io.sarl.lang.core.util
Class SarlUtils
final class SarlUtils
extends java.lang.Object
Utilities functions according to SARL specifications.
Maven Group Identifier:
io.sarl.lang
Maven Artifact Identifier:
core
Since:
0.12
Field Summary
Modifier and type Field and description
public static val java.lang.String HIDDEN_MEMBER_CHARACTER
Character for hidden features.
Action Summary
Modifier and type Action and description
static java.lang.String getFileExtensions(String)
Replies the individual file extensions from the given list of file extensions.
static java.lang.String getMajorFileExtension(String)
Replies the major file extension from the given list of file extensions.
static java.lang.String getMajorFileExtension(String)
Replies the major file extension from the given list of file extensions.
static boolean hasFileExtension(String,String)
Replies if the given filename has one of the following file extensions
static boolean isHiddenMember(String)
Replies if the given name is related to an hidden action.
Field Details
HIDDEN_MEMBER_CHARACTER
public static val HIDDEN_MEMBER_CHARACTER : java.lang.String = "$"
Character for hidden features.
Action Details
getFileExtensions(String)
def getFileExtensions(String) : java.lang.String
Replies the individual file extensions from the given list of file extensions.

The argument could be a list of file extensions, in which extensions must be separated by one of the separators ,, ; or :.
Parameters:
fileExtensions - the list of file extensions.
Returns:
the extensions.
Since:
0.15
getMajorFileExtension(String)
def getMajorFileExtension(String) : java.lang.String
Replies the major file extension from the given list of file extensions.
Parameters:
fileExtensions - the list of file extensions.
Returns:
the major extension.
Since:
0.15
getMajorFileExtension(String)
def getMajorFileExtension(String) : java.lang.String
Replies the major file extension from the given list of file extensions.

The argument could be a list of file extensions, in which extensions must be separated by coma separators.
Parameters:
fileExtensions - the list of file extensions
Returns:
the major extension.
Since:
0.15
hasFileExtension(String,String)
def hasFileExtension(String,String) : boolean
Replies if the given filename has one of the following file extensions
Parameters:
filename - the filename to test.
fileExtensions - the list of file extensions.
Returns:
true if the filename has the extension. Otherwise file if the filename has not the extension.
Since:
0.15
isHiddenMember(String)
def isHiddenMember(String) : boolean
Replies if the given name is related to an hidden action.

An hidden action is an action that is generated by the SARL compiler, and that cannot be defined by the SARL user.
Parameters:
name - - the name to test.
Returns:
true if the given name is reserved by SARL.