Path: blob/master/src/java.base/share/native/libjava/java_props.h
41149 views
/*1* Copyright (c) 1998, 2013, Oracle and/or its affiliates. All rights reserved.2* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.3*4* This code is free software; you can redistribute it and/or modify it5* under the terms of the GNU General Public License version 2 only, as6* published by the Free Software Foundation. Oracle designates this7* particular file as subject to the "Classpath" exception as provided8* by Oracle in the LICENSE file that accompanied this code.9*10* This code is distributed in the hope that it will be useful, but WITHOUT11* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or12* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License13* version 2 for more details (a copy is included in the LICENSE file that14* accompanied this code).15*16* You should have received a copy of the GNU General Public License version17* 2 along with this work; if not, write to the Free Software Foundation,18* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.19*20* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA21* or visit www.oracle.com if you need additional information or have any22* questions.23*/2425#ifndef _JAVA_PROPS_H26#define _JAVA_PROPS_H2728#include <jni_util.h>2930/* The preferred native type for storing text on the current OS */31#ifdef WIN3232#include <tchar.h>33typedef WCHAR nchar;34#else35typedef char nchar;36#endif3738typedef struct {39char *os_name;40char *os_version;41char *os_arch;4243#ifdef JDK_ARCH_ABI_PROP_NAME44char *sun_arch_abi;45#endif4647nchar *tmp_dir;48nchar *user_dir;4950char *file_separator;51char *path_separator;52char *line_separator;5354nchar *user_name;55nchar *user_home;5657char *format_language;58char *display_language;59char *format_script;60char *display_script;61char *format_country;62char *display_country;63char *format_variant;64char *display_variant;65char *encoding;66char *sun_jnu_encoding;67char *sun_stdout_encoding;68char *sun_stderr_encoding;6970char *unicode_encoding; /* The default endianness of unicode71i.e. UnicodeBig or UnicodeLittle */7273const char *cpu_isalist; /* list of supported instruction sets */7475char *cpu_endian; /* endianness of platform */7677char *data_model; /* 32 or 64 bit data model */7879char *patch_level; /* patches/service packs installed */8081#ifdef MACOSX82// These are for proxy-related information.83// Note that if these platform-specific extensions get out of hand we should make a new84// structure for them and #include it here.85int httpProxyEnabled;86char *httpHost;87char *httpPort;8889int httpsProxyEnabled;90char *httpsHost;91char *httpsPort;9293int ftpProxyEnabled;94char *ftpHost;95char *ftpPort;9697int socksProxyEnabled;98char *socksHost;99char *socksPort;100101char *exceptionList;102#endif103104} java_props_t;105106java_props_t *GetJavaProperties(JNIEnv *env);107jstring GetStringPlatform(JNIEnv *env, nchar* str);108109#endif /* _JAVA_PROPS_H */110111112