00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031 package org.objectweb.proactive.core.descriptor.xml;
00032
00033 import org.objectweb.proactive.core.descriptor.data.ProActiveDescriptor;
00034 import org.objectweb.proactive.core.xml.handler.CollectionUnmarshaller;
00035 import org.objectweb.proactive.core.xml.handler.PassiveCompositeUnmarshaller;
00036 import org.objectweb.proactive.scheduler.Scheduler;
00037
00038
00045 class InfrastructureHandler extends PassiveCompositeUnmarshaller
00046 implements ProActiveDescriptorConstants {
00047
00048
00049
00050
00051
00052
00053 public InfrastructureHandler(ProActiveDescriptor proActiveDescriptor) {
00054 super(false);
00055 CollectionUnmarshaller ch = new CollectionUnmarshaller();
00056 ch.addHandler(PROCESS_DEFINITION_TAG,
00057 new ProcessDefinitionHandler(proActiveDescriptor));
00058 this.addHandler(PROCESSES_TAG, ch);
00059 ch.addHandler(SERVICE_DEFINITION_TAG,
00060 new ServiceDefinitionHandler(proActiveDescriptor));
00061 this.addHandler(SERVICES_TAG, ch);
00062 }
00063
00064 public InfrastructureHandler(Scheduler scheduler, String jobId,
00065 ProActiveDescriptor proActiveDescriptor) {
00066 super(false);
00067 CollectionUnmarshaller ch = new CollectionUnmarshaller();
00068 ch.addHandler(SERVICE_DEFINITION_TAG,
00069 new ServiceDefinitionHandler(scheduler, jobId, proActiveDescriptor));
00070 this.addHandler(SERVICES_TAG, ch);
00071 ch.addHandler(PROCESS_DEFINITION_TAG,
00072 new ProcessDefinitionHandler(proActiveDescriptor));
00073 this.addHandler(PROCESSES_TAG, ch);
00074 }
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085 }