com.fatwire.services.beans.asset
Class PermissionBean<T>
java.lang.Object
com.fatwire.services.beans.BaseBean
com.fatwire.services.beans.ServiceBean<T>
com.fatwire.services.beans.asset.PermissionBean<T>
- Type Parameters:
T
- type of the entity encapsulated into the ServiceBean
.
- All Implemented Interfaces:
- java.io.Serializable
public class PermissionBean<T>
- extends ServiceBean<T>
The PermissionBean is the value object for authorization modules which
determine permission for performing operations on an asset. It provides the
following information:
- a flag set to true if permission is granted
- the asset identifier associated with the asset for which permission is
checked
- a response object providing the success or error condition, along with
localized messages and a status code
- an optional typed entity, which is customized to hold further information
regarding the authorization (for example: if the asset is locked by some
other user and hence cannot be accessed)
- See Also:
ServiceBean
,
Serialized Form
Method Summary |
AssetId |
getAsset()
Returns the asset identifier associated with the asset on which the
permission is checked. |
java.lang.Boolean |
isPermitted()
Returns true if an asset operation is authorized for an
asset. |
void |
setAsset(AssetId asset)
Sets the asset identifier associated with the asset on which the
permission is checked. |
void |
setPermitted(java.lang.Boolean permitted)
Sets authorized permission for an operation in the context of an asset. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PermissionBean
public PermissionBean()
getAsset
public AssetId getAsset()
- Returns the asset identifier associated with the asset on which the
permission is checked.
- Returns:
- the asset identifier.
setAsset
public void setAsset(AssetId asset)
- Sets the asset identifier associated with the asset on which the
permission is checked.
- Parameters:
asset
- the asset identifier to set.
isPermitted
public final java.lang.Boolean isPermitted()
- Returns
true
if an asset operation is authorized for an
asset.
- Returns:
true
if an asset operation is authorized for an
asset.
setPermitted
public final void setPermitted(java.lang.Boolean permitted)
- Sets authorized permission for an operation in the context of an asset.
Set to
true
if permission is granted.
- Parameters:
permitted
- permission flag to set. Set to true
if permission is
granted.
Copyright (c) 2012, Oracle and/or its affiliates. All rights reserved.