boolean function ( State arg0 ) { synchronized ( listeners ) { if ( arg0 . ordinal ( ) > state . ordinal ( ) && state . ordinal ( ) < State . CANCELLED . ordinal ( ) ) { state = arg0 ; for ( Listener loc0 : listeners ) { fireStateChange ( arg0 , loc0 ) ; } return true ; } return false ; } }
changes the state of this job handle , making sure that illegal state transitions are ignored . fires events appropriately . as a rule , state transitions can only occur if the current state is `` higher '' than the current state i.e. , has a higher ordinal number and is not a `` final '' state . `` final '' states are cancelled , failed and succeeded , defined here in the code as having an ordinal number higher than the cancelled enum constant . concode_field_sep String jobId concode_elem_sep List<Listener> listeners concode_elem_sep List<Integer> sparkJobIds concode_elem_sep SparkClientImpl client concode_elem_sep Promise<T> promise concode_elem_sep MetricsCollection metrics concode_elem_sep State state concode_elem_sep SparkCounters sparkCounters concode_field_sep boolean cancel concode_elem_sep boolean isCancelled concode_elem_sep void fireStateChange concode_elem_sep String getClientJobId concode_elem_sep SparkCounters getSparkCounters concode_elem_sep MetricsCollection getMetrics concode_elem_sep void addSparkJobId concode_elem_sep boolean isDone concode_elem_sep List<Integer> getSparkJobIds concode_elem_sep void setSuccess concode_elem_sep void setFailure concode_elem_sep State getState concode_elem_sep T get concode_elem_sep T get concode_elem_sep void finalize concode_elem_sep void setSparkCounters concode_elem_sep void addListener