Examples of ValueGetter


Examples of org.apache.phoenix.hbase.index.ValueGetter

            Put dataMutation = new Put(rowKeyPtr.copyBytes());
            for (KeyValue kv : dataKeyValues) {
                valueMap.put(new ColumnReference(kv.getFamily(),kv.getQualifier()), kv.getValue());
                dataMutation.add(kv);
            }
            ValueGetter valueGetter = newValueGetter(valueMap);
           
            List<Mutation> indexMutations =
                    IndexTestUtil.generateIndexData(index, table, dataMutation, ptr, builder);
            assertEquals(1,indexMutations.size());
            assertTrue(indexMutations.get(0) instanceof Put);
View Full Code Here

Examples of org.apache.phoenix.hbase.index.ValueGetter

                long ts = MetaDataUtil.getClientTimeStamp(dataMutation);
                ptr.set(dataMutation.getRow());
                if (dataMutation instanceof Put) {
                    // TODO: is this more efficient than looking in our mutation map
                    // using the key plus finding the PColumn?
                    ValueGetter valueGetter = new ValueGetter() {
       
                        @Override
                        public ImmutableBytesPtr getLatestValue(ColumnReference ref) {
                            // Always return null for our empty key value, as this will cause the index
                            // maintainer to always treat this Put as a new row.
View Full Code Here

Examples of org.apache.phoenix.hbase.index.ValueGetter

            ImmutableBytesPtr qual = new ImmutableBytesPtr(kv.getBuffer(), kv.getQualifierOffset(),
                    kv.getQualifierLength());
            ImmutableBytesPtr value = new ImmutableBytesPtr(kv.getBuffer(), kv.getValueOffset(), kv.getValueLength());
            valueMap.put(new ReferencingColumn(family, qual), value);
        }
        return new ValueGetter() {
            @Override
            public ImmutableBytesPtr getLatestValue(ColumnReference ref) throws IOException {
                return valueMap.get(ReferencingColumn.wrap(ref));
            }
        };
View Full Code Here

Examples of org.jbehave.core.steps.needle.ValueGetter

        AnnotatedWithStepsWithDependency.class);
    final List<CandidateSteps> buildCandidateSteps = builderAnnotated
        .buildCandidateSteps();
    assertThatStepsInstancesAre(buildCandidateSteps,
        FooStepsWithDependency.class);
    final ValueGetter getter = ((FooStepsWithDependency) ((Steps) buildCandidateSteps
        .get(0)).instance()).getGetter();
    assertNotNull(getter);
    assertThat((String) getter.getValue(), is(ValueGetter.VALUE));
  }
View Full Code Here

Examples of org.jbehave.core.steps.needle.ValueGetter

  public boolean verify(InjectionTargetInformation target) {
    return target.getType().isAssignableFrom(ValueGetter.class);
  }

  public ValueGetter getInjectedObject(Class<?> injectionPointType) {
    return new ValueGetter() {

      public Object getValue() {
        return VALUE;
      }
View Full Code Here

Examples of testinterfaces.ValueGetter

        delegate.protectedValue = newValue;
    }

    public ValueGetter getValueGetter()
    {
        return new ValueGetter()
        {
            public String getValue()
            {
                return delegate.protectedValue;
            }
View Full Code Here

Examples of testinterfaces.ValueGetter

        delegate.protectedValue = newValue;
    }

    public ValueGetter getValueGetter()
    {
        return new ValueGetter()
        {
            @Override
            public String getValue()
            {
                return delegate.protectedValue;
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.