Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle WebCenter
11g Release 1 (11.1.1.4.0)
E15995-03


oracle.wcps.property
Interface IPropertyServiceFactory


public interface IPropertyServiceFactory

The factory interface to manage INamespace and IPropertyService instances. Users shouldn't use this directly, they should use the ServiceFactory class instead. The implementation instances are created using the jar service loading mechanism.


Method Summary
 INamespace createNamespace(IContext context, INamespace namespace)
          Creates the given namespace.
 INamespace createNamespace(IContext context, INamespaceName namespaceName)
          Creates a namespace with the given name namespaceName.
 IPagedList<INamespace> filter(IContext context, NamespaceFilterContext fc)
          Searches for the namespaces based on the given namespace filter context fc.
 INamespace getNamespace(IContext context, INamespaceName namespaceName)
          Retrieves the namespace identified by the given namespaceName.
 IPagedList<INamespace> getNamespaces(IContext context, PaginationContext paginationContext)
          Retrieves a paged list of the namespaces found in the system.
 IPropertyService getPropertyService(IContext context, INamespaceName namespaceName)
          Returns the namespace scoped property service to manage the propertydefinitions, propertysetdefinitions and propertysets within the scope of the namespace identified by the given namespaceName.
 void removeAllNamespaces(IContext context)
          Removes all the namespaces in the system.
 INamespace removeNamespace(IContext context, INamespace namespace)
          Removes the given namespace.
 INamespace removeNamespace(IContext context, INamespaceName namespaceName)
          Removes the namespace identified by the given namespaceName.
 INamespace updateNamespace(IContext context, INamespace namespace)
          Updates the given namespace.

 

Method Detail

createNamespace

INamespace createNamespace(IContext context,
                           INamespaceName namespaceName)
                           throws AlreadyExistsException
Creates a namespace with the given name namespaceName.
Parameters:
context - A property service context. If this API is accessed remotely this context must have remote properties.
namespaceName - A namespace name.
Returns:
the newly created namespace.
Throws:
AlreadyExistsException - if the namespace with the given name namespaceName already exists in the system.

createNamespace

INamespace createNamespace(IContext context,
                           INamespace namespace)
                           throws AlreadyExistsException
Creates the given namespace.
Parameters:
context - A property service context. If this API is accessed remotely this context must have remote properties.
namespace - A namespace instance used as a template.
Returns:
the newly create namespace.
Throws:
AlreadyExistsException - if the namespace already exists in the system.

removeNamespace

INamespace removeNamespace(IContext context,
                           INamespaceName namespaceName)
                           throws ObjectInUseException
Removes the namespace identified by the given namespaceName.
Parameters:
context - A property service context. If this API is accessed remotely this context must have remote properties.
namespaceName - A namespace name.
Returns:
the removed namespace.
Throws:
ObjectInUseException - if there are propertysets, propertydefinitions and propertysetdefinitions associated with this namespace. Remove all the propertysetdefinitions, propertydefinitions and propertysets by calling removeAll* methods in IPropertyService and then call this to avoid getting this exception.

removeNamespace

INamespace removeNamespace(IContext context,
                           INamespace namespace)
                           throws ObjectInUseException,
                                  ObjectOutOfSyncException
Removes the given namespace. If the optimistic concurrency feature is enabled, this method removes the namespace optimistically, it is removed only if its updatedOn time matches with the updatedOn time of the namespace in the system.
Parameters:
context - A property service context. If this API is accessed remotely this context must have remote properties.
namespace - A namespace that was returned by this system.
Returns:
the removed namespace.
Throws:
ObjectInUseException - if there are propertysets, propertydefinitions and propertysetdefinitions associated with this namespace. Remove all the propertysetdefinitions, propertydefinitions and propertysets by calling removeAll* methods in IPropertyService and then call this to avoid getting this exception.
ObjectOutOfSyncException - if the optimistic concurrency feature is enabled and updatedOn time of the given namespace doesn't match with the current version in the system.
See Also:
PropertyServiceContext.isOptimisticConcurrencyEnabled()

updateNamespace

INamespace updateNamespace(IContext context,
                           INamespace namespace)
                           throws NotFoundException,
                                  ObjectOutOfSyncException
Updates the given namespace. If the optimistic concurrency feature is enabled IContext.isOptimisticConcurrencyEnabled(), this method updates the namespace optimistically. The given namespace is updated only if its updatedOn time matches with the updatedOn time of the namespace in the system.
Parameters:
context - A property service context. If this API is accessed remotely this context must have remote properties.
namespace - A namespace that was returned by this system.
Returns:
the updated namespace.
Throws:
NotFoundException - if there is no namespace in the system.
ObjectOutOfSyncException - if the optimistic concurrency feature is enabled and the updatedOn time of the given namespace doesn't match with the current version in the system.

getNamespace

INamespace getNamespace(IContext context,
                        INamespaceName namespaceName)
Retrieves the namespace identified by the given namespaceName.
Parameters:
context - A property service context. If this API is accessed remotely this context must have remote properties.
namespaceName - A namespace name.
Returns:
the namespace if found otherwise null.

getNamespaces

IPagedList<INamespace> getNamespaces(IContext context,
                                     PaginationContext paginationContext)
Retrieves a paged list of the namespaces found in the system. The paged list size and the starting index is determined by the given paginationContext.
Parameters:
context - A property service context. If this API is accessed remotely this context must have remote properties.
paginationContext - containing the page size and the starting index.
Returns:
a paged list of namespaces.

filter

IPagedList<INamespace> filter(IContext context,
                              NamespaceFilterContext fc)
Searches for the namespaces based on the given namespace filter context fc.
Parameters:
context - A property service context. If this API is accessed remotely this context must have remote properties.
fc - A filter context that contains search expression and pagination context.
Returns:
the paged list of namespaces that satisfy the given filter context criteria.

removeAllNamespaces

void removeAllNamespaces(IContext context)
                         throws ObjectInUseException
Removes all the namespaces in the system.
Parameters:
context - A property service context. If this API is accessed remotely this context must have remote properties.
Throws:
ObjectInUseException - if there is at least one namespace that is associated with at least one of the propertysets, or the propertydefinitions or the propertysetdefinitions. Remove all the propertysetdefinitions, propertydefinitions and propertysets by calling removeAll* methods in IPropertyService and then call this to avoid getting this exception.

getPropertyService

IPropertyService getPropertyService(IContext context,
                                    INamespaceName namespaceName)
Returns the namespace scoped property service to manage the propertydefinitions, propertysetdefinitions and propertysets within the scope of the namespace identified by the given namespaceName.
Parameters:
context - A property service context. If this API is accessed remotely this context must have remote properties.
namespaceName - a namespace name.
Returns:
the namespace scoped property service.

Skip navigation links

Oracle Fusion Middleware Java API Reference for Oracle WebCenter
11g Release 1 (11.1.1.4.0)
E15995-03


Copyright © 2009, 2011, Oracle and/or its affiliates. All rights reserved.