com.sun.syndication.feed.synd

## Class SyndEnclosureImpl

- java.lang.Object
- - com.sun.syndication.feed.synd.SyndEnclosureImpl

All Implemented Interfaces:
  CopyFrom, SyndEnclosure, java.io.Serializable, java.lang.Cloneable

    public class SyndEnclosureImpl
    extends java.lang.Object
    implements java.io.Serializable, SyndEnclosure

See Also:
  Serialized Form

### Constructor Summary

Constructors
Constructor and Description
`SyndEnclosureImpl()` Default constructor.

### Method Summary

All Methods Instance Methods Concrete Methods
`java.lang.Object` `clone()` Creates a deep 'bean' clone of the object.
`void` `copyFrom(java.lang.Object obj)` Copies all the properties of the given bean into this one.
`boolean` `equals(java.lang.Object other)` Indicates whether some other object is "equal to" this one as defined by the Object equals() method.
`java.lang.Class` `getInterface()` Returns the interface the copyFrom works on.
`long` `getLength()` Returns the enclosure length.
`java.lang.String` `getType()` Returns the enclosure type.
`java.lang.String` `getUrl()` Returns the enclosure URL.
`int` `hashCode()` Returns a hashcode value for the object.
`void` `setLength(long length)` Sets the enclosure length.
`void` `setType(java.lang.String type)` Sets the enclosure type.
`void` `setUrl(java.lang.String url)` Sets the enclosure URL.
`java.lang.String` `toString()` Returns the String representation for the object.

### Methods inherited from class java.lang.Object

`finalize, getClass, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### SyndEnclosureImpl

    public SyndEnclosureImpl()

Default constructor. All properties are set to null.

### Method Detail

#### clone

    public java.lang.Object clone()
                           throws java.lang.CloneNotSupportedException

Creates a deep 'bean' clone of the object.

Overrides:
  `clone` in class `java.lang.Object`
Returns:
  a clone of the object.
Throws:
  `java.lang.CloneNotSupportedException` - thrown if an element of the object cannot be cloned.

#### equals

    public boolean equals(java.lang.Object other)

Indicates whether some other object is "equal to" this one as defined by the Object equals() method.

Overrides:
  `equals` in class `java.lang.Object`
Parameters:
  `other` - he reference object with which to compare.
Returns:
  true if 'this' object is equal to the 'other' object.

#### hashCode

    public int hashCode()

Returns a hashcode value for the object.

It follows the contract defined by the Object hashCode() method.

Overrides:
  `hashCode` in class `java.lang.Object`
Returns:
  the hashcode of the bean object.

#### toString

    public java.lang.String toString()

Returns the String representation for the object.

Overrides:
  `toString` in class `java.lang.Object`
Returns:
  String representation for the object.

#### getUrl

    public java.lang.String getUrl()

Returns the enclosure URL.

Specified by:
  `getUrl` in interface `SyndEnclosure`
Returns:
  the enclosure URL, null if none.

#### setUrl

    public void setUrl(java.lang.String url)

Sets the enclosure URL.

Specified by:
  `setUrl` in interface `SyndEnclosure`
Parameters:
  `url` - the enclosure URL to set, null if none.

#### getLength

    public long getLength()

Returns the enclosure length.

Specified by:
  `getLength` in interface `SyndEnclosure`
Returns:
  the enclosure length, null if none.

#### setLength

    public void setLength(long length)

Sets the enclosure length.

Specified by:
  `setLength` in interface `SyndEnclosure`
Parameters:
  `length` - the enclosure length to set, null if none.

#### getType

    public java.lang.String getType()

Returns the enclosure type.

Specified by:
  `getType` in interface `SyndEnclosure`
Returns:
  the enclosure type, null if none.

#### setType

    public void setType(java.lang.String type)

Sets the enclosure type.

Specified by:
  `setType` in interface `SyndEnclosure`
Parameters:
  `type` - the enclosure type to set, null if none.

#### getInterface

    public java.lang.Class getInterface()

Description copied from interface: `CopyFrom`
Returns the interface the copyFrom works on.

This is useful when dealing with properties that may have multiple implementations. For example, Module.

Specified by:
  `getInterface` in interface `CopyFrom`
Returns:
  the interface the copyFrom works on.

#### copyFrom

    public void copyFrom(java.lang.Object obj)

Description copied from interface: `CopyFrom`
Copies all the properties of the given bean into this one.

Any existing properties in this bean are lost.

This method is useful for moving from one implementation of a bean interface to another. For example from the default SyndFeed bean implementation to a Hibernate ready implementation.

Specified by:
  `copyFrom` in interface `CopyFrom`
Parameters:
  `obj` - the instance to copy properties from.