lumis.portal.serviceinterface.style
Class ServiceInterfaceStyleConfig

Package class diagram package ServiceInterfaceStyleConfig
java.lang.Object
  extended by lumis.portal.serviceinterface.style.ServiceInterfaceStyleConfig
All Implemented Interfaces:
Cloneable, ICloneableConfig<ServiceInterfaceStyleConfig>

@StableMinor(version="6.2",
             sinceVersion="4.0")
public class ServiceInterfaceStyleConfig
extends Object
implements ICloneableConfig<ServiceInterfaceStyleConfig>

Value class for Service Interface Style properties

Since:
4.0.0

Nested Class Summary
static class ServiceInterfaceStyleConfig.IsolationLevel
          Represents the level of isolation of a Style.
 
Field Summary
protected  String description
           
protected  String filePath
           
protected  String id
           
protected  boolean isFromDefinition
           
protected  Collection<String> isolationAllowedConsumers
           
protected  ServiceInterfaceStyleConfig.IsolationLevel isolationLevel
           
protected  boolean isWidgetDefault
           
protected  String name
           
protected  String serviceInterfaceId
           
 
Constructor Summary
ServiceInterfaceStyleConfig()
           
 
Method Summary
 ServiceInterfaceStyleConfig clone()
           
 void deserialize(Node serviceInstanceNode)
          Deserialize the properties of the ServiceInstanceStyleConfig from the specified XML Node.
 boolean equals(Object obj)
           
 String getDescription()
           
 String getFilePath()
           
 String getId()
           
 Collection<String> getIsolationAllowedConsumers()
          Returns a list of identifiers of elements that are allowed to use this style.
 ServiceInterfaceStyleConfig.IsolationLevel getIsolationLevel()
          Returns the isolation level for this style.
 boolean getIsWidgetDefault()
          Returns the isWidgetDefault.
 String getName()
           
 String getServiceInterfaceId()
           
 int hashCode()
           
 boolean isFromDefinition()
           
 void serialize(ServiceInterfaceStyleConfig styleConfig, OutputStream outputStream)
          Serializes the interface style config to the specified output stream.
 void setDescription(String description)
           
 void setFilePath(String filePath)
           
 void setFromDefinition(boolean isFromDefinition)
           
 void setId(String id)
           
 void setIsolation(ServiceInterfaceStyleConfig.IsolationLevel isolationLevel, Collection<String> allowedConsumers)
          Sets the isolationLevel.
 void setIsWidgetDefault(boolean isWidgetDefault)
          Sets the isWidgetDefault.
 void setName(String name)
           
 void setServiceInterfaceId(String interfaceId)
           
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

id

protected String id

serviceInterfaceId

protected String serviceInterfaceId

name

protected String name

description

protected String description

filePath

protected String filePath

isFromDefinition

protected boolean isFromDefinition

isWidgetDefault

protected boolean isWidgetDefault

isolationAllowedConsumers

protected Collection<String> isolationAllowedConsumers

isolationLevel

protected ServiceInterfaceStyleConfig.IsolationLevel isolationLevel
Constructor Detail

ServiceInterfaceStyleConfig

public ServiceInterfaceStyleConfig()
Method Detail

getDescription

public String getDescription()
Returns:
Returns the description.

setDescription

public void setDescription(String description)
Parameters:
description - The description to set.

getFilePath

public String getFilePath()
Returns:
Returns the filePath.

setFilePath

public void setFilePath(String filePath)
Parameters:
filePath - The filePath to set.

getId

public String getId()
Returns:
Returns the id.

setId

public void setId(String id)
Parameters:
id - The id to set.

getServiceInterfaceId

public String getServiceInterfaceId()
Returns:
Returns the serviceInterfaceId.

setServiceInterfaceId

public void setServiceInterfaceId(String interfaceId)
Parameters:
serviceInterfaceId - The serviceInterfaceId to set.

isFromDefinition

public boolean isFromDefinition()
Returns:
Returns the isFromDefinition.

setFromDefinition

public void setFromDefinition(boolean isFromDefinition)
Parameters:
isFromDefinition - The isFromDefinition to set.

getName

public String getName()
Returns:
Returns the name.

setName

public void setName(String name)
Parameters:
name - The name to set.

serialize

public void serialize(ServiceInterfaceStyleConfig styleConfig,
                      OutputStream outputStream)
               throws PortalException
Serializes the interface style config to the specified output stream.

Parameters:
pageConfig -
outputStream -
Throws:
PortalException
Since:
4.0.3

deserialize

public void deserialize(Node serviceInstanceNode)
                 throws PortalException
Deserialize the properties of the ServiceInstanceStyleConfig from the specified XML Node.

Parameters:
serviceInstanceNode -
Throws:
PortalException
Since:
4.0.3

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

clone

public ServiceInterfaceStyleConfig clone()
                                  throws CloneNotSupportedException
Specified by:
clone in interface ICloneableConfig<ServiceInterfaceStyleConfig>
Overrides:
clone in class Object
Throws:
CloneNotSupportedException

setIsWidgetDefault

public void setIsWidgetDefault(boolean isWidgetDefault)
Sets the isWidgetDefault.

Parameters:
isWidgetDefault - the isWidgetDefault value to set.
Since:
6.0.0

getIsWidgetDefault

public boolean getIsWidgetDefault()
Returns the isWidgetDefault.

Returns:
the isWidgetDefault
Since:
6.0.0

getIsolationLevel

public ServiceInterfaceStyleConfig.IsolationLevel getIsolationLevel()
Returns the isolation level for this style.

Returns:
the isolation level.
Since:
6.2.0

setIsolation

public void setIsolation(ServiceInterfaceStyleConfig.IsolationLevel isolationLevel,
                         Collection<String> allowedConsumers)
                  throws IsolationLevelValidationException,
                         PortalException
Sets the isolationLevel. This method validates the rules of isolation. If any error of validation occurs an IsolationLevelValidationException is raised.

Parameters:
isolationLevel - the isolation level.
allowedConsumers - collection with the identifiers of the consumers allowed to use this style. If isolationLevel is ServiceInterfaceStyleConfig.IsolationLevel.ISOLATED, it must be a single interface instance identifier; If isolationLevel is ServiceInterfaceStyleConfig.IsolationLevel.SHARED, it must be the identifiers of the service instances that can use the style.
Throws:
IsolationLevelValidationException - if any rule of validation is invalid.
PortalException - if any error occurs during the process.
Since:
6.2.0

getIsolationAllowedConsumers

public Collection<String> getIsolationAllowedConsumers()
Returns a list of identifiers of elements that are allowed to use this style.

If the isolation level is ServiceInterfaceStyleConfig.IsolationLevel.PUBLIC the returned collection is empty.

If the isolation level is ServiceInterfaceStyleConfig.IsolationLevel.ISOLATED the returned collection contains a single interface instance identifier.

If the isolation level is ServiceInterfaceStyleConfig.IsolationLevel.SHARED the returned collection contains the identifiers of service instances.

Returns:
the consumers identifiers, as explained above.
Since:
6.2.0


Lumisportal  6.2.0.120405 - Copyright © 2006–2012 Lumis EIP Tecnologia da Informação LTDA. All Rights Reserved.