text
stringlengths
1
1.04M
language
stringclasses
25 values
Our editors will review what you’ve submitted and determine whether to revise the article. - Died: - July 4, 1948, São Paulo (aged 66) José Bento Monteiro Lobato, (born April 18, 1882, Taubaté, Brazil—died July 4, 1948, São Paulo), writer and publisher, forerunner of the Modernist movement in Brazilian literature. A man of action, Monteiro Lobato moved to São Paulo, founded the literary review Revista do Brasil and a publishing house, and gathered around him a circle of new literary talents. Critical and rebellious, he was in and out of prison and exile many times. He also wrote children’s books enjoyed equally well by adults.
english
use crate::util::parse_graphql_response::parse_graphql_response; use chrono::Utc; use hyper::{ body::to_bytes, header, header::HeaderValue, Body, Request, Response, StatusCode, }; use juniper::{ http::GraphQLRequest, DefaultScalarValue, GraphQLTypeAsync, RootNode, }; use std::{ convert::Infallible, sync::Arc, time::Instant, }; pub async fn graphql_post< Q: GraphQLTypeAsync<DefaultScalarValue, Context = Ctxt>, M: GraphQLTypeAsync<DefaultScalarValue, Context = Ctxt>, Ctxt: Send + Sync, >( root_node: Arc<RootNode<'_, Q, M>>, context: Ctxt, req: Request<Body>, ) -> Result<Response<Body>, Infallible> where <Q as juniper::GraphQLType>::TypeInfo: Send + Sync, <M as juniper::GraphQLType>::TypeInfo: Send + Sync, { let start_time = Utc::now(); let start_instant = Instant::now(); match to_bytes(req.into_body()).await { Ok(body) => match serde_json::from_slice::<GraphQLRequest<DefaultScalarValue>>(&body) { Ok(request) => { let resp = request.execute_async(&root_node, &context).await; Ok(parse_graphql_response(resp, start_time, start_instant)) } Err(_e) => { let mut resp = Response::new(Body::from( serde_json::to_string_pretty("Body was not valid json").unwrap(), )); *resp.status_mut() = StatusCode::BAD_REQUEST; resp.headers_mut().insert( header::CONTENT_TYPE, HeaderValue::from_static("application/json"), ); Ok(resp) } }, Err(_e) => { let mut resp = Response::new(Body::from( serde_json::to_string_pretty("Failed to parse body").unwrap(), )); *resp.status_mut() = StatusCode::BAD_REQUEST; resp.headers_mut().insert( header::CONTENT_TYPE, HeaderValue::from_static("application/json"), ); Ok(resp) } } }
rust
{ "schema_version": "1.2.0", "id": "GHSA-7v6r-rp2v-rc22", "modified": "2022-04-29T01:27:09Z", "published": "2022-04-29T01:27:09Z", "aliases": [ "CVE-2003-0895" ], "details": "Buffer overflow in the Mac OS X kernel 10.2.8 and earlier allows local users, and possibly remote attackers, to cause a denial of service (crash), access portions of memory, and possibly execute arbitrary code via a long command line argument (argv[]).", "severity": [ ], "affected": [ ], "references": [ { "type": "ADVISORY", "url": "https://nvd.nist.gov/vuln/detail/CVE-2003-0895" }, { "type": "WEB", "url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/13541" }, { "type": "WEB", "url": "http://lists.apple.com/mhonarc/security-announce/msg00038.html" }, { "type": "WEB", "url": "http://www.atstake.com/research/advisories/2003/a102803-3.txt" }, { "type": "WEB", "url": "http://www.securityfocus.com/bid/8913" } ], "database_specific": { "cwe_ids": [ ], "severity": "MODERATE", "github_reviewed": false } }
json
<reponame>zhangpf/fuchsia-rs<gh_stars>1-10 // Copyright 2016 The Fuchsia Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include <assert.h> #include <dirent.h> #include <errno.h> #include <fcntl.h> #include <stdio.h> #include <stdlib.h> #include <string.h> #include <threads.h> #include <unistd.h> #include <limits.h> #include <fbl/algorithm.h> #include <fbl/unique_ptr.h> #include <fuchsia/hardware/input/c/fidl.h> #include <lib/fdio/watcher.h> #include <lib/fzl/fdio.h> #include <zircon/assert.h> #include <zircon/listnode.h> #include <zircon/threads.h> #include <zircon/types.h> #include <utility> // defined in report.cpp void print_report_descriptor(const uint8_t* rpt_desc, size_t desc_len); #define DEV_INPUT "/dev/class/input" static bool verbose = false; #define xprintf(fmt...) do { if (verbose) printf(fmt); } while (0) void usage(void) { printf("usage: hid [-v] <command> [<args>]\n\n"); printf(" commands:\n"); printf(" read [<devpath> [num reads]]\n"); printf(" get <devpath> <in|out|feature> <id>\n"); printf(" set <devpath> <in|out|feature> <id> [0xXX *]\n"); printf(" parse <devpath>\n"); } typedef struct input_args { fbl::unique_fd fd; char name[128]; unsigned long int num_reads; } input_args_t; static thrd_t input_poll_thread; static mtx_t print_lock = MTX_INIT; #define lprintf(fmt...) \ do { \ mtx_lock(&print_lock); \ printf(fmt); \ mtx_unlock(&print_lock); \ } while (0) static void print_hex(uint8_t* buf, size_t len) { for (size_t i = 0; i < len; i++) { printf("%02x ", buf[i]); if (i % 16 == 15) printf("\n"); } printf("\n"); } static zx_status_t parse_uint_arg(const char* arg, uint32_t min, uint32_t max, uint32_t* out_val) { if ((arg == NULL) || (out_val == NULL)) { return ZX_ERR_INVALID_ARGS; } bool is_hex = (arg[0] == '0') && (arg[1] == 'x'); if (sscanf(arg, is_hex ? "%x" : "%u", out_val) != 1) { return ZX_ERR_INVALID_ARGS; } if ((*out_val < min) || (*out_val > max)) { return ZX_ERR_OUT_OF_RANGE; } return ZX_OK; } static zx_status_t parse_input_report_type(const char* arg, fuchsia_hardware_input_ReportType* out_type) { if ((arg == NULL) || (out_type == NULL)) { return ZX_ERR_INVALID_ARGS; } static const struct { const char* name; fuchsia_hardware_input_ReportType type; } LUT[] = { {.name = "in", .type = fuchsia_hardware_input_ReportType_INPUT}, {.name = "out", .type = fuchsia_hardware_input_ReportType_OUTPUT}, {.name = "feature", .type = fuchsia_hardware_input_ReportType_FEATURE}, }; for (size_t i = 0; i < fbl::count_of(LUT); ++i) { if (!strcasecmp(arg, LUT[i].name)) { *out_type = LUT[i].type; return ZX_OK; } } return ZX_ERR_INVALID_ARGS; } static zx_status_t parse_set_get_report_args(int argc, const char** argv, uint8_t* out_id, fuchsia_hardware_input_ReportType* out_type) { if ((argc < 3) || (argv == NULL) || (out_id == NULL) || (out_type == NULL)) { return ZX_ERR_INVALID_ARGS; } zx_status_t res; uint32_t tmp; res = parse_uint_arg(argv[2], 0, 255, &tmp); if (res != ZX_OK) { return res; } *out_id = static_cast<uint8_t>(tmp); return parse_input_report_type(argv[1], out_type); } static zx_status_t get_hid_protocol(const fzl::FdioCaller& caller, const char* name) { uint32_t proto; zx_status_t status = fuchsia_hardware_input_DeviceGetBootProtocol(caller.borrow_channel(), &proto); if (status != ZX_OK) { lprintf("hid: could not get protocol from %s (status=%d)\n", name, status); } else { lprintf("hid: %s proto=%d\n", name, proto); } return status; } static zx_status_t get_report_desc_len(const fzl::FdioCaller& caller, const char* name, size_t* report_desc_len) { uint16_t len; zx_status_t status = fuchsia_hardware_input_DeviceGetReportDescSize(caller.borrow_channel(), &len); if (status != ZX_OK) { lprintf("hid: could not get report descriptor length from %s (status=%d)\n", name, status); } else { *report_desc_len = len; lprintf("hid: %s report descriptor len=%zu\n", name, *report_desc_len); } return status; } static zx_status_t get_report_desc(const fzl::FdioCaller& caller, const char* name, size_t report_desc_len) { fbl::unique_ptr<uint8_t[]> buf(new uint8_t[report_desc_len]); size_t actual; zx_status_t status = fuchsia_hardware_input_DeviceGetReportDesc( caller.borrow_channel(), buf.get(), report_desc_len, &actual); if (status != ZX_OK) { lprintf("hid: could not get report descriptor from %s (status=%d)\n", name, status); return status; } if (actual != report_desc_len) { lprintf("hid: got unexpected length on report descriptor: %zu versus %zu\n", actual, report_desc_len); return ZX_ERR_BAD_STATE; } mtx_lock(&print_lock); printf("hid: %s report descriptor:\n", name); if (verbose) { print_hex(buf.get(), report_desc_len); } print_report_descriptor(buf.get(), report_desc_len); mtx_unlock(&print_lock); return status; } static zx_status_t get_num_reports(const fzl::FdioCaller& caller, const char* name, size_t* num_reports) { uint16_t count; zx_status_t status = fuchsia_hardware_input_DeviceGetNumReports(caller.borrow_channel(), &count); if (status != ZX_OK) { lprintf("hid: could not get number of reports from %s (status=%d)\n", name, status); } else { *num_reports = count; lprintf("hid: %s num reports: %zu\n", name, *num_reports); } return status; } static zx_status_t get_report_ids(const fzl::FdioCaller& caller, const char* name, size_t num_reports) { fbl::unique_ptr<uint8_t[]> ids(new uint8_t[num_reports]); size_t actual; zx_status_t status = fuchsia_hardware_input_DeviceGetReportIds(caller.borrow_channel(), ids.get(), num_reports, &actual); if (status != ZX_OK) { lprintf("hid: could not get report ids from %s (status=%d)\n", name, status); return status; } if (actual != num_reports) { lprintf("hid: got unexpected number of reports: %zu versus %zu\n", actual, num_reports); return ZX_ERR_BAD_STATE; } mtx_lock(&print_lock); printf("hid: %s report ids...\n", name); for (size_t i = 0; i < num_reports; i++) { static const struct { fuchsia_hardware_input_ReportType type; const char* tag; } TYPES[] = { {.type = fuchsia_hardware_input_ReportType_INPUT, .tag = "Input"}, {.type = fuchsia_hardware_input_ReportType_OUTPUT, .tag = "Output"}, {.type = fuchsia_hardware_input_ReportType_FEATURE, .tag = "Feature"}, }; bool found = false; for (size_t j = 0; j < fbl::count_of(TYPES); ++j) { uint16_t size; zx_status_t call_status; status = fuchsia_hardware_input_DeviceGetReportSize( caller.borrow_channel(), TYPES[j].type, ids[i], &call_status, &size); if (status == ZX_OK && call_status == ZX_OK) { printf(" ID 0x%02x : TYPE %7s : SIZE %u bytes\n", ids[i], TYPES[j].tag, size); found = true; } } if (!found) { printf(" hid: failed to find any report sizes for report id 0x%02x's (dev %s)\n", ids[i], name); } } mtx_unlock(&print_lock); return status; } static zx_status_t get_max_report_len(const fzl::FdioCaller& caller, const char* name, uint16_t* max_report_len) { uint16_t tmp; if (max_report_len == NULL) { max_report_len = &tmp; } zx_status_t status = fuchsia_hardware_input_DeviceGetMaxInputReportSize(caller.borrow_channel(), max_report_len); if (status != ZX_OK) { lprintf("hid: could not get max report size from %s (status=%d)\n", name, status); } else { lprintf("hid: %s maxreport=%u\n", name, *max_report_len); } return status; } #define TRY(fn) \ do { \ zx_status_t status = fn; \ if (status != ZX_OK) \ return status; \ } while (0) static zx_status_t hid_status(const fzl::FdioCaller& caller, const char* name, uint16_t* max_report_len) { size_t num_reports; TRY(get_hid_protocol(caller, name)); TRY(get_num_reports(caller, name, &num_reports)); TRY(get_report_ids(caller, name, num_reports)); TRY(get_max_report_len(caller, name, max_report_len)); return ZX_OK; } static zx_status_t parse_rpt_descriptor(const fzl::FdioCaller& caller, const char* name) { size_t report_desc_len; TRY(get_report_desc_len(caller, "", &report_desc_len)); TRY(get_report_desc(caller, "", report_desc_len)); return ZX_OK; } #undef TRY static int hid_input_thread(void* arg) { input_args_t* args = (input_args_t*)arg; lprintf("hid: input thread started for %s\n", args->name); fzl::FdioCaller caller(std::move(args->fd)); uint16_t max_report_len = 0; ssize_t rc = hid_status(caller, args->name, &max_report_len); if (rc < 0) { return static_cast<int>(rc); } // Add 1 to the max report length to make room for a Report ID. max_report_len++; fbl::unique_ptr<uint8_t[]> report(new uint8_t[max_report_len]); args->fd = caller.release(); for (uint32_t i = 0; i < args->num_reads; i++) { ssize_t r = read(args->fd.get(), report.get(), max_report_len); mtx_lock(&print_lock); printf("read returned %ld\n", r); if (r < 0) { printf("read errno=%d (%s)\n", errno, strerror(errno)); mtx_unlock(&print_lock); break; } printf("hid: input from %s\n", args->name); print_hex(report.get(), r); mtx_unlock(&print_lock); } lprintf("hid: closing %s\n", args->name); delete args; return ZX_OK; } static zx_status_t hid_input_device_added(int dirfd, int event, const char* fn, void* cookie) { if (event != WATCH_EVENT_ADD_FILE) { return ZX_OK; } int fd = openat(dirfd, fn, O_RDONLY); if (fd < 0) { return ZX_OK; } input_args_t* args = new input_args {}; args->fd = fbl::unique_fd(fd); // TODO: support setting num_reads across all devices. requires a way to // signal shutdown to all input threads. args->num_reads = ULONG_MAX; thrd_t t; snprintf(args->name, sizeof(args->name), "hid-input-%s", fn); int ret = thrd_create_with_name(&t, hid_input_thread, (void*)args, args->name); if (ret != thrd_success) { printf("hid: input thread %s did not start (error=%d)\n", args->name, ret); close(fd); return thrd_status_to_zx_status(ret); } thrd_detach(t); return ZX_OK; } static int hid_input_devices_poll_thread(void* arg) { int dirfd = open(DEV_INPUT, O_DIRECTORY|O_RDONLY); if (dirfd < 0) { printf("hid: error opening %s\n", DEV_INPUT); return ZX_ERR_INTERNAL; } fdio_watch_directory(dirfd, hid_input_device_added, ZX_TIME_INFINITE, NULL); close(dirfd); return -1; } int read_reports(int argc, const char** argv) { argc--; argv++; if (argc < 1) { usage(); return 0; } uint32_t tmp = 0xffffffff; if (argc > 1) { zx_status_t res = parse_uint_arg(argv[1], 0, 0xffffffff, &tmp); if (res != ZX_OK) { printf("Failed to parse <num reads> (res %d)\n", res); usage(); return 0; } } int fd = open(argv[0], O_RDWR); if (fd < 0) { printf("could not open %s: %d\n", argv[0], errno); return -1; } input_args_t* args = new input_args_t {}; args->fd = fbl::unique_fd(fd); args->num_reads = tmp; strlcpy(args->name, argv[0], sizeof(args->name)); thrd_t t; int ret = thrd_create_with_name(&t, hid_input_thread, (void*)args, args->name); if (ret != thrd_success) { printf("hid: input thread %s did not start (error=%d)\n", args->name, ret); delete args; return -1; } thrd_join(t, NULL); return 0; } int readall_reports(int argc, const char** argv) { int ret = thrd_create_with_name(&input_poll_thread, hid_input_devices_poll_thread, NULL, "hid-inputdev-poll"); if (ret != thrd_success) { return -1; } thrd_join(input_poll_thread, NULL); return 0; } int get_report(int argc, const char** argv) { argc--; argv++; if (argc < 3) { usage(); return 0; } uint8_t id; fuchsia_hardware_input_ReportType type; zx_status_t res = parse_set_get_report_args(argc, argv, &id, &type); if (res != ZX_OK) { printf("Failed to parse type/id for get report operation (res %d)\n", res); usage(); return 0; } int fd = open(argv[0], O_RDWR); if (fd < 0) { printf("could not open %s: %d\n", argv[0], errno); return -1; } fzl::FdioCaller caller{fbl::unique_fd(fd)}; xprintf("hid: getting report size for id=0x%02x type=%u\n", id, type); uint16_t size; zx_status_t call_status; res = fuchsia_hardware_input_DeviceGetReportSize(caller.borrow_channel(), type, id, &call_status, &size); if (res != ZX_OK || call_status != ZX_OK) { printf("hid: could not get report (id 0x%02x type %u) size from %s (status=%d, %d)\n", id, type, argv[0], res, call_status); return static_cast<int>(-1); } xprintf("hid: report size=%u\n", size); // TODO(johngro) : Come up with a better policy than this... While devices // are *supposed* to only deliver a report descriptor's computed size, in // practice they frequently seem to deliver number of bytes either greater // or fewer than the number of bytes originally requested. For example... // // ++ Sometimes a device is expected to deliver a Report ID byte along with // the payload contents, but does not do so. // ++ Sometimes it is unclear whether or not a device needs to deliver a // Report ID byte at all since there is only one report listed (and, // sometimes the device delivers that ID, and sometimes it chooses not // to). // ++ Sometimes no bytes at all are returned for a report (this seems to // be relatively common for input reports) // ++ Sometimes the number of bytes returned has basically nothing to do // with the expected size of the report (this seems to be relatively // common for vendor feature reports). // // Because of this uncertainty, we currently just provide a worst-case 4KB // buffer to read into, and report the number of bytes which came back along // with the expected size of the raw report. size_t bufsz = 4u << 10; size_t actual; fbl::unique_ptr<uint8_t[]> buf(new uint8_t[bufsz]); res = fuchsia_hardware_input_DeviceGetReport(caller.borrow_channel(), type, id, &call_status, buf.get(), bufsz, &actual); if (res != ZX_OK || call_status != ZX_OK) { printf("hid: could not get report: %d, %d\n", res, call_status); return -1; } printf("hid: got %zu bytes (raw report size %u)\n", actual, size); print_hex(buf.get(), actual); return 0; } int set_report(int argc, const char** argv) { argc--; argv++; if (argc < 4) { usage(); return 0; } uint8_t id; fuchsia_hardware_input_ReportType type; zx_status_t res = parse_set_get_report_args(argc, argv, &id, &type); if (res != ZX_OK) { printf("Failed to parse type/id for get report operation (res %d)\n", res); usage(); return 0; } xprintf("hid: setting report size for id=0x%02x type=%u\n", id, type); int fd = open(argv[0], O_RDWR); if (fd < 0) { printf("could not open %s: %d\n", argv[0], errno); return -1; } fzl::FdioCaller caller{fbl::unique_fd(fd)}; // If the set/get report args parsed, then we must have at least 3 arguments. ZX_DEBUG_ASSERT(argc >= 3); uint16_t payload_size = static_cast<uint16_t>(argc - 3); uint16_t size; zx_status_t call_status; res = fuchsia_hardware_input_DeviceGetReportSize(caller.borrow_channel(), type, id, &call_status, &size); if (res != ZX_OK || call_status != ZX_OK) { printf("hid: could not get report (id 0x%02x type %u) size from %s (status=%d, %d)\n", id, type, argv[0], res, call_status); return -1; } xprintf("hid: report size=%u, tx payload size=%u\n", size, payload_size); fbl::unique_ptr<uint8_t[]> report(new uint8_t[payload_size]); for (int i = 0; i < payload_size; i++) { uint32_t tmp; zx_status_t res = parse_uint_arg(argv[i+3], 0, 255, &tmp); if (res != ZX_OK) { printf("Failed to parse payload byte \"%s\" (res = %d)\n", argv[i+3], res); return res; } report[i] = static_cast<uint8_t>(tmp); } res = fuchsia_hardware_input_DeviceSetReport(caller.borrow_channel(), type, id, report.get(), payload_size, &call_status); if (res != ZX_OK || call_status != ZX_OK) { printf("hid: could not set report: %d, %d\n", res, call_status); return -1; } printf("hid: success\n"); return 0; } int parse(int argc, const char** argv) { argc--; argv++; if (argc < 1) { usage(); return 0; } int fd = open(argv[0], O_RDWR); if (fd < 0) { printf("could not open %s: %d\n", argv[0], errno); return -1; } fzl::FdioCaller caller{fbl::unique_fd(fd)}; zx_status_t status = parse_rpt_descriptor(caller, argv[0]); return static_cast<int>(status); } int main(int argc, const char** argv) { if (argc < 2) { usage(); return 0; } argc--; argv++; if (!strcmp("-v", argv[0])) { verbose = true; argc--; argv++; } if (!strcmp("read", argv[0])) { if (argc > 1) { return read_reports(argc, argv); } else { return readall_reports(argc, argv); } } if (!strcmp("get", argv[0])) { return get_report(argc, argv); } if (!strcmp("set", argv[0])) { return set_report(argc, argv); } if (!strcmp("parse", argv[0])) { return parse(argc, argv); } usage(); return 0; }
cpp
MS Dhoni is undoubtedly known as a limited-overs legend. While he led the side with distinction in white-ball format and scored heavily, Dhoni also did considerably well in the purest format, which many deemed would not suit him during his early days. The former Indian captain retired from Tests in late 2014, with 4,876 runs -- most by an Indian keeper (third-most overall) and led the side to the No. 1 ranking for the first-time ever in 2009. While Dhoni's numbers as a captain overseas aren't good by any means, he did have a very young and unsettled team; being caught in the transition period. As a result, Dhoni did well to guide them and give a more balanced unit to his successor Virat Kohli by the time he stepped aside. Since then, Kohli has instilled ruthless aggression into the side, transforming them totally and leading them to the No. 1 ranking once again, with a memorable series win in Australia (2018-19), Sri Lanka, West Indies and competing well in South Africa along with their dominance at home. Speaking to journalist Indranil Basu on SK Live, former India cricketer and noted commentator Vivek Razdan lauded the roles of Dhoni and Kohli and told, “We always think about the destination and get happy with it. What we saw in Brisbane (versus Australia) wasn’t an overnight success. It’s a process in place for the past few years. It started under MS Dhoni, then Virat Kohli continued. Ajinkya Rahane may have led India to the win, but Kohli’s contribution was equal. Ever since Virat Kohli took charge, we saw a different Indian team. A side that’s fearless. We tend to overanalyze Kohli and knit pick aspects of his personality that we don’t like, but here is Kohli, the complete package. He is what he is, and ever since he took charge, the team has transformed. " He further opined on batting coach Vikram Rathour's role, who prompted the tail-enders to bat for longer periods at the nets in Australia, which paved the way for their historic series win in the Brisbane Test. “In our times, the bowlers didn’t get batting practice. During India’s tour of Pakistan in 1989, Our first Test was in Karachi. Before a practice session, I carried my entire kitbag. A senior asked me why I was carrying such a big kitbag. I replied that it has my bat, pad, guards and helmet. He told me that as a bowler, all I need are my spikes. There would be so many days that we wouldn’t practice any batting at all and still managed to get some runs in the big games. Coaches from that era were like – batsmen to bat and bowlers to bowl. " Currently, the Kohli-led side is involved in the series opener of the four-match Test series versus England at home, their first-ever home series ever since the advent of the novel coronavirus. Kohli & Co. need to win the series by a handsome margin to cement their spot in the final of the inaugural ICC World Test Championship, with Kane Williamson-led New Zealand already qualified.
english
{ "ID": "3559" ,"post_name": "efficient-json-table-data-representation" ,"post_title": "Efficient JSON-Table Data Representation" ,"post_date_gmt": "2015-10-21 11:01:54" ,"post_modified_gmt": "2016-02-29 12:00:49" ,"post_status": "publish" ,"comment_status": "closed" ,"post_type": "post" }
json
Summers last hurrah………….. When Church was finished today, I noticed a motorcycle club was “refueling” at the local coffee shop! This is Silvertop’s favorite time of year, and also a favorite for bike clubs, both gasoline powered, and human powered Lol! I had several chores to complete before today’s hike………….. Split and stack one wheelbarrow load of firewood…….. Check! Thin a half gallon of paint for tomorrows spray painting, it never ends Lol🤣…… Check! When I was flying, we would call this type of Flight Plan a “Round Robin”! Fall is coming!!
english
#include "script_component.hpp" class CfgPatches { class ADDON { name = COMPONENT_NAME; units[] = {}; weapons[] = {}; requiredVersion = REQUIRED_VERSION; requiredAddons[] = {"a3cs_common", "A3_Ui_F"}; author = ECSTRING(main,Author); authors[] = {"SzwedzikPL"}; url = ECSTRING(main,URL); VERSION_CONFIG; }; }; /* class RscText; class RscTitle; class RscListBox; class RscControlsGroup; class RscMapControl; class RscButtonMenu; class RscButtonMenuCancel; class GVAR(RscSupportPanel) { onLoad = QUOTE(uiNamespace setVariable [ARR_2(QQGVAR(RscSupportPanel), _this select 0)];); onUnload = QUOTE(uiNamespace setVariable [ARR_2(QQGVAR(RscSupportPanel), displayNull)];); idd = -1; movingEnable = 1; enableSimulation = 1; enableDisplay = 1; class controlsBackground { class titleBackground: RscText { idc = IDC_RSCSUPPORTPANEL_TITLEBG; x = "-6.5 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)"; y = "1 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)"; w = "53 * (((safezoneW / safezoneH) min 1.2) / 40)"; h = "1 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)"; colorBackground[] = { "(profilenamespace getvariable ['GUI_BCG_RGB_R', 0.13])", "(profilenamespace getvariable ['GUI_BCG_RGB_G', 0.54])", "(profilenamespace getvariable ['GUI_BCG_RGB_B', 0.21])", "(profilenamespace getvariable ['GUI_BCG_RGB_A', 0.8])" }; }; class mainBackground: RscText { idc = IDC_RSCSUPPORTPANEL_MAINBG; x = "-6.5 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)"; y = "2.1 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)"; w = "53 * (((safezoneW / safezoneH) min 1.2) / 40)"; h = "20.8 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)"; colorBackground[] = {0, 0, 0, 0.69999999}; }; }; class Controls { class title: RscTitle { idc = IDC_RSCSUPPORTPANEL_TITLE; text = CSTRING(Title); x = "-6.5 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)"; y = "1 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)"; w = "15 * (((safezoneW / safezoneH) min 1.2) / 40)"; h = "1 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)"; }; class assetTitle: RscTitle { idc = IDC_RSCSUPPORTPANEL_ASSETTITLE; text = ""; x = "8.5 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)"; y = "1 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)"; w = "24 * (((safezoneW / safezoneH) min 1.2) / 40)"; h = "1 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)"; }; class assetsList: RscListBox { IDC = IDC_RSCSUPPORTPANEL_ASSETS; x = "-6.3 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)"; y = "2.3 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)"; w = "15 * (((safezoneW / safezoneH) min 1.2) / 40)"; h = "20.4 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)"; }; class propertiesGroup: RscControlsGroup { IDC = IDC_RSCSUPPORTPANEL_PROPERTIES; x = "8.5 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)"; y = "2.3 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)"; w = "15 * (((safezoneW / safezoneH) min 1.2) / 40)"; h = "20.4 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)"; }; class positionMap: RscMapControl { idc = IDC_RSCSUPPORTPANEL_MAP; x = "23.7 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)"; y = "2.3 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)"; w = "22.5 * (((safezoneW / safezoneH) min 1.2) / 40)"; h = "20.4 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)"; colorBackground[] = {1, 1, 1, 1}; showCountourInterval = 0; scaleDefault = 0.1; drawObjects = 0; showMarkers = 0; showTacticalPing = 0; }; class sendMission: RscButtonMenu { idc = IDC_RSCSUPPORTPANEL_BUTTONSEND; text = CSTRING(SendMission); x = "38.5 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)"; y = "23 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)"; w = "8 * (((safezoneW / safezoneH) min 1.2) / 40)"; h = "1 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)"; }; class cancelDialog: RscButtonMenuCancel { text = ECSTRING(Common,Close); x = "-6.5 * (((safezoneW / safezoneH) min 1.2) / 40) + (safezoneX + (safezoneW - ((safezoneW / safezoneH) min 1.2))/2)"; y = "23 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25) + (safezoneY + (safezoneH - (((safezoneW / safezoneH) min 1.2) / 1.2))/2)"; w = "6.25 * (((safezoneW / safezoneH) min 1.2) / 40)"; h = "1 * ((((safezoneW / safezoneH) min 1.2) / 1.2) / 25)"; }; }; }; */
cpp
Innovation, high quality and reliability are the core values of our corporation. These principles today extra than ever form the basis of our success as an internationally active mid-size firm for Manufacturer of Custom Powder Metallurgy Gears Powder Metal Sintered Gears, We are always looking forward to forming successful business relationships with new clients around the world. Innovation, high quality and reliability are the core values of our corporation. These principles today extra than ever form the basis of our success as an internationally active mid-size firm for Powder Metal Sintered Gears, Powder Metallurgy Gear, Sintered Gear, In order to meet more market demands and long-term development, a 150, 000-square-meter new factory is under construction, which are going to be put into use in 2014. Then, we shall own a large capacity of producing. Of course, we will continue improving the service system to meet the requirements of customers, bringing health, happiness and beauty to everyone. INM series hydraulic motor is one type of radial piston motor. It has been widely applied in various kinds of applications, including plastic injection machine, ship and deck machinery, construction equipment, hoist and transport vehicle, heavy metallurgical machinery, petroleum and mining machinery. Most of tailor-made winches, hydraulic transmission & slewing devices we design and manufacture are built by using this type motors. Mechanical Configuration: Distributor, output shaft (including involute spline shaft, fat key shaft, taper fat key shaft, internal spline shaft, involute internal spline shaft), tachometer. INM5 Series Hydraulic Motors' Technical Parameters: We have a full rage of INM Series motors for your choice, from INM05 to INM7. More information can be seen in our Pump and Motor data sheets from Download page.
english
<filename>package.json { "name": "steal-bundle-manifest", "version": "1.0.4", "description": "Bundle manifest tools for steal", "main": "index.js", "scripts": { "document": "node build-docs.js", "test": "mocha test/test.js", "release:patch": "npm version patch && npm publish", "release:minor": "npm version minor && npm publish", "release:major": "npm version major && npm publish" }, "files": [ "index.js", "docs" ], "repository": { "type": "git", "url": "git+https://github.com/matthewp/steal-bundle-manifest.git" }, "author": "", "license": "MIT", "bugs": { "url": "https://github.com/matthewp/steal-bundle-manifest/issues" }, "homepage": "https://github.com/matthewp/steal-bundle-manifest#readme", "devDependencies": { "mocha": "^3.5.0", "mock-fs": "^4.4.1" }, "dependencies": { "steal-fuzzy-normalize": "^1.0.0", "steal-push": "^1.2.0" } }
json
{ "id": 13332, "source": "wen", "verse_id": 18906, "verse_count": 1, "reference": "65:8", "title": "", "html": "Thus, &c.\u2014These word's may be conceived as a gracious answer from God to the prophet, pleading God's covenant with Abraham, Isaac, and Israel. To this God replies, that he intended no such severity. His threatening should be made good upon the generality of this people. Blessing\u2014But yet, as in a vineyard, which is generally unfruitful, there may be some vine that brings forth fruit, and has the hopes of new wine in the cluster, and as to such, the gardener bids his servant destroy it not, for there is in them what speaks God's blessing. So\u2014So (saith God) will I do for my servants sake, that I may not destroy them all, for the sake of my servants, Abraham, Isaac, and Jacob.", "audit": null }
json
Addressing the 71st session of the United Nations General Assembly in New York on Monday, Union external affairs minister Sushma Swaraj said recent terror attacks and the ongoing conflicts in Syria and Iraq were an indication that the world was failing in the fight against terrorism. India on Monday asked Pakistan to give up the dream of snatching Jammu and Kashmir, saying all it had received in response to unprecedented peace overtures were a string of terror strikes and the export of cross-border terrorism. External affairs minister Sushma Swaraj delivered a stinging riposte to Prime Minister Nawaz Sharif’s speech at the UN General Assembly, saying Pakistan should look within at “egregious abuses” in Balochistan instead of leveling baseless allegations against India. Swaraj’s address marked the latest exchange in a war of words between the two sides, which has heated up since the terror attack on an Indian Army camp in Uri more than a week ago that killed 18 soldiers. Sharif devoted most of his speech to the Kashmir issue and demanded a UN fact-finding mission into alleged rights violations. India, Swaraj said, had attempted a “paradigm of friendship…without precedent” to resolve outstanding issues but all it got in return was “Pathankot, Uri and Bahadur Ali, a terrorist in our custody whose confession is living proof of Pakistan’s complicity in cross-border terror”. She added Pakistan remains in denial when confronted with such evidence. “It persists in the belief that such attacks and provocative remarks will enable it to snatch the territory it covets. My firm advice to Pakistan is: Abandon this dream. Let me state unequivocally that Jammu and Kashmir is an integral part of India and will always remain so,” she said. In a tacit reference to Pakistan’s policy of acting against “bad” terrorists while turning a blind eye to “good” terrorists, Swaraj said there should be no distinction between terrorists and the world community should “join hands to script an effective strategy” against the menace. “If any nation refuses to join this global strategy we must isolate it. In our midst, there are nations that still speak the language of terrorism, that nurture it, peddle it, and export it. To shelter terrorists has become their calling card. We must identify these nations and hold them to account,” she said. She said the world community is yet to reach a conclusion on a comprehensive convention on international terrorism proposed by India in 1996. This has prevented nations from agreeing on “norms to punish and extradite terrorists” and there is need to act with “fresh urgency to adopt this convention”. Swaraj also brought up the reform of the UN Security Council so that it does not remain an outdated body that “reflects the world order of an older era” and comes to terms with present day realities. In a speech seeking to marry New Delhi’s national interest with global objectives to buttress its stature as an emerging global power, Swaraj stressed India’s commitment to climate change and announced it will submit its instrument of ratification of the Paris Agreement on October 2, the birth anniversary of Mahatma Gandhi, who, she added, “epitomised a lifestyle with the smallest carbon footprint”. She also emphasised India’s commitment to the UN’s Sustainable Development Goals (SDGs), which she said, were “matched by the development vision of my government, which is geared towards the achievement of these same objectives”. Several schemes of the Indian government dovetailed with the SDGs, such as the Swachh Bharat, Beti Bachao, Beti Padhao, Make in India and Digital India campaigns. While India will play a leading role in combating climate change through measures such an international solar alliance, it expects developed nations to hold up their end of the bargain by providing finance and technology transfers.
english
<gh_stars>0 export {ErrorBoundary, withErrorBoundary, useErrorHandler, FallbackProps} from './ErrorBoundary' export {InfiniteScroller} from './InfiniteScroller'
typescript
{ "name": "DDCameraViewController", "version": "0.1.0", "summary": "A camera view controller build on top of AVFoundation", "homepage": "http://dashdevs.com", "license": { "type": "MIT", "file": "LICENSE" }, "authors": { "dashdevs llc": "<EMAIL>" }, "source": { "git": "https://bitbucket.org/itomych/DDCameraViewController.git", "tag": "0.1.0" }, "platforms": { "ios": "9.0" }, "source_files": "DDCameraViewController/Classes/**/*", "frameworks": [ "UIKit", "AVFoundation" ], "default_subspecs": "DDCameraViewController", "subspecs": [ { "name": "DDCameraView", "source_files": "DDCameraViewController/Classes/DDCameraView.{h,m}", "public_header_files": "DDCameraViewController/Classes/DDCameraView.h", "platforms": { "ios": "9.0" } }, { "name": "DDCameraViewController", "source_files": [ "DDCameraViewController/Classes/DDCameraViewController.{h,m}", "DDCameraViewController/Classes/DDCameraViewController_Private.h" ], "public_header_files": "DDCameraViewController/Classes/DDCameraViewController.h", "platforms": { "ios": "9.0" }, "dependencies": { "DDCameraViewController/DDCameraView": [ ] } }, { "name": "DDCaptureStillImageOutput", "source_files": "DDCameraViewController/Classes/DDCameraViewController+DDCaptureStillImageOutput.{h,m}", "public_header_files": "DDCameraViewController/Classes/DDCameraViewController+DDCaptureStillImageOutput.h", "platforms": { "ios": "9.0" }, "dependencies": { "DDCameraViewController/DDCameraViewController": [ ] } }, { "name": "DDStillImageViewController", "source_files": "DDCameraViewController/Classes/DDStillImageViewController.{h,m}", "public_header_files": "DDCameraViewController/Classes/DDStillImageViewController.h", "platforms": { "ios": "9.0" }, "dependencies": { "DDCameraViewController/DDCaptureStillImageOutput": [ ] } }, { "name": "DDCaptureDeviceInputSwitch", "source_files": [ "DDCameraViewController/Classes/AVCaptureDevice+DDCaptureDevicePosition.{h,m}", "DDCameraViewController/Classes/DDCameraViewController+DDCaptureDeviceInputSwitch.{h,m}" ], "public_header_files": "DDCameraViewController/Classes/DDCameraViewController+DDCaptureDeviceInputSwitch.h", "platforms": { "ios": "9.0" }, "dependencies": { "DDCameraViewController/DDCameraViewController": [ ] } }, { "name": "DDCaptureDeviceModesSwitch", "source_files": "DDCameraViewController/Classes/AVCaptureDevice+DDCaptureDeviceModesSwitch.{h,m}", "public_header_files": "DDCameraViewController/Classes/AVCaptureDevice+DDCaptureDeviceModesSwitch.h", "platforms": { "ios": "9.0" } } ] }
json
For those who don’t know, a solar eclipse transpires when a part of the Earth is covered in a shadow cast by the Moon, which partially or fully blocks sunlight. This occurs when the Moon, Sun, and Earth are aligned. Such arrangement concurs with a new moon indicating the Moon is nearest to the ecliptic plane. In a typical total eclipse, the Sun’s disk is entirely covered by the Moon. In annular and partial eclipses, only part of the Sun is covered. What does Solar Eclipse do to our eyes? Scientists have proven that staring at our Sun with our naked eyes during a Solar Eclipse can burn our retina, damaging the images our brain can observe. This phenomenon, known to the modern world as ‘eclipse blindness,’ can cause permanent or temporary vision impairment. It can also lead to legal blindness, which means a significant vision loss in the individual staring at the Sun during Solar Eclipse without protection. There are no quick pain or symptoms associated with the eye damage — the retina doesn’t have pain receptors — so it is difficult to know at the time if you’ve really been afflicted with total eclipse blindness. If you stare at the Sun unfiltered, you may instantly notice a dazzling effect or a stare the way you would from any sharp object, but that doesn’t fundamentally mean your retina is broken. According to doctors and researchers, symptoms usually begin occurring around 12 hours after staring at the eclipse, when affected individuals wake up in the morning and notice their vision has been completely altered. Why does this happen? During the actual eclipse, nothing happens when the overlapping is ideally perfect. The problem begins when the Moon moves out of the way, and the Sun gradually comes back. When you are staring at the Sun during the eclipse immediately before and or shortly after Totality, even when just 4% of the Sun’s disk is noticeable, it is still too bright to stare at without danger of damaging a crescent shaped spot on your retinas, creating permanent blind spots in your eyes. In other words, when the Moon moves away from the Sun after the total eclipse, the rays coming from the Sun are so extreme and bright that it penetrates our retina and irreversibly burns/damages it. Ordinary dark sunglasses are Not dark enough to protect your eyes in this case because the sunglasses fail to stop this bright light from penetrating our eyes and destroying them. Use Welders Glass or special Mylar glasses specially made for eclipse-watching.
english
import { oneOf } from "../prims/one-of"; import { xfInt } from "../xform/number"; import { repeat } from "../combinators/repeat"; import { xform } from "../combinators/xform"; export const BIT = oneOf("01"); export const BINARY_UINT = xform(repeat(BIT, 1, 32, "uint"), xfInt(2));
typescript
package configdir_test import ( "encoding/json" "fmt" "os" "path/filepath" "github.com/hugefiver/qush/configdir" ) // Quick start example for a common use case of this module. func Example() { // A common use case is to get a private config folder for your app to // place its settings files into, that are specific to the local user. configPath := configdir.LocalConfig("my-app") err := configdir.MakePath(configPath) // Ensure it exists. if err != nil { panic(err) } // Deal with a JSON configuration file in that folder. configFile := filepath.Join(configPath, "settings.json") type AppSettings struct { Username string `json:"username"` Password string `json:"password"` } var settings AppSettings // Does the file not exist? if _, err = os.Stat(configFile); os.IsNotExist(err) { // Create the new config file. settings = AppSettings{"MyUser", "MyPassword"} fh, err := os.Create(configFile) if err != nil { panic(err) } defer fh.Close() encoder := json.NewEncoder(fh) encoder.Encode(&settings) } else { // Load the existing file. fh, err := os.Open(configFile) if err != nil { panic(err) } defer fh.Close() decoder := json.NewDecoder(fh) decoder.Decode(&settings) } } // Example for getting a global system configuration path. func ExampleSystemConfig() { // Get all of the global system configuration paths. // // On Linux or BSD this might be []string{"/etc/xdg"} or the split // version of $XDG_CONFIG_DIRS. // // On macOS or Windows this will likely return a slice with only one entry // that points to the global config path; see the README.md for details. paths := configdir.SystemConfig() fmt.Printf("Global system config paths: %v\n", paths) // Or you can get a version of the path suffixed with a vendor folder. vendor := configdir.SystemConfig("acme") fmt.Printf("Vendor-specific config paths: %v\n", vendor) // Or you can use multiple path suffixes to group configs in a // `vendor/application` namespace. You can use as many path // components as you like. app := configdir.SystemConfig("acme", "sprockets") fmt.Printf("Vendor/app specific config paths: %v\n", app) } // Example for getting a user-specific configuration path. func ExampleLocalConfig() { // Get the default root of the local configuration path. // // On Linux or BSD this might be "$HOME/.config", or on Windows this might // be "C:\\Users\\$USER\\AppData\\Roaming" path := configdir.LocalConfig() fmt.Printf("Local user config path: %s\n", path) // Or you can get a local config path with a vendor suffix, like // "$HOME/.config/acme" on Linux. vendor := configdir.LocalConfig("acme") fmt.Printf("Vendor-specific local config path: %s\n", vendor) // Or you can use multiple path suffixes to group configs in a // `vendor/application` namespace. You can use as many path // components as you like. app := configdir.LocalConfig("acme", "sprockets") fmt.Printf("Vendor/app specific local config path: %s\n", app) } // Example for getting a user-specific cache folder. func ExampleLocalCache() { // Get the default root of the local cache folder. // // On Linux or BSD this might be "$HOME/.cache", or on Windows this might // be "C:\\Users\\$USER\\AppData\\Local" path := configdir.LocalCache() fmt.Printf("Local user cache path: %s\n", path) // Or you can get a local cache path with a vendor suffix, like // "$HOME/.cache/acme" on Linux. vendor := configdir.LocalCache("acme") fmt.Printf("Vendor-specific local cache path: %s\n", vendor) // Or you can use multiple path suffixes to group caches in a // `vendor/application` namespace. You can use as many path // components as you like. app := configdir.LocalCache("acme", "sprockets") fmt.Printf("Vendor/app specific local cache path: %s\n", app) } // Example for automatically creating config directories. func ExampleMakePath() { // The MakePath() function can accept the output of any of the folder // getting functions and ensure that their path exists. // Create a local user configuration folder under an app prefix. // On Linux this may result in `$HOME/.config/my-cool-app` existing as // a directory, depending on the value of `$XDG_CONFIG_HOME`. err := configdir.MakePath(configdir.LocalConfig("my-cool-app")) if err != nil { panic(err) } // Create a cache folder under a namespace. err = configdir.MakePath(configdir.LocalCache("acme", "sprockets", "client")) if err != nil { panic(err) } // In the case of global system configuration, which may return more than // one path (especially on Linux/BSD that uses the XDG Base Directory Spec), // it will attempt to create the directories only under the *first* path. // // For example, if $XDG_CONFIG_DIRS="/etc/xdg:/opt/config" this will try // to create the config dir only in "/etc/xdg/acme/sprockets" and not try // to create any folders under "/opt/config". err = configdir.MakePath(configdir.SystemConfig("acme", "sprockets")...) if err != nil { panic(err) } } // Example for recalculating what the directories should be. func ExampleRefresh() { // On your program's initialization, this module decides which paths to // use for global, local and cache folders, based on environment variables // and falling back on defaults. // // In case the environment variables change throughout the life of your // program, for example if you re-assigned $XDG_CONFIG_HOME, you can call // the Refresh() function to re-calculate the paths to reflect the new // environment. configdir.Refresh() }
go
<gh_stars>0 { "platforms": ["ios", "android"], "ios": { "modulesClassNames": ["EASClientModule"] }, "android": { "modulesClassNames": ["expo.modules.easclient.EASClientModule"] } }
json
Bollywood actor Anushka Sharma, who has been shooting in Kolkata for her upcoming film Chakda Xpress, took to her social media to share a series of photos from her time in the city. Anushka also shared a photo where she held her daughter Vamika close in her arms. Vamika’s face was away from the camera. Chakda Xpress is an upcoming Netflix film which traces the journey of Indian cricketer Jhulan Goswami. Before filming in Kolkata, Anushka was in the UK to train for the film. Click for more updates and latest Bollywood news along with Entertainment updates. Also get latest news and top headlines from India and around the world at The Indian Express.
english
<reponame>justinkx/kia-handbook<gh_stars>0 import React, { memo, useMemo } from "react"; import { StyleSheet, Dimensions, View, TouchableOpacity, Text, } from "react-native"; import _size from "lodash/size"; import { Entypo } from "@expo/vector-icons"; import GlobalStyle from "../Styles/GlobalStyle"; const { width } = Dimensions.get("window"); const PICKER_SIZE = width - 30; const MARGIN_RIGHT = 8; const ColorPicker = ({ colors, selectedColor, onSelectColor }) => { return ( <View style={[GlobalStyle.center]}> <Text style={styles.paint}>{selectedColor.paint}</Text> <View style={styles.wrapper}> {colors.map((color, index) => ( <ColorPellette onSelectColor={onSelectColor} pallette={color} key={index} size={_size(colors)} selectedColor={selectedColor} /> ))} </View> </View> ); }; export default memo(ColorPicker); const ColorPellette = memo( ({ pallette, onSelectColor, size, selectedColor }) => { const PALLETTE_SIZE = useMemo( () => Math.min((PICKER_SIZE - MARGIN_RIGHT * size) / size, 20), [size] ); return ( <TouchableOpacity onPress={() => onSelectColor(pallette)}> <View style={[ styles.pallette, { backgroundColor: pallette.dualTone ? pallette.colors[0] : pallette.color, width: PALLETTE_SIZE, height: PALLETTE_SIZE, borderRadius: PALLETTE_SIZE / 2, }, ]} > {pallette.dualTone && ( <View style={{ backgroundColor: pallette.colors[1], width: PALLETTE_SIZE / 2, height: PALLETTE_SIZE, position: "absolute", }} /> )} {selectedColor.paint === pallette.paint && ( <View style={styles.check}> <Entypo name="check" size={15} color="#80ff80" /> </View> )} </View> </TouchableOpacity> ); } ); const styles = StyleSheet.create({ paint: { width: "100%", fontSize: 15, fontWeight: "bold", textAlign: "left", paddingBottom: 10, }, wrapper: { flexDirection: "row", justifyContent: "flex-start", alignItems: "center", }, pallette: { marginRight: 8, borderWidth: StyleSheet.hairlineWidth, borderColor: "#00000033", position: "relative", overflow: "hidden", }, check: { position: "absolute", top: 0, left: 0, right: 0, bottom: 0, justifyContent: "center", alignItems: "center", }, });
javascript
Vagrant Manager =============== Desktop application to manage vagrant machines. [![License](http://img.shields.io/:license-mit-blue.svg)](http://doge.mit-license.org)
markdown
Amanda Beggs CAS works as a production sound mixer in Los Angeles has worked on both features and television. She's been honored with CAS Award nominations and an Emmy nomination. She is a member of IATSE Local 695, the Academy of Motion Picture Arts & Sciences, the Television Academy, and the Cinema Audio Society. Known for: How much have you seen? Keep track of how much of Amanda Beggs’s work you have seen. Go to your list.
english
<filename>protocols/cabin/index.json { "cname": "cabin", "description": "a community of cabins for web3 workers 🌐 a DAO retreat & residency program 🌆 an experiment in decentralized cities ", "path": "cabin", "isEnabled": false, "type": "snapshot" }
json
<reponame>V-Lor/codemirror-mode-makefile { "name": "codemirror-mode-makefile", "version": "1.0.0", "description": "Makefile mode for CodeMirror", "main": "makefile.js", "repository": { "type": "git", "url": "git+https://github.com/V-Lor/codemirror-mode-makefile.git" }, "keywords": [ "codemirror", "makefile" ], "author": "", "license": "MIT", "bugs": { "url": "https://github.com/V-Lor/codemirror-mode-makefile/issues" }, "homepage": "https://github.com/V-Lor/codemirror-mode-makefile#readme", "dependencies": { "codemirror": "^5.60.0" } }
json
<filename>engine/calculators/source/PoisonCalculator.cpp #include "PoisonCalculator.hpp" #include "Random.hpp" const int PoisonCalculator::BASE_POISON_DURATION_MEAN = 15; const int PoisonCalculator::BASE_POISON_PCT_CHANCE = 25; // The chance of being poisoned is reduced by 1 per every x points of // health. const int PoisonCalculator::BASE_POISON_CHANCE_HEALTH_MODIFIER = 5; // Calculated mean for the Poisson distribution is reduced by 1 per every // five points of health. const int PoisonCalculator::HEALTH_DIVISOR = 5; // The character is considered weak with a HEALTH <= 7. const int PoisonCalculator::HEALTH_THRESHOLD_EXTRA_DAMAGE = 7; // Calculate the chance that this creature gets poisoned. int PoisonCalculator::calculate_pct_chance_effect(CreaturePtr creature) const { int pct_chance = BASE_POISON_PCT_CHANCE; if (creature) { int health_modifier = creature->get_health().get_current() / BASE_POISON_CHANCE_HEALTH_MODIFIER; double poison_multiplier = std::max<double>(0, creature->get_resistances().get_resistance_value(DamageType::DAMAGE_TYPE_POISON)); pct_chance -= health_modifier; pct_chance = static_cast<int>(pct_chance * poison_multiplier); } return pct_chance; } // Calculate the duration of the successful poisoning. int PoisonCalculator::calculate_duration_in_minutes(CreaturePtr creature) const { // Poison duration is described by a Poisson distribution, with the // average poisoning lasting about half an hour. PoissonDistribution p(calculate_poison_duration_mean(creature)); int duration = p.next(); return duration; } // Calculate the mean of the Poison Poisson distribution, which is affected // by the creature's health. int PoisonCalculator::calculate_poison_duration_mean(CreaturePtr creature) const { int base_mean = BASE_POISON_DURATION_MEAN; return base_mean; } // Calculate the amount of damage that this creature takes per tick. int PoisonCalculator::calculate_damage_per_tick(CreaturePtr creature, const int danger_level) const { int base_damage = 1; if (creature) { // Poison scales with the danger level, so a level 1 baby snake does // 1 damage/min, while a level 50 great slime of doom or something // does 6 damage/min. base_damage *= std::max<int>(1, 1 + (danger_level / 10)); int cur_health = creature->get_health().get_current(); // Poison damage is doubled when the creature has low health. if (cur_health <= HEALTH_THRESHOLD_EXTRA_DAMAGE) { base_damage *= 2; } } return base_damage; } #ifdef UNIT_TESTS #include "unit_tests/PoisonCalculator_test.cpp" #endif
cpp
Former England captain Michael Vaughan has expressed his disappointment on being dropped from the BBC's Ashes coverage for allegedly making racist comments to an Asian-origin player a few years back. LONDON: Former England captain Michael Vaughan has expressed his disappointment on being dropped from the BBC's Ashes coverage for allegedly making racist comments to an Asian-origin player a few years back. While expressing his disappointment, Vaughan said he 'wants to be part of the solution' and help make cricket "a more welcoming sport for all". His comments came after BCC confirmed on Wednesday that Ashes-winning England captain Vaughan will not be part of its Test Match Special team for the upcoming series in Australia. BBC's decision came after Vaughan was named in Yorkshire's report into Azeem Rafiq's claims of racism during his time at the club. Rafiq has claimed that Vaughan had told a group of Asian-origin players that there were too many of them in the club now and they need to do something about 'you lot'. Vaughan has repeatedly denied the allegation made against him. On Wednesday evening, he reacted to BBC's decision via social a media post. "Very disappointed not to be commentating for TMS (BBC Test Match Special) on the Ashes and will miss working with great colleagues and friends, but looking forward to being behind the mic for Fox Cricket in Australia," Vaughan said on social media. "The issues facing cricket are bigger than any individual case and I want to be part of the solution, listening, educating myself, and helping to make it a more welcoming sport for all," he wrote on Twitter. England leg-spinner Adil Rashid and former Pakistan bowler Rana Naved-ul-Hasan both said they heard the comment, while the fourth player in the group - Ajmal Shahzad - said he had no recollection of the alleged event. Vaughan wrote in his Daily Telegraph column that he "completely and categorically denies" making the comment and insisted he is not racist. Also Watch:
english
{"pos":"3ms","translits":{"wə·’êḏ":{"gen.2.6|0":[null,"But a mist","went up"]}},"meanings":{"mist":1},"meaningsCount":1,"occurences":1,"translation":"greek-887"}
json
The marketing automation folks would have you believe the most important part of your program is focused on inbound marketing activities. They say this is because it proves your targeted content is resonating with potential buyers who are more likely to become marketing qualified leads because they have followed a call to action. Any potential impact from outbound marketing, they say, is at or even above the awareness level of the funnel – almost impossible to track and long before a need has even been identified. Better to spend your marketing budget only on those things that can be tracked and nurtured in order to prove the ROI of your programs. The problem is this on/off thinking isn’t reality when it comes to today’s buyer’s journey. I believe one of the biggest injustices we have done to the marketing world is to drive a clear split between the two activities. I’ve yet to speak to a customer who has thought about their engagement with or decision about a brand in terms of inbound/outbound activities. The reality is much more complex than this simple distinction. When you artificially define the buyer’s journey and the value of a lead in this way it misses the simple truth that customers don’t engage with you and your brand in this fashion. What’s far more likely to happen as buyers move through the funnel is less straightforward. Buyers do not move in a linear fashion from awareness to purchase. They may backtrack multiple times in their progress and repeatedly arrive at the different levels. The more touch points you can have with them during this journey, whether outbound or inbound, therefore the more likely you are to get them to the desired outcome. The best solution is to devise programs that offer buyers a mix of inbound/outbound touch points – or to use that dreadfully old-fashioned term an “integrated approach” to win the sale. I’ve had many conversations with customers where their journey started at a baseball game when they saw a brand that started them on the journey to explore. Or it may have been a phone conversation or a conversation with a peer or word of mouth that started a digital engagement. The problem for us as marketers is that we are focusing too much on that first engagement in the digital world and deciding that’s where the journey started. We’re missing the bigger picture of how a customer engages. In an excellent book from Forrester analysts Harley Manning and Kerry Bodine entitled, Outside In: The Power of Putting Customers at the Center of Your Business, the authors discuss the critical importance of taking an outside-in or customer first view of your brand. If we only look at track-able activities, we are taking a very inside-out approach. Much better to create a balanced program that sets the right experience and perspective for you and your brand. The reality is there are as many courses through the funnel to your brand as there are potential customers. A smart, integrated approach will cast a wide net. I challenge you to go ask your customers how they found you. Don’t blindly follow a dashboard or value the difference between outbound (where you interrupt potential customers) and inbound (when they finally engage with you). It takes a balance of the two. Your mileage will always vary depending on the market and the needs of the buyer.
english
import * as specs from './specs'; import { ADFEntity, ADFEntityMark } from '../types'; import { copy, isBoolean, isDefined, isInteger, isNumber, isPlainObject, isString, makeArray, } from './utils'; import { NodeValidationResult, ValidatorSpec, AttributesSpec, ValidationErrorMap, ValidationError, ErrorCallback, ValidationOptions, Content, ValidationErrorType, ValidatorContent, MarkValidationResult, SpecValidatorResult, Err, Validate, } from '../types/validatorTypes'; function mapMarksItems(spec: ValidatorSpec, fn = (x: any) => x) { if (spec.props && spec.props.marks) { const { items, ...rest } = spec.props!.marks!; return { ...spec, props: { ...spec.props, marks: { ...rest, /** * `Text & MarksObject<Mark-1>` produces `items: ['mark-1']` * `Text & MarksObject<Mark-1 | Mark-2>` produces `items: [['mark-1', 'mark-2']]` */ items: items.length ? Array.isArray(items[0]) ? items.map(fn) : [fn(items)] : [[]], }, }, }; } else { return spec; } } const partitionObject = <T extends { [key: string]: any }>( obj: T, predicate: <K extends keyof T>( key: K, value: Exclude<T[K], undefined>, obj: T, ) => boolean, ) => Object.keys(obj).reduce<[Array<string>, Array<string>]>( (acc, key) => { acc[predicate(key, obj[key], obj) ? 0 : 1].push(key); return acc; }, [[], []], ); /** * Normalizes the structure of files imported form './specs'. * We denormalised the spec to save bundle size. */ function createSpec(nodes?: Array<string>, marks?: Array<string>) { return Object.keys(specs).reduce<Record<string, any>>((newSpecs, k) => { const spec = { ...(specs as any)[k] }; if (spec.props) { spec.props = { ...spec.props }; if (spec.props.content) { // 'tableCell_content' => { type: 'array', items: [ ... ] } if (isString(spec.props.content)) { spec.props.content = (specs as any)[spec.props.content]; } // ['inline', 'emoji'] if (Array.isArray(spec.props.content)) { /** * Flatten * * Input: * [ { type: 'array', items: [ 'tableHeader' ] }, { type: 'array', items: [ 'tableCell' ] } ] * * Output: * { type: 'array', items: [ [ 'tableHeader' ], [ 'tableCell' ] ] } */ spec.props.content = { type: 'array', items: ((spec.props.content || []) as Array<ValidatorContent>).map( (arr) => arr.items, ), }; } else { spec.props.content = { ...spec.props.content }; } spec.props.content.items = (spec.props.content.items as Array< string | Array<string> >) // ['inline'] => [['emoji', 'hr', ...]] // ['media'] => [['media']] .map((item) => isString(item) ? Array.isArray((specs as any)[item]) ? (specs as any)[item] : [item] : item, ) // [['emoji', 'hr', 'inline_code']] => [['emoji', 'hr', ['text', { marks: {} }]]] .map((item: Array<string>) => item .map((subItem) => Array.isArray((specs as any)[subItem]) ? (specs as any)[subItem] : isString(subItem) ? subItem : // Now `NoMark` produces `items: []`, should be fixed in generator ['text', subItem], ) // Remove unsupported nodes & marks // Filter nodes .filter((subItem) => { if (nodes) { // Node with overrides // ['mediaSingle', { props: { content: { items: [ 'media', 'caption' ] } }}] if (Array.isArray(subItem)) { const isMainNodeSupported = nodes.indexOf(subItem[0]) > -1; if ( isMainNodeSupported && subItem[1]?.props?.content?.items ) { return subItem[1].props.content.items.every( (item: string) => nodes.indexOf(item) > -1, ); } return isMainNodeSupported; } return nodes.indexOf(subItem) > -1; } return true; }) // Filter marks .map((subItem) => Array.isArray(subItem) && marks ? /** * TODO: Probably try something like immer, but it's 3.3kb gzipped. * Not worth it just for this. */ [subItem[0], mapMarksItems(subItem[1])] : subItem, ), ); } } newSpecs[k] = spec; return newSpecs; }, {}); } function getOptionsForType( type: string, list?: Content, ): false | Record<string, any> { if (!list) { return {}; } for (let i = 0, len = list.length; i < len; i++) { const spec = list[i]; let name = spec; let options = {}; if (Array.isArray(spec)) { [name, options] = spec; } if (name === type) { return options; } } return false; } export function validateAttrs<T>(spec: AttributesSpec, value: T): boolean { // extension_node parameters has no type if (!isDefined(spec.type)) { return !!spec.optional; } if (!isDefined(value)) { return !!spec.optional; } switch (spec.type) { case 'boolean': return isBoolean(value); case 'number': return ( isNumber(value) && (isDefined(spec.minimum) ? spec.minimum <= value : true) && (isDefined(spec.maximum) ? spec.maximum >= value : true) ); case 'integer': return ( isInteger(value) && (isDefined(spec.minimum) ? spec.minimum <= value : true) && (isDefined(spec.maximum) ? spec.maximum >= value : true) ); case 'string': return ( isString(value) && (isDefined(spec.minLength) ? spec.minLength! <= value.length : true) && (spec.pattern ? new RegExp(spec.pattern).test(value) : true) ); case 'object': return isPlainObject(value); case 'array': const types = spec.items; const lastTypeIndex = types.length - 1; if (Array.isArray(value)) { // We are doing this to support tuple which can be defined as [number, string] // NOTE: Not validating tuples strictly return value.every((x, i) => validateAttrs(types[Math.min(i, lastTypeIndex)], x), ); } return false; case 'enum': return isString(value) && spec.values.indexOf(value) > -1; } return false; } const errorMessageFor = (type: string, message: string) => `${type}: ${message}.`; const getUnsupportedOptions = (spec?: ValidatorSpec) => { if (spec && spec.props && spec.props.content) { const { allowUnsupportedBlock, allowUnsupportedInline, } = spec.props.content; return { allowUnsupportedBlock, allowUnsupportedInline }; } return {}; }; const invalidChildContent = ( child: ADFEntity, errorCallback?: ErrorCallback, parentSpec?: ValidatorSpec, ) => { const message = errorMessageFor(child.type, 'invalid content'); if (!errorCallback) { throw new Error(message); } else { return errorCallback( { ...child }, { code: 'INVALID_CONTENT', message, }, getUnsupportedOptions(parentSpec), ); } }; const unsupportedMarkContent = ( errorCode: ValidationError['code'], mark: ADFEntityMark, errorCallback?: ErrorCallback, errorMessage?: string, ) => { const message = errorMessage || errorMessageFor(mark.type, 'unsupported mark'); if (!errorCallback) { throw new Error(message); } else { return errorCallback( { ...mark }, { code: errorCode, message, meta: mark, }, { allowUnsupportedBlock: false, allowUnsupportedInline: false, isMark: true, }, ) as ADFEntityMark; } }; const unsupportedNodeAttributesContent = ( entity: ADFEntity, errorCode: ValidationError['code'], invalidAttributes: ADFEntity['attrs'], message: string, errorCallback?: ErrorCallback, ) => { if (!errorCallback) { throw new Error(message); } else { return errorCallback( { type: entity.type } as ADFEntity, { code: errorCode, message, meta: invalidAttributes, }, { allowUnsupportedBlock: false, allowUnsupportedInline: false, isMark: false, isNodeAttribute: true, }, ) as ADFEntityMark; } }; export function validator( nodes?: Array<string>, marks?: Array<string>, options?: ValidationOptions, ) { const validatorSpecs = createSpec(nodes, marks); const { mode = 'strict', allowPrivateAttributes = false } = options || {}; const validate: Validate = (entity, errorCallback, allowed, parentSpec) => { const validationResult = validateNode( entity, errorCallback, allowed, parentSpec, ); return { entity: validationResult.entity, valid: validationResult.valid }; }; const validateNode = ( entity: ADFEntity, errorCallback?: ErrorCallback, allowed?: Content, parentSpec?: ValidatorSpec, isMark: boolean = false, ): NodeValidationResult => { const { type } = entity; let newEntity: ADFEntity = { ...entity }; const err = <T extends ValidationErrorType>( code: T, msg: string, meta?: T extends keyof ValidationErrorMap ? ValidationErrorMap[T] : never, ): NodeValidationResult => { const message = errorMessageFor(type, msg); if (errorCallback) { return { valid: false, entity: errorCallback( newEntity, { code, message, meta }, getUnsupportedOptions(parentSpec), ), }; } else { throw new Error(message); } }; if (type) { const typeOptions = getOptionsForType(type, allowed); if (typeOptions === false) { return isMark ? { valid: false } : err('INVALID_TYPE', 'type not allowed here'); } const spec = validatorSpecs[type]; if (!spec) { return err( 'INVALID_TYPE', `${type}: No validation spec found for type!`, ); } const specBasedValidationResult = specBasedValidationFor( spec, typeOptions, entity, err, newEntity, type, errorCallback, isMark, ); if ( specBasedValidationResult.hasValidated && specBasedValidationResult.result ) { return specBasedValidationResult.result; } } else { return err( 'INVALID_TYPE', 'ProseMirror Node/Mark should contain a `type`', ); } return { valid: true, entity: newEntity }; }; return validate; function marksValidationFor( validator: ValidatorSpec, entity: ADFEntity, errorCallback: ErrorCallback | undefined, newEntity: ADFEntity, err: Err, ) { let validationResult: NodeValidationResult; if (validator.props && validator.props.marks) { const marksSet = allowedMarksFor(validator); const marksValidationResult = marksAfterValidation( entity, errorCallback, marksSet, validator, ); validationResult = { valid: true, entity: newEntity, marksValidationOutput: marksValidationResult, }; } else { validationResult = marksForEntitySpecNotSupportingMarks( entity, newEntity, errorCallback, err, ); } return validationResult; } function validatorFor( spec: ValidatorSpec, typeOptions: Record<string, any>, ): ValidatorSpec { return { ...spec, ...typeOptions, // options with props can override props of spec ...(spec.props ? { props: { ...spec.props, ...(typeOptions['props'] || {}) } } : {}), }; } function marksAfterValidation( entity: ADFEntity, errorCallback: ErrorCallback | undefined, marksSet: Array<string | Array<string>>, validator: ValidatorSpec, ): MarkValidationResult[] { return entity.marks ? entity.marks.map((mark) => { const isAKnownMark = marks ? marks.indexOf(mark.type) > -1 : true; if (mode === 'strict' && isAKnownMark) { const finalResult = validateNode( mark, errorCallback, marksSet, validator, true, ); const finalMark = finalResult.entity; if (finalMark) { return { valid: true, originalMark: mark, newMark: finalMark }; } // this checks for mark level attribute errors // and propagates error code and message else if ( finalResult.marksValidationOutput && finalResult.marksValidationOutput.length ) { return { valid: false, originalMark: mark, errorCode: finalResult.marksValidationOutput[0].errorCode, message: finalResult.marksValidationOutput[0].message, }; } else { return { valid: false, originalMark: mark, errorCode: 'INVALID_TYPE', }; } } else { return { valid: false, originalMark: mark, errorCode: 'INVALID_CONTENT', }; } }) : []; } function allowedMarksFor(validator: ValidatorSpec) { const { items } = validator.props!.marks!; const marksSet = items.length ? Array.isArray(items[0]) ? items[0] : items : []; return marksSet; } function marksForEntitySpecNotSupportingMarks( prevEntity: ADFEntity, newEntity: ADFEntity, errorCallback: ErrorCallback | undefined, err: Err, ) { const errorCode = 'REDUNDANT_MARKS'; const currentMarks = prevEntity.marks || []; const newMarks = currentMarks.map((mark: ADFEntityMark) => { const isUnsupportedNodeAttributeMark = mark.type === 'unsupportedNodeAttribute'; if (isUnsupportedNodeAttributeMark) { return mark; } return unsupportedMarkContent(errorCode, mark, errorCallback); }); if (newMarks.length) { newEntity.marks = newMarks; return { valid: true, entity: newEntity }; } else { return err('REDUNDANT_MARKS', 'redundant marks', { marks: Object.keys(currentMarks), }); } } function requiredPropertyValidationFor( validatorSpec: ValidatorSpec, prevEntity: ADFEntity, err: Err, ) { let result: NodeValidationResult = { valid: true, entity: prevEntity }; if (validatorSpec.required) { if ( !validatorSpec.required.every((prop: string | number) => isDefined(prevEntity[prop]), ) ) { result = err('MISSING_PROPERTIES', 'required prop missing'); } } return result; } function textPropertyValidationFor( validatorSpec: ValidatorSpec, prevEntity: ADFEntity, err: Err, ) { let result: NodeValidationResult = { valid: true, entity: prevEntity }; if (validatorSpec.props!.text) { if ( isDefined(prevEntity.text) && !validateAttrs(validatorSpec.props!.text, prevEntity.text) ) { result = err('INVALID_TEXT', `'text' validation failed`); } } return result; } function contentLengthValidationFor( validatorSpec: ValidatorSpec, prevEntity: ADFEntity, err: Err, ) { let result: NodeValidationResult = { valid: true, entity: prevEntity }; if (validatorSpec.props!.content && prevEntity.content) { const { minItems, maxItems } = validatorSpec.props!.content; const length = prevEntity.content.length; if (isDefined(minItems) && minItems > length) { result = err( 'INVALID_CONTENT_LENGTH', `'content' should have more than ${minItems} child`, { length, requiredLength: minItems, type: 'minimum' }, ); } else if (isDefined(maxItems) && maxItems < length) { result = err( 'INVALID_CONTENT_LENGTH', `'content' should have less than ${maxItems} child`, { length, requiredLength: maxItems, type: 'maximum' }, ); } } return result; } function invalidAttributesFor( validatorSpec: ValidatorSpec, prevEntity: ADFEntity, ) { let invalidAttrs: Array<string> = []; let validatorAttrs: Record<string, any> = {}; if (validatorSpec.props && validatorSpec.props.attrs) { const attrOptions = makeArray(validatorSpec.props.attrs); /** * Attrs can be union type so try each path * attrs: [{ props: { url: { type: 'string' } } }, { props: { data: {} } }], * Gotcha: It will always report the last failure. */ for (let i = 0, length = attrOptions.length; i < length; ++i) { const attrOption = attrOptions[i]; if (attrOption && attrOption.props) { [, invalidAttrs] = partitionObject(attrOption.props, (k, v) => { return validateAttrs(v, (prevEntity.attrs as any)[k]); }); } validatorAttrs = attrOption!; if (!invalidAttrs.length) { break; } } } return { invalidAttrs, validatorAttrs }; } function attributesValidationFor( validatorSpec: ValidatorSpec, prevEntity: ADFEntity, newEntity: ADFEntity, isMark: boolean, errorCallback: ErrorCallback | undefined, ): NodeValidationResult { const validatorSpecAllowsAttributes = validatorSpec.props && validatorSpec.props.attrs; if (prevEntity.attrs) { if (!validatorSpecAllowsAttributes) { if (isMark) { return handleNoAttibutesAllowedInSpecForMark( prevEntity, prevEntity.attrs, ); } const attrs = Object.keys(prevEntity.attrs); return handleUnsupportedNodeAttributes( prevEntity, newEntity, [], attrs, errorCallback, ); } const { hasUnsupportedAttrs, redundantAttrs, invalidAttrs, } = validateAttributes(validatorSpec, prevEntity, prevEntity.attrs); if (hasUnsupportedAttrs) { if (isMark) { return handleUnsupportedMarkAttributes( prevEntity, invalidAttrs, redundantAttrs, ); } return handleUnsupportedNodeAttributes( prevEntity, newEntity, invalidAttrs, redundantAttrs, errorCallback, ); } } return { valid: true, entity: prevEntity }; } function validateAttributes( validatorSpec: ValidatorSpec, prevEntity: ADFEntity, attributes: { [name: string]: any }, ) { const invalidAttributesResult = invalidAttributesFor( validatorSpec, prevEntity, ); const { invalidAttrs } = invalidAttributesResult; const validatorAttrs = invalidAttributesResult.validatorAttrs; const attrs = Object.keys(attributes).filter( (k) => !(allowPrivateAttributes && k.startsWith('__')), ); const redundantAttrs = attrs.filter((a) => !validatorAttrs.props![a]); const hasRedundantAttrs = redundantAttrs.length > 0; const hasUnsupportedAttrs = invalidAttrs.length || hasRedundantAttrs; return { hasUnsupportedAttrs, invalidAttrs, redundantAttrs, }; } function handleUnsupportedNodeAttributes( prevEntity: ADFEntity, newEntity: ADFEntity, invalidAttrs: Array<string>, redundantAttrs: Array<string>, errorCallback: ErrorCallback | undefined, ) { const attr: Array<string> = invalidAttrs.concat(redundantAttrs); let result: NodeValidationResult = { valid: true, entity: prevEntity }; const message = errorMessageFor( prevEntity.type, `'attrs' validation failed`, ); const errorCode = 'UNSUPPORTED_ATTRIBUTES'; newEntity.marks = wrapUnSupportedNodeAttributes( prevEntity, newEntity, attr, errorCode, message, errorCallback, ); result = { valid: true, entity: newEntity }; return result; } function handleUnsupportedMarkAttributes( prevEntity: ADFEntity, invalidAttrs: Array<string>, redundantAttrs: Array<string>, ) { let errorCode: ValidationErrorType = 'INVALID_ATTRIBUTES'; let message = errorMessageFor(prevEntity.type, `'attrs' validation failed`); const hasRedundantAttrs = redundantAttrs.length; const hasBothInvalidAndRedundantAttrs = hasRedundantAttrs && invalidAttrs.length; if (!hasBothInvalidAndRedundantAttrs && hasRedundantAttrs) { errorCode = 'REDUNDANT_ATTRIBUTES'; message = errorMessageFor( 'redundant attributes found', redundantAttrs.join(', '), ); } const markValidationResult = { valid: true, originalMark: prevEntity, errorCode: errorCode, message: message, }; return { valid: false, marksValidationOutput: [markValidationResult], }; } function handleNoAttibutesAllowedInSpecForMark( prevEntity: ADFEntity, attributes: { [name: string]: any }, ) { const message = errorMessageFor( 'redundant attributes found', Object.keys(attributes).join(', '), ); const errorCode: ValidationErrorType = 'REDUNDANT_ATTRIBUTES'; const markValidationResult = { valid: true, originalMark: prevEntity, errorCode: errorCode, message: message, }; return { valid: false, marksValidationOutput: [markValidationResult], }; } function wrapUnSupportedNodeAttributes( prevEntity: ADFEntity, newEntity: ADFEntity, invalidAttrs: Array<string>, errorCode: ValidationErrorType, message: string, errorCallback: ErrorCallback | undefined, ) { let invalidValues: ADFEntity['attrs'] = {}; for (let invalidAttr in invalidAttrs) { invalidValues[invalidAttrs[invalidAttr]] = prevEntity.attrs && prevEntity.attrs[invalidAttrs[invalidAttr]]; if (newEntity.attrs) { delete newEntity.attrs[invalidAttrs[invalidAttr]]; } } const unsupportedNodeAttributeValues = unsupportedNodeAttributesContent( prevEntity, errorCode, invalidValues, message, errorCallback, ); const finalEntity = { ...newEntity }; if (finalEntity.marks) { unsupportedNodeAttributeValues && finalEntity.marks.push(unsupportedNodeAttributeValues); return finalEntity.marks; } else { return [unsupportedNodeAttributeValues] as ADFEntityMark[]; } } function extraPropsValidationFor( validatorSpec: ValidatorSpec, prevEntity: ADFEntity, err: Err, newEntity: ADFEntity, type: string, ): NodeValidationResult { let result: NodeValidationResult = { valid: true, entity: prevEntity }; const [requiredProps, redundantProps] = partitionObject(prevEntity, (k) => isDefined((validatorSpec.props as any)[k]), ); if (redundantProps.length) { if (mode === 'loose') { newEntity = { type }; requiredProps.reduce((acc, p) => copy(prevEntity, acc, p), newEntity); } else { if ( !( (redundantProps.indexOf('marks') > -1 || redundantProps.indexOf('attrs') > -1) && redundantProps.length === 1 ) ) { return err( 'REDUNDANT_PROPERTIES', `redundant props found: ${redundantProps.join(', ')}`, { props: redundantProps }, ); } } } return result; } function specBasedValidationFor( spec: ValidatorSpec, typeOptions: Record<string, any>, prevEntity: ADFEntity, err: Err, newEntity: ADFEntity, type: string, errorCallback: ErrorCallback | undefined, isMark: boolean, ): SpecValidatorResult { let specBasedValidationResult: SpecValidatorResult = { hasValidated: false, }; const validatorSpec: ValidatorSpec = validatorFor(spec, typeOptions); if (!validatorSpec) { return specBasedValidationResult; } // Required Props // For array format where `required` is an array const requiredPropertyValidatonResult = requiredPropertyValidationFor( validatorSpec, prevEntity, err, ); if (!requiredPropertyValidatonResult.valid) { return { hasValidated: true, result: requiredPropertyValidatonResult, }; } if (!validatorSpec.props) { const props = Object.keys(prevEntity); // If there's no validator.props then there shouldn't be any key except `type` if (props.length > 1) { return { hasValidated: true, result: err( 'REDUNDANT_PROPERTIES', `redundant props found: ${Object.keys(prevEntity).join(', ')}`, { props }, ), }; } return specBasedValidationResult; } // Check text const textPropertyValidationResult = textPropertyValidationFor( validatorSpec, prevEntity, err, ); if (!textPropertyValidationResult.valid) { return { hasValidated: true, result: textPropertyValidationResult, }; } // Content Length const contentLengthValidationResult = contentLengthValidationFor( validatorSpec, prevEntity, err, ); if (!contentLengthValidationResult.valid) { return { hasValidated: true, result: contentLengthValidationResult, }; } // Required Props // For object format based on `optional` property const [, missingProps] = partitionObject( validatorSpec.props, (k, v) => v.optional || isDefined(prevEntity[k]), ); if (missingProps.length) { return { hasValidated: true, result: err('MISSING_PROPERTIES', 'required prop missing', { props: missingProps, }), }; } const attributesValidationResult = attributesValidationFor( validatorSpec, prevEntity, newEntity, isMark, errorCallback, ); if (!attributesValidationResult.valid) { return { hasValidated: true, result: attributesValidationResult, }; } if (isMark && attributesValidationResult.valid) { return { hasValidated: true, result: attributesValidationResult, }; } const extraPropsValidationResult = extraPropsValidationFor( validatorSpec, prevEntity, err, newEntity, type, ); if (!extraPropsValidationResult.valid) { return { hasValidated: true, result: extraPropsValidationResult, }; } // Children if (validatorSpec.props.content) { const contentValidatorSpec = validatorSpec.props.content; if (prevEntity.content) { const validateChildNode = ( child: ADFEntity | undefined, index: any, ) => { if (child === undefined) { return child; } const validateChildMarks = ( childEntity: ADFEntity | undefined, marksValidationOutput: MarkValidationResult[] | undefined, errorCallback: ErrorCallback | undefined, isLastValidationSpec: boolean, isParentTupleLike: boolean = false, ) => { let marksAreValid = true; if (childEntity && childEntity.marks && marksValidationOutput) { const validMarks = marksValidationOutput.filter( (mark) => mark.valid, ); const finalMarks = marksValidationOutput! .map((mr) => { if (mr.valid) { return mr.newMark; } else { if ( validMarks.length || isLastValidationSpec || isParentTupleLike || mr.errorCode === 'INVALID_TYPE' || mr.errorCode === 'INVALID_CONTENT' || mr.errorCode === 'REDUNDANT_ATTRIBUTES' || mr.errorCode === 'INVALID_ATTRIBUTES' ) { return unsupportedMarkContent( mr.errorCode!, mr.originalMark, errorCallback, mr.message, ); } return; } }) .filter(Boolean) as ADFEntityMark[]; if (finalMarks.length) { childEntity.marks = finalMarks; } else { delete childEntity.marks; marksAreValid = false; } } return { valid: marksAreValid, entity: childEntity }; }; const hasMultipleCombinationOfContentAllowed = !!contentValidatorSpec.isTupleLike; if (hasMultipleCombinationOfContentAllowed) { const { entity: newChildEntity, marksValidationOutput, } = validateNode( child, errorCallback, makeArray( contentValidatorSpec.items[index] || contentValidatorSpec.items[ contentValidatorSpec.items.length - 1 ], ), validatorSpec, ); const { entity } = validateChildMarks( newChildEntity, marksValidationOutput, errorCallback, false, true, ); return entity; } // Only go inside valid branch const allowedSpecsForEntity = contentValidatorSpec.items.filter( (item) => Array.isArray(item) ? item.some( // [p, hr, ...] or [p, [text, {}], ...] (spec) => (Array.isArray(spec) ? spec[0] : spec) === child.type, ) : true, ); if (allowedSpecsForEntity.length) { if (allowedSpecsForEntity.length > 1) { throw new Error('Consider using Tuple instead!'); } const maybeArray = makeArray(allowedSpecsForEntity[0]); const allowedSpecsForChild = maybeArray.filter( (item) => (Array.isArray(item) ? item[0] : item) === child.type, ); if (allowedSpecsForChild.length === 0) { return invalidChildContent(child, errorCallback, validatorSpec); } /** * When there's multiple possible branches try all of them. * If all of them fails, throw the first one. * e.g.- [['text', { marks: ['a'] }], ['text', { marks: ['b'] }]] */ let firstError; let firstChild; for (let i = 0, len = allowedSpecsForChild.length; i < len; i++) { try { const allowedValueForCurrentSpec = [allowedSpecsForChild[i]]; const { valid, entity: newChildEntity, marksValidationOutput, } = validateNode( child, errorCallback, allowedValueForCurrentSpec, validatorSpec, ); if (valid) { const isLastValidationSpec = i === allowedSpecsForChild.length - 1; const { valid: marksAreValid, entity } = validateChildMarks( newChildEntity, marksValidationOutput, errorCallback, isLastValidationSpec, ); const unsupportedMarks = (entity && entity.marks && entity.marks.filter( (mark) => mark.type === 'unsupportedMark', )) || []; if (marksAreValid && !unsupportedMarks.length) { return entity; } else { firstChild = firstChild || newChildEntity; } } else { firstChild = firstChild || newChildEntity; } } catch (error) { firstError = firstError || error; } } if (!errorCallback) { throw firstError; } else { return firstChild; } } else { return invalidChildContent(child, errorCallback, validatorSpec); } }; newEntity.content = prevEntity.content .map(validateChildNode) .filter(Boolean) as Array<ADFEntity>; } else if (!contentValidatorSpec.optional) { return { hasValidated: true, result: err('MISSING_PROPERTIES', 'missing `content` prop'), }; } } // Marks if (prevEntity.marks) { return { hasValidated: true, result: marksValidationFor( validatorSpec, prevEntity, errorCallback, newEntity, err, ), }; } return specBasedValidationResult; } }
typescript
package org.noear.solon.core.handle; import java.util.List; /** * 过滤器调用链实现 * * @author noear * @since 1.3 * */ public class FilterChainNode implements FilterChain { private final List<FilterEntity> filterList; private int index; public FilterChainNode(List<FilterEntity> filterList) { this.filterList = filterList; this.index = 0; } @Override public void doFilter(Context ctx) throws Throwable { filterList.get(index++).filter.doFilter(ctx, this); } }
java
/** @format */ const jql = require('../../../src'); const JQLError = require('../../../src/constructs/JQLError'); const sampleData = [ { test1: 'test1', test2: 'test2', test3: 'test3', test4: { test5: { test6: { test7: 'test4' } } }, test8: [{ test8_1: 'test8_1' }, { test8_1: 'test8_2' }, { test8_1: 'test8_3' }] }, { test1: 'test11', test2: 'test21', test3: 'test31', test4: { test5: { test6: { test7: 'test41' } } }, test8: [{ test8_1: 'test8_11' }, { test8_1: 'test8_21' }, { test8_1: 'test8_31' }] } ]; describe('operator $regex', () => { it('throws error when given wrong value', () => { expect(() => jql( { test1: { $regex: [] } }, sampleData ) ).toThrow(JQLError); expect(() => jql( { test1: { $regex: 'test' } }, sampleData ) ).toThrow(JQLError); expect(() => jql( { test1: { $regex: 1 } }, sampleData ) ).toThrow(JQLError); expect(() => jql( { test1: { $regex: '' } }, sampleData ) ).toThrow(JQLError); expect(() => jql( { test1: { $regex: null } }, sampleData ) ).toThrow(JQLError); expect(() => jql( { test1: { $regex: undefined } }, sampleData ) ).toThrow(JQLError); }); it('handles multiple layers and arrays', () => { const query = { test1: { $regex: /test1$/ }, test2: { $regex: /test2$/ }, test3: { $regex: /test3$/ }, test4: { test5: { test6: { test7: { $regex: /test4$/ } } } }, test8: { test8_1: { $regex: /test8_1$/ } } }; expect(jql(query, sampleData)).toEqual([sampleData[0]]); }); it('handles querying a field that does not exist', () => { expect(jql({ doesNotExist: { $regex: /test/ } }, sampleData)).toEqual([]); expect(jql({ does: { not: { exist: { $regex: /test/ } } } }, sampleData)).toEqual([]); }); });
javascript
<filename>app/views/idverification/v1/complete.html {% extends "layout-idauth.html" %} {% block pageTitle %} {% endblock %} {% block heroClass %} {% endblock %} {% block heroContent %} {% endblock %} {% block content %} <div class="govuk-grid-row"> <div class="govuk-grid-column-two-thirds"> <h1 class="govuk-heading-l">Complete</h1> </div> </div> {% endblock %}
html
Imsai Arasan 23aam Pulikesi from Shankar's S Productions is truly a masterpiece in Shankar's unique and flamboyant style. Vadivelu as Pulikesi has impressed all the viewers through his fun provoking punishments, and his funny fight sequences. The elderly cast of Nagesh, Manorama, and Vennira Adai Moorthy has definitely impressed the audience. Arthur Wilson's cinematography has brought the historical era alive before our eyes. Special mention should be made of the art director P Krishnamurthy who has done a fantastic job with the palatial sets! This comical historical movie has completed an unbeatable 25 days run a couple of days ago. Hats off to the cast and crew of this movie!!!
english
Praveen Kumar stormed to the silver medal in the men’s high jump T64 with a personal best and Asian record on Friday, taking India’s haul to 11 at the ongoing Tokyo Paralympics. The Indian teen finished on the podium ahead of the Rio 2016 champion and behind only the reigning world champion. This was Kumar’s first major medal since taking up the sport in 2019. The teenager is a Noida resident and is now the youngest medal winner in the Indian contingent. The 18-year-old, competing in his debut Paralympics, has a personal best of 2.05m before. But with a 2.07m jump on his second attempt, he put himself in the gold medal position. However, eventual champion as Jonathan Broom-Edwards of Great Britain cleared it on his third attempt and then notched up his season’s best of 2.10m for the gold. The bronze went to Rio Games champion Maciej Lepiato of Poland who produced an effort of 2.04m. T64 classification is for athletes with a leg amputation, who compete with prosthetics in a standing position. T44, the disability classification that Kumar has but is eligible to compete in T64, is for athletes with a leg deficiency, leg length difference, impaired muscle power or impaired passive range of movement in the legs. His impairment, which is congenital, affects the bones that connect his hip to his left leg. The ongoing Games are turning out to be India’s best ever and the nation has so far claimed two gold, six silver and three bronze medals.
english
The Lenovo K5 offers premium design at a low price point, but that may not be enough to convince people to take a punt. Why you can trust TechRadar We spend hours testing every product or service we review, so you can be sure you’re buying the best. Find out more about how we test. Lenovo is already a well know producer of technology, and you're likely familiar with the brand in the laptop world. Thing is, it doesn't just deal in computers and in Asian markets it has a bustling smartphone business. It may have only recently purchased Motorola, a much more established name in the UK mobile market, but it's now looking it get its own-brand handsets onto our fair shores as well. Its first offering is the Lenovo K5, a budget phone that when it launched would set you back just £129 SIM-free, and from the looks of it that's a pretty good deal. It's now even cheaper and we've seen deals for around £100. The US aren't quite so lucky with the phone sticking around $200. The K5 is a rebadged Vibe K5 Plus from Lenovo's Eastern activities and boasts a 5-inch display, octa-core processor, 2GB of RAM, 16GB of internal space, 13MP rear camera, 5MP front camera, 2,750mah removable battery and Dolby Atmos speakers. Considering the price point, that's a very good line-up of specs. There's a microSD card slot too, and it'll also land as a dual-SIM phone - allowing you to slip two separate cards in so you can harness the power, allowances and coverage of more than one network. The handset I got hands on with sported a white front plant and a silver rear, but you'll also be able to pick it up with a black front and a gunmetal grey back. The back cover, which comes off the phone giving you access to the battery and various slots, is covered in a thin veneer of metal. Pick up the Lenovo K5 and you feel the slightly cool, metallic finish giving this budget smartphone a slightly more premium finish. It's no where near the quality of the iPhone 6S or HTC 10, but it provides a pleasing presence in the hand. Flip the phone over and towards the base you'll spot two speaker grilles. Now these aren't your standard internal smartphone speakers, as Lenovo has teamed up with Dolby to infuse the K5 with its Atmos technology. That gives you richer audio from the speakers, but it's not going to drown you in sound. This is still a smartphone. The placement is also less than ideal. Front facing speakers would really showcase the power, but with them residing on the back I found my hands muffling the sound. On screen things aren't quite as lovely - Lenovo's heavy Android skin is a stark contrast to Motorola's hands-off approach and the result is a gaudy colour scheme and a missing app draw. It's not as oppressive as Huawei's Emotion UI, but it's leaning that way and UK palettes may struggle to fully embrace it. There's also the issue that this phone, launched over six months after the arrival of Android Marshmallow, is still running Android Lollipop. It's not like the Snapdragon 415 processor and 2GB of RAM are not capable of running Google's latest OS, and both the Moto G4 and G4 Plus come with the newest version. Things at least look good on the 720p 5-inch display, and navigation was smooth during my time with the K5. There aren't any real bells and whistles here, but then I don't expect that from a phone which sets you back just £129. Lenovo finds itself in a tricky position. Sure the K5 is a decent budget handset, but it's not a brand name people in the UK associate with mobiles. It's likely to be overlooked as people's eyes land on more familiar territory. Motorola and Samsung are safer bets. That said, the K5 does offer more premium design than many of its peers, and if you can get over Lenovo's interface then you may well enjoy this low cost option. John joined TechRadar over a decade ago as Staff Writer for Phones, and over the years has built up a vast knowledge of the tech industry. He's interviewed CEOs from some of the world's biggest tech firms, visited their HQs and has appeared on live TV and radio, including Sky News, BBC News, BBC World News, Al Jazeera, LBC and BBC Radio 4. Originally specializing in phones, tablets and wearables, John is now TechRadar's resident automotive expert, reviewing the latest and greatest EVs and PHEVs on the market. John also looks after the day-to-day running of the site. What is a hands on review? Hands on reviews' are a journalist's first impressions of a piece of kit based on spending some time with it. It may be just a few moments, or a few hours. The important thing is we have been able to play with it ourselves and can give you some sense of what it's like to use, even if it's only an embryonic view. For more information, see TechRadar's Reviews Guarantee.
english
<reponame>atouchet/lldb-sys.rs //===-- SBInstructionListBinding.cpp ----------------------------*- C++ -*-===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===----------------------------------------------------------------------===// #include "lldb/API/LLDB.h" #include "lldb/Bindings/LLDBBinding.h" using namespace lldb; #ifdef __cplusplus extern "C" { #endif SBInstructionListRef CreateSBInstructionList() { return reinterpret_cast<SBInstructionListRef>(new SBInstructionList()); } SBInstructionListRef CloneSBInstructionList(SBInstructionListRef instance) { return reinterpret_cast<SBInstructionListRef>( new SBInstructionList(*reinterpret_cast<SBInstructionList *>(instance))); } void DisposeSBInstructionList(SBInstructionListRef instance) { delete reinterpret_cast<SBInstructionList *>(instance); } bool SBInstructionListIsValid(SBInstructionListRef instance) { SBInstructionList *unwrapped = reinterpret_cast<SBInstructionList *>(instance); return unwrapped->IsValid(); } size_t SBInstructionListGetSize(SBInstructionListRef instance) { SBInstructionList *unwrapped = reinterpret_cast<SBInstructionList *>(instance); return unwrapped->GetSize(); } SBInstructionRef SBInstructionListGetInstructionAtIndex(SBInstructionListRef instance, uint32_t idx) { SBInstructionList *unwrapped = reinterpret_cast<SBInstructionList *>(instance); return reinterpret_cast<SBInstructionRef>( new SBInstruction(unwrapped->GetInstructionAtIndex(idx))); } void SBInstructionListClear(SBInstructionListRef instance) { SBInstructionList *unwrapped = reinterpret_cast<SBInstructionList *>(instance); unwrapped->Clear(); } void SBInstructionListAppendInstruction(SBInstructionListRef instance, SBInstructionRef inst) { SBInstructionList *unwrapped = reinterpret_cast<SBInstructionList *>(instance); unwrapped->AppendInstruction(*reinterpret_cast<SBInstruction *>(inst)); } void SBInstructionListPrint(SBInstructionListRef instance, FILE *out) { SBInstructionList *unwrapped = reinterpret_cast<SBInstructionList *>(instance); unwrapped->Print(out); } bool SBInstructionListGetDescription(SBInstructionListRef instance, SBStreamRef description) { SBInstructionList *unwrapped = reinterpret_cast<SBInstructionList *>(instance); return unwrapped->GetDescription(*reinterpret_cast<SBStream *>(description)); } bool SBInstructionListDumpEmulationForAllInstructions( SBInstructionListRef instance, const char *triple) { SBInstructionList *unwrapped = reinterpret_cast<SBInstructionList *>(instance); return unwrapped->DumpEmulationForAllInstructions(triple); } #ifdef __cplusplus } #endif
cpp
AFTERMATH of the WAR to be pursued in case of all other States, if they went the same way.' »»1 In fact, the position of the States had considerably weakened after the lapse of paramountcy and they had no sufficient resources to maintain their position. Chaos and confusion could not be allowed to prevail in any of the States for larger interest of the province. After the take over of the administration of Nilgiri, the States Ministry took the initiative to resolve the problem of the Orissa States. In a high level meeting of the ministry on 20 November 1947, in which Mahtab was also present, it was decided not to recognize the Eastern States Union as it was formed "in utter disregard of linguistic, economic and social considerations." Though the Dominion of India was prepared to guarantee the continuance of the ruling dynasty, succession etc., it was seriously felt that the future of those States lay in developing with the province of Orissa and not outside it. In order to explore the possibilities of associating the States with the provincial administration for common interest, it was finally settled to meet the rulers in a conference in Orissa as soon as possible. Accordingly, Sardar Patel, V.P. Menon and other officials of the States Ministry arrived at Cuttack on 13 December 1947. The historic conference began in the Raj Bhavan at Cuttack in the morning of 14 December. Mahtab gives a vivid description of the situation in the previous evening as follows: "After some discussions he (Sardar Patel) scrapped straightaway the conclusions which were arrived at in Delhi on the 20th November 1947. He made up his mind and gave his decision that these states should be amalgamated with the province. He asked me if our memorandum was ready. I said it would be circulated early next morning. The memorandum which was prepared at the instance of the States Ministry was scrapped and a new memorandum was quickly prepared... The whole night Sardar discussed with me again all the future possibilities. He repeatedly told me that responsibility in the case of Nilgiri was entirely mine but in the present case it is shared by him as well. I assured him that in case the Rulers did not agree to his proposal, there was bound to be serious lawlessness in the States and Orissa Government would not allow such a situation to develop. If necessary, all the States would be taken over on the very day Sardar left Orissa disappointed." Amrit Bazar Patrika, 20 November 1947. 2. H.K. Mahtab, Beginning of the End p. 29. Also, Durga Das, India From Curzon to Nehru and After, (London, 1969), pp. 281-82. HISTORY OF ORISSA Sardar Patel inaugurated the conference with a most persuasive speech. His first meeting was with the rulers of 'B' and 'C' class States. Twelve rulers of that category were present and three more could not attend the meeting. It was explained that the States possessed no resources to maintain any stable government. Therefore, it was most desirable for them to merge in the province so that Orissa could prosper and progress in the new federal set-up. After some persuasion, twelve rulers signed the document for merger with the Indian Dominion and the remaining three rulers could sign the document later. It was more difficult to tackle eleven rulers of ‘A’ Class States. In the afternoon session of the Conference, Sardar Patel tried to convince them about the utility of the merger with the province. At the outset, the ruler of Mayurbhanj pointed out that he had already transferred power to the hands of the representatives of the people and he was unable to make any commitment without consulting the ministry. Infact, it was the only State in Orissa which had not joined the Eastern States Union and had installed a popular ministry under the Praja Mandal leadership. Naturally Mayurbhanj 'alone remained beyond the scope of discussion and finally outside the periphery of the agreement. Ten other ruling chiefs ultimately agreed after a good deal of pressure and persuasion, to accept the plan of merger and the documents were signed by the morning of 15 December 1947.¹ It was a dramatic climax to the history of the Garjats who had maintained their separate identities throughout the British rule, but could not withstand the popular and political pressure for four months in independent India. The bitter agitation of the people in the Feudatory States of Orissa thus ended with the advent of independence by their merger with the province. The subsequent integration of those States with the provincial adıninistration in all fields took some time to be accomplished, but it presented no serious problem. On 23 December 1947, in exercise of the powers conferred by the Extra Provincial Jurisdiction Act, 1947, the Government of India delegated to the Orissa Government the power to administer the Feudatory States 'in the same manner as the districts in that province.' It became effective from 1 January 1948. Mayurbhanj signed the Instrument of Merger on 17 October 1948 and the State was taken over by the Government of India on 9 November. It was administered by a Chief Commissioner for some time and then came under the control of the Government of Orissa from January 1949. 1. V.P. Menon, The Story of the Integration of the Indian States, pp. 156-40. AFTERMATH OF THE WAR In the meanwhile, trouble had begun in two States of Seraikala and Kharsuan. It became the bone of contention between the two neighbouring provinces of Orissa and Bihar. By the arbitration of the States Ministry, those two States were handed over to Bihar on 18 May 1948. Ultimately twentyfour Feudatory States were integrated with the province. The emergence of a greater Orissa in indian body politic presented immense possibilities for the all-round development of a long-affected people. PRIMARY SOURCES (a) Manuscript Records (i) National Archives, New Delhi-Records of Home (Public), Home (Political) and Reforms Office-Relevant Files on Orissa from 1933 to 1945. (ii) Nehru Memorial Museum and Library, New DelhiA.I.C.C. Files and Files of Indian States People's Conference (1937-49)-Relevant Files on Orissa affairs. (iii) State Archives, West Bengal, Calcutta. Letters to and from the Court of Directors, 1803-1858, Bengal Revenue Proceedings, 1815-1900. Bengal Judicial (Civil and Criminal) Proceedings, 18041900. Proceedings of Board of Customs, Salt and Opium, 18191850. Proceedings of Board of Revenue (Excise), 1804-1822. (iv) State Archives, Orissa, Bhubaneswar. Cuttack Revenue Records, 1803-1900 Balasore Revenue Records, 1803-1900 Balasore Salt Records, 1803-1900 Cuttack Salt Records, 1803-1900 Balasore Customs House Records, 1810-1858. Orissa Revenue Records, 1804-1900 Orissa Judicial Records, 1804-1900 Records of Customs Department, 1820-1823 Records on the History of Freedom Movement, 1920-47 (Typed Volumes) (v) Board of Revenue Records Room, Cuttack Jagannath Temple Correspondences, 1804-1900 (These volumes contain the copies of original correspondences of British Officers regarding the Jagannath Temple) (b) Proceedings of Legislative Chambers (i) Parliamentary Papers (House of Commons)-1812-13 to 1856 (all relevant papers on Orissa) (ii) Proceedings of the Legislative Council of Bengal (19011911) 2 Volumes (iv) Proceedings of the Legislative Assembly of Orissa (193748) 16 Volumes. Proceedings of the Legislative Council of Bihar and Orissa (1912-36)-42 Volumes (c) Government Reports and Publications A Collection of Treaties, Engagements and Sunnuds relating to India and neighbouring countries, C.U. Aitchison (ed), 3 Vols. II (Calcutta, 1931). Annual Administrative Report of the Orissa Division, 185859-1900, 42 Vols. Annual Administrative Report of the Bengal Presidency, 1858-59-1900, 42 Vols. Bihar and Orissa (Annual Report) (Government of Bihar and Orissa, Patna, 1923-38), 15 Vols. Calendar of Persian Correspondences, 9 Vols. (Records Department, Calcutta and New Delhi, 1911-49) Despatches, Minutes and Correspondences of Marquis Wellesley during his administration in India, Montgomery Martin (ed), Vol. III, (London, 1837). Government of Orissa at work (work of the Congress Ministry) (Cuttack, 1938-39)-2 Vols. Guide to Orissan Records, 5 Vols. (State Archives, Bhubaneswar, 1961-64). Indian Round Table Conference, Vol. II (Proceedings of SubCommittees) (Calcutta, 1931). N. Mansergh (ed), Transfer of Power (Lond, 1971–76) 6 Vols. Report of the Commissioners on the Famine of Orissa, 1866 (Calcutta, 1867). Report on the district of Cuttack, Henry Ricketts, Calcutta, 1858. Report on the Land Revenue Administration of the Lower Provinces, 1858-59-1900-01, 42 Vols. HISTORY OF ORISSA. Report on the Public Instruction in Bengal, 1858-59-1900-01, 42 Vols. Report on the Village Watch of the Lower Provinces of Bengal, 1866, D.J. Mcneile. Report on the Abkari Revenue of the Lower Provinces, 185258 (Calcutta, 1854-59), 4 Vols. Report of the Indian Statutory Commission, Vol. I (Survey) (Calcutta, 1930)-Vol. II (Recommendations) (London,. 1930). Report of the Orissa Boundary Committee (Calcutta, 1932). Report of the Joint Committee on Indian Constitutional. Reform, Vol. I (London, 1934). Selections from the Records of the Government of Bengal,. XXIVB-No. 3 (Papers on the Settlement of Cuttack and on the State of the Tributary Mahals), Calcutta, 1867. Selections from the Nagpur Residency Records Vol. I, 17991806, H.N. Sinha (ed), Nagpur, 1950. Selections from the Records of the Bengal Government,. No. XXX (Report on the Districts of Puri and Balasoreby Henry Ricketts, 1853), Calcutta, 1859. Selections from Official Letters and Records relating to the History of Mayurbhanj, 2 Vols. (Baripada, 1942-43). Selections from Records of the Government of India, No. V (Operation for Suppression of Human Sacrifice) Calcutta, 1854. (d) Periodical Publications and Newspaper Files Amrit Bazár Patrika, (Calcutta) 1922-47. Indian Annual Register (Calcutta) 1921-47. Orissa Review, (Government of Orissa), 1947-72. Prajatantra, (Cuttack) 1947-48. Utkal Dipika, (Cuttack) 1869-1933. Satya Samachar, (Cuttack) 1930-34. The Samaj (Cuttack) 1920-38.
english
<filename>docx-core/src/documents/elements/instr_toc.rs use serde::Serialize; use crate::documents::*; #[derive(Serialize, Debug, Clone, PartialEq, Default)] pub struct StyleWithLevel(pub (String, usize)); impl StyleWithLevel { pub fn new(s: impl Into<String>, l: usize) -> Self { Self((s.into(), l)) } } // https://c-rex.net/projects/samples/ooxml/e1/Part4/OOXML_P4_DOCX_TOCTOC_topic_ID0ELZO1.html #[derive(Serialize, Debug, Clone, PartialEq, Default)] pub struct InstrToC { // \o If no heading range is specified, all heading levels used in the document are listed. #[serde(skip_serializing_if = "Option::is_none")] pub heading_styles_range: Option<(usize, usize)>, // \l Includes TC fields that assign entries to one of the levels specified by text in this switch's field-argument as a range having the form startLevel-endLevel, // where startLevel and endLevel are integers, and startLevel has a value equal-to or less-than endLevel. // TC fields that assign entries to lower levels are skipped. #[serde(skip_serializing_if = "Option::is_none")] pub tc_field_level_range: Option<(usize, usize)>, // \n Without field-argument, omits page numbers from the table of contents. // .Page numbers are omitted from all levels unless a range of entry levels is specified by text in this switch's field-argument. // A range is specified as for \l. #[serde(skip_serializing_if = "Option::is_none")] pub omit_page_numbers_level_range: Option<(usize, usize)>, // \b includes entries only from the portion of the document marked by the bookmark named by text in this switch's field-argument. #[serde(skip_serializing_if = "Option::is_none")] pub entry_bookmark_name: Option<String>, // \t Uses paragraphs formatted with styles other than the built-in heading styles. // . text in this switch's field-argument specifies those styles as a set of comma-separated doublets, // with each doublet being a comma-separated set of style name and table of content level. \t can be combined with \o. pub styles_with_levels: Vec<StyleWithLevel>, // struct S texWin Lis switch's field-argument specifies a sequence of character // . The default is a tab with leader dots. #[serde(skip_serializing_if = "Option::is_none")] pub entry_and_page_number_separator: Option<String>, // \d #[serde(skip_serializing_if = "Option::is_none")] pub sequence_and_page_numbers_separator: Option<String>, // \a pub caption_label: Option<String>, // \c #[serde(skip_serializing_if = "Option::is_none")] pub caption_label_including_numbers: Option<String>, // \s #[serde(skip_serializing_if = "Option::is_none")] pub seq_field_identifier_for_prefix: Option<String>, // \f #[serde(skip_serializing_if = "Option::is_none")] pub tc_field_identifier: Option<String>, // \h pub hyperlink: bool, // \w pub preserve_tab: bool, // \x pub preserve_new_line: bool, // \u pub use_applied_paragraph_line_level: bool, // \z Hides tab leader and page numbers in Web layout view. pub hide_tab_and_page_numbers_in_webview: bool, } impl InstrToC { pub fn new() -> Self { Self::default() } pub fn heading_styles_range(mut self, start: usize, end: usize) -> Self { self.heading_styles_range = Some((start, end)); self } pub fn tc_field_level_range(mut self, start: usize, end: usize) -> Self { self.tc_field_level_range = Some((start, end)); self } pub fn tc_field_identifier(mut self, t: impl Into<String>) -> Self { self.tc_field_identifier = Some(t.into()); self } pub fn omit_page_numbers_level_range(mut self, start: usize, end: usize) -> Self { self.omit_page_numbers_level_range = Some((start, end)); self } pub fn entry_and_page_number_separator(mut self, t: impl Into<String>) -> Self { self.entry_and_page_number_separator = Some(t.into()); self } pub fn entry_bookmark_name(mut self, t: impl Into<String>) -> Self { self.entry_bookmark_name = Some(t.into()); self } pub fn caption_label(mut self, t: impl Into<String>) -> Self { self.caption_label = Some(t.into()); self } pub fn caption_label_including_numbers(mut self, t: impl Into<String>) -> Self { self.caption_label_including_numbers = Some(t.into()); self } pub fn sequence_and_page_numbers_separator(mut self, t: impl Into<String>) -> Self { self.sequence_and_page_numbers_separator = Some(t.into()); self } pub fn seq_field_identifier_for_prefix(mut self, t: impl Into<String>) -> Self { self.seq_field_identifier_for_prefix = Some(t.into()); self } pub fn hyperlink(mut self) -> Self { self.hyperlink = true; self } pub fn preserve_tab(mut self) -> Self { self.preserve_tab = true; self } pub fn preserve_new_line(mut self) -> Self { self.preserve_new_line = true; self } pub fn use_applied_paragraph_line_level(mut self) -> Self { self.use_applied_paragraph_line_level = true; self } pub fn hide_tab_and_page_numbers_in_webview(mut self) -> Self { self.hide_tab_and_page_numbers_in_webview = true; self } pub fn add_style_with_level(mut self, s: StyleWithLevel) -> Self { self.styles_with_levels.push(s); self } } impl BuildXML for InstrToC { fn build(&self) -> Vec<u8> { let mut instr = "TOC".to_string(); // \a if let Some(ref t) = self.caption_label { instr = format!("{} \\a &quot;{}&quot;", instr, t); } // \b if let Some(ref t) = self.entry_bookmark_name { instr = format!("{} \\b &quot;{}&quot;", instr, t); } // \c if let Some(ref t) = self.caption_label_including_numbers { instr = format!("{} \\c &quot;{}&quot;", instr, t); } // \d if let Some(ref t) = self.sequence_and_page_numbers_separator { instr = format!("{} \\d &quot;{}&quot;", instr, t); } // \f if let Some(ref t) = self.tc_field_identifier { instr = format!("{} \\f &quot;{}&quot;", instr, t); } // \l if let Some(range) = self.tc_field_level_range { instr = format!("{} \\l &quot;{}-{}&quot;", instr, range.0, range.1); } // \n if let Some(range) = self.omit_page_numbers_level_range { instr = format!("{} \\n &quot;{}-{}&quot;", instr, range.0, range.1); } // \o if let Some(range) = self.heading_styles_range { instr = format!("{} \\o &quot;{}-{}&quot;", instr, range.0, range.1); } // \p if let Some(ref t) = self.entry_and_page_number_separator { instr = format!("{} \\p &quot;{}&quot;", instr, t); } // \s if let Some(ref t) = self.seq_field_identifier_for_prefix { instr = format!("{} \\s &quot;{}&quot;", instr, t); } // \t if !self.styles_with_levels.is_empty() { let s = self .styles_with_levels .iter() .map(|s| format!("{},{}", (s.0).0, (s.0).1)) .collect::<Vec<String>>() .join(","); instr = format!("{} \\t &quot;{}&quot;", instr, s); } // \h if self.hyperlink { instr = format!("{} \\h", instr); } // \u if self.use_applied_paragraph_line_level { instr = format!("{} \\u", instr); } // \w if self.preserve_tab { instr = format!("{} \\w", instr); } // \x if self.preserve_new_line { instr = format!("{} \\x", instr); } // \z if self.hide_tab_and_page_numbers_in_webview { instr = format!("{} \\z", instr); } instr.into() } } fn parse_level_range(i: &str) -> Option<(usize, usize)> { let r = i.replace("&quot;", "").replace("\"", ""); let r: Vec<&str> = r.split('-').collect(); if let Some(s) = r.get(0) { if let Ok(s) = usize::from_str(s) { if let Some(e) = r.get(1) { if let Ok(e) = usize::from_str(e) { return Some((s, e)); } } } } None } impl std::str::FromStr for InstrToC { type Err = (); fn from_str(instr: &str) -> Result<Self, Self::Err> { let mut s = instr.split(' '); let mut toc = InstrToC::new(); loop { if let Some(i) = s.next() { match i { "\\a" => { if let Some(r) = s.next() { let r = r.replace("&quot;", "").replace("\"", ""); toc = toc.caption_label(r); } } "\\b" => { if let Some(r) = s.next() { let r = r.replace("&quot;", "").replace("\"", ""); toc = toc.entry_bookmark_name(r); } } "\\c" => { if let Some(r) = s.next() { let r = r.replace("&quot;", "").replace("\"", ""); toc = toc.caption_label_including_numbers(r); } } "\\d" => { if let Some(r) = s.next() { let r = r.replace("&quot;", "").replace("\"", ""); toc = toc.sequence_and_page_numbers_separator(r); } } "\\f" => { if let Some(r) = s.next() { let r = r.replace("&quot;", "").replace("\"", ""); toc = toc.tc_field_identifier(r); } } "\\h" => toc = toc.hyperlink(), "\\l" => { if let Some(r) = s.next() { if let Some((s, e)) = parse_level_range(r) { toc = toc.tc_field_level_range(s, e); } } } "\\n" => { if let Some(r) = s.next() { if let Some((s, e)) = parse_level_range(r) { toc = toc.omit_page_numbers_level_range(s, e); } } } "\\o" => { if let Some(r) = s.next() { if let Some((s, e)) = parse_level_range(r) { toc = toc.heading_styles_range(s, e); } } } "\\p" => { if let Some(r) = s.next() { let r = r.replace("&quot;", "").replace("\"", ""); toc = toc.entry_and_page_number_separator(r); } } "\\s" => { if let Some(r) = s.next() { let r = r.replace("&quot;", "").replace("\"", ""); toc = toc.seq_field_identifier_for_prefix(r); } } "\\t" => { if let Some(r) = s.next() { let r = r.replace("&quot;", "").replace("\"", ""); let mut r = r.split(','); loop { if let Some(style) = r.next() { if let Some(level) = r.next() { if let Ok(level) = usize::from_str(level) { toc = toc.add_style_with_level(StyleWithLevel(( style.to_string(), level, ))); continue; } } } break; } } } "\\u" => toc = toc.use_applied_paragraph_line_level(), "\\w" => toc = toc.preserve_tab(), "\\x" => toc = toc.preserve_new_line(), "\\z" => toc = toc.hide_tab_and_page_numbers_in_webview(), _ => {} } } else { return Ok(toc); } } } } #[cfg(test)] mod tests { use super::*; #[cfg(test)] use pretty_assertions::assert_eq; use std::str; #[test] fn test_toc() { let b = InstrToC::new().heading_styles_range(1, 3).build(); assert_eq!(str::from_utf8(&b).unwrap(), r#"TOC \o &quot;1-3&quot;"#); } #[test] fn test_toc_with_styles() { let b = InstrToC::new() .heading_styles_range(1, 3) .add_style_with_level(StyleWithLevel::new("style1", 2)) .add_style_with_level(StyleWithLevel::new("style2", 3)) .build(); assert_eq!( str::from_utf8(&b).unwrap(), r#"TOC \o &quot;1-3&quot; \t &quot;style1,2,style2,3&quot;"# ); } #[test] fn read_toc_with_o_and_h() { let i = r#"TOC \o &quot;1-3&quot; \h"#; let i = InstrToC::from_str(i).unwrap(); assert_eq!(i, InstrToC::new().heading_styles_range(1, 3).hyperlink()); } #[test] fn read_toc_with_l_and_n() { let i = r#"TOC \o &quot;1-3&quot; \l &quot;4-5&quot; \n &quot;1-4&quot; \h"#; let i = InstrToC::from_str(i).unwrap(); assert_eq!( i, InstrToC::new() .heading_styles_range(1, 3) .hyperlink() .omit_page_numbers_level_range(1, 4) .tc_field_level_range(4, 5) ); } #[test] fn read_toc_with_a_and_b_and_t() { let i = r#"TOC \a &quot;hoge&quot; \b &quot;test&quot; \o &quot;1-3&quot; \t &quot;MySpectacularStyle,1,MySpectacularStyle2,4&quot;"#; let i = InstrToC::from_str(i).unwrap(); assert_eq!( i, InstrToC::new() .caption_label("hoge") .entry_bookmark_name("test") .heading_styles_range(1, 3) .add_style_with_level(StyleWithLevel::new("MySpectacularStyle", 1)) .add_style_with_level(StyleWithLevel::new("MySpectacularStyle2", 4)) ); } }
rust
In this Ninaivey Oru Sangeedham film, Vijayakanth, Radha played the primary leads. The Ninaivey Oru Sangeedham was released in theaters on 24 Jul 1987. The soundtracks and background music were composed by Ilayaraja for the movie Ninaivey Oru Sangeedham. The movie Ninaivey Oru Sangeedham belonged to the Family, genre.
english
A subscription to JoVE is required to view this content. You will only be able to see the first 20 seconds. The JoVE video player is compatible with HTML5 and Adobe Flash. Older browsers that do not support HTML5 and the H.264 video codec will still use a Flash-based video player. We recommend downloading the newest version of Flash here, but we support all versions 10 and above. If that doesn't help, please let us know. Cellulose is an unbranched polymer of β-glucose units linked by β-1→4 linkage and arranged parallelly via intermolecular hydrogen bonds. Cellulose serves as the major structural component of the plant cell wall, providing shape and rigidity to the cells and facilitating plant growth and development. The proportion of cellulose within the cell wall varies significantly throughout the plant, according to the cell type and growth stage. To visualize cellulose deposition in the stem, take thin cross-sections of agarose-embedded stem sections. Add Congo red fluorescent dye and incubate the sections. Congo red molecules enter the cell wall and form hydrogen bonds with the hydroxyl groups of the cellulose, thereby getting adsorbed onto the polymer. This imparts a red color to the epidermis, cortex, and pith. The dye molecules also diffuse within the complex cell walls of the xylem and interfascicular fibers, crossing the rigid lignin barrier, thus, imparting a red color to these tissues too. Now, rinse the sections in water to remove excess stain. Transfer the sections onto a microscope slide and place a coverslip. When visualized under a fluorescence microscope, the epidermis, cortex, central pith, xylem, and interfascicular fibers appear red, corresponding to their cellulose content.
english
Changing alliances, a poor show by the Congress, the eruption of the Bharatiya Janata Party on the state’s stage and a lot of local volatility have led to a deep reconfiguration of the political landscape in Nagaland. As state Governor PB Acharya appointed Nationalist Democratic Progressive Party leader Neiphiu Rio as Nagaland’s next chief minister on Tuesday, and asked him to prove his government’s majority in the Assembly by March 16, constituency-level data analysis gives some insights on what happened in these elections. Voter participation came down a bit in a state where it frequently touches 90%. As in the rest of the North East, women have been outvoting men since 2008. The decrease in turnout is not geographically uniform. Participation remained very high in the seats where the BJP performed well. The traditional Naga People’s Front strongholds registered a lower turnout than in 2013. It particularly came down in the southern districts of Peren and Dimapur, and in state capital Kohima, where participation fell by 10 percentage points. The number of parties represented in the Assembly remains the same (six). Half of the parties who contested the election obtained representation. The party system of Nagaland started fragmenting after the 1998 elections. Before 1998, four to five parties used to contest and get seats. That number more than doubled 2003 onwards. The overall number of candidates (counting independents) has remained stable over time. This year however, the number of candidates who saved their deposit – by securing more than one sixth of the votes polled in their seat – was significantly higher than in previous elections – 46%, against 25% in 2013. This means that the votes were more equally distributed between a large number of candidates and/or parties, indicating a high level of constituency-level fragmentation. The map of the results reveals that the Naga People’s Front has receded since 2013, but it has resisted rather well in the southern districts of the state, and in a cluster of seats in the northern districts of Mon and Longleng. The BJP’s performance is concentrated along the state’s western border with Assam, which it won in 2016. The Nationalist Democratic People’s Party performed well in the interior of the state and around state capital Kohima. It won mostly in seats held before by the Naga People’s Front. Both the Congress and the Nationalist Congress Party have disappeared from the map. In terms of vote share, most parties have lost ground in this election, with the exception of the BJP and its pre-electoral partner – a newcomer – the Nationalist Democratic People’s Party. The Congress has registered the largest loss, going from 25% of the votes to 2%. The Naga People’s Front lost nearly 8% of vote share. The Nationalist Congress Party has almost disappeared, going from 6% of the vote share to 1%. The BJP is a net gainer, with a 12.6% increase in vote share. It has reached 14.4% of vote share, 3% more than its earlier best performance (11% in 2003). Despite the slump of most major parties, the total vote share obtained by the main parties increased from 74% to 88% of the vote. This increase is essentially pulled by the BJP-Nationalist Democratic People’s Party alliance. Independent candidates in Nagaland have on many occasions received a lot of votes. The state has the peculiarity of having voted in only independent candidates in its first election in 1964. In 1998, half of the state’s MLAs were independent candidates. That ratio has dropped since, as voters choose to opt more strategically for candidates backed by strong parties – strong locally, or at the state level. Nagaland is a small territory in which parties contest each other in every corner of the state. As a result, there are no particular geographical or sub-regional strongholds. The Naga People’s Front’s loss of vote share, for instance, is quite even across the state. The party does not retain any particular cluster of seats, which means that the explanation for its relatively poorer performance in 2018 has to be a general, all-state level rebuff, rather than a collection of local rejections. Similarly. The Congress’s collapse is also evenly distributed, which is not surprising, given its amplitude. There are only three seats left where the party’s vote share exceeded 20%, in Pfutsero, Ghaspani-II and in Tapi. The BJP’s performance is more locally marked, which is explained by the fact that being in an alliance, it did not contest every seat. The BJP crossed the 50% vote share bar in five seats, in Alongtaki, Tyui, Akuluto and Seyochung Sitimi. It even crossed the 60% bar in Dimapur-I. The Nationalist Democratic People’s Party performed well across the state, with two clusters of seats in the North, and in the southern most districts, including Kohima. The Nationalist Democratic People’s Party rode on the strength of its alliance with the BJP as well as on the strength of many turncoat candidates who switched to this new formation before the elections. Since all parties do not contest in every seat, we need to look at their vote share performance in the seats where they contested. The Naga People’s Front scores the highest vote share, having contested in 57 seats. The BJP, which contested only 19 seats, scored an average of 40% of vote share. The Nationalist Democratic People’s Party registered a similar performance as its partner, which shows that the alliance – and the vote transfers between both parties’ respective vote bases – worked very well. A pre-electoral coalition partner frequently under-performs and drags the alliance down, as the Congress did to the Samajwadi Party in Uttar Pradesh in 2017. It was not the case here. In terms of seat share, the Naga People’s Front lost its previous majority (63.3% of the seats in 2013). The BJP-Nationalist Democratic People’s Party combine got the same cumulated seat share (46.56%) as the Naga People’s Front (45.55%). Volatility refers to various measures of discontinuity in electoral politics. Stable party performance can hide a lot of variations at the constituency level. Every party wins some, loses some. Many seats change hands between two elections. Turncoat candidates can get re-elected under different party tickets over time. These measures are important since they give us an idea of how much churning takes place at the local level. Seats were won with an average victory margin lower than 10%, which makes for a very competitive election. The distribution of victory margins across seats is also quite flat, which indicates that most seats were highly competitive. The winner scored more than 20% as victory margin in only seven seats scattered across the state. That phenomenon was more pronounced in 2018 as compared to 2013 due to the BJP’s rise. If we examine party-wise winners’ average vote share and party-wise victory margins, we see that while most individual candidates obtained a near majority of votes in their constituency (which is a strong performance), there is almost always a strong runner-up, particularly in the constituencies won by the BJP and the Nationalist Democratic People’s Party. This means that most seats saw a high level of voter polarisation. There are, however, important variations behind those numbers. The BJP’s average victory margin is 8.3%. But half of its seats were won on extremely narrow margins (less than 5%). The Nationalist Democratic People’s Party scored an average victory margin of 9.7%, with four seats won in a very close election. The same goes for the Naga People’s Front, whose average victory margin of 10% conceals the fact that it won 12 of its 27 seats with narrow margins. The National People’s Party only won two seats, one with a 5% margin, and the other with a 25% margin. In total, 23 seats were won with small margins, which reveals once again that this was a very competitive election. In most states, incumbent MLAs stand little chance to serve more than one term. If the party does not deprive them of the chance of running again, voters often reject those they have elected in the previous election. This is what is called individual anti-incumbency. Individual anti-incumbency runs low in Nagaland, where frequently more than half of the incumbent MLAs get re-elected. The figures show however that once an MLA loses the election, they generally do not come back. This year, only 34.5% of the MLAs are first-time legislators. This picture does not really fit with the data on party performance, which reveals much variation. This is also attested by the high number of seats that change hands between two elections. In 2018, voters elected a candidate from a different party than in 2013 in 70% of the seats. This is a huge turnover and an indication that parties find it very hard to build stable local strongholds in Nagaland. Nagaland is a peculiar case since parties tend to come and go frequently between elections. Over the years, many parties have been splitting and merging on a regular basis. Many parties have also disappeared after having fought one or two elections. How do we explain the relative stability of the political class in Nagaland? Partly by the presence of many turncoats – candidates who switched party affiliation between two elections. On average, close to a quarter of candidates in any given election change party affiliation. This year, the Congress saw massive desertion in its ranks. Twenty Congress candidates shifted to other parties (nine went to the Naga People’s Front, four to the Nationalist Democratic People’s Party and two to the BJP). Fifty-three candidates in all shifted their allegiance before the 2018 elections. Most of them came from the Congress (20) and the Naga People’s Front (21). Four candidates deserted the BJP to run under four different party affiliations. Most turncoats went to the Naga People’s Front (11, including nine from the Congress alone). The Nationalist Democratic People’s Party fielded 18 turncoats, mostly from the Naga People’s Front (12). The BJP fielded nine turncoats, including three MLAs from the Nationalist Congress Party. No one turned to the Congress. It is always hard to assess whether party appeal or candidate appeal predominates in the determination of voters’ electoral choices. In the case of Nagaland, we see a lot of party-level volatility and lesser volatility at the candidate level, which indicates that candidates do matter and that they are not simple standard-bearers for their party. The performance of these turncoat candidates, however, is not great. In 2018, 40% of all turncoats won their seat, against 30.6% in 2013. Regardless of the fragmentation of the political space, turncoat performance does increase over time, at least in recent elections. As in other North Eastern states, the None Of The Above option or NOTA finds no takers. The NOTA scores exceed 1% in only eight seats. It is rejected as an option everywhere else. There are several reasons for this lack of appeal of the right to reject. The first, obvious, one is that few voters want to reject any candidate or party. Most voters want their vote to count and therefore are reluctant to waste it by considering the act of voting as an act of protest. Disgruntled voters – and there are a great many of them – would rather punish a candidate or a party by voting for someone else, rather than for no one at all. Another reason is that voters also want their vote to be counted. In the current system, NOTA votes are treated as invalid votes. That means that they are not even included in the candidates and parties’ vote share calculation. Finally, the greatest continuity in Nagaland politics is the absence of women in the legislature. Since its first election in 1964, Nagaland has not sent a single woman to its legislature. Only 21 women have contested elections in Nagaland since the creation of the state, half of them as independents. In 2018, there were only five women contestants out of 251 candidates (two were fielded by National People’s Party, one by the BJP and the Nationalist Democratic People’s Party, and one ran as an independent). The absolute unwillingness of parties to field women candidates blocks any chance for voters to express their eventual preference for women candidates. The 2018 Nagaland election data reveals that it is possible to have great political churning while having stable trends at the candidate level. Like in Tripura, the Congress has disappeared from the stage, having been massively rejected by voters. It only survives through the six Congress turncoats who succeeded in winning their seats. The BJP-Nationalist Democratic People’s Party alliance matched the performance of the incumbent Naga People’s Front government, both in terms of votes and seats. The strategy clearly paid off and the alliance succeeded in presenting itself as the main Opposition to the party in power. There is a clear pattern between these three north eastern elections. All governments suffered from some amount of anti-incumbency, and the BJP succeeded either on its own, as in Tripura, or in an alliance, as in Nagaland. In Meghalaya, it succeeded in becoming the architect of a non-Congress alliance of regional parties, despite having won only two seats. This is not the place to explain exactly how the BJP pulled that performance off. One can cite the strategy of a continuous ground presence that the BJP adopted very early on, its ability to mobilise a vast organisation of party workers, the back-up of the Rashtriya Swayamsevak Sangh on the ground, and a discourse that effectively portrayed its opponents as outdated and lacking credibility. In all three elections, the Congress greatly helped by letting the space open to BJP, by neglecting the North East between elections and by showing contempt to voters in the North East by not even trying to garner their votes. The collapse of the Congress in all three states created a space that the BJP could occupy. Ironically, the BJP showed how real Opposition work is done, while having no prior strength in those states. The Congress will do well to take cue from it. The Trivedi Centre for Political Election team is led by Gilles Verniers, Assistant Professor of Political Science at Ashoka University and co-director, TCPD. Basim-U-Nissa, Mohit Kumar, Ashish Ranjan and Sudesh Kumar have contributed to the data. Raw data available at http://lokdhaba.ashoka.edu.in.
english
Paris Saint Germain (PSG) are miles ahead in the race for the Ligue 1 title, 12 points clear of second-placed Marseille with only eight games left to play. Meanwhile, a former Argentina coach has said that Lionel Messi might not be the best version of himself at the FIFA World Cup in Qatar later this year. Elsewhere, the Parisians are planning a contract renewal for Marco Verratti. On that note, here's a look at the key PSG transfer stories as on 7th April 2022: Former Argentina national team trainer Fernando Signorini believes Lionel Messi might not be at his best in the Qatar World Cup. The 34-year-old has cut a sorry figure at PSG since joining the Ligue 1 giants from Barcelona last summer. The seven-time Ballon d’Or winner has fallen short of expectations and has looked a shadow of his former self at the moment. Nevertheless, Messi will be leading La Albicelete’s FIFA World Cup challenge this winter. The 34-year-old’s presence in the team makes his nation among the contenders for the coveted trophy. Messi played the 2014 final of the competition, which Argentina lost to Germany by a solitary goal. However, speaking to La Nacion, Signorini said that the current Argentina team doesn’t entice him. “The football of before was different and better. I prefer not to be hypocritical and, to be honest: this Argentine team does not excite me. There are no national teams that excite me,” said Signorini. “I have seen a totally different football because society was different. I don’t see flashes of art that I’ve seen in the past. Football from before was different and better. We are not going to see it anymore,” said Signorini. Signorini added that Messi is past his prime. “We are seeing an expected version of Messi. Without a doubt, we will not see the best version of Messi in Qatar, just as Diego did not arrive in the best version of him in 1994. In that, physical conditions are decisive, and especially in high competition,” said Signorini. Messi has scored just eight goals across competitions for the Parisians this season. PSG are planning to renew Marco Verratti’s contract this year, according to PSG Talk via France Bleu. The Italian has been an indispensable part of the Ligue 1 giants and has attracted attention from clubs around Europe. The Parisians are eager to bolster their midfield at the end of the season. However, Verratti continues to be in their plans for the future. The Italian is tied to the French giants till the summer of 2024. However, the club are unwilling to take any chances and could hand him a new deal as soon as the Ligue 1 title is secured. PSG are interested in Salernitana midfielder Ederson, according to PSG Talk via La Gazzetta dello Sport. The Brazilian has earned rave reviews with a string of impressive performances for the Serie A team. The Parisians are looking to reinforce their midfield this summer and have Ederson on their wishlist. The 22-year-old’s contract runs till 2026, and he is likely to cost €26 million. Ederson has been a workhorse in midfield for Salernitana and is averaging 1. 7 tackles per game in the league. He joined the Serie A team in January and has appeared seven times this year.
english
# 6.00 Problem Set 2 # # Hangman # Name : Solutions # Collaborators : <your collaborators> # Time spent : <total time> # ----------------------------------- # Helper code # You don't need to understand this helper code, # but you will have to know how to use the functions import random import string WORDLIST_FILENAME = "words.txt" def load_words(): """ Returns a list of valid words. Words are strings of lowercase letters. Depending on the size of the word list, this function may take a while to finish. """ print "Loading word list from file..." # inFile: file inFile = open(WORDLIST_FILENAME, 'r', 0) # line: string line = inFile.readline() # wordlist: list of strings wordlist = string.split(line) print " ", len(wordlist), "words loaded." return wordlist def choose_word(wordlist): """ wordlist (list): list of words (strings) Returns a word from wordlist at random """ return random.choice(wordlist) # end of helper code # ----------------------------------- # load the list of words into the wordlist variable # so that it can be accessed from anywhere in the program wordlist = load_words() def partial_word(secret_word, guessed_letters): """ Return the secret_word in user-visible format, with underscores used to replace characters that have not yet been guessed. """ result = '' for letter in secret_word: if letter in guessed_letters: result = result + letter else: result = result + '_' return result def hangman(): """ Runs the hangman game. """ print 'Welcome to the game, Hangman!' secret_word = choose_word(wordlist) print 'I am thinking of a word that is ' + str(len(secret_word)) + ' letters long.' num_guesses = 8 word_guessed = False guessed_letters = '' available_letters = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n', 'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x', 'y', 'z'] # Letter-guessing loop. Ask the user to guess a letter and respond to the # user based on whether the word has yet been correctly guessed. while num_guesses > 0 and not word_guessed: print '-------------' print 'You have ' + str(num_guesses) + ' guesses left.' print 'Available letters: ' + ''.join(available_letters) guess = raw_input('Please guess a letter:') if guess not in available_letters: print 'Oops! You\'ve already guessed that letter: ' + partial_word(secret_word, guessed_letters) elif guess not in secret_word: num_guesses -= 1 available_letters.remove(guess) print 'Oops! That letter is not in my word: ' + partial_word(secret_word, guessed_letters) else: available_letters.remove(guess) guessed_letters += guess print 'Good guess: ' + partial_word(secret_word, guessed_letters) if secret_word == partial_word(secret_word, guessed_letters): word_guessed = True if word_guessed: print 'Congratulations, you won!' else: print 'Game over.'
python
<filename>Properties/launchSettings.json { "profiles": { "PackedPrettier": { "commandName": "Project", "commandLineArgs": "--write \"D:\\PackedPrettier\\pack.sh\" --plugin \"<NodeModulesPath>/prettier-plugin-sh\"" } } }
json
<gh_stars>0 // Copyright 2022 @nepoche/ // SPDX-License-Identifier: Apache-2.0 import BigNumber from 'bignumber.js'; import { Codec } from '@polkadot/types/types'; /** * @constant * @type {(0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8)} * @description * | Value | Property | Description | * | 0 | ROUND_UP | Rounds away from zero | * | 1 | ROUND_DOWN | Rounds towards zero | * | 2 | ROUND_CEIL | Rounds towards Infinity | * | 3 | ROUND_FLOOR | Rounds towards -Infinity | * | 4 | ROUND_HALF_UP | Rounds towards nearest neighbour, If equidistant, rounds away form zero | * | 5 | ROUND_HALF_DOWN | Rounds towards nearest neighbour, If equidistant, rounds towards zero | * | 6 | ROUND_HALF_EVEN | Rounds towards nearest neighbour, If equidistant, rounds towards even zero | * | 7 | ROUND_HALF_CEIL | Rounds towards nearest neighbour, If equidistant, rounds towards Infinity | * | 8 | ROUND_HALF_FLOOR | Rounds towards nearest neighbour, If equidistant, rounds towards -Infinity | */ export type ROUND_MODE = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8; type NumLike = number | string; /** * @class Fixed18 * @description fixed point mathematical operation support with 18 decimals */ export class Fixed18 { private inner: BigNumber; /** * @constant * @description precision to 18 decimals */ static PRECISION = 10 ** 18; /** * @constant * @description zero */ static ZERO = Fixed18.fromNatural(0); /** * @description constructor of Fixed18 * @param {(number | string | BigNumber)} origin - the origin number */ constructor (origin: NumLike | BigNumber) { if (origin instanceof BigNumber) { this.inner = origin; } else { this.inner = new BigNumber(origin || 0); } return this; } /** * @name getInner * @description get the inner BigNumber value */ public getInner (): BigNumber { return this.inner; } /** * @name toString * @description format real number(division by precision) to string * @param {number} [dp=6] - decimal places deafult is 6 * @param {number} [rm=3] - round modle, default is ROUND_FLOOR */ public toString (dp = 6, rm: ROUND_MODE = 3): string { let result = this.inner.div(Fixed18.PRECISION); result = result.decimalPlaces(dp, rm); return result.toString(); } /** * @name toFixed * @description format real number string(division by precision) to string * @param {number} [dp=6] - decimal places deafult is 6 * @param {number} [rm=3] - round modle, default is ROUND_FLOOR */ public toFixed (dp = 6, rm: ROUND_MODE = 3): string { let result = this.inner.div(Fixed18.PRECISION); result = result.decimalPlaces(dp, rm); return result.toFixed(); } /** * @name innerToString * @description format inner BigNumber value to string * @param {number} [dp=0] - decimal places deafult is 0 * @param {number} [rm=3] - round modle, default is ROUND_FLOOR */ public innerToString (dp = 0, rm: ROUND_MODE = 3): string { // return 0 if the value is Infinity, -Infinity and NaN if (!this.isFinity()) { return '0'; } return this.inner.decimalPlaces(dp, rm).toFixed(); } /** * @name innerToNumber * @description format inner BigNumber value to string * @param {number} [dp=0] - decimal places deafult is 0 * @param {number} [rm=3] - round modle, default is ROUND_FLOOR */ public innerToNumber (dp = 0, rm: ROUND_MODE = 3): number { // return 0 if the value is Infinity, -Infinity and NaN if (!this.isFinity()) { return 0; } return this.inner.decimalPlaces(dp, rm).toNumber(); } /** * @name toNumber * @description format real number(division by precision) to number * @param {number} [dp=6] - decimal places deafult is 6 * @param {number} [rm=3] - round modle, default is ROUND_FLOOR */ public toNumber (dp = 6, rm: ROUND_MODE = 3): number { let result = this.inner.div(Fixed18.PRECISION); result = result.decimalPlaces(dp, rm); return result.toNumber(); } /** * @name deciminalPlaces * @description returns a Fixed18 whose value is the value of this Fixed18 rounded by rounding mode roundingMode to a maximum of decimalPlaces decimal places. * @param {number} [dp=18] - decimal places * @param {number} [rm=3] - round modle, default is ROUND_FLOOR */ public decimalPlaces (dp = 18, rm: ROUND_MODE = 3): Fixed18 { return Fixed18.fromNatural(this.toNumber(dp, rm)); } /** * @name fromNatural * @description get Fixed18 from real number, will multiply by precision * @param {(string | number)} target - target number */ static fromNatural (target: NumLike): Fixed18 { return new Fixed18(new BigNumber(target).times(Fixed18.PRECISION)); } /** * @name fromParts * @description get Fixed18 from real number, will not multiply by precision * @param {(string | number)} parts - parts number */ static fromParts (parts: NumLike): Fixed18 { return new Fixed18(parts); } /** * @name formRational * @param {(string | number)} n - numerator * @param {(string | number)} d - denominator */ static fromRational (n: NumLike, d: NumLike): Fixed18 { const _n = new BigNumber(n); const _d = new BigNumber(d); return new Fixed18(_n.times(Fixed18.PRECISION).div(_d).decimalPlaces(0, 3)); } /** * @name add * @description fixed-point addition operator * @param {Fixed18} target - target number */ public add (target: Fixed18): Fixed18 { return new Fixed18(this.inner.plus(target.inner).decimalPlaces(0, 3)); } /** * @name sub * @description fixed-point subtraction operator * @param {Fixed18} target - target number */ public sub (target: Fixed18): Fixed18 { return new Fixed18(this.inner.minus(target.inner).decimalPlaces(0, 3)); } /** * @name mul * @description fixed-point multiplication operator * @param {Fixed18} target - target number */ public mul (target: Fixed18): Fixed18 { const inner = this.inner.times(target.inner).div(Fixed18.PRECISION).decimalPlaces(0, 3); return new Fixed18(inner); } /** * @name div * @description fixed-point divided operator * @param {Fixed18} target - target number */ public div (target: Fixed18): Fixed18 { const inner = this.inner.div(target.inner).times(Fixed18.PRECISION).decimalPlaces(0, 3); return new Fixed18(inner); } /** * @name isLessThan * @description return true if the value is less than the target value * @param {Fixed18} target - target number */ public isLessThan (target: Fixed18): boolean { return this.inner.isLessThan(target.inner); } /** * @name isGreaterThan * @description return true if the value is greater than the target value * @param {Fixed18} target - target number */ public isGreaterThan (target: Fixed18): boolean { return this.inner.isGreaterThan(target.inner); } /** * @name isEqualTo * @description return true if the values are equal * @param {Fixed18} target - target number */ public isEqualTo (target: Fixed18): boolean { return this.inner.isEqualTo(target.inner); } /** * @name max * @description return the max value * @param {...Fixed18} target - target numbers */ public max (...targets: Fixed18[]): Fixed18 { return new Fixed18(BigNumber.max.apply(null, [this.inner, ...targets.map((i) => i.inner)])); } /** * @name min * @description return the min value * @param {...Fixed18} target - target numbers */ public min (...targets: Fixed18[]): Fixed18 { return new Fixed18(BigNumber.min.apply(null, [this.inner, ...targets.map((i) => i.inner)])); } /** * @name nagated * @description return the nageted value */ public negated (): Fixed18 { return new Fixed18(this.inner.negated()); } /** * @name isZero * @description return true if the value of inner is 0 */ public isZero (): boolean { return this.inner.isZero(); } /** * @name isNaN * @description return true if the value of inner is NaN */ public isNaN (): boolean { return this.inner.isNaN(); } /** * @name isFinity * @description return true if the value of inner is finity, only return false when the value is NaN, -Infinity or Infinity. */ public isFinity (): boolean { return this.inner.isFinite(); } } // force to Fixed18 export function convertToFixed18 (data: Codec | number | Fixed18): Fixed18 { if (data instanceof Fixed18) { return data; } else if (typeof data === 'number') { return Fixed18.fromNatural(data); } if ('toString' in data) { return Fixed18.fromParts(data.toString()); // for Codec } return Fixed18.ZERO; }
typescript
<reponame>anvithks/qa { "xmlCreateLifecycle": "<LifecycleConfiguration xmlns=\"http://s3.amazonaws.com/doc/2006-03-01/\">\n<Rule><ID>abcc</ID><Filter>\n<Prefix></Prefix></Filter>\n<Status>Disabled</Status>\n<Transition>\n<StorageClass>STANDARD_IA</StorageClass>\n<Days>30</Days>\n<Backend></Backend></Transition>\n<Transition>\n<StorageClass>GLACIER</StorageClass>\n<Days>60</Days>\n<Backend></Backend>\n</Transition>\n<Expiration>\n<Days>61</Days>\n</Expiration>\n<AbortIncompleteMultipartUpload>\n<DaysAfterInitiation>7</DaysAfterInitiation>\n</AbortIncompleteMultipartUpload></Rule></LifecycleConfiguration>\n", "xmlCreateLifecycleSameRule": "<LifecycleConfiguration xmlns=\"http://s3.amazonaws.com/doc/2006-03-01/\">\n<Rule><ID>abcc</ID><Filter>\n<Prefix></Prefix></Filter>\n<Status>Disabled</Status>\n<Transition>\n<StorageClass>STANDARD_IA</StorageClass>\n<Days>30</Days>\n<Backend></Backend></Transition>\n<Transition>\n<StorageClass>GLACIER</StorageClass>\n<Days>60</Days>\n<Backend></Backend>\n</Transition>\n<Expiration>\n<Days>61</Days>\n</Expiration>\n<AbortIncompleteMultipartUpload>\n<DaysAfterInitiation>7</DaysAfterInitiation>\n</AbortIncompleteMultipartUpload></Rule></LifecycleConfiguration>\n", "xmlCreateLifecycleWithoutName": "<LifecycleConfiguration xmlns=\"http://s3.amazonaws.com/doc/2006-03-01/\">\n<Rule><ID></ID><Filter>\n<Prefix></Prefix></Filter>\n<Status>Disabled</Status>\n<Transition>\n<StorageClass>STANDARD_IA</StorageClass>\n<Days>30</Days>\n<Backend></Backend></Transition>\n<Transition>\n<StorageClass>GLACIER</StorageClass>\n<Days>60</Days>\n<Backend></Backend>\n</Transition>\n<Expiration>\n<Days>61</Days>\n</Expiration>\n<AbortIncompleteMultipartUpload>\n<DaysAfterInitiation>7</DaysAfterInitiation>\n</AbortIncompleteMultipartUpload></Rule></LifecycleConfiguration>\n", "xmlCreateLifecycleWithoutExpiration": "<LifecycleConfiguration xmlns=\"http://s3.amazonaws.com/doc/2006-03-01/\">\n<Rule><ID></ID><Filter>\n<Prefix></Prefix></Filter>\n<Status>Disabled</Status>\n<Transition>\n<StorageClass>STANDARD_IA</StorageClass>\n<Days>30</Days>\n<Backend></Backend></Transition>\n<Transition>\n<StorageClass>GLACIER</StorageClass>\n<Days>60</Days>\n<Backend></Backend>\n</Transition>\n<AbortIncompleteMultipartUpload>\n<DaysAfterInitiation>7</DaysAfterInitiation>\n</AbortIncompleteMultipartUpload></Rule></LifecycleConfiguration>\n", "xmlCreateLifecycleWithoutExpirationTransition": "<LifecycleConfiguration xmlns=\"http://s3.amazonaws.com/doc/2006-03-01/\">\n<Rule><ID></ID><Filter>\n<Prefix></Prefix></Filter>\n<Status>Disabled</Status>\n<AbortIncompleteMultipartUpload>\n<DaysAfterInitiation>7</DaysAfterInitiation>\n</AbortIncompleteMultipartUpload></Rule></LifecycleConfiguration>\n", "xmlCreateLifecycleExtendedDays": "<LifecycleConfiguration xmlns=\"http://s3.amazonaws.com/doc/2006-03-01/\">\n<Rule><ID>abcc</ID><Filter>\n<Prefix></Prefix></Filter>\n<Status>Disabled</Status>\n<Transition>\n<StorageClass>STANDARD_IA</StorageClass>\n<Days>100</Days>\n<Backend></Backend></Transition>\n<Transition>\n<StorageClass>GLACIER</StorageClass>\n<Days>60</Days>\n<Backend></Backend>\n</Transition>\n<Expiration>\n<Days>61</Days>\n</Expiration>\n<AbortIncompleteMultipartUpload>\n<DaysAfterInitiation>7</DaysAfterInitiation>\n</AbortIncompleteMultipartUpload></Rule></LifecycleConfiguration>\n", "xmlCreateLifecycleLessDays": "<LifecycleConfiguration xmlns=\"http://s3.amazonaws.com/doc/2006-03-01/\">\n<Rule><ID>abcc</ID><Filter>\n<Prefix></Prefix></Filter>\n<Status>Disabled</Status>\n<Transition>\n<StorageClass>STANDARD_IA</StorageClass>\n<Days>20</Days>\n<Backend></Backend></Transition>\n<Transition>\n<StorageClass>GLACIER</StorageClass>\n<Days>60</Days>\n<Backend></Backend>\n</Transition>\n<Expiration>\n<Days>61</Days>\n</Expiration>\n<AbortIncompleteMultipartUpload>\n<DaysAfterInitiation>7</DaysAfterInitiation>\n</AbortIncompleteMultipartUpload></Rule></LifecycleConfiguration>\n" }
json
<filename>python/DC2_Classifier.py """ @brief DC2 version of Python code for parsing ROOT TCuts and partitioning Gleam events into event classes. @author <NAME> <<EMAIL>> """ # # $Header: /nfs/slac/g/glast/ground/cvs/fitsGen/python/DC2_Classifier.py,v 1.3 2006/12/11 19:09:51 jchiang Exp $ # from EventClassifier import EventClassifier meritVariables = """ Tkr1FirstLayer CTBCORE CTBGAM CTBBestEnergyProb """.split() # # DC2 Event class cuts. Note that the ordering ensures that class A # events are assigned first, so that class B events need only be # defined by their looser lower limits. Defining the cuts using an # order from more to less restrictive also helps ensure that the # events are properly partitioned. # eventClassCuts = ["CTBCORE > 0.35 && CTBBestEnergyProb > 0.35 && " + " CTBGAM > 0.50 && Tkr1FirstLayer > 5.5", "CTBCORE > 0.35 && CTBBestEnergyProb > 0.35 && " + " CTBGAM > 0.50 && Tkr1FirstLayer < 5.5", "CTBCORE > 0.1 && CTBBestEnergyProb > 0.3 && " + " CTBGAM > 0.35 && Tkr1FirstLayer > 5.5", "CTBCORE > 0.1 && CTBBestEnergyProb > 0.3 && " + " CTBGAM > 0.35 && Tkr1FirstLayer < 5.5"] eventClassifier = EventClassifier(eventClassCuts)
python
<gh_stars>1-10 import React from 'react'; import './Technology.css'; import data from './data.json'; import { useState, useEffect } from 'react'; export default function Technology() { const [Name, setName] = useState(data.technology[0].name); const [description, setdescription] = useState(data.technology[0].description); const [dataActive, setdataActive] = useState("Launch vehicle"); useEffect(() => { if(Name === "Launch vehicle") { setdataActive("Launch vehicle") } else if(Name === "Spaceport") { setdataActive("Spaceport"); } else if(Name === "Space capsule") { setdataActive("Space capsule"); } }) return ( <div className='Technology'> <div className="Hero"> <h1><span>03</span>Space launch 101</h1> <div className='img' data-image={ dataActive }></div> </div> <ul> <li data-active={(dataActive === "Launch vehicle") ? 'true' : 'false'} onClick={() => { setName(data.technology[0].name); setdescription(data.technology[0].description); }}>1</li> <li data-active={(dataActive === "Spaceport") ? 'true' : 'false'} onClick={() => { setName(data.technology[1].name); setdescription(data.technology[1].description); }}>2</li> <li data-active={(dataActive === "Space capsule") ? 'true' : 'false'} onClick={() => { setName(data.technology[2].name); setdescription(data.technology[2].description); }}>3</li> </ul> <div className="Content"> <div className="Name"> <p>The terminology...</p> <h1>{ Name }</h1> </div> <p>{ description }</p> </div> </div> ); }
javascript
var searchData= [ ['suspending_20and_20resuming_20blt_2fulp',['Suspending and resuming BLT/ULP',['../group__ULP-2-suspension.html',1,'']]] ];
javascript
declare var RxQ: RxQStatic; declare module 'rxq' { export = RxQ; } interface RxQStatic { qixVersion: string; version: string; connectEngine(config: any, temp: any): GlobalObservable; connectQRS(config: any, temp: any): GlobalObservable; } interface AppObservable { constructor(source: any, temp: any); /** * Aborts any selection mode in an app. * @param {boolean} qAccept - Set this parameter to true to accept the selections before exiting the selection mode. */ qAbortModal(qAccept: boolean): any; /** * Adds an alternate state in the app. * @param {string} qStateName - Name of the alternate state. */ qAddAlternateState(qStateName: string): any; /** * Adds a field on the fly. * @param {string} qName - Name of the field. * @param {string} qExpr - Expression value. */ qAddFieldFromExpression(qName: string, qExpr: string): any; qAppLayouts(): any; /** * Applies a bookmark * @param {string} qId - Identifier of the bookmark. */ qApplyBookmark(qId: string): any; /** * Loads the last logical operation (if any). */ qBack(): any; /** * Returns the number of entries on the Back stack. */ qBackCount(): any; /** * Checks if a given expression is valid. * @param {string} qExpr - Expression to check. * @param {string[]} [qLabels] - List of labels. */ qCheckExpression(qExpr: string, qLabels?: string[]): any; /** * Checks if: * - a given expression is valid. * - a number is correct according to the locale. * @param {string} qExpr - Expression to check. */ qCheckNumberOrExpression(qExpr: string): any; /** * Checks the syntax of a script. */ qCheckScriptSyntax(): any; /** * Clears all selections in all fields of the current app. * @param {boolean} [qLockedAlso] - Set this parameter to true to clear all selections including the locked fields. * @param {string} [qStateName] - Name of the alternate state. */ qClearAll(qLockedAlso?: boolean, qStateName?: string): any; /** * Clears entirely the undo and redo buffer. */ qClearUndoBuffer(): any; /** * Clones a bookmark. * @param {string} qId - Identifier of the object to clone. */ qCloneBookmark(qId: string): any; /** * Clones a dimension * @param {string} qId - Identifier of the object to clone. */ qCloneDimension(qId: string): any; /** * Clones a measure * @param {string} qId - Identifier of the object to clone. */ qCloneMeasure(qId: string): any; /** * Clones any visualizations, sheets and stories. * @param {string} qId - Identifier of the object to clone. */ qCloneObject(qId: string): any; /** * Commits the draft of an object that was previously created by invoking the CreateDraft method. * @param {string} qId - Identifier of the draft to commit. */ qCommitDraft(qId: string): any; /** * Creates a bookmark. * @param {GenericBookmarkProperties} qProp - Information about the object. */ qCreateBookmark(qProp: GenericBookmarkProperties): GenericBookmarkObservable; /** * Creates a connection. A connection indicates from which data source, the data should be taken. * @param {Connection} qConnection - Information about the connection. */ qCreateConnection(qConnection: Connection): any; /** * Creates a master dimension. * @param {GenericDimensionProperties} qProp - Information about the properties. */ qCreateDimension(qProp: GenericDimensionProperties): GenericDimensionObservable; /** * Creates a drafs of an object. * @param {String} qId - Identifier of the object to create a draft from. */ qCreateDraft(qId: string): any; /** * Creates a master measure. * @param {GenericMeasureProperties} qProp - Information about the properties. */ qCreateMeasure(qProp: GenericMeasureProperties): GenericMeasureObservable; /** * Creates a generic object at app level. * @param {GenericObjectProperties} qProp - Information about the object. */ qCreateObject(qProp: GenericObjectProperties): GenericObjectObservable; /** * Creates a transient object. * @param {GenericObjectProperties} qProp - Information about the object. */ qCreateSessionObject(qProp: GenericObjectProperties): GenericObjectObservable; qCreateSessionVariable(...args: any[]): GenericVariableObservable; qCreateVariable(...args: any[]): GenericVariableObservable; qCreateVariableEx(...args: any[]): any; qDeleteConnection(...args: any[]): any; qDestroyBookmark(...args: any[]): any; qDestroyDimension(...args: any[]): any; qDestroyDraft(...args: any[]): any; qDestroyMeasure(...args: any[]): any; qDestroyObject(...args: any[]): any; qDestroySessionObject(...args: any[]): any; qDestroySessionVariable(...args: any[]): any; qDestroyVariableById(...args: any[]): any; qDestroyVariableByName(...args: any[]): any; qDoReload(...args: any[]): any; qDoReloadEx(...args: any[]): any; qDoSave(...args: any[]): any; qEvaluate(...args: any[]): any; qEvaluateEx(...args: any[]): any; qFindMatchingFields(...args: any[]): any; qForward(...args: any[]): any; qForwardCount(...args: any[]): any; qGetAllInfos(...args: any[]): any; qGetAppLayout(...args: any[]): any; qGetAppProperties(...args: any[]): any; qGetAssociationScores(...args: any[]): any; qGetBookmark(...args: any[]): any; qGetConnection(...args: any[]): any; qGetConnections(...args: any[]): any; qGetContentLibraries(...args: any[]): any; qGetDatabaseInfo(...args: any[]): any; qGetDatabaseOwners(...args: any[]): any; qGetDatabaseTableFields(...args: any[]): any; qGetDatabaseTablePreview(...args: any[]): any; qGetDatabaseTables(...args: any[]): any; qGetDatabases(...args: any[]): any; qGetDimension(...args: any[]): any; qGetEmptyScript(...args: any[]): any; qGetFavoriteVariables(...args: any[]): any; qGetField(...args: any[]): any; qGetFieldDescription(...args: any[]): any; qGetFileTableFields(...args: any[]): any; qGetFileTablePreview(...args: any[]): any; qGetFileTables(...args: any[]): any; qGetFileTablesEx(...args: any[]): any; qGetFolderItemsForConnection(...args: any[]): any; qGetIncludeFileContent(...args: any[]): any; qGetLibraryContent(...args: any[]): any; qGetLocaleInfo(...args: any[]): any; qGetLooselyCoupledVector(...args: any[]): any; qGetMatchingFields(...args: any[]): any; qGetMeasure(...args: any[]): any; qGetMediaList(...args: any[]): any; qGetObject(...args: any[]): any; qGetScript(...args: any[]): any; qGetScriptBreakpoints(...args: any[]): any; qGetTableData(...args: any[]): any; qGetTablesAndKeys(...args: any[]): any; qGetTextMacros(...args: any[]): any; qGetVariable(...args: any[]): any; qGetVariableById(...args: any[]): any; qGetVariableByName(...args: any[]): any; qGetViewDlgSaveInfo(...args: any[]): any; qGuessFileType(...args: any[]): any; qLockAll(...args: any[]): any; qMigrateDerivedFields(...args: any[]): any; qMigrateVariables(...args: any[]): any; qModifyConnection(...args: any[]): any; qPublish(...args: any[]): any; qRedo(...args: any[]): any; qReduceData(...args: any[]): any; qRemoveAllData(...args: any[]): any; qRemoveAlternateState(...args: any[]): any; qRemoveVariable(...args: any[]): any; qResume(...args: any[]): any; qSaveObjects(...args: any[]): any; qScramble(...args: any[]): any; qSearchAssociations(...args: any[]): any; qSearchObjects(...args: any[]): any; qSearchResults(...args: any[]): any; qSearchSuggest(...args: any[]): any; qSelectAssociations(...args: any[]): any; qSendGenericCommandToCustomConnector(...args: any[]): any; qSetAppProperties(...args: any[]): any; qSetFavoriteVariables(...args: any[]): any; qSetFetchLimit(...args: any[]): any; qSetLooselyCoupledVector(...args: any[]): any; qSetScript(...args: any[]): any; qSetScriptBreakpoints(...args: any[]): any; qSetViewDlgSaveInfo(...args: any[]): any; qUnPublish(...args: any[]): any; qUndo(...args: any[]): any; qUnlockAll(...args: any[]): any; } interface FieldObservable { constructor(source: any, temp: any); qClear(...args: any[]): any; qClearAllButThis(...args: any[]): any; qGetAndMode(...args: any[]): any; qGetCardinal(...args: any[]): any; qGetNxProperties(...args: any[]): any; qLock(...args: any[]): any; qLowLevelSelect(...args: any[]): any; qProperties(): any; qSelect(...args: any[]): any; qSelectAll(...args: any[]): any; qSelectAlternative(...args: any[]): any; qSelectExcluded(...args: any[]): any; qSelectPossible(...args: any[]): any; qSelectValues(...args: any[]): any; qSetAndMode(...args: any[]): any; qSetNxProperties(...args: any[]): any; qToggleSelect(...args: any[]): any; qUnlock(...args: any[]): any; } interface GenericBookmarkObservable { constructor(source: any, temp: any); qApply(...args: any[]): any; qApplyPatches(...args: any[]): any; qGetFieldValues(...args: any[]): any; qGetInfo(...args: any[]): any; qGetLayout(...args: any[]): any; qGetProperties(...args: any[]): any; qLayouts(): any; qPublish(...args: any[]): any; qSetProperties(...args: any[]): any; qUnPublish(...args: any[]): any; } interface GenericDimensionObservable { constructor(source: any, temp: any); qApplyPatches(...args: any[]): any; qGetDimension(...args: any[]): any; qGetInfo(...args: any[]): any; qGetLayout(...args: any[]): any; qGetLinkedObjects(...args: any[]): any; qGetProperties(...args: any[]): any; qLayouts(): any; qPublish(...args: any[]): any; qSetProperties(...args: any[]): any; qUnPublish(...args: any[]): any; } interface GenericMeasureObservable { constructor(source: any, temp: any); qApplyPatches(...args: any[]): any; qGetInfo(...args: any[]): any; qGetLayout(...args: any[]): any; qGetLinkedObjects(...args: any[]): any; qGetMeasure(...args: any[]): any; qGetProperties(...args: any[]): any; qLayouts(): any; qPublish(...args: any[]): any; qSetProperties(...args: any[]): any; qUnPublish(...args: any[]): any; } interface GenericObjectObservable { constructor(source: any, temp: any); qAbortListObjectSearch(...args: any[]): any; qAcceptListObjectSearch(...args: any[]): any; qApplyPatches(...args: any[]): any; qBeginSelections(...args: any[]): any; qClearSelections(...args: any[]): any; qClearSoftPatches(...args: any[]): any; qCollapseLeft(...args: any[]): any; qCollapseTop(...args: any[]): any; qCopyFrom(...args: any[]): any; qCreateChild(...args: any[]): any; qDestroyAllChildren(...args: any[]): any; qDestroyChild(...args: any[]): any; qDrillUp(...args: any[]): any; qEmbedSnapshotObject(...args: any[]): any; qEndSelections(...args: any[]): any; qExpandLeft(...args: any[]): any; qExpandTop(...args: any[]): any; qExportData(...args: any[]): any; qGetChild(...args: any[]): any; qGetChildInfos(...args: any[]): any; qGetEffectiveProperties(...args: any[]): any; qGetFullPropertyTree(...args: any[]): any; qGetHyperCubeBinnedData(...args: any[]): any; qGetHyperCubeContinuousData(...args: any[]): any; qGetHyperCubeData(...args: any[]): any; qGetHyperCubePivotData(...args: any[]): any; qGetHyperCubeReducedData(...args: any[]): any; qGetHyperCubeStackData(...args: any[]): any; qGetInfo(...args: any[]): any; qGetLayout(...args: any[]): any; qGetLinkedObjects(...args: any[]): any; qGetListObjectData(...args: any[]): any; qGetProperties(...args: any[]): any; qGetSnapshotObject(...args: any[]): any; qLayouts(): any; qLock(...args: any[]): any; qMultiRangeSelectHyperCubeValues(...args: any[]): any; qPublish(...args: any[]): any; qRangeSelectHyperCubeValues(...args: any[]): any; qResetMadeSelections(...args: any[]): any; qSearchListObjectFor(...args: any[]): any; qSelectHyperCubeCells(...args: any[]): any; qSelectHyperCubeContinuousRange(...args: any[]): any; qSelectHyperCubeValues(...args: any[]): any; qSelectListObjectAll(...args: any[]): any; qSelectListObjectAlternative(...args: any[]): any; qSelectListObjectContinuousRange(...args: any[]): any; qSelectListObjectExcluded(...args: any[]): any; qSelectListObjectPossible(...args: any[]): any; qSelectListObjectValues(...args: any[]): any; qSelectPivotCells(...args: any[]): any; qSetChildArrayOrder(...args: any[]): any; qSetFullPropertyTree(...args: any[]): any; qSetProperties(...args: any[]): any; qUnPublish(...args: any[]): any; qUnlock(...args: any[]): any; } interface GenericVariableObservable { constructor(source: any, temp: any); qApplyPatches(...args: any[]): any; qGetInfo(...args: any[]): any; qGetLayout(...args: any[]): any; qGetProperties(...args: any[]): any; qLayouts(): any; qSetDualValue(...args: any[]): any; qSetNumValue(...args: any[]): any; qSetProperties(...args: any[]): any; qSetStringValue(...args: any[]): any; } interface GlobalObservable { constructor(source: any, temp: any); qAbortAll(...args: any[]): any; qAbortRequest(...args: any[]): any; qAllowCreateApp(...args: any[]): any; qCancelReload(...args: any[]): any; qCancelRequest(...args: any[]): any; qConfigureReload(...args: any[]): any; qCopyApp(...args: any[]): any; qCreateApp(...args: any[]): any; qCreateDocEx(...args: any[]): any; qCreateSessionApp(...args: any[]): any; qCreateSessionAppFromApp(...args: any[]): any; qDeleteApp(...args: any[]): any; qEngineVersion(...args: any[]): any; qExportApp(...args: any[]): any; qGetActiveDoc(...args: any[]): any; qGetAppEntry(...args: any[]): any; qGetAuthenticatedUser(...args: any[]): any; qGetBNF(...args: any[]): any; qGetConfiguration(...args: any[]): any; qGetCustomConnectors(...args: any[]): any; qGetDatabasesFromConnectionString(...args: any[]): any; qGetDefaultAppFolder(...args: any[]): any; qGetDocList(...args: any[]): any; qGetFolderItemsForPath(...args: any[]): any; qGetFunctions(...args: any[]): any; qGetInteract(...args: any[]): any; qGetLogicalDriveStrings(...args: any[]): any; qGetMyDocumentsFolder(...args: any[]): any; qGetOdbcDsns(...args: any[]): any; qGetOleDbProviders(...args: any[]): any; qGetProgress(...args: any[]): any; qGetStreamList(...args: any[]): any; qGetSupportedCodePages(...args: any[]): any; qGetUniqueID(...args: any[]): any; qImportApp(...args: any[]): any; qImportAppEx(...args: any[]): any; qInteractDone(...args: any[]): any; qIsDesktopMode(...args: any[]): any; qIsPersonalMode(...args: any[]): any; qIsValidConnectionString(...args: any[]): any; qOSName(...args: any[]): any; qOSVersion(...args: any[]): any; qOpenDoc(...args: any[]): any; qProductVersion(...args: any[]): any; qPublishApp(...args: any[]): any; qQTProduct(...args: any[]): any; qQvVersion(...args: any[]): any; qReloadExtensionList(...args: any[]): any; qReplaceAppFromID(...args: any[]): any; qShutdownProcess(...args: any[]): any; qUploadToContentService(...args: any[]): any; } interface VariableObservable { constructor(source: any, temp: any); qForceContent(...args: any[]): any; qGetContent(...args: any[]): any; qGetNxProperties(...args: any[]): any; qGetRawContent(...args: any[]): any; qProperties(): any; qSetContent(...args: any[]): any; qSetNxProperties(...args: any[]): any; } interface Connection { /** * Identifier of the connection. * Is generated by the engine and is unique. */ qId: string; /** * Name of the connection. */ qName: string; /** * One of: * - ODBC CONNECT TO [<provider name>] * - OLEDB CONNECT TO [<provider name>] * - CUSTOM CONNECT TO [<provider name>] * - "<local absolute or relative path,UNC path>" * - "<URL>" * Connection string. */ qConnectionString: string; /** * One of: * - ODBC * - OLEDB * - <Name of the custom connection file> * - folder * - internet * Type of the connection. */ qType: string; /** * Name of the user who creates the connection. */ qUserName: string; /** * Password of the user who creates the connection. */ qPassword: string; /** * Creation date of the connection or last modification date of the connection. */ qModifiedDate: string; /** * Information about the connection. */ qMeta: NxMeta; /** * Select which user credentials to use to connect to the source. * - LOG_ON_SERVICE_USER: Disables * - LOG_ON_CURRENT_USER: Enables */ qLogOn: 'LOG_ON_SERVICE_USER' | 'LOG_ON_CURRENT_USER'; } interface VariableListDef { /** * Type of the list */ qType?: string; /** * Shows the reserved variables if set to true. */ qShowReserved?: boolean; /** * Shows the system variables if set to true. */ qShowConfig?: boolean; /** * Data */ qData?: JSON; } interface ListObjectDef { /** * Name of the alternate state. */ qStateName?: string; /** * Refers to a dimension stored in the library. */ qLibraryId?: string; /** * Refers to a dimension stored in the list object. * TODO */ qDef?: null; /** * Defines the sorting by state. * TODO */ qAutoSortByState?: null; /** * Defines the frequence mode. * TODO */ qFrequencyMode?: any; /** * If set to true, alternative values are allowd in qData. */ qShowAlternatives?: boolean; /** * Fetches an initial data set. * TODO */ qInitialDataFetch?: any; /** * Lists the expression in the list object. * TODO */ qExpressions?: any; } interface HyperCubeDef { /** * Name of the alternate state. */ qStateName?: string; /** * Array of dimensions. * TODO */ qDimensions?: any; /** * Array of measures. * TODO */ qMeasures?: any; /** * Order the columns of the hypercube should be sorted. */ qInterColumnSortOrder?: number[]; /** * Removes zero values. */ qSuppressZero?: boolean; /** * Removes missing values. */ qSuppressMissing?: boolean; /** * Initial data set. * TODO */ qInitialDataFetch?: any; /** * Defines the way the data are handled internally by the engine. * One of: * - S for DATA_MODE_STRAIGHT * - P for DATA_MODE_PIVOT * - K for DATA_MODE_PIVOT_STACK */ qMode?: 'S' | 'P' | 'K'; /** * Number of left dimensions. */ qNoOfLeftDims?: number; /** * If this property is set to true, the cells are always expanded. It implies that it is not possible to collapse any cells. */ qAlwaysFullyExpanded?: boolean; /** * Maximum number of cells for an initial data fetch (set in qInitialDataFetch) when in stacked mode (qMode is K). */ qMaxStackedCells?: number; /** * If this property is set to true, the missing symbols (if any) are replaced by 0 if the value is a numeric and by an empty string if the value is a string. */ qPopulateMissing?: boolean; /** * If set to true, the total (if any) is shown on the first row. */ qShowTotalsAbove?: boolean; /** * This property applies for pivot tables and allows to change the layout of the table. */ qIndentMode?: boolean; /** * Specifies a calculation condition, which must be fulfilled for the hupercube to be (re)calculated. */ qCalcCond?: string; /** * To enable the sorting by ascending or descending order in the values of a measure. * One of: * - -1 for sorting descending * - 0 for no sorting * - 1 for sorting ascending */ qSortbyYValue?: -1 | 0 | 1; } interface MeasureListDef { /** * Type of the list. */ qType?: string; /** * Data. */ qData?: JSON; } interface FieldListDef { /** * Shows the system tables if set to true. */ qShowSystem?: boolean; /** * Shows the hidden fields if set to true. */ qShowHidden?: boolean; /** * Show the semantic fields if set to true. */ qShowSemantic?: boolean; /** * Shows the tables and fields present in the data model viewer if set to true. */ qShowSrcTables?: boolean; /** * Shows the fields defined on the fly if set to true. */ qShowDefinitionOnly?: boolean; /** * Shows the fields and derived fields if set to true. */ qShowDerivedFields?: boolean; /** * Shows the Direct Discovery measure fields if set to true. */ qShowImplicit?: boolean; } interface DimensionListDef { /** * Type of the list. */ qType?: string; /** * Data. */ qData?: JSON; } interface ChildListDef { /** * Data that you want to include in the child list definition. */ qData: JSON; } interface BookmarkListDef { /** * Type of the list. */ qType?: string; /** * Data. */ qData?: JSON; } interface AppObjectListDef { /** * Type of the list. */ qType?: string; /** * Data. */ qData?: JSON; } interface AbstractGenericProperties { /** * Definition of the dynamic properties. */ qVariableListDef?: VariableListDef; qValueExpression?: string; qUndoInfoDef?: any; qStringExpression?: string; qSelectionObjectDef?: any; qMediaListDef?: any; qListObjectDef?: ListObjectDef; qHyperCubeDef?: HyperCubeDef; qMeasureListDef?: MeasureListDef; qFieldListDef?: FieldListDef; qEmbeddedSnapshotDef?: any; qDimensionListDef?: DimensionListDef; qChildListDef?: ChildListDef; qBookmarkListDef?: BookmarkListDef; qAppObjectListDef?: AppObjectListDef; } interface GenericBookmarkProperties extends AbstractGenericProperties { /** * Information about the bookmark. */ qInfo: NxInfo; } interface GenericDimensionProperties extends AbstractGenericProperties { /** * Identifier and type of the dimension. */ qInfo: NxInfo; /** * Definition of the dimension. */ qDim: NxLibraryDimensionDef; } interface GenericMeasureProperties extends AbstractGenericProperties { /** * Information about the measure. */ qInfo: NxInfo; /** * Definition of the measure. */ qDim: NxLibraryMeasureDef; } interface GenericObjectProperties extends AbstractGenericProperties { /** * Identifier and type of the object. */ qInfo: NxInfo; /** * Should be set to create an object that is linked to another object. * Enter the identifier of the linking object (i.e the object you want to link to). */ qExtendsId: string; } interface NxInfo { /** * Identifier of the object. */ qId?: string; /** * Type of the object. */ qType: string; } interface NxLibraryDimensionDef { /** * Information about the grouping; */ qGrouping: 'N' | 'H' | 'C'; /** * Array of dimension names. */ qFieldDefs: string[]; /** * Array of dimension labels. */ qFieldLabels: string[]; } interface NxLibraryMeasureDef { /** * Label of the measure. */ qLabel: string; /** * Definition of the measure. */ qDef: string; /** * Used to define a cyclic group or drill-down group. */ qGrouping: 'N' | 'H' | 'C'; /** * Array of expressions. */ qExpressions: string[]; /** * Index to the active expression in a measure. */ qActiveExpression: number; } interface NxMeta { /** * Name. */ qName: string; }
typescript
# PXSourceList Release Notes ## 2.0.7 - Remove -setFlipped: call which was causing a deprecation warning on OS X 10.10. - Fix whitespace in PXSourceList.m. ## 2.0.6 - Merge PR #49: Fix PXSourceListBadgeCell accessibility. Adds accessibility for PXSourceListBadgeCell when using PXSourceList in view-based mode. ## 2.0.5 - Fix #43: sourceListDeleteKeyPressedOnRows: called twice. This was caused by an issue where PXSourceList was incorrectly removing the old delegate as an observer of PXSourceList notifications in -setDelegate:. ## 2.0.4 - PR #41: fix a Zeroing Weak References problem. This fixes an issue where using an `NSWindow`, `NSWindowController` or `NSViewController` as a PXSourceList delegate or dataSource would cause problems on 10.7 because prior to 10.8, these classes could not be referenced by zeroing weak references. - Remove unused `badgeMargin` constant from PXSourceList.m. ## 2.0.3 - Fix #40: Editing titles on cell based source list causes exception. - Fix issue in view-based source list example where items created with the add button couldn't be dragged. ## 2.0.2 - Fix #39: Badges not drawn correctly when Source List row is selected. ## 2.0.1 - Add missing note to the 2.0.0 release notes about marking `-[PXSourceList delegate]` and `-[PXSourceList dataSource]` as unavailable using \_\_attribute\_\_. ## 2.0.0 ### New Features - Added support for view-based mode to `PXSourceList`, whilst retaining legacy cell-based support. (View-based delegate methods added are detailed below). - Added a new view-based Source List example target which includes an example of how to use drag-and-drop in the Source List. - Added `PXSourceListTableCellView`, an `NSTableCellView` subclass which is useful when using `PXSourceList` in view-based mode. - Added `PXSourceListBadgeView`, which can be used in `PXSourceListTableCellView`s to display badges. This class's drawing is done by the internal `PXSourceListBadgeCell` class. - Added a generic `PXSourceListItem` data source model class which can be used for easily constructing data source models without having to implement your own class. ### API Changes - **Incompatible change.* Marked `-[PXSourceList delegate]` and -[PXSourceList dataSource]` as unavailable using the “unavailable” \_\_attribute\_\_. These methods shouldn’t be used because of the internal implementation of PXSourceList, and have been documented as such since version 0.8. However, adding this \_\_attribute\_\_ is more robust because a compile-time error will be generated if you use either of these methods. - Added view-based Source List delegate methods to `PXSourceListDelegate`, namely: - `-sourceList:viewForItem:` - `-sourceList:rowViewForItem:` - `-sourceList:didAddRowView:forRow:` - `-sourceList:didRemoveRowView:forRow:` - Added missing `PXSourceListDelegate` methods which map to their `NSOutlineViewDelegate` counterpart methods, namely: - `-sourceList:toolTipForCell:rect:item:mouseLocation:` - `-sourceList:typeSelectStringForItem:` - `-sourceList:nextTypeSelectMatchFromItem:toItem:forString:` - `-sourceList:shouldTypeSelectForEvent:withCurrentSearchString:` - Moved the Source List delegate notification methods that were previously part of an `NSObject` category into `PXSourceListDelegate`. The methods affected are: - `-sourceListSelectionIsChanging:` - `-sourceListSelectionDidChange:` - `-sourceListItemWillExpand:` - `-sourceListItemDidExpand:` - `-sourceListItemWillCollapse:` - `-sourceListItemDidCollapse:` - `-sourceListDeleteKeyPressedOnRows:` ### Bugfixes - Fixed a *huge* bug where several delegate methods which weren't being called in version 0.x and 1.x of PXSourceList, by removing explicit implementations of `NSOutlineViewDelegate` methods in `PXSourceList` which are now forwarded using a shiny new proxy-based implementation. The stub method implementations removed from `PXSourceList` are: - `-outlineView:numberOfChildrenOfItem:` - `-outlineView:child:ofItem:` - `-outlineView:isItemExpandable:` - `-outlineView:objectValueForTableColumn:byItem:` - `-outlineView:setObjectValue:forTableColumn:byItem:` - `-outlineView:itemForPersistentObject:` - `-outlineView:persistentObjectForItem:` - `-outlineView:writeItems:toPasteboard:` - `-outlineView:writeItems:toPasteboard:` - `-outlineView:validateDrop:proposedItem:proposedChildIndex:` - `-outlineView:acceptDrop:item:childIndex:` - `-outlineView:namesOfPromisedFilesDroppedAtDestination:forDraggedItems:` - `-outlineView:pasteboardWriterForItem:` - `-outlineView:draggingSession:willBeginAtPoint:forItems:` - `-outlineView:draggingSession:endedAtPoint:operation:` - `-outlineView:updateDraggingItemsForDrag:` - `-outlineView:shouldExpandItem:` - `-outlineView:shouldTrackCell:forTableColumn:item:` - `-outlineView:heightOfRowByItem:` - `-outlineView:selectionIndexesForProposedSelection:` - `-outlineView:dataCellForTableColumn:item:` - `-outlineView:willDisplayCell:forTableColumn:item:` - Fixed the PXSourceList framework's `CFBundleIdentifier`. It should have been `com.alexrozanski.PXSourceList`. ### Documentation, Documentation, Documentation - Updated documentation for all public members of `PXSourceList` and its related classes and protocols. - Added documentation for new classes and `PXSourceListDelegate` methods. - Added documentation for `PXSourceList` delegate notifications. - Added a Documentation target to the Xcode project, which can be used to build documentation from source using [appledoc](http://gentlebytes.com/appledoc/). ### Other Changes - Removed `SourceListItem` from the old example project as it has been superseded by `PXSourceListItem`. - Removed the TODO.rtf file from the project as all issues are now being tracked through GitHub. - Upgraded the Xcode project to the Xcode 5 project format. `LastUpgradeCheck` was updated from `0450` to`0500`. - Added a Release Notes file ;)
markdown
<gh_stars>0 [ [ {"name": "ZPT直插式接线端子ZST回拉式弹簧接线端子", "src": "/product/1.pdf", "cover_src": "images/product/1.png"}, {"name": "ZT螺钉接线端子", "src": "/product/2.pdf", "cover_src": "images/product/2.png"}, {"name": "ZK螺钉接线端子", "src": "/product/3.pdf", "cover_src": "images/product/3.png"}, {"name": "ZSK螺钉接线端子", "src": "/product/4.pdf", "cover_src": "images/product/4.png"} ], [ {"name": "ZH1A螺钉板式接线端子", "src": "/product/5.pdf", "cover_src": "images/product/5.png"}, {"name": "ZPDB模块式分线端子", "src": "/product/6.pdf", "cover_src": "images/product/6.png"}, {"name": "ZTC螺钉直压大电流接线端子", "src": "/product/7.pdf", "cover_src": "images/product/7.png"}, {"name": "ZWFF螺柱接线端子", "src": "/product/8.pdf", "cover_src": "images/product/8.png"} ], [ {"name": "模块式小母线接线端子", "src": "/product/9.pdf", "cover_src": "images/product/9.png"}, {"name": "安装屏切换片", "src": "/product/10.pdf", "cover_src": "images/product/10.png"}, {"name": "熔断器", "src": "/product/11.pdf", "cover_src": "images/product/11.png"}, {"name": "超薄继电器", "src": "/product/12.pdf", "cover_src": "images/product/12.png"} ], [ {"name": "端子式光电耦合器", "src": "/product/13.pdf", "cover_src": "images/product/13.png"}, {"name": "支架式继电器模组", "src": "/product/14.pdf", "cover_src": "images/product/14.png"} ] ]
json
<filename>code/visualization/visualizer.py #!/usr/bin/env python # -*- coding: utf-8 -*- """ This script contains functions to visualize the development of the statistics over the total iterations per simulation and it contains functions to plot an arbitrary graph and all the graphs generated by all the simulations for a given human mobility algorithm. """ # Import built-in modules import os # Import libraries import numpy as np import pandas as pd import matplotlib.pyplot as plt import networkx as nx def plot_metrics(algorithm, simulations, user_name): """ This function collects all csv files generated by a specific algorithm and user, calculates the averages and standard deviations for the three statiscs for accuracy and shape metrics for each iteration moment and makes a plot of the development over time for each of the statistcs and saves them to specific file for the given user. Input: algorithm = algorithm for human mobility simulations = the total amount of simulations performed user_name = name of the user who ran the simulations Output: Plots are saved in a folder specified by results_{user_name}/algorithm """ # Create relative file path to results folder and to the csv files alg_path = os.path.join(f"results_{user_name}", algorithm) path = os.path.join(alg_path, "datacollector_sim") # Load all csv files into a dataframe and store each of them in a list. dfs = [pd.read_csv(path + str(sim) + ".csv") for sim in range(simulations)] # Determine the amount of observation per variable and create tracking # varibales for the three statistics for accuracy and shape metrics size = dfs[0]["Accuracy"].size all_accuracies, all_shape = [], [] # Collects all values for each of the statistics seperately nr_stats = 3 for variable in range(nr_stats): var_accuracy = [[] for _ in range(size)] var_shape = [[] for _ in range(size)] for df in dfs: for obs in range(size): accuracy = df[["Accuracy"]].iloc[obs][0] shapes = df[["Shape"]].iloc[obs][0] acc_preproccesed = accuracy.strip("(),").split(",") shapes_preproccesed = shapes.strip("(),").split(",") number = float(acc_preproccesed[variable]) number2 = float(shapes_preproccesed[variable]) var_accuracy[obs].append(number), var_shape[obs].append(number2) all_accuracies.append(var_accuracy), all_shape.append(var_shape) # Determine the averages and standard deviation of each of the statistics ave_accuracies, ave_shapes = [[], [], []], [[], [], []] stds_accuracies, stds_shapes = [[], [], []], [[], [], []] for variable in range(nr_stats): for acc, s in zip(all_accuracies[variable], all_shape[variable]): ave_accuracies[variable].append(np.mean(acc)) ave_shapes[variable].append(np.mean(s)) stds_accuracies[variable].append(np.std(acc)) stds_shapes[variable].append(np.std(s)) # Make plots for the accuracy statistics variables = ["Accuracy", "F1", "Mathews_Correlation_Coeffcient"] make_figure(algorithm, alg_path, variables, ave_accuracies, stds_accuracies) # Make plots for the shape metrics variables = ["Density", "Variance_degree", "Centrality"] make_figure(algorithm, alg_path, variables, ave_shapes, stds_shapes) def make_figure(algorithm, alg_path, variables, averages, stds): """ Makes plots of each of the statistics' averages and confidence interval against the total iterations. Input: algorithm = human mobility algorithm alg_path = relative file path to save the figures variables = array-like containing the names of the statistics averages = nested list containing the averages of each statistic stds = nested list containing the standard deviations of each statistic Output: Saves figures to a folder specified by results_{user_name}/algorithm """ # Makes a figure for each statistic for i, statistic in enumerate(averages): plt.figure() # Create values for x-axis (iterations) and make plot observations = len(statistic) x = [0.01 * i for i in range(observations)] plt.plot(x, statistic, color="darkblue") # Generate different title and x label for the different algorithms if algorithm == "SBLN": plt.title("Mean accuracy over all tests for Levy based walk") plt.xlabel("iteration number (10^5)") elif algorithm == "GRAV": plt.title("Mean accuracy over all tests for gravitywalk") plt.xlabel("iteration number (10^5)") elif algorithm == "BM": plt.title("Mean accuracy over all tests for Brownian Motion") plt.xlabel("iteration number (10^6)") # Create y label and plot confidence interval plt.ylabel(variables[i]) plt.errorbar( x, statistic, yerr=stds[i], alpha=0.1, color="cornflowerblue" ) # Save figure to results folder, when done close figure plt.savefig(os.path.join(alg_path, f"plot_{algorithm}_{variables[i]}.pdf"), dpi=300 ) plt.close() def plot_network(road_dens, graph, user_name, gr_type): """ Makes a plot of a specific graph. Input: road_dens = road denisty matrix of the area (numpy) graph = graph object (networkx) user_name = name of the user who ran the simulations (string) gr_type = name of the graph (string) Output: Saves files to a folder of the form results_{user_name}/algorithm """ # Create relative file path to results folder # and determine widht, height of area path = os.path.join(f"results_{user_name}", f"{gr_type}.pdf") width = road_dens.shape[1] - 1 height = road_dens.shape[0] - 1 # Draw graph with the nodes on thei positions and their size depending on # it's nodal degree (amount of rivals) pos = nx.get_node_attributes(graph, "pos") d = dict(graph.degree) nx.draw(graph, pos, node_size=[(v + 1) * 5 for v in d.values()]) # Set x, y limits and title graph. If done save figure and close figure plt.xlim(0, width) plt.ylim(0, height) plt.title(f"{gr_type}") plt.savefig(path, dpi=300) plt.close() def plot_networks(algorithm, simulations, config, user_name): """ Makes figures of the graphs generated at the end of each simulation by a certain user. Input: algorithm = human mobility algorithm simulations = total amount of simulations that the model has ran config = object containing the configuration of the model user_name = name of the user who ran the simulations """ # Create relative file path to results folder # and to load each rivalry matrix alg_path = os.path.join(f"results_{user_name}", algorithm) path = os.path.join(alg_path, "rivalry_matrix_sim") # Load all rivalry matrices matrices_sim = [np.load(path + str(sim) + ".npy") for sim in range(simulations)] # Determine width and height of the area (Hollenbeck) width = config.road_dens.shape[1] - 1 height = config.road_dens.shape[0] - 1 # Create graph for each of the rivalry matrices shape = len(config.gang_info) for mat, matrix in enumerate(matrices_sim): # Initialize graph with the nodes (gangs) at their home locations graph = nx.Graph() for gang in config.gang_info.values(): graph.add_node(gang.number, pos=gang.coords) # Determines if the rivalry between gangs is larger than a threshold. # If so add edge as confirmation of the rivalry for i in range(shape): total_interactions = matrix[i, :].sum() for j in range(shape): if total_interactions: rival_strength = matrix[i][j] / total_interactions if rival_strength > config.parameters["threshold"]: graph.add_edge(i, j, color=config.colors[i]) # Draw graph with the nodes at their location and their size depending # on the nodal degree (amount of rivals) pos = nx.get_node_attributes(graph, "pos") d = dict(graph.degree) nx.draw(graph, pos, node_size=[(v + 1) * 5 for v in d.values()]) # Plots a differen title depending on the human mobility algorithm if algorithm == "GRAV": plt.title("Network Gravity model") elif algorithm == "SBLN": plt.title("Network Semi-Biased Levy walk") elif algorithm == "BM": plt.title("Network Brownian Motion") # Set limits axis and save figure to folder. If done close figure plt.xlim(0, width) plt.ylim(0, height) plt.savefig(os.path.join(alg_path, f"network_sim{mat}.pdf"), dpi=300) plt.close()
python
{ "name": "situm-cordova-plugin-official", "version": "1.15.3", "cordova": { "id": "situm-cordova-plugin-official", "platforms": [ "android", "ios" ] }, "description": "Situm Cordova-based Plugin for hybrid apps.", "repository": { "type": "git", "url": "git+https://github.com/situmtech/situm-cordova-plugin.git" }, "keywords": [ "situm", "indoor positioning", "ecosystem:cordova", "cordova-android", "cordova-ios" ], "engines": [ { "name": "cordova-android", "version": ">=6.0.0" } ], "author": "Situm Techonologies", "license": "MIT", "bugs": { "url": "https://github.com/situmtech/situm-cordova-plugin/issues" }, "homepage": "https://github.com/situmtech/situm-cordova-plugin#readme", "dependencies": { "cordova-common": "^2.2.5", "describe": "^1.2.0", "q": "^1.5.1", "tui-jsdoc-template": "^1.2.2" }, "scripts": { "test": "cd tests/js && mocha", "eslint": "node node_modules/eslint/bin/eslint www && node node_modules/eslint/bin/eslint src && node node_modules/eslint/bin/eslint tests", "jsdoc": "rm -rf docs/JSDoc && ./node_modules/.bin/jsdoc www/android/situm.js www/android/Interfaces.js -c ./docs/conf.json -d docs/JSDoc" }, "devDependencies": { "eslint": "^5.3.0", "eslint-config-semistandard": "^11.0.0", "eslint-config-standard": "^10.2.1", "eslint-plugin-import": "^2.3.0", "eslint-plugin-node": "^5.0.0", "eslint-plugin-promise": "^3.5.0", "eslint-plugin-standard": "^3.0.1", "jsdoc": "^3.5.5", "mocha": "^5.2.0", "expect.js": "^0.3.1", "jsdoc-toolkit": "0.0.2" } }
json
<gh_stars>1-10 // Copyright 2013 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "remoting/client/jni/jni_frame_consumer.h" #include "base/android/jni_android.h" #include "base/logging.h" #include "base/stl_util.h" #include "base/synchronization/waitable_event.h" #include "remoting/base/util.h" #include "remoting/client/frame_producer.h" #include "remoting/client/jni/chromoting_jni_instance.h" #include "remoting/client/jni/chromoting_jni_runtime.h" #include "third_party/webrtc/modules/desktop_capture/desktop_frame.h" #include "third_party/webrtc/modules/desktop_capture/desktop_region.h" #include "ui/gfx/android/java_bitmap.h" namespace remoting { JniFrameConsumer::JniFrameConsumer( ChromotingJniRuntime* jni_runtime, scoped_refptr<ChromotingJniInstance> jni_instance) : jni_runtime_(jni_runtime), jni_instance_(jni_instance), frame_producer_(nullptr) { } JniFrameConsumer::~JniFrameConsumer() { // The producer should now return any pending buffers. At this point, however, // ReturnBuffer() tasks scheduled by the producer will not be delivered, // so we free all the buffers once the producer's queue is empty. base::WaitableEvent done_event(true, false); frame_producer_->RequestReturnBuffers( base::Bind(&base::WaitableEvent::Signal, base::Unretained(&done_event))); done_event.Wait(); STLDeleteElements(&buffers_); } void JniFrameConsumer::set_frame_producer(FrameProducer* producer) { frame_producer_ = producer; } void JniFrameConsumer::ApplyBuffer(const webrtc::DesktopSize& view_size, const webrtc::DesktopRect& clip_area, webrtc::DesktopFrame* buffer, const webrtc::DesktopRegion& region, const webrtc::DesktopRegion& shape) { DCHECK(jni_runtime_->display_task_runner()->BelongsToCurrentThread()); if (bitmap_->size().width() != buffer->size().width() || bitmap_->size().height() != buffer->size().height()) { // Drop the frame, since the data belongs to the previous generation, // before SetSourceSize() called SetOutputSizeAndClip(). FreeBuffer(buffer); return; } // Copy pixels from |buffer| into the Java Bitmap. // TODO(lambroslambrou): Optimize away this copy by having the VideoDecoder // decode directly into the Bitmap's pixel memory. This currently doesn't // work very well because the VideoDecoder writes the decoded data in BGRA, // and then the R/B channels are swapped in place (on the decoding thread). // If a repaint is triggered from a Java event handler, the unswapped pixels // can sometimes appear on the display. uint8* dest_buffer = static_cast<uint8*>(bitmap_->pixels()); webrtc::DesktopRect buffer_rect = webrtc::DesktopRect::MakeSize(view_size); for (webrtc::DesktopRegion::Iterator i(region); !i.IsAtEnd(); i.Advance()) { const webrtc::DesktopRect& rect(i.rect()); CopyRGB32Rect(buffer->data(), buffer->stride(), buffer_rect, dest_buffer, bitmap_->stride(), buffer_rect, rect); } // TODO(lambroslambrou): Optimize this by only repainting the changed pixels. base::TimeTicks start_time = base::TimeTicks::Now(); jni_runtime_->RedrawCanvas(); jni_instance_->RecordPaintTime( (base::TimeTicks::Now() - start_time).InMilliseconds()); // Supply |frame_producer_| with a buffer to render the next frame into. frame_producer_->DrawBuffer(buffer); } void JniFrameConsumer::ReturnBuffer(webrtc::DesktopFrame* buffer) { DCHECK(jni_runtime_->display_task_runner()->BelongsToCurrentThread()); FreeBuffer(buffer); } void JniFrameConsumer::SetSourceSize(const webrtc::DesktopSize& source_size, const webrtc::DesktopVector& dpi) { DCHECK(jni_runtime_->display_task_runner()->BelongsToCurrentThread()); // We currently render the desktop 1:1 and perform pan/zoom scaling // and cropping on the managed canvas. clip_area_ = webrtc::DesktopRect::MakeSize(source_size); frame_producer_->SetOutputSizeAndClip(source_size, clip_area_); // Allocate buffer and start drawing frames onto it. AllocateBuffer(source_size); } FrameConsumer::PixelFormat JniFrameConsumer::GetPixelFormat() { return FORMAT_RGBA; } void JniFrameConsumer::AllocateBuffer(const webrtc::DesktopSize& source_size) { DCHECK(jni_runtime_->display_task_runner()->BelongsToCurrentThread()); webrtc::DesktopSize size(source_size.width(), source_size.height()); // Allocate a new Bitmap, store references here, and pass it to Java. JNIEnv* env = base::android::AttachCurrentThread(); // |bitmap_| must be deleted before |bitmap_global_ref_| is released. bitmap_.reset(); bitmap_global_ref_.Reset(env, jni_runtime_->NewBitmap(size).obj()); bitmap_.reset(new gfx::JavaBitmap(bitmap_global_ref_.obj())); jni_runtime_->UpdateFrameBitmap(bitmap_global_ref_.obj()); webrtc::DesktopFrame* buffer = new webrtc::BasicDesktopFrame(size); buffers_.push_back(buffer); frame_producer_->DrawBuffer(buffer); } void JniFrameConsumer::FreeBuffer(webrtc::DesktopFrame* buffer) { DCHECK(std::find(buffers_.begin(), buffers_.end(), buffer) != buffers_.end()); buffers_.remove(buffer); delete buffer; } } // namespace remoting
cpp
Chokkanarayana Swamy is the main deity of this temple, who is an incarnation of Lord Vishnu. Here deity is facing in East. The idol is small but very beautiful,the deity will be in a standing posture with four hands one in varada posture, one placed over thigh and other two holding Shanka and Sudarshana Chakra. This deity is madeup of saligrama (black) stone. Chokkanarayana Swamy is the main deity of this temple, who is an incarnation of Lord Vishnu. Here deity is facing in East. The idol is small but very beautiful,the deity will be in a standing posture with four hands one in varada posture, one placed over thigh and other two holding Shanka and Sudarshana Chakra. This deity is madeup of saligrama (black) stone. Weather<p> Highest - April to June (38°C during day and 26°C during night) Domlur Chokkanatha Temple ‘Chokka’ in Telugu means ‘beautiful’ and the temple is constructed in such a way at a high place facing East. The temple has a tall stone flagstaff in front, the customary Garuda idol facing the main deity has a little mantap of its own. The carvings on the pillars portray the Kolata scene, fight of Vaali and Sugreev and a lion figure at the base and scenes from the Dasavataram. In sanctum Lord Vishnu or Chokka Perumal and his consorts Sridevi and Bhoodevi in the garbha graham (sanctum). These images have been carved from the saligrama (black) stone. Two ardhamandapas in front of it are the original structures and one of these mandapas (halls) has an underground cell. One can see the images of Lord Vishnu, the front portion or navaranga mantapa seems to be typical of the later Vijayanagar style. Tamil Inscriptions - The Chokkanatha swamy Temple is a 10th-century Chola temple, located in Domlur. There are a number of Tamil inscriptions in the temple. Domlur is called as Tombalur or Desimanikkapattanam in these inscriptions. Chakravarthi Posalaviraramanatha Deva has left inscriptions with directions to temple authorities of his kingdom. Further some inscriptions record the tributes, taxes and tolls made to the temple by Devaraya II of Vijayanagar Empire, which state the houses, wells, land around Tombalur were offered to the deity Sokkapperumal. Another Tamil inscription dated 1270 talks about 2 door posts being donated by Alagiyar. Yet another inscription in Tamil details Talaikkattu and his wife donating lands from Jalapalli village and Vinnamangalam tank to the deity. A 1290 A.D. inscription talks about donation of ten pens from the revenue of Tommalur by Poysala vira Ramananda. The temple was built in 10th century by Cholas and a renovation of this temple was carried out during 1975-1983. Hoysala King Ramanandadeva of 1300 A.D. is the contributor of this temple. According to this inscription Irvi Tripuranthaka chettiar and his wife Parvathichetti for the betterment of the shoulder and sword of Tribhuvana mallar vempi probably chieften of domlur, donated wet and dry lands. Total area of the Government aquarium is 2700 sq.m.
english
The new rules, which were issued last week, prohibit the trade of cattle meant for slaughter at open markets, a move that many said would lead to an effective ban on cattle slaughter for much of the country, even though the government insists that is not its objective. Analysts have argued that the rules go beyond the objectives laid out in the Prevention of Cruelty to Animals Act, under which they are framed, an argument that Vijayan too makes in his letter. Vijayan had already written a letter to Prime Minister Narendra Modi asking him to take back the rules, saying they would have a severe impact on the rural economy, while protests were held across Kerala against an act that many saw as the Centre imposing its anti-beef morals. On Monday, West Bengal Chief Minister Mamata Banerjee too said that she would be challenging the rules in court, insisting that they are unconstitutional. The Karnataka government has suggested that it will do the same. Below is the full text of Vijayan’s letter to the other chief ministers, which he also posted on his Facebook page. I am sure that you are already conversant with the Notification containing the Prevention of Cruelty to Animals (Regulation of Livestock Markets) Rules, 2017 issued by the Ministry of Environment, Forest and Climate Change on 23rd May, 2017. The Rules impose a number of restriction on cattle trade which would have serious repercussions on the livelihood of millions of people, especially those in the agricultural sector, in our country. It appears strange that the Rules are promulgated under the Prevention of Cruelty to Animals Act, 1960 since they have nothing to do with the objects of the Act. Neither are the Rules covered by the express delegation of legislative powers contained in the Act. Hence it is nothing but a covert attempt to usurp the powers of State legislatures in the guise of rules under a Central Act. The subjects covered by the Rules belong to entries 15 and 18 of the State List in the Constitution. This impermissible encroachment into the domain of the State Legislatures is a clear violation of the spirit of federalism, which is acclaimed as one of the basic features of the constitution.. The Rules, by imposing unreasonable restriction on the fundamental right to carry on any trade or occupation under Article 19 (1) (g) of the Constitution, will not stand the test of constitutionality. They also violate the basic right of a person to freedom of choice regarding his food. It is rather unfortunate that such a drastic measure, producing serious consequences, was introduced in exercise of the rule making power, surpassing the elected representatives of the people and avoiding any public debate. This is nothing but a negation of the democratic principle, which is indisputably accepted as forming part of the basic structure of the Constitution. Apart from the Constitutional and legal infirmities of the Rules, the disastrous consequences which are likely to arise if these Rules are brought into force make one shudder. It will definitely produce a chaotic situation in the rural agricultural economy in all the States. Unless we stand together and oppose this anti-federal, anti-democratic and anti-secular move, it may mark the beginning of a series of similar measures aimed at destroying the federal democratic fabric and secular culture of our country. I would therefore fervently appeal to you to convey your objection to the 2017 Rules under the Prevention of Cruelty to Animals Act to the Prime Minister, and to request him to withdraw the Rules introduced without any consultation with the States. Since the matters dealt within the Rules squarely fall within the purview of State Legislatures, the State Governments may be allowed to formulate necessary policies and laws to suit the socio-cultural and economic milieu of the State. I have already brought these matters to the kind attention of the Prime Minister in a letter dated May 27th, 2017. A copy of the letter is attached for your kind perusal.
english
<reponame>greenelab/nature_news_disparities version https://git-lfs.github.com/spec/v1 oid sha256:a1b0d862f0adfea18dee6156d9e97464f3989321b8124b9f8f13edc9ff94704a size 524062
json
// Copyright (c) 2014-2020 Dr. <NAME> and <NAME> // Please see LICENSE for license or visit https://github.com/taocpp/PEGTL/ #ifndef TAO_PEGTL_SRC_EXAMPLES_PEGTL_JSON_UNESCAPE_HPP #define TAO_PEGTL_SRC_EXAMPLES_PEGTL_JSON_UNESCAPE_HPP #include <string> #include <tao/pegtl/change_action_and_states.hpp> #include <tao/pegtl/contrib/json.hpp> #include <tao/pegtl/contrib/unescape.hpp> namespace example { // Action class for parsing literal strings, uses the PEGTL unescape utilities, cf. unescape.cpp. // clang-format off template< typename Rule > struct json_unescape_action {}; template<> struct json_unescape_action< TAO_PEGTL_NAMESPACE::json::unicode > : TAO_PEGTL_NAMESPACE::unescape::unescape_j {}; template<> struct json_unescape_action< TAO_PEGTL_NAMESPACE::json::escaped_char > : TAO_PEGTL_NAMESPACE::unescape::unescape_c< TAO_PEGTL_NAMESPACE::json::escaped_char, '"', '\\', '/', '\b', '\f', '\n', '\r', '\t' > {}; template<> struct json_unescape_action< TAO_PEGTL_NAMESPACE::json::unescaped > : TAO_PEGTL_NAMESPACE::unescape::append_all {}; // clang-format on using json_unescape = tao::pegtl::change_action_and_states< json_unescape_action, std::string >; } // namespace example #endif
cpp
Uttarakhand board UBSE class 11 syllabus, date sheet, exam schedule, class 11 NCERT books solutions and UK board Ram Nagar Nainital exams, results and class 11 question papers. UK Board, UBSE class 11 syllabus and class 11 sample papers. UBSE syllabus, sample papers, test papers, Uttarakhand board question papers for class 11 Biology course material includes The Living World, Biological Classification, Plant Kingdom, Animal Kingdom, Morphology of Flowering Plants, Anatomy of Flowering Plants, Structural Organisation in Animals, Cell : The Unit of Life, Biomolecules, Cell Cycle and Cell Division, Transport in Plants, Mineral Nutrition, Photosynthesis in Higher Plants, Respiration in Plants, Plant Growth and Development, Digestion and Absorption, Breathing and Exchange of Gases, Body Fluids and Circulation, Excretory Products and their Elimination, Locomotion and Movement, Neural Control and Coordination, Chemical Coordination and Integration. The complete course of class 11 Biology comprises downloadable PDF files as sample papers, test papers, unit exam papers, model question papers, NCERT solutions, online free MCQ tests and video lectures. NCERT Solutions, NCERT Exemplars, Revison Notes, Free Videos, CBSE Papers, MCQ Tests & more. NCERT Solutions, NCERT Exemplars, Revison Notes, Free Videos, CBSE Papers, MCQ Tests & more.
english
import { e2e } from '../index'; export const login = (username: string, password: string) => { e2e().logToConsole('Trying to login with:', { username, password }); e2e.pages.Login.visit(); e2e.pages.Login.username() .should('be.visible') // prevents flakiness .type(username); e2e.pages.Login.password().type(password); e2e.pages.Login.submit().click(); e2e().logToConsole('Logged in with', { username, password }); };
typescript
-Option/root .public/section ~ .public/section:before { }
css
<reponame>BuzzWordsGame/assets {"answers":["cava","cave","caved","chave","cuvee","deave","deaved","deev","deeve","deeved","deva","eave","eaved","evacuee","evade","evaded","have","heave","heaved","hevea","uvae","uvea","vacua","vade","vaded","vauch","vauched"],"centerLetter":"v","letterString":"vacdehu","outerLetters":["a","c","d","e","h","u"],"pangrams":["vauched"],"validLetters":["a","c","d","e","h","u","v"]}
json
<reponame>ViguierB/ZiaApi var classzany_1_1_entity = [ [ "OnConflitFunc", "classzany_1_1_entity.html#a007686cc00c54a37865405a65d6f5477", null ], [ "CloneOption", "classzany_1_1_entity.html#a5d33a8d8bda745a8c8e6cf0a03eee7e2", [ [ "LAZY", "classzany_1_1_entity.html#a5d33a8d8bda745a8c8e6cf0a03eee7e2a6a8a3c94520fb08ece01af05181f1545", null ], [ "DEEP", "classzany_1_1_entity.html#a5d33a8d8bda745a8c8e6cf0a03eee7e2ac7489a84585b023358dc07a421411f45", null ] ] ], [ "StringifyAttr", "classzany_1_1_entity.html#a167c260d0fe1b1888bda92c0cfbf74f1", [ [ "PRETTY", "classzany_1_1_entity.html#a167c260d0fe1b1888bda92c0cfbf74f1a2b908e3bfd5ebc739a3ce26d5045b76f", null ], [ "MINIFIED", "classzany_1_1_entity.html#a167c260d0fe1b1888bda92c0cfbf74f1a70276717bf212c8ced0e3014b7dcacca", null ] ] ], [ "Type", "classzany_1_1_entity.html#abac615101758cc03e160fc711e15c884", [ [ "NBR", "classzany_1_1_entity.html#abac615101758cc03e160fc711e15c884ad3716f98e0f37af864d9f6280c2cd79d", null ], [ "STR", "classzany_1_1_entity.html#abac615101758cc03e160fc711e15c884a3fe0dfff438296bb525e0e8642586c2d", null ], [ "ARR", "classzany_1_1_entity.html#abac615101758cc03e160fc711e15c884ac703eb65f968f2a9c9145fd07132f72b", null ], [ "OBJ", "classzany_1_1_entity.html#abac615101758cc03e160fc711e15c884af34d534adfb78a9e6432be4621a93eec", null ], [ "BOL", "classzany_1_1_entity.html#abac615101758cc03e160fc711e15c884a72df28bd206a4338d55124038c46d3b6", null ], [ "NUL", "classzany_1_1_entity.html#abac615101758cc03e160fc711e15c884a890f5fe6581170eeff26bec1c1e6a023", null ] ] ], [ "Entity", "classzany_1_1_entity.html#a01477d997fda0587f327f987aea6c168", null ], [ "Entity", "classzany_1_1_entity.html#ad10aae47371332c96e4f2c8cc614f5e3", null ], [ "Entity", "classzany_1_1_entity.html#a144fdfaeb805515baa69380c0c1595ff", null ], [ "Entity", "classzany_1_1_entity.html#a87cd79062899647c63e4b0b407e6e272", null ], [ "Entity", "classzany_1_1_entity.html#aa634ddfdebe96ff05458fa992d9c5ef8", null ], [ "Entity", "classzany_1_1_entity.html#a36cc88188f6188a8b5f25861371dac71", null ], [ "Entity", "classzany_1_1_entity.html#a91dd25a738255565138546dfdf1ce7a1", null ], [ "Entity", "classzany_1_1_entity.html#a3fe428e713937a4773f2543362ea394c", null ], [ "Entity", "classzany_1_1_entity.html#a7ef279496a4ae34ba31caeee41466548", null ], [ "Entity", "classzany_1_1_entity.html#a4ee47f00ccba139a4914f8ec6eedb824", null ], [ "Entity", "classzany_1_1_entity.html#aa66f81c7326eaadda5117a743c42b5eb", null ], [ "Entity", "classzany_1_1_entity.html#ade02ec78fbfdf684461d5fb57ecec218", null ], [ "clone", "classzany_1_1_entity.html#afd73007d5ebe1119548653be5b59b8e1", null ], [ "constGetData", "classzany_1_1_entity.html#ae743c8b1cdf54d3cc9b2eabcc5ade641", null ], [ "getData", "classzany_1_1_entity.html#a36eaf259b330065ef5d4d562b485895a", null ], [ "getData", "classzany_1_1_entity.html#aa9836cb17e3e7747ab2146025d6f58ea", null ], [ "isArray", "classzany_1_1_entity.html#ae6908971cb9ef360026b441164bc6fae", null ], [ "isBool", "classzany_1_1_entity.html#a4823951c80f2939c28a19344bf0a6ef5", null ], [ "isNull", "classzany_1_1_entity.html#ae249c0ff1d495ba051551e0247f7e599", null ], [ "isNumber", "classzany_1_1_entity.html#a4b2332f5a4e45849118e20e312c957ef", null ], [ "isObject", "classzany_1_1_entity.html#ae573986490449ae0513bd3e0e640ca50", null ], [ "isString", "classzany_1_1_entity.html#af2567149bcbc8d2a8b5b96d78720c243", null ], [ "merge", "classzany_1_1_entity.html#a603b1b5a8d685c89da2ae8159729f7fb", null ], [ "operator!=", "classzany_1_1_entity.html#a7955362e5e19901f4890949862f8b7dc", null ], [ "operator=", "classzany_1_1_entity.html#a4f301b0cdab72445a68912c994edd3d7", null ], [ "operator==", "classzany_1_1_entity.html#a272ac41048907f59c46b9fc21cd184a0", null ], [ "operator[]", "classzany_1_1_entity.html#a7cc96544785d0ce20a25a2d2b177f438", null ], [ "operator[]", "classzany_1_1_entity.html#a2123776a705ab53965cf1bcbab5ac3e7", null ], [ "push", "classzany_1_1_entity.html#aaace39cfc871d25e3a8e52b4bb949b7c", null ], [ "to", "classzany_1_1_entity.html#a26594f38171700d5f00d4770bc8056e1", null ], [ "to", "classzany_1_1_entity.html#a38cba4eaebbb8f358d47952ed96d615b", null ], [ "to", "classzany_1_1_entity.html#a5680d7d3126442c3f82a9045f4648e9c", null ], [ "to", "classzany_1_1_entity.html#a52abac40f3107b9cfca3b2812a03e716", null ], [ "to", "classzany_1_1_entity.html#a644c78dd43e8436180c00b4ffc156f67", null ], [ "to", "classzany_1_1_entity.html#a19a9eafff1b66ac2f3f8c576e988cef8", null ], [ "to", "classzany_1_1_entity.html#a0a627b6067bb23265a6bbca33ecc91db", null ], [ "to", "classzany_1_1_entity.html#a26594f38171700d5f00d4770bc8056e1", null ], [ "to", "classzany_1_1_entity.html#a38cba4eaebbb8f358d47952ed96d615b", null ], [ "to", "classzany_1_1_entity.html#a52abac40f3107b9cfca3b2812a03e716", null ], [ "to", "classzany_1_1_entity.html#a19a9eafff1b66ac2f3f8c576e988cef8", null ], [ "to", "classzany_1_1_entity.html#a0a627b6067bb23265a6bbca33ecc91db", null ], [ "value", "classzany_1_1_entity.html#ab26474b9955424dedab37f6757065f4a", null ], [ "value", "classzany_1_1_entity.html#a416ef68c2f2d7cc99050bb7010aa9fdd", null ], [ "value", "classzany_1_1_entity.html#a4b46d65306ba9028581d7e4791300d1a", null ], [ "value", "classzany_1_1_entity.html#a276a87b238a0e68824988aa8940eea7d", null ] ];
javascript
<filename>docs/epi/Harriet Beecher Stower.html <html> <body> <h1>Author: <NAME></h1> <h3>Cites</h3> <ul> <li><a href='<NAME>.html' class='author'><NAME></a> (1) <ul> <li>IN: <i>Dred: A Tale of the Great Dismal Swamp</i> (1856) Fiction, American <br>EPIGRAPH: <i><b>"Away to the Dismal Swamp he speeds, His path was rugged and sore, Through tangled juniper, beds of reeds, Through many a fen, where the serpent feeds, And man never trod before. And, when on the earth he sunk to sleep, If slumber his eyelids knew, He lay where the deadly vine doth weep Its venomous tears, that nightly steep The flesh with blistering dew."</i></b> <br>FROM: <i>A Ballad: The Lake of the Dismal Swamp</i>, (1803), Poem, Ireland </ul> </ul> </body> </html>
html
A global outage of multimedia platform Facebook that made its affiliated apps like WhatsApp and Instagram non-operational for almost seven hours on Monday was due to faulty configuration changes on its routers, said the platform after the restoration of services. “Our engineering teams have learned that configuration changes on the backbone routers that coordinate network traffic between our data centres caused issues that interrupted this communication,” the company said. Earlier, Facebook CEO Mark Zuckerberg issued an apology after three platforms run by the social media giant — Facebook, Instagram and WhatsApp saw hours-long outages on Monday. “Facebook, Instagram, WhatsApp and Messenger are coming back online now. Sorry for the disruption today — I know how much you rely on our services to stay connected with people you care about,” Zuckerberg wrote. Social media users across the world started experiencing troubles in using Facebook-owned, some of the most relied upon platforms, WhatsApp and Instagram on Monday at around 9 pm (IST). Subsequently, millions of users wrote on Twitter that their messages were not being loaded and their user feed had been disrupted. According to outage tracking website Downdetector. com, this was “the largest outage they have ever seen”. The company said it had received 10. 6 million reports of problems ranging from the United States and Europe to Colombia and Singapore, with trouble first appearing at about 15:45 GMT. Following the outage, Facebook stocks plummeted by nearly 5%. However, this was not the first time that the multimedia giant suffered a massive global outage, In 2010, Facebook users experienced a two-hour outage due to a perplexingly complicated networking issue, which was reportedly created by its engineers once again, the Guardian reported. Another major outage was reported in 2019, when the platform went offline for more than 14 hours because of a server configuration change, said a BBC report.
english
/** * @param {number[][]} obstacleGrid * @return {number} */ var uniquePathsWithObstacles = function (obstacleGrid) { if ( obstacleGrid === null || obstacleGrid.length === 0 || obstacleGrid[0].length === 0 ) { return 0; } var m = obstacleGrid.length; var n = obstacleGrid[0].length; if (m === 0 || n === 0) { return 0; } if (obstacleGrid[0][0] === 1) { return 0; } var dp = [[1]]; for (var i = 1; i < n; i++) { if (obstacleGrid[0][i] === 1) { dp[0][i] = 0; } else if (dp[0][i - 1] === 0) { dp[0][i] = 0; } else { dp[0][i] = 1; } } for (var j = 1; j < m; j++) { dp.push([]); if (obstacleGrid[j][0] === 1) { dp[j][0] = 0; } else if (dp[j - 1][0] === 0) { dp[j][0] = 0; } else { dp[j][0] = 1; } } for (i = 1; i < m; i++) { for (j = 1; j < n; j++) { if (obstacleGrid[i][j] === 1) { dp[i][j] = 0; } else { dp[i][j] = dp[i - 1][j] + dp[i][j - 1]; } } } return dp[m - 1][n - 1]; };
javascript
<reponame>mossid/cosmos-sdk package util import ( "fmt" sdk "github.com/cosmos/cosmos-sdk" "github.com/cosmos/cosmos-sdk/errors" ) // Recovery catches any panics and returns them as errors instead type Recovery struct{} var _ sdk.Decorator = Recovery{} // CheckTx catches any panic and converts to error - fulfills Middlware interface func (Recovery) CheckTx(ctx sdk.Context, store sdk.SimpleDB, tx interface{}, next sdk.Checker) (res sdk.CheckResult, err error) { defer func() { if r := recover(); r != nil { err = normalizePanic(r) } }() return next.CheckTx(ctx, store, tx) } // DeliverTx catches any panic and converts to error - fulfills Middlware interface func (Recovery) DeliverTx(ctx sdk.Context, store sdk.SimpleDB, tx interface{}, next sdk.Deliverer) (res sdk.DeliverResult, err error) { defer func() { if r := recover(); r != nil { err = normalizePanic(r) } }() return next.DeliverTx(ctx, store, tx) } // normalizePanic makes sure we can get a nice TMError (with stack) out of it func normalizePanic(p interface{}) error { if err, isErr := p.(error); isErr { return errors.Wrap(err) } msg := fmt.Sprintf("%v", p) return errors.ErrInternal(msg) }
go
{"id":"3d533105-4e6a-41d9-acaa-0f9da15519ba","name":"St Nicolas C of E School","code":"9","address":{"addressLine1":"Locks Hill","town":"Portslade","county":"East Sussex","postcode":"BN41 2LA"},"organisation":{"id":"d42008b9-26c1-45a8-95c6-fefca8f13512","code":"1KN","name":"BHSSA"}}
json
[{"filename": "a regular filename", "flags": "-rw-rw-r--", "links": 1, "owner": "kbrazil", "group": "kbrazil", "size": 0, "date": "Feb 27 18:08"}, {"filename": "\n\nthis file has\na combination\n\n\nof everything\n\n\n\n", "flags": "-rw-rw-r--", "links": 1, "owner": "kbrazil", "group": "kbrazil", "size": 0, "date": "Feb 27 18:08"}, {"filename": "this file has\na newline inside", "flags": "-rw-rw-r--", "links": 1, "owner": "kbrazil", "group": "kbrazil", "size": 0, "date": "Feb 27 18:08"}, {"filename": "this file has\n\n\n\nfour contiguous newlines inside", "flags": "-rw-rw-r--", "links": 1, "owner": "kbrazil", "group": "kbrazil", "size": 0, "date": "Feb 27 18:08"}, {"filename": "this file\nhas\nsix\n\nnewlines\n\nwithin", "flags": "-rw-rw-r--", "links": 1, "owner": "kbrazil", "group": "kbrazil", "size": 0, "date": "Feb 27 18:08"}, {"filename": "\n\n\n\nthis file starts with four newlines", "flags": "-rw-rw-r--", "links": 1, "owner": "kbrazil", "group": "kbrazil", "size": 0, "date": "Feb 27 18:08"}, {"filename": "\nthis file starts with one newline", "flags": "-rw-rw-r--", "links": 1, "owner": "kbrazil", "group": "kbrazil", "size": 0, "date": "Feb 27 18:08"}]
json
package com.example.gameoflife.core; import org.junit.jupiter.api.Test; import static org.junit.jupiter.api.Assertions.assertEquals; public class CellTest { @Test public void testUpdateState() { Cell c = new Cell(); c.setNewState(Cell.CellState.LEVEL_1); c.updateState(); assertEquals(Cell.CellState.LEVEL_1, c.getState()); } @Test public void testConstructor() { Cell c = new Cell(Cell.CellState.LEVEL_1); assertEquals(Cell.CellState.LEVEL_1, c.getState()); } }
java
With two legends set to be inducted next month, the Premier League have launched their own official Hall of Fame. The Premier League officials claimed that they want to “recognise and celebrate the exceptional skill and talent of players since 1992”. With a shortlist drawn up to allow fans to vote for additional deserving Hall of Famers, The Premier League chiefs went on to say two players will be inducted into the list and voting in the due course. Premier League chief executive Richard Masters said: “Since 1992, the Premier League has been home to world-class players who have defined generations and provided us with compelling football season after season. “A place in the Premier League Hall of Fame is reserved for the very best. According to the entry rules, the players be retired already and only their Premier League performances will be noted for the Hall of Fame purpose. The performances on the international front, Europe and other domestic cups are not taken into consideration. Even though the list is yet to be released, the fans of different clubs are already divided as to who deserves the two automatic spots, with such a vast array of talent plying their trade in the league in the last 28 years. One Arsenal supporter posted a picture of Thierry Henry and Dennis Bergkamp, and captioned: “First names on the list.” But one disagreed, saying Manchester United‘s stars are set to be heavily represented. They wrote: A Chelsea fan demanded their biggest legends be recognised, saying: Also, the Liverpool midfielder and Sky Sports pundit Alan Shearer and Manchester United midfielder and Welsh manager, Ryan Giggs were amongst the names to crop up time and time again. However, not everyone among the fans wanted “marquee” names, with one suggesting ever-present grinders deserve a look in. One supporter said: “I want them to avoid doing bulls*** like adding in just marquee names, long standing servants that were PL household names for over a decade. The first two Hall of Famers are going to be named next month and each inductee will be receiving a personalized medallion, engraved with the year they were bestowed with the honor. On the other hand, some sections of the fans feel that the “Hall of Fame” should be opened up not only to players but also to managers. Especially with Sir Alex Ferguson and Arsene Wenger and their contribution to the Premier League, it remains to what Premier League decide.
english
Golden State Warriors superstar Steph Curry's recent championship victory elevated his historical standing. Many believe that his fourth championship has cemented his legacy as a top ten player of all time. Some believe he is in the Mt. Rushmore of basketball. On ESPN's "Keyshawn, JWill and Max," Max Kellerman spoke about Curry's legacy. He feels that Curry has a case for being the best player in the world but not for being the greatest of all time. Kellerman said that Curry's height and size should not be considered in the greatest player of all time debate. "He is under 6 foot 3, in the history of modern basketball there has never been a player under 6'4 ever who you could say - that's the best player in the world. So, people like to give him credit for that in the GOAT conversation as though it is a pound-for-pound conversation," Kellerman said. There is no pound-for-pound in basketball. Basketball selects out for height and that is why it is so impressive what he's doing. When measuring the greatness of a player, I don't give extra credit for being so incredible that you can do it at a certain height," Kellerman continued. Steph Curry led his team to their fourth championship in eight years after defeating the Boston Celtics. The marksman also won his first Finals MVP trophy. Curry carried the load for the Warriors in the first four games of the series. Curry averaged 31. 2 points, 6 rebounds and 5 assists in the Finals. He shot the ball better than 48% from the field and nearly 44% from the perimeter. He also averaged 2 steals per game. Winning the Finals MVP was the icing on the cake for Steph Curry. This achievement has arguably elevated him into being considered one of the top 10 players. The lack of a Finals MVP trophy has often been used against Steph Curry in arguments about his historical standing. Andre Iguodala won the Finals MVP award in 2015 for the defense he played on LeBron James. Durant won the Finals MVP award in 2017 and 2018. 5 Times Steph Curry Was HUMILIATED On And Off The Court! Poll : Is Steph Curry in the GOAT conversation?
english
GOSWAMI, P.K. GOSWAMI, P.K. BEG, M. HAMEEDULLAH KRISHNAIYER, V.R. Constitution of India, Art. 16-Civil Service--Central Secretariat Service (Reorganisatioin and Reinforcement) Scheme-Home Ministry circular dated 22nd June, 1949-Whether subsequent direct recruits can supersede those who are absorbed in service earlier-Delay and laches. Petitioners are Assistants in Grade IV Class 11 of the Central Secretariat Service. Petitioners were appointed as Assistants during the period 1944-54. The respondent Union of India appointed a large number of persons as Assistants by direct recruitment and many of those appointed after the petitioners have been confirmed in the grade and have since been promoted to the next higher grade of Section Officer. In 1948, the Government framed a Scheme known as the Central Secretariat Service (Reorganisation & Reinforcement) Scheme. Thereafter instructions for the initial constitution of the Assistants Grade were issued in March, 1949. Thereafter, the Ministry of Home Affairs issued Office Memorandum dated June 22, 1949. dealing with the question of seniority. Para 2 of the office memorandum provided that the rule of seniority on the basis of length of service should be taken as a model in framing the rules of seniority for other Ser- vices. The main question to be determined in the present petition is whether the office memorandum of June, 1949 is applicable in determining seniority of the petitioners. HELD'. Office Memorandum of June 22, 1949 is no bar lo the Government making separate provision for the mode of constitution and future maintenance of the service of Assistants. The classification made in the instructions cannot be characterised as unreasonable. There is no discrimination amongst equals nor any arbitrary exercise of powers by the Government. In the absence of any statutory rules prior to the Central Secretariat Service Rules 1962 it was open to Government in exercise of its executive power to issue administrative instructions with regard to constitution and reorganisation of the Service as long as there is no violation of Arts. 14 and 16 of the Constitution. The instructions of the Government issued from time to time do not violate any fundamental rights of the petitioners. In the present petition, the Civil List of 1962 has not been challenged as invalid. Only office Memorandum of 1971 is challenged. The said Memorandum of 1971 is based on the civil list of 1962. The validity of which is not specifically challenged in the petition. There is no infirmity in the Memorandum of 1971 simply because it is not in conformity with the Memorandum of 22-6-1949. ORIGINAL JURISDICTION : Writ Petition No. 163 of 1972. Petition under Art. 32 of the Constitution of India. S. S. Javali and B. P. Singh, for the petitioners. M. N. Phadke and R. N. Sachthey, for respondent No. 1. P. P. Rao and A. K. Ganguli, for respondent No. 2 & the interveners. T. V. S. Narasimhachari, for respondent Nos. 27-32. The Judgment of the Court was delivered by Goswami, J.-The petitioners are Assistants in Grade IV (Class II Non-gazetted) of the Central Secretariat Service (briefly the Service) and have been working in the various Ministries of the Government of India. They were appointed as Assistants during the period between 1944 and 1954. Their next promotional post is now that of Section Officer (Class 11, Gazetted). They have raised in this Writ Petition the question of their seniority and challenged the validity of the Office Memorandum of 7th September, 1971, issued by the first Respondent fixing zones for promotion to the grade of Section Officer on the basis or ranks assigned in the Civil List of 1962 for the grade of Assistant on the ground of being in contravention of the Office Memorandum of June 22, 1949, of the Ministry of Home Affairs. They also challenge the validity of rule 18(1) of the Central Secre- tariat Service Rules, 1962 (briefly the Rules) in so far as it is construed to protect the seniority determined prior to the commencement of the said Rule in violation of the Office Memorandum of June 22, 1949. The petitioners allege that the Government have not followed any consistent principle or rule in regulating the seniority of the Assistants. It is said the first Respondent prepared lists of officers in the Assistant's Grade by different combination of classifications, such as initial constitution, regular temporary establishments, non-test category, first test category, second test category, hard cases category, dis- placed persons, direct recruits, etc. and effected promotions in utter disregard of the dates of confirmation. The first Respondent appointed a large number of persons as Assistants by direct recruitment and many of those appointed after the petitioners have been confirmed in the grade and have since been promoted to the next higher grade of Section Officer. According to the petitioners glaring instance of arbitrary action is the assignment of en bloc seniority to persons appointed by direct recruitment in 1956 exceeding 800 in number who have been assigned seniority over all the petitioners appointed as Assistants long prior thereto. Such instances were there also in 1958 and 1959. In retrospect, on July 19, 1948, the Government framed a scheme known as the Central Secretariat Service (Re- organisation and Reinforcement) Scheme (briefly the Scheme). It constituted four grades in the Service, namely, Under Secretary (Grade 1), Superintendent (Grade II). Assistant Superintendent (Grade 111) and Assistant (Grade IV). The Scheme was, however, not implemented until November 1951. Under para 15 of the Scheme, the authorised permanent strength of the Service will be fixed by the Ministry of Home Affairs with the concurrence of the Ministry of Finance. It was recog- 203 nised therein that "it is essential from the point of view alike of economy and efficiency that as large a proportion as possible members of the Service should be recruited on a permanent basis. A flexible system of fixation of Authorised Permanent Strength will therefore be followed .... should be revised once in every three years". It is also mentioned in the same paragraph that "if as a result of any such triennial refixation, the Authorised Permanent Strength is reduced, effect should given to such reduction by equivalent reduction in the following triennium of the rate of direct recruitment to the Service and Promotions from grade to grade." It is also particularly mentioned in the said paragraph that "the rights of members appointed to the Service on a permanent basis will not be prejudiced by any revision of permanent strength, effected subsequent to such appointment". Under Paragraph 19 of the Scheme, after the Authorised Permanent Strength of the Service is determined, the initial constitution of the Service will be undertaken, and, inter alia, appointments to Grade IV will be completed within thirty months. Under para 25 of the Scheme, the mode of constitution of Grade IV is as follows:- "Assistants who have already been appointed on a permanent basis and are not appointed to a higher grade in the Service as reorganised will be appointed permanently to Grade IV first. The remaining vacancies in Grade IV will be filled by persons who are 'qualified' in terms of the Ministry of Home Affairs Office Memorandum No. 23/20/48-NGS, dated the 25th May, 1948. As contemplated in that Memo- randum two tests will be held by the Federal Public Service Commission in which the temporary 'qualifiables' as defined therein will be enabled to qualify for permanent absorption in Grade IV. In the first of two tests only qualifiable temporary Assistants will be allowed to appear. It would then be considered with reference to the number of vacancies to be filled as well as the number of qualifiable candidates remaining whether, and if so to what extent, the seco nd test should be thrown open partially to the outsiders also". Paragraph 26 in Part V of the Scheme dealing with future maintenance of the Service, provides, inter alia, for the recruitment as follows :- Permanent vacancies in the Authorised Permanent Strength of this Grade will be filled in two ways. One out of every 4 vacancies will be filled, Ministry-wise, by promotion from the Ministerial Grades below the rank of Assistant. The remaining 3 vacancies will be pooled for the Central Secretariat as a whole and filled from among the successful candidates at the competitive Ministerial Services Examination held by the Federal Public Service Commission, The, quali- fications for admission to- this examination will continue to be graduates in the age- groups 20-22 with relaxation of age limit for the Scheduled Castes". 204 With regard to promotion it is stated in the said paragraph as follows :- ,,Assistants who have completed 5 years' but not more than 10 years' service in their grade will be eligible for promotion by selection based strictly on the result of a limited competitive test held among Assistants of that Service group to the rank of Assistant Superintendent, provided that no Assistant will be allowed more than three consecutive chances to compete in this test. Those Assistants who are not so promoted will also be eligible in due course for promotion based on seniority, subject to the rejection of the unfit, to vacancies in the Grade of Assistant Superintendent which would be reserved for being filled by such promotion". Under para 31 of the Scheme, leave, pension and other conditions of service will be as applicable at present to all officers of Central Services, Class I or II, as the case may be. After the publication of the Scheme, the Ministry of Home Affairs on October 25, 1948, circulated an explanatory memorandum explaining the nature and purpose of the Service. The Central Secretariat is pithily described therein as "the workshop of policy" which helps the Government to make and revise policies and to create, maintain and direct the organs which execute the policies. The Assistants, we are concerned with, are the fifth layer at the lowest rung of the Secretariat Department and are engaged on case work as distinguished from clerks and typists employed on routine work in a separate lower service. It was pointed out that there was a phenomenal expansion in the Service as would be reflected from the figures, for example, of Assistants in 1939 at 493 which rose upto 2306 in 1948. This is said to have affected the quality of the Service which includes a large number of staff employed on a temporary basis. In 1948 itself the entire number of 2306 Assistants, except 95, were temporary employees. It was further mentioned in the explanatory note that "reinforcement is not required at the lowest level, viz., the Assistants, Grade. Here what is necessary is the weeding out of the poor quality material and the improvement of efficiency of the rest through a permanent tenure and better training and guidance?. Then in sequence came the instructions for the initial constitution of the Assistants' Grade of the Service on March 1, 1949. These instructions governed the manner in which the sanctioned permanent strength of the grade of Assistants would be filled by existing permanent Assistants and from various categories of existing temporary employees. The scheme of the Instructions contains these broad features (1) All existing permanent Assistants who are not appointed to higher grades in the Service will form part of the permanent strength of the Service. 205 (2) The remaining number of permanent vacancies in the Grade will be divided among three categories, namely, (i) The Non Test Category, (ii) The First Test Category and (iii) The Second Test Category. A particular specified number of vacancies will be allotted to the Non Test Category and the remaining vacancies will be divided among the First Test Category and the Second Test Category in the ratio 2 : 1. There is also reservation of a specific number of vacancies for allotment to Displaced Government servants. There are five categories of employees which are included in the Non Test Category and for them there will be two separate lists, namely, (a) for Displaced Government servants and (b) for others. Both the lists will be drawn up ranking the employees in order of seniority according to their length of service. The employees who are included in these lists will be eligible for permanent appointments in accordance with their position in the lists upto the respective quotas prescribed for them. It will, therefore, appear that although there may be a large number of employees included in the lists of Non Test Category, all may not be absorbed in the permanent vacancies but only these in order of seniority in the lists upto the sanctioned strength of the vacancies in the Non Test Category. ,Next comes those Assistants who are eligible to be considered for permanent appointment to the vacancies reserved for the First Test Category by qualifying at the first test to be held by the Federal Public Service Commission. Here again on the results of the first test candidates in order of merit upto the number of vacancies allotted to this category will be confirmed in the grade. That is to say, although there may be a large number of temporary Assistants who may have qualified at the first test, only the candidates in order- of merit upto their quota in this category will be confirmed. Similarly there will also be a Second Test Category which will include candidates who have qualified in the test but only these candidates in the order of merit upto the number of vacancies allotted to this Category will be confirmed. The inter se seniority of the confirmed employees in the Non Test Category, The First Test Category and The Second Test Category wilt be according to their length of service. Paragraph 8 of the instructions which deals with seniority of Assistants in Grade IV as newly constituted, which is even quoted in the Office Memorandum of June 22, 1949, provides in substances,follows :- All existing permanent Assistants who were confirmed in their posts prior to October 22, 1948, will be arranged in the first instance Ministry-wise in accordance with the rules in force then. They will be senior to all others confirmed thereafter in vacancies arising upto October 22, 1950. Those who are confirmed after 1943 in vacancies arising upto October 22, 1950, will be arranged in a single list for all Ministries and their seniority inter se will be determined on 206 the basis of their length of continuous service temporary or permanent in the grade of Assistant or in an equivalent grade. After the sanctioned strength of the permanent establishment has been filled up as set out earlier, the remaining persons in the Non Test, First Test and Second Test Categories, because of lack of sanctioned strength in the various categories, could not be absorbed will form a regular temporary establishment (R.T.E.). There will be a single seniority list for such R.T.E. and seniority will be determined on the basis of the length of continuous service. The sanctioned strength of the service upto October 22, 1950, will be filled as above. Thereafter a proportion of future permanent vacancies will be, filled by appointments, based upon seniority from the list of members of the R.T.E. The next stage is reached when instructions for the constitution and maintenance of the regular temporary establishment of Assistants were issued on August 26, 1952. The R.T.E. as initially constituted is as follows :- A list (List A) arranged in order of seniority as Assistants shall be prepared of all existing Assistants that is those holding Posts of Assistant as on July 1, 1952 and not confirmed in Grade IV and of others specifically mentioned in sub-para (2) (i) of para 3 of the instructions. These left over from the two Non Test lists mentioned earlier are entered in one list (List B) in accordance With seniority with some weightage for Displaced Government servants. The lists of persons who have qualified in the First and the Second Test Categories but not confirmed in the service are referred to as Lists C and D respectively. For the first time a rotation system is introduced as per sub-para (5) of these instructions in so far as appointments to the R.T.E. shall now be made one from each list in serial order from the top of each list until 1200 persons are chosen. There is, however, an overall reservation of 121/2% for Scheduled Castes and 5% for Schedule Tribes. Persons who are neither permanent members of Grade TV nor members of the R.T.E. of Assistants are referred to as "Ex-cadre" Assistants. Under para 4 of these instructions the list of R.T E. prepared in accordance with para 3(5) shall be the Gradation List of the R.T.E. at its initial constitution. Para 6 provides that the persons appointed to the R.T.E. at its initial constitution shall be senior to these appointed later. The latter shall rank inter se in the order of their appointment to the R.T.E. in accordance with para 5(4) of the instructions. Para 9 provides that all permanent vacancies in Grade IV not filled by direct recruitment on the results of competitive examination held by the Union Public Service Commission shall be filled from the R.T.E. in the order of the Gradation List subject to certain proviso, the first one being that not less than one-fourth of the vacancies shall be reserved for permanent Clerks. Then in the wake of these instructions came the Ministry of Home Affairs' Office Memorandum of June 22, 1949, dealing with the subject of "seniority of the displaced Government servants who have been absorbed temporarily in service under the Central Government". Paragraph 2 of the said Office Memorandum may be set out 207 The question of seniority of Assistants in the Secretariat was recently examined very carefully in consultation with all the Ministries and the Federal Public Service Commission and the decisions reached are incorporated in para 2 of the Instructions far the initial constitution of the grade of Assistants. This paragraph 8 which is mentioned is the, one which is quoted earlier from the Instructions of March 1, 1949, which was expressly intended for the initial constitution of the Assistant's Grade of the Central Secretariat Services. The principle which was adumbrated in the Office Memorandum of June 22, 1949, is the same as has been earlier mentioned in paragraph 8 of the Instructions of March 1949. In paragraph 11 of the counter-affidavit of the Deputy Secretary to the Government of India, Department of Personnel, Cabinet Secretariat, it is stated as follows :- "I say that the statement;that persons who were appointed long after the petitioners' appointment as Assistants have been further promoted in supersession of the claims of the petitioners is a statement made shorn of its context. That criticism would have been valid if with regard to the Assistants of the Central Secretariat Service the Office Memorandum of 1949 was applicable under which length of service was the criterion in the matter of determining seniority. " with refer- ence to Annexure 'B' to the writ petition I am advised to submit that if the 1949 or 1959 Office Memorandum were applicable to the petitioners' case, then Annexure 'B' w ould be valid and this respondent would have no reply thereto but, unfortunately, for the petitioner, they being governed by different principles as regards seniority and art any rate they being not governed by 1948 or 1959 Office Memorandum, it is only a futile exercise to find out what would have been their seniority in the Civil List of 1962 and 1949 Office Memorandum applied to them". It may be noted that Annexure 'B' to the Petition is a statement showing the order of seniority had it been based on length of service as Assistant. The principal question that arises for consideration in this case is whether the Office Memorandum of June 22, 1949, is applicable in determining seniority of the petitioners. Para 2 of the Office Memorandum as quoted above clearly shows that paragraph 8 which contains the rule of seniority being length of continuous service was in terms applicable to the initial constitution of the grade of Assistants. The said rule of seniority should be taken as "the medal in framing the rules of seniority for other services". This would go to demonstrate that the Office Memorandum of June 22, 1949, is no bar to the Government in making separate provisions for the mode of constitution. and future maintenance of the service of Assistants. There is, there- fore, no obligation under the aforesaid Office Memorandum on the part of the Government to enforce a rule of bald length of continuous 208 service irrespective of other considerations then the service was sought to be reorganised and reinforced. As noticed earlier the service had to be reconstituted and the temporary Assistants properly observed keeping in view the question of quality and efficiency as well as at the same where regard being had to accommodate as large number as possible for gradual absorption. In doing so we are unable to hold that the Government has violated the provisions of articles 14 or 16 of the Constitution. The classification under the instructions for the constitution of regular temporary establishment in the manner done cannot be characterised as unreasonable in view of the object for which these had to be introduced in reconstituting the service to ensure security of temporary employees assistant with efficiency in the Service. There is no discrimination whatsoever amongst the equals as such nor any arbitrary exercise of power by the Government. In absence of any statutory rules prior to the Central Secretariat Rules 1962 it was open to the Government in exercise of its executive power to issue administrative instructions with regard to constitution and reorganisation of the Service as long as there is no violation of article 14 or article 16 of the Constitution. Subject to what is observed hereafter, as held above we do not find that the instructions of the Government made from time to time violated any fundamental rights of the petitioners. We should also observe that the various Office Memorandum and instructions including the Civil list of 1962 have not been challenged as invalid with the solitary exception of the Office Memorandum of 1971 (Annexure 1). This Office Memorandum again is based on the Civil List of 1962 the validity of which is not specifically challenged in this Petition. We, therefore, do not find any infirmity in the Office Memorandum of 1971 (Annexure 1), simply because it is not in conformity with the Office Memorandum of June 22, 1949. Besides, it is stated in the counter-affidavit of the Deputy Secretary (page 176 of the record) that "the Office Memorandum of 1971 is no longer operative. " We have seen that the rule of length of continuous service has been adopted in the case of different categories reconstituted in the Service in accordance with the administrative instructions of the Home Ministry issued after consultation with the Union Public Service Commission. The grievance that the said Office Memorandum should have been applied to all the temporary employees without the requirement of their being eligible in accordance with other instructions is without any foundation and cannot be upheld. A regular set of separate instructions governed the Service the existence of which cannot be explained if the Office Memorandum of June 22, 1949, alone were applicable, de hors these other instructions. It is further contended that rule 18 of the Rules is invalid in so far as it protects the seniority of the Assistants already observed violating the rule of continuous length of service amongst the entire group as a whole. This argument is untenable as the rule of continuous length of service cannot be invoked unless the temporary Assistants are absorbed in the Service in accordance, with the instructions which are valid. The entire group of temporary Assistants cannot claim seniority by the rule of length of continuous service without prior compliance with the conditions laid down under the instructions. Rule 1 8 is, there- 209 lore, not violative of article 14 or article 16 of,the Constitution on the score of giving effect to the earlier or other instructions which are not found to be otherwise objectionable. That leaves one more question to be resolved, that is, with reference to the direct recruits. Once the temporary Assistants have been absorbed in the service after they are found to be eligible in accordance with the instructions their claim for seniority cannot be superseded by the direct recruits if appointed after the former's absorption in the Service. This conclusion is based on the following factors :- Although the Scheme was made in July 1948 it was not enforced until November 1951. Even then there was no direct recruitment until 1956. The reasons for delaying direct recruitment can be found from a perusal of paragraph 15 of the 1948 Scheme itself,that "it is essential from the point of view alike of economy and efficiency that as large a proportion is possible of the members of the service should be recruited on a permanent basis. If the Authorised permanent strength is reduced, effect should be given to such reduction by equivalent reduction in the following triennium of the rate of direct recruitment to the Service. It was, therefore, not the intention of the scheme to prejudice the seniority of the Assistants after their absorption in the Service nor such an intention was evident in the explanatory memorandum annexed to the Office Memorandum of October 25, 1948. In para 11 of the latter Memorandum it is unambiguously stated the "reinforcement is not required at the lowest level, namely., the Assistants' Grade. Here what is necessary is the: weeding out of the poor quality material and the improvement of efficiency- of the rest. through permanent tenure and better training d guidances. This is also clear from the instructions for the constitution and maintenance of the regular temporary establishment of Assistants dated August 26, 1968. Para 9 thereof provides that "all permanent vacancies in Grade IV not filled by direct recruitment on the results of Competitive Examination, held by the Union Public Service Commission shall be filled from the Regular Temporary Estab- lishment in the order of Gazetted List" subject to certain provisions with which we are not concerned. It appears the quota, if any, of direct recruitment Was Dot enforced and perhaps for good reasons as noted above, the policy of the Government being different. Administrative instructions, if not carried into effect for obvious and good reasons, cannot confer a right upon entrants on later recruitment to enforce the same to supersede the claims of others already absorbed in the Service in accordance with the appropriate and valid instructions. Nothing was brought to our notice which could justify such a wholesale or en bloc discrimination in favour of those who suddenly enter the same grade of service by direct recruitment. It would, if permitted, be violative of article 16 of the Constitution which should never be overlooked in such cases. We are, therefore, clearly of opinion that the direct recruits who were appointed after the absorption of the Assistants, in conformity with the instructions of the initial constitution or in regular temporary 15-L379 Sup. CI/75 210 establishment shall rank junior to the latter. We, therefore, direct that the seniority of such Assistants shall be adjusted and the seniority list corrected accordingly. This will, however, not affect the cases of these Assistants who are already promoted and confirmed in a higher rank prior to the date of this petition. The learned counsel for the respondents strenuously contended that the petition may be dismissed on account of delay and laches. In view of the entire circumstances of the case and the hopes held out by the Government from time to time we are not prepared to accede to this submission. The petitioners also sought to take advantage of what they described as admission in Government's affidavits filed in connection with certain earlier proceedings of similar nature and other admissions in Parliament on behalf of the Government. We, are, however, unable to hold that such admissions, if any, which are mere expression of opinion limited to the context and also being rather vague hopes, not specific assurances, are binding on the Government to create an estoppel. In the view we have taken the case is distinguishable from Union of India and Ors. v. M. Ravi Yarma and Ors. etc.(1) principally relied upon by the petitioners. In the result the petition is partly allowed only to the extent that the Assistants who have been absorbed in the Service in conformity with the instructions will rank senior to the direct recruits appointed after such absorption. The seniority list shall be adjusted and corrected accordingly. This direction will, however, not affect those Assistants who have already been promoted and confirmed in a higher rank prior to the date of this petition. In the circumstances of the case we leave the parties to bear their own costs. P.H.P. Petition allowed in part.
english
<filename>src/client/app/shared/service/auth_guard/authguard.service.ts // Authguard Service import { Injectable } from '@angular/core'; import { Location } from '@angular/common'; import { Router, CanActivate } from '@angular/router'; import { Observable } from 'rxjs/Observable'; import 'rxjs/add/observable/of'; import { Http, Response } from '@angular/http'; import { CookieService } from 'ngx-cookie'; import { Config } from '../..//config/env.config'; import { IUser } from '../..//model/index'; import { ContentHeaderService } from '../index'; @Injectable() export class AuthGuard implements CanActivate { public user:IUser; constructor(private router: Router, private http:Http, private _contentHeaderService:ContentHeaderService, private _cookieService:CookieService ) { } // Method to check if user is logged in canActivate():Observable<boolean> { return this.checkLoggedIn() .map((response:Response) => this.handleSuccess(response)) .catch(this.logError); } checkLoggedIn(): Observable<any> { let options = this._contentHeaderService.getOptions(null); return this.http.get(Config.APIURL+'auth/me', options) .map((response:Response) => this.handleMeResponse(response)) .catch((err:Response) => this.handleMeError(err)); } // Logout User Didnt put it in auth service coz it causes circular dependency logout(): Observable<any> { let body = {}; let options = this._contentHeaderService.getOptions(null); return this.http.post(Config.APIURL+'auth/logout', body, options) .map((response:Response) => this.handleLogoutResponse(response)) .catch((err:Response) => this.handleLogoutError(err)); } private handleSuccess(response:any) { return true; } private logError(error:any) { return Observable.of(false); } private handleMeResponse(res:Response) { this.user = res.json(); return true; } private handleMeError(err: Response) { this.logout().subscribe(); return Observable.throw('Internal server error'); } private handleLogoutResponse(res:Response) { this.performLogout(res); } private handleLogoutError(err: Response) { this.performLogout(err); return Observable.throw('Internal server error'); } private performLogout(res:Response) { if(this._cookieService.get('token')) { this._cookieService.remove('token'); } this.router.navigate(['/login']); } }
typescript
<reponame>duxuso/jasmine-openWindow<gh_stars>0 <!DOCTYPE html> <html> <head lang="en"> <meta charset="UTF-8"> <title>JavaScript Requirement 7</title> <script src="lib/jquery.js"></script> <script src="src/jquery.openWindow.js"></script> </head> <body> <!-- HTML table for display --> <table cellpadding="0" cellspacing="0" align="center" bgcolor="#f0fff0"> <tr><td align="left" valign="top" style="font-family: Helvetica, Arial, sans-serif;border: solid #808080 2px;"> <table cellpadding="0" cellspacing="0" width="800px" border="1"> <thead><tr><td align="center" valign="top" colspan="3" style="font-family: Helvetica, Arial, sans-serif;"><h2>Javascript Requirements</h2></td></tr></thead> <tbody><tr><td align="left" valign="top" height="40px" style="font-family: Helvetica, Arial, sans-serif;" colspan="3" bgcolor="#87cefa"><b>Requirement 7</b> Write a jQuery plugin which, given a jQuery object containing anchor elements (e.g $('a')), makes clicking on those elements open the link target in a new window.<br/> The plugin should:<br/><ul><li>Ensure that links with the same data­window­group open in the same window</li><li>Take an option object used to set the features on the new window (size, position, scrollbars, etc.), sensible defaults should be supplied by the plugin.</li></ul></td></tr> <tr><td align="center" valign="middle" height="40px" style="font-size: 14px;"><a href="http://www.google.com" data-window-group="group1" >the group 1 link 1 (Google)</a></td></tr> <tr><td align="center" valign="middle" height="40px" style="font-size: 14px;"><a href="http://www.apple.com" data-window-group="group2" >the group 2 link 1 (Apple)</a></td></tr> <tr><td align="center" valign="middle" height="40px" style="font-size: 14px;"><a href="http://www.amazon.com" data-window-group="group1" >the Group 1 link 2 (Amazon)</a></td></tr> <tr><td align="center" valign="middle" height="40px" style="font-size: 14px;"><a href="http://www.facebook.com" data-window-group="group2" >the Group 2 link 2 (Facebook)</a></td></tr> <tr><td align="center" valign="middle" height="40px" style="font-size: 14px;" class="options"><a href="http://www.stackoverflow.com" data-window-group="group1" >the Group 1 link 3 (StackOverflow)</a></td></tr> </tbody> </table> </td></tr> </table> <!-- call openWindow plugin, given anchor 'a' element, without 'options' --> <script> $('a').openWindow(); </script> </body> </html>
html
<gh_stars>0 <!DOCTYPE html> <html xmlns="http://www.w3.org/1999/xhtml" lang="" xml:lang=""> <head> <meta charset="utf-8" /> <meta name="generator" content="pandoc" /> <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" /> <title>article</title> <style type="text/css"> code{white-space: pre-wrap;} span.smallcaps{font-variant: small-caps;} span.underline{text-decoration: underline;} div.column{display: inline-block; vertical-align: top; width: 50%;} </style> <style type="text/css"> a.sourceLine { display: inline-block; line-height: 1.25; } a.sourceLine { pointer-events: none; color: inherit; text-decoration: inherit; } a.sourceLine:empty { height: 1.2em; } .sourceCode { overflow: visible; } code.sourceCode { white-space: pre; position: relative; } div.sourceCode { margin: 1em 0; } pre.sourceCode { margin: 0; } @media screen { div.sourceCode { overflow: auto; } } @media print { code.sourceCode { white-space: pre-wrap; } a.sourceLine { text-indent: -1em; padding-left: 1em; } } pre.numberSource a.sourceLine { position: relative; left: -4em; } pre.numberSource a.sourceLine::before { content: attr(title); position: relative; left: -1em; text-align: right; vertical-align: baseline; border: none; pointer-events: all; display: inline-block; -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; padding: 0 4px; width: 4em; color: #aaaaaa; } pre.numberSource { margin-left: 3em; border-left: 1px solid #aaaaaa; padding-left: 4px; } div.sourceCode { } @media screen { a.sourceLine::before { text-decoration: underline; } } code span.al { color: #ff0000; font-weight: bold; } /* Alert */ code span.an { color: #60a0b0; font-weight: bold; font-style: italic; } /* Annotation */ code span.at { color: #7d9029; } /* Attribute */ code span.bn { color: #40a070; } /* BaseN */ code span.bu { } /* BuiltIn */ code span.cf { color: #007020; font-weight: bold; } /* ControlFlow */ code span.ch { color: #4070a0; } /* Char */ code span.cn { color: #880000; } /* Constant */ code span.co { color: #60a0b0; font-style: italic; } /* Comment */ code span.cv { color: #60a0b0; font-weight: bold; font-style: italic; } /* CommentVar */ code span.do { color: #ba2121; font-style: italic; } /* Documentation */ code span.dt { color: #902000; } /* DataType */ code span.dv { color: #40a070; } /* DecVal */ code span.er { color: #ff0000; font-weight: bold; } /* Error */ code span.ex { } /* Extension */ code span.fl { color: #40a070; } /* Float */ code span.fu { color: #06287e; } /* Function */ code span.im { } /* Import */ code span.in { color: #60a0b0; font-weight: bold; font-style: italic; } /* Information */ code span.kw { color: #007020; font-weight: bold; } /* Keyword */ code span.op { color: #666666; } /* Operator */ code span.ot { color: #007020; } /* Other */ code span.pp { color: #bc7a00; } /* Preprocessor */ code span.sc { color: #4070a0; } /* SpecialChar */ code span.ss { color: #bb6688; } /* SpecialString */ code span.st { color: #4070a0; } /* String */ code span.va { color: #19177c; } /* Variable */ code span.vs { color: #4070a0; } /* VerbatimString */ code span.wa { color: #60a0b0; font-weight: bold; font-style: italic; } /* Warning */ </style> </head> <body> <h1 id="custom-elements">Custom elements</h1> <p>We can create custom HTML elements, described by our class, with its own methods and properties, events and so on.</p> <p>Once a custom element is defined, we can use it on par with built-in HTML elements.</p> <p>That’s great, as HTML dictionary is rich, but not infinite. There are no <code>&lt;easy-tabs&gt;</code>, <code>&lt;sliding-carousel&gt;</code>, <code>&lt;beautiful-upload&gt;</code>… Just think of any other tag we might need.</p> <p>We can define them with a special class, and then use as if they were always a part of HTML.</p> <p>There are two kinds of custom elements:</p> <ol type="1"> <li><strong>Autonomous custom elements</strong> – “all-new” elements, extending the abstract <code>HTMLElement</code> class.</li> <li><strong>Customized built-in elements</strong> – extending built-in elements, like a customized button, based on <code>HTMLButtonElement</code> etc.</li> </ol> <p>First we’ll cover autonomous elements, and then move to customized built-in ones.</p> <p>To create a custom element, we need to tell the browser several details about it: how to show it, what to do when the element is added or removed to page, etc.</p> <p>That’s done by making a class with special methods. That’s easy, as there are only few methods, and all of them are optional.</p> <p>Here’s a sketch with the full list:</p> <div class="sourceCode" id="cb1"><pre class="sourceCode js"><code class="sourceCode javascript"><a class="sourceLine" id="cb1-1" title="1"><span class="kw">class</span> MyElement <span class="kw">extends</span> HTMLElement <span class="op">{</span></a> <a class="sourceLine" id="cb1-2" title="2"> <span class="at">constructor</span>() <span class="op">{</span></a> <a class="sourceLine" id="cb1-3" title="3"> <span class="kw">super</span>()<span class="op">;</span></a> <a class="sourceLine" id="cb1-4" title="4"> <span class="co">// element created</span></a> <a class="sourceLine" id="cb1-5" title="5"> <span class="op">}</span></a> <a class="sourceLine" id="cb1-6" title="6"></a> <a class="sourceLine" id="cb1-7" title="7"> <span class="at">connectedCallback</span>() <span class="op">{</span></a> <a class="sourceLine" id="cb1-8" title="8"> <span class="co">// browser calls this method when the element is added to the document</span></a> <a class="sourceLine" id="cb1-9" title="9"> <span class="co">// (can be called many times if an element is repeatedly added/removed)</span></a> <a class="sourceLine" id="cb1-10" title="10"> <span class="op">}</span></a> <a class="sourceLine" id="cb1-11" title="11"></a> <a class="sourceLine" id="cb1-12" title="12"> <span class="at">disconnectedCallback</span>() <span class="op">{</span></a> <a class="sourceLine" id="cb1-13" title="13"> <span class="co">// browser calls this method when the element is removed from the document</span></a> <a class="sourceLine" id="cb1-14" title="14"> <span class="co">// (can be called many times if an element is repeatedly added/removed)</span></a> <a class="sourceLine" id="cb1-15" title="15"> <span class="op">}</span></a> <a class="sourceLine" id="cb1-16" title="16"></a> <a class="sourceLine" id="cb1-17" title="17"> <span class="kw">static</span> get <span class="at">observedAttributes</span>() <span class="op">{</span></a> <a class="sourceLine" id="cb1-18" title="18"> <span class="cf">return</span> [</a> <a class="sourceLine" id="cb1-19" title="19"> <span class="co">/* array of attribute names to monitor for changes */</span></a> <a class="sourceLine" id="cb1-20" title="20"> ]<span class="op">;</span></a> <a class="sourceLine" id="cb1-21" title="21"> <span class="op">}</span></a> <a class="sourceLine" id="cb1-22" title="22"></a> <a class="sourceLine" id="cb1-23" title="23"> <span class="at">attributeChangedCallback</span>(name<span class="op">,</span> oldValue<span class="op">,</span> newValue) <span class="op">{</span></a> <a class="sourceLine" id="cb1-24" title="24"> <span class="co">// called when one of attributes listed above is modified</span></a> <a class="sourceLine" id="cb1-25" title="25"> <span class="op">}</span></a> <a class="sourceLine" id="cb1-26" title="26"></a> <a class="sourceLine" id="cb1-27" title="27"> <span class="at">adoptedCallback</span>() <span class="op">{</span></a> <a class="sourceLine" id="cb1-28" title="28"> <span class="co">// called when the element is moved to a new document</span></a> <a class="sourceLine" id="cb1-29" title="29"> <span class="co">// (happens in document.adoptNode, very rarely used)</span></a> <a class="sourceLine" id="cb1-30" title="30"> <span class="op">}</span></a> <a class="sourceLine" id="cb1-31" title="31"></a> <a class="sourceLine" id="cb1-32" title="32"> <span class="co">// there can be other element methods and properties</span></a> <a class="sourceLine" id="cb1-33" title="33"><span class="op">}</span></a></code></pre></div> <p>After that, we need to register the element:</p> <div class="sourceCode" id="cb2"><pre class="sourceCode js"><code class="sourceCode javascript"><a class="sourceLine" id="cb2-1" title="1"><span class="co">// let the browser know that &lt;my-element&gt; is served by our new class</span></a> <a class="sourceLine" id="cb2-2" title="2"><span class="va">customElements</span>.<span class="at">define</span>(<span class="st">&quot;my-element&quot;</span><span class="op">,</span> MyElement)<span class="op">;</span></a></code></pre></div> <p>Now for any HTML elements with tag <code>&lt;my-element&gt;</code>, an instance of <code>MyElement</code> is created, and the aforementioned methods are called. We also can <code>document.createElement('my-element')</code> in JavaScript.</p> <p>``<code>smart header="Custom element name must contain a hyphen</code>-<code>" Custom element name must have a hyphen</code>-<code>, e.g.</code>my-element<code>and</code>super-button<code>are valid names, but</code>myelement` is not.</p> <p>That’s to ensure that there are no name conflicts between built-in and custom HTML elements.</p> <pre><code> ## Example: &quot;time-formatted&quot; For example, there already exists `&lt;time&gt;` element in HTML, for date/time. But it doesn&#39;t do any formatting by itself. Let&#39;s create `&lt;time-formatted&gt;` element that displays the time in a nice, language-aware format: ```html run height=50 autorun=&quot;no-epub&quot; &lt;script&gt; *!* class TimeFormatted extends HTMLElement { // (1) */!* connectedCallback() { let date = new Date(this.getAttribute(&#39;datetime&#39;) || Date.now()); this.innerHTML = new Intl.DateTimeFormat(&quot;default&quot;, { year: this.getAttribute(&#39;year&#39;) || undefined, month: this.getAttribute(&#39;month&#39;) || undefined, day: this.getAttribute(&#39;day&#39;) || undefined, hour: this.getAttribute(&#39;hour&#39;) || undefined, minute: this.getAttribute(&#39;minute&#39;) || undefined, second: this.getAttribute(&#39;second&#39;) || undefined, timeZoneName: this.getAttribute(&#39;time-zone-name&#39;) || undefined, }).format(date); } } *!* customElements.define(&quot;time-formatted&quot;, TimeFormatted); // (2) */!* &lt;/script&gt; &lt;!-- (3) --&gt; *!* &lt;time-formatted datetime=&quot;2019-12-01&quot; */!* year=&quot;numeric&quot; month=&quot;long&quot; day=&quot;numeric&quot; hour=&quot;numeric&quot; minute=&quot;numeric&quot; second=&quot;numeric&quot; time-zone-name=&quot;short&quot; &gt;&lt;/time-formatted&gt;</code></pre> <ol type="1"> <li>The class has only one method <code>connectedCallback()</code> – the browser calls it when <code>&lt;time-formatted&gt;</code> element is added to page (or when HTML parser detects it), and it uses the built-in <a href="mdn:/JavaScript/Reference/Global_Objects/DateTimeFormat">Intl.DateTimeFormat</a> data formatter, well-supported across the browsers, to show a nicely formatted time.</li> <li>We need to register our new element by <code>customElements.define(tag, class)</code>.</li> <li>And then we can use it everywhere.</li> </ol> <p>``<code>smart header="Custom elements upgrade" If the browser encounters any</code><time-formatted><code>elements before</code>customElements.define`, that’s not an error. But the element is yet unknown, just like any non-standard tag.</p> <p>Such “undefined” elements can be styled with CSS selector <code>:not(:defined)</code>.</p> <p>When <code>customElement.define</code> is called, they are “upgraded”: a new instance of <code>TimeFormatted</code> is created for each, and <code>connectedCallback</code> is called. They become <code>:defined</code>.</p> <p>To get the information about custom elements, there are methods: - <code>customElements.get(name)</code> – returns the class for a custom element with the given <code>name</code>, - <code>customElements.whenDefined(name)</code> – returns a promise that resolves (without value) when a custom element with the given <code>name</code> becomes defined. ```</p> <p>``<code>smart header="Rendering in</code>connectedCallback<code>, not in</code>constructor<code>" In the example above, element content is rendered (created) in</code>connectedCallback`.</p> <p>Why not in the <code>constructor</code>?</p> <p>The reason is simple: when <code>constructor</code> is called, it’s yet too early. The element is created, but the browser did not yet process/assign attributes at this stage: calls to <code>getAttribute</code> would return <code>null</code>. So we can’t really render there.</p> <p>Besides, if you think about it, that’s better performance-wise – to delay the work until it’s really needed.</p> <p>The <code>connectedCallback</code> triggers when the element is added to the document. Not just appended to another element as a child, but actually becomes a part of the page. So we can build detached DOM, create elements and prepare them for later use. They will only be actually rendered when they make it into the page.</p> <pre><code> ## Observing attributes In the current implementation of `&lt;time-formatted&gt;`, after the element is rendered, further attribute changes don&#39;t have any effect. That&#39;s strange for an HTML element. Usually, when we change an attribute, like `a.href`, we expect the change to be immediately visible. So let&#39;s fix this. We can observe attributes by providing their list in `observedAttributes()` static getter. For such attributes, `attributeChangedCallback` is called when they are modified. It doesn&#39;t trigger for other, unlisted attributes (that&#39;s for performance reasons). Here&#39;s a new `&lt;time-formatted&gt;`, that auto-updates when attributes change: ```html run autorun=&quot;no-epub&quot; height=50 &lt;script&gt; class TimeFormatted extends HTMLElement { *!* render() { // (1) */!* let date = new Date(this.getAttribute(&#39;datetime&#39;) || Date.now()); this.innerHTML = new Intl.DateTimeFormat(&quot;default&quot;, { year: this.getAttribute(&#39;year&#39;) || undefined, month: this.getAttribute(&#39;month&#39;) || undefined, day: this.getAttribute(&#39;day&#39;) || undefined, hour: this.getAttribute(&#39;hour&#39;) || undefined, minute: this.getAttribute(&#39;minute&#39;) || undefined, second: this.getAttribute(&#39;second&#39;) || undefined, timeZoneName: this.getAttribute(&#39;time-zone-name&#39;) || undefined, }).format(date); } *!* connectedCallback() { // (2) */!* if (!this.rendered) { this.render(); this.rendered = true; } } *!* static get observedAttributes() { // (3) */!* return [&#39;datetime&#39;, &#39;year&#39;, &#39;month&#39;, &#39;day&#39;, &#39;hour&#39;, &#39;minute&#39;, &#39;second&#39;, &#39;time-zone-name&#39;]; } *!* attributeChangedCallback(name, oldValue, newValue) { // (4) */!* this.render(); } } customElements.define(&quot;time-formatted&quot;, TimeFormatted); &lt;/script&gt; &lt;time-formatted id=&quot;elem&quot; hour=&quot;numeric&quot; minute=&quot;numeric&quot; second=&quot;numeric&quot;&gt;&lt;/time-formatted&gt; &lt;script&gt; *!* setInterval(() =&gt; elem.setAttribute(&#39;datetime&#39;, new Date()), 1000); // (5) */!* &lt;/script&gt;</code></pre> <ol type="1"> <li>The rendering logic is moved to <code>render()</code> helper method.</li> <li>We call it once when the element is inserted into page.</li> <li>For a change of an attribute, listed in <code>observedAttributes()</code>, <code>attributeChangedCallback</code> triggers.</li> <li>…and re-renders the element.</li> <li>At the end, we can easily make a live timer.</li> </ol> <h2 id="rendering-order">Rendering order</h2> <p>When HTML parser builds the DOM, elements are processed one after another, parents before children. E.g. if we have <code>&lt;outer&gt;&lt;inner&gt;&lt;/inner&gt;&lt;/outer&gt;</code>, then <code>&lt;outer&gt;</code> element is created and connected to DOM first, and then <code>&lt;inner&gt;</code>.</p> <p>That leads to important consequences for custom elements.</p> <p>For example, if a custom element tries to access <code>innerHTML</code> in <code>connectedCallback</code>, it gets nothing:</p> ```html run height=40 <script> customElements.define('user-info', class extends HTMLElement { connectedCallback() { *!* alert(this.innerHTML); // empty (*) */!* } }); </script> <p><em>!</em> <user-info>John</user-info> <em>/!</em> ```</p> <p>If you run it, the <code>alert</code> is empty.</p> <p>That’s exactly because there are no children on that stage, the DOM is unfinished. HTML parser connected the custom element <code>&lt;user-info&gt;</code>, and is going to proceed to its children, but just didn’t yet.</p> <p>If we’d like to pass information to custom element, we can use attributes. They are available immediately.</p> <p>Or, if we really need the children, we can defer access to them with zero-delay <code>setTimeout</code>.</p> <p>This works:</p> ```html run height=40 <script> customElements.define('user-info', class extends HTMLElement { connectedCallback() { *!* setTimeout(() => alert(this.innerHTML)); // John (*) */!* } }); </script> <p><em>!</em> <user-info>John</user-info> <em>/!</em> ```</p> <p>Now the <code>alert</code> in line <code>(*)</code> shows “John”, as we run it asynchronously, after the HTML parsing is complete. We can process children if needed and finish the initialization.</p> <p>On the other hand, this solution is also not perfect. If nested custom elements also use <code>setTimeout</code> to initialize themselves, then they queue up: the outer <code>setTimeout</code> triggers first, and then the inner one.</p> <p>So the outer element finishes the initialization before the inner one.</p> <p>Let’s demonstrate that on example:</p> ``<code>html run height=0 &lt;script&gt; customElements.define( "user-info", class extends HTMLElement { connectedCallback() { alert(</code><span class="math inline">${this.id} connected.`); setTimeout(() =&gt; alert(`$</span>{this.id} initialized.`)); } } ); </script> <p><em>!</em> <user-info id="outer"> <user-info id="inner"></user-info> </user-info> <em>/!</em> ```</p> <p>Output order:</p> <ol type="1"> <li>outer connected.</li> <li>inner connected.</li> <li>outer initialized.</li> <li>inner initialized.</li> </ol> <p>We can clearly see that the outer element finishes initialization <code>(3)</code> before the inner one <code>(4)</code>.</p> <p>There’s no built-in callback that triggers after nested elements are ready. If needed, we can implement such thing on our own. For instance, inner elements can dispatch events like <code>initialized</code>, and outer ones can listen and react on them.</p> <h2 id="customized-built-in-elements">Customized built-in elements</h2> <p>New elements that we create, such as <code>&lt;time-formatted&gt;</code>, don’t have any associated semantics. They are unknown to search engines, and accessibility devices can’t handle them.</p> <p>But such things can be important. E.g, a search engine would be interested to know that we actually show a time. And if we’re making a special kind of button, why not reuse the existing <code>&lt;button&gt;</code> functionality?</p> <p>We can extend and customize built-in HTML elements by inheriting from their classes.</p> <p>For example, buttons are instances of <code>HTMLButtonElement</code>, let’s build upon it.</p> <ol type="1"> <li><p>Extend <code>HTMLButtonElement</code> with our class:</p> <div class="sourceCode" id="cb5"><pre class="sourceCode js"><code class="sourceCode javascript"><a class="sourceLine" id="cb5-1" title="1"><span class="kw">class</span> HelloButton <span class="kw">extends</span> HTMLButtonElement <span class="op">{</span></a> <a class="sourceLine" id="cb5-2" title="2"> <span class="co">/* custom element methods */</span></a> <a class="sourceLine" id="cb5-3" title="3"><span class="op">}</span></a></code></pre></div></li> <li><p>Provide the third argument to <code>customElements.define</code>, that specifies the tag:</p> <div class="sourceCode" id="cb6"><pre class="sourceCode js"><code class="sourceCode javascript"><a class="sourceLine" id="cb6-1" title="1"><span class="va">customElements</span>.<span class="at">define</span>(<span class="st">&#39;hello-button&#39;</span><span class="op">,</span> HelloButton<span class="op">,</span> <span class="op">*!*{</span><span class="dt">extends</span><span class="op">:</span> <span class="st">&#39;button&#39;</span><span class="op">}*</span><span class="ss">/!</span><span class="sc">*)</span><span class="ss">;</span></a></code></pre></div> <p>There may be different tags that share the same DOM-class, that’s why specifying <code>extends</code> is needed.</p></li> <li><p>At the end, to use our custom element, insert a regular <code>&lt;button&gt;</code> tag, but add <code>is="hello-button"</code> to it:</p> <div class="sourceCode" id="cb7"><pre class="sourceCode html"><code class="sourceCode html"><a class="sourceLine" id="cb7-1" title="1"><span class="kw">&lt;button</span><span class="ot"> is=</span><span class="st">&quot;hello-button&quot;</span><span class="kw">&gt;</span>...<span class="kw">&lt;/button&gt;</span></a></code></pre></div></li> </ol> <p>Here’s a full example:</p> ```html run autorun=“no-epub” <script> // The button that says "hello" on click class HelloButton extends HTMLButtonElement { *!* constructor() { */!* super(); this.addEventListener('click', () => alert("Hello!")); } } *!* customElements.define('hello-button', HelloButton, {extends: 'button'}); */!* </script> <p><em>!</em> <button is="hello-button">Click me</button> <em>/!</em> <em>!</em> <button is="hello-button" disabled>Disabled</button> <em>/!</em> ```</p> <p>Our new button extends the built-in one. So it keeps the same styles and standard features like <code>disabled</code> attribute.</p> <h2 id="references">References</h2> <ul> <li>HTML Living Standard: <a href="https://html.spec.whatwg.org/#custom-elements" class="uri">https://html.spec.whatwg.org/#custom-elements</a>.</li> <li>Compatiblity: <a href="https://caniuse.com/#feat=custom-elementsv1" class="uri">https://caniuse.com/#feat=custom-elementsv1</a>.</li> </ul> <h2 id="summary">Summary</h2> <p>Custom elements can be of two types:</p> <ol type="1"> <li><p>“Autonomous” – new tags, extending <code>HTMLElement</code>.</p> <p>Definition scheme:</p> <div class="sourceCode" id="cb8"><pre class="sourceCode js"><code class="sourceCode javascript"><a class="sourceLine" id="cb8-1" title="1"><span class="kw">class</span> MyElement <span class="kw">extends</span> HTMLElement <span class="op">{</span></a> <a class="sourceLine" id="cb8-2" title="2"> <span class="at">constructor</span>() <span class="op">{</span></a> <a class="sourceLine" id="cb8-3" title="3"> <span class="kw">super</span>()<span class="op">;</span> <span class="co">/* ... */</span></a> <a class="sourceLine" id="cb8-4" title="4"> <span class="op">}</span></a> <a class="sourceLine" id="cb8-5" title="5"> <span class="at">connectedCallback</span>() <span class="op">{</span></a> <a class="sourceLine" id="cb8-6" title="6"> <span class="co">/* ... */</span></a> <a class="sourceLine" id="cb8-7" title="7"> <span class="op">}</span></a> <a class="sourceLine" id="cb8-8" title="8"> <span class="at">disconnectedCallback</span>() <span class="op">{</span></a> <a class="sourceLine" id="cb8-9" title="9"> <span class="co">/* ... */</span></a> <a class="sourceLine" id="cb8-10" title="10"> <span class="op">}</span></a> <a class="sourceLine" id="cb8-11" title="11"> <span class="kw">static</span> get <span class="at">observedAttributes</span>() <span class="op">{</span></a> <a class="sourceLine" id="cb8-12" title="12"> <span class="cf">return</span> [</a> <a class="sourceLine" id="cb8-13" title="13"> <span class="co">/* ... */</span></a> <a class="sourceLine" id="cb8-14" title="14"> ]<span class="op">;</span></a> <a class="sourceLine" id="cb8-15" title="15"> <span class="op">}</span></a> <a class="sourceLine" id="cb8-16" title="16"> <span class="at">attributeChangedCallback</span>(name<span class="op">,</span> oldValue<span class="op">,</span> newValue) <span class="op">{</span></a> <a class="sourceLine" id="cb8-17" title="17"> <span class="co">/* ... */</span></a> <a class="sourceLine" id="cb8-18" title="18"> <span class="op">}</span></a> <a class="sourceLine" id="cb8-19" title="19"> <span class="at">adoptedCallback</span>() <span class="op">{</span></a> <a class="sourceLine" id="cb8-20" title="20"> <span class="co">/* ... */</span></a> <a class="sourceLine" id="cb8-21" title="21"> <span class="op">}</span></a> <a class="sourceLine" id="cb8-22" title="22"><span class="op">}</span></a> <a class="sourceLine" id="cb8-23" title="23"><span class="va">customElements</span>.<span class="at">define</span>(<span class="st">&quot;my-element&quot;</span><span class="op">,</span> MyElement)<span class="op">;</span></a> <a class="sourceLine" id="cb8-24" title="24"><span class="co">/* &lt;my-element&gt; */</span></a></code></pre></div></li> <li><p>“Customized built-in elements” – extensions of existing elements.</p> <p>Requires one more <code>.define</code> argument, and <code>is="..."</code> in HTML:</p> <div class="sourceCode" id="cb9"><pre class="sourceCode js"><code class="sourceCode javascript"><a class="sourceLine" id="cb9-1" title="1"><span class="kw">class</span> MyButton <span class="kw">extends</span> HTMLButtonElement <span class="op">{</span></a> <a class="sourceLine" id="cb9-2" title="2"> <span class="co">/*...*/</span></a> <a class="sourceLine" id="cb9-3" title="3"><span class="op">}</span></a> <a class="sourceLine" id="cb9-4" title="4"><span class="va">customElements</span>.<span class="at">define</span>(<span class="st">&quot;my-button&quot;</span><span class="op">,</span> MyElement<span class="op">,</span> <span class="op">{</span> <span class="dt">extends</span><span class="op">:</span> <span class="st">&quot;button&quot;</span> <span class="op">}</span>)<span class="op">;</span></a> <a class="sourceLine" id="cb9-5" title="5"><span class="co">/* &lt;button is=&quot;my-button&quot;&gt; */</span></a></code></pre></div></li> </ol> <p>Custom elements are well-supported among browsers. There’s a polyfill <a href="https://github.com/webcomponents/polyfills/tree/master/packages/webcomponentsjs" class="uri">https://github.com/webcomponents/polyfills/tree/master/packages/webcomponentsjs</a>.</p> </body> </html>
html
<filename>public/data/square/okhttp/subgraph_371.json {"info": {"project": "square/okhttp", "developers": 2, "edges": 3, "vertices": 4, "commits": 3, "id": 371, "agedays": 108, "refactorings": 1, "group": "Overtime", "language": "Java", "level": "Method", "summary": ""}, "commits_list": ["a867db645", "d53dae207", "46fa5178b"], "edges": [{"id": 577, "before": "okhttp.src.main.com.squareup.okhttp.internal.http.HttpEngine#isEndToEnd(String)", "lineB": null, "after": "okhttp.src.main.com.squareup.okhttp.internal.http.OkHeaders#isEndToEnd(String)", "lineA": null, "ref": "MOVE", "sha1": "a867db645"}, {"id": 998, "before": "okhttp.src.main.com.squareup.okhttp.internal.http.ResponseHeaders#isEndToEnd(String)", "lineB": null, "after": "okhttp.src.main.com.squareup.okhttp.Response#isEndToEnd(String)", "lineA": null, "ref": "MOVE", "sha1": "d53dae207"}, {"id": 919, "before": "okhttp.src.main.com.squareup.okhttp.Response#isEndToEnd(String)", "lineB": null, "after": "okhttp.src.main.com.squareup.okhttp.internal.http.HttpEngine#isEndToEnd(String)", "lineA": null, "ref": "MOVE", "sha1": "46fa5178b"}]}
json
After being closed for 45 years, a trek route near Valley of Flowers has finally been opened for adventure seekers to enjoy the view, and also to provide an alternate route to rescue teams in case of natural disasters in the region. After being closed for 45 years, a trek route near Valley of Flowers has finally been opened for adventure seekers to enjoy the view, and also to provide an alternate route to rescue teams in case of natural disasters in the region. The Valley of Flowers National Park, located in Uttarakhand, is famous for its meadow of alpine flowers, variety of flora and the presence of endangered animals. A trek route near the park – the Kunthkhal-Hanuman Chatti route, had been closed for the last 45 years, and now it has finally been opened by the Uttarakhand forest department. The route is from Kunthkhal, which is in Valley of Flowers, to Hanuman Chatti. This stretch offers the marvellous view of glaciers, gorges and rivers, on the way. The route has been opened for two reasons – for nature and adventure lovers to enjoy the trek, and to provide an alternate route for rescue teams in case of disasters like the Kedarnath flash floods. SS Rasaily, director of Nanda Devi Biosphere, told Times of India that the trek route was closed since 1970 because tourists had started opting for the easier route from Ghanghariya. “Because it was lying unused, the trek trail soon became overgrown with dense vegetation. During the recent disaster, a need was felt for an alternate route which could be used to evict people. This route is suitable for this purpose,” he said. Hanuman Chatti, a popular trekking spot, is about 10 km from Badrinath. From there, people can trek to Kunthkhal and Ghanghariya to get back to civilization. The forest department is also starting to promote other treks near the Valley of Flowers such as those leading to the Chenab Valley, Kagbhusandi Lake, Dronagiri Parvat, etc. According to Chandresh Joshi, divisional forest officer of Joshimath, the ideal time to trek to the valley is from July to October. The beautiful Brahm Kamal flower, which is found at an elevation of over 4500 meter above sea level, can also be seen on this trail. Like this story? Or have something to share? Write to us: contact@thebetterindia.com, or connect with us on Facebook and Twitter (@thebetterindia). We bring stories straight from the heart of India, to inspire millions and create a wave of impact. Our positive movement is growing bigger everyday, and we would love for you to join it. Please contribute whatever you can, every little penny helps our team in bringing you more stories that support dreams and spread hope.
english
Suggest best medicine to prevent pregnancy & is any medicine available which take once in 6month to prevent pregnancy for 6 months? Pls share name of medicine. The choice of contraceptive would depend on a number of factors, such as age, no of children, other medical and generic problems, and previous contraceptive methods used. Was this answer helpful?
english
<reponame>KDCinfo/expired-to-be<filename>public/extensions/chrome/manifest.json { "manifest_version": 2, "name": "Expired To Be", "version": "2.3.2", "icons": { "16": "icon16.png", "32": "icon32.png", "48": "icon48.png", "128": "icon128.png" }, "browser_action": { "default_icon": "icon.png", "default_popup": "popup.html" }, "background": { "scripts": ["eventPage.js"], "persistent": false }, "permissions": [ "storage", "alarms" ], "author": "<NAME> (https://kdcinfo.com)", "homepage_url": "https://github.com/KDCinfo/expired-to-be", "short_name": "Expired To Be", "description": "Expiration Reminders for groceries, medicine, warranties, etc. A quick and convenient way to set and be reminded of expiring items." }
json
[ { "functionName": "Ember.RouterDSL.route", "moduleName": "ember-route-alias/initializers/route-alias" }, { "functionName": "A.map", "moduleName": "route-recognizer" }, { "functionName": "_setupLocation", "moduleName": "ember-routing/system/router" }, { "functionName": "_internalGetHandler", "moduleName": "ember-engines/-private/router-ext" }, { "functionName": "o.willTransition", "moduleName": "ember-routing/system/router" }, { "functionName": "generateURL", "moduleName": "ember-routing/services/routing" }, { "functionName": "normalizeQueryParams", "moduleName": "ember-routing/services/routing" }, { "functionName": "_getQPMeta", "moduleName": "ember-routing/system/router" }, { "functionName": "applyIntent", "moduleName": "router" } ]
json
<gh_stars>1-10 {"media_id": "77480991", "local_id": "NP016\n", "title": "File:Amanda_and_Nils_Personne,_actors,_photo_1905_-_SMV_-_NP016.tif", "thumbnail": "https://upload.wikimedia.org/wikipedia/commons/thumb/9/9d/Amanda_and_Nils_Personne,_actors,_photo_1905_-_SMV_-_NP016.tif/500px-Amanda_and_Nils_Personne,_actors,_photo_1905_-_SMV_-_NP016.tif.jpg", "desc": " Amanda och <NAME>, foto taget i samband med deras br\u00f6llop 1905. Skannat glasnegativ\n", "auto_desc": {"translatedText": "Amanda and <NAME>, photo taken in connection with their wedding in 1905. Scanned glass negative", "input": " Amanda och <NAME>, foto taget i samband med deras br\u00f6llop 1905. Skannat glasnegativ\n"}}
json
Monday July 29, 2013, It all started when they came to Bangalore in 2007 and couldn’t find the right property. After finding something to their satisfaction, many new problems cropped up which all had their seed in the process of moving to a new house. In this case, it was a sewage problem in the society which wasn’t getting solved because none of the society residents knew each other or had any sort of co-ordination to come to a conclusion. Privy to these problems, the trio of Sumit Jain, Lalit Mangal and Vikas Malpani ventured out to find a solution and thus was born CommonFloor. We covered the company last in 2009 and since then, CommonFloor has raised two more rounds of funding (the latest being a $7.5 million Series C investment) and has gone on to become one of the largest online real estate portals in the country. Here, we get in conversation with Sumit Jain to learn more. Edited excerpts: YourStory: CommonFloor has come a long way! Can you rewind a bit and tell us something about the time you started up and things that gave you confidence. Sumit Jain: The initial thought was to develop a platform that could bring together people who live in gated communities and had come up with CommonFloor.com in November 2007. It was a challenge initially to get communities on board and we had to come up with several iterations to get the product right. We also had to keep the product flexible enough to accommodate different priorities of different communities while still ensuring a good user experience for all. The real confidence came when the communities that adopted us in the beginning started to see real value in our product, appreciated our efforts and even partnered with us in improving it. That is when we started believing that CommonFloor.com will work. YS: So, how has CommonFloor evolved? SJ: Our vision was always to satisfy all requirements of a person around his home. In the initial years, we noticed a lot of owners using our platform to post listings of their apartments. We realized that if we open this information to people outside their gated communities, it will add much more value to these owners. Soon we started to be known as the best place for genuine listings and started seeing a lot of traction from those looking for a house to buy/sell or rent. We then started making deliberate efforts to build our capabilities in real estate and today we are the third largest real estate portal in the country in terms of unique visitors as per comScore. YS: Anything that you believe you did differently and that it clicked? SJ: The key difference that we have brought to the online real estate market is – while everyone looked at it from a classifieds perspective, we look at it from a community perspective. Unlike our competitors who come into picture when a person is buying / selling a house, we are a complete home portal and engage with our users right from the time they are looking for a home to when they move into their house and start living there and even when they want to sell it. (Using their Apartment Management Software, the owners / residents benefit by being able to connect to their neighbours online, forming interest groups and finding neighbours who share similar interests and using CommonFloor.com as a forum to discuss issues / topics relevant to the community. Owners / residents also get specific updates and notices from RWA (Residents’ Welfare Association) directly on their phones and e-mails, can reach out to vendors like electricians, plumbers etc. through CommonFloor.com’s directory and pay their maintenance bills online through the integrated payment gateway. And for RWA’s, our Apartment Management Software offers features comparable to ERP systems) YS: Tell us a bit about the reach of AMS (Apartment Management Software). SJ: We have grown to become the largest players in this segment and are currently present in 120 cities across the country. Around 60,000 communities are listed with us today, constituting more than 50 Lakh homes. YS: Can you give us a few numbers in terms of traction and some of the key milestones over the years. SJ: We are the fastest growing real estate portal in the country growing by more than 100% year on year as per comScore. In Bangalore, we are the number one property portal as per Alexa traffic rank. Today, we have more than 1000 paying customers that include builders, agents and vendors. Our revenue has been growing by more than 100% every quarter and we aim to achieve a turnover of $25 million in the next two years. We have more than 60,000 projects listed on our portal and this is the largest compared to any property portal in India. The number of property listings has grown by more than 500% in the past financial year and we currently have more than one lakh live active listings. We had also recently launched a mobile application for our users with unique features like augmented reality and map search which allows customers to view properties around them; using the camera on their phone. Today we have offices in 7 cities - Bangalore, Gurgaon, Noida, Pune, Hyderabad, Mumbai and Chennai. YS: What are the revenue streams for Commonfloor? SJ: When it comes to revenues, our model is simple. Like Google, we offer our services free to users and charge businesses. We generate revenue from advertising and vendor listings. Many well-known players across various verticals such as real estate and banking services advertise with us to reach out to people who are looking to buy or sell property. Vendors like architects, plumbers, carpenters etc. also use our platform to reach out to people who own homes and advertise their services. YS: Any particular thing that clicked for you w.r.t marketing? SJ: As far as marketing is concerned, I think the biggest reason we have been successful is that due to our community based approach we have been able to offer highly genuine listings to our users. The accuracy of the information led to positive word of mouth, which has helped us reach where we are today. We have also focused on sharing relevant content on our website which has helped in gaining more users. YS: How big is the team now and what has worked for you when it comes to hiring? SJ: We are more than 400 people now and are looking to hire more. I think what has worked for us has been the mindset change amongst talented Indians when it comes to making a career decision. Not everyone today is satisfied with a 9 to 5 job at an MNC. Young Indians today want to make a difference at what they do. They are willing to take risks and join young and innovative Indian companies. They understand that they can grow faster and make a big difference when they join a company that is on a growth track. The fact that we have scaled fast and people have grown with us has also helped, particularly with referrals. YS: You’ve recently raised the third round of funding. How is it going to be utilized? SJ: The new funds are being used for scaling presence across multiple cities, upgrading technology capabilities, hiring talent and expanding marketing initiatives. YS: What keeps you going as an entrepreneur? SJ: We are really passionate about how we can use technology to solve people’s requirements around their homes. Home is where we spend most of our time and 70% of our daily use expenditure is made in the radius of 2 km of our home. Yet, we pay no attention to improving the quality of living around our homes. I think the team at Commonfloor.com has a great opportunity to change the way communities live. To be able to drive that change and have that kind of positive impact on society is a huge motivating factor. And some more points of note:
english
Celina Jaitly is a proud mother to 3 kids and the actress who’s currently in Austria is juggling work and children with ease. The actress will be seen in a film called Season’s Greetings. We spoke to the actress at length as she discussed about her children, managing work and children, speculations around her pregnancy before marriage and much more. Would you term Season’s Greetings as your comeback film? I wish people would stop using the phrase “Comeback Film”. It’s not the 70s or 80s anymore. We live in an era of globalisation wherein we are connected by a wide diaspora of information and technology. All I did was take a maternity sabbatical to enjoy family life and birth of my children, but even then my films, music and campaigns ran on every possible digital platform and channel. When our male compatriots take a break no one uses this term. Many of my co-stars have not done films for years and nobody uses this terminology for them when they resume filming. Any advantages/disadvantages that one has to deal with, when staying abroad and raising a family? Living abroad has been fabulous for us. Multicultural diversity and exchange boost the children’s capability to be tomorrow’s successful generation. Since I got married, thanks to my husband’s corporate leadership roles, I have had the opportunity to live in many countries like Singapore, UAE and now back home in Austria. When you leave your home country, you not only get to see other ways of doing things but you also discover how others perceive your country and your culture. In taking a few steps back, a new picture of your home country and of your relationships (with your family, your friends) starts to emerge. What do you have to say about the speculations which suggested that you got pregnant before marriage? There are some overconfident proclaims of the fact that Peter and I got married only because I became pregnant. The depiction of our children being conceived before marriage doing rounds on the internet through some very strong media platforms is absolutely baseless and irresponsible. They could have checked their facts with the Austrian marriage courts before jumping to such irresponsible conclusion and the worst part of it is that they continue to do so even 9 years after our marriage. These rumours expose our growing kids to harmful content on-screen and bullying too in some cases. I have decided to raise my voice against this malicious circulation of information as our kids must be protected from images and information that could have a lasting and detrimental impact on them. The media has an important role to play in protecting and promoting the rights of the child and by continuously circulating such terribly wrong information about their very conception, they are playing an important part in causing the children great emotional and possibly physical trauma too. So, when did you decide to have kids? I have been enjoying the limelight since I was 15. I started my busy and stressful professional career at an age when people enjoy their teens in colleges and have campus romances. When Peter (Haag) came in my life, he was my charming prince, and I knew that if I have to settle in life then it has to be with him! Obviously, both of us love kids and we were eventually blessed with twins twice, Winston, Viraaj, Arthur and Shamsher. How did you keep yourself updated with what was happening in India? We don’t live in the 80’s, and we all are working directly or indirectly together through various channels and platforms on various creative projects. The world is just a whatsapp, tweet or an instagram feed away anyway. What would you like to do next? I am super excited to explore different aspects of myself as an individual. From an upcoming music single to films and my work with UN, I’m under a continuous process of evolution. Are you open to doing web shows? It depends entirely on the platform and script. When I joined films in 2002, people took offence when you asked them for a script. Even if a script was given to you, the dialogue and story would be very different from what it was initially projected to be. I am so happy that thanks to the digital platform, one can truly explore so many new dimensions of themselves as actors. So yes, I look forward to doing something fabulous in the near future. People say that post pregnancy it becomes difficult to get back in shape. But you seem to be an exception. How tough or easy has it been? Fitness to me is a lifestyle, it is everything from how much one sleeps to what one eats to how many steps does one take in a day or the perfect balance between weight training or resistance training because besides my own physical and mental wellbeing I have to be a perfect role model to my 3 sons. Having said that, pregnancy and post pregnancy recovery is an experience unique to every individual and differs from women to women. Between social media, cultural influences and increased awareness about the guidelines, pregnant women and new moms should follow the judgment women face as they enter motherhood. I remember how much flak I received for posting a picture in a bikini and bathtub when I was pregnant with my second set of twins 1 1/2 years ago. Some people were vicious enough to attribute our son’s death as well as my father’s death to the same. Because women today have their own individuality, the society at large feels all-too-comfortable passing judgments because the newfound expression of freedom is something people around us find it difficult to deal with. What they don’t realise is the last thing an overworked, sleep-deprived, overwhelmed, hormonal, healing new mother needs is to feel judged. What we all need is respect and lots of support. How do you manage to strike the right balance between managing work and children? Like most working moms, I also experience immense MOM GUILT returning to a career that I’d built for years. The trick is that if you do a job that makes you “feel valued” it could be the perfect cure for Mom Guilt as one becomes more confident. Business travel has been a predominantly male sphere, but things have changed a lot, as an actor and UN ambassador, I made my kids understand right from the beginning the travel consequences of my job. I sometimes do suffer a great deal of separation anxiety like all working mothers. It important as career moms we have to find ways to be efficient in both worlds—and that requires being able to come to terms with choices and focus on the priorities that are in the moment.
english
Party like it's 1989! The best strategy game in the world is here! A full version program for Windows, by Paradox Development Studio. A full version program for Windows, by BANDAI NAMCO Studios.
english
A landslide that occurred in southwest China’s Yunnan Province Thursday morning has left nine people missing, local authorities said. The landslide, triggered by heavy rain, took place at 4:40 a.m. in Qiaojia County under the city of Zhaotong, the county’s information office said. The county has launched an emergency response and sent rescuers to the site.
english
BJP National President J. P Nadda will be visiting Nagaland on 15th September. This will be Nadda’s maiden visit to the state. public rally at Old Riphyim, Tyui Mandal in Wokha. Mr. Nadda will thereafter proceed to Kohima to address the BJP leaders at Capital Cultural Hall, Kohima.
english
{ "name": "<NAME>", "commonname": "bottle gentian", "description": "Bottle Gentian are slow-growing but long-lived and require little care once established. Bumblebees are the main pollinators because they are the only insects strong enough to pry open the closed flowers (see photo). Cream Gentian is the first Gentian to bloom in late summer.  Bottle Gentian and others (see our website) may wait until September or October to lend late-season color to mostly sunny sites in medium-wet to medium-dry soils. It is a great companion with other late bloomers such as: New England Aster (Aster novae-angliae), Obedient Plant (Physostegia virginiana), and Prairie Blazing Star (Liatris pycnostachya).  Other common names include Closed Bottle Gentian, and Andrew's Gentian. Dormant bare root plants ship each year during optimal transplanting season: Fall (October) or Spring (April/May).", "prices": [ { "quantity": 1, "unit": "packet", "price": 2.5 } ], "seeds/packet": 750, "seeds/ounce": 280000, "germination": [ "C(60)", "D" ], "light": [ "Full", "Partial" ], "moisture": [ "Medium-Wet", "Medium" ], "height": 24, "blooms": [ "August", "September", "October" ], "color": [ "Blue" ], "features": [ "Pollinator Favorite: butterflies, bees and birds", "Deer Resistant (Our experiences here in the Upper Midwest may vary in other regions; deer can respond differently to local conditions or seasonal variations.)", "Highly recommended for home landscaping" ], "zones": [ 3, 4, 5, 6 ], "spacing": { "min": 1, "max": 2 }, "sku": "GEN02F" }
json
{ "id": "ethersniper", "symbol": "ets", "name": "Ethersniper", "platforms": { "binance-smart-chain": "0x080f2ed125c2e41e979d1ae9f8ef8c262b344855" }, "hashing_algorithm": null, "categories": [], "description": { "en": "Ethsniper is the next generation gaming NFT platform.\r\n\r\nEthsniper is the first blockchain powered shooting game with Ethereum reflection.\r\n\r\nHold Ets tokens and get rewarded in Ethereum on every transaction." }, "country_origin": "", "genesis_date": null, "contract_address": "0x080f2ed125c2e41e979d1ae9f8ef8c262b344855", "url": "https://ethsniper.com/", "explorers": [ "https://bscscan.com/token/0x080f2ed125C2E41E979d1Ae9F8EF8c262B344855" ], "twitter": "ethsniper", "telegram": "ethsniper1" }
json
package com.kkard.seoulroad.Calendar_C; /** * Created by KyungHWan on 2017-10-07. */ import android.content.Context; import android.content.res.Resources; import android.content.res.TypedArray; import android.graphics.Canvas; import android.graphics.Paint; import android.graphics.Paint.Align; import android.graphics.Paint.Style; import android.graphics.RectF; import android.graphics.Typeface; import android.text.format.DateUtils; import android.text.format.Time; import android.util.Log; import android.util.TypedValue; import android.view.MotionEvent; import android.view.View; import com.kkard.seoulroad.R; import java.security.InvalidParameterException; import java.text.DateFormatSymbols; import java.text.SimpleDateFormat; import java.util.Calendar; import java.util.HashMap; import java.util.Map; public class SimpleMonthView extends View { public static final String VIEW_PARAMS_HEIGHT = "height"; public static final String VIEW_PARAMS_MONTH = "month"; public static final String VIEW_PARAMS_YEAR = "year"; public static final String VIEW_PARAMS_SELECTED_BEGIN_DAY = "selected_begin_day"; public static final String VIEW_PARAMS_SELECTED_LAST_DAY = "selected_last_day"; public static final String VIEW_PARAMS_SELECTED_BEGIN_MONTH = "selected_begin_month"; public static final String VIEW_PARAMS_SELECTED_LAST_MONTH = "selected_last_month"; public static final String VIEW_PARAMS_SELECTED_BEGIN_YEAR = "selected_begin_year"; public static final String VIEW_PARAMS_SELECTED_LAST_YEAR = "selected_last_year"; public static final String VIEW_PARAMS_WEEK_START = "week_start"; private static final int DRAGING_ALPHA = 82; private static final int NORMAL_ALPHA = 255; protected static int DEFAULT_HEIGHT = 40; protected static final int DEFAULT_NUM_ROWS = 6; protected static int DAY_SELECTED_CIRCLE_SIZE; protected static int EVENT_DOTS_CIRCLE_SIZE; protected static int DAY_SEPARATOR_WIDTH = 1; protected static int MINI_DAY_NUMBER_TEXT_SIZE; protected static int MIN_HEIGHT = 10; protected static int MONTH_DAY_LABEL_TEXT_SIZE; protected static int MONTH_HEADER_SIZE; protected static int MONTH_LABEL_TEXT_SIZE; protected static int MONTH_INFO_TEXT_SIZE; protected static int PADDING_BOTTOM; protected int mPadding = 0; private String mDayOfWeekTypeface; private String mMonthTitleTypeface; protected Paint mMonthDayLabelPaint; protected Paint mMonthNumPaint; protected Paint mMonthInfoPaint; protected Paint mMonthTitlePaint; protected Paint mSelectedCirclePaint; protected Paint mCurrentCirclePaint; protected int mCurrentDayTextColor; protected int mMonthTextColor; protected int mDayTextColor; protected int mMonthDayLabelTextColor; protected int mDayNumColor; protected int mMonthTitleBGColor; protected int mPreviousDayColor; protected int mSelectedDaysColor; protected int mWeekendsColor; protected int mCurrentDayColor; private final StringBuilder mStringBuilder; protected boolean mHasToday = false; protected boolean mIsPrev = false; protected int mSelectedBeginDay = -1; protected int mSelectedBeginMonth = -1; protected int mSelectedBeginYear = -1; protected int mToday = -1; protected int mWeekStart = 1; protected int mNumDays = 7; protected int mNumCells = mNumDays; private int mDayOfWeekStart = 0; protected int mMonth; protected Boolean mDrawRect; protected int mRowHeight = DEFAULT_HEIGHT; protected int mWidth; protected int mYear; final Time today; private final Calendar mCalendar; private final Calendar mDayLabelCalendar; private final Boolean isPrevDayEnabled; private boolean shouldShowMonthInfo = false; private long alphaStartTime = -1; private final int FRAMES_PER_SECOND = 60; private final long ALPHA_DURATION = 400; private int currentDraggingAlpha; private int currentNormalAlpha; private int mNumRows = DEFAULT_NUM_ROWS; private Map<Integer, Integer> eventSymbols = new HashMap<>(); private DateFormatSymbols mDateFormatSymbols = new DateFormatSymbols(); private OnDayClickListener mOnDayClickListener; int flag = 1; public SimpleMonthView(Context context, TypedArray typedArray) { super(context); Resources resources = context.getResources(); mDayLabelCalendar = Calendar.getInstance(); mCalendar = Calendar.getInstance(); today = new Time(Time.getCurrentTimezone()); today.setToNow(); mDayOfWeekTypeface = resources.getString(R.string.sans_serif); mMonthTitleTypeface = resources.getString(R.string.sans_serif); mCurrentDayTextColor = typedArray.getColor(R.styleable.DayPickerView_colorCurrentDay, resources.getColor(R.color.normal_day)); mMonthTextColor = typedArray.getColor(R.styleable.DayPickerView_colorMonthName, resources.getColor(R.color.normal_month)); mMonthDayLabelTextColor = resources.getColor(R.color.month_day_label_text); mDayTextColor = typedArray.getColor(R.styleable.DayPickerView_colorDayName, resources.getColor(R.color.normal_day)); mDayNumColor = typedArray.getColor(R.styleable.DayPickerView_colorNormalDay, resources.getColor(R.color.normal_day)); mPreviousDayColor = typedArray.getColor(R.styleable.DayPickerView_colorPreviousDay, resources.getColor(R.color.normal_day)); mSelectedDaysColor = typedArray.getColor(R.styleable.DayPickerView_colorSelectedDayBackground, resources.getColor(R.color.selected_day_background)); mMonthTitleBGColor = typedArray.getColor(R.styleable.DayPickerView_colorSelectedDayText, resources.getColor(R.color.selected_day_text)); mWeekendsColor = resources.getColor(R.color.weekends_day); mDrawRect = typedArray.getBoolean(R.styleable.DayPickerView_drawRoundRect, false); mCurrentDayColor = resources.getColor(R.color.current_day_background); mStringBuilder = new StringBuilder(50); MINI_DAY_NUMBER_TEXT_SIZE = typedArray.getDimensionPixelSize(R.styleable.DayPickerView_textSizeDay, resources.getDimensionPixelSize(R.dimen.text_size_day)); MONTH_LABEL_TEXT_SIZE = typedArray.getDimensionPixelSize(R.styleable.DayPickerView_textSizeMonth, resources.getDimensionPixelSize(R.dimen.text_size_month)); MONTH_DAY_LABEL_TEXT_SIZE = typedArray.getDimensionPixelSize(R.styleable.DayPickerView_textSizeDayName, resources.getDimensionPixelSize(R.dimen.text_size_day_name)); MONTH_HEADER_SIZE = typedArray.getDimensionPixelOffset(R.styleable.DayPickerView_headerMonthHeight, resources.getDimensionPixelOffset(R.dimen.header_month_height)); DAY_SELECTED_CIRCLE_SIZE = typedArray.getDimensionPixelSize(R.styleable.DayPickerView_selectedDayRadius, resources.getDimensionPixelOffset(R.dimen.selected_day_radius)); EVENT_DOTS_CIRCLE_SIZE = resources.getDimensionPixelSize(R.dimen.event_dots_radius); MONTH_INFO_TEXT_SIZE = resources.getDimensionPixelSize(R.dimen.month_info_text_size); PADDING_BOTTOM = (int) TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 10, resources.getDisplayMetrics()); mRowHeight = ((typedArray.getDimensionPixelSize(R.styleable.DayPickerView_calendarHeight, resources.getDimensionPixelOffset(R.dimen.calendar_height)) - MONTH_HEADER_SIZE) / 6); isPrevDayEnabled = typedArray.getBoolean(R.styleable.DayPickerView_enablePreviousDay, true); initView(); } private int calculateNumRows() { int offset = findDayOffset(); int dividend = (offset + mNumCells) / mNumDays; int remainder = (offset + mNumCells) % mNumDays; return (dividend + (remainder > 0 ? 1 : 0)); } private void drawMonthDayLabels(Canvas canvas) { int y = MONTH_HEADER_SIZE - (MONTH_DAY_LABEL_TEXT_SIZE / 2); int dayWidthHalf = (mWidth - mPadding * 2) / (mNumDays * 2); for (int i = 0; i < mNumDays; i++) { if (i == 0 || i == mNumDays - 1) { mMonthDayLabelPaint.setColor(mWeekendsColor); } else { mMonthDayLabelPaint.setColor(mMonthDayLabelTextColor); } int calendarDay = (i + mWeekStart) % mNumDays; int x = (2 * i + 1) * dayWidthHalf + mPadding; mDayLabelCalendar.set(Calendar.DAY_OF_WEEK, calendarDay); SimpleDateFormat dateFormat = new SimpleDateFormat("EEEEE"); String dayLabelText = dateFormat.format(mDayLabelCalendar.getTime()); canvas.drawText(dayLabelText, x, y, mMonthDayLabelPaint); } } private void drawMonthTitle(Canvas canvas) { int paddingDay = (mWidth - 2 * mPadding) / (2 * mNumDays); //int x = paddingDay * (findDayOffset() * 2 + 1) + mPadding; int x = (int)(getWidth()*0.5);//월 가운데에 위치 시키는것 int y = ((mRowHeight + MINI_DAY_NUMBER_TEXT_SIZE) / 2 - DAY_SEPARATOR_WIDTH + MONTH_HEADER_SIZE / 5 * 2)-15; StringBuilder stringBuilder = new StringBuilder(getMonthString().toLowerCase()); stringBuilder.setCharAt(0, Character.toUpperCase(stringBuilder.charAt(0))); canvas.drawText(stringBuilder.toString(), x, y, mMonthTitlePaint); } private int findDayOffset() { return (mDayOfWeekStart < mWeekStart ? (mDayOfWeekStart + mNumDays) : mDayOfWeekStart) - mWeekStart; } private String getMonthAndYearString() { int flags = DateUtils.FORMAT_SHOW_DATE | DateUtils.FORMAT_SHOW_YEAR | DateUtils.FORMAT_NO_MONTH_DAY; mStringBuilder.setLength(0); long millis = mCalendar.getTimeInMillis(); return DateUtils.formatDateRange(getContext(), millis, millis, flags); } private String getMonthString() { SimpleDateFormat dateFormat = new SimpleDateFormat("MMM"); String monthTitleText = dateFormat.format(mCalendar.getTime()); return monthTitleText; } private void onDayClick(SimpleMonthAdapter.CalendarDay calendarDay) { if (mOnDayClickListener != null && (isPrevDayEnabled || !((calendarDay.month == today.month) && (calendarDay.year == today.year) && calendarDay.day < today.monthDay))) { mOnDayClickListener.onDayClick(this, calendarDay); } } private boolean sameDay(int monthDay, Time time) { return (mYear == time.year) && (mMonth == time.month) && (monthDay == time.monthDay); } private boolean prevDay(int monthDay, Time time) { return ((mYear < time.year)) || (mYear == time.year && mMonth < time.month) || ( mMonth == time.month && monthDay < time.monthDay); } /** * draw dots to show events * @param x x pos of date number * @param y y pos of date number * @param count * @param canvas */ protected void drawDots(int x, int y, int count, Canvas canvas) { switch (count) { case 1: canvas.drawCircle(x, y + EVENT_DOTS_CIRCLE_SIZE * 16 / 5, EVENT_DOTS_CIRCLE_SIZE, mCurrentCirclePaint); break; case 2: canvas.drawCircle(x - EVENT_DOTS_CIRCLE_SIZE * 8 / 5, y + EVENT_DOTS_CIRCLE_SIZE * 16 / 5, EVENT_DOTS_CIRCLE_SIZE, mCurrentCirclePaint); canvas.drawCircle(x + EVENT_DOTS_CIRCLE_SIZE * 8 / 5, y + EVENT_DOTS_CIRCLE_SIZE * 16 / 5, EVENT_DOTS_CIRCLE_SIZE, mCurrentCirclePaint); break; case 3: default: canvas.drawCircle(x - EVENT_DOTS_CIRCLE_SIZE * 16 / 5, y + EVENT_DOTS_CIRCLE_SIZE * 16 / 5, EVENT_DOTS_CIRCLE_SIZE, mCurrentCirclePaint); canvas.drawCircle(x + EVENT_DOTS_CIRCLE_SIZE * 16 / 5, y + EVENT_DOTS_CIRCLE_SIZE * 16 / 5, EVENT_DOTS_CIRCLE_SIZE, mCurrentCirclePaint); canvas.drawCircle(x, y + EVENT_DOTS_CIRCLE_SIZE * 16 / 5, EVENT_DOTS_CIRCLE_SIZE, mCurrentCirclePaint); break; } } protected void drawMonthNums(Canvas canvas) { int y = (mRowHeight + MINI_DAY_NUMBER_TEXT_SIZE) / 2 - DAY_SEPARATOR_WIDTH + MONTH_HEADER_SIZE; int paddingDay = (mWidth - 2 * mPadding) / (2 * mNumDays); int dayOffset = findDayOffset(); int day = 1; while (day <= mNumCells) { int x = paddingDay * (1 + dayOffset * 2) + mPadding; if (mMonth == mSelectedBeginMonth && mSelectedBeginDay == day && mSelectedBeginYear == mYear) { if (mDrawRect) { RectF rectF = new RectF(x - DAY_SELECTED_CIRCLE_SIZE, (y - MINI_DAY_NUMBER_TEXT_SIZE / 3) - DAY_SELECTED_CIRCLE_SIZE, x + DAY_SELECTED_CIRCLE_SIZE, (y - MINI_DAY_NUMBER_TEXT_SIZE / 3) + DAY_SELECTED_CIRCLE_SIZE); canvas.drawRoundRect(rectF, 10.0f, 10.0f,mSelectedCirclePaint); } else { canvas.drawCircle(x, y - MINI_DAY_NUMBER_TEXT_SIZE / 3, DAY_SELECTED_CIRCLE_SIZE, mSelectedCirclePaint); } Log.d("day : "+day,"cellNum : "+mNumCells); } else { if (mHasToday && (mToday == day)) { Log.d("1day : "+day,"cellNum : "+mNumCells); canvas.drawCircle(x, y - MINI_DAY_NUMBER_TEXT_SIZE / 3, DAY_SELECTED_CIRCLE_SIZE, mCurrentCirclePaint); } else { drawMonthTitle(canvas); Integer dotsCount = eventSymbols.get(day); if (dotsCount != null && dotsCount > 0) { drawDots(x, y, dotsCount, canvas); } } } if (dayOffset == 0 || dayOffset == mNumDays - 1) { mMonthNumPaint.setColor(mWeekendsColor); } else { mMonthNumPaint.setColor(mDayNumColor); } if (mMonth == mSelectedBeginMonth && mSelectedBeginDay == day && mSelectedBeginYear == mYear) mMonthNumPaint.setColor(mMonthTitleBGColor); if (!isPrevDayEnabled && prevDay(day, today) && today.month == mMonth && today.year == mYear) { mMonthNumPaint.setColor(mPreviousDayColor); mMonthNumPaint.setTypeface(Typeface.defaultFromStyle(Typeface.ITALIC)); } if (shouldShowMonthInfo) { mMonthNumPaint.setAlpha(DRAGING_ALPHA); } else { mMonthNumPaint.setAlpha(NORMAL_ALPHA); } canvas.drawText(String.format("%d", day), x, y, mMonthNumPaint); dayOffset++; if (dayOffset == mNumDays) { dayOffset = 0; y += mRowHeight; } day++; } } private void drawMonthInfo(Canvas canvas) { int x = (mWidth + 2 * mPadding) / 2; int y = (int) (mRowHeight * 3.2); canvas.drawText(getMonthAndYearString(), x, y, mMonthInfoPaint); } public SimpleMonthAdapter.CalendarDay getDayFromLocation(float x, float y) { int padding = mPadding; if ((x < padding) || (x > mWidth - mPadding)) { return null; } int yDay = (int) (y - MONTH_HEADER_SIZE) / mRowHeight; int day = 1 + ((int) ((x - padding) * mNumDays / (mWidth - padding - mPadding)) - findDayOffset()) + yDay * mNumDays; if (mMonth > 11 || mMonth < 0 || CalendarUtils.getDaysInMonth(mMonth, mYear) < day || day < 1) return null; return new SimpleMonthAdapter.CalendarDay(mYear, mMonth, day); } protected void initView() { mMonthTitlePaint = new Paint(); mMonthTitlePaint.setFakeBoldText(true); mMonthTitlePaint.setAntiAlias(true); mMonthTitlePaint.setTextSize(MONTH_LABEL_TEXT_SIZE); mMonthTitlePaint.setTypeface(Typeface.create(mMonthTitleTypeface, Typeface.NORMAL)); mMonthTitlePaint.setColor(mMonthTextColor); mMonthTitlePaint.setTextAlign(Align.CENTER); mMonthTitlePaint.setStyle(Style.FILL); mMonthInfoPaint = new Paint(); mMonthInfoPaint.setFakeBoldText(true); mMonthInfoPaint.setAntiAlias(true); mMonthInfoPaint.setTextSize(MONTH_INFO_TEXT_SIZE); mMonthInfoPaint.setTypeface(Typeface.create(mMonthTitleTypeface, Typeface.NORMAL)); mMonthInfoPaint.setColor(mDayNumColor); mMonthInfoPaint.setTypeface(Typeface.defaultFromStyle(Typeface.BOLD)); mMonthInfoPaint.setTextAlign(Align.CENTER); mMonthInfoPaint.setAlpha(0); mMonthInfoPaint.setStyle(Style.FILL); mSelectedCirclePaint = new Paint(); mSelectedCirclePaint.setFakeBoldText(true); mSelectedCirclePaint.setAntiAlias(true); mSelectedCirclePaint.setColor(mSelectedDaysColor); mSelectedCirclePaint.setTextAlign(Align.CENTER); mSelectedCirclePaint.setStyle(Style.FILL); mCurrentCirclePaint = new Paint(); mCurrentCirclePaint.setFakeBoldText(true); mCurrentCirclePaint.setAntiAlias(true); mCurrentCirclePaint.setColor(mCurrentDayColor); mCurrentCirclePaint.setTextAlign(Align.CENTER); mCurrentCirclePaint.setStyle(Style.FILL); mMonthDayLabelPaint = new Paint(); mMonthDayLabelPaint.setAntiAlias(true); mMonthDayLabelPaint.setTextSize(MONTH_DAY_LABEL_TEXT_SIZE); mMonthDayLabelPaint.setColor(mMonthDayLabelTextColor); mMonthDayLabelPaint.setTypeface(Typeface.create(mDayOfWeekTypeface, Typeface.NORMAL)); mMonthDayLabelPaint.setStyle(Style.FILL); mMonthDayLabelPaint.setTextAlign(Align.CENTER); mMonthDayLabelPaint.setFakeBoldText(true); mMonthNumPaint = new Paint(); mMonthNumPaint.setAntiAlias(true); mMonthNumPaint.setTextSize(MINI_DAY_NUMBER_TEXT_SIZE); mMonthNumPaint.setStyle(Style.FILL); mMonthNumPaint.setTextAlign(Align.CENTER); mMonthNumPaint.setFakeBoldText(false); } protected void onDraw(Canvas canvas) { calculateAlpha(); drawMonthNums(canvas); drawMonthInfo(canvas); } protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) { setMeasuredDimension(MeasureSpec.getSize(widthMeasureSpec), mRowHeight * mNumRows + MONTH_HEADER_SIZE + PADDING_BOTTOM); } protected void onSizeChanged(int w, int h, int oldw, int oldh) { mWidth = w; } public boolean onTouchEvent(MotionEvent event) { if (event.getAction() == MotionEvent.ACTION_UP) { SimpleMonthAdapter.CalendarDay calendarDay = getDayFromLocation(event.getX(), event.getY()); if (calendarDay != null) { onDayClick(calendarDay); } } return true; } public void reuse() { mNumRows = DEFAULT_NUM_ROWS; eventSymbols.clear(); requestLayout(); } public void setMonthParams(HashMap<String, Integer> params) { if (!params.containsKey(VIEW_PARAMS_MONTH) && !params.containsKey(VIEW_PARAMS_YEAR)) { throw new InvalidParameterException("You must specify month and year for this view"); } setTag(params); if (params.containsKey(VIEW_PARAMS_HEIGHT)) { mRowHeight = params.get(VIEW_PARAMS_HEIGHT); if (mRowHeight < MIN_HEIGHT) { mRowHeight = MIN_HEIGHT; } } if (params.containsKey(VIEW_PARAMS_SELECTED_BEGIN_DAY)) { mSelectedBeginDay = params.get(VIEW_PARAMS_SELECTED_BEGIN_DAY); } if (params.containsKey(VIEW_PARAMS_SELECTED_BEGIN_MONTH)) { mSelectedBeginMonth = params.get(VIEW_PARAMS_SELECTED_BEGIN_MONTH); } if (params.containsKey(VIEW_PARAMS_SELECTED_BEGIN_YEAR)) { mSelectedBeginYear = params.get(VIEW_PARAMS_SELECTED_BEGIN_YEAR); } mMonth = params.get(VIEW_PARAMS_MONTH); mYear = params.get(VIEW_PARAMS_YEAR); mHasToday = false; mToday = -1; mCalendar.set(Calendar.MONTH, mMonth); mCalendar.set(Calendar.YEAR, mYear); mCalendar.set(Calendar.DAY_OF_MONTH, 1); mDayOfWeekStart = mCalendar.get(Calendar.DAY_OF_WEEK); if (params.containsKey(VIEW_PARAMS_WEEK_START)) { mWeekStart = params.get(VIEW_PARAMS_WEEK_START); } else { mWeekStart = mCalendar.getFirstDayOfWeek(); } mNumCells = CalendarUtils.getDaysInMonth(mMonth, mYear); for (int i = 0; i < mNumCells; i++) { final int day = i + 1; if (sameDay(day, today)) { mHasToday = true; mToday = day; } mIsPrev = prevDay(day, today); } mNumRows = calculateNumRows(); } public void showMothInfo(boolean show) { if (shouldShowMonthInfo != show) { shouldShowMonthInfo = show; alphaStartTime = System.currentTimeMillis(); } } private void calculateAlpha() { long elapsedTime = System.currentTimeMillis() - alphaStartTime; int alphaChange = (int) ((NORMAL_ALPHA - 0) * elapsedTime / ALPHA_DURATION); currentDraggingAlpha = NORMAL_ALPHA - alphaChange; if (currentDraggingAlpha < 0 || alphaStartTime == -1) { currentDraggingAlpha = 0; } currentNormalAlpha = alphaChange; if (currentNormalAlpha > NORMAL_ALPHA) { currentNormalAlpha = NORMAL_ALPHA; } if (shouldShowMonthInfo) { mMonthInfoPaint.setAlpha(currentNormalAlpha); mMonthTitlePaint.setAlpha(DRAGING_ALPHA); mSelectedCirclePaint.setAlpha(DRAGING_ALPHA); mCurrentCirclePaint.setAlpha(DRAGING_ALPHA); mMonthDayLabelPaint.setAlpha(DRAGING_ALPHA); } else { mMonthInfoPaint.setAlpha(currentDraggingAlpha); mMonthTitlePaint.setAlpha(NORMAL_ALPHA); mSelectedCirclePaint.setAlpha(NORMAL_ALPHA); mCurrentCirclePaint.setAlpha(NORMAL_ALPHA); mMonthDayLabelPaint.setAlpha(NORMAL_ALPHA); } if(elapsedTime < ALPHA_DURATION) { this.postInvalidateDelayed( 1000 / FRAMES_PER_SECOND); } } public void setEventSymbols(HashMap<SimpleMonthAdapter.CalendarDay, Integer> symbols) { eventSymbols.clear(); for (HashMap.Entry<SimpleMonthAdapter.CalendarDay, Integer> entry : symbols.entrySet()) { eventSymbols.put(entry.getKey().getDay(), entry.getValue()); } } public void setOnDayClickListener(OnDayClickListener onDayClickListener) { mOnDayClickListener = onDayClickListener; } public static abstract interface OnDayClickListener { public abstract void onDayClick(SimpleMonthView simpleMonthView, SimpleMonthAdapter.CalendarDay calendarDay); } }
java
Detroit Tigers shortstop Javier Baez has recently been a target for fans mocking him on Twitter after his performance against the Toronto Blue Jays in spring training. The world of sports can be a cruel and unforgiving place, especially when it comes to social media. That came to the fore once again recently when MLB Twitter took a dig at Baez after a video of him being struck out in Spring Training went viral. Fans and pundits alike quickly jumped on the bandwagon, making snide comments and sarcastic jokes at the expense of the Tigers' star player. The video in question shows Baez facing off against pitcher Ricky Tiedemann during a spring training game. Baez got struck out by Tiedemann with a 99.4 MPH fastball. The video quickly made its way across social media, with many fans and pundits chiming in with their thoughts. Unfortunately, not all comments were lighthearted. Some took the opportunity to criticize Baez's overall performance, claiming that he's overrated and not worth the hype. That's despite Baez being widely regarded as one of the best infielders in the league. Despite the negativity, many fans came to Baez's defense. They pointed out that Spring Training is just a warm-up and that Baez has a proven track record of success during the regular season. They also noted that no player is immune to striking out, and that even the best batters in the league have off days. In a Twitter thread that went viral, one fan wrote: "Don't all pitchers strike out Baez, though?" Another chimed in: "Nasty, but I think Farmer Jim could walk up throwing 62 mph and blow Baez away." Here are the other reactions: The Twitter backlash against Javier Baez was just another reminder of how quickly public opinion can turn around in the world of sports. One minute you can be a hero, and the next you can be the target of cruel and unfounded criticism. However, with a strong support system and dedication to one's craft, it's possible to rise above negativity and continue to succeed on the field. Such criticism is something professional athletes face regularly, but they cannot let that affect their game. Javier Baez, a former World Series champion, will look to excel for the Detroit Tigers in his second season with them. Click here for 2023 MLB Free Agency Tracker Updates. Follow Sportskeeda for latest news and updates on MLB.
english
What is the advantage of having guest posts in our blog? want to write guest post ? Write Freelance is looking for Guest Bloggers (Paid gig) Want a guest writer for my blog - junksin. Anyone accepting guest posts for an article about SEO? Would you like to guest blog?
english
<gh_stars>0 { "name": "fetch-decode", "version": "0.3.0", "description": "Browser oriented fetch lib using fp-ts + io-ts to decode and taskify REST API requests", "main": "dist/index.js", "types": "dist/index.d.ts", "files": [ "dist" ], "scripts": { "build": "tsc", "prepare": "npm run build", "tap": "tap", "test": "tap" }, "repository": { "type": "git", "url": "https://github.com/henry-hc/fetch-decode" }, "homepage": "https://github.com/henry-hc/fetch-decode", "author": "<NAME> <<EMAIL>>", "license": "MIT", "devDependencies": { "fp-ts": "*", "io-ts": "*", "node-fetch": "^2.6.1", "prettier": "^2.1.2", "tap": "^14.10.8", "typescript": "^4.0.5" }, "peerDependencies": { "fp-ts": "*", "io-ts": "*" }, "packageManager": "yarn@3.0.2" }
json
{ "hello": "Bonjour", "translations.are.incredible": "Les traductions sont incroyables.", "very": { "compound": { "key": "La clé composée" } } }
json
<filename>app/content/lexicons/strongs/entries/H3778.json {"derivation": "(occasionally with enclitic) \u05db\u05bc\u05b7\u05e9\u05c2\u05b0\u05d3\u05bc\u05b4\u05d9\u05de\u05b8\u05d4; towards the Kasdites into Chaldea), patronymically from H3777 (\u05db\u05bc\u05b6\u05e9\u05c2\u05b6\u05d3) (only in the plural);", "pron": "kas-dee'", "outline": "<ol><li> a territory in lower Mesopotamia bordering on the Persian Gulf (n pr m)</li><li> the inhabitants of Chaldea, living on the lower Euphrates and Tigris</li><li> those persons considered the wisest in the land (by extension)</li></ol>", "kjv_def": "Chaldeans, Chaldees, inhabitants of Chaldea.", "lemma": "\u05db\u05bc\u05b7\u05e9\u05c2\u05b0\u05d3\u05bc\u05b4\u05d9", "frequency": 80, "strongs_def": "a Kasdite, or descendant of Kesed; by implication, a Chaldaean (as if so descended); also an astrologer (as if proverbial of that people", "xlit": "Kasd\u00eey"}
json
I am very satisfied with the Protocol for Life Balance Molecularly Distilled Ultra Omega-3 supplement! The quality and purity of the ingredients are exceptional, with 500 EPA and 250 DHA per serving. The 180 softgels come in a convenient and easy-to-use package. The benefits of taking this supplement are numerous, including supporting heart health, reducing inflammation, and improving cholesterol levels. The best part is that there is no fishy after-taste, making it a pleasant experience to take daily. Overall, this product deserves a five-star rating for its effectiveness and quality.
english
<reponame>mickvav/LogDevice<gh_stars>1000+ #!/usr/bin/env python3 # Copyright (c) Facebook, Inc. and its affiliates. # All rights reserved. # # This source code is licensed under the BSD-style license found in the # LICENSE file in the root directory of this source tree. from __future__ import absolute_import, division, print_function, unicode_literals import unittest import logdevice.client class LogDeviceUnitTest(unittest.TestCase): "Tests that do not need a local LogDevice cluster" def setUp(self): self._initialLogLevel = logdevice.client.getLoggingLevel() def tearDown(self): logdevice.client.setLoggingLevel(self._initialLogLevel) def test_GapType(self): self.assertEqual(str(logdevice.client.GapType.BRIDGE), "BRIDGE") self.assertEqual( logdevice.client.GapType.BRIDGE, logdevice.client.GapType.BRIDGE ) self.assertNotEqual( logdevice.client.GapType.BRIDGE, logdevice.client.GapType.HOLE ) def test_docstring_crash(self): # this would previously segfault, due to a recursive casting issue # with the boost::python doc generation. lets verify it stays fixed. logdevice.client.Client.append.__doc__ def test_logdevice_error(self): self.assertIsInstance( logdevice.client.LogDeviceError("testing"), Exception, "correct exception ancestry", ) def test_logging_level(self): def test(logLevel): logdevice.client.setLoggingLevel(logLevel) self.assertEquals(logdevice.client.getLoggingLevel(), logLevel) loggingLevel = logdevice.client.LoggingLevel test(loggingLevel.NONE) test(loggingLevel.CRITICAL) test(loggingLevel.ERROR) test(loggingLevel.WARNING) test(loggingLevel.NOTIFY) test(loggingLevel.INFO) test(loggingLevel.DEBUG) test(loggingLevel.SPEW) self.assertEqual( logdevice.client.parse_log_level(str("error")), loggingLevel.ERROR ) def test_lsn_to_string(self): tests = ((283467847824, "e66n6288"), (85899668877, "e20n322957")) for test in tests: self.assertEqual(logdevice.client.lsn_to_string(test[0]), test[1])
python
<filename>data/scraped_data/coreNLP_output_2019_guardian/science.2019.jun.24.ill.be.flying.till.i.die.why.wally.funk.wont.give.up.her.lifelong.space.mission.txt.json version https://git-lfs.github.com/spec/v1 oid sha256:f37f4822081f5901d71b3ae89d7fade2bc5019aef9f25f78ba88a0ad6f2fb9c8 size 2205007
json
Actor Sridevi suffered a cardiac arrest and passed away in the early hours of Sunday. Leaders and film fraternities across the country mourned the loss of the veteran actor. Prime Minister Narendra Modi expressed his condolences and tweeted: Saddened by the untimely demise of noted actor Sridevi. She was a veteran of the film industry, whose long career included diverse roles and memorable performances. My thoughts are with her family and admirers in this hour of grief. May her soul rest in peace. President Ram Nath Kovind said she had left millions of fans heartbroken. "Shocked to hear of passing of movie star Sridevi. She has left millions of fans heartbroken. Her performances in films such as Moondram Pirai, Lamhe and English Vinglish remain an inspiration for other actors. My condolences to her family and close associates," he tweeted. Actor Rajinikanth said he had lost a true friend and the industry, a true legend. "I’m shocked and very disturbed. I’ve lost a dear friend and the industry has lost a true legend. My heart goes out to her family and friends. I feel the pain with them #RIPSridevi . . . you will be missed," he tweeted. Speaking to media persons outside his residence, he said, "I was extremely shocked to hear of her demise. I've known her for around 40 years and we've been acting together since my second film. and she's a very good friend. May her soul rest in peace and my condolences to Boney Kapoor and her family. "Everyone knows how good an actor she was. Off camera, she would be normal and listen to all the instructions given to her. And then suddenly on camera, it was as if she was fire, like electricity her performance would be. I have always greatly admired how she effortlessly acted in Hindi films too. " Actor Kamal Hasaan recalled working with Sridevi. "Have witnessed Sridevi's life from an adolescent teenager to the magnificeint lady she became. Her stardom was well deserved. Many happy moments with her flash through my mind including the last time I met her. Sadma 's lullaby haunts me now. We'll miss her," he tweeted. Andhra Pradesh Chief Minister Chandrababu Naidu also expressed his condolences. "As a multi lingual actress, especially for the Telugus, she became the most favorite heroine. She remains as a proud actress of India with her unparalleled acting skills," ANI reported him as saying. The official twitter handle of the Congress tweeted that she was a legend who would "continue to live in our hearts". "We regret to hear about the passing away of Sridevi. An actor par excellence. A legend who will continue to live in our hearts through her stellar body of work. Our deepest condolences to her loved ones. She was awarded the Padma Shri by the UPA Govt in 2013," the party's handle tweeted. Congress President Rahul Gandhi : Shocked to hear about the sudden and untimely death of one of India’s favourite actress, Sridevi. Sridevi was an incredibly talented and versatile actress whose vast body of work spanned a range of genres and languages. My condolences to her family. May her soul rest in peace. Congress leader Shashi Tharoor quoted Austrian poet Rainer Maria Rilke from Sonnets to Orpheus . "Let your presence ring out like a bell into the night. And if the earthly no longer knows your name, whisper to the silent earth: I am flowing. To the flashing water say: I am," he tweeted. Tamil Nadu Deputy Chief Minister O. Paneerselvam tweeted: My Heartfelt Condolences to the untimely and unfortunate demise of the veteran,versatile and vibrant actress SrideviBKapoor . Her impeccable life and illustrious career has impressed every one surpassing generations! May her soul rest in peace. Jeetendra : On this day, I'm at a loss of words owing to shock and utter disbelief. Having worked closely with Sri in 16 films, it's hard for me to even express how this feels, let alone take it in my stride as one of life's inevitability. All I can say, though, is that she was a very special co-star, a rare talent combined with extreme professionalism and hard work. May God give her family the strength at this hour to deal with this situation and above all, may her soul rest in peace. Will miss you Sri! . Karan Johar : I danced to “Hawa Hawai” when I was in school. I have seen every film of hers multiple times. I met her with shaking hands and feet on the sets of my fathers film Gumrah and felt I had arrived when she called me for the first time. Every time I met her I had a star-struck moment and a fan-boy vibe. I don’t think I can believe it. Perhaps I don’t think I want to believe that she is no more. She is a huge reason I love the movies. I feel like Indian cinema just lost its smile. The heavens are fortunate they just inherited a gift of life. Heartbroken. Former editor of Filmfare , Rauf Ahmed : I used to do the Filmfare Awards in the south, and it was rather casual in the '80s for South Indian filmmakers to make Hindi films. Jaya Prada and Sridevi had had this fierce competition. Jaya Prada’s brother, who owned cinemas, blocked Sridevi’s films from being screened. But they lost a lot of money and it didn’t make sense to be this childish and immature. Jeetendra brought Sridevi to Bollywood with her second Hindi film Himmatwala . The film did very well and Sridevi overtook Jaya Prada, but [the former] was a greater dancer and was considered to have more sex appeal. In fact she overtook everybody. I remember I asked Javed Akhtar – when I was doing a cover story on Sridevi for Filmfare – and he said Sridevi’s the first heroine who has brought to the screen the kind of sensuality she became known for. Once Himmatwala happened, she always won praise. [In 1990] there was a bit of controversy when Sridevi won the Filmfare Award for Best Actress for Chaalbaaz instead of Chandni. The jury felt her performance in Chaalbaaz was superior but most people in the industry felt it was gimmicky and that Chandni was more emotionally touching. Sridevi stood out with her films; especially with Yash Chopra’s Chandini . But she had already established herself by then. Then in the '90s there was competition between Sridevi and Madhuri Dixit about who Saroj Khan worked with. At the time, both Anil and Boney Kapoor were backing Madhuri Dixit. Things got very bad for Sridevi around the time her mother died and her sister Latha became estranged. She felt alone and insecure. She was getting too insecure, about being a woman who’s not from the north, not so fluent in Hindi. She was initially very diffident about [interviews] and not very fluent in English and couldn't speak Hindi very fluently but she was a great performer. In the beginning, she was a little intimidated by the media in Bombay. She was not openly flamboyant and she would underplay herself. She was always professional and didn’t talk too much because she was concerned about being watched [by the media]. After Himmatwala , I think she gained more confidence. She was very communicative if she trusted you and she would speak to you very well. She is my favourite personally and she's a phenomenal actress. Boney Kapoor challenged Shekar Kapoor to make Sridevi sexier than ‘ Har kisko nahin milta’ in Feroz Khan’s Janbaaz. It was a sensuous dance, the first time for Sridevi. At that time, Saroj Khan was taking a lot of care of Sridevi. That’s how ‘ Kaate Nahi Katte’ came about, because of a challenge. Choreographer Saroj Khan : I met her when I was choreographing the song ' Maine Rab Se Tujhe” for Karma . Her dance style was more of the [South Indian] Madras-style and we used to have to do a few retakes. But she still danced well. Then, she herself said, “Saroj-ji, please give me more rehearsals, I’m not a good dancer. ” Her truthfulness really took my surprise because no artiste likes to admit they’re not good. We became the best of friends and had the best of master and teacher relationship. We never choose our relationships. When she got married she left the industry. She came back with English Vinglish (2012) but there was no dancing in the film. But we were good friends. My fondest memory is the day she stopped my car on the road and introduced her two daughters saying, “Saroj-ji, how are you. Here are my daughters. ” A big artiste like her getting down in the middle of the road and bringing her daughters to me. That's a big thing. I will always remember her in the mornings when she would come and say, “Hello Saroj-ji”, and she would hold me tight and give me a kiss. Even your own child won’t do that. I will also remember a New Year's party when she invited me and my six dancer boys to her house in Madras. [It was when we were shooting songs for Gurudev (1993). ] She sent us seven tickets and they were playing dandiya. I was staying in her house and when I got up in the morning, there was a jewel box kept near my pillow. I got scared that I slept in the wrong room. I found her mother and told her about the box on my pillow. She said Shree has kept it there for you. Inside there was a diamond jewellery set with rings, necklace, earrings and kadhas. And she gave Rs 11,000 to all my boys each and a return ticket. We also played a prank on her. The boys saw her having champagne the previous night so they pretended to be hurt by her dandiya. Her father was standing there and saw me telling the boys “thoda aur langedke chal” and he must have told her. When she saw the boys, she cried, “I did this? ”. The next thing she calls us for lunch and we see all gold vessels. She said to me, “Masterji, first you eat and then your boys will eat. ” When i opened one dish, there were stones, another had sand and third had paper. We all burst out laughing. She was a doll. That's all I can say. It’s not because she gave me jewellery but because she was [a wonderful] human. I have no more words. Actor Nagarjuna Akkineni : I met Sridevi on the sets of one of my father's film, in which she acted as his daughter. My dad always considered her like his daughter. He was fond of her. Maybe now they both can say hi to each other. I am at a loss for words, don't know whether to cry or smile remembering the good memories. She was three years younger to me but much more experienced than me as an actor. When I got the chance to act with her, in Aakhari Poratam , I was nervous. I had observed her from a distance, but was scared that I would make a fool of myself. We were shooting in a car on beach road, Madras, and I was forgetting my lines. Away from the camera, she would whisper my lines. Later we burst out laughing. We kept in touch over the years, have been good friends. I hope her two beautiful daughters get the strength to overcome this loss. Sridevi conquered every industry she set foot in. There won't be another like her. Actor Adil Hussain , who worked with Sridevi English Vinglish recalls his association with the actor: My first experience of meeting Sridevi was the day I went to do the tests rehearsals (for English Vinglish ). I had done just three films before, I was sort of an infant in front of her in terms of skill. I remember we were sitting besides each other and I told her that I saw your film Sadma long ago. I still remember that I couldn’t speak for two whole days after I watched the film because of its impact and its sadness. And she looked at me, and she had moist eyes. It was then that I realised in that every tiny 30-second interaction – of course we went ahead and rehearsed more – but she’s such a vulnerable and defenceless person and she opens up her entire being in order to let you enter her and sort of face the turmoil [of her character]. That's one of the rarest of qualities any actor can have. I personally think vulnerability is the key to a versatility. She allows the audience to sort of come through the window of her soul and enter her personal space. She executes all her emotions in front of the camera with such finesse, it’s kind of an Indianness, not in a nationalist kind of way, but the inherent Eastern aesthetics and the tenderness and grace that we possess just by virtue of being born in this part of this world. [She had that] in spite of her being educated in a Western system as we all are. [It’s something] which I rarely see in any actor today. It was a unique experience [working with her] and the kind of respect she had for a newcomer as me playing her husband, it was a gift. And more so I feel it right now. I didn’t expect her to leave so suddenly and it's frustrating and I felt angry. I didn't have a personal relationship with her, and after just a few a few meetings I had with [her] I feel I’m going to be deprived of her. Of course it’s a deeply personal loss to her family, but’s it’s an impersonal loss of being not being able to see her onscreen, especially with talent which rarely any other actor has. Cricketer Sachin Tendulkar said it was difficult to digest that she was not with us anymore. "I have no words to express how i feel. We have grown up seeing her. It is difficult to digest that she is not with us. My heartiest condolences to her family," ANI reported Mr. Tendulkar as saying. Actor Farhan Akhtar recalled his first job, working on the sets of Lamhe. "My first job in 1990 was on Lamhe and this song Megha re Megha was the very first time I saw this legendary actor create her incredible magic on screen. From Sadma to Chalbaaz , from Mr. India to Chandni , it was impossible to take your eyes off her when she appeared on screen. A true star. A gifted actor. A woman with tremendous dignity. Gone too soon. RIP Sridevi. Sad sad day," he posted on Instagram. Music director A. R. Rahman tweeted his condolences, while veteran actor Amitabh Bachchan tweeted, "I don't know why, I feel this strange fear. " Actor Venkatesh said there was only one Sridevi and she was unparelled. "It’s shocking to wake up to this news. I am still wondering if the news is true. This shouldn’t have happened to her. I have known her since childhood, much before I became an actor. I don’t remember when I met her first, but I think it was in Chennai when she was a child actor. She was extremely disciplined and graceful. She as born to be an actor," he said. Union Minister Smriti Irani called Sridevi a powerhouse of acting. "Sridevi - a powerhouse of acting , a long journey embellished with success comes to a sudden end. My condolences to her loved ones and fans," she tweeted. Actor Radhikaa Sarathkumar who has starred with Sridevi in several films said she was an artiste par excellence. "So shocked to hear about sridevikapoor, still in shock. my heart goes out to her family. An artiste par excellence, co starred in many movies with her. Can’t believe this," she tweeted. Suresh Triveni, director of Tumhari Sulu: My first and only memory of meeting her was at the preview of Tumhari Sulu at NSCI (National Sports Club of India) auditorium in Worli. She took time off her hectic schedule and drove all the way to town to wish Vidya Balan and the entire team. It was a dream come true for me. I am a huge fan of Sridevi's. Who is not? It was a brief opportunity of interaction with her. I told her that I couldn't believe I was standing in front of her. It is the memory of the icon that I take back with me. The song Hawa Hawai 2. 0 was meant to be a tribute to her, never to match up to her. Also the way Vidya Balan says Balma . It was about referencing popular culture and no one personifies popular culture better than Sridevi. She leaves behind an immense body of work. I loved her in Sadma , English Vinglish , Lamhe and more recently in Mom . She has been part of en entire generation of film lovers. I haven't come across anyone who didn't like her. Her passing on is a loss for us filmmakers. One would have liked to have worked with her. So many stories that could have been made [with her] will now take a backseat. Veteran director Shekhar Kapur said an era was over. "SriDevi . . gone. It's like an era is over. Like life turning a new chapter. A beautiful story just ended. An amazing spirit just vanished leaving us with amazing love, memories, and incredible grief," he tweeted. Actor Sushmita Sen tweeted: "I just heard Ma’am Sridevi passed away due to a massive cardiac arrest. I am in shock. . . cant stop crying. . . ", while actor Priyanka Chopra said it was a dark day. "I have no words. Condolences to everyone who loved Sridevi. A dark day. RIP. " "Just woke up to the saddest news. . Sridevi is no more amongst us. . the most talented and most beautiful. . no words to express the grief. . my deepest condolences to the family. . May the force be with them in such hard times. . her childlike laughter will be missed. . RIP," tweeted actor Khushbu Sundar . "Shocked beyond words at the passing away of SrideviBKapoor ! Each of your expression will remain etched in our mind for ever! Can’t believe you are gone, a true star among the stars! Condolences to the family. RIP SRIDEVI," tweeted Resul Pookutty . Kona Venkat , one of the writers of her last film Mom: The Indian film industry has lost a great soul, a great actress. Like everyone else, I am also coming to terms with the fact that she is no more. The first film for which I was associated with her is Mom . I didn’t think it will be the last one. She was a very warm person. I convey my heartfelt condolences to her family. May she rest in peace. Veteran actor Lakshmi : I've acted with Sridevi in several films in Tamil telugu and Malayalam. She's played my younger version and my younger sister in several films and I've never seen a more dedicated and sincere child artist. Every producer and director was lucky to work with her. It's hard to come across a celebrity like her, with no airs. I received the news of her demise early this morning and it has come as a huge shock to all of us in the industry. She will always be remembered as a committed, hard working and dedicated actress who was always ready to give her best. Actor Madhavan said the film industry would never be the same again. "Shocked and deeply saddened by the tragic and sudden passing away of a Legend of Indian Cinema Srideviji. Cant imagine what the family is going thru. Our industry will never be the same again. She was the kindest soul apart from being a Giant performer. The heavens are lucky. RIP," he tweeted. Actor Boman Irani : Just woken up to the tragic and shocking news of the passing of our dear Sridevi ji. Heartfelt condolences to Boneyji and her family. Actor Hansika , who played Sridevi's daughter in her last Tamil film 'Puli', says: It’s a very little big loss. I’ve been a huge fan ever since I watched 'Lamhe'. When I worked with her in 'Puli', I got to speak to her a lot because most of my scenes were with her. She spoke to me a lot of about her journey in cinema, and with me, being a child actor first, could draw a lot of parallels with her life. We could see the pros and cons of starting out early in the industry. Apart from that, I remember we bonded over how I often I would speak to my mother. She said that her daughters too were like me in the way we just needed to speak to our moms ever so often. My heart now goes out to her family and her daughters. Stay strong. Actor Priya Anand : I am deeply saddened by the news of her passing. I spent a big chunk of my childhood following her movies and imitating her dance! My life's biggest gift was working on 'English Vinglish'. And what struck me the most was what an amazing mom she was! Such a terrible loss for her family and friends and fans all over the world like me. Actor Rishi Kapoor : Woken up to this tragic news. Absolute shock. Sad. Heartfelt condolences to Boney and their two daughters! CPI (M) leader Sitaram Yechury : Actor Sridevi brought so many varied characters to life, over such a long span and in so many languages. She had so much more to do. Condolences to her near and dear ones. Telangana Governor E. S. L. Narasimhan expressed shock at the sudden demise of Sridevi and said the film industry has suffered an irreparable loss. Telangana Chief Minister K Chandrashekhar Rao said in her death, the Indian film industry had a void and left Telugu film industry in sorrow. He also conveyed his condolences to the members of the bereaved family. YSR Congress Party president Y. S. Jagan Mohan Reddy expressed shock and said that the veteran actor rode the film industry like a colossus with her charm, talent and agility. "It is loss to the industry and film lovers, more so, generations of filmgoers in the country," he said. Telangana Congress President N. Uttam Kumar Reddy , actor and Janasena founder Pawan Kalyan and Tamil Nadu Governor Banwarilal Purohit all expressed their condolences. Actor Niithin : I truly wish it's not true, deeply saddened by the news RIP . . . Legendary Sridevi. . deepest condolences to the family. Maharashtra Chief Minister Devendra Fadnavis said the country has lost a brilliant actor who ruled the Indian cinema for decades together with her exemplary acting skills. “Her roles in movies such as ‘Sadma’, ‘Chandni’, ’Lamhe’ and ‘English-Vinglish’ will be remembered for a long time,” he said. Producer A. M. Ratnam : My association with Sridevi goes back a long way. Most of my superhits were remade in Hindi by Mr. Boney Kapoor. There was no trip to Mumbai where I would miss visiting their family. I'm unable to digest the fact that such a good human being and a good actress is no more with us. Actor Balakrishna : She had acted in many movies with my father. She had the ability to emote any situation through her eyes. Her sudden death is a great loss to the film fraternity. I wish her soul rests in peace. Actor Pawan Kalyan : She won hearts across the country, regardless of language. It's tough to believe that she's no more, yet her roles in iconic movies will stay with us forever. I still remember her song Boochadamma in Badipantulu and her wide gamut of expressions. I hold her innocent performance with my brother Chiranjeevi in Jagadeka Veerudu Atiloka Sundari close to my heart. It's unfortunate that she couldn't see her daughter's entry into films. Her position in the Indian film industry is irreplaceable. Pay your tributes to Sridevi in the comments to this article. Select ones will be published by The Hindu in an article. (With inputs from Sangeetha Devi Dundoo, Poorvaja Sundar, Vishal Menon, Namrata Joshi , Deborah Cornelious and Agencies)
english