Examples of Wrapper


Examples of ar.com.AmberSoft.iEvenTask.utils.Wrapper

    if (filters!=null){
      int index = 0;
      Iterator it = filters.iterator();
      while (it.hasNext()) {
        BaseFilterConfig filter = (BaseFilterConfig) it.next();
        Wrapper wrapper = FiltersWrapperFactory.getInstance().getWrapper(filter);
        if (wrapper!=null){
          wrapper.setValueOnQuery(query, index);
        } else {
          if (filter instanceof BaseDateFilterConfig) {
            query.setDate(index, (Date)filter.getValue());
          } else if (filter instanceof BaseNumericFilterConfig) {
            query.setDouble(index, (Double)filter.getValue());
View Full Code Here

Examples of com.alibaba.dubbo.common.bytecode.Wrapper

        return (T) Proxy.getProxy(interfaces).newInstance(new InvokerInvocationHandler(invoker));
    }

    public <T> Invoker<T> getInvoker(T proxy, Class<T> type, URL url) {
        // TODO Wrapper类不能正确处理带$的类名
        final Wrapper wrapper = Wrapper.getWrapper(proxy.getClass().getName().indexOf('$') < 0 ? proxy.getClass() : type);
        return new AbstractProxyInvoker<T>(proxy, type, url) {
            @Override
            protected Object doInvoke(T proxy, String methodName,
                                      Class<?>[] parameterTypes,
                                      Object[] arguments) throws Throwable {
                return wrapper.invokeMethod(proxy, methodName, parameterTypes, arguments);
            }
        };
    }
View Full Code Here

Examples of com.alvazan.orm.api.z5api.IndexColumnInfo.Wrapper

  public Holder<byte[]> nextImpl() {
    Holder<IndexColumnInfo> next = cursor.nextImpl();
    if(next == null)
      return null;
    IndexColumnInfo info = next.getValue();
    Wrapper wrapper = info.getIndexNode(view);
    IndexColumn indNode = wrapper.getCol();
    byte[] key = indNode.getPrimaryKey();
    if(key == null)
      throw new IllegalArgumentException("key was null, index data seems corrupt on view="+view+" col="
          +wrapper.getColMeta()+" some value is tied to a null primary key.  Should" +
              " never happen even in face of eventual consistent, should never happen");
    return new Holder<byte[]>(key);
  }
View Full Code Here

Examples of com.dyuproject.protostuff.runtime.IdStrategy.Wrapper

                }
               
                if(next != 1)
                    throw new ProtostuffException("Corrupt input");
               
                final Wrapper wrapper = new Wrapper();
                Object element = input.mergeObject(wrapper, strategy.OBJECT_SCHEMA);
                if(!graph || !((GraphInput)input).isCurrentMessageReference())
                    element = wrapper.value;
               
                try
                {
                    fSingletonSet_element.set(collection, element);
                }
                catch (IllegalArgumentException e)
                {
                    throw new RuntimeException(e);
                }
                catch (IllegalAccessException e)
                {
                    throw new RuntimeException(e);
                }
               
                ret = collection;
                break;
            }
           
            case ID_SINGLETON_LIST:
            {
                if(0 != input.readUInt32())
                    throw new ProtostuffException("Corrupt input.");
               
                final Object collection = iSingletonList.newInstance();
                if(graph)
                {
                    // update the actual reference.
                    ((GraphInput)input).updateLast(collection, owner);
                }
               
                final int next = input.readFieldNumber(schema);
                if(next == 0)
                {
                    // null element
                    return collection;
                }
               
                if(next != 1)
                    throw new ProtostuffException("Corrupt input.");
               
                final Wrapper wrapper = new Wrapper();
                Object element = input.mergeObject(wrapper, strategy.OBJECT_SCHEMA);
                if(!graph || !((GraphInput)input).isCurrentMessageReference())
                    element = wrapper.value;
               
                try
                {
                    fSingletonList_element.set(collection, element);
                }
                catch (IllegalArgumentException e)
                {
                    throw new RuntimeException(e);
                }
                catch (IllegalAccessException e)
                {
                    throw new RuntimeException(e);
                }
               
                ret = collection;
                break;
            }
           
            case ID_SET_FROM_MAP:
            {
                final Object collection = iSetFromMap.newInstance();
                if(graph)
                {
                    // update the actual reference.
                    ((GraphInput)input).updateLast(collection, owner);
                }
               
                final Wrapper wrapper = new Wrapper();
                Object m = input.mergeObject(wrapper, strategy.POLYMORPHIC_MAP_SCHEMA);
                if(!graph || !((GraphInput)input).isCurrentMessageReference())
                    m = wrapper.value;
               
                try
                {
                    fSetFromMap_m.set(collection, m);
                    fSetFromMap_s.set(collection, ((Map<?,?>)m).keySet());
                }
                catch (IllegalArgumentException e)
                {
                    throw new RuntimeException(e);
                }
                catch (IllegalAccessException e)
                {
                    throw new RuntimeException(e);
                }
               
                ret = collection;
                break;
            }
               
            case ID_COPIES_LIST:
            {
                if(0 != input.readUInt32())
                    throw new ProtostuffException("Corrupt input.");
               
                final Object collection = iCopiesList.newInstance();
                if(graph)
                {
                    // update the actual reference.
                    ((GraphInput)input).updateLast(collection, owner);
                }
               
                if(1 != input.readFieldNumber(schema))
                    throw new ProtostuffException("Corrupt input.");
               
                final int n = input.readUInt32(),
                        next = input.readFieldNumber(schema);
               
                if(next == 0)
                {
                    // null element
                    try
                    {
                        fCopiesList_n.setInt(collection, n);
                    }
                    catch (IllegalArgumentException e)
                    {
                        throw new RuntimeException(e);
                    }
                    catch (IllegalAccessException e)
                    {
                        throw new RuntimeException(e);
                    }
                   
                    return collection;
                }
               
                if(next != 2)
                    throw new ProtostuffException("Corrupt input.");
               
                final Wrapper wrapper = new Wrapper();
                Object element = input.mergeObject(wrapper, strategy.OBJECT_SCHEMA);
                if(!graph || !((GraphInput)input).isCurrentMessageReference())
                    element = wrapper.value;
               
                try
View Full Code Here

Examples of com.github.mustachejava.util.Wrapper

*/
public class IndyObjectHandler extends CodegenObjectHandler {

  @Override
  public Wrapper find(String name, Object[] scopes) {
    Wrapper wrapper = super.find(name, scopes);
    if (wrapper instanceof CodegenReflectionWrapper) {
      CodegenReflectionWrapper rw = (CodegenReflectionWrapper) wrapper;
      return IndyWrapper.create(rw);
    } else {
      return wrapper;
View Full Code Here

Examples of com.github.theholywaffle.teamspeak3.api.wrapper.Wrapper

  }

  public Wrapper getFirstResponse() {
    List<HashMap<String, String>> resp = getResponse();
    if(resp.size() > 0){
      return new Wrapper(resp.get(0));
    }
    return new Wrapper(new HashMap<String, String>());
  }
View Full Code Here

Examples of de.abstrakt.mock.utils.Wrapper

        {
            addExpectationToBlock(marker, params, returnValue);
        }
        else
        {
            expectations.add(new Wrapper(marker, params));
            returns.add(returnValue);
        }

        expects.add(marker);
        checkConsistency(marker);
View Full Code Here

Examples of java.sql.Wrapper

                    return (OracleConnection) uwcx;
                }
            } else if (cx instanceof Wrapper) {
                // try to use java 6 unwrapping
                try {
                    Wrapper w = cx;
                    if (w.isWrapperFor(OracleConnection.class)) {
                        return w.unwrap(OracleConnection.class);
                    }
                } catch (Throwable t) {
                    // not a mistake, old DBCP versions will throw an Error here, we need to catch
                    // it
                    LOGGER.log(Level.FINER, "Failed to unwrap connection using java 6 facilities",
View Full Code Here

Examples of mil.nga.giat.geowave.store.CloseableIterator.Wrapper

        final List<GeoWaveData<GridCoverage>> coverages = new ArrayList<GeoWaveData<GridCoverage>>();
        coverages.add(new GeoWaveData<GridCoverage>(
            adapter,
            primaryIndexId,
            coverage));
        return new Wrapper(
            coverages.iterator()) {

          @Override
          public void close()
              throws IOException {
            reader.dispose();
          }
        };
      }
      else {
        LOGGER.warn("Null grid coverage from file '" + input.getAbsolutePath() + "' for discovered geotools format '" + format.getName() + "'");
      }
    }
    catch (final IOException e) {
      LOGGER.warn(
          "Unable to read grid coverage of file '" + input.getAbsolutePath() + "' for discovered geotools format '" + format.getName() + "'",
          e);
    }
    return new Wrapper(
        Collections.emptyIterator());
  }
View Full Code Here

Examples of net.sf.clairv.search.util.Wrapper

  float idf;

  public ResponseMessage handleRequest(OverlayRequest request) {

    final Wrapper resp = new Wrapper();

    final Counter counter = new Counter(1);

    final KeywordQueryMessage kqm = (KeywordQueryMessage) request
        .getMessage();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.