|
SAP NetWeaver 7.30 SP01 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IPcdUtils
Provides miscellaneous factory methods and auxiliary functions. An instance of this interface can be retrieved via PcdAccess.
This interface is not intended to be implemented by clients.
| Method Summary | |
|---|---|
String |
convertShortNameToUrl(String shortName)
Converts a short name to its corresponding URL (name including JNDI scheme). |
String |
convertUrlToShortName(String url)
Converts a URL (name including JNDI scheme) to a short name. |
IPcdAttribute |
createPcdAttribute(PcdAttributeValueType type,
IPcdAttributeId attributeId)
Creates an ordered PcdAttribute of the specified value type and id. |
IPcdAttribute |
createPcdAttribute(PcdAttributeValueType type,
IPcdAttributeId attributeId,
boolean isOrdered)
Creates a PcdAttribute of the specified value type and id and ordering |
IPcdAttribute |
createPcdAttribute(PcdAttributeValueType type,
String attributeName)
Creates an ordered PcdAttribute of the selected value type. |
IPcdAttribute |
createPcdAttribute(PcdAttributeValueType type,
String attributeName,
boolean isOrdered)
Creates pcd attribute instance |
IPcdAttributeId |
createPcdAttributeId(String[] attributeNameElements)
Creates a compound attribute identifier from the specified attribute ID components. |
IPcdAttributes |
createPcdAttributes()
createPcdAttributes creates an instance of PcdAttributes |
String |
escapeShortName(String shortName)
Escapes a short name so that it can be used as atomic name in PCD. |
Locale |
getDefaultLocale()
Returns the default locale of the portal. |
ILockHandle |
getLockHandle(String nameInNamespace)
Returns the ILockHandle for the specified name (i.e., without prefix),
which allows to lock/unlock it etc. |
int |
getMaxLengthAtomicName()
Returns the maximum length of atomic names. |
int |
getMaxLengthAttributeId()
Deprecated. the restriction in the length of an attributes name has been removed |
int |
getMaxLengthTextType()
Returns the maximum length of a text type. |
IPcdNameFactory |
getPcdNameFactory()
Returns an IPcdNameFactory instance that provides
various methods for creation of IPcdName objects. |
String |
getUrlSchemePrefix()
Returns the pcd url scheme prefix (pcd:) |
WriteProtectInfo |
getWriteProtectInfo()
Returns information about the write protect mode. |
boolean |
isADbSearch(String jndiFilterExpr,
Object[] filterArgs,
Locale locale)
|
boolean |
matches(String objAtomicName,
String objObjectClass,
String objDeltalinkTarget,
IPcdAttributes objAttributes,
IPcdAttributes objUnitAttributes,
IPcdAttributes matchingAttributes,
String filterExpression,
Locale locale)
Performs the same comparison as is used internally during the search. |
boolean |
originalLocaleTextsOnly()
If true, only texts in the original locale are returned. |
void |
publishChanges()
Publishes changes to pcd objects to all other objects that depend on the changed one. |
DirContext |
recreateSchemaEntry(String atomicName,
Attributes attrs,
Object securityPrincipal)
Ensures that the specified schema entry exists (after this call returns). |
boolean |
storesLongString(String longStr)
Returns true if the long string longStr has already been converted to a short string. |
String |
unescapeShortName(String escapedShortName)
Unescapes a short name that has been escaped with method escapeShortName(String). |
| Method Detail |
|---|
IPcdAttribute createPcdAttribute(PcdAttributeValueType type,
String attributeName)
type - attributeName -
IPcdAttribute createPcdAttribute(PcdAttributeValueType type,
String attributeName,
boolean isOrdered)
type - attributeName - isOrdered -
IPcdAttribute createPcdAttribute(PcdAttributeValueType type,
IPcdAttributeId attributeId)
type - attributeId - the ID of the new attribute
IPcdAttribute createPcdAttribute(PcdAttributeValueType type,
IPcdAttributeId attributeId,
boolean isOrdered)
type - attributeId - the ID of the new attributeisOrdered -
IPcdAttributeId createPcdAttributeId(String[] attributeNameElements)
Note: usage of compound attribute IDs should be restricted to special use-cases. This method is not intended for public use and might be discarded in future releases.
attributeNameElements - the elements of the compound attribute id
IPcdAttributes createPcdAttributes()
createPcdAttributes creates an instance of PcdAttributes
int getMaxLengthAtomicName()
@Deprecated int getMaxLengthAttributeId()
int getMaxLengthTextType()
String convertUrlToShortName(String url)
throws IllegalArgumentException
url -
IllegalArgumentException - if the parameter is notconvertShortNameToUrl(String)String convertShortNameToUrl(String shortName)
shortName -
convertUrlToShortName(String)String escapeShortName(String shortName)
The short name generated by method convertUrlToShortName(String) can contain characters
which are not allowed as part of an atomic name in PCD.
This method "escapes" these characters by replacing them with characters which are allowed
for names in PCD but which are not part of the character encoding which is used by method
convertUrlToShortName(String)
shortName - A short name generated by convertUrlToShortName(String)
unescapeShortName(String),
convertUrlToShortName(String)String unescapeShortName(String escapedShortName)
escapeShortName(String).
escapedShortName - A short name which was escaped by escapeShortName(String)
convertUrlToShortName(String)escapeShortName(String)boolean storesLongString(String longStr)
longStr has already been converted to a short string.
longStr - long string
longStr has already been converted to a short string, otherwise falseString getUrlSchemePrefix()
Locale getDefaultLocale()
boolean originalLocaleTextsOnly()
com.sapportals.portal.pcd.gl
for details.
void publishChanges()
DirContext recreateSchemaEntry(String atomicName,
Attributes attrs,
Object securityPrincipal)
throws NamingException
atomicName - name of the schema entryattrs - attributes of the schema entrysecurityPrincipal - security principal, which is added to the environment of the context;
can be null; in future releases this might become a required parameter
NamingException
ILockHandle getLockHandle(String nameInNamespace)
throws NamingException
ILockHandle for the specified name (i.e., without prefix),
which allows to lock/unlock it etc.
This method should be used if you need to lock a not yet existing unit.
It is not checked whether the object exists, and whether it is a unit.
nameInNamespace - a pcd-internal "name in namespace", i.e., without url-prefix
NamingExceptionWriteProtectInfo getWriteProtectInfo()
IPcdNameFactory getPcdNameFactory()
IPcdNameFactory instance that provides
various methods for creation of IPcdName objects.
IPcdNameFactory instance
boolean matches(String objAtomicName,
String objObjectClass,
String objDeltalinkTarget,
IPcdAttributes objAttributes,
IPcdAttributes objUnitAttributes,
IPcdAttributes matchingAttributes,
String filterExpression,
Locale locale)
throws NamingException
objAtomicName - maybe null if the comparison does not check the atomic nameobjObjectClass - maybe null if the comparison does not check the obejct classobjDeltalinkTarget - maybe null if the comparison does not check the deltalink targetobjAttributes - the attributes of the objectobjUnitAttributes - maybe null if the comparison does not check the unit attributes of the objectmatchingAttributes - maybe null if filterExpression is not nullfilterExpression - maybe null if matchingAttributes is not nulllocale - is relevant only if text attributes are compared
true if the object matches
NamingException - if e.g. the filterString cannot be parsed
boolean isADbSearch(String jndiFilterExpr,
Object[] filterArgs,
Locale locale)
throws InvalidSearchFilterException
jndiFilterExpr - filterArgs - locale -
true if the given expression can be executed on the database layer, i.e. only considers object class, atomic name and
unit attributes - atomic name and object class may be case insensitive. In the case-insensitive case, the PL layer does the
post filtering directly on the result set.
InvalidSearchFilterException| Access Rights |
|---|
| SC | DC | Public Part | ACH |
|---|---|---|---|
[sap.com] EP-BASIS-API
|
[sap.com] tc/epbc/pcd/gl/api
|
-
|
EP-PIN
|
[sap.com] EP-BASIS-API
|
[sap.com] tc/epbc/pcd/gl/api
|
api
|
EP-PIN
|
[sap.com] EP-BASIS
|
[sap.com]
|
api
|
BC-PIN-PCD
|
[sap.com] KMC-WPC
|
[sap.com] tc/kmc/wpc/wpcfacade
|
api
|
EP-PIN-WPC-WCM
|
|
SAP NetWeaver 7.30 SP01 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||