public class ServiceInterfaceManager extends Object implements IServiceInterfaceManagerSPI
INTERFACE_HOLDER_ID
Constructor and Description |
---|
ServiceInterfaceManager() |
Modifier and Type | Method and Description |
---|---|
void |
addOrUpdateStyle(SessionConfig sessionConfig,
ServiceInterfaceStyleConfig serviceInterfaceStyleConfig,
ITransaction transaction)
Add or update a Style.
|
void |
clearCache()
Clears the service interface caches.
|
void |
deleteStyle(SessionConfig sessionConfig,
String serviceInterfaceStyleId,
String serviceInterfaceId,
ITransaction transaction)
Delete a Style.
|
void |
deserializeStyle(SessionConfig sessionConfig,
Node interfaceStyleNode,
ITransaction transaction)
Deserializes a ServiceInterfaceStyleConfig contained in the interfaceStyleNode.
|
Collection<String> |
getIdsByServiceId(String serviceId,
ITransaction transaction)
Get the service interface ids from a given service.
|
ServiceInterfaceMenuGroupTypeConfig |
getMenuGroupType(SessionConfig sessionConfig,
String menuGroupTypeId,
ITransaction transaction)
Get the menu group type.
|
ServiceInterfaceMenuItemTypeConfig |
getMenuItemType(SessionConfig sessionConfig,
String menuItemTypeId,
ITransaction transaction)
Get the menu item type.
|
IServiceInterface |
getServiceInterface(String serviceInterfaceId,
ITransaction transaction)
Get the service interface.
|
ServiceInterfaceConfig |
getServiceInterfaceConfig(String serviceInterfaceId,
ITransaction transaction)
Get the configuration of the service interface.
|
protected ServiceInterfaceTypeConfig |
getServiceInterfaceTypeConfig(String interfaceType,
ITransaction transaction) |
ServiceInterfaceStyleConfig |
getStyle(SessionConfig sessionConfig,
String serviceInterfaceStyleId,
String serviceInterfaceId,
ITransaction transaction)
Get the style configuration os the service interface.
|
ServiceInterfaceStyleConfig |
getStyleByServiceInterfaceInstanceId(SessionConfig sessionConfig,
String serviceInterfaceInstanceId,
ITransaction transaction)
Get the Style given the ServiceInterfaceInstanceId.
|
IConfigKeyChecker |
getStyleConfigKeyChecker() |
Collection<String> |
getStyleIds(SessionConfig sessionConfig,
String serviceInterfaceId,
ITransaction transaction)
Get the Id of all styles associated with a service interface.
|
Collection<String> |
getStyleIdsByInterfaceInstance(SessionConfig sessionConfig,
String interfaceInstanceId,
ITransaction transaction,
boolean onlyCustomStyles)
Get the Id of all styles available to an interface instance considering
the isolation rules.
|
boolean |
keyExists(SessionConfig sessionConfig,
Object configKey,
Object config,
ITransaction transaction)
Checks if configId matches an already persisted object
|
void |
register(SessionConfig sessionConfig,
String serviceConfigPath,
ITransaction transaction)
Register the service interface.
|
void |
registerMenuGroupTypes(SessionConfig sessionConfig,
String groupTypesConfigPath,
ITransaction transaction)
Register the menu group types.
|
void |
registerMenuItemTypes(SessionConfig sessionConfig,
String itemTypesConfigPath,
ITransaction transaction)
Register menu item type.
|
void |
registerServiceInterfaceTypes(SessionConfig sessionConfig,
String serviceTypesConfigPath,
ITransaction transaction)
Register the type of the service interface.
|
void |
serializeStyle(SessionConfig sessionConfig,
String serviceInterfaceStyleId,
String serviceInterfaceId,
OutputStream outputStream,
ITransaction transaction)
Serializes a ServiceInterfaceStyleConfig to the specified outputStream.
|
void |
unregister(SessionConfig sessionConfig,
ServiceInterfaceConfig serviceInterfaceConfig,
ITransaction transaction)
Unregister the Service Interface.
|
void |
unregisterMenuGroupType(SessionConfig sessionConfig,
String typeId,
ITransaction transaction)
Unregisters a service menu group type.
|
void |
unregisterMenuItemType(SessionConfig sessionConfig,
String typeId,
ITransaction transaction)
Unregisters a service menu item type.
|
void |
unregisterServiceInterfaceType(String typeId,
ITransaction transaction)
Unregister the type of service interface.
|
public ServiceInterfaceConfig getServiceInterfaceConfig(String serviceInterfaceId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
getServiceInterfaceConfig
in interface IServiceInterfaceManager
ManagerException
PortalException
public Collection<String> getIdsByServiceId(String serviceId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
getIdsByServiceId
in interface IServiceInterfaceManager
ManagerException
PortalException
public IServiceInterface getServiceInterface(String serviceInterfaceId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
getServiceInterface
in interface IServiceInterfaceManager
ManagerException
PortalException
public void register(SessionConfig sessionConfig, String serviceConfigPath, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
register
in interface IServiceInterfaceManager
ManagerException
PortalException
public void registerServiceInterfaceTypes(SessionConfig sessionConfig, String serviceTypesConfigPath, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
registerServiceInterfaceTypes
in interface IServiceInterfaceManager
ManagerException
PortalException
protected ServiceInterfaceTypeConfig getServiceInterfaceTypeConfig(String interfaceType, ITransaction transaction) throws ManagerException, PortalException
ManagerException
PortalException
public void unregisterServiceInterfaceType(String typeId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
unregisterServiceInterfaceType
in interface IServiceInterfaceManager
ManagerException
PortalException
public ServiceInterfaceStyleConfig getStyleByServiceInterfaceInstanceId(SessionConfig sessionConfig, String serviceInterfaceInstanceId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
getStyleByServiceInterfaceInstanceId
in interface IServiceInterfaceManager
ManagerException
PortalException
public ServiceInterfaceStyleConfig getStyle(SessionConfig sessionConfig, String serviceInterfaceStyleId, String serviceInterfaceId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
getStyle
in interface IServiceInterfaceManager
ManagerException
PortalException
public void deleteStyle(SessionConfig sessionConfig, String serviceInterfaceStyleId, String serviceInterfaceId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
deleteStyle
in interface IServiceInterfaceManager
ManagerException
PortalException
public void addOrUpdateStyle(SessionConfig sessionConfig, ServiceInterfaceStyleConfig serviceInterfaceStyleConfig, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
The rules considered are:
addOrUpdateStyle
in interface IServiceInterfaceManager
sessionConfig
- the sessionConfig object that contains the
informations about the user request.serviceInterfaceStyleConfig
- the style object to be persisted.transaction
- used to get informations from database.ManagerException
- if any error occurs during the process
of communication with database.PortalException
- if any other error occurs during the process.public void registerMenuItemTypes(SessionConfig sessionConfig, String itemTypesConfigPath, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
registerMenuItemTypes
in interface IServiceInterfaceManager
ManagerException
PortalException
public void registerMenuGroupTypes(SessionConfig sessionConfig, String groupTypesConfigPath, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
registerMenuGroupTypes
in interface IServiceInterfaceManager
ManagerException
PortalException
public void unregisterMenuItemType(SessionConfig sessionConfig, String typeId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
unregisterMenuItemType
in interface IServiceInterfaceManager
ManagerException
PortalException
public void unregisterMenuGroupType(SessionConfig sessionConfig, String typeId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
unregisterMenuGroupType
in interface IServiceInterfaceManager
ManagerException
PortalException
public ServiceInterfaceMenuGroupTypeConfig getMenuGroupType(SessionConfig sessionConfig, String menuGroupTypeId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
getMenuGroupType
in interface IServiceInterfaceManager
ManagerException
PortalException
public ServiceInterfaceMenuItemTypeConfig getMenuItemType(SessionConfig sessionConfig, String menuItemTypeId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
getMenuItemType
in interface IServiceInterfaceManager
ManagerException
PortalException
public void unregister(SessionConfig sessionConfig, ServiceInterfaceConfig serviceInterfaceConfig, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
unregister
in interface IServiceInterfaceManager
ManagerException
PortalException
public Collection<String> getStyleIds(SessionConfig sessionConfig, String serviceInterfaceId, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
getStyleIds
in interface IServiceInterfaceManager
sessionConfig
- the sessionConfig object that contains the
informations about the user request.serviceInterfaceId
- Service Interface target.transaction
- used to get informations from database.ManagerException
- if any error occurs during the process
of communication with database.PortalException
- if any other error occurs during the process.public void serializeStyle(SessionConfig sessionConfig, String serviceInterfaceStyleId, String serviceInterfaceId, OutputStream outputStream, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
serializeStyle
in interface IServiceInterfaceManager
ManagerException
PortalException
public void deserializeStyle(SessionConfig sessionConfig, Node interfaceStyleNode, ITransaction transaction) throws ManagerException, PortalException
IServiceInterfaceManager
deserializeStyle
in interface IServiceInterfaceManager
ManagerException
PortalException
public boolean keyExists(SessionConfig sessionConfig, Object configKey, Object config, ITransaction transaction)
IConfigKeyChecker
keyExists
in interface IConfigKeyChecker
config
- Optional, allows a checker to read aditional fields to check composed keyspublic IConfigKeyChecker getStyleConfigKeyChecker()
getStyleConfigKeyChecker
in interface IServiceInterfaceManager
public Collection<String> getStyleIdsByInterfaceInstance(SessionConfig sessionConfig, String interfaceInstanceId, ITransaction transaction, boolean onlyCustomStyles) throws ManagerException, PortalException
IServiceInterfaceManager
The isolation rules are:
Non-Isolated
- Can
be used for any the interface instance. This level is the default for new
styles.Shared
- Can be
used just by service instances indicated by the user during the add or update
custom interface style process.getStyleIdsByInterfaceInstance
in interface IServiceInterfaceManager
sessionConfig
- the sessionConfig object that contains the informations about
the user request.interfaceInstanceId
- Interface instance target.transaction
- used to get informations from database.onlyCustomStyles
- determine if is to return only custom styles.ManagerException
- if any error occurs during the process of communication with
database.PortalException
- if any other error occurs during the process.public void clearCache()
IServiceInterfaceManagerSPI
clearCache
in interface IServiceInterfaceManagerSPI
LumisXP 12.4.0.200625 - Copyright © 2006–2020 Lumis EIP Tecnologia da Informação LTDA. All Rights Reserved.