src/share/classes/org/omg/CORBA_2_3/portable/OutputStream.java

Print this page
rev 597 : 8047722: @since tag cleanup in corba
Reviewed-by:


  25 /*
  26  * Licensed Materials - Property of IBM
  27  * RMI-IIOP v1.0
  28  * Copyright IBM Corp. 1998 1999  All Rights Reserved
  29  *
  30  */
  31 
  32 package org.omg.CORBA_2_3.portable;
  33 
  34 import java.io.SerializablePermission;
  35 import java.security.AccessController;
  36 import java.security.PrivilegedAction;
  37 
  38 /**
  39  * OutputStream provides interface for writing of all of the mapped IDL type
  40  * to the stream. It extends org.omg.CORBA.portable.OutputStream, and defines
  41  * new methods defined by CORBA 2.3.
  42  *
  43  * @see org.omg.CORBA.portable.OutputStream
  44  * @author  OMG
  45  * @since   JDK1.2
  46  */
  47 
  48 public abstract class OutputStream extends org.omg.CORBA.portable.OutputStream {
  49 
  50     private static final String ALLOW_SUBCLASS_PROP = "jdk.corba.allowOutputStreamSubclass";
  51     private static final boolean allowSubclass = AccessController.doPrivileged(
  52         new PrivilegedAction<Boolean>() {
  53             @Override
  54             public Boolean run() {
  55             String prop = System.getProperty(ALLOW_SUBCLASS_PROP);
  56                 return prop == null ? false :
  57                            (prop.equalsIgnoreCase("false") ? false : true);
  58             }
  59         });
  60 
  61     private static Void checkPermission() {
  62         SecurityManager sm = System.getSecurityManager();
  63         if (sm != null) {
  64             if (!allowSubclass)
  65                 sm.checkPermission(new




  25 /*
  26  * Licensed Materials - Property of IBM
  27  * RMI-IIOP v1.0
  28  * Copyright IBM Corp. 1998 1999  All Rights Reserved
  29  *
  30  */
  31 
  32 package org.omg.CORBA_2_3.portable;
  33 
  34 import java.io.SerializablePermission;
  35 import java.security.AccessController;
  36 import java.security.PrivilegedAction;
  37 
  38 /**
  39  * OutputStream provides interface for writing of all of the mapped IDL type
  40  * to the stream. It extends org.omg.CORBA.portable.OutputStream, and defines
  41  * new methods defined by CORBA 2.3.
  42  *
  43  * @see org.omg.CORBA.portable.OutputStream
  44  * @author  OMG
  45  * @since   1.2
  46  */
  47 
  48 public abstract class OutputStream extends org.omg.CORBA.portable.OutputStream {
  49 
  50     private static final String ALLOW_SUBCLASS_PROP = "jdk.corba.allowOutputStreamSubclass";
  51     private static final boolean allowSubclass = AccessController.doPrivileged(
  52         new PrivilegedAction<Boolean>() {
  53             @Override
  54             public Boolean run() {
  55             String prop = System.getProperty(ALLOW_SUBCLASS_PROP);
  56                 return prop == null ? false :
  57                            (prop.equalsIgnoreCase("false") ? false : true);
  58             }
  59         });
  60 
  61     private static Void checkPermission() {
  62         SecurityManager sm = System.getSecurityManager();
  63         if (sm != null) {
  64             if (!allowSubclass)
  65                 sm.checkPermission(new