org.xwiki.extension.repository
Class DefaultExtensionRepositoryDescriptor

java.lang.Object
  extended by org.xwiki.extension.repository.DefaultExtensionRepositoryDescriptor
All Implemented Interfaces:
ExtensionRepositoryDescriptor
Direct Known Subclasses:
ExtensionRepositoryId

public class DefaultExtensionRepositoryDescriptor
extends Object
implements ExtensionRepositoryDescriptor

Default implementation of ExtensionRepositoryDescriptor.

Since:
4.3M1
Version:
$Id: 9dbefb1bf6cce229752fcb413263e4f43b8e3e9a $

Constructor Summary
DefaultExtensionRepositoryDescriptor(ExtensionRepositoryDescriptor descriptor)
           
DefaultExtensionRepositoryDescriptor(String id, String type, URI uri)
           
 
Method Summary
 boolean equals(Object obj)
           
 String getId()
           
 Map<String,String> getProperties()
          Extends ExtensionRepositoryDescriptor standard properties.
 String getProperty(String key)
           
 String getType()
           
 URI getURI()
           
 int hashCode()
           
 void putProperty(String key, String value)
          Set a property.
 void setProperties(Map<String,String> properties)
          Replace existing properties with provided properties.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DefaultExtensionRepositoryDescriptor

public DefaultExtensionRepositoryDescriptor(ExtensionRepositoryDescriptor descriptor)
Parameters:
descriptor - the identifier to clone

DefaultExtensionRepositoryDescriptor

public DefaultExtensionRepositoryDescriptor(String id,
                                            String type,
                                            URI uri)
Parameters:
id - the unique identifier
type - the repository type (maven, xwiki, etc.)
uri - the repository adress
Method Detail

getId

public String getId()
Specified by:
getId in interface ExtensionRepositoryDescriptor
Returns:
the unique identifier

getType

public String getType()
Specified by:
getType in interface ExtensionRepositoryDescriptor
Returns:
the repository type (maven, xwiki, etc.)

getURI

public URI getURI()
Specified by:
getURI in interface ExtensionRepositoryDescriptor
Returns:
the repository adress

getProperties

public Map<String,String> getProperties()
Description copied from interface: ExtensionRepositoryDescriptor
Extends ExtensionRepositoryDescriptor standard properties.

Specified by:
getProperties in interface ExtensionRepositoryDescriptor
Returns:
the properties

getProperty

public String getProperty(String key)
Specified by:
getProperty in interface ExtensionRepositoryDescriptor
Parameters:
key - the property key
Returns:
the property value

putProperty

public void putProperty(String key,
                        String value)
Set a property.

Parameters:
key - the property key
value - the property value
See Also:
getProperty(String)

setProperties

public void setProperties(Map<String,String> properties)
Replace existing properties with provided properties.

Parameters:
properties - the properties

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2004-2013 XWiki. All Rights Reserved.