FileDocCategorySizeDatePackage
SecurityConstraintImpl.javaAPI DocGlassfish v2 API5937Fri May 04 22:31:22 BST 2007None

SecurityConstraintImpl

public class SecurityConstraintImpl extends Descriptor implements com.sun.enterprise.deployment.web.SecurityConstraint, Serializable
Objects exhibiting this interface represent a security constraint on the web application that owns them.
author
Danny Coward

Fields Summary
private Set
webResourceCollections
private com.sun.enterprise.deployment.web.AuthorizationConstraint
authorizationConstraint
private com.sun.enterprise.deployment.web.UserDataConstraint
userDataConstraint
Constructors Summary
public SecurityConstraintImpl()
Default constructor.

    
    
public SecurityConstraintImpl(SecurityConstraintImpl other)
Copy constructor.

	this.webResourceCollections = new HashSet(other.webResourceCollections);
	if (other.authorizationConstraint != null) {
	    this.authorizationConstraint = new AuthorizationConstraintImpl((AuthorizationConstraintImpl) other.authorizationConstraint);
	}
	if (other.userDataConstraint != null) {
	    this.userDataConstraint = new UserDataConstraintImpl();
	    this.userDataConstraint.setTransportGuarantee(other.userDataConstraint.getTransportGuarantee());
	}
    
Methods Summary
public voidaddWebResourceCollection(com.sun.enterprise.deployment.web.WebResourceCollection webResourceCollection)
Adds a web resource collection to this constraint.

	this.getWebResourceCollectionSet().add(webResourceCollection);
    
public voidaddWebResourceCollection(WebResourceCollectionImpl webResourceCollection)

    
        addWebResourceCollection((WebResourceCollection) webResourceCollection);
    
public com.sun.enterprise.deployment.web.AuthorizationConstraintgetAuthorizationConstraint()
The authorization constraint.

	return this.authorizationConstraint;
    
public com.sun.enterprise.deployment.web.UserDataConstraintgetUserDataConstraint()
The user data constraint.

	return this.userDataConstraint;
    
public java.util.SetgetWebResourceCollectionSet()
Return all the web resource collection.

	if (this.webResourceCollections == null) {
	    this.webResourceCollections = new HashSet();
	}
	return this.webResourceCollections;
    
public java.util.EnumerationgetWebResourceCollections()
The collection of URL pattern plus HTTP methods that are constrained.

	return (new Vector(this.getWebResourceCollectionSet())).elements();
    
public voidprint(java.lang.StringBuffer toStringBuffer)
Returns a formatted String representing of my state.

	toStringBuffer.append("SecurityConstraint: ");
	toStringBuffer.append(" webResourceCollections: ").append(webResourceCollections);
	toStringBuffer.append(" authorizationConstraint ").append(authorizationConstraint);
	toStringBuffer.append(" userDataConstraint ").append(userDataConstraint);
    
    
public voidremoveWebResourceCollection(com.sun.enterprise.deployment.web.WebResourceCollection webResourceCollection)
Removes the given web resource collection from this constraint.

	this.getWebResourceCollectionSet().remove(webResourceCollection);
    
public voidsetAuthorizationConstraint(AuthorizationConstraintImpl authorizationConstraint)
Sets the authorization constraint.

	setAuthorizationConstraint((AuthorizationConstraint) authorizationConstraint);
    
public voidsetAuthorizationConstraint(com.sun.enterprise.deployment.web.AuthorizationConstraint authorizationConstraint)
Sets the authorization constraint.

	this.authorizationConstraint = authorizationConstraint;
    
public voidsetUserDataConstraint(com.sun.enterprise.deployment.web.UserDataConstraint userDataConstraint)
Sets the user data constraint.

	this.userDataConstraint = userDataConstraint;
    
public voidsetUserDataConstraint(UserDataConstraintImpl userDataConstraint)

	setUserDataConstraint((UserDataConstraint) userDataConstraint);