src/share/jaxws_classes/com/sun/xml/internal/bind/v2/runtime/unmarshaller/StructureLoader.java

changeset 707
31893650acaf
parent 650
121e938cb9c3
child 1103
face9bd6bac2
equal deleted inserted replaced
706:1e9d08d74c48 707:31893650acaf
1 /* 1 /*
2 * Copyright (c) 1997, 2011, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 1997, 2014, Oracle and/or its affiliates. All rights reserved.
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 * 4 *
5 * This code is free software; you can redistribute it and/or modify it 5 * This code is free software; you can redistribute it and/or modify it
6 * under the terms of the GNU General Public License version 2 only, as 6 * under the terms of the GNU General Public License version 2 only, as
7 * published by the Free Software Foundation. Oracle designates this 7 * published by the Free Software Foundation. Oracle designates this
170 if(child == null) 170 if(child == null)
171 child = context.createInstance(beanInfo); 171 child = context.createInstance(beanInfo);
172 172
173 context.recordInnerPeer(child); 173 context.recordInnerPeer(child);
174 174
175 state.target = child; 175 state.setTarget(child);
176 176
177 fireBeforeUnmarshal(beanInfo, child, state); 177 fireBeforeUnmarshal(beanInfo, child, state);
178 178
179 179
180 context.startScope(frameSize); 180 context.startScope(frameSize);
195 xacc.parse(child,avalue); 195 xacc.parse(child,avalue);
196 } else if (attCatchAll!=null) { 196 } else if (attCatchAll!=null) {
197 String qname = atts.getQName(i); 197 String qname = atts.getQName(i);
198 if(atts.getURI(i).equals(WellKnownNamespace.XML_SCHEMA_INSTANCE)) 198 if(atts.getURI(i).equals(WellKnownNamespace.XML_SCHEMA_INSTANCE))
199 continue; // xsi:* attributes are meant to be processed by us, not by user apps. 199 continue; // xsi:* attributes are meant to be processed by us, not by user apps.
200 Object o = state.target; 200 Object o = state.getTarget();
201 Map<QName,String> map = attCatchAll.get(o); 201 Map<QName,String> map = attCatchAll.get(o);
202 if(map==null) { 202 if(map==null) {
203 // TODO: use ClassFactory.inferImplClass(sig,knownImplClasses) 203 // TODO: use ClassFactory.inferImplClass(sig,knownImplClasses)
204 204
205 // if null, create a new map. 205 // if null, create a new map.
248 return; 248 return;
249 } 249 }
250 } 250 }
251 } 251 }
252 252
253 state.loader = child.loader; 253 state.setLoader(child.loader);
254 state.receiver = child.receiver; 254 state.setReceiver(child.receiver);
255 } 255 }
256 256
257 @Override 257 @Override
258 public Collection<QName> getExpectedChildElements() { 258 public Collection<QName> getExpectedChildElements() {
259 return childUnmarshallers.keySet(); 259 return childUnmarshallers.keySet();
271 } 271 }
272 272
273 @Override 273 @Override
274 public void leaveElement(UnmarshallingContext.State state, TagName ea) throws SAXException { 274 public void leaveElement(UnmarshallingContext.State state, TagName ea) throws SAXException {
275 state.getContext().endScope(frameSize); 275 state.getContext().endScope(frameSize);
276 fireAfterUnmarshal(beanInfo, state.target, state.prev); 276 fireAfterUnmarshal(beanInfo, state.getTarget(), state.getPrev());
277 } 277 }
278 278
279 private static final QNameMap<TransducedAccessor> EMPTY = new QNameMap<TransducedAccessor>(); 279 private static final QNameMap<TransducedAccessor> EMPTY = new QNameMap<TransducedAccessor>();
280 280
281 public JaxBeanInfo getBeanInfo() { 281 public JaxBeanInfo getBeanInfo() {

mercurial