use of org.ovirt.engine.api.v3.types.V3SpecialObjects in project ovirt-engine by oVirt.
the class V3SpecialObjectsOutAdapter method adapt.
@Override
public V3SpecialObjects adapt(SpecialObjects from) {
V3SpecialObjects to = new V3SpecialObjects();
Template blankTemplate = from.getBlankTemplate();
if (blankTemplate != null) {
V3Link blankTemplateLink = new V3Link();
blankTemplateLink.setRel("templates/blank");
blankTemplateLink.setHref(blankTemplate.getHref());
to.getLinks().add(blankTemplateLink);
}
Tag rootTag = from.getRootTag();
if (rootTag != null) {
V3Link rootTagLink = new V3Link();
rootTagLink.setRel("tags/root");
rootTagLink.setHref(rootTag.getHref());
to.getLinks().add(rootTagLink);
}
return to;
}
Aggregations