text
stringlengths 2
100k
| meta
dict |
---|---|
/*
* Copyright (C) 2017 The Android Open Source Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package androidx.lifecycle;
/**
* {@link LiveData} which publicly exposes {@link #setValue(T)} and {@link #postValue(T)} method.
*
* @param <T> The type of data hold by this instance
*/
@SuppressWarnings("WeakerAccess")
public class MutableLiveData<T> extends LiveData<T> {
/**
* Creates a MutableLiveData initialized with the given {@code value}.
*
* @param value initial value
*/
public MutableLiveData(T value) {
super(value);
}
/**
* Creates a MutableLiveData with no value assigned to it.
*/
public MutableLiveData() {
super();
}
@Override
public void postValue(T value) {
super.postValue(value);
}
@Override
public void setValue(T value) {
super.setValue(value);
}
}
| {
"pile_set_name": "Github"
} |
#!/bin/bash
#########################################################################
##
## This file is part of the SAMRAI distribution. For full copyright
## information, see COPYRIGHT and LICENSE.
##
## Copyright: (c) 1997-2020 Lawrence Livermore National Security, LLC
##
########################################################################
set -o errexit
set -o nounset
# Check environment variables
sys_type=${SYS_TYPE:-""}
if [[ -z ${sys_type} ]]
then
sys_type=${OSTYPE:-""}
if [[ -z ${sys_type} ]]
then
echo "System type not found (both SYS_TYPE and OSTYPE are undefined)"
exit 1
fi
fi
build_root=${BUILD_ROOT:-""}
if [[ -z ${build_root} ]]
then
build_root=$(pwd)
fi
compiler=${COMPILER:-""}
if [[ -z ${compiler} ]]
then
echo "COMPILER is undefined... aborting" && exit 1
fi
project_dir="$(pwd)"
build_dir="${build_root}/build_${sys_type}_${compiler}"
option=${1:-""}
# Build
if [[ "${option}" != "--test-only" ]]
then
# If building, then delete everything first
rm -rf ${build_dir} && mkdir -p ${build_dir} && cd ${build_dir}
conf_suffix="host-configs/${sys_type}/${compiler}.cmake"
generic_conf="${project_dir}/.radiuss-ci/gitlab/conf/${conf_suffix}"
if [[ ! -f ${generic_conf} ]]
then
echo "ERROR: Host-config file ${generic_conf} does not exist" && exit 1
fi
samrai_conf="${project_dir}/${conf_suffix}"
if [[ ! -f ${samrai_conf} ]]
then
echo "ERROR: Host-config file ${samrai_conf} does not exist" && exit 1
fi
cmake \
-C ${generic_conf} \
-C ${samrai_conf} \
${project_dir}
cmake --build . -j 8
fi
# Test
if [[ "${option}" != "--build-only" ]]
then
if [[ ! -d ${build_dir} ]]
then
echo "ERROR: Build directory not found : ${build_dir}" && exit 1
fi
cd ${build_dir}
ctest_out=0
( ctest --output-on-failure -T test 2>&1 || ( ctest_out=$?; echo "Error(s) in CTest" ) ) | tee tests_output.txt
no_test_str="No tests were found!!!"
if [[ "$(tail -n 1 tests_output.txt)" == "${no_test_str}" ]]
then
echo "ERROR: No tests were found" && exit 1
fi
echo "Copying Testing xml reports for export"
tree Testing
for report in Testing/*/Test.xml
do
cp ${report} ${project_dir}/ctest_report_${report//\//_}
done
exit ${ctest_out}
fi
| {
"pile_set_name": "Github"
} |
-- Licensed to the Apache Software Foundation (ASF) under one or more
-- contributor license agreements. See the NOTICE file distributed with
-- this work for additional information regarding copyright ownership.
-- The ASF licenses this file to You under the Apache License, Version 2.0
-- (the "License"); you may not use this file except in compliance with
-- the License. You may obtain a copy of the License at
--
-- http://www.apache.org/licenses/LICENSE-2.0
--
-- Unless required by applicable law or agreed to in writing, software
-- distributed under the License is distributed on an "AS IS" BASIS,
-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-- See the License for the specific language governing permissions and
-- limitations under the License.
-- create sequences
CREATE SEQUENCE SEQ_GEN_IDENTITY START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_ACCESS_AUDIT_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_ASSET_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_AUDIT_MAP_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_AUTH_SESS_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_CRED_STORE_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_DB_BASE_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_GROUP_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_GROUP_GROUPS_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_GROUP_USERS_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_PERM_MAP_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_POLICY_EXPORT_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_PORTAL_USER_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_PORTAL_USER_ROLE_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_RESOURCE_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_TRX_LOG_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE X_USER_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE V_TRX_LOG_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
CREATE SEQUENCE XA_ACCESS_AUDIT_SEQ START WITH 1 INCREMENT BY 1 NOCACHE NOCYCLE;
commit;
-- create tables
CREATE TABLE x_portal_user (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
first_name VARCHAR(256) DEFAULT NULL NULL ,
last_name VARCHAR(256) DEFAULT NULL NULL ,
pub_scr_name VARCHAR(2048) DEFAULT NULL NULL ,
login_id VARCHAR(767) DEFAULT NULL NULL ,
password VARCHAR(512) NOT NULL,
email VARCHAR(512) DEFAULT NULL NULL ,
status NUMBER(11) DEFAULT '0' NOT NULL ,
user_src NUMBER(11) DEFAULT '0' NOT NULL ,
notes VARCHAR(4000) DEFAULT NULL NULL ,
PRIMARY KEY (id),
CONSTRAINT x_portal_user_UK_login_id UNIQUE (login_id) ,
CONSTRAINT x_portal_user_UK_email UNIQUE (email),
CONSTRAINT x_portal_user_FK_added_by_id FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_portal_user_FK_upd_by_id FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id)
);
CREATE TABLE x_portal_user_role (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
user_id NUMBER(20) NOT NULL ,
user_role VARCHAR(128) DEFAULT NULL NULL ,
status NUMBER(11) DEFAULT 0 NOT NULL ,
PRIMARY KEY (id),
CONSTRAINT x_portal_user_role_FK_addedby FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_portal_user_role_FK_updby FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_portal_user_role_FK_user_id FOREIGN KEY (user_id) REFERENCES x_portal_user (id)
);
CREATE TABLE xa_access_audit (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
audit_type NUMBER(11) DEFAULT '0' NOT NULL ,
access_result NUMBER(11) DEFAULT '0' NULL ,
access_type VARCHAR(255) DEFAULT NULL NULL ,
acl_enforcer VARCHAR(255) DEFAULT NULL NULL ,
agent_id VARCHAR(255) DEFAULT NULL NULL ,
client_ip VARCHAR(255) DEFAULT NULL NULL ,
client_type VARCHAR(255) DEFAULT NULL NULL ,
policy_id NUMBER(20) DEFAULT '0' NULL ,
repo_name VARCHAR(255) DEFAULT NULL NULL ,
repo_type NUMBER(11) DEFAULT '0' NULL,
result_reason VARCHAR(255) DEFAULT NULL NULL ,
session_id VARCHAR(255) DEFAULT NULL NULL ,
event_time DATE DEFAULT NULL NULL ,
request_user VARCHAR(255) DEFAULT NULL NULL ,
action VARCHAR(2000) DEFAULT NULL NULL ,
request_data VARCHAR(2000) DEFAULT NULL NULL ,
resource_path VARCHAR(2000) DEFAULT NULL NULL ,
resource_type VARCHAR(255) DEFAULT NULL NULL ,
PRIMARY KEY (id)
);
CREATE TABLE x_asset (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
asset_name VARCHAR(1024) NOT NULL,
descr VARCHAR(4000) DEFAULT NULL NULL,
act_status NUMBER(11) DEFAULT '0' NOT NULL ,
asset_type NUMBER(11) DEFAULT '0' NOT NULL,
config CLOB NULL,
sup_native NUMBER(1) DEFAULT '0' NOT NULL,
PRIMARY KEY (id),
CONSTRAINT x_asset_FK_added_by_id FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_asset_FK_upd_by_id FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id)
);
CREATE TABLE x_auth_sess (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
login_id VARCHAR(767) NOT NULL,
user_id NUMBER(20) DEFAULT NULL NULL ,
ext_sess_id VARCHAR(512) DEFAULT NULL NULL ,
auth_time DATE NOT NULL,
auth_status NUMBER(11) DEFAULT '0' NOT NULL ,
auth_type NUMBER(11) DEFAULT '0' NOT NULL ,
auth_provider NUMBER(11) DEFAULT '0' NOT NULL ,
device_type NUMBER(11) DEFAULT '0' NOT NULL ,
req_ip VARCHAR(48) NOT NULL,
req_ua VARCHAR(1024) DEFAULT NULL NULL ,
PRIMARY KEY (id),
CONSTRAINT x_auth_sess_FK_added_by_id FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_auth_sess_FK_upd_by_id FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_auth_sess_FK_user_id FOREIGN KEY (user_id) REFERENCES x_portal_user (id)
);
CREATE TABLE x_cred_store (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
store_name VARCHAR(1024) NOT NULL,
descr VARCHAR(4000) NOT NULL,
PRIMARY KEY (id),
CONSTRAINT x_cred_store_FK_added_by_id FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_cred_store_FK_upd_by_id FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id)
);
CREATE TABLE x_db_base (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
PRIMARY KEY (id),
CONSTRAINT x_db_base_FK_added_by_id FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_db_base_FK_upd_by_id FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id)
);
CREATE TABLE X_GROUP(
ID NUMBER(20,0) NOT NULL ENABLE,
CREATE_TIME DATE DEFAULT NULL,
UPDATE_TIME DATE DEFAULT NULL,
ADDED_BY_ID NUMBER(20,0) DEFAULT NULL,
UPD_BY_ID NUMBER(20,0) DEFAULT NULL,
GROUP_NAME VARCHAR2(1024) NOT NULL ENABLE,
DESCR VARCHAR2(4000) DEFAULT NULL NULL,
STATUS NUMBER(11,0) DEFAULT '0' NOT NULL ENABLE,
GROUP_TYPE NUMBER(11,0) DEFAULT '0' NOT NULL ENABLE,
CRED_STORE_ID NUMBER(20,0) DEFAULT NULL,
PRIMARY KEY (ID),
CONSTRAINT X_GROUP_FK_ADDED_BY_ID FOREIGN KEY (ADDED_BY_ID) REFERENCES X_PORTAL_USER (ID) ENABLE,
CONSTRAINT X_GROUP_FK_CRED_STORE_ID FOREIGN KEY (CRED_STORE_ID) REFERENCES X_CRED_STORE (ID) ENABLE,
CONSTRAINT X_GROUP_FK_UPD_BY_ID FOREIGN KEY (UPD_BY_ID) REFERENCES X_PORTAL_USER (ID) ENABLE
) ;
CREATE TABLE x_group_groups (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
group_name VARCHAR(1024) NOT NULL,
p_group_id NUMBER(20) DEFAULT NULL NULL ,
group_id NUMBER(20) DEFAULT NULL NULL ,
PRIMARY KEY (id),
CONSTRAINT x_group_groups_FK_added_by_id FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_group_groups_FK_group_id FOREIGN KEY (group_id) REFERENCES x_group (id),
CONSTRAINT x_group_groups_FK_p_group_id FOREIGN KEY (p_group_id) REFERENCES x_group (id),
CONSTRAINT x_group_groups_FK_upd_by_id FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id)
);
CREATE TABLE x_user (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
user_name VARCHAR(1024) NOT NULL,
descr VARCHAR(4000) DEFAULT NULL NULL,
status NUMBER(11) DEFAULT '0' NOT NULL,
cred_store_id NUMBER(20) DEFAULT NULL NULL ,
PRIMARY KEY (id),
CONSTRAINT x_user_FK_added_by_id FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_user_FK_cred_store_id FOREIGN KEY (cred_store_id) REFERENCES x_cred_store (id),
CONSTRAINT x_user_FK_upd_by_id FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id)
);
CREATE TABLE x_group_users (
id NUMBER(20) NOT NULL ,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
group_name VARCHAR(1024) NOT NULL,
p_group_id NUMBER(20) DEFAULT NULL NULL ,
user_id NUMBER(20) DEFAULT NULL NULL ,
PRIMARY KEY (id),
CONSTRAINT x_group_users_FK_added_by_id FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_group_users_FK_p_group_id FOREIGN KEY (p_group_id) REFERENCES x_group (id),
CONSTRAINT x_group_users_FK_upd_by_id FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_group_users_FK_user_id FOREIGN KEY (user_id) REFERENCES x_user (id)
);
CREATE TABLE x_policy_export_audit (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
client_ip VARCHAR(255) NOT NULL,
agent_id VARCHAR(255) DEFAULT NULL NULL ,
req_epoch NUMBER(20) NOT NULL,
last_updated DATE DEFAULT NULL NULL ,
repository_name VARCHAR(1024) DEFAULT NULL NULL ,
exported_json CLOB NULL,
http_ret_code NUMBER(11) DEFAULT '0' NOT NULL ,
PRIMARY KEY (id),
CONSTRAINT x_policy_export_audit_FK_added FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_policy_export_audit_FK_upd FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id)
);
CREATE TABLE x_resource (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
res_name VARCHAR(4000) DEFAULT NULL NULL ,
descr VARCHAR(4000) DEFAULT NULL NULL ,
res_type NUMBER(11) DEFAULT '0' NOT NULL ,
asset_id NUMBER(20) NOT NULL,
parent_id NUMBER(20) DEFAULT NULL NULL ,
parent_path VARCHAR(4000) DEFAULT NULL NULL ,
is_encrypt NUMBER(11) DEFAULT '0' NOT NULL ,
is_recursive NUMBER(11) DEFAULT '0' NOT NULL ,
res_group VARCHAR(1024) DEFAULT NULL NULL ,
res_dbs CLOB NULL,
res_tables CLOB NULL,
res_col_fams CLOB NULL,
res_cols CLOB NULL,
res_udfs CLOB NULL,
res_status NUMBER(11) DEFAULT '1' NOT NULL,
table_type NUMBER(11) DEFAULT '0' NOT NULL,
col_type NUMBER(11) DEFAULT '0' NOT NULL,
PRIMARY KEY (id),
CONSTRAINT x_resource_FK_added_by_id FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_resource_FK_asset_id FOREIGN KEY (asset_id) REFERENCES x_asset (id),
CONSTRAINT x_resource_FK_parent_id FOREIGN KEY (parent_id) REFERENCES x_resource (id),
CONSTRAINT x_resource_FK_upd_by_id FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id)
);
CREATE TABLE x_trx_log (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
class_type NUMBER(11) DEFAULT '0' NOT NULL ,
object_id NUMBER(20) DEFAULT NULL NULL ,
parent_object_id NUMBER(20) DEFAULT NULL NULL ,
parent_object_class_type NUMBER(11) DEFAULT '0' NOT NULL ,
parent_object_name VARCHAR(1024) DEFAULT NULL NULL ,
object_name VARCHAR(1024) DEFAULT NULL NULL ,
attr_name VARCHAR(255) DEFAULT NULL NULL ,
prev_val CLOB DEFAULT NULL NULL ,
new_val CLOB DEFAULT NULL NULL ,
trx_id VARCHAR(1024) DEFAULT NULL NULL ,
action VARCHAR(255) DEFAULT NULL NULL ,
sess_id VARCHAR(512) DEFAULT NULL NULL ,
req_id VARCHAR(30) DEFAULT NULL NULL ,
sess_type VARCHAR(30) DEFAULT NULL NULL ,
PRIMARY KEY (id),
CONSTRAINT x_trx_log_FK_added_by_id FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_trx_log_FK_upd_by_id FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id)
);
CREATE TABLE x_perm_map (
id NUMBER(20) NOT NULL,
create_time DATE DEFAULT NULL NULL ,
update_time DATE DEFAULT NULL NULL ,
added_by_id NUMBER(20) DEFAULT NULL NULL ,
upd_by_id NUMBER(20) DEFAULT NULL NULL ,
perm_group VARCHAR(1024) DEFAULT NULL NULL ,
res_id NUMBER(20) DEFAULT NULL NULL ,
group_id NUMBER(20) DEFAULT NULL NULL ,
user_id NUMBER(20) DEFAULT NULL NULL ,
perm_for NUMBER(11) DEFAULT '0' NOT NULL ,
perm_type NUMBER(11) DEFAULT '0' NOT NULL ,
is_recursive NUMBER(11) DEFAULT '0' NOT NULL ,
is_wild_card NUMBER(1) DEFAULT '1' NOT NULL ,
grant_revoke NUMBER(1) DEFAULT '1' NOT NULL ,
PRIMARY KEY (id),
CONSTRAINT x_perm_map_FK_added_by_id FOREIGN KEY (added_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_perm_map_FK_group_id FOREIGN KEY (group_id) REFERENCES x_group (id),
CONSTRAINT x_perm_map_FK_res_id FOREIGN KEY (res_id) REFERENCES x_resource (id),
CONSTRAINT x_perm_map_FK_upd_by_id FOREIGN KEY (upd_by_id) REFERENCES x_portal_user (id),
CONSTRAINT x_perm_map_FK_user_id FOREIGN KEY (user_id) REFERENCES x_user (id)
);
CREATE TABLE X_AUDIT_MAP
( ID NUMBER(20,0) NOT NULL ENABLE,
CREATE_TIME DATE DEFAULT NULL,
UPDATE_TIME DATE DEFAULT NULL,
ADDED_BY_ID NUMBER(20,0) DEFAULT NULL,
UPD_BY_ID NUMBER(20,0) DEFAULT NULL,
RES_ID NUMBER(20,0) DEFAULT NULL,
GROUP_ID NUMBER(20,0) DEFAULT NULL,
USER_ID NUMBER(20,0) DEFAULT NULL,
AUDIT_TYPE NUMBER(11,0) DEFAULT 0 NOT NULL ENABLE,
PRIMARY KEY (ID),
CONSTRAINT X_AUDIT_MAP_FK_ADDED_BY_ID FOREIGN KEY (ADDED_BY_ID) REFERENCES X_PORTAL_USER (ID) ENABLE,
CONSTRAINT X_AUDIT_MAP_FK_GROUP_ID FOREIGN KEY (GROUP_ID) REFERENCES X_GROUP (ID) ENABLE,
CONSTRAINT X_AUDIT_MAP_FK_RES_ID FOREIGN KEY (RES_ID) REFERENCES X_RESOURCE (ID) ENABLE,
CONSTRAINT X_AUDIT_MAP_FK_UPD_BY_ID FOREIGN KEY (UPD_BY_ID) REFERENCES X_PORTAL_USER (ID) ENABLE,
CONSTRAINT X_AUDIT_MAP_FK_USER_ID FOREIGN KEY (USER_ID) REFERENCES X_USER (ID) ENABLE
);
commit;
CREATE VIEW vx_trx_log AS select x_trx_log.id AS id,x_trx_log.create_time AS create_time,x_trx_log.update_time AS update_time,x_trx_log.added_by_id AS added_by_id,x_trx_log.upd_by_id AS upd_by_id,x_trx_log.class_type AS class_type,x_trx_log.object_id AS object_id,x_trx_log.parent_object_id AS parent_object_id,x_trx_log.parent_object_class_type AS parent_object_class_type,x_trx_log.attr_name AS attr_name,x_trx_log.parent_object_name AS parent_object_name,x_trx_log.object_name AS object_name,x_trx_log.prev_val AS prev_val,x_trx_log.new_val AS new_val,x_trx_log.trx_id AS trx_id,x_trx_log.action AS action,x_trx_log.sess_id AS sess_id,x_trx_log.req_id AS req_id,x_trx_log.sess_type AS sess_type from x_trx_log where id in(select min(x_trx_log.id) from x_trx_log group by x_trx_log.trx_id);
commit;
CREATE INDEX xa_access_audit_added_by_id ON xa_access_audit(added_by_id);
CREATE INDEX xa_access_audit_upd_by_id ON xa_access_audit(upd_by_id);
CREATE INDEX xa_access_audit_cr_time ON xa_access_audit(create_time);
CREATE INDEX xa_access_audit_up_time ON xa_access_audit(update_time);
CREATE INDEX xa_access_audit_event_time ON xa_access_audit(event_time);
CREATE INDEX x_asset_FK_added_by_id ON x_asset(added_by_id);
CREATE INDEX x_asset_FK_upd_by_id ON x_asset(upd_by_id);
CREATE INDEX x_asset_cr_time ON x_asset (create_time);
CREATE INDEX x_asset_up_time ON x_asset (update_time);
CREATE INDEX x_audit_map_FK_added_by_id ON x_audit_map (added_by_id);
CREATE INDEX x_audit_map_FK_upd_by_id ON x_audit_map (upd_by_id);
CREATE INDEX x_audit_map_FK_res_id ON x_audit_map(res_id);
CREATE INDEX x_audit_map_FK_group_id ON x_audit_map (group_id);
CREATE INDEX x_audit_map_FK_user_id ON x_audit_map(user_id);
CREATE INDEX x_audit_map_cr_time ON x_audit_map(create_time);
CREATE INDEX x_audit_map_up_time ON x_audit_map (update_time);
CREATE INDEX x_auth_sess_FK_added_by_id ON x_auth_sess (added_by_id);
CREATE INDEX x_auth_sess_FK_upd_by_id ON x_auth_sess (upd_by_id);
CREATE INDEX x_auth_sess_FK_user_id ON x_auth_sess (user_id);
CREATE INDEX x_auth_sess_cr_time ON x_auth_sess (create_time);
CREATE INDEX x_auth_sess_up_time ON x_auth_sess (update_time);
CREATE INDEX x_cred_store_FK_added_by_id ON x_cred_store (added_by_id);
CREATE INDEX x_cred_store_FK_upd_by_id ON x_cred_store (upd_by_id);
CREATE INDEX x_cred_store_cr_time ON x_cred_store (create_time);
CREATE INDEX x_cred_store_up_time ON x_cred_store (update_time);
CREATE INDEX x_db_base_FK_added_by_id ON x_db_base (added_by_id);
CREATE INDEX x_db_base_FK_upd_by_id ON x_db_base (upd_by_id);
CREATE INDEX x_db_base_cr_time ON x_db_base (create_time);
CREATE INDEX x_db_base_up_time ON x_db_base(update_time);
CREATE INDEX x_group_FK_added_by_id ON x_group (added_by_id);
CREATE INDEX x_group_FK_upd_by_id ON x_group (upd_by_id);
CREATE INDEX x_group_FK_cred_store_id ON x_group (cred_store_id);
CREATE INDEX x_group_cr_time ON x_group (create_time);
CREATE INDEX x_group_up_time ON x_group (update_time);
CREATE INDEX x_group_groups_FK_added_by_id ON x_group_groups (added_by_id);
CREATE INDEX x_group_groups_FK_upd_by_id ON x_group_groups(upd_by_id);
CREATE INDEX x_group_groups_FK_p_group_id ON x_group_groups (p_group_id);
CREATE INDEX x_group_groups_FK_group_id ON x_group_groups(group_id);
CREATE INDEX x_group_groups_cr_time ON x_group_groups (create_time);
CREATE INDEX x_group_groups_up_time ON x_group_groups (update_time);
CREATE INDEX x_group_users_FK_added_by_id ON x_group_users (added_by_id);
CREATE INDEX x_group_users_FK_upd_by_id ON x_group_users(upd_by_id);
CREATE INDEX x_group_users_FK_p_group_id ON x_group_users (p_group_id);
CREATE INDEX x_group_users_FK_user_id ON x_group_users (user_id);
CREATE INDEX x_group_users_cr_time ON x_group_users(create_time);
CREATE INDEX x_group_users_up_time ON x_group_users(update_time);
CREATE INDEX x_perm_map_FK_added_by_id ON x_perm_map (added_by_id);
CREATE INDEX x_perm_map_FK_upd_by_id ON x_perm_map (upd_by_id);
CREATE INDEX x_perm_map_FK_res_id ON x_perm_map(res_id);
CREATE INDEX x_perm_map_FK_group_id ON x_perm_map(group_id);
CREATE INDEX x_perm_map_FK_user_id ON x_perm_map(user_id);
CREATE INDEX x_perm_map_cr_time ON x_perm_map (create_time);
CREATE INDEX x_perm_map_up_time ON x_perm_map(update_time);
CREATE INDEX x_policy_export_audit_FK_added ON x_policy_export_audit (added_by_id);
CREATE INDEX x_policy_export_audit_FK_upd ON x_policy_export_audit (upd_by_id);
CREATE INDEX x_policy_export_audit_cr_time ON x_policy_export_audit (create_time);
CREATE INDEX x_policy_export_audit_up_time ON x_policy_export_audit(update_time);
CREATE INDEX x_portal_user_FK_added_by_id ON x_portal_user (added_by_id);
CREATE INDEX x_portal_user_FK_upd_by_id ON x_portal_user (upd_by_id);
CREATE INDEX x_portal_user_cr_time ON x_portal_user(create_time);
CREATE INDEX x_portal_user_up_time ON x_portal_user (update_time);
CREATE INDEX x_portal_user_name ON x_portal_user(first_name);
CREATE INDEX x_portal_user_role_FK_added ON x_portal_user_role(added_by_id);
CREATE INDEX x_portal_user_role_FK_upd ON x_portal_user_role(upd_by_id);
CREATE INDEX x_portal_user_role_FK_user_id ON x_portal_user_role(user_id);
CREATE INDEX x_portal_user_role_cr_time ON x_portal_user_role(create_time);
CREATE INDEX x_portal_user_role_up_time ON x_portal_user_role (update_time);
CREATE INDEX x_resource_FK_added_by_id ON x_resource(added_by_id);
CREATE INDEX x_resource_FK_upd_by_id ON x_resource(upd_by_id);
CREATE INDEX x_resource_FK_asset_id ON x_resource (asset_id);
CREATE INDEX x_resource_FK_parent_id ON x_resource (parent_id);
CREATE INDEX x_resource_cr_time ON x_resource(create_time);
CREATE INDEX x_resource_up_time ON x_resource (update_time);
CREATE INDEX x_trx_log_FK_added_by_id ON x_trx_log (added_by_id);
CREATE INDEX x_trx_log_FK_upd_by_id ON x_trx_log(upd_by_id);
CREATE INDEX x_trx_log_cr_time ON x_trx_log (create_time);
CREATE INDEX x_trx_log_up_time ON x_trx_log (update_time);
CREATE INDEX x_user_FK_added_by_id ON x_user (added_by_id);
CREATE INDEX x_user_FK_upd_by_id ON x_user (upd_by_id);
CREATE INDEX x_user_FK_cred_store_id ON x_user (cred_store_id);
CREATE INDEX x_user_cr_time ON x_user (create_time);
CREATE INDEX x_user_up_time ON x_user(update_time);
commit;
insert into x_portal_user (
id,CREATE_TIME, UPDATE_TIME,
FIRST_NAME, LAST_NAME, PUB_SCR_NAME,
LOGIN_ID, PASSWORD, EMAIL, STATUS
) values (
X_PORTAL_USER_SEQ.NEXTVAL, SYSDATE, SYSDATE,
'Admin', '', 'Admin',
'admin', 'ceb4f32325eda6142bd65215f4c0f371', '', 1
);
commit;
insert into x_portal_user_role (
id, CREATE_TIME, UPDATE_TIME,
USER_ID, USER_ROLE, STATUS
) values (
X_PORTAL_USER_ROLE_SEQ.NEXTVAL, SYSDATE, SYSDATE,
1, 'ROLE_SYS_ADMIN', 1
);
commit;
insert into x_user (id,CREATE_TIME, UPDATE_TIME,user_name, status,descr) values (
X_USER_SEQ.NEXTVAL, SYSDATE, SYSDATE,'admin', 0,'Administrator');
commit;
INSERT INTO x_group (ID,ADDED_BY_ID, CREATE_TIME, DESCR, GROUP_TYPE, GROUP_NAME, STATUS, UPDATE_TIME, UPD_BY_ID) VALUES (X_GROUP_SEQ.nextval,1, sys_extract_utc(systimestamp), 'public group', 0, 'public', 0, sys_extract_utc(systimestamp), 1);
commit; | {
"pile_set_name": "Github"
} |
"MJRefreshHeaderIdleText" = "아래로 당겨 새로고침";
"MJRefreshHeaderPullingText" = "놓으면 새로고침";
"MJRefreshHeaderRefreshingText" = "로딩중...";
"MJRefreshAutoFooterIdleText" = "탭 또는 위로 당겨 로드함";
"MJRefreshAutoFooterRefreshingText" = "로딩중...";
"MJRefreshAutoFooterNoMoreDataText" = "더이상 데이터 없음";
"MJRefreshBackFooterIdleText" = "위로 당겨 더 로드 가능";
"MJRefreshBackFooterPullingText" = "놓으면 더 로드됨.";
"MJRefreshBackFooterRefreshingText" = "로딩중...";
"MJRefreshBackFooterNoMoreDataText" = "더이상 데이터 없음";
"MJRefreshHeaderLastTimeText" = "마지막 업데이트: ";
"MJRefreshHeaderDateTodayText" = "오늘";
"MJRefreshHeaderNoneLastDateText" = "기록 없음";
| {
"pile_set_name": "Github"
} |
# Copyright 2017 Intel Corporation
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the
# "Software"), to deal in the Software without restriction, including
# without limitation the rights to use, copy, modify, merge, publish,
# distribute, sub license, and/or sell copies of the Software, and to
# permit persons to whom the Software is furnished to do so, subject to
# the following conditions:
#
# The above copyright notice and this permission notice (including the
# next paragraph) shall be included in all copies or substantial portions
# of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
# IN NO EVENT SHALL VMWARE AND/OR ITS SUPPLIERS BE LIABLE FOR
# ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
import json
import os.path
import argparse
if __name__ == '__main__':
parser = argparse.ArgumentParser()
parser.add_argument('--out', help='Output json file.', required=True)
parser.add_argument('--lib-path', help='Path to libvulkan_val.so')
args = parser.parse_args()
path = 'libvulkan_val.so'
if args.lib_path:
path = os.path.join(args.lib_path, path)
json_data = {
'file_format_version': '1.0.0',
'ICD': {
'library_path': path,
'api_version': str('1.1.107'),
},
}
with open(args.out, 'w') as f:
json.dump(json_data, f, indent = 4, sort_keys=True, separators=(',', ': '))
| {
"pile_set_name": "Github"
} |
import createEagerElementUtil from './utils/createEagerElementUtil'
import isReferentiallyTransparentFunctionComponent from './isReferentiallyTransparentFunctionComponent'
/**
* The factory form of `createEagerElement()`.
* Given a component, it returns a [factory](https://facebook.github.io/react/docs/react-api.html#createfactory).
*
* @static
* @category Utilities
* @param {ReactClass|ReactFunctionalComponent|String} type The type of component to render.
* @returns {Function} Returns a function that take two arguments (props, children) and create
* an element of the given type.
* @example
*
* const div = createFactory('div');
* div({className: 'foo'});
*/
const createEagerFactory = type => {
const isReferentiallyTransparent = isReferentiallyTransparentFunctionComponent(
type,
)
return (props, children) =>
createEagerElementUtil(
false,
isReferentiallyTransparent,
type,
props,
children,
)
}
export default createEagerFactory
| {
"pile_set_name": "Github"
} |
/*---------------------------------------------------------------------------*\
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration |
\\ / A nd | Copyright (C) 2011-2013 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
This file is part of OpenFOAM.
OpenFOAM is free software: you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
for more details.
You should have received a copy of the GNU General Public License
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
Class
Foam::fvSurfaceMapper
Description
FV surface mapper.
SourceFiles
fvSurfaceMapper.C
\*---------------------------------------------------------------------------*/
#ifndef fvSurfaceMapper_H
#define fvSurfaceMapper_H
#include "morphFieldMapper.H"
#include "fvMesh.H"
#include "faceMapper.H"
#include "HashSet.H"
#include "mapPolyMesh.H"
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
namespace Foam
{
// Forward declaration of classes
/*---------------------------------------------------------------------------*\
Class fvSurfaceMapper Declaration
\*---------------------------------------------------------------------------*/
class fvSurfaceMapper
:
public morphFieldMapper
{
// Private data
//- Reference to mesh
const fvMesh& mesh_;
//- Reference to face mapper
const faceMapper& faceMap_;
// Demand-driven private data
//- Direct addressing (only one for of addressing is used)
mutable labelList* directAddrPtr_;
//- Interpolated addressing (only one for of addressing is used)
mutable labelListList* interpolationAddrPtr_;
//- Interpolation weights
mutable scalarListList* weightsPtr_;
//- Inserted faces
mutable labelList* insertedObjectLabelsPtr_;
// Private Member Functions
//- Disallow default bitwise copy construct
fvSurfaceMapper(const fvSurfaceMapper&);
//- Disallow default bitwise assignment
void operator=(const fvSurfaceMapper&);
//- Calculate addressing
void calcAddressing() const;
//- Clear out local storage
void clearOut();
public:
// Constructors
//- Construct from components
fvSurfaceMapper
(
const fvMesh& mesh,
const faceMapper& fMapper
);
//- Destructor
virtual ~fvSurfaceMapper();
// Member Functions
//- Return size
virtual label size() const
{
return mesh_.nInternalFaces();
}
//- Return size of field before mapping
virtual label sizeBeforeMapping() const
{
return faceMap_.internalSizeBeforeMapping();
}
//- Is the mapping direct
virtual bool direct() const
{
return faceMap_.direct();
}
//- Has unmapped elements
virtual bool hasUnmapped() const
{
return insertedObjects();
}
//- Return direct addressing
virtual const labelUList& directAddressing() const;
//- Return interpolated addressing
virtual const labelListList& addressing() const;
//- Return interpolaion weights
virtual const scalarListList& weights() const;
//- Are there any inserted faces
virtual bool insertedObjects() const
{
return faceMap_.insertedObjects();
}
//- Return list of inserted faces
virtual const labelList& insertedObjectLabels() const;
//- Return flux flip map
const labelHashSet& flipFaceFlux() const
{
return faceMap_.flipFaceFlux();
}
};
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
} // End namespace Foam
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
#endif
// ************************************************************************* //
| {
"pile_set_name": "Github"
} |
// Automatically generated by the Fast Binary Encoding compiler, do not modify!
// https://github.com/chronoxor/FastBinaryEncoding
// Source: FBE
// Version: 1.4.0.0
import Foundation
// Fast Binary Encoding Int32 final model
public class FinalModelInt32: FinalModel {
public var _buffer = Buffer()
public var _offset: Int = 0
public init(buffer: Buffer, offset: Int) {
_buffer = buffer
_offset = offset
}
// Get the allocation size
public func fbeAllocationSize(value: Int32) -> Int {
return fbeSize
}
// Field size
public let fbeSize: Int = 4
// Check if the value is valid
public func verify() -> Int {
if _buffer.offset + fbeOffset + fbeSize > _buffer.size {
return Int.max
}
return fbeSize
}
// Get the value
public func get(size: inout Size) -> Int32 {
if (_buffer.offset + fbeOffset + fbeSize) > _buffer.size {
return 0
}
size.value = fbeSize
return readInt32(offset: fbeOffset)
}
// Set the value
public func set(value: Int32) throws -> Int {
if (_buffer.offset + fbeOffset + fbeSize) > _buffer.size {
assertionFailure("Model is broken!")
return 0
}
write(offset: fbeOffset, value: value)
return fbeSize
}
}
| {
"pile_set_name": "Github"
} |
<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006~2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <[email protected]>
// +----------------------------------------------------------------------
namespace think\response;
use think\Collection;
use think\Model;
use think\Response;
class Xml extends Response
{
// 输出参数
protected $options = [
// 根节点名
'root_node' => 'think',
// 根节点属性
'root_attr' => '',
//数字索引的子节点名
'item_node' => 'item',
// 数字索引子节点key转换的属性名
'item_key' => 'id',
// 数据编码
'encoding' => 'utf-8',
];
protected $contentType = 'text/xml';
/**
* 处理数据
* @access protected
* @param mixed $data 要处理的数据
* @return mixed
*/
protected function output($data)
{
if (is_string($data)) {
if (0 !== strpos($data, '<?xml')) {
$encoding = $this->options['encoding'];
$xml = "<?xml version=\"1.0\" encoding=\"{$encoding}\"?>";
$data = $xml . $data;
}
return $data;
}
// XML数据转换
return $this->xmlEncode($data, $this->options['root_node'], $this->options['item_node'], $this->options['root_attr'], $this->options['item_key'], $this->options['encoding']);
}
/**
* XML编码
* @access protected
* @param mixed $data 数据
* @param string $root 根节点名
* @param string $item 数字索引的子节点名
* @param string $attr 根节点属性
* @param string $id 数字索引子节点key转换的属性名
* @param string $encoding 数据编码
* @return string
*/
protected function xmlEncode($data, $root, $item, $attr, $id, $encoding)
{
if (is_array($attr)) {
$array = [];
foreach ($attr as $key => $value) {
$array[] = "{$key}=\"{$value}\"";
}
$attr = implode(' ', $array);
}
$attr = trim($attr);
$attr = empty($attr) ? '' : " {$attr}";
$xml = "<?xml version=\"1.0\" encoding=\"{$encoding}\"?>";
$xml .= "<{$root}{$attr}>";
$xml .= $this->dataToXml($data, $item, $id);
$xml .= "</{$root}>";
return $xml;
}
/**
* 数据XML编码
* @access protected
* @param mixed $data 数据
* @param string $item 数字索引时的节点名称
* @param string $id 数字索引key转换为的属性名
* @return string
*/
protected function dataToXml($data, $item, $id)
{
$xml = $attr = '';
if ($data instanceof Collection || $data instanceof Model) {
$data = $data->toArray();
}
foreach ($data as $key => $val) {
if (is_numeric($key)) {
$id && $attr = " {$id}=\"{$key}\"";
$key = $item;
}
$xml .= "<{$key}{$attr}>";
$xml .= (is_array($val) || is_object($val)) ? $this->dataToXml($val, $item, $id) : $val;
$xml .= "</{$key}>";
}
return $xml;
}
}
| {
"pile_set_name": "Github"
} |
/* Intro */
"LILLY_\"=PULITZER_M=ES\"SAGE" = "LILLY_=PULITZER_M=ES\"SAGE";
// asdlökfja sdlkf
"key" = "value";
// single line comment
/* multi
line
comment */
"key" = "value";
// some comment without connection to anything
/* MultiCatalog */
"Dow\"nload" = "Download";
/* No comment provided by engineer. */
"I am a hamster" = "I am a hamster";
/* Intro */
"Mac Gyver" = "Mac Gyver";
/* Intro */
"New iCatalog version available" = "New iCatalog version \n available";
/* Intro */
"New iMac" = "New iMac";
/* No comment provided by engineer. */
"NEW_DAY" = "NEW_DAY";
/* MultiCatalog */
"Software tester" = "Software tester";
/* MultiCatalog */
"Software Update Required" = "Software Update Required";
/* Intro */
"TODAY" = "TODAY";
/* MultiCatalog */
"Today is Wednesday" = "Today is Wednesday";
/* Intro */
"Uncompressing" = "Uncompressing";
/* Intro */
"You rock" = "You rock";
| {
"pile_set_name": "Github"
} |
/*#######################################################################
# RDOS operating system
# Copyright (C) 1988-2006, Leif Ekblad
#
# This library is free software; you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as published
# by the Free Software Foundation; either version 2.1 of the License, or
# (at your option) any later version.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the Free Software
# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
# The author of this program may be contacted at [email protected]
#
# sbrk.c
# sbrk function implementation
#
##########################################################################*/
#include "config.h"
#include <_syslist.h>
#include "rdos.h"
void *sbrk (int incr)
{
return RdosAllocateMem(incr);
}
| {
"pile_set_name": "Github"
} |
var structarm__iir__lattice__instance__q15 =
[
[ "numStages", "structarm__iir__lattice__instance__q15.html#a96fbed313bef01070409fa182d26ba3f", null ],
[ "pkCoeffs", "structarm__iir__lattice__instance__q15.html#a41c214a1ec38d4a82fae8899d715dd29", null ],
[ "pState", "structarm__iir__lattice__instance__q15.html#afd0136ab917b529554d93f41a5e04618", null ],
[ "pvCoeffs", "structarm__iir__lattice__instance__q15.html#a4c4f57f45b223abbe2a9fb727bd2cad9", null ]
]; | {
"pile_set_name": "Github"
} |
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 1.3
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">1.3</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1">this is my long string</data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
[base64 mime encoded serialized .NET Framework object]
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
[base64 mime encoded string representing a byte array form of the .NET Framework object]
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>1.3</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.3500.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.3500.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root> | {
"pile_set_name": "Github"
} |
---
title: "Find the Report Definition Schema Version | Microsoft Docs"
description: Learn how to identify the Report Definition Language (RDL) schema version of your report definition file.
ms.date: 06/06/2019
ms.prod: reporting-services
ms.prod_service: "reporting-services-native"
ms.technology: reports
ms.topic: conceptual
helpviewer_keywords:
- "XML schemas [Reporting Services]"
- "Report Definition Language, XML schema"
- "schemas [Reporting Services]"
ms.assetid: 67954419-1b61-4481-a3b9-23b4ba7a5624
author: maggiesMSFT
ms.author: maggies
---
# Find the Report Definition Schema Version (SSRS)
A report definition file specifies the RDL namespace for the version of the report definition schema that is used to validate the rdl file. When you open an .rdl file in a report authoring environment such as Report Designer in [!INCLUDE[ssBIDevStudioFull](../../includes/ssbidevstudiofull-md.md)], Visual Studio, or Report Builder. If the report was created for a previous namespace, a backup file is automatically created, and the report is upgraded to the current namespace. If you save the upgraded report definition, you have saved the converted .rdl file. This is the only way to upgrade a report definition. The report definition itself is not upgraded on a report server. The compiled report is upgraded on a report server. For more information, see [Upgrade Reports](../../reporting-services/install-windows/upgrade-reports.md).
## How to: Identify the RDL schema version of a report
1. Open the report .rdl file in an application such as Notepad or XML Notepad, in which you can view the XML.
The XML Report element specifies the schema namespace. For example, the following Report element specifies the namespace for Report Designer and the namespace for the report definition.
``` XML
<Report xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner" xmlns="http://schemas.microsoft.com/sqlserver/reporting/2016/01/reportdefinition" xmlns:df="http://schemas.microsoft.com/sqlserver/reporting/2016/01/reportdefinition/defaultfontfamily" MustUnderstand="df">
```
The most recent report definition namespace is 2016. However, the most recent published report definition namespace is 2010, specified by the following URL: `https://schemas.microsoft.com/sqlserver/reporting/2010/01/reportdefinition`..
### How to: Identify the RDL schema version of Report Designer
1. Open a new project. The version of the project that you choose determines the version of the RDL schema. In SQL Server, more than one schema version is supported. For more information, see [Deployment and Version Support in SQL Server Data Tools](../../reporting-services/tools/deployment-and-version-support-in-sql-server-data-tools-ssrs.md).
2. On the **Project** menu, click **Add New Item**. The **Add New Item** dialog box opens.
3. In the **Templates** pane, click **Report**.
4. In **Name**, type a report name or accept the default.
5. Click **Add**. Report Designer opens a new blank report in Design view.
6. On the **View** menu, click **Code**. The report definition is displayed as an XML file.
The XML Report element specifies the schema namespace. For example, the following Report element specifies the namespace for Report Designer and the namespace for the report definition.
``` XML
<Report xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner" xmlns="http://schemas.microsoft.com/sqlserver/reporting/*year*/01/reportdefinition" xmlns:df="http://schemas.microsoft.com/sqlserver/reporting/*year*/01/reportdefinition/defaultfontfamily" MustUnderstand="df">
```
The report definition namespace is specified by the following URL: `https://schemas.microsoft.com/sqlserver/reporting/*year*/01/reportdefinition`
### How to: Identify the RDL schema version on the Report Server
- In the web portal, type the URL for the report server. For example, the following URL specifies a report server on the local computer:
`https://localhost/reportserver/reportdefinition.xsd`
The .xsd file opens in the browser.
The XML schema element specifies the schema namespace. For example, the following schema element specifies three namespaces: the targetNamespace reference that is used internally by [!INCLUDE[vsprvs](../../includes/vsprvs-md.md)], the xsd reference for the schema itself (xsd), and the report definition reference. *Year* represents the year of the schema the report is using. For example, 2010 or 2016.
``` XML
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.microsoft.com/sqlserver/reporting/*year*/01/reportdefinition" targetNamespace="http://schemas.microsoft.com/sqlserver/reporting/*year*/01/reportdefinition" elementFormDefault="qualified">
```
The report definition namespace is specified by the following URL: `https://schemas.microsoft.com/sqlserver/reporting/*year*/01/reportdefinition`
## Next steps
[Upgrade Reports](../../reporting-services/install-windows/upgrade-reports.md)
[Report Definition Language](../../reporting-services/reports/report-definition-language-ssrs.md)
More questions? [Try asking the Reporting Services forum](https://go.microsoft.com/fwlink/?LinkId=620231)
| {
"pile_set_name": "Github"
} |
/*
* Copyright (c) 2018. paascloud.net All Rights Reserved.
* 项目名称:paascloud快速搭建企业级分布式微服务平台
* 类名称:MqMessage.java
* 创建人:刘兆明
* 联系方式:[email protected]
* 开源地址: https://github.com/paascloud
* 博客地址: http://blog.paascloud.net
* 项目官网: http://paascloud.net
*/
package com.paascloud.core.mq;
import com.google.common.base.Preconditions;
import com.paascloud.base.enums.ErrorCodeEnum;
import com.paascloud.base.exception.BusinessException;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.extern.slf4j.Slf4j;
import org.apache.rocketmq.client.producer.SendResult;
import org.apache.rocketmq.common.message.Message;
import org.apache.rocketmq.remoting.common.RemotingHelper;
import org.slf4j.Logger;
import org.springframework.util.StringUtils;
import java.io.Serializable;
import java.io.UnsupportedEncodingException;
/**
* The class Mq message.
*
* @author [email protected]
*/
@Slf4j
@Data
@ApiModel("消息队列")
public class MqMessage implements Serializable {
private static final long serialVersionUID = 9215900048842983997L;
@ApiModelProperty("主题")
private String topic;
@ApiModelProperty("标签")
private String tag;
@ApiModelProperty("唯一键")
private String key;
@ApiModelProperty("消息体")
private String body;
/**
* Check message message.
*
* @param mqMessage the mq message
*
* @return the message
*/
public static Message checkMessage(MqMessage mqMessage) {
String topic = mqMessage.getTopic();
String key = mqMessage.getKey();
String body = mqMessage.getBody();
String tag = mqMessage.getTag();
printCheckMessageLog(topic, key, body, tag);
checkMessage(topic, key, body);
return buildMessage(body, topic, tag, key);
}
private static void printCheckMessageLog(final String topic, final String key, final String body, final String tag) {
log.info("checkMessage - 校验MQ body={}, topic={}, tag={}, key={}", body, topic, tag, key);
}
/**
* Check message message.
*
* @param body the body
* @param topic the topic
* @param tag the tag
* @param key the key
*
* @return the message
*/
public static Message checkMessage(String body, String topic, String tag, String key) {
printCheckMessageLog(topic, key, body, tag);
checkMessage(topic, key, body);
return buildMessage(body, topic, tag, key);
}
/**
* Check message message.
*
* @param message the message
*
* @return the message
*/
public static Message checkMessage(Message message) {
String body = new String(message.getBody());
String topic = message.getTopic();
String key = message.getKeys();
String tag = message.getTags();
printCheckMessageLog(topic, key, body, tag);
checkMessage(topic, key, body);
return buildMessage(body, topic, tag, key);
}
/**
* Instantiates a new Mq message.
*
* @param message the message
*/
public MqMessage(Message message) {
this.body = new String(message.getBody());
this.topic = message.getTopic();
this.key = message.getKeys();
this.tag = message.getTags();
}
private static Message buildMessage(String body, String topic, String tag, String key) {
Message message = new Message();
try {
message.setBody(body.getBytes(RemotingHelper.DEFAULT_CHARSET));
} catch (UnsupportedEncodingException e) {
log.error("编码转换,出现异常={}", e.getMessage(), e);
throw new BusinessException(ErrorCodeEnum.TPC100500011);
}
message.setKeys(key);
message.setTopic(topic);
message.setTags(tag);
return message;
}
/**
* Instantiates a new Mq message.
*
* @param topic the topic
* @param tag the tag
* @param key the key
* @param body the body
*/
public MqMessage(String topic, String tag, String key, String body) {
this.topic = topic;
this.tag = tag;
this.key = key;
this.body = body;
}
/**
* Check message.
*
* @param topic the topic
* @param key the key
* @param body the body
*/
public static void checkMessage(String topic, String key, String body) {
Preconditions.checkArgument(!StringUtils.isEmpty(topic), "发送消息失败, 消息主题不能为空");
Preconditions.checkArgument(!StringUtils.isEmpty(key), "发送消息失败, 消息关键字不能为空");
Preconditions.checkArgument(!StringUtils.isEmpty(body), "发送消息失败, 消息体不能为空");
}
/**
* Print producer result.
*
* @param sendResult the send result
* @param logger the logger
*/
public static void printProducerResult(SendResult sendResult, Logger logger) {
if (sendResult != null) {
logger.info("sendSimpleMessage - 发送MQ [OK]sendResult={}", sendResult);
} else {
logger.info("sendSimpleMessage - 发送MQ [FAIL]");
}
}
/**
* Print producer exception.
*
* @param topic the topic
* @param tag the tag
* @param key the key
* @param logger the logger
* @param e the e
*/
public static void printProducerException(String topic, String tag, String key, Logger logger, Exception e) {
logger.error("sendSimpleMessage - 发送MQ [FAIL] topic={}, tag={}, key={}", topic, tag, key, e);
}
}
| {
"pile_set_name": "Github"
} |
Invoke the `signOut` api to sign out a user from the Auth category. You can only have one user signed in at a given time.
<inline-fragment platform="android" src="~/lib/auth/fragments/android/signout/10_local_signout.md"></inline-fragment>
<inline-fragment platform="ios" src="~/lib/auth/fragments/ios/signout/10_local_signout.md"></inline-fragment>
<inline-fragment platform="flutter" src="~/lib/auth/fragments/flutter/signout/10_local_signout.md"></inline-fragment>
Calling signOut without any options will just delete the local cache and keychain of the user. If you would like to sign out of all devices, invoke the signOut api with advanced options.
<inline-fragment platform="android" src="~/lib/auth/fragments/android/signout/20_global_signout.md"></inline-fragment>
<inline-fragment platform="ios" src="~/lib/auth/fragments/ios/signout/20_global_signout.md"></inline-fragment>
<inline-fragment platform="flutter" src="~/lib/auth/fragments/flutter/signout/20_global_signout.md"></inline-fragment>
Calling signout with `globalSignOut = true` will invalidate all the Cognito User Pool tokens of the signed in user. If the user is signed into a device, they won't be authorized to perform a task that requires a valid token when a global signout is called from some other device. They need to sign in again to get valid tokens.
<amplify-callout warning>
Global signout functionality does not work if you use one of the web UI sign in methods.
</amplify-callout> | {
"pile_set_name": "Github"
} |
package com.uwsoft.editor.view.stage.tools.transformStrategy;
import com.badlogic.ashley.core.Entity;
import com.badlogic.gdx.math.Vector2;
import com.uwsoft.editor.renderer.components.DimensionsComponent;
import com.uwsoft.editor.renderer.components.NinePatchComponent;
import com.uwsoft.editor.renderer.components.TransformComponent;
import com.uwsoft.editor.renderer.utils.ComponentRetriever;
import com.uwsoft.editor.utils.TransformCommandBuilder;
import com.uwsoft.editor.view.ui.followers.NormalSelectionFollower;
/**
* Created by Sasun Poghosyan on 4/13/2016.
*/
public class NinePatchStrategy extends AbstractTransformStrategy {
@Override
public void calculate(float mouseDx, float mouseDy, int anchor, Entity entity, TransformCommandBuilder transformCommandBuilder, Vector2 mousePointStage, float lastTransformAngle, float lastEntityAngle) {
TransformComponent transformComponent = ComponentRetriever.get(entity, TransformComponent.class);
DimensionsComponent dimensionsComponent = ComponentRetriever.get(entity, DimensionsComponent.class);
float newX = transformComponent.x;
float newY = transformComponent.y;
float newWidth = dimensionsComponent.width;
float newHeight = dimensionsComponent.height;
NinePatchComponent ninePatchComponent = ComponentRetriever.get(entity, NinePatchComponent.class);
float minWidth = ninePatchComponent.ninePatch.getTotalWidth();
float minHeight = ninePatchComponent.ninePatch.getTotalHeight();
switch (anchor) {
case NormalSelectionFollower.L:
newWidth = dimensionsComponent.width + (transformComponent.x - mousePointStage.x);
if (newWidth < minWidth) {
newX = mousePointStage.x - (minWidth - newWidth);
newWidth = minWidth;
} else {
newX = mousePointStage.x;
}
break;
case NormalSelectionFollower.R:
newWidth = dimensionsComponent.width + (mousePointStage.x - (transformComponent.x + dimensionsComponent.width));
if (newWidth < minWidth) {
newWidth = minWidth;
}
break;
case NormalSelectionFollower.B:
newHeight = dimensionsComponent.height + (transformComponent.y - mousePointStage.y);
if (newHeight < minHeight) {
newY = mousePointStage.y - (minHeight - newHeight);
newHeight = minHeight;
} else {
newY = mousePointStage.y;
}
break;
case NormalSelectionFollower.T:
newHeight = dimensionsComponent.height + (mousePointStage.y - (transformComponent.y + dimensionsComponent.height));
if (newHeight < minHeight) {
newHeight = minHeight;
}
break;
case NormalSelectionFollower.LT:
newWidth = dimensionsComponent.width + (transformComponent.x - mousePointStage.x);
newHeight = dimensionsComponent.height + (mousePointStage.y - (transformComponent.y + dimensionsComponent.height));
if (newWidth < minWidth) {
newX = mousePointStage.x - (minWidth - newWidth);
newWidth = minWidth;
} else {
newX = mousePointStage.x;
}
if (newHeight < minHeight) {
newHeight = minHeight;
}
break;
case NormalSelectionFollower.RT:
newWidth = dimensionsComponent.width + (mousePointStage.x - (transformComponent.x + dimensionsComponent.width));
newHeight = dimensionsComponent.height + (mousePointStage.y - (transformComponent.y + dimensionsComponent.height));
if (newHeight < minHeight) {
newHeight = minHeight;
}
if (newWidth < minWidth) {
newWidth = minWidth;
}
break;
case NormalSelectionFollower.RB:
newWidth = dimensionsComponent.width + (mousePointStage.x - (transformComponent.x + dimensionsComponent.width));
newHeight = dimensionsComponent.height + (transformComponent.y - mousePointStage.y);
if (newWidth < minWidth) {
newWidth = minWidth;
}
if (newHeight < minHeight) {
newY = mousePointStage.y - (minHeight - newHeight);
newHeight = minHeight;
} else {
newY = mousePointStage.y;
}
break;
case NormalSelectionFollower.LB:
newWidth = dimensionsComponent.width + (transformComponent.x - mousePointStage.x);
newHeight = dimensionsComponent.height + (transformComponent.y - mousePointStage.y);
if (newWidth < minWidth) {
newX = mousePointStage.x - (minWidth - newWidth);
newWidth = minWidth;
} else {
newX = mousePointStage.x;
}
if (newHeight < minHeight) {
newY = mousePointStage.y - (minHeight - newHeight);
newHeight = minHeight;
} else {
newY = mousePointStage.y;
}
break;
}
transformCommandBuilder.setPos(newX, newY);
transformCommandBuilder.setSize(newWidth, newHeight);
transformComponent.x = newX;
transformComponent.y = newY;
dimensionsComponent.width = newWidth;
dimensionsComponent.height = newHeight;
}
}
| {
"pile_set_name": "Github"
} |
- CSV
| {
"pile_set_name": "Github"
} |
/**
* @license
* Copyright Google LLC All Rights Reserved.
*
* Use of this source code is governed by an MIT-style license that can be
* found in the LICENSE file at https://angular.io/license
*/
export * from './bottom-sheet-module';
export * from './bottom-sheet';
export * from './bottom-sheet-config';
export * from './bottom-sheet-container';
export * from './bottom-sheet-animations';
export * from './bottom-sheet-ref';
| {
"pile_set_name": "Github"
} |
module Jekyll
class Theme
extend Forwardable
attr_reader :name
def_delegator :gemspec, :version, :version
def initialize(name)
@name = name.downcase.strip
configure_sass
end
def root
# Must use File.realpath to resolve symlinks created by rbenv
# Otherwise, Jekyll.sanitized path with prepend the unresolved root
@root ||= File.realpath(gemspec.full_gem_path)
rescue Errno::ENOENT, Errno::EACCES, Errno::ELOOP
nil
end
def includes_path
path_for :includes
end
def layouts_path
path_for :layouts
end
def sass_path
path_for :sass
end
def configure_sass
return unless sass_path
require "sass"
Sass.load_paths << sass_path
end
private
def path_for(folder)
path = realpath_for(folder)
path if path && File.directory?(path)
end
def realpath_for(folder)
File.realpath(Jekyll.sanitized_path(root, "_#{folder}"))
rescue Errno::ENOENT, Errno::EACCES, Errno::ELOOP
nil
end
def gemspec
@gemspec ||= Gem::Specification.find_by_name(name)
rescue Gem::LoadError
raise Jekyll::Errors::MissingDependencyException,
"The #{name} theme could not be found."
end
end
end
| {
"pile_set_name": "Github"
} |
{
"parent": "block/cross",
"textures": {
"cross": "unity:block/weeping_vines_alt"
}
}
| {
"pile_set_name": "Github"
} |
// Copyright 2019 spaGO Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package mat
import (
"fmt"
"strconv"
_ "github.com/nlpodyssey/spago/pkg/global"
)
var _ fmt.Formatter = &Dense{}
// Format implements custom formatting for represeinting a Dense matrix.
// Thanks to this method, a Dense matrix implements the fmt.Formatter interface.
func (d *Dense) Format(f fmt.State, c rune) {
if c == 'v' {
if f.Flag('#') {
fmt.Fprintf(f, "&%#v", *d)
return
}
if f.Flag('+') {
fmt.Fprintf(f, "%+v", *d)
return
}
c = 'g'
}
if len(d.data) == 0 {
fmt.Fprintf(f, "[]")
return
}
if c == 'F' {
c = 'f' // %F (alias for %f) does not work with strconv.AppendFloat
}
precision, precisionOk := f.Precision()
if !precisionOk {
precision = -1
}
d.format(f, c, precision)
}
// format formats a non-empty Dense matrix
func (d *Dense) format(f fmt.State, c rune, precision int) {
maxWidths, maxWidth := d.formattingMaxColumnsWidth(f, c, precision)
spaceBuf := makeSpaceBuffer(maxWidth)
buf := make([]byte, 0, maxWidth)
for row, index := 0, 0; row < d.rows; row++ {
rowPrefix, rowSuffix := d.formattingRowPrefixAndSuffix(row)
fmt.Fprintf(f, rowPrefix)
for col := 0; col < d.cols; col, index = col+1, index+1 {
if col > 0 {
fmt.Fprintf(f, " ")
}
buf = formatValue(buf, d.data[index], c, precision)
writeFormattedValue(f, buf, spaceBuf, maxWidths[col])
}
fmt.Fprintf(f, rowSuffix)
}
}
func writeFormattedValue(f fmt.State, buf, spaceBuf []byte, maxW lrWidth) {
var leftPadding, rightPadding int
if pi, ok := indexOfPoint(buf); ok {
leftPadding = maxW.left - pi
rightPadding = maxW.right - (len(buf) - pi - 1)
} else {
leftPadding = maxW.left - len(buf)
rightPadding = maxW.right
if rightPadding > 0 {
rightPadding += 1
}
}
f.Write(spaceBuf[:leftPadding])
f.Write(buf)
f.Write(spaceBuf[:rightPadding])
}
func makeSpaceBuffer(length int) []byte {
buf := make([]byte, length)
for i := range buf {
buf[i] = ' '
}
return buf
}
func (d *Dense) formattingRowPrefixAndSuffix(rowIndex int) (string, string) {
if d.rows == 1 {
return "[", "]"
}
if rowIndex == 0 {
return "⎡", "⎤\n"
}
if rowIndex == d.rows-1 {
return "⎣", "⎦"
}
return "⎢", "⎥\n"
}
type lrWidth struct{ left, right int }
func (d *Dense) formattingMaxColumnsWidth(
f fmt.State,
c rune,
precision int,
) ([]lrWidth, int) {
minWidth := 0
if fw, ok := f.Width(); ok {
minWidth = fw
}
maxWidth := 0
widths := make([]lrWidth, d.cols)
buf := make([]byte, 0, 16)
for row, index := 0, 0; row < d.rows; row++ {
for col := 0; col < d.cols; col, index = col+1, index+1 {
buf = formatValue(buf, d.data[index], c, precision)
w := len(buf)
maxWidth = maxInt(maxWidth, w)
if pi, ok := indexOfPoint(buf); ok {
leftSize := pi
if minWidth > w {
leftSize += minWidth - w
}
widths[col].left = maxInt(widths[col].left, leftSize)
widths[col].right = maxInt(widths[col].right, w-pi-1)
} else {
widths[col].left = maxInt(widths[col].left, w)
}
}
}
return widths, maxWidth
}
func formatValue(buf []byte, val float64, c rune, precision int) []byte {
return strconv.AppendFloat(buf[:0], val, byte(c), precision, 64)
}
func indexOfPoint(buf []byte) (int, bool) {
for i, b := range buf {
if b == byte('.') {
return i, true
}
}
return 0, false
}
func maxInt(a, b int) int {
if a > b {
return a
}
return b
}
| {
"pile_set_name": "Github"
} |
/*
Copyright The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
// Code generated by client-gen. DO NOT EDIT.
package v1
import (
v1 "k8s.io/api/storage/v1"
"k8s.io/client-go/kubernetes/scheme"
rest "k8s.io/client-go/rest"
)
type StorageV1Interface interface {
RESTClient() rest.Interface
CSIDriversGetter
CSINodesGetter
StorageClassesGetter
VolumeAttachmentsGetter
}
// StorageV1Client is used to interact with features provided by the storage.k8s.io group.
type StorageV1Client struct {
restClient rest.Interface
}
func (c *StorageV1Client) CSIDrivers() CSIDriverInterface {
return newCSIDrivers(c)
}
func (c *StorageV1Client) CSINodes() CSINodeInterface {
return newCSINodes(c)
}
func (c *StorageV1Client) StorageClasses() StorageClassInterface {
return newStorageClasses(c)
}
func (c *StorageV1Client) VolumeAttachments() VolumeAttachmentInterface {
return newVolumeAttachments(c)
}
// NewForConfig creates a new StorageV1Client for the given config.
func NewForConfig(c *rest.Config) (*StorageV1Client, error) {
config := *c
if err := setConfigDefaults(&config); err != nil {
return nil, err
}
client, err := rest.RESTClientFor(&config)
if err != nil {
return nil, err
}
return &StorageV1Client{client}, nil
}
// NewForConfigOrDie creates a new StorageV1Client for the given config and
// panics if there is an error in the config.
func NewForConfigOrDie(c *rest.Config) *StorageV1Client {
client, err := NewForConfig(c)
if err != nil {
panic(err)
}
return client
}
// New creates a new StorageV1Client for the given RESTClient.
func New(c rest.Interface) *StorageV1Client {
return &StorageV1Client{c}
}
func setConfigDefaults(config *rest.Config) error {
gv := v1.SchemeGroupVersion
config.GroupVersion = &gv
config.APIPath = "/apis"
config.NegotiatedSerializer = scheme.Codecs.WithoutConversion()
if config.UserAgent == "" {
config.UserAgent = rest.DefaultKubernetesUserAgent()
}
return nil
}
// RESTClient returns a RESTClient that is used to communicate
// with API server by this client implementation.
func (c *StorageV1Client) RESTClient() rest.Interface {
if c == nil {
return nil
}
return c.restClient
}
| {
"pile_set_name": "Github"
} |
package com.timeyang.jkes.entity;
import lombok.AllArgsConstructor;
import lombok.Setter;
import javax.persistence.Embeddable;
/**
* @author chaokunyang
*/
@Embeddable
@Setter
@AllArgsConstructor
public class Car {
private Long id;
private String name;
public Long getId() {
return id;
}
public String getName() {
return name;
}
}
| {
"pile_set_name": "Github"
} |
file(READ "${RunCMake_TEST_BINARY_DIR}/CMP0085-OLD-generated.txt" content)
set(expected "000011")
if(NOT content STREQUAL expected)
set(RunCMake_TEST_FAILED "actual content:\n [[${content}]]\nbut expected:\n [[${expected}]]")
endif()
| {
"pile_set_name": "Github"
} |
module InetData
module Source
class GOV < Base
def download_file(src, dst)
tmp = dst + ".tmp"
ims = false
tries = 0
begin
tries += 1
target = URI.parse(src)
size = 0
csize = nil
http = Net::HTTP.new(target.host, target.port)
if src.index("https") == 0
http.use_ssl = true
end
req = Net::HTTP::Get.new(target.request_uri)
if File.exists?(dst)
req['If-Modified-Since'] = File.stat(dst).mtime.rfc2822
ims = true
end
http.request(req) do |res|
if ims && res.code.to_i == 304
log(" > Skipped downloading of #{dst} due to not modified response")
return true
end
if ims && res['Content-Length']
if res['Content-Length'].to_i == File.size(dst)
log(" > Skipped downloading of #{dst} with same size of #{res['Content-Length']} bytes")
return true
end
end
if res.code.to_i != 200
log(" > Skipped downloading of #{dst} due to server response of #{res.code} #{res.message}")
return true
end
log("Download started from #{src} to #{dst}")
outp = File.open(tmp, "wb")
res.read_body do |chunk|
outp.write(chunk)
size += chunk.length
end
outp.close
end
File.rename(tmp, dst)
rescue ::Interrupt
raise $!
rescue ::Exception
if tries < self.max_tries
log("Download failed: #{src} -> #{dst} : #{$!.class} #{$!}, retrying...")
sleep(30)
retry
else
fail("Download failed: #{src} -> #{dst} : #{$!.class} #{$!} after #{tries} attempts")
end
end
log("Download completed from #{src} to #{dst}")
end
#
# Download the latest data file
#
def download
url = config['gov_domains_url']
targ = URI.parse(url)
file = datafile_name
date = Time.now.strftime("%Y%m%d")
dir = File.expand_path(File.join(storage_path, date))
dst = File.join(dir, file)
FileUtils.mkdir_p(dir)
download_file(url, dst)
end
#
# Normalize the latest data file
#
def normalize
data = latest_data
norm = File.join(data, "normalized")
FileUtils.mkdir_p(norm)
if File.exists?(File.join(norm, "domains.txt"))
log("Normalized data is already present for #{data}")
return
end
src = File.join(data, datafile_name)
dst = File.join(norm, "domains.txt")
tmp = dst + ".tmp"
File.open(tmp, "wb") do |fd|
File.open(src, "rb") do |r|
r.each_line do |line|
next if line =~ /^Domain Name,/
dname = validate_domain(line.strip.downcase.split(",").first.to_s)
if dname
fd.puts dname
else
log("Invalid hostname in #{self.name} : #{src} -> #{line.strip}")
end
end
end
end
uniq_sort_file(tmp)
File.rename(tmp, dst)
end
#
# Find the most recent dataset
#
def latest_data
path = Dir["#{storage_path}/[0-9][0-9][0-9][0-9][0-9][0-9][0-9][0-9]/#{datafile_name}"].
sort{|a,b| b.split("/")[-2].to_i <=> a.split("/")[-2].to_i}.
first
if not path
raise RuntimeError, "No dataset available for #{self.name}"
end
File.dirname(path)
end
#
# The local name of the data file
#
def datafile_name
"current-full.csv"
end
end
end
end
| {
"pile_set_name": "Github"
} |
<html>
<head>
<title>Test 517 An owned, unfocusable element, having aria-dropeffect="move" that inherits role="presentation"</title>
</head>
<body>
<table role="presentation">
<tr>
<td aria-dropeffect="move">Test me</td>
</tr>
</table>
</body>
</html>
| {
"pile_set_name": "Github"
} |
module.exports = {
entry: {
bundle: [
'./docs/entry'
]
},
output: {
path: __dirname,
filename: 'bundle.js'
},
module: {
loaders: [
{
test: /\.js$/,
exclude: /node_modules/,
loader: 'babel'
},
{
test: /\.md$/,
exclude: /node_modules/,
loader: 'html!markdown'
},
{
test: /\.json$/,
loader: 'json'
}
]
},
devServer: {
contentBase: 'docs'
}
}
| {
"pile_set_name": "Github"
} |
/*
Copyright The Kubernetes Authors.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
*/
// Code generated by client-gen. DO NOT EDIT.
package fake
import (
v1beta1 "k8s.io/api/extensions/v1beta1"
v1 "k8s.io/apimachinery/pkg/apis/meta/v1"
labels "k8s.io/apimachinery/pkg/labels"
schema "k8s.io/apimachinery/pkg/runtime/schema"
types "k8s.io/apimachinery/pkg/types"
watch "k8s.io/apimachinery/pkg/watch"
testing "k8s.io/client-go/testing"
)
// FakeDaemonSets implements DaemonSetInterface
type FakeDaemonSets struct {
Fake *FakeExtensionsV1beta1
ns string
}
var daemonsetsResource = schema.GroupVersionResource{Group: "extensions", Version: "v1beta1", Resource: "daemonsets"}
var daemonsetsKind = schema.GroupVersionKind{Group: "extensions", Version: "v1beta1", Kind: "DaemonSet"}
// Get takes name of the daemonSet, and returns the corresponding daemonSet object, and an error if there is any.
func (c *FakeDaemonSets) Get(name string, options v1.GetOptions) (result *v1beta1.DaemonSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewGetAction(daemonsetsResource, c.ns, name), &v1beta1.DaemonSet{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.DaemonSet), err
}
// List takes label and field selectors, and returns the list of DaemonSets that match those selectors.
func (c *FakeDaemonSets) List(opts v1.ListOptions) (result *v1beta1.DaemonSetList, err error) {
obj, err := c.Fake.
Invokes(testing.NewListAction(daemonsetsResource, daemonsetsKind, c.ns, opts), &v1beta1.DaemonSetList{})
if obj == nil {
return nil, err
}
label, _, _ := testing.ExtractFromListOptions(opts)
if label == nil {
label = labels.Everything()
}
list := &v1beta1.DaemonSetList{ListMeta: obj.(*v1beta1.DaemonSetList).ListMeta}
for _, item := range obj.(*v1beta1.DaemonSetList).Items {
if label.Matches(labels.Set(item.Labels)) {
list.Items = append(list.Items, item)
}
}
return list, err
}
// Watch returns a watch.Interface that watches the requested daemonSets.
func (c *FakeDaemonSets) Watch(opts v1.ListOptions) (watch.Interface, error) {
return c.Fake.
InvokesWatch(testing.NewWatchAction(daemonsetsResource, c.ns, opts))
}
// Create takes the representation of a daemonSet and creates it. Returns the server's representation of the daemonSet, and an error, if there is any.
func (c *FakeDaemonSets) Create(daemonSet *v1beta1.DaemonSet) (result *v1beta1.DaemonSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewCreateAction(daemonsetsResource, c.ns, daemonSet), &v1beta1.DaemonSet{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.DaemonSet), err
}
// Update takes the representation of a daemonSet and updates it. Returns the server's representation of the daemonSet, and an error, if there is any.
func (c *FakeDaemonSets) Update(daemonSet *v1beta1.DaemonSet) (result *v1beta1.DaemonSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateAction(daemonsetsResource, c.ns, daemonSet), &v1beta1.DaemonSet{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.DaemonSet), err
}
// UpdateStatus was generated because the type contains a Status member.
// Add a +genclient:noStatus comment above the type to avoid generating UpdateStatus().
func (c *FakeDaemonSets) UpdateStatus(daemonSet *v1beta1.DaemonSet) (*v1beta1.DaemonSet, error) {
obj, err := c.Fake.
Invokes(testing.NewUpdateSubresourceAction(daemonsetsResource, "status", c.ns, daemonSet), &v1beta1.DaemonSet{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.DaemonSet), err
}
// Delete takes name of the daemonSet and deletes it. Returns an error if one occurs.
func (c *FakeDaemonSets) Delete(name string, options *v1.DeleteOptions) error {
_, err := c.Fake.
Invokes(testing.NewDeleteAction(daemonsetsResource, c.ns, name), &v1beta1.DaemonSet{})
return err
}
// DeleteCollection deletes a collection of objects.
func (c *FakeDaemonSets) DeleteCollection(options *v1.DeleteOptions, listOptions v1.ListOptions) error {
action := testing.NewDeleteCollectionAction(daemonsetsResource, c.ns, listOptions)
_, err := c.Fake.Invokes(action, &v1beta1.DaemonSetList{})
return err
}
// Patch applies the patch and returns the patched daemonSet.
func (c *FakeDaemonSets) Patch(name string, pt types.PatchType, data []byte, subresources ...string) (result *v1beta1.DaemonSet, err error) {
obj, err := c.Fake.
Invokes(testing.NewPatchSubresourceAction(daemonsetsResource, c.ns, name, pt, data, subresources...), &v1beta1.DaemonSet{})
if obj == nil {
return nil, err
}
return obj.(*v1beta1.DaemonSet), err
}
| {
"pile_set_name": "Github"
} |
<?xml version="1.0" encoding="utf-8"?>
<TextClock xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="wrap_content" android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:layout_alignParentEnd="true"
android:format24Hour="HH:mm"
android:format12Hour="h:mm"
android:textColor="@color/TrafficLightText"
android:textSize="40sp"
android:textStyle="bold">
</TextClock> | {
"pile_set_name": "Github"
} |
Title: openSUSE 教育版 Li-f-e 获更新
Date: 2010-03-25 19:05
Author: toy
Category: Distros
Tags: Li-f-e, openSUSE
Slug: li-f-e-updated
近日,[openSUSE Education](http://www.opensuse-education.org/) 团队对
openSUSE
的教育版本 Li-f-e 进行了更新,本次更新主要包括以下几个方面:
+ 桌面环境:GNOME 2.28.2、Sugar 0.86.3、KDE 4.3.5
+ 增添软件:Stellarium、Cinelerra、vsftpd、FreeNX
+ 其他更新:LTSP 0.5.1.99(包括 fat-client 支持)、Banshee 1.6 RC
1、Code::Blocks SVN 6182、gcompris 及 tux4kids 等
Li-f-e 的 ISO
映像可从[这里下载](http://www.opensuse-education.org/download/ISOs/)。
{ via [openSUSE
Lizards](http://lizards.opensuse.org/2010/03/24/li-f-e-updated-2/) }
| {
"pile_set_name": "Github"
} |
// Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
// All rights reserved.
// This component and the accompanying materials are made available
// under the terms of the License "Eclipse Public License v1.0"
// which accompanies this distribution, and is available
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
//
// Initial Contributors:
// Nokia Corporation - initial contribution.
//
// Contributors:
//
// Description:
// e32\memmodel\epoc\direct\arm\xsched.cia
//
//
#include <e32cia.h>
#include <arm_mem.h>
#define iMState iWaitLink.iSpare1
#ifdef __SCHEDULER_MACHINE_CODED__
#if defined(_DEBUG)
extern "C" void __DebugMsgRequestComplete(TInt a0, TInt a1, TInt a2);
extern "C" void __DebugMsgReqCompleteWrite(TInt a0, TInt a1, TInt a2);
#endif
__NAKED__ void DThread::RequestComplete(TRequestStatus*& /*aStatus*/, TInt /*aReason*/)
//
// Signal this threads request semaphore.
//
{
ASM_DEBUG2(DThreadRequestComplete,r0,lr);
asm("ldr r3, [r1] "); // r3 points to TRequestStatus
asm("mov r12, #0 ");
asm("str r12, [r1] "); // aStatus=NULL
asm(".global _asm_RequestComplete ");
asm("_asm_RequestComplete: ");
#ifdef BTRACE_REQUESTS
asm("stmdb sp!,{r0-r3,lr}");
asm("mov r1,r3");
asm("mov r3,r2"); // arg3 = aReason
asm("mov r2,r1"); // arg2 = aStatus
asm("add r1,r0,#%a0" : : "i" _FOFF(DThread,iNThread)); // arg1 = &this->iNThread
asm("ldr r0,_threadReqequestCompleteTraceHeader"); // arg0 = header
asm("bl " CSM_ZN6BTrace4OutXEmmmm);
asm("ldmia sp!,{r0-r3,lr}");
#endif
ASM_DEBUG3(RequestComplete,r0,r3,r2);
asm("ldrb r12, [r0, #%a0]" : : "i" _FOFF(DThread,iMState));
asm("add r0, r0, #%a0" : : "i" _FOFF(DThread,iNThread));
asm("cmp r12, #%a0" : : "i" (DThread::EDead)); // test if iMState=EDead
asm("beq " CSM_ZN5NKern12UnlockSystemEv ); // if it is, finish
asm("tst r3, #3 "); // check address aligned
asm("streq r2, [r3] "); // if so, write completion code
asm("moveq r1, #0 "); // and signal thread
asm("beq " CSM_ZN5NKern19ThreadRequestSignalEP7NThreadP10NFastMutex );
asm("b " CSM_ZN5NKern12UnlockSystemEv ); // bad address, just finish.
#ifdef BTRACE_REQUESTS
asm("_threadReqequestCompleteTraceHeader:");
asm(".word %a0" : : "i" (BTRACE_HEADER_C(16,BTrace::ERequests,BTrace::ERequestComplete)));
#endif
}
#endif
| {
"pile_set_name": "Github"
} |
#import "GPUImageFilterGroup.h"
@class GPUImagePicture;
/** A photo filter based on Photoshop action by Amatorka
http://amatorka.deviantart.com/art/Amatorka-Action-2-121069631
*/
// Note: If you want to use this effect you have to add lookup_amatorka.png
// from Resources folder to your application bundle.
@interface GPUImageAmatorkaFilter : GPUImageFilterGroup
{
GPUImagePicture *lookupImageSource;
}
@end
| {
"pile_set_name": "Github"
} |
/* Copyright (c) Colorado School of Mines, 2011.*/
/* All rights reserved. */
/* LAS2SU: $Revision: 1.9 $ ; $Date: 2011/11/16 17:43:20 $ */
#include "par.h"
#include "su.h"
#include "segy.h"
/*********************** self documentation **********************/
char *sdoc[] = {
" ",
" LAS2SU - convert las2 format well log curves to su traces ",
" ",
" las2su <stdin nskip= ncurve= >stdout [optional params] ",
" ",
" Required parameters: ",
" none ",
" Optional parameters: ",
" ncurve=automatic number of log curves in the las file ",
" dz=0.5 input depth sampling (ft) ",
" m=0 output (d1,f1) in feet ",
" =1 output (d1,f1) in meters ",
" ss=0 do not subsample (unless nz > 32767 ) ",
" =1 pass every other sample ",
" verbose=0 =1 to echo las header lines to screen ",
" outhdr=las_header.asc name of file for las headers ",
" ",
" Notes: ",
" 1. It is recommended to run LAS_CERTIFY available from CWLS ",
" at http://cwls.org. ",
" 2. First log curve MUST BE depth. ",
" 3. If number of depth levels > 32767 (segy NT limit) ",
" then input is subsampled by factor of 2 or 4 as needed ",
" 4. Logs may be isolated using tracl header word (1,2,...,ncurve) ",
" tracl=1 is depth ",
" ",
" If the input LAS file contains sonic data as delta t or interval",
" transit time and you plan to use these data for generating a ",
" reflection coefficient time series in suwellrf, convert the sonic",
" trace to velocity using suop with op=s2v (sonic to velocity) ",
" before input of the velocity trace to suwellrf. ",
" ",
" Caveat: ",
" No trap is made for the commonly used null value in LAS files ",
" (-999.25). The null value will be output as ?999.25, which ",
" really messes up a suxwigb display of density data because the",
" ?999.25 skews the more or less 2.5 values of density. ",
" The user needs to edit out null values (-999.25) before running",
" other programs, such as \"suwellrf\". ",
" ",
NULL};
/* Credits:
* Chris Liner based on code by Ferhan Ahmed and a2b.c (June 2005)
* (Based on code by Ferhan Ahmed and a2b.c)
* I gratefully acknowledge Saudi Aramco for permission
* to release this code developed while I worked for the
* EXPEC-ARC research division.
* CWP: John Stockwell 31 Oct 2006, combining lasstrip and
* CENPET: lasstrip 2006 by Werner Heigl
*
* Rob Hardy: allow the ncurve parameter to work correctly if set
* - change string length to 400 characters to allow more curves
* - note nskip in header is totally ignored !
*
* Ideas for improvement:
* add option to chop off part of logs (often shallow
* portions are not of interest
* cross check sampling interval from header against
* values found from first log curve (=depth)
*
*/
/**************** end self doc ***********************************/
/* defined quantities */
#define LAS_MAXLINE 1000
#define LAS_HDR_DEF "las_header.asc"
/* function prototype for subroutine used internally */
int las_getnewline(char line[], int maxline);
segy tr; /* output trace structure */
int
main(int argc, char **argv)
{
int ncurve=0; /* number of log curves in las file */
int discard=1; /* count to discard */
float **x=NULL; /* binary floats */
float len=0; /* line length */
char string[300]; /* one line of input ascii file */
char c1[30]; /* ascii form of log value */
int m; /* flag for metric (d1,f1) output */
int nzmax; /* max number of depth levels */
int nz; /* actual number of depth levels */
int iz,izz,icurve,i; /* counters */
int verbose; /* if 1(yes) echo las header lines to stderr */
float dz; /* depth sample rate */
int ss; /* subsample flag */
char line[LAS_MAXLINE];
char *outhdr=NULL; /* name of file holding LAS header */
FILE *outhdrfp=NULL; /* ... its file pointer */
/* booleans for curve portion */
cwp_Bool is_ncurve_set=cwp_false; /* is ncurve set manually?*/
cwp_Bool in_tilde_C_block=cwp_false; /* are we inside the ~C block?*/
/* Hook up getpar */
initargs(argc, argv);
requestdoc(1);
/* get parameters */
if (!getparint("verbose", &verbose)) verbose = 0;
if (!getparint("m", &m)) m = 0;
if (!getparint("ss", &ss)) ss = 0;
if (!getparfloat("dz", &dz)) dz = 0.5;
if (!getparstring("outhdr", &outhdr)) outhdr = LAS_HDR_DEF;
outhdrfp = efopen(outhdr, "w");
/* WMH: read LAS header, extract ncurve, and copy to outhdr */
/* hardyr: flip the booleans here */
if (!getparint("ncurve",&ncurve)) {
is_ncurve_set=cwp_true;
ncurve = 0;
} else {
is_ncurve_set=cwp_false;
}
checkpars();
do {
len = las_getnewline(line,LAS_MAXLINE);
i = 0;
while (line[i]!='\0') {
fputc(line[i],outhdrfp);
++i;
}
fputc('\n',outhdrfp);
/* have we reached the curve section yet? */
if (strncmp("~C",line,2)==0) {
in_tilde_C_block=cwp_true;
} else if(strncmp("~P",line,2)==0) {
in_tilde_C_block=cwp_false;
}
/* count discards */
/* hardyr: if ncurve not set */
if ((strncmp("#",line,1)==0) && (in_tilde_C_block) ) ++discard;
/* count lines */
/* hardyr: if ncurve not set */
if ((in_tilde_C_block) && (is_ncurve_set) ) ++ncurve;
/* are we through the curve section? */
} while (strncmp("~A",line,2)!=0 );
/* discard # and ~ line counts */
/* hardyr: if ncurve not set */
if ((is_ncurve_set)) ncurve = ncurve - discard;
/* close output file */
efclose(outhdrfp);
/* max depth levels: 32767 (segy limit) */
nzmax = SU_NFLTS;
if (verbose) warn("ncurve %d nzmax %d",ncurve,nzmax);
/* alloc array to hold float log values */
x = ealloc2float(nzmax,ncurve);
/* zero array */
memset((void *) x[0], 0, ncurve*nzmax*FSIZE);
/* initialize depth counter */
nz = 0;
iz = 0;
/* get each line as a string */
/* hardyr change line length max to 400 characters */
while(fgets(string,400,stdin) != NULL) {
/* read first token */
strcpy(c1,strtok(string," \n\t"));
/* load log value into float array */
x[0][iz] = atof(c1);
for (icurve = 1; icurve < ncurve; ++icurve) {
/* read next token get ascii log value */
strcpy(c1,strtok(NULL," \n\t"));
/* load this log value into float array */
x[icurve][iz] = atof(c1);
}
/* bump depth counter */
++iz;
}
/* number of depth values in log */
nz = iz;
warn("nz=%i",nz);
/* check that nz limit is not exceeded, or subsampling requested */
if ( nz > nzmax || ss == 1 ) {
/* reset number of depth samples and sample rate */
nz = nz/2;
dz = 2.0 * dz;
/* subsample */
for (icurve=0 ; icurve < ncurve ; ++icurve) {
for (iz = 0 ; iz < nz ; ++iz){
izz = 2*iz;
x[icurve][iz] = x[icurve][izz];
}
}
if (verbose) warn("New: nz=%i dz=%g ft\n",nz,dz);
}
/* check again (possible deep well with 0.25 ft sampling) */
if ( nz > nzmax || ss == 1 ) {
/* reset number of depth samples and sample rate */
nz = nz/2;
dz = 2.0 * dz;
/* subsample */
for (icurve=0 ; icurve < ncurve ; ++icurve){
for (iz = 0 ; iz < nz ; ++iz){
izz = 2*iz;
x[icurve][iz] = x[icurve][izz];
}
}
if (verbose) warn("New: nz=%i dz=%g ft\n",nz,dz);
}
/* set up output trace headers */
tr.trid = 1; /* su time traces (trick) */
tr.ns = nz; /* samples per trace */
tr.dt = 1000*dz; /* time sample rate (trick) */
if (m == 0) {
tr.d1 = dz; /* actual dz (in ft) */
tr.f1 = x[0][0]; /* first depth value (in ft) */
} else {
tr.d1 = dz/3.28084; /* actual dz (in m) */
tr.f1 = x[0][0]/3.28084; /* first depth value (in m) */
}
for (icurve=0 ; icurve < ncurve ; ++icurve){
tr.tracl = icurve+1;
for (iz = 0 ; iz < nz ; ++iz){
tr.data[iz] = x[icurve][iz];
}
puttr(&tr);
}
return EXIT_SUCCESS;
}
int las_getnewline(char s[], int lim)
/***************************************************************************
las_getnewline: read a line from stdin into s[] and return length of line
****************************************************************************
Input:
s[] input string
lim maximum length of line
Returns:
i length of line
****************************************************************************
Author: CENPET: Werner Heigl 2005
****************************************************************************/
{
int c=0,i;
for (i=0; i<lim-1 && (c=getchar())!=EOF && c!='\n'; ++i)
s[i] = c;
if (c=='\n') {
s[i] = c;
++i;
}
s[i] = '\0';
return i;
}
| {
"pile_set_name": "Github"
} |
---
title: Componente React para Emblemas
components: Badge
githubLabel: 'component: Badge'
---
# Badge
<p class="description">O componente <code>Badge</code> gera um pequeno emblema no canto superior direito de seu(s) filho(s).</p>
{{"component": "modules/components/ComponentLinkHeader.js"}}
## Emblemas básicos
Exemplos de emblemas contendo texto, usando cores primárias e secundárias. O emblema é aplicado aos seus filhos.
{{"demo": "pages/components/badges/SimpleBadge.js"}}
## Emblemas customizados
Aqui está um exemplo de customização do componente. Você pode aprender mais sobre isso na [página de documentação de sobrescritas](/customization/components/).
{{"demo": "pages/components/badges/CustomizedBadges.js"}}
## Visibilidade do emblema
A visibilidade dos emblemas pode ser controlada usando a propriedade `invisible`.
{{"demo": "pages/components/badges/BadgeVisibility.js"}}
O emblema se esconde automaticamente quando o badgeContent é zero. Você pode sobrescrever isso com a propriedade `showZero`.
{{"demo": "pages/components/badges/ShowZeroBadge.js"}}
## Valor máximo
Você pode usar a propriedade `max` para limitar o valor do conteúdo do emblema.
{{"demo": "pages/components/badges/BadgeMax.js"}}
## Emblema como ponto
A propriedade `dot` altera um emblema para um pequeno ponto. Isto pode ser usado como uma notificação de que algo mudou sem fornecer uma contagem.
{{"demo": "pages/components/badges/DotBadge.js"}}
## Alinhamento do emblema
Você pode usar a propriedade `overlap` para colocar o emblema em relação ao canto do elemento envolvido.
{{"demo": "pages/components/badges/BadgeOverlap.js"}}
## Alinhamento do emblema
Você pode usar a propriedade `anchorOrigin` para mover o emblema para qualquer canto do elemento envolvido.
{{"demo": "pages/components/badges/BadgeAlignment.js", "hideToolbar": true}}
| {
"pile_set_name": "Github"
} |
# readable-stream
***Node-core v5.9.1 streams for userland*** [](https://travis-ci.org/nodejs/readable-stream)
[](https://nodei.co/npm/readable-stream/)
[](https://nodei.co/npm/readable-stream/)
[](https://saucelabs.com/u/readable-stream)
```bash
npm install --save readable-stream
```
***Node-core streams for userland***
This package is a mirror of the Streams2 and Streams3 implementations in
Node-core, including [documentation](doc/stream.markdown).
If you want to guarantee a stable streams base, regardless of what version of
Node you, or the users of your libraries are using, use **readable-stream** *only* and avoid the *"stream"* module in Node-core, for background see [this blogpost](http://r.va.gg/2014/06/why-i-dont-use-nodes-core-stream-module.html).
As of version 2.0.0 **readable-stream** uses semantic versioning.
# Streams WG Team Members
* **Chris Dickinson** ([@chrisdickinson](https://github.com/chrisdickinson)) <[email protected]>
- Release GPG key: 9554F04D7259F04124DE6B476D5A82AC7E37093B
* **Calvin Metcalf** ([@calvinmetcalf](https://github.com/calvinmetcalf)) <[email protected]>
- Release GPG key: F3EF5F62A87FC27A22E643F714CE4FF5015AA242
* **Rod Vagg** ([@rvagg](https://github.com/rvagg)) <[email protected]>
- Release GPG key: DD8F2338BAE7501E3DD5AC78C273792F7D83545D
* **Sam Newman** ([@sonewman](https://github.com/sonewman)) <[email protected]>
* **Mathias Buus** ([@mafintosh](https://github.com/mafintosh)) <[email protected]>
* **Domenic Denicola** ([@domenic](https://github.com/domenic)) <[email protected]>
| {
"pile_set_name": "Github"
} |
//
// ___FILENAME___
// ___PROJECTNAME___
//
// Created by ___FULLUSERNAME___ on ___DATE___.
// Copyright ___YEAR___ ___ORGANIZATIONNAME___. All rights reserved.
//
#include "___FILEBASENAME___.h"
| {
"pile_set_name": "Github"
} |
// Mgmt
// Copyright (C) 2013-2020+ James Shubin and the project contributors
// Written by James Shubin <[email protected]> and the project contributors
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see <http://www.gnu.org/licenses/>.
package interfaces
import (
"fmt"
"io"
"io/ioutil"
"strings"
"github.com/purpleidea/mgmt/util/errwrap"
"gopkg.in/yaml.v2"
)
const (
// MetadataFilename is the filename for the metadata storage. This is
// the ideal entry point for any running code.
MetadataFilename = "metadata.yaml"
// FileNameExtension is the filename extension used for languages files.
FileNameExtension = "mcl" // alternate suggestions welcome!
// DotFileNameExtension is the filename extension with a dot prefix.
DotFileNameExtension = "." + FileNameExtension
// MainFilename is the default filename for code to start running from.
MainFilename = "main" + DotFileNameExtension
// PathDirectory is the path directory name we search for modules in.
PathDirectory = "path/"
// FilesDirectory is the files directory name we include alongside
// modules. It can store any useful files that we'd like.
FilesDirectory = "files/"
// ModuleDirectory is the default module directory name. It gets
// appended to whatever the running prefix is or relative to the base
// dir being used for deploys.
ModuleDirectory = "modules/"
)
// Metadata is a data structure representing the module metadata. Since it can
// get moved around to different filesystems, it should only contain relative
// paths.
type Metadata struct {
// Main is the path to the entry file where we start reading code.
// Normally this is main.mcl or the value of the MainFilename constant.
Main string `yaml:"main"`
// Path is the relative path to the local module search path directory
// that we should look in. This is similar to golang's vendor directory.
// If a module wishes to include this directory, it's recommended that
// it have the contained directory be a `git submodule` if possible.
Path string `yaml:"path"`
// Files is the location of the files/ directory which can contain some
// useful additions that might get used in the modules. You can store
// templates, or any other data that you'd like.
// TODO: also allow storing files alongside the .mcl files in their dir!
Files string `yaml:"files"`
// License is the listed license of the module. Use the short names, eg:
// LGPLv3+, or MIT.
License string `yaml:"license"`
// ParentPathBlock specifies whether we're allowed to search in parent
// metadata file Path settings for modules. We always search in the
// global path if we don't find others first. This setting defaults to
// false, which is important because the downloader uses it to decide
// where to put downloaded modules. It is similar to the equivalent of
// a `require vendoring` flag in golang if such a thing existed. If a
// module sets this to true, and specifies a Path value, then only that
// path will be used as long as imports are present there. Otherwise it
// will fall-back on the global modules directory. If a module sets this
// to true, and does not specify a Path value, then the global modules
// directory is automatically chosen for the import location for this
// module. When this is set to true, in no scenario will an import come
// from a directory other than the one specified here, or the global
// modules directory. Module authors should use this sparingly when they
// absolutely need a specific import vendored, otherwise they might
// rouse the ire of module consumers. Keep in mind that you can specify
// a Path directory, and include a git submodule in it, which will be
// used by default, without specifying this option. In that scenario,
// the consumer can decide to not recursively clone your submodule if
// they wish to override it higher up in the module search locations.
ParentPathBlock bool `yaml:"parentpathblock"`
// Metadata stores a link to the parent metadata structure if it exists.
Metadata *Metadata // this does *NOT* get a yaml struct tag
// metadataPath stores the absolute path to this metadata file as it is
// parsed. This is useful when we search upwards for parent Path values.
metadataPath string // absolute path that this file was found in
// TODO: is this needed anymore?
defaultMain *string // set this to pick a default Main when decoding
// bug395 is a flag to workaround the terrible yaml parser resetting all
// the default struct field values when it finds an empty yaml document.
// We set this value to have a default of true, which enables us to know
// if the document was empty or not, and if so, then we know this struct
// was emptied, so we should then return a new struct with all defaults.
// See: https://github.com/go-yaml/yaml/issues/395 for more information.
bug395 bool
}
// DefaultMetadata returns the default metadata that is used for absent values.
func DefaultMetadata() *Metadata {
return &Metadata{ // the defaults
Main: MainFilename, // main.mcl
// This MUST be empty for a top-level default, because if it's
// not, then an undefined Path dir at a lower level won't search
// upwards to find a suitable path, and we'll nest forever...
//Path: PathDirectory, // do NOT set this!
Files: FilesDirectory, // files/
//License: "", // TODO: ???
bug395: true, // workaround, lol
}
}
// SetAbsSelfPath sets the absolute directory path to this metadata file. This
// method is used on a built metadata file so that it can internally know where
// it is located.
func (obj *Metadata) SetAbsSelfPath(p string) error {
obj.metadataPath = p
return nil
}
// ToBytes marshals the struct into a byte array and returns it.
func (obj *Metadata) ToBytes() ([]byte, error) {
return yaml.Marshal(obj) // TODO: obj or *obj ?
}
// NOTE: this is not currently needed, but here for reference.
//// MarshalYAML modifies the struct before it is used to build the raw output.
//func (obj *Metadata) MarshalYAML() (interface{}, error) {
// // The Marshaler interface may be implemented by types to customize
// // their behavior when being marshaled into a YAML document. The
// // returned value is marshaled in place of the original value
// // implementing Marshaler.
//
// if obj.metadataPath == "" { // make sure metadataPath isn't saved!
// return obj, nil
// }
// md := obj.Copy() // TODO: implement me
// md.metadataPath = "" // if set, blank it out before save
// return md, nil
//}
// UnmarshalYAML is the standard unmarshal method for this struct.
func (obj *Metadata) UnmarshalYAML(unmarshal func(interface{}) error) error {
type indirect Metadata // indirection to avoid infinite recursion
def := DefaultMetadata()
// support overriding
if x := obj.defaultMain; x != nil {
def.Main = *x
}
raw := indirect(*def) // convert; the defaults go here
if err := unmarshal(&raw); err != nil {
return err
}
*obj = Metadata(raw) // restore from indirection with type conversion!
return nil
}
// ParseMetadata reads from some input and returns a *Metadata struct that
// contains plausible values to be used.
func ParseMetadata(reader io.Reader) (*Metadata, error) {
metadata := DefaultMetadata() // populate this
//main := MainFilename // set a custom default here if you want
//metadata.defaultMain = &main
// does not work in all cases :/ (fails with EOF files, ioutil does not)
//decoder := yaml.NewDecoder(reader)
////decoder.SetStrict(true) // TODO: consider being strict?
//if err := decoder.Decode(metadata); err != nil {
// return nil, errwrap.Wrapf(err, "can't parse metadata")
//}
b, err := ioutil.ReadAll(reader)
if err != nil {
return nil, errwrap.Wrapf(err, "can't read metadata")
}
if err := yaml.Unmarshal(b, metadata); err != nil {
return nil, errwrap.Wrapf(err, "can't parse metadata")
}
if !metadata.bug395 { // workaround, lol
// we must have gotten an empty document, so use a new default!
metadata = DefaultMetadata()
}
// FIXME: search for unclean paths containing ../ or similar and error!
if strings.HasPrefix(metadata.Main, "/") || strings.HasSuffix(metadata.Main, "/") {
return nil, fmt.Errorf("the Main field must be a relative file path")
}
if metadata.Path != "" && (strings.HasPrefix(metadata.Path, "/") || !strings.HasSuffix(metadata.Path, "/")) {
return nil, fmt.Errorf("the Path field must be undefined or be a relative dir path")
}
if metadata.Files != "" && (strings.HasPrefix(metadata.Files, "/") || !strings.HasSuffix(metadata.Files, "/")) {
return nil, fmt.Errorf("the Files field must be undefined or be a relative dir path")
}
// TODO: add more validation
return metadata, nil
}
// FindModulesPath returns an absolute path to the Path dir where modules can be
// found. This can vary, because the current metadata file might not specify a
// Path value, meaning we'd have to return the global modules path.
// Additionally, we can search upwards for a path if our metadata file allows
// this. It searches with respect to the calling base directory, and uses the
// ParentPathBlock field to determine if we're allowed to search upwards. It
// does logically without doing any filesystem operations.
func FindModulesPath(metadata *Metadata, base, modules string) (string, error) {
ret := func(s string) (string, error) { // return helper function
// don't return an empty string without an error!!!
if s == "" {
return "", fmt.Errorf("can't find a module path")
}
return s, nil
}
m := metadata // start
b := base // absolute base path current metadata file is in
for m != nil {
if m.metadataPath == "" { // a top-level module might be empty!
return ret(modules) // so return this, there's nothing else!
}
if m.metadataPath != b { // these should be the same if no bugs!
return "", fmt.Errorf("metadata inconsistency: `%s` != `%s`", m.metadataPath, b)
}
// does metadata specify where to look ?
// search in the module specific space
if m.Path != "" { // use this path, since it was specified!
if !strings.HasSuffix(m.Path, "/") {
return "", fmt.Errorf("metadata inconsistency: path `%s` has no trailing slash", m.Path)
}
return ret(b + m.Path) // join w/o cleaning trailing slash
}
// are we allowed to search incrementally upwards?
if m.ParentPathBlock {
break
}
// search upwards (search in parent dirs upwards recursively...)
m = m.Metadata // might be nil
if m != nil {
b = m.metadataPath // get new parent path
}
}
// by now we haven't found a metadata path, so we use the global path...
return ret(modules) // often comes from an ENV or a default
}
// FindModulesPathList does what FindModulesPath does, except this function
// returns the entirely linear string of possible module locations until it gets
// to the root. This can be useful if you'd like to know which possible
// locations are valid, so that you can search through them to see if there is
// downloaded code available.
func FindModulesPathList(metadata *Metadata, base, modules string) ([]string, error) {
found := []string{}
ret := func(s []string) ([]string, error) { // return helper function
// don't return an empty list without an error!!!
if s == nil || len(s) == 0 {
return nil, fmt.Errorf("can't find any module paths")
}
return s, nil
}
m := metadata // start
b := base // absolute base path current metadata file is in
for m != nil {
if m.metadataPath == "" { // a top-level module might be empty!
return ret([]string{modules}) // so return this, there's nothing else!
}
if m.metadataPath != b { // these should be the same if no bugs!
return nil, fmt.Errorf("metadata inconsistency: `%s` != `%s`", m.metadataPath, b)
}
// does metadata specify where to look ?
// search in the module specific space
if m.Path != "" { // use this path, since it was specified!
if !strings.HasSuffix(m.Path, "/") {
return nil, fmt.Errorf("metadata inconsistency: path `%s` has no trailing slash", m.Path)
}
p := b + m.Path // join w/o cleaning trailing slash
found = append(found, p) // add to list
}
// are we allowed to search incrementally upwards?
if m.ParentPathBlock {
break
}
// search upwards (search in parent dirs upwards recursively...)
m = m.Metadata // might be nil
if m != nil {
b = m.metadataPath // get new parent path
}
}
// add the global path to everything we've found...
found = append(found, modules) // often comes from an ENV or a default
return ret(found)
}
| {
"pile_set_name": "Github"
} |
Copyright (c) 2011, Barry Schwartz <[email protected]>, with Reserved Font Name OFL "Fanwood".
This Font Software is licensed under the SIL Open Font License, Version 1.1.
This license is copied below, and is also available with a FAQ at:
http://scripts.sil.org/OFL
Version 1.1 - 26 February 2007
SIL Open Font License
====================================================
Preamble
----------
The goals of the Open Font License (OFL) are to stimulate worldwide
development of collaborative font projects, to support the font creation
efforts of academic and linguistic communities, and to provide a free and
open framework in which fonts may be shared and improved in partnership
with others.
The OFL allows the licensed fonts to be used, studied, modified and
redistributed freely as long as they are not sold by themselves. The
fonts, including any derivative works, can be bundled, embedded,
redistributed and/or sold with any software provided that any reserved
names are not used by derivative works. The fonts and derivatives,
however, cannot be released under any other type of license. The
requirement for fonts to remain under this license does not apply
to any document created using the fonts or their derivatives.
Definitions
-------------
`"Font Software"` refers to the set of files released by the Copyright
Holder(s) under this license and clearly marked as such. This may
include source files, build scripts and documentation.
`"Reserved Font Name"` refers to any names specified as such after the
copyright statement(s).
`"Original Version"` refers to the collection of Font Software components as
distributed by the Copyright Holder(s).
`"Modified Version"` refers to any derivative made by adding to, deleting,
or substituting -- in part or in whole -- any of the components of the
Original Version, by changing formats or by porting the Font Software to a
new environment.
`"Author"` refers to any designer, engineer, programmer, technical
writer or other person who contributed to the Font Software.
Permission & Conditions
------------------------
Permission is hereby granted, free of charge, to any person obtaining
a copy of the Font Software, to use, study, copy, merge, embed, modify,
redistribute, and sell modified and unmodified copies of the Font
Software, subject to the following conditions:
1. Neither the Font Software nor any of its individual components,
in Original or Modified Versions, may be sold by itself.
2. Original or Modified Versions of the Font Software may be bundled,
redistributed and/or sold with any software, provided that each copy
contains the above copyright notice and this license. These can be
included either as stand-alone text files, human-readable headers or
in the appropriate machine-readable metadata fields within text or
binary files as long as those fields can be easily viewed by the user.
3. No Modified Version of the Font Software may use the Reserved Font
Name(s) unless explicit written permission is granted by the corresponding
Copyright Holder. This restriction only applies to the primary font name as
presented to the users.
4. The name(s) of the Copyright Holder(s) or the Author(s) of the Font
Software shall not be used to promote, endorse or advertise any
Modified Version, except to acknowledge the contribution(s) of the
Copyright Holder(s) and the Author(s) or with their explicit written
permission.
5. The Font Software, modified or unmodified, in part or in whole,
must be distributed entirely under this license, and must not be
distributed under any other license. The requirement for fonts to
remain under this license does not apply to any document created
using the Font Software.
Termination
-----------
This license becomes null and void if any of the above conditions are
not met.
DISCLAIMER
THE FONT SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT
OF COPYRIGHT, PATENT, TRADEMARK, OR OTHER RIGHT. IN NO EVENT SHALL THE
COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
INCLUDING ANY GENERAL, SPECIAL, INDIRECT, INCIDENTAL, OR CONSEQUENTIAL
DAMAGES, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
OTHER DEALINGS IN THE FONT SOFTWARE.
| {
"pile_set_name": "Github"
} |
package com.tencent.mm.ui.account;
import android.content.DialogInterface;
import android.content.DialogInterface.OnCancelListener;
import com.tencent.mm.model.ax;
import com.tencent.mm.modelsimple.y;
import com.tencent.mm.q.l;
final class hk
implements DialogInterface.OnCancelListener
{
hk(RegSetInfoUI paramRegSetInfoUI, y paramy) {}
public final void onCancel(DialogInterface paramDialogInterface)
{
ax.tm().c(ixe);
ax.tm().b(126, ixd);
}
}
/* Location:
* Qualified Name: com.tencent.mm.ui.account.hk
* Java Class Version: 6 (50.0)
* JD-Core Version: 0.7.1
*/ | {
"pile_set_name": "Github"
} |
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jun 6 2019 20:12:56).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by Steve Nygard.
//
#import <objc/NSObject.h>
#import <IDEKit/IDEReviewFilesDataSource-Protocol.h>
@class IDENavigableItem, IDEWorkspace, NSArray, NSPredicate, NSString;
@interface IDESourceControlReviewFilesDataSource : NSObject <IDEReviewFilesDataSource>
{
IDENavigableItem *_navigableItem;
NSArray *_statusCategoryNames;
NSString *_selectedRevisionIdentifier;
NSPredicate *_filterPredicate;
IDEWorkspace *_workspace;
NSString *_filterString;
}
+ (id)keyPathsForValuesAffectingFlatNavigableItem;
+ (id)keyPathsForValuesAffectingFileSystemNavigableItem;
+ (id)keyPathsForValuesAffectingWorkspaceNavigableItem;
@property(copy) NSArray *statusCategoryNames; // @synthesize statusCategoryNames=_statusCategoryNames;
@property(retain) IDEWorkspace *workspace; // @synthesize workspace=_workspace;
@property(copy) NSString *selectedRevisionIdentifier; // @synthesize selectedRevisionIdentifier=_selectedRevisionIdentifier;
- (void).cxx_destruct;
- (void)dealloc;
- (void)teardown;
- (id)reviewFilesNavigator:(id)arg1 importantFilePathsForNavigableItem:(id)arg2 excludingDisabledItems:(id)arg3;
- (id)reviewFilesNavigator:(id)arg1 documentLocationForNavigableItem:(id)arg2;
@property(copy) NSString *filterString; // @synthesize filterString=_filterString;
@property(copy) NSPredicate *filterPredicate; // @synthesize filterPredicate=_filterPredicate;
- (id)issueNavigableItem;
@property(readonly) IDENavigableItem *flatNavigableItem;
@property(readonly) IDENavigableItem *fileSystemNavigableItem;
@property(readonly) IDENavigableItem *workspaceNavigableItem;
@property(copy) IDENavigableItem *navigableItem; // @synthesize navigableItem=_navigableItem;
- (id)init;
// Remaining properties
@property(readonly, copy) NSString *debugDescription;
@property(readonly, copy) NSString *description;
@property(readonly) unsigned long long hash;
@property(readonly) Class superclass;
@end
| {
"pile_set_name": "Github"
} |
# Lenient-Encryption11.rnc
#
# Copyright 2011 W3C (Massachusetts Institute of Technology,
# Institut National de Recherche en Informatique et en Automatique,
# Keio University). All Rights Reserved. http://www.w3.org/Consortium/Legal/
#
# Use and distribution of all schemas in this directory are permitted under the terms
# W3C Software Notice and License
# http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231
namespace ds = "http://www.w3.org/2000/09/xmldsig#"
namespace ds11 = "http://www.w3.org/2009/xmldsig11#"
namespace xenc = "http://www.w3.org/2001/04/xmlenc#"
namespace xenc11 = "http://www.w3.org/2009/xmlenc11#"
start = anyForeignElementOrEncrypted
anyForeignElementOrEncrypted =
element * - xenc:* {
mixed { security_anyAttribute*, anyForeignElementOrEncrypted* } }
| xenc_EncryptedData
| xenc_EncryptedKey
ds_anyForeignElement = element * - (ds:* | xenc:*) {
mixed { security_anyAttribute*, security_anyElement* } }
dsig11_anyForeignElement = element * - ds11:* {
mixed { security_anyAttribute*, security_anyElement* } }
xenc_anyForeignElement = element * - xenc:* {
mixed { security_anyAttribute*, security_anyElement* } }
xenc11_anyForeignElement = element * - xenc11:* {
mixed { security_anyAttribute*, security_anyElement* } }
include "security_any.rnc"
include "xmldsig-core-schema.rnc"
include "xmldsig-allowAnyForeign.rnc"
include "xmldsig11-schema.rnc"
include "xmldsig11-allowAnyForeign.rnc"
include "xenc-schema.rnc"
include "xenc-allowAnyForeign.rnc"
include "xenc-schema-11.rnc"
include "xenc11-allowAnyForeign.rnc" | {
"pile_set_name": "Github"
} |
set(LLVM_LINK_COMPONENTS
Core
ExecutionEngine
Interpreter
MC
RuntimeDyld
Support
)
add_llvm_unittest(ExecutionEngineTests
ExecutionEngineTest.cpp
)
# Include MCJIT tests only if native arch is a built JIT target.
list(FIND LLVM_TARGETS_TO_BUILD "${LLVM_NATIVE_ARCH}" build_idx)
list(FIND LLVM_TARGETS_WITH_JIT "${LLVM_NATIVE_ARCH}" jit_idx)
if (NOT build_idx LESS 0 AND NOT jit_idx LESS 0)
add_subdirectory(MCJIT)
endif()
| {
"pile_set_name": "Github"
} |
#!/usr/bin/env python3
#
# This file is the most simple lilac.py file,
# and it suits for most packages in AUR.
#
from lilaclib import *
def post_build():
git_add_files('PKGBUILD')
git_commit()
update_aur_repo()
def pre_build():
run_cmd(['updpkgsums'])
vcs_update()
if __name__ == '__main__':
single_main()
| {
"pile_set_name": "Github"
} |
<?php
/*
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
* OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*
* This software consists of voluntary contributions made by many individuals
* and is licensed under the MIT license. For more information, see
* <http://www.doctrine-project.org>.
*/
namespace Doctrine\ORM\Query\AST;
/**
* ConditionalExpression ::= ConditionalTerm {"OR" ConditionalTerm}*
*
*
* @link www.doctrine-project.org
* @since 2.0
* @author Guilherme Blanco <[email protected]>
* @author Jonathan Wage <[email protected]>
* @author Roman Borschel <[email protected]>
*/
class ConditionalExpression extends Node
{
public $conditionalTerms = array();
public function __construct(array $conditionalTerms)
{
$this->conditionalTerms = $conditionalTerms;
}
public function dispatch($sqlWalker)
{
return $sqlWalker->walkConditionalExpression($this);
}
}
| {
"pile_set_name": "Github"
} |
documentation_complete: true
title: 'Verify Group Who Owns Backup passwd File'
description: '{{{ describe_file_group_owner(file="/etc/passwd-", group="root") }}}'
rationale: |-
The <tt>/etc/passwd-</tt> file is a backup file of <tt>/etc/passwd</tt>, and as such,
it contains information about the users that are configured on the system.
Protection of this file is critical for system security.
severity: medium
identifiers:
cce@rhel7: CCE-83323-6
cce@rhel8: CCE-83324-4
references:
cis@rhel7: 6.1.6
cis@rhel8: 6.1.6
ocil_clause: '{{{ ocil_clause_file_group_owner(file="/etc/passwd-", group="root") }}}'
ocil: '{{{ ocil_file_group_owner(file="/etc/passwd-", group="root") }}}'
template:
name: file_groupowner
vars:
filepath: /etc/passwd-
filegid: '0'
missing_file_pass: 'true'
| {
"pile_set_name": "Github"
} |
/**********************************************************************
*
* Project: CPL - Common Portability Library
* Purpose: CPL worker thread pool
* Author: Even Rouault, <even dot rouault at spatialys dot com>
*
**********************************************************************
* Copyright (c) 2015, Even Rouault, <even dot rouault at spatialys dot com>
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included
* in all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
* THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* DEALINGS IN THE SOFTWARE.
****************************************************************************/
#include "cpl_port.h"
#include "cpl_worker_thread_pool.h"
#include <cstddef>
#include <memory>
#include "cpl_conv.h"
#include "cpl_error.h"
#include "cpl_vsi.h"
CPL_CVSID("$Id$")
struct CPLWorkerThreadJob
{
CPLThreadFunc pfnFunc;
void *pData;
};
/************************************************************************/
/* CPLWorkerThreadPool() */
/************************************************************************/
/** Instantiate a new pool of worker threads.
*
* The pool is in an uninitialized state after this call. The Setup() method
* must be called.
*/
CPLWorkerThreadPool::CPLWorkerThreadPool()
{
}
/************************************************************************/
/* ~CPLWorkerThreadPool() */
/************************************************************************/
/** Destroys a pool of worker threads.
*
* Any still pending job will be completed before the destructor returns.
*/
CPLWorkerThreadPool::~CPLWorkerThreadPool()
{
WaitCompletion();
{
std::lock_guard<std::mutex> oGuard(m_mutex);
eState = CPLWTS_STOP;
}
for( auto& wt: aWT )
{
{
std::lock_guard<std::mutex> oGuard(wt->m_mutex);
wt->m_cv.notify_one();
}
CPLJoinThread(wt->hThread);
}
CPLListDestroy(psWaitingWorkerThreadsList);
}
/************************************************************************/
/* WorkerThreadFunction() */
/************************************************************************/
void CPLWorkerThreadPool::WorkerThreadFunction(void* user_data)
{
CPLWorkerThread* psWT = static_cast<CPLWorkerThread*>(user_data);
CPLWorkerThreadPool* poTP = psWT->poTP;
if( psWT->pfnInitFunc )
psWT->pfnInitFunc( psWT->pInitData );
while( true )
{
CPLWorkerThreadJob* psJob = poTP->GetNextJob(psWT);
if( psJob == nullptr )
break;
if( psJob->pfnFunc )
{
psJob->pfnFunc(psJob->pData);
}
CPLFree(psJob);
#if DEBUG_VERBOSE
CPLDebug("JOB", "%p finished a job", psWT);
#endif
poTP->DeclareJobFinished();
}
}
/************************************************************************/
/* SubmitJob() */
/************************************************************************/
/** Queue a new job.
*
* @param pfnFunc Function to run for the job.
* @param pData User data to pass to the job function.
* @return true in case of success.
*/
bool CPLWorkerThreadPool::SubmitJob( CPLThreadFunc pfnFunc, void* pData )
{
CPLAssert( !aWT.empty() );
CPLWorkerThreadJob* psJob = static_cast<CPLWorkerThreadJob *>(
VSI_MALLOC_VERBOSE(sizeof(CPLWorkerThreadJob)));
if( psJob == nullptr )
return false;
psJob->pfnFunc = pfnFunc;
psJob->pData = pData;
CPLList* psItem =
static_cast<CPLList *>(VSI_MALLOC_VERBOSE(sizeof(CPLList)));
if( psItem == nullptr )
{
VSIFree(psJob);
return false;
}
psItem->pData = psJob;
std::unique_lock<std::mutex> oGuard(m_mutex);
psItem->psNext = psJobQueue;
psJobQueue = psItem;
nPendingJobs++;
if( psWaitingWorkerThreadsList )
{
CPLWorkerThread* psWorkerThread =
static_cast<CPLWorkerThread *>(psWaitingWorkerThreadsList->pData);
CPLAssert( psWorkerThread->bMarkedAsWaiting );
psWorkerThread->bMarkedAsWaiting = false;
CPLList* psNext = psWaitingWorkerThreadsList->psNext;
CPLList* psToFree = psWaitingWorkerThreadsList;
psWaitingWorkerThreadsList = psNext;
nWaitingWorkerThreads--;
// CPLAssert(
// CPLListCount(psWaitingWorkerThreadsList) == nWaitingWorkerThreads);
#if DEBUG_VERBOSE
CPLDebug("JOB", "Waking up %p", psWorkerThread);
#endif
{
std::lock_guard<std::mutex> oGuardWT(psWorkerThread->m_mutex);
oGuard.unlock();
psWorkerThread->m_cv.notify_one();
}
CPLFree(psToFree);
}
return true;
}
/************************************************************************/
/* SubmitJobs() */
/************************************************************************/
/** Queue several jobs
*
* @param pfnFunc Function to run for the job.
* @param apData User data instances to pass to the job function.
* @return true in case of success.
*/
bool CPLWorkerThreadPool::SubmitJobs(CPLThreadFunc pfnFunc,
const std::vector<void*>& apData)
{
CPLAssert( !aWT.empty() );
std::unique_lock<std::mutex> oGuard(m_mutex);
CPLList* psJobQueueInit = psJobQueue;
bool bRet = true;
for(size_t i=0;i<apData.size();i++)
{
CPLWorkerThreadJob* psJob = static_cast<CPLWorkerThreadJob*>(
VSI_MALLOC_VERBOSE(sizeof(CPLWorkerThreadJob)));
if( psJob == nullptr )
{
bRet = false;
break;
}
psJob->pfnFunc = pfnFunc;
psJob->pData = apData[i];
CPLList* psItem =
static_cast<CPLList *>(VSI_MALLOC_VERBOSE(sizeof(CPLList)));
if( psItem == nullptr )
{
VSIFree(psJob);
bRet = false;
break;
}
psItem->pData = psJob;
psItem->psNext = psJobQueue;
psJobQueue = psItem;
nPendingJobs++;
}
if( !bRet )
{
for( CPLList* psIter = psJobQueue; psIter != psJobQueueInit; )
{
CPLList* psNext = psIter->psNext;
VSIFree(psIter->pData);
VSIFree(psIter);
nPendingJobs--;
psIter = psNext;
}
return false;
}
for(size_t i=0;i<apData.size();i++)
{
if( psWaitingWorkerThreadsList && psJobQueue )
{
CPLWorkerThread* psWorkerThread;
psWorkerThread = static_cast<CPLWorkerThread*>(psWaitingWorkerThreadsList->pData);
CPLAssert( psWorkerThread->bMarkedAsWaiting );
psWorkerThread->bMarkedAsWaiting = false;
CPLList* psNext = psWaitingWorkerThreadsList->psNext;
CPLList* psToFree = psWaitingWorkerThreadsList;
psWaitingWorkerThreadsList = psNext;
nWaitingWorkerThreads--;
// CPLAssert(
// CPLListCount(psWaitingWorkerThreadsList) ==
// nWaitingWorkerThreads);
#if DEBUG_VERBOSE
CPLDebug("JOB", "Waking up %p", psWorkerThread);
#endif
{
std::lock_guard<std::mutex> oGuardWT(psWorkerThread->m_mutex);
oGuard.unlock();
psWorkerThread->m_cv.notify_one();
}
CPLFree(psToFree);
oGuard.lock();
}
else
{
break;
}
}
return true;
}
/************************************************************************/
/* WaitCompletion() */
/************************************************************************/
/** Wait for completion of part or whole jobs.
*
* @param nMaxRemainingJobs Maximum number of pendings jobs that are allowed
* in the queue after this method has completed. Might be
* 0 to wait for all jobs.
*/
void CPLWorkerThreadPool::WaitCompletion(int nMaxRemainingJobs)
{
if( nMaxRemainingJobs < 0 )
nMaxRemainingJobs = 0;
std::unique_lock<std::mutex> oGuard(m_mutex);
while( nPendingJobs > nMaxRemainingJobs )
{
m_cv.wait(oGuard);
}
}
/************************************************************************/
/* WaitEvent() */
/************************************************************************/
/** Wait for completion of at least one job, if there are any remaining
*/
void CPLWorkerThreadPool::WaitEvent()
{
std::unique_lock<std::mutex> oGuard(m_mutex);
while( true )
{
const int nPendingJobsBefore = nPendingJobs;
if( nPendingJobsBefore == 0 )
{
break;
}
m_cv.wait(oGuard);
if( nPendingJobs < nPendingJobsBefore )
{
break;
}
}
}
/************************************************************************/
/* Setup() */
/************************************************************************/
/** Setup the pool.
*
* @param nThreads Number of threads to launch
* @param pfnInitFunc Initialization function to run in each thread. May be NULL
* @param pasInitData Array of initialization data. Its length must be nThreads,
* or it should be NULL.
* @return true if initialization was successful.
*/
bool CPLWorkerThreadPool::Setup(int nThreads,
CPLThreadFunc pfnInitFunc,
void** pasInitData)
{
return Setup(nThreads, pfnInitFunc, pasInitData, true);
}
/** Setup the pool.
*
* @param nThreads Number of threads to launch
* @param pfnInitFunc Initialization function to run in each thread. May be NULL
* @param pasInitData Array of initialization data. Its length must be nThreads,
* or it should be NULL.
* @param bWaitallStarted Whether to wait for all threads to be fully started.
* @return true if initialization was successful.
*/
bool CPLWorkerThreadPool::Setup(int nThreads,
CPLThreadFunc pfnInitFunc,
void** pasInitData,
bool bWaitallStarted)
{
CPLAssert( nThreads > 0 );
bool bRet = true;
for(int i=static_cast<int>(aWT.size());i<nThreads;i++)
{
std::unique_ptr<CPLWorkerThread> wt(new CPLWorkerThread);
wt->pfnInitFunc = pfnInitFunc;
wt->pInitData = pasInitData ? pasInitData[i] : nullptr;
wt->poTP = this;
wt->bMarkedAsWaiting = false;
wt->hThread =
CPLCreateJoinableThread(WorkerThreadFunction, wt.get());
if( wt->hThread == nullptr )
{
nThreads = i;
bRet = false;
break;
}
aWT.emplace_back(std::move(wt));
}
if( bWaitallStarted )
{
// Wait all threads to be started
std::unique_lock<std::mutex> oGuard(m_mutex);
while( nWaitingWorkerThreads < nThreads )
{
m_cv.wait(oGuard);
}
}
if( eState == CPLWTS_ERROR )
bRet = false;
return bRet;
}
/************************************************************************/
/* DeclareJobFinished() */
/************************************************************************/
void CPLWorkerThreadPool::DeclareJobFinished()
{
std::lock_guard<std::mutex> oGuard(m_mutex);
nPendingJobs --;
m_cv.notify_one();
}
/************************************************************************/
/* GetNextJob() */
/************************************************************************/
CPLWorkerThreadJob *
CPLWorkerThreadPool::GetNextJob( CPLWorkerThread* psWorkerThread )
{
while(true)
{
std::unique_lock<std::mutex> oGuard(m_mutex);
if( eState == CPLWTS_STOP )
{
return nullptr;
}
CPLList* psTopJobIter = psJobQueue;
if( psTopJobIter )
{
psJobQueue = psTopJobIter->psNext;
#if DEBUG_VERBOSE
CPLDebug("JOB", "%p got a job", psWorkerThread);
#endif
CPLWorkerThreadJob* psJob =
static_cast<CPLWorkerThreadJob*>(psTopJobIter->pData);
CPLFree(psTopJobIter);
return psJob;
}
if( !psWorkerThread->bMarkedAsWaiting )
{
psWorkerThread->bMarkedAsWaiting = true;
nWaitingWorkerThreads++;
CPLList* psItem =
static_cast<CPLList *>(VSI_MALLOC_VERBOSE(sizeof(CPLList)));
if( psItem == nullptr )
{
eState = CPLWTS_ERROR;
m_cv.notify_one();
return nullptr;
}
psItem->pData = psWorkerThread;
psItem->psNext = psWaitingWorkerThreadsList;
psWaitingWorkerThreadsList = psItem;
#if DEBUG_VERBOSE
CPLAssert(CPLListCount(psWaitingWorkerThreadsList) ==
nWaitingWorkerThreads);
#endif
}
m_cv.notify_one();
#if DEBUG_VERBOSE
CPLDebug("JOB", "%p sleeping", psWorkerThread);
#endif
std::unique_lock<std::mutex> oGuardThisThread(psWorkerThread->m_mutex);
oGuard.unlock();
psWorkerThread->m_cv.wait(oGuardThisThread);
}
}
/************************************************************************/
/* CreateJobQueue() */
/************************************************************************/
/** Create a new job queue based on this worker thread pool.
*
* The worker thread pool must remain alive while the returned object is
* itself alive.
*
* @since GDAL 3.2
*/
std::unique_ptr<CPLJobQueue> CPLWorkerThreadPool::CreateJobQueue()
{
return std::unique_ptr<CPLJobQueue>(new CPLJobQueue(this));
}
/************************************************************************/
/* CPLJobQueue() */
/************************************************************************/
//! @cond Doxygen_Suppress
CPLJobQueue::CPLJobQueue(CPLWorkerThreadPool* poPool): m_poPool(poPool) {}
//! @endcond
/************************************************************************/
/* ~CPLJobQueue() */
/************************************************************************/
CPLJobQueue::~CPLJobQueue()
{
WaitCompletion();
}
/************************************************************************/
/* JobQueueJob */
/************************************************************************/
struct JobQueueJob
{
CPLJobQueue* poQueue = nullptr;
CPLThreadFunc pfnFunc = nullptr;
void* pData = nullptr;
};
/************************************************************************/
/* JobQueueFunction() */
/************************************************************************/
void CPLJobQueue::JobQueueFunction(void* pData)
{
JobQueueJob* poJob = static_cast<JobQueueJob*>(pData);
poJob->pfnFunc(poJob->pData);
poJob->poQueue->DeclareJobFinished();
delete poJob;
}
/************************************************************************/
/* DeclareJobFinished() */
/************************************************************************/
void CPLJobQueue::DeclareJobFinished()
{
std::lock_guard<std::mutex> oGuard(m_mutex);
m_nPendingJobs --;
m_cv.notify_one();
}
/************************************************************************/
/* SubmitJob() */
/************************************************************************/
/** Queue a new job.
*
* @param pfnFunc Function to run for the job.
* @param pData User data to pass to the job function.
* @return true in case of success.
*/
bool CPLJobQueue::SubmitJob(CPLThreadFunc pfnFunc, void* pData)
{
JobQueueJob* poJob = new JobQueueJob;
poJob->poQueue = this;
poJob->pfnFunc = pfnFunc;
poJob->pData = pData;
{
std::lock_guard<std::mutex> oGuard(m_mutex);
m_nPendingJobs ++;
}
bool bRet = m_poPool->SubmitJob(JobQueueFunction, poJob);
if( !bRet )
{
delete poJob;
}
return bRet;
}
/************************************************************************/
/* WaitCompletion() */
/************************************************************************/
/** Wait for completion of part or whole jobs.
*
* @param nMaxRemainingJobs Maximum number of pendings jobs that are allowed
* in the queue after this method has completed. Might be
* 0 to wait for all jobs.
*/
void CPLJobQueue::WaitCompletion(int nMaxRemainingJobs)
{
std::unique_lock<std::mutex> oGuard(m_mutex);
while( m_nPendingJobs > nMaxRemainingJobs )
{
m_cv.wait(oGuard);
}
}
| {
"pile_set_name": "Github"
} |
class Pandocomatic < Formula
desc "Automate the use of pandoc"
homepage "https://heerdebeer.org/Software/markdown/pandocomatic/"
url "https://github.com/htdebeer/pandocomatic/archive/0.2.6.tar.gz"
sha256 "902d1c366e85c14b5a3bc0fd5247b22fde985858f8f985e368e3eb7c03324e23"
license "GPL-3.0"
bottle do
cellar :any_skip_relocation
sha256 "e8844df8b3f91e671a6734004ecb712db288adcf8952d17aa444e7cba8a29115" => :catalina
sha256 "c3e059e365bf28455fbb0db2010e09195ff01b78ca02248bb6282f7d03136be2" => :mojave
sha256 "5824fc9e4accf029a29ddc6dc31f1027d9e63d2752c316bcf941eddf75884b64" => :high_sierra
end
depends_on "pandoc"
uses_from_macos "ruby", since: :catalina
def install
ENV["GEM_HOME"] = libexec
system "gem", "build", "#{name}.gemspec"
system "gem", "install", "#{name}-#{version}.gem"
bin.install libexec/"bin/#{name}"
bin.env_script_all_files(libexec/"bin", GEM_HOME: ENV["GEM_HOME"])
end
test do
(testpath/"test.md").write <<~EOS
# Homebrew
A package manager for humans. Cats should take a look at Tigerbrew.
EOS
expected_html = <<~EOS
<h1 id="homebrew">Homebrew</h1>
<p>A package manager for humans. Cats should take a look at Tigerbrew.</p>
EOS
system "#{bin}/pandocomatic", "-i", "test.md", "-o", "test.html"
assert_equal expected_html, (testpath/"test.html").read
end
end
| {
"pile_set_name": "Github"
} |
/*
** $Id: lmem.c,v 1.91 2015/03/06 19:45:54 roberto Exp $
** Interface to Memory Manager
** See Copyright Notice in lua.h
*/
#define lmem_c
#define LUA_CORE
#include "lprefix.h"
#include <stddef.h>
#include "lua.h"
#include "ldebug.h"
#include "ldo.h"
#include "lgc.h"
#include "lmem.h"
#include "lobject.h"
#include "lstate.h"
/*
** About the realloc function:
** void * frealloc (void *ud, void *ptr, size_t osize, size_t nsize);
** ('osize' is the old size, 'nsize' is the new size)
**
** * frealloc(ud, NULL, x, s) creates a new block of size 's' (no
** matter 'x').
**
** * frealloc(ud, p, x, 0) frees the block 'p'
** (in this specific case, frealloc must return NULL);
** particularly, frealloc(ud, NULL, 0, 0) does nothing
** (which is equivalent to free(NULL) in ISO C)
**
** frealloc returns NULL if it cannot create or reallocate the area
** (any reallocation to an equal or smaller size cannot fail!)
*/
#define MINSIZEARRAY 4
void *luaM_growaux_ (lua_State *L, void *block, int *size, size_t size_elems,
int limit, const char *what) {
void *newblock;
int newsize;
if (*size >= limit/2) { /* cannot double it? */
if (*size >= limit) /* cannot grow even a little? */
luaG_runerror(L, "too many %s (limit is %d)", what, limit);
newsize = limit; /* still have at least one free place */
}
else {
newsize = (*size)*2;
if (newsize < MINSIZEARRAY)
newsize = MINSIZEARRAY; /* minimum size */
}
newblock = luaM_reallocv(L, block, *size, newsize, size_elems);
*size = newsize; /* update only when everything else is OK */
return newblock;
}
l_noret luaM_toobig (lua_State *L) {
luaG_runerror(L, "memory allocation error: block too big");
}
/*
** generic allocation routine.
*/
void *luaM_realloc_ (lua_State *L, void *block, size_t osize, size_t nsize) {
void *newblock;
global_State *g = G(L);
size_t realosize = (block) ? osize : 0;
lua_assert((realosize == 0) == (block == NULL));
#if defined(HARDMEMTESTS)
if (nsize > realosize && g->gcrunning)
luaC_fullgc(L, 1); /* force a GC whenever possible */
#endif
newblock = (*g->frealloc)(g->ud, block, osize, nsize);
if (newblock == NULL && nsize > 0) {
lua_assert(nsize > realosize); /* cannot fail when shrinking a block */
if (g->version) { /* is state fully built? */
luaC_fullgc(L, 1); /* try to free some memory... */
newblock = (*g->frealloc)(g->ud, block, osize, nsize); /* try again */
}
if (newblock == NULL)
luaD_throw(L, LUA_ERRMEM);
}
lua_assert((nsize == 0) == (newblock == NULL));
g->GCdebt = (g->GCdebt + nsize) - realosize;
return newblock;
}
| {
"pile_set_name": "Github"
} |
#training parameters
train:
loss: "xentropy" # must be either xentropy or iou
max_epochs: 1000
max_lr: 0.001 # sgd learning rate max
min_lr: 0.001 # warmup initial learning rate
up_epochs: 0 # warmup during first XX epochs (can be float)
down_epochs: 0 # warmdown during second XX epochs (can be float)
max_momentum: 0.9 # sgd momentum max when lr is mim
min_momentum: 0.9 # sgd momentum min when lr is max
final_decay: 0.99 # learning rate decay per epoch after initial cycle (from min lr)
w_decay: 0.00001 # weight decay
batch_size: 8 # batch size
report_batch: 1 # every x batches, report loss
report_epoch: 1 # every x epochs, report validation set
save_summary: False # Summary of weight histograms for tensorboard
save_imgs: True # False doesn't save anything, True saves some
# sample images (one per batch of the last calculated batch)
# in log folder
avg_N: 3 # average the N best models
crop_prop:
height: 448
width: 448
# backbone parameters
backbone:
name: "mobilenetv2"
dropout: 0.0
bn_d: 0.001
OS: 8 # output stride
train: True # train backbone?
extra:
width_mult: 1.0
shallow_feats: True # get features before the last layer (mn2)
decoder:
name: "aspp_residual_attention"
dropout: 0.0
bn_d: 0.001
train: True # train decoder?
extra:
aspp_channels: 64
skip_os: [4, 2]
last_channels: 32
# classification head parameters
head:
name: "segmentation"
dropout: 0.0
# dataset (to find parser)
dataset:
name: "coco"
location: "/cache/datasets/coco/"
workers: 12 # number of threads to get data
img_means: #rgb
- 0.47037394
- 0.44669544
- 0.40731883
img_stds: #rgb
- 0.27876515
- 0.27429348
- 0.28861644
img_prop:
width: 512
height: 512
depth: 3
labels:
0: 'nothing'
1: 'person'
2: 'bicycle'
3: 'car'
4: 'motorcycle'
5: 'airplane'
6: 'bus'
7: 'train'
8: 'truck'
9: 'boat'
10: 'traffic light'
11: 'fire hydrant'
12: 'stop sign'
13: 'parking meter'
14: 'bench'
15: 'bird'
16: 'cat'
17: 'dog'
18: 'horse'
19: 'sheep'
20: 'cow'
21: 'elephant'
22: 'bear'
23: 'zebra'
24: 'giraffe'
25: 'backpack'
26: 'umbrella'
27: 'handbag'
28: 'tie'
29: 'suitcase'
30: 'frisbee'
31: 'skis'
32: 'snowboard'
33: 'sports ball'
34: 'kite'
35: 'baseball bat'
36: 'baseball glove'
37: 'skateboard'
38: 'surfboard'
39: 'tennis racket'
40: 'bottle'
41: 'wine glass'
42: 'cup'
43: 'fork'
44: 'knife'
45: 'spoon'
46: 'bowl'
47: 'banana'
48: 'apple'
49: 'sandwich'
50: 'orange'
51: 'broccoli'
52: 'carrot'
53: 'hot dog'
54: 'pizza'
55: 'donut'
56: 'cake'
57: 'chair'
58: 'couch'
59: 'potted plant'
60: 'bed'
61: 'dining table'
62: 'toilet'
63: 'tv'
64: 'laptop'
65: 'mouse'
66: 'remote'
67: 'keyboard'
68: 'cell phone'
69: 'microwave'
70: 'oven'
71: 'toaster'
72: 'sink'
73: 'refrigerator'
74: 'book'
75: 'clock'
76: 'vase'
77: 'scissors'
78: 'teddy bear'
79: 'hair drier'
80: 'toothbrush'
81: 'banner'
82: 'blanket'
83: 'bridge'
84: 'cardboard'
85: 'counter'
86: 'curtain'
87: 'door-stuff'
88: 'floor-wood'
89: 'flower'
90: 'fruit'
91: 'gravel'
92: 'house'
93: 'light'
94: 'mirror-stuff'
95: 'net'
96: 'pillow'
97: 'platform'
98: 'playingfield'
99: 'railroad'
100: 'river'
101: 'road'
102: 'roof'
103: 'sand'
104: 'sea'
105: 'shelf'
106: 'snow'
107: 'stairs'
108: 'tent'
109: 'towel'
110: 'wall-brick'
111: 'wall-stone'
112: 'wall-tile'
113: 'wall-wood'
114: 'water-other'
115: 'window-blind'
116: 'window-other'
117: 'tree-merged'
118: 'fence-merged'
119: 'ceiling-merged'
120: 'sky-other-merged'
121: 'cabinet-merged'
122: 'table-merged'
123: 'floor-other-merged'
124: 'pavement-merged'
125: 'mountain-merged'
126: 'grass-merged'
127: 'dirt-merged'
128: 'paper-merged'
129: 'food-other-merged'
130: 'building-other-merged'
131: 'rock-merged'
132: 'wall-other-merged'
133: 'rug-merged'
labels_w:
0: 3.30289772
1: 3.44347075
2: 4.45638856
3: 4.38993873
4: 4.40558454
5: 4.43124634
6: 4.3704214
7: 4.37116607
8: 4.39089505
9: 4.43982977
10: 4.47110532
11: 4.46438403
12: 4.4641625
13: 4.47022578
14: 4.42895632
15: 4.45500307
16: 4.38707112
17: 4.4106653
18: 4.42796692
19: 4.45204959
20: 4.4401263
21: 4.40878283
22: 4.45387203
23: 4.42985916
24: 4.43098019
25: 4.46656527
26: 4.43376055
27: 4.46507904
28: 4.46901983
29: 4.43360579
30: 4.47575828
31: 4.47660484
32: 4.47609518
33: 4.47902746
34: 4.47053574
35: 4.47920049
36: 4.47851516
37: 4.47207879
38: 4.4627746
39: 4.47251257
40: 4.45219224
41: 4.46598228
42: 4.43872198
43: 4.47574847
44: 4.47361754
45: 4.47653982
46: 4.3856233
47: 4.44137513
48: 4.46232492
49: 4.42603155
50: 4.45842983
51: 4.44975287
52: 4.46772733
53: 4.46178419
54: 4.35241406
55: 4.44811407
56: 4.41883936
57: 4.38430288
58: 4.39932503
59: 4.44830829
60: 4.34076057
61: 4.12794364
62: 4.43239948
63: 4.42920318
64: 4.42674297
65: 4.4779212
66: 4.47228467
67: 4.4601095
68: 4.464409
69: 4.46698271
70: 4.43035479
71: 4.4805109
72: 4.45518222
73: 4.42609323
74: 4.44834649
75: 4.46003338
76: 4.45381149
77: 4.47562135
78: 4.43113793
79: 4.48089522
80: 4.47869317
81: 4.44563805
82: 4.46413676
83: 4.46293932
84: 4.44642236
85: 4.43632268
86: 4.40910322
87: 4.38526776
88: 4.3944411
89: 4.45029668
90: 4.46144729
91: 4.44159602
92: 4.41370389
93: 4.45954104
94: 4.42862471
95: 4.45304841
96: 4.47323538
97: 4.4488511
98: 4.21416693
99: 4.43753689
100: 4.40023077
101: 4.14827356
102: 4.45886822
103: 4.33387961
104: 4.15029549
105: 4.4377465
106: 4.19835921
107: 4.46436897
108: 4.46873253
109: 4.46950434
110: 4.39793066
111: 4.44590653
112: 4.35002018
113: 4.38429034
114: 4.41615226
115: 4.45421316
116: 4.33110842
117: 3.65425719
118: 4.26863963
119: 4.34291598
120: 3.44555095
121: 4.3511337
122: 4.26604345
123: 4.27425755
124: 4.13640191
125: 4.37059881
126: 3.90903173
127: 4.27844617
128: 4.40569505
129: 4.37009275
130: 4.04897801
131: 4.41257335
132: 3.66257514
133: 4.38268395
color_map: # bgr
0: [0, 0, 0]
1: [220, 20, 60]
2: [119, 11, 32]
3: [0, 0, 142]
4: [0, 0, 230]
5: [106, 0, 228]
6: [0, 60, 100]
7: [0, 80, 100]
8: [0, 0, 70]
9: [0, 0, 192]
10: [250, 170, 30]
11: [100, 170, 30]
12: [220, 220, 0]
13: [175, 116, 175]
14: [250, 0, 30]
15: [165, 42, 42]
16: [255, 77, 255]
17: [0, 226, 252]
18: [182, 182, 255]
19: [0, 82, 0]
20: [120, 166, 157]
21: [110, 76, 0]
22: [174, 57, 255]
23: [199, 100, 0]
24: [72, 0, 118]
25: [255, 179, 240]
26: [0, 125, 92]
27: [209, 0, 151]
28: [188, 208, 182]
29: [0, 220, 176]
30: [255, 99, 164]
31: [92, 0, 73]
32: [133, 129, 255]
33: [78, 180, 255]
34: [0, 228, 0]
35: [174, 255, 243]
36: [45, 89, 255]
37: [134, 134, 103]
38: [145, 148, 174]
39: [255, 208, 186]
40: [197, 226, 255]
41: [171, 134, 1]
42: [109, 63, 54]
43: [207, 138, 255]
44: [151, 0, 95]
45: [9, 80, 61]
46: [84, 105, 51]
47: [74, 65, 105]
48: [166, 196, 102]
49: [208, 195, 210]
50: [255, 109, 65]
51: [0, 143, 149]
52: [179, 0, 194]
53: [209, 99, 106]
54: [5, 121, 0]
55: [227, 255, 205]
56: [147, 186, 208]
57: [153, 69, 1]
58: [3, 95, 161]
59: [163, 255, 0]
60: [119, 0, 170]
61: [0, 182, 199]
62: [0, 165, 120]
63: [183, 130, 88]
64: [95, 32, 0]
65: [130, 114, 135]
66: [110, 129, 133]
67: [166, 74, 118]
68: [219, 142, 185]
69: [79, 210, 114]
70: [178, 90, 62]
71: [65, 70, 15]
72: [127, 167, 115]
73: [59, 105, 106]
74: [142, 108, 45]
75: [196, 172, 0]
76: [95, 54, 80]
77: [128, 76, 255]
78: [201, 57, 1]
79: [246, 0, 122]
80: [191, 162, 208]
81: [255, 255, 128]
82: [147, 211, 203]
83: [150, 100, 100]
84: [168, 171, 172]
85: [146, 112, 198]
86: [210, 170, 100]
87: [92, 136, 89]
88: [218, 88, 184]
89: [241, 129, 0]
90: [217, 17, 255]
91: [124, 74, 181]
92: [70, 70, 70]
93: [255, 228, 255]
94: [154, 208, 0]
95: [193, 0, 92]
96: [76, 91, 113]
97: [255, 180, 195]
98: [106, 154, 176]
99: [230, 150, 140]
100: [60, 143, 255]
101: [128, 64, 128]
102: [92, 82, 55]
103: [254, 212, 124]
104: [73, 77, 174]
105: [255, 160, 98]
106: [255, 255, 255]
107: [104, 84, 109]
108: [169, 164, 131]
109: [225, 199, 255]
110: [137, 54, 74]
111: [135, 158, 223]
112: [7, 246, 231]
113: [107, 255, 200]
114: [58, 41, 149]
115: [183, 121, 142]
116: [255, 73, 97]
117: [107, 142, 35]
118: [190, 153, 153]
119: [146, 139, 141]
120: [70, 130, 180]
121: [134, 199, 156]
122: [209, 226, 140]
123: [96, 36, 108]
124: [96, 96, 96]
125: [64, 170, 64]
126: [152, 251, 152]
127: [208, 229, 228]
128: [206, 186, 171]
129: [152, 161, 64]
130: [116, 112, 0]
131: [0, 114, 143]
132: [102, 102, 156]
133: [250, 141, 255]
| {
"pile_set_name": "Github"
} |
// Copyright 2017 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.
package http2
// A list of the possible cipher suite ids. Taken from
// https://www.iana.org/assignments/tls-parameters/tls-parameters.txt
const (
cipher_TLS_NULL_WITH_NULL_NULL uint16 = 0x0000
cipher_TLS_RSA_WITH_NULL_MD5 uint16 = 0x0001
cipher_TLS_RSA_WITH_NULL_SHA uint16 = 0x0002
cipher_TLS_RSA_EXPORT_WITH_RC4_40_MD5 uint16 = 0x0003
cipher_TLS_RSA_WITH_RC4_128_MD5 uint16 = 0x0004
cipher_TLS_RSA_WITH_RC4_128_SHA uint16 = 0x0005
cipher_TLS_RSA_EXPORT_WITH_RC2_CBC_40_MD5 uint16 = 0x0006
cipher_TLS_RSA_WITH_IDEA_CBC_SHA uint16 = 0x0007
cipher_TLS_RSA_EXPORT_WITH_DES40_CBC_SHA uint16 = 0x0008
cipher_TLS_RSA_WITH_DES_CBC_SHA uint16 = 0x0009
cipher_TLS_RSA_WITH_3DES_EDE_CBC_SHA uint16 = 0x000A
cipher_TLS_DH_DSS_EXPORT_WITH_DES40_CBC_SHA uint16 = 0x000B
cipher_TLS_DH_DSS_WITH_DES_CBC_SHA uint16 = 0x000C
cipher_TLS_DH_DSS_WITH_3DES_EDE_CBC_SHA uint16 = 0x000D
cipher_TLS_DH_RSA_EXPORT_WITH_DES40_CBC_SHA uint16 = 0x000E
cipher_TLS_DH_RSA_WITH_DES_CBC_SHA uint16 = 0x000F
cipher_TLS_DH_RSA_WITH_3DES_EDE_CBC_SHA uint16 = 0x0010
cipher_TLS_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA uint16 = 0x0011
cipher_TLS_DHE_DSS_WITH_DES_CBC_SHA uint16 = 0x0012
cipher_TLS_DHE_DSS_WITH_3DES_EDE_CBC_SHA uint16 = 0x0013
cipher_TLS_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA uint16 = 0x0014
cipher_TLS_DHE_RSA_WITH_DES_CBC_SHA uint16 = 0x0015
cipher_TLS_DHE_RSA_WITH_3DES_EDE_CBC_SHA uint16 = 0x0016
cipher_TLS_DH_anon_EXPORT_WITH_RC4_40_MD5 uint16 = 0x0017
cipher_TLS_DH_anon_WITH_RC4_128_MD5 uint16 = 0x0018
cipher_TLS_DH_anon_EXPORT_WITH_DES40_CBC_SHA uint16 = 0x0019
cipher_TLS_DH_anon_WITH_DES_CBC_SHA uint16 = 0x001A
cipher_TLS_DH_anon_WITH_3DES_EDE_CBC_SHA uint16 = 0x001B
// Reserved uint16 = 0x001C-1D
cipher_TLS_KRB5_WITH_DES_CBC_SHA uint16 = 0x001E
cipher_TLS_KRB5_WITH_3DES_EDE_CBC_SHA uint16 = 0x001F
cipher_TLS_KRB5_WITH_RC4_128_SHA uint16 = 0x0020
cipher_TLS_KRB5_WITH_IDEA_CBC_SHA uint16 = 0x0021
cipher_TLS_KRB5_WITH_DES_CBC_MD5 uint16 = 0x0022
cipher_TLS_KRB5_WITH_3DES_EDE_CBC_MD5 uint16 = 0x0023
cipher_TLS_KRB5_WITH_RC4_128_MD5 uint16 = 0x0024
cipher_TLS_KRB5_WITH_IDEA_CBC_MD5 uint16 = 0x0025
cipher_TLS_KRB5_EXPORT_WITH_DES_CBC_40_SHA uint16 = 0x0026
cipher_TLS_KRB5_EXPORT_WITH_RC2_CBC_40_SHA uint16 = 0x0027
cipher_TLS_KRB5_EXPORT_WITH_RC4_40_SHA uint16 = 0x0028
cipher_TLS_KRB5_EXPORT_WITH_DES_CBC_40_MD5 uint16 = 0x0029
cipher_TLS_KRB5_EXPORT_WITH_RC2_CBC_40_MD5 uint16 = 0x002A
cipher_TLS_KRB5_EXPORT_WITH_RC4_40_MD5 uint16 = 0x002B
cipher_TLS_PSK_WITH_NULL_SHA uint16 = 0x002C
cipher_TLS_DHE_PSK_WITH_NULL_SHA uint16 = 0x002D
cipher_TLS_RSA_PSK_WITH_NULL_SHA uint16 = 0x002E
cipher_TLS_RSA_WITH_AES_128_CBC_SHA uint16 = 0x002F
cipher_TLS_DH_DSS_WITH_AES_128_CBC_SHA uint16 = 0x0030
cipher_TLS_DH_RSA_WITH_AES_128_CBC_SHA uint16 = 0x0031
cipher_TLS_DHE_DSS_WITH_AES_128_CBC_SHA uint16 = 0x0032
cipher_TLS_DHE_RSA_WITH_AES_128_CBC_SHA uint16 = 0x0033
cipher_TLS_DH_anon_WITH_AES_128_CBC_SHA uint16 = 0x0034
cipher_TLS_RSA_WITH_AES_256_CBC_SHA uint16 = 0x0035
cipher_TLS_DH_DSS_WITH_AES_256_CBC_SHA uint16 = 0x0036
cipher_TLS_DH_RSA_WITH_AES_256_CBC_SHA uint16 = 0x0037
cipher_TLS_DHE_DSS_WITH_AES_256_CBC_SHA uint16 = 0x0038
cipher_TLS_DHE_RSA_WITH_AES_256_CBC_SHA uint16 = 0x0039
cipher_TLS_DH_anon_WITH_AES_256_CBC_SHA uint16 = 0x003A
cipher_TLS_RSA_WITH_NULL_SHA256 uint16 = 0x003B
cipher_TLS_RSA_WITH_AES_128_CBC_SHA256 uint16 = 0x003C
cipher_TLS_RSA_WITH_AES_256_CBC_SHA256 uint16 = 0x003D
cipher_TLS_DH_DSS_WITH_AES_128_CBC_SHA256 uint16 = 0x003E
cipher_TLS_DH_RSA_WITH_AES_128_CBC_SHA256 uint16 = 0x003F
cipher_TLS_DHE_DSS_WITH_AES_128_CBC_SHA256 uint16 = 0x0040
cipher_TLS_RSA_WITH_CAMELLIA_128_CBC_SHA uint16 = 0x0041
cipher_TLS_DH_DSS_WITH_CAMELLIA_128_CBC_SHA uint16 = 0x0042
cipher_TLS_DH_RSA_WITH_CAMELLIA_128_CBC_SHA uint16 = 0x0043
cipher_TLS_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA uint16 = 0x0044
cipher_TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA uint16 = 0x0045
cipher_TLS_DH_anon_WITH_CAMELLIA_128_CBC_SHA uint16 = 0x0046
// Reserved uint16 = 0x0047-4F
// Reserved uint16 = 0x0050-58
// Reserved uint16 = 0x0059-5C
// Unassigned uint16 = 0x005D-5F
// Reserved uint16 = 0x0060-66
cipher_TLS_DHE_RSA_WITH_AES_128_CBC_SHA256 uint16 = 0x0067
cipher_TLS_DH_DSS_WITH_AES_256_CBC_SHA256 uint16 = 0x0068
cipher_TLS_DH_RSA_WITH_AES_256_CBC_SHA256 uint16 = 0x0069
cipher_TLS_DHE_DSS_WITH_AES_256_CBC_SHA256 uint16 = 0x006A
cipher_TLS_DHE_RSA_WITH_AES_256_CBC_SHA256 uint16 = 0x006B
cipher_TLS_DH_anon_WITH_AES_128_CBC_SHA256 uint16 = 0x006C
cipher_TLS_DH_anon_WITH_AES_256_CBC_SHA256 uint16 = 0x006D
// Unassigned uint16 = 0x006E-83
cipher_TLS_RSA_WITH_CAMELLIA_256_CBC_SHA uint16 = 0x0084
cipher_TLS_DH_DSS_WITH_CAMELLIA_256_CBC_SHA uint16 = 0x0085
cipher_TLS_DH_RSA_WITH_CAMELLIA_256_CBC_SHA uint16 = 0x0086
cipher_TLS_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA uint16 = 0x0087
cipher_TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA uint16 = 0x0088
cipher_TLS_DH_anon_WITH_CAMELLIA_256_CBC_SHA uint16 = 0x0089
cipher_TLS_PSK_WITH_RC4_128_SHA uint16 = 0x008A
cipher_TLS_PSK_WITH_3DES_EDE_CBC_SHA uint16 = 0x008B
cipher_TLS_PSK_WITH_AES_128_CBC_SHA uint16 = 0x008C
cipher_TLS_PSK_WITH_AES_256_CBC_SHA uint16 = 0x008D
cipher_TLS_DHE_PSK_WITH_RC4_128_SHA uint16 = 0x008E
cipher_TLS_DHE_PSK_WITH_3DES_EDE_CBC_SHA uint16 = 0x008F
cipher_TLS_DHE_PSK_WITH_AES_128_CBC_SHA uint16 = 0x0090
cipher_TLS_DHE_PSK_WITH_AES_256_CBC_SHA uint16 = 0x0091
cipher_TLS_RSA_PSK_WITH_RC4_128_SHA uint16 = 0x0092
cipher_TLS_RSA_PSK_WITH_3DES_EDE_CBC_SHA uint16 = 0x0093
cipher_TLS_RSA_PSK_WITH_AES_128_CBC_SHA uint16 = 0x0094
cipher_TLS_RSA_PSK_WITH_AES_256_CBC_SHA uint16 = 0x0095
cipher_TLS_RSA_WITH_SEED_CBC_SHA uint16 = 0x0096
cipher_TLS_DH_DSS_WITH_SEED_CBC_SHA uint16 = 0x0097
cipher_TLS_DH_RSA_WITH_SEED_CBC_SHA uint16 = 0x0098
cipher_TLS_DHE_DSS_WITH_SEED_CBC_SHA uint16 = 0x0099
cipher_TLS_DHE_RSA_WITH_SEED_CBC_SHA uint16 = 0x009A
cipher_TLS_DH_anon_WITH_SEED_CBC_SHA uint16 = 0x009B
cipher_TLS_RSA_WITH_AES_128_GCM_SHA256 uint16 = 0x009C
cipher_TLS_RSA_WITH_AES_256_GCM_SHA384 uint16 = 0x009D
cipher_TLS_DHE_RSA_WITH_AES_128_GCM_SHA256 uint16 = 0x009E
cipher_TLS_DHE_RSA_WITH_AES_256_GCM_SHA384 uint16 = 0x009F
cipher_TLS_DH_RSA_WITH_AES_128_GCM_SHA256 uint16 = 0x00A0
cipher_TLS_DH_RSA_WITH_AES_256_GCM_SHA384 uint16 = 0x00A1
cipher_TLS_DHE_DSS_WITH_AES_128_GCM_SHA256 uint16 = 0x00A2
cipher_TLS_DHE_DSS_WITH_AES_256_GCM_SHA384 uint16 = 0x00A3
cipher_TLS_DH_DSS_WITH_AES_128_GCM_SHA256 uint16 = 0x00A4
cipher_TLS_DH_DSS_WITH_AES_256_GCM_SHA384 uint16 = 0x00A5
cipher_TLS_DH_anon_WITH_AES_128_GCM_SHA256 uint16 = 0x00A6
cipher_TLS_DH_anon_WITH_AES_256_GCM_SHA384 uint16 = 0x00A7
cipher_TLS_PSK_WITH_AES_128_GCM_SHA256 uint16 = 0x00A8
cipher_TLS_PSK_WITH_AES_256_GCM_SHA384 uint16 = 0x00A9
cipher_TLS_DHE_PSK_WITH_AES_128_GCM_SHA256 uint16 = 0x00AA
cipher_TLS_DHE_PSK_WITH_AES_256_GCM_SHA384 uint16 = 0x00AB
cipher_TLS_RSA_PSK_WITH_AES_128_GCM_SHA256 uint16 = 0x00AC
cipher_TLS_RSA_PSK_WITH_AES_256_GCM_SHA384 uint16 = 0x00AD
cipher_TLS_PSK_WITH_AES_128_CBC_SHA256 uint16 = 0x00AE
cipher_TLS_PSK_WITH_AES_256_CBC_SHA384 uint16 = 0x00AF
cipher_TLS_PSK_WITH_NULL_SHA256 uint16 = 0x00B0
cipher_TLS_PSK_WITH_NULL_SHA384 uint16 = 0x00B1
cipher_TLS_DHE_PSK_WITH_AES_128_CBC_SHA256 uint16 = 0x00B2
cipher_TLS_DHE_PSK_WITH_AES_256_CBC_SHA384 uint16 = 0x00B3
cipher_TLS_DHE_PSK_WITH_NULL_SHA256 uint16 = 0x00B4
cipher_TLS_DHE_PSK_WITH_NULL_SHA384 uint16 = 0x00B5
cipher_TLS_RSA_PSK_WITH_AES_128_CBC_SHA256 uint16 = 0x00B6
cipher_TLS_RSA_PSK_WITH_AES_256_CBC_SHA384 uint16 = 0x00B7
cipher_TLS_RSA_PSK_WITH_NULL_SHA256 uint16 = 0x00B8
cipher_TLS_RSA_PSK_WITH_NULL_SHA384 uint16 = 0x00B9
cipher_TLS_RSA_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0x00BA
cipher_TLS_DH_DSS_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0x00BB
cipher_TLS_DH_RSA_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0x00BC
cipher_TLS_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0x00BD
cipher_TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0x00BE
cipher_TLS_DH_anon_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0x00BF
cipher_TLS_RSA_WITH_CAMELLIA_256_CBC_SHA256 uint16 = 0x00C0
cipher_TLS_DH_DSS_WITH_CAMELLIA_256_CBC_SHA256 uint16 = 0x00C1
cipher_TLS_DH_RSA_WITH_CAMELLIA_256_CBC_SHA256 uint16 = 0x00C2
cipher_TLS_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA256 uint16 = 0x00C3
cipher_TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA256 uint16 = 0x00C4
cipher_TLS_DH_anon_WITH_CAMELLIA_256_CBC_SHA256 uint16 = 0x00C5
// Unassigned uint16 = 0x00C6-FE
cipher_TLS_EMPTY_RENEGOTIATION_INFO_SCSV uint16 = 0x00FF
// Unassigned uint16 = 0x01-55,*
cipher_TLS_FALLBACK_SCSV uint16 = 0x5600
// Unassigned uint16 = 0x5601 - 0xC000
cipher_TLS_ECDH_ECDSA_WITH_NULL_SHA uint16 = 0xC001
cipher_TLS_ECDH_ECDSA_WITH_RC4_128_SHA uint16 = 0xC002
cipher_TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA uint16 = 0xC003
cipher_TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA uint16 = 0xC004
cipher_TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA uint16 = 0xC005
cipher_TLS_ECDHE_ECDSA_WITH_NULL_SHA uint16 = 0xC006
cipher_TLS_ECDHE_ECDSA_WITH_RC4_128_SHA uint16 = 0xC007
cipher_TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA uint16 = 0xC008
cipher_TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA uint16 = 0xC009
cipher_TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA uint16 = 0xC00A
cipher_TLS_ECDH_RSA_WITH_NULL_SHA uint16 = 0xC00B
cipher_TLS_ECDH_RSA_WITH_RC4_128_SHA uint16 = 0xC00C
cipher_TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA uint16 = 0xC00D
cipher_TLS_ECDH_RSA_WITH_AES_128_CBC_SHA uint16 = 0xC00E
cipher_TLS_ECDH_RSA_WITH_AES_256_CBC_SHA uint16 = 0xC00F
cipher_TLS_ECDHE_RSA_WITH_NULL_SHA uint16 = 0xC010
cipher_TLS_ECDHE_RSA_WITH_RC4_128_SHA uint16 = 0xC011
cipher_TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA uint16 = 0xC012
cipher_TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA uint16 = 0xC013
cipher_TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA uint16 = 0xC014
cipher_TLS_ECDH_anon_WITH_NULL_SHA uint16 = 0xC015
cipher_TLS_ECDH_anon_WITH_RC4_128_SHA uint16 = 0xC016
cipher_TLS_ECDH_anon_WITH_3DES_EDE_CBC_SHA uint16 = 0xC017
cipher_TLS_ECDH_anon_WITH_AES_128_CBC_SHA uint16 = 0xC018
cipher_TLS_ECDH_anon_WITH_AES_256_CBC_SHA uint16 = 0xC019
cipher_TLS_SRP_SHA_WITH_3DES_EDE_CBC_SHA uint16 = 0xC01A
cipher_TLS_SRP_SHA_RSA_WITH_3DES_EDE_CBC_SHA uint16 = 0xC01B
cipher_TLS_SRP_SHA_DSS_WITH_3DES_EDE_CBC_SHA uint16 = 0xC01C
cipher_TLS_SRP_SHA_WITH_AES_128_CBC_SHA uint16 = 0xC01D
cipher_TLS_SRP_SHA_RSA_WITH_AES_128_CBC_SHA uint16 = 0xC01E
cipher_TLS_SRP_SHA_DSS_WITH_AES_128_CBC_SHA uint16 = 0xC01F
cipher_TLS_SRP_SHA_WITH_AES_256_CBC_SHA uint16 = 0xC020
cipher_TLS_SRP_SHA_RSA_WITH_AES_256_CBC_SHA uint16 = 0xC021
cipher_TLS_SRP_SHA_DSS_WITH_AES_256_CBC_SHA uint16 = 0xC022
cipher_TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256 uint16 = 0xC023
cipher_TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384 uint16 = 0xC024
cipher_TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256 uint16 = 0xC025
cipher_TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA384 uint16 = 0xC026
cipher_TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256 uint16 = 0xC027
cipher_TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384 uint16 = 0xC028
cipher_TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256 uint16 = 0xC029
cipher_TLS_ECDH_RSA_WITH_AES_256_CBC_SHA384 uint16 = 0xC02A
cipher_TLS_ECDHE_ECDSA_WITH_AES_128_GCM_SHA256 uint16 = 0xC02B
cipher_TLS_ECDHE_ECDSA_WITH_AES_256_GCM_SHA384 uint16 = 0xC02C
cipher_TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256 uint16 = 0xC02D
cipher_TLS_ECDH_ECDSA_WITH_AES_256_GCM_SHA384 uint16 = 0xC02E
cipher_TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 uint16 = 0xC02F
cipher_TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 uint16 = 0xC030
cipher_TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256 uint16 = 0xC031
cipher_TLS_ECDH_RSA_WITH_AES_256_GCM_SHA384 uint16 = 0xC032
cipher_TLS_ECDHE_PSK_WITH_RC4_128_SHA uint16 = 0xC033
cipher_TLS_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA uint16 = 0xC034
cipher_TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA uint16 = 0xC035
cipher_TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA uint16 = 0xC036
cipher_TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA256 uint16 = 0xC037
cipher_TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA384 uint16 = 0xC038
cipher_TLS_ECDHE_PSK_WITH_NULL_SHA uint16 = 0xC039
cipher_TLS_ECDHE_PSK_WITH_NULL_SHA256 uint16 = 0xC03A
cipher_TLS_ECDHE_PSK_WITH_NULL_SHA384 uint16 = 0xC03B
cipher_TLS_RSA_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC03C
cipher_TLS_RSA_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC03D
cipher_TLS_DH_DSS_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC03E
cipher_TLS_DH_DSS_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC03F
cipher_TLS_DH_RSA_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC040
cipher_TLS_DH_RSA_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC041
cipher_TLS_DHE_DSS_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC042
cipher_TLS_DHE_DSS_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC043
cipher_TLS_DHE_RSA_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC044
cipher_TLS_DHE_RSA_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC045
cipher_TLS_DH_anon_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC046
cipher_TLS_DH_anon_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC047
cipher_TLS_ECDHE_ECDSA_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC048
cipher_TLS_ECDHE_ECDSA_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC049
cipher_TLS_ECDH_ECDSA_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC04A
cipher_TLS_ECDH_ECDSA_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC04B
cipher_TLS_ECDHE_RSA_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC04C
cipher_TLS_ECDHE_RSA_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC04D
cipher_TLS_ECDH_RSA_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC04E
cipher_TLS_ECDH_RSA_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC04F
cipher_TLS_RSA_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC050
cipher_TLS_RSA_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC051
cipher_TLS_DHE_RSA_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC052
cipher_TLS_DHE_RSA_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC053
cipher_TLS_DH_RSA_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC054
cipher_TLS_DH_RSA_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC055
cipher_TLS_DHE_DSS_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC056
cipher_TLS_DHE_DSS_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC057
cipher_TLS_DH_DSS_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC058
cipher_TLS_DH_DSS_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC059
cipher_TLS_DH_anon_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC05A
cipher_TLS_DH_anon_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC05B
cipher_TLS_ECDHE_ECDSA_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC05C
cipher_TLS_ECDHE_ECDSA_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC05D
cipher_TLS_ECDH_ECDSA_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC05E
cipher_TLS_ECDH_ECDSA_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC05F
cipher_TLS_ECDHE_RSA_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC060
cipher_TLS_ECDHE_RSA_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC061
cipher_TLS_ECDH_RSA_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC062
cipher_TLS_ECDH_RSA_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC063
cipher_TLS_PSK_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC064
cipher_TLS_PSK_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC065
cipher_TLS_DHE_PSK_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC066
cipher_TLS_DHE_PSK_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC067
cipher_TLS_RSA_PSK_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC068
cipher_TLS_RSA_PSK_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC069
cipher_TLS_PSK_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC06A
cipher_TLS_PSK_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC06B
cipher_TLS_DHE_PSK_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC06C
cipher_TLS_DHE_PSK_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC06D
cipher_TLS_RSA_PSK_WITH_ARIA_128_GCM_SHA256 uint16 = 0xC06E
cipher_TLS_RSA_PSK_WITH_ARIA_256_GCM_SHA384 uint16 = 0xC06F
cipher_TLS_ECDHE_PSK_WITH_ARIA_128_CBC_SHA256 uint16 = 0xC070
cipher_TLS_ECDHE_PSK_WITH_ARIA_256_CBC_SHA384 uint16 = 0xC071
cipher_TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0xC072
cipher_TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 uint16 = 0xC073
cipher_TLS_ECDH_ECDSA_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0xC074
cipher_TLS_ECDH_ECDSA_WITH_CAMELLIA_256_CBC_SHA384 uint16 = 0xC075
cipher_TLS_ECDHE_RSA_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0xC076
cipher_TLS_ECDHE_RSA_WITH_CAMELLIA_256_CBC_SHA384 uint16 = 0xC077
cipher_TLS_ECDH_RSA_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0xC078
cipher_TLS_ECDH_RSA_WITH_CAMELLIA_256_CBC_SHA384 uint16 = 0xC079
cipher_TLS_RSA_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC07A
cipher_TLS_RSA_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC07B
cipher_TLS_DHE_RSA_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC07C
cipher_TLS_DHE_RSA_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC07D
cipher_TLS_DH_RSA_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC07E
cipher_TLS_DH_RSA_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC07F
cipher_TLS_DHE_DSS_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC080
cipher_TLS_DHE_DSS_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC081
cipher_TLS_DH_DSS_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC082
cipher_TLS_DH_DSS_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC083
cipher_TLS_DH_anon_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC084
cipher_TLS_DH_anon_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC085
cipher_TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC086
cipher_TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC087
cipher_TLS_ECDH_ECDSA_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC088
cipher_TLS_ECDH_ECDSA_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC089
cipher_TLS_ECDHE_RSA_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC08A
cipher_TLS_ECDHE_RSA_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC08B
cipher_TLS_ECDH_RSA_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC08C
cipher_TLS_ECDH_RSA_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC08D
cipher_TLS_PSK_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC08E
cipher_TLS_PSK_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC08F
cipher_TLS_DHE_PSK_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC090
cipher_TLS_DHE_PSK_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC091
cipher_TLS_RSA_PSK_WITH_CAMELLIA_128_GCM_SHA256 uint16 = 0xC092
cipher_TLS_RSA_PSK_WITH_CAMELLIA_256_GCM_SHA384 uint16 = 0xC093
cipher_TLS_PSK_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0xC094
cipher_TLS_PSK_WITH_CAMELLIA_256_CBC_SHA384 uint16 = 0xC095
cipher_TLS_DHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0xC096
cipher_TLS_DHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 uint16 = 0xC097
cipher_TLS_RSA_PSK_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0xC098
cipher_TLS_RSA_PSK_WITH_CAMELLIA_256_CBC_SHA384 uint16 = 0xC099
cipher_TLS_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256 uint16 = 0xC09A
cipher_TLS_ECDHE_PSK_WITH_CAMELLIA_256_CBC_SHA384 uint16 = 0xC09B
cipher_TLS_RSA_WITH_AES_128_CCM uint16 = 0xC09C
cipher_TLS_RSA_WITH_AES_256_CCM uint16 = 0xC09D
cipher_TLS_DHE_RSA_WITH_AES_128_CCM uint16 = 0xC09E
cipher_TLS_DHE_RSA_WITH_AES_256_CCM uint16 = 0xC09F
cipher_TLS_RSA_WITH_AES_128_CCM_8 uint16 = 0xC0A0
cipher_TLS_RSA_WITH_AES_256_CCM_8 uint16 = 0xC0A1
cipher_TLS_DHE_RSA_WITH_AES_128_CCM_8 uint16 = 0xC0A2
cipher_TLS_DHE_RSA_WITH_AES_256_CCM_8 uint16 = 0xC0A3
cipher_TLS_PSK_WITH_AES_128_CCM uint16 = 0xC0A4
cipher_TLS_PSK_WITH_AES_256_CCM uint16 = 0xC0A5
cipher_TLS_DHE_PSK_WITH_AES_128_CCM uint16 = 0xC0A6
cipher_TLS_DHE_PSK_WITH_AES_256_CCM uint16 = 0xC0A7
cipher_TLS_PSK_WITH_AES_128_CCM_8 uint16 = 0xC0A8
cipher_TLS_PSK_WITH_AES_256_CCM_8 uint16 = 0xC0A9
cipher_TLS_PSK_DHE_WITH_AES_128_CCM_8 uint16 = 0xC0AA
cipher_TLS_PSK_DHE_WITH_AES_256_CCM_8 uint16 = 0xC0AB
cipher_TLS_ECDHE_ECDSA_WITH_AES_128_CCM uint16 = 0xC0AC
cipher_TLS_ECDHE_ECDSA_WITH_AES_256_CCM uint16 = 0xC0AD
cipher_TLS_ECDHE_ECDSA_WITH_AES_128_CCM_8 uint16 = 0xC0AE
cipher_TLS_ECDHE_ECDSA_WITH_AES_256_CCM_8 uint16 = 0xC0AF
// Unassigned uint16 = 0xC0B0-FF
// Unassigned uint16 = 0xC1-CB,*
// Unassigned uint16 = 0xCC00-A7
cipher_TLS_ECDHE_RSA_WITH_CHACHA20_POLY1305_SHA256 uint16 = 0xCCA8
cipher_TLS_ECDHE_ECDSA_WITH_CHACHA20_POLY1305_SHA256 uint16 = 0xCCA9
cipher_TLS_DHE_RSA_WITH_CHACHA20_POLY1305_SHA256 uint16 = 0xCCAA
cipher_TLS_PSK_WITH_CHACHA20_POLY1305_SHA256 uint16 = 0xCCAB
cipher_TLS_ECDHE_PSK_WITH_CHACHA20_POLY1305_SHA256 uint16 = 0xCCAC
cipher_TLS_DHE_PSK_WITH_CHACHA20_POLY1305_SHA256 uint16 = 0xCCAD
cipher_TLS_RSA_PSK_WITH_CHACHA20_POLY1305_SHA256 uint16 = 0xCCAE
)
// isBadCipher reports whether the cipher is blacklisted by the HTTP/2 spec.
// References:
// https://tools.ietf.org/html/rfc7540#appendix-A
// Reject cipher suites from Appendix A.
// "This list includes those cipher suites that do not
// offer an ephemeral key exchange and those that are
// based on the TLS null, stream or block cipher type"
func isBadCipher(cipher uint16) bool {
switch cipher {
case cipher_TLS_NULL_WITH_NULL_NULL,
cipher_TLS_RSA_WITH_NULL_MD5,
cipher_TLS_RSA_WITH_NULL_SHA,
cipher_TLS_RSA_EXPORT_WITH_RC4_40_MD5,
cipher_TLS_RSA_WITH_RC4_128_MD5,
cipher_TLS_RSA_WITH_RC4_128_SHA,
cipher_TLS_RSA_EXPORT_WITH_RC2_CBC_40_MD5,
cipher_TLS_RSA_WITH_IDEA_CBC_SHA,
cipher_TLS_RSA_EXPORT_WITH_DES40_CBC_SHA,
cipher_TLS_RSA_WITH_DES_CBC_SHA,
cipher_TLS_RSA_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_DH_DSS_EXPORT_WITH_DES40_CBC_SHA,
cipher_TLS_DH_DSS_WITH_DES_CBC_SHA,
cipher_TLS_DH_DSS_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_DH_RSA_EXPORT_WITH_DES40_CBC_SHA,
cipher_TLS_DH_RSA_WITH_DES_CBC_SHA,
cipher_TLS_DH_RSA_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_DHE_DSS_EXPORT_WITH_DES40_CBC_SHA,
cipher_TLS_DHE_DSS_WITH_DES_CBC_SHA,
cipher_TLS_DHE_DSS_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_DHE_RSA_EXPORT_WITH_DES40_CBC_SHA,
cipher_TLS_DHE_RSA_WITH_DES_CBC_SHA,
cipher_TLS_DHE_RSA_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_DH_anon_EXPORT_WITH_RC4_40_MD5,
cipher_TLS_DH_anon_WITH_RC4_128_MD5,
cipher_TLS_DH_anon_EXPORT_WITH_DES40_CBC_SHA,
cipher_TLS_DH_anon_WITH_DES_CBC_SHA,
cipher_TLS_DH_anon_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_KRB5_WITH_DES_CBC_SHA,
cipher_TLS_KRB5_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_KRB5_WITH_RC4_128_SHA,
cipher_TLS_KRB5_WITH_IDEA_CBC_SHA,
cipher_TLS_KRB5_WITH_DES_CBC_MD5,
cipher_TLS_KRB5_WITH_3DES_EDE_CBC_MD5,
cipher_TLS_KRB5_WITH_RC4_128_MD5,
cipher_TLS_KRB5_WITH_IDEA_CBC_MD5,
cipher_TLS_KRB5_EXPORT_WITH_DES_CBC_40_SHA,
cipher_TLS_KRB5_EXPORT_WITH_RC2_CBC_40_SHA,
cipher_TLS_KRB5_EXPORT_WITH_RC4_40_SHA,
cipher_TLS_KRB5_EXPORT_WITH_DES_CBC_40_MD5,
cipher_TLS_KRB5_EXPORT_WITH_RC2_CBC_40_MD5,
cipher_TLS_KRB5_EXPORT_WITH_RC4_40_MD5,
cipher_TLS_PSK_WITH_NULL_SHA,
cipher_TLS_DHE_PSK_WITH_NULL_SHA,
cipher_TLS_RSA_PSK_WITH_NULL_SHA,
cipher_TLS_RSA_WITH_AES_128_CBC_SHA,
cipher_TLS_DH_DSS_WITH_AES_128_CBC_SHA,
cipher_TLS_DH_RSA_WITH_AES_128_CBC_SHA,
cipher_TLS_DHE_DSS_WITH_AES_128_CBC_SHA,
cipher_TLS_DHE_RSA_WITH_AES_128_CBC_SHA,
cipher_TLS_DH_anon_WITH_AES_128_CBC_SHA,
cipher_TLS_RSA_WITH_AES_256_CBC_SHA,
cipher_TLS_DH_DSS_WITH_AES_256_CBC_SHA,
cipher_TLS_DH_RSA_WITH_AES_256_CBC_SHA,
cipher_TLS_DHE_DSS_WITH_AES_256_CBC_SHA,
cipher_TLS_DHE_RSA_WITH_AES_256_CBC_SHA,
cipher_TLS_DH_anon_WITH_AES_256_CBC_SHA,
cipher_TLS_RSA_WITH_NULL_SHA256,
cipher_TLS_RSA_WITH_AES_128_CBC_SHA256,
cipher_TLS_RSA_WITH_AES_256_CBC_SHA256,
cipher_TLS_DH_DSS_WITH_AES_128_CBC_SHA256,
cipher_TLS_DH_RSA_WITH_AES_128_CBC_SHA256,
cipher_TLS_DHE_DSS_WITH_AES_128_CBC_SHA256,
cipher_TLS_RSA_WITH_CAMELLIA_128_CBC_SHA,
cipher_TLS_DH_DSS_WITH_CAMELLIA_128_CBC_SHA,
cipher_TLS_DH_RSA_WITH_CAMELLIA_128_CBC_SHA,
cipher_TLS_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA,
cipher_TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA,
cipher_TLS_DH_anon_WITH_CAMELLIA_128_CBC_SHA,
cipher_TLS_DHE_RSA_WITH_AES_128_CBC_SHA256,
cipher_TLS_DH_DSS_WITH_AES_256_CBC_SHA256,
cipher_TLS_DH_RSA_WITH_AES_256_CBC_SHA256,
cipher_TLS_DHE_DSS_WITH_AES_256_CBC_SHA256,
cipher_TLS_DHE_RSA_WITH_AES_256_CBC_SHA256,
cipher_TLS_DH_anon_WITH_AES_128_CBC_SHA256,
cipher_TLS_DH_anon_WITH_AES_256_CBC_SHA256,
cipher_TLS_RSA_WITH_CAMELLIA_256_CBC_SHA,
cipher_TLS_DH_DSS_WITH_CAMELLIA_256_CBC_SHA,
cipher_TLS_DH_RSA_WITH_CAMELLIA_256_CBC_SHA,
cipher_TLS_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA,
cipher_TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA,
cipher_TLS_DH_anon_WITH_CAMELLIA_256_CBC_SHA,
cipher_TLS_PSK_WITH_RC4_128_SHA,
cipher_TLS_PSK_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_PSK_WITH_AES_128_CBC_SHA,
cipher_TLS_PSK_WITH_AES_256_CBC_SHA,
cipher_TLS_DHE_PSK_WITH_RC4_128_SHA,
cipher_TLS_DHE_PSK_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_DHE_PSK_WITH_AES_128_CBC_SHA,
cipher_TLS_DHE_PSK_WITH_AES_256_CBC_SHA,
cipher_TLS_RSA_PSK_WITH_RC4_128_SHA,
cipher_TLS_RSA_PSK_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_RSA_PSK_WITH_AES_128_CBC_SHA,
cipher_TLS_RSA_PSK_WITH_AES_256_CBC_SHA,
cipher_TLS_RSA_WITH_SEED_CBC_SHA,
cipher_TLS_DH_DSS_WITH_SEED_CBC_SHA,
cipher_TLS_DH_RSA_WITH_SEED_CBC_SHA,
cipher_TLS_DHE_DSS_WITH_SEED_CBC_SHA,
cipher_TLS_DHE_RSA_WITH_SEED_CBC_SHA,
cipher_TLS_DH_anon_WITH_SEED_CBC_SHA,
cipher_TLS_RSA_WITH_AES_128_GCM_SHA256,
cipher_TLS_RSA_WITH_AES_256_GCM_SHA384,
cipher_TLS_DH_RSA_WITH_AES_128_GCM_SHA256,
cipher_TLS_DH_RSA_WITH_AES_256_GCM_SHA384,
cipher_TLS_DH_DSS_WITH_AES_128_GCM_SHA256,
cipher_TLS_DH_DSS_WITH_AES_256_GCM_SHA384,
cipher_TLS_DH_anon_WITH_AES_128_GCM_SHA256,
cipher_TLS_DH_anon_WITH_AES_256_GCM_SHA384,
cipher_TLS_PSK_WITH_AES_128_GCM_SHA256,
cipher_TLS_PSK_WITH_AES_256_GCM_SHA384,
cipher_TLS_RSA_PSK_WITH_AES_128_GCM_SHA256,
cipher_TLS_RSA_PSK_WITH_AES_256_GCM_SHA384,
cipher_TLS_PSK_WITH_AES_128_CBC_SHA256,
cipher_TLS_PSK_WITH_AES_256_CBC_SHA384,
cipher_TLS_PSK_WITH_NULL_SHA256,
cipher_TLS_PSK_WITH_NULL_SHA384,
cipher_TLS_DHE_PSK_WITH_AES_128_CBC_SHA256,
cipher_TLS_DHE_PSK_WITH_AES_256_CBC_SHA384,
cipher_TLS_DHE_PSK_WITH_NULL_SHA256,
cipher_TLS_DHE_PSK_WITH_NULL_SHA384,
cipher_TLS_RSA_PSK_WITH_AES_128_CBC_SHA256,
cipher_TLS_RSA_PSK_WITH_AES_256_CBC_SHA384,
cipher_TLS_RSA_PSK_WITH_NULL_SHA256,
cipher_TLS_RSA_PSK_WITH_NULL_SHA384,
cipher_TLS_RSA_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_DH_DSS_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_DH_RSA_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_DHE_DSS_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_DHE_RSA_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_DH_anon_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_RSA_WITH_CAMELLIA_256_CBC_SHA256,
cipher_TLS_DH_DSS_WITH_CAMELLIA_256_CBC_SHA256,
cipher_TLS_DH_RSA_WITH_CAMELLIA_256_CBC_SHA256,
cipher_TLS_DHE_DSS_WITH_CAMELLIA_256_CBC_SHA256,
cipher_TLS_DHE_RSA_WITH_CAMELLIA_256_CBC_SHA256,
cipher_TLS_DH_anon_WITH_CAMELLIA_256_CBC_SHA256,
cipher_TLS_EMPTY_RENEGOTIATION_INFO_SCSV,
cipher_TLS_ECDH_ECDSA_WITH_NULL_SHA,
cipher_TLS_ECDH_ECDSA_WITH_RC4_128_SHA,
cipher_TLS_ECDH_ECDSA_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA,
cipher_TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA,
cipher_TLS_ECDHE_ECDSA_WITH_NULL_SHA,
cipher_TLS_ECDHE_ECDSA_WITH_RC4_128_SHA,
cipher_TLS_ECDHE_ECDSA_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA,
cipher_TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA,
cipher_TLS_ECDH_RSA_WITH_NULL_SHA,
cipher_TLS_ECDH_RSA_WITH_RC4_128_SHA,
cipher_TLS_ECDH_RSA_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_ECDH_RSA_WITH_AES_128_CBC_SHA,
cipher_TLS_ECDH_RSA_WITH_AES_256_CBC_SHA,
cipher_TLS_ECDHE_RSA_WITH_NULL_SHA,
cipher_TLS_ECDHE_RSA_WITH_RC4_128_SHA,
cipher_TLS_ECDHE_RSA_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA,
cipher_TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA,
cipher_TLS_ECDH_anon_WITH_NULL_SHA,
cipher_TLS_ECDH_anon_WITH_RC4_128_SHA,
cipher_TLS_ECDH_anon_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_ECDH_anon_WITH_AES_128_CBC_SHA,
cipher_TLS_ECDH_anon_WITH_AES_256_CBC_SHA,
cipher_TLS_SRP_SHA_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_SRP_SHA_RSA_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_SRP_SHA_DSS_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_SRP_SHA_WITH_AES_128_CBC_SHA,
cipher_TLS_SRP_SHA_RSA_WITH_AES_128_CBC_SHA,
cipher_TLS_SRP_SHA_DSS_WITH_AES_128_CBC_SHA,
cipher_TLS_SRP_SHA_WITH_AES_256_CBC_SHA,
cipher_TLS_SRP_SHA_RSA_WITH_AES_256_CBC_SHA,
cipher_TLS_SRP_SHA_DSS_WITH_AES_256_CBC_SHA,
cipher_TLS_ECDHE_ECDSA_WITH_AES_128_CBC_SHA256,
cipher_TLS_ECDHE_ECDSA_WITH_AES_256_CBC_SHA384,
cipher_TLS_ECDH_ECDSA_WITH_AES_128_CBC_SHA256,
cipher_TLS_ECDH_ECDSA_WITH_AES_256_CBC_SHA384,
cipher_TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256,
cipher_TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384,
cipher_TLS_ECDH_RSA_WITH_AES_128_CBC_SHA256,
cipher_TLS_ECDH_RSA_WITH_AES_256_CBC_SHA384,
cipher_TLS_ECDH_ECDSA_WITH_AES_128_GCM_SHA256,
cipher_TLS_ECDH_ECDSA_WITH_AES_256_GCM_SHA384,
cipher_TLS_ECDH_RSA_WITH_AES_128_GCM_SHA256,
cipher_TLS_ECDH_RSA_WITH_AES_256_GCM_SHA384,
cipher_TLS_ECDHE_PSK_WITH_RC4_128_SHA,
cipher_TLS_ECDHE_PSK_WITH_3DES_EDE_CBC_SHA,
cipher_TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA,
cipher_TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA,
cipher_TLS_ECDHE_PSK_WITH_AES_128_CBC_SHA256,
cipher_TLS_ECDHE_PSK_WITH_AES_256_CBC_SHA384,
cipher_TLS_ECDHE_PSK_WITH_NULL_SHA,
cipher_TLS_ECDHE_PSK_WITH_NULL_SHA256,
cipher_TLS_ECDHE_PSK_WITH_NULL_SHA384,
cipher_TLS_RSA_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_RSA_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_DH_DSS_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_DH_DSS_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_DH_RSA_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_DH_RSA_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_DHE_DSS_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_DHE_DSS_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_DHE_RSA_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_DHE_RSA_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_DH_anon_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_DH_anon_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_ECDHE_ECDSA_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_ECDHE_ECDSA_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_ECDH_ECDSA_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_ECDH_ECDSA_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_ECDHE_RSA_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_ECDHE_RSA_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_ECDH_RSA_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_ECDH_RSA_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_RSA_WITH_ARIA_128_GCM_SHA256,
cipher_TLS_RSA_WITH_ARIA_256_GCM_SHA384,
cipher_TLS_DH_RSA_WITH_ARIA_128_GCM_SHA256,
cipher_TLS_DH_RSA_WITH_ARIA_256_GCM_SHA384,
cipher_TLS_DH_DSS_WITH_ARIA_128_GCM_SHA256,
cipher_TLS_DH_DSS_WITH_ARIA_256_GCM_SHA384,
cipher_TLS_DH_anon_WITH_ARIA_128_GCM_SHA256,
cipher_TLS_DH_anon_WITH_ARIA_256_GCM_SHA384,
cipher_TLS_ECDH_ECDSA_WITH_ARIA_128_GCM_SHA256,
cipher_TLS_ECDH_ECDSA_WITH_ARIA_256_GCM_SHA384,
cipher_TLS_ECDH_RSA_WITH_ARIA_128_GCM_SHA256,
cipher_TLS_ECDH_RSA_WITH_ARIA_256_GCM_SHA384,
cipher_TLS_PSK_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_PSK_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_DHE_PSK_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_DHE_PSK_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_RSA_PSK_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_RSA_PSK_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_PSK_WITH_ARIA_128_GCM_SHA256,
cipher_TLS_PSK_WITH_ARIA_256_GCM_SHA384,
cipher_TLS_RSA_PSK_WITH_ARIA_128_GCM_SHA256,
cipher_TLS_RSA_PSK_WITH_ARIA_256_GCM_SHA384,
cipher_TLS_ECDHE_PSK_WITH_ARIA_128_CBC_SHA256,
cipher_TLS_ECDHE_PSK_WITH_ARIA_256_CBC_SHA384,
cipher_TLS_ECDHE_ECDSA_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_ECDHE_ECDSA_WITH_CAMELLIA_256_CBC_SHA384,
cipher_TLS_ECDH_ECDSA_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_ECDH_ECDSA_WITH_CAMELLIA_256_CBC_SHA384,
cipher_TLS_ECDHE_RSA_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_ECDHE_RSA_WITH_CAMELLIA_256_CBC_SHA384,
cipher_TLS_ECDH_RSA_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_ECDH_RSA_WITH_CAMELLIA_256_CBC_SHA384,
cipher_TLS_RSA_WITH_CAMELLIA_128_GCM_SHA256,
cipher_TLS_RSA_WITH_CAMELLIA_256_GCM_SHA384,
cipher_TLS_DH_RSA_WITH_CAMELLIA_128_GCM_SHA256,
cipher_TLS_DH_RSA_WITH_CAMELLIA_256_GCM_SHA384,
cipher_TLS_DH_DSS_WITH_CAMELLIA_128_GCM_SHA256,
cipher_TLS_DH_DSS_WITH_CAMELLIA_256_GCM_SHA384,
cipher_TLS_DH_anon_WITH_CAMELLIA_128_GCM_SHA256,
cipher_TLS_DH_anon_WITH_CAMELLIA_256_GCM_SHA384,
cipher_TLS_ECDH_ECDSA_WITH_CAMELLIA_128_GCM_SHA256,
cipher_TLS_ECDH_ECDSA_WITH_CAMELLIA_256_GCM_SHA384,
cipher_TLS_ECDH_RSA_WITH_CAMELLIA_128_GCM_SHA256,
cipher_TLS_ECDH_RSA_WITH_CAMELLIA_256_GCM_SHA384,
cipher_TLS_PSK_WITH_CAMELLIA_128_GCM_SHA256,
cipher_TLS_PSK_WITH_CAMELLIA_256_GCM_SHA384,
cipher_TLS_RSA_PSK_WITH_CAMELLIA_128_GCM_SHA256,
cipher_TLS_RSA_PSK_WITH_CAMELLIA_256_GCM_SHA384,
cipher_TLS_PSK_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_PSK_WITH_CAMELLIA_256_CBC_SHA384,
cipher_TLS_DHE_PSK_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_DHE_PSK_WITH_CAMELLIA_256_CBC_SHA384,
cipher_TLS_RSA_PSK_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_RSA_PSK_WITH_CAMELLIA_256_CBC_SHA384,
cipher_TLS_ECDHE_PSK_WITH_CAMELLIA_128_CBC_SHA256,
cipher_TLS_ECDHE_PSK_WITH_CAMELLIA_256_CBC_SHA384,
cipher_TLS_RSA_WITH_AES_128_CCM,
cipher_TLS_RSA_WITH_AES_256_CCM,
cipher_TLS_RSA_WITH_AES_128_CCM_8,
cipher_TLS_RSA_WITH_AES_256_CCM_8,
cipher_TLS_PSK_WITH_AES_128_CCM,
cipher_TLS_PSK_WITH_AES_256_CCM,
cipher_TLS_PSK_WITH_AES_128_CCM_8,
cipher_TLS_PSK_WITH_AES_256_CCM_8:
return true
default:
return false
}
}
| {
"pile_set_name": "Github"
} |
--CREATE DATABASE BLToolkitData ON PRIMARY
--(NAME=N'BLToolkitTest', FILENAME=N'C:\Data\MSSQL.1\MSSQL\DATA\BLToolkitData.mdf', SIZE=3072KB, FILEGROWTH=1024KB)
--LOG ON
--(NAME=N'BLToolkitTest_log', FILENAME=N'C:\Data\MSSQL.1\MSSQL\DATA\BLToolkitData_log.ldf', SIZE=1024KB, FILEGROWTH=10%)
--GO
IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID('Doctor') AND type in (N'U'))
BEGIN DROP TABLE Doctor END
IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID('Patient') AND type in (N'U'))
BEGIN DROP TABLE Patient END
-- Person Table
IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID('Person') AND type in (N'U'))
BEGIN DROP TABLE Person END
CREATE TABLE Person
(
PersonID int NOT NULL IDENTITY(1,1) CONSTRAINT PK_Person PRIMARY KEY CLUSTERED,
FirstName nvarchar(50) NOT NULL,
LastName nvarchar(50) NOT NULL,
MiddleName nvarchar(50) NULL,
Gender char(1) NOT NULL CONSTRAINT CK_Person_Gender CHECK (Gender in ('M', 'F', 'U', 'O'))
)
ON [PRIMARY]
GO
INSERT INTO Person (FirstName, LastName, Gender) VALUES ('John', 'Pupkin', 'M')
GO
INSERT INTO Person (FirstName, LastName, Gender) VALUES ('Tester', 'Testerson', 'M')
GO
-- Doctor Table Extension
CREATE TABLE Doctor
(
PersonID int NOT NULL
CONSTRAINT PK_Doctor PRIMARY KEY CLUSTERED
CONSTRAINT FK_Doctor_Person FOREIGN KEY
REFERENCES Person ([PersonID])
ON UPDATE CASCADE
ON DELETE CASCADE,
Taxonomy nvarchar(50) NOT NULL
)
ON [PRIMARY]
GO
INSERT INTO Doctor (PersonID, Taxonomy) VALUES (1, 'Psychiatry')
GO
-- Patient Table Extension
CREATE TABLE Patient
(
PersonID int NOT NULL
CONSTRAINT PK_Patient PRIMARY KEY CLUSTERED
CONSTRAINT FK_Patient_Person FOREIGN KEY
REFERENCES Person ([PersonID])
ON UPDATE CASCADE
ON DELETE CASCADE,
Diagnosis nvarchar(256) NOT NULL
)
ON [PRIMARY]
GO
INSERT INTO Patient (PersonID, Diagnosis) VALUES (2, 'Hallucination with Paranoid Bugs'' Delirium of Persecution')
GO
-- Person_SelectByKey
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Person_SelectByKey')
BEGIN DROP Procedure Person_SelectByKey
END
GO
CREATE Procedure Person_SelectByKey
@id int
AS
SELECT * FROM Person WHERE PersonID = @id
GO
GRANT EXEC ON Person_SelectByKey TO PUBLIC
GO
-- Person_SelectAll
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Person_SelectAll')
BEGIN DROP Procedure Person_SelectAll END
GO
CREATE Procedure Person_SelectAll
AS
SELECT * FROM Person
GO
GRANT EXEC ON Person_SelectAll TO PUBLIC
GO
-- Person_SelectByName
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Person_SelectByName')
BEGIN DROP Procedure Person_SelectByName END
GO
CREATE Procedure Person_SelectByName
@firstName nvarchar(50),
@lastName nvarchar(50)
AS
SELECT
*
FROM
Person
WHERE
FirstName = @firstName AND LastName = @lastName
GO
GRANT EXEC ON Person_SelectByName TO PUBLIC
GO
-- Person_SelectListByName
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Person_SelectListByName')
BEGIN DROP Procedure Person_SelectListByName
END
GO
CREATE Procedure Person_SelectListByName
@firstName nvarchar(50),
@lastName nvarchar(50)
AS
SELECT
*
FROM
Person
WHERE
FirstName like @firstName AND LastName like @lastName
GO
GRANT EXEC ON Person_SelectByName TO PUBLIC
GO
-- Person_Insert
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Person_Insert')
BEGIN DROP Procedure Person_Insert END
GO
CREATE Procedure Person_Insert
@FirstName nvarchar(50),
@LastName nvarchar(50),
@MiddleName nvarchar(50),
@Gender char(1)
AS
INSERT INTO Person
( LastName, FirstName, MiddleName, Gender)
VALUES
(@LastName, @FirstName, @MiddleName, @Gender)
SELECT Cast(SCOPE_IDENTITY() as int) PersonID
GO
GRANT EXEC ON Person_Insert TO PUBLIC
GO
-- Person_Insert_OutputParameter
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Person_Insert_OutputParameter')
BEGIN DROP Procedure Person_Insert_OutputParameter END
GO
CREATE Procedure Person_Insert_OutputParameter
@FirstName nvarchar(50),
@LastName nvarchar(50),
@MiddleName nvarchar(50),
@Gender char(1),
@PersonID int output
AS
INSERT INTO Person
( LastName, FirstName, MiddleName, Gender)
VALUES
(@LastName, @FirstName, @MiddleName, @Gender)
SET @PersonID = Cast(SCOPE_IDENTITY() as int)
GO
GRANT EXEC ON Person_Insert_OutputParameter TO PUBLIC
GO
-- Person_Update
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Person_Update')
BEGIN DROP Procedure Person_Update END
GO
CREATE Procedure Person_Update
@PersonID int,
@FirstName nvarchar(50),
@LastName nvarchar(50),
@MiddleName nvarchar(50),
@Gender char(1)
AS
UPDATE
Person
SET
LastName = @LastName,
FirstName = @FirstName,
MiddleName = @MiddleName,
Gender = @Gender
WHERE
PersonID = @PersonID
GO
GRANT EXEC ON Person_Update TO PUBLIC
GO
-- Person_Delete
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Person_Delete')
BEGIN DROP Procedure Person_Delete END
GO
CREATE Procedure Person_Delete
@PersonID int
AS
DELETE FROM Person WHERE PersonID = @PersonID
GO
GRANT EXEC ON Person_Delete TO PUBLIC
GO
-- Patient_SelectAll
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Patient_SelectAll')
BEGIN DROP Procedure Patient_SelectAll END
GO
CREATE Procedure Patient_SelectAll
AS
SELECT
Person.*, Patient.Diagnosis
FROM
Patient, Person
WHERE
Patient.PersonID = Person.PersonID
GO
GRANT EXEC ON Patient_SelectAll TO PUBLIC
GO
-- Patient_SelectByName
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Patient_SelectByName')
BEGIN DROP Procedure Patient_SelectByName END
GO
CREATE Procedure Patient_SelectByName
@firstName nvarchar(50),
@lastName nvarchar(50)
AS
SELECT
Person.*, Patient.Diagnosis
FROM
Patient, Person
WHERE
Patient.PersonID = Person.PersonID
AND FirstName = @firstName AND LastName = @lastName
GO
GRANT EXEC ON Person_SelectByName TO PUBLIC
GO
-- BinaryData Table
IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID('BinaryData') AND type in (N'U'))
BEGIN DROP TABLE BinaryData END
CREATE TABLE BinaryData
(
BinaryDataID int NOT NULL IDENTITY(1,1) CONSTRAINT PK_BinaryData PRIMARY KEY CLUSTERED,
Stamp timestamp NOT NULL,
Data varbinary(1024) NOT NULL)
ON [PRIMARY]
GO
-- OutRefTest
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'OutRefTest')
BEGIN DROP Procedure OutRefTest END
GO
CREATE Procedure OutRefTest
@ID int,
@outputID int output,
@inputOutputID int output,
@str varchar(50),
@outputStr varchar(50) output,
@inputOutputStr varchar(50) output
AS
SET @outputID = @ID
SET @inputOutputID = @ID + @inputOutputID
SET @outputStr = @str
SET @inputOutputStr = @str + @inputOutputStr
GO
-- OutRefEnumTest
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'OutRefEnumTest')
BEGIN DROP Procedure OutRefEnumTest END
GO
CREATE Procedure OutRefEnumTest
@str varchar(50),
@outputStr varchar(50) output,
@inputOutputStr varchar(50) output
AS
SET @outputStr = @str
SET @inputOutputStr = @str + @inputOutputStr
GO
-- ExecuteScalarTest
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Scalar_DataReader')
BEGIN DROP Procedure Scalar_DataReader END
GO
CREATE Procedure Scalar_DataReader
AS
SELECT Cast(12345 as int) AS intField, Cast('54321' as varchar(50)) AS stringField
GO
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'Scalar_OutputParameter')
BEGIN DROP Procedure Scalar_OutputParameter END
GO
CREATE Procedure Scalar_OutputParameter
@outputInt int = 0 output,
@outputString varchar(50) = '' output
AS
BEGIN
SET @outputInt = 12345
SET @outputString = '54321'
END
GO
IF EXISTS (SELECT * FROM sys.objects WHERE type in (N'FN', N'IF', N'TF', N'FS', N'FT') AND name = 'Scalar_ReturnParameter')
BEGIN DROP Function Scalar_ReturnParameter END
GO
CREATE Function Scalar_ReturnParameter()
RETURNS int
AS
BEGIN
RETURN 12345
END
GO
IF EXISTS (SELECT * FROM sys.objects WHERE type ='P' AND name = 'Scalar_ReturnParameterWithObject')
BEGIN DROP Procedure Scalar_ReturnParameterWithObject END
GO
CREATE Procedure Scalar_ReturnParameterWithObject
@id int
AS
BEGIN
SELECT * FROM Person WHERE PersonID = @id
RETURN @id
END
GO
-- Data Types test
IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID('DataTypeTest') AND type in (N'U'))
BEGIN DROP TABLE DataTypeTest END
GO
CREATE TABLE DataTypeTest
(
DataTypeID int NOT NULL IDENTITY(1,1) CONSTRAINT PK_DataType PRIMARY KEY CLUSTERED,
Binary_ binary(50) NULL,
Boolean_ bit NULL,
Byte_ tinyint NULL,
Bytes_ varbinary(50) NULL,
Char_ char(1) NULL,
DateTime_ datetime NULL,
Decimal_ decimal(20,2) NULL,
Double_ float NULL,
Guid_ uniqueidentifier NULL,
Int16_ smallint NULL,
Int32_ int NULL,
Int64_ bigint NULL,
Money_ money NULL,
SByte_ tinyint NULL,
Single_ real NULL,
Stream_ varbinary(50) NULL,
String_ nvarchar(50) NULL,
UInt16_ numeric(5) NULL,
UInt32_ numeric(10) NULL,
UInt64_ numeric(20) NULL,
Xml_ xml NULL
) ON [PRIMARY]
GO
INSERT INTO DataTypeTest
(Binary_, Boolean_, Byte_, Bytes_, Char_, DateTime_, Decimal_,
Double_, Guid_, Int16_, Int32_, Int64_, Money_, SByte_,
Single_, Stream_, String_, UInt16_, UInt32_, UInt64_, Xml_)
VALUES
( NULL, NULL, NULL, NULL, NULL, NULL, NULL,
NULL, NULL, NULL, NULL, NULL, NULL, NULL,
NULL, NULL, NULL, NULL, NULL, NULL, NULL)
GO
INSERT INTO DataTypeTest
(Binary_, Boolean_, Byte_, Bytes_, Char_, DateTime_, Decimal_,
Double_, Guid_, Int16_, Int32_, Int64_, Money_, SByte_,
Single_, Stream_, String_, UInt16_, UInt32_, UInt64_,
Xml_)
VALUES
(NewID(), 1, 255, NewID(), 'B', GetDate(), 12345.67,
1234.567, NewID(), 32767, 32768, 1000000, 12.3456, 127,
1234.123, NewID(), 'string', 32767, 32768, 200000000,
'<root><element strattr="strvalue" intattr="12345"/></root>')
GO
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'DataTypeTest_Insert')
BEGIN DROP PROCEDURE DataTypeTest_Insert END
GO
CREATE PROCEDURE DataTypeTest_Insert
@Binary_ binary(50) =null,
@Boolean_ bit =null,
@Byte_ tinyint =null,
@Bytes_ varbinary(50) =null,
@Char_ char(1) =null,
@DateTime_ datetime =null,
@Decimal_ decimal(20,2) =null,
@Double_ float =null,
@Guid_ uniqueidentifier =null,
@Int16_ smallint =null,
@Int32_ int =null,
@Int64_ bigint =null,
@Money_ money =null,
@SByte_ tinyint =null,
@Single_ real =null,
@Stream_ varbinary(50) =null,
@String_ nvarchar(50) =null,
@UInt16_ smallint =null,
@UInt32_ int =null,
@UInt64_ bigint =null,
@Xml_ xml =null
AS
INSERT INTO DataTypeTest
(Binary_, Boolean_, Byte_, Bytes_, Char_, DateTime_, Decimal_,
Double_, Guid_, Int16_, Int32_, Int64_, Money_, SByte_,
Single_, Stream_, String_, UInt16_, UInt32_, UInt64_, Xml_)
VALUES
(
@Binary_ ,
@Boolean_ ,
@Byte_ ,
@Bytes_ ,
@Char_ ,
@DateTime_ ,
@Decimal_ ,
@Double_ ,
@Guid_ ,
@Int16_ ,
@Int32_ ,
@Int64_ ,
@Money_ ,
@SByte_ ,
@Single_ ,
@Stream_ ,
@String_ ,
@UInt16_ ,
@UInt32_ ,
@UInt64_ ,
@Xml_
)
GO
-- SKIP Sql2005 BEGIN
--
-- Arrays
--
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'ArrayTest')
BEGIN DROP PROCEDURE ArrayTest END
GO
--IF EXISTS (SELECT * FROM sys.objects WHERE type = 'T' AND name = 'IntArray')
--BEGIN
DROP TYPE IntArray
--END
GO
CREATE TYPE IntArray AS TABLE
(
Num int NULL
)
GO
CREATE PROCEDURE ArrayTest
@InputIntArray IntArray READONLY
AS
BEGIN
SELECT Num * 2 FROM @InputIntArray;
END
GO
-- SKIP Sql2005 END
DROP FUNCTION GetParentByID
GO
DROP TABLE Parent
GO
DROP TABLE Child
GO
DROP TABLE GrandChild
GO
CREATE TABLE Parent (ParentID int, Value1 int)
GO
CREATE TABLE Child (ParentID int, ChildID int)
GO
CREATE TABLE GrandChild (ParentID int, ChildID int, GrandChildID int)
GO
CREATE FUNCTION GetParentByID(@id int)
RETURNS TABLE
AS
RETURN
(
SELECT * FROM Parent WHERE ParentID = @id
)
GO
IF EXISTS (SELECT * FROM sys.objects WHERE object_id = OBJECT_ID('LinqDataTypes') AND type in (N'U'))
BEGIN DROP TABLE LinqDataTypes END
GO
-- SKIP Sql2005 BEGIN
CREATE TABLE LinqDataTypes
(
ID int,
MoneyValue decimal(10,4),
DateTimeValue datetime,
DateTimeValue2 datetime2,
BoolValue bit,
GuidValue uniqueidentifier,
BinaryValue varbinary(5000),
SmallIntValue smallint,
IntValue int NULL,
BigIntValue bigint NULL,
UInt16 numeric(5, 0) NULL,
UInt32 numeric(10, 0) NULL,
UInt64 numeric(20, 0) NULL
)
GO
-- SKIP Sql2005 END
-- SKIP Sql2008 BEGIN
-- SKIP Sql2012 BEGIN
CREATE TABLE LinqDataTypes
(
ID int,
MoneyValue decimal(10,4),
DateTimeValue datetime,
DateTimeValue2 datetime,
BoolValue bit,
GuidValue uniqueidentifier,
BinaryValue varbinary(5000) NULL,
SmallIntValue smallint,
IntValue int NULL,
BigIntValue bigint NULL,
UInt16 numeric(5, 0) NULL,
UInt32 numeric(10, 0) NULL,
UInt64 numeric(20, 0) NULL
)
GO
-- SKIP Sql2012 END
-- SKIP Sql2008 END
DROP TABLE TestIdentity
GO
CREATE TABLE TestIdentity (
ID INTEGER NOT NULL IDENTITY(1,1) CONSTRAINT PK_TestIdentity PRIMARY KEY CLUSTERED,
IntValue INTEGER NULL,
StringValue NVARCHAR(50) NULL
)
GO
| {
"pile_set_name": "Github"
} |
<template>
<div id="wrapper">
<img id="logo" src="~@/assets/logo.png" alt="electron-vue">
<main>
<div class="left-side">
<span class="title">
Welcome to your new project!
</span>
<system-information></system-information>
</div>
<div class="right-side">
<div class="doc">
<div class="title">Getting Started</div>
<p>
electron-vue comes packed with detailed documentation that covers everything from
internal configurations, using the project structure, building your application,
and so much more.
</p>
<button @click="open('https://simulatedgreg.gitbooks.io/electron-vue/content/')">Read the Docs</button><br><br>
</div>
<div class="doc">
<div class="title alt">Other Documentation</div>
<button class="alt" @click="open('https://electron.atom.io/docs/')">Electron</button>
<button class="alt" @click="open('https://vuejs.org/v2/guide/')">Vue.js</button>
</div>
</div>
</main>
</div>
</template>
<script>
import SystemInformation from './LandingPage/SystemInformation'
export default {
name: 'landing-page',
components: { SystemInformation },
methods: {
open (link) {
{{#isEnabled plugins 'vue-electron'}}this.$electron{{else}}require('electron'){{/isEnabled}}.shell.openExternal(link)
}
}
}
</script>
<style>
@import url('https://fonts.googleapis.com/css?family=Source+Sans+Pro');
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
body { font-family: 'Source Sans Pro', sans-serif; }
#wrapper {
background:
radial-gradient(
ellipse at top left,
rgba(255, 255, 255, 1) 40%,
rgba(229, 229, 229, .9) 100%
);
height: 100vh;
padding: 60px 80px;
width: 100vw;
}
#logo {
height: auto;
margin-bottom: 20px;
width: 420px;
}
main {
display: flex;
justify-content: space-between;
}
main > div { flex-basis: 50%; }
.left-side {
display: flex;
flex-direction: column;
}
.welcome {
color: #555;
font-size: 23px;
margin-bottom: 10px;
}
.title {
color: #2c3e50;
font-size: 20px;
font-weight: bold;
margin-bottom: 6px;
}
.title.alt {
font-size: 18px;
margin-bottom: 10px;
}
.doc p {
color: black;
margin-bottom: 10px;
}
.doc button {
font-size: .8em;
cursor: pointer;
outline: none;
padding: 0.75em 2em;
border-radius: 2em;
display: inline-block;
color: #fff;
background-color: #4fc08d;
transition: all 0.15s ease;
box-sizing: border-box;
border: 1px solid #4fc08d;
}
.doc button.alt {
color: #42b983;
background-color: transparent;
}
</style>
| {
"pile_set_name": "Github"
} |
<?xml version="1.0" encoding="UTF-8"?>
<Workspace
version = "1.0">
<FileRef
location = "self:IOSParseXMLTutorial.xcodeproj">
</FileRef>
</Workspace>
| {
"pile_set_name": "Github"
} |
#import <XCTest/XCTest.h>
#import "JavaScriptBridge.h"
@import JavaScriptCore;
@interface JSBEventKitTests : XCTestCase
@end
@implementation JSBEventKitTests
- (void)setUp
{
[super setUp];
}
- (void)tearDown
{
[super tearDown];
}
- (void)testInstantiation
{
JSContext *context = [[JSContext alloc] init];
[context addScriptingSupport:@"EventKit"];
JSValue *value = nil;
[context evaluateScript:@"var ekeventstore = EKEventStore.new();"];
value = context[@"ekeventstore"];
XCTAssertTrue(value && !value.isUndefined);
[context evaluateScript:@"var ekrecurrencedayofweek = EKRecurrenceDayOfWeek.new();"];
value = context[@"ekrecurrencedayofweek"];
XCTAssertTrue(value && !value.isUndefined);
[context evaluateScript:@"var ekrecurrenceend = EKRecurrenceEnd.new();"];
value = context[@"ekrecurrenceend"];
XCTAssertTrue(value && !value.isUndefined);
[context evaluateScript:@"var ekalarm = EKAlarm.new();"];
value = context[@"ekalarm"];
XCTAssertTrue(value && !value.isUndefined);
[context evaluateScript:@"var ekcalendar = EKCalendar.calendarForEntityTypeEventStore(0, ekeventstore);"];
value = context[@"ekcalendar"];
XCTAssertTrue(value && !value.isUndefined);
[context evaluateScript:@"var ekcalendaritem = EKCalendarItem.new();"];
value = context[@"ekcalendaritem"];
XCTAssertTrue(value && !value.isUndefined);
[context evaluateScript:@"var ekparticipant = EKParticipant.new();"];
value = context[@"ekparticipant"];
XCTAssertTrue(value && !value.isUndefined);
[context evaluateScript:@"var ekrecurrencerule = EKRecurrenceRule.new();"];
value = context[@"ekrecurrencerule"];
XCTAssertTrue(value && !value.isUndefined);
[context evaluateScript:@"var eksource = EKSource.new();"];
value = context[@"eksource"];
XCTAssertTrue(value && !value.isUndefined);
[context evaluateScript:@"var ekstructuredlocation = EKStructuredLocation.new();"];
value = context[@"ekstructuredlocation"];
XCTAssertTrue(value && !value.isUndefined);
[context evaluateScript:@"var ekevent = EKEvent.eventWithEventStore(ekeventstore);"];
value = context[@"ekevent"];
XCTAssertTrue(value && !value.isUndefined);
[context evaluateScript:@"var ekreminder = EKReminder.reminderWithEventStore(ekeventstore);"];
value = context[@"ekreminder"];
XCTAssertTrue(value && !value.isUndefined);
}
@end
| {
"pile_set_name": "Github"
} |
[package]
name = "git-trim"
description = "Automatically trims your tracking branches whose upstream branches are merged or stray"
license = "MIT"
version = "0.4.0-alpha.4"
authors = ["SeongChan Lee <[email protected]>"]
repository = "https://github.com/foriequal0/git-trim"
readme = "README.md"
keywords = ["git", "branch", "prune", "trim"]
categories = ["command-line-utilities", "development-tools"]
edition = "2018"
build = "build.rs"
default-run = "git-trim"
[[bin]]
name = "build-man"
required-features = ["build-man"]
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[features]
build-man = ["man", "rson_rs", "regex"]
[build-dependencies]
vergen = "3"
[dependencies]
dialoguer = "0.5.0"
env_logger = "0.7.1"
git2 = "0.10"
log = "0.4.0"
paw = "1.0"
clap = { package="clap-v3", version = "~3.0.0-beta.1" }
anyhow = "1.0.26"
rayon = "1.3.0"
thiserror = "1.0"
crossbeam-channel = "0.4.3"
man = { version = "0.3.0", optional = true }
rson_rs = { version = "0.2.1", optional = true }
regex = { version = "1.3.6", optional = true }
[dev-dependencies]
tempfile = "3.1.0"
textwrap = "0.11.0"
| {
"pile_set_name": "Github"
} |
<?xml version="1.0" encoding="utf-8"?>
<topic id="22117048-bf36-4232-a81c-5ff868c2e824" revisionNumber="1">
<developerConceptualDocument
xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5"
xmlns:xlink="http://www.w3.org/1999/xlink">
<!--
<summary>
<para>Optional summary abstract</para>
</summary>
-->
<introduction>
<!-- Uncomment this to generate an outline of the section and sub-section
titles. Specify a numeric value as the inner text to limit it to
a specific number of sub-topics when creating the outline. Specify
zero (0) to limit it to top-level sections only. -->
<!-- <autoOutline /> -->
<para>Required introduction</para>
</introduction>
<!-- Add one or more top-level section elements. These are collapsible.
If using <autoOutline />, add an address attribute to identify it
and specify a title so that it can be jumped to with a hyperlink. -->
<section address="Section1">
<title>Optional section title</title>
<content>
<!-- Uncomment this to create a sub-section outline
<autoOutline /> -->
<para>Add one or more sections with content</para>
</content>
<!-- If a section contains a sections element, its content creates
sub-sections. These are not collapsible.
<sections>
<section address="SubSection1">
<title>Sub-section 1</title>
<content>
<para>Sub-section content.</para>
</content>
</section>
<section address="SubSection2">
<title>Sub-section 2</title>
<content>
<para>Sub-section content.</para>
</content>
</section>
</sections> -->
</section>
<relatedTopics>
<!-- One or more of the following:
- A local link
- An external link
- A code entity reference
<link xlink:href="Other Topic's ID"/>
<link xlink:href="Other Topic's ID">Link inner text</link>
<externalLink>
<linkText>Link text</linkText>
<linkAlternateText>Optional alternate link text</linkAlternateText>
<linkUri>URI</linkUri>
</externalLink>
<codeEntityReference>API member ID</codeEntityReference>
Examples:
<link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8270" />
<link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8278">Some other topic</link>
<externalLink>
<linkText>SHFB on GitHub</linkText>
<linkAlternateText>Go to GitHub</linkAlternateText>
<linkUri>https://GitHub.com/EWSoftware/SHFB</linkUri>
</externalLink>
<codeEntityReference>T:TestDoc.TestClass</codeEntityReference>
<codeEntityReference>P:TestDoc.TestClass.SomeProperty</codeEntityReference>
<codeEntityReference>M:TestDoc.TestClass.#ctor</codeEntityReference>
<codeEntityReference>M:TestDoc.TestClass.#ctor(System.String,System.Int32)</codeEntityReference>
<codeEntityReference>M:TestDoc.TestClass.ToString</codeEntityReference>
<codeEntityReference>M:TestDoc.TestClass.FirstMethod</codeEntityReference>
<codeEntityReference>M:TestDoc.TestClass.SecondMethod(System.Int32,System.String)</codeEntityReference>
-->
</relatedTopics>
</developerConceptualDocument>
</topic>
| {
"pile_set_name": "Github"
} |
{
"images" : [
{
"orientation" : "portrait",
"idiom" : "iphone",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
},
{
"orientation" : "portrait",
"idiom" : "iphone",
"subtype" : "retina4",
"extent" : "full-screen",
"minimum-system-version" : "7.0",
"scale" : "2x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
} | {
"pile_set_name": "Github"
} |
/*
* Copyright (C) Kreogist Dev Team
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
* of the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*/
#ifndef KNABSTRACTSLIDER_H
#define KNABSTRACTSLIDER_H
#include <QWidget>
/*!
* \brief The KNAbstractSlider class provides the basic operation of a 64-bit
* integer slider. All the data is in 64-bit integer type. This is an abstract
* interface widget class. The slider widget should implement this widget and
* realize the paintEvent() function.
*/
class KNAbstractSlider : public QWidget
{
Q_OBJECT
public:
/*!
* \brief Construct a KNAbstractSlider widget.
* \param parent The parent widget.
*/
explicit KNAbstractSlider(QWidget *parent = 0);
/*!
* \brief This property holds the slider's maximum value.\n
* When setting this property, the minimum is adjusted if necessary to
* ensure that the range remains valid. Also the slider's current value is
* adjusted to be within the new range.
* \return The maximum value.
*/
virtual qint64 maximum() const
{
return m_maximum;
}
/*!
* \brief This property holds the sliders's minimum value.\n
* When setting this property, the maximum is adjusted if necessary to
* ensure that the range remains valid. Also the slider's current value is
* adjusted to be within the new range.
* \return The minimal value.
*/
virtual qint64 minimal() const
{
return m_minimal;
}
/*!
* \brief This property holds the slider's current value.\n
* The slider forces the value to be within the legal range: minimum <=
* value <= maximum.
* \return The current slider value.
*/
virtual qint64 value() const
{
return m_value;
}
/*!
* \brief Get the range size of the slider.
* \return The slider range gap.
*/
virtual qint64 range() const
{
return m_range;
}
/*!
* \brief Get the percentage of the current value to the range.
* \return The percentage of the current value to the minimum value.
*/
virtual qreal percentage() const
{
return m_percentage;
}
/*!
* \brief Get the wheel step value.
* \return The wheel step.
*/
virtual qint64 wheelStep() const
{
return m_wheelStep;
}
signals:
/*!
* \brief When either minimum or maximum changed, this signal will be
* emitted.
* \param min The minimum of the slider.
* \param max The maximum of the slider.
*/
void rangeChanged(qint64 min, qint64 max);
/*!
* \brief When the mouse moved the button of the slider, this signal will be
* emitted.
* \param value The value of the slider.
*/
void sliderMoved(qint64 value);
/*!
* \brief When the mouse pressed the button of the slider, this signal will
* be emitted.
*/
void sliderPressed();
/*!
* \brief When the mouse released the pressed of the button of the slider,
* this signal will be emitted.
*/
void sliderReleased();
/*!
* \brief When the value of the slider changed, this signal will be changed.
* \param value The current value of the slider.
*/
void valueChanged(qint64 value);
public slots:
/*!
* \brief Set the maximum value of the slider.
* \param maximum The prefer maximum value.
*/
virtual void setMaximum(qint64 maximum);
/*!
* \brief Set the minimal value of the slider.
* \param maximum The prefer minimal value.
*/
virtual void setMinimal(qint64 minimal);
/*!
* \brief Set both maximum and minimal value of the slider.
* \param min The prefer minimal value.
* \param max The prefer maximum value.
*/
virtual void setRange(qint64 min, qint64 max);
/*!
* \brief Set the value of the slider.
* \param value The prefer value.
*/
virtual void setValue(qint64 value);
/*!
* \brief Set the wheel step of the scrolling of the mouse or trackpad.
* \param wheelStep The wheel step of the slider.
*/
virtual void setWheelStep(qint64 wheelStep)
{
m_wheelStep=wheelStep;
}
protected:
/*!
* \brief Reimplemented from QWidget::wheelEvent().
*/
void wheelEvent(QWheelEvent *event);
/*!
* \brief All the implement slider must provides the paintEvent() function.
* \param event The event provided by the system.
*/
virtual void paintEvent(QPaintEvent *event)=0;
private:
inline void updateRange();
qint64 m_maximum, m_minimal, m_value, m_range, m_wheelStep;
qreal m_percentage;
};
#endif // KNABSTRACTSLIDER_H
| {
"pile_set_name": "Github"
} |
/*
* Copyright (c) 2003, Oracle and/or its affiliates. All rights reserved.
* ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*
*/
package com.sun.corba.se.spi.monitoring;
import com.sun.corba.se.spi.monitoring.MonitoredAttribute;
import java.util.*;
import java.util.Collection;
/**
* @author Hemanth Puttaswamy
*
* Monitored Object provides an Hierarchichal view of the ORB Monitoring
* System. It can contain multiple children and a single parent. Each
* Monitored Object may also contain Multiple Monitored Attributes.
*/
public interface MonitoredObject {
///////////////////////////////////////
// operations
/**
* Gets the name of this MonitoredObject
*
* @return a String with name of this Monitored Object
*/
public String getName();
/**
* Gets the description of MonitoredObject
*
* @return a String with Monitored Object Description.
*/
public String getDescription();
/**
* This method will add a child Monitored Object to this Monitored Object.
*/
public void addChild( MonitoredObject m );
/**
* This method will remove child Monitored Object identified by the given name
*
* @param name of the ChildMonitored Object
*/
public void removeChild( String name );
/**
* Gets the child MonitoredObject associated with this MonitoredObject
* instance using name as the key. The name should be fully qualified name
* like orb.connectionmanager
*
* @return a MonitoredObject identified by the given name
* @param name of the ChildMonitored Object
*/
public MonitoredObject getChild(String name);
/**
* Gets all the Children registered under this instance of Monitored
* Object.
*
* @return Collection of immediate Children associated with this MonitoredObject.
*/
public Collection getChildren();
/**
* Sets the parent for this Monitored Object.
*/
public void setParent( MonitoredObject m );
/**
* There will be only one parent for an instance of MontoredObject, this
* call gets parent and returns null if the Monitored Object is the root.
*
* @return a MonitoredObject which is a Parent of this Monitored Object instance
*/
public MonitoredObject getParent();
/**
* Adds the attribute with the given name.
*
* @param value is the MonitoredAttribute which will be set as one of the
* attribute of this MonitoredObject.
*/
public void addAttribute(MonitoredAttribute value);
/**
* Removes the attribute with the given name.
*
* @param name is the MonitoredAttribute name
*/
public void removeAttribute(String name);
/**
* Gets the Monitored Object registered by the given name
*
* @return a MonitoredAttribute identified by the given name
* @param name of the attribute
*/
public MonitoredAttribute getAttribute(String name);
/**
* Gets all the Monitored Attributes for this Monitored Objects. It doesn't
* include the Child Monitored Object, that needs to be traversed using
* getChild() or getChildren() call.
*
* @return Collection of all the Attributes for this MonitoredObject
*/
public Collection getAttributes();
/**
* Clears the state of all the Monitored Attributes associated with the
* Monitored Object. It will also clear the state on all it's child
* Monitored Object. The call to clearState will be initiated from
* CORBAMBean.startMonitoring() call.
*/
public void clearState();
} // end MonitoredObject
| {
"pile_set_name": "Github"
} |
# AUTOGENERATED FILE
AF_PPPOX = 24
PPPIOCGCHAN = 1074033719
PPPIOCGFLAGS = 1074033754
PPPIOCGL2TPSTATS = 1078490166
PPPIOCGMRU = 1074033747
PPPIOCSFLAGS = 2147775577
PPPIOCSMRU = 2147775570
PPPOEIOCDFWD = 536916225
PPPOEIOCSFWD = 2148053248
PPPOL2TP_SO_DEBUG = 1
PPPOL2TP_SO_LNSMODE = 4
PPPOL2TP_SO_RECVSEQ = 2
PPPOL2TP_SO_REORDERTO = 5
PPPOL2TP_SO_SENDSEQ = 3
PX_PROTO_OE = 0
PX_PROTO_OL2TP = 1
PX_PROTO_PPTP = 2
SC_CCP_OPEN = 64
SC_CCP_UP = 128
SC_COMP_AC = 2
SC_COMP_PROT = 1
SC_COMP_RUN = 4096
SC_COMP_TCP = 4
SC_DEBUG = 65536
SC_DECOMP_RUN = 8192
SC_ENABLE_IP = 256
SC_LOG_FLUSH = 1048576
SC_LOG_INPKT = 131072
SC_LOG_OUTPKT = 262144
SC_LOG_RAWIN = 524288
SC_LOOP_TRAFFIC = 512
SC_MP_SHORTSEQ = 2048
SC_MP_XSHORTSEQ = 16384
SC_MULTILINK = 1024
SC_MUST_COMP = 4194304
SC_NO_TCP_CCID = 8
SC_REJ_COMP_AC = 16
SC_REJ_COMP_TCP = 32
SC_SYNC = 2097152
SIOCGIFMTU = 35105
SIOCSIFMTU = 35106
SOCKADDR_PPPOX_SIZE = 30
SOCK_STREAM = 1
SOL_PPPOL2TP = 273
__NR_bind = 327
__NR_connect = 328
__NR_ioctl = 54
__NR_setsockopt = 339
__NR_socket = 326
| {
"pile_set_name": "Github"
} |
using DigitalRune.Geometry;
using DigitalRune.Geometry.Shapes;
using DigitalRune.Mathematics;
using DigitalRune.Mathematics.Algebra;
using DigitalRune.Physics.Constraints;
using NUnit.Framework;
namespace DigitalRune.Physics.Constraints.Tests
{
[TestFixture]
public class ConstraintHelperTest
{
[Test]
public void SpringDampingTest()
{
float erp = 0.3f;
float cfm = 0.001f;
float spring = ConstraintHelper.ComputeSpringConstant(1 / 60f, erp, cfm);
float damping = ConstraintHelper.ComputeDampingConstant(1 / 60f, erp, cfm);
Assert.IsTrue(Numeric.AreEqual(erp, ConstraintHelper.ComputeErrorReduction(1 / 60f, spring, damping)));
Assert.IsTrue(Numeric.AreEqual(cfm, ConstraintHelper.ComputeSoftness(1 / 60f, spring, damping)));
}
[Test]
public void ComputeKMatrix()
{
var b = new RigidBody(new EmptyShape());
b.MassFrame = new MassFrame()
{
Mass = 3,
Inertia = new Vector3F(0.4f, 0.5f, 0.6f),
};
var r = new Vector3F(1, 2, 3);
var k = ConstraintHelper.ComputeKMatrix(b, r);
var desiredK = 1 / b.MassFrame.Mass * Matrix33F.Identity - r.ToCrossProductMatrix() * Matrix33F.CreateScale(b.MassFrame.InertiaInverse) * r.ToCrossProductMatrix();
Assert.AreEqual(desiredK, k);
}
[Test]
public void SetVelocityTest()
{
var body = new RigidBody(new BoxShape(1, 2, 3));
body.Pose = new Pose(new Vector3F(10, 20, 30), QuaternionF.CreateRotationY(1.1f));
body.LinearVelocity = new Vector3F(1, 2, 3);
body.AngularVelocity = new Vector3F(4, 5, 6);
Vector3F pointLocal = new Vector3F(0.5f, 0.9f, 1.3f);
Vector3F point = body.Pose.ToWorldPosition(pointLocal);
Vector3F targetVelocity = new Vector3F(7, -8, 9);
Assert.AreNotEqual(targetVelocity, body.GetVelocityOfLocalPoint(pointLocal));
ConstraintHelper.SetVelocityOfWorldPoint(body, point, targetVelocity);
Assert.IsTrue(Vector3F.AreNumericallyEqual(targetVelocity, body.GetVelocityOfLocalPoint(pointLocal)));
}
}
}
| {
"pile_set_name": "Github"
} |
//
// Bounce.cs
//
// Author: Daniele Giardini (C# port of the easing equations created by Robert Penner - http://robertpenner.com/easing)
//
// TERMS OF USE - EASING EQUATIONS
//
// Open source under the BSD License.
//
// Copyright © 2001 Robert Penner
// All rights reserved.
//
// Redistribution and use in source and binary forms, with or without modification,
// are permitted provided that the following conditions are met:
//
// - Redistributions of source code must retain the above copyright notice,
// this list of conditions and the following disclaimer.
// - Redistributions in binary form must reproduce the above copyright notice,
// this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
// - Neither the name of the author nor the names of contributors may be used to endorse
// or promote products derived from this software without specific prior written permission.
// - THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
// AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
// THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
// IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
// STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
// EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
namespace DG.Tweening.Core.Easing
{
/// <summary>
/// This class contains a C# port of the easing equations created by Robert Penner (http://robertpenner.com/easing).
/// </summary>
public static class Bounce
{
/// <summary>
/// Easing equation function for a bounce (exponentially decaying parabolic bounce) easing in: accelerating from zero velocity.
/// </summary>
/// <param name="time">
/// Current time (in frames or seconds).
/// </param>
/// <param name="duration">
/// Expected easing duration (in frames or seconds).
/// </param>
/// <param name="unusedOvershootOrAmplitude">Unused: here to keep same delegate for all ease types.</param>
/// <param name="unusedPeriod">Unused: here to keep same delegate for all ease types.</param>
/// <returns>
/// The eased value.
/// </returns>
public static float EaseIn(float time, float duration, float unusedOvershootOrAmplitude, float unusedPeriod)
{
return 1 - EaseOut(duration - time, duration, -1, -1);
}
/// <summary>
/// Easing equation function for a bounce (exponentially decaying parabolic bounce) easing out: decelerating from zero velocity.
/// </summary>
/// <param name="time">
/// Current time (in frames or seconds).
/// </param>
/// <param name="duration">
/// Expected easing duration (in frames or seconds).
/// </param>
/// <param name="unusedOvershootOrAmplitude">Unused: here to keep same delegate for all ease types.</param>
/// <param name="unusedPeriod">Unused: here to keep same delegate for all ease types.</param>
/// <returns>
/// The eased value.
/// </returns>
public static float EaseOut(float time, float duration, float unusedOvershootOrAmplitude, float unusedPeriod)
{
if ((time /= duration) < (1 / 2.75f)) {
return (7.5625f * time * time);
}
if (time < (2 / 2.75f)) {
return (7.5625f * (time -= (1.5f / 2.75f)) * time + 0.75f);
}
if (time < (2.5f / 2.75f)) {
return (7.5625f * (time -= (2.25f / 2.75f)) * time + 0.9375f);
}
return (7.5625f * (time -= (2.625f / 2.75f)) * time + 0.984375f);
}
/// <summary>
/// Easing equation function for a bounce (exponentially decaying parabolic bounce) easing in/out: acceleration until halfway, then deceleration.
/// </summary>
/// <param name="time">
/// Current time (in frames or seconds).
/// </param>
/// <param name="duration">
/// Expected easing duration (in frames or seconds).
/// </param>
/// <param name="unusedOvershootOrAmplitude">Unused: here to keep same delegate for all ease types.</param>
/// <param name="unusedPeriod">Unused: here to keep same delegate for all ease types.</param>
/// <returns>
/// The eased value.
/// </returns>
public static float EaseInOut(float time, float duration, float unusedOvershootOrAmplitude, float unusedPeriod)
{
if (time < duration*0.5f)
{
return EaseIn(time*2, duration, -1, -1)*0.5f;
}
return EaseOut(time*2 - duration, duration, -1, -1)*0.5f + 0.5f;
}
}
}
| {
"pile_set_name": "Github"
} |
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Sep 17 2017 16:24:48).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2015 by Steve Nygard.
//
#import <MMCommon/MMObject.h>
@class NSArray, NSData, NSDictionary, NSString;
@interface WABlueToothDeviceAdData : MMObject
{
NSString *_localName;
NSData *_manufacturerData;
NSArray *_serviceUUIDs;
NSDictionary *_serviceData;
}
@property(retain, nonatomic) NSDictionary *serviceData; // @synthesize serviceData=_serviceData;
@property(retain, nonatomic) NSArray *serviceUUIDs; // @synthesize serviceUUIDs=_serviceUUIDs;
@property(retain, nonatomic) NSData *manufacturerData; // @synthesize manufacturerData=_manufacturerData;
@property(copy, nonatomic) NSString *localName; // @synthesize localName=_localName;
- (void).cxx_destruct;
@end
| {
"pile_set_name": "Github"
} |
(**************************************************************************)
(* *)
(* This file is part of WP plug-in of Frama-C. *)
(* *)
(* Copyright (C) 2007-2019 *)
(* CEA (Commissariat a l'energie atomique et aux energies *)
(* alternatives) *)
(* *)
(* you can redistribute it and/or modify it under the terms of the GNU *)
(* Lesser General Public License as published by the Free Software *)
(* Foundation, version 2.1. *)
(* *)
(* It is distributed in the hope that it will be useful, *)
(* but WITHOUT ANY WARRANTY; without even the implied warranty of *)
(* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *)
(* GNU Lesser General Public License for more details. *)
(* *)
(* See the GNU Lesser General Public License version 2.1 *)
(* for more details (enclosed in the file licenses/LGPLv2.1). *)
(* *)
(**************************************************************************)
open Lang
open Qed.Logic
(* Only integer patterns *)
type pattern =
| IMUL_K of Integer.t * F.term
| IDIV_K of F.term * Integer.t
| QDIV of F.term * F.term
| Ival of F.term * Integer.t option
| Rval of F.term
let pattern e =
match F.repr e with
| Kint n -> Ival(e,Some n)
| Times(k,e) when F.is_int e -> IMUL_K(k,e)
| Div(a,b) when not (F.is_int e) -> QDIV(a,b)
| Div(a,b) when F.is_int e ->
begin match F.repr b with
| Kint k ->
if Integer.(equal k zero) then raise Not_found ;
IDIV_K(a,k)
| _ -> Ival(e,None)
end
| _ ->
if F.is_int e then Ival(e,None) else
if F.is_real e then Rval e else
raise Not_found
(*
let pp_pattern fmt = function
| Ival(_,Some z) -> Format.fprintf fmt "(%s : constant)" (Integer.to_string z)
| Ival(e,None) -> Format.fprintf fmt "@[<hov 2>(%a : int)@]" F.pp_term e
| Rval e -> Format.fprintf fmt "@[<hov 2>(%a : real)@]" F.pp_term e
| IMUL_K(k,e) -> Format.fprintf fmt "@[<hov 2>%s.(%a : int)@]" (Integer.to_string k) F.pp_term e
| IDIV_K(e,k) -> Format.fprintf fmt "@[<hov 2>(%a : int)/%s@]" F.pp_term e (Integer.to_string k)
| QDIV(a,b) -> Format.fprintf fmt "@[<hov 2>(%a : real)@,/(%a : real)@]" F.pp_term a F.pp_term b
*)
let to_term = function
| IMUL_K(k,a) -> F.e_times k a
| IDIV_K(a,k) -> F.e_div a (F.e_zint k)
| QDIV(a,b) -> F.e_div a b
| Ival(e,_) | Rval e -> e
let pdiv a b = let k = Integer.c_div a b in Ival(F.e_zint k,Some k)
let nzero x = F.p_neq F.e_zero x
let positive x = F.p_lt F.e_zero x
let negative x = F.p_lt x F.e_zero
type cmp = LEQ | LT | EQ
let icmp cmp a b = match cmp with
| LEQ -> Integer.le a b
| LT -> Integer.lt a b
| EQ -> Integer.equal a b
let fcmp cmp a b = match cmp with
| LEQ -> F.p_leq a b
| LT -> F.p_lt a b
| EQ -> F.p_equal a b
let compare_ratio cmp a u b v =
let x = F.e_mul a v in
let y = F.e_mul b v in
let pu = positive u in
let nu = negative u in
let pv = positive v in
let nv = negative v in
F.p_conj [ nzero u ; nzero v ;
F.p_hyps [pu;pv] (fcmp cmp x y) ;
F.p_hyps [nu;pv] (fcmp cmp y x) ;
F.p_hyps [pu;nv] (fcmp cmp y x) ;
F.p_hyps [nu;nv] (fcmp cmp x y) ]
let compare_div cmp a b g =
let ra = F.e_mod a g in
let rb = F.e_mod b g in
fcmp cmp (F.e_sub a ra) (F.e_sub b rb)
let rec compare cmp a b =
match a, b with
| IMUL_K( k,a ) , Ival(_,Some n) ->
if Integer.(lt zero k) then compare cmp (pattern a) (pdiv n k) else
if Integer.(lt k zero) then compare cmp (pdiv n k) (pattern a) else
if icmp cmp Integer.zero n then F.p_true else F.p_false
| Ival(_,Some n) , IMUL_K( k,a ) ->
if Integer.(lt zero k) then compare cmp (pdiv n k) (pattern a) else
if Integer.(lt k zero) then compare cmp (pattern a) (pdiv n k) else
if icmp cmp Integer.zero n then F.p_true else F.p_false
| IDIV_K( a,k ) , Ival(b,_) ->
if Integer.(lt zero k) then
let c = F.e_times k (F.e_add b F.e_one) in
fcmp cmp a c
else
if Integer.(lt k zero) then
let c = F.e_times k (F.e_sub b F.e_one) in
fcmp cmp c a
else
raise Not_found
| Ival(a,_) , IDIV_K( b,k ) ->
if Integer.(lt zero k) then
let c = F.e_times k (F.e_sub a F.e_one) in
fcmp cmp c b
else
if Integer.(lt k zero) then
let c = F.e_times k (F.e_add a F.e_one) in
fcmp cmp b c
else
raise Not_found
| IDIV_K( a,p ) , IDIV_K( b,q ) when
not Integer.(equal p zero) &&
not Integer.(equal q zero) ->
let g = Integer.pgcd (Integer.abs p) (Integer.abs q) in
let ka = Integer.e_div p g in
let kb = Integer.e_div q g in
compare_div cmp (F.e_times ka a) (F.e_times kb b) (F.e_zint g)
| QDIV(a,u) , QDIV(b,v) -> compare_ratio cmp a u b v
| QDIV(a,u) , (Ival(b,_) | Rval b) -> compare_ratio cmp a u b F.e_one
| (Ival(a,_) | Rval a) , QDIV(b,v) -> compare_ratio cmp a F.e_one b v
| _ ->
raise Not_found
let eq_ratio eq a u b v =
F.p_conj [ nzero u ; nzero v ; eq (F.e_mul a v) (F.e_mul b u) ]
let rec equal eq a b =
match a , b with
| IMUL_K( k,a ) , Ival(_,Some n)
| Ival(_,Some n) , IMUL_K( k,a ) ->
let r = Integer.c_rem k n in
if Integer.equal r Integer.zero then
equal eq (pattern a) (pdiv n k)
else
eq F.e_one F.e_zero
| IMUL_K( k,a ) , IMUL_K( k',b ) ->
let r = Integer.pgcd k k' in
eq (F.e_times (Integer.c_div k r) a)
(F.e_times (Integer.c_div k' r) b)
| IDIV_K( a,p ) , IDIV_K( b,q ) when
not Integer.(equal p zero) &&
not Integer.(equal q zero) ->
let g = Integer.pgcd (Integer.abs p) (Integer.abs q) in
let ka = Integer.e_div p g in
let kb = Integer.e_div q g in
compare_div EQ (F.e_times ka a) (F.e_times kb b) (F.e_zint g)
| QDIV(a,u) , QDIV(b,v) -> eq_ratio eq a u b v
| QDIV(a,u) , (Ival(b,_) | Rval b) -> eq_ratio eq a u b F.e_one
| (Ival(a,_) | Rval a) , QDIV(b,v) -> eq_ratio eq a F.e_one b v
| _ -> eq (to_term a) (to_term b)
let select goal =
match F.repr (F.e_prop goal) with
| Leq(a,b) -> compare LEQ (pattern a) (pattern b)
| Lt(a,b) -> compare LT (pattern a) (pattern b)
| Eq(a,b) -> equal F.p_equal (pattern a) (pattern b)
| Neq(a,b) -> equal F.p_neq (pattern a) (pattern b)
| _ -> raise Not_found
class congruence =
object
inherit Tactical.make
~id:"Wp.congruence"
~title:"Congruence"
~descr:"Euclidian Comparisons"
~params:[]
method select _feedback = function
| Tactical.Clause(Tactical.Goal p) ->
let q = select p in
if q != p
then Tactical.Applicable(fun seq -> ["congruence" , (fst seq , q)])
else Tactical.Not_applicable
| _ -> Tactical.Not_applicable
end
let tactical = Tactical.export (new congruence)
let strategy = Strategy.make tactical ~arguments:[]
(* -------------------------------------------------------------------------- *)
(* --- Auto Congruence --- *)
(* -------------------------------------------------------------------------- *)
class autodiv =
object
method id = "wp:congruence"
method title = "Auto Congruence"
method descr = "Resolve Divisions and Multiplications"
method search push (seq : Conditions.sequent) =
try
let p = snd seq in
let q = select p in
if q != p then push (strategy Tactical.(Clause (Goal p)))
with Not_found -> ()
end
let () = Strategy.register (new autodiv)
| {
"pile_set_name": "Github"
} |
NAME
ballerina-grpc - Generate Ballerina sources for the given protobuf
definition
SYNOPSIS
ballerina grpc --input <proto-file-path> [--output <path>]
[--mode client | service | proxy]
DESCRIPTION
GRPC generates the Ballerina gRPC client/service sources for a given
gRPC protocol buffer definition.
OPTIONS
--input <proto-file-path>
Path of the input .proto file.
--output <path>
Location of the generated Ballerina source files.
If output path is not specified, output will be written to a
directory corresponding to the package in the protocol buffer
definition. If package is not specified, output will be written
to a 'temp' directory in the current location.
--mode client | service | proxy
Set client or service mode to generate sample code.
Set proxy mode to generate a gateway proxy.
If not specified, only the stub file is generated.
EXAMPLES
Generate the Ballerina gRPC stub file for the given .proto file to a
'stub' directory.
$ ballerina grpc --input chat.proto --output stub
Generate the Ballerina gRPC stub file and client sample code for the
given .proto file to a 'client' directory.
$ ballerina grpc --input chat.proto --output client --mode client
Generate the Ballerina gRPC stub file and service sample code for the
given .proto file to a 'service' directory.
$ ballerina grpc --input chat.proto --output service --mode service
| {
"pile_set_name": "Github"
} |
! Base16 Default
! Scheme: Chris Kempson (http://chriskempson.com)
#define base00 #181818
#define base01 #282828
#define base02 #383838
#define base03 #585858
#define base04 #b8b8b8
#define base05 #d8d8d8
#define base06 #e8e8e8
#define base07 #f8f8f8
#define base08 #ab4642
#define base09 #dc9656
#define base0A #f7ca88
#define base0B #a1b56c
#define base0C #86c1b9
#define base0D #7cafc2
#define base0E #ba8baf
#define base0F #a16946
*foreground: base02
*background: base07
*cursorColor: base02
*color0: base00
*color1: base08
*color2: base0B
*color3: base0A
*color4: base0D
*color5: base0E
*color6: base0C
*color7: base05
*color8: base03
*color9: base08
*color10: base0B
*color11: base0A
*color12: base0D
*color13: base0E
*color14: base0C
*color15: base07
! Note: colors beyond 15 might not be loaded (e.g., xterm, urxvt),
! use 'shell' template to set these if necessary
*color16: base09
*color17: base0F
*color18: base01
*color19: base02
*color20: base04
*color21: base06
| {
"pile_set_name": "Github"
} |
.modal--media-browser {
&__dialog {
max-width: 100rem;
}
&__body {
display: flex;
padding: 0;
@include tablet {
display: block;
}
}
&__folders {
padding: 1rem;
border-right: 1px solid var(--color-default-300);
flex-basis: 20rem;
flex-shrink: 0;
@include tablet {
flex-basis: 0;
}
}
&__items {
flex-grow: 1;
padding: 0.5rem;
display: flex;
flex-wrap: wrap;
justify-content: center;
align-items: center;
min-height: 20rem;
&::after {
content: '';
display: block;
clear: both;
}
}
&__search {
flex-grow: 0;
width: auto;
}
&__item {
flex-grow: 1;
border: 0;
padding: 0.5rem;
cursor: pointer;
background-color: transparent;
margin: 0;
min-width: 20rem;
max-width: calc(100% / 3);
height: 20rem;
position: relative;
border: 1px solid transparent;
&:hover {
border-color: var(--color-action-500);
}
@include tablet {
max-width: calc(100% / 2);
}
@include phone {
max-width: 100%;
}
&__media {
position: absolute;
max-height: calc(100% - 1rem);
max-width: calc(100% - 1rem);
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
}
&__name {
display: block;
padding: 0 0.5rem;
line-height: var(--size-widget-small);
position: absolute;
bottom: 1rem;
left: 1rem;
width: calc(100% - 2rem);
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
background-color: var(--color-default-100);
color: var(--color-default-text);
border-radius: var(--border-radius-small);
}
&:hover &__name {
background-color: var(--color-action-500);
color: var(--color-action-text);
}
}
}
| {
"pile_set_name": "Github"
} |
var keyId = {
"U+0008" : "BackSpace",
"U+0009" : "Tab",
"U+0018" : "Cancel",
"U+001B" : "Esc",
"U+0020" : "Space",
"U+0021" : "!",
"U+0022" : "\"",
"U+0023" : "#",
"U+0024" : "$",
"U+0026" : "&",
"U+0027" : "'",
"U+0028" : "(",
"U+0029" : ")",
"U+002A" : "*",
"U+002B" : "+",
"U+002C" : ",",
"U+002D" : "-",
"U+002E" : ".",
"U+002F" : "/",
"U+0030" : "0",
"U+0031" : "1",
"U+0032" : "2",
"U+0033" : "3",
"U+0034" : "4",
"U+0035" : "5",
"U+0036" : "6",
"U+0037" : "7",
"U+0038" : "8",
"U+0039" : "9",
"U+003A" : ":",
"U+003B" : ";",
"U+003C" : "<",
"U+003D" : "=",
"U+003E" : ">",
"U+003F" : "?",
"U+0040" : "@",
"U+0041" : "a",
"U+0042" : "b",
"U+0043" : "c",
"U+0044" : "d",
"U+0045" : "e",
"U+0046" : "f",
"U+0047" : "g",
"U+0048" : "h",
"U+0049" : "i",
"U+004A" : "j",
"U+004B" : "k",
"U+004C" : "l",
"U+004D" : "m",
"U+004E" : "n",
"U+004F" : "o",
"U+0050" : "p",
"U+0051" : "q",
"U+0052" : "r",
"U+0053" : "s",
"U+0054" : "t",
"U+0055" : "u",
"U+0056" : "v",
"U+0057" : "w",
"U+0058" : "x",
"U+0059" : "y",
"U+005A" : "z",
"U+005B" : "[",
"U+005C" : "\\",
"U+005D" : "]",
"U+005E" : "^",
"U+005F" : "_",
"U+0060" : "`",
"U+007B" : "{",
"U+007C" : "|",
"U+007D" : "}",
"U+007F" : "Delete",
/* unsupported
"U+00A1" : "RevExcl",
"U+0300" : "CombGrave",
"U+0300" : "CombAcute",
"U+0302" : "CombCircum",
"U+0303" : "CombTilde",
"U+0304" : "CombMacron",
"U+0306" : "CombBreve",
"U+0307" : "CombDot",
"U+0308" : "CombDiaer",
"U+030A" : "CombRing",
"U+030B" : "CombDblAcute",
"U+030C" : "CombCaron",
"U+0327" : "CombCedilla",
"U+0328" : "CombOgonek",
"U+0345" : "CombYpogeg",
"U+20AC" : "Euro",
"U+3099" : "CombVoice",
"U+309A" : "CombSVoice",
*/
};
var winkeys = {
"U+00BC":",",
"U+00BE":".",
"U+00BF":"/",
"U+00E2":"\\",
"U+00BB":";",
"U+00BA":":",
"U+00DD":"]",
"U+00C0":"@",
"U+00DB":"[",
"U+00BD":"-",
"U+00DE":"^",
"U+00DC":"\\"
};
var shiftWinkeys = {
"U+00BC":"<",
"U+00BE":">",
"U+00BF":"?",
"U+00E2":"_",
"U+00BB":"+",
"U+00BA":"*",
"U+00DD":"}",
"U+00C0":"`",
"U+00DB":"{",
"U+00BD":"=",
"U+00DE":"~",
"U+00DC":"|",
"U+0031":"!",
"U+0032":"\"",
"U+0033":"#",
"U+0034":"$",
"U+0035":"%",
"U+0036":"&",
"U+0037":"'",
"U+0038":"(",
"U+0039":")"
};
function get_key(evt){
var key = keyId[evt.keyIdentifier] || winkeys[evt.keyIdentifier] || evt.keyIdentifier,
ctrl = evt.ctrlKey ? 'C-' : '',
meta = (evt.metaKey || evt.altKey) ? 'M-' : '',
shift = evt.shiftKey ? 'S-' : '';
if (evt.shiftKey && shiftWinkeys[evt.keyIdentifier]) key = shiftWinkeys[evt.keyIdentifier];
if (/^(Meta|Shift|Control|Alt)$/.test(key)) return key;
if (evt.shiftKey){
if (/^[a-z]$/.test(key))
return ctrl+meta+key.toUpperCase();
if (/^(Enter|Space|BackSpace|Tab|Esc|Home|End|Left|Right|Up|Down|PageUp|PageDown|Delete|F\d\d?)$/.test(key))
return ctrl+meta+shift+key;
}
return ctrl+meta+key;
}
| {
"pile_set_name": "Github"
} |
// Go support for Protocol Buffers - Google's data interchange format
//
// Copyright 2012 The Go Authors. All rights reserved.
// https://github.com/golang/protobuf
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
// copyright notice, this list of conditions and the following disclaimer
// in the documentation and/or other materials provided with the
// distribution.
// * Neither the name of Google Inc. nor the names of its
// contributors may be used to endorse or promote products derived from
// this software without specific prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
// +build !purego,!appengine,!js
// This file contains the implementation of the proto field accesses using package unsafe.
package proto
import (
"reflect"
"sync/atomic"
"unsafe"
)
const unsafeAllowed = true
// A field identifies a field in a struct, accessible from a pointer.
// In this implementation, a field is identified by its byte offset from the start of the struct.
type field uintptr
// toField returns a field equivalent to the given reflect field.
func toField(f *reflect.StructField) field {
return field(f.Offset)
}
// invalidField is an invalid field identifier.
const invalidField = ^field(0)
// zeroField is a noop when calling pointer.offset.
const zeroField = field(0)
// IsValid reports whether the field identifier is valid.
func (f field) IsValid() bool {
return f != invalidField
}
// The pointer type below is for the new table-driven encoder/decoder.
// The implementation here uses unsafe.Pointer to create a generic pointer.
// In pointer_reflect.go we use reflect instead of unsafe to implement
// the same (but slower) interface.
type pointer struct {
p unsafe.Pointer
}
// size of pointer
var ptrSize = unsafe.Sizeof(uintptr(0))
// toPointer converts an interface of pointer type to a pointer
// that points to the same target.
func toPointer(i *Message) pointer {
// Super-tricky - read pointer out of data word of interface value.
// Saves ~25ns over the equivalent:
// return valToPointer(reflect.ValueOf(*i))
return pointer{p: (*[2]unsafe.Pointer)(unsafe.Pointer(i))[1]}
}
// toAddrPointer converts an interface to a pointer that points to
// the interface data.
func toAddrPointer(i *interface{}, isptr bool) pointer {
// Super-tricky - read or get the address of data word of interface value.
if isptr {
// The interface is of pointer type, thus it is a direct interface.
// The data word is the pointer data itself. We take its address.
return pointer{p: unsafe.Pointer(uintptr(unsafe.Pointer(i)) + ptrSize)}
}
// The interface is not of pointer type. The data word is the pointer
// to the data.
return pointer{p: (*[2]unsafe.Pointer)(unsafe.Pointer(i))[1]}
}
// valToPointer converts v to a pointer. v must be of pointer type.
func valToPointer(v reflect.Value) pointer {
return pointer{p: unsafe.Pointer(v.Pointer())}
}
// offset converts from a pointer to a structure to a pointer to
// one of its fields.
func (p pointer) offset(f field) pointer {
// For safety, we should panic if !f.IsValid, however calling panic causes
// this to no longer be inlineable, which is a serious performance cost.
/*
if !f.IsValid() {
panic("invalid field")
}
*/
return pointer{p: unsafe.Pointer(uintptr(p.p) + uintptr(f))}
}
func (p pointer) isNil() bool {
return p.p == nil
}
func (p pointer) toInt64() *int64 {
return (*int64)(p.p)
}
func (p pointer) toInt64Ptr() **int64 {
return (**int64)(p.p)
}
func (p pointer) toInt64Slice() *[]int64 {
return (*[]int64)(p.p)
}
func (p pointer) toInt32() *int32 {
return (*int32)(p.p)
}
// See pointer_reflect.go for why toInt32Ptr/Slice doesn't exist.
/*
func (p pointer) toInt32Ptr() **int32 {
return (**int32)(p.p)
}
func (p pointer) toInt32Slice() *[]int32 {
return (*[]int32)(p.p)
}
*/
func (p pointer) getInt32Ptr() *int32 {
return *(**int32)(p.p)
}
func (p pointer) setInt32Ptr(v int32) {
*(**int32)(p.p) = &v
}
// getInt32Slice loads a []int32 from p.
// The value returned is aliased with the original slice.
// This behavior differs from the implementation in pointer_reflect.go.
func (p pointer) getInt32Slice() []int32 {
return *(*[]int32)(p.p)
}
// setInt32Slice stores a []int32 to p.
// The value set is aliased with the input slice.
// This behavior differs from the implementation in pointer_reflect.go.
func (p pointer) setInt32Slice(v []int32) {
*(*[]int32)(p.p) = v
}
// TODO: Can we get rid of appendInt32Slice and use setInt32Slice instead?
func (p pointer) appendInt32Slice(v int32) {
s := (*[]int32)(p.p)
*s = append(*s, v)
}
func (p pointer) toUint64() *uint64 {
return (*uint64)(p.p)
}
func (p pointer) toUint64Ptr() **uint64 {
return (**uint64)(p.p)
}
func (p pointer) toUint64Slice() *[]uint64 {
return (*[]uint64)(p.p)
}
func (p pointer) toUint32() *uint32 {
return (*uint32)(p.p)
}
func (p pointer) toUint32Ptr() **uint32 {
return (**uint32)(p.p)
}
func (p pointer) toUint32Slice() *[]uint32 {
return (*[]uint32)(p.p)
}
func (p pointer) toBool() *bool {
return (*bool)(p.p)
}
func (p pointer) toBoolPtr() **bool {
return (**bool)(p.p)
}
func (p pointer) toBoolSlice() *[]bool {
return (*[]bool)(p.p)
}
func (p pointer) toFloat64() *float64 {
return (*float64)(p.p)
}
func (p pointer) toFloat64Ptr() **float64 {
return (**float64)(p.p)
}
func (p pointer) toFloat64Slice() *[]float64 {
return (*[]float64)(p.p)
}
func (p pointer) toFloat32() *float32 {
return (*float32)(p.p)
}
func (p pointer) toFloat32Ptr() **float32 {
return (**float32)(p.p)
}
func (p pointer) toFloat32Slice() *[]float32 {
return (*[]float32)(p.p)
}
func (p pointer) toString() *string {
return (*string)(p.p)
}
func (p pointer) toStringPtr() **string {
return (**string)(p.p)
}
func (p pointer) toStringSlice() *[]string {
return (*[]string)(p.p)
}
func (p pointer) toBytes() *[]byte {
return (*[]byte)(p.p)
}
func (p pointer) toBytesSlice() *[][]byte {
return (*[][]byte)(p.p)
}
func (p pointer) toExtensions() *XXX_InternalExtensions {
return (*XXX_InternalExtensions)(p.p)
}
func (p pointer) toOldExtensions() *map[int32]Extension {
return (*map[int32]Extension)(p.p)
}
// getPointerSlice loads []*T from p as a []pointer.
// The value returned is aliased with the original slice.
// This behavior differs from the implementation in pointer_reflect.go.
func (p pointer) getPointerSlice() []pointer {
// Super-tricky - p should point to a []*T where T is a
// message type. We load it as []pointer.
return *(*[]pointer)(p.p)
}
// setPointerSlice stores []pointer into p as a []*T.
// The value set is aliased with the input slice.
// This behavior differs from the implementation in pointer_reflect.go.
func (p pointer) setPointerSlice(v []pointer) {
// Super-tricky - p should point to a []*T where T is a
// message type. We store it as []pointer.
*(*[]pointer)(p.p) = v
}
// getPointer loads the pointer at p and returns it.
func (p pointer) getPointer() pointer {
return pointer{p: *(*unsafe.Pointer)(p.p)}
}
// setPointer stores the pointer q at p.
func (p pointer) setPointer(q pointer) {
*(*unsafe.Pointer)(p.p) = q.p
}
// append q to the slice pointed to by p.
func (p pointer) appendPointer(q pointer) {
s := (*[]unsafe.Pointer)(p.p)
*s = append(*s, q.p)
}
// getInterfacePointer returns a pointer that points to the
// interface data of the interface pointed by p.
func (p pointer) getInterfacePointer() pointer {
// Super-tricky - read pointer out of data word of interface value.
return pointer{p: (*(*[2]unsafe.Pointer)(p.p))[1]}
}
// asPointerTo returns a reflect.Value that is a pointer to an
// object of type t stored at p.
func (p pointer) asPointerTo(t reflect.Type) reflect.Value {
return reflect.NewAt(t, p.p)
}
func atomicLoadUnmarshalInfo(p **unmarshalInfo) *unmarshalInfo {
return (*unmarshalInfo)(atomic.LoadPointer((*unsafe.Pointer)(unsafe.Pointer(p))))
}
func atomicStoreUnmarshalInfo(p **unmarshalInfo, v *unmarshalInfo) {
atomic.StorePointer((*unsafe.Pointer)(unsafe.Pointer(p)), unsafe.Pointer(v))
}
func atomicLoadMarshalInfo(p **marshalInfo) *marshalInfo {
return (*marshalInfo)(atomic.LoadPointer((*unsafe.Pointer)(unsafe.Pointer(p))))
}
func atomicStoreMarshalInfo(p **marshalInfo, v *marshalInfo) {
atomic.StorePointer((*unsafe.Pointer)(unsafe.Pointer(p)), unsafe.Pointer(v))
}
func atomicLoadMergeInfo(p **mergeInfo) *mergeInfo {
return (*mergeInfo)(atomic.LoadPointer((*unsafe.Pointer)(unsafe.Pointer(p))))
}
func atomicStoreMergeInfo(p **mergeInfo, v *mergeInfo) {
atomic.StorePointer((*unsafe.Pointer)(unsafe.Pointer(p)), unsafe.Pointer(v))
}
func atomicLoadDiscardInfo(p **discardInfo) *discardInfo {
return (*discardInfo)(atomic.LoadPointer((*unsafe.Pointer)(unsafe.Pointer(p))))
}
func atomicStoreDiscardInfo(p **discardInfo, v *discardInfo) {
atomic.StorePointer((*unsafe.Pointer)(unsafe.Pointer(p)), unsafe.Pointer(v))
}
| {
"pile_set_name": "Github"
} |
/*
* This file is subject to the terms and conditions of the GNU General Public
* License. See the file "COPYING" in the main directory of this archive
* for more details.
*
* Copyright (C) 1997, 1999, 2001, 06 by Ralf Baechle
* Copyright (C) 2001 MIPS Technologies, Inc.
*/
#ifndef _ASM_REBOOT_H
#define _ASM_REBOOT_H
extern void (*_machine_restart)(char *command);
extern void (*_machine_halt)(void);
#endif /* _ASM_REBOOT_H */
| {
"pile_set_name": "Github"
} |
<?php
namespace oasis\names\specification\ubl\schema\xsd\CommonBasicComponents_2;
use un\unece\uncefact\data\specification\UnqualifiedDataTypesSchemaModule\_2;
/**
* @xmlNamespace urn:oasis:names:specification:ubl:schema:xsd:CommonBasicComponents-2
* @xmlType AmountType
* @xmlName TaxAmountType
* @var oasis\names\specification\ubl\schema\xsd\CommonBasicComponents_2\TaxAmountType
*/
class TaxAmountType extends _2\AmountType
{
} // end class TaxAmountType
| {
"pile_set_name": "Github"
} |
package ast
import (
"fmt"
"strings"
)
// Call represents a function call.
type Call struct {
Func string
Args []Node
Posx Pos
}
func (n *Call) Accept(v Visitor) Node {
for i, a := range n.Args {
n.Args[i] = a.Accept(v)
}
return v(n)
}
func (n *Call) Pos() Pos {
return n.Posx
}
func (n *Call) String() string {
args := make([]string, len(n.Args))
for i, arg := range n.Args {
args[i] = fmt.Sprintf("%s", arg)
}
return fmt.Sprintf("Call(%s, %s)", n.Func, strings.Join(args, ", "))
}
func (n *Call) Type(s Scope) (Type, error) {
f, ok := s.LookupFunc(n.Func)
if !ok {
return TypeInvalid, fmt.Errorf("unknown function: %s", n.Func)
}
return f.ReturnType, nil
}
func (n *Call) GoString() string {
return fmt.Sprintf("*%#v", *n)
}
| {
"pile_set_name": "Github"
} |
/*
* Copyright 2020 ConsenSys AG.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on
* an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the
* specific language governing permissions and limitations under the License.
*/
package tech.pegasys.teku.core.signatures;
/**
* Thrown to indicate that a signing request has been refused because it may violate a slashable
* condition.
*/
public class SlashableConditionException extends RuntimeException {
public SlashableConditionException(final String message) {
super(message);
}
}
| {
"pile_set_name": "Github"
} |
// ------------------------------------------------------------------------------
// Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License. See License in the project root for license information.
// ------------------------------------------------------------------------------
// **NOTE** This file was generated by a tool and any changes will be overwritten.
// <auto-generated/>
// Template Source: Templates\CSharp\Requests\EntityRequest.cs.tt
namespace Microsoft.Graph
{
using System;
using System.Collections.Generic;
using System.IO;
using System.Net.Http;
using System.Threading;
using System.Linq.Expressions;
/// <summary>
/// The type IosVppEBookAssignmentRequest.
/// </summary>
public partial class IosVppEBookAssignmentRequest : BaseRequest, IIosVppEBookAssignmentRequest
{
/// <summary>
/// Constructs a new IosVppEBookAssignmentRequest.
/// </summary>
/// <param name="requestUrl">The URL for the built request.</param>
/// <param name="client">The <see cref="IBaseClient"/> for handling requests.</param>
/// <param name="options">Query and header option name value pairs for the request.</param>
public IosVppEBookAssignmentRequest(
string requestUrl,
IBaseClient client,
IEnumerable<Option> options)
: base(requestUrl, client, options)
{
}
/// <summary>
/// Creates the specified IosVppEBookAssignment using POST.
/// </summary>
/// <param name="iosVppEBookAssignmentToCreate">The IosVppEBookAssignment to create.</param>
/// <returns>The created IosVppEBookAssignment.</returns>
public System.Threading.Tasks.Task<IosVppEBookAssignment> CreateAsync(IosVppEBookAssignment iosVppEBookAssignmentToCreate)
{
return this.CreateAsync(iosVppEBookAssignmentToCreate, CancellationToken.None);
}
/// <summary>
/// Creates the specified IosVppEBookAssignment using POST.
/// </summary>
/// <param name="iosVppEBookAssignmentToCreate">The IosVppEBookAssignment to create.</param>
/// <param name="cancellationToken">The <see cref="CancellationToken"/> for the request.</param>
/// <returns>The created IosVppEBookAssignment.</returns>
public async System.Threading.Tasks.Task<IosVppEBookAssignment> CreateAsync(IosVppEBookAssignment iosVppEBookAssignmentToCreate, CancellationToken cancellationToken)
{
this.ContentType = "application/json";
this.Method = "POST";
var newEntity = await this.SendAsync<IosVppEBookAssignment>(iosVppEBookAssignmentToCreate, cancellationToken).ConfigureAwait(false);
this.InitializeCollectionProperties(newEntity);
return newEntity;
}
/// <summary>
/// Deletes the specified IosVppEBookAssignment.
/// </summary>
/// <returns>The task to await.</returns>
public System.Threading.Tasks.Task DeleteAsync()
{
return this.DeleteAsync(CancellationToken.None);
}
/// <summary>
/// Deletes the specified IosVppEBookAssignment.
/// </summary>
/// <param name="cancellationToken">The <see cref="CancellationToken"/> for the request.</param>
/// <returns>The task to await.</returns>
public async System.Threading.Tasks.Task DeleteAsync(CancellationToken cancellationToken)
{
this.Method = "DELETE";
await this.SendAsync<IosVppEBookAssignment>(null, cancellationToken).ConfigureAwait(false);
}
/// <summary>
/// Gets the specified IosVppEBookAssignment.
/// </summary>
/// <returns>The IosVppEBookAssignment.</returns>
public System.Threading.Tasks.Task<IosVppEBookAssignment> GetAsync()
{
return this.GetAsync(CancellationToken.None);
}
/// <summary>
/// Gets the specified IosVppEBookAssignment.
/// </summary>
/// <param name="cancellationToken">The <see cref="CancellationToken"/> for the request.</param>
/// <returns>The IosVppEBookAssignment.</returns>
public async System.Threading.Tasks.Task<IosVppEBookAssignment> GetAsync(CancellationToken cancellationToken)
{
this.Method = "GET";
var retrievedEntity = await this.SendAsync<IosVppEBookAssignment>(null, cancellationToken).ConfigureAwait(false);
this.InitializeCollectionProperties(retrievedEntity);
return retrievedEntity;
}
/// <summary>
/// Updates the specified IosVppEBookAssignment using PATCH.
/// </summary>
/// <param name="iosVppEBookAssignmentToUpdate">The IosVppEBookAssignment to update.</param>
/// <returns>The updated IosVppEBookAssignment.</returns>
public System.Threading.Tasks.Task<IosVppEBookAssignment> UpdateAsync(IosVppEBookAssignment iosVppEBookAssignmentToUpdate)
{
return this.UpdateAsync(iosVppEBookAssignmentToUpdate, CancellationToken.None);
}
/// <summary>
/// Updates the specified IosVppEBookAssignment using PATCH.
/// </summary>
/// <param name="iosVppEBookAssignmentToUpdate">The IosVppEBookAssignment to update.</param>
/// <param name="cancellationToken">The <see cref="CancellationToken"/> for the request.</param>
/// <exception cref="ClientException">Thrown when an object returned in a response is used for updating an object in Microsoft Graph.</exception>
/// <returns>The updated IosVppEBookAssignment.</returns>
public async System.Threading.Tasks.Task<IosVppEBookAssignment> UpdateAsync(IosVppEBookAssignment iosVppEBookAssignmentToUpdate, CancellationToken cancellationToken)
{
if (iosVppEBookAssignmentToUpdate.AdditionalData != null)
{
if (iosVppEBookAssignmentToUpdate.AdditionalData.ContainsKey(Constants.HttpPropertyNames.ResponseHeaders) ||
iosVppEBookAssignmentToUpdate.AdditionalData.ContainsKey(Constants.HttpPropertyNames.StatusCode))
{
throw new ClientException(
new Error
{
Code = GeneratedErrorConstants.Codes.NotAllowed,
Message = String.Format(GeneratedErrorConstants.Messages.ResponseObjectUsedForUpdate, iosVppEBookAssignmentToUpdate.GetType().Name)
});
}
}
if (iosVppEBookAssignmentToUpdate.AdditionalData != null)
{
if (iosVppEBookAssignmentToUpdate.AdditionalData.ContainsKey(Constants.HttpPropertyNames.ResponseHeaders) ||
iosVppEBookAssignmentToUpdate.AdditionalData.ContainsKey(Constants.HttpPropertyNames.StatusCode))
{
throw new ClientException(
new Error
{
Code = GeneratedErrorConstants.Codes.NotAllowed,
Message = String.Format(GeneratedErrorConstants.Messages.ResponseObjectUsedForUpdate, iosVppEBookAssignmentToUpdate.GetType().Name)
});
}
}
this.ContentType = "application/json";
this.Method = "PATCH";
var updatedEntity = await this.SendAsync<IosVppEBookAssignment>(iosVppEBookAssignmentToUpdate, cancellationToken).ConfigureAwait(false);
this.InitializeCollectionProperties(updatedEntity);
return updatedEntity;
}
/// <summary>
/// Adds the specified expand value to the request.
/// </summary>
/// <param name="value">The expand value.</param>
/// <returns>The request object to send.</returns>
public IIosVppEBookAssignmentRequest Expand(string value)
{
this.QueryOptions.Add(new QueryOption("$expand", value));
return this;
}
/// <summary>
/// Adds the specified expand value to the request.
/// </summary>
/// <param name="expandExpression">The expression from which to calculate the expand value.</param>
/// <returns>The request object to send.</returns>
public IIosVppEBookAssignmentRequest Expand(Expression<Func<IosVppEBookAssignment, object>> expandExpression)
{
if (expandExpression == null)
{
throw new ArgumentNullException(nameof(expandExpression));
}
string error;
string value = ExpressionExtractHelper.ExtractMembers(expandExpression, out error);
if (value == null)
{
throw new ArgumentException(error, nameof(expandExpression));
}
else
{
this.QueryOptions.Add(new QueryOption("$expand", value));
}
return this;
}
/// <summary>
/// Adds the specified select value to the request.
/// </summary>
/// <param name="value">The select value.</param>
/// <returns>The request object to send.</returns>
public IIosVppEBookAssignmentRequest Select(string value)
{
this.QueryOptions.Add(new QueryOption("$select", value));
return this;
}
/// <summary>
/// Adds the specified select value to the request.
/// </summary>
/// <param name="selectExpression">The expression from which to calculate the select value.</param>
/// <returns>The request object to send.</returns>
public IIosVppEBookAssignmentRequest Select(Expression<Func<IosVppEBookAssignment, object>> selectExpression)
{
if (selectExpression == null)
{
throw new ArgumentNullException(nameof(selectExpression));
}
string error;
string value = ExpressionExtractHelper.ExtractMembers(selectExpression, out error);
if (value == null)
{
throw new ArgumentException(error, nameof(selectExpression));
}
else
{
this.QueryOptions.Add(new QueryOption("$select", value));
}
return this;
}
/// <summary>
/// Initializes any collection properties after deserialization, like next requests for paging.
/// </summary>
/// <param name="iosVppEBookAssignmentToInitialize">The <see cref="IosVppEBookAssignment"/> with the collection properties to initialize.</param>
private void InitializeCollectionProperties(IosVppEBookAssignment iosVppEBookAssignmentToInitialize)
{
}
}
}
| {
"pile_set_name": "Github"
} |
'use strict'
import { combineReducers } from 'redux'
import address from './address'
import todos from './todos'
import visibilityFilter from './visibility-filter'
export default combineReducers({
address,
todos,
visibilityFilter
})
| {
"pile_set_name": "Github"
} |
// Copyright 2011 Google Inc. All Rights Reserved.
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
// copyright notice, this list of conditions and the following disclaimer
// in the documentation and/or other materials provided with the
// distribution.
// * Neither the name of Google Inc. nor the names of its
// contributors may be used to endorse or promote products derived from
// this software without specific prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#ifndef THIRD_PARTY_SNAPPY_SNAPPY_SINKSOURCE_H_
#define THIRD_PARTY_SNAPPY_SNAPPY_SINKSOURCE_H_
#include <stddef.h>
namespace snappy {
// A Sink is an interface that consumes a sequence of bytes.
class Sink {
public:
Sink() { }
virtual ~Sink();
// Append "bytes[0,n-1]" to this.
virtual void Append(const char* bytes, size_t n) = 0;
// Returns a writable buffer of the specified length for appending.
// May return a pointer to the caller-owned scratch buffer which
// must have at least the indicated length. The returned buffer is
// only valid until the next operation on this Sink.
//
// After writing at most "length" bytes, call Append() with the
// pointer returned from this function and the number of bytes
// written. Many Append() implementations will avoid copying
// bytes if this function returned an internal buffer.
//
// If a non-scratch buffer is returned, the caller may only pass a
// prefix of it to Append(). That is, it is not correct to pass an
// interior pointer of the returned array to Append().
//
// The default implementation always returns the scratch buffer.
virtual char* GetAppendBuffer(size_t length, char* scratch);
// For higher performance, Sink implementations can provide custom
// AppendAndTakeOwnership() and GetAppendBufferVariable() methods.
// These methods can reduce the number of copies done during
// compression/decompression.
// Append "bytes[0,n-1] to the sink. Takes ownership of "bytes"
// and calls the deleter function as (*deleter)(deleter_arg, bytes, n)
// to free the buffer. deleter function must be non NULL.
//
// The default implementation just calls Append and frees "bytes".
// Other implementations may avoid a copy while appending the buffer.
virtual void AppendAndTakeOwnership(
char* bytes, size_t n, void (*deleter)(void*, const char*, size_t),
void *deleter_arg);
// Returns a writable buffer for appending and writes the buffer's capacity to
// *allocated_size. Guarantees *allocated_size >= min_size.
// May return a pointer to the caller-owned scratch buffer which must have
// scratch_size >= min_size.
//
// The returned buffer is only valid until the next operation
// on this ByteSink.
//
// After writing at most *allocated_size bytes, call Append() with the
// pointer returned from this function and the number of bytes written.
// Many Append() implementations will avoid copying bytes if this function
// returned an internal buffer.
//
// If the sink implementation allocates or reallocates an internal buffer,
// it should use the desired_size_hint if appropriate. If a caller cannot
// provide a reasonable guess at the desired capacity, it should set
// desired_size_hint = 0.
//
// If a non-scratch buffer is returned, the caller may only pass
// a prefix to it to Append(). That is, it is not correct to pass an
// interior pointer to Append().
//
// The default implementation always returns the scratch buffer.
virtual char* GetAppendBufferVariable(
size_t min_size, size_t desired_size_hint, char* scratch,
size_t scratch_size, size_t* allocated_size);
private:
// No copying
Sink(const Sink&);
void operator=(const Sink&);
};
// A Source is an interface that yields a sequence of bytes
class Source {
public:
Source() { }
virtual ~Source();
// Return the number of bytes left to read from the source
virtual size_t Available() const = 0;
// Peek at the next flat region of the source. Does not reposition
// the source. The returned region is empty iff Available()==0.
//
// Returns a pointer to the beginning of the region and store its
// length in *len.
//
// The returned region is valid until the next call to Skip() or
// until this object is destroyed, whichever occurs first.
//
// The returned region may be larger than Available() (for example
// if this ByteSource is a view on a substring of a larger source).
// The caller is responsible for ensuring that it only reads the
// Available() bytes.
virtual const char* Peek(size_t* len) = 0;
// Skip the next n bytes. Invalidates any buffer returned by
// a previous call to Peek().
// REQUIRES: Available() >= n
virtual void Skip(size_t n) = 0;
private:
// No copying
Source(const Source&);
void operator=(const Source&);
};
// A Source implementation that yields the contents of a flat array
class ByteArraySource : public Source {
public:
ByteArraySource(const char* p, size_t n) : ptr_(p), left_(n) { }
virtual ~ByteArraySource();
virtual size_t Available() const;
virtual const char* Peek(size_t* len);
virtual void Skip(size_t n);
private:
const char* ptr_;
size_t left_;
};
// A Sink implementation that writes to a flat array without any bound checks.
class UncheckedByteArraySink : public Sink {
public:
explicit UncheckedByteArraySink(char* dest) : dest_(dest) { }
virtual ~UncheckedByteArraySink();
virtual void Append(const char* data, size_t n);
virtual char* GetAppendBuffer(size_t len, char* scratch);
virtual char* GetAppendBufferVariable(
size_t min_size, size_t desired_size_hint, char* scratch,
size_t scratch_size, size_t* allocated_size);
virtual void AppendAndTakeOwnership(
char* bytes, size_t n, void (*deleter)(void*, const char*, size_t),
void *deleter_arg);
// Return the current output pointer so that a caller can see how
// many bytes were produced.
// Note: this is not a Sink method.
char* CurrentDestination() const { return dest_; }
private:
char* dest_;
};
} // namespace snappy
#endif // THIRD_PARTY_SNAPPY_SNAPPY_SINKSOURCE_H_
| {
"pile_set_name": "Github"
} |
#include "libavutil/file_open.c"
| {
"pile_set_name": "Github"
} |
/* eslint no-console:0 */
/**
* This is the main entry point for KaTeX. Here, we expose functions for
* rendering expressions either to DOM nodes or to markup strings.
*
* We also expose the ParseError class to check if errors thrown from KaTeX are
* errors in the expression, or errors in javascript handling.
*/
var ParseError = require("./src/ParseError");
var Settings = require("./src/Settings");
var buildTree = require("./src/buildTree");
var parseTree = require("./src/parseTree");
var utils = require("./src/utils");
/**
* Parse and build an expression, and place that expression in the DOM node
* given.
*/
var render = function(expression, baseNode, options) {
utils.clearNode(baseNode);
var settings = new Settings(options);
var tree = parseTree(expression, settings);
var node = buildTree(tree, expression, settings).toNode();
baseNode.appendChild(node);
};
// KaTeX's styles don't work properly in quirks mode. Print out an error, and
// disable rendering.
if (typeof document !== "undefined") {
if (document.compatMode !== "CSS1Compat") {
typeof console !== "undefined" && console.warn(
"Warning: KaTeX doesn't work in quirks mode. Make sure your " +
"website has a suitable doctype.");
render = function() {
throw new ParseError("KaTeX doesn't work in quirks mode.");
};
}
}
/**
* Parse and build an expression, and return the markup for that.
*/
var renderToString = function(expression, options) {
var settings = new Settings(options);
var tree = parseTree(expression, settings);
return buildTree(tree, expression, settings).toMarkup();
};
/**
* Parse an expression and return the parse tree.
*/
var generateParseTree = function(expression, options) {
var settings = new Settings(options);
return parseTree(expression, settings);
};
module.exports = {
render: render,
renderToString: renderToString,
/**
* NOTE: This method is not currently recommended for public use.
* The internal tree representation is unstable and is very likely
* to change. Use at your own risk.
*/
__parse: generateParseTree,
ParseError: ParseError,
};
| {
"pile_set_name": "Github"
} |
<?xml version="1.0" encoding="utf-8"?>
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=301880
-->
<configuration>
<appSettings>
<add key="webpages:Version" value="3.0.0.0" />
<add key="webpages:Enabled" value="false" />
<add key="ClientValidationEnabled" value="true" />
<add key="UnobtrusiveJavaScriptEnabled" value="true" />
</appSettings>
<system.web>
<compilation debug="true" targetFramework="4.5.2" />
<httpRuntime targetFramework="4.5.2" />
</system.web>
<system.webServer>
<handlers>
<remove name="ExtensionlessUrlHandler-Integrated-4.0" />
<remove name="OPTIONSVerbHandler" />
<remove name="TRACEVerbHandler" />
<add name="ExtensionlessUrlHandler-Integrated-4.0" path="*." verb="*" type="System.Web.Handlers.TransferRequestHandler" preCondition="integratedMode,runtimeVersionv4.0" />
</handlers>
</system.webServer>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="Newtonsoft.Json" culture="neutral" publicKeyToken="30ad4fe6b2a6aeed" />
<bindingRedirect oldVersion="0.0.0.0-9.0.0.0" newVersion="9.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Optimization" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="1.1.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="WebGrease" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="0.0.0.0-1.6.5135.21930" newVersion="1.6.5135.21930" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Helpers" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.Mvc" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="System.Web.WebPages" publicKeyToken="31bf3856ad364e35" />
<bindingRedirect oldVersion="1.0.0.0-3.0.0.0" newVersion="3.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Validation" publicKeyToken="2fc06f0d701809a7" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-2.3.0.0" newVersion="2.3.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Antlr3.Runtime" publicKeyToken="eb42632606e9261f" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-3.5.0.2" newVersion="3.5.0.2" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="PCLCrypto" publicKeyToken="d4421c8a4786956c" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-2.0.0.0" newVersion="2.0.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.WindowsAzure.Storage" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-7.2.0.0" newVersion="7.2.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.Data.Services.Client" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-5.7.0.0" newVersion="5.7.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.Data.OData" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-5.7.0.0" newVersion="5.7.0.0" />
</dependentAssembly>
<dependentAssembly>
<assemblyIdentity name="Microsoft.Data.Edm" publicKeyToken="31bf3856ad364e35" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-5.7.0.0" newVersion="5.7.0.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:6 /nowarn:1659;1699;1701" />
<compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:14 /nowarn:41008 /define:_MYTYPE=\"Web\" /optionInfer+" />
</compilers>
</system.codedom>
<system.serviceModel>
<extensions>
<!-- In this extension section we are introducing all known service bus extensions. User can remove the ones they don't need. -->
<behaviorExtensions>
<add name="connectionStatusBehavior" type="Microsoft.ServiceBus.Configuration.ConnectionStatusElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="transportClientEndpointBehavior" type="Microsoft.ServiceBus.Configuration.TransportClientEndpointBehaviorElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="serviceRegistrySettings" type="Microsoft.ServiceBus.Configuration.ServiceRegistrySettingsElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
</behaviorExtensions>
<bindingElementExtensions>
<add name="netMessagingTransport" type="Microsoft.ServiceBus.Messaging.Configuration.NetMessagingTransportExtensionElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="tcpRelayTransport" type="Microsoft.ServiceBus.Configuration.TcpRelayTransportElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="httpRelayTransport" type="Microsoft.ServiceBus.Configuration.HttpRelayTransportElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="httpsRelayTransport" type="Microsoft.ServiceBus.Configuration.HttpsRelayTransportElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="onewayRelayTransport" type="Microsoft.ServiceBus.Configuration.RelayedOnewayTransportElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
</bindingElementExtensions>
<bindingExtensions>
<add name="basicHttpRelayBinding" type="Microsoft.ServiceBus.Configuration.BasicHttpRelayBindingCollectionElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="webHttpRelayBinding" type="Microsoft.ServiceBus.Configuration.WebHttpRelayBindingCollectionElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="ws2007HttpRelayBinding" type="Microsoft.ServiceBus.Configuration.WS2007HttpRelayBindingCollectionElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="netTcpRelayBinding" type="Microsoft.ServiceBus.Configuration.NetTcpRelayBindingCollectionElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="netOnewayRelayBinding" type="Microsoft.ServiceBus.Configuration.NetOnewayRelayBindingCollectionElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="netEventRelayBinding" type="Microsoft.ServiceBus.Configuration.NetEventRelayBindingCollectionElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
<add name="netMessagingBinding" type="Microsoft.ServiceBus.Messaging.Configuration.NetMessagingBindingCollectionElement, Microsoft.ServiceBus, Culture=neutral, PublicKeyToken=31bf3856ad364e35" />
</bindingExtensions>
</extensions>
</system.serviceModel>
</configuration>
| {
"pile_set_name": "Github"
} |
// Licensed to the Apache Software Foundation (ASF) under one
// or more contributor license agreements. See the NOTICE file
// distributed with this work for additional information
// regarding copyright ownership. The ASF licenses this file
// to you under the Apache License, Version 2.0 (the
// "License"); you may not use this file except in compliance
// with the License. You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing,
// software distributed under the License is distributed on an
// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
// KIND, either express or implied. See the License for the
// specific language governing permissions and limitations
// under the License.
#pragma once
#include <memory>
#include <set>
#include <string>
#include <utility>
#include <vector>
#include <boost/optional/optional.hpp>
#include <glog/logging.h>
#include <sasl/sasl.h>
#include "kudu/gutil/port.h"
#include "kudu/rpc/messenger.h"
#include "kudu/rpc/negotiation.h"
#include "kudu/rpc/remote_user.h"
#include "kudu/rpc/rpc_header.pb.h"
#include "kudu/rpc/sasl_common.h"
#include "kudu/rpc/sasl_helper.h"
#include "kudu/security/security_flags.h"
#include "kudu/security/tls_handshake.h"
#include "kudu/util/monotime.h"
#include "kudu/util/net/socket.h"
#include "kudu/util/status.h"
namespace kudu {
class Sockaddr;
class faststring;
namespace security {
class TlsContext;
class TokenVerifier;
}
namespace rpc {
// Class for doing KRPC negotiation with a remote client over a bidirectional socket.
// Operations on this class are NOT thread-safe.
class ServerNegotiation {
public:
// Creates a new server negotiation instance, taking ownership of the
// provided socket. After completing the negotiation process by setting the
// desired options and calling Negotiate((), the socket can be retrieved with
// release_socket().
//
// The provided TlsContext must outlive this negotiation instance.
ServerNegotiation(std::unique_ptr<Socket> socket,
const security::TlsContext* tls_context,
const security::TokenVerifier* token_verifier,
RpcEncryption encryption,
std::string sasl_proto_name);
// Enable PLAIN authentication.
// Despite PLAIN authentication taking a username and password, we disregard
// the password and use this as a "unauthenticated" mode.
// Must be called before Negotiate().
Status EnablePlain();
// Enable GSSAPI (Kerberos) authentication.
// Must be called before Negotiate().
Status EnableGSSAPI();
// Returns mechanism negotiated by this connection.
// Must be called after Negotiate().
SaslMechanism::Type negotiated_mechanism() const;
// Returns the negotiated authentication type for the connection.
// Must be called after Negotiate().
AuthenticationType negotiated_authn() const {
DCHECK_NE(negotiated_authn_, AuthenticationType::INVALID);
return negotiated_authn_;
}
// Returns true if TLS was negotiated.
// Must be called after Negotiate().
bool tls_negotiated() const {
return tls_negotiated_;
}
// Returns the set of RPC system features supported by the remote client.
// Must be called after Negotiate().
std::set<RpcFeatureFlag> client_features() const {
return client_features_;
}
// Returns the set of RPC system features supported by the remote client.
// Must be called after Negotiate().
// Subsequent calls to this method or client_features() will return an empty set.
std::set<RpcFeatureFlag> take_client_features() {
return std::move(client_features_);
}
// Name of the user that was authenticated.
// Must be called after a successful Negotiate().
//
// Subsequent calls will return bogus data.
RemoteUser take_authenticated_user() {
return std::move(authenticated_user_);
}
// Specify the fully-qualified domain name of the remote server.
// Must be called before Negotiate(). Required for some mechanisms.
void set_server_fqdn(const std::string& domain_name);
// Set deadline for connection negotiation.
void set_deadline(const MonoTime& deadline);
Socket* socket() const { return socket_.get(); }
// Returns the socket owned by this server negotiation. The caller will own
// the socket after this call, and the negotiation instance should no longer
// be used. Must be called after Negotiate().
std::unique_ptr<Socket> release_socket() { return std::move(socket_); }
// Negotiate with the remote client. Should only be called once per
// ServerNegotiation and socket instance, after all options have been set.
//
// Returns OK on success, otherwise may return NotAuthorized, NotSupported, or
// another non-OK status.
Status Negotiate() WARN_UNUSED_RESULT;
// SASL callback for plugin options, supported mechanisms, etc.
// Returns SASL_FAIL if the option is not handled, which does not fail the handshake.
int GetOptionCb(const char* plugin_name, const char* option,
const char** result, unsigned* len);
// SASL callback for PLAIN authentication via SASL_CB_SERVER_USERDB_CHECKPASS.
int PlainAuthCb(sasl_conn_t* conn, const char* user, const char* pass,
unsigned passlen, struct propctx* propctx);
// Perform a "pre-flight check" that everything required to act as a Kerberos
// server is properly set up.
static Status PreflightCheckGSSAPI(const std::string& sasl_proto_name) WARN_UNUSED_RESULT;
private:
// Parse a negotiate request from the client, deserializing it into 'msg'.
// If the request is malformed, sends an error message to the client.
Status RecvNegotiatePB(NegotiatePB* msg, faststring* recv_buf) WARN_UNUSED_RESULT;
// Encode and send the specified negotiate response message to the server.
Status SendNegotiatePB(const NegotiatePB& msg) WARN_UNUSED_RESULT;
// Encode and send the specified RPC error message to the client.
// Calls Status.ToString() for the embedded error message.
Status SendError(ErrorStatusPB::RpcErrorCodePB code, const Status& err) WARN_UNUSED_RESULT;
// Parse and validate connection header.
Status ValidateConnectionHeader(faststring* recv_buf) WARN_UNUSED_RESULT;
// Initialize the SASL server negotiation instance.
Status InitSaslServer() WARN_UNUSED_RESULT;
// Handle case when client sends NEGOTIATE request. Builds the set of
// client-supported RPC features, determines a mutually supported
// authentication type to use for the connection, and sends a NEGOTIATE
// response.
Status HandleNegotiate(const NegotiatePB& request) WARN_UNUSED_RESULT;
// Handle a TLS_HANDSHAKE request message from the server.
Status HandleTlsHandshake(const NegotiatePB& request) WARN_UNUSED_RESULT;
// Send a TLS_HANDSHAKE response message to the server with the provided token.
Status SendTlsHandshake(std::string tls_token) WARN_UNUSED_RESULT;
// Authenticate the client using SASL. Populates the 'authenticated_user_'
// field with the SASL principal.
// 'recv_buf' allows a receive buffer to be reused.
Status AuthenticateBySasl(faststring* recv_buf) WARN_UNUSED_RESULT;
// Authenticate the client using a token. Populates the
// 'authenticated_user_' field with the token's principal.
// 'recv_buf' allows a receive buffer to be reused.
Status AuthenticateByToken(faststring* recv_buf) WARN_UNUSED_RESULT;
// Authenticate the client using the client's TLS certificate. Populates the
// 'authenticated_user_' field with the certificate's subject.
Status AuthenticateByCertificate() WARN_UNUSED_RESULT;
// Handle case when client sends SASL_INITIATE request.
// Returns Status::OK if the SASL negotiation is complete, or
// Status::Incomplete if a SASL_RESPONSE step is expected.
Status HandleSaslInitiate(const NegotiatePB& request) WARN_UNUSED_RESULT;
// Handle case when client sends SASL_RESPONSE request.
Status HandleSaslResponse(const NegotiatePB& request) WARN_UNUSED_RESULT;
// Send a SASL_CHALLENGE response to the client with a challenge token.
Status SendSaslChallenge(const char* challenge, unsigned clen) WARN_UNUSED_RESULT;
// Send a SASL_SUCCESS response to the client.
Status SendSaslSuccess() WARN_UNUSED_RESULT;
// Receive and validate the ConnectionContextPB.
Status RecvConnectionContext(faststring* recv_buf) WARN_UNUSED_RESULT;
// Returns true if connection is from trusted subnets or local networks.
static bool IsTrustedConnection(const Sockaddr& addr);
// The socket to the remote client.
std::unique_ptr<Socket> socket_;
// SASL state.
std::vector<sasl_callback_t> callbacks_;
std::unique_ptr<sasl_conn_t, SaslDeleter> sasl_conn_;
SaslHelper helper_;
boost::optional<std::string> nonce_;
// TLS state.
const security::TlsContext* tls_context_;
security::TlsHandshake tls_handshake_;
const RpcEncryption encryption_;
bool tls_negotiated_;
// TSK state.
const security::TokenVerifier* token_verifier_;
// The set of features supported by the client and server. Filled in during negotiation.
std::set<RpcFeatureFlag> client_features_;
std::set<RpcFeatureFlag> server_features_;
// The successfully-authenticated user, if applicable. Filled in during
// negotiation.
RemoteUser authenticated_user_;
// The authentication type. Filled in during negotiation.
AuthenticationType negotiated_authn_;
// The SASL mechanism. Filled in during negotiation if the negotiated
// authentication type is SASL.
SaslMechanism::Type negotiated_mech_;
// The SASL protocol name that is used for the SASL negotiation.
const std::string sasl_proto_name_;
// Negotiation timeout deadline.
MonoTime deadline_;
};
} // namespace rpc
} // namespace kudu
| {
"pile_set_name": "Github"
} |
<template>
<div>
<div class="q-layout-padding" style="max-width: 500px;">
<h4>Chat with avatar</h4>
<p>To mix messages with avatar and without avatar in the same thread, use a placeholder avatar image.</p>
<q-chat-message
v-for="(msg, index) in messages"
:key="index"
v-bind="msg"
/>
<q-chat-message
name="Vladimir"
avatar="https://cdn.quasar.dev/img/blueish.jpg"
>
<q-spinner-dots size="2rem" />
</q-chat-message>
<br><br><br><br>
<h4>Chat using avatar slot</h4>
<q-chat-message
name="Vladimir"
:text="['Use your own spacing or class q-message-avatar']"
>
<template v-slot:avatar>
<q-icon name="face" size="4em" />
</template>
</q-chat-message>
<br><br><br><br>
<h4>Chat without avatar</h4>
<q-chat-message
v-for="(msg, index) in messagesWithoutAvatar"
:key="1000 + index"
v-bind="msg"
/>
<q-chat-message
name="Vladimir"
>
<q-spinner-dots size="2rem" />
</q-chat-message>
</div>
</div>
</template>
<script>
export default {
data () {
const messages = [
{
label: 'Sunday, 19th'
},
{
name: 'Vladimir',
text: ['How are you?'],
avatar: 'https://cdn.quasar.dev/img/boy-avatar.png',
stamp: 'Yesterday 13:34'
},
{
name: 'Jane',
text: ['I\'m good, thank you!', 'And you?'],
sent: true,
textColor: 'white',
bgColor: 'black',
avatar: 'https://cdn.quasar.dev/img/linux-avatar.png',
stamp: 'Yesterday at 13:50'
},
{
name: 'Jane',
text: ['And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? And you? '],
sent: true,
avatar: 'https://cdn.quasar.dev/img/linux-avatar.png',
stamp: 'Yesterday at 13:51'
},
{
name: '<strong class="text-uppercase">Trusted Vladimir</strong>',
text: ['I\'m also fine, thank you. <span class="text-primary">But I feel like writing a very long text here too test the avatar.</span>'],
avatar: 'https://cdn.quasar.dev/img/boy-avatar.png',
stamp: 'Yesterday 13:34'
},
{
name: '<strong class="text-uppercase">Untrusted Vladimir</strong>',
text: ['I\'m also fine, thank you. <span class="text-primary">But I feel like writing a very long text here too test the avatar.</span>'],
textSanitize: true,
avatar: 'https://cdn.quasar.dev/img/boy-avatar.png',
stamp: 'Yesterday 13:34'
},
{
name: 'Vladimir',
text: ['I\'m also fine, thank you. <span class="text-primary">But I feel like writing a very long text here too test the avatar.</span>'],
avatar: 'https://cdn.quasar.dev/img/boy-avatar.png',
stamp: 'Yesterday 13:34'
},
{
label: '<span class="bg-primary text-white q-pa-sm rounded-borders">Sunday, 19th</span>'
},
{
name: 'Vladimir',
bgColor: 'amber',
textColor: 'white',
text: ['Fine. Nice weather today, right?', 'Hmm...'],
avatar: 'https://cdn.quasar.dev/img/boy-avatar.png',
stamp: '13:55'
},
{
label: 'Sunday, 19th'
},
{
name: 'Vladimir',
text: ['How are you?'],
avatar: 'https://cdn.quasar.dev/img/boy-avatar.png',
stamp: 'Yesterday 13:34'
},
{
name: 'Jane',
text: ['I\'m good, thank you!', 'And you?'],
sent: true,
avatar: 'https://cdn.quasar.dev/img/linux-avatar.png',
stamp: 'Yesterday at 13:50'
},
{
name: 'Jane',
text: ['And you?'],
sent: true,
avatar: 'https://cdn.quasar.dev/img/linux-avatar.png',
stamp: 'Yesterday at 13:51'
},
{
label: 'Sunday, 19th'
},
{
name: 'Vladimir',
text: ['Fine. Nice weather today, right?', 'Hmm...'],
avatar: 'https://cdn.quasar.dev/img/boy-avatar.png',
stamp: '13:55'
},
{
label: 'Sunday, 19th'
},
{
name: 'Vladimir',
text: ['How are you?'],
avatar: 'https://cdn.quasar.dev/img/boy-avatar.png',
stamp: 'Yesterday 13:34'
},
{
name: 'Jane',
text: ['I\'m good, thank you!', 'And you?'],
sent: true,
avatar: 'https://cdn.quasar.dev/img/linux-avatar.png',
stamp: 'Yesterday at 13:50'
},
{
name: 'Jane',
text: ['And you?'],
sent: true,
avatar: 'https://cdn.quasar.dev/img/linux-avatar.png',
stamp: 'Yesterday at 13:51'
},
{
label: 'Sunday, 19th'
},
{
name: 'Vladimir',
text: ['Fine. Nice weather today, right?', 'Hmm...'],
avatar: 'https://cdn.quasar.dev/img/boy-avatar.png',
stamp: '13:55'
},
{
label: 'Sunday, 19th'
},
{
name: 'Vladimir',
text: ['How are you?'],
avatar: 'https://cdn.quasar.dev/img/boy-avatar.png',
stamp: 'Yesterday 13:34'
},
{
name: 'Jane',
text: ['I\'m good, thank you!', 'And you?'],
sent: true,
avatar: 'https://cdn.quasar.dev/img/linux-avatar.png',
stamp: 'Yesterday at 13:50'
},
{
name: 'Jane',
text: ['And you?'],
sent: true,
avatar: 'https://cdn.quasar.dev/img/linux-avatar.png',
stamp: 'Yesterday at 13:51'
},
{
label: 'Sunday, 19th'
},
{
name: 'Vladimir',
text: ['Fine. Nice weather today, right?', 'Hmm...'],
avatar: 'https://cdn.quasar.dev/img/boy-avatar.png',
stamp: '13:55'
}
]
return {
message: '',
messages,
messagesWithoutAvatar: messages.map((msg) => ({
...msg,
avatar: void 0
}))
}
}
}
</script>
| {
"pile_set_name": "Github"
} |
USING: compiler.cfg.parallel-copy tools.test arrays
compiler.cfg.registers namespaces compiler.cfg.instructions
cpu.architecture ;
IN: compiler.cfg.parallel-copy.tests
SYMBOL: temp
: test-parallel-copy ( mapping -- seq )
3 vreg-counter set-global parallel-copy ;
{
{ }
} [
H{ } test-parallel-copy
] unit-test
{
{
T{ ##copy f 4 2 any-rep }
T{ ##copy f 2 1 any-rep }
T{ ##copy f 1 4 any-rep }
}
} [
H{
{ 1 2 }
{ 2 1 }
} test-parallel-copy
] unit-test
{
{
T{ ##copy f 1 2 any-rep }
T{ ##copy f 3 4 any-rep }
}
} [
H{
{ 1 2 }
{ 3 4 }
} test-parallel-copy
] unit-test
{
{
T{ ##copy f 1 3 any-rep }
T{ ##copy f 2 1 any-rep }
}
} [
H{
{ 1 3 }
{ 2 3 }
} test-parallel-copy
] unit-test
{
{
T{ ##copy f 4 3 any-rep }
T{ ##copy f 3 2 any-rep }
T{ ##copy f 2 1 any-rep }
T{ ##copy f 1 4 any-rep }
}
} [
{
{ 2 1 }
{ 3 2 }
{ 1 3 }
{ 4 3 }
} test-parallel-copy
] unit-test
| {
"pile_set_name": "Github"
} |
#Maintained by: RehabMan for: Laptop Patches
#battery_Acer-Aspire-5737z.txt
# created by 5737Z via RehabMan guide 2014-05-19
# some cleanup by RehabMan
# works for:
# Acer Aspire 5737z
# fix_HID_pnp.txt (from repository)
into_all all code_regex (Name\s+\(_HID,\s+\")\*pnp(.*\") replaceall_matched begin %1PNP%2 end;
into_all all code_regex (Name\s+\(_HID,\s+\")pnp(.*\") replaceall_matched begin %1PNP%2 end;
# 16-bit EC (fan related - copied from repository)
into device label EC0 code_regex ERIB,\s+16 replace_matched begin ERI0,8,ERI1,8 end;
into method label FANG code_regex Store\s+\(Arg0,\s+ERIB\) replace_matched
begin
Store(Arg0, ERI0) Store(ShiftRight(Arg0, 8), ERI1)
end;
into method label FANW code_regex Store\s+\(Arg0,\s+ERIB\) replace_matched
begin
Store(Arg0, ERI0) Store(ShiftRight(Arg0, 8), ERI1)
end;
#16-bit EC
into device label EC0 code_regex BATM,\s+16, replace_matched begin ATM0,8,ATM1,8, end;
into device label EC0 code_regex BRC0,\s+16, replace_matched begin RC00,8,RC01,8, end;
into device label EC0 code_regex BSN0,\s+16, replace_matched begin SN00,8,SN01,8, end;
into device label EC0 code_regex BPV0,\s+16, replace_matched begin PV00,8,PV01,8, end;
into device label EC0 code_regex BDV0,\s+16, replace_matched begin DV00,8,DV01,8, end;
into device label EC0 code_regex BDC0,\s+16, replace_matched begin DC00,8,DC01,8, end;
into device label EC0 code_regex BFC0,\s+16, replace_matched begin FC00,8,FC01,8, end;
into device label EC0 code_regex BSCU,\s+16, replace_matched begin SCU0,8,SCU1,8, end;
into device label EC0 code_regex BAC0,\s+16, replace_matched begin AC00,8,AC01,8, end;
into device label EC0 code_regex BTMA,\s+16, replace_matched begin TMA0,8,TMA1,8, end;
into device label EC0 code_regex BTSS,\s+16, replace_matched begin TSS0,8,TSS1,8, end;
into device label EC0 code_regex BSC1,\s+16, replace_matched begin SC10,8,SC11,8, end;
into device label EC0 code_regex BSC2,\s+16, replace_matched begin SC20,8,SC21,8, end;
into device label EC0 code_regex BSC3,\s+16, replace_matched begin SC30,8,SC31,8, end;
into device label EC0 code_regex BSC4,\s+16, replace_matched begin SC40,8,SC41,8, end;
into device label EC0 code_regex BDME,\s+16, replace_matched begin DME0,8,DME1,8, end;
into device label EC0 code_regex BSCS,\s+16, replace_matched begin SCS0,8,SCS1,8, end;
into device label EC0 code_regex BDAD,\s+16, replace_matched begin DAD0,8,DAD1,8, end;
into device label EC0 code_regex BACV,\s+16, replace_matched begin ACV0,8,ACV1,8, end;
into device label EC0 code_regex BDFC,\s+16 replace_matched begin DFC0,8,DFC1,8, end;
into method label Z00G code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BATM, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.ATM0,\\_SB.PCI0.LPC0.EC0.ATM1), end;
into method label Z00G code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BRC0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.RC00,\\_SB.PCI0.LPC0.EC0.RC01), end;
into method label Z00G code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BSN0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.SN00,\\_SB.PCI0.LPC0.EC0.SN01), end;
into method label Z00G code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BPV0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.PV00,\\_SB.PCI0.LPC0.EC0.PV01), end;
into method label _BST code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BPV0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.PV00,\\_SB.PCI0.LPC0.EC0.PV01), end;
into method label Z00G code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BDV0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.DV00,\\_SB.PCI0.LPC0.EC0.DV01), end;
into method label _BIF code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BDV0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.DV00,\\_SB.PCI0.LPC0.EC0.DV01), end;
into method label Z00G code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BDC0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.DC00,\\_SB.PCI0.LPC0.EC0.DC01), end;
into method label _BIF code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BDC0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.DC00,\\_SB.PCI0.LPC0.EC0.DC01), end;
into method label Z00G code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BFC0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.FC00,\\_SB.PCI0.LPC0.EC0.FC01), end;
into method label _BIF code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BFC0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.FC00,\\_SB.PCI0.LPC0.EC0.FC01), end;
into method label _BST code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BFC0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.FC00,\\_SB.PCI0.LPC0.EC0.FC01), end;
into method label Z00G code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BSCU, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.SCU0,\\_SB.PCI0.LPC0.EC0.SCU1), end;
into method label _BST code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BAC0, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.AC00,\\_SB.PCI0.LPC0.EC0.AC01), end;
into method label Z00G code_regex \(Local1,\s+\\\_SB\.PCI0\.LPC0\.EC0\.BTMA\) replaceall_matched begin (Local1, B1B2(\\_SB.PCI0.LPC0.EC0.TMA0,\\_SB.PCI0.LPC0.EC0.TMA1)) end;
into method label Z00G code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BDME, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.DME0,\\_SB.PCI0.LPC0.EC0.DME1), end;
into method label Z00G code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BDAD, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.DAD0,\\_SB.PCI0.LPC0.EC0.DAD1), end;
into method label Z00G code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BDFC, replaceall_matched begin (B1B2(\\_SB.PCI0.LPC0.EC0.DFC0,\\_SB.PCI0.LPC0.EC0.DFC1), end;
# 56-bit conversion based on offsets in DSDT
#
#
# OperationRegion (ERAM, EmbeddedControl, 0x00, 0xFF)
# Field (ERAM, ByteAcc, Lock, Preserve)
# {
# Offset (0x08),
# BATM, 16,
# Offset (0x19),
# BATD, 56,
#
# 56-bit EC
into device label EC0 code_regex (BATD,)\s+(56) replace_matched begin BATX,%2,//%1%2 end;
into method label _BIF code_regex \(\\_SB\.PCI0\.LPC0\.EC0\.BATD, replaceall_matched begin (\\_SB.PCI0.LPC0.EC0.RECB(0x19,56), end;
# convert two 8-bit EC fields to 16-bit and return
into method label B1B2 remove_entry;
into definitionblock code_regex . insert
begin
Method (B1B2, 2, NotSerialized) { Return(Or(Arg0, ShiftLeft(Arg1, 8))) }\n
end;
# utility methods to read buffers from/to EC
into method label B1B4 remove_entry;
into definitionblock code_regex . insert
begin
Method (B1B4, 4, NotSerialized)\n
{\n
Store(Arg3, Local0)\n
Or(Arg2, ShiftLeft(Local0, 8), Local0)\n
Or(Arg1, ShiftLeft(Local0, 8), Local0)\n
Or(Arg0, ShiftLeft(Local0, 8), Local0)\n
Return(Local0)\n
}\n
end;
into method label RE1B parent_label EC0 remove_entry;
into method label RECB parent_label EC0 remove_entry;
into device label EC0 insert
begin
Method (RE1B, 1, NotSerialized)\n
{\n
OperationRegion(ERAM, EmbeddedControl, Arg0, 1)\n
Field(ERAM, ByteAcc, NoLock, Preserve) { BYTE, 8 }\n
Return(BYTE)\n
}\n
Method (RECB, 2, Serialized)\n
{\n
ShiftRight(Arg1, 3, Arg1)\n
Name(TEMP, Buffer(Arg1) { })\n
Add(Arg0, Arg1, Arg1)\n
Store(0, Local0)\n
While (LLess(Arg0, Arg1))\n
{\n
Store(RE1B(Arg0), Index(TEMP, Local0))\n
Increment(Arg0)\n
Increment(Local0)\n
}\n
Return(TEMP)\n
}\n
end;
| {
"pile_set_name": "Github"
} |
/**
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
package org.apache.metamodel.query.builder;
import java.util.Arrays;
import java.util.List;
import org.apache.metamodel.DataContext;
import org.apache.metamodel.query.Query;
import org.apache.metamodel.schema.Schema;
import org.apache.metamodel.schema.Table;
import org.apache.metamodel.util.BaseObject;
public final class InitFromBuilderImpl extends BaseObject implements InitFromBuilder {
private DataContext dataContext;
private Query query;
public InitFromBuilderImpl(DataContext dataContext) {
this.dataContext = dataContext;
this.query = new Query();
}
@Override
public TableFromBuilder from(Table table) {
if (table == null) {
throw new IllegalArgumentException("table cannot be null");
}
return new TableFromBuilderImpl(table, query, dataContext);
}
@Override
public TableFromBuilder from(String schemaName, String tableName) {
if (schemaName == null) {
throw new IllegalArgumentException("schemaName cannot be null");
}
if (tableName == null) {
throw new IllegalArgumentException("tableName cannot be null");
}
Schema schema = dataContext.getSchemaByName(schemaName);
if (schema == null) {
schema = dataContext.getDefaultSchema();
}
return from(schema, tableName);
}
@Override
public TableFromBuilder from(Schema schema, String tableName) {
Table table = schema.getTableByName(tableName);
if (table == null) {
throw new IllegalArgumentException("Nu such table '" + tableName + "' found in schema: " + schema
+ ". Available tables are: " + Arrays.toString(schema.getTableNames().toArray()));
}
return from(table);
}
@Override
public TableFromBuilder from(String tableName) {
if (tableName == null) {
throw new IllegalArgumentException("tableName cannot be null");
}
Table table = dataContext.getTableByQualifiedLabel(tableName);
if (table == null) {
throw new IllegalArgumentException("No such table: " + tableName);
}
return from(table);
}
@Override
protected void decorateIdentity(List<Object> identifiers) {
identifiers.add(query);
}
} | {
"pile_set_name": "Github"
} |
// Code generated by running "go generate" in golang.org/x/text. DO NOT EDIT.
package identifier
const (
// ASCII is the MIB identifier with IANA name US-ASCII (MIME: US-ASCII).
//
// ANSI X3.4-1986
// Reference: RFC2046
ASCII MIB = 3
// ISOLatin1 is the MIB identifier with IANA name ISO_8859-1:1987 (MIME: ISO-8859-1).
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISOLatin1 MIB = 4
// ISOLatin2 is the MIB identifier with IANA name ISO_8859-2:1987 (MIME: ISO-8859-2).
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISOLatin2 MIB = 5
// ISOLatin3 is the MIB identifier with IANA name ISO_8859-3:1988 (MIME: ISO-8859-3).
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISOLatin3 MIB = 6
// ISOLatin4 is the MIB identifier with IANA name ISO_8859-4:1988 (MIME: ISO-8859-4).
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISOLatin4 MIB = 7
// ISOLatinCyrillic is the MIB identifier with IANA name ISO_8859-5:1988 (MIME: ISO-8859-5).
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISOLatinCyrillic MIB = 8
// ISOLatinArabic is the MIB identifier with IANA name ISO_8859-6:1987 (MIME: ISO-8859-6).
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISOLatinArabic MIB = 9
// ISOLatinGreek is the MIB identifier with IANA name ISO_8859-7:1987 (MIME: ISO-8859-7).
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1947
// Reference: RFC1345
ISOLatinGreek MIB = 10
// ISOLatinHebrew is the MIB identifier with IANA name ISO_8859-8:1988 (MIME: ISO-8859-8).
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISOLatinHebrew MIB = 11
// ISOLatin5 is the MIB identifier with IANA name ISO_8859-9:1989 (MIME: ISO-8859-9).
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISOLatin5 MIB = 12
// ISOLatin6 is the MIB identifier with IANA name ISO-8859-10 (MIME: ISO-8859-10).
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISOLatin6 MIB = 13
// ISOTextComm is the MIB identifier with IANA name ISO_6937-2-add.
//
// ISO-IR: International Register of Escape Sequences and ISO 6937-2:1983
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISOTextComm MIB = 14
// HalfWidthKatakana is the MIB identifier with IANA name JIS_X0201.
//
// JIS X 0201-1976. One byte only, this is equivalent to
// JIS/Roman (similar to ASCII) plus eight-bit half-width
// Katakana
// Reference: RFC1345
HalfWidthKatakana MIB = 15
// JISEncoding is the MIB identifier with IANA name JIS_Encoding.
//
// JIS X 0202-1991. Uses ISO 2022 escape sequences to
// shift code sets as documented in JIS X 0202-1991.
JISEncoding MIB = 16
// ShiftJIS is the MIB identifier with IANA name Shift_JIS (MIME: Shift_JIS).
//
// This charset is an extension of csHalfWidthKatakana by
// adding graphic characters in JIS X 0208. The CCS's are
// JIS X0201:1997 and JIS X0208:1997. The
// complete definition is shown in Appendix 1 of JIS
// X0208:1997.
// This charset can be used for the top-level media type "text".
ShiftJIS MIB = 17
// EUCPkdFmtJapanese is the MIB identifier with IANA name Extended_UNIX_Code_Packed_Format_for_Japanese (MIME: EUC-JP).
//
// Standardized by OSF, UNIX International, and UNIX Systems
// Laboratories Pacific. Uses ISO 2022 rules to select
// code set 0: US-ASCII (a single 7-bit byte set)
// code set 1: JIS X0208-1990 (a double 8-bit byte set)
// restricted to A0-FF in both bytes
// code set 2: Half Width Katakana (a single 7-bit byte set)
// requiring SS2 as the character prefix
// code set 3: JIS X0212-1990 (a double 7-bit byte set)
// restricted to A0-FF in both bytes
// requiring SS3 as the character prefix
EUCPkdFmtJapanese MIB = 18
// EUCFixWidJapanese is the MIB identifier with IANA name Extended_UNIX_Code_Fixed_Width_for_Japanese.
//
// Used in Japan. Each character is 2 octets.
// code set 0: US-ASCII (a single 7-bit byte set)
// 1st byte = 00
// 2nd byte = 20-7E
// code set 1: JIS X0208-1990 (a double 7-bit byte set)
// restricted to A0-FF in both bytes
// code set 2: Half Width Katakana (a single 7-bit byte set)
// 1st byte = 00
// 2nd byte = A0-FF
// code set 3: JIS X0212-1990 (a double 7-bit byte set)
// restricted to A0-FF in
// the first byte
// and 21-7E in the second byte
EUCFixWidJapanese MIB = 19
// ISO4UnitedKingdom is the MIB identifier with IANA name BS_4730.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO4UnitedKingdom MIB = 20
// ISO11SwedishForNames is the MIB identifier with IANA name SEN_850200_C.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO11SwedishForNames MIB = 21
// ISO15Italian is the MIB identifier with IANA name IT.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO15Italian MIB = 22
// ISO17Spanish is the MIB identifier with IANA name ES.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO17Spanish MIB = 23
// ISO21German is the MIB identifier with IANA name DIN_66003.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO21German MIB = 24
// ISO60Norwegian1 is the MIB identifier with IANA name NS_4551-1.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO60Norwegian1 MIB = 25
// ISO69French is the MIB identifier with IANA name NF_Z_62-010.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO69French MIB = 26
// ISO10646UTF1 is the MIB identifier with IANA name ISO-10646-UTF-1.
//
// Universal Transfer Format (1), this is the multibyte
// encoding, that subsets ASCII-7. It does not have byte
// ordering issues.
ISO10646UTF1 MIB = 27
// ISO646basic1983 is the MIB identifier with IANA name ISO_646.basic:1983.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO646basic1983 MIB = 28
// INVARIANT is the MIB identifier with IANA name INVARIANT.
//
// Reference: RFC1345
INVARIANT MIB = 29
// ISO2IntlRefVersion is the MIB identifier with IANA name ISO_646.irv:1983.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO2IntlRefVersion MIB = 30
// NATSSEFI is the MIB identifier with IANA name NATS-SEFI.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
NATSSEFI MIB = 31
// NATSSEFIADD is the MIB identifier with IANA name NATS-SEFI-ADD.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
NATSSEFIADD MIB = 32
// NATSDANO is the MIB identifier with IANA name NATS-DANO.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
NATSDANO MIB = 33
// NATSDANOADD is the MIB identifier with IANA name NATS-DANO-ADD.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
NATSDANOADD MIB = 34
// ISO10Swedish is the MIB identifier with IANA name SEN_850200_B.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO10Swedish MIB = 35
// KSC56011987 is the MIB identifier with IANA name KS_C_5601-1987.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
KSC56011987 MIB = 36
// ISO2022KR is the MIB identifier with IANA name ISO-2022-KR (MIME: ISO-2022-KR).
//
// rfc1557 (see also KS_C_5601-1987)
// Reference: RFC1557
ISO2022KR MIB = 37
// EUCKR is the MIB identifier with IANA name EUC-KR (MIME: EUC-KR).
//
// rfc1557 (see also KS_C_5861-1992)
// Reference: RFC1557
EUCKR MIB = 38
// ISO2022JP is the MIB identifier with IANA name ISO-2022-JP (MIME: ISO-2022-JP).
//
// rfc1468 (see also rfc2237 )
// Reference: RFC1468
ISO2022JP MIB = 39
// ISO2022JP2 is the MIB identifier with IANA name ISO-2022-JP-2 (MIME: ISO-2022-JP-2).
//
// rfc1554
// Reference: RFC1554
ISO2022JP2 MIB = 40
// ISO13JISC6220jp is the MIB identifier with IANA name JIS_C6220-1969-jp.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO13JISC6220jp MIB = 41
// ISO14JISC6220ro is the MIB identifier with IANA name JIS_C6220-1969-ro.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO14JISC6220ro MIB = 42
// ISO16Portuguese is the MIB identifier with IANA name PT.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO16Portuguese MIB = 43
// ISO18Greek7Old is the MIB identifier with IANA name greek7-old.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO18Greek7Old MIB = 44
// ISO19LatinGreek is the MIB identifier with IANA name latin-greek.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO19LatinGreek MIB = 45
// ISO25French is the MIB identifier with IANA name NF_Z_62-010_(1973).
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO25French MIB = 46
// ISO27LatinGreek1 is the MIB identifier with IANA name Latin-greek-1.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO27LatinGreek1 MIB = 47
// ISO5427Cyrillic is the MIB identifier with IANA name ISO_5427.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO5427Cyrillic MIB = 48
// ISO42JISC62261978 is the MIB identifier with IANA name JIS_C6226-1978.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO42JISC62261978 MIB = 49
// ISO47BSViewdata is the MIB identifier with IANA name BS_viewdata.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO47BSViewdata MIB = 50
// ISO49INIS is the MIB identifier with IANA name INIS.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO49INIS MIB = 51
// ISO50INIS8 is the MIB identifier with IANA name INIS-8.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO50INIS8 MIB = 52
// ISO51INISCyrillic is the MIB identifier with IANA name INIS-cyrillic.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO51INISCyrillic MIB = 53
// ISO54271981 is the MIB identifier with IANA name ISO_5427:1981.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO54271981 MIB = 54
// ISO5428Greek is the MIB identifier with IANA name ISO_5428:1980.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO5428Greek MIB = 55
// ISO57GB1988 is the MIB identifier with IANA name GB_1988-80.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO57GB1988 MIB = 56
// ISO58GB231280 is the MIB identifier with IANA name GB_2312-80.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO58GB231280 MIB = 57
// ISO61Norwegian2 is the MIB identifier with IANA name NS_4551-2.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO61Norwegian2 MIB = 58
// ISO70VideotexSupp1 is the MIB identifier with IANA name videotex-suppl.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO70VideotexSupp1 MIB = 59
// ISO84Portuguese2 is the MIB identifier with IANA name PT2.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO84Portuguese2 MIB = 60
// ISO85Spanish2 is the MIB identifier with IANA name ES2.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO85Spanish2 MIB = 61
// ISO86Hungarian is the MIB identifier with IANA name MSZ_7795.3.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO86Hungarian MIB = 62
// ISO87JISX0208 is the MIB identifier with IANA name JIS_C6226-1983.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO87JISX0208 MIB = 63
// ISO88Greek7 is the MIB identifier with IANA name greek7.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO88Greek7 MIB = 64
// ISO89ASMO449 is the MIB identifier with IANA name ASMO_449.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO89ASMO449 MIB = 65
// ISO90 is the MIB identifier with IANA name iso-ir-90.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO90 MIB = 66
// ISO91JISC62291984a is the MIB identifier with IANA name JIS_C6229-1984-a.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO91JISC62291984a MIB = 67
// ISO92JISC62991984b is the MIB identifier with IANA name JIS_C6229-1984-b.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO92JISC62991984b MIB = 68
// ISO93JIS62291984badd is the MIB identifier with IANA name JIS_C6229-1984-b-add.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO93JIS62291984badd MIB = 69
// ISO94JIS62291984hand is the MIB identifier with IANA name JIS_C6229-1984-hand.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO94JIS62291984hand MIB = 70
// ISO95JIS62291984handadd is the MIB identifier with IANA name JIS_C6229-1984-hand-add.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO95JIS62291984handadd MIB = 71
// ISO96JISC62291984kana is the MIB identifier with IANA name JIS_C6229-1984-kana.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO96JISC62291984kana MIB = 72
// ISO2033 is the MIB identifier with IANA name ISO_2033-1983.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO2033 MIB = 73
// ISO99NAPLPS is the MIB identifier with IANA name ANSI_X3.110-1983.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO99NAPLPS MIB = 74
// ISO102T617bit is the MIB identifier with IANA name T.61-7bit.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO102T617bit MIB = 75
// ISO103T618bit is the MIB identifier with IANA name T.61-8bit.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO103T618bit MIB = 76
// ISO111ECMACyrillic is the MIB identifier with IANA name ECMA-cyrillic.
//
// ISO registry
// (formerly ECMA
// registry )
ISO111ECMACyrillic MIB = 77
// ISO121Canadian1 is the MIB identifier with IANA name CSA_Z243.4-1985-1.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO121Canadian1 MIB = 78
// ISO122Canadian2 is the MIB identifier with IANA name CSA_Z243.4-1985-2.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO122Canadian2 MIB = 79
// ISO123CSAZ24341985gr is the MIB identifier with IANA name CSA_Z243.4-1985-gr.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO123CSAZ24341985gr MIB = 80
// ISO88596E is the MIB identifier with IANA name ISO_8859-6-E (MIME: ISO-8859-6-E).
//
// rfc1556
// Reference: RFC1556
ISO88596E MIB = 81
// ISO88596I is the MIB identifier with IANA name ISO_8859-6-I (MIME: ISO-8859-6-I).
//
// rfc1556
// Reference: RFC1556
ISO88596I MIB = 82
// ISO128T101G2 is the MIB identifier with IANA name T.101-G2.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO128T101G2 MIB = 83
// ISO88598E is the MIB identifier with IANA name ISO_8859-8-E (MIME: ISO-8859-8-E).
//
// rfc1556
// Reference: RFC1556
ISO88598E MIB = 84
// ISO88598I is the MIB identifier with IANA name ISO_8859-8-I (MIME: ISO-8859-8-I).
//
// rfc1556
// Reference: RFC1556
ISO88598I MIB = 85
// ISO139CSN369103 is the MIB identifier with IANA name CSN_369103.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO139CSN369103 MIB = 86
// ISO141JUSIB1002 is the MIB identifier with IANA name JUS_I.B1.002.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO141JUSIB1002 MIB = 87
// ISO143IECP271 is the MIB identifier with IANA name IEC_P27-1.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO143IECP271 MIB = 88
// ISO146Serbian is the MIB identifier with IANA name JUS_I.B1.003-serb.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO146Serbian MIB = 89
// ISO147Macedonian is the MIB identifier with IANA name JUS_I.B1.003-mac.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO147Macedonian MIB = 90
// ISO150GreekCCITT is the MIB identifier with IANA name greek-ccitt.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO150GreekCCITT MIB = 91
// ISO151Cuba is the MIB identifier with IANA name NC_NC00-10:81.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO151Cuba MIB = 92
// ISO6937Add is the MIB identifier with IANA name ISO_6937-2-25.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO6937Add MIB = 93
// ISO153GOST1976874 is the MIB identifier with IANA name GOST_19768-74.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO153GOST1976874 MIB = 94
// ISO8859Supp is the MIB identifier with IANA name ISO_8859-supp.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO8859Supp MIB = 95
// ISO10367Box is the MIB identifier with IANA name ISO_10367-box.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO10367Box MIB = 96
// ISO158Lap is the MIB identifier with IANA name latin-lap.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO158Lap MIB = 97
// ISO159JISX02121990 is the MIB identifier with IANA name JIS_X0212-1990.
//
// ISO-IR: International Register of Escape Sequences
// Note: The current registration authority is IPSJ/ITSCJ, Japan.
// Reference: RFC1345
ISO159JISX02121990 MIB = 98
// ISO646Danish is the MIB identifier with IANA name DS_2089.
//
// Danish Standard, DS 2089, February 1974
// Reference: RFC1345
ISO646Danish MIB = 99
// USDK is the MIB identifier with IANA name us-dk.
//
// Reference: RFC1345
USDK MIB = 100
// DKUS is the MIB identifier with IANA name dk-us.
//
// Reference: RFC1345
DKUS MIB = 101
// KSC5636 is the MIB identifier with IANA name KSC5636.
//
// Reference: RFC1345
KSC5636 MIB = 102
// Unicode11UTF7 is the MIB identifier with IANA name UNICODE-1-1-UTF-7.
//
// rfc1642
// Reference: RFC1642
Unicode11UTF7 MIB = 103
// ISO2022CN is the MIB identifier with IANA name ISO-2022-CN.
//
// rfc1922
// Reference: RFC1922
ISO2022CN MIB = 104
// ISO2022CNEXT is the MIB identifier with IANA name ISO-2022-CN-EXT.
//
// rfc1922
// Reference: RFC1922
ISO2022CNEXT MIB = 105
// UTF8 is the MIB identifier with IANA name UTF-8.
//
// rfc3629
// Reference: RFC3629
UTF8 MIB = 106
// ISO885913 is the MIB identifier with IANA name ISO-8859-13.
//
// ISO See http://www.iana.org/assignments/charset-reg/ISO-8859-13 http://www.iana.org/assignments/charset-reg/ISO-8859-13
ISO885913 MIB = 109
// ISO885914 is the MIB identifier with IANA name ISO-8859-14.
//
// ISO See http://www.iana.org/assignments/charset-reg/ISO-8859-14
ISO885914 MIB = 110
// ISO885915 is the MIB identifier with IANA name ISO-8859-15.
//
// ISO
// Please see: http://www.iana.org/assignments/charset-reg/ISO-8859-15
ISO885915 MIB = 111
// ISO885916 is the MIB identifier with IANA name ISO-8859-16.
//
// ISO
ISO885916 MIB = 112
// GBK is the MIB identifier with IANA name GBK.
//
// Chinese IT Standardization Technical Committee
// Please see: http://www.iana.org/assignments/charset-reg/GBK
GBK MIB = 113
// GB18030 is the MIB identifier with IANA name GB18030.
//
// Chinese IT Standardization Technical Committee
// Please see: http://www.iana.org/assignments/charset-reg/GB18030
GB18030 MIB = 114
// OSDEBCDICDF0415 is the MIB identifier with IANA name OSD_EBCDIC_DF04_15.
//
// Fujitsu-Siemens standard mainframe EBCDIC encoding
// Please see: http://www.iana.org/assignments/charset-reg/OSD-EBCDIC-DF04-15
OSDEBCDICDF0415 MIB = 115
// OSDEBCDICDF03IRV is the MIB identifier with IANA name OSD_EBCDIC_DF03_IRV.
//
// Fujitsu-Siemens standard mainframe EBCDIC encoding
// Please see: http://www.iana.org/assignments/charset-reg/OSD-EBCDIC-DF03-IRV
OSDEBCDICDF03IRV MIB = 116
// OSDEBCDICDF041 is the MIB identifier with IANA name OSD_EBCDIC_DF04_1.
//
// Fujitsu-Siemens standard mainframe EBCDIC encoding
// Please see: http://www.iana.org/assignments/charset-reg/OSD-EBCDIC-DF04-1
OSDEBCDICDF041 MIB = 117
// ISO115481 is the MIB identifier with IANA name ISO-11548-1.
//
// See http://www.iana.org/assignments/charset-reg/ISO-11548-1
ISO115481 MIB = 118
// KZ1048 is the MIB identifier with IANA name KZ-1048.
//
// See http://www.iana.org/assignments/charset-reg/KZ-1048
KZ1048 MIB = 119
// Unicode is the MIB identifier with IANA name ISO-10646-UCS-2.
//
// the 2-octet Basic Multilingual Plane, aka Unicode
// this needs to specify network byte order: the standard
// does not specify (it is a 16-bit integer space)
Unicode MIB = 1000
// UCS4 is the MIB identifier with IANA name ISO-10646-UCS-4.
//
// the full code space. (same comment about byte order,
// these are 31-bit numbers.
UCS4 MIB = 1001
// UnicodeASCII is the MIB identifier with IANA name ISO-10646-UCS-Basic.
//
// ASCII subset of Unicode. Basic Latin = collection 1
// See ISO 10646, Appendix A
UnicodeASCII MIB = 1002
// UnicodeLatin1 is the MIB identifier with IANA name ISO-10646-Unicode-Latin1.
//
// ISO Latin-1 subset of Unicode. Basic Latin and Latin-1
// Supplement = collections 1 and 2. See ISO 10646,
// Appendix A. See rfc1815 .
UnicodeLatin1 MIB = 1003
// UnicodeJapanese is the MIB identifier with IANA name ISO-10646-J-1.
//
// ISO 10646 Japanese, see rfc1815 .
UnicodeJapanese MIB = 1004
// UnicodeIBM1261 is the MIB identifier with IANA name ISO-Unicode-IBM-1261.
//
// IBM Latin-2, -3, -5, Extended Presentation Set, GCSGID: 1261
UnicodeIBM1261 MIB = 1005
// UnicodeIBM1268 is the MIB identifier with IANA name ISO-Unicode-IBM-1268.
//
// IBM Latin-4 Extended Presentation Set, GCSGID: 1268
UnicodeIBM1268 MIB = 1006
// UnicodeIBM1276 is the MIB identifier with IANA name ISO-Unicode-IBM-1276.
//
// IBM Cyrillic Greek Extended Presentation Set, GCSGID: 1276
UnicodeIBM1276 MIB = 1007
// UnicodeIBM1264 is the MIB identifier with IANA name ISO-Unicode-IBM-1264.
//
// IBM Arabic Presentation Set, GCSGID: 1264
UnicodeIBM1264 MIB = 1008
// UnicodeIBM1265 is the MIB identifier with IANA name ISO-Unicode-IBM-1265.
//
// IBM Hebrew Presentation Set, GCSGID: 1265
UnicodeIBM1265 MIB = 1009
// Unicode11 is the MIB identifier with IANA name UNICODE-1-1.
//
// rfc1641
// Reference: RFC1641
Unicode11 MIB = 1010
// SCSU is the MIB identifier with IANA name SCSU.
//
// SCSU See http://www.iana.org/assignments/charset-reg/SCSU
SCSU MIB = 1011
// UTF7 is the MIB identifier with IANA name UTF-7.
//
// rfc2152
// Reference: RFC2152
UTF7 MIB = 1012
// UTF16BE is the MIB identifier with IANA name UTF-16BE.
//
// rfc2781
// Reference: RFC2781
UTF16BE MIB = 1013
// UTF16LE is the MIB identifier with IANA name UTF-16LE.
//
// rfc2781
// Reference: RFC2781
UTF16LE MIB = 1014
// UTF16 is the MIB identifier with IANA name UTF-16.
//
// rfc2781
// Reference: RFC2781
UTF16 MIB = 1015
// CESU8 is the MIB identifier with IANA name CESU-8.
//
// http://www.unicode.org/unicode/reports/tr26
CESU8 MIB = 1016
// UTF32 is the MIB identifier with IANA name UTF-32.
//
// http://www.unicode.org/unicode/reports/tr19/
UTF32 MIB = 1017
// UTF32BE is the MIB identifier with IANA name UTF-32BE.
//
// http://www.unicode.org/unicode/reports/tr19/
UTF32BE MIB = 1018
// UTF32LE is the MIB identifier with IANA name UTF-32LE.
//
// http://www.unicode.org/unicode/reports/tr19/
UTF32LE MIB = 1019
// BOCU1 is the MIB identifier with IANA name BOCU-1.
//
// http://www.unicode.org/notes/tn6/
BOCU1 MIB = 1020
// Windows30Latin1 is the MIB identifier with IANA name ISO-8859-1-Windows-3.0-Latin-1.
//
// Extended ISO 8859-1 Latin-1 for Windows 3.0.
// PCL Symbol Set id: 9U
Windows30Latin1 MIB = 2000
// Windows31Latin1 is the MIB identifier with IANA name ISO-8859-1-Windows-3.1-Latin-1.
//
// Extended ISO 8859-1 Latin-1 for Windows 3.1.
// PCL Symbol Set id: 19U
Windows31Latin1 MIB = 2001
// Windows31Latin2 is the MIB identifier with IANA name ISO-8859-2-Windows-Latin-2.
//
// Extended ISO 8859-2. Latin-2 for Windows 3.1.
// PCL Symbol Set id: 9E
Windows31Latin2 MIB = 2002
// Windows31Latin5 is the MIB identifier with IANA name ISO-8859-9-Windows-Latin-5.
//
// Extended ISO 8859-9. Latin-5 for Windows 3.1
// PCL Symbol Set id: 5T
Windows31Latin5 MIB = 2003
// HPRoman8 is the MIB identifier with IANA name hp-roman8.
//
// LaserJet IIP Printer User's Manual,
// HP part no 33471-90901, Hewlet-Packard, June 1989.
// Reference: RFC1345
HPRoman8 MIB = 2004
// AdobeStandardEncoding is the MIB identifier with IANA name Adobe-Standard-Encoding.
//
// PostScript Language Reference Manual
// PCL Symbol Set id: 10J
AdobeStandardEncoding MIB = 2005
// VenturaUS is the MIB identifier with IANA name Ventura-US.
//
// Ventura US. ASCII plus characters typically used in
// publishing, like pilcrow, copyright, registered, trade mark,
// section, dagger, and double dagger in the range A0 (hex)
// to FF (hex).
// PCL Symbol Set id: 14J
VenturaUS MIB = 2006
// VenturaInternational is the MIB identifier with IANA name Ventura-International.
//
// Ventura International. ASCII plus coded characters similar
// to Roman8.
// PCL Symbol Set id: 13J
VenturaInternational MIB = 2007
// DECMCS is the MIB identifier with IANA name DEC-MCS.
//
// VAX/VMS User's Manual,
// Order Number: AI-Y517A-TE, April 1986.
// Reference: RFC1345
DECMCS MIB = 2008
// PC850Multilingual is the MIB identifier with IANA name IBM850.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
PC850Multilingual MIB = 2009
// PC8DanishNorwegian is the MIB identifier with IANA name PC8-Danish-Norwegian.
//
// PC Danish Norwegian
// 8-bit PC set for Danish Norwegian
// PCL Symbol Set id: 11U
PC8DanishNorwegian MIB = 2012
// PC862LatinHebrew is the MIB identifier with IANA name IBM862.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
PC862LatinHebrew MIB = 2013
// PC8Turkish is the MIB identifier with IANA name PC8-Turkish.
//
// PC Latin Turkish. PCL Symbol Set id: 9T
PC8Turkish MIB = 2014
// IBMSymbols is the MIB identifier with IANA name IBM-Symbols.
//
// Presentation Set, CPGID: 259
IBMSymbols MIB = 2015
// IBMThai is the MIB identifier with IANA name IBM-Thai.
//
// Presentation Set, CPGID: 838
IBMThai MIB = 2016
// HPLegal is the MIB identifier with IANA name HP-Legal.
//
// PCL 5 Comparison Guide, Hewlett-Packard,
// HP part number 5961-0510, October 1992
// PCL Symbol Set id: 1U
HPLegal MIB = 2017
// HPPiFont is the MIB identifier with IANA name HP-Pi-font.
//
// PCL 5 Comparison Guide, Hewlett-Packard,
// HP part number 5961-0510, October 1992
// PCL Symbol Set id: 15U
HPPiFont MIB = 2018
// HPMath8 is the MIB identifier with IANA name HP-Math8.
//
// PCL 5 Comparison Guide, Hewlett-Packard,
// HP part number 5961-0510, October 1992
// PCL Symbol Set id: 8M
HPMath8 MIB = 2019
// HPPSMath is the MIB identifier with IANA name Adobe-Symbol-Encoding.
//
// PostScript Language Reference Manual
// PCL Symbol Set id: 5M
HPPSMath MIB = 2020
// HPDesktop is the MIB identifier with IANA name HP-DeskTop.
//
// PCL 5 Comparison Guide, Hewlett-Packard,
// HP part number 5961-0510, October 1992
// PCL Symbol Set id: 7J
HPDesktop MIB = 2021
// VenturaMath is the MIB identifier with IANA name Ventura-Math.
//
// PCL 5 Comparison Guide, Hewlett-Packard,
// HP part number 5961-0510, October 1992
// PCL Symbol Set id: 6M
VenturaMath MIB = 2022
// MicrosoftPublishing is the MIB identifier with IANA name Microsoft-Publishing.
//
// PCL 5 Comparison Guide, Hewlett-Packard,
// HP part number 5961-0510, October 1992
// PCL Symbol Set id: 6J
MicrosoftPublishing MIB = 2023
// Windows31J is the MIB identifier with IANA name Windows-31J.
//
// Windows Japanese. A further extension of Shift_JIS
// to include NEC special characters (Row 13), NEC
// selection of IBM extensions (Rows 89 to 92), and IBM
// extensions (Rows 115 to 119). The CCS's are
// JIS X0201:1997, JIS X0208:1997, and these extensions.
// This charset can be used for the top-level media type "text",
// but it is of limited or specialized use (see rfc2278 ).
// PCL Symbol Set id: 19K
Windows31J MIB = 2024
// GB2312 is the MIB identifier with IANA name GB2312 (MIME: GB2312).
//
// Chinese for People's Republic of China (PRC) mixed one byte,
// two byte set:
// 20-7E = one byte ASCII
// A1-FE = two byte PRC Kanji
// See GB 2312-80
// PCL Symbol Set Id: 18C
GB2312 MIB = 2025
// Big5 is the MIB identifier with IANA name Big5 (MIME: Big5).
//
// Chinese for Taiwan Multi-byte set.
// PCL Symbol Set Id: 18T
Big5 MIB = 2026
// Macintosh is the MIB identifier with IANA name macintosh.
//
// The Unicode Standard ver1.0, ISBN 0-201-56788-1, Oct 1991
// Reference: RFC1345
Macintosh MIB = 2027
// IBM037 is the MIB identifier with IANA name IBM037.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM037 MIB = 2028
// IBM038 is the MIB identifier with IANA name IBM038.
//
// IBM 3174 Character Set Ref, GA27-3831-02, March 1990
// Reference: RFC1345
IBM038 MIB = 2029
// IBM273 is the MIB identifier with IANA name IBM273.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM273 MIB = 2030
// IBM274 is the MIB identifier with IANA name IBM274.
//
// IBM 3174 Character Set Ref, GA27-3831-02, March 1990
// Reference: RFC1345
IBM274 MIB = 2031
// IBM275 is the MIB identifier with IANA name IBM275.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM275 MIB = 2032
// IBM277 is the MIB identifier with IANA name IBM277.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM277 MIB = 2033
// IBM278 is the MIB identifier with IANA name IBM278.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM278 MIB = 2034
// IBM280 is the MIB identifier with IANA name IBM280.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM280 MIB = 2035
// IBM281 is the MIB identifier with IANA name IBM281.
//
// IBM 3174 Character Set Ref, GA27-3831-02, March 1990
// Reference: RFC1345
IBM281 MIB = 2036
// IBM284 is the MIB identifier with IANA name IBM284.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM284 MIB = 2037
// IBM285 is the MIB identifier with IANA name IBM285.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM285 MIB = 2038
// IBM290 is the MIB identifier with IANA name IBM290.
//
// IBM 3174 Character Set Ref, GA27-3831-02, March 1990
// Reference: RFC1345
IBM290 MIB = 2039
// IBM297 is the MIB identifier with IANA name IBM297.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM297 MIB = 2040
// IBM420 is the MIB identifier with IANA name IBM420.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990,
// IBM NLS RM p 11-11
// Reference: RFC1345
IBM420 MIB = 2041
// IBM423 is the MIB identifier with IANA name IBM423.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM423 MIB = 2042
// IBM424 is the MIB identifier with IANA name IBM424.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM424 MIB = 2043
// PC8CodePage437 is the MIB identifier with IANA name IBM437.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
PC8CodePage437 MIB = 2011
// IBM500 is the MIB identifier with IANA name IBM500.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM500 MIB = 2044
// IBM851 is the MIB identifier with IANA name IBM851.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM851 MIB = 2045
// PCp852 is the MIB identifier with IANA name IBM852.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
PCp852 MIB = 2010
// IBM855 is the MIB identifier with IANA name IBM855.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM855 MIB = 2046
// IBM857 is the MIB identifier with IANA name IBM857.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM857 MIB = 2047
// IBM860 is the MIB identifier with IANA name IBM860.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM860 MIB = 2048
// IBM861 is the MIB identifier with IANA name IBM861.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM861 MIB = 2049
// IBM863 is the MIB identifier with IANA name IBM863.
//
// IBM Keyboard layouts and code pages, PN 07G4586 June 1991
// Reference: RFC1345
IBM863 MIB = 2050
// IBM864 is the MIB identifier with IANA name IBM864.
//
// IBM Keyboard layouts and code pages, PN 07G4586 June 1991
// Reference: RFC1345
IBM864 MIB = 2051
// IBM865 is the MIB identifier with IANA name IBM865.
//
// IBM DOS 3.3 Ref (Abridged), 94X9575 (Feb 1987)
// Reference: RFC1345
IBM865 MIB = 2052
// IBM868 is the MIB identifier with IANA name IBM868.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM868 MIB = 2053
// IBM869 is the MIB identifier with IANA name IBM869.
//
// IBM Keyboard layouts and code pages, PN 07G4586 June 1991
// Reference: RFC1345
IBM869 MIB = 2054
// IBM870 is the MIB identifier with IANA name IBM870.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM870 MIB = 2055
// IBM871 is the MIB identifier with IANA name IBM871.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM871 MIB = 2056
// IBM880 is the MIB identifier with IANA name IBM880.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM880 MIB = 2057
// IBM891 is the MIB identifier with IANA name IBM891.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM891 MIB = 2058
// IBM903 is the MIB identifier with IANA name IBM903.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM903 MIB = 2059
// IBBM904 is the MIB identifier with IANA name IBM904.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBBM904 MIB = 2060
// IBM905 is the MIB identifier with IANA name IBM905.
//
// IBM 3174 Character Set Ref, GA27-3831-02, March 1990
// Reference: RFC1345
IBM905 MIB = 2061
// IBM918 is the MIB identifier with IANA name IBM918.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM918 MIB = 2062
// IBM1026 is the MIB identifier with IANA name IBM1026.
//
// IBM NLS RM Vol2 SE09-8002-01, March 1990
// Reference: RFC1345
IBM1026 MIB = 2063
// IBMEBCDICATDE is the MIB identifier with IANA name EBCDIC-AT-DE.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
IBMEBCDICATDE MIB = 2064
// EBCDICATDEA is the MIB identifier with IANA name EBCDIC-AT-DE-A.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICATDEA MIB = 2065
// EBCDICCAFR is the MIB identifier with IANA name EBCDIC-CA-FR.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICCAFR MIB = 2066
// EBCDICDKNO is the MIB identifier with IANA name EBCDIC-DK-NO.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICDKNO MIB = 2067
// EBCDICDKNOA is the MIB identifier with IANA name EBCDIC-DK-NO-A.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICDKNOA MIB = 2068
// EBCDICFISE is the MIB identifier with IANA name EBCDIC-FI-SE.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICFISE MIB = 2069
// EBCDICFISEA is the MIB identifier with IANA name EBCDIC-FI-SE-A.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICFISEA MIB = 2070
// EBCDICFR is the MIB identifier with IANA name EBCDIC-FR.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICFR MIB = 2071
// EBCDICIT is the MIB identifier with IANA name EBCDIC-IT.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICIT MIB = 2072
// EBCDICPT is the MIB identifier with IANA name EBCDIC-PT.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICPT MIB = 2073
// EBCDICES is the MIB identifier with IANA name EBCDIC-ES.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICES MIB = 2074
// EBCDICESA is the MIB identifier with IANA name EBCDIC-ES-A.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICESA MIB = 2075
// EBCDICESS is the MIB identifier with IANA name EBCDIC-ES-S.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICESS MIB = 2076
// EBCDICUK is the MIB identifier with IANA name EBCDIC-UK.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICUK MIB = 2077
// EBCDICUS is the MIB identifier with IANA name EBCDIC-US.
//
// IBM 3270 Char Set Ref Ch 10, GA27-2837-9, April 1987
// Reference: RFC1345
EBCDICUS MIB = 2078
// Unknown8BiT is the MIB identifier with IANA name UNKNOWN-8BIT.
//
// Reference: RFC1428
Unknown8BiT MIB = 2079
// Mnemonic is the MIB identifier with IANA name MNEMONIC.
//
// rfc1345 , also known as "mnemonic+ascii+38"
// Reference: RFC1345
Mnemonic MIB = 2080
// Mnem is the MIB identifier with IANA name MNEM.
//
// rfc1345 , also known as "mnemonic+ascii+8200"
// Reference: RFC1345
Mnem MIB = 2081
// VISCII is the MIB identifier with IANA name VISCII.
//
// rfc1456
// Reference: RFC1456
VISCII MIB = 2082
// VIQR is the MIB identifier with IANA name VIQR.
//
// rfc1456
// Reference: RFC1456
VIQR MIB = 2083
// KOI8R is the MIB identifier with IANA name KOI8-R (MIME: KOI8-R).
//
// rfc1489 , based on GOST-19768-74, ISO-6937/8,
// INIS-Cyrillic, ISO-5427.
// Reference: RFC1489
KOI8R MIB = 2084
// HZGB2312 is the MIB identifier with IANA name HZ-GB-2312.
//
// rfc1842 , rfc1843 rfc1843 rfc1842
HZGB2312 MIB = 2085
// IBM866 is the MIB identifier with IANA name IBM866.
//
// IBM NLDG Volume 2 (SE09-8002-03) August 1994
IBM866 MIB = 2086
// PC775Baltic is the MIB identifier with IANA name IBM775.
//
// HP PCL 5 Comparison Guide (P/N 5021-0329) pp B-13, 1996
PC775Baltic MIB = 2087
// KOI8U is the MIB identifier with IANA name KOI8-U.
//
// rfc2319
// Reference: RFC2319
KOI8U MIB = 2088
// IBM00858 is the MIB identifier with IANA name IBM00858.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM00858
IBM00858 MIB = 2089
// IBM00924 is the MIB identifier with IANA name IBM00924.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM00924
IBM00924 MIB = 2090
// IBM01140 is the MIB identifier with IANA name IBM01140.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM01140
IBM01140 MIB = 2091
// IBM01141 is the MIB identifier with IANA name IBM01141.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM01141
IBM01141 MIB = 2092
// IBM01142 is the MIB identifier with IANA name IBM01142.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM01142
IBM01142 MIB = 2093
// IBM01143 is the MIB identifier with IANA name IBM01143.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM01143
IBM01143 MIB = 2094
// IBM01144 is the MIB identifier with IANA name IBM01144.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM01144
IBM01144 MIB = 2095
// IBM01145 is the MIB identifier with IANA name IBM01145.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM01145
IBM01145 MIB = 2096
// IBM01146 is the MIB identifier with IANA name IBM01146.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM01146
IBM01146 MIB = 2097
// IBM01147 is the MIB identifier with IANA name IBM01147.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM01147
IBM01147 MIB = 2098
// IBM01148 is the MIB identifier with IANA name IBM01148.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM01148
IBM01148 MIB = 2099
// IBM01149 is the MIB identifier with IANA name IBM01149.
//
// IBM See http://www.iana.org/assignments/charset-reg/IBM01149
IBM01149 MIB = 2100
// Big5HKSCS is the MIB identifier with IANA name Big5-HKSCS.
//
// See http://www.iana.org/assignments/charset-reg/Big5-HKSCS
Big5HKSCS MIB = 2101
// IBM1047 is the MIB identifier with IANA name IBM1047.
//
// IBM1047 (EBCDIC Latin 1/Open Systems) http://www-1.ibm.com/servers/eserver/iseries/software/globalization/pdf/cp01047z.pdf
IBM1047 MIB = 2102
// PTCP154 is the MIB identifier with IANA name PTCP154.
//
// See http://www.iana.org/assignments/charset-reg/PTCP154
PTCP154 MIB = 2103
// Amiga1251 is the MIB identifier with IANA name Amiga-1251.
//
// See http://www.amiga.ultranet.ru/Amiga-1251.html
Amiga1251 MIB = 2104
// KOI7switched is the MIB identifier with IANA name KOI7-switched.
//
// See http://www.iana.org/assignments/charset-reg/KOI7-switched
KOI7switched MIB = 2105
// BRF is the MIB identifier with IANA name BRF.
//
// See http://www.iana.org/assignments/charset-reg/BRF
BRF MIB = 2106
// TSCII is the MIB identifier with IANA name TSCII.
//
// See http://www.iana.org/assignments/charset-reg/TSCII
TSCII MIB = 2107
// CP51932 is the MIB identifier with IANA name CP51932.
//
// See http://www.iana.org/assignments/charset-reg/CP51932
CP51932 MIB = 2108
// Windows874 is the MIB identifier with IANA name windows-874.
//
// See http://www.iana.org/assignments/charset-reg/windows-874
Windows874 MIB = 2109
// Windows1250 is the MIB identifier with IANA name windows-1250.
//
// Microsoft http://www.iana.org/assignments/charset-reg/windows-1250
Windows1250 MIB = 2250
// Windows1251 is the MIB identifier with IANA name windows-1251.
//
// Microsoft http://www.iana.org/assignments/charset-reg/windows-1251
Windows1251 MIB = 2251
// Windows1252 is the MIB identifier with IANA name windows-1252.
//
// Microsoft http://www.iana.org/assignments/charset-reg/windows-1252
Windows1252 MIB = 2252
// Windows1253 is the MIB identifier with IANA name windows-1253.
//
// Microsoft http://www.iana.org/assignments/charset-reg/windows-1253
Windows1253 MIB = 2253
// Windows1254 is the MIB identifier with IANA name windows-1254.
//
// Microsoft http://www.iana.org/assignments/charset-reg/windows-1254
Windows1254 MIB = 2254
// Windows1255 is the MIB identifier with IANA name windows-1255.
//
// Microsoft http://www.iana.org/assignments/charset-reg/windows-1255
Windows1255 MIB = 2255
// Windows1256 is the MIB identifier with IANA name windows-1256.
//
// Microsoft http://www.iana.org/assignments/charset-reg/windows-1256
Windows1256 MIB = 2256
// Windows1257 is the MIB identifier with IANA name windows-1257.
//
// Microsoft http://www.iana.org/assignments/charset-reg/windows-1257
Windows1257 MIB = 2257
// Windows1258 is the MIB identifier with IANA name windows-1258.
//
// Microsoft http://www.iana.org/assignments/charset-reg/windows-1258
Windows1258 MIB = 2258
// TIS620 is the MIB identifier with IANA name TIS-620.
//
// Thai Industrial Standards Institute (TISI)
TIS620 MIB = 2259
// CP50220 is the MIB identifier with IANA name CP50220.
//
// See http://www.iana.org/assignments/charset-reg/CP50220
CP50220 MIB = 2260
)
| {
"pile_set_name": "Github"
} |
import test from 'ava';
import { stock } from '../src';
test('Get Concepts Classify', t => {
t.plan(2);
return stock.getSinaConceptsClassified().then(({ data }) => {
t.truthy(Object.prototype.toString.apply(data) === '[object Array]',
'It should return an array concepts classified data');
t.truthy(data.length > 0, 'It should return more than one concepts classified data');
});
});
| {
"pile_set_name": "Github"
} |
<?php
namespace Aliyun\Core\Auth;
class ShaHmac256Signer implements ISigner
{
public function signString($source, $accessSecret)
{
return base64_encode(hash_hmac('sha256', $source, $accessSecret, true));
}
public function getSignatureMethod() {
return "HMAC-SHA256";
}
public function getSignatureVersion() {
return "1.0";
}
} | {
"pile_set_name": "Github"
} |
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Runtime.InteropServices.WindowsRuntime;
using Uno.UI.Samples.Controls;
using Windows.Foundation;
using Windows.Foundation.Collections;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
using Windows.UI.Xaml.Controls.Primitives;
using Windows.UI.Xaml.Data;
using Windows.UI.Xaml.Input;
using Windows.UI.Xaml.Media;
using Windows.UI.Xaml.Navigation;
namespace Uno.UI.Samples.UITests.ImageTests
{
[SampleControlInfo(category: "Image", controlName: nameof(ImageSourceUrlMsAppxScheme))]
public sealed partial class ImageSourceUrlMsAppxScheme : Page
{
public ImageSourceUrlMsAppxScheme()
{
this.InitializeComponent();
}
}
}
| {
"pile_set_name": "Github"
} |
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace"/>
<xsd:element msdata:IsDataSet="true" name="root">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element minOccurs="0" name="value" type="xsd:string"/>
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required"/>
<xsd:attribute name="type" type="xsd:string"/>
<xsd:attribute name="mimetype" type="xsd:string"/>
<xsd:attribute ref="xml:space"/>
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string"/>
<xsd:attribute name="name" type="xsd:string"/>
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element minOccurs="0" msdata:Ordinal="1" name="value" type="xsd:string"/>
<xsd:element minOccurs="0" msdata:Ordinal="2" name="comment" type="xsd:string"/>
</xsd:sequence>
<xsd:attribute msdata:Ordinal="1" name="name" type="xsd:string" use="required"/>
<xsd:attribute msdata:Ordinal="3" name="type" type="xsd:string"/>
<xsd:attribute msdata:Ordinal="4" name="mimetype" type="xsd:string"/>
<xsd:attribute ref="xml:space"/>
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element minOccurs="0" msdata:Ordinal="1" name="value" type="xsd:string"/>
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required"/>
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<assembly alias="mscorlib" name="mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
<data name="m_ctrlError.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<assembly alias="System.Windows.Forms" name="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
<data name="m_ctrlError.AutoSizeMode" type="System.Windows.Forms.AutoSizeMode, System.Windows.Forms">
<value>GrowAndShrink</value>
</data>
<data name="tableLayoutPanel2.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="tableLayoutPanel2.AutoSizeMode" type="System.Windows.Forms.AutoSizeMode, System.Windows.Forms">
<value>GrowAndShrink</value>
</data>
<data name="tableLayoutPanel2.ColumnCount" type="System.Int32, mscorlib">
<value>4</value>
</data>
<data name="m_labelIntro.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="m_labelIntro.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/>
<data name="m_labelIntro.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 0</value>
</data>
<data name="m_labelIntro.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>3, 0, 3, 15</value>
</data>
<data name="m_labelIntro.Size" type="System.Drawing.Size, System.Drawing">
<value>587, 78</value>
</data>
<data name="m_labelIntro.TabIndex" type="System.Int32, mscorlib">
<value>1</value>
</data>
<data name="m_labelIntro.Text" xml:space="preserve">
<value>操作系统修复将为在非 [XenServer] 平台上创建的 OVF 包(例如,在 VMware 环境中创建的 OVF 包)和磁盘映像创建基本级别的互操作性。操作系统修复将尝试修复导入的 VM 中出现的可能会阻止 VM 的操作系统重新启动的问题。
操作系统修复以可引导的 ISO 映像方式提供,附加到导入的 VM 的 DVD 驱动器上,在首次启动时对该 VM 执行必要的修复。</value>
</data>
<data name=">>m_labelIntro.Name" xml:space="preserve">
<value>m_labelIntro</value>
</data>
<data name=">>m_labelIntro.Type" xml:space="preserve">
<value>XenAdmin.Controls.Common.AutoHeightLabel, XenCenterMain, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</value>
</data>
<data name=">>m_labelIntro.Parent" xml:space="preserve">
<value>tableLayoutPanel2</value>
</data>
<data name=">>m_labelIntro.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="m_radioButtonDontRunOSFixups.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="m_radioButtonDontRunOSFixups.Font" type="System.Drawing.Font, System.Drawing">
<value>Microsoft Sans Serif, 8.25pt, style=Bold</value>
</data>
<data name="m_radioButtonDontRunOSFixups.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 96</value>
</data>
<data name="m_radioButtonDontRunOSFixups.Size" type="System.Drawing.Size, System.Drawing">
<value>216, 17</value>
</data>
<data name="m_radioButtonDontRunOSFixups.TabIndex" type="System.Int32, mscorlib">
<value>2</value>
</data>
<data name="m_radioButtonDontRunOSFixups.Text" xml:space="preserve">
<value>不使用操作系统修复(&D)</value>
</data>
<data name=">>m_radioButtonDontRunOSFixups.Name" xml:space="preserve">
<value>m_radioButtonDontRunOSFixups</value>
</data>
<data name=">>m_radioButtonDontRunOSFixups.Type" xml:space="preserve">
<value>System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>m_radioButtonDontRunOSFixups.Parent" xml:space="preserve">
<value>tableLayoutPanel2</value>
</data>
<data name=">>m_radioButtonDontRunOSFixups.ZOrder" xml:space="preserve">
<value>1</value>
</data>
<data name="m_labelDontRunOSFixups.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="m_labelDontRunOSFixups.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="m_labelDontRunOSFixups.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="m_labelDontRunOSFixups.Location" type="System.Drawing.Point, System.Drawing">
<value>23, 119</value>
</data>
<data name="m_labelDontRunOSFixups.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>3, 3, 3, 12</value>
</data>
<data name="m_labelDontRunOSFixups.Size" type="System.Drawing.Size, System.Drawing">
<value>567, 13</value>
</data>
<data name="m_labelDontRunOSFixups.TabIndex" type="System.Int32, mscorlib">
<value>3</value>
</data>
<data name="m_labelDontRunOSFixups.Text" xml:space="preserve">
<value>如果正在导入的 VM 是在 [XenServer] 上创建的,请选择此选项。</value>
</data>
<data name=">>m_labelDontRunOSFixups.Name" xml:space="preserve">
<value>m_labelDontRunOSFixups</value>
</data>
<data name=">>m_labelDontRunOSFixups.Type" xml:space="preserve">
<value>XenAdmin.Controls.Common.AutoHeightLabel, XenCenterMain, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</value>
</data>
<data name=">>m_labelDontRunOSFixups.Parent" xml:space="preserve">
<value>tableLayoutPanel2</value>
</data>
<data name=">>m_labelDontRunOSFixups.ZOrder" xml:space="preserve">
<value>2</value>
</data>
<data name="m_radioButtonRunOSFixups.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="m_radioButtonRunOSFixups.Font" type="System.Drawing.Font, System.Drawing">
<value>Microsoft Sans Serif, 8.25pt, style=Bold</value>
</data>
<data name="m_radioButtonRunOSFixups.Location" type="System.Drawing.Point, System.Drawing">
<value>3, 147</value>
</data>
<data name="m_radioButtonRunOSFixups.Size" type="System.Drawing.Size, System.Drawing">
<value>184, 17</value>
</data>
<data name="m_radioButtonRunOSFixups.TabIndex" type="System.Int32, mscorlib">
<value>4</value>
</data>
<data name="m_radioButtonRunOSFixups.Text" xml:space="preserve">
<value>使用操作系统修复(&U)</value>
</data>
<data name=">>m_radioButtonRunOSFixups.Name" xml:space="preserve">
<value>m_radioButtonRunOSFixups</value>
</data>
<data name=">>m_radioButtonRunOSFixups.Type" xml:space="preserve">
<value>System.Windows.Forms.RadioButton, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>m_radioButtonRunOSFixups.Parent" xml:space="preserve">
<value>tableLayoutPanel2</value>
</data>
<data name=">>m_radioButtonRunOSFixups.ZOrder" xml:space="preserve">
<value>3</value>
</data>
<data name="m_labelRunOSFixups.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="m_labelRunOSFixups.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="m_labelRunOSFixups.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="m_labelRunOSFixups.Location" type="System.Drawing.Point, System.Drawing">
<value>23, 170</value>
</data>
<data name="m_labelRunOSFixups.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>3, 3, 3, 6</value>
</data>
<data name="m_labelRunOSFixups.Size" type="System.Drawing.Size, System.Drawing">
<value>567, 13</value>
</data>
<data name="m_labelRunOSFixups.TabIndex" type="System.Int32, mscorlib">
<value>5</value>
</data>
<data name="m_labelRunOSFixups.Text" xml:space="preserve">
<value>如果正在导入的 VM 是在除 [XenServer] 外的虚拟机管理程序上创建的,请选择此选项。</value>
</data>
<data name=">>m_labelRunOSFixups.Name" xml:space="preserve">
<value>m_labelRunOSFixups</value>
</data>
<data name=">>m_labelRunOSFixups.Type" xml:space="preserve">
<value>XenAdmin.Controls.Common.AutoHeightLabel, XenCenterMain, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</value>
</data>
<data name=">>m_labelRunOSFixups.Parent" xml:space="preserve">
<value>tableLayoutPanel2</value>
</data>
<data name=">>m_labelRunOSFixups.ZOrder" xml:space="preserve">
<value>4</value>
</data>
<data name="m_labelLocationFixupISO.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
<value>Left</value>
</data>
<data name="m_labelLocationFixupISO.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="m_labelLocationFixupISO.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="m_labelLocationFixupISO.Location" type="System.Drawing.Point, System.Drawing">
<value>23, 193</value>
</data>
<data name="m_labelLocationFixupISO.Size" type="System.Drawing.Size, System.Drawing">
<value>130, 19</value>
</data>
<data name="m_labelLocationFixupISO.TabIndex" type="System.Int32, mscorlib">
<value>6</value>
</data>
<data name="m_labelLocationFixupISO.Text" xml:space="preserve">
<value>操作系统修复 ISO 的位置(&L):</value>
</data>
<data name="m_labelLocationFixupISO.TextAlign" type="System.Drawing.ContentAlignment, System.Drawing">
<value>MiddleLeft</value>
</data>
<data name=">>m_labelLocationFixupISO.Name" xml:space="preserve">
<value>m_labelLocationFixupISO</value>
</data>
<data name=">>m_labelLocationFixupISO.Type" xml:space="preserve">
<value>System.Windows.Forms.Label, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>m_labelLocationFixupISO.Parent" xml:space="preserve">
<value>tableLayoutPanel2</value>
</data>
<data name=">>m_labelLocationFixupISO.ZOrder" xml:space="preserve">
<value>5</value>
</data>
<data name="m_comboBoxISOLibraries.Location" type="System.Drawing.Point, System.Drawing">
<value>159, 192</value>
</data>
<data name="m_comboBoxISOLibraries.Size" type="System.Drawing.Size, System.Drawing">
<value>213, 21</value>
</data>
<data name="m_comboBoxISOLibraries.TabIndex" type="System.Int32, mscorlib">
<value>7</value>
</data>
<data name=">>m_comboBoxISOLibraries.Name" xml:space="preserve">
<value>m_comboBoxISOLibraries</value>
</data>
<data name=">>m_comboBoxISOLibraries.Type" xml:space="preserve">
<value>XenAdmin.Controls.LongStringComboBox, XenCenterMain, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</value>
</data>
<data name=">>m_comboBoxISOLibraries.Parent" xml:space="preserve">
<value>tableLayoutPanel2</value>
</data>
<data name=">>m_comboBoxISOLibraries.ZOrder" xml:space="preserve">
<value>6</value>
</data>
<data name="m_pictureBoxInfo.Location" type="System.Drawing.Point, System.Drawing">
<value>159, 219</value>
</data>
<data name="m_pictureBoxInfo.Size" type="System.Drawing.Size, System.Drawing">
<value>16, 16</value>
</data>
<data name="m_pictureBoxInfo.TabIndex" type="System.Int32, mscorlib">
<value>81</value>
</data>
<data name="m_pictureBoxInfo.Visible" type="System.Boolean, mscorlib">
<value>False</value>
</data>
<data name=">>m_pictureBoxInfo.Name" xml:space="preserve">
<value>m_pictureBoxInfo</value>
</data>
<data name=">>m_pictureBoxInfo.Type" xml:space="preserve">
<value>System.Windows.Forms.PictureBox, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>m_pictureBoxInfo.Parent" xml:space="preserve">
<value>tableLayoutPanel2</value>
</data>
<data name=">>m_pictureBoxInfo.ZOrder" xml:space="preserve">
<value>7</value>
</data>
<data name="m_labelFixupISOInfo.Anchor" type="System.Windows.Forms.AnchorStyles, System.Windows.Forms">
<value>Left, Right</value>
</data>
<data name="m_labelFixupISOInfo.AutoSize" type="System.Boolean, mscorlib">
<value>True</value>
</data>
<data name="m_labelFixupISOInfo.ImeMode" type="System.Windows.Forms.ImeMode, System.Windows.Forms">
<value>NoControl</value>
</data>
<data name="m_labelFixupISOInfo.Location" type="System.Drawing.Point, System.Drawing">
<value>181, 219</value>
</data>
<data name="m_labelFixupISOInfo.Size" type="System.Drawing.Size, System.Drawing">
<value>409, 16</value>
</data>
<data name="m_labelFixupISOInfo.TabIndex" type="System.Int32, mscorlib">
<value>8</value>
</data>
<data name="m_labelFixupISOInfo.Text" xml:space="preserve">
<value>修复 ISO 将自动复制到所选 SR</value>
</data>
<data name="m_labelFixupISOInfo.Visible" type="System.Boolean, mscorlib">
<value>False</value>
</data>
<data name=">>m_labelFixupISOInfo.Name" xml:space="preserve">
<value>m_labelFixupISOInfo</value>
</data>
<data name=">>m_labelFixupISOInfo.Type" xml:space="preserve">
<value>XenAdmin.Controls.Common.AutoHeightLabel, XenCenterMain, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</value>
</data>
<data name=">>m_labelFixupISOInfo.Parent" xml:space="preserve">
<value>tableLayoutPanel2</value>
</data>
<data name=">>m_labelFixupISOInfo.ZOrder" xml:space="preserve">
<value>8</value>
</data>
<data name="tableLayoutPanel2.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="tableLayoutPanel2.Location" type="System.Drawing.Point, System.Drawing">
<value>0, 0</value>
</data>
<data name="tableLayoutPanel2.RowCount" type="System.Int32, mscorlib">
<value>9</value>
</data>
<data name="tableLayoutPanel2.Size" type="System.Drawing.Size, System.Drawing">
<value>593, 270</value>
</data>
<data name="tableLayoutPanel2.TabIndex" type="System.Int32, mscorlib">
<value>0</value>
</data>
<data name=">>tableLayoutPanel2.Name" xml:space="preserve">
<value>tableLayoutPanel2</value>
</data>
<data name=">>tableLayoutPanel2.Type" xml:space="preserve">
<value>System.Windows.Forms.TableLayoutPanel, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</data>
<data name=">>tableLayoutPanel2.Parent" xml:space="preserve">
<value>$this</value>
</data>
<data name=">>tableLayoutPanel2.ZOrder" xml:space="preserve">
<value>0</value>
</data>
<data name="tableLayoutPanel2.LayoutSettings" type="System.Windows.Forms.TableLayoutSettings, System.Windows.Forms">
<value><?xml version="1.0" encoding="utf-16"?><TableLayoutSettings><Controls><Control Name="m_labelIntro" Row="0" RowSpan="1" Column="0" ColumnSpan="4" /><Control Name="m_radioButtonDontRunOSFixups" Row="2" RowSpan="1" Column="0" ColumnSpan="4" /><Control Name="m_labelDontRunOSFixups" Row="3" RowSpan="1" Column="1" ColumnSpan="3" /><Control Name="m_radioButtonRunOSFixups" Row="4" RowSpan="1" Column="0" ColumnSpan="4" /><Control Name="m_labelRunOSFixups" Row="5" RowSpan="1" Column="1" ColumnSpan="3" /><Control Name="m_labelLocationFixupISO" Row="6" RowSpan="1" Column="1" ColumnSpan="1" /><Control Name="m_comboBoxISOLibraries" Row="6" RowSpan="1" Column="2" ColumnSpan="2" /><Control Name="m_pictureBoxInfo" Row="7" RowSpan="1" Column="2" ColumnSpan="1" /><Control Name="m_labelFixupISOInfo" Row="7" RowSpan="1" Column="3" ColumnSpan="1" /><Control Name="m_ctrlError" Row="8" RowSpan="1" Column="2" ColumnSpan="2" /></Controls><Columns Styles="Absolute,20,AutoSize,0,AutoSize,0,Percent,100" /><Rows Styles="AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,AutoSize,0,Absolute,20" /></TableLayoutSettings></value>
</data>
<data name="m_ctrlError.Dock" type="System.Windows.Forms.DockStyle, System.Windows.Forms">
<value>Fill</value>
</data>
<data name="m_ctrlError.Error" xml:space="preserve">
<value/>
</data>
<data name="m_ctrlError.Location" type="System.Drawing.Point, System.Drawing">
<value>156, 241</value>
</data>
<data name="m_ctrlError.Margin" type="System.Windows.Forms.Padding, System.Windows.Forms">
<value>0, 3, 3, 3</value>
</data>
<data name="m_ctrlError.Size" type="System.Drawing.Size, System.Drawing">
<value>434, 26</value>
</data>
<data name="m_ctrlError.TabIndex" type="System.Int32, mscorlib">
<value>9</value>
</data>
<data name="m_ctrlError.Visible" type="System.Boolean, mscorlib">
<value>False</value>
</data>
<data name=">>m_ctrlError.Name" xml:space="preserve">
<value>m_ctrlError</value>
</data>
<data name=">>m_ctrlError.Type" xml:space="preserve">
<value>XenAdmin.Controls.Common.PasswordFailure, XenCenterMain, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</value>
</data>
<data name=">>m_ctrlError.Parent" xml:space="preserve">
<value>tableLayoutPanel2</value>
</data>
<data name=">>m_ctrlError.ZOrder" xml:space="preserve">
<value>9</value>
</data>
<metadata name="$this.Localizable" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<data name="$this.AutoScaleDimensions" type="System.Drawing.SizeF, System.Drawing">
<value>96, 96</value>
</data>
<data name="$this.Size" type="System.Drawing.Size, System.Drawing">
<value>593, 270</value>
</data>
<data name=">>$this.Name" xml:space="preserve">
<value>ImportOptionsPage</value>
</data>
<data name=">>$this.Type" xml:space="preserve">
<value>XenAdmin.Controls.XenTabPage, XenCenterMain, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null</value>
</data>
</root> | {
"pile_set_name": "Github"
} |
include: ../dart_test_base.yaml
| {
"pile_set_name": "Github"
} |
@model Kooboo.CMS.Web.Areas.Account.Models.ChangeLanguageModel
@{
ViewBag.Title = "Change language".Localize();
Layout = "~/Views/Shared/Blank.cshtml";
}
@section Panel{
<ul class="panel">
<li>
<a data-ajaxform="">
@Html.IconImage("save") @("Save".Localize())</a>
</li>
@foreach (var group in Kooboo.CMS.Sites.Extension.UI.TopToolbar.ToolbarButtons.GetToolbarButtons(ViewContext.RequestContext))
{
@Html.Partial("_ToolbarGroupButtons", group)
}
<li>
<a href="@ViewContext.RequestContext.GetRequestValue("return")">
@Html.IconImage("cancel") @("Back".Localize())</a>
</li>
</ul>
}
<div class="common-form">
<h1 class="title">@("Change language".Localize())</h1>
@using (Html.BeginForm())
{
<table>
<tbody>
@Html.EditorFor(m => m.UICulture)
</tbody>
</table>
}
</div>
| {
"pile_set_name": "Github"
} |
import { Directive, Input, AfterContentInit, ContentChildren, QueryList } from '@angular/core';
import { CKEditorComponent } from './ckeditor.component';
import { CKButtonDirective } from './ckbutton.directive';
/**
* CKGroup component
* Usage :
* <ckeditor [(ngModel)]="data" [config]="{...}" debounce="500">
* <ckgroup [name]="'exampleGroup2'" [previous]="'1'" [subgroupOf]="'exampleGroup1'">
* .
* .
* </ckgroup>
* </ckeditor>
*/
@Directive({
selector: 'ckgroup',
})
export class CKGroupDirective implements AfterContentInit {
@Input() name: string;
@Input() previous: any;
@Input() subgroupOf: string;
@ContentChildren(CKButtonDirective) toolbarButtons: QueryList<CKButtonDirective>;
ngAfterContentInit() {
// Reconfigure each button's toolbar property within ckgroup to hold its parent's name
this.toolbarButtons.forEach(button => (button.toolbar = this.name));
}
public initialize(editor: CKEditorComponent) {
editor.instance.ui.addToolbarGroup(this.name, this.previous, this.subgroupOf);
// Initialize each button within ckgroup
this.toolbarButtons.forEach(button => {
button.initialize(editor);
});
}
}
| {
"pile_set_name": "Github"
} |
SHA256 (pinocchio-0.4.2.tar.gz) = bc53568703bc8e22d0b96010be657a5ebc6ca445defa45878568a0aef992c343
SIZE (pinocchio-0.4.2.tar.gz) = 12118
| {
"pile_set_name": "Github"
} |
/*
* Generated by class-dump 3.3.4 (64 bit).
*
* class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2011 by Steve Nygard.
*/
//#import "NSObject.h"
//#import "FBLazyInitializing-Protocol.h"
//#import "FBStickerResourceManager-Protocol.h"
@class FBCache, FBMStickerStoragePathManager, FBStickerResourceFileNameConverter, FBStickerResourceImageConverter, FBStickerResourceMap, FBStickerResourceTypeConfigProvider, FBStickersPerfLogger, FBUserSession, NSFileManager, NSMutableDictionary, NSOperationQueue, NSSet, NSString;
@interface FBMStickerResourceManagerLegacy : NSObject //<FBLazyInitializing, FBStickerResourceManager>
{
FBCache *_inMemoryCache;
FBCache *_staticStickerCache;
FBCache *_animatedStickerCache;
NSFileManager *_fileManager;
FBMStickerStoragePathManager *_stickerStoragePathManager;
FBStickersPerfLogger *_perfLogger;
FBStickerResourceTypeConfigProvider *_resourceTypeConfigProvider;
FBStickerResourceFileNameConverter *_stickerResourceFileNameConverter;
FBStickerResourceMap *_resourceMap;
FBStickerResourceImageConverter *_imageConverter;
NSOperationQueue *_animatedStickerTaskQueue;
NSMutableDictionary *_needToLoadStickerId;
FBUserSession *_session;
NSSet *_firstLevelDirectories;
}
@property(copy, nonatomic) NSSet *firstLevelDirectories; // @synthesize firstLevelDirectories=_firstLevelDirectories;
@property(readonly, nonatomic) FBUserSession *session; // @synthesize session=_session;
//- (void).cxx_destruct;
- (void)getAnimatedStickerWithFbId:(unsigned long long)arg1 completion:(id)arg2;
- (void)stopGettingAnimatedStickerWithFbId:(unsigned long long)arg1;
- (BOOL)_haveTaskWithFbId:(unsigned long long)arg1;
- (void)_addToTaskQueueWithFbId:(unsigned long long)arg1 stickerTask:(id)arg2;
- (void)_removeFromTaskQueueWithFbId:(unsigned long long)arg1;
- (BOOL)_isCancelledWithFbId:(unsigned long long)arg1;
- (void)getAllResourcesOnDiskWithSuccess:(id)arg1 failure:(void)arg2;
- (void)_blockUntilInitializationComplete;
- (BOOL)_makeDirectoryIfNeeded:(id)arg1 error:(id *)arg2;
- (BOOL)_addSkipBackupAttributeToPathURL:(id)arg1;
- (void)_createRootDirectoryIfNeeded;
- (id)_resourceFileNameWithFbId:(unsigned long long)arg1 type:(unsigned int)arg2;
- (id)_generateBundlePathForFileName:(id)arg1 type:(unsigned int)arg2;
- (void)_readFilePathWithFbId:(unsigned long long)arg1 type:(unsigned int)arg2 callbackQueue:(id)arg3 completion:(id)arg4;
- (id)_writeFilePathWithFbId:(unsigned long long)arg1 type:(unsigned int)arg2;
- (id)_generatePathForFileName:(id)arg1;
- (void)deleteResourcesWithStickerPackFbId:(unsigned long long)arg1 success:(id)arg2 failure:(void)arg3;
- (void)_removeResourcesFromMapWithStickerPackId:(unsigned long long)arg1;
- (void)_addResourceToMap:(unsigned long long)arg1 resourceType:(unsigned int)arg2 stickerPackId:(unsigned long long)arg3;
- (void)_loadResourceMap;
- (BOOL)_removeResources:(id)arg1 error:(id *)arg2;
- (void)_getCachedResourceWithFbId:(unsigned long long)arg1 startTime:(unsigned long long)arg2 resourceType:(unsigned int)arg3 completion:(id)arg4;
- (void)_getCachedImageWithFbId:(unsigned long long)arg1 startTime:(unsigned long long)arg2 resourceType:(unsigned int)arg3 completion:(id)arg4;
- (void)cachedResourceWithFbId:(unsigned long long)arg1 resourceType:(unsigned int)arg2 completion:(id)arg3;
- (void)cachedImageWithFbId:(unsigned long long)arg1 resourceType:(unsigned int)arg2 completion:(id)arg3;
- (id)_cachedInMemoryResourceWithFbId:(unsigned long long)arg1 resourceType:(unsigned int)arg2;
- (id)_inMemCacheKeyWith:(unsigned long long)arg1 type:(unsigned int)arg2;
- (void)deleteResourceWithFbId:(unsigned long long)arg1 resourceType:(unsigned int)arg2 queue:(id)arg3 success:(id)arg4 failure:(void)arg5;
- (id)_loadDictionaryAtPath:(id)arg1;
- (id)_plistAtPath:(id)arg1 fbId:(unsigned long long)arg2 resourceType:(unsigned int)arg3 memoryCacheOnly:(BOOL)arg4;
- (BOOL)saveImageData:(id)arg1 fbId:(unsigned long long)arg2 resourceType:(unsigned int)arg3 stickerPackFbId:(unsigned long long)arg4 ofOwnedStickerPack:(BOOL)arg5 error:(id *)arg6;
- (id)_imageAtPath:(id)arg1 fbId:(unsigned long long)arg2 resourceType:(unsigned int)arg3 memoryCacheOnly:(BOOL)arg4;
- (id)_chooseCacheWithType:(unsigned int)arg1;
- (void)_appBackground;
- (void)_migrateFiles;
- (void)_migrateIfNeeded;
- (id)prepareLazyState;
- (void)dealloc;
- (id)initWithInMemoryCache:(id)arg1 staticStickerCache:(id)arg2 animatedStickerCache:(id)arg3 fileManager:(id)arg4 stickerStoragePathManager:(id)arg5 session:(id)arg6;
- (id)initWithStaticStickerCache:(id)arg1 animatedStickerCache:(id)arg2 fileManager:(id)arg3 stickerStoragePathManager:(id)arg4 session:(id)arg5;
- (id)initWithInMemoryCache:(id)arg1 fileManager:(id)arg2 stickerStoragePathManager:(id)arg3 session:(id)arg4;
// Remaining properties
@property(readonly, copy) NSString *debugDescription;
@property(readonly, copy) NSString *description;
@property(readonly) unsigned int hash;
@property(readonly) Class superclass;
@end
| {
"pile_set_name": "Github"
} |
import { TypedRule } from '@fimbul/ymir';
import {
isElementAccessExpression,
isIdentifier,
isPropertyAccessExpression,
getUsageDomain,
isCallLikeExpression,
isObjectBindingPattern,
getPropertyName,
isPropertyAssignment,
isReassignmentTarget,
isShorthandPropertyAssignment,
getLateBoundPropertyNames,
getLateBoundPropertyNamesOfPropertyName,
getPropertyOfType,
} from 'tsutils';
import * as ts from 'typescript';
import { elementAccessSymbols, propertiesOfType } from '../utils';
const functionLikeSymbol = ts.SymbolFlags.Function | ts.SymbolFlags.Method;
const signatureFormatFlags = ts.TypeFormatFlags.UseFullyQualifiedType | ts.TypeFormatFlags.UseAliasDefinedOutsideCurrentScope;
export class Rule extends TypedRule {
public apply() {
for (const node of this.context.getFlatAst()) {
// TODO maybe check Type["property"]
if (isIdentifier(node)) {
if (shouldCheckIdentifier(node))
this.checkSymbol(this.checker.getSymbolAtLocation(node), node, node.text);
} else if (isPropertyAccessExpression(node)) {
this.checkSymbol(this.checker.getSymbolAtLocation(node), node, node.name.text);
} else if (isElementAccessExpression(node)) {
this.checkElementAccess(node);
} else if (isPropertyAssignment(node)) {
if (isReassignmentTarget(node.parent))
this.checkObjectDestructuring(node);
} else if (isShorthandPropertyAssignment(node)) {
this.checkSymbol(this.checker.getShorthandAssignmentValueSymbol(node), node, node.name.text);
if (isReassignmentTarget(node.parent))
this.checkObjectDestructuring(node);
} else if (isCallLikeExpression(node)) {
this.checkSignature(node);
} else if (isObjectBindingPattern(node)) {
this.checkObjectBindingPattern(node);
} else if (node.kind === ts.SyntaxKind.QualifiedName && shouldCheckQualifiedName(node)) {
this.checkSymbol(this.checker.getSymbolAtLocation(node), node, node.right.text);
}
}
}
private checkObjectDestructuring(node: ts.PropertyAssignment | ts.ShorthandPropertyAssignment) {
const type = this.checker.getTypeOfAssignmentPattern(node.parent!);
for (const {symbolName, displayName} of getLateBoundPropertyNamesOfPropertyName(node.name, this.checker).names) {
const symbol = getPropertyOfType(type, symbolName);
if (symbol !== undefined)
this.checkStability(symbol, node.name, displayName, describeWithName);
}
}
private checkSignature(node: ts.CallLikeExpression) {
return this.checkStability(this.checker.getResolvedSignature(node)!, node, undefined, signatureToString);
}
private checkObjectBindingPattern(node: ts.ObjectBindingPattern) {
const type = this.checker.getTypeAtLocation(node)!;
for (const element of node.elements) {
if (element.dotDotDotToken !== undefined)
continue;
if (element.propertyName === undefined) {
const name = (<ts.Identifier>element.name).text;
const symbol = type.getProperty(name);
if (symbol !== undefined)
this.checkStability(symbol, element.name, name, describeWithName);
} else {
const propName = getPropertyName(element.propertyName);
if (propName !== undefined) {
const symbol = type.getProperty(propName);
if (symbol !== undefined)
this.checkStability(symbol, element.propertyName, propName, describeWithName);
} else {
for (const {symbol, name} of propertiesOfType(
type,
getLateBoundPropertyNames((<ts.ComputedPropertyName>element.propertyName).expression!, this.checker).names,
)
)
this.checkStability(symbol, element.propertyName, name, describeWithName);
}
}
}
}
private checkElementAccess(node: ts.ElementAccessExpression) {
for (const {symbol, name} of elementAccessSymbols(node, this.checker))
this.checkSymbol(symbol, node, name);
}
private checkSymbol(symbol: ts.Symbol | undefined, node: ts.Node, name: string) {
if (symbol === undefined)
return;
if (symbol.flags & ts.SymbolFlags.Alias)
symbol = this.checker.getAliasedSymbol(symbol);
if ((symbol.flags & functionLikeSymbol) && isPartOfCall(node))
return;
return this.checkStability(symbol, node, name, describeWithName);
}
private checkStability<T extends ts.Signature | ts.Symbol, U extends ts.Node, V>(
s: T,
node: U,
hint: V,
descr: (s: T, checker: ts.TypeChecker, hint: V, node: U) => string,
) {
for (const tag of s.getJsDocTags())
if (tag.name === 'deprecated' || tag.name === 'experimental')
this.addFindingAtNode(
node,
`${descr(s, this.checker, hint, node)} is ${tag.name}${tag.text ? ': ' + tag.text : '.'}`,
);
}
}
function describeWithName(symbol: ts.Symbol, _c: ts.TypeChecker, name: string) {
return `${describeSymbol(symbol)} '${name}'`;
}
function describeSymbol(symbol: ts.Symbol): string {
if (symbol.flags & ts.SymbolFlags.Variable)
return 'Variable';
if (symbol.flags & ts.SymbolFlags.PropertyOrAccessor)
return 'Property';
if (symbol.flags & ts.SymbolFlags.Class)
return 'Class';
if (symbol.flags & ts.SymbolFlags.Enum)
return 'Enum';
if (symbol.flags & ts.SymbolFlags.EnumMember)
return 'EnumMember';
if (symbol.flags & ts.SymbolFlags.Function)
return 'Function';
if (symbol.flags & ts.SymbolFlags.Method)
return 'Method';
if (symbol.flags & ts.SymbolFlags.Interface)
return 'Interface';
if (symbol.flags & ts.SymbolFlags.NamespaceModule)
return 'Namespace';
if (symbol.flags & ts.SymbolFlags.TypeAlias)
return 'TypeAlias';
return '(unknown)';
}
function signatureToString(signature: ts.Signature, checker: ts.TypeChecker, _: undefined, node: ts.CallLikeExpression) {
let construct = false;
switch (signature.declaration && signature.declaration.kind) {
case ts.SyntaxKind.Constructor:
case ts.SyntaxKind.ConstructSignature:
case ts.SyntaxKind.ConstructorType:
construct = true;
}
let name = '';
const expr = getExpressionOfCallLike(node);
if (isIdentifier(expr)) {
name = expr.text;
} else if (isPropertyAccessExpression(expr)) {
name = expr.name.text;
} else if (expr.kind === ts.SyntaxKind.SuperKeyword) {
name = 'super';
}
return `${construct ? 'Costruct' : 'Call'}Signature '${
construct && expr.kind !== ts.SyntaxKind.SuperKeyword ? 'new ' : ''
}${name}${checker.signatureToString(signature, undefined, signatureFormatFlags)}'`;
}
function getExpressionOfCallLike(node: ts.CallLikeExpression): ts.Expression {
switch (node.kind) {
case ts.SyntaxKind.CallExpression:
case ts.SyntaxKind.NewExpression:
case ts.SyntaxKind.Decorator:
return (<ts.CallExpression | ts.NewExpression | ts.Decorator>node).expression;
case ts.SyntaxKind.TaggedTemplateExpression:
return (<ts.TaggedTemplateExpression>node).tag;
case ts.SyntaxKind.JsxOpeningElement:
case ts.SyntaxKind.JsxSelfClosingElement:
return (<ts.JsxOpeningLikeElement>node).tagName;
}
}
function isPartOfCall(node: ts.Node) {
while (true) {
const parent = node.parent!;
switch (parent.kind) {
case ts.SyntaxKind.TaggedTemplateExpression:
case ts.SyntaxKind.Decorator:
return true;
case ts.SyntaxKind.CallExpression:
// note: NewExpression will never get here, because if the class is deprecated, we show an error all the time
return (<ts.CallExpression>parent).expression === node;
case ts.SyntaxKind.JsxOpeningElement:
case ts.SyntaxKind.JsxSelfClosingElement:
return (<ts.JsxOpeningLikeElement>parent).tagName === node;
case ts.SyntaxKind.ParenthesizedExpression:
node = parent;
break;
default:
return false;
}
}
}
function shouldCheckIdentifier(node: ts.Identifier): boolean {
switch (node.parent!.kind) {
case ts.SyntaxKind.ImportEqualsDeclaration:
case ts.SyntaxKind.ExportAssignment:
case ts.SyntaxKind.ExportSpecifier:
case ts.SyntaxKind.JsxClosingElement:
return false;
case ts.SyntaxKind.ShorthandPropertyAssignment: // checked separately
return (<ts.ShorthandPropertyAssignment>node.parent).name !== node;
default:
return getUsageDomain(node) !== undefined;
}
}
function shouldCheckQualifiedName(node: ts.Node): node is ts.QualifiedName {
// if parent is a QualifiedName, it is the my.ns part of my.ns.Something -> we definitely want to check that
// if the parent is an ImportEqualsDeclaration -> we don't want to check the rightmost identifier, because importing is not that bad
// everything else is a TypeReference -> we want to check that
return node.parent!.kind !== ts.SyntaxKind.ImportEqualsDeclaration;
}
| {
"pile_set_name": "Github"
} |
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* ***** BEGIN LICENSE BLOCK *****
* Version: MPL 1.1/GPL 2.0/LGPL 2.1
*
* The contents of this file are subject to the Mozilla Public License Version
* 1.1 (the "License"); you may not use this file except in compliance with
* the License. You may obtain a copy of the License at
* http://www.mozilla.org/MPL/
*
* Software distributed under the License is distributed on an "AS IS" basis,
* WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
* for the specific language governing rights and limitations under the
* License.
*
* The Original Code is Mozilla Universal charset detector code.
*
* The Initial Developer of the Original Code is
* Netscape Communications Corporation.
* Portions created by the Initial Developer are Copyright (C) 2001
* the Initial Developer. All Rights Reserved.
*
* Contributor(s):
* Shy Shalom <[email protected]>
*
* Alternatively, the contents of this file may be used under the terms of
* either the GNU General Public License Version 2 or later (the "GPL"), or
* the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
* in which case the provisions of the GPL or the LGPL are applicable instead
* of those above. If you wish to allow use of your version of this file only
* under the terms of either the GPL or the LGPL, and not to allow others to
* use your version of this file under the terms of the MPL, indicate your
* decision by deleting the provisions above and replace them with the notice
* and other provisions required by the GPL or the LGPL. If you do not delete
* the provisions above, a recipient may use your version of this file under
* the terms of any one of the MPL, the GPL or the LGPL.
*
* ***** END LICENSE BLOCK ***** */
#include "nscore.h"
#include "nsUniversalDetector.h"
#include "nsUdetXPCOMWrapper.h"
#include "nsCharSetProber.h" // for DumpStatus
#include "nsUniversalCharDetDll.h"
//---- for XPCOM
#include "nsIFactory.h"
#include "nsISupports.h"
#include "pratom.h"
#include "prmem.h"
#include "nsCOMPtr.h"
static NS_DEFINE_CID(kUniversalDetectorCID, NS_UNIVERSAL_DETECTOR_CID);
static NS_DEFINE_CID(kUniversalStringDetectorCID, NS_UNIVERSAL_STRING_DETECTOR_CID);
//---------------------------------------------------------------------
nsUniversalXPCOMDetector:: nsUniversalXPCOMDetector() : nsUniversalDetector()
{
}
//---------------------------------------------------------------------
nsUniversalXPCOMDetector::~nsUniversalXPCOMDetector()
{
}
//---------------------------------------------------------------------
NS_IMPL_ISUPPORTS1(nsUniversalXPCOMDetector, nsICharsetDetector)
//---------------------------------------------------------------------
NS_IMETHODIMP nsUniversalXPCOMDetector::Init(
nsICharsetDetectionObserver* aObserver)
{
NS_ASSERTION(mObserver == nsnull , "Init twice");
if(nsnull == aObserver)
return NS_ERROR_ILLEGAL_VALUE;
mObserver = aObserver;
return NS_OK;
}
//----------------------------------------------------------
NS_IMETHODIMP nsUniversalXPCOMDetector::DoIt(const char* aBuf,
PRUint32 aLen, PRBool* oDontFeedMe)
{
NS_ASSERTION(mObserver != nsnull , "have not init yet");
if((nsnull == aBuf) || (nsnull == oDontFeedMe))
return NS_ERROR_ILLEGAL_VALUE;
nsresult rv = this->HandleData(aBuf, aLen);
if (NS_FAILED(rv))
return rv;
if (mDone)
{
if (mDetectedCharset)
Report(mDetectedCharset);
*oDontFeedMe = PR_TRUE;
}
*oDontFeedMe = PR_FALSE;
return NS_OK;
}
//----------------------------------------------------------
NS_IMETHODIMP nsUniversalXPCOMDetector::Done()
{
NS_ASSERTION(mObserver != nsnull , "have not init yet");
#ifdef DEBUG_chardet
for (PRInt32 i = 0; i < NUM_OF_CHARSET_PROBERS; i++)
{
// If no data was received the array might stay filled with nulls
// the way it was initialized in the constructor.
if (mCharSetProbers[i])
mCharSetProbers[i]->DumpStatus();
}
#endif
this->DataEnd();
return NS_OK;
}
//----------------------------------------------------------
void nsUniversalXPCOMDetector::Report(const char* aCharset)
{
NS_ASSERTION(mObserver != nsnull , "have not init yet");
#ifdef DEBUG_chardet
printf("Universal Charset Detector report charset %s . \r\n", aCharset);
#endif
mObserver->Notify(aCharset, eBestAnswer);
}
//---------------------------------------------------------------------
nsUniversalXPCOMStringDetector:: nsUniversalXPCOMStringDetector()
: nsUniversalDetector()
{
}
//---------------------------------------------------------------------
nsUniversalXPCOMStringDetector::~nsUniversalXPCOMStringDetector()
{
}
//---------------------------------------------------------------------
NS_IMPL_ISUPPORTS1(nsUniversalXPCOMStringDetector, nsIStringCharsetDetector)
//---------------------------------------------------------------------
void nsUniversalXPCOMStringDetector::Report(const char *aCharset)
{
mResult = aCharset;
#ifdef DEBUG_chardet
printf("New Charset Prober report charset %s . \r\n", aCharset);
#endif
}
//---------------------------------------------------------------------
NS_IMETHODIMP nsUniversalXPCOMStringDetector::DoIt(const char* aBuf,
PRUint32 aLen, const char** oCharset,
nsDetectionConfident &oConf)
{
mResult = nsnull;
this->Reset();
nsresult rv = this->HandleData(aBuf, aLen);
if (NS_FAILED(rv))
return rv;
this->DataEnd();
if (mResult)
{
*oCharset=mResult;
oConf = eBestAnswer;
}
return NS_OK;
}
| {
"pile_set_name": "Github"
} |
// Protocol Buffers for Go with Gadgets
//
// Copyright (c) 2016, The GoGo Authors. All rights reserved.
// http://github.com/gogo/protobuf
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
// copyright notice, this list of conditions and the following disclaimer
// in the documentation and/or other materials provided with the
// distribution.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
package proto
import (
"reflect"
"time"
)
var durationType = reflect.TypeOf((*time.Duration)(nil)).Elem()
type duration struct {
Seconds int64 `protobuf:"varint,1,opt,name=seconds,proto3" json:"seconds,omitempty"`
Nanos int32 `protobuf:"varint,2,opt,name=nanos,proto3" json:"nanos,omitempty"`
}
func (m *duration) Reset() { *m = duration{} }
func (*duration) ProtoMessage() {}
func (*duration) String() string { return "duration<string>" }
func init() {
RegisterType((*duration)(nil), "gogo.protobuf.proto.duration")
}
| {
"pile_set_name": "Github"
} |
<root dataType="Struct" type="Duality.Resources.Material" id="129723834">
<assetInfo />
<info dataType="Struct" type="Duality.Drawing.BatchInfo" id="427169525">
<mainColor dataType="Struct" type="Duality.Drawing.ColorRgba">
<A dataType="Byte">255</A>
<B dataType="Byte">255</B>
<G dataType="Byte">255</G>
<R dataType="Byte">255</R>
</mainColor>
<parameters dataType="Struct" type="Duality.Drawing.ShaderParameterCollection" id="1100841590" custom="true">
<body>
<mainTex dataType="Struct" type="Duality.ContentRef`1[[Duality.Resources.Texture]]">
<contentPath dataType="String">Data\SteeringSample\Textures\Floor.Texture.res</contentPath>
</mainTex>
</body>
</parameters>
<technique dataType="Struct" type="Duality.ContentRef`1[[Duality.Resources.DrawTechnique]]">
<contentPath dataType="String">Default:DrawTechnique:Solid</contentPath>
</technique>
</info>
</root>
<!-- XmlFormatterBase Document Separator -->
| {
"pile_set_name": "Github"
} |
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<system.webServer>
<handlers>
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModule" resourceType="Unspecified" />
</handlers>
<aspNetCore processPath="dotnet" arguments="Frank.Falco.dll" stdoutLogEnabled="false" stdoutLogFile="logs/stdout" />
</system.webServer>
</configuration> | {
"pile_set_name": "Github"
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.