HomeForumSourceResearchGuide
Sign in to contribute to source.
Type definition file .System by barry
expand copy to clipboardexpand
/*
{"description" : "This interface is provided by the Dana runtime and can be used to get a range of information about the Dana runtime environment (but not information about the host OS)."}
*/

uses data.String

data PlatformInfo {
	char osCode[]
	char chipCode[]
}

interface System {
	/* {"@description" : "Get the VM's 'type' code, which must match the object type information of loaded components."} */
	byte[] getVMType()
	
	/* {"@description" : "Get the VM's 'host' code, which must match the object type information of loaded components."} */
	byte[] getHostType()
	
	/* {"@description" : "Get the VM's version number."} */
	int getVersion()

	/* {"@description" : "Host platform identifier codes."} */
	PlatformInfo getPlatform()

	/* {"@description" : "Get the VM's native library API version number."} */
	int getLibAPIVersion()

	/* {"@description" : "Get the language platform's version number. These are major releases."} */
	int getFrameworkVersion()
	
	/* {"@description" : "Get the install directory of Dana (affected e.g. by the -dh parameter, or the DANA_HOME environment variable). It is always better to use this function instead of directly reading environment variables."} */
	char[] getDanaHome()
	
	/* {"@description" : "Get the list of search paths used by the Dana virtual machine when looking for components (affected e.g. by the -sp parameter)."} */
	String[] getSearchPaths()
	
	/* {"@description" : "Get the list of required interfaces (including package paths) that the virtual machine will automatically wire (to itself)."} */
	String[] getAutoBindings()
	}
Revision history
To propose a new revision to this entity, use dana source put -ut your/new/version.dn -n System.System -m "reason for update" -u yourUsername
Version 1 (this version) by barry
Notes for this version: Standard Library Initialisation