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

## org.eclipse.update.core.model
Class SiteModel

    java.lang.Object
      org.eclipse.core.runtime.PlatformObject
          org.eclipse.update.core.model.ModelObject
              org.eclipse.update.core.model.SiteModel

All Implemented Interfaces:
  IAdaptable

Direct Known Subclasses:
  Site

public class SiteModel
extends ModelObject

Site 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.

Note: This class/interface is part of an interim API that is still under development and expected to change significantly before reaching stability. It is being made available at this early stage to solicit feedback from pioneering adopters on the understanding that any code that uses this API will almost certainly be broken (repeatedly) as the API evolves.

Since:
  2.0
See Also:
  `Site`

Constructor Summary
`SiteModel()` Creates an uninitialized site model object.

Method Summary
`void` | `addArchiveReferenceModel(ArchiveReferenceModel archiveReference)` Adds an archive reference model to site.
`void` | `addCategoryModel(CategoryModel category)` Adds a category model to site.
`void` | `addFeatureReferenceModel(SiteFeatureReferenceModel featureReference)` Adds a feature reference model to site.
`ArchiveReferenceModel[]` | `getArchiveReferenceModels()` Returns an array of plug-in and non-plug-in archive reference models on this site
`CategoryModel[]` | `getCategoryModels()` Returns an array of category models for this site.
`org.eclipse.update.internal.model.ConfiguredSiteModel` | `getConfiguredSiteModel()`
`URLEntryModel` | `getDescriptionModel()` Returns the site description.
`SiteFeatureReferenceModel[]` | `getFeatureReferenceModels()` Returns an array of feature reference models on this site.
`URL` | `getLocationURL()` Returns the resolved URL for the site.
`String` | `getLocationURLString()` Returns the unresolved URL string for the site.
`protected String` | `getPropertyName()` Method getPropertyName.
`String` | `getType()` Returns the site type.
`void` | `markReadOnly()` Marks the model object as read-only.
`void` | `removeArchiveReferenceModel(ArchiveReferenceModel archiveReference)` Removes an archive reference model from site.
`void` | `removeCategoryModel(CategoryModel category)` Removes a category model from site.
`void` | `removeFeatureReferenceModel(FeatureReferenceModel featureReference)` Removes a feature reference model from site.
`void` | `resolve(URL base, URL bundleURL)` Resolve the model object.
`void` | `setArchiveReferenceModels(ArchiveReferenceModel[] archiveReferences)` Sets the archive references for this site.
`void` | `setCategoryModels(CategoryModel[] categories)` Sets the site categories.
`void` | `setConfiguredSiteModel(org.eclipse.update.internal.model.ConfiguredSiteModel configuredSiteModel)`
`void` | `setDescriptionModel(URLEntryModel description)` Sets the site description.
`void` | `setFeatureReferenceModels(FeatureReferenceModel[] featureReferences)` Sets the feature references for this site.
`void` | `setLocationURLString(String locationURLString)` Sets the unresolved URL for the site.
`void` | `setType(String type)` Sets the site type.

Methods inherited from class org.eclipse.update.core.model.ModelObject
`arrayTypeFor, arrayTypeFor, assertIsWriteable, getResourceBundle, isReadOnly, markListReferenceReadOnly, 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

### SiteModel

    public SiteModel()

  Creates an uninitialized site model object.

Since:
  2.0

Method Detail

### getType

    public String getType()

  Returns the site type.

  Returns:
    site type, or `null`.
  Since:
    2.0

### getDescriptionModel

    public URLEntryModel getDescriptionModel()

  Returns the site description.

  Returns:
    site description, or `null`.
  Since:
    2.0

### getFeatureReferenceModels

    public SiteFeatureReferenceModel[] getFeatureReferenceModels()

  Returns an array of feature reference models on this site.

  Returns:
    an array of feature reference models, or an empty array.
  Since:
    2.0

### getArchiveReferenceModels

    public ArchiveReferenceModel[] getArchiveReferenceModels()

  Returns an array of plug-in and non-plug-in archive reference models on this site

  Returns:
    an array of archive reference models, or an empty array if there are no archives known to this site.
  Since:
    2.0

### getCategoryModels

    public CategoryModel[] getCategoryModels()

  Returns an array of category models for this site.

  Returns:
    array of site category models, or an empty array.
  Since:
    2.0

### getLocationURLString

    public String getLocationURLString()

  Returns the unresolved URL string for the site.

  Returns:
    url string, or `null`
  Since:
    2.0

### getLocationURL

    public URL getLocationURL()

  Returns the resolved URL for the site.

  Returns:
    url, or `null`
  Since:
    2.0

### setType

    public void setType(String type)

  Sets the site type. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `type` - site type
  Since:
    2.0

### setDescriptionModel

    public void setDescriptionModel(URLEntryModel description)

  Sets the site description. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `description` - site description
  Since:
    2.0

### setFeatureReferenceModels

    public void setFeatureReferenceModels(FeatureReferenceModel[] featureReferences)

  Sets the feature references for this site. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `featureReferences` - an array of feature reference models
  Since:
    2.0

### setArchiveReferenceModels

    public void setArchiveReferenceModels(ArchiveReferenceModel[] archiveReferences)

  Sets the archive references for this site. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `archiveReferences` - an array of archive reference models
  Since:
    2.0

### setCategoryModels

    public void setCategoryModels(CategoryModel[] categories)

  Sets the site categories. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `categories` - an array of category models
  Since:
    2.0

### setLocationURLString

    public void setLocationURLString(String locationURLString)

  Sets the unresolved URL for the site. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `locationURLString` - url for the site (as a string)
  Since:
    2.0

### addFeatureReferenceModel

    public void addFeatureReferenceModel(SiteFeatureReferenceModel featureReference)

  Adds a feature reference model to site. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `featureReference` - feature reference model
  Since:
    2.0

### addArchiveReferenceModel

    public void addArchiveReferenceModel(ArchiveReferenceModel archiveReference)

  Adds an archive reference model to site. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `archiveReference` - archive reference model
  Since:
    2.0

### addCategoryModel

    public void addCategoryModel(CategoryModel category)

  Adds a category model to site. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `category` - category model
  Since:
    2.0

### removeFeatureReferenceModel

    public void removeFeatureReferenceModel(FeatureReferenceModel featureReference)

  Removes a feature reference model from site. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `featureReference` - feature reference model
  Since:
    2.0

### removeArchiveReferenceModel

    public void removeArchiveReferenceModel(ArchiveReferenceModel archiveReference)

  Removes an archive reference model from site. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `archiveReference` - archive reference model
  Since:
    2.0

### removeCategoryModel

    public void removeCategoryModel(CategoryModel category)

  Removes a category model from site. Throws a runtime exception if this object is marked read-only.

  Parameters:
    `category` - category model
  Since:
    2.0

### markReadOnly

    public void markReadOnly()

  Marks the model object as read-only.

  Overrides:
    `markReadOnly` in class `ModelObject`
  Since:
    2.0
  See Also:
    `ModelObject.isReadOnly()`

### resolve

    public void resolve(URL base,
                        URL bundleURL)
                 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
    `bundleURL` - resource bundle URL
  Throws:
    `MalformedURLException`
  Since:
    2.0

### getConfiguredSiteModel

    public org.eclipse.update.internal.model.ConfiguredSiteModel getConfiguredSiteModel()

### setConfiguredSiteModel

    public void setConfiguredSiteModel(org.eclipse.update.internal.model.ConfiguredSiteModel configuredSiteModel)

### getPropertyName

    protected String getPropertyName()

  Description copied from class: `ModelObject`
  Method getPropertyName.

  Overrides:
    `getPropertyName` in class `ModelObject`
  Returns:
    String
  See Also:
    `ModelObject.getPropertyName()`

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

Guidelines for using Eclipse APIs.

Copyright (c) IBM Corp. and others 2000, 2004. All rights reserved.