< prev index next >

src/java.xml/share/classes/javax/xml/stream/events/XMLEvent.java

Print this page

        

*** 1,7 **** /* ! * Copyright (c) 2009, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this --- 1,7 ---- /* ! * Copyright (c) 2009, 2020, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this
*** 49,58 **** --- 49,59 ---- */ public interface XMLEvent extends javax.xml.stream.XMLStreamConstants { /** * Returns an integer code for this event. + * @return the event type * @see #START_ELEMENT * @see #END_ELEMENT * @see #CHARACTERS * @see #ATTRIBUTE * @see #NAMESPACE
*** 66,157 **** --- 67,172 ---- /** * Return the location of this event. The Location * returned from this method is non-volatile and * will retain its information. + * @return the location of the event * @see javax.xml.stream.Location */ javax.xml.stream.Location getLocation(); /** * A utility function to check if this event is a StartElement. + * @return true if the event is {@code StartElement}, false otherwise * @see StartElement */ public boolean isStartElement(); /** * A utility function to check if this event is an Attribute. + * @return true if the event is {@code Attribute}, false otherwise * @see Attribute */ public boolean isAttribute(); /** * A utility function to check if this event is a Namespace. + * @return true if the event is {@code Namespace}, false otherwise * @see Namespace */ public boolean isNamespace(); /** * A utility function to check if this event is a EndElement. + * @return true if the event is {@code EndElement}, false otherwise * @see EndElement */ public boolean isEndElement(); /** * A utility function to check if this event is an EntityReference. + * @return true if the event is {@code EntityReference}, false otherwise * @see EntityReference */ public boolean isEntityReference(); /** * A utility function to check if this event is a ProcessingInstruction. + * @return true if the event is {@code ProcessingInstruction}, false otherwise * @see ProcessingInstruction */ public boolean isProcessingInstruction(); /** * A utility function to check if this event is Characters. + * @return true if the event is {@code Characters}, false otherwise * @see Characters */ public boolean isCharacters(); /** * A utility function to check if this event is a StartDocument. + * @return true if the event is {@code StartDocument}, false otherwise * @see StartDocument */ public boolean isStartDocument(); /** * A utility function to check if this event is an EndDocument. + * @return true if the event is {@code EndDocument}, false otherwise * @see EndDocument */ public boolean isEndDocument(); /** * Returns this event as a start element event, may result in * a class cast exception if this event is not a start element. + * @return a {@code StartElement} event */ public StartElement asStartElement(); /** * Returns this event as an end element event, may result in * a class cast exception if this event is not a end element. + * @return a {@code EndElement} event */ public EndElement asEndElement(); /** * Returns this event as Characters, may result in * a class cast exception if this event is not Characters. + * @return a {@code Characters} event */ public Characters asCharacters(); /** * This method is provided for implementations to provide * optional type information about the associated event. * It is optional and will return null if no information * is available. + * @return the type of the event, null if not available */ public QName getSchemaType(); /** * This method will write the XMLEvent as per the XML 1.0 specification as Unicode characters.
< prev index next >