Greet 2014
Documentation for the GREET 2014 API
 All Classes Namespaces Functions Variables Enumerations Properties Events
Greet.DataStructureV3.Interfaces.APlugin Class Referenceabstract

Abstact class to implement in order to be loaded in GREET as a plugin More...

Public Member Functions

virtual string[] AvailableCommandsForThisPlugin ()
 Returns a list of the available command names for this plugin that can be called using the command line More...
 
virtual ToolStripMenuItem[] GetMainMenuItems ()
 A collection of tool strip menu items that will be added to the existing main menu of the GREET main form or null More...
 
virtual ToolStripMenuItem[] GetMixMenuItems (int mixID)
 A collection of menu items that will be added to the context menus shown for a mix or null More...
 
virtual MenuItem[] GetParameterMenuItems (IParameter parameter)
 Called when a parameter is right clicked in order to add items to the existing menu Parameter ID represents a unique ID for the selected parameter More...
 
virtual ToolStripMenuItem[] GetPathwayMenuItems (int pathwayID)
 A collection of menu items that will be added to the context menus shown for a pathway or null More...
 
virtual ToolStripMenuItem[] GetProcessMenuItems (int processID)
 A collection of menu items that will be added to the context menus shown for a process (stationary or transportation) or null More...
 
virtual ToolStripMenuItem[] GetVehiclesMenuItems (int vehicleID)
 A collection of menu items that will be added to the context menus shown for a vehicle or null More...
 
abstract bool InitializePlugin (IGREETController controler)
 Initialize the default parameters for the plugin More...
 
virtual void onControlClicked (object sender, EventArgs e)
 Raised when one of the supported controls raises a Click event More...
 
virtual void onControlKeyPressed (object sender, System.Windows.Forms.KeyPressEventArgs e)
 Raised when one of the supported controls raises a KeyPress event More...
 
virtual void onControlLeave (object sender, EventArgs e)
 Raised when one of the supported controls raises a Leave event More...
 
virtual void onControlPaint (object sender, System.Windows.Forms.PaintEventArgs e, object content)
 Raised when one of the supported controls raises a Paint event More...
 
virtual void onDatabaseLoaded (string filename)
 Called when a database is loaded by the user or automatically after an update. Method is called after the database is loaded into GREET. More...
 
virtual void onDatabaseUpdate (string updateFile)
 Called when a new file is available after the user manually checked for updates or the automatic check detected that new database was available. Method is called right after the downloaded file is saved in some folder More...
 
virtual void onFinalizePlugin ()
 Called when GREET main routine ends. This is the last call before everything gets unallocated from the memory At this points the Main form no longer exists More...
 
virtual void onMainFormClosing ()
 Called when the main form is closing, just before we check for any data changes in loaded the database More...
 
virtual void onSaveActionRequired ()
 Called when the user clicks File->Save, File->Save As or when he hits Ctrl+S in the main user interface. More...
 
virtual bool RunCommand (string command, string[] args)
 Asks the plugin to run the specified command and return True if the execution was done properly More...
 

Properties

abstract string GetPluginDescription [get]
 Short description of the plugin with a possible link to a specific website More...
 
abstract Image GetPluginIcon [get]
 Icon to be used in the plugin manager More...
 
virtual Stack< String > GetPluginMessages [get]
 Messages that the plugins stacks to be displayed by the main form More...
 
abstract string GetPluginName [get]
 Name of the plugin that will be used in the plugin manager More...
 
abstract string GetPluginVersion [get]
 Version of the plugin More...
 

Detailed Description

Abstact class to implement in order to be loaded in GREET as a plugin

Member Function Documentation

virtual string [] Greet.DataStructureV3.Interfaces.APlugin.AvailableCommandsForThisPlugin ( )
virtual

Returns a list of the available command names for this plugin that can be called using the command line

Returns
virtual ToolStripMenuItem [] Greet.DataStructureV3.Interfaces.APlugin.GetMainMenuItems ( )
virtual

A collection of tool strip menu items that will be added to the existing main menu of the GREET main form or null

Returns
Array of menu items to be displayed
virtual ToolStripMenuItem [] Greet.DataStructureV3.Interfaces.APlugin.GetMixMenuItems ( int  mixID)
virtual

A collection of menu items that will be added to the context menus shown for a mix or null

Returns
Array of menu items to be displayed
virtual MenuItem [] Greet.DataStructureV3.Interfaces.APlugin.GetParameterMenuItems ( IParameter  parameter)
virtual

Called when a parameter is right clicked in order to add items to the existing menu Parameter ID represents a unique ID for the selected parameter

Parameters
parameterParameter that is beeing clicked
Returns
Array of menu items to be displayed
virtual ToolStripMenuItem [] Greet.DataStructureV3.Interfaces.APlugin.GetPathwayMenuItems ( int  pathwayID)
virtual

A collection of menu items that will be added to the context menus shown for a pathway or null

Returns
Array of menu items to be displayed
virtual ToolStripMenuItem [] Greet.DataStructureV3.Interfaces.APlugin.GetProcessMenuItems ( int  processID)
virtual

A collection of menu items that will be added to the context menus shown for a process (stationary or transportation) or null

Returns
Array of menu items to be displayed
virtual ToolStripMenuItem [] Greet.DataStructureV3.Interfaces.APlugin.GetVehiclesMenuItems ( int  vehicleID)
virtual

A collection of menu items that will be added to the context menus shown for a vehicle or null

Returns
Array of menu items to be displayed
abstract bool Greet.DataStructureV3.Interfaces.APlugin.InitializePlugin ( IGREETController  controler)
pure virtual

Initialize the default parameters for the plugin

Returns
True if the initialization was done correctly
virtual void Greet.DataStructureV3.Interfaces.APlugin.onControlClicked ( object  sender,
EventArgs  e 
)
virtual

Raised when one of the supported controls raises a Click event

Parameters
sender
e
virtual void Greet.DataStructureV3.Interfaces.APlugin.onControlKeyPressed ( object  sender,
System.Windows.Forms.KeyPressEventArgs  e 
)
virtual

Raised when one of the supported controls raises a KeyPress event

Parameters
sender
e
virtual void Greet.DataStructureV3.Interfaces.APlugin.onControlLeave ( object  sender,
EventArgs  e 
)
virtual

Raised when one of the supported controls raises a Leave event

Parameters
sender
e
virtual void Greet.DataStructureV3.Interfaces.APlugin.onControlPaint ( object  sender,
System.Windows.Forms.PaintEventArgs  e,
object  content 
)
virtual

Raised when one of the supported controls raises a Paint event

Parameters
sender
e
contentPossibly the object that is currently represented within the sender control
virtual void Greet.DataStructureV3.Interfaces.APlugin.onDatabaseLoaded ( string  filename)
virtual

Called when a database is loaded by the user or automatically after an update. Method is called after the database is loaded into GREET.

virtual void Greet.DataStructureV3.Interfaces.APlugin.onDatabaseUpdate ( string  updateFile)
virtual

Called when a new file is available after the user manually checked for updates or the automatic check detected that new database was available. Method is called right after the downloaded file is saved in some folder

Parameters
updateFileThe location of the new file downloaded by the automated process
virtual void Greet.DataStructureV3.Interfaces.APlugin.onFinalizePlugin ( )
virtual

Called when GREET main routine ends. This is the last call before everything gets unallocated from the memory At this points the Main form no longer exists

Returns
virtual void Greet.DataStructureV3.Interfaces.APlugin.onMainFormClosing ( )
virtual

Called when the main form is closing, just before we check for any data changes in loaded the database

virtual void Greet.DataStructureV3.Interfaces.APlugin.onSaveActionRequired ( )
virtual

Called when the user clicks File->Save, File->Save As or when he hits Ctrl+S in the main user interface.

This is called just before we save all the data to the XML file, so it's a good time to push your plugin XML node to the project or to save the data you need to save

Important, this may also be called before an Autosave or if an other plugin asks the IGREETController to save data to a given file

virtual bool Greet.DataStructureV3.Interfaces.APlugin.RunCommand ( string  command,
string[]  args 
)
virtual

Asks the plugin to run the specified command and return True if the execution was done properly

Parameters
commandThe comannd that the plugin needs to run
argsThe arguments for that command
Returns
True if the command runs wellm false otherwise

Property Documentation

abstract string Greet.DataStructureV3.Interfaces.APlugin.GetPluginDescription
get

Short description of the plugin with a possible link to a specific website

abstract Image Greet.DataStructureV3.Interfaces.APlugin.GetPluginIcon
get

Icon to be used in the plugin manager

virtual Stack<String> Greet.DataStructureV3.Interfaces.APlugin.GetPluginMessages
get

Messages that the plugins stacks to be displayed by the main form

abstract string Greet.DataStructureV3.Interfaces.APlugin.GetPluginName
get

Name of the plugin that will be used in the plugin manager

abstract string Greet.DataStructureV3.Interfaces.APlugin.GetPluginVersion
get

Version of the plugin


The documentation for this class was generated from the following file: