Package org.eclipse.pde.core.target
Interface ITargetLocationFactory
-
public interface ITargetLocationFactory
A factory to instantiate target locations from a serialized string of xml (seeITargetLocation.serialize()
). A factory must be provided for eachITargetLocation
type using theorg.eclipse.pde.core.targetLocations
extension point.- Since:
- 3.8
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description ITargetLocation
getTargetLocation(String type, String serializedXML)
Returns an instance of anITargetLocation
from the provided serialized xml string or throws aCoreException
if unable to do so.
-
-
-
Method Detail
-
getTargetLocation
ITargetLocation getTargetLocation(String type, String serializedXML) throws CoreException
Returns an instance of anITargetLocation
from the provided serialized xml string or throws aCoreException
if unable to do so.The serialized xml will not be prefixed by a XML declaration such as
<?xml version="1.0" encoding="UTF-8"?>
. The xml will contain a single root element namedlocation
with the attributetype
that matches the type parameter. The root element may have children and other attributes set.- Parameters:
type
- the string type describing the implementation of ITargetLocation expected, seeITargetLocation.getType()
serializedXML
- the xml string describing the location to create, seeITargetLocation.serialize()
- Returns:
- an instance of
ITargetLocation
- Throws:
CoreException
- if this factory cannot create a location for the specified type or if the xml string is invalid
-
-