Class ProjectCommandLineAction

  • All Implemented Interfaces:
    CommandLineAction

    @OpenApiAll
    public abstract class ProjectCommandLineAction
    extends java.lang.Object
    implements CommandLineAction
    This class contains general methods (open, close project, read command line properties, connect to server, etc) related to project in command line for plugins Override execute(String[], Properties, Project)
    Arguments are specified as name=value pairs.
    Default arguments that will be used to try and open project:
    • project - Project name or path
    • projectDescriptor - Project descriptor
    • server - Server url
    • username - Username on server
    • password - Password for provided username
    • enableSSL - To use ssl
    • encryptPassword - Set true if provided password is in plain text
    • properties - Path to properties file containing properties. Multiple properties files can be provided "properties=prop1.properties;prop2.properties"
    • projectPassword - Project password
    • version - Project version
    • branch - Project branch
    • useDefaultPropertyValidation - set false to disable validation of default properties
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      byte execute​(java.lang.String[] args)
      Implement this method to execute custom task in running MagicDraw application environment.
      protected abstract byte execute​(java.lang.String[] args, java.util.Properties properties, Project project)
      Override this method to execute your custom task(s) in running MagicDraw environment on opened project.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ProjectCommandLineAction

        public ProjectCommandLineAction()
    • Method Detail

      • execute

        public final byte execute​(java.lang.String[] args)
        Description copied from interface: CommandLineAction
        Implement this method to execute custom task in running MagicDraw application environment.
        Specified by:
        execute in interface CommandLineAction
        Returns:
        application exit status.
      • execute

        protected abstract byte execute​(java.lang.String[] args,
                                        java.util.Properties properties,
                                        Project project)
        Override this method to execute your custom task(s) in running MagicDraw environment on opened project.
        Parameters:
        args - arguments environment was started with
        properties - parsed arguments for this project
        project - project opened based on provided arguments
        Returns:
        application exit status (default is 0).