The NMToken is used for authenticating communication with NodeManager
NodeManager
It is issued by ResourceMananger when ApplicationMaster negotiates resource with ResourceManager and validated on NodeManager side.
ResourceMananger
ApplicationMaster
ResourceManager
311312313314315316317
new NCName("_Atlanta.Braves"),true); } public void testNMToken() throws Exception { deserialize("<result xsi:type=\"xsd:NMTOKEN\">_A.B.C.1-2-3</result>", new NMToken("_A.B.C.1-2-3"),true); }
228229230231232233234
287288289290291292293294295296
} assertTrue("binding is null", binding != null); // Test operation org.apache.axis.types.NMToken value = null; NMToken token = new NMToken(); token.setValue("eye_am_an_en_em_tokin"); value = binding.echoNMToken(token); assertEquals(token, value); }
70717273747576777879808182
/** * Run a failure test. value should be invalid. */ private void runFailTest(String value) throws Exception { NMToken oToken = null; try { oToken = new NMToken(value); } catch (Exception e) { // catch the validation exception } assertNull( "NMToken validation restriction failed. did not restrict bad value [" +
85868788899091929394959697
/** * Run a successful test. value should be valid. */ private void runPassTest(String value) throws Exception { NMToken oToken = null; try { oToken = new NMToken(value); } catch (Exception e) { // catch the validation exception } assertEquals("NMToken strings not equal. orig value:" + value, oToken.toString(), value); }
759760761762763764765
public static NMToken convertToNMTOKEN(String s) { if ((s == null) || s.equals("")){ return null; } return new NMToken(s); }
765766767768769770771
431432433434435436437
public static Language convertTolanguage(String s) { return new Language(s); } public static NMToken convertToNMTOKEN(String s) { return new NMToken(s); }
761762763764765766767