/** * Construct a <code>ParamDomain</code> with values from the given array. * * @param parameterName * the parameter whose domain is being described. * @param isRequired * whether specifying a value is required. * @param domainValues * the domain values. */ public ParamDomain(String parameterName, boolean isRequired, String[] domainValues) { _parameterName = parameterName; _isRequired = isRequired; for (String element : domainValues) { add(element); } }
protected static DigitalObject getSDefTwo() { Set<ParamDomainMap> methodDefs = new HashSet<ParamDomainMap>(); ParamDomainMap methodOne = new ParamDomainMap("methodOne"); ParamDomain argOneDomain = new ParamDomain("argOne", true); argOneDomain.add("val1"); argOneDomain.add("val2"); methodOne.put("argOne", argOneDomain); methodDefs.add(methodOne); return getTestSDef("test:sdef2", "sdef2", methodDefs); }
protected static DigitalObject getSDefTwoB() { Set<ParamDomainMap> methodDefs = new HashSet<ParamDomainMap>(); ParamDomainMap methodOne = new ParamDomainMap("methodOne"); ParamDomain argOneDomain = new ParamDomain("argOne", true); argOneDomain.add("val1"); argOneDomain.add("val2"); methodOne.put("argOne", argOneDomain); methodDefs.add(methodOne); ParamDomainMap methodTwo = new ParamDomainMap("methodTwo"); methodTwo.put("argOne", argOneDomain); methodDefs.add(methodTwo); return getTestSDef("test:sdef2b", "sdef2b", methodDefs); }
protected static DigitalObject getSDefFour() { Set<ParamDomainMap> methodDefs = new HashSet<ParamDomainMap>(); ParamDomainMap methodOne = new ParamDomainMap("methodOne"); ParamDomain argOneDomain = new ParamDomain("argOne", true); argOneDomain.add("val1"); argOneDomain.add("val2"); methodOne.put("argOne", argOneDomain); methodDefs.add(methodOne); ParamDomainMap methodTwo = new ParamDomainMap("methodTwo"); argOneDomain = new ParamDomain("argOne", false); methodTwo.put("argOne", argOneDomain); methodDefs.add(methodTwo); return getTestSDef("test:sdef4", "sdef4", methodDefs); }
protected static DigitalObject getSDepTwo() { Set<ParamDomainMap> methodDefs = new HashSet<ParamDomainMap>(); ParamDomainMap methodOne = new ParamDomainMap("methodOne"); ParamDomain argOneDomain = new ParamDomain("argOne", true); argOneDomain.add("val1"); argOneDomain.add("val2"); methodOne.put("argOne", argOneDomain); methodDefs.add(methodOne); return getTestSDep("test:sdep2", "sdep2", "test:sdef2", methodDefs, getMap("methodOne", new String[] {"KEY1"}, null, null), getMap("KEY1", new String[] {"text/xml"}, null, null), getMap("methodOne", new String[] {"text/xml"}, null, null)); }
protected static DigitalObject getSDepTwoB() { Set<ParamDomainMap> methodDefs = new HashSet<ParamDomainMap>(); ParamDomainMap methodOne = new ParamDomainMap("methodOne"); ParamDomain argOneDomain = new ParamDomain("argOne", true); argOneDomain.add("val1"); argOneDomain.add("val2"); methodOne.put("argOne", argOneDomain); methodDefs.add(methodOne); ParamDomainMap methodTwo = new ParamDomainMap("methodTwo"); methodTwo.put("argOne", argOneDomain); methodDefs.add(methodTwo); return getTestSDep("test:sdep2b", "sdep2b", "test:zdef2b", methodDefs, getMap("methodOne", new String[] {"KEY1"}, "methodTwo", new String[] {"KEY2"}), getMap("KEY1", new String[] {"text/xml"}, "KEY2", new String[] {"text/xml"}), getMap("methodOne", new String[] {"text/xml"}, "methodTwo", new String[] {"text/xml"})); }
protected static DigitalObject getSDepFour() { Set<ParamDomainMap> methodDefs = new HashSet<ParamDomainMap>(); ParamDomainMap methodOne = new ParamDomainMap("methodOne"); ParamDomain argOneDomain = new ParamDomain("argOne", true); argOneDomain.add("val1"); argOneDomain.add("val2"); methodOne.put("argOne", argOneDomain); methodDefs.add(methodOne); ParamDomainMap methodTwo = new ParamDomainMap("methodTwo"); argOneDomain = new ParamDomain("argOne", false); methodTwo.put("argOne", argOneDomain); methodDefs.add(methodTwo); return getTestSDep("test:sdep4", "sdep4", "test:sdef4", methodDefs, getMap("methodOne", new String[] {"KEY1"}, "methodTwo", new String[] {"KEY2"}), getMap("KEY1", new String[] {"text/xml"}, "KEY2", new String[] {"text/xml"}), getMap("methodOne", new String[] {"text/xml"}, "methodTwo", new String[] {"text/xml"})); }