Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.ivy.plugins.repository
Class LazyResource

    java.lang.Object
      org.apache.ivy.plugins.repository.LazyResource

All Implemented Interfaces:
  Resource

Direct Known Subclasses:
  VsftpResource

    public abstract class LazyResource

extends java.lang.Object
implements Resource

Constructor Summary
`LazyResource(java.lang.String name)`

Method Summary
`boolean` | `exists()` Determine if the resource is available.
`long` | `getContentLength()` Get the resource size
`long` | `getLastModified()` Get the date the resource was last modified
`java.lang.String` | `getName()` Get the name of the resource.
`protected abstract void` | `init()`
`protected void` | `init(Resource r)`
`boolean` | `isLocal()` Is this resource local to this host, i.e. is it on the file system?
`protected void` | `setContentLength(long contentLength)`
`protected void` | `setExists(boolean exists)`
`protected void` | `setLastModified(long lastModified)`
`protected void` | `setLocal(boolean local)`
`java.lang.String` | `toString()`

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

Methods inherited from interface org.apache.ivy.plugins.repository.Resource
`clone, openStream`

Constructor Detail

### LazyResource

    public LazyResource(java.lang.String name)

Method Detail

### init

    protected abstract void init()

### exists

    public boolean exists()

  Description copied from interface: `Resource`
  Determine if the resource is available. Note that this method only checks for availability, not for actual existence.

  Specified by:
    `exists` in interface `Resource`
  Returns:
    `boolean` value indicating if the resource is available.

### getContentLength

    public long getContentLength()

  Description copied from interface: `Resource`
  Get the resource size

  Specified by:
    `getContentLength` in interface `Resource`
  Returns:
    a `long` value representing the size of the resource in bytes.

### getLastModified

    public long getLastModified()

  Description copied from interface: `Resource`
  Get the date the resource was last modified

  Specified by:
    `getLastModified` in interface `Resource`
  Returns:
    A `long` value representing the time the file was last modified, measured in milliseconds since the epoch (00:00:00 GMT, January 1, 1970), or `0L` if the file does not exist or if an I/O error occurs.

### getName

    public java.lang.String getName()

  Description copied from interface: `Resource`
  Get the name of the resource.

  Specified by:
    `getName` in interface `Resource`
  Returns:
    the repositorie's assigned resource name/identifier.

### isLocal

    public boolean isLocal()

  Description copied from interface: `Resource`
  Is this resource local to this host, i.e. is it on the file system?

  Specified by:
    `isLocal` in interface `Resource`
  Returns:
    `boolean` value indicating if the resource is local.

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

### setContentLength

    protected void setContentLength(long contentLength)

### setExists

    protected void setExists(boolean exists)

### setLastModified

    protected void setLastModified(long lastModified)

### setLocal

    protected void setLocal(boolean local)

### init

    protected void init(Resource r)

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD