id int32 0 165k | repo stringlengths 7 58 | path stringlengths 12 218 | func_name stringlengths 3 140 | original_string stringlengths 73 34.1k | language stringclasses 1
value | code stringlengths 73 34.1k | code_tokens list | docstring stringlengths 3 16k | docstring_tokens list | sha stringlengths 40 40 | url stringlengths 105 339 |
|---|---|---|---|---|---|---|---|---|---|---|---|
57,100 | sarl/sarl | main/coreplugins/io.sarl.eclipse/src/io/sarl/eclipse/launching/runner/AbstractSARLLaunchConfigurationDelegate.java | AbstractSARLLaunchConfigurationDelegate.getSREClasspathEntries | private static List<IRuntimeClasspathEntry> getSREClasspathEntries(
ILaunchConfiguration configuration,
ILaunchConfigurationAccessor configAccessor,
IJavaProjectAccessor projectAccessor) throws CoreException {
final ISREInstall sre = getSREInstallFor(configuration, configAccessor, projectAccessor);
return ... | java | private static List<IRuntimeClasspathEntry> getSREClasspathEntries(
ILaunchConfiguration configuration,
ILaunchConfigurationAccessor configAccessor,
IJavaProjectAccessor projectAccessor) throws CoreException {
final ISREInstall sre = getSREInstallFor(configuration, configAccessor, projectAccessor);
return ... | [
"private",
"static",
"List",
"<",
"IRuntimeClasspathEntry",
">",
"getSREClasspathEntries",
"(",
"ILaunchConfiguration",
"configuration",
",",
"ILaunchConfigurationAccessor",
"configAccessor",
",",
"IJavaProjectAccessor",
"projectAccessor",
")",
"throws",
"CoreException",
"{",
... | Replies the classpath entries associated to the SRE of the given configuration.
@param configuration the configuration to read.
@param configAccessor the accessor to the SRE configuration.
@param projectAccessor the accessor to the Java project.
@return the classpath entries for the SRE associated to the configuration... | [
"Replies",
"the",
"classpath",
"entries",
"associated",
"to",
"the",
"SRE",
"of",
"the",
"given",
"configuration",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.eclipse/src/io/sarl/eclipse/launching/runner/AbstractSARLLaunchConfigurationDelegate.java#L530-L536 |
57,101 | sarl/sarl | main/coreplugins/io.sarl.eclipse/src/io/sarl/eclipse/launching/runner/AbstractSARLLaunchConfigurationDelegate.java | AbstractSARLLaunchConfigurationDelegate.isNotSREEntry | private static boolean isNotSREEntry(IRuntimeClasspathEntry entry) {
try {
final File file = new File(entry.getLocation());
if (file.isDirectory()) {
return !SARLRuntime.isUnpackedSRE(file);
} else if (file.canRead()) {
return !SARLRuntime.isPackedSRE(file);
}
} catch (Throwable e) {
SARLEcli... | java | private static boolean isNotSREEntry(IRuntimeClasspathEntry entry) {
try {
final File file = new File(entry.getLocation());
if (file.isDirectory()) {
return !SARLRuntime.isUnpackedSRE(file);
} else if (file.canRead()) {
return !SARLRuntime.isPackedSRE(file);
}
} catch (Throwable e) {
SARLEcli... | [
"private",
"static",
"boolean",
"isNotSREEntry",
"(",
"IRuntimeClasspathEntry",
"entry",
")",
"{",
"try",
"{",
"final",
"File",
"file",
"=",
"new",
"File",
"(",
"entry",
".",
"getLocation",
"(",
")",
")",
";",
"if",
"(",
"file",
".",
"isDirectory",
"(",
... | Replies if the given classpath entry is a SRE.
@param entry the entry.
@return <code>true</code> if the entry points to a SRE;
<code>false</code> otherwise. | [
"Replies",
"if",
"the",
"given",
"classpath",
"entry",
"is",
"a",
"SRE",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.eclipse/src/io/sarl/eclipse/launching/runner/AbstractSARLLaunchConfigurationDelegate.java#L562-L574 |
57,102 | sarl/sarl | sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/services/jdk/executors/JdkExecutorService.java | JdkExecutorService.createTask | @SuppressWarnings("static-method")
protected Runnable createTask(Runnable runnable) {
if (runnable instanceof JanusRunnable) {
return runnable;
}
return new JanusRunnable(runnable);
} | java | @SuppressWarnings("static-method")
protected Runnable createTask(Runnable runnable) {
if (runnable instanceof JanusRunnable) {
return runnable;
}
return new JanusRunnable(runnable);
} | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"protected",
"Runnable",
"createTask",
"(",
"Runnable",
"runnable",
")",
"{",
"if",
"(",
"runnable",
"instanceof",
"JanusRunnable",
")",
"{",
"return",
"runnable",
";",
"}",
"return",
"new",
"JanusRunnable",
... | Create a task with the given runnable.
@param runnable the runnable.
@return the task. | [
"Create",
"a",
"task",
"with",
"the",
"given",
"runnable",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/services/jdk/executors/JdkExecutorService.java#L154-L160 |
57,103 | sarl/sarl | sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/services/jdk/executors/JdkExecutorService.java | JdkExecutorService.createTask | @SuppressWarnings("static-method")
protected <T> Callable<T> createTask(Callable<T> callable) {
if (callable instanceof JanusCallable<?>) {
return callable;
}
return new JanusCallable<>(callable);
} | java | @SuppressWarnings("static-method")
protected <T> Callable<T> createTask(Callable<T> callable) {
if (callable instanceof JanusCallable<?>) {
return callable;
}
return new JanusCallable<>(callable);
} | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"protected",
"<",
"T",
">",
"Callable",
"<",
"T",
">",
"createTask",
"(",
"Callable",
"<",
"T",
">",
"callable",
")",
"{",
"if",
"(",
"callable",
"instanceof",
"JanusCallable",
"<",
"?",
">",
")",
"... | Create a task with the given callable.
@param <T> the type of the returned value.
@param callable the callable.
@return the task. | [
"Create",
"a",
"task",
"with",
"the",
"given",
"callable",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/services/jdk/executors/JdkExecutorService.java#L168-L174 |
57,104 | sarl/sarl | main/coreplugins/io.sarl.eclipse/src/io/sarl/eclipse/launching/runner/SARLAgentLaunchConfigurationDelegate.java | SARLAgentLaunchConfigurationDelegate.verifyAgentName | protected void verifyAgentName(ILaunchConfiguration configuration) throws CoreException {
final String name = getAgentName(configuration);
if (name == null) {
abort(
io.sarl.eclipse.launching.dialog.Messages.MainLaunchConfigurationTab_2,
null,
SARLEclipseConfig.ERR_UNSPECIFIED_AGENT_NAME);
}
} | java | protected void verifyAgentName(ILaunchConfiguration configuration) throws CoreException {
final String name = getAgentName(configuration);
if (name == null) {
abort(
io.sarl.eclipse.launching.dialog.Messages.MainLaunchConfigurationTab_2,
null,
SARLEclipseConfig.ERR_UNSPECIFIED_AGENT_NAME);
}
} | [
"protected",
"void",
"verifyAgentName",
"(",
"ILaunchConfiguration",
"configuration",
")",
"throws",
"CoreException",
"{",
"final",
"String",
"name",
"=",
"getAgentName",
"(",
"configuration",
")",
";",
"if",
"(",
"name",
"==",
"null",
")",
"{",
"abort",
"(",
... | Verifies a main type name is specified by the given launch configuration,
and returns the main type name.
@param configuration launch configuration
@throws CoreException if unable to retrieve the attribute or the attribute is
unspecified | [
"Verifies",
"a",
"main",
"type",
"name",
"is",
"specified",
"by",
"the",
"given",
"launch",
"configuration",
"and",
"returns",
"the",
"main",
"type",
"name",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.eclipse/src/io/sarl/eclipse/launching/runner/SARLAgentLaunchConfigurationDelegate.java#L152-L160 |
57,105 | sarl/sarl | main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/SarlAgentBuilderImpl.java | SarlAgentBuilderImpl.addSarlInterface | public ISarlInterfaceBuilder addSarlInterface(String name) {
ISarlInterfaceBuilder builder = this.iSarlInterfaceBuilderProvider.get();
builder.eInit(getSarlAgent(), name, getTypeResolutionContext());
return builder;
} | java | public ISarlInterfaceBuilder addSarlInterface(String name) {
ISarlInterfaceBuilder builder = this.iSarlInterfaceBuilderProvider.get();
builder.eInit(getSarlAgent(), name, getTypeResolutionContext());
return builder;
} | [
"public",
"ISarlInterfaceBuilder",
"addSarlInterface",
"(",
"String",
"name",
")",
"{",
"ISarlInterfaceBuilder",
"builder",
"=",
"this",
".",
"iSarlInterfaceBuilderProvider",
".",
"get",
"(",
")",
";",
"builder",
".",
"eInit",
"(",
"getSarlAgent",
"(",
")",
",",
... | Create a SarlInterface.
@param name the name of the SarlInterface.
@return the builder. | [
"Create",
"a",
"SarlInterface",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/SarlAgentBuilderImpl.java#L248-L252 |
57,106 | sarl/sarl | main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/SarlAgentBuilderImpl.java | SarlAgentBuilderImpl.addSarlEnumeration | public ISarlEnumerationBuilder addSarlEnumeration(String name) {
ISarlEnumerationBuilder builder = this.iSarlEnumerationBuilderProvider.get();
builder.eInit(getSarlAgent(), name, getTypeResolutionContext());
return builder;
} | java | public ISarlEnumerationBuilder addSarlEnumeration(String name) {
ISarlEnumerationBuilder builder = this.iSarlEnumerationBuilderProvider.get();
builder.eInit(getSarlAgent(), name, getTypeResolutionContext());
return builder;
} | [
"public",
"ISarlEnumerationBuilder",
"addSarlEnumeration",
"(",
"String",
"name",
")",
"{",
"ISarlEnumerationBuilder",
"builder",
"=",
"this",
".",
"iSarlEnumerationBuilderProvider",
".",
"get",
"(",
")",
";",
"builder",
".",
"eInit",
"(",
"getSarlAgent",
"(",
")",
... | Create a SarlEnumeration.
@param name the name of the SarlEnumeration.
@return the builder. | [
"Create",
"a",
"SarlEnumeration",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/SarlAgentBuilderImpl.java#L261-L265 |
57,107 | sarl/sarl | main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/SarlAgentBuilderImpl.java | SarlAgentBuilderImpl.addSarlAnnotationType | public ISarlAnnotationTypeBuilder addSarlAnnotationType(String name) {
ISarlAnnotationTypeBuilder builder = this.iSarlAnnotationTypeBuilderProvider.get();
builder.eInit(getSarlAgent(), name, getTypeResolutionContext());
return builder;
} | java | public ISarlAnnotationTypeBuilder addSarlAnnotationType(String name) {
ISarlAnnotationTypeBuilder builder = this.iSarlAnnotationTypeBuilderProvider.get();
builder.eInit(getSarlAgent(), name, getTypeResolutionContext());
return builder;
} | [
"public",
"ISarlAnnotationTypeBuilder",
"addSarlAnnotationType",
"(",
"String",
"name",
")",
"{",
"ISarlAnnotationTypeBuilder",
"builder",
"=",
"this",
".",
"iSarlAnnotationTypeBuilderProvider",
".",
"get",
"(",
")",
";",
"builder",
".",
"eInit",
"(",
"getSarlAgent",
... | Create a SarlAnnotationType.
@param name the name of the SarlAnnotationType.
@return the builder. | [
"Create",
"a",
"SarlAnnotationType",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/SarlAgentBuilderImpl.java#L274-L278 |
57,108 | sarl/sarl | sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/bic/AgentTraitData.java | AgentTraitData.removeTask | public void removeTask(AgentTask task) {
final Iterator<WeakReference<AgentTask>> iterator = this.tasks.iterator();
while (iterator.hasNext()) {
final WeakReference<AgentTask> reference = iterator.next();
final AgentTask knownTask = reference.get();
if (knownTask == null) {
iterator.remove();
} else... | java | public void removeTask(AgentTask task) {
final Iterator<WeakReference<AgentTask>> iterator = this.tasks.iterator();
while (iterator.hasNext()) {
final WeakReference<AgentTask> reference = iterator.next();
final AgentTask knownTask = reference.get();
if (knownTask == null) {
iterator.remove();
} else... | [
"public",
"void",
"removeTask",
"(",
"AgentTask",
"task",
")",
"{",
"final",
"Iterator",
"<",
"WeakReference",
"<",
"AgentTask",
">",
">",
"iterator",
"=",
"this",
".",
"tasks",
".",
"iterator",
"(",
")",
";",
"while",
"(",
"iterator",
".",
"hasNext",
"(... | Remove task.
@param task the task. | [
"Remove",
"task",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/bic/AgentTraitData.java#L66-L78 |
57,109 | sarl/sarl | main/coreplugins/io.sarl.lang.ui/src/io/sarl/lang/ui/quickfix/acceptors/MultiModification.java | MultiModification.bind | public void bind(Class<?> type, Class<? extends SARLSemanticModification> modification) {
this.modificationTypes.put(type, modification);
} | java | public void bind(Class<?> type, Class<? extends SARLSemanticModification> modification) {
this.modificationTypes.put(type, modification);
} | [
"public",
"void",
"bind",
"(",
"Class",
"<",
"?",
">",
"type",
",",
"Class",
"<",
"?",
"extends",
"SARLSemanticModification",
">",
"modification",
")",
"{",
"this",
".",
"modificationTypes",
".",
"put",
"(",
"type",
",",
"modification",
")",
";",
"}"
] | Add a semantic modification related to the given element type.
@param type the type of the element.
@param modification the modification | [
"Add",
"a",
"semantic",
"modification",
"related",
"to",
"the",
"given",
"element",
"type",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.ui/src/io/sarl/lang/ui/quickfix/acceptors/MultiModification.java#L73-L75 |
57,110 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java | JavaInlineExpressionCompiler._generate | @SuppressWarnings("static-method")
protected Boolean _generate(CharSequence expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
output.appendStringConstant(expression.toString());
return Boolean.TRUE;
} | java | @SuppressWarnings("static-method")
protected Boolean _generate(CharSequence expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
output.appendStringConstant(expression.toString());
return Boolean.TRUE;
} | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"protected",
"Boolean",
"_generate",
"(",
"CharSequence",
"expression",
",",
"XExpression",
"parentExpression",
",",
"XtendExecutable",
"feature",
",",
"InlineAnnotationTreeAppendable",
"output",
")",
"{",
"output",
... | Append the inline code for the given character sequence.
@param expression the expression of the operation.
@param parentExpression is the expression that contains this one, or {@code null} if the current expression is
the root expression.
@param feature the feature that contains the expression.
@param output the outp... | [
"Append",
"the",
"inline",
"code",
"for",
"the",
"given",
"character",
"sequence",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java#L276-L281 |
57,111 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java | JavaInlineExpressionCompiler._generate | @SuppressWarnings("static-method")
protected Boolean _generate(Number expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
final Class<?> type = ReflectionUtil.getRawType(expression.getClass());
if (Byte.class.equals(type) || byte.class.equals(type)) {
o... | java | @SuppressWarnings("static-method")
protected Boolean _generate(Number expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
final Class<?> type = ReflectionUtil.getRawType(expression.getClass());
if (Byte.class.equals(type) || byte.class.equals(type)) {
o... | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"protected",
"Boolean",
"_generate",
"(",
"Number",
"expression",
",",
"XExpression",
"parentExpression",
",",
"XtendExecutable",
"feature",
",",
"InlineAnnotationTreeAppendable",
"output",
")",
"{",
"final",
"Clas... | Append the inline code for the given number value.
@param expression the expression of the operation.
@param parentExpression is the expression that contains this one, or {@code null} if the current expression is
the root expression.
@param feature the feature that contains the expression.
@param output the output.
@r... | [
"Append",
"the",
"inline",
"code",
"for",
"the",
"given",
"number",
"value",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java#L308-L322 |
57,112 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java | JavaInlineExpressionCompiler._generate | @SuppressWarnings("static-method")
protected Boolean _generate(XBooleanLiteral expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
output.appendConstant(Boolean.toString(expression.isIsTrue()));
return Boolean.TRUE;
} | java | @SuppressWarnings("static-method")
protected Boolean _generate(XBooleanLiteral expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
output.appendConstant(Boolean.toString(expression.isIsTrue()));
return Boolean.TRUE;
} | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"protected",
"Boolean",
"_generate",
"(",
"XBooleanLiteral",
"expression",
",",
"XExpression",
"parentExpression",
",",
"XtendExecutable",
"feature",
",",
"InlineAnnotationTreeAppendable",
"output",
")",
"{",
"output... | Append the inline code for the given XBooleanLiteral.
@param expression the expression of the operation.
@param parentExpression is the expression that contains this one, or {@code null} if the current expression is
the root expression.
@param feature the feature that contains the expression.
@param output the output.... | [
"Append",
"the",
"inline",
"code",
"for",
"the",
"given",
"XBooleanLiteral",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java#L333-L338 |
57,113 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java | JavaInlineExpressionCompiler._generate | protected Boolean _generate(XNullLiteral expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
if (parentExpression == null && feature instanceof XtendFunction) {
final XtendFunction function = (XtendFunction) feature;
output.append("("); //$NON-NLS-1$
... | java | protected Boolean _generate(XNullLiteral expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
if (parentExpression == null && feature instanceof XtendFunction) {
final XtendFunction function = (XtendFunction) feature;
output.append("("); //$NON-NLS-1$
... | [
"protected",
"Boolean",
"_generate",
"(",
"XNullLiteral",
"expression",
",",
"XExpression",
"parentExpression",
",",
"XtendExecutable",
"feature",
",",
"InlineAnnotationTreeAppendable",
"output",
")",
"{",
"if",
"(",
"parentExpression",
"==",
"null",
"&&",
"feature",
... | Append the inline code for the given XNullLiteral.
@param expression the expression of the operation.
@param parentExpression is the expression that contains this one, or {@code null} if the current expression is
the root expression.
@param feature the feature that contains the expression.
@param output the output.
@r... | [
"Append",
"the",
"inline",
"code",
"for",
"the",
"given",
"XNullLiteral",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java#L349-L372 |
57,114 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java | JavaInlineExpressionCompiler._generate | @SuppressWarnings("static-method")
protected Boolean _generate(XNumberLiteral expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
output.appendConstant(expression.getValue());
return Boolean.TRUE;
} | java | @SuppressWarnings("static-method")
protected Boolean _generate(XNumberLiteral expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
output.appendConstant(expression.getValue());
return Boolean.TRUE;
} | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"protected",
"Boolean",
"_generate",
"(",
"XNumberLiteral",
"expression",
",",
"XExpression",
"parentExpression",
",",
"XtendExecutable",
"feature",
",",
"InlineAnnotationTreeAppendable",
"output",
")",
"{",
"output"... | Append the inline code for the given XNumberLiteral.
@param expression the expression of the operation.
@param parentExpression is the expression that contains this one, or {@code null} if the current expression is
the root expression.
@param feature the feature that contains the expression.
@param output the output.
... | [
"Append",
"the",
"inline",
"code",
"for",
"the",
"given",
"XNumberLiteral",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java#L383-L388 |
57,115 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java | JavaInlineExpressionCompiler._generate | @SuppressWarnings("static-method")
protected Boolean _generate(XStringLiteral expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
output.appendStringConstant(expression.getValue());
return Boolean.TRUE;
} | java | @SuppressWarnings("static-method")
protected Boolean _generate(XStringLiteral expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
output.appendStringConstant(expression.getValue());
return Boolean.TRUE;
} | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"protected",
"Boolean",
"_generate",
"(",
"XStringLiteral",
"expression",
",",
"XExpression",
"parentExpression",
",",
"XtendExecutable",
"feature",
",",
"InlineAnnotationTreeAppendable",
"output",
")",
"{",
"output"... | Append the inline code for the given XStringLiteral.
@param expression the expression of the operation.
@param parentExpression is the expression that contains this one, or {@code null} if the current expression is
the root expression.
@param feature the feature that contains the expression.
@param output the output.
... | [
"Append",
"the",
"inline",
"code",
"for",
"the",
"given",
"XStringLiteral",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java#L399-L404 |
57,116 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java | JavaInlineExpressionCompiler._generate | @SuppressWarnings("static-method")
protected Boolean _generate(XTypeLiteral expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
output.appendTypeConstant(expression.getType());
return Boolean.TRUE;
} | java | @SuppressWarnings("static-method")
protected Boolean _generate(XTypeLiteral expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
output.appendTypeConstant(expression.getType());
return Boolean.TRUE;
} | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"protected",
"Boolean",
"_generate",
"(",
"XTypeLiteral",
"expression",
",",
"XExpression",
"parentExpression",
",",
"XtendExecutable",
"feature",
",",
"InlineAnnotationTreeAppendable",
"output",
")",
"{",
"output",
... | Append the inline code for the given XTypeLiteral.
@param expression the expression of the operation.
@param parentExpression is the expression that contains this one, or {@code null} if the current expression is
the root expression.
@param feature the feature that contains the expression.
@param output the output.
@r... | [
"Append",
"the",
"inline",
"code",
"for",
"the",
"given",
"XTypeLiteral",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java#L415-L420 |
57,117 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java | JavaInlineExpressionCompiler._generate | protected Boolean _generate(XCastedExpression expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
final InlineAnnotationTreeAppendable child = newAppendable(output.getImportManager());
boolean bool = generate(expression.getTarget(), expression, feature, chi... | java | protected Boolean _generate(XCastedExpression expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
final InlineAnnotationTreeAppendable child = newAppendable(output.getImportManager());
boolean bool = generate(expression.getTarget(), expression, feature, chi... | [
"protected",
"Boolean",
"_generate",
"(",
"XCastedExpression",
"expression",
",",
"XExpression",
"parentExpression",
",",
"XtendExecutable",
"feature",
",",
"InlineAnnotationTreeAppendable",
"output",
")",
"{",
"final",
"InlineAnnotationTreeAppendable",
"child",
"=",
"newAp... | Append the inline code for the given XCastedExpression.
@param expression the expression of the operation.
@param parentExpression is the expression that contains this one, or {@code null} if the current expression is
the root expression.
@param feature the feature that contains the expression.
@param output the outpu... | [
"Append",
"the",
"inline",
"code",
"for",
"the",
"given",
"XCastedExpression",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java#L431-L445 |
57,118 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java | JavaInlineExpressionCompiler._generate | protected Boolean _generate(XReturnExpression expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
return generate(expression.getExpression(), parentExpression, feature, output);
} | java | protected Boolean _generate(XReturnExpression expression, XExpression parentExpression, XtendExecutable feature,
InlineAnnotationTreeAppendable output) {
return generate(expression.getExpression(), parentExpression, feature, output);
} | [
"protected",
"Boolean",
"_generate",
"(",
"XReturnExpression",
"expression",
",",
"XExpression",
"parentExpression",
",",
"XtendExecutable",
"feature",
",",
"InlineAnnotationTreeAppendable",
"output",
")",
"{",
"return",
"generate",
"(",
"expression",
".",
"getExpression"... | Append the inline code for the given XReturnLiteral.
@param expression the expression of the operation.
@param parentExpression is the expression that contains this one, or {@code null} if the current expression is
the root expression.
@param feature the feature that contains the expression.
@param output the output.
... | [
"Append",
"the",
"inline",
"code",
"for",
"the",
"given",
"XReturnLiteral",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/compiler/JavaInlineExpressionCompiler.java#L481-L484 |
57,119 | sarl/sarl | main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java | AbstractSubCodeBuilderFragment.getExportedPackages | public void getExportedPackages(Set<String> exportedPackages) {
if (exportedPackages != null) {
exportedPackages.add(getCodeElementExtractor().getBasePackage());
exportedPackages.add(getCodeElementExtractor().getBuilderPackage());
if (getCodeBuilderConfig().isISourceAppendableEnable()) {
exportedPackages... | java | public void getExportedPackages(Set<String> exportedPackages) {
if (exportedPackages != null) {
exportedPackages.add(getCodeElementExtractor().getBasePackage());
exportedPackages.add(getCodeElementExtractor().getBuilderPackage());
if (getCodeBuilderConfig().isISourceAppendableEnable()) {
exportedPackages... | [
"public",
"void",
"getExportedPackages",
"(",
"Set",
"<",
"String",
">",
"exportedPackages",
")",
"{",
"if",
"(",
"exportedPackages",
"!=",
"null",
")",
"{",
"exportedPackages",
".",
"add",
"(",
"getCodeElementExtractor",
"(",
")",
".",
"getBasePackage",
"(",
... | Fill the given set with the exported packages for this fragment.
@param exportedPackages the set to fill in. | [
"Fill",
"the",
"given",
"set",
"with",
"the",
"exported",
"packages",
"for",
"this",
"fragment",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java#L156-L164 |
57,120 | sarl/sarl | main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java | AbstractSubCodeBuilderFragment.getLanguageScriptMemberGetter | @Pure
protected String getLanguageScriptMemberGetter() {
final Grammar grammar = getGrammar();
final AbstractRule scriptRule = GrammarUtil.findRuleForName(grammar, getCodeBuilderConfig().getScriptRuleName());
for (final Assignment assignment : GrammarUtil.containedAssignments(scriptRule)) {
if ((assignment.ge... | java | @Pure
protected String getLanguageScriptMemberGetter() {
final Grammar grammar = getGrammar();
final AbstractRule scriptRule = GrammarUtil.findRuleForName(grammar, getCodeBuilderConfig().getScriptRuleName());
for (final Assignment assignment : GrammarUtil.containedAssignments(scriptRule)) {
if ((assignment.ge... | [
"@",
"Pure",
"protected",
"String",
"getLanguageScriptMemberGetter",
"(",
")",
"{",
"final",
"Grammar",
"grammar",
"=",
"getGrammar",
"(",
")",
";",
"final",
"AbstractRule",
"scriptRule",
"=",
"GrammarUtil",
".",
"findRuleForName",
"(",
"grammar",
",",
"getCodeBui... | Replies the getter function for accessing to the top element collection of the script.
@return the name of the getter function. | [
"Replies",
"the",
"getter",
"function",
"for",
"accessing",
"to",
"the",
"top",
"element",
"collection",
"of",
"the",
"script",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java#L369-L381 |
57,121 | sarl/sarl | main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java | AbstractSubCodeBuilderFragment.getXFactoryFor | @Pure
protected TypeReference getXFactoryFor(TypeReference type) {
final String packageName = type.getPackageName();
final Grammar grammar = getGrammar();
TypeReference reference = getXFactoryFor(packageName, grammar);
if (reference != null) {
return reference;
}
for (final Grammar usedGrammar : Gramma... | java | @Pure
protected TypeReference getXFactoryFor(TypeReference type) {
final String packageName = type.getPackageName();
final Grammar grammar = getGrammar();
TypeReference reference = getXFactoryFor(packageName, grammar);
if (reference != null) {
return reference;
}
for (final Grammar usedGrammar : Gramma... | [
"@",
"Pure",
"protected",
"TypeReference",
"getXFactoryFor",
"(",
"TypeReference",
"type",
")",
"{",
"final",
"String",
"packageName",
"=",
"type",
".",
"getPackageName",
"(",
")",
";",
"final",
"Grammar",
"grammar",
"=",
"getGrammar",
"(",
")",
";",
"TypeRefe... | Replies the type for the factory for the given type.
@param type the type of the object to create.
@return the factory. | [
"Replies",
"the",
"type",
"for",
"the",
"factory",
"for",
"the",
"given",
"type",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java#L397-L413 |
57,122 | sarl/sarl | main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java | AbstractSubCodeBuilderFragment.generateAppenderMembers | @SuppressWarnings("static-method")
protected StringConcatenationClient generateAppenderMembers(String appenderSimpleName,
TypeReference builderInterface, String elementAccessor) {
return new StringConcatenationClient() {
@Override
protected void appendTo(TargetStringConcatenation it) {
it.append("\tpriv... | java | @SuppressWarnings("static-method")
protected StringConcatenationClient generateAppenderMembers(String appenderSimpleName,
TypeReference builderInterface, String elementAccessor) {
return new StringConcatenationClient() {
@Override
protected void appendTo(TargetStringConcatenation it) {
it.append("\tpriv... | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"protected",
"StringConcatenationClient",
"generateAppenderMembers",
"(",
"String",
"appenderSimpleName",
",",
"TypeReference",
"builderInterface",
",",
"String",
"elementAccessor",
")",
"{",
"return",
"new",
"StringCo... | Generate the members related to appenders.
@param appenderSimpleName the simple name of the appender.
@param builderInterface the interface of the code builder to wrap.
@param elementAccessor the code for accessing to the generated element.
@return the code. | [
"Generate",
"the",
"members",
"related",
"to",
"appenders",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java#L442-L479 |
57,123 | sarl/sarl | main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java | AbstractSubCodeBuilderFragment.getAorAnArticle | protected static String getAorAnArticle(String word) {
if (Arrays.asList('a', 'e', 'i', 'o', 'u', 'y').contains(Character.toLowerCase(word.charAt(0)))) {
return "an"; //$NON-NLS-1$
}
return "a"; //$NON-NLS-1$
} | java | protected static String getAorAnArticle(String word) {
if (Arrays.asList('a', 'e', 'i', 'o', 'u', 'y').contains(Character.toLowerCase(word.charAt(0)))) {
return "an"; //$NON-NLS-1$
}
return "a"; //$NON-NLS-1$
} | [
"protected",
"static",
"String",
"getAorAnArticle",
"(",
"String",
"word",
")",
"{",
"if",
"(",
"Arrays",
".",
"asList",
"(",
"'",
"'",
",",
"'",
"'",
",",
"'",
"'",
",",
"'",
"'",
",",
"'",
"'",
",",
"'",
"'",
")",
".",
"contains",
"(",
"Chara... | Replies the "an" or "a" article according to the given word.
<p>This function does not follow the real English grammatical rule, but it is
an acceptable approximation.
@param word the word that follows the article.
@return the article. | [
"Replies",
"the",
"an",
"or",
"a",
"article",
"according",
"to",
"the",
"given",
"word",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java#L631-L636 |
57,124 | sarl/sarl | main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java | AbstractSubCodeBuilderFragment.toSingular | protected static String toSingular(String word) {
if (word.endsWith("ies")) { //$NON-NLS-1$
return word.substring(0, word.length() - 3) + "y"; //$NON-NLS-1$
}
if (word.endsWith("s")) { //$NON-NLS-1$
return word.substring(0, word.length() - 1);
}
return word;
} | java | protected static String toSingular(String word) {
if (word.endsWith("ies")) { //$NON-NLS-1$
return word.substring(0, word.length() - 3) + "y"; //$NON-NLS-1$
}
if (word.endsWith("s")) { //$NON-NLS-1$
return word.substring(0, word.length() - 1);
}
return word;
} | [
"protected",
"static",
"String",
"toSingular",
"(",
"String",
"word",
")",
"{",
"if",
"(",
"word",
".",
"endsWith",
"(",
"\"ies\"",
")",
")",
"{",
"//$NON-NLS-1$",
"return",
"word",
".",
"substring",
"(",
"0",
",",
"word",
".",
"length",
"(",
")",
"-",... | Replies the singular version of the word.
<p>This function does not follow the real English grammatical rule, but it is
an acceptable approximation.
@param word the word.
@return the singular word. | [
"Replies",
"the",
"singular",
"version",
"of",
"the",
"word",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java#L646-L654 |
57,125 | sarl/sarl | main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java | AbstractSubCodeBuilderFragment.nameMatches | protected static boolean nameMatches(EObject element, String pattern) {
if (element instanceof RuleCall) {
return nameMatches(((RuleCall) element).getRule(), pattern);
}
if (element instanceof AbstractRule) {
final String name = ((AbstractRule) element).getName();
final Pattern compilerPattern = Pattern.... | java | protected static boolean nameMatches(EObject element, String pattern) {
if (element instanceof RuleCall) {
return nameMatches(((RuleCall) element).getRule(), pattern);
}
if (element instanceof AbstractRule) {
final String name = ((AbstractRule) element).getName();
final Pattern compilerPattern = Pattern.... | [
"protected",
"static",
"boolean",
"nameMatches",
"(",
"EObject",
"element",
",",
"String",
"pattern",
")",
"{",
"if",
"(",
"element",
"instanceof",
"RuleCall",
")",
"{",
"return",
"nameMatches",
"(",
"(",
"(",
"RuleCall",
")",
"element",
")",
".",
"getRule",... | Replies if the name of the given element is matching the pattern.
@param element the element.
@param pattern the name pattern.
@return <code>true</code> if the element's name is matching. | [
"Replies",
"if",
"the",
"name",
"of",
"the",
"given",
"element",
"is",
"matching",
"the",
"pattern",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java#L662-L675 |
57,126 | sarl/sarl | main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java | AbstractSubCodeBuilderFragment.bindElementDescription | protected void bindElementDescription(BindingFactory factory, CodeElementExtractor.ElementDescription... descriptions) {
for (final CodeElementExtractor.ElementDescription description : descriptions) {
bindTypeReferences(factory,
description.getBuilderInterfaceType(),
description.getBuilderImplementation... | java | protected void bindElementDescription(BindingFactory factory, CodeElementExtractor.ElementDescription... descriptions) {
for (final CodeElementExtractor.ElementDescription description : descriptions) {
bindTypeReferences(factory,
description.getBuilderInterfaceType(),
description.getBuilderImplementation... | [
"protected",
"void",
"bindElementDescription",
"(",
"BindingFactory",
"factory",
",",
"CodeElementExtractor",
".",
"ElementDescription",
"...",
"descriptions",
")",
"{",
"for",
"(",
"final",
"CodeElementExtractor",
".",
"ElementDescription",
"description",
":",
"descripti... | Binds the given descriptions according to the standard policy.
<p>If an custom implementation is defined, it is binded to. Otherwise, the default implementation
is binded.
@param factory the binding factory to use for creating the bindings.
@param descriptions the descriptions to bind to. | [
"Binds",
"the",
"given",
"descriptions",
"according",
"to",
"the",
"standard",
"policy",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java#L707-L714 |
57,127 | sarl/sarl | main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java | AbstractSubCodeBuilderFragment.bindTypeReferences | protected void bindTypeReferences(BindingFactory factory, TypeReference interfaceType,
TypeReference implementationType, TypeReference customImplementationType) {
final IFileSystemAccess2 fileSystem = getSrc();
final TypeReference type;
if ((fileSystem.isFile(implementationType.getJavaPath()))
|| (fileSyst... | java | protected void bindTypeReferences(BindingFactory factory, TypeReference interfaceType,
TypeReference implementationType, TypeReference customImplementationType) {
final IFileSystemAccess2 fileSystem = getSrc();
final TypeReference type;
if ((fileSystem.isFile(implementationType.getJavaPath()))
|| (fileSyst... | [
"protected",
"void",
"bindTypeReferences",
"(",
"BindingFactory",
"factory",
",",
"TypeReference",
"interfaceType",
",",
"TypeReference",
"implementationType",
",",
"TypeReference",
"customImplementationType",
")",
"{",
"final",
"IFileSystemAccess2",
"fileSystem",
"=",
"get... | Binds the given references according to the standard policy.
<p>If an custom implementation is defined, it is binded to. Otherwise, the default implementation
is binded.
@param factory the binding factory to use for creating the bindings.
@param interfaceType the type to bind to an implementation type.
@param impleme... | [
"Binds",
"the",
"given",
"references",
"according",
"to",
"the",
"standard",
"policy",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java#L726-L737 |
57,128 | sarl/sarl | main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java | AbstractSubCodeBuilderFragment.getMemberRule | protected AbstractRule getMemberRule(CodeElementExtractor.ElementDescription description) {
for (final Assignment assignment : GrammarUtil.containedAssignments(description.getGrammarComponent())) {
if (Objects.equals(getCodeBuilderConfig().getMemberCollectionExtensionGrammarName(), assignment.getFeature())) {
... | java | protected AbstractRule getMemberRule(CodeElementExtractor.ElementDescription description) {
for (final Assignment assignment : GrammarUtil.containedAssignments(description.getGrammarComponent())) {
if (Objects.equals(getCodeBuilderConfig().getMemberCollectionExtensionGrammarName(), assignment.getFeature())) {
... | [
"protected",
"AbstractRule",
"getMemberRule",
"(",
"CodeElementExtractor",
".",
"ElementDescription",
"description",
")",
"{",
"for",
"(",
"final",
"Assignment",
"assignment",
":",
"GrammarUtil",
".",
"containedAssignments",
"(",
"description",
".",
"getGrammarComponent",... | Replies the rule used for defining the members of the given element.
@param description description of the container.
@return the rule that is defining the members. | [
"Replies",
"the",
"rule",
"used",
"for",
"defining",
"the",
"members",
"of",
"the",
"given",
"element",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang.mwe2/src/io/sarl/lang/mwe2/codebuilder/fragments/AbstractSubCodeBuilderFragment.java#L744-L753 |
57,129 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java | MavenHelper.getConfig | public String getConfig(String key) throws MojoExecutionException {
ResourceBundle resource = null;
try {
resource = ResourceBundle.getBundle(
"io/sarl/maven/compiler/config", //$NON-NLS-1$
java.util.Locale.getDefault(),
MavenHelper.class.getClassLoader());
} catch (MissingResourceException e) {... | java | public String getConfig(String key) throws MojoExecutionException {
ResourceBundle resource = null;
try {
resource = ResourceBundle.getBundle(
"io/sarl/maven/compiler/config", //$NON-NLS-1$
java.util.Locale.getDefault(),
MavenHelper.class.getClassLoader());
} catch (MissingResourceException e) {... | [
"public",
"String",
"getConfig",
"(",
"String",
"key",
")",
"throws",
"MojoExecutionException",
"{",
"ResourceBundle",
"resource",
"=",
"null",
";",
"try",
"{",
"resource",
"=",
"ResourceBundle",
".",
"getBundle",
"(",
"\"io/sarl/maven/compiler/config\"",
",",
"//$N... | Extract the value from the hard-coded configuration.
@param key the key of the configuration entry.
@return the value.
@throws MojoExecutionException on error. | [
"Extract",
"the",
"value",
"from",
"the",
"hard",
"-",
"coded",
"configuration",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java#L152-L168 |
57,130 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java | MavenHelper.loadPlugin | public PluginDescriptor loadPlugin(Plugin plugin)
throws MojoExecutionException {
try {
final Object repositorySessionObject = this.getRepositorySessionMethod.invoke(this.session);
return (PluginDescriptor) this.loadPluginMethod.invoke(
this.buildPluginManager,
plugin,
getSession().getCurrentP... | java | public PluginDescriptor loadPlugin(Plugin plugin)
throws MojoExecutionException {
try {
final Object repositorySessionObject = this.getRepositorySessionMethod.invoke(this.session);
return (PluginDescriptor) this.loadPluginMethod.invoke(
this.buildPluginManager,
plugin,
getSession().getCurrentP... | [
"public",
"PluginDescriptor",
"loadPlugin",
"(",
"Plugin",
"plugin",
")",
"throws",
"MojoExecutionException",
"{",
"try",
"{",
"final",
"Object",
"repositorySessionObject",
"=",
"this",
".",
"getRepositorySessionMethod",
".",
"invoke",
"(",
"this",
".",
"session",
"... | Load the given plugin.
@param plugin the plugin to load.
@return the descriptor of the plugin.
@throws MojoExecutionException if something bad append. | [
"Load",
"the",
"given",
"plugin",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java#L176-L189 |
57,131 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java | MavenHelper.executeMojo | public void executeMojo(MojoExecution mojo) throws MojoExecutionException, MojoFailureException {
try {
this.buildPluginManager.executeMojo(this.session, mojo);
} catch (PluginConfigurationException
| PluginManagerException e) {
throw new MojoFailureException(e.getLocalizedMessage(), e);
}
} | java | public void executeMojo(MojoExecution mojo) throws MojoExecutionException, MojoFailureException {
try {
this.buildPluginManager.executeMojo(this.session, mojo);
} catch (PluginConfigurationException
| PluginManagerException e) {
throw new MojoFailureException(e.getLocalizedMessage(), e);
}
} | [
"public",
"void",
"executeMojo",
"(",
"MojoExecution",
"mojo",
")",
"throws",
"MojoExecutionException",
",",
"MojoFailureException",
"{",
"try",
"{",
"this",
".",
"buildPluginManager",
".",
"executeMojo",
"(",
"this",
".",
"session",
",",
"mojo",
")",
";",
"}",
... | Execute the given mojo.
@param mojo the mojo to execute.
@throws MojoExecutionException if the mojo cannot be run properly.
@throws MojoFailureException if the build failed. | [
"Execute",
"the",
"given",
"mojo",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java#L197-L204 |
57,132 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java | MavenHelper.toDependency | @SuppressWarnings("static-method")
public Dependency toDependency(Artifact artifact) {
final Dependency result = new Dependency();
result.setArtifactId(artifact.getArtifactId());
result.setClassifier(artifact.getClassifier());
result.setGroupId(artifact.getGroupId());
result.setOptional(artifact.isOptional()... | java | @SuppressWarnings("static-method")
public Dependency toDependency(Artifact artifact) {
final Dependency result = new Dependency();
result.setArtifactId(artifact.getArtifactId());
result.setClassifier(artifact.getClassifier());
result.setGroupId(artifact.getGroupId());
result.setOptional(artifact.isOptional()... | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"public",
"Dependency",
"toDependency",
"(",
"Artifact",
"artifact",
")",
"{",
"final",
"Dependency",
"result",
"=",
"new",
"Dependency",
"(",
")",
";",
"result",
".",
"setArtifactId",
"(",
"artifact",
".",... | Convert an artifact to a dependency.
@param artifact the artifact to convert.
@return the result of the conversion. | [
"Convert",
"an",
"artifact",
"to",
"a",
"dependency",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java#L211-L222 |
57,133 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java | MavenHelper.getPluginDependencies | public synchronized Map<String, Dependency> getPluginDependencies() throws MojoExecutionException {
if (this.pluginDependencies == null) {
final String groupId = getConfig("plugin.groupId"); //$NON-NLS-1$
final String artifactId = getConfig("plugin.artifactId"); //$NON-NLS-1$
final String pluginArtifactKey =... | java | public synchronized Map<String, Dependency> getPluginDependencies() throws MojoExecutionException {
if (this.pluginDependencies == null) {
final String groupId = getConfig("plugin.groupId"); //$NON-NLS-1$
final String artifactId = getConfig("plugin.artifactId"); //$NON-NLS-1$
final String pluginArtifactKey =... | [
"public",
"synchronized",
"Map",
"<",
"String",
",",
"Dependency",
">",
"getPluginDependencies",
"(",
")",
"throws",
"MojoExecutionException",
"{",
"if",
"(",
"this",
".",
"pluginDependencies",
"==",
"null",
")",
"{",
"final",
"String",
"groupId",
"=",
"getConfi... | Build the map of dependencies for the current plugin.
@return the artifact.
@throws MojoExecutionException if the current plugin cannot be determined. | [
"Build",
"the",
"map",
"of",
"dependencies",
"for",
"the",
"current",
"plugin",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java#L229-L247 |
57,134 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java | MavenHelper.resolve | public Set<Artifact> resolve(String groupId, String artifactId) throws MojoExecutionException {
final ArtifactResolutionRequest request = new ArtifactResolutionRequest();
request.setResolveRoot(true);
request.setResolveTransitively(true);
request.setLocalRepository(getSession().getLocalRepository());
request.... | java | public Set<Artifact> resolve(String groupId, String artifactId) throws MojoExecutionException {
final ArtifactResolutionRequest request = new ArtifactResolutionRequest();
request.setResolveRoot(true);
request.setResolveTransitively(true);
request.setLocalRepository(getSession().getLocalRepository());
request.... | [
"public",
"Set",
"<",
"Artifact",
">",
"resolve",
"(",
"String",
"groupId",
",",
"String",
"artifactId",
")",
"throws",
"MojoExecutionException",
"{",
"final",
"ArtifactResolutionRequest",
"request",
"=",
"new",
"ArtifactResolutionRequest",
"(",
")",
";",
"request",... | Resolve the artifacts with the given key.
@param groupId the group identifier.
@param artifactId the artifact identifier.
@return the discovered artifacts.
@throws MojoExecutionException if resolution cannot be done.
@since 0.8 | [
"Resolve",
"the",
"artifacts",
"with",
"the",
"given",
"key",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java#L268-L284 |
57,135 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java | MavenHelper.createArtifact | public Artifact createArtifact(String groupId, String artifactId) {
return this.repositorySystem.createArtifact(groupId, artifactId, "RELEASE", "jar"); //$NON-NLS-1$ //$NON-NLS-2$
} | java | public Artifact createArtifact(String groupId, String artifactId) {
return this.repositorySystem.createArtifact(groupId, artifactId, "RELEASE", "jar"); //$NON-NLS-1$ //$NON-NLS-2$
} | [
"public",
"Artifact",
"createArtifact",
"(",
"String",
"groupId",
",",
"String",
"artifactId",
")",
"{",
"return",
"this",
".",
"repositorySystem",
".",
"createArtifact",
"(",
"groupId",
",",
"artifactId",
",",
"\"RELEASE\"",
",",
"\"jar\"",
")",
";",
"//$NON-NL... | Create an instance of artifact with a version range that corresponds to all versions.
@param groupId the group identifier.
@param artifactId the artifact identifier.
@return the artifact descriptor.
@since 0.8 | [
"Create",
"an",
"instance",
"of",
"artifact",
"with",
"a",
"version",
"range",
"that",
"corresponds",
"to",
"all",
"versions",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java#L293-L295 |
57,136 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java | MavenHelper.resolveDependencies | public Set<Artifact> resolveDependencies(String artifactId, boolean plugins) throws MojoExecutionException {
final Artifact pluginArtifact;
if (plugins) {
pluginArtifact = getSession().getCurrentProject().getPluginArtifactMap().get(artifactId);
} else {
pluginArtifact = getSession().getCurrentProject().getA... | java | public Set<Artifact> resolveDependencies(String artifactId, boolean plugins) throws MojoExecutionException {
final Artifact pluginArtifact;
if (plugins) {
pluginArtifact = getSession().getCurrentProject().getPluginArtifactMap().get(artifactId);
} else {
pluginArtifact = getSession().getCurrentProject().getA... | [
"public",
"Set",
"<",
"Artifact",
">",
"resolveDependencies",
"(",
"String",
"artifactId",
",",
"boolean",
"plugins",
")",
"throws",
"MojoExecutionException",
"{",
"final",
"Artifact",
"pluginArtifact",
";",
"if",
"(",
"plugins",
")",
"{",
"pluginArtifact",
"=",
... | Replies the dependencies for the given artifact.
@param artifactId the artifact identifier.
@param plugins indicates if the map of the plugin artifacts must be explore (if true) or the dependency
artifacts (if false).
@return the dependencies.
@throws MojoExecutionException if the resolution cannot be done. | [
"Replies",
"the",
"dependencies",
"for",
"the",
"given",
"artifact",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java#L305-L339 |
57,137 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java | MavenHelper.getPluginDependencyVersion | public String getPluginDependencyVersion(String groupId, String artifactId) throws MojoExecutionException {
final Map<String, Dependency> deps = getPluginDependencies();
final String key = ArtifactUtils.versionlessKey(groupId, artifactId);
this.log.debug("COMPONENT DEPENDENCIES(getPluginVersionFromDependencies):"... | java | public String getPluginDependencyVersion(String groupId, String artifactId) throws MojoExecutionException {
final Map<String, Dependency> deps = getPluginDependencies();
final String key = ArtifactUtils.versionlessKey(groupId, artifactId);
this.log.debug("COMPONENT DEPENDENCIES(getPluginVersionFromDependencies):"... | [
"public",
"String",
"getPluginDependencyVersion",
"(",
"String",
"groupId",
",",
"String",
"artifactId",
")",
"throws",
"MojoExecutionException",
"{",
"final",
"Map",
"<",
"String",
",",
"Dependency",
">",
"deps",
"=",
"getPluginDependencies",
"(",
")",
";",
"fina... | Replies the version of the given plugin that is specified in the POM of the
plugin in which this mojo is located.
@param groupId the identifier of the group.
@param artifactId thidentifier of the artifact.
@return the version, never <code>null</code>
@throws MojoExecutionException if the plugin was not found. | [
"Replies",
"the",
"version",
"of",
"the",
"given",
"plugin",
"that",
"is",
"specified",
"in",
"the",
"POM",
"of",
"the",
"plugin",
"in",
"which",
"this",
"mojo",
"is",
"located",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java#L349-L363 |
57,138 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java | MavenHelper.toXpp3Dom | @SuppressWarnings("static-method")
public Xpp3Dom toXpp3Dom(String content, Log logger) {
if (content != null && !content.isEmpty()) {
try (StringReader sr = new StringReader(content)) {
return Xpp3DomBuilder.build(sr);
} catch (Exception exception) {
if (logger != null) {
logger.debug(exception);... | java | @SuppressWarnings("static-method")
public Xpp3Dom toXpp3Dom(String content, Log logger) {
if (content != null && !content.isEmpty()) {
try (StringReader sr = new StringReader(content)) {
return Xpp3DomBuilder.build(sr);
} catch (Exception exception) {
if (logger != null) {
logger.debug(exception);... | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"public",
"Xpp3Dom",
"toXpp3Dom",
"(",
"String",
"content",
",",
"Log",
"logger",
")",
"{",
"if",
"(",
"content",
"!=",
"null",
"&&",
"!",
"content",
".",
"isEmpty",
"(",
")",
")",
"{",
"try",
"(",
... | Parse the given string for extracting an XML tree.
@param content the text to parse.
@param logger the logger to use for printing out the parsing errors. May be {@code null}.
@return the XML tree, or {@code null} if empty.
@since 0.8 | [
"Parse",
"the",
"given",
"string",
"for",
"extracting",
"an",
"XML",
"tree",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/MavenHelper.java#L391-L403 |
57,139 | sarl/sarl | products/sarlc/src/main/java/io/sarl/lang/sarlc/modules/configs/CompilerConfigModule.java | CompilerConfigModule.providesJavaBatchCompiler | @SuppressWarnings("static-method")
@Provides
@Singleton
public IJavaBatchCompiler providesJavaBatchCompiler(Injector injector, Provider<SarlConfig> config) {
final SarlConfig cfg = config.get();
final IJavaBatchCompiler compiler = cfg.getCompiler().getJavaCompiler().newCompilerInstance();
injector.injectMember... | java | @SuppressWarnings("static-method")
@Provides
@Singleton
public IJavaBatchCompiler providesJavaBatchCompiler(Injector injector, Provider<SarlConfig> config) {
final SarlConfig cfg = config.get();
final IJavaBatchCompiler compiler = cfg.getCompiler().getJavaCompiler().newCompilerInstance();
injector.injectMember... | [
"@",
"SuppressWarnings",
"(",
"\"static-method\"",
")",
"@",
"Provides",
"@",
"Singleton",
"public",
"IJavaBatchCompiler",
"providesJavaBatchCompiler",
"(",
"Injector",
"injector",
",",
"Provider",
"<",
"SarlConfig",
">",
"config",
")",
"{",
"final",
"SarlConfig",
"... | Provide a Java batch compiler based on the Bootique configuration.
@param injector the injector.
@param config the bootique configuration.
@return the batch compiler.
@since 0.8 | [
"Provide",
"a",
"Java",
"batch",
"compiler",
"based",
"on",
"the",
"Bootique",
"configuration",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/products/sarlc/src/main/java/io/sarl/lang/sarlc/modules/configs/CompilerConfigModule.java#L190-L198 |
57,140 | sarl/sarl | sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/bic/AgentLifeCycleSupport.java | AgentLifeCycleSupport.uninstallSkillsPreStage | private static void uninstallSkillsPreStage(Iterable<? extends Skill> skills) {
try {
// Use reflection to ignore the "private/protected" access right.
for (final Skill s : skills) {
SREutils.doSkillUninstallation(s, UninstallationStage.PRE_DESTROY_EVENT);
}
} catch (RuntimeException e) {
throw e;
... | java | private static void uninstallSkillsPreStage(Iterable<? extends Skill> skills) {
try {
// Use reflection to ignore the "private/protected" access right.
for (final Skill s : skills) {
SREutils.doSkillUninstallation(s, UninstallationStage.PRE_DESTROY_EVENT);
}
} catch (RuntimeException e) {
throw e;
... | [
"private",
"static",
"void",
"uninstallSkillsPreStage",
"(",
"Iterable",
"<",
"?",
"extends",
"Skill",
">",
"skills",
")",
"{",
"try",
"{",
"// Use reflection to ignore the \"private/protected\" access right.",
"for",
"(",
"final",
"Skill",
"s",
":",
"skills",
")",
... | Run the uninstallation functions of the skills for the pre stage of the uninstallation process.
<p>This function is run before the handlers for {@link Destroy} are invoked.
@param skills the skills to uninstall.
@see #uninstallSkillsFinalStage(Agent) | [
"Run",
"the",
"uninstallation",
"functions",
"of",
"the",
"skills",
"for",
"the",
"pre",
"stage",
"of",
"the",
"uninstallation",
"process",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/bic/AgentLifeCycleSupport.java#L174-L185 |
57,141 | sarl/sarl | sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/bic/AgentLifeCycleSupport.java | AgentLifeCycleSupport.uninstallSkillsFinalStage | private static void uninstallSkillsFinalStage(Iterable<? extends Skill> skills) {
try {
// Use reflection to ignore the "private/protected" access right.
for (final Skill s : skills) {
SREutils.doSkillUninstallation(s, UninstallationStage.POST_DESTROY_EVENT);
}
} catch (RuntimeException e) {
throw e... | java | private static void uninstallSkillsFinalStage(Iterable<? extends Skill> skills) {
try {
// Use reflection to ignore the "private/protected" access right.
for (final Skill s : skills) {
SREutils.doSkillUninstallation(s, UninstallationStage.POST_DESTROY_EVENT);
}
} catch (RuntimeException e) {
throw e... | [
"private",
"static",
"void",
"uninstallSkillsFinalStage",
"(",
"Iterable",
"<",
"?",
"extends",
"Skill",
">",
"skills",
")",
"{",
"try",
"{",
"// Use reflection to ignore the \"private/protected\" access right.",
"for",
"(",
"final",
"Skill",
"s",
":",
"skills",
")",
... | Run the uninstallation functions of the skills for the final stage of the uninstallation process.
<p>This function is run after the handlers for {@link Destroy} are invoked.
@param skills the skills to uninstall.
@see #uninstallSkillsPreStage(Agent) | [
"Run",
"the",
"uninstallation",
"functions",
"of",
"the",
"skills",
"for",
"the",
"final",
"stage",
"of",
"the",
"uninstallation",
"process",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/bic/AgentLifeCycleSupport.java#L194-L205 |
57,142 | sarl/sarl | sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/services/hazelcast/HazelcastKernelDiscoveryService.java | HazelcastKernelDiscoveryService.fireKernelDiscovered | protected void fireKernelDiscovered(URI uri) {
this.logger.getKernelLogger().info(MessageFormat.format(Messages.HazelcastKernelDiscoveryService_0, uri, getCurrentKernel()));
for (final KernelDiscoveryServiceListener listener : this.listeners.getListeners(KernelDiscoveryServiceListener.class)) {
listener.kernelDi... | java | protected void fireKernelDiscovered(URI uri) {
this.logger.getKernelLogger().info(MessageFormat.format(Messages.HazelcastKernelDiscoveryService_0, uri, getCurrentKernel()));
for (final KernelDiscoveryServiceListener listener : this.listeners.getListeners(KernelDiscoveryServiceListener.class)) {
listener.kernelDi... | [
"protected",
"void",
"fireKernelDiscovered",
"(",
"URI",
"uri",
")",
"{",
"this",
".",
"logger",
".",
"getKernelLogger",
"(",
")",
".",
"info",
"(",
"MessageFormat",
".",
"format",
"(",
"Messages",
".",
"HazelcastKernelDiscoveryService_0",
",",
"uri",
",",
"ge... | Notifies the listeners about the discovering of a kernel.
@param uri URI of the discovered kernel. | [
"Notifies",
"the",
"listeners",
"about",
"the",
"discovering",
"of",
"a",
"kernel",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/services/hazelcast/HazelcastKernelDiscoveryService.java#L173-L178 |
57,143 | sarl/sarl | sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/services/hazelcast/HazelcastKernelDiscoveryService.java | HazelcastKernelDiscoveryService.fireKernelDisconnected | protected void fireKernelDisconnected(URI uri) {
this.logger.getKernelLogger().info(MessageFormat.format(Messages.HazelcastKernelDiscoveryService_1, uri, getCurrentKernel()));
for (final KernelDiscoveryServiceListener listener : this.listeners.getListeners(KernelDiscoveryServiceListener.class)) {
listener.kernel... | java | protected void fireKernelDisconnected(URI uri) {
this.logger.getKernelLogger().info(MessageFormat.format(Messages.HazelcastKernelDiscoveryService_1, uri, getCurrentKernel()));
for (final KernelDiscoveryServiceListener listener : this.listeners.getListeners(KernelDiscoveryServiceListener.class)) {
listener.kernel... | [
"protected",
"void",
"fireKernelDisconnected",
"(",
"URI",
"uri",
")",
"{",
"this",
".",
"logger",
".",
"getKernelLogger",
"(",
")",
".",
"info",
"(",
"MessageFormat",
".",
"format",
"(",
"Messages",
".",
"HazelcastKernelDiscoveryService_1",
",",
"uri",
",",
"... | Notifies the listeners about the killing of a kernel.
@param uri URI of the disconnected kernel. | [
"Notifies",
"the",
"listeners",
"about",
"the",
"killing",
"of",
"a",
"kernel",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/kernel/services/hazelcast/HazelcastKernelDiscoveryService.java#L185-L190 |
57,144 | sarl/sarl | products/sarlc/src/main/java/io/sarl/lang/sarlc/configs/SarlConfig.java | SarlConfig.getConfiguration | public static SarlConfig getConfiguration(ConfigurationFactory configFactory) {
assert configFactory != null;
return configFactory.config(SarlConfig.class, PREFIX);
} | java | public static SarlConfig getConfiguration(ConfigurationFactory configFactory) {
assert configFactory != null;
return configFactory.config(SarlConfig.class, PREFIX);
} | [
"public",
"static",
"SarlConfig",
"getConfiguration",
"(",
"ConfigurationFactory",
"configFactory",
")",
"{",
"assert",
"configFactory",
"!=",
"null",
";",
"return",
"configFactory",
".",
"config",
"(",
"SarlConfig",
".",
"class",
",",
"PREFIX",
")",
";",
"}"
] | Replies the configuration for SARLC.
@param configFactory the general configuration factory.
@return the SARLC configuration. | [
"Replies",
"the",
"configuration",
"for",
"SARLC",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/products/sarlc/src/main/java/io/sarl/lang/sarlc/configs/SarlConfig.java#L108-L111 |
57,145 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/AbstractSarlMojo.java | AbstractSarlMojo.unix2os | protected static File unix2os(String filename) {
File file = null;
for (final String base : filename.split(Pattern.quote("/"))) { //$NON-NLS-1$
if (file == null) {
file = new File(base);
} else {
file = new File(file, base);
}
}
return file;
} | java | protected static File unix2os(String filename) {
File file = null;
for (final String base : filename.split(Pattern.quote("/"))) { //$NON-NLS-1$
if (file == null) {
file = new File(base);
} else {
file = new File(file, base);
}
}
return file;
} | [
"protected",
"static",
"File",
"unix2os",
"(",
"String",
"filename",
")",
"{",
"File",
"file",
"=",
"null",
";",
"for",
"(",
"final",
"String",
"base",
":",
"filename",
".",
"split",
"(",
"Pattern",
".",
"quote",
"(",
"\"/\"",
")",
")",
")",
"{",
"//... | Create a file from a unix-like representation of the filename.
@param filename the unix-like filename.
@return the file. | [
"Create",
"a",
"file",
"from",
"a",
"unix",
"-",
"like",
"representation",
"of",
"the",
"filename",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/AbstractSarlMojo.java#L137-L147 |
57,146 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/AbstractSarlMojo.java | AbstractSarlMojo.makeAbsolute | protected File makeAbsolute(File file) {
if (!file.isAbsolute()) {
final File basedir = this.mavenHelper.getSession().getCurrentProject().getBasedir();
return new File(basedir, file.getPath()).getAbsoluteFile();
}
return file;
} | java | protected File makeAbsolute(File file) {
if (!file.isAbsolute()) {
final File basedir = this.mavenHelper.getSession().getCurrentProject().getBasedir();
return new File(basedir, file.getPath()).getAbsoluteFile();
}
return file;
} | [
"protected",
"File",
"makeAbsolute",
"(",
"File",
"file",
")",
"{",
"if",
"(",
"!",
"file",
".",
"isAbsolute",
"(",
")",
")",
"{",
"final",
"File",
"basedir",
"=",
"this",
".",
"mavenHelper",
".",
"getSession",
"(",
")",
".",
"getCurrentProject",
"(",
... | Make absolute the given filename, relatively to the project's folder.
@param file the file to convert.
@return the absolute filename. | [
"Make",
"absolute",
"the",
"given",
"filename",
"relatively",
"to",
"the",
"project",
"s",
"folder",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/AbstractSarlMojo.java#L154-L160 |
57,147 | sarl/sarl | main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/AbstractSarlMojo.java | AbstractSarlMojo.executeMojo | protected void executeMojo(
String groupId, String artifactId,
String version, String goal,
String configuration,
Dependency... dependencies) throws MojoExecutionException, MojoFailureException {
final Plugin plugin = new Plugin();
plugin.setArtifactId(artifactId);
plugin.setGroupId(groupId);
plugin... | java | protected void executeMojo(
String groupId, String artifactId,
String version, String goal,
String configuration,
Dependency... dependencies) throws MojoExecutionException, MojoFailureException {
final Plugin plugin = new Plugin();
plugin.setArtifactId(artifactId);
plugin.setGroupId(groupId);
plugin... | [
"protected",
"void",
"executeMojo",
"(",
"String",
"groupId",
",",
"String",
"artifactId",
",",
"String",
"version",
",",
"String",
"goal",
",",
"String",
"configuration",
",",
"Dependency",
"...",
"dependencies",
")",
"throws",
"MojoExecutionException",
",",
"Moj... | Execute another MOJO.
@param groupId identifier of the MOJO plugin group.
@param artifactId identifier of the MOJO plugin artifact.
@param version version of the MOJO plugin version.
@param goal the goal to run.
@param configuration the XML code for the configuration.
@param dependencies the dependencies of the plugin... | [
"Execute",
"another",
"MOJO",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/internalmaven/sarl-maven-plugin/src/main/java/io/sarl/maven/compiler/AbstractSarlMojo.java#L231-L273 |
57,148 | sarl/sarl | main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java | AbstractDocumentationMojo.internalExecute | protected String internalExecute() {
getLog().info(Messages.AbstractDocumentationMojo_1);
final Map<File, File> files = getFiles();
getLog().info(MessageFormat.format(Messages.AbstractDocumentationMojo_2, files.size()));
return internalExecute(files);
} | java | protected String internalExecute() {
getLog().info(Messages.AbstractDocumentationMojo_1);
final Map<File, File> files = getFiles();
getLog().info(MessageFormat.format(Messages.AbstractDocumentationMojo_2, files.size()));
return internalExecute(files);
} | [
"protected",
"String",
"internalExecute",
"(",
")",
"{",
"getLog",
"(",
")",
".",
"info",
"(",
"Messages",
".",
"AbstractDocumentationMojo_1",
")",
";",
"final",
"Map",
"<",
"File",
",",
"File",
">",
"files",
"=",
"getFiles",
"(",
")",
";",
"getLog",
"("... | Internal run.
@return the error message | [
"Internal",
"run",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java#L242-L247 |
57,149 | sarl/sarl | main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java | AbstractDocumentationMojo.formatErrorMessage | protected String formatErrorMessage(File inputFile, Throwable exception) {
File filename;
int lineno = 0;
final boolean addExceptionName;
if (exception instanceof ParsingException) {
addExceptionName = false;
final ParsingException pexception = (ParsingException) exception;
final File file = pexception... | java | protected String formatErrorMessage(File inputFile, Throwable exception) {
File filename;
int lineno = 0;
final boolean addExceptionName;
if (exception instanceof ParsingException) {
addExceptionName = false;
final ParsingException pexception = (ParsingException) exception;
final File file = pexception... | [
"protected",
"String",
"formatErrorMessage",
"(",
"File",
"inputFile",
",",
"Throwable",
"exception",
")",
"{",
"File",
"filename",
";",
"int",
"lineno",
"=",
"0",
";",
"final",
"boolean",
"addExceptionName",
";",
"if",
"(",
"exception",
"instanceof",
"ParsingEx... | Format the error message.
@param inputFile the input file.
@param exception the error.
@return the error message. | [
"Format",
"the",
"error",
"message",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java#L309-L351 |
57,150 | sarl/sarl | main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java | AbstractDocumentationMojo.createLanguageParser | @SuppressWarnings("checkstyle:npathcomplexity")
protected AbstractMarkerLanguageParser createLanguageParser(File inputFile) throws MojoExecutionException, IOException {
final AbstractMarkerLanguageParser parser;
if (isFileExtension(inputFile, MarkdownParser.MARKDOWN_FILE_EXTENSIONS)) {
parser = this.injector.ge... | java | @SuppressWarnings("checkstyle:npathcomplexity")
protected AbstractMarkerLanguageParser createLanguageParser(File inputFile) throws MojoExecutionException, IOException {
final AbstractMarkerLanguageParser parser;
if (isFileExtension(inputFile, MarkdownParser.MARKDOWN_FILE_EXTENSIONS)) {
parser = this.injector.ge... | [
"@",
"SuppressWarnings",
"(",
"\"checkstyle:npathcomplexity\"",
")",
"protected",
"AbstractMarkerLanguageParser",
"createLanguageParser",
"(",
"File",
"inputFile",
")",
"throws",
"MojoExecutionException",
",",
"IOException",
"{",
"final",
"AbstractMarkerLanguageParser",
"parser... | Create a parser for the given file.
@param inputFile the file to be parsed.
@return the parser.
@throws MojoExecutionException if the parser cannot be created.
@throws IOException if a classpath entry cannot be found. | [
"Create",
"a",
"parser",
"for",
"the",
"given",
"file",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java#L378-L429 |
57,151 | sarl/sarl | main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java | AbstractDocumentationMojo.getFiles | protected Map<File, File> getFiles() {
final Map<File, File> files = new TreeMap<>();
for (final String rootName : this.inferredSourceDirectories) {
File root = FileSystem.convertStringToFile(rootName);
if (!root.isAbsolute()) {
root = FileSystem.makeAbsolute(root, this.baseDirectory);
}
getLog().de... | java | protected Map<File, File> getFiles() {
final Map<File, File> files = new TreeMap<>();
for (final String rootName : this.inferredSourceDirectories) {
File root = FileSystem.convertStringToFile(rootName);
if (!root.isAbsolute()) {
root = FileSystem.makeAbsolute(root, this.baseDirectory);
}
getLog().de... | [
"protected",
"Map",
"<",
"File",
",",
"File",
">",
"getFiles",
"(",
")",
"{",
"final",
"Map",
"<",
"File",
",",
"File",
">",
"files",
"=",
"new",
"TreeMap",
"<>",
"(",
")",
";",
"for",
"(",
"final",
"String",
"rootName",
":",
"this",
".",
"inferred... | Replies the source files.
@return the map from the source files to the corresponding source folders. | [
"Replies",
"the",
"source",
"files",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java#L463-L478 |
57,152 | sarl/sarl | main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java | AbstractDocumentationMojo.toPackageName | protected static String toPackageName(String rootPackage, File packageName) {
final StringBuilder name = new StringBuilder();
File tmp = packageName;
while (tmp != null) {
final String elementName = tmp.getName();
if (!Strings.equal(FileSystem.CURRENT_DIRECTORY, elementName)
&& !Strings.equal(FileSyst... | java | protected static String toPackageName(String rootPackage, File packageName) {
final StringBuilder name = new StringBuilder();
File tmp = packageName;
while (tmp != null) {
final String elementName = tmp.getName();
if (!Strings.equal(FileSystem.CURRENT_DIRECTORY, elementName)
&& !Strings.equal(FileSyst... | [
"protected",
"static",
"String",
"toPackageName",
"(",
"String",
"rootPackage",
",",
"File",
"packageName",
")",
"{",
"final",
"StringBuilder",
"name",
"=",
"new",
"StringBuilder",
"(",
")",
";",
"File",
"tmp",
"=",
"packageName",
";",
"while",
"(",
"tmp",
"... | Convert a file to a package name.
@param rootPackage an additional root package.
@param packageName the file.
@return the package name. | [
"Convert",
"a",
"file",
"to",
"a",
"package",
"name",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java#L491-L512 |
57,153 | sarl/sarl | main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java | AbstractDocumentationMojo.toPackageFolder | protected static File toPackageFolder(String packageName) {
File file = null;
for (final String element : packageName.split("[.]")) { //$NON-NLS-1$
if (file == null) {
file = new File(element);
} else {
file = new File(file, element);
}
}
return file;
} | java | protected static File toPackageFolder(String packageName) {
File file = null;
for (final String element : packageName.split("[.]")) { //$NON-NLS-1$
if (file == null) {
file = new File(element);
} else {
file = new File(file, element);
}
}
return file;
} | [
"protected",
"static",
"File",
"toPackageFolder",
"(",
"String",
"packageName",
")",
"{",
"File",
"file",
"=",
"null",
";",
"for",
"(",
"final",
"String",
"element",
":",
"packageName",
".",
"split",
"(",
"\"[.]\"",
")",
")",
"{",
"//$NON-NLS-1$",
"if",
"(... | Convert a a package name for therelative file.
@param packageName the name.
@return the file. | [
"Convert",
"a",
"a",
"package",
"name",
"for",
"therelative",
"file",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java#L519-L529 |
57,154 | sarl/sarl | main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java | AbstractDocumentationMojo.getBootClassPath | protected String getBootClassPath() throws IOException {
final Toolchain toolchain = this.toolchainManager.getToolchainFromBuildContext("jdk", this.session); //$NON-NLS-1$
if (toolchain instanceof JavaToolchain && toolchain instanceof ToolchainPrivate) {
final JavaToolchain javaToolChain = (JavaToolchain) toolch... | java | protected String getBootClassPath() throws IOException {
final Toolchain toolchain = this.toolchainManager.getToolchainFromBuildContext("jdk", this.session); //$NON-NLS-1$
if (toolchain instanceof JavaToolchain && toolchain instanceof ToolchainPrivate) {
final JavaToolchain javaToolChain = (JavaToolchain) toolch... | [
"protected",
"String",
"getBootClassPath",
"(",
")",
"throws",
"IOException",
"{",
"final",
"Toolchain",
"toolchain",
"=",
"this",
".",
"toolchainManager",
".",
"getToolchainFromBuildContext",
"(",
"\"jdk\"",
",",
"this",
".",
"session",
")",
";",
"//$NON-NLS-1$",
... | Replies the boot classpath.
@return the boot classpath.
@throws IOException in case of error. | [
"Replies",
"the",
"boot",
"classpath",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/externalmaven/io.sarl.maven.docs.generator/src/main/java/io/sarl/maven/docs/AbstractDocumentationMojo.java#L563-L592 |
57,155 | sarl/sarl | main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/ExpressionBuilderImpl.java | ExpressionBuilderImpl.fromString | @Pure
protected XExpression fromString(String expression) {
if (!Strings.isEmpty(expression)) {
ResourceSet resourceSet = this.context.eResource().getResourceSet();
URI uri = computeUnusedUri(resourceSet);
Resource resource = getResourceFactory().createResource(uri);
resourceSet.getResources().add(resour... | java | @Pure
protected XExpression fromString(String expression) {
if (!Strings.isEmpty(expression)) {
ResourceSet resourceSet = this.context.eResource().getResourceSet();
URI uri = computeUnusedUri(resourceSet);
Resource resource = getResourceFactory().createResource(uri);
resourceSet.getResources().add(resour... | [
"@",
"Pure",
"protected",
"XExpression",
"fromString",
"(",
"String",
"expression",
")",
"{",
"if",
"(",
"!",
"Strings",
".",
"isEmpty",
"(",
"expression",
")",
")",
"{",
"ResourceSet",
"resourceSet",
"=",
"this",
".",
"context",
".",
"eResource",
"(",
")"... | Create an expression but does not change the container.
@param expression the textual representation of the expression.
@return the expression. | [
"Create",
"an",
"expression",
"but",
"does",
"not",
"change",
"the",
"container",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/ExpressionBuilderImpl.java#L158-L178 |
57,156 | sarl/sarl | main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/ExpressionBuilderImpl.java | ExpressionBuilderImpl.getDefaultXExpressionForType | @Pure
public XExpression getDefaultXExpressionForType(String type) {
//TODO: Check if a similar function exists in the Xbase library.
XExpression expr = null;
if (type != null && !"void".equals(type) && !Void.class.getName().equals(type)) {
switch (type) {
case "boolean":
case "java.lang.Boolean":
X... | java | @Pure
public XExpression getDefaultXExpressionForType(String type) {
//TODO: Check if a similar function exists in the Xbase library.
XExpression expr = null;
if (type != null && !"void".equals(type) && !Void.class.getName().equals(type)) {
switch (type) {
case "boolean":
case "java.lang.Boolean":
X... | [
"@",
"Pure",
"public",
"XExpression",
"getDefaultXExpressionForType",
"(",
"String",
"type",
")",
"{",
"//TODO: Check if a similar function exists in the Xbase library.",
"XExpression",
"expr",
"=",
"null",
";",
"if",
"(",
"type",
"!=",
"null",
"&&",
"!",
"\"void\"",
... | Replies the XExpression for the default value associated to the given type.
@param type the type for which the default value should be determined.
@return the default value. | [
"Replies",
"the",
"XExpression",
"for",
"the",
"default",
"value",
"associated",
"to",
"the",
"given",
"type",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/ExpressionBuilderImpl.java#L184-L237 |
57,157 | sarl/sarl | main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/ExpressionBuilderImpl.java | ExpressionBuilderImpl.getDefaultValueForType | @Pure
public String getDefaultValueForType(String type) {
//TODO: Check if a similar function exists in the Xbase library.
String defaultValue = "";
if (!Strings.isEmpty(type) && !"void".equals(type)) {
switch (type) {
case "boolean":
defaultValue = "true";
break;
case "double":
defaultValue... | java | @Pure
public String getDefaultValueForType(String type) {
//TODO: Check if a similar function exists in the Xbase library.
String defaultValue = "";
if (!Strings.isEmpty(type) && !"void".equals(type)) {
switch (type) {
case "boolean":
defaultValue = "true";
break;
case "double":
defaultValue... | [
"@",
"Pure",
"public",
"String",
"getDefaultValueForType",
"(",
"String",
"type",
")",
"{",
"//TODO: Check if a similar function exists in the Xbase library.",
"String",
"defaultValue",
"=",
"\"\"",
";",
"if",
"(",
"!",
"Strings",
".",
"isEmpty",
"(",
"type",
")",
"... | Replies the default value for the given type.
@param type the type for which the default value should be determined.
@return the default value. | [
"Replies",
"the",
"default",
"value",
"for",
"the",
"given",
"type",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/ExpressionBuilderImpl.java#L243-L279 |
57,158 | sarl/sarl | main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/ExpressionBuilderImpl.java | ExpressionBuilderImpl.createReferenceToThis | public XFeatureCall createReferenceToThis() {
final XExpression expr = getXExpression();
XtendTypeDeclaration type = EcoreUtil2.getContainerOfType(expr, XtendTypeDeclaration.class);
JvmType jvmObject = getAssociatedElement(JvmType.class, type, expr.eResource());
final XFeatureCall thisFeature = XbaseFactory.eIN... | java | public XFeatureCall createReferenceToThis() {
final XExpression expr = getXExpression();
XtendTypeDeclaration type = EcoreUtil2.getContainerOfType(expr, XtendTypeDeclaration.class);
JvmType jvmObject = getAssociatedElement(JvmType.class, type, expr.eResource());
final XFeatureCall thisFeature = XbaseFactory.eIN... | [
"public",
"XFeatureCall",
"createReferenceToThis",
"(",
")",
"{",
"final",
"XExpression",
"expr",
"=",
"getXExpression",
"(",
")",
";",
"XtendTypeDeclaration",
"type",
"=",
"EcoreUtil2",
".",
"getContainerOfType",
"(",
"expr",
",",
"XtendTypeDeclaration",
".",
"clas... | Create a reference to "this" object or to the current type.
@return the reference. | [
"Create",
"a",
"reference",
"to",
"this",
"object",
"or",
"to",
"the",
"current",
"type",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/ExpressionBuilderImpl.java#L315-L322 |
57,159 | sarl/sarl | main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/ExpressionBuilderImpl.java | ExpressionBuilderImpl.createReferenceToSuper | public XFeatureCall createReferenceToSuper() {
final XExpression expr = getXExpression();
XtendTypeDeclaration type = EcoreUtil2.getContainerOfType(expr, XtendTypeDeclaration.class);
JvmType jvmObject = getAssociatedElement(JvmType.class, type, expr.eResource());
final XFeatureCall superFeature = XbaseFactory.e... | java | public XFeatureCall createReferenceToSuper() {
final XExpression expr = getXExpression();
XtendTypeDeclaration type = EcoreUtil2.getContainerOfType(expr, XtendTypeDeclaration.class);
JvmType jvmObject = getAssociatedElement(JvmType.class, type, expr.eResource());
final XFeatureCall superFeature = XbaseFactory.e... | [
"public",
"XFeatureCall",
"createReferenceToSuper",
"(",
")",
"{",
"final",
"XExpression",
"expr",
"=",
"getXExpression",
"(",
")",
";",
"XtendTypeDeclaration",
"type",
"=",
"EcoreUtil2",
".",
"getContainerOfType",
"(",
"expr",
",",
"XtendTypeDeclaration",
".",
"cla... | Create a reference to "super" object or to the super type.
@return the reference. | [
"Create",
"a",
"reference",
"to",
"super",
"object",
"or",
"to",
"the",
"super",
"type",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src-gen/io/sarl/lang/codebuilder/builders/ExpressionBuilderImpl.java#L328-L350 |
57,160 | sarl/sarl | sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/services/network/NetworkUtil.java | NetworkUtil.getLoopbackAddress | public static InetAddress getLoopbackAddress() {
try {
final Enumeration<NetworkInterface> interfaces = NetworkInterface.getNetworkInterfaces();
if (interfaces != null) {
NetworkInterface inter;
InetAddress adr;
Enumeration<InetAddress> addrs;
while (interfaces.hasMoreElements()) {
inter = ... | java | public static InetAddress getLoopbackAddress() {
try {
final Enumeration<NetworkInterface> interfaces = NetworkInterface.getNetworkInterfaces();
if (interfaces != null) {
NetworkInterface inter;
InetAddress adr;
Enumeration<InetAddress> addrs;
while (interfaces.hasMoreElements()) {
inter = ... | [
"public",
"static",
"InetAddress",
"getLoopbackAddress",
"(",
")",
"{",
"try",
"{",
"final",
"Enumeration",
"<",
"NetworkInterface",
">",
"interfaces",
"=",
"NetworkInterface",
".",
"getNetworkInterfaces",
"(",
")",
";",
"if",
"(",
"interfaces",
"!=",
"null",
")... | Replies the IPv4 loopback address.
@return the IPv4 loopback address or <code>null</code> if none. | [
"Replies",
"the",
"IPv4",
"loopback",
"address",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/services/network/NetworkUtil.java#L95-L119 |
57,161 | sarl/sarl | sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/services/network/NetworkUtil.java | NetworkUtil.toURI | public static URI toURI(String uri) throws URISyntaxException {
final URI u = new URI(uri);
// Inspired by ZeroMQ
String adr = u.getAuthority();
if (adr == null) {
adr = u.getPath();
}
if (adr != null && adr.endsWith(":*")) { //$NON-NLS-1$
return new URI(u.getScheme(), u.getUserInfo(), adr.substring(0... | java | public static URI toURI(String uri) throws URISyntaxException {
final URI u = new URI(uri);
// Inspired by ZeroMQ
String adr = u.getAuthority();
if (adr == null) {
adr = u.getPath();
}
if (adr != null && adr.endsWith(":*")) { //$NON-NLS-1$
return new URI(u.getScheme(), u.getUserInfo(), adr.substring(0... | [
"public",
"static",
"URI",
"toURI",
"(",
"String",
"uri",
")",
"throws",
"URISyntaxException",
"{",
"final",
"URI",
"u",
"=",
"new",
"URI",
"(",
"uri",
")",
";",
"// Inspired by ZeroMQ",
"String",
"adr",
"=",
"u",
".",
"getAuthority",
"(",
")",
";",
"if"... | Convert a string URI to an object URI.
<p>This function support the syntax ":*" for the port.
@param uri the string representation of the URI to parse.
@return the URI.
@throws URISyntaxException - if the given string has invalid format. | [
"Convert",
"a",
"string",
"URI",
"to",
"an",
"object",
"URI",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/services/network/NetworkUtil.java#L150-L162 |
57,162 | sarl/sarl | sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/services/network/NetworkUtil.java | NetworkUtil.toURI | public static URI toURI(InetAddress adr) {
try {
return new URI("tcp", adr.getHostAddress(), null, null); //$NON-NLS-1$
} catch (URISyntaxException e) {
throw new IOError(e);
}
} | java | public static URI toURI(InetAddress adr) {
try {
return new URI("tcp", adr.getHostAddress(), null, null); //$NON-NLS-1$
} catch (URISyntaxException e) {
throw new IOError(e);
}
} | [
"public",
"static",
"URI",
"toURI",
"(",
"InetAddress",
"adr",
")",
"{",
"try",
"{",
"return",
"new",
"URI",
"(",
"\"tcp\"",
",",
"adr",
".",
"getHostAddress",
"(",
")",
",",
"null",
",",
"null",
")",
";",
"//$NON-NLS-1$",
"}",
"catch",
"(",
"URISyntax... | Convert an inet address to an URI.
@param adr address to convert to URI.
@return the URI. | [
"Convert",
"an",
"inet",
"address",
"to",
"an",
"URI",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/sre/io.janusproject/io.janusproject.plugin/src/io/janusproject/services/network/NetworkUtil.java#L170-L176 |
57,163 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.toLightweightTypeReference | protected LightweightTypeReference toLightweightTypeReference(JvmType type, EObject context) {
final StandardTypeReferenceOwner owner = new StandardTypeReferenceOwner(getServices(), context);
final LightweightTypeReferenceFactory factory = new LightweightTypeReferenceFactory(owner, false);
return factory.toLightw... | java | protected LightweightTypeReference toLightweightTypeReference(JvmType type, EObject context) {
final StandardTypeReferenceOwner owner = new StandardTypeReferenceOwner(getServices(), context);
final LightweightTypeReferenceFactory factory = new LightweightTypeReferenceFactory(owner, false);
return factory.toLightw... | [
"protected",
"LightweightTypeReference",
"toLightweightTypeReference",
"(",
"JvmType",
"type",
",",
"EObject",
"context",
")",
"{",
"final",
"StandardTypeReferenceOwner",
"owner",
"=",
"new",
"StandardTypeReferenceOwner",
"(",
"getServices",
"(",
")",
",",
"context",
")... | Create a lightweight type reference from the given type.
@param type the type to point to.
@param context the context in which the reference is located.
@return the reference. | [
"Create",
"a",
"lightweight",
"type",
"reference",
"from",
"the",
"given",
"type",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L472-L476 |
57,164 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.isIgnored | protected boolean isIgnored(String issueCode, EObject currentObject) {
final IssueSeverities severities = getIssueSeverities(getContext(), currentObject);
return severities.isIgnored(issueCode);
} | java | protected boolean isIgnored(String issueCode, EObject currentObject) {
final IssueSeverities severities = getIssueSeverities(getContext(), currentObject);
return severities.isIgnored(issueCode);
} | [
"protected",
"boolean",
"isIgnored",
"(",
"String",
"issueCode",
",",
"EObject",
"currentObject",
")",
"{",
"final",
"IssueSeverities",
"severities",
"=",
"getIssueSeverities",
"(",
"getContext",
"(",
")",
",",
"currentObject",
")",
";",
"return",
"severities",
".... | Replies if the given issue is ignored for the given object.
@param issueCode the code if the issue.
@param currentObject the current object.
@return <code>true</code> if the issue is ignored.
@see #isIgnored(String) | [
"Replies",
"if",
"the",
"given",
"issue",
"is",
"ignored",
"for",
"the",
"given",
"object",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L506-L509 |
57,165 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.canonicalName | protected String canonicalName(EObject object) {
if (object instanceof JvmIdentifiableElement) {
return ((JvmIdentifiableElement) object).getQualifiedName();
}
final EObject jvmElement = this.associations.getPrimaryJvmElement(object);
if (jvmElement instanceof JvmIdentifiableElement) {
return ((JvmIdentif... | java | protected String canonicalName(EObject object) {
if (object instanceof JvmIdentifiableElement) {
return ((JvmIdentifiableElement) object).getQualifiedName();
}
final EObject jvmElement = this.associations.getPrimaryJvmElement(object);
if (jvmElement instanceof JvmIdentifiableElement) {
return ((JvmIdentif... | [
"protected",
"String",
"canonicalName",
"(",
"EObject",
"object",
")",
"{",
"if",
"(",
"object",
"instanceof",
"JvmIdentifiableElement",
")",
"{",
"return",
"(",
"(",
"JvmIdentifiableElement",
")",
"object",
")",
".",
"getQualifiedName",
"(",
")",
";",
"}",
"f... | Replies the canonical name of the given object.
@param object the object.
@return the canonical name or <code>null</code> if it cannot be computed. | [
"Replies",
"the",
"canonical",
"name",
"of",
"the",
"given",
"object",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L516-L525 |
57,166 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkSpaceUse | @Check
public void checkSpaceUse(SarlSpace space) {
error(MessageFormat.format(
Messages.SARLValidator_0,
this.grammarAccess.getSpaceKeyword()),
space,
null);
} | java | @Check
public void checkSpaceUse(SarlSpace space) {
error(MessageFormat.format(
Messages.SARLValidator_0,
this.grammarAccess.getSpaceKeyword()),
space,
null);
} | [
"@",
"Check",
"public",
"void",
"checkSpaceUse",
"(",
"SarlSpace",
"space",
")",
"{",
"error",
"(",
"MessageFormat",
".",
"format",
"(",
"Messages",
".",
"SARLValidator_0",
",",
"this",
".",
"grammarAccess",
".",
"getSpaceKeyword",
"(",
")",
")",
",",
"space... | Space keyword is reserved.
@param space the space to check. | [
"Space",
"keyword",
"is",
"reserved",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L531-L538 |
57,167 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkArtifactUse | @Check
public void checkArtifactUse(SarlArtifact artifact) {
error(MessageFormat.format(
Messages.SARLValidator_0,
this.grammarAccess.getSpaceKeyword()),
artifact,
null);
} | java | @Check
public void checkArtifactUse(SarlArtifact artifact) {
error(MessageFormat.format(
Messages.SARLValidator_0,
this.grammarAccess.getSpaceKeyword()),
artifact,
null);
} | [
"@",
"Check",
"public",
"void",
"checkArtifactUse",
"(",
"SarlArtifact",
"artifact",
")",
"{",
"error",
"(",
"MessageFormat",
".",
"format",
"(",
"Messages",
".",
"SARLValidator_0",
",",
"this",
".",
"grammarAccess",
".",
"getSpaceKeyword",
"(",
")",
")",
",",... | Artifact keyword is reserved.
@param artifact the artifact to check. | [
"Artifact",
"keyword",
"is",
"reserved",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L544-L551 |
57,168 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkEarlyExitEventInFires | @Check
public void checkEarlyExitEventInFires(SarlAction action) {
int i = 0;
for (final JvmTypeReference event : action.getFiredEvents()) {
if (!this.earlyExitComputer.isEarlyExitEvent(event)) {
warning(MessageFormat.format(
Messages.SARLValidator_95,
event.getSimpleName()),
action,
... | java | @Check
public void checkEarlyExitEventInFires(SarlAction action) {
int i = 0;
for (final JvmTypeReference event : action.getFiredEvents()) {
if (!this.earlyExitComputer.isEarlyExitEvent(event)) {
warning(MessageFormat.format(
Messages.SARLValidator_95,
event.getSimpleName()),
action,
... | [
"@",
"Check",
"public",
"void",
"checkEarlyExitEventInFires",
"(",
"SarlAction",
"action",
")",
"{",
"int",
"i",
"=",
"0",
";",
"for",
"(",
"final",
"JvmTypeReference",
"event",
":",
"action",
".",
"getFiredEvents",
"(",
")",
")",
"{",
"if",
"(",
"!",
"t... | Emit a warning when the events after the "fires" keyword are not early-exit events.
@param action the action to check. | [
"Emit",
"a",
"warning",
"when",
"the",
"events",
"after",
"the",
"fires",
"keyword",
"are",
"not",
"early",
"-",
"exit",
"events",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L557-L571 |
57,169 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkRequiredCapacityUse | @Check
public void checkRequiredCapacityUse(SarlRequiredCapacity statement) {
warning(MessageFormat.format(
Messages.SARLValidator_0,
this.grammarAccess.getRequiresKeyword()),
statement,
null);
} | java | @Check
public void checkRequiredCapacityUse(SarlRequiredCapacity statement) {
warning(MessageFormat.format(
Messages.SARLValidator_0,
this.grammarAccess.getRequiresKeyword()),
statement,
null);
} | [
"@",
"Check",
"public",
"void",
"checkRequiredCapacityUse",
"(",
"SarlRequiredCapacity",
"statement",
")",
"{",
"warning",
"(",
"MessageFormat",
".",
"format",
"(",
"Messages",
".",
"SARLValidator_0",
",",
"this",
".",
"grammarAccess",
".",
"getRequiresKeyword",
"("... | Emit a warning when the "requires" keyword is used.
@param statement the statement to check. | [
"Emit",
"a",
"warning",
"when",
"the",
"requires",
"keyword",
"is",
"used",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L577-L584 |
57,170 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkModifiers | @Check
protected void checkModifiers(SarlAgent agent) {
this.agentModifierValidator.checkModifiers(agent,
MessageFormat.format(Messages.SARLValidator_9, agent.getName()));
} | java | @Check
protected void checkModifiers(SarlAgent agent) {
this.agentModifierValidator.checkModifiers(agent,
MessageFormat.format(Messages.SARLValidator_9, agent.getName()));
} | [
"@",
"Check",
"protected",
"void",
"checkModifiers",
"(",
"SarlAgent",
"agent",
")",
"{",
"this",
".",
"agentModifierValidator",
".",
"checkModifiers",
"(",
"agent",
",",
"MessageFormat",
".",
"format",
"(",
"Messages",
".",
"SARLValidator_9",
",",
"agent",
".",... | Check the modifiers for the SARL agents.
@param agent the agent. | [
"Check",
"the",
"modifiers",
"for",
"the",
"SARL",
"agents",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L778-L782 |
57,171 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkModifiers | @Check
protected void checkModifiers(SarlBehavior behavior) {
this.behaviorModifierValidator.checkModifiers(behavior,
MessageFormat.format(Messages.SARLValidator_9, behavior.getName()));
} | java | @Check
protected void checkModifiers(SarlBehavior behavior) {
this.behaviorModifierValidator.checkModifiers(behavior,
MessageFormat.format(Messages.SARLValidator_9, behavior.getName()));
} | [
"@",
"Check",
"protected",
"void",
"checkModifiers",
"(",
"SarlBehavior",
"behavior",
")",
"{",
"this",
".",
"behaviorModifierValidator",
".",
"checkModifiers",
"(",
"behavior",
",",
"MessageFormat",
".",
"format",
"(",
"Messages",
".",
"SARLValidator_9",
",",
"be... | Check the modifiers for the SARL behaviors.
@param behavior the behavior. | [
"Check",
"the",
"modifiers",
"for",
"the",
"SARL",
"behaviors",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L788-L792 |
57,172 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkModifiers | @Check
protected void checkModifiers(SarlCapacity capacity) {
this.capacityModifierValidator.checkModifiers(capacity,
MessageFormat.format(Messages.SARLValidator_9, capacity.getName()));
} | java | @Check
protected void checkModifiers(SarlCapacity capacity) {
this.capacityModifierValidator.checkModifiers(capacity,
MessageFormat.format(Messages.SARLValidator_9, capacity.getName()));
} | [
"@",
"Check",
"protected",
"void",
"checkModifiers",
"(",
"SarlCapacity",
"capacity",
")",
"{",
"this",
".",
"capacityModifierValidator",
".",
"checkModifiers",
"(",
"capacity",
",",
"MessageFormat",
".",
"format",
"(",
"Messages",
".",
"SARLValidator_9",
",",
"ca... | Check the modifiers for the SARL capacities.
@param capacity the capacity. | [
"Check",
"the",
"modifiers",
"for",
"the",
"SARL",
"capacities",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L798-L802 |
57,173 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkModifiers | @Check
protected void checkModifiers(SarlSkill skill) {
this.skillModifierValidator.checkModifiers(skill,
MessageFormat.format(Messages.SARLValidator_9, skill.getName()));
} | java | @Check
protected void checkModifiers(SarlSkill skill) {
this.skillModifierValidator.checkModifiers(skill,
MessageFormat.format(Messages.SARLValidator_9, skill.getName()));
} | [
"@",
"Check",
"protected",
"void",
"checkModifiers",
"(",
"SarlSkill",
"skill",
")",
"{",
"this",
".",
"skillModifierValidator",
".",
"checkModifiers",
"(",
"skill",
",",
"MessageFormat",
".",
"format",
"(",
"Messages",
".",
"SARLValidator_9",
",",
"skill",
".",... | Check the modifiers for the SARL skills.
@param skill the skill. | [
"Check",
"the",
"modifiers",
"for",
"the",
"SARL",
"skills",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L808-L812 |
57,174 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkContainerType | @Check
public void checkContainerType(SarlAgent agent) {
final XtendTypeDeclaration declaringType = agent.getDeclaringType();
if (declaringType != null) {
final String name = canonicalName(declaringType);
assert name != null;
error(MessageFormat.format(Messages.SARLValidator_28, name),
agent,
nu... | java | @Check
public void checkContainerType(SarlAgent agent) {
final XtendTypeDeclaration declaringType = agent.getDeclaringType();
if (declaringType != null) {
final String name = canonicalName(declaringType);
assert name != null;
error(MessageFormat.format(Messages.SARLValidator_28, name),
agent,
nu... | [
"@",
"Check",
"public",
"void",
"checkContainerType",
"(",
"SarlAgent",
"agent",
")",
"{",
"final",
"XtendTypeDeclaration",
"declaringType",
"=",
"agent",
".",
"getDeclaringType",
"(",
")",
";",
"if",
"(",
"declaringType",
"!=",
"null",
")",
"{",
"final",
"Str... | Check the container for the SARL agents.
@param agent the agent. | [
"Check",
"the",
"container",
"for",
"the",
"SARL",
"agents",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L873-L884 |
57,175 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkContainerType | @Check
public void checkContainerType(SarlBehavior behavior) {
final XtendTypeDeclaration declaringType = behavior.getDeclaringType();
if (declaringType != null) {
final String name = canonicalName(declaringType);
assert name != null;
error(MessageFormat.format(Messages.SARLValidator_29, name),
behav... | java | @Check
public void checkContainerType(SarlBehavior behavior) {
final XtendTypeDeclaration declaringType = behavior.getDeclaringType();
if (declaringType != null) {
final String name = canonicalName(declaringType);
assert name != null;
error(MessageFormat.format(Messages.SARLValidator_29, name),
behav... | [
"@",
"Check",
"public",
"void",
"checkContainerType",
"(",
"SarlBehavior",
"behavior",
")",
"{",
"final",
"XtendTypeDeclaration",
"declaringType",
"=",
"behavior",
".",
"getDeclaringType",
"(",
")",
";",
"if",
"(",
"declaringType",
"!=",
"null",
")",
"{",
"final... | Check the container for the SARL behaviors.
@param behavior the behavior. | [
"Check",
"the",
"container",
"for",
"the",
"SARL",
"behaviors",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L890-L901 |
57,176 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkContainerType | @Check
public void checkContainerType(SarlCapacity capacity) {
final XtendTypeDeclaration declaringType = capacity.getDeclaringType();
if (declaringType != null) {
final String name = canonicalName(declaringType);
assert name != null;
error(MessageFormat.format(Messages.SARLValidator_30, name),
capac... | java | @Check
public void checkContainerType(SarlCapacity capacity) {
final XtendTypeDeclaration declaringType = capacity.getDeclaringType();
if (declaringType != null) {
final String name = canonicalName(declaringType);
assert name != null;
error(MessageFormat.format(Messages.SARLValidator_30, name),
capac... | [
"@",
"Check",
"public",
"void",
"checkContainerType",
"(",
"SarlCapacity",
"capacity",
")",
"{",
"final",
"XtendTypeDeclaration",
"declaringType",
"=",
"capacity",
".",
"getDeclaringType",
"(",
")",
";",
"if",
"(",
"declaringType",
"!=",
"null",
")",
"{",
"final... | Check the container for the SARL capacities.
@param capacity the capacity. | [
"Check",
"the",
"container",
"for",
"the",
"SARL",
"capacities",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L907-L918 |
57,177 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkContainerType | @Check
public void checkContainerType(SarlSkill skill) {
final XtendTypeDeclaration declaringType = skill.getDeclaringType();
if (declaringType != null) {
final String name = canonicalName(declaringType);
assert name != null;
error(MessageFormat.format(Messages.SARLValidator_31, name),
skill,
nu... | java | @Check
public void checkContainerType(SarlSkill skill) {
final XtendTypeDeclaration declaringType = skill.getDeclaringType();
if (declaringType != null) {
final String name = canonicalName(declaringType);
assert name != null;
error(MessageFormat.format(Messages.SARLValidator_31, name),
skill,
nu... | [
"@",
"Check",
"public",
"void",
"checkContainerType",
"(",
"SarlSkill",
"skill",
")",
"{",
"final",
"XtendTypeDeclaration",
"declaringType",
"=",
"skill",
".",
"getDeclaringType",
"(",
")",
";",
"if",
"(",
"declaringType",
"!=",
"null",
")",
"{",
"final",
"Str... | Check the container for the SARL skills.
@param skill the skill. | [
"Check",
"the",
"container",
"for",
"the",
"SARL",
"skills",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L924-L935 |
57,178 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkFinalFieldInitialization | @Check
public void checkFinalFieldInitialization(SarlEvent event) {
final JvmGenericType inferredType = this.associations.getInferredType(event);
if (inferredType != null) {
checkFinalFieldInitialization(inferredType);
}
} | java | @Check
public void checkFinalFieldInitialization(SarlEvent event) {
final JvmGenericType inferredType = this.associations.getInferredType(event);
if (inferredType != null) {
checkFinalFieldInitialization(inferredType);
}
} | [
"@",
"Check",
"public",
"void",
"checkFinalFieldInitialization",
"(",
"SarlEvent",
"event",
")",
"{",
"final",
"JvmGenericType",
"inferredType",
"=",
"this",
".",
"associations",
".",
"getInferredType",
"(",
"event",
")",
";",
"if",
"(",
"inferredType",
"!=",
"n... | Check if all the fields are initialized in a SARL event.
@param event the event. | [
"Check",
"if",
"all",
"the",
"fields",
"are",
"initialized",
"in",
"a",
"SARL",
"event",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L958-L964 |
57,179 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkFinalFieldInitialization | @Check
public void checkFinalFieldInitialization(SarlBehavior behavior) {
final JvmGenericType inferredType = this.associations.getInferredType(behavior);
if (inferredType != null) {
checkFinalFieldInitialization(inferredType);
}
} | java | @Check
public void checkFinalFieldInitialization(SarlBehavior behavior) {
final JvmGenericType inferredType = this.associations.getInferredType(behavior);
if (inferredType != null) {
checkFinalFieldInitialization(inferredType);
}
} | [
"@",
"Check",
"public",
"void",
"checkFinalFieldInitialization",
"(",
"SarlBehavior",
"behavior",
")",
"{",
"final",
"JvmGenericType",
"inferredType",
"=",
"this",
".",
"associations",
".",
"getInferredType",
"(",
"behavior",
")",
";",
"if",
"(",
"inferredType",
"... | Check if all the fields are initialized in a SARL behavior.
@param behavior the behavior. | [
"Check",
"if",
"all",
"the",
"fields",
"are",
"initialized",
"in",
"a",
"SARL",
"behavior",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L970-L976 |
57,180 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkFinalFieldInitialization | @Check
public void checkFinalFieldInitialization(SarlSkill skill) {
final JvmGenericType inferredType = this.associations.getInferredType(skill);
if (inferredType != null) {
checkFinalFieldInitialization(inferredType);
}
} | java | @Check
public void checkFinalFieldInitialization(SarlSkill skill) {
final JvmGenericType inferredType = this.associations.getInferredType(skill);
if (inferredType != null) {
checkFinalFieldInitialization(inferredType);
}
} | [
"@",
"Check",
"public",
"void",
"checkFinalFieldInitialization",
"(",
"SarlSkill",
"skill",
")",
"{",
"final",
"JvmGenericType",
"inferredType",
"=",
"this",
".",
"associations",
".",
"getInferredType",
"(",
"skill",
")",
";",
"if",
"(",
"inferredType",
"!=",
"n... | Check if all the fields are initialized in a SARL skill.
@param skill the skill. | [
"Check",
"if",
"all",
"the",
"fields",
"are",
"initialized",
"in",
"a",
"SARL",
"skill",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L982-L988 |
57,181 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkFinalFieldInitialization | @Check
public void checkFinalFieldInitialization(SarlAgent agent) {
final JvmGenericType inferredType = this.associations.getInferredType(agent);
if (inferredType != null) {
checkFinalFieldInitialization(inferredType);
}
} | java | @Check
public void checkFinalFieldInitialization(SarlAgent agent) {
final JvmGenericType inferredType = this.associations.getInferredType(agent);
if (inferredType != null) {
checkFinalFieldInitialization(inferredType);
}
} | [
"@",
"Check",
"public",
"void",
"checkFinalFieldInitialization",
"(",
"SarlAgent",
"agent",
")",
"{",
"final",
"JvmGenericType",
"inferredType",
"=",
"this",
".",
"associations",
".",
"getInferredType",
"(",
"agent",
")",
";",
"if",
"(",
"inferredType",
"!=",
"n... | Check if all the fields are initialized in a SARL agent.
@param agent the agent. | [
"Check",
"if",
"all",
"the",
"fields",
"are",
"initialized",
"in",
"a",
"SARL",
"agent",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L994-L1000 |
57,182 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkSuperConstructor | @SuppressWarnings({"checkstyle:cyclomaticcomplexity", "checkstyle:npathcomplexity", "checkstyle:nestedifdepth"})
protected void checkSuperConstructor(
XtendTypeDeclaration container,
EStructuralFeature feature,
Collection<ActionParameterTypes> defaultSignatures) {
final JvmDeclaredType jvmElement = this.ass... | java | @SuppressWarnings({"checkstyle:cyclomaticcomplexity", "checkstyle:npathcomplexity", "checkstyle:nestedifdepth"})
protected void checkSuperConstructor(
XtendTypeDeclaration container,
EStructuralFeature feature,
Collection<ActionParameterTypes> defaultSignatures) {
final JvmDeclaredType jvmElement = this.ass... | [
"@",
"SuppressWarnings",
"(",
"{",
"\"checkstyle:cyclomaticcomplexity\"",
",",
"\"checkstyle:npathcomplexity\"",
",",
"\"checkstyle:nestedifdepth\"",
"}",
")",
"protected",
"void",
"checkSuperConstructor",
"(",
"XtendTypeDeclaration",
"container",
",",
"EStructuralFeature",
"fe... | Check the super constructors.
@param container the container.
@param feature the syntactic feature related to the supertypes.
@param defaultSignatures the signatures of the default constructors for the given container. | [
"Check",
"the",
"super",
"constructors",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1008-L1079 |
57,183 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkForbiddenCalls | @Check(CheckType.FAST)
public void checkForbiddenCalls(XAbstractFeatureCall expression) {
if (this.featureCallValidator.isDisallowedCall(expression)) {
error(
MessageFormat.format(
Messages.SARLValidator_36,
expression.getFeature().getIdentifier()),
expression,
null,
ValidationMe... | java | @Check(CheckType.FAST)
public void checkForbiddenCalls(XAbstractFeatureCall expression) {
if (this.featureCallValidator.isDisallowedCall(expression)) {
error(
MessageFormat.format(
Messages.SARLValidator_36,
expression.getFeature().getIdentifier()),
expression,
null,
ValidationMe... | [
"@",
"Check",
"(",
"CheckType",
".",
"FAST",
")",
"public",
"void",
"checkForbiddenCalls",
"(",
"XAbstractFeatureCall",
"expression",
")",
"{",
"if",
"(",
"this",
".",
"featureCallValidator",
".",
"isDisallowedCall",
"(",
"expression",
")",
")",
"{",
"error",
... | Check if the call is forbidden.
<p>One example of a forbidden feature is {@link System#exit(int)}.
@param expression the expression. | [
"Check",
"if",
"the",
"call",
"is",
"forbidden",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1168-L1180 |
57,184 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkDiscouragedCalls | @Check(CheckType.FAST)
public void checkDiscouragedCalls(XAbstractFeatureCall expression) {
if (!isIgnored(DISCOURAGED_REFERENCE)
&& this.featureCallValidator.isDiscouragedCall(expression)) {
addIssue(
MessageFormat.format(Messages.SARLValidator_37,
expression.getConcreteSyntaxFeatureName()),
... | java | @Check(CheckType.FAST)
public void checkDiscouragedCalls(XAbstractFeatureCall expression) {
if (!isIgnored(DISCOURAGED_REFERENCE)
&& this.featureCallValidator.isDiscouragedCall(expression)) {
addIssue(
MessageFormat.format(Messages.SARLValidator_37,
expression.getConcreteSyntaxFeatureName()),
... | [
"@",
"Check",
"(",
"CheckType",
".",
"FAST",
")",
"public",
"void",
"checkDiscouragedCalls",
"(",
"XAbstractFeatureCall",
"expression",
")",
"{",
"if",
"(",
"!",
"isIgnored",
"(",
"DISCOURAGED_REFERENCE",
")",
"&&",
"this",
".",
"featureCallValidator",
".",
"isD... | Check if the call is discouraged.
<p>One example of a discouraged feature is {@link System#err}.
@param expression the expression. | [
"Check",
"if",
"the",
"call",
"is",
"discouraged",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1188-L1198 |
57,185 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkDefaultValueTypeCompatibleWithParameterType | @Check
public void checkDefaultValueTypeCompatibleWithParameterType(SarlFormalParameter param) {
final XExpression defaultValue = param.getDefaultValue();
if (defaultValue != null) {
final JvmTypeReference rawType = param.getParameterType();
assert rawType != null;
final LightweightTypeReference toType = ... | java | @Check
public void checkDefaultValueTypeCompatibleWithParameterType(SarlFormalParameter param) {
final XExpression defaultValue = param.getDefaultValue();
if (defaultValue != null) {
final JvmTypeReference rawType = param.getParameterType();
assert rawType != null;
final LightweightTypeReference toType = ... | [
"@",
"Check",
"public",
"void",
"checkDefaultValueTypeCompatibleWithParameterType",
"(",
"SarlFormalParameter",
"param",
")",
"{",
"final",
"XExpression",
"defaultValue",
"=",
"param",
".",
"getDefaultValue",
"(",
")",
";",
"if",
"(",
"defaultValue",
"!=",
"null",
"... | Check if the default values of the formal parameters have a compatible type with the formal parameter.
@param param the formal parameter to check. | [
"Check",
"if",
"the",
"default",
"values",
"of",
"the",
"formal",
"parameters",
"have",
"a",
"compatible",
"type",
"with",
"the",
"formal",
"parameter",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1204-L1247 |
57,186 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkDefaultValueFieldReference | @Check
public void checkDefaultValueFieldReference(SarlFormalParameter param) {
final XExpression defaultValue = param.getDefaultValue();
if (defaultValue != null) {
final Iterator<XFeatureCall> iter;
if (defaultValue instanceof XFeatureCall) {
iter = Iterators.singletonIterator((XFeatureCall) defaultVal... | java | @Check
public void checkDefaultValueFieldReference(SarlFormalParameter param) {
final XExpression defaultValue = param.getDefaultValue();
if (defaultValue != null) {
final Iterator<XFeatureCall> iter;
if (defaultValue instanceof XFeatureCall) {
iter = Iterators.singletonIterator((XFeatureCall) defaultVal... | [
"@",
"Check",
"public",
"void",
"checkDefaultValueFieldReference",
"(",
"SarlFormalParameter",
"param",
")",
"{",
"final",
"XExpression",
"defaultValue",
"=",
"param",
".",
"getDefaultValue",
"(",
")",
";",
"if",
"(",
"defaultValue",
"!=",
"null",
")",
"{",
"fin... | Check if the default values has not a reference to the not final fields.
@param param the formal parameter to check. | [
"Check",
"if",
"the",
"default",
"values",
"has",
"not",
"a",
"reference",
"to",
"the",
"not",
"final",
"fields",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1253-L1289 |
57,187 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkActionName | @Check(CheckType.FAST)
public void checkActionName(SarlAction action) {
final JvmOperation inferredType = this.associations.getDirectlyInferredOperation(action);
final QualifiedName name = QualifiedName.create(inferredType.getQualifiedName('.').split("\\.")); //$NON-NLS-1$
if (this.featureNames.isDisallowedName(... | java | @Check(CheckType.FAST)
public void checkActionName(SarlAction action) {
final JvmOperation inferredType = this.associations.getDirectlyInferredOperation(action);
final QualifiedName name = QualifiedName.create(inferredType.getQualifiedName('.').split("\\.")); //$NON-NLS-1$
if (this.featureNames.isDisallowedName(... | [
"@",
"Check",
"(",
"CheckType",
".",
"FAST",
")",
"public",
"void",
"checkActionName",
"(",
"SarlAction",
"action",
")",
"{",
"final",
"JvmOperation",
"inferredType",
"=",
"this",
".",
"associations",
".",
"getDirectlyInferredOperation",
"(",
"action",
")",
";",... | Check if the given action has a valid name.
@param action the action to test.
@see SARLFeatureNameValidator | [
"Check",
"if",
"the",
"given",
"action",
"has",
"a",
"valid",
"name",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1296-L1320 |
57,188 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkFieldName | @Check(CheckType.FAST)
public void checkFieldName(SarlField field) {
final JvmField inferredType = this.associations.getJvmField(field);
final QualifiedName name = Utils.getQualifiedName(inferredType);
if (this.featureNames.isDisallowedName(name)) {
final String validName = Utils.fixHiddenMember(field.getName... | java | @Check(CheckType.FAST)
public void checkFieldName(SarlField field) {
final JvmField inferredType = this.associations.getJvmField(field);
final QualifiedName name = Utils.getQualifiedName(inferredType);
if (this.featureNames.isDisallowedName(name)) {
final String validName = Utils.fixHiddenMember(field.getName... | [
"@",
"Check",
"(",
"CheckType",
".",
"FAST",
")",
"public",
"void",
"checkFieldName",
"(",
"SarlField",
"field",
")",
"{",
"final",
"JvmField",
"inferredType",
"=",
"this",
".",
"associations",
".",
"getJvmField",
"(",
"field",
")",
";",
"final",
"QualifiedN... | Check if the given field has a valid name.
@param field the field to test.
@see SARLFeatureNameValidator | [
"Check",
"if",
"the",
"given",
"field",
"has",
"a",
"valid",
"name",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1327-L1350 |
57,189 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkFieldNameShadowing | @Check
public void checkFieldNameShadowing(SarlField field) {
if (!isIgnored(VARIABLE_NAME_SHADOWING)
&& !Utils.isHiddenMember(field.getName())) {
final JvmField inferredField = this.associations.getJvmField(field);
final Map<String, JvmField> inheritedFields = new TreeMap<>();
Utils.populateInheritance... | java | @Check
public void checkFieldNameShadowing(SarlField field) {
if (!isIgnored(VARIABLE_NAME_SHADOWING)
&& !Utils.isHiddenMember(field.getName())) {
final JvmField inferredField = this.associations.getJvmField(field);
final Map<String, JvmField> inheritedFields = new TreeMap<>();
Utils.populateInheritance... | [
"@",
"Check",
"public",
"void",
"checkFieldNameShadowing",
"(",
"SarlField",
"field",
")",
"{",
"if",
"(",
"!",
"isIgnored",
"(",
"VARIABLE_NAME_SHADOWING",
")",
"&&",
"!",
"Utils",
".",
"isHiddenMember",
"(",
"field",
".",
"getName",
"(",
")",
")",
")",
"... | Check if the given field has a name that is shadowing an inherited field.
@param field the field to test. | [
"Check",
"if",
"the",
"given",
"field",
"has",
"a",
"name",
"that",
"is",
"shadowing",
"an",
"inherited",
"field",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1356-L1389 |
57,190 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkParameterName | @Check(CheckType.FAST)
public void checkParameterName(SarlFormalParameter parameter) {
if (this.grammarAccess.getOccurrenceKeyword().equals(parameter.getName())) {
error(MessageFormat.format(
Messages.SARLValidator_14,
this.grammarAccess.getOccurrenceKeyword()),
parameter,
XtendPackage.Literal... | java | @Check(CheckType.FAST)
public void checkParameterName(SarlFormalParameter parameter) {
if (this.grammarAccess.getOccurrenceKeyword().equals(parameter.getName())) {
error(MessageFormat.format(
Messages.SARLValidator_14,
this.grammarAccess.getOccurrenceKeyword()),
parameter,
XtendPackage.Literal... | [
"@",
"Check",
"(",
"CheckType",
".",
"FAST",
")",
"public",
"void",
"checkParameterName",
"(",
"SarlFormalParameter",
"parameter",
")",
"{",
"if",
"(",
"this",
".",
"grammarAccess",
".",
"getOccurrenceKeyword",
"(",
")",
".",
"equals",
"(",
"parameter",
".",
... | Check if the given parameter has a valid name.
@param parameter the parameter to test.
@see SARLFeatureNameValidator | [
"Check",
"if",
"the",
"given",
"parameter",
"has",
"a",
"valid",
"name",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1396-L1407 |
57,191 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkParameterName | @Check(CheckType.FAST)
public void checkParameterName(XVariableDeclaration variable) {
if (this.grammarAccess.getOccurrenceKeyword().equals(variable.getName())) {
error(MessageFormat.format(
Messages.SARLValidator_15,
this.grammarAccess.getOccurrenceKeyword()),
variable,
XbasePackage.Literals.... | java | @Check(CheckType.FAST)
public void checkParameterName(XVariableDeclaration variable) {
if (this.grammarAccess.getOccurrenceKeyword().equals(variable.getName())) {
error(MessageFormat.format(
Messages.SARLValidator_15,
this.grammarAccess.getOccurrenceKeyword()),
variable,
XbasePackage.Literals.... | [
"@",
"Check",
"(",
"CheckType",
".",
"FAST",
")",
"public",
"void",
"checkParameterName",
"(",
"XVariableDeclaration",
"variable",
")",
"{",
"if",
"(",
"this",
".",
"grammarAccess",
".",
"getOccurrenceKeyword",
"(",
")",
".",
"equals",
"(",
"variable",
".",
... | Check if the given local variable has a valid name.
@param variable the variable to test.
@see SARLFeatureNameValidator | [
"Check",
"if",
"the",
"given",
"local",
"variable",
"has",
"a",
"valid",
"name",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1414-L1425 |
57,192 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkRedundantImplementedInterfaces | @Check
public void checkRedundantImplementedInterfaces(SarlSkill skill) {
checkRedundantInterfaces(
skill,
SARL_SKILL__IMPLEMENTS,
skill.getImplements(),
Utils.singletonList(skill.getExtends()));
} | java | @Check
public void checkRedundantImplementedInterfaces(SarlSkill skill) {
checkRedundantInterfaces(
skill,
SARL_SKILL__IMPLEMENTS,
skill.getImplements(),
Utils.singletonList(skill.getExtends()));
} | [
"@",
"Check",
"public",
"void",
"checkRedundantImplementedInterfaces",
"(",
"SarlSkill",
"skill",
")",
"{",
"checkRedundantInterfaces",
"(",
"skill",
",",
"SARL_SKILL__IMPLEMENTS",
",",
"skill",
".",
"getImplements",
"(",
")",
",",
"Utils",
".",
"singletonList",
"("... | Check if implemented interfaces of a skill are redundant.
@param skill the skill. | [
"Check",
"if",
"implemented",
"interfaces",
"of",
"a",
"skill",
"are",
"redundant",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1599-L1606 |
57,193 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkRedundantImplementedInterfaces | @Check
public void checkRedundantImplementedInterfaces(SarlClass xtendClass) {
checkRedundantInterfaces(
xtendClass,
XTEND_CLASS__IMPLEMENTS,
xtendClass.getImplements(),
Utils.singletonList(xtendClass.getExtends()));
} | java | @Check
public void checkRedundantImplementedInterfaces(SarlClass xtendClass) {
checkRedundantInterfaces(
xtendClass,
XTEND_CLASS__IMPLEMENTS,
xtendClass.getImplements(),
Utils.singletonList(xtendClass.getExtends()));
} | [
"@",
"Check",
"public",
"void",
"checkRedundantImplementedInterfaces",
"(",
"SarlClass",
"xtendClass",
")",
"{",
"checkRedundantInterfaces",
"(",
"xtendClass",
",",
"XTEND_CLASS__IMPLEMENTS",
",",
"xtendClass",
".",
"getImplements",
"(",
")",
",",
"Utils",
".",
"singl... | Check if implemented interfaces of a Xtend Class are redundant.
@param xtendClass the class. | [
"Check",
"if",
"implemented",
"interfaces",
"of",
"a",
"Xtend",
"Class",
"are",
"redundant",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1612-L1619 |
57,194 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkRedundantImplementedInterfaces | @Check
public void checkRedundantImplementedInterfaces(SarlInterface xtendInterface) {
checkRedundantInterfaces(
xtendInterface,
XTEND_INTERFACE__EXTENDS,
xtendInterface.getExtends(),
Collections.<JvmTypeReference>emptyList());
} | java | @Check
public void checkRedundantImplementedInterfaces(SarlInterface xtendInterface) {
checkRedundantInterfaces(
xtendInterface,
XTEND_INTERFACE__EXTENDS,
xtendInterface.getExtends(),
Collections.<JvmTypeReference>emptyList());
} | [
"@",
"Check",
"public",
"void",
"checkRedundantImplementedInterfaces",
"(",
"SarlInterface",
"xtendInterface",
")",
"{",
"checkRedundantInterfaces",
"(",
"xtendInterface",
",",
"XTEND_INTERFACE__EXTENDS",
",",
"xtendInterface",
".",
"getExtends",
"(",
")",
",",
"Collectio... | Check if implemented interfaces of a Xtend Interface are redundant.
@param xtendInterface the interface. | [
"Check",
"if",
"implemented",
"interfaces",
"of",
"a",
"Xtend",
"Interface",
"are",
"redundant",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1625-L1632 |
57,195 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkBehaviorUnitGuardType | @Check(CheckType.FAST)
public void checkBehaviorUnitGuardType(SarlBehaviorUnit behaviorUnit) {
final XExpression guard = behaviorUnit.getGuard();
if (guard != null) {
if (this.operationHelper.hasSideEffects(null, guard)) {
error(Messages.SARLValidator_53,
guard,
null,
ValidationMessageAcce... | java | @Check(CheckType.FAST)
public void checkBehaviorUnitGuardType(SarlBehaviorUnit behaviorUnit) {
final XExpression guard = behaviorUnit.getGuard();
if (guard != null) {
if (this.operationHelper.hasSideEffects(null, guard)) {
error(Messages.SARLValidator_53,
guard,
null,
ValidationMessageAcce... | [
"@",
"Check",
"(",
"CheckType",
".",
"FAST",
")",
"public",
"void",
"checkBehaviorUnitGuardType",
"(",
"SarlBehaviorUnit",
"behaviorUnit",
")",
"{",
"final",
"XExpression",
"guard",
"=",
"behaviorUnit",
".",
"getGuard",
"(",
")",
";",
"if",
"(",
"guard",
"!=",... | Check the type of the behavior unit's guard.
@param behaviorUnit the behavior unit. | [
"Check",
"the",
"type",
"of",
"the",
"behavior",
"unit",
"s",
"guard",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1638-L1682 |
57,196 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkCapacityTypeForUses | @Check(CheckType.FAST)
public void checkCapacityTypeForUses(SarlCapacityUses uses) {
for (final JvmParameterizedTypeReference usedType : uses.getCapacities()) {
final LightweightTypeReference ref = toLightweightTypeReference(usedType);
if (ref != null && !this.inheritanceHelper.isSarlCapacity(ref)) {
error... | java | @Check(CheckType.FAST)
public void checkCapacityTypeForUses(SarlCapacityUses uses) {
for (final JvmParameterizedTypeReference usedType : uses.getCapacities()) {
final LightweightTypeReference ref = toLightweightTypeReference(usedType);
if (ref != null && !this.inheritanceHelper.isSarlCapacity(ref)) {
error... | [
"@",
"Check",
"(",
"CheckType",
".",
"FAST",
")",
"public",
"void",
"checkCapacityTypeForUses",
"(",
"SarlCapacityUses",
"uses",
")",
"{",
"for",
"(",
"final",
"JvmParameterizedTypeReference",
"usedType",
":",
"uses",
".",
"getCapacities",
"(",
")",
")",
"{",
... | Check the type of the capacity uses.
@param uses the capacity uses. | [
"Check",
"the",
"type",
"of",
"the",
"capacity",
"uses",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1688-L1705 |
57,197 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkActionFires | @Check(CheckType.FAST)
public void checkActionFires(SarlAction action) {
for (final JvmTypeReference event : action.getFiredEvents()) {
final LightweightTypeReference ref = toLightweightTypeReference(event);
if (ref != null && !this.inheritanceHelper.isSarlEvent(ref)) {
error(MessageFormat.format(
Me... | java | @Check(CheckType.FAST)
public void checkActionFires(SarlAction action) {
for (final JvmTypeReference event : action.getFiredEvents()) {
final LightweightTypeReference ref = toLightweightTypeReference(event);
if (ref != null && !this.inheritanceHelper.isSarlEvent(ref)) {
error(MessageFormat.format(
Me... | [
"@",
"Check",
"(",
"CheckType",
".",
"FAST",
")",
"public",
"void",
"checkActionFires",
"(",
"SarlAction",
"action",
")",
"{",
"for",
"(",
"final",
"JvmTypeReference",
"event",
":",
"action",
".",
"getFiredEvents",
"(",
")",
")",
"{",
"final",
"LightweightTy... | Check the types of the parameters of the "fires" statement.
@param action the signature that contains the "fires" statement. | [
"Check",
"the",
"types",
"of",
"the",
"parameters",
"of",
"the",
"fires",
"statement",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1711-L1728 |
57,198 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkSuperTypes | @Check(CheckType.FAST)
public void checkSuperTypes(SarlCapacity capacity) {
checkSuperTypes(
capacity,
SARL_CAPACITY__EXTENDS,
capacity.getExtends(),
Capacity.class,
false);
} | java | @Check(CheckType.FAST)
public void checkSuperTypes(SarlCapacity capacity) {
checkSuperTypes(
capacity,
SARL_CAPACITY__EXTENDS,
capacity.getExtends(),
Capacity.class,
false);
} | [
"@",
"Check",
"(",
"CheckType",
".",
"FAST",
")",
"public",
"void",
"checkSuperTypes",
"(",
"SarlCapacity",
"capacity",
")",
"{",
"checkSuperTypes",
"(",
"capacity",
",",
"SARL_CAPACITY__EXTENDS",
",",
"capacity",
".",
"getExtends",
"(",
")",
",",
"Capacity",
... | Check if the supertype of the given capacity is a subtype of Capacity.
@param capacity the type to test. | [
"Check",
"if",
"the",
"supertype",
"of",
"the",
"given",
"capacity",
"is",
"a",
"subtype",
"of",
"Capacity",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1838-L1846 |
57,199 | sarl/sarl | main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java | SARLValidator.checkSuperType | @Check(CheckType.FAST)
public void checkSuperType(SarlSkill skill) {
final int nbSuperTypes = checkSuperTypes(
skill,
SARL_SKILL__EXTENDS,
Utils.singletonList(skill.getExtends()),
Skill.class,
false);
checkImplementedTypes(
skill,
SARL_SKILL__IMPLEMENTS,
skill.getImplements(),
C... | java | @Check(CheckType.FAST)
public void checkSuperType(SarlSkill skill) {
final int nbSuperTypes = checkSuperTypes(
skill,
SARL_SKILL__EXTENDS,
Utils.singletonList(skill.getExtends()),
Skill.class,
false);
checkImplementedTypes(
skill,
SARL_SKILL__IMPLEMENTS,
skill.getImplements(),
C... | [
"@",
"Check",
"(",
"CheckType",
".",
"FAST",
")",
"public",
"void",
"checkSuperType",
"(",
"SarlSkill",
"skill",
")",
"{",
"final",
"int",
"nbSuperTypes",
"=",
"checkSuperTypes",
"(",
"skill",
",",
"SARL_SKILL__EXTENDS",
",",
"Utils",
".",
"singletonList",
"("... | Check if the supertype of the given skill is a subtype of Skill.
@param skill the type to test. | [
"Check",
"if",
"the",
"supertype",
"of",
"the",
"given",
"skill",
"is",
"a",
"subtype",
"of",
"Skill",
"."
] | ca00ff994598c730339972def4e19a60e0b8cace | https://github.com/sarl/sarl/blob/ca00ff994598c730339972def4e19a60e0b8cace/main/coreplugins/io.sarl.lang/src/io/sarl/lang/validation/SARLValidator.java#L1852-L1867 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.