org.outerj.daisy.repository.schema
Interface PartType


public interface PartType


Method Summary
 java.lang.String getDescription(java.util.Locale locale)
           
 java.lang.String getDescriptionExact(java.util.Locale locale)
           
 long getId()
           
 java.lang.String getLabel(java.util.Locale locale)
          Gets the label in the given locale, using the usual locale fallback mechanisms if not found in the exactly specified locale, and finally returning the parttype's name if no label is available.
 java.lang.String getLabelExact(java.util.Locale locale)
           
 java.util.Date getLastModified()
          When was this PartType last changed (persistently).
 long getLastModifier()
          Who (which user) last changed this PartType (persistently).
 java.lang.String getMimeTypes()
          Returns a string describing limitations on the allowed mime-types.
 java.lang.String getName()
           
 long getUpdateCount()
           
 org.outerx.daisy.x10.PartTypeDocument getXml()
           
 boolean isDaisyHtml()
          Indicates if the content of the part is Daisy HTML (well-formed XML using HTML elements).
 boolean isDeprecated()
           
 boolean mimeTypeAllowed(java.lang.String mimeType)
           
 void save()
           
 void setAllFromXml(org.outerx.daisy.x10.PartTypeDocument.PartType partTypeXml)
          Changes the state of this object to match the given XML.
 void setDaisyHtml(boolean daisyHtml)
           
 void setDeprecated(boolean deprecated)
           
 void setDescription(java.util.Locale locale, java.lang.String description)
           
 void setLabel(java.util.Locale locale, java.lang.String label)
           
 void setMimeTypes(java.lang.String mimeTypes)
          Specify the type of data that is allowed in parts of this type based on the mime-type.
 void setName(java.lang.String name)
           
 

Method Detail

getId

public long getId()

getName

public java.lang.String getName()

setName

public void setName(java.lang.String name)

getLabel

public java.lang.String getLabel(java.util.Locale locale)
Gets the label in the given locale, using the usual locale fallback mechanisms if not found in the exactly specified locale, and finally returning the parttype's name if no label is available.


getLabelExact

public java.lang.String getLabelExact(java.util.Locale locale)

setLabel

public void setLabel(java.util.Locale locale,
                     java.lang.String label)

getDescription

public java.lang.String getDescription(java.util.Locale locale)

getDescriptionExact

public java.lang.String getDescriptionExact(java.util.Locale locale)

setDescription

public void setDescription(java.util.Locale locale,
                           java.lang.String description)

getMimeTypes

public java.lang.String getMimeTypes()
Returns a string describing limitations on the allowed mime-types. An empty string means no restrictions. Otherwise, the string contains a comma-separated list of allowed mime-types.


setMimeTypes

public void setMimeTypes(java.lang.String mimeTypes)
Specify the type of data that is allowed in parts of this type based on the mime-type.

Parameters:
mimeTypes - A comma-separated list of mime-types. If empty, all mime-types are allowed.

mimeTypeAllowed

public boolean mimeTypeAllowed(java.lang.String mimeType)

isDaisyHtml

public boolean isDaisyHtml()
Indicates if the content of the part is Daisy HTML (well-formed XML using HTML elements).


setDaisyHtml

public void setDaisyHtml(boolean daisyHtml)

isDeprecated

public boolean isDeprecated()

setDeprecated

public void setDeprecated(boolean deprecated)

getLastModified

public java.util.Date getLastModified()
When was this PartType last changed (persistently). Returns null on newly created PartTypes.


getLastModifier

public long getLastModifier()
Who (which user) last changed this PartType (persistently). Returns -1 on newly created PartTypes.


getXml

public org.outerx.daisy.x10.PartTypeDocument getXml()

setAllFromXml

public void setAllFromXml(org.outerx.daisy.x10.PartTypeDocument.PartType partTypeXml)
Changes the state of this object to match the given XML. Note that this will only change properties otherwise changeable through methods of this interface, and not internal properties like id or lastModified.


save

public void save()
          throws RepositoryException
Throws:
RepositoryException

getUpdateCount

public long getUpdateCount()


Copyright © -2005 . All Rights Reserved.