src/main/java/com/machinezoo/pushmode/dom/DomElement.java
@NoDocs
	@Override
	public List<DomAttribute> attributes() {
		List<DomAttribute> result = new ArrayList<>();
		if (attributes != null) {
			for (int i = 0; i < attributes.length; i += 2) {
				if (attributes[i] == null)
					break;
				result.add(new DomAttribute(attributes[i], attributes[i + 1]));
			}
		}
		return result;
	}
/*
	 * While most DOM operations are append-only building of new DOM trees,
	 * applications often have to do DOM tree rewriting, e.g. to process templates.
	 * An easy to use attribute query API is very valuable in those cases.
	 * Plus some parts of this API are used by specialized attribute getters.
	 * 
	 * List of attributes can be returned either as a copy or a live view.
	 * The current implementation returns a copy, which is mostly justified by simplicity/laziness.
	 * Live view could be implemented and this option is not excluded from future development.
	 */
While most DOM operations are append-only building of new DOM trees,
applications often have to do DOM tree rewriting, e.g. to process templates.
An easy to use attribute query API is very valuable in those cases.
Plus some parts of this API are used by specialized attribute getters.

List of attributes can be returned either as a copy or a live view.
The current implementation returns a copy, which is mostly justified by simplicity/laziness.
Live view could be implemented and this option is not excluded from future development.
While most DOM operations are append - only building of new DOM trees applications often have to do DOM tree rewriting e . g . to process templates . An easy to use attribute query API is very valuable in those cases . Plus some parts of this API are used by specialized attribute getters . List of attributes can be returned either as a copy or a live view . The current implementation returns a copy which is mostly justified by simplicity / laziness . Live view could be implemented and this option is not excluded from future development .
@NoDocs
	@Override
	public List<DomAttribute> attributes() {
		List<DomAttribute> result = new ArrayList<>();
		if (attributes != null) {
			for (int i = 0; i < attributes.length; i += 2) {
				if (attributes[i] == null)
					break;
				result.add(new DomAttribute(attributes[i], attributes[i + 1]));
			}
		}
		return result;
	}
@ NoDocs @ Override public List < DomAttribute > attributes ( ) { List < DomAttribute > result = new ArrayList < > ( ) ; if ( attributes != null ) { for ( int i = 0 ; i < attributes . length ; i += 2 ) { if ( attributes [ i ] == null ) break ; result . add ( new DomAttribute ( attributes [ i ] , attributes [ i + 1 ] ) ) ; } } return result ; }
While most DOM operations are append-only building of new DOM trees,
 applications often have to do DOM tree rewriting, e.g.
While most DOM operations are append - only building of new DOM trees applications often have to do DOM tree rewriting e . g .