< prev index next >

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

Print this page




2171             }
2172             public void blockedOn(Interruptible b) {
2173                 Thread.blockedOn(b);
2174             }
2175             public void registerShutdownHook(int slot, boolean registerShutdownInProgress, Runnable hook) {
2176                 Shutdown.add(slot, registerShutdownInProgress, hook);
2177             }
2178             public Thread newThreadWithAcc(Runnable target, AccessControlContext acc) {
2179                 return new Thread(target, acc);
2180             }
2181             @SuppressWarnings("deprecation")
2182             public void invokeFinalize(Object o) throws Throwable {
2183                 o.finalize();
2184             }
2185             public ConcurrentHashMap<?, ?> createOrGetClassLoaderValueMap(ClassLoader cl) {
2186                 return cl.createOrGetClassLoaderValueMap();
2187             }
2188             public Class<?> defineClass(ClassLoader loader, String name, byte[] b, ProtectionDomain pd, String source) {
2189                 return ClassLoader.defineClass1(loader, name, b, 0, b.length, pd, source);
2190             }




2191             public Class<?> findBootstrapClassOrNull(ClassLoader cl, String name) {
2192                 return cl.findBootstrapClassOrNull(name);
2193             }
2194             public Package definePackage(ClassLoader cl, String name, Module module) {
2195                 return cl.definePackage(name, module);
2196             }
2197             public String fastUUID(long lsb, long msb) {
2198                 return Long.fastUUID(lsb, msb);
2199             }
2200             public void addNonExportedPackages(ModuleLayer layer) {
2201                 SecurityManager.addNonExportedPackages(layer);
2202             }
2203             public void invalidatePackageAccessCache() {
2204                 SecurityManager.invalidatePackageAccessCache();
2205             }
2206             public Module defineModule(ClassLoader loader,
2207                                        ModuleDescriptor descriptor,
2208                                        URI uri) {
2209                 return new Module(null, loader, descriptor, uri);
2210             }


2252             }
2253 
2254             public String newStringNoRepl(byte[] bytes, Charset cs) throws CharacterCodingException  {
2255                 return StringCoding.newStringNoRepl(bytes, cs);
2256             }
2257 
2258             public byte[] getBytesNoRepl(String s, Charset cs) throws CharacterCodingException {
2259                 return StringCoding.getBytesNoRepl(s, cs);
2260             }
2261 
2262             public String newStringUTF8NoRepl(byte[] bytes, int off, int len) {
2263                 return StringCoding.newStringUTF8NoRepl(bytes, off, len);
2264             }
2265 
2266             public byte[] getBytesUTF8NoRepl(String s) {
2267                 return StringCoding.getBytesUTF8NoRepl(s);
2268             }
2269 
2270             public void setCause(Throwable t, Throwable cause) {
2271                 t.setCause(cause);




2272             }
2273         });
2274     }
2275 }


2171             }
2172             public void blockedOn(Interruptible b) {
2173                 Thread.blockedOn(b);
2174             }
2175             public void registerShutdownHook(int slot, boolean registerShutdownInProgress, Runnable hook) {
2176                 Shutdown.add(slot, registerShutdownInProgress, hook);
2177             }
2178             public Thread newThreadWithAcc(Runnable target, AccessControlContext acc) {
2179                 return new Thread(target, acc);
2180             }
2181             @SuppressWarnings("deprecation")
2182             public void invokeFinalize(Object o) throws Throwable {
2183                 o.finalize();
2184             }
2185             public ConcurrentHashMap<?, ?> createOrGetClassLoaderValueMap(ClassLoader cl) {
2186                 return cl.createOrGetClassLoaderValueMap();
2187             }
2188             public Class<?> defineClass(ClassLoader loader, String name, byte[] b, ProtectionDomain pd, String source) {
2189                 return ClassLoader.defineClass1(loader, name, b, 0, b.length, pd, source);
2190             }
2191             public Class<?> defineClass(ClassLoader loader, Class<?> lookup, String name, byte[] b, ProtectionDomain pd,
2192                                         int flags, Object classData) {
2193                 return ClassLoader.defineClass0(loader, lookup, name, b, 0, b.length, pd, flags, classData);
2194             }
2195             public Class<?> findBootstrapClassOrNull(ClassLoader cl, String name) {
2196                 return cl.findBootstrapClassOrNull(name);
2197             }
2198             public Package definePackage(ClassLoader cl, String name, Module module) {
2199                 return cl.definePackage(name, module);
2200             }
2201             public String fastUUID(long lsb, long msb) {
2202                 return Long.fastUUID(lsb, msb);
2203             }
2204             public void addNonExportedPackages(ModuleLayer layer) {
2205                 SecurityManager.addNonExportedPackages(layer);
2206             }
2207             public void invalidatePackageAccessCache() {
2208                 SecurityManager.invalidatePackageAccessCache();
2209             }
2210             public Module defineModule(ClassLoader loader,
2211                                        ModuleDescriptor descriptor,
2212                                        URI uri) {
2213                 return new Module(null, loader, descriptor, uri);
2214             }


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             public ProtectionDomain protectionDomain(Class<?> c) {
2279                 return c.protectionDomain();
2280             }
2281         });
2282     }
2283 }
< prev index next >