Flutter Engine
The Flutter Engine
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
org.dartlang.analysis.server.protocol.RenameOptions Class Reference
Inheritance diagram for org.dartlang.analysis.server.protocol.RenameOptions:
org.dartlang.analysis.server.protocol.RefactoringOptions

Public Member Functions

 RenameOptions (String newName)
 
boolean equals (Object obj)
 
String getNewName ()
 
int hashCode ()
 
void setNewName (String newName)
 
JsonObject toJson ()
 
String toString ()
 
- Public Member Functions inherited from org.dartlang.analysis.server.protocol.RefactoringOptions
 RefactoringOptions ()
 
boolean equals (Object obj)
 
int hashCode ()
 
JsonObject toJson ()
 
String toString ()
 

Static Public Member Functions

static RenameOptions fromJson (JsonObject jsonObject)
 
static List< RenameOptionsfromJsonArray (JsonArray jsonArray)
 
static RefactoringOptions fromJson (JsonObject jsonObject)
 

Static Public Attributes

static final RenameOptions[] EMPTY_ARRAY = new RenameOptions[0]
 
static final List< RenameOptionsEMPTY_LIST = Lists.newArrayList()
 
- Static Public Attributes inherited from org.dartlang.analysis.server.protocol.RefactoringOptions
static final RefactoringOptions[] EMPTY_ARRAY = new RefactoringOptions[0]
 
static final List< RefactoringOptionsEMPTY_LIST = Lists.newArrayList()
 

Detailed Description

@coverage dart.server.generated.types

Definition at line 30 of file RenameOptions.java.

Constructor & Destructor Documentation

◆ RenameOptions()

org.dartlang.analysis.server.protocol.RenameOptions.RenameOptions ( String  newName)
inline

Constructor for RenameOptions.

Definition at line 44 of file RenameOptions.java.

44 {
45 this.newName = newName;
46 }

Member Function Documentation

◆ equals()

boolean org.dartlang.analysis.server.protocol.RenameOptions.equals ( Object  obj)
inline

Reimplemented from org.dartlang.analysis.server.protocol.RefactoringOptions.

Definition at line 49 of file RenameOptions.java.

49 {
50 if (obj instanceof RenameOptions) {
51 RenameOptions other = (RenameOptions) obj;
52 return
53 ObjectUtilities.equals(other.newName, newName);
54 }
55 return false;
56 }

◆ fromJson()

static RenameOptions org.dartlang.analysis.server.protocol.RenameOptions.fromJson ( JsonObject  jsonObject)
inlinestatic

Reimplemented from org.dartlang.analysis.server.protocol.RefactoringOptions.

Definition at line 58 of file RenameOptions.java.

58 {
59 String newName = jsonObject.get("newName").getAsString();
60 return new RenameOptions(newName);
61 }

◆ fromJsonArray()

static List< RenameOptions > org.dartlang.analysis.server.protocol.RenameOptions.fromJsonArray ( JsonArray  jsonArray)
inlinestatic

Definition at line 63 of file RenameOptions.java.

63 {
64 if (jsonArray == null) {
65 return EMPTY_LIST;
66 }
67 ArrayList<RenameOptions> list = new ArrayList<RenameOptions>(jsonArray.size());
68 Iterator<JsonElement> iterator = jsonArray.iterator();
69 while (iterator.hasNext()) {
70 list.add(fromJson(iterator.next().getAsJsonObject()));
71 }
72 return list;
73 }
static RenameOptions fromJson(JsonObject jsonObject)
static final List< RenameOptions > EMPTY_LIST

◆ getNewName()

String org.dartlang.analysis.server.protocol.RenameOptions.getNewName ( )
inline

The name that the element should have after the refactoring.

Definition at line 78 of file RenameOptions.java.

78 {
79 return newName;
80 }

◆ hashCode()

int org.dartlang.analysis.server.protocol.RenameOptions.hashCode ( )
inline

Reimplemented from org.dartlang.analysis.server.protocol.RefactoringOptions.

Definition at line 83 of file RenameOptions.java.

83 {
84 HashCodeBuilder builder = new HashCodeBuilder();
85 builder.append(newName);
86 return builder.toHashCode();
87 }

◆ setNewName()

void org.dartlang.analysis.server.protocol.RenameOptions.setNewName ( String  newName)
inline

The name that the element should have after the refactoring.

Definition at line 92 of file RenameOptions.java.

92 {
93 this.newName = newName;
94 }

◆ toJson()

JsonObject org.dartlang.analysis.server.protocol.RenameOptions.toJson ( )
inline

Reimplemented from org.dartlang.analysis.server.protocol.RefactoringOptions.

Definition at line 96 of file RenameOptions.java.

96 {
97 JsonObject jsonObject = new JsonObject();
98 jsonObject.addProperty("newName", newName);
99 return jsonObject;
100 }

◆ toString()

String org.dartlang.analysis.server.protocol.RenameOptions.toString ( )
inline

Reimplemented from org.dartlang.analysis.server.protocol.RefactoringOptions.

Definition at line 103 of file RenameOptions.java.

103 {
104 StringBuilder builder = new StringBuilder();
105 builder.append("[");
106 builder.append("newName=");
107 builder.append(newName);
108 builder.append("]");
109 return builder.toString();
110 }

Member Data Documentation

◆ EMPTY_ARRAY

final RenameOptions [] org.dartlang.analysis.server.protocol.RenameOptions.EMPTY_ARRAY = new RenameOptions[0]
static

Definition at line 32 of file RenameOptions.java.

◆ EMPTY_LIST

final List<RenameOptions> org.dartlang.analysis.server.protocol.RenameOptions.EMPTY_LIST = Lists.newArrayList()
static

Definition at line 34 of file RenameOptions.java.


The documentation for this class was generated from the following file: