Package jason.infra.local
Class RunLocalMAS
java.lang.Object
javax.management.NotificationBroadcasterSupport
jason.infra.local.BaseLocalMAS
jason.infra.local.RunLocalMAS
- All Implemented Interfaces:
RunLocalMASMBean
,NotificationBroadcaster
,NotificationEmitter
- Direct Known Subclasses:
RunJadeMAS
Runs MASProject using *Local* infrastructure.
-
Nested Class Summary
Modifier and TypeClassDescriptionprotected final class
an agent architecture for the infra based on thread pool -
Field Summary
Modifier and TypeFieldDescriptionprotected List
<LocalAgArch> protected boolean
protected AtomicBoolean
protected static Logger
static final String
static final String
Fields inherited from class jason.infra.local.BaseLocalMAS
ags, appFromClassPath, control, debug, defaultProjectFileName, dfAg, env, logPropFile, project, runner, stopMASFileName
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addInitArg
(String k, Object v) protected void
change the current running MAS to debug modevoid
create()
create environment, agents, controllerprotected void
protected void
protected void
protected void
protected void
protected void
protected void
void
void
finish
(int deadline, boolean stopJVM, int exitValue) protected InputStream
static File
boolean
int
boolean
boolean
static void
protected void
protected void
protected void
protected void
protected void
void
void
setupLogger
(String confFile) void
start()
start agents, ....protected void
startAgs()
protected void
protected void
stopAgs
(int deadline) void
storeRunningMASInCommonFile
(String masName, String address) void
waitEnd()
Methods inherited from class jason.infra.local.BaseLocalMAS
addAg, delAg, dfAgExists, dfDeRegister, dfRegister, dfSearch, dfSubscribe, finish, getAg, getAgs, getControllerInfraTier, getDF, getDFAg, getDFAgArch, getEnvironmentInfraTier, getNbAgents, getProject, getRunner, getRuntimeServices, getSubscribers, getWP, isDebug, sendProvider, setProject, setRuntimeServices
Methods inherited from class javax.management.NotificationBroadcasterSupport
addNotificationListener, getNotificationInfo, handleNotification, removeNotificationListener, removeNotificationListener, sendNotification
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface jason.infra.local.RunLocalMASMBean
getNbAgents
-
Field Details
-
logger
-
isRunning
protected boolean isRunning -
createdAgents
-
initArgs
-
RMI_PREFIX_RTS
- See Also:
-
RUNNING_MAS_FILE_NAME
- See Also:
-
isRunningFinish
-
-
Constructor Details
-
RunLocalMAS
public RunLocalMAS()
-
-
Method Details
-
hasDebugControl
public boolean hasDebugControl()- Specified by:
hasDebugControl
in classBaseLocalMAS
-
enableDebugControl
public void enableDebugControl()- Specified by:
enableDebugControl
in classBaseLocalMAS
-
main
- Throws:
JasonException
-
registerMBean
protected void registerMBean() -
registerWebMindInspector
protected void registerWebMindInspector() -
addInitArg
-
init
-
parseArgs
-
registerInRMI
protected void registerInRMI() -
getRunningMASFile
-
storeRunningMASInCommonFile
-
create
create environment, agents, controller- Throws:
JasonException
-
start
public void start()start agents, .... -
isRunning
public boolean isRunning()- Specified by:
isRunning
in classBaseLocalMAS
-
setupLogger
public void setupLogger()- Specified by:
setupLogger
in classBaseLocalMAS
-
setupLogger
-
getDefaultLogProperties
- Throws:
IOException
-
setupDefaultConsoleLogger
protected void setupDefaultConsoleLogger() -
createButtons
protected void createButtons() -
createPauseButton
protected void createPauseButton() -
createStopButton
protected void createStopButton() -
createNewReplAgButton
protected void createNewReplAgButton() -
createEnvironment
- Throws:
JasonException
-
createAgs
- Throws:
JasonException
-
createController
- Throws:
JasonException
-
startAgs
protected void startAgs() -
stopAgs
protected void stopAgs(int deadline) -
killAg
- Specified by:
killAg
in interfaceRunLocalMASMBean
-
changeToDebugMode
protected void changeToDebugMode()change the current running MAS to debug mode -
startSyncMode
protected void startSyncMode() -
waitEnd
public void waitEnd() -
finish
public void finish(int deadline, boolean stopJVM, int exitValue) - Specified by:
finish
in interfaceRunLocalMASMBean
- Specified by:
finish
in classBaseLocalMAS
-