Converts an amcl.BN256.ECP into an ECP protobuf object.

@param w an ECP to be transformed into a protobuf object
@return a protobuf representation of the ECP
763610
static Idemix.ECP transformToProto(ECP w) {
        byte[] valueX = new byte[IdemixUtils.FIELD_BYTES];
        byte[] valueY = new byte[IdemixUtils.FIELD_BYTES];

        w.getX().toBytes(valueX);
        w.getY().toBytes(valueY);

        return Idemix.ECP.newBuilder().setX(ByteString.copyFrom(valueX)).setY(ByteString.copyFrom(valueY)).build();
    }
384913
public final void mRULE_WS() throws RecognitionException {
        try {
            int _type = RULE_WS;
            int _channel = DEFAULT_TOKEN_CHANNEL;
            // InternalSimpleAntlr.g:1742:9: ( ( ' ' | '\\t' | '\\r' | '\\n' )+ )
            // InternalSimpleAntlr.g:1742:11: ( ' ' | '\\t' | '\\r' | '\\n' )+
            {
            // InternalSimpleAntlr.g:1742:11: ( ' ' | '\\t' | '\\r' | '\\n' )+
            int cnt12=0;
            loop12:
            do {
                int alt12=2;
                int LA12_0 = input.LA(1);

                if ( ((LA12_0>='\t' && LA12_0<='\n')||LA12_0=='\r'||LA12_0==' ') ) {
                    alt12=1;
                }


                switch (alt12) {
            	case 1 :
            	    // InternalSimpleAntlr.g:
            	    {
            	    if ( (input.LA(1)>='\t' && input.LA(1)<='\n')||input.LA(1)=='\r'||input.LA(1)==' ' ) {
            	        input.consume();

            	    }
            	    else {
            	        MismatchedSetException mse = new MismatchedSetException(null,input);
            	        recover(mse);
            	        throw mse;}


            	    }
            	    break;

            	default :
            	    if ( cnt12 >= 1 ) break loop12;
                        EarlyExitException eee =
                            new EarlyExitException(12, input);
                        throw eee;
                }
                cnt12++;
            } while (true);


            }

            state.type = _type;
            state.channel = _channel;
        }
        finally {
        }
    }
660734
public EjbLocalRefType<WebFragmentType<T>> getOrCreateEjbLocalRef()
   {
      List<Node> nodeList = childNode.get("ejb-local-ref");
      if (nodeList != null &&  nodeList.size() > 0)
      {
         return new EjbLocalRefTypeImpl<WebFragmentType<T>>(this, "ejb-local-ref", childNode, nodeList.get(0));
      }
      return createEjbLocalRef();
   }
995962
public static WaveletDescription<WlCoef_F32> generate_F32( int I ) {
		if( I != 6 ) {
			throw new IllegalArgumentException("Only 6 is currently supported");
		}

		WlCoef_F32 coef = new WlCoef_F32();

		coef.offsetScaling = -2;
		coef.offsetWavelet = -2;

		coef.scaling = new float[6];
		coef.wavelet = new float[6];

		double sqrt7 = Math.sqrt(7);
		double div = 16.0*Math.sqrt(2);
		coef.scaling[0] = (float)((1.0-sqrt7)/div);
		coef.scaling[1] = (float)((5.0+sqrt7)/div);
		coef.scaling[2] = (float)((14.0+2.0*sqrt7)/div);
		coef.scaling[3] = (float)((14.0-2.0*sqrt7)/div);
		coef.scaling[4] = (float)((1.0-sqrt7)/div);
		coef.scaling[5] = (float)((-3.0+sqrt7)/div);

		coef.wavelet[0] = coef.scaling[5];
		coef.wavelet[1] = -coef.scaling[4];
		coef.wavelet[2] = coef.scaling[3];
		coef.wavelet[3] = -coef.scaling[2];
		coef.wavelet[4] = coef.scaling[1];
		coef.wavelet[5] = -coef.scaling[0];

		WlBorderCoefStandard<WlCoef_F32> inverse = new WlBorderCoefStandard<>(coef);

		return new WaveletDescription<>(new BorderIndex1D_Wrap(), coef, inverse);
	}
1190655
private Builder createProtoClassBuilder() {
    componentExposedTypeBuilder.addField(
        FieldSpec
            .builder(ClassName.bestGuess("Proto"), "__proto__", Modifier.PUBLIC)
            .addAnnotation(JsProperty.class)
            .build()
    );

    return TypeSpec
        .classBuilder("Proto")
        .addSuperinterface(ParameterizedTypeName.get(JsPropertyMap.class, Object.class))
        .addModifiers(Modifier.STATIC)
        .addModifiers(Modifier.PRIVATE)
        .addAnnotation(AnnotationSpec
            .builder(JsType.class)
            .addMember("isNative", "$L", true)
            .addMember("namespace", "$T.GLOBAL", JsPackage.class)
            .addMember("name", "$S", "Object")
            .build());
  }
726397
function getAbbr(wofData) {
  const iso2 = getPropertyValue(wofData, 'wof:country');

  // sometimes there are codes set to XX which cause an exception so check if it's a valid ISO2 code
  if (iso2 !== false && iso3166.is2(iso2)) {
    return iso3166.to3(iso2);
  }

  return null;
}
701788
public static Iterator<Widget> getChildren(Widget w) {
    if (w instanceof Panel) {
      return ((Panel) w).iterator();
    }
    if (w instanceof Composite) {
      return getChildren(compositeGetWidget((Composite) w));
    }
    return null;
  }
819916
public long readRawVarint64() throws IOException
    {
        // final byte[] buffer = this.buffer;
        // int offset = this.offset;

        int shift = 0;
        long result = 0;
        while (shift < 64)
        {
            final byte b = buffer.get();
            result |= (long) (b & 0x7F) << shift;
            if ((b & 0x80) == 0)
            {
                // this.offset = offset;
                return result;
            }
            shift += 7;
        }
        throw ProtobufException.malformedVarint();
    }
1153012
private static WlCoef_I32 generateInv_I32() {
		WlCoef_I32 ret = new WlCoef_I32();

		ret.scaling = new int[]{1,1};
		ret.wavelet = new int[]{ret.scaling[0],-ret.scaling[0]};
		ret.denominatorScaling = 2;
		ret.denominatorWavelet = 2;

		return ret;
	}
1106810
def wploader(self):
        ''''''
        if self.target_system not in self.wploader_by_sysid:
            self.wploader_by_sysid[self.target_system] = mavwp.MAVWPLoader()
        return self.wploader_by_sysid[self.target_system]
147418
public ByteBuffer preProcessOneWriteBuffer() {
        // We can process the single buffer case more efficiently than if we
        // include it as a part of the multi-buffer logic
        WsByteBufferImpl wsBuffImpl = null;
        try {
            wsBuffImpl = (WsByteBufferImpl) getBuffer();
        } catch (ClassCastException cce) {
            if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                Tr.debug(tc, "Writing with a non-WsByteBufferImpl");
            }
            return getBuffer().getWrappedByteBuffer();
        }

        if (!wsBuffImpl.isDirect() && wsBuffImpl.hasArray()) {
            wsBuffImpl.copyToDirectBuffer();
            return wsBuffImpl.oWsBBDirect;
        }
        return wsBuffImpl.getWrappedByteBufferNonSafe();
    }
1319427
public static org.geomajas.gwt.client.spatial.Bbox toGwt(Bbox bbox) {
		return new org.geomajas.gwt.client.spatial.Bbox(bbox);
	}
785813
private IoBuffer encodeServerBW(ServerBW serverBW) {
        final IoBuffer out = IoBuffer.allocate(4);
        out.putInt(serverBW.getBandwidth());
        return out;
    }
165110
public long readRawVarint64() throws IOException
    {
        int shift = 0;
        long result = 0;
        while (shift < 64)
        {
            final byte b = readRawByte();
            result |= (long) (b & 0x7F) << shift;
            if ((b & 0x80) == 0)
            {
                return result;
            }
            shift += 7;
        }
        throw ProtobufException.malformedVarint();
    }
886744
public static byte[] byteBufToArray(ByteBuf byteBuf) {
        int length = byteBuf.readableBytes();
        byte[] byteArray = new byte[length];
        byteBuf.getBytes(byteBuf.readerIndex(), byteArray);
        return byteArray;
    }
1024666
protected final PrcWageCopy<RS> createPutPrcWageCopy(
    final Map<String, Object> pAddParam) throws Exception {
    PrcWageCopy<RS> proc = new PrcWageCopy<RS>();
    @SuppressWarnings("unchecked")
    IEntityProcessor<Wage, Long> procDlg = (IEntityProcessor<Wage, Long>)
      this.fctBnEntitiesProcessors
        .lazyGet(pAddParam, PrcEntityPbCopy.class.getSimpleName());
    proc.setPrcAccEntityPbCopy(procDlg);
    //assigning fully initialized object:
    this.processorsMap.put(PrcWageCopy.class.getSimpleName(), proc);
    return proc;
  }
1330510
public static int consumeLWS(final Buffer buffer) throws SipParseException {
        final int i = buffer.getReaderIndex();
        consumeWS(buffer);

        // if we consume a CRLF we expect at least ONE WS to be present next
        if (consumeCRLF(buffer) > 0) {
            expectWS(buffer);
        }
        consumeWS(buffer);
        if (buffer.getReaderIndex() == i) {
            throw new SipParseException(i, "Expected at least 1 WSP");
        }
        return buffer.getReaderIndex() - i;
    }