Flutter Engine
The Flutter Engine
Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
org.dartlang.analysis.server.protocol.AnalysisStatus Class Reference

Public Member Functions

 AnalysisStatus (boolean isAnalyzing, String analysisTarget)
 
boolean equals (Object obj)
 
String getAnalysisTarget ()
 
boolean isAnalyzing ()
 
int hashCode ()
 
JsonObject toJson ()
 
String toString ()
 

Static Public Member Functions

static AnalysisStatus fromJson (JsonObject jsonObject)
 
static List< AnalysisStatusfromJsonArray (JsonArray jsonArray)
 

Static Public Attributes

static final AnalysisStatus[] EMPTY_ARRAY = new AnalysisStatus[0]
 
static final List< AnalysisStatusEMPTY_LIST = Lists.newArrayList()
 

Detailed Description

An indication of the current state of analysis.

@coverage dart.server.generated.types

Definition at line 32 of file AnalysisStatus.java.

Constructor & Destructor Documentation

◆ AnalysisStatus()

org.dartlang.analysis.server.protocol.AnalysisStatus.AnalysisStatus ( boolean  isAnalyzing,
String  analysisTarget 
)
inline

Constructor for AnalysisStatus.

Definition at line 51 of file AnalysisStatus.java.

51 {
52 this.isAnalyzing = isAnalyzing;
53 this.analysisTarget = analysisTarget;
54 }

Member Function Documentation

◆ equals()

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

Definition at line 57 of file AnalysisStatus.java.

57 {
58 if (obj instanceof AnalysisStatus) {
59 AnalysisStatus other = (AnalysisStatus) obj;
60 return
61 other.isAnalyzing == isAnalyzing &&
62 ObjectUtilities.equals(other.analysisTarget, analysisTarget);
63 }
64 return false;
65 }
AnalysisStatus(boolean isAnalyzing, String analysisTarget)

◆ fromJson()

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

Definition at line 67 of file AnalysisStatus.java.

67 {
68 boolean isAnalyzing = jsonObject.get("isAnalyzing").getAsBoolean();
69 String analysisTarget = jsonObject.get("analysisTarget") == null ? null : jsonObject.get("analysisTarget").getAsString();
70 return new AnalysisStatus(isAnalyzing, analysisTarget);
71 }

◆ fromJsonArray()

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

Definition at line 73 of file AnalysisStatus.java.

73 {
74 if (jsonArray == null) {
75 return EMPTY_LIST;
76 }
77 ArrayList<AnalysisStatus> list = new ArrayList<AnalysisStatus>(jsonArray.size());
78 Iterator<JsonElement> iterator = jsonArray.iterator();
79 while (iterator.hasNext()) {
80 list.add(fromJson(iterator.next().getAsJsonObject()));
81 }
82 return list;
83 }
static final List< AnalysisStatus > EMPTY_LIST
static AnalysisStatus fromJson(JsonObject jsonObject)

◆ getAnalysisTarget()

String org.dartlang.analysis.server.protocol.AnalysisStatus.getAnalysisTarget ( )
inline

The name of the current target of analysis. This field is omitted if analyzing is false.

Definition at line 88 of file AnalysisStatus.java.

88 {
89 return analysisTarget;
90 }

◆ hashCode()

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

Definition at line 100 of file AnalysisStatus.java.

100 {
101 HashCodeBuilder builder = new HashCodeBuilder();
102 builder.append(isAnalyzing);
103 builder.append(analysisTarget);
104 return builder.toHashCode();
105 }

◆ isAnalyzing()

boolean org.dartlang.analysis.server.protocol.AnalysisStatus.isAnalyzing ( )
inline

True if analysis is currently being performed.

Definition at line 95 of file AnalysisStatus.java.

95 {
96 return isAnalyzing;
97 }

◆ toJson()

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

Definition at line 107 of file AnalysisStatus.java.

107 {
108 JsonObject jsonObject = new JsonObject();
109 jsonObject.addProperty("isAnalyzing", isAnalyzing);
110 if (analysisTarget != null) {
111 jsonObject.addProperty("analysisTarget", analysisTarget);
112 }
113 return jsonObject;
114 }

◆ toString()

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

Definition at line 117 of file AnalysisStatus.java.

117 {
118 StringBuilder builder = new StringBuilder();
119 builder.append("[");
120 builder.append("isAnalyzing=");
121 builder.append(isAnalyzing + ", ");
122 builder.append("analysisTarget=");
123 builder.append(analysisTarget);
124 builder.append("]");
125 return builder.toString();
126 }

Member Data Documentation

◆ EMPTY_ARRAY

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

Definition at line 34 of file AnalysisStatus.java.

◆ EMPTY_LIST

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

Definition at line 36 of file AnalysisStatus.java.


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