Code examples for Attributes

Codota analyzed 7,668,838 open source code samples to find the most common, credible and clear examples.
You can now enable Codota on your own code to easily search and navigate your Java codebase.
149:	assertEquals(1, attributes.getLength()); 
150:	assertEquals("", attributes.getURI(0)); 
151:	assertOneOf("a:bar", "", attributes.getLocalName(0)); 
152:	assertEquals("a:bar", attributes.getQName(0)); 
Full Snippet Info
8
CodeRank
35:	final String id = attrs.getValue( "id" ); 
36:	final String name = attrs.getValue( "name" ); 
37:	final String version = attrs.getValue( "version" ); 
38:	final String type = attrs.getValue( "type" ); 
39:	final String packageName = attrs.getValue( "package-name" ); 
40:	final String routerLayout = attrs.getValue( "routerLayout" ); 
Full Snippet Info
7
CodeRank
113:	return new RemoteException(attrs.getValue("class"), 
114:	attrs.getValue("message")); 
Full Snippet Info
7
CodeRank
128:	packageName = emptyToNull(attrs.getValue("packageName")); 
129:	versionCode = emptyToNull(attrs.getValue("versionCode")); 
130:	versionName = emptyToNull(attrs.getValue("versionName")); 
131:	buildBrand = emptyToNull(attrs.getValue("buildBrand")); 
132:	buildId = emptyToNull(attrs.getValue("buildId")); 
133:	buildModel = emptyToNull(attrs.getValue("buildModel")); 
Full Snippet Info
7
CodeRank
33:	parser.startElementBuilder(localName, attrs); 
-
36:	final String name = attrs.getValue("name"); 
37:	final String type = attrs.getValue("importType"); 
38:	final String location = attrs.getValue("location"); 
39:	final String namespace = attrs.getValue("namespace"); 
Full Snippet Info
7
CodeRank
55:	final String name = attrs.getValue(getUri(), "name");// NON-NLS 
-
57:	parameter.setMandatory("true".equals(attrs.getValue(getUri(), "is-mandatory")));// NON-NLS 
58:	parameter.setStrict("true".equals(attrs.getValue(getUri(), "is-strict")));// NON-NLS 
59:	parameter.setMultiSelect("true".equals(attrs.getValue(getUri(), "is-multi-select")));// NON-NLS 
60:	parameter.setType(attrs.getValue(getUri(), "type"));// NON-NLS 
61:	parameter.setTimezoneHint(attrs.getValue(getUri(), "timezone-hint"));// NON-NLS 
Full Snippet Info
7
CodeRank
49:	userName = attrs.getValue(getUri(), "userName"); 
50:	password = attrs.getValue(getUri(), "password"); 
51:	driverClass = attrs.getValue(getUri(), "driverClass"); 
52:	sqlQuery = attrs.getValue(getUri(), "sqlQuery"); 
53:	connectionString = attrs.getValue(getUri(), "connectionString"); 
Full Snippet Info
7
CodeRank
47:	color = ColorConverter.getObject(attrs.getValue(getUri(), "color")); 
48:	final float width = ParserUtil.parseFloat(attrs.getValue(getUri(), "width"), "Failed to parse numeric value", getLocator()); 
49:	final float miterLimit = ParserUtil.parseFloat(attrs.getValue(getUri(), "miterlimit"), "Failed to parse numeric value", getLocator()); 
50:	final float dashPhase = ParserUtil.parseFloat(attrs.getValue(getUri(), "dashPhase"), "Failed to parse numeric value", getLocator()); 
51:	final int cap = ParserUtil.parseInt(attrs.getValue(getUri(), "cap"), "Failed to parse numeric value", getLocator()); 
52:	final int join = ParserUtil.parseInt(attrs.getValue(getUri(), "join"), "Failed to parse numeric value", getLocator()); 
53:	final String dashType = attrs.getValue(getUri(), "dash"); 
Full Snippet Info
7
CodeRank
38:	mCurrentDrink = new Drink(Integer.parseInt(atts.getValue("id").trim())); 
39:	} else if (name.equals("supplier") && !TextUtils.isEmpty(atts.getValue("url").trim())) { 
40:	mCurrentDrink.setSupplierUrl(atts.getValue("url").trim()); 
-
43:	String articleId = atts.getValue("sb_article_id").trim(); 
-
47:	mCurrentVolume.setPriceSek(atts.getValue("price").trim()); 
48:	mCurrentVolume.setRetired(Integer.parseInt(atts.getValue("retired").trim())); 
-
51:	mCurrentTag.setId(Integer.parseInt(atts.getValue("id"))); 
52:	mCurrentTag.setType(atts.getValue("type")); 
-
54:	String producerId = atts.getValue("id"); 
Full Snippet Info
7
CodeRank
62:	name = attrs.getValue(getUri(), "name"); // NON-NLS 
-
67:	bundleName = attrs.getValue(getUri(), "bundle-name"); // NON-NLS 
-
72:	expert = "true".equals(attrs.getValue(getUri(), "expert")); // NON-NLS 
73:	hidden = "true".equals(attrs.getValue(getUri(), "hidden")); // NON-NLS 
74:	preferred = "true".equals(attrs.getValue(getUri(), "preferred")); // NON-NLS 
75:	deprecated = "true".equals(attrs.getValue(getUri(), "deprecated")); // NON-NLS 
-
77:	final String valueTypeText = attrs.getValue(getUri(), "class"); // NON-NLS 
Full Snippet Info
7
CodeRank
46:	assertEquals(1, attributes.getLength()); 
47:	assertEquals("", attributes.getURI(0)); 
48:	assertOneOf("bar", "", attributes.getLocalName(0)); 
49:	assertEquals("bar", attributes.getQName(0)); 
Full Snippet Info
7
CodeRank
132:	id = atts.getValue("", "id"); 
-
135:	id = atts.getValue(namespaceURI, "id"); 
-
138:	name = atts.getValue("", "name"); 
-
141:	name = atts.getValue(namespaceURI, "name"); 
-
144:	ref = atts.getValue("", "ref"); 
-
147:	ref = atts.getValue(namespaceURI, "ref"); 
Full Snippet Info
7
CodeRank
72:	parser.startElementBuilder(localName, attrs); 
-
74:	String id = attrs.getValue("id"); 
75:	String name = attrs.getValue("name"); 
76:	String structureRef = attrs.getValue("structureRef"); 
Full Snippet Info
7
CodeRank
73:	final String type = attrs.getValue("type"); 
-
75:	final String x = attrs.getValue("x"); 
76:	final String y = attrs.getValue("y"); 
77:	final String w = attrs.getValue("width"); 
78:	final String h = attrs.getValue("height"); 
Full Snippet Info
7
CodeRank
57:	parser.startElementBuilder(localName, attrs); 
-
59:	final String type = attrs.getValue("importType"); 
60:	final String location = attrs.getValue("location"); 
61:	final String namespace = attrs.getValue("namespace"); 
Full Snippet Info
7
CodeRank
70:	id = Long.parseLong(attributes.getValue(ATTRIBUTE_NAME_ID)); 
71:	sversion = attributes.getValue(ATTRIBUTE_NAME_VERSION); 
-
78:	timestampContainer = createTimestampContainer(attributes.getValue(ATTRIBUTE_NAME_TIMESTAMP)); 
79:	rawUserId = attributes.getValue(ATTRIBUTE_NAME_USERID); 
80:	rawUserName = attributes.getValue(ATTRIBUTE_NAME_USER); 
81:	changesetId = buildChangesetId(attributes.getValue(ATTRIBUTE_NAME_CHANGESET_ID)); 
Full Snippet Info
7
CodeRank
93:	final String bytesPerCRC = attrs.getValue("bytesPerCRC"); 
94:	final String crcPerBlock = attrs.getValue("crcPerBlock"); 
95:	final String md5 = attrs.getValue("md5"); 
Full Snippet Info
7
CodeRank
68:	instanceNum = Integer.parseInt(attrs.getValue(getUri(), "instanceNum")); 
-
75:	attrs.getValue(getUri(), "modelPath"), 
-
77:	attrs.getValue(getUri(), "operator"), 
78:	attrs.getValue(getUri(), "fieldName"), 
79:	attrs.getValue(getUri(), "comparator"), 
80:	attrs.getValue(getUri(), "value")); 
Full Snippet Info
7
CodeRank
48:	parser.startElementBuilder(localName, attrs); 
-
50:	String id = attrs.getValue("id"); 
51:	String name = attrs.getValue("name"); 
52:	String implRef = attrs.getValue("implementationRef"); 
Full Snippet Info
7
CodeRank
52:	final String label = attrs.getValue(getUri(), "label"); // NON-NLS 
53:	final String value = attrs.getValue(getUri(), "value"); // NON-NLS 
54:	String type = attrs.getValue(getUri(), "type"); // NON-NLS 
-
59:	final boolean selected = "true".equals(attrs.getValue(getUri(), "selected")); // NON-NLS 
Full Snippet Info
7
CodeRank