idx
int64
0
41.2k
question
stringlengths
74
4.04k
target
stringlengths
7
750
33,500
private Object convertStrToObjTree ( String s ) { Object contentObj = null ; if ( s != null ) { s = s . trim ( ) ; try { if ( s . startsWith ( "{" ) ) { contentObj = Config . getInstance ( ) . getMapper ( ) . readValue ( s , new TypeReference < HashMap < String , Object > > ( ) { } ) ; } else if ( s . startsWith ( "[" ) ) { contentObj = Config . getInstance ( ) . getMapper ( ) . readValue ( s , new TypeReference < List < Object > > ( ) { } ) ; } else { logger . error ( "cannot deserialize json str: {}" , s ) ; return null ; } } catch ( IOException e ) { logger . error ( e . getMessage ( ) ) ; } } return contentObj ; }
try to convert a string with json style to a structured object .
33,501
private OpenApiOperation getOpenApiOperation ( String uri , String httpMethod ) throws URISyntaxException { String uriWithoutQuery = new URI ( uri ) . getPath ( ) ; NormalisedPath requestPath = new ApiNormalisedPath ( uriWithoutQuery ) ; Optional < NormalisedPath > maybeApiPath = OpenApiHelper . findMatchingApiPath ( requestPath ) ; if ( ! maybeApiPath . isPresent ( ) ) { return null ; } final NormalisedPath openApiPathString = maybeApiPath . get ( ) ; final Path path = OpenApiHelper . openApi3 . getPath ( openApiPathString . original ( ) ) ; final Operation operation = path . getOperation ( httpMethod ) ; return new OpenApiOperation ( openApiPathString , path , httpMethod , operation ) ; }
locate operation based on uri and httpMethod
33,502
public FilterStreamParameters follow ( long follow ) { if ( this . follow . length ( ) > 0 ) { this . follow . append ( ',' ) ; } this . follow . append ( follow ) ; return this ; }
Add a user to follow in the stream . Does not replace any existing follows in the filter .
33,503
public AbstractStreamParameters track ( String track ) { if ( this . track . length ( ) > 0 ) { this . track . append ( ',' ) ; } this . track . append ( track ) ; return this ; }
Add tracking keywords to the filter . Does not replace any existing tracking keywords in the filter .
33,504
public AbstractStreamParameters addLocation ( float west , float south , float east , float north ) { if ( locations . length ( ) > 0 ) { locations . append ( ',' ) ; } locations . append ( west ) . append ( ',' ) . append ( south ) . append ( ',' ) ; locations . append ( east ) . append ( ',' ) . append ( north ) . append ( ',' ) ; return this ; }
Add a location to the filter Does not replace any existing locations in the filter .
33,505
private Entities toEntities ( final JsonNode node , String text ) throws IOException { if ( null == node || node . isNull ( ) || node . isMissingNode ( ) ) { return null ; } final ObjectMapper mapper = this . createMapper ( ) ; Entities entities = mapper . readerFor ( Entities . class ) . readValue ( node ) ; extractTickerSymbolEntitiesFromText ( text , entities ) ; return entities ; }
passing in text to fetch ticker symbol pseudo - entities
33,506
public UserStateResult getUserState ( String username ) throws APIConnectionException , APIRequestException { StringUtils . checkUsername ( username ) ; ResponseWrapper response = _httpClient . sendGet ( _baseUrl + userPath + "/" + username + "/userstat" ) ; return UserStateResult . fromResponse ( response , UserStateResult . class ) ; }
Get user state
33,507
public UserStateListResult [ ] getUsersState ( String ... users ) throws APIConnectionException , APIRequestException { JsonArray jsonArray = new JsonArray ( ) ; for ( String username : users ) { StringUtils . checkUsername ( username ) ; jsonArray . add ( new JsonPrimitive ( username ) ) ; } ResponseWrapper response = _httpClient . sendPost ( _baseUrl + userPath + "/userstat" , jsonArray . toString ( ) ) ; return _gson . fromJson ( response . responseContent , UserStateListResult [ ] . class ) ; }
Get users state
33,508
public UserInfoResult [ ] getBlackList ( String username ) throws APIConnectionException , APIRequestException { StringUtils . checkUsername ( username ) ; ResponseWrapper response = _httpClient . sendGet ( _baseUrl + userPath + "/" + username + "/blacklist" ) ; return _gson . fromJson ( response . responseContent , UserInfoResult [ ] . class ) ; }
Get a user s all black list
33,509
public UserGroupsResult getGroupList ( String username ) throws APIConnectionException , APIRequestException { StringUtils . checkUsername ( username ) ; ResponseWrapper response = _httpClient . sendGet ( _baseUrl + userPath + "/" + username + "/groups" ) ; return UserGroupsResult . fromResponse ( response ) ; }
Get all groups of a user
33,510
public ResponseWrapper addBlackList ( String username , String ... users ) throws APIConnectionException , APIRequestException { return _userClient . addBlackList ( username , users ) ; }
Add Users to black list
33,511
public ResponseWrapper setNoDisturb ( String username , NoDisturbPayload payload ) throws APIConnectionException , APIRequestException { return _userClient . setNoDisturb ( username , payload ) ; }
Set don t disturb service while receiving messages . You can Add or remove single conversation or group conversation
33,512
public void addOrRemoveMembers ( long gid , String [ ] addList , String [ ] removeList ) throws APIConnectionException , APIRequestException { Members add = Members . newBuilder ( ) . addMember ( addList ) . build ( ) ; Members remove = Members . newBuilder ( ) . addMember ( removeList ) . build ( ) ; _groupClient . addOrRemoveMembers ( gid , add , remove ) ; }
Add or remove members from a group
33,513
public SendMessageResult sendSingleTextByAdmin ( String targetId , String fromId , MessageBody body ) throws APIConnectionException , APIRequestException { return sendMessage ( _sendVersion , "single" , targetId , "admin" , fromId , MessageType . TEXT , body ) ; }
Send single text message by admin
33,514
public ResponseWrapper addCrossBlacklist ( String username , CrossBlacklist [ ] blacklists ) throws APIConnectionException , APIRequestException { return _crossAppClient . addCrossBlacklist ( username , blacklists ) ; }
Add blacklist whose users belong to another app to a given user .
33,515
public CreateChatRoomResult createChatRoom ( ChatRoomPayload payload ) throws APIConnectionException , APIRequestException { Preconditions . checkArgument ( null != payload , "ChatRoomPayload should not be null" ) ; ResponseWrapper responseWrapper = _httpClient . sendPost ( _baseUrl + mChatRoomPath , payload . toString ( ) ) ; return CreateChatRoomResult . fromResponse ( responseWrapper , CreateChatRoomResult . class ) ; }
Create chat room
33,516
public ChatRoomListResult getBatchChatRoomInfo ( long ... roomIds ) throws APIConnectionException , APIRequestException { Preconditions . checkArgument ( roomIds != null && roomIds . length > 0 , "Room ids should not be null" ) ; JsonArray array = new JsonArray ( ) ; for ( long id : roomIds ) { array . add ( new JsonPrimitive ( id ) ) ; } ResponseWrapper responseWrapper = _httpClient . sendPost ( _baseUrl + mChatRoomPath + "/batch" , array . toString ( ) ) ; return ChatRoomListResult . fromResponse ( responseWrapper ) ; }
Get chat room information by room ids
33,517
public ChatRoomListResult getUserChatRoomInfo ( String username ) throws APIConnectionException , APIRequestException { StringUtils . checkUsername ( username ) ; ResponseWrapper responseWrapper = _httpClient . sendGet ( _baseUrl + mUserPath + "/" + username + "/chatroom" ) ; return ChatRoomListResult . fromResponse ( responseWrapper ) ; }
Get user s whole chat room information
33,518
public ResponseWrapper deleteChatRoom ( long roomId ) throws APIConnectionException , APIRequestException { Preconditions . checkArgument ( roomId > 0 , "room id is invalid" ) ; return _httpClient . sendDelete ( _baseUrl + mChatRoomPath + "/" + roomId ) ; }
Delete chat room by id
33,519
public DownloadResult downloadFile ( String mediaId ) throws APIConnectionException , APIRequestException { Preconditions . checkArgument ( null != mediaId , "mediaId is necessary" ) ; ResponseWrapper response = _httpClient . sendGet ( _baseUrl + resourcePath + "?mediaId=" + mediaId ) ; return DownloadResult . fromResponse ( response , DownloadResult . class ) ; }
Download file with mediaId will return DownloadResult which include url .
33,520
public MessageListResult v2GetMessageListByCursor ( String cursor ) throws APIConnectionException , APIRequestException { if ( null != cursor ) { String requestUrl = mBaseReportPath + mV2MessagePath + "?cursor=" + cursor ; ResponseWrapper response = _httpClient . sendGet ( requestUrl ) ; return MessageListResult . fromResponse ( response , MessageListResult . class ) ; } else { throw new IllegalArgumentException ( "the cursor parameter should not be null" ) ; } }
Get message list with cursor the cursor will effective in 120 seconds . And will return same count of messages as first request .
33,521
public MemberListResult getCrossGroupMembers ( long gid ) throws APIConnectionException , APIRequestException { Preconditions . checkArgument ( 0 != gid , "gid must not be empty" ) ; ResponseWrapper response = _httpClient . sendGet ( _baseUrl + crossGroupPath + "/" + gid + "/members/" ) ; return MemberListResult . fromResponse ( response ) ; }
Get members info from cross group
33,522
public ResponseWrapper deleteCrossBlacklist ( String username , CrossBlacklist [ ] blacklists ) throws APIConnectionException , APIRequestException { StringUtils . checkUsername ( username ) ; CrossBlacklistPayload payload = new CrossBlacklistPayload . Builder ( ) . setCrossBlacklists ( blacklists ) . build ( ) ; return _httpClient . sendDelete ( _baseUrl + crossUserPath + "/" + username + "/blacklist" , payload . toString ( ) ) ; }
Delete blacklist whose users belong to another app from a given user .
33,523
public ResponseWrapper deleteSensitiveWord ( String word ) throws APIConnectionException , APIRequestException { Preconditions . checkArgument ( word . length ( ) <= 10 , "one word's max length is 10" ) ; JsonObject jsonObject = new JsonObject ( ) ; jsonObject . addProperty ( "word" , word ) ; return _httpClient . sendDelete ( _baseUrl + sensitiveWordPath , jsonObject . toString ( ) ) ; }
Delete sensitive word
33,524
public ResponseWrapper updateSensitiveWordStatus ( int status ) throws APIConnectionException , APIRequestException { Preconditions . checkArgument ( status == 0 || status == 1 , "status should be 0 or 1" ) ; return _httpClient . sendPut ( _baseUrl + sensitiveWordPath + "/status?status=" + status , null ) ; }
Update sensitive word status
33,525
public SensitiveWordStatusResult getSensitiveWordStatus ( ) throws APIConnectionException , APIRequestException { ResponseWrapper responseWrapper = _httpClient . sendGet ( _baseUrl + sensitiveWordPath + "/status" ) ; return _gson . fromJson ( responseWrapper . responseContent , SensitiveWordStatusResult . class ) ; }
Get sensitive word status
33,526
public void setAction ( final Action fromAction , final Action toAction , final int rotation , long delay ) { setAction ( fromAction , false , ROTATE_CLOCKWISE ) ; postDelayed ( new Runnable ( ) { public void run ( ) { if ( ! isAttachedToWindow ( ) ) { return ; } setAction ( toAction , true , rotation ) ; } } , delay ) ; }
Sets a new action transition .
33,527
private float calculateScale ( int x , int y ) { final float centerX = getWidth ( ) / 2f ; final float centerY = getHeight ( ) / 2f ; final float maxDistance = ( float ) Math . sqrt ( centerX * centerX + centerY * centerY ) ; final float deltaX = centerX - x ; final float deltaY = centerY - y ; final float distance = ( float ) Math . sqrt ( deltaX * deltaX + deltaY * deltaY ) ; final float scale = 0.5f + ( distance / maxDistance ) * 0.5f ; return scale ; }
calculates the required scale of the ink - view to fill the whole view
33,528
public static boolean validOptions ( String [ ] [ ] options , DocErrorReporter reporter ) { return SARL_DOCLET . configuration . validOptions ( options , reporter ) ; }
Validate the given options .
33,529
public List < UUID > spawn ( int nbAgents , Class < ? extends Agent > agent , Object ... params ) { return this . spawnService . spawn ( nbAgents , null , this . janusContext , null , agent , params ) ; }
Spawn agents of the given type and pass the parameters to its initialization function .
33,530
public UUID spawn ( UUID agentID , Class < ? extends Agent > agent , Object ... params ) { final List < UUID > ids = this . spawnService . spawn ( 1 , null , this . janusContext , agentID , agent , params ) ; if ( ids . isEmpty ( ) ) { return null ; } return ids . get ( 0 ) ; }
Spawn an agent of the given type and pass the parameters to its initialization function .
33,531
public < S extends Service > S getService ( Class < S > type ) { for ( final Service serv : this . serviceManager . servicesByState ( ) . values ( ) ) { if ( serv . isRunning ( ) && type . isInstance ( serv ) ) { return type . cast ( serv ) ; } } return null ; }
Replies a kernel service that is alive .
33,532
public void setCodeminingEnabled ( Boolean enable ) { final IPreferenceStore store = getWritablePreferenceStore ( null ) ; if ( enable == null ) { store . setToDefault ( CODEMINING_PROPERTY ) ; } else { store . setValue ( CODEMINING_PROPERTY , enable . booleanValue ( ) ) ; } }
Enable or disable the codemining feature into the SARL editor .
33,533
public static void addFormalParameter ( ExecutableMemberDoc member , Parameter param , boolean isVarArg , Content htmlTree , SarlConfiguration configuration , SubWriterHolderWriter writer ) { final ProxyInstaller proxyInstaller = configuration . getProxyInstaller ( ) ; final ExecutableMemberDoc omember = proxyInstaller . unwrap ( member ) ; final Parameter oparam = proxyInstaller . unwrap ( param ) ; final String defaultValue = Utils . getParameterDefaultValue ( omember , oparam , configuration ) ; final boolean addDefaultValueBrackets = Utils . isNullOrEmpty ( defaultValue ) && Utils . isDefaultValuedParameter ( oparam , configuration ) ; if ( addDefaultValueBrackets ) { htmlTree . addContent ( "[" ) ; } if ( oparam . name ( ) . length ( ) > 0 ) { htmlTree . addContent ( oparam . name ( ) ) ; } htmlTree . addContent ( writer . getSpace ( ) ) ; htmlTree . addContent ( Utils . getKeywords ( ) . getColonKeyword ( ) ) ; htmlTree . addContent ( " " ) ; if ( oparam . type ( ) != null ) { final Content link = writer . getLink ( new LinkInfoImpl ( configuration , LinkInfoImpl . Kind . EXECUTABLE_MEMBER_PARAM , oparam . type ( ) ) . varargs ( isVarArg ) ) ; htmlTree . addContent ( link ) ; } if ( addDefaultValueBrackets ) { htmlTree . addContent ( "]" ) ; } else if ( ! Utils . isNullOrEmpty ( defaultValue ) ) { htmlTree . addContent ( " " ) ; htmlTree . addContent ( Utils . getKeywords ( ) . getEqualsSignKeyword ( ) ) ; htmlTree . addContent ( writer . getSpace ( ) ) ; htmlTree . addContent ( defaultValue ) ; } }
Add a parameter to the given executable member .
33,534
public String getKeyString ( ) { if ( ! Strings . isEmpty ( getAnnotatedWith ( ) ) ) { return MessageFormat . format ( "@{1} {0}" , getBind ( ) , getAnnotatedWith ( ) ) ; } if ( ! Strings . isEmpty ( getAnnotatedWithName ( ) ) ) { return MessageFormat . format ( "@Named({1}) {0}" , getBind ( ) , getAnnotatedWithName ( ) ) ; } return MessageFormat . format ( "{0}" , getBind ( ) ) ; }
Replies the string representation of the binding key .
33,535
protected void refreshSREListUI ( ) { final Display display = Display . getDefault ( ) ; if ( display . getThread ( ) . equals ( Thread . currentThread ( ) ) ) { if ( ! this . sresList . isBusy ( ) ) { this . sresList . refresh ( ) ; } } else { display . syncExec ( new Runnable ( ) { @ SuppressWarnings ( "synthetic-access" ) public void run ( ) { if ( ! SREsPreferencePage . this . sresList . isBusy ( ) ) { SREsPreferencePage . this . sresList . refresh ( ) ; } } } ) ; } }
Refresh the UI list of SRE .
33,536
public void setErrorMessage ( Throwable exception ) { if ( exception != null ) { String message = exception . getLocalizedMessage ( ) ; if ( Strings . isNullOrEmpty ( message ) ) { message = exception . getMessage ( ) ; } if ( Strings . isNullOrEmpty ( message ) ) { message = MessageFormat . format ( Messages . SREsPreferencePage_9 , exception . getClass ( ) . getName ( ) ) ; } setErrorMessage ( message ) ; } }
Set the error message from the given exception .
33,537
protected void setSREs ( ISREInstall [ ] sres ) { this . sreArray . clear ( ) ; for ( final ISREInstall sre : sres ) { this . sreArray . add ( sre ) ; } this . sresList . setInput ( this . sreArray ) ; refreshSREListUI ( ) ; updateUI ( ) ; }
Sets the SREs to be displayed in this block .
33,538
public String createUniqueName ( String name ) { if ( ! isDuplicateName ( name ) ) { return name ; } if ( name . matches ( ".*\\(\\d*\\)" ) ) { final int start = name . lastIndexOf ( '(' ) ; final int end = name . lastIndexOf ( ')' ) ; final String stringInt = name . substring ( start + 1 , end ) ; final int numericValue = Integer . parseInt ( stringInt ) ; final String newName = name . substring ( 0 , start + 1 ) + ( numericValue + 1 ) + ")" ; return createUniqueName ( newName ) ; } return createUniqueName ( name + " (1)" ) ; }
Compares the given name against current names and adds the appropriate numerical suffix to ensure that it is unique .
33,539
protected void addSRE ( ) { final AddSREInstallWizard wizard = new AddSREInstallWizard ( createUniqueIdentifier ( ) , this . sreArray . toArray ( new ISREInstall [ this . sreArray . size ( ) ] ) ) ; final WizardDialog dialog = new WizardDialog ( getShell ( ) , wizard ) ; if ( dialog . open ( ) == Window . OK ) { final ISREInstall result = wizard . getCreatedSRE ( ) ; if ( result != null ) { this . sreArray . add ( result ) ; refreshSREListUI ( ) ; this . sresList . setSelection ( new StructuredSelection ( result ) ) ; if ( ! this . sresList . isBusy ( ) ) { this . sresList . refresh ( true ) ; } updateUI ( ) ; if ( getDefaultSRE ( ) == null ) { setDefaultSRE ( result ) ; } } } }
Add a SRE .
33,540
protected void editSRE ( ) { final IStructuredSelection selection = ( IStructuredSelection ) this . sresList . getSelection ( ) ; final ISREInstall sre = ( ISREInstall ) selection . getFirstElement ( ) ; if ( sre == null ) { return ; } final EditSREInstallWizard wizard = new EditSREInstallWizard ( sre , this . sreArray . toArray ( new ISREInstall [ this . sreArray . size ( ) ] ) ) ; final WizardDialog dialog = new WizardDialog ( getShell ( ) , wizard ) ; if ( dialog . open ( ) == Window . OK ) { this . sresList . setSelection ( new StructuredSelection ( sre ) ) ; this . sresList . refresh ( true ) ; updateUI ( ) ; } }
Edit the selected SRE .
33,541
@ SuppressWarnings ( "unchecked" ) protected void copySRE ( ) { final IStructuredSelection selection = ( IStructuredSelection ) this . sresList . getSelection ( ) ; final Iterator < ISREInstall > it = selection . iterator ( ) ; final List < ISREInstall > newEntries = new ArrayList < > ( ) ; while ( it . hasNext ( ) ) { final ISREInstall selectedSRE = it . next ( ) ; final ISREInstall copy = selectedSRE . copy ( createUniqueIdentifier ( ) ) ; copy . setName ( createUniqueName ( selectedSRE . getName ( ) ) ) ; final EditSREInstallWizard wizard = new EditSREInstallWizard ( copy , this . sreArray . toArray ( new ISREInstall [ this . sreArray . size ( ) ] ) ) ; final WizardDialog dialog = new WizardDialog ( getShell ( ) , wizard ) ; final int dlgResult = dialog . open ( ) ; if ( dlgResult == Window . OK ) { newEntries . add ( copy ) ; } else { assert dlgResult == Window . CANCEL ; break ; } } if ( ! newEntries . isEmpty ( ) ) { this . sreArray . addAll ( newEntries ) ; refreshSREListUI ( ) ; this . sresList . setSelection ( new StructuredSelection ( newEntries . toArray ( ) ) ) ; } else { this . sresList . setSelection ( selection ) ; } this . sresList . refresh ( true ) ; updateUI ( ) ; }
Copy the selected SRE .
33,542
@ SuppressWarnings ( "unchecked" ) protected void removeSREs ( ) { final IStructuredSelection selection = ( IStructuredSelection ) this . sresList . getSelection ( ) ; final ISREInstall [ ] vms = new ISREInstall [ selection . size ( ) ] ; final Iterator < ISREInstall > iter = selection . iterator ( ) ; int i = 0 ; while ( iter . hasNext ( ) ) { vms [ i ] = iter . next ( ) ; i ++ ; } removeSREs ( vms ) ; }
Remove the selected SREs .
33,543
@ SuppressWarnings ( "checkstyle:npathcomplexity" ) public void removeSREs ( ISREInstall ... sres ) { final ISREInstall defaultSRE = getDefaultSRE ( ) ; final String defaultId = defaultSRE == null ? null : defaultSRE . getId ( ) ; int defaultIndex = - 1 ; if ( defaultId != null ) { for ( int i = 0 ; defaultIndex == - 1 && i < this . sreTable . getItemCount ( ) ; ++ i ) { if ( defaultId . equals ( ( ( ISREInstall ) this . sreTable . getItem ( i ) . getData ( ) ) . getId ( ) ) ) { defaultIndex = i ; } } } final String normedDefaultId = Strings . nullToEmpty ( defaultId ) ; boolean defaultIsRemoved = false ; for ( final ISREInstall sre : sres ) { if ( this . sreArray . remove ( sre ) && sre . getId ( ) . equals ( normedDefaultId ) ) { defaultIsRemoved = true ; } } refreshSREListUI ( ) ; if ( defaultIsRemoved ) { if ( this . sreTable . getItemCount ( ) == 0 ) { setSelection ( null ) ; } else { if ( defaultIndex < 0 ) { defaultIndex = 0 ; } else if ( defaultIndex >= this . sreTable . getItemCount ( ) ) { defaultIndex = this . sreTable . getItemCount ( ) - 1 ; } setSelection ( new StructuredSelection ( this . sreTable . getItem ( defaultIndex ) . getData ( ) ) ) ; } } this . sresList . refresh ( true ) ; if ( defaultIsRemoved ) { fireDefaultSREChanged ( ) ; } updateUI ( ) ; }
Removes the given SREs from the table .
33,544
@ SuppressWarnings ( "unchecked" ) private void enableButtons ( ) { final IStructuredSelection selection = ( IStructuredSelection ) this . sresList . getSelection ( ) ; final int selectionCount = selection . size ( ) ; this . editButton . setEnabled ( selectionCount == 1 ) ; this . copyButton . setEnabled ( selectionCount > 0 ) ; if ( selectionCount > 0 && selectionCount <= this . sresList . getTable ( ) . getItemCount ( ) ) { final Iterator < ISREInstall > iterator = selection . iterator ( ) ; while ( iterator . hasNext ( ) ) { final ISREInstall install = iterator . next ( ) ; if ( SARLRuntime . isPlatformSRE ( install ) ) { this . removeButton . setEnabled ( false ) ; return ; } } this . removeButton . setEnabled ( true ) ; } else { this . removeButton . setEnabled ( false ) ; } }
Enables the buttons based on selected items counts in the viewer .
33,545
private void sortByName ( ) { this . sresList . setComparator ( new ViewerComparator ( ) { public int compare ( Viewer viewer , Object e1 , Object e2 ) { if ( ( e1 instanceof ISREInstall ) && ( e2 instanceof ISREInstall ) ) { final ISREInstall left = ( ISREInstall ) e1 ; final ISREInstall right = ( ISREInstall ) e2 ; return left . getName ( ) . compareToIgnoreCase ( right . getName ( ) ) ; } return super . compare ( viewer , e1 , e2 ) ; } public boolean isSorterProperty ( Object element , String property ) { return true ; } } ) ; this . sortColumn = Column . NAME ; }
Sorts by SRE name .
33,546
private void sortByLocation ( ) { this . sresList . setComparator ( new ViewerComparator ( ) { public int compare ( Viewer viewer , Object e1 , Object e2 ) { if ( ( e1 instanceof ISREInstall ) && ( e2 instanceof ISREInstall ) ) { final ISREInstall left = ( ISREInstall ) e1 ; final ISREInstall right = ( ISREInstall ) e2 ; return left . getLocation ( ) . compareToIgnoreCase ( right . getLocation ( ) ) ; } return super . compare ( viewer , e1 , e2 ) ; } public boolean isSorterProperty ( Object element , String property ) { return true ; } } ) ; this . sortColumn = Column . LOCATION ; }
Sorts by VM location .
33,547
@ SuppressWarnings ( "static-method" ) protected Collection < AbstractSubCodeBuilderFragment > initializeSubGenerators ( Injector injector ) { final Collection < AbstractSubCodeBuilderFragment > fragments = new ArrayList < > ( ) ; fragments . add ( injector . getInstance ( BuilderFactoryFragment . class ) ) ; fragments . add ( injector . getInstance ( DocumentationBuilderFragment . class ) ) ; fragments . add ( injector . getInstance ( AbstractBuilderBuilderFragment . class ) ) ; fragments . add ( injector . getInstance ( AbstractAppenderBuilderFragment . class ) ) ; fragments . add ( injector . getInstance ( ScriptBuilderFragment . class ) ) ; return fragments ; }
Initialize the sub generators .
33,548
protected BindingFactory createRuntimeBindings ( ) { final BindingFactory factory = new BindingFactory ( getClass ( ) . getName ( ) ) ; for ( final AbstractSubCodeBuilderFragment subFragment : this . subFragments ) { subFragment . generateRuntimeBindings ( factory ) ; } return factory ; }
Create the runtime bindings for the builders .
33,549
protected BindingFactory createEclipseBindings ( ) { final BindingFactory factory = new BindingFactory ( getClass ( ) . getName ( ) ) ; for ( final AbstractSubCodeBuilderFragment subFragment : this . subFragments ) { subFragment . generateEclipseBindings ( factory ) ; } return factory ; }
Create the Eclipse bindings for the builders .
33,550
protected BindingFactory createIdeaBindings ( ) { final BindingFactory factory = new BindingFactory ( getClass ( ) . getName ( ) ) ; for ( final AbstractSubCodeBuilderFragment subFragment : this . subFragments ) { subFragment . generateIdeaBindings ( factory ) ; } return factory ; }
Create the IDEA bindings for the builders .
33,551
protected BindingFactory createWebBindings ( ) { final BindingFactory factory = new BindingFactory ( getClass ( ) . getName ( ) ) ; for ( final AbstractSubCodeBuilderFragment subFragment : this . subFragments ) { subFragment . generateWebBindings ( factory ) ; } return factory ; }
Create the Web - interface bindings for the builders .
33,552
public int compareTo ( Address address ) { if ( address == null ) { return 1 ; } return this . agentId . compareTo ( address . getUUID ( ) ) ; }
Compares this object with the specified object for order . Returns a negative integer zero or a positive integer as this object is less than equal to or greater than the specified object .
33,553
public static void main ( String [ ] args ) { final int retCode = createMainObject ( ) . runCompiler ( args ) ; System . exit ( retCode ) ; }
Main program of the batch compiler .
33,554
public void setFromString ( String sectionNumber , int level ) { assert level >= 1 ; final String [ ] numbers = sectionNumber . split ( "[^0-9]+" ) ; final int len = Math . max ( 0 , this . numbers . size ( ) - numbers . length ) ; for ( int i = 0 ; i < len ; ++ i ) { this . numbers . removeLast ( ) ; } for ( int i = 0 ; i < numbers . length && i < level ; ++ i ) { this . numbers . addLast ( Integer . valueOf ( numbers [ i ] ) ) ; } }
Change this version number from the given string representation .
33,555
public void increment ( int level ) { assert level >= 1 ; if ( this . numbers . size ( ) < level ) { do { this . numbers . addLast ( 0 ) ; } while ( this . numbers . size ( ) < level ) ; } else if ( this . numbers . size ( ) > level ) { do { this . numbers . removeLast ( ) ; } while ( this . numbers . size ( ) > level ) ; } assert this . numbers . size ( ) == level ; final int previousSection = this . numbers . removeLast ( ) ; this . numbers . addLast ( previousSection + 1 ) ; }
Change this version number by incrementing the number for the given level .
33,556
@ Fix ( "*" ) public void fixSuppressWarnings ( Issue issue , IssueResolutionAcceptor acceptor ) { if ( isIgnorable ( issue . getCode ( ) ) ) { SuppressWarningsAddModification . accept ( this , issue , acceptor ) ; } }
Add the fixes with suppress - warning annotations .
33,557
public List < JvmOperation > getJvmOperationsFromURIs ( XtendTypeDeclaration container , String ... operationUris ) { final List < JvmOperation > operations = new ArrayList < > ( ) ; final ResourceSet resourceSet = container . eResource ( ) . getResourceSet ( ) ; for ( final String operationUriAsString : operationUris ) { final URI operationURI = URI . createURI ( operationUriAsString ) ; final EObject overridden = resourceSet . getEObject ( operationURI , true ) ; if ( overridden instanceof JvmOperation ) { final JvmOperation operation = ( JvmOperation ) overridden ; if ( this . annotationFinder . findAnnotation ( operation , DefaultValueUse . class ) == null ) { operations . add ( operation ) ; } } } return operations ; }
Replies the JVM operations that correspond to the given URIs .
33,558
public boolean removeToPreviousSeparator ( Issue issue , IXtextDocument document , String separator ) throws BadLocationException { return removeToPreviousSeparator ( issue . getOffset ( ) , issue . getLength ( ) , document , separator ) ; }
Remove the element related to the issue and the whitespaces before the element until the given separator .
33,559
public boolean removeToPreviousSeparator ( int offset , int length , IXtextDocument document , String separator ) throws BadLocationException { int index = offset - 1 ; char c = document . getChar ( index ) ; while ( Character . isWhitespace ( c ) ) { index -- ; c = document . getChar ( index ) ; } final boolean foundSeparator = document . getChar ( index ) == separator . charAt ( 0 ) ; if ( foundSeparator ) { index -- ; c = document . getChar ( index ) ; while ( Character . isWhitespace ( c ) ) { index -- ; c = document . getChar ( index ) ; } final int delta = offset - index - 1 ; document . replace ( index + 1 , length + delta , "" ) ; } return foundSeparator ; }
Remove the portion of text and the whitespaces before the text until the given separator .
33,560
public int getImportInsertOffset ( SarlScript script ) { final ICompositeNode node = NodeModelUtils . findActualNodeFor ( script . getImportSection ( ) ) ; if ( node == null ) { final List < INode > children = NodeModelUtils . findNodesForFeature ( script , XtendPackage . eINSTANCE . getXtendFile_Package ( ) ) ; if ( children . isEmpty ( ) ) { return 0 ; } return children . get ( 0 ) . getEndOffset ( ) ; } return node . getEndOffset ( ) ; }
Replies the index where import declaration could be inserted into the given container .
33,561
public boolean removeToNextSeparator ( Issue issue , IXtextDocument document , String separator ) throws BadLocationException { int index = issue . getOffset ( ) + issue . getLength ( ) ; char c = document . getChar ( index ) ; while ( Character . isWhitespace ( c ) ) { index ++ ; c = document . getChar ( index ) ; } final boolean foundSeparator = document . getChar ( index ) == separator . charAt ( 0 ) ; if ( foundSeparator ) { index ++ ; c = document . getChar ( index ) ; while ( Character . isWhitespace ( c ) ) { index ++ ; c = document . getChar ( index ) ; } final int newLength = index - issue . getOffset ( ) ; document . replace ( issue . getOffset ( ) , newLength , "" ) ; } return foundSeparator ; }
Remove the element related to the issue and the whitespaces after the element until the given separator .
33,562
public boolean removeToPreviousKeyword ( Issue issue , IXtextDocument document , String keyword1 , String ... otherKeywords ) throws BadLocationException { int index = issue . getOffset ( ) - 1 ; char c = document . getChar ( index ) ; while ( Character . isWhitespace ( c ) ) { index -- ; c = document . getChar ( index ) ; } final StringBuffer kw = new StringBuffer ( ) ; while ( ! Character . isWhitespace ( c ) ) { kw . insert ( 0 , c ) ; index -- ; c = document . getChar ( index ) ; } if ( kw . toString ( ) . equals ( keyword1 ) || Arrays . contains ( otherKeywords , kw . toString ( ) ) ) { while ( Character . isWhitespace ( c ) ) { index -- ; c = document . getChar ( index ) ; } final int delta = issue . getOffset ( ) - index - 1 ; document . replace ( index + 1 , issue . getLength ( ) + delta , "" ) ; return true ; } return false ; }
Remove the element related to the issue and the whitespaces before the element until one of the given keywords is encountered .
33,563
public boolean removeBetweenSeparators ( Issue issue , IXtextDocument document , String beginSeparator , String endSeparator ) throws BadLocationException { int offset = issue . getOffset ( ) ; int length = issue . getLength ( ) ; int index = offset - 1 ; char c = document . getChar ( index ) ; while ( Character . isWhitespace ( c ) ) { index -- ; c = document . getChar ( index ) ; } boolean foundSeparator = document . getChar ( index ) == beginSeparator . charAt ( 0 ) ; if ( foundSeparator ) { index -- ; c = document . getChar ( index ) ; while ( Character . isWhitespace ( c ) ) { index -- ; c = document . getChar ( index ) ; } length = length + ( offset - index - 1 ) ; offset = index + 1 ; index = offset + length ; c = document . getChar ( index ) ; while ( Character . isWhitespace ( c ) ) { index ++ ; c = document . getChar ( index ) ; } foundSeparator = document . getChar ( index ) == endSeparator . charAt ( 0 ) ; if ( foundSeparator ) { index ++ ; length = index - offset ; document . replace ( offset , length , "" ) ; } } return foundSeparator ; }
Remove the element related to the issue and the whitespaces before the element until the begin separator and the whitespaces after the element until the end separator .
33,564
public int getInsertOffset ( XtendTypeDeclaration container ) { if ( container . getMembers ( ) . isEmpty ( ) ) { final ICompositeNode node = NodeModelUtils . findActualNodeFor ( container ) ; final ILeafNode openingBraceNode = IterableExtensions . findFirst ( node . getLeafNodes ( ) , lnode -> "{" . equals ( lnode . getText ( ) ) ) ; if ( openingBraceNode != null ) { return openingBraceNode . getOffset ( ) + 1 ; } return node . getEndOffset ( ) ; } final EObject lastFeature = IterableExtensions . last ( container . getMembers ( ) ) ; final ICompositeNode node = NodeModelUtils . findActualNodeFor ( lastFeature ) ; return node . getEndOffset ( ) ; }
Replies the index where elements could be inserted into the given container .
33,565
public int getSpaceSize ( IXtextDocument document , int offset ) throws BadLocationException { int size = 0 ; char c = document . getChar ( offset + size ) ; while ( Character . isWhitespace ( c ) ) { size ++ ; c = document . getChar ( offset + size ) ; } return size ; }
Replies the size of a sequence of whitespaces .
33,566
public int getOffsetForPattern ( IXtextDocument document , int startOffset , String pattern ) { final Pattern compiledPattern = Pattern . compile ( pattern ) ; final Matcher matcher = compiledPattern . matcher ( document . get ( ) ) ; if ( matcher . find ( startOffset ) ) { final int end = matcher . end ( ) ; return end ; } return - 1 ; }
Replies the offset that corresponds to the given regular expression pattern .
33,567
public QualifiedName qualifiedName ( String name ) { if ( ! com . google . common . base . Strings . isNullOrEmpty ( name ) ) { final List < String > segments = Strings . split ( name , "." ) ; return QualifiedName . create ( segments ) ; } return QualifiedName . create ( ) ; }
Replies the qualified name for the given name .
33,568
public void removeExecutableFeature ( EObject element , IModificationContext context ) throws BadLocationException { final ICompositeNode node ; final SarlAction action = EcoreUtil2 . getContainerOfType ( element , SarlAction . class ) ; if ( action == null ) { final XtendMember feature = EcoreUtil2 . getContainerOfType ( element , XtendMember . class ) ; node = NodeModelUtils . findActualNodeFor ( feature ) ; } else { node = NodeModelUtils . findActualNodeFor ( action ) ; } if ( node != null ) { remove ( context . getXtextDocument ( ) , node ) ; } }
Remove the exectuable feature .
33,569
@ Fix ( IssueCodes . DUPLICATE_TYPE_NAME ) public void fixDuplicateTopElements ( Issue issue , IssueResolutionAcceptor acceptor ) { MemberRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Duplicate type .
33,570
@ Fix ( IssueCodes . DUPLICATE_FIELD ) public void fixDuplicateAttribute ( Issue issue , IssueResolutionAcceptor acceptor ) { MemberRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Duplicate field .
33,571
@ Fix ( IssueCodes . DUPLICATE_METHOD ) public void fixDuplicateMethod ( Issue issue , IssueResolutionAcceptor acceptor ) { MemberRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Duplicate method .
33,572
@ Fix ( IssueCodes . INVALID_MEMBER_NAME ) public void fixMemberName ( final Issue issue , IssueResolutionAcceptor acceptor ) { MemberRenameModification . accept ( this , issue , acceptor ) ; MemberRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Invalid member name .
33,573
@ Fix ( io . sarl . lang . validation . IssueCodes . REDUNDANT_INTERFACE_IMPLEMENTATION ) public void fixRedundantInterface ( final Issue issue , IssueResolutionAcceptor acceptor ) { ImplementedTypeRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Redundant interface implementation .
33,574
@ Fix ( org . eclipse . xtext . xbase . validation . IssueCodes . VARIABLE_NAME_SHADOWING ) public void fixVariableNameShadowing ( final Issue issue , IssueResolutionAcceptor acceptor ) { MemberRemoveModification . accept ( this , issue , acceptor ) ; MemberRenameModification . accept ( this , issue , acceptor ) ; }
Quick fix for Variable name shadowing .
33,575
@ Fix ( IssueCodes . OVERRIDDEN_FINAL ) public void fixOverriddenFinal ( Issue issue , IssueResolutionAcceptor acceptor ) { final MultiModification modifications = new MultiModification ( this , issue , acceptor , Messages . SARLQuickfixProvider_0 , Messages . SARLQuickfixProvider_1 ) ; modifications . bind ( XtendTypeDeclaration . class , SuperTypeRemoveModification . class ) ; modifications . bind ( XtendMember . class , MemberRemoveModification . class ) ; }
Quick fix for Override final operation .
33,576
@ Fix ( io . sarl . lang . validation . IssueCodes . DISCOURAGED_BOOLEAN_EXPRESSION ) public void fixDiscouragedBooleanExpression ( final Issue issue , IssueResolutionAcceptor acceptor ) { BehaviorUnitGuardRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Discouraged boolean expression .
33,577
@ Fix ( io . sarl . lang . validation . IssueCodes . UNREACHABLE_BEHAVIOR_UNIT ) public void fixUnreachableBehaviorUnit ( Issue issue , IssueResolutionAcceptor acceptor ) { MemberRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Unreachable behavior unit .
33,578
@ Fix ( io . sarl . lang . validation . IssueCodes . INVALID_CAPACITY_TYPE ) public void fixInvalidCapacityType ( final Issue issue , IssueResolutionAcceptor acceptor ) { CapacityReferenceRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Invalid capacity type .
33,579
@ Fix ( io . sarl . lang . validation . IssueCodes . INVALID_FIRING_EVENT_TYPE ) public void fixInvalidFiringEventType ( final Issue issue , IssueResolutionAcceptor acceptor ) { FiredEventRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Invalid firing event type .
33,580
@ Fix ( io . sarl . lang . validation . IssueCodes . INVALID_IMPLEMENTED_TYPE ) public void fixInvalidImplementedType ( final Issue issue , IssueResolutionAcceptor acceptor ) { ImplementedTypeRemoveModification . accept ( this , issue , acceptor , RemovalType . OTHER ) ; }
Quick fix for Invalid implemented type .
33,581
@ Fix ( io . sarl . lang . validation . IssueCodes . INVALID_EXTENDED_TYPE ) public void fixInvalidExtendedType ( final Issue issue , IssueResolutionAcceptor acceptor ) { ExtendedTypeRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Invalid extended type .
33,582
@ Fix ( IssueCodes . CYCLIC_INHERITANCE ) public void fixCyclicInheritance ( final Issue issue , IssueResolutionAcceptor acceptor ) { ExtendedTypeRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Cyclic hierarchy .
33,583
@ Fix ( IssueCodes . INTERFACE_EXPECTED ) public void fixInteraceExpected ( final Issue issue , IssueResolutionAcceptor acceptor ) { ExtendedTypeRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Interface expected .
33,584
@ Fix ( IssueCodes . CLASS_EXPECTED ) public void fixClassExpected ( final Issue issue , IssueResolutionAcceptor acceptor ) { ExtendedTypeRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Class expected .
33,585
@ Fix ( io . sarl . lang . validation . IssueCodes . DISCOURAGED_CAPACITY_DEFINITION ) public void fixDiscouragedCapacityDefinition ( Issue issue , IssueResolutionAcceptor acceptor ) { MemberRemoveModification . accept ( this , issue , acceptor , SarlCapacity . class ) ; ActionAddModification . accept ( this , issue , acceptor ) ; }
Quick fix for Discouraged capacity definition .
33,586
@ Fix ( org . eclipse . xtext . xbase . validation . IssueCodes . INCOMPATIBLE_RETURN_TYPE ) public void fixIncompatibleReturnType ( final Issue issue , IssueResolutionAcceptor acceptor ) { ReturnTypeReplaceModification . accept ( this , issue , acceptor ) ; }
Quick fix for Incompatible return type .
33,587
@ Fix ( io . sarl . lang . validation . IssueCodes . RETURN_TYPE_SPECIFICATION_IS_RECOMMENDED ) public void fixReturnTypeRecommended ( final Issue issue , IssueResolutionAcceptor acceptor ) { ReturnTypeAddModification . accept ( this , issue , acceptor ) ; }
Quick fix for Return type is recommended .
33,588
@ Fix ( io . sarl . lang . validation . IssueCodes . UNUSED_AGENT_CAPACITY ) public void fixUnusedAgentCapacity ( final Issue issue , IssueResolutionAcceptor acceptor ) { CapacityReferenceRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Unused agent capacity .
33,589
@ Fix ( io . sarl . lang . validation . IssueCodes . REDUNDANT_CAPACITY_USE ) public void fixRedundantAgentCapacityUse ( final Issue issue , IssueResolutionAcceptor acceptor ) { CapacityReferenceRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for Redundant capacity use .
33,590
@ Fix ( SyntaxIssueCodes . USED_RESERVED_KEYWORD ) public void fixNoViableAlternativeAtKeyword ( final Issue issue , IssueResolutionAcceptor acceptor ) { ProtectKeywordModification . accept ( this , issue , acceptor ) ; }
Quick fix for the no viable alternative at an input that is a SARL keyword .
33,591
@ Fix ( io . sarl . lang . validation . IssueCodes . USED_RESERVED_SARL_ANNOTATION ) public void fixDiscouragedAnnotationUse ( final Issue issue , IssueResolutionAcceptor acceptor ) { AnnotationRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for the discouraged annotation uses .
33,592
@ Fix ( io . sarl . lang . validation . IssueCodes . MANUAL_INLINE_DEFINITION ) public void fixManualInlineDefinition ( final Issue issue , IssueResolutionAcceptor acceptor ) { AnnotationRemoveModification . accept ( this , issue , acceptor ) ; }
Quick fix for the manual definition of inline statements .
33,593
public IDialogSettings getDialogSettingsSection ( String name ) { final IDialogSettings dialogSettings = getDialogSettings ( ) ; IDialogSettings section = dialogSettings . getSection ( name ) ; if ( section == null ) { section = dialogSettings . addNewSection ( name ) ; } return section ; }
Returns a section in the SARL Eclipse plugin s dialog settings . If the section doesn t exist yet it is created .
33,594
public PyGeneratorConfiguration install ( ResourceSet resourceSet , PyGeneratorConfiguration config ) { assert config != null ; PyGeneratorConfigAdapter adapter = PyGeneratorConfigAdapter . findInEmfObject ( resourceSet ) ; if ( adapter == null ) { adapter = new PyGeneratorConfigAdapter ( ) ; } adapter . attachToEmfObject ( resourceSet ) ; return adapter . getLanguage2GeneratorConfig ( ) . put ( this . languageId , config ) ; }
Install the given configuration into the context .
33,595
protected void generatePythonSetup ( IStyleAppendable it , String basename ) { it . appendNl ( "# -*- coding: {0} -*-" , getCodeConfig ( ) . getEncoding ( ) . toLowerCase ( ) ) ; it . appendHeader ( ) ; it . newLine ( ) ; it . append ( "from setuptools import setup" ) ; it . newLine ( ) . newLine ( ) ; it . append ( "setup (" ) ; it . increaseIndentation ( ) . newLine ( ) ; it . append ( "name='" ) . append ( basename ) . append ( "lexer'," ) ; it . newLine ( ) ; it . append ( "version='" ) . append ( getLanguageVersion ( ) ) . append ( "'," ) ; it . newLine ( ) ; it . append ( "packages=['" ) . append ( basename ) . append ( "lexer']," ) ; it . newLine ( ) ; it . append ( "entry_points =" ) ; it . newLine ( ) ; it . append ( "\"\"\"" ) ; it . newLine ( ) ; it . append ( "[pygments.lexers]" ) ; it . newLine ( ) ; it . append ( "sarllexer = " ) . append ( basename ) . append ( "lexer." ) . append ( basename ) ; it . append ( ":SarlLexer" ) ; it . newLine ( ) ; it . append ( "\"\"\"," ) ; it . decreaseIndentation ( ) . newLine ( ) ; it . append ( ")" ) ; it . newLine ( ) ; }
Create the content of the setup . py file .
33,596
public JvmParameterizedTypeReference newTypeRef ( Notifier context , String typeName ) { return this . builder . newTypeRef ( context , typeName ) ; }
Find the reference to the type with the given name .
33,597
protected LightweightTypeReference getLightweightType ( XExpression expr ) { final IResolvedTypes resolvedTypes = getResolvedTypes ( expr ) ; final LightweightTypeReference expressionType = resolvedTypes . getActualType ( expr ) ; if ( expr instanceof AnonymousClass ) { final List < LightweightTypeReference > superTypes = expressionType . getSuperTypes ( ) ; if ( superTypes . size ( ) == 1 ) { return superTypes . get ( 0 ) ; } } return expressionType ; }
Replies the inferred type for the given expression .
33,598
private void createImplicitVariableType ( XtextResource resource , IAcceptor < ? super ICodeMining > acceptor ) { createImplicitVarValType ( resource , acceptor , XtendVariableDeclaration . class , it -> it . getType ( ) , it -> { LightweightTypeReference type = getLightweightType ( it . getRight ( ) ) ; if ( type . isAny ( ) ) { type = getTypeForVariableDeclaration ( it . getRight ( ) ) ; } return type . getSimpleName ( ) ; } , it -> it . getRight ( ) , ( ) -> this . grammar . getXVariableDeclarationAccess ( ) . getRightAssignment_3_1 ( ) ) ; }
Add an annotation when the variable s type is implicit and inferred by the SARL compiler .
33,599
private void createImplicitFieldType ( XtextResource resource , IAcceptor < ? super ICodeMining > acceptor ) { createImplicitVarValType ( resource , acceptor , XtendField . class , it -> it . getType ( ) , it -> { final JvmField inferredField = ( JvmField ) this . jvmModelAssocitions . getPrimaryJvmElement ( it ) ; if ( inferredField == null || inferredField . getType ( ) == null || inferredField . getType ( ) . eIsProxy ( ) ) { return null ; } return inferredField . getType ( ) . getSimpleName ( ) ; } , null , ( ) -> this . grammar . getAOPMemberAccess ( ) . getInitialValueAssignment_2_3_3_1 ( ) ) ; }
Add an annotation when the field s type is implicit and inferred by the SARL compiler .