9package org.dartlang.analysis.server.protocol;
11import java.util.Arrays;
14import com.google.common.collect.Lists;
15import com.google.dart.server.utilities.general.JsonUtilities;
16import com.google.dart.server.utilities.general.ObjectUtilities;
17import com.google.gson.JsonArray;
18import com.google.gson.JsonElement;
19import com.google.gson.JsonObject;
20import com.google.gson.JsonPrimitive;
21import org.apache.commons.lang3.builder.HashCodeBuilder;
22import java.util.ArrayList;
23import java.util.Iterator;
24import org.apache.commons.lang3.StringUtils;
31@SuppressWarnings(
"unused")
65 private String parameters;
75 this.parameters = parameters;
83 ObjectUtilities.
equals(other.id,
id) &&
84 ObjectUtilities.equals(other.kind, kind) &&
85 ObjectUtilities.equals(other.type,
type) &&
86 ObjectUtilities.equals(other.name,
name) &&
87 ObjectUtilities.equals(other.parameters, parameters);
93 String
id = jsonObject.get(
"id") ==
null ? null : jsonObject.get(
"id").getAsString();
94 String kind = jsonObject.get(
"kind").getAsString();
95 String
type = jsonObject.get(
"type").getAsString();
96 String
name = jsonObject.get(
"name").getAsString();
97 String parameters = jsonObject.get(
"parameters") ==
null ? null : jsonObject.get(
"parameters").getAsString();
102 if (jsonArray ==
null) {
105 ArrayList<RefactoringMethodParameter> list =
new ArrayList<RefactoringMethodParameter>(jsonArray.size());
106 Iterator<JsonElement> iterator = jsonArray.iterator();
107 while (iterator.hasNext()) {
108 list.add(fromJson(iterator.next().getAsJsonObject()));
154 HashCodeBuilder
builder =
new HashCodeBuilder();
191 this.parameters = parameters;
203 JsonObject jsonObject =
new JsonObject();
205 jsonObject.addProperty(
"id",
id);
207 jsonObject.addProperty(
"kind", kind);
208 jsonObject.addProperty(
"type",
type);
209 jsonObject.addProperty(
"name",
name);
210 if (parameters !=
null) {
211 jsonObject.addProperty(
"parameters", parameters);
218 StringBuilder
builder =
new StringBuilder();
void setName(String name)
static RefactoringMethodParameter fromJson(JsonObject jsonObject)
void setParameters(String parameters)
void setKind(String kind)
boolean equals(Object obj)
static List< RefactoringMethodParameter > fromJsonArray(JsonArray jsonArray)
void setType(String type)
RefactoringMethodParameter(String id, String kind, String type, String name, String parameters)
DEF_SWITCHES_START aot vmservice shared library name