예제 #1
0
 public V get(B bean) throws AccessorException {
   V v = core.get(bean);
   if (v == null) {
     // creates a new object
     P pack = lister.startPacking(bean, core);
     lister.endPacking(pack, bean, core);
     v = core.get(bean);
   }
   return v;
 }
 /*     */ public static <T> TransducedAccessor<T> get(
     JAXBContextImpl context, RuntimeNonElementRef ref)
       /*     */ {
   /* 142 */ Transducer xducer = RuntimeModelBuilder.createTransducer(ref);
   /* 143 */ RuntimePropertyInfo prop = ref.getSource();
   /*     */
   /* 145 */ if (prop.isCollection()) {
     /* 146 */ return new ListTransducedAccessorImpl(
         xducer,
         prop.getAccessor(),
         Lister.create(
             Navigator.REFLECTION.erasure(prop.getRawType()), prop.id(), prop.getAdapter()));
     /*     */ }
   /*     */
   /* 151 */ if (prop.id() == ID.IDREF) {
     /* 152 */ return new IDREFTransducedAccessorImpl(prop.getAccessor());
     /*     */ }
   /* 154 */ if ((xducer.isDefault()) && (context != null) && (!context.fastBoot)) {
     /* 155 */ TransducedAccessor xa = OptimizedTransducedAccessorFactory.get(prop);
     /* 156 */ if (xa != null) return xa;
     /*     */ }
   /*     */
   /* 159 */ if (xducer.useNamespace()) {
     /* 160 */ return new CompositeContextDependentTransducedAccessorImpl(
         context, xducer, prop.getAccessor());
     /*     */ }
   /* 162 */ return new CompositeTransducedAccessorImpl(context, xducer, prop.getAccessor());
   /*     */ }