Eclipse Platform
2.0

org.eclipse.update.core.model
Class URLEntryModel

java.lang.Object
  |
  +--org.eclipse.core.runtime.PlatformObject
        |
        +--org.eclipse.update.core.model.ModelObject
              |
              +--org.eclipse.update.core.model.URLEntryModel
All Implemented Interfaces:
IAdaptable
Direct Known Subclasses:
URLEntry

public class URLEntryModel
extends ModelObject

Annotated URL model object.

This class may be instantiated or subclassed by clients. However, in most cases clients should instead instantiate or subclass the provided concrete implementation of this model.

Since:
2.0
See Also:
URLEntry

Constructor Summary
URLEntryModel()
          Creates a uninitialized annotated URL model object.
 
Method Summary
 String getAnnotation()
          Returns the url annotation.
 String getAnnotationNonLocalized()
          returns the non-localized url annotation.
 URL getURL()
          Returns the resolved URL.
 String getURLString()
          Returns the unresolved url string.
 void resolve(URL base, ResourceBundle bundle)
          Resolve the model object.
 void setAnnotation(String annotation)
          Sets the annotation.
 void setURLString(String urlString)
          Sets the url string Throws a runtime exception if this object is marked read-only.
 
Methods inherited from class org.eclipse.update.core.model.ModelObject
arrayTypeFor, arrayTypeFor, assertIsWriteable, isReadOnly, markListReferenceReadOnly, markReadOnly, markReferenceReadOnly, resolveListReference, resolveNLString, resolveReference, resolveURL
 
Methods inherited from class org.eclipse.core.runtime.PlatformObject
getAdapter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

URLEntryModel

public URLEntryModel()
Creates a uninitialized annotated URL model object.

Since:
2.0
Method Detail

getAnnotation

public String getAnnotation()
Returns the url annotation. If the model object has been resolved, the annotation is localized.

Returns:
url annotation, or null.
Since:
2.0

getAnnotationNonLocalized

public String getAnnotationNonLocalized()
returns the non-localized url annotation.

Returns:
non-localized url annotation, or null.
Since:
2.0

getURLString

public String getURLString()
Returns the unresolved url string.

Returns:
url string, or null
Since:
2.0

getURL

public URL getURL()
Returns the resolved URL.

Returns:
url, or null
Since:
2.0

setAnnotation

public void setAnnotation(String annotation)
Sets the annotation. Throws a runtime exception if this object is marked read-only.

Parameters:
annotation - annotation
Since:
2.0

setURLString

public void setURLString(String urlString)
Sets the url string Throws a runtime exception if this object is marked read-only.

Since:
2.0

resolve

public void resolve(URL base,
                    ResourceBundle bundle)
             throws MalformedURLException
Resolve the model object. Any URL strings in the model are resolved relative to the base URL argument. Any translatable strings in the model that are specified as translation keys are localized using the supplied resource bundle.

Overrides:
resolve in class ModelObject
Parameters:
base - URL
bundle - resource bundle
Throws:
MalformedURLException
Since:
2.0

Eclipse Platform
2.0

Copyright (c) IBM Corp. and others 2000, 2002. All Rights Reserved.