package gov.nasa.arc.mct.scenario.component;

import gov.nasa.arc.mct.components.AbstractComponent;

public class TagRepositoryComponent extends AbstractComponent implements RepositoryCapability {
	private String scope;
	
	@Override
	public Class<?> getCapabilityClass() {
		return TagComponent.class;
	}

	@Override
	public String getUserScope() {
		return scope;
	}
}

@@ -97,127 +97,646 @@
 nt;%0A
-%0Apublic class TagRepositoryComponent extends AbstractComponent implements RepositoryCapability %7B%0A%09private String scope;
+import gov.nasa.arc.mct.components.JAXBModelStatePersistence;%0Aimport gov.nasa.arc.mct.components.ModelStatePersistence;%0A%0Aimport javax.xml.bind.annotation.XmlAccessType;%0Aimport javax.xml.bind.annotation.XmlAccessorType;%0Aimport javax.xml.bind.annotation.XmlRootElement;%0A%0Apublic class TagRepositoryComponent extends AbstractComponent implements RepositoryCapability %7B%0A%09private TagRepositoryModel model;%0A%09%0A%09@Override%0A%09public %3CT%3E T handleGetCapability(Class%3CT%3E capabilityClass) %7B%0A%09%09return (capabilityClass.isAssignableFrom(ModelStatePersistence.class)) ?%0A%09%09%09capabilityClass.cast(persistence) :%0A%09%09%09super.handleGetCapability(capabilityClass);%0A%09%7D
 %0A%09%0A%09
@@ -870,16 +870,22 @@
 %09return 
+model.
 scope;%0A%09
@@ -886,10 +886,578 @@
 ope;%0A%09%7D%0A
+%09%0A%09@XmlRootElement%0A%09@XmlAccessorType(XmlAccessType.FIELD)%0A%09public static class TagRepositoryModel %7B%0A%09%09private String scope;%0A%09%7D%0A%09%0A%09private final ModelStatePersistence persistence = %0A%09%09%09new JAXBModelStatePersistence%3CTagRepositoryModel%3E() %7B%0A%09%09@Override%0A%09%09protected TagRepositoryModel getStateToPersist() %7B%0A%09%09%09return model;%0A%09%09%7D%0A%0A%09%09@Override%0A%09%09protected void setPersistentState(TagRepositoryModel modelState) %7B%0A%09%09%09model = (TagRepositoryModel) modelState;%0A%09%09%7D%0A%0A%09%09@Override%0A%09%09protected Class%3CTagRepositoryModel%3E getJAXBClass() %7B%0A%09%09%09return TagRepositoryModel.class;%0A%09%09%7D%09%09%0A%09%7D;%0A
 %7D%0A

Add persistence support to tag repository