Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "Custom Artifact Metadata"

m (New page: {{backlink|Tigerstripe Extension Points}} *Full name : org.eclipse.tigerstripe.metamodel.customArtifactMetadata Purpose : This extension point is designed to allow users to override or ...)
 
 
(One intermediate revision by one other user not shown)
Line 3: Line 3:
 
*Full name : org.eclipse.tigerstripe.metamodel.customArtifactMetadata  
 
*Full name : org.eclipse.tigerstripe.metamodel.customArtifactMetadata  
  
Purpose : This extension point is designed to allow users to override or specify additional metadata that is used buy the Tigerstripe explorer and other componenets of the UI.
+
Purpose : This extension point is designed to allow users to override or specify additional metadata that is used by the Tigerstripe explorer and other components of the UI.
  
 
*Usage :
 
*Usage :
The extension point supports any number of new rules, each of which has 2 attributes
+
 
 +
There are three separate elements that can be provided :
 +
 
 +
''artifactIcon'' : Here you can override the icon that is used for a "standard" artifact. For each artifactType, eg "IEnumArtifact", you can specify the "normal" icon, and the "greyed out" icon (these are used when an artifact is outsode the scope of a facet). The "new" Icon that can be specified is ignored by the platform as this has been superceded by the creationPatterns extension point.
 +
 
 +
''modelComponentIconProvider'' : Here you can define a custom dynamic icon provider for a specific type of Artifact. For example this can be used to change the appearance of an artifact icon based on annotations. For each artifact type, eg "IEnumArtifact", you can specify a provider. The provider must implement the Interface :
 +
 
 +
org.eclipse.tigerstripe.repository.metamodel.providers.IModelComponentIconProvider
 +
 
 +
Only two methods need to be implmemented : getIconURL(Object context), and getGreyedoutIconURL(Object context). The methods refering to creationTool are obsolete (as above). The implementation of these methods would typically cast the object to the appropriate artifactType and examine the structure of the artifact (eg examine sterotypes) to determine the icon to use. If any method returns null, then the default icon will be used. In this case the default may alreday have been overriden if the above part of the ext pt is used.
 +
 
 +
(You could use this part of the ext point to achieve the same ends as the previous "artifactIcon" section, but this should only be used if the behaviour is complex as there is a (small) overhead involved in examining the structure of the artifact.)
 +
 
 +
''artifactMetadata'' : This element is for future use and is not currently implemented.

Latest revision as of 10:30, 1 April 2011

< To: Tigerstripe Extension Points

  • Full name : org.eclipse.tigerstripe.metamodel.customArtifactMetadata

Purpose : This extension point is designed to allow users to override or specify additional metadata that is used by the Tigerstripe explorer and other components of the UI.

  • Usage :

There are three separate elements that can be provided :

artifactIcon : Here you can override the icon that is used for a "standard" artifact. For each artifactType, eg "IEnumArtifact", you can specify the "normal" icon, and the "greyed out" icon (these are used when an artifact is outsode the scope of a facet). The "new" Icon that can be specified is ignored by the platform as this has been superceded by the creationPatterns extension point.

modelComponentIconProvider : Here you can define a custom dynamic icon provider for a specific type of Artifact. For example this can be used to change the appearance of an artifact icon based on annotations. For each artifact type, eg "IEnumArtifact", you can specify a provider. The provider must implement the Interface :

org.eclipse.tigerstripe.repository.metamodel.providers.IModelComponentIconProvider

Only two methods need to be implmemented : getIconURL(Object context), and getGreyedoutIconURL(Object context). The methods refering to creationTool are obsolete (as above). The implementation of these methods would typically cast the object to the appropriate artifactType and examine the structure of the artifact (eg examine sterotypes) to determine the icon to use. If any method returns null, then the default icon will be used. In this case the default may alreday have been overriden if the above part of the ext pt is used.

(You could use this part of the ext point to achieve the same ends as the previous "artifactIcon" section, but this should only be used if the behaviour is complex as there is a (small) overhead involved in examining the structure of the artifact.)

artifactMetadata : This element is for future use and is not currently implemented.

Back to the top