|
Openwings API Documentation (v1.1) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
This interface provides the basis for defining policies in Openwings. Interfaces for custom policies extend this interface.
| Method Summary | |
java.lang.String |
getDescription()
Get the human-readable description for this Policy. |
java.net.URL |
getLastLoadURL()
Returns a URL corresponding to the last location
from which the policy was loaded. |
java.lang.String |
getName()
Get the name of this Policy. |
java.lang.String[] |
getPolicyAttributes()
Returns an array of strings that contains the attributes for the policy in the order defined in the schema. |
java.lang.String[] |
getPolicyElements()
Returns an array of strings that contains the elements for the policy in the order defined in the schema. |
boolean |
isPolicyUpdated()
Determines if this policy has been updated and is in need of being saved. |
void |
loadPolicy(java.io.File file)
Load the policy with configuration data from the File. |
void |
loadPolicy(java.net.URL url)
Load the policy with configuration data from the URL. |
void |
savePolicy()
Save the policy configuration data to the file or URL where it was originally loaded from. |
void |
savePolicy(java.io.File file)
Save the policy configuration data to the File. |
void |
savePolicy(java.net.URL url)
Save the policy configuration data to the URL. |
void |
setDescription(java.lang.String description)
Set a human-readable description for this Policy. |
void |
setName(java.lang.String name)
Assign a name to this Policy. |
void |
setPolicyUpdated(boolean policyUpdated)
Sets the update status of this policy. |
| Method Detail |
public void loadPolicy(java.net.URL url)
throws PolicyException
URL.
The values from the configuration data overwrite
any previous values stored by the Policy object.
url - The location of the policy configuration data.
throws - A PolicyException that wraps any
exception generated when attempting to load the policy data.
PolicyException
public void loadPolicy(java.io.File file)
throws PolicyException
File.
The values from the configuration data overwrite
any previous values stored by the Policy object.
file - The file for the policy configuration data.
throws - A PolicyException that wraps any
exception generated when attempting to load the policy data.
PolicyException
public void savePolicy(java.net.URL url)
throws PolicyException
URL.
url - The location for the policy configuration data.
throws - A PolicyException that wraps any
exception generated when attempting to load the policy data.
PolicyException
public void savePolicy(java.io.File file)
throws PolicyException
File.
file - The file for the policy configuration data.
throws - A PolicyException that wraps any
exception generated when attempting to load the policy data.
PolicyException
public void savePolicy()
throws PolicyException
throws - A PolicyException that wraps any
exception generated when attempting to load the policy data.
PolicyExceptionpublic void setName(java.lang.String name)
Policy. Naming is used to
distinguish between policies of the same type.
name - The name to be used in identifying the Policy.public java.lang.String getName()
Policy. Naming is used to
distinguish between policies of the same type.
Policy.public void setDescription(java.lang.String description)
Policy. The
description should be suitable for display in a graphical user interface.
description - The text to be used in describing the
Policy.public java.lang.String getDescription()
Policy. The
description should be suitable for display in a graphical user interface.
Policy.public void setPolicyUpdated(boolean policyUpdated)
public boolean isPolicyUpdated()
public java.lang.String[] getPolicyAttributes()
public java.lang.String[] getPolicyElements()
public java.net.URL getLastLoadURL()
URL corresponding to the last location
from which the policy was loaded.
|
Openwings API Documentation (v1.1) | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||