|
Oracle Fusion Middleware extensions for Applications Core API Reference 11g Release 1 (11.1.2) E22562-02 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object oracle.apps.fnd.applcore.moac.MOACUtil
public class MOACUtil
MOACUtil class provides utility methods to initialize MOAC frame work and appending view Criteria to View Object. In addition, there are other helper methods to switch Access Mode and getting MOAC attributes. All publicly accessible methods are static.
Field Summary | |
---|---|
static java.lang.String |
LAST_MOAC_PRIV
Constant String litarals |
static java.lang.String |
MOAC_QUERY_MODE
|
static java.lang.String |
MOAC_VC_ROW_NAME
|
Constructor Summary | |
---|---|
MOACUtil()
|
Method Summary | |
---|---|
static boolean |
checkAccess(java.lang.Long orgId)
Checks if a given Org Id has access. |
static boolean |
checkAccess(java.lang.Long orgId,
Privilege priv)
Checks if a given Org Id has access. |
static void |
createBindAndApplyMOACVC(OAViewObjectImpl pVOImpl,
Privilege priv)
Sets view criteria for restricting data access based on Org Id list. |
static oracle.jbo.ViewCriteria |
createVC(OAViewObjectImpl pVOImpl,
java.lang.String accessType,
java.lang.String vcName,
java.lang.String orgIdAttrbName)
Create View Criteria for MAOC |
static void |
doMOACInit(Privilege priv,
OAApplicationModuleImpl amImpl)
This method initilizes MOAC. |
static java.lang.Long[] |
getAccessibleBUIds()
Return the list Org Ids. |
static java.lang.Long[] |
getAccessibleBUIds(Privilege priv)
Return the list Org Ids. |
static java.lang.String[] |
getAccessibleBUNames()
Return the list Org Names. |
static java.lang.String[] |
getAccessibleBUNames(Privilege priv)
Return the list Org Names. |
static java.lang.String |
getAccessMode()
Returns current access mode set During Init or set Mode switching. |
static java.lang.String |
getAccessMode(Privilege priv)
Returns current access mode set During Init or set Mode switching for a given privilege. |
static java.lang.String |
getBUName(java.lang.Long orgId)
Return the Org Name for a given OrgId. |
static java.lang.String |
getBUName(java.lang.Long orgId,
Privilege priv)
Return the Org Name for a given OrgId. |
static java.lang.Long |
getCurrentOrgId()
Returns current Org Id, In case Single mode it will have valid value. |
static java.lang.Long |
getCurrentOrgId(Privilege priv)
Returns current Org Id, In case Single mode it will have valid value. |
static java.lang.Long |
getDfltOrgId()
Returns current Org Id, In case Single mode it will have valid value. |
static java.lang.Long |
getDfltOrgId(Privilege priv)
Returns current Org Id, In case Single mode it will have valid value. |
static Privilege |
getMostRecentPrivilege()
Returns most recent Privilege in use, not necessarily the last one used during MOAC init. |
static java.lang.String |
getMultiModeQueryClause(oracle.jbo.ViewCriteriaItem vci)
|
static int |
getOrgCount()
Returns Org Count set during MOAC init based on most recent privilege |
static int |
getOrgCount(Privilege priv)
Returns Org Count set during MOAC init using a given privilege |
static java.lang.String |
getQueryClause(oracle.jbo.ViewCriteria vc)
This required to set the Query Cluase in MOACCriteria Adapter Work around for bug # 7172280 |
static int |
getTotalOrgCount()
Returns Total Org Count during MOAC init based on most recent privilege |
static int |
getTotalOrgCount(Privilege priv)
Returns Count of Org Ids during MOAC init using a given privilege |
static java.lang.String |
initMOACplsql(Privilege priv,
OAApplicationModuleImpl amImpl)
This may be used initialize MOAC in PL SQL while calling PL SQL Program Unit from ADF. |
static boolean |
isMOACInitialized(Privilege priv)
Checks if MOAC is initialized for a given privilege. |
static void |
printMOACAttributes(Privilege priv)
Used for Testing to print MOAC Attributes |
static void |
setAllOrgAccessMode(Privilege priv)
Sets access mode to All Org Mode ("A"). |
static void |
setMultiOrgAccessMode()
Sets access mode to Multi Org Mode ("M"). |
static void |
setMultiOrgAccessMode(Privilege priv)
Sets access mode to Multi Org Mode ("M"). |
static void |
setSingleOrgAccessMode(java.lang.Long orgId)
|
static void |
setSingleOrgAccessMode(java.lang.Long orgId,
Privilege priv)
Pass OrgId to switch to Single Org Access Mode ("S"). |
static java.lang.String |
showSecurityPredicate(Privilege priv,
OAApplicationModuleImpl amImpl)
used for testing |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String LAST_MOAC_PRIV
public static final java.lang.String MOAC_VC_ROW_NAME
public static final java.lang.String MOAC_QUERY_MODE
Constructor Detail |
---|
public MOACUtil()
Method Detail |
---|
public static void doMOACInit(Privilege priv, OAApplicationModuleImpl amImpl)
priv
- Privilege of the current user.amImpl
- Application Module to be used to call this method
from AM it will be amImpl from VO use
(OAApplicationModuleImpl)VOImpl.getRootApplicationModule()public static int getOrgCount()
public static int getOrgCount(Privilege priv)
priv
- Privilege of the user.
public static int getTotalOrgCount()
public static int getTotalOrgCount(Privilege priv)
priv
- Privilege of the user.
public static java.lang.String getAccessMode()
public static java.lang.String getAccessMode(Privilege priv)
priv
- Privilege of the user.
public static java.lang.Long getCurrentOrgId()
public static java.lang.Long getCurrentOrgId(Privilege priv)
priv
- Privilege of the user.
public static java.lang.Long getDfltOrgId()
public static java.lang.Long getDfltOrgId(Privilege priv)
priv
- Privilege of the user/role.
public static Privilege getMostRecentPrivilege()
public static void setSingleOrgAccessMode(java.lang.Long orgId)
public static void setSingleOrgAccessMode(java.lang.Long orgId, Privilege priv)
orgId
- OrgId for which Single Access Mode will be setpriv
- Privlege of the userpublic static boolean checkAccess(java.lang.Long orgId)
orgId
- Org Id for which access is being verified.
public static boolean checkAccess(java.lang.Long orgId, Privilege priv)
orgId
- Org Id for which access is being verified.priv
- Privlege of the user
public static void setAllOrgAccessMode(Privilege priv)
public static void setMultiOrgAccessMode()
public static void setMultiOrgAccessMode(Privilege priv)
public static java.lang.Long[] getAccessibleBUIds()
public static java.lang.Long[] getAccessibleBUIds(Privilege priv)
priv
- Privlege of the user
public static java.lang.String[] getAccessibleBUNames()
public static java.lang.String[] getAccessibleBUNames(Privilege priv)
priv
- Privilege of the user/role
public static java.lang.String getBUName(java.lang.Long orgId)
orgId
- A valid Org Id
public static java.lang.String getBUName(java.lang.Long orgId, Privilege priv)
orgId
- A valid Org Id
public static boolean isMOACInitialized(Privilege priv)
public static void createBindAndApplyMOACVC(OAViewObjectImpl pVOImpl, Privilege priv)
pVOImpl
- Moac enabled View Object Impl.priv
- Privilege of the userpublic static java.lang.String getQueryClause(oracle.jbo.ViewCriteria vc)
vc
- View Criteria
public static java.lang.String getMultiModeQueryClause(oracle.jbo.ViewCriteriaItem vci)
public static oracle.jbo.ViewCriteria createVC(OAViewObjectImpl pVOImpl, java.lang.String accessType, java.lang.String vcName, java.lang.String orgIdAttrbName)
pVOImpl
- View Object ImplaccessType
- MOAC access TypevcName
- View Criteria NameorgIdAttrbName
- VO attribute name for MOAC
public static java.lang.String initMOACplsql(Privilege priv, OAApplicationModuleImpl amImpl)
priv
- Privilege of the user/roleamImpl
- ApplicationMOduleImpl object
public static void printMOACAttributes(Privilege priv)
priv
- public static java.lang.String showSecurityPredicate(Privilege priv, OAApplicationModuleImpl amImpl)
priv
- Privilege of the useramImpl
- Application Module Implementation
|
Oracle Fusion Middleware extensions for Applications Core API Reference 11g Release 1 (11.1.2) E22562-02 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |