Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
gs-gama
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Incidents
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
graphstream
gs-gama
Commits
66280f79
Commit
66280f79
authored
Feb 10, 2014
by
Thibaut Démare
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add the 'clear receivers' command
parent
d917f604
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
31 additions
and
0 deletions
+31
-0
src/org/graphstream/gama/extension/IKeywordGSAdditional.java
src/org/graphstream/gama/extension/IKeywordGSAdditional.java
+1
-0
src/org/graphstream/gama/extension/receiver/ClearReceiversStatement.java
...ream/gama/extension/receiver/ClearReceiversStatement.java
+30
-0
No files found.
src/org/graphstream/gama/extension/IKeywordGSAdditional.java
View file @
66280f79
...
...
@@ -22,6 +22,7 @@ public class IKeywordGSAdditional implements IKeyword {
public
static
final
String
STEP
=
"gs_step"
;
//Receiver command
public
static
final
String
ADD_RECEIVER
=
"gs_add_receiver"
;
public
static
final
String
CLEAR_RECEIVERS
=
"gs_clear_receivers"
;
public
static
final
String
GET_EDGE_ATTRIBUTE
=
"gs_get_edge_attribute"
;
public
static
final
String
GET_NODE_ATTRIBUTE
=
"gs_get_node_attribute"
;
public
static
final
String
GET_GRAPH_ATTRIBUTE
=
"gs_get_graph_attribute"
;
...
...
src/org/graphstream/gama/extension/receiver/ClearReceiversStatement.java
0 → 100644
View file @
66280f79
package
org.graphstream.gama.extension.receiver
;
import
msi.gama.precompiler.ISymbolKind
;
import
msi.gama.precompiler.GamlAnnotations.inside
;
import
msi.gama.precompiler.GamlAnnotations.symbol
;
import
msi.gama.runtime.IScope
;
import
msi.gama.runtime.exceptions.GamaRuntimeException
;
import
msi.gaml.descriptions.IDescription
;
import
msi.gaml.statements.AbstractStatement
;
import
msi.gaml.statements.IStatement
;
import
org.graphstream.gama.extension.GSManager
;
import
org.graphstream.gama.extension.IKeywordGSAdditional
;
@symbol
(
name
=
IKeywordGSAdditional
.
CLEAR_RECEIVERS
,
kind
=
ISymbolKind
.
SINGLE_STATEMENT
,
with_sequence
=
false
)
@inside
(
kinds
=
{
ISymbolKind
.
BEHAVIOR
,
ISymbolKind
.
SINGLE_STATEMENT
})
public
class
ClearReceiversStatement
extends
AbstractStatement
implements
IStatement
{
public
ClearReceiversStatement
(
IDescription
desc
)
{
super
(
desc
);
}
@Override
protected
Object
privateExecuteIn
(
IScope
scope
)
throws
GamaRuntimeException
{
GSManager
.
clearReceivers
();
return
null
;
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment