类org.omg.CORBA.OctetSeqHelper源码实例Demo

下面列出了怎么用org.omg.CORBA.OctetSeqHelper的API类实例代码及写法,或者点击链接到github查看源代码。

源代码1 项目: jdk1.8-source-analysis   文件: ServiceContexts.java
/**
 * Given the input stream, this fills our service
 * context map.  See the definition of scMap for
 * details.  Creates a HashMap.
 *
 * Note that we don't actually unmarshal the
 * bytes of the service contexts here.  That is
 * done when they are actually requested via
 * get(int).
 */
private void createMapFromInputStream(InputStream is)
{
    orb = (ORB)(is.orb()) ;
    if (orb.serviceContextDebugFlag)
        dprint( "Constructing ServiceContexts from input stream" ) ;

    int numValid = is.read_long() ;

    if (orb.serviceContextDebugFlag)
        dprint("Number of service contexts = " + numValid);

    for (int ctr = 0; ctr < numValid; ctr++) {
        int scId = is.read_long();

        if (orb.serviceContextDebugFlag)
            dprint("Reading service context id " + scId);

        byte[] data = OctetSeqHelper.read(is);

        if (orb.serviceContextDebugFlag)
            dprint("Service context" + scId + " length: " + data.length);

        scMap.put(new Integer(scId), data);
    }
}
 
源代码2 项目: jdk1.8-source-analysis   文件: ServiceContexts.java
/**
 * Write the given entry from the scMap to the OutputStream.
 * See note on giopVersion.  The service context should
 * know the GIOP version it is meant for.
 */
private void writeMapEntry(OutputStream os, Integer id, Object scObj, GIOPVersion gv) {

    // If it's still in byte[] form, we don't need to
    // unmarshal it here, just copy the bytes into
    // the new stream.

    if (scObj instanceof byte[]) {
        if (isDebugging(os))
            dprint( "Writing service context bytes for id " + id);

        OctetSeqHelper.write(os, (byte[])scObj);

    } else {

        // We actually unmarshaled it into a ServiceContext
        // at some point.
        ServiceContext sc = (ServiceContext)scObj;

        if (isDebugging(os))
            dprint( "Writing service context " + sc ) ;

        sc.write(os, gv);
    }
}
 
源代码3 项目: TencentKona-8   文件: ServiceContexts.java
/**
 * Given the input stream, this fills our service
 * context map.  See the definition of scMap for
 * details.  Creates a HashMap.
 *
 * Note that we don't actually unmarshal the
 * bytes of the service contexts here.  That is
 * done when they are actually requested via
 * get(int).
 */
private void createMapFromInputStream(InputStream is)
{
    orb = (ORB)(is.orb()) ;
    if (orb.serviceContextDebugFlag)
        dprint( "Constructing ServiceContexts from input stream" ) ;

    int numValid = is.read_long() ;

    if (orb.serviceContextDebugFlag)
        dprint("Number of service contexts = " + numValid);

    for (int ctr = 0; ctr < numValid; ctr++) {
        int scId = is.read_long();

        if (orb.serviceContextDebugFlag)
            dprint("Reading service context id " + scId);

        byte[] data = OctetSeqHelper.read(is);

        if (orb.serviceContextDebugFlag)
            dprint("Service context" + scId + " length: " + data.length);

        scMap.put(new Integer(scId), data);
    }
}
 
源代码4 项目: TencentKona-8   文件: ServiceContexts.java
/**
 * Write the given entry from the scMap to the OutputStream.
 * See note on giopVersion.  The service context should
 * know the GIOP version it is meant for.
 */
private void writeMapEntry(OutputStream os, Integer id, Object scObj, GIOPVersion gv) {

    // If it's still in byte[] form, we don't need to
    // unmarshal it here, just copy the bytes into
    // the new stream.

    if (scObj instanceof byte[]) {
        if (isDebugging(os))
            dprint( "Writing service context bytes for id " + id);

        OctetSeqHelper.write(os, (byte[])scObj);

    } else {

        // We actually unmarshaled it into a ServiceContext
        // at some point.
        ServiceContext sc = (ServiceContext)scObj;

        if (isDebugging(os))
            dprint( "Writing service context " + sc ) ;

        sc.write(os, gv);
    }
}
 
源代码5 项目: jdk8u60   文件: ServiceContexts.java
/**
 * Given the input stream, this fills our service
 * context map.  See the definition of scMap for
 * details.  Creates a HashMap.
 *
 * Note that we don't actually unmarshal the
 * bytes of the service contexts here.  That is
 * done when they are actually requested via
 * get(int).
 */
private void createMapFromInputStream(InputStream is)
{
    orb = (ORB)(is.orb()) ;
    if (orb.serviceContextDebugFlag)
        dprint( "Constructing ServiceContexts from input stream" ) ;

    int numValid = is.read_long() ;

    if (orb.serviceContextDebugFlag)
        dprint("Number of service contexts = " + numValid);

    for (int ctr = 0; ctr < numValid; ctr++) {
        int scId = is.read_long();

        if (orb.serviceContextDebugFlag)
            dprint("Reading service context id " + scId);

        byte[] data = OctetSeqHelper.read(is);

        if (orb.serviceContextDebugFlag)
            dprint("Service context" + scId + " length: " + data.length);

        scMap.put(new Integer(scId), data);
    }
}
 
源代码6 项目: jdk8u60   文件: ServiceContexts.java
/**
 * Write the given entry from the scMap to the OutputStream.
 * See note on giopVersion.  The service context should
 * know the GIOP version it is meant for.
 */
private void writeMapEntry(OutputStream os, Integer id, Object scObj, GIOPVersion gv) {

    // If it's still in byte[] form, we don't need to
    // unmarshal it here, just copy the bytes into
    // the new stream.

    if (scObj instanceof byte[]) {
        if (isDebugging(os))
            dprint( "Writing service context bytes for id " + id);

        OctetSeqHelper.write(os, (byte[])scObj);

    } else {

        // We actually unmarshaled it into a ServiceContext
        // at some point.
        ServiceContext sc = (ServiceContext)scObj;

        if (isDebugging(os))
            dprint( "Writing service context " + sc ) ;

        sc.write(os, gv);
    }
}
 
源代码7 项目: JDKSourceCode1.8   文件: ServiceContexts.java
/**
 * Given the input stream, this fills our service
 * context map.  See the definition of scMap for
 * details.  Creates a HashMap.
 *
 * Note that we don't actually unmarshal the
 * bytes of the service contexts here.  That is
 * done when they are actually requested via
 * get(int).
 */
private void createMapFromInputStream(InputStream is)
{
    orb = (ORB)(is.orb()) ;
    if (orb.serviceContextDebugFlag)
        dprint( "Constructing ServiceContexts from input stream" ) ;

    int numValid = is.read_long() ;

    if (orb.serviceContextDebugFlag)
        dprint("Number of service contexts = " + numValid);

    for (int ctr = 0; ctr < numValid; ctr++) {
        int scId = is.read_long();

        if (orb.serviceContextDebugFlag)
            dprint("Reading service context id " + scId);

        byte[] data = OctetSeqHelper.read(is);

        if (orb.serviceContextDebugFlag)
            dprint("Service context" + scId + " length: " + data.length);

        scMap.put(new Integer(scId), data);
    }
}
 
源代码8 项目: JDKSourceCode1.8   文件: ServiceContexts.java
/**
 * Write the given entry from the scMap to the OutputStream.
 * See note on giopVersion.  The service context should
 * know the GIOP version it is meant for.
 */
private void writeMapEntry(OutputStream os, Integer id, Object scObj, GIOPVersion gv) {

    // If it's still in byte[] form, we don't need to
    // unmarshal it here, just copy the bytes into
    // the new stream.

    if (scObj instanceof byte[]) {
        if (isDebugging(os))
            dprint( "Writing service context bytes for id " + id);

        OctetSeqHelper.write(os, (byte[])scObj);

    } else {

        // We actually unmarshaled it into a ServiceContext
        // at some point.
        ServiceContext sc = (ServiceContext)scObj;

        if (isDebugging(os))
            dprint( "Writing service context " + sc ) ;

        sc.write(os, gv);
    }
}
 
源代码9 项目: openjdk-jdk8u   文件: ServiceContexts.java
/**
 * Given the input stream, this fills our service
 * context map.  See the definition of scMap for
 * details.  Creates a HashMap.
 *
 * Note that we don't actually unmarshal the
 * bytes of the service contexts here.  That is
 * done when they are actually requested via
 * get(int).
 */
private void createMapFromInputStream(InputStream is)
{
    orb = (ORB)(is.orb()) ;
    if (orb.serviceContextDebugFlag)
        dprint( "Constructing ServiceContexts from input stream" ) ;

    int numValid = is.read_long() ;

    if (orb.serviceContextDebugFlag)
        dprint("Number of service contexts = " + numValid);

    for (int ctr = 0; ctr < numValid; ctr++) {
        int scId = is.read_long();

        if (orb.serviceContextDebugFlag)
            dprint("Reading service context id " + scId);

        byte[] data = OctetSeqHelper.read(is);

        if (orb.serviceContextDebugFlag)
            dprint("Service context" + scId + " length: " + data.length);

        scMap.put(new Integer(scId), data);
    }
}
 
源代码10 项目: openjdk-jdk8u   文件: ServiceContexts.java
/**
 * Write the given entry from the scMap to the OutputStream.
 * See note on giopVersion.  The service context should
 * know the GIOP version it is meant for.
 */
private void writeMapEntry(OutputStream os, Integer id, Object scObj, GIOPVersion gv) {

    // If it's still in byte[] form, we don't need to
    // unmarshal it here, just copy the bytes into
    // the new stream.

    if (scObj instanceof byte[]) {
        if (isDebugging(os))
            dprint( "Writing service context bytes for id " + id);

        OctetSeqHelper.write(os, (byte[])scObj);

    } else {

        // We actually unmarshaled it into a ServiceContext
        // at some point.
        ServiceContext sc = (ServiceContext)scObj;

        if (isDebugging(os))
            dprint( "Writing service context " + sc ) ;

        sc.write(os, gv);
    }
}
 
源代码11 项目: openjdk-jdk8u-backup   文件: ServiceContexts.java
/**
 * Given the input stream, this fills our service
 * context map.  See the definition of scMap for
 * details.  Creates a HashMap.
 *
 * Note that we don't actually unmarshal the
 * bytes of the service contexts here.  That is
 * done when they are actually requested via
 * get(int).
 */
private void createMapFromInputStream(InputStream is)
{
    orb = (ORB)(is.orb()) ;
    if (orb.serviceContextDebugFlag)
        dprint( "Constructing ServiceContexts from input stream" ) ;

    int numValid = is.read_long() ;

    if (orb.serviceContextDebugFlag)
        dprint("Number of service contexts = " + numValid);

    for (int ctr = 0; ctr < numValid; ctr++) {
        int scId = is.read_long();

        if (orb.serviceContextDebugFlag)
            dprint("Reading service context id " + scId);

        byte[] data = OctetSeqHelper.read(is);

        if (orb.serviceContextDebugFlag)
            dprint("Service context" + scId + " length: " + data.length);

        scMap.put(new Integer(scId), data);
    }
}
 
源代码12 项目: openjdk-jdk8u-backup   文件: ServiceContexts.java
/**
 * Write the given entry from the scMap to the OutputStream.
 * See note on giopVersion.  The service context should
 * know the GIOP version it is meant for.
 */
private void writeMapEntry(OutputStream os, Integer id, Object scObj, GIOPVersion gv) {

    // If it's still in byte[] form, we don't need to
    // unmarshal it here, just copy the bytes into
    // the new stream.

    if (scObj instanceof byte[]) {
        if (isDebugging(os))
            dprint( "Writing service context bytes for id " + id);

        OctetSeqHelper.write(os, (byte[])scObj);

    } else {

        // We actually unmarshaled it into a ServiceContext
        // at some point.
        ServiceContext sc = (ServiceContext)scObj;

        if (isDebugging(os))
            dprint( "Writing service context " + sc ) ;

        sc.write(os, gv);
    }
}
 
源代码13 项目: openjdk-jdk9   文件: ServiceContexts.java
/**
 * Given the input stream, this fills our service
 * context map.  See the definition of scMap for
 * details.  Creates a HashMap.
 *
 * Note that we don't actually unmarshal the
 * bytes of the service contexts here.  That is
 * done when they are actually requested via
 * get(int).
 */
private void createMapFromInputStream(InputStream is)
{
    orb = (ORB)(is.orb()) ;
    if (orb.serviceContextDebugFlag)
        dprint( "Constructing ServiceContexts from input stream" ) ;

    int numValid = is.read_long() ;

    if (orb.serviceContextDebugFlag)
        dprint("Number of service contexts = " + numValid);

    for (int ctr = 0; ctr < numValid; ctr++) {
        int scId = is.read_long();

        if (orb.serviceContextDebugFlag)
            dprint("Reading service context id " + scId);

        byte[] data = OctetSeqHelper.read(is);

        if (orb.serviceContextDebugFlag)
            dprint("Service context" + scId + " length: " + data.length);

        scMap.put(new Integer(scId), data);
    }
}
 
源代码14 项目: openjdk-jdk9   文件: ServiceContexts.java
/**
 * Write the given entry from the scMap to the OutputStream.
 * See note on giopVersion.  The service context should
 * know the GIOP version it is meant for.
 */
private void writeMapEntry(OutputStream os, Integer id, Object scObj, GIOPVersion gv) {

    // If it's still in byte[] form, we don't need to
    // unmarshal it here, just copy the bytes into
    // the new stream.

    if (scObj instanceof byte[]) {
        if (isDebugging(os))
            dprint( "Writing service context bytes for id " + id);

        OctetSeqHelper.write(os, (byte[])scObj);

    } else {

        // We actually unmarshaled it into a ServiceContext
        // at some point.
        ServiceContext sc = (ServiceContext)scObj;

        if (isDebugging(os))
            dprint( "Writing service context " + sc ) ;

        sc.write(os, gv);
    }
}
 
源代码15 项目: hottub   文件: ServiceContexts.java
/**
 * Given the input stream, this fills our service
 * context map.  See the definition of scMap for
 * details.  Creates a HashMap.
 *
 * Note that we don't actually unmarshal the
 * bytes of the service contexts here.  That is
 * done when they are actually requested via
 * get(int).
 */
private void createMapFromInputStream(InputStream is)
{
    orb = (ORB)(is.orb()) ;
    if (orb.serviceContextDebugFlag)
        dprint( "Constructing ServiceContexts from input stream" ) ;

    int numValid = is.read_long() ;

    if (orb.serviceContextDebugFlag)
        dprint("Number of service contexts = " + numValid);

    for (int ctr = 0; ctr < numValid; ctr++) {
        int scId = is.read_long();

        if (orb.serviceContextDebugFlag)
            dprint("Reading service context id " + scId);

        byte[] data = OctetSeqHelper.read(is);

        if (orb.serviceContextDebugFlag)
            dprint("Service context" + scId + " length: " + data.length);

        scMap.put(new Integer(scId), data);
    }
}
 
源代码16 项目: hottub   文件: ServiceContexts.java
/**
 * Write the given entry from the scMap to the OutputStream.
 * See note on giopVersion.  The service context should
 * know the GIOP version it is meant for.
 */
private void writeMapEntry(OutputStream os, Integer id, Object scObj, GIOPVersion gv) {

    // If it's still in byte[] form, we don't need to
    // unmarshal it here, just copy the bytes into
    // the new stream.

    if (scObj instanceof byte[]) {
        if (isDebugging(os))
            dprint( "Writing service context bytes for id " + id);

        OctetSeqHelper.write(os, (byte[])scObj);

    } else {

        // We actually unmarshaled it into a ServiceContext
        // at some point.
        ServiceContext sc = (ServiceContext)scObj;

        if (isDebugging(os))
            dprint( "Writing service context " + sc ) ;

        sc.write(os, gv);
    }
}
 
源代码17 项目: openjdk-8-source   文件: ServiceContexts.java
/**
 * Given the input stream, this fills our service
 * context map.  See the definition of scMap for
 * details.  Creates a HashMap.
 *
 * Note that we don't actually unmarshal the
 * bytes of the service contexts here.  That is
 * done when they are actually requested via
 * get(int).
 */
private void createMapFromInputStream(InputStream is)
{
    orb = (ORB)(is.orb()) ;
    if (orb.serviceContextDebugFlag)
        dprint( "Constructing ServiceContexts from input stream" ) ;

    int numValid = is.read_long() ;

    if (orb.serviceContextDebugFlag)
        dprint("Number of service contexts = " + numValid);

    for (int ctr = 0; ctr < numValid; ctr++) {
        int scId = is.read_long();

        if (orb.serviceContextDebugFlag)
            dprint("Reading service context id " + scId);

        byte[] data = OctetSeqHelper.read(is);

        if (orb.serviceContextDebugFlag)
            dprint("Service context" + scId + " length: " + data.length);

        scMap.put(new Integer(scId), data);
    }
}
 
源代码18 项目: openjdk-8-source   文件: ServiceContexts.java
/**
 * Write the given entry from the scMap to the OutputStream.
 * See note on giopVersion.  The service context should
 * know the GIOP version it is meant for.
 */
private void writeMapEntry(OutputStream os, Integer id, Object scObj, GIOPVersion gv) {

    // If it's still in byte[] form, we don't need to
    // unmarshal it here, just copy the bytes into
    // the new stream.

    if (scObj instanceof byte[]) {
        if (isDebugging(os))
            dprint( "Writing service context bytes for id " + id);

        OctetSeqHelper.write(os, (byte[])scObj);

    } else {

        // We actually unmarshaled it into a ServiceContext
        // at some point.
        ServiceContext sc = (ServiceContext)scObj;

        if (isDebugging(os))
            dprint( "Writing service context " + sc ) ;

        sc.write(os, gv);
    }
}
 
源代码19 项目: openjdk-8   文件: ServiceContexts.java
/**
 * Given the input stream, this fills our service
 * context map.  See the definition of scMap for
 * details.  Creates a HashMap.
 *
 * Note that we don't actually unmarshal the
 * bytes of the service contexts here.  That is
 * done when they are actually requested via
 * get(int).
 */
private void createMapFromInputStream(InputStream is)
{
    orb = (ORB)(is.orb()) ;
    if (orb.serviceContextDebugFlag)
        dprint( "Constructing ServiceContexts from input stream" ) ;

    int numValid = is.read_long() ;

    if (orb.serviceContextDebugFlag)
        dprint("Number of service contexts = " + numValid);

    for (int ctr = 0; ctr < numValid; ctr++) {
        int scId = is.read_long();

        if (orb.serviceContextDebugFlag)
            dprint("Reading service context id " + scId);

        byte[] data = OctetSeqHelper.read(is);

        if (orb.serviceContextDebugFlag)
            dprint("Service context" + scId + " length: " + data.length);

        scMap.put(new Integer(scId), data);
    }
}
 
源代码20 项目: openjdk-8   文件: ServiceContexts.java
/**
 * Write the given entry from the scMap to the OutputStream.
 * See note on giopVersion.  The service context should
 * know the GIOP version it is meant for.
 */
private void writeMapEntry(OutputStream os, Integer id, Object scObj, GIOPVersion gv) {

    // If it's still in byte[] form, we don't need to
    // unmarshal it here, just copy the bytes into
    // the new stream.

    if (scObj instanceof byte[]) {
        if (isDebugging(os))
            dprint( "Writing service context bytes for id " + id);

        OctetSeqHelper.write(os, (byte[])scObj);

    } else {

        // We actually unmarshaled it into a ServiceContext
        // at some point.
        ServiceContext sc = (ServiceContext)scObj;

        if (isDebugging(os))
            dprint( "Writing service context " + sc ) ;

        sc.write(os, gv);
    }
}
 
 类所在包
 类方法
 同包方法