Overview | Package | Class | Use | Tree | Deprecated | Index | Help
|  | BEA Systems, Inc.
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## weblogic.security.service
Class WebResource

    java.lang.Object
      |
      +--weblogic.security.service.ResourceBase
            |
            +--weblogic.security.service.WebResource

Deprecated. The `WebResource` class is used by a container to specify the Web resource (and method related to the resource) that a caller is attempting to access.

The `URLResource` class should be used in place of this `WebResource` class, which is now deprecated.

The `toString` format (which is produced by the `ResourceBase` class) for a Web resource is:
`type=<web>, application=myApp, uri=/mywebapp, webResource=securityConstraintName, httpMethod=GET`

public final class WebResource
extends ResourceBase

Author:
  Copyright (c) 2002 by BEA Systems, Inc. All Rights Reserved.
See Also:
  Serialized Form

Fields inherited from class weblogic.security.service.ResourceBase
`id, length, NO_PARENT, parent, resStr, SCOPE_RESOURCE_ACTION, values`

Constructor Summary
`WebResource(java.lang.String application, java.lang.String uri, java.lang.String webResource, java.lang.String httpMethod, java.lang.String transportType)` Deprecated. Constructs a new `WebResource` with a target name composed from the `application`, `uri`, `webResource`, `httpMethod`, and `transportType` parameters.

Method Summary
`java.lang.String` | `getApplicationName()` Deprecated. Gets the name of the application associated with the `WebResource`.
`java.lang.String` | `getHttpMethod()` Deprecated. Gets the HTTP method of the Web resource.
`java.lang.String[]` | `getKeys()` Deprecated. Gets keys for the `WebResource`.
`java.lang.String` | `getResourceName()` Deprecated. Gets the name of the `WebResource`.
`java.lang.String` | `getTransportType()` Deprecated. Gets the transport guarantee required to access the `WebResource`.
`java.lang.String` | `getType()` Deprecated. Gets the type of this resource (`WebResource`).
`java.lang.String` | `getURI()` Deprecated. Gets the `URI` of the Web component.
`void` | `initialize(java.lang.String application, java.lang.String uri, java.lang.String webResource, java.lang.String httpMethod, java.lang.String transportType)` Deprecated. As of 04/01/02, the constructor should be used instead.
`protected Resource` | `makeParent()` Deprecated. Gets a `Resource` object that represents the parent of the current `WebResource`.

Methods inherited from class weblogic.security.service.ResourceBase
`appendArrayValue, appendValue, equals, getFieldType, getID, getParentResource, getRepeatingFieldIndex, getRepeatingFieldTerminatingIndex, getValues, hashCode, init, init, reset, toString, writeResourceString`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

Constructor Detail

### WebResource

    public WebResource(java.lang.String application,
                       java.lang.String uri,
                       java.lang.String webResource,
                       java.lang.String httpMethod,
                       java.lang.String transportType)

  Deprecated.
  Constructs a new `WebResource` with a target name composed from the `application`, `uri`, `webResource`, `httpMethod`, and `transportType` parameters.

  For example, if the `web.xml` deployment descriptor in `mywebapp.war` (which is inside `myApp.ear`) contains the following elements:

  `<web-app>
  <security-constraint>
  <web-resource-collection>
  <web-resource-name>MyResource</web-resource-name>
  <url-pattern>/*</url-pattern>
  </web-resource-collection>
  <auth-constraint>
  <role-name>MyRole</role-name>
  </auth-constraint>
  </security-constraint>
  ...
  </web-app>`

  If the URL to access the resource is `http://MyServer:MyPort/mywebapp/foo/bar/my.jsp?x=y`, then the context path is `"/mywebapp"`, the servlet path is `"/foo/bar/my.jsp"`, and the path info is "" (null).

  Finally, the `WebResource` is represented as `type=<web>, application=myApp, uri=/mywebapp, webResource=myResource, httpMethod=GET`.

  Parameters:
    `application` - a String indicating the name of the application in which the resource is deployed, as it appears in the corresponding `<display-name>` element. The `<display-name>` element is associated with an `<application>` element in the deployment descriptor, in an `.ear` file.

    `uri` - a String representing the `URI` of the Web component.

    `webResource` - a String representing the name of the Web resource, as it appears in the corresponding `<web-resource-name>` element in the deployment descriptor.

    `httpMethod` - a String representing the name of the HTTP method on the Web resource, as it appears in the corresponding `<http-method>` element in the deployment descriptor. A value of `null` indicates that the security policy for the resource pertains to all methods that match the other parameters of the resource specification, without consideration for the method name.

    `transportType` - a String representing the transport guarantee required to access the Web resource, as it appears in the corresponding `<transport-guarantee>` element in the deployment descriptor. A value of `null` indicates that the associated method of the Web resource can be accessed over any transport. Valid values for this parameter are restricted to the following:
    - `INTEGRAL`
    - `CONFIDENTIAL`

Method Detail

### initialize

    public void initialize(java.lang.String application,
                           java.lang.String uri,
                           java.lang.String webResource,
                           java.lang.String httpMethod,
                           java.lang.String transportType)

  Deprecated. As of 04/01/02, the constructor should be used instead.

  Replaces `application`, `uri`, `webResource`, `httpMethod`, and `transportType` parameters of the resource with the specified values.

  Parameters:
    `application` - a String indicating the name of the application in which the resource is deployed, as it appears in the corresponding `<display-name>` element. The `<display-name>` element is associated with an `<application>` element in the deployment descriptor, in an `.ear` file.

    `uri` - a String representing the `URI` of the Web component.

    `webResource` - a String representing the name of the Web resource, as it appears in the corresponding `<web-resource-name>` element in the deployment descriptor.

    `httpMethod` - a String representing the name of the HTTP method on the Web resource, as it appears in the corresponding `<http-method>` element in the deployment descriptor. A value of `null` indicates that the security policy for the resource pertains to all methods that match the other parameters of the resource specification, without consideration for the method name.

    `transportType` - a String representing the transport guarantee required to access the Web resource, as it appears in the corresponding `<transport-guarantee>` element in the deployment descriptor. A value of `null` indicates that the associated method of the Web resource can be accessed over any transport. Valid values for this parameter are restricted to the following:
    - `INTEGRAL`
    - `CONFIDENTIAL`

### getType

    public java.lang.String getType()

  Deprecated.
  Gets the type of this resource (`WebResource`).

  Returns:
    the type of this resource, represented as a String.

### makeParent

    protected Resource makeParent()

  Deprecated.
  Gets a `Resource` object that represents the parent of the current `WebResource`. If the resource does not have a parent, the value of `null` must be returned.

  The parentage hierarchy for the `WebResource` (that is, the values returned from successive calls to this method) is:

  `type=<web>, application=myApp, uri=/mywebapp, webResource=securityConstraintName
  type=<web>, application=myApp, uri=/mywebapp
  type=<web>, application=myApp
  type=<app>, application=myApp
  type=<web>`

  Returns:
    the `Resource` object of the parent resource.

  Overrides:
    makeParent in class ResourceBase

### getKeys

    public java.lang.String[] getKeys()

  Deprecated.
  Gets keys for the `WebResource`.

  Returns:
    an array of Strings containing the `WebResource`'s keys.

  Overrides:
    getKeys in class ResourceBase

### getApplicationName

    public java.lang.String getApplicationName()

  Deprecated.
  Gets the name of the application associated with the `WebResource`.

  Returns:
    the name of the application associated with the `WebResource`, represented as a String.

### getURI

    public java.lang.String getURI()

  Deprecated.
  Gets the `URI` of the Web component.

  Returns:
    the `URI` of the Web component, represented as a String.

### getResourceName

    public java.lang.String getResourceName()

  Deprecated.
  Gets the name of the `WebResource`.

  Returns:
    the name of the `WebResource`, represented as a String.

### getHttpMethod

    public java.lang.String getHttpMethod()

  Deprecated.
  Gets the HTTP method of the Web resource.

  Returns:
    the name of the HTTP method on the `WebResource`, represented as a String.

### getTransportType

    public java.lang.String getTransportType()

  Deprecated.
  Gets the transport guarantee required to access the `WebResource`.

  Returns:
    the transport guarantee required to access the `WebResource`.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Documentation is available at http://e-docs.bea.com/wls/docs70
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2004 BEA Systems, Inc. All Rights Reserved.
WebLogic Server 7.0 API Reference