diff options
author | Ade Lee <alee@redhat.com> | 2011-12-08 21:15:59 -0500 |
---|---|---|
committer | Ade Lee <alee@redhat.com> | 2011-12-08 21:15:59 -0500 |
commit | 171aaece4f23709d33d180cf36eb3af5e454b0c9 (patch) | |
tree | 1485f9f0a7bd10de4ff25030db575dbb8dafae74 /pki/base/common/src/com/netscape/certsrv/policy | |
parent | adad2fcee8a29fdb82376fbce07dedb11fccc182 (diff) | |
download | pki-171aaece4f23709d33d180cf36eb3af5e454b0c9.tar.gz pki-171aaece4f23709d33d180cf36eb3af5e454b0c9.tar.xz pki-171aaece4f23709d33d180cf36eb3af5e454b0c9.zip |
Revert "Formatting"
This reverts commit 32150d3ee32f8ac27118af7c792794b538c78a2f.
Diffstat (limited to 'pki/base/common/src/com/netscape/certsrv/policy')
18 files changed, 251 insertions, 213 deletions
diff --git a/pki/base/common/src/com/netscape/certsrv/policy/EPolicyException.java b/pki/base/common/src/com/netscape/certsrv/policy/EPolicyException.java index dacbb103d..c8431fcfd 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/EPolicyException.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/EPolicyException.java @@ -17,23 +17,25 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + import java.util.Locale; import com.netscape.certsrv.base.EBaseException; import com.netscape.certsrv.base.MessageFormatter; + /** - * This class represents Exceptions used by the policy package. The policies - * themselves do not raise exceptions but use them to format error messages. - * + * This class represents Exceptions used by the policy package. + * The policies themselves do not raise exceptions but use them + * to format error messages. + * * Adapted from EBasException * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ * @see java.text.MessageFormat @@ -47,13 +49,12 @@ public class EPolicyException extends EBaseException { /** * Resource class name. */ - private static final String POLICY_RESOURCES = PolicyResources.class - .getName(); + private static final String POLICY_RESOURCES = PolicyResources.class.getName(); /** * Constructs a base exception. * <P> - * + * * @param msgFormat exception details */ public EPolicyException(String msgFormat) { @@ -63,12 +64,11 @@ public class EPolicyException extends EBaseException { /** * Constructs a base exception with a parameter. For example, - * * <PRE> - * new EPolicyException("failed to load {0}", fileName); + * new EPolicyException("failed to load {0}", fileName); * </PRE> * <P> - * + * * @param msgFormat exception details in message string format * @param param message string parameter */ @@ -81,7 +81,7 @@ public class EPolicyException extends EBaseException { /** * Constructs a base exception with two String parameters. For example, * <P> - * + * * @param msgFormat exception details in message string format * @param param1 message string parameter * @param param2 message string parameter @@ -94,9 +94,9 @@ public class EPolicyException extends EBaseException { } /** - * Constructs a base exception. It can be used to carry a system exception - * that may contain information about the context. For example, - * + * Constructs a base exception. It can be used to carry + * a system exception that may contain information about + * the context. For example, * <PRE> * try { * ... @@ -105,7 +105,7 @@ public class EPolicyException extends EBaseException { * } * </PRE> * <P> - * + * * @param msgFormat exception details in message string format * @param param system exception */ @@ -116,10 +116,10 @@ public class EPolicyException extends EBaseException { } /** - * Constructs a base exception with a list of parameters that will be - * substituted into the message format. + * Constructs a base exception with a list of parameters + * that will be substituted into the message format. * <P> - * + * * @param msgFormat exception details in message string format * @param params list of message format parameters */ @@ -131,7 +131,7 @@ public class EPolicyException extends EBaseException { /** * Returns a list of parameters. * <P> - * + * * @return list of message format parameters */ public Object[] getParameters() { @@ -139,10 +139,10 @@ public class EPolicyException extends EBaseException { } /** - * Returns localized exception string. This method should only be called if - * a localized string is necessary. + * Returns localized exception string. This method should + * only be called if a localized string is necessary. * <P> - * + * * @return details message */ public String toString() { @@ -152,7 +152,7 @@ public class EPolicyException extends EBaseException { /** * Returns the string based on the given locale. * <P> - * + * * @param locale locale * @return details message */ diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IEnrollmentPolicy.java b/pki/base/common/src/com/netscape/certsrv/policy/IEnrollmentPolicy.java index 04de34341..bfd0e7c20 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IEnrollmentPolicy.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IEnrollmentPolicy.java @@ -17,18 +17,20 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + /** - * Interface for an enrollment policy rule. This provides general typing for - * rules so that a policy processor can group rules based on a particular type. + * Interface for an enrollment policy rule. This provides general + * typing for rules so that a policy processor can group rules + * based on a particular type. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ public interface IEnrollmentPolicy extends IPolicyRule { } + diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IExpression.java b/pki/base/common/src/com/netscape/certsrv/policy/IExpression.java index f66253aad..6bed58c5d 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IExpression.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IExpression.java @@ -17,17 +17,18 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + import com.netscape.certsrv.request.IRequest; + /** * Interface for a policy expression. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ @@ -47,11 +48,12 @@ public interface IExpression { /** * Evaluate the Expression. - * - * @param req The PKIRequest on which we are applying the condition. - * @return The return value. + * + * @param req The PKIRequest on which we are applying the condition. + * @return The return value. */ - boolean evaluate(IRequest req) throws EPolicyException; + boolean evaluate(IRequest req) + throws EPolicyException; /** * Convert to a string. diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameAsConstraintsConfig.java b/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameAsConstraintsConfig.java index 33eaa2983..ff30dc11b 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameAsConstraintsConfig.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameAsConstraintsConfig.java @@ -17,20 +17,21 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + import java.util.Vector; import netscape.security.x509.GeneralName; -/** - * Class that can be used to form general names from configuration file. Used by - * policies and extension commands. + +/** + * Class that can be used to form general names from configuration file. + * Used by policies and extension commands. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ @@ -38,14 +39,14 @@ public interface IGeneralNameAsConstraintsConfig { /** * Retrieves instance parameters. - * + * * @param params parameters */ public void getInstanceParams(Vector params); /** * Retrieves the general name. - * + * * @return general name */ public GeneralName getGeneralName(); diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameConfig.java b/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameConfig.java index 06badb548..1f93719d3 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameConfig.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameConfig.java @@ -17,22 +17,23 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + import java.util.Vector; import netscape.security.x509.GeneralName; import com.netscape.certsrv.base.EBaseException; -/** - * Class that can be used to form general names from configuration file. Used by - * policies and extension commands. + +/** + * Class that can be used to form general names from configuration file. + * Used by policies and extension commands. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ @@ -40,25 +41,27 @@ public interface IGeneralNameConfig { /** * Forms a general name from string. - * + * * @param value general name in string * @return general name object * @exception EBaseException failed to form general name */ - public GeneralName formGeneralName(String value) throws EBaseException; + public GeneralName formGeneralName(String value) + throws EBaseException; /** * Forms general names from the given value. - * + * * @param value general name in string * @return a vector of general names * @exception EBaseException failed to form general name */ - public Vector formGeneralNames(Object value) throws EBaseException; + public Vector formGeneralNames(Object value) + throws EBaseException; /** * Retrieves the instance parameters. - * + * * @param params parameters */ public void getInstanceParams(Vector params); diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameUtil.java b/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameUtil.java index 7987dd2c3..c1526284a 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameUtil.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNameUtil.java @@ -17,16 +17,16 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; -/** - * Class that can be used to form general names from configuration file. Used by - * policies and extension commands. + +/** + * Class that can be used to form general names from configuration file. + * Used by policies and extension commands. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ @@ -51,27 +51,30 @@ public interface IGeneralNameUtil { */ public static final int DEF_NUM_GENERALNAMES = 8; - /** + /** * Default extended plugin info. */ - public static String NUM_GENERALNAMES_INFO = "number;The total number of alternative names or identities permitted in the extension."; - public static String GENNAME_CHOICE_INFO = "choice(" - + IGeneralNameUtil.GENNAME_CHOICE_RFC822NAME + "," - + IGeneralNameUtil.GENNAME_CHOICE_DIRECTORYNAME + "," - + IGeneralNameUtil.GENNAME_CHOICE_DNSNAME + "," - + IGeneralNameUtil.GENNAME_CHOICE_EDIPARTYNAME + "," - + IGeneralNameUtil.GENNAME_CHOICE_URL + "," - + IGeneralNameUtil.GENNAME_CHOICE_IPADDRESS + "," - + IGeneralNameUtil.GENNAME_CHOICE_REGISTEREDID + "," - + IGeneralNameUtil.GENNAME_CHOICE_OTHERNAME + ");" - + "GeneralName choice. See RFC 2459 appendix B2 on GeneralName."; - public static String GENNAME_VALUE_INFO = "string;Value according to the GeneralName choice."; + public static String + NUM_GENERALNAMES_INFO = "number;The total number of alternative names or identities permitted in the extension."; + public static String GENNAME_CHOICE_INFO = + "choice(" + + IGeneralNameUtil.GENNAME_CHOICE_RFC822NAME + "," + + IGeneralNameUtil.GENNAME_CHOICE_DIRECTORYNAME + "," + + IGeneralNameUtil.GENNAME_CHOICE_DNSNAME + "," + + IGeneralNameUtil.GENNAME_CHOICE_EDIPARTYNAME + "," + + IGeneralNameUtil.GENNAME_CHOICE_URL + "," + + IGeneralNameUtil.GENNAME_CHOICE_IPADDRESS + "," + + IGeneralNameUtil.GENNAME_CHOICE_REGISTEREDID + "," + + IGeneralNameUtil.GENNAME_CHOICE_OTHERNAME + ");" + + "GeneralName choice. See RFC 2459 appendix B2 on GeneralName."; + public static String GENNAME_VALUE_INFO = + "string;Value according to the GeneralName choice."; - public static String PROP_NUM_GENERALNAMES_INFO = PROP_NUM_GENERALNAMES - + ";" + NUM_GENERALNAMES_INFO; - public static String PROP_GENNAME_CHOICE_INFO = PROP_GENNAME_CHOICE + ";" - + GENNAME_CHOICE_INFO; - public static String PROP_GENNAME_VALUE_INFO = PROP_GENNAME_VALUE + ";" - + GENNAME_VALUE_INFO; + public static String + PROP_NUM_GENERALNAMES_INFO = PROP_NUM_GENERALNAMES + ";" + NUM_GENERALNAMES_INFO; + public static String + PROP_GENNAME_CHOICE_INFO = PROP_GENNAME_CHOICE + ";" + GENNAME_CHOICE_INFO; + public static String + PROP_GENNAME_VALUE_INFO = PROP_GENNAME_VALUE + ";" + GENNAME_VALUE_INFO; } diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNamesAsConstraintsConfig.java b/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNamesAsConstraintsConfig.java index 75c21f2bd..e64187b86 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNamesAsConstraintsConfig.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNamesAsConstraintsConfig.java @@ -17,20 +17,21 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + import java.util.Vector; import netscape.security.x509.GeneralNames; -/** - * Class that can be used to form general names from configuration file. Used by - * policies and extension commands. + +/** + * Class that can be used to form general names from configuration file. + * Used by policies and extension commands. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ @@ -38,14 +39,14 @@ public interface IGeneralNamesAsConstraintsConfig { /** * Retrieves a list of configured general names. - * + * * @return a list of general names */ public GeneralNames getGeneralNames(); /** * Retrieves instance parameters. - * + * * @param params instance parameters */ public void getInstanceParams(Vector params); diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNamesConfig.java b/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNamesConfig.java index 197a25317..644258567 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNamesConfig.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IGeneralNamesConfig.java @@ -17,20 +17,21 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + import java.util.Vector; import netscape.security.x509.GeneralNames; -/** - * Class that can be used to form general names from configuration file. Used by - * policies and extension commands. + +/** + * Class that can be used to form general names from configuration file. + * Used by policies and extension commands. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ @@ -38,14 +39,14 @@ public interface IGeneralNamesConfig { /** * Retrieves a list of configured general names. - * + * * @return general names */ public GeneralNames getGeneralNames(); /** * Retrieves the instance parameters. - * + * * @param params instance parameters */ public void getInstanceParams(Vector params); diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IKeyArchivalPolicy.java b/pki/base/common/src/com/netscape/certsrv/policy/IKeyArchivalPolicy.java index 14a29256f..13ba5f616 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IKeyArchivalPolicy.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IKeyArchivalPolicy.java @@ -17,17 +17,18 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + /** * Interface for a key recovery policy rule. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ public interface IKeyArchivalPolicy extends IPolicyRule { } + diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IKeyRecoveryPolicy.java b/pki/base/common/src/com/netscape/certsrv/policy/IKeyRecoveryPolicy.java index 6de615673..1d173f28f 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IKeyRecoveryPolicy.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IKeyRecoveryPolicy.java @@ -17,17 +17,18 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + /** * Interface for a key recovery policy rule. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ public interface IKeyRecoveryPolicy extends IPolicyRule { } + diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IPolicyPredicateParser.java b/pki/base/common/src/com/netscape/certsrv/policy/IPolicyPredicateParser.java index 641932faa..7b5f44650 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IPolicyPredicateParser.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IPolicyPredicateParser.java @@ -17,15 +17,15 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + /** * Interface for policy predicate parsers. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ @@ -33,10 +33,11 @@ public interface IPolicyPredicateParser { /** * Parse the predicate expression and return a vector of expressions. - * - * @param predicateExpression The predicate expression as read from the - * config file. - * @return expVector The vector of expressions. + * + * @param predicateExpression The predicate expression as read from the + * config file. + * @return expVector The vector of expressions. */ - IExpression parse(String predicateExpression) throws EPolicyException; + IExpression parse(String predicateExpression) + throws EPolicyException; } diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IPolicyProcessor.java b/pki/base/common/src/com/netscape/certsrv/policy/IPolicyProcessor.java index 5e2d297f9..834d462e0 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IPolicyProcessor.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IPolicyProcessor.java @@ -17,6 +17,7 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + import java.util.Enumeration; import java.util.Hashtable; import java.util.Vector; @@ -24,22 +25,22 @@ import java.util.Vector; import com.netscape.certsrv.base.EBaseException; import com.netscape.certsrv.base.ISubsystem; + /** - * A generic interface for a policy processor. By making a processor extend the - * policy interface, we make even the processor a rule - which makes sense - * because a processor may be based on some rule such as evaluate all policies - * before returning the final result or return as soon as one of the policies - * return a failure and so on. - * - * By making both processor and policy rules implement a common interface, one - * can write rules that are processors as well. + * A generic interface for a policy processor. By making a processor + * extend the policy interface, we make even the processor a rule - + * which makes sense because a processor may be based on some rule + * such as evaluate all policies before returning the final result or + * return as soon as one of the policies return a failure and so on. + * + * By making both processor and policy rules implement a common + * interface, one can write rules that are processors as well. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ @@ -60,40 +61,42 @@ public interface IPolicyProcessor extends ISubsystem, /** * Returns the policy substore id. - * - * @return storeID The policy store id used by this processor. + * + * @return storeID The policy store id used by this processor. */ String getPolicySubstoreId(); /** * Returns information on Policy impls. - * - * @return An enumeration of strings describing the information about policy - * implementations. Currently only the the implementation id is - * expected. + * + * @return An enumeration of strings describing the information + * about policy implementations. Currently only the + * the implementation id is expected. */ Enumeration getPolicyImplsInfo(); /** * Returns the rule implementations registered with this processor. - * - * @return An Enumeration of uninitialized IPolicyRule objects. + * + * @return An Enumeration of uninitialized IPolicyRule + * objects. */ Enumeration getPolicyImpls(); /** * Returns an implementation identified by a given id. - * - * @param id The implementation id. + * + * @param id The implementation id. * @return The uninitialized instance of the policy rule. */ IPolicyRule getPolicyImpl(String id); /** - * Returns configuration for an implmentation. - * - * @param id The implementation id. - * @return A vector of name/value pairs in the form of name=value. + * Returns configuration for an implmentation. + * + * @param id The implementation id. + * @return A vector of name/value pairs in the form of + * name=value. */ Vector getPolicyImplConfig(String id); @@ -101,48 +104,53 @@ public interface IPolicyProcessor extends ISubsystem, * Deletes a policy implementation identified by an impl id. * * - * @param id The impl id of the policy to be deleted. There shouldn't be any - * active instance for this implementation. + * @param id The impl id of the policy to be deleted. + * There shouldn't be any active instance for this + * implementation. * @exception EBaseException is thrown if an error occurs in deletion. */ - void deletePolicyImpl(String id) throws EBaseException; + void deletePolicyImpl(String id) + throws EBaseException; /** * Adds a policy implementation identified by an impl id. * - * @param id The impl id of the policy to be added. The id should be unique. - * @param classPath The fully qualified path for the implementation. + * @param id The impl id of the policy to be added. + * The id should be unique. + * @param classPath The fully qualified path for the implementation. * @exception EBaseException is thrown if an error occurs in addition. */ - void addPolicyImpl(String id, String classPath) throws EBaseException; + void addPolicyImpl(String id, String classPath) + throws EBaseException; /** * Returns information on Policy instances. - * - * @return An Enumeration of Strings describing the information about policy - * rule instances. + * + * @return An Enumeration of Strings describing the information + * about policy rule instances. */ Enumeration getPolicyInstancesInfo(); /** * Returns policy instances registered with this processor. - * + * * @return An Enumeration of policy instances. */ Enumeration getPolicyInstances(); /** * Returns instance configuration for a given instance id. - * - * @param id The rule id. - * @return A vector of name/value pairs in the form of name=value. + * + * @param id The rule id. + * @return A vector of name/value pairs in the form of + * name=value. */ Vector getPolicyInstanceConfig(String id); /** * Returns instance configuration for a given instance id. - * - * @param id The rule id. + * + * @param id The rule id. * @return the policy instance identified by the id. */ IPolicyRule getPolicyInstance(String id); @@ -150,36 +158,41 @@ public interface IPolicyProcessor extends ISubsystem, /** * Deletes a policy instance identified by an instance id. * - * @param id The instance id of the policy to be deleted. + * @param id The instance id of the policy to be deleted. * @exception EBaseException is thrown if an error occurs in deletion. */ - void deletePolicyInstance(String id) throws EBaseException; + void deletePolicyInstance(String id) + throws EBaseException; /** - * Adds a policy instance + * Adds a policy instance * - * @param id The impl id of the policy to be added. The id should be unique. + * @param id The impl id of the policy to be added. + * The id should be unique. * @param ht a Hashtable of config params. * @exception EBaseException is thrown if an error occurs in addition. */ - void addPolicyInstance(String id, Hashtable ht) throws EBaseException; + void addPolicyInstance(String id, Hashtable ht) + throws EBaseException; /** - * Modifies a policy instance + * Modifies a policy instance * - * @param id The impl id of the policy to be modified. The policy instance - * with this id should be present. + * @param id The impl id of the policy to be modified. + * The policy instance with this id should be present. * @param ht a Hashtable of config params. * @exception EBaseException is thrown if an error occurs in addition. */ - void modifyPolicyInstance(String id, Hashtable ht) throws EBaseException; + void modifyPolicyInstance(String id, Hashtable ht) + throws EBaseException; /** * Modifies policy ordering. - * + * * @param policyOrderStr The comma separated list of instance ids. - * + * */ void changePolicyInstanceOrdering(String policyOrderStr) - throws EBaseException; + throws EBaseException; } + diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IPolicyRule.java b/pki/base/common/src/com/netscape/certsrv/policy/IPolicyRule.java index aa4dcde84..d80a0d0c2 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IPolicyRule.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IPolicyRule.java @@ -17,6 +17,7 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + import java.util.Vector; import com.netscape.certsrv.base.EBaseException; @@ -25,19 +26,20 @@ import com.netscape.certsrv.base.ISubsystem; import com.netscape.certsrv.request.IRequest; import com.netscape.certsrv.request.PolicyResult; + /** * Interface for a policy rule. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ -public interface IPolicyRule extends com.netscape.certsrv.request.IPolicy { +public interface IPolicyRule + extends com.netscape.certsrv.request.IPolicy { public static final String PROP_ENABLE = "enable"; public static final String PROP_PREDICATE = "predicate"; public static final String PROP_IMPLNAME = "implName"; @@ -45,15 +47,15 @@ public interface IPolicyRule extends com.netscape.certsrv.request.IPolicy { /** * Initializes the policy rule. * <P> - * + * * @param config The config store reference */ - void init(ISubsystem owner, IConfigStore config) throws EBaseException; + void init(ISubsystem owner, IConfigStore config) + throws EBaseException; /** * Gets the description for this policy rule. * <P> - * * @return The Description for this rule. */ String getDescription(); @@ -61,7 +63,7 @@ public interface IPolicyRule extends com.netscape.certsrv.request.IPolicy { /** * Returns the name of the policy rule class. * <P> - * + * * @return The name of the policy class. */ String getName(); @@ -69,52 +71,52 @@ public interface IPolicyRule extends com.netscape.certsrv.request.IPolicy { /** * Returns the name of the policy rule instance. * <P> - * - * @return The name of the policy rule instance. If none is set the name of - * the implementation will be returned. - * + * + * @return The name of the policy rule instance. If none + * is set the name of the implementation will be returned. + * */ String getInstanceName(); /** * Sets a predicate expression for rule matching. * <P> - * - * @param exp The predicate expression for the rule. + * + * @param exp The predicate expression for the rule. */ void setPredicate(IExpression exp); /** * Returns the predicate expression for the rule. * <P> - * + * * @return The predicate expression for the rule. */ IExpression getPredicate(); /** - * Applies the policy on the given Request. This may modify the request - * appropriately. + * Applies the policy on the given Request. This may modify + * the request appropriately. * <P> - * - * @param req The request on which to apply policy. + * + * @param req The request on which to apply policy. * @return The PolicyResult object. */ PolicyResult apply(IRequest req); /** * Return configured parameters for a policy rule instance. - * - * @return nvPairs A Vector of name/value pairs. Each name/value pair is - * constructed as a String in name=value format. + * + * @return nvPairs A Vector of name/value pairs. Each name/value + * pair is constructed as a String in name=value format. */ public Vector getInstanceParams(); /** * Return default parameters for a policy implementation. - * - * @return nvPairs A Vector of name/value pairs. Each name/value pair is - * constructed as a String in name=value. + * + * @return nvPairs A Vector of name/value pairs. Each name/value + * pair is constructed as a String in name=value. */ public Vector getDefaultParams(); @@ -124,3 +126,4 @@ public interface IPolicyRule extends com.netscape.certsrv.request.IPolicy { public void setPolicyException(IRequest req, EBaseException ex); } + diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IPolicySet.java b/pki/base/common/src/com/netscape/certsrv/policy/IPolicySet.java index 0218cd476..ea12f4b1b 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IPolicySet.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IPolicySet.java @@ -17,27 +17,28 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + import java.util.Enumeration; import com.netscape.certsrv.request.IRequest; import com.netscape.certsrv.request.PolicyResult; + /** - * Represents a set of policy rules. Policy rules are ordered from lowest - * priority to highest priority. The priority assignment for rules is not - * enforced by this interface. Various implementation may use different - * mechanisms such as a linear ordering of rules in a configuration file or - * explicit assignment of priority levels ..etc. The policy system - * initialization needs to deal with reading the rules, sorting them in - * increasing order of priority and presenting an ordered vector of rules via - * the IPolicySet interface. + * Represents a set of policy rules. Policy rules are ordered from + * lowest priority to highest priority. The priority assignment for rules + * is not enforced by this interface. Various implementation may + * use different mechanisms such as a linear ordering of rules + * in a configuration file or explicit assignment of priority levels ..etc. + * The policy system initialization needs to deal with reading the rules, sorting + * them in increasing order of priority and presenting an ordered vector of rules + * via the IPolicySet interface. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ @@ -46,7 +47,7 @@ public interface IPolicySet { /** * Returns the name of the rule set. * <P> - * + * * @return The name of the rule set. */ String getName(); @@ -54,7 +55,6 @@ public interface IPolicySet { /** * Returns the no of rules in a set. * <P> - * * @return the no of rules. */ int count(); @@ -62,24 +62,24 @@ public interface IPolicySet { /** * Add a policy rule. * <P> - * + * * @param ruleName The name of the rule to be added. - * @param rule The rule to be added. + * @param rule The rule to be added. */ void addRule(String ruleName, IPolicyRule rule); /** * Removes a policy rule identified by the given name. - * - * @param ruleName The name of the rule to be removed. + * + * @param ruleName The name of the rule to be removed. */ void removeRule(String ruleName); /** * Returns the rule identified by a given name. * <P> - * - * @param ruleName The name of the rule to be return. + * + * @param ruleName The name of the rule to be return. * @return The rule identified by the given name or null if none exists. */ IPolicyRule getRule(String ruleName); @@ -87,19 +87,20 @@ public interface IPolicySet { /** * Returns an enumeration of rules. * <P> - * + * * @return An enumeration of rules. */ Enumeration getRules(); /** - * Apply policy rules on a request. This call may modify the request - * content. - * - * @param req The request to apply policies on. - * - * <P> + * Apply policy rules on a request. This call may modify + * the request content. + * + * @param req The request to apply policies on. + * + * <P> * @return The policy result. */ PolicyResult apply(IRequest req); } + diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IRenewalPolicy.java b/pki/base/common/src/com/netscape/certsrv/policy/IRenewalPolicy.java index 28f56fe73..7bf2026e2 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IRenewalPolicy.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IRenewalPolicy.java @@ -17,17 +17,18 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + /** * Interface for a renewal policy rule. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ public interface IRenewalPolicy extends IPolicyRule { } + diff --git a/pki/base/common/src/com/netscape/certsrv/policy/IRevocationPolicy.java b/pki/base/common/src/com/netscape/certsrv/policy/IRevocationPolicy.java index 7e6084c76..e0ecfb16f 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/IRevocationPolicy.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/IRevocationPolicy.java @@ -17,17 +17,18 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + /** * Interface for a revocation policy rule. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ public interface IRevocationPolicy extends IPolicyRule { } + diff --git a/pki/base/common/src/com/netscape/certsrv/policy/ISubjAltNameConfig.java b/pki/base/common/src/com/netscape/certsrv/policy/ISubjAltNameConfig.java index 388bd4056..75df22de1 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/ISubjAltNameConfig.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/ISubjAltNameConfig.java @@ -17,16 +17,18 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; -/** - * Class that can be used to form general names from configuration file. Used by - * policies and extension commands. + + + +/** + * Class that can be used to form general names from configuration file. + * Used by policies and extension commands. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ */ @@ -34,14 +36,14 @@ public interface ISubjAltNameConfig extends IGeneralNameConfig { /** * Retrieves configuration prefix. - * + * * @return prefix */ public String getPfx(); /** * Retrieves configuration attribute. - * + * * @return attribute */ public String getAttr(); diff --git a/pki/base/common/src/com/netscape/certsrv/policy/PolicyResources.java b/pki/base/common/src/com/netscape/certsrv/policy/PolicyResources.java index d330b719f..c8bcec2ce 100644 --- a/pki/base/common/src/com/netscape/certsrv/policy/PolicyResources.java +++ b/pki/base/common/src/com/netscape/certsrv/policy/PolicyResources.java @@ -17,17 +17,18 @@ // --- END COPYRIGHT BLOCK --- package com.netscape.certsrv.policy; + import java.util.ListResourceBundle; + /** * Error messages for Policies. * <P> - * * <PRE> * NOTE: The Policy Framework has been replaced by the Profile Framework. * </PRE> * <P> - * + * * @deprecated * @version $Revision$, $Date$ * @see java.util.ListResourceBundle |