Top Description Inners Fields Constructors Methods
net.fortuna.ical4j.model.property

public Class Attach

extends Property
Class Inheritance
Imports
net.fortuna.ical4j.model.*, net.fortuna.ical4j.model.parameter.Encoding, .Value, net.fortuna.ical4j.util.DecoderFactory, .EncoderFactory, .Strings, .Uris, net.fortuna.ical4j.validate.ValidationException, .ValidationResult, net.fortuna.ical4j.validate.property.DescriptivePropertyValidators, org.apache.commons.codec.DecoderException, .EncoderException, org.slf4j.Logger, .LoggerFactory, java.io.UnsupportedEncodingException, java.net.URI, .URISyntaxException, java.util.Arrays, .Optional

$Id$

Created: [Apr 6, 2004]

Defines an ATTACH iCalendar component property.

      4.8.1.1 Attachment

         Property Name: ATTACH

         Purpose: The property provides the capability to associate a document
         object with a calendar component.

         Value Type: The default value type for this property is URI. The
         value type can also be set to BINARY to indicate inline binary
         encoded content information.

         Property Parameters: Non-standard, inline encoding, format type and
         value data type property parameters can be specified on this
         property.

         Conformance: The property can be specified in a "VEVENT", "VTODO",
         "VJOURNAL" or "VALARM" calendar components.

         Description: The property can be specified within "VEVENT", "VTODO",
         "VJOURNAL", or "VALARM" calendar components. This property can be
         specified multiple times within an iCalendar object.
Author
benf
See Also
DescriptivePropertyValidators#ATTACH_URI

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class

Field Summary

Modifier and TypeField and Description
private byte[]
private static final long
private URI
Inherited from net.fortuna.ical4j.model.Property:
ACKNOWLEDGEDACTIONATTACHATTENDEEBUSYTYPECALENDAR_ADDRESSCALSCALECATEGORIESCLASSCOMMENTCOMPLETEDCONTACTCOUNTRYCREATEDDESCRIPTIONDTENDDTSTAMPDTSTARTDUEDURATIONEXDATEEXPERIMENTAL_PREFIXEXRULEEXTENDED_ADDRESSFREEBUSYGEOLAST_MODIFIEDLOCALITYLOCATIONLOCATION_TYPEMETHODNAMEORGANIZERPARTICIPANT_TYPEPERCENT_COMPLETEPOSTALCODEPRIORITYPRODIDPROXIMITYRDATERECURRENCE_IDREGIONRELATED_TOREPEATREQUEST_STATUSRESOURCE_TYPERESOURCESRRULESEQUENCESTATUSSTREET_ADDRESSSTRUCTURED_DATASTYLED_DESCRIPTIONSUMMARYTELTRANSPTRIGGERTZIDTZID_ALIAS_OFTZNAMETZOFFSETFROMTZOFFSETTOTZUNTILTZURLUIDURLVERSIONXML

Constructor Summary

AccessConstructor and Description
public
Attach()

Default constructor.

public
Attach(final ParameterList
a list of parameters for this component
aList
,
final String
a value string for this component
aValue
)

public
Attach(final byte[]
binary data
data
)

public
Attach(final ParameterList
a list of parameters for this component
aList
,
final byte[]
binary data
data
)

public
Attach(final URI
a URI
aUri
)

public
Attach(final ParameterList
a list of parameters for this component
aList
,
final URI
a URI
aUri
)

Method Summary

Modifier and TypeMethod and Description
public final byte[]

Returns:

Returns the binary.
getBinary
()

public final URI

Returns:

Returns the uri.
getUri
()

public final String
protected PropertyFactory<Attach>
newFactory()

Implements abstract net.fortuna.ical4j.model.Property.newFactory.

Returns a new property factory used to create deep copies.

public final void
setBinary(final byte[]
The binary to set.
binary
)

public final void
setUri(final URI
The uri to set.
uri
)

public final void
setValue(final String
a string encoded binary or URI value
aValue
)

Implements abstract net.fortuna.ical4j.model.Property.setValue.

Sets the current value of the Attach instance.

public ValidationResult
validate()

Implements abstract net.fortuna.ical4j.model.Property.validate.

Perform validation on a property.

Inherited from net.fortuna.ical4j.model.Property:
addcompareTocopyequalsgetFluentTargetgetNamegetParametergetParametergetParameterListgetParametersgetPrefixgetRequiredParametergetRequiredParameterhashCoderemoveremoveAllreplacesetParameterssetPrefixtoString

Field Detail

binaryback to summary
private byte[] binary
serialVersionUIDback to summary
private static final long serialVersionUID

Hides net.fortuna.ical4j.model.Property.serialVersionUID.

uriback to summary
private URI uri

Constructor Detail

Attachback to summary
public Attach()

Default constructor.

Attachback to summary
public Attach(final ParameterList aList, final String aValue)
Parameters
aList:ParameterList

a list of parameters for this component

aValue:String

a value string for this component

Attachback to summary
public Attach(final byte[] data)
Parameters
data:byte[]

binary data

Attachback to summary
public Attach(final ParameterList aList, final byte[] data)
Parameters
aList:ParameterList

a list of parameters for this component

data:byte[]

binary data

Attachback to summary
public Attach(final URI aUri)
Parameters
aUri:URI

a URI

Attachback to summary
public Attach(final ParameterList aList, final URI aUri)
Parameters
aList:ParameterList

a list of parameters for this component

aUri:URI

a URI

Method Detail

getBinaryback to summary
public final byte[] getBinary()
Returns:byte[]

Returns the binary.

getUriback to summary
public final URI getUri()
Returns:URI

Returns the uri.

getValueback to summary
public final String getValue()

Implements abstract net.fortuna.ical4j.model.Content.getValue.

Returns:String

Doc from net.fortuna.ical4j.model.Content.getValue.

the content value

Annotations
@Override
newFactoryback to summary
protected PropertyFactory<Attach> newFactory()

Implements abstract net.fortuna.ical4j.model.Property.newFactory.

Doc from net.fortuna.ical4j.model.Property.newFactory.

Returns a new property factory used to create deep copies.

Returns:PropertyFactory<Attach>

a property factory instance

Annotations
@Override
setBinaryback to summary
public final void setBinary(final byte[] binary)
Parameters
binary:byte[]

The binary to set.

setUriback to summary
public final void setUri(final URI uri)
Parameters
uri:URI

The uri to set.

setValueback to summary
public final void setValue(final String aValue)

Implements abstract net.fortuna.ical4j.model.Property.setValue.

Sets the current value of the Attach instance. If the specified value is encoded binary data, the value is decoded and stored in the binary field. Otherwise the value is assumed to be a URI location to binary data and is stored as such.

Parameters
aValue:String

a string encoded binary or URI value

Annotations
@Override
validateback to summary
public ValidationResult validate() throws ValidationException

Implements abstract net.fortuna.ical4j.model.Property.validate.

Doc from net.fortuna.ical4j.model.Property.validate.

Perform validation on a property.

Annotations
@Override
Exceptions
ValidationException:
where the property is not in a valid state
net.fortuna.ical4j.model.property back to summary

public Class Attach.Factory

extends Factory
implements PropertyFactory<Attach>
Class Inheritance
All Implemented Interfaces
net.fortuna.ical4j.model.PropertyFactory, java.io.Serializable

Field Summary

Modifier and TypeField and Description
private static final long

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public Attach
createProperty(final ParameterList
a list of property parameters
parameters
,
final String
a property value
value
)

Implements net.fortuna.ical4j.model.PropertyFactory.createProperty.

public Attach
Inherited from net.fortuna.ical4j.model.Content.Factory:
supports

Field Detail

serialVersionUIDback to summary
private static final long serialVersionUID

Constructor Detail

Factoryback to summary
public Factory()

Method Detail

createPropertyback to summary
public Attach createProperty(final ParameterList parameters, final String value)

Implements net.fortuna.ical4j.model.PropertyFactory.createProperty.

Parameters
parameters:ParameterList

Doc from net.fortuna.ical4j.model.PropertyFactory.createProperty.

a list of property parameters

value:String

Doc from net.fortuna.ical4j.model.PropertyFactory.createProperty.

a property value

Returns:Attach

Doc from net.fortuna.ical4j.model.PropertyFactory.createProperty.

a new instance of the specified property

Annotations
@Override
createPropertyback to summary
public Attach createProperty()

Implements net.fortuna.ical4j.model.PropertyFactory.createProperty.

Returns:Attach

Doc from net.fortuna.ical4j.model.PropertyFactory.createProperty.

a new instance of the specified property

Annotations
@Override