< prev index next >

src/java.base/share/classes/java/lang/System.java

Print this page




  32 import java.io.FileOutputStream;
  33 import java.io.IOException;
  34 import java.io.InputStream;
  35 import java.io.PrintStream;
  36 import java.io.UnsupportedEncodingException;
  37 import java.lang.annotation.Annotation;
  38 import java.lang.module.ModuleDescriptor;
  39 import java.lang.reflect.Constructor;
  40 import java.lang.reflect.Executable;
  41 import java.lang.reflect.Method;
  42 import java.lang.reflect.Modifier;
  43 import java.net.URI;
  44 import java.nio.charset.CharacterCodingException;
  45 import java.security.AccessControlContext;
  46 import java.security.ProtectionDomain;
  47 import java.security.AccessController;
  48 import java.security.PrivilegedAction;
  49 import java.nio.channels.Channel;
  50 import java.nio.channels.spi.SelectorProvider;
  51 import java.nio.charset.Charset;

  52 import java.util.Iterator;
  53 import java.util.List;
  54 import java.util.Map;
  55 import java.util.Objects;
  56 import java.util.Properties;
  57 import java.util.PropertyPermission;
  58 import java.util.ResourceBundle;

  59 import java.util.function.Supplier;
  60 import java.util.concurrent.ConcurrentHashMap;
  61 import java.util.stream.Stream;
  62 
  63 import jdk.internal.util.StaticProperty;
  64 import jdk.internal.module.ModuleBootstrap;
  65 import jdk.internal.module.ServicesCatalog;
  66 import jdk.internal.reflect.CallerSensitive;
  67 import jdk.internal.reflect.Reflection;
  68 import jdk.internal.HotSpotIntrinsicCandidate;
  69 import jdk.internal.access.JavaLangAccess;
  70 import jdk.internal.access.SharedSecrets;
  71 import jdk.internal.misc.VM;
  72 import jdk.internal.logger.LoggerFinderLoader;
  73 import jdk.internal.logger.LazyLoggers;
  74 import jdk.internal.logger.LocalizedLoggerWrapper;
  75 import jdk.internal.util.SystemProps;
  76 import jdk.internal.vm.annotation.Stable;
  77 import sun.reflect.annotation.AnnotationType;
  78 import sun.nio.ch.Interruptible;


2253             }
2254             public Stream<ModuleLayer> layers(ClassLoader loader) {
2255                 return ModuleLayer.layers(loader);
2256             }
2257 
2258             public String newStringNoRepl(byte[] bytes, Charset cs) throws CharacterCodingException  {
2259                 return StringCoding.newStringNoRepl(bytes, cs);
2260             }
2261 
2262             public byte[] getBytesNoRepl(String s, Charset cs) throws CharacterCodingException {
2263                 return StringCoding.getBytesNoRepl(s, cs);
2264             }
2265 
2266             public String newStringUTF8NoRepl(byte[] bytes, int off, int len) {
2267                 return StringCoding.newStringUTF8NoRepl(bytes, off, len);
2268             }
2269 
2270             public byte[] getBytesUTF8NoRepl(String s) {
2271                 return StringCoding.getBytesUTF8NoRepl(s);
2272             }
2273 
2274             public void setCause(Throwable t, Throwable cause) {
2275                 t.setCause(cause);
2276             }
2277         });
2278     }
2279 }


  32 import java.io.FileOutputStream;
  33 import java.io.IOException;
  34 import java.io.InputStream;
  35 import java.io.PrintStream;
  36 import java.io.UnsupportedEncodingException;
  37 import java.lang.annotation.Annotation;
  38 import java.lang.module.ModuleDescriptor;
  39 import java.lang.reflect.Constructor;
  40 import java.lang.reflect.Executable;
  41 import java.lang.reflect.Method;
  42 import java.lang.reflect.Modifier;
  43 import java.net.URI;
  44 import java.nio.charset.CharacterCodingException;
  45 import java.security.AccessControlContext;
  46 import java.security.ProtectionDomain;
  47 import java.security.AccessController;
  48 import java.security.PrivilegedAction;
  49 import java.nio.channels.Channel;
  50 import java.nio.channels.spi.SelectorProvider;
  51 import java.nio.charset.Charset;
  52 import java.util.Collections;
  53 import java.util.Iterator;
  54 import java.util.List;
  55 import java.util.Map;
  56 import java.util.Objects;
  57 import java.util.Properties;
  58 import java.util.PropertyPermission;
  59 import java.util.ResourceBundle;
  60 import java.util.Set;
  61 import java.util.function.Supplier;
  62 import java.util.concurrent.ConcurrentHashMap;
  63 import java.util.stream.Stream;
  64 
  65 import jdk.internal.util.StaticProperty;
  66 import jdk.internal.module.ModuleBootstrap;
  67 import jdk.internal.module.ServicesCatalog;
  68 import jdk.internal.reflect.CallerSensitive;
  69 import jdk.internal.reflect.Reflection;
  70 import jdk.internal.HotSpotIntrinsicCandidate;
  71 import jdk.internal.access.JavaLangAccess;
  72 import jdk.internal.access.SharedSecrets;
  73 import jdk.internal.misc.VM;
  74 import jdk.internal.logger.LoggerFinderLoader;
  75 import jdk.internal.logger.LazyLoggers;
  76 import jdk.internal.logger.LocalizedLoggerWrapper;
  77 import jdk.internal.util.SystemProps;
  78 import jdk.internal.vm.annotation.Stable;
  79 import sun.reflect.annotation.AnnotationType;
  80 import sun.nio.ch.Interruptible;


2255             }
2256             public Stream<ModuleLayer> layers(ClassLoader loader) {
2257                 return ModuleLayer.layers(loader);
2258             }
2259 
2260             public String newStringNoRepl(byte[] bytes, Charset cs) throws CharacterCodingException  {
2261                 return StringCoding.newStringNoRepl(bytes, cs);
2262             }
2263 
2264             public byte[] getBytesNoRepl(String s, Charset cs) throws CharacterCodingException {
2265                 return StringCoding.getBytesNoRepl(s, cs);
2266             }
2267 
2268             public String newStringUTF8NoRepl(byte[] bytes, int off, int len) {
2269                 return StringCoding.newStringUTF8NoRepl(bytes, off, len);
2270             }
2271 
2272             public byte[] getBytesUTF8NoRepl(String s) {
2273                 return StringCoding.getBytesUTF8NoRepl(s);
2274             }

2275             public void setCause(Throwable t, Throwable cause) {
2276                 t.setCause(cause);
2277             }
2278         });
2279     }
2280 }
< prev index next >