Hi, Do we want them in the SlingConstants ? Or aren't they rather ResourceConstants ?
Regards Felix [email protected] schrieb: > Author: cziegeler > Date: Tue Jun 30 09:23:49 2009 > New Revision: 789635 > > URL: http://svn.apache.org/viewvc?rev=789635&view=rev > Log: > SLING-944 : Add constants for resource modification events. > > Modified: > > sling/trunk/bundles/api/src/main/java/org/apache/sling/api/SlingConstants.java > > Modified: > sling/trunk/bundles/api/src/main/java/org/apache/sling/api/SlingConstants.java > URL: > http://svn.apache.org/viewvc/sling/trunk/bundles/api/src/main/java/org/apache/sling/api/SlingConstants.java?rev=789635&r1=789634&r2=789635&view=diff > ============================================================================== > --- > sling/trunk/bundles/api/src/main/java/org/apache/sling/api/SlingConstants.java > (original) > +++ > sling/trunk/bundles/api/src/main/java/org/apache/sling/api/SlingConstants.java > Tue Jun 30 09:23:49 2009 > @@ -145,4 +145,65 @@ > * The type of the attribute value is <code>java.lang.Integer</code>. > */ > public static final String ERROR_STATUS = > "javax.servlet.error.status_code"; > + > + /** > + * The topic for the OSGi event which is sent when a resource has been > added > + * to the resource tree. > + * The event contains at least the {...@link #PROPERTY_PATH}, {...@link > #PROPERTY_RESOURCE_SUPER_TYPE} > + * and {...@link #PROPERTY_RESOURCE_TYPE} poperties. > + * @since 2.0.6 > + */ > + public static final String TOPIC_RESOURCE_ADDED = > "org/apache/sling/api/resource/Resource/ADDED"; > + > + /** > + * The topic for the OSGi event which is sent when a resource has been > removed > + * from the resource tree. > + * The event contains at least the {...@link #PROPERTY_PATH}.As the > resource has already been removed > + * no further information like resource type etc. might be available. > + * @since 2.0.6 > + */ > + public static final String TOPIC_RESOURCE_REMOVED = > "org/apache/sling/api/resource/Resource/REMOVED"; > + > + /** > + * The topic for the OSGi event which is sent when a resource has been > changed > + * in the resource tree. > + * The event contains at least the {...@link #PROPERTY_PATH}, {...@link > #PROPERTY_RESOURCE_SUPER_TYPE} > + * and {...@link #PROPERTY_RESOURCE_TYPE} poperties. > + * @since 2.0.6 > + */ > + public static final String TOPIC_RESOURCE_CHANGED = > "org/apache/sling/api/resource/Resource/CHANGED"; > + > + /** > + * The topic for the OSGi event which is sent when a resource provider > has been > + * added to the resource tree. > + * The event contains at least the {...@link #PROPERTY_PATH} property. > + * @since 2.0.6 > + */ > + public static final String TOPIC_RESOURCE_PROVIDER_ADDED = > "org/apache/sling/api/resource/ResourceProvider/ADDED"; > + > + /** > + * The topic for the OSGi event which is sent when a resource provider > has been > + * removed from the resource tree. > + * The event contains at least the {...@link #PROPERTY_PATH} property. > + * @since 2.0.6 > + */ > + public static final String TOPIC_RESOURCE_PROVIDER_REMOVED = > "org/apache/sling/api/resource/ResourceProvider/REMOVED"; > + > + /** > + * The name of the event property holding the resource path. > + * @since 2.0.6 > + */ > + public static final String PROPERTY_PATH = "path"; > + > + /** > + * The name of the event property holding the resource type. > + * @since 2.0.6 > + */ > + public static final String PROPERTY_RESOURCE_TYPE = "resourceType"; > + > + /** > + * The name of the event property holding the resource super type. > + * @since 2.0.6 > + */ > + public static final String PROPERTY_RESOURCE_SUPER_TYPE = > "resourceSuperType"; > } > > >
