Skip to content

Commit 446693f

Browse files
committed
refactor
git-svn-id: https://svn.apache.org/repos/asf/xmlbeans/trunk@1935541 13f79535-47bb-0310-9956-ffa450edef68
1 parent cf5b923 commit 446693f

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

src/main/java/org/apache/xmlbeans/impl/common/Sax2Dom.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public class Sax2Dom
4343

4444
private Node _root = null;
4545
private Document _document = null;
46-
private Stack<Node> _nodeStk = new Stack<>();
46+
private final Stack<Node> _nodeStk = new Stack<>();
4747
private Vector<String> _namespaceDecls = null;
4848

4949
public Sax2Dom() throws ParserConfigurationException
@@ -155,7 +155,7 @@ public void startPrefixMapping(String prefix, String uri)
155155
{
156156
if (_namespaceDecls == null)
157157
{
158-
_namespaceDecls = new Vector(2);
158+
_namespaceDecls = new Vector<>(2);
159159
}
160160
_namespaceDecls.addElement(prefix);
161161
_namespaceDecls.addElement(uri);

src/main/java/org/apache/xmlbeans/impl/regex/Op.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -163,10 +163,10 @@ int getData() {
163163

164164
// ================================================================
165165
static class UnionOp extends Op {
166-
Vector branches;
166+
Vector<Op> branches;
167167
UnionOp(int type, int size) {
168168
super(type);
169-
this.branches = new Vector(size);
169+
this.branches = new Vector<>(size);
170170
}
171171
void addElement(Op op) {
172172
this.branches.addElement(op);
@@ -175,7 +175,7 @@ int size() {
175175
return this.branches.size();
176176
}
177177
Op elementAt(int index) {
178-
return (Op)this.branches.elementAt(index);
178+
return this.branches.elementAt(index);
179179
}
180180
}
181181

0 commit comments

Comments
 (0)