text
stringlengths
1
1.04M
language
stringclasses
25 values
BJP is a party with differences, the NCP said here on Monday, reacting to L. K. Advani’s resignation from the BJP Parliamentary Board, Election Committee and National Executive. “The party with a difference is indeed a party with differences as is evident from Advani’s resignation,” Maharashtra NCP spokesperson Mahesh Tapase said. “The fate of NDA is sealed as BJP suffers NaMonia. The UPA will bounce back to power in 2014 Lok Sabha elections,” he said.
english
<reponame>figarocorso/figarocorso.github.io<filename>_day_by_day/2018-06-14-concierto-avatar.md --- layout: post category: day-by-day date: 2018-06-14 title: Concierto Avatar image: thumbnail: /images/blog/thumbnails/2018-06-14-concierto-avatar.jpg path: /images/blog/2018-06-14-concierto-avatar.jpg ---
markdown
<gh_stars>10-100 import React from 'react'; import PropTypes from 'prop-types'; import { Table, TableBody, TableCell, TableContainer, TableHead, TableRow } from '@material-ui/core'; const CodeDetailsTable = ({ codeData }) => { return ( <TableContainer> <Table aria-label="code details table"> <TableHead> <TableRow> <TableCell>Code</TableCell> <TableCell>Code System</TableCell> <TableCell>Display</TableCell> </TableRow> </TableHead> <TableBody> <TableRow> <TableCell>{codeData.code}</TableCell> <TableCell>{codeData.systemName}</TableCell> <TableCell>{codeData.display}</TableCell> </TableRow> </TableBody> </Table> </TableContainer> ); }; CodeDetailsTable.propTypes = { codeData: PropTypes.shape({ code: PropTypes.string.isRequired, systemName: PropTypes.string.isRequired, display: PropTypes.string.isRequired }) }; export default CodeDetailsTable;
javascript
Bring the entire family for a day of skating and sliding at John Lake School Skating rink and Toboggan hill! Enjoy the hospitality of the Avalon Community Association over coffee, hot chocolate, and treats!! They will have sleigh rides available at the start of the afternoon, an oversized Cornhole-in-the-snow game and snowman-making contest and more. Where: John Lake School, 2606 Broadway Ave.
english
<reponame>SurfaceJS/surface import type IPattern from "./interfaces/pattern"; import TypeGuard from "./type-guard.js"; import type Token from "./types/token"; export function hasDuplicated(parameters: IPattern[]): boolean; export function hasDuplicated(parameters: IPattern[], lookeaheads: Token[]): { result: true, token: Token } | { result: false, token: null }; export function hasDuplicated(parameters: IPattern[], lookeaheads?: Token[]): boolean | { result: boolean, token: Token | null } { const cache = new Set<string>(); const isDuplicated = (pattern: IPattern): boolean => { if (TypeGuard.isIdentifier(pattern)) { if (cache.has(pattern.name)) { return true; } cache.add(pattern.name); } else if (TypeGuard.isAssignmentPattern(pattern)) { return isDuplicated(pattern.left); } else if (TypeGuard.isArrayPattern(pattern)) { for (const element of pattern.elements) { if (element && isDuplicated(element)) { return true; } } } else if (TypeGuard.isObjectPattern(pattern)) { for (const property of pattern.properties) { if (TypeGuard.isAssignmentProperty(property)) { if (isDuplicated(property.value)) { return true; } } else if (isDuplicated(property.argument)) { return true; } } } else if (TypeGuard.isRestElement(pattern)) { return isDuplicated(pattern.argument); } return false; }; if (lookeaheads) { for (let index = 0; index < parameters.length; index++) { if (isDuplicated(parameters[index])) { return { result: true, token: lookeaheads[index] }; } } return { result: false, token: null }; } return parameters.some(isDuplicated); }
typescript
33 you will be filled with (A)drunkenness and sorrow.(B)A cup of horror and desolation, the cup of (C)your sister Samaria; The Holy Bible, English Standard Version. ESV® Text Edition: 2016. Copyright © 2001 by Crossway Bibles, a publishing ministry of Good News Publishers.
english
<filename>assets/resources.json { "Fireship.io": { "date": "26-06-2021", "url": "https://www.youtube.com/channel/UCsBjURrPoezykLs9EqgamOA", "image": "https://yt3.ggpht.com/ytc/AKedOLTcIl6kKt3lEPJEySUf_hpHiKDKiFeo9eWPReLysQ=s88-c-k-c0x00ffffff-no-rj", "type": "youtube-channel", "detail": "Everything cool I know about front-end development, I learned from this channel." }, "Continuous Delivery": { "date": "26-06-2021", "url": "https://www.youtube.com/channel/UCCfqyGl3nq_V0bo64CjZh8g", "image": "https://yt3.ggpht.com/ytc/AKedOLTaTa15riM58dTUuON1ZZY3dt6DByTpnmQtLlU-=s88-c-k-c0x00ffffff-no-rj", "type": "youtube-channel", "detail": "For DevOps and Engineering" }, "<NAME>": { "date": "27-06-2021", "url": "https://www.youtube.com/c/HusseinNasser-software-engineering", "image": "https://yt3.ggpht.com/ytc/AKedOLQBFiy-urLmvQpjRxsZNutt53btgsu-JMTpMdojQQ=s88-c-k-c0x00ffffff-no-rj", "type": "youtube-channel", "detail": "Software engineering (especially the backend), Databases and System Design" }, "Freedom In Thoughts": { "date": "23-03-2022", "url": "https://www.youtube.com/channel/UCd6Za0CXVldhY8fK8eYoIuw", "image": "https://yt3.ggpht.com/pKvF3qL7I5Co0Mf4xLKte4YE4vjKnfrrpsFn2Uhqa1oUVzaSxPVbR-ZGFg-sONaV8W72IiN64xs=s88-c-k-c0x00ffffff-no-rj", "type": "youtube-channel", "detail": "I can't explain philosphy as good as Freedom in Thoughts does it." }, "Deep Work by Cal Newport": { "date": "26-06-2021", "url": "https://www.calnewport.com/books/deep-work/", "image": "https://www.calnewport.com/wp-content/uploads/2015/11/deep-work-cal-newport.jpg", "type": "books", "detail": "" }, "FastAI": { "date": "27-06-2021", "url": "https://www.fast.ai", "image": "https://course.fast.ai/images/company_logo.png", "type": "course", "detail": "Probably the best deep learning course I have come across" }, "Codecademy": { "date": "27-06-2021", "url": "https://www.codecademy.com/", "image": "https://www.codecademy.com/resources/blog/content/images/2021/05/blog-logo-3.svg", "type": "website", "detail": "Interatice coding for developers. I first came across it during college. Currently using it to learn React." }, "Python Tricks by <NAME>": { "date": "27-06-2021", "url": "https://www.amazon.in/Python-Tricks-Buffet-Awesome-Features/dp/1775093301", "image": "https://images-na.ssl-images-amazon.com/images/I/41Jia8+RIuL._SX331_BO1,204,203,200_.jpg", "type": "books", "detail": "A fun read. I must have read it in 2019." }, "The Personal MBA by <NAME>": { "date": "26-06-2021", "url": "https://personalmba.com/", "image": "https://www.ankushchoubey.com/images/mba.jpg", "type": "books", "detail": "" }, "Sapiens by <NAME>": { "date": "26-06-2021", "url": "https://www.ynharari.com/book/sapiens-2/", "image": "https://vialogue.files.wordpress.com/2017/04/sapiens.jpg", "type": "books", "detail": "" }, "Cracking the Coding Interview": { "date": "26-06-2021", "url": "https://www.crackingthecodinginterview.com/", "image": "https://miro.medium.com/max/952/1*P7pTGa-PMfCq1VWuNJioig.png", "type": "books", "detail": "Read this first in 2018. Will be reading this again soon." }, "Animal Farm by <NAME>": { "date": "26-06-2021", "image": "https://www.ankushchoubey.com/images/resources/animal_farm_george_orwell.jpg", "url": "https://en.wikipedia.org/wiki/Animal_Farm", "type": "books", "detail": "This is my favorite fiction book. It seems to be very relevant event today. A must read of everyone interested in understanding governmental systems." }, "Waking Up": { "date": "27-06-2021", "url": "https://wakingup.com/", "image": "https://wakingup.com/static/pure-home-cta-waking-up-2x-0ad1c1297b71b17961029c30aa1361aa.webp", "type": "app", "detail": "" }, "Simply Piano": { "date": "27-06-2021", "url": "https://www.joytunes.com/simply-piano", "image": "https://www.joytunes.com/images/company/masked3.jpg", "type": "app", "detail": "" } }
json
Mumbai, March 2: Former chief minister Ashok Chavan was appointed the new Maharashtra Pradesh Congress Committee president, with Sanjay Nirupam taking over as Mumbai’s party chief, officials said. Chavan replaced Manikrao Thakre, who headed the party for seven years and Nirupam took over from Dalit leader Jardhan Chandurkar, who headed the Mumbai Regiol Congress Committee for two years. The move came nearly 10 months after the Congress was routed in the Lok Sabha elections in 2014 and four months after suffering heavy losses in the October 2014 assembly polls. Thakre and Chandurkar had quit after the assembly defeat. Chavan and Nirupam are now expected to revive the party for the next polls. Hailing from nded in Marathwada region, Chavan, 56, was elected as the chief minister in December 2008 in the wake of 26/11 Mumbai terror attack and to replace late Vilasrao Deshmukh. However, Chavan was forced to quit in November 2010 after his me figured in the Adarsh Society scam. The first major challenge to Nirupam,, hailed as the north-Indian face of Congress in Mumbai, is set to come in the 2017 elections of Brihan Mumbai Municipal Corporation (BMC). (IANS)
english
<reponame>Shl-Pathak99/CafeSatna.github.io<filename>css/home.css *{ margin: 0px; padding: 0px; box-sizing: border-box; } body{ font-size: 20px; overflow-x: hidden; color: white; font-family: 'Flamenco', cursive; } header{ background-image: linear-gradient(rgba(0,0,0,0.6),rgba(0,0,0,0.6)), url('../imgs/background.jpg'); background-size: cover; background-repeat: no-repeat; background-position: center; height: 100vh; } .clearfix:after{ content: "."; visibility: hidden; display: block; height: 0px; clear: both; } .row{ max-width: 1180px; margin: 0 auto; } .logo{ height: 200px; width: auto; float: left; margin-top: 20px; } .main-nav{ float: right; margin-top: 60px; } .main-nav li{ display: inline-block; list-style: none; margin-left: 40px; } .main-nav li a{ padding: 5px 5px; color: #fff; text-decoration: none; text-transform: uppercase; font-size: 90%; font-weight: 100; display: inline-block; font-weight: lighter; border-radius: 200px; transition: background-color 0.2s, border 0.2s, color 0.2s } .main-nav li a:hover{ background-color: #bf55ec } .main-content-header{ width: 1200px; height: 300px; position: absolute; /*border: 1px solid red;*/ top: 55%; left: 50%; transform: translate(-50%, -50%); } h1{ color: #fff; font-size: 240%; word-spacing: 5px; letter-spacing: 3px; margin-bottom: 20px; margin-top: 20px; text-transform: uppercase; font-weight: lighter; } .btn{ display: inline-block; padding: 10px 30px; font-weight: lighter; text-decoration: none; text-transform: uppercase; border-radius: 200px; transition: background-color 0.2s, border 0.2s, color 0.2s; } .btn-full{ background-color: black; color:whitesmoke; margin-right: 15px; border: 1px solid whitesmoke; } .btn-full:hover{ background-color: #bf55ec; } .btn-nav{ background-color: black; color: whitesmoke; border: 1px solid whitesmoke; } .btn-nav:hover{ background-color: #bf55ec; } .colorchange{ animation: colorchangecafe 1s infinite; } #p { color:whitesmoke font-size: 120%; word-spacing: 5px; letter-spacing: 3px; margin-bottom: 20px; margin-top: 20px; font-weight: bold; } @keyframes colorchangecafe{ 0%{color: red;} 30%{color: #bf55ec;} 50%{color: royalblue;} 100%{color: #bf55ec;} } .mobile-icon{display: none;} /*///Responsive Queries///*/ @media only screen and (max-width: 1180px){ .main-content-header{ width: 100%; padding: 0 2%; } } @media only screen and (max-width: 998px){ h1{font-size: 200%;} p{font-size: 70%;} } @media only screen and (max-width: 768px){ h1{font-size: 180%;} p{font-size: 70%;} .main-nav{display: none;} .mobile-icon{ display: inline-block; color: #fff; float: right; margin-top: 30px; margin-right: 20px; } .main-nav{float: left;} .main-nav li{ display: block; margin-top: 10px; } } @media only screen and (max-width: 480px){ .btn-full{ margin-bottom: 20px; } h1{font-size: 160%;} p{font-size: 70%;} }
css
{ "id": 17575, "name": "Legs", "incomplete": false, "members": false, "tradeable": false, "tradeable_on_ge": false, "stackable": false, "stacked": null, "noted": false, "noteable": false, "linked_id_item": 4196, "linked_id_noted": null, "linked_id_placeholder": null, "placeholder": true, "equipable": false, "equipable_by_player": false, "equipable_weapon": false, "cost": 1, "lowalch": null, "highalch": null, "weight": 6.35, "buy_limit": null, "quest_item": true, "release_date": "2005-01-31", "duplicate": true, "examine": "A pair of lifeless, rotting legs.", "icon": "<KEY>AAAAABJRU5ErkJggg==", "wiki_name": "Legs", "wiki_url": "https://oldschool.runescape.wiki/w/Legs", "wiki_exchange": null, "equipment": null, "weapon": null }
json
{ "name": "vue-bootstrap-ajax-combobox", "version": "1.0.30", "description": "AJAX Combobox autocomplete component for Vue.js >=2.5.16, Axios >=0.18.0, Font Awesome >=4.7.0, and Bootstrap >=4.3.1", "main": "dist/ajax-combobox.ssr.js", "module": "dist/ajax-combobox.esm.js", "unpkg": "dist/ajax-combobox.min.js", "files": [ "dist/*", "src/**/*.vue" ], "scripts": { "build": "cross-env NODE_ENV=production rollup --config build/rollup.config.js", "build:ssr": "cross-env NODE_ENV=production rollup --config build/rollup.config.js --format cjs", "build:es": "cross-env NODE_ENV=production rollup --config build/rollup.config.js --format es", "build:unpkg": "cross-env NODE_ENV=production rollup --config build/rollup.config.js --format iife" }, "dependencies": { "vue": ">=2.5.16", "axios": ">=0.18.0", "font-awesome": ">=4.7.0", "bootstrap": ">=4.3.1" }, "devDependencies": { "cross-env": "^6.0.3", "minimist": "^1.2.0", "rollup": "^1.26.1", "rollup-plugin-buble": "^0.19.8", "rollup-plugin-commonjs": "^10.1.0", "rollup-plugin-replace": "^2.2.0", "rollup-plugin-terser": "^5.1.2", "rollup-plugin-vue": "5.1.1", "vue": "^2.6.10", "vue-template-compiler": "^2.6.10" } }
json
from django.db.models import Count from django.core.paginator import EmptyPage, PageNotAnInteger from django.core.urlresolvers import reverse from django.conf import settings from django.contrib import messages from django.contrib.auth.decorators import login_required from django.http import Http404 from django.shortcuts import ( redirect, render_to_response, get_list_or_404, get_object_or_404 ) from django.template import RequestContext from django.utils.http import urlquote, urlunquote from core.pagination import Pages from cves.models import Alert from .models import Item, Watch import re PER_PAGE = getattr(settings, 'MAX_PER_PAGE', 100) ALLOWED_CHARS = re.compile( r'[a-zA-Z0-9\-"\'`\|~!@#\$%\^&\'\*\(\)_\[\]{};:,\.<>=\+]+"' ) def get_part(request): part = request.GET.get('part', None) if not part in ('a', 'o', 'h'): part = 'a' return part def get_val(request, val): val = urlunquote(request.GET.get(val, None)) if val is not None: val = re.sub(ALLOWED_CHARS, '', val) return val def index(request, level='part'): part = None if level == 'part': item_list = Item.objects.values('part').order_by('part').annotate( count=Count('vendor')) q_dict = {} next_level = 'vendor' part = None vendor = None elif level == 'vendor': part = get_part(request) item_list = Item.objects.filter(part=part).values( 'vendor').order_by('vendor').annotate(count=Count('product')) q_dict = {'part': part} next_level = 'product' vendor = None elif level == 'product': part = get_part(request) vendor = get_val(request, 'vendor') q_dict = { 'part': part, 'vendor': vendor } if not Item.objects.filter(part=part, vendor=vendor).exists(): raise Http404("No products exist.") item_list = Item.objects.filter( part=part, vendor=vendor).values( 'product').order_by('product').annotate(count=Count('id')) next_level = None paginator = Pages(item_list.all(), PER_PAGE) page = int(request.GET.get('page', 1)) try: objects = paginator.pages.page(page) except PageNotAnInteger: objects = paginator.pages.page(1) except EmptyPage: objects = paginator.pages.page(paginator.pages.num_pages) new_objects = [] for obj in objects: new_objects.append({ 'obj': obj.get(level), 'count': obj.get('count'), 'url': urlquote(obj.get(level), safe=None) }) objects.object_list = new_objects return render_to_response( 'cpes/index.html', RequestContext( request, { 'part': part, 'vendor': vendor, 'objects': objects, 'level': level, 'q_dict': q_dict, 'next_level': next_level, 'pages': paginator.pages_to_show(page) } ) ) def version_index(request): part = get_part(request) vendor = get_val(request, 'vendor') product = get_val(request, 'product') if part is None or vendor is None or product is None: raise Http404('No product found.') objects = get_list_or_404(Item.objects.only( 'part', 'vendor', 'product', 'pk', 'cpe23_wfn' ), part=part, vendor=vendor, product=product) q_dict = { 'part': part, 'vendor': vendor, 'product': product } can_watch = request.user.is_authenticated() has_watch = None if can_watch: has_watch = Watch.objects.filter(**q_dict).filter( users=request.user).exists() return render_to_response( 'cpes/version_index.html', RequestContext( request, { 'part': part, 'vendor': vendor, 'product': product, 'objects': objects, 'q_dict': q_dict, 'can_watch': can_watch, 'has_watch': has_watch } ) ) @login_required def watch_toggle(request): part = get_part(request) vendor = get_val(request, 'vendor') product = get_val(request, 'product') if part is None or vendor is None or product is None: raise Http404('No product found.') w, created = Watch.objects.get_or_create( part=part, vendor=vendor, product=product ) if created: w.users.add(request.user) messages.success(request, 'Watch created') else: if w.users.filter(pk=request.user.pk).exists(): w.users.remove(request.user) messages.warning(request, 'Watch removed') else: w.users.add(request.user) messages.success(request, 'Watch created') return redirect( '{0}?part={1}&vendor={2}&product={3}'.format( reverse('cpes:version_index'), urlquote(part), urlquote(vendor), urlquote(product) ) )
python
Tech billionaires Elon Musk and Mark Zuckerberg may potentially face off against each other in the octagon in an MMA fight. UFC president Dana White confirmed their interest in a matchup and the news has gotten fans stoked. American comedian and social media star Austin Nasso shared a hilarious reenactment of the two billionaires trash-talking each other ahead of their rumored fight. The jokes revolved around data privacy on their respective platforms and likened Zuckerberg's appearance to an alien. Here are key takeaways from Nasso's video: Fans loved the jokes and mentioned their favorite parts in the comments. "Not the user data 🥲😔" "Bro you’re a savage with these videos" "Musk, “built like a 1950’s fridge. ”" ""If I win, I get your user data”. Nothing more true has ever been said 😂" "That tongue flicker killed me 💀" "This news story was made for you 😂" Fans also remarked on the implications of the potential fight. "This is a fine example of a dystopian horror of late capitalism repacked as a wholesome content. " "We live in the strangest timeline" Fans also predicted what the outcome of a match between Elon Musk and Mark Zuckerberg could be. "They’re literally battling autism" "I got my money on Zuckerberg, joos never lose (yes I misspelled that intentionally)" "😂 Elon will fake an illness or emergency and bail last minute" "Wanted to put money on elon but that thing he plans with user data is something I disapprove. " Check out the hilarious responses from fans in the screenshots from Instagram below: UFC legends Jon Jones and Georges St-Pierre have jumped on the tech billionaire matchup bandwagon. UFC heavyweight champion Jones was the first to offer his services as a training partner to Meta CEO Mark Zuckerberg. He wrote on Twitter: "You already know I am Team Zuck…. Let me know if you need a training partner! " Check out his tweet below: UFC Hall of Famer Georges St-Pierre then got behind Twitter owner Elon Musk and called it an honor to help him out in his upcoming challenge agaisnt Zuckerberg. "@elonmusk I'm a huge fan of yours and it would be an absolute honor to help you and be your training partner for the challenge against Zuckerberg" Check out GSP's offer to Elon Musk:
english
<filename>spark/resources/assets/js/settings/security.js module.exports = { props: ['user'], /** * The component's data. */ data() { return { twoFactorResetCode: null }; }, events: { /** * Display the received two-factor authentication code. */ receivedTwoFactorResetCode(code) { this.twoFactorResetCode = code; $('#modal-show-two-factor-reset-code').modal('show'); } } };
javascript
Kathy Griffin is set to explain the reasoning behind her controversial photo shoot with a bloodied mask of President Trump and respond to alleged bullying from the Trump family on Friday. Griffin and attorney Lisa Bloom said in a joint news release they will hold a press conference in Woodland Hills, Calif. 12 p. m. It will be the first comments Griffin has made since she was relieved of her duties as CNN’s New Year’s Eve host. Griffin received major backlash after the photo was published on Tuesday of her holding a bloodied mask that resembled President Trump. She apologized for the photo shoot and YouTube video later, acknowledging she "went too far. " However, by Wednesday morning, her attempt at a joke clearly fell flat among the public. Donald Trump Jr. called for CNN to drop Griffin as a commentator shortly after the image went viral. "Dear CNN, I must have missed your statement banning your commentator #KathyGriffin from future shows. Please resend. Thx," he tweeted. Both the president and first lady also called the photos "disturbing," Trump adding that the photo took a toll on his youngest son, Barron. Griffin has co-hosted CNN’s “New Year’s Eve Live” with Anderson Cooper since 2007. Cooper criticized Griffin's actions as "disgusting. "
english
div1 { position: absolute; text-align: center; font-size: small; color: red; font-family: "Press Start 2P", cursive; } body { background-color: black; } .square { position: absolute; top: 20%; margin: 20px auto; height: 75%; width: 100%; background-color: rgb(61, 61, 61); border: 3px rgb(255, 251, 0) solid; } .githublogo { filter: invert(100%) sepia(100%) saturate(0%) hue-rotate(86deg) brightness(118%) contrast(119%); } strong:hover { color: chartreuse; } .buttoms { display: grid; grid-template-columns: 10% 10%; justify-items: stretch; justify-content: center; }
css
<gh_stars>0 [ { "voce": "Il suo ritrovamento in un cantiere dopo un sonno di 2000 anni fece a suo tempo molto scalpore.", "giochi": [ "diamante" ] }, { "voce": "Può invocare delle nubi cariche di pioggia. Un tempo era venerato come patrono dei buoni raccolti.", "giochi": [ "perla" ] }, { "voce": "Può portare pioggia aprendo portali verso un altro mondo. Si pensava che propiziasse i raccolti.", "giochi": [ "platino", "nero", "bianco" ] }, { "voce": "Anticamente si credeva BRONZONG potesse essere invocato per ottenere pioggia e buoni raccolti.", "giochi": [ "heartgold", "soulsilver", "y", "zaffiro_alpha" ] }, { "voce": "É stato venerato per secoli come Pokémon della pioggia. a volte lo si trova sepolto nel terreno.", "giochi": [ "nero_2", "bianco_2", "x", "rubino_omega" ] } ]
json
<filename>node_modules/.cache/babel-loader/94cbd0b16ba512eacb916ba5c19e0f53.json<gh_stars>0 {"ast":null,"code":"'use strict';\n\nconst toPull = require('stream-to-pull-stream');\n\nconst lsReadableStream = require('./ls-readable-stream');\n\nmodule.exports = send => {\n return (args, opts) => {\n opts = opts || {};\n return toPull.source(lsReadableStream(send)(args, opts));\n };\n};","map":null,"metadata":{},"sourceType":"script"}
json
<gh_stars>1-10 package org.artorg.tools.phantomData.server.model; import java.io.Serializable; import java.util.Date; import java.util.UUID; import javax.persistence.Column; import javax.persistence.Id; import javax.persistence.Inheritance; import javax.persistence.InheritanceType; import javax.persistence.MappedSuperclass; import javax.persistence.OneToOne; import org.artorg.tools.phantomData.server.models.base.person.Person; import org.artorg.tools.phantomData.server.util.EntityUtils; @MappedSuperclass @Inheritance(strategy = InheritanceType.SINGLE_TABLE) public abstract class AbstractPersonifiedEntity<T> implements DbPersistentUUID<T>, Serializable, NameGeneratable { private static final long serialVersionUID = 2549825982365608082L; @Id @Column(name = "ID", nullable = false) private UUID id = UUID.randomUUID(); @OneToOne private Person creator; @OneToOne private Person changer; @Column(name = "DATE_ADDED", nullable = false) private Date dateAdded; @Column(name = "DATE_LAST_MODIFIED", nullable = false) private Date dateLastModified; public AbstractPersonifiedEntity() { this.dateAdded = new Date(); this.dateLastModified = dateAdded; this.creator = null; this.changer = null; } @Override public String toString() { return String.format( "dateLastModified=%s, changer=%s, " + "dateAdded=%s, creator=%s, id=%s", dateLastModified, changer, dateAdded, creator, id); } @Override public int compareTo(T item) { if (item == null) return -1; AbstractPersonifiedEntity<?> that = (AbstractPersonifiedEntity<?>) item; int result; result = dateLastModified.compareTo(that.dateLastModified); if (result != 0) return result; result = changer.compareTo(that.changer); if (result != 0) return result; result = dateAdded.compareTo(that.dateAdded); if (result != 0) return result; result = creator.compareTo(that.creator); if (result != 0) return result; return id.compareTo(that.id); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (!(obj instanceof AbstractPersonifiedEntity)) return false; AbstractPersonifiedEntity<?> other = (AbstractPersonifiedEntity<?>) obj; if (!EntityUtils.equals(changer, other.changer)) return false; if (!EntityUtils.equals(creator, other.creator)) return false; if (!EntityUtils.equals(dateAdded, other.dateAdded)) return false; return EntityUtils.equals(dateLastModified, other.dateLastModified); } // Getters & Setters @Override public UUID getId() { return id; } @Override public void setId(UUID id) { this.id = id; } public Date getDateAdded() { return dateAdded; } public void setDateAdded(Date dateAdded) { this.dateAdded = dateAdded; } public Date getDateLastModified() { return dateLastModified; } public void setDateLastModified(Date dateLastModified) { this.dateLastModified = dateLastModified; } public Person getCreator() { return creator; } public void setCreator(Person creator) { this.creator = creator; } public Person getChanger() { return changer; } public void setChanger(Person changer) { this.changer = changer; } }
java
Dhaka: Bangladesh on Thursday included teenage off-spinner Mehedi Hasan to their one-day international line-up for a three-match series against Sri Lanka, an official said. The 19-year-old was part of the squad that defeated Sri Lanka at the weekend in Colombo to draw the two-Test series 1-1. Mehedi and several other Test specialists have returned home since the historic win, which was Bangladesh's 100th Test since their elevation to full status 17 years ago. Mehedi has played seven Tests since making his debut against England last year but is yet to feature in a limited-over game. Chief selector Minhajul Abedin said team management felt an off-spinner would work against Sri Lanka's left-handed batsmen in the ODI series opener in Dambula on Saturday. "The composition of the Sri Lanka team suggested that we would need an extra off-spinner in the series," he told AFP. Mehedi will join the 16-man Bangladesh squad already in Sri Lanka. The three-match ODI series will be followed by two Twenty20 internationals next month. Squad: Mashrafe Mortaza (Capt), Tamim Iqbal, Soumya Sarkar, Imrul Kayes, Mushfiqur Rahim, Shakib Al Hasan, Sabbir Rahman, Mahmudullah Riyad, Mosaddek Hossain, Mustafizur Rahman, Rubel Hossain, Taskin Ahmed, Subashis Roy, Sanjamul Islam, Shuvagata Hom, Nurul Hasan and Mehedi Hasan. (This story has not been edited by News18 staff and is published from a syndicated news agency feed - AFP)
english
11 0ct,Rajkot: Yuvraj Singh made a fantastic comeback to the national side as he blasted his way to a 35-ball 77 to power India to a comfortable four-wicket win over Australia in the high-scoring one-off Twenty20 International, here on Thursday. Yuvraj forged an unbeaten 102-run stand with skipper Mahendra Singh Dhoni, who played a second-fiddle, as India chased down a huge 202-run target with two balls to spare. Yuvraj carried his sublime form, with which he forced his way into the team, into the game as he plundered eight fours and five sixes in his 35-ball knock. The left-hander whacked the bowlers all around the park as his trademark powerful flicks, ferocious cuts and elegantly lofted drives enthralled the packed house even as the Australians watched helplessly. Batting like a man-possessed, Yuvraj reached his 50 with a straight six off paceman James Faulkner while Dhoni (24 off 21) finished the match with a four and couple of runs off Shane Watson. Aaron Finch had powered Australia to a challenging 201 for seven with his blistering 89-run knock off 52-ball as visiting batsmen made merry on a flat wicket after being invited to bat at SCA stadium. Finch plundered 15 boundaries, including a six, as he anchored the Australian innings while debutant Nic Maddinson (34) and Glenn Maxwell (27) also played more than handful knocks for their side. Had it not been for some exceptional bowling by pace duo of R Vinay Kumar (3/26) and Bhuvaneshwar Kumar (3/25), who shared six wickets between them, India would have been in more deep trouble. An off-colour R Ashwin and Ishant Sharma bled 93 runs in six wicket-less overs between them and that cost India dearly. However, the wicket had nothing for the bowlers even as they bowled poorly. However, India batsmen made up for the poor first half with some excellent batting even though the start was not that good as Rohit Sharma (8) exited early and Suresh Raina (19) could not build on to a good start. Since Shikhar Dhawan (32) and Virat Kohli (29) were striking the ball cleanly, India maintained a healthy run-rate but not keeping wickets did cause some anxiety. Dhawan was stumped off Xaviwer Doherty while Kohli was caught off Clint McKay even as India reached 100 in 11 overs. Dhoni and Yuvraj then turned it on with their scintillating batting. Yuvraj hit two sixes and a four in three balls off McKay to plunder 18 runs in the 14th over. India needed 69 runs from the last six overs but with Yuvraj in scintillating form, the hosts recorded a comfortable win. Earlier, Finch provided a blazing start to his side with debutant Nic Maddinson as Australia raced to 50 in just 4. 1 overs. Maddinson showed no signs of nerves as he punished the bowlers to make a 16-ball 34. The 21-year old left-hander forged a 56-run opening stand with Finch before being castled by seamer Bhuvneshwar. Vinay Kumar picked up two crucial wickets of all-rounder Shane Watson (6) and Aussie skipper George Bailey (0) to bring some relief for the hosts. The visitors came back strongly as Glenn Maxwell blazed through the opposition attack and made 27 off just 13 balls. The 24-year old played a blinder as he struck four sixes in his fluent knock, including three in the same over against Ravichandran Ashwin. Finch was dismissed in the 17th over when Vinay held on to a powerful strike in his follow through. James Faulkner struck a last-ball six to guide his team to a go past the 200-run mark figure. Left-arm spinner Ravindra Jadeja, playing his first T20 at home, played a crucial part in the hosts` recovery as he gave away just 23 runs in his four overs and also got a wicket.
english
from ..utils import AnalysisException from .expressions import Expression class Literal(Expression): def __init__(self, value): super().__init__() self.value = value def eval(self, row, schema): return self.value def __str__(self): if self.value is True: return "true" if self.value is False: return "false" if self.value is None: return "NULL" return str(self.value) def get_literal_value(self): if hasattr(self.value, "expr") or isinstance(self.value, Expression): raise AnalysisException("Value should not be a Column or an Expression," f" but got {type(self)}: {self}") return self.value def args(self): return (self.value, ) __all__ = ["Literal"]
python
Chennai made five changes from the 3-1 loss to Delhi Dynamos. Duwayne Kerr was replaced by young Karanjit Singh in goal, while Sabia was brought in for Mendy in central defence. Left back also saw a change with Nallappan Mohanraj making way for Jerry Lalrinzuala. Chennai also modified their formation from a 4-4-2 to a loose 4-3-3, with Blasi joining Mulder and Raphael Augusto in central midfield. Up front, Succi started in place of Dudu Omagbeni. Goa persisted with their core and made only one change from the weekend loss to FC Pune City. Wide midfielder Mandar Rao Dessai replaced by central midfielder Sahil Tavora, with a slight modification in their shape. Chennai broadened their field of play by utilizing the central as well as the wide areas of the pitch. Blasi sat a little deeper than fellow central midfielders Raphael Augusto and Hans Mulder, and they worked well with Riise and co. In defense. Mulder, especially, in the first half, made influential runs and passes in the midfield and attacking third of the pitch, and was rewarded early in the game with a goal. He received the ball just outside the penalty box, and angled the ball into the net perfectly past the outstretched hands of Kattimani, to give Chennai the lead. Chennai also employed the wide areas through Wadoo and Jerry. Wadoo was captain on the night, and celebrated the honour by getting on the scoresheet himself. He attacked well, making well-timed runs on the right and delivering dangerous passes and crosses into the box. For the second goal, he had the ball inside the box and went for goal. The ball caught a deflection from a Goa defender on the way but nevertheless flew into the back of the net. Chennai defended strongly, with Raphael Augusto and Mulder regularly tracking back to help out their defence. Especially in the second half when Goa went into a higher gear, their presence paid dividends. The full backs also had a tiring game, having to run up and down the sides for attacks and defending respectively. With Goa executing wave after wave of attack, Chennai sat back and patiently waited for counter attack opportunities to hit Goa, but could not score more than the two goals in the first half. Build up play and general set up – Goa: With Zico preferring a defensive formation for away games, this one at Chennai was not different. Goa lined up with one defensive midfielder in Sanjay Balmuchu, two central midfielders Sahil Tavora and Trindade Goncalves and attacking midfielder Joffre. Balmuchu played very deep in his own half, almost forming a straight line with his full backs. He was defensively solid along with Rafael Dumas, and they were instrumental in restricting Chennai’s attackers to the two goals. Ahead of him, Sahil Tavora was tasked with dropping into his own half to collect the ball, and Trindade Goncalves was given the responsibility of being a mobile midfielder with stamina, capable of constantly being on the move. Joffre was as usual the playmaker, trying to set up forwards Reinaldo and Rafael Coelho. Goa’s attacking tactics: Sahil Tavora regularly tracked back to receive the ball from the centre backs and Sanjay Balmuchu. Unlike Chennai’s full backs, Goa’s right back and left back did not attack too much, and most of the offensive build up was carried out through Sahil Tavora and Joffre in the middle. At times, it could be seen the Rafael Coelho shifted into the left wing position, contributing to the build up play. This left Reinaldo up front, who tried to find free spaces in the attacking third. As has been typical of Goa’s campaign so far, many chances were created but most attacks lacked end product. Even after the introduction of Richarlyson, Romeo and Julio Cesar brought in a good tempo but couldn’t result in Goal. Goa’s defensive performance: Another trend that has repeated itself in Goa’s ISL 2016 season is that they concede early goals. It has happened in all three games so far. However, after the first thirty minutes, Balmuchu and Dumas were strong in the air and the ground, and did not let Chennai get many more chances on goal. The full backs were disciplined and kept their positions, but the two early goals conceded meant FC Goa fell to another defeat.
english
Mumbai: A heart transplant in time saved the life of a 62-year-old man in Mumbai today who had been on the recipient waiting list for over a month. The donor, a 50-year-old woman, was declared brain dead after an injury, and her family agreed to the transplant. The 50-year-old woman was declared brain dead at M. G. M. Hospital in Navi Mumbai after a collapse at her home which resulted in Subdural Acute Haemorrhage. After the woman's family agreed to donate her heart and liver, the Fortis Hospital arranged for the transfer of the heart from Vashi to Mulund, a distance of 18 km that was covered in just 16 minutes. The harvested heart was taken from Navi Mumbai around 12. 20 a. m. and travelled via Thane-Belapur-Airoli to reach Fortis Hospital in Mulund at 12. 36 a. m. -- in 16 minutes flat, said Anvay Mulay, head of the cardiac transplant team. The heart transplant was successfully done and the patient has now been shifted to the ICCU and shall be under observation for the next 2-3 days, Mr Mulay added. The man had been suffering from Dilated Cardiomyopathy. Fortis Hospital zonal director S Narayani said now people in Maharashtra can have hope and need not go out of the state as they can avail the best treatment locally. "Despite all successful surgeries that build awareness levels about organ donations, patients are still lost due to unavailability of hearts. We have a long way to go before the state becomes the transplant capital of the country," Mr Narayani said. This was the second heart transplant carried out by Fortis Hospital in Mulund within two days and the 15th since August, a spokesperson said. Last week, the hospital carried out an inter-state transplant by flying down the heart of a teenager from Surat, Gujarat, in 75 minutes. It was transplanted in a 43-year-old man from Rajasthan.
english
import sys, signal def signal_handler(signal, frame): print("\nprogram exiting gracefully") sys.exit(0) signal.signal(signal.SIGINT, signal_handler) ####################### Listen ################################# import speech_recognition as sr import wave def listen_to_me(threshold=3000): # used speech_recognition to control audio input # Github: https://github.com/Uberi/speech_recognition/blob/master/speech_recognition/__init__.py # Documentation: https://pypi.org/project/SpeechRecognition/1.2.3/ url,x_header = xunfei_preparation() r = sr.Recognizer() r.energy_threshold = threshold # threshold for background noise # r.pause_threshold = 0.8 # minimum length of silence (in seconds) that will register as the end of a phrase. while True: with sr.Microphone() as source: print("I am listening....") # r.listen start recording when there is audio input higher than threshold (set this to a reasonable number), # and stops recording when silence >0.8s(changable) audio = r.listen(source) # get wav data from AudioData object wav = audio.get_wav_data(convert_rate = 16000,convert_width=2) # width=2 gives 16bit audio. print('Got it. Recognizing....') try: # print("You said :\n" + r.recognize_google(audio)) word = xunfei_recognition(wav,url,x_header) print(word) except sr.UnknownValueError: print("Could not understand audio\nTurning on Silence Mode...") except sr.RequestError as e: print("Could not request results; {0}".format(e)) ########################### Recognition ###################################### import urllib.parse, urllib.request import time import json import hashlib import base64 def xunfei_preparation(): url = 'https://api.xfyun.cn/v1/service/v1/iat' api_key = '<KEY>' # api key在这里 x_appid = '5b6e5b3e' # appid在这里 param = {"engine_type": "sms16k", "aue": "raw"} x_time = int(int(round(time.time() * 1000)) / 1000) x_param = base64.b64encode(json.dumps(param).replace(' ', '').encode('utf-8')) x_checksum_content = api_key + str(x_time) + str(x_param, 'utf-8') x_checksum = hashlib.md5(x_checksum_content.encode('utf-8')).hexdigest() x_header = {'X-Appid': x_appid, 'X-CurTime': x_time, 'X-Param': x_param, 'X-CheckSum': x_checksum} return url,x_header def xunfei_recognition(audio,url,headers): base64_audio = base64.b64encode(audio) body = urllib.parse.urlencode({'audio': base64_audio}) req = urllib.request.Request(url=url, data=body.encode('utf-8'), headers=headers, method='POST') result = urllib.request.urlopen(req) result = result.read().decode('utf-8') result = json.loads(result) print(result) return (result['data']) listen_to_me()
python
<filename>client/src/containers/Stats/ResultsTable.tsx import { Paper, Table, TableBody, TableCell, TableHead, TableRow } from '@material-ui/core'; import { makeStyles } from '@material-ui/core/styles'; import clsx from 'clsx'; import { StatsErrorCard } from 'components/ErrorCards'; import TableSkeleton from 'components/Skeletons/TableSkeleton'; import React from 'react'; import type { IStatsStore } from 'types/store'; const useStyles = makeStyles((theme) => ({ table: { background: theme.palette.background.nested, }, skeleton: {}, container: { overflowX: 'auto', }, sticky: { position: 'sticky', left: 0, zIndex: 11, backgroundColor: theme.palette.background.nested, }, header: { fontWeight: theme.typography.fontWeightBold, }, cell: { background: theme.palette.background.nested, }, error: { width: 'auto', height: theme.spacing(30), }, })); interface IResultsTableProps { stats: IStatsStore; unitNames: string[]; className?: string; } const ResultsTable: React.FC<IResultsTableProps> = ({ stats, unitNames, className }) => { const classes = useStyles(); if (stats.error) { return <StatsErrorCard className={classes.error} />; } if (!stats?.payload?.length) { return ( <TableSkeleton dense rows={6} cols={unitNames && unitNames.length ? unitNames.length + 1 : 2} className={classes.skeleton} /> ); } return ( <Paper className={classes.container}> <Table size="small" className={clsx(classes.table, className)}> <TableHead> <TableRow className={classes.header}> <TableCell className={clsx(classes.sticky, classes.header)}>Save</TableCell> {unitNames.map((name) => ( <TableCell align="right" key={name} className={classes.header}> {name} </TableCell> ))} </TableRow> </TableHead> <TableBody> {stats.payload.map((result) => { const { save, ...unitResults } = result; return ( // eslint-disable-next-line react/no-array-index-key <TableRow key={save}> <TableCell className={clsx(classes.sticky, classes.cell)}> {save && save !== 0 ? `${save}+` : '-'} </TableCell> {unitNames.map((name) => ( <TableCell key={name} align="right"> {unitResults[name]} </TableCell> ))} </TableRow> ); })} </TableBody> </Table> </Paper> ); }; export default ResultsTable;
typescript
# -*- coding: utf-8 -*- def convert_decimal_to_n_ary_number(n: int, m_ary_number: int = 2) -> int: '''Represents conversion from decimal number to n-ary number. Args: n: Input number (greater than 1). m_ary_number: m-ary number (from 2 to 10). Returns: values of m-ary number. Landau notation: O(log n) ''' if n < m_ary_number: return n ans = '' while n >= m_ary_number: p, q = divmod(n, m_ary_number) n = p ans += str(q) if n < m_ary_number: ans += str(p) return int(ans[::-1]) def main(): import sys input = sys.stdin.readline n, k = map(int, input().split()) for i in range(k): m = list(str(n))[::-1] tmp = 0 for i in range(len(m)): tmp += 8 ** i * int(m[i]) # 10進数に変換 o = convert_decimal_to_n_ary_number(tmp, 9) # 9進数に変換 n = int(''.join(map(str, str(o).replace('8', '5')))) # 8→5に置き換え print(n) if __name__ == "__main__": main()
python
package com.ichmed.trinketeers.entity.pickup; import org.lwjgl.util.vector.Vector4f; import com.ichmed.trinketeers.entity.Player; import com.ichmed.trinketeers.util.render.light.ILight; import com.ichmed.trinketeers.util.render.light.SimpleLight; import com.ichmed.trinketeers.world.World; public class ManaBottle extends Pickup { public ManaBottle(World w, float min, float max) { super(w); this.entityType = "healthBottle"; this.mana = min + (float) Math.random() * (max - min); this.size.x = this.size.y = (float) (Math.sqrt(this.mana)) / 100f; this.movementDelay = 15; } public ManaBottle(World w) { this(w, 15, 30); } public float mana = 1; @Override public boolean pickUp(World w, Player p) { if (p.mana < p.maxMana) { p.mana += Math.min(this.mana, p.maxMana - p.mana); return true; } return false; } public ILight createLight() { SimpleLight l = new SimpleLight(); l.setColor(new Vector4f(1.4f, 1.4f, 6f, 1)); return l; } @Override public boolean movesTowardPlayer() { return false; } }
java
{"data":{"site":{"siteMetadata":{"title":"Kelly's Personal Portfolio","description":"All the world is a laboratory to the inquiring mind.","author":"@kellyx"}}}}
json
<filename>Universe/styles.css html { background-image: url('galaxy.jpg'); background-repeat: no-repeat; background-size: cover; top: 0; bottom: 0; right:0; left: 0; } h1{ color:yellow; text-align: center; font-size: 4em; } .parent{ font-size:25px; padding: 20px; background-color: black; background-repeat: no-repeat; opacity: 60%; color:white; text-align: center; text-size-adjust: 90px; margin-bottom:110px ; } #hello{ float:left; width:48%; padding:3px; } p{ opacity:100%; } #fixed{ position:fixed; bottom: 0px; right:0; height:260px; width: 70%; opacity:100%; } section{ clear:both; } .earth{ opacity:100% } @media(min-width: 400px) and (max-width: 700px){ h1{ color:yellow; text-align: center; font-size: 4em; } .parent{ font-size:20px; padding: 5%; background-color: black; background-repeat: no-repeat; min-width:90%; color:white; text-align: center; text-size-adjust: 90px; margin-bottom:50px ; } #hello{ width:95%; padding:3px; } p{ opacity:100%; } #fixed{ position:fixed; bottom: 0px; right:0; opacity:100%; height:30%; width: 70%; } section{ clear:both; } } @media(max-width:399px) and (min-width:300px){ h1{ color:yellow; text-align: center; font-size: 3em; } .parent{ font-size:20px; background-color: black; background-repeat: no-repeat; opacity: 60%; color:white; text-align: center; text-size-adjust: 90px; margin-bottom:20%; max-width: 95%; } #hello{ width:95%; } p{ opacity:100%; } div,img{ max-width:95%; } #fixed{ position:fixed; bottom: 0px; right:0; height:30%; width: 70%; opacity:100%; } section{ clear:both; } .earth{ opacity:100% } } @media (max-width:299.9px){ h1{ color:yellow; text-align: center; font-size: 3em; } .parent{ background-color: black; background-repeat: no-repeat; opacity: 60%; color:white; text-align: center; text-size-adjust: 90px; margin-bottom:20%; max-width: 95%; } #hello{ width:95%; } p{ opacity:100%; } div,img{ max-width:95%; } #fixed{ position:fixed; bottom: 0px; right:0; height:30%; width: 70%; opacity:0%; } section{ clear:both; } .earth{ opacity:100% } }
css
package com.example.espritindoor.ViewModel; import android.content.Intent; import android.graphics.Bitmap; import android.graphics.BitmapFactory; import android.os.Bundle; import android.util.Base64; import android.widget.EditText; import android.widget.ImageView; import android.widget.Toast; import androidx.annotation.Nullable; import androidx.appcompat.app.AppCompatActivity; import androidx.recyclerview.widget.LinearLayoutManager; import androidx.recyclerview.widget.RecyclerView; import com.example.espritindoor.Adapters.MessageAdapter; import com.example.espritindoor.R; import org.json.JSONException; import org.json.JSONObject; import java.io.ByteArrayOutputStream; import java.io.FileNotFoundException; import java.io.InputStream; import okhttp3.OkHttpClient; import okhttp3.Request; import okhttp3.Response; import okhttp3.WebSocket; import okhttp3.WebSocketListener; public class Chat extends AppCompatActivity { private String name; private WebSocket webSocket; private String SERVER_PATH = "http://192.168.1.20:3100"; private EditText messageEdit; private ImageView sendBtn, pickImgBtn; private RecyclerView recyclerView; private int IMAGE_REQUEST_ID = 1; private MessageAdapter messageAdapter; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_chat); name = "ali"; //= getIntent().getStringExtra("name"); initiateSocketConnection(); } private void initiateSocketConnection() { OkHttpClient client = new OkHttpClient(); Request request = new Request.Builder().url(SERVER_PATH).build(); webSocket = client.newWebSocket(request, new SocketListener()); } private class SocketListener extends WebSocketListener { @Override public void onOpen(WebSocket webSocket, Response response) { super.onOpen(webSocket, response); runOnUiThread(() -> { Toast.makeText(Chat.this, "Socket Connection Successful!", Toast.LENGTH_SHORT).show(); initializeView(); }); } @Override public void onMessage(WebSocket webSocket, String text) { super.onMessage(webSocket, text); runOnUiThread(() -> { try { JSONObject jsonObject = new JSONObject(text); jsonObject.put("isSent", false); messageAdapter.addItem(jsonObject); recyclerView.smoothScrollToPosition(messageAdapter.getItemCount() - 1); } catch (JSONException e) { e.printStackTrace(); } }); } } private void initializeView() { messageEdit = findViewById(R.id.messageEdit); sendBtn = findViewById(R.id.sendBtn); pickImgBtn = findViewById(R.id.pickImgBtn); recyclerView = findViewById(R.id.recyclerView); messageAdapter = new MessageAdapter(getLayoutInflater()); recyclerView.setAdapter(messageAdapter); recyclerView.setLayoutManager(new LinearLayoutManager(this)); sendBtn.setOnClickListener(v -> { JSONObject jsonObject = new JSONObject(); try { jsonObject.put("name", name); jsonObject.put("message", messageEdit.getText().toString()); webSocket.send(jsonObject.toString()); jsonObject.put("isSent", true); messageAdapter.addItem(jsonObject); recyclerView.smoothScrollToPosition(messageAdapter.getItemCount() - 1); } catch (JSONException e) { e.printStackTrace(); } }); pickImgBtn.setOnClickListener(v -> { Intent intent = new Intent(Intent.ACTION_GET_CONTENT); intent.setType("image/*"); startActivityForResult(Intent.createChooser(intent, "Pick image"), IMAGE_REQUEST_ID); }); } @Override protected void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) { super.onActivityResult(requestCode, resultCode, data); if (requestCode == IMAGE_REQUEST_ID && resultCode == RESULT_OK) { try { InputStream is = getContentResolver().openInputStream(data.getData()); Bitmap image = BitmapFactory.decodeStream(is); sendImage(image); } catch (FileNotFoundException e) { e.printStackTrace(); } } } private void sendImage(Bitmap image) { ByteArrayOutputStream outputStream = new ByteArrayOutputStream(); image.compress(Bitmap.CompressFormat.JPEG, 50, outputStream); String base64String = Base64.encodeToString(outputStream.toByteArray(), Base64.DEFAULT); JSONObject jsonObject = new JSONObject(); try { jsonObject.put("name", name); jsonObject.put("image", base64String); webSocket.send(jsonObject.toString()); jsonObject.put("isSent", true); messageAdapter.addItem(jsonObject); recyclerView.smoothScrollToPosition(messageAdapter.getItemCount() - 1); } catch (JSONException e) { e.printStackTrace(); } } }
java
Indian Premier League (IPL) team and Champions League Twenty20 (CLT20) defending champions Mumbai Indians will get a direct entry into the Champions League Twenty20 2012 Championship. On account of being the defending champions, they won’t have to play the qualification matches. The other Indian teams who will be playing in the Champions League 2012 include Kolkata Knight Riders, Chennai Super Kings and Delhi Daredevils. Last year, top three teams from IPL had got a direct entry into the tournament while the fourth team had to play the qualification matches. This year the winning teams from England and Pakistan might have to play the qualifying matches in order to play the tournament. “A discussion to this effect has taken place, now it’s up to the council to take the final call,” The Times of India quoted a source. Governing Council of Champions League T20 will meet in Kuala Lumpur on Monday to discuss on the issue of who will be hosting the tournament. South Africa is expected to inform the council on whether or not they are ready to host the Champions League. Earlier, India were supposed to host the event. However, the Indian board offered to shift the event to South Africa due to monsoon and Durga Puja. It was also learnt that the official broadcaster will discuss the cost involving the qualifying matches and logistic costs of the entire tournament. “During the IPL final, South Africa was keen when they were offered to host the league. In all probability, they are ready to host the event,” a source was quoted as saying. The council is also going discuss the budget of the league and the cost involved in hosting the event in India.
english
<filename>rename_test.go package cheapcash_test import ( "errors" "math/rand" "strconv" "sync" "testing" "github.com/aldy505/cheapcash" ) func TestRename(t *testing.T) { randomValue := strconv.Itoa(rand.Int()) randomValue2 := strconv.Itoa(rand.Int()) c := cheapcash.Default() err := c.Write(randomValue, []byte("Another random value")) if err != nil { t.Error("an error was thrown:", err) } err = c.Rename(randomValue, randomValue2) if err != nil { t.Error("an error was thrown:", err) } v, err := c.Read(randomValue2) if err != nil { t.Error("an error was thrown:", err) } if string(v) != "Another random value" { t.Errorf("expected %s, got %v", "Another random value", string(v)) } _, err = c.Read(randomValue) if err != nil && !errors.Is(err, cheapcash.ErrNotExists) { t.Error("expected ErrNotExists, got:", err.Error()) } } func TestRename_Concurrency(t *testing.T) { randomValue := strconv.Itoa(rand.Int()) randomValue2 := strconv.Itoa(rand.Int()) c := cheapcash.Default() err := c.Write(randomValue, []byte("Another random value")) if err != nil { t.Error("an error was thrown:", err) } var wg sync.WaitGroup renameFunc := func() { err = c.Rename(randomValue, randomValue2) if err != nil && !errors.Is(err, cheapcash.ErrNotExists) { t.Error("an error was thrown", err) } wg.Done() } wg.Add(5) go renameFunc() go renameFunc() go renameFunc() go renameFunc() go renameFunc() wg.Wait() } func TestRename_OldNotExists(t *testing.T) { randomValue := strconv.Itoa(rand.Int()) c := cheapcash.Default() err := c.Rename(randomValue, "test") if !errors.Is(err, cheapcash.ErrNotExists) { t.Error("expected ErrNotExists, got:", err) } } func TestRename_NewExists(t *testing.T) { randomValue := strconv.Itoa(rand.Int()) randomValue2 := strconv.Itoa(rand.Int()) c := cheapcash.Default() err := c.Write(randomValue, []byte("value")) if err != nil { t.Error("an error was thrown:", err) } err = c.Write(randomValue2, []byte("value")) if err != nil { t.Error("an error was thrown:", err) } err = c.Rename(randomValue, randomValue2) if !errors.Is(err, cheapcash.ErrExists) { t.Error("expected ErrExists, got:", err) } }
go
Back in 2019 when casinos were being raided, it was hinted from government’s top level that no one associated with this will be spared. Some were suspended from the party also. All the bigwigs of the ruling party, involved in the casino episode, were arrested and sent behind bars. It was said then, this raid will continue outside of Dhaka as well. Everyone would be brought to book in phases. But after a gap of four years it seems all of it was just a sham. According to Prothom Alo news, the trial of none of the 57 cases lodged against 13 people including expelled Jubo League leader Ismail Hossain alias Shamrat and Khaled Mahmud Bhuiyan has been completed. Investigation reports have been submitted in 52 cases. List of the five cases, which have not been investigated even after four years, includes a money laundering case against Samrat and Khaled each along with multiple cases of unknown income sources against expelled Awami League leader Enamul Haque alias Enu and Rupon Bhuiyan. Police’s Criminal Investigation Department (CID) is provided with investigating the money laundering cases filed against Samrat and Khaled. Investigating officers have said that information of Samrat siphoning off Tk 1. 95 billion (195 crore) to Singapore and Malaysia has been found. He has spent a major portion of the money, laundered away through Hundi, in the casino. In between 27 December 2011 and 9 August 2019, Samrat had been to Singapore 35 times. Investigating officers claim that they are unable to submit the probe report for not receiving any answers from Singapore and Malaysia, despite sending letters there regarding the laundered money. Case investigation cannot remain suspended on the excuse of not having information of laundered money from respective countries. As much time goes by, the chances of getting information will grow thinner. Investigating officers could have submitted an investigation report based on the money-laundering information they have already received, as per their claims. They, however, didn’t do that. In consequence, this idea that no matter how big an offence is committed by party members they won’t be prosecuted has been rooted deeply in the public mind. Transparency International Bangladesh (TIB) executive director Iftekharuzzaman has said that in the name of delay in receiving information from abroad these criminals with links to the ruling party are being shielded. In the same way, they are being reinstated in the party as well. This procedure of reinstating accused persons has been going on elsewhere also. Jubo League leader AKM Mominul Haque, whose name had come up in the casino incident, has returned from abroad recently after remaining in hiding for three and a half years. Then the responsibility of Bangladesh Hockey Federation general secretary have been re-entrusted with him. Just like that, all the Awami League, Jubo League and allied organisation leaders who had been banished from the party for being involved in the casino scandal and other criminalities, are also being reinstated one by one. Four years isn’t a short period for prosecuting or settling a criminal case. Police have arrested the accused after finding information about them of being involved in the crime during primary investigation. If these cases are not tried or the investigations aren't completed even after that, it will send a wrong message to the public indeed. They will think, opposition leaders-activists can be framed in fabricated cases while ruling party leaders-activists can get away with major crimes.
english
<reponame>Ryebread4/Rustionary<filename>en/asper.json {"word":"asper","definition":"Rough; rugged; harsh; bitter; stern; fierce. [Archaic] \"An asper sound.\" Bacon.\n\nThe rough breathing; a mark placed over an initial vowel sound or over h before it; thus hws, pronounced h, hrj'twr, pronounced hra\\'b6t.\n\nA Turkish money of account (formerly a coin), of little value; the 120th part of a piaster."}
json
<reponame>quinn-dougherty/python-on-nix<filename>projects/pyvisa/meta.json<gh_stars>10-100 { "desc": "Python VISA bindings for GPIB, RS232, TCPIP and USB instruments", "home": "https://github.com/pyvisa/pyvisa", "license": "MIT License" }
json
/* eslint-disable complexity */ import React from 'react' import {getGames} from '../store/reducers/user' import {connect} from 'react-redux' import {Link} from 'react-router-dom' import { TableContainer, Table, TableHead, TableBody, TableRow, TableCell } from '@material-ui/core' import Paper from '@material-ui/core/Paper' import {MyButton as Button} from './Button' const mapGames = (games, username) => { return games.map(game => { const amP1 = game.p1 === username const result = (amP1 && game.game.player1.settlers > game.game.player2.settlers) || (!amP1 && game.game.player1.settlers < game.game.player2.settlers) ? 'W' : 'L' return [ <TableRow key={game._id} hover> <TableCell align="center">{result}</TableCell> <TableCell align="center">{amP1 ? game.p2 : game.p1}</TableCell> <TableCell align="center"> {amP1 ? game.game.player1.settlers : game.game.player2.settlers} </TableCell> <TableCell align="center"> {amP1 ? game.game.player2.settlers : game.game.player1.settlers} </TableCell> </TableRow>, result ] }) } class History extends React.Component { componentDidMount() { this.props.getGames() } render() { const games = mapGames(this.props.games, this.props.userName) const totalWins = games.reduce((acc, curr) => { acc += curr[1] === 'W' ? 1 : 0 return acc }, 0) return ( <div className="history"> <div style={{width: '25%'}}> <Link to="/home"> <Button text="Home" color="default" icon="home" /> </Link> </div> <h1 className="history-text">total wins: {totalWins}</h1> {this.props.games.length === 0 ? ( <h1 className="history-text"> Play your first game to see your stats! </h1> ) : ( <TableContainer component={Paper}> <Table stickyHeader> <TableHead> <TableRow> <TableCell align="center">W/L</TableCell> <TableCell align="center">Opponent</TableCell> <TableCell align="center">Your Settlers</TableCell> <TableCell align="center">Opponent's Settlers</TableCell> </TableRow> </TableHead> <TableBody>{games.map(game => game[0])}</TableBody> </Table> </TableContainer> )} </div> ) } } const mapState = state => ({ games: state.user.history, userName: state.user.userName }) const mapDispatch = dispatch => ({ getGames: () => dispatch(getGames()) }) export default connect(mapState, mapDispatch)(History)
javascript
- Although Congress emerged as the state's single largest party in the last Assembly election with 28 seats, the BJP managed to cobble together an alliance that included the NPP, NPF and Lok Janshakti Party (LJP) Ahead of the state's Assembly elections expected to take place in the early months of 2022, Prime Minister Narendra Modi has travelled to Manipur's Imphal where he will spend the day inaugurating 13 development projects valued at over Rs 1,850 crore while laying the foundation stones of nine other projects worth Rs 2,950 crore. The projects cover varying sectors including road infrastructure, health, housing, urban development, drinking water, information technology, art and culture and skill development. In keeping with the saffron party's push to boost connectivity, PM Modi will lay the foundation stones for five national highway projects to be constructed at a cost of 1,700 crore, stretching over 110 km. A steel bridge over the Barak river on NH-37 to be built at a cost of Rs 75 crore will also be inaugurated by the prime minister in a bid to improve connectivity between Imphal and Silchar. The prime minister will also dedicate 2,387 mobile towers, valued at Rs 1,100 crores, to the constituents of Manipur. Additionally, PM Modi will inaugurate the Rs 280 crore 'Water Transmission System of Thoubal Multi-purpose project' that aims to provide clean drinking water to the people of Imphal. This will accompany other similar projects like the 'Augmentation of Senapati district headquarter water supply scheme' built at a cost of Rs 51 crore and the 'Water Supply Scheme project' managed by the Water Conservation for Tamenglong Headquarters valued at Rs 65 crore. The prime minister will also lay the foundation stone of a 'state of the art cancer hospital' worth roughly Rs 160 crore in Imphal. To buttress COVID-19-related infrastructure in the state, PM Modi will launch a '200-bedded COVID hospital' at Kiyamgei valued at Rs 37 crore, in collaboration with the Defence Research and Development Organisation. He will also inaugurate three projects under the Imphal Smart City Mission and lay the foundation stone of the Centre for Invention, Innovation, Incubation and Training (CIIT) in Manipur, expected to cost the exchequer roughly Rs 200 crore. The electoral battle in the state of Manipur has, in recent weeks, assumed greater prominence given the revival of the debate around the controversial Armed Forces (Special Powers) Act that provides the armed forces with extraordinary powers to use aggression and arrest citizens in notified areas. Following a botched military operation that led to several civilian killings in Nagaland, groups from various Northeast states including Manipur have called for a revocation of the Act. The saffron party will be looking to retain power in the state after it managed to oust Congress in 2017 after fifteen years. The BJP is viewing its latest infrastructure and development push as key to achieving this. Having been in power for fifteen years, Congress ceded control of the state to a coalition led by the BJP in 2017. Although Congress emerged as the state's single largest party in the last Assembly election with 28 seats, the BJP managed to cobble together an alliance that included the NPP, NPF and Lok Janshakti Party (LJP). Since then, Congress has suffered from a spate of MLA defections including that of former state party chief Govindas Konthoujam in August this year. But it hasn't been clear skies for the BJP either with the Conrad Sangma-led NPP announcing intentions to contest independently across 40 seats this year. The rift between the BJP and NPP emerged following the removal of two of the four NPP ministers from the state Cabinet. Like Congress, the NPP has also demanded the repeal of the AFSPA.
english
<filename>calims2-taglib/src/java/gov/nih/nci/calims2/taglib/TagHelper.java /*L * Copyright Moxie Informatics. * * Distributed under the OSI-approved BSD 3-Clause License. * See http://ncip.github.com/calims/LICENSE.txt for details. */ /** * */ package gov.nih.nci.calims2.taglib; import java.io.IOException; import javax.servlet.jsp.JspException; import javax.servlet.jsp.PageContext; import org.springframework.web.servlet.support.JspAwareRequestContext; import org.springframework.web.servlet.support.RequestContext; import org.springframework.web.servlet.tags.RequestContextAwareTag; import gov.nih.nci.calims2.uic.html.Tag; import gov.nih.nci.calims2.uic.html.TagRenderer; /** * Helper class used for common tasks in custom tags. * * @author viseem * */ public class TagHelper { /** * RequestContext resolution method for all related tags. * @param context The page context of the page. * * @return The current RequestContext; */ public static RequestContext getRequestContext(PageContext context) { RequestContext requestContext = (RequestContext) context.getAttribute(RequestContextAwareTag.REQUEST_CONTEXT_PAGE_ATTRIBUTE); if (requestContext == null) { requestContext = new JspAwareRequestContext(context); context.setAttribute(RequestContextAwareTag.REQUEST_CONTEXT_PAGE_ATTRIBUTE, requestContext); } return requestContext; } /** * Output the given tag. * @param context The page context of the page. * @param tag The tag to output * @param pretty True for pretty rendering. * @throws JspException If an IO error occurs. */ public static void outputTag(PageContext context, Tag tag, boolean pretty) throws JspException { TagRenderer renderer = new TagRenderer(pretty); tag.accept(renderer); try { context.getOut().print(renderer.getMarkup()); } catch (IOException e) { throw new JspException("Writing error in custom Tag", e); } } }
java
After a decent outing like 'Check', youth star Nithiin is all set to entertain the audience on 26th March with his romantic comedy titled 'Rang De'. Starring Keerthy Suresh as the female lead, the film is written and directed by Venky Atluri. Songs by Devi Sri Prasad have created a good buzz over this film and sources say that Nithiin & Co have planned three grand pre-release events for promotions. Apparently, the team will be organizing pre-release events in Andhra, Telangana and Rayalaseema territories. While an event will be held in Hyderabad, insiders say that Rajahmundry will be the city in the Andhra region. For Rayalaseema, it is expected to be in Kurnool city. In this way, the makers are covering all three regions. While the dates and venues of these events will be revealed soon, Sithara Entertainments are hoping that 'Rang De' becomes a good success. The teaser and songs were good and we need to wait and see how the film turns out.
english
<filename>result/wilayah/kecamatan_51695.json [{"id":51698,"idParent":51695,"namaWilayah":"BANYUBIRU","tingkatWilayah":4,"idPro":51578,"idKab":51579,"idKec":51695,"idKel":51698,"namaPro":"BANTEN","namaKab":"PANDEGLANG","namaKec":"LABUAN","namaKel":"BANYUBIRU","kodeWilayah":"36.01.12.2003"},{"id":51704,"idParent":51695,"namaWilayah":"BANYUMEKAR","tingkatWilayah":4,"idPro":51578,"idKab":51579,"idKec":51695,"idKel":51704,"namaPro":"BANTEN","namaKab":"PANDEGLANG","namaKec":"LABUAN","namaKel":"BANYUMEKAR","kodeWilayah":"36.01.12.2015"},{"id":51699,"idParent":51695,"namaWilayah":"CARINGIN","tingkatWilayah":4,"idPro":51578,"idKab":51579,"idKec":51695,"idKel":51699,"namaPro":"BANTEN","namaKab":"PANDEGLANG","namaKec":"LABUAN","namaKel":"CARINGIN","kodeWilayah":"36.01.12.2004"},{"id":51701,"idParent":51695,"namaWilayah":"CIGONDANG","tingkatWilayah":4,"idPro":51578,"idKab":51579,"idKec":51695,"idKel":51701,"namaPro":"BANTEN","namaKab":"PANDEGLANG","namaKec":"LABUAN","namaKel":"CIGONDANG","kodeWilayah":"36.01.12.2012"},{"id":51702,"idParent":51695,"namaWilayah":"KALANGANYAR","tingkatWilayah":4,"idPro":51578,"idKab":51579,"idKec":51695,"idKel":51702,"namaPro":"BANTEN","namaKab":"PANDEGLANG","namaKec":"LABUAN","namaKel":"KALANGANYAR","kodeWilayah":"36.01.12.2013"},{"id":51697,"idParent":51695,"namaWilayah":"LABUAN","tingkatWilayah":4,"idPro":51578,"idKab":51579,"idKec":51695,"idKel":51697,"namaPro":"BANTEN","namaKab":"PANDEGLANG","namaKec":"LABUAN","namaKel":"LABUAN","kodeWilayah":"36.01.12.2002"},{"id":51696,"idParent":51695,"namaWilayah":"RANCATEUREUP","tingkatWilayah":4,"idPro":51578,"idKab":51579,"idKec":51695,"idKel":51696,"namaPro":"BANTEN","namaKab":"PANDEGLANG","namaKec":"LABUAN","namaKel":"RANCATEUREUP","kodeWilayah":"36.01.12.2001"},{"id":51703,"idParent":51695,"namaWilayah":"SUKAMAJU","tingkatWilayah":4,"idPro":51578,"idKab":51579,"idKec":51695,"idKel":51703,"namaPro":"BANTEN","namaKab":"PANDEGLANG","namaKec":"LABUAN","namaKel":"SUKAMAJU","kodeWilayah":"36.01.12.2014"},{"id":51700,"idParent":51695,"namaWilayah":"TELUK","tingkatWilayah":4,"idPro":51578,"idKab":51579,"idKec":51695,"idKel":51700,"namaPro":"BANTEN","namaKab":"PANDEGLANG","namaKec":"LABUAN","namaKel":"TELUK","kodeWilayah":"36.01.12.2010"}]
json
If you're young and hungry, the place to go is New York City — even if you weigh 25 tons and have a blowhole. Whale watch captains and scientists around America's most populous city say recent years have seen a tremendous surge in the number of whales observed in the waters around the Big Apple. Many of the whales are juvenile humpbacks, and scientists say they're drawn to New York by an abundance of the small fish they love to eat. There are numerous theories about why whales are suddenly flocking to the city, but one of the most widely held is that the menhaden population has grown around New York and New Jersey. Menhaden are small, schooling fish that humpbacks relish, and environmentalists believe cleaner waters and stricter conservation laws have increased their numbers near New York City. Gotham Whale, a New York City-based whale research organization, made more than 300 observations of 500 total whales in 2019, said Paul Sieswerda, the nonprofit's president. That's up from three sightings of five whales in 2011, after which a steady climb began, he said. The resurgence of whales in the New York-New Jersey Bight, a triangle-shaped indentation in the Atlantic coast, has attracted tourists who want to see and photograph the giant marine mammals. But the concentration of whales near New York City also poses risks to the mammals, as they ply some of the most heavily traversed waters on the planet. The whales are essentially “playing in traffic” by feeding so close to busy shipping lanes, Sieswerda said. And the National Oceanic and Atmospheric Administration has already declared an “unusual mortality event” for humpback whales from Maine to Florida in recent years due to an elevated number of deaths. Since 2016, NOAA records show 133 humpback whales have died on the beaches and waters of the Atlantic coast. The 29 in New York were the most of any state. Of the dead whales examined, half had evidence of human interaction, such as a ship strike or entanglement in fishing gear. The appearance of so many whales near New York City calls for environmental stewardship, said Howard Rosenbaum, director of the Wildlife Conservation Society's Ocean Giants Program. Environmental safeguards, such as the Clean Water Act and Marine Mammal Protection Act, likely helped bring the whales back to New York's bustling waterways, and more protection can help keep them safe there, he said. That will take nongovernmental organizations and state and federal agencies working together "to minimize the risk to animals that are using these habitats to feed,” Rosenabum said. That could include implementing new laws to protect the mammals from ship strikes, he said. Such laws have sometimes included speed reductions in areas where whales travel and feed. The increased sighting of whales off New York City isn't necessarily evidence that the total whale population is growing, said Danielle Brown, the lead humpback whale researcher with Gotham Whale and a doctoral student at Rutgers University. The New York whales aren't a standalone population, but rather members of feeding populations that mostly live farther north, such as in the Gulf of Maine, Brown said. And it's unclear whether the whales are in New York because the larger population is growing. Brown and other scientists have observed that the presence of the giant whales off New York City could take mariners by surprise, and that could put the mammals at risk of ship strikes or other hazards. Increasingly clean water and a growing diversity of fish to feed on could keep the whales in the New York area for the foreseeable future, she said. “This is most likely going to continue, and we have to find a way to coexist with these large animals in our waters,” Brown said.
english
<reponame>SergeyDz/chef-repo<gh_stars>1-10 { "name": "docker", "description": "finalize docker setup", "run_list": [ "recipe[mesosphere::docker_restart]" ] }
json
package com.temple.service.ejb.action.constraint; import java.io.Serializable; import java.util.regex.Pattern; /** * TODOC * @author cr9z1k * @version 1.0 */ public final class PatternConstraintChecker extends PropertiesChecker<PatternConstraint> { private final Pattern pattern; private transient Object[] parameters ; /** * Constructor. * @param keys * @param constraint */ public PatternConstraintChecker(String[] keys, PatternConstraint constraint) { super(keys, constraint); this.pattern = Pattern.compile(constraint.pattern()); } @Override protected boolean isValid(Serializable s) { return (s instanceof String) && this.pattern.matcher((String)s).matches(); } @Override protected Object[] getLocaleParameters() { if(this.parameters == null) { this.parameters = new Object[]{this.pattern.pattern()} ; } return this.parameters; } }
java
<gh_stars>1-10 package com.pubnub.api; class NonSubscribeManager extends AbstractNonSubscribeManager { public NonSubscribeManager(String name, int connectionTimeout, int requestTimeout, boolean daemonThreads) { super(name, connectionTimeout, requestTimeout, daemonThreads); } public void clearRequestQueue() { _waiting.removeAllElements(); } }
java
Fresh from a glorious season-saving triumph at one of his favourite venues, Lewis Hamilton sets out to tame his unpredictable and sometimes wayward “diva” of a Mercedes again as the Formula One circus endures sizzling heat at the Azerbaijan Grand Prix. The three-time world champion’s victory at the Canadian Grand Prix earlier this month – his sixth at the Montreal track – hauled him back within 12 points of championship leader Sebastian Vettel of Ferrari and sharpened his appetite for a maiden success on the streets of Baku, the only venue on the current calendar where he has never won. After an inconsistent opening to the season in which he and Mercedes team-mate Valtteri Bottas have struggled badly at times, Hamilton bounced back to his best in Montreal to claim his third win in seven races as Mercedes produced a crushing one-two success. He arrives in Baku with team boss Toto Wolff’s praise endorsing his behaviour and performances. “Lewis is in the best place I’ve seen him in any of the five years since I joined the team,” said Wolff. Referring to this year’s “new era” car, Wolff admitted it had posed challenges for the team and the drivers with its contrary and temperamental nature: happy and triumphant one week, sulky and unresponsive the next.
english
<filename>js/collection/Walt Whitman/O Me! O Life!.json { "author": "<NAME>", "classification": "", "keywords": [ "Religion", "Faith", "Doubt", "Social Commentaries", "Life Choices" ], "period": "", "reference": "http://www.poetryfoundation.org/poem/182088", "region": "U.S., Mid-Atlantic", "text": [ "Oh me! Oh life! of the questions of these recurring,", "Of the endless trains of the faithless, of cities fill\u2019d with the foolish,", "Of myself forever reproaching myself, (for who more foolish than I, and who more faithless?)", "Of eyes that vainly crave the light, of the objects mean, of the struggle ever renew\u2019d,", "Of the poor results of all, of the plodding and sordid crowds I see around me,", "Of the empty and useless years of the rest, with the rest me intertwined,", "The question, O me! so sad, recurring\u2014What good amid these, O me, O life?", "That you are here\u2014that life exists and identity,", "That the powerful play goes on, and you may contribute a verse." ], "title": "O Me! O Life!", "year": "" }
json
import Sidebar2 from '../components/sidebar/Sidebar2'; global.fetch = require('jest-fetch-mock'); describe('a sidebar', () => { beforeEach(() => { fetch.resetMocks(); }); test('can be constructed', () => { document.body.innerHTML = '<div id="js-sidebar-container">SIDEBAR CONTENT</div>'; const sidebar = new Sidebar2(); expect(sidebar).toBeInstanceOf(Sidebar2); }); test('fails if sidebar element is not present in DOM', () => { document.body.innerHTML = '<div></div>'; const triggerError = () => { new Sidebar2(); }; expect(triggerError).toThrowError('No sidebar container element found in DOM.'); }); test('clicking trigger opens panel in sidebar', async () => { fetch.mockResponse('MOCKED RESPONSE'); document.body.innerHTML = `${ '<a id="trigger" href="foobar"></a>' + '<div id="js-sidebar-container"></div>' }${sidebarTemplate}`; const sidebar = new Sidebar2({ triggerSelector: '#trigger', }); sidebar.listenForEventsInDocument(); await document.getElementById('trigger').click(); expect(fetch.mock.calls.length).toEqual(1); const sidebarEl = document.body.querySelector('#js-sidebar-container'); expect(sidebarEl.innerHTML).toEqual('fake response'); // return Promise.resolve() // .then(() => { // // }) // .then(() => { // // }); }); }); const sidebarTemplate = '<template id="js-sidebar-template">' + '<div data-sidebar style="display:none;">' + '<div data-sidebar-backdrop data-sidebar-close></div>' + '<aside data-sidebar-aside><div data-sidebar-close data-sidebar-close-button></div>' + '<div data-sidebar-content><!-- panel content --></div>' + '</aside></div></template>' + '<template id="js-sidebar-close-button"><span></span></template>';
javascript
Cheni, June 4: India’s heaviest rocket — Geosynchronous Satellite Launch Vehicle-Mark III (GSLV-Mk III) — is all set for its maiden flight into space along with a communications satellite on Monday evening as its countdown of 25 hours and 30 minutes began at 3. 58 p. m. on Sunday, an official of the Indian space agency said. The rocket, weighing 640 tonnes and standing 43. 43 metres tall, will blast off from the second launch pad at India’s rocket port at Satish Dhawan Space Centre in Sriharikota in Andhra Pradesh, around 105 km from here. It will carry a 3,136-kg GSAT-19 communications satellite — the heaviest to be lifted by an Indian rocket till date — to an altitude of around 179 km above the Earth after just over 16 minutes into the flight. On June 2, the Mission Readiness Review Committee and Launch Authorisation Board had cleared the countdown for GSLV Mk-III D1/GSAT-19 mission. The rocket’s main and bigger cryogenic engine has been developed by space scientists here. The mission’s success will eble India to launch four-tonne satellites on its own rocket instead of paying huge amounts of money to foreign space agencies to execute the operation. According to Indian Space Research Organisation, GSAT-19 with a life span of 10 years is a multi-beam satellite that carries Ka and Ku band forward and return link transponders and geostatiory radiation spectrometer. “The rocket’s design carrying capacity is four tonnes. The payload will be gradually increased in future flights of the GSLV Mk-III,” K. Sivan, Director, Vikram Sarabhai Space Centre, told IANS earlier. The Indian space agency had flown a similar rocket without the cryogenic engine but with 3. 7-tonne payload in 2014 mainly to test its structural stability while in flight and the aerodymics. S. Somath, Director, Liquid Propulsion Systems Centre, told IANS that the inputs of the 2014 mission ebled the ISRO to reduce the rocket load by around 20 per cent. Interestingly, GSLV-Mk III at around 43 metres is slightly shorter than Mk-II version that is around 49 metres tall. “The new rocket may be slightly short but has more punch power,” an ISRO official told IANS. India presently has two rockets — the Polar Satellite Launch Vehicle and GSLV-Mk II — with a lift-off mass of 415 tonnes and a carrying capacity of 2. 5 tonnes. (IANS)
english
<reponame>lyonva/Nue Obtained from https://github.com/anonymous12138/biasmitigation/tree/main/Data xFair paper: https://arxiv.org/abs/2110.01109
markdown
<filename>token-metadata/0x63dB4d5E1f9153DA2Bde2d585A0B33d59524181E/metadata.json { "name": "<NAME>", "symbol": "CONY", "address": "0x63dB4d5E1f9153DA2Bde2d585A0B33d59524181E", "decimals": 4, "dharmaVerificationStatus": "UNVERIFIED" }
json
<gh_stars>1-10 { "name": "marjs", "version": "0.0.1", "description": "A library to help you combine angular + selenium", "main": "./dist/index.js", "scripts": { "test": "./node_modules/mocha/bin/mocha tests/test.js --compilers js:babel-core/register -t 15s", "build": "./node_modules/babel-cli/bin/babel.js lib -d dist", "prepublish": "npm run build" }, "author": "Urucas <<EMAIL>>", "license": "MIT", "dependencies": { "babel-cli": "^6.4.5", "babel-core": "^6.4.5", "babel-preset-es2015": "^6.3.13" }, "repository": { "type": "git", "url": "git+https://github.com/Urucas/mar.git" }, "bugs": { "url": "https://github.com/Urucas/mar/issues" }, "homepage": "https://github.com/Urucas/mar#readme", "devDependencies": { "angular": "^1.4.9", "chai": "^3.5.0", "express": "^4.13.4", "selenium-webdriver": "^2.48.2", "mocha": "^2.4.5" } }
json
--- title: 'Tutorial sobre controles de aplicaciones y acceso: Azure Security Center' description: En este tutorial se muestra cómo configurar una directiva de acceso a las máquinas virtuales Just-In-Time y una directiva de control de aplicaciones. services: security-center documentationcenter: na author: memildin manager: rkarlin ms.assetid: 61e95a87-39c5-48f5-aee6-6f90ddcd336e ms.service: security-center ms.devlang: na ms.topic: tutorial ms.custom: mvc ms.tgt_pltfrm: na ms.workload: na ms.date: 12/03/2018 ms.author: memildin ms.openlocfilehash: 3e4404589e180be730579b8cbbfadd132502585a ms.sourcegitcommit: 3543d3b4f6c6f496d22ea5f97d8cd2700ac9a481 ms.translationtype: HT ms.contentlocale: es-ES ms.lasthandoff: 07/20/2020 ms.locfileid: "86529325" --- # <a name="tutorial-protect-your-resources-with-azure-security-center"></a>Tutorial: Protección de los recursos con Azure Security Center Security Center limita la exposición a amenazas mediante controles de acceso y aplicación para bloquear actividades malintencionadas. El acceso a las máquinas virtuales Just-In-Time (JIT) reduce la exposición a ataques mediante la posibilidad de denegar el acceso persistente a las máquinas virtuales. En su lugar, se proporciona acceso controlado y auditado a VM solo cuando se necesita. Los controles de aplicación adaptables ayudan a proteger las VM frente a malware controlando qué aplicaciones se pueden ejecutar en dichas VM. Security Center usa el aprendizaje automático para analizar los procesos que se ejecutan en la máquina virtual y le ayuda a aplicar reglas de inclusión en listas de permitidos con esta inteligencia. En este tutorial, aprenderá a: > [!div class="checklist"] > * Configuración de una directiva de acceso a las máquinas virtuales Just-In-Time > * Configuración de una directiva de control de aplicación ## <a name="prerequisites"></a>Prerrequisitos Para recorrer las características que se tratan en este tutorial, es preciso tener el plan de tarifa Estándar de Security Center. Dicho plan se puede probar de forma gratuita. Para más información, consulte la [página de precios](https://azure.microsoft.com/pricing/details/security-center/). En [Guía de inicio rápido de Azure Security Center](security-center-get-started.md) le explicamos cómo realizar la actualización al plan de tarifa Estándar. ## <a name="manage-vm-access"></a>Administración de acceso a VM El acceso a VM JIT se puede usar para bloquear el tráfico entrante a las VM de Azure. Para ello, se reduce la exposición a ataques al mismo tiempo que se proporciona un acceso sencillo para conectarse a las VM cuando sea necesario. No es necesario que los puertos de administración estén abiertos en todo momento. Solo deben estar abiertos mientras se está conectado a la máquina virtual, por ejemplo, para realizar tareas de administración o mantenimiento. Cuando se habilita Just-In-Time, Security Center usa las reglas del grupo de seguridad de red (NSG), que restringen el acceso a los puertos de administración para que no puedan ser objeto de ataques. 1. En el menú principal de Security Center, seleccione **Acceso de máquina virtual Just-In-Time** en **PROTECCIÓN EN LA NUBE AVANZADA**. ![Acceso de máquina virtual Just-In-Time][1] **Just-in-time VM access** (Acceso a máquina virtual del tipo Just-In-Time) proporciona información acerca del estado de las máquinas virtuales: - **Configurado**: máquinas virtuales que se han configurado para admitir el acceso a máquina virtual Just-In-Time. - **Recomendado**: máquinas virtuales que pueden admitir el acceso a máquina virtual Just-In-Time, pero que no se han configurado para ello. - **Ninguna recomendación**: una máquina virtual podría no recomendarse por diversas razones: - Falta grupo de seguridad de red: la solución Just-In-Time requiere que exista un grupo de seguridad de red. - Máquina virtual clásica: en la actualidad, el acceso a máquina virtual Just-In-Time de Security Center solo admite las máquinas virtuales implementadas mediante Azure Resource Manager. - Otros: una máquina virtual de esta categoría si la solución Just-In-Time está desactivada en la directiva de seguridad de la suscripción o del grupo de recursos, o si la máquina virtual no tiene una IP pública y no existe ningún grupo de seguridad de red. 2. Seleccione una máquina virtual recomendada y haga clic en **Habilitar JIT en 1 VM** para configurar una directiva Just-In-Time para esa máquina virtual: Puede guardar los puertos predeterminados que Security Center recomienda o agregar y configurar un puerto nuevo donde desee habilitar la solución Just-In-Time. En este tutorial, vamos a agregar un puerto seleccionando **Agregar**. ![Adición de configuración de puerto][2] 3. En **Add port configuration** (Agregar configuración de puerto), se identifica: - El puerto - El tipo de protocolo - Las direcciones IP de origen permitidas (intervalos IP que pueden acceder una vez que se ha aprobado una solicitud) - El tiempo de solicitud máximo (el período de tiempo máximo durante el que puede estar abierto un puerto específico) 4. Seleccione **Aceptar** para guardar. ## <a name="harden-vms-against-malware"></a>Proteger VM frente a malware Los controles de aplicación adaptables ayudan a definir un conjunto de aplicaciones que se pueden ejecutar en grupos de recursos configurados que, entre otras ventajas, le ayuda a proteger las VM frente a malware. Security Center usa el aprendizaje automático para analizar los procesos que se ejecutan en la máquina virtual y le ayuda a aplicar reglas de inclusión en listas de permitidos con esta inteligencia. 1. Vuelva al menú principal de Security Center. En **PROTECCIÓN EN LA NUBE AVANZADA**, seleccione **Controles de aplicaciones adaptables**. ![Controles de aplicación adaptables][3] La sección **Grupos de recursos** contiene tres pestañas: - **Configurado**: lista de grupos de recursos con VM configuradas con control de aplicación. - **Recomendado**: lista de grupos de recursos para los que se recomienda el control de aplicación. - **Ninguna recomendación**: lista de grupos de recursos que contienen máquinas virtuales sin ninguna recomendación de control de aplicación. Por ejemplo, máquinas virtuales en las que las aplicaciones cambian constantemente y no han alcanzado un estado estable. 2. Seleccione la pestaña **Recomendado** para obtener una lista de grupos de recursos con las recomendaciones de control de aplicación. ![Recomendaciones de control de aplicación][4] 3. Seleccione un grupo de recursos para abrir la opción **Crear reglas de control de aplicaciones**. En **Seleccionar máquinas virtuales**, revise la lista de máquinas virtuales recomendadas y desactive cualquiera a la que no desee aplicar el control de aplicación. En **Seleccionar procesos para reglas de inclusión en lista blanca**, revise la lista de aplicaciones recomendadas y desactive aquellas a las que no desea que se apliquen. La lista incluye: - **NOMBRE**: la ruta de acceso completa de la aplicación - **PROCESOS**: el número de aplicaciones que residen dentro de cada ruta de acceso - **COMÚN**: "Sí" indica que estos procesos se han ejecutado en la mayoría de las máquinas virtuales de este grupo de recursos - **INFRINGIBLE**: un icono de advertencia indica si un atacante podría usar las aplicaciones para evitar las listas de aplicaciones permitidas. Se recomienda revisar estas aplicaciones antes de su aprobación. 4. Cuando haya terminado de realizar las selecciones, elija **Crear**. ## <a name="clean-up-resources"></a>Limpieza de recursos Otras guías de inicio rápido y tutoriales de esta colección se basan en los valores de esta. Si planea continuar trabajando con las guías rápidas y tutoriales posteriores, siga ejecutando el plan de tarifa Estándar y mantenga el aprovisionamiento automático habilitado. Si no planea continuar o desea volver al nivel Gratis: 1. Vuelva al menú principal de Security Center y seleccione **Directiva de seguridad**. 2. Seleccione la suscripción o directiva que desea que vuelva al nivel Gratis. Se abre **Directiva de seguridad**. 3. En **COMPONENTES DE LA DIRECTIVAS**, seleccione **Plan de tarifa**. 4. Seleccione **Gratis** para cambiar la suscripción del nivel Estándar al Gratis. 5. Seleccione **Guardar**. Si desea deshabilitar el aprovisionamiento automático: 1. Vuelva al menú principal de Security Center y seleccione **Directiva de seguridad**. 2. Seleccione la suscripción en la que quiere deshabilitar el aprovisionamiento automático. 3. En **Directiva de seguridad: Colección de datos**, en **Incorporación**, seleccione **Desactivado** para deshabilitar el aprovisionamiento automático. 4. Seleccione **Guardar**. >[!NOTE] > La deshabilitación del aprovisionamiento automático no quita el agente de Log Analytics de las máquinas virtuales de Azure en las que se ha aprovisionado. La deshabilitación del aprovisionamiento automático limita la supervisión de seguridad de los recursos. > ## <a name="next-steps"></a>Pasos siguientes En este tutorial, aprendió a limitar la exposición a amenazas mediante: > [!div class="checklist"] > * La configuración de un directiva de acceso a las máquinas virtuales Just-In-Time para proporcionar acceso controlado y auditado a las máquinas virtuales solo cuando sea necesario > * La configuración de una directiva de controles de aplicación adaptables para controlar qué aplicaciones se pueden ejecutar en las VM Pase al siguiente tutorial para aprender a responder a incidentes relacionados con la seguridad. > [!div class="nextstepaction"] > [Tutorial: Respuesta a incidentes de seguridad](tutorial-security-incident.md) <!--Image references--> [1]: ./media/tutorial-protect-resources/just-in-time-vm-access.png [2]: ./media/tutorial-protect-resources/add-port.png [3]: ./media/tutorial-protect-resources/adaptive-application-control-options.png [4]: ./media/tutorial-protect-resources/recommended-resource-groups.png
markdown
In a shocking state of affairs, actress Sushmita Sen announced that she has called off her relationship with model Rohman Shawl after dating him for three years. On Thursday, the actress took to her Instagram to share a picture of them and wrote, "We began as friends, we remain friends! ! The relationship was long over…the love remains! ! #nomorespeculations #liveandletlive #cherishedmemories #gratitude #love #friendship I love you guys! ! ! " The Bollywood galore also claims that Rohman has even moved out of her house. He is currently staying at a friend’s place. On December 22, Sushmita had reshared a post on relationships, which had added oil to the fire. Earlier this year in February when Sushmita shared a post that spoke about walking out of a futile relationship, there were speculations that all is not well in Sushmita and Rohman's paradise. Fans had begun wondering if she had broken up with Rohman. However, the couple was often snapped together making public appearances which eventually killed the rumours of their break-up. For those unversed, Rohman and Sushmita started dating in 2018 and were quite active on social media showing love to each other. They were spotted together for the first time at Shilpa Shetty's Diwali party in 2018. Also read: Happy Birthday Sushmita Sen: Beau Rohman Shawl showers love on his 'Babush' Meanwhile, on the work front, Sushmita is currently basking in the success of her web series Arya 2. Created by Ram Madhvani, the International Emmy-nominated show is an official adaption of the hit Dutch series "Penoza". Sen, 46, plays the role of Aarya Sareen, a mother combatting the dark world of crime and enemies closing in on her family and children.
english
import json from django.contrib.auth.models import User from django.urls import reverse from rest_framework import status from rest_framework.authtoken.models import Token from rest_framework.test import APITestCase from profiles.api import serializers from . import models class RegistrationTestCase(APITestCase): def test_registration(self): data = {"username": "testcase", "email":"<EMAIL>", "password1": "<PASSWORD>", "password2": "<PASSWORD>"} response = self.client.post("/api/v1/rest-auth/registration/", data=data) self.assertEqual(response.status_code, status.HTTP_201_CREATED) class ProfileViewSetTestCase(APITestCase): list_url = reverse('profile-list') def setUp(self): self.user = User.objects.create_user(username="test1", password="<PASSWORD>") self.token = Token.objects.create(user=self.user) self.api_authentication() def api_authentication(self): self.client.credentials(HTTP_AUTHORIZATION="Token " + self.token.key) def test_profile_list_authenticated(self): response = self.client.get(self.list_url) self.assertEqual(response.status_code, status.HTTP_200_OK) def test_profile_list_un_authenitcated(self): self.client.force_authenticate(user=None) response = self.client.get(self.list_url) self.assertEqual(response.status_code, status.HTTP_403_FORBIDDEN) def test_profile_detail_retrieve(self): response = self.client.get(reverse('profile-detail', kwargs={"pk": 1})) self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(response.data["user"], "test1") def test_profile_update_by_owner(self): response = self.client.put(reverse('profile-detail', kwargs={"pk": 1}), {"city": "TestCity", "bio": "TestBio"}) self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(json.loads(response.content), {"id": 1, "user": "test1", "bio": "TestBio", "city": "TestCity", "avatar":None}) def test_profile_update_by_random_user(self): random_user = User.objects.create_user(username="random", password="<PASSWORD>") self.client.force_authenticate(user=random_user) response = self.client.put(reverse("profile-detail", kwargs={"pk":1}), {"bio": "Bio Hacked!"}) self.assertEqual(response.status_code, status.HTTP_403_FORBIDDEN) class ProfileStatusViewSetTestCase(APITestCase): url = reverse("status-list") def setUp(self): self.user = User.objects.create_user(username="test1", password="<PASSWORD>") self.status = models.ProfileStatus.objects.create(user_profile=self.user.profile, status_content="status test") self.token = Token.objects.create(user=self.user) self.api_authentication() def api_authentication(self): self.client.credentials(HTTP_AUTHORIZATION="Token " + self.token.key) def test_status_list_authenticated(self): response = self.client.get(self.url) self.assertEqual(response.status_code, status.HTTP_200_OK) def test_status_list_un_authenticated(self): self.client.force_authenticate(user=None) response = self.client.get(self.url) self.assertEqual(response.status_code, status.HTTP_403_FORBIDDEN) def test_status_create(self): data = {"status_content": "a new status!"} response = self.client.post(self.url, data) self.assertEqual(response.status_code, status.HTTP_201_CREATED) self.assertEqual(response.data["user_profile"], "test1") self.assertEqual(response.data["status_content"], "a new status!") def test_single_status_retrieve(self): serializer_data = serializers.ProfileStatusSerializer(instance=self.status).data response = self.client.get(reverse('status-detail', kwargs={"pk":1})) self.assertEqual(response.status_code, status.HTTP_200_OK) response_data = json.loads(response.content) self.assertEqual(serializer_data, response_data) def test_status_update_owner(self): data = {"status_content": "content updated"} response = self.client.put(reverse("status-detail", kwargs={"pk":1}), data=data) self.assertEqual(response.status_code, status.HTTP_200_OK) self.assertEqual(response.data["status_content"], "content updated") def test_status_update_random_user(self): random_user = User.objects.create_user(username="random", password="<PASSWORD>") self.client.force_authenticate(user=random_user) data = {"status_content": "Data hacked!"} response = self.client.put(reverse("status-detail", kwargs={"pk":1}), data=data) self.assertEqual(response.status_code, status.HTTP_403_FORBIDDEN)
python
<gh_stars>10-100 import { Button } from "@chakra-ui/react"; import React from "react"; import { Link as RouteLink, useMatch } from "react-router-dom"; type NavLinkProps = { text: string; path: string }; export default function NavLink({ text, path }: NavLinkProps) { const match = useMatch(path); return ( <RouteLink to={path}> <Button width="100px" colorScheme="blue" variant={match?.path ? "solid" : "outline"}> {text} </Button> </RouteLink> ); }
typescript
{ "n_targets": 1121, "n_bootstraps": 0, "n_processed": 39720727, "n_pseudoaligned": 7671, "n_unique": 7418, "p_pseudoaligned": 0.0, "p_unique": 0.0, "kallisto_version": "0.46.1", "index_version": 10, "start_time": "Tue Sep 28 10:18:38 2021", "call": "kallisto quant -i /cluster/work/users/anderkkr/57_Virvar/00_data/Genome_annotated/PkV-RF01_final_cds -t 16 -o kallisto_results 54-a13ca_S151_L004_R1_001_val_1.fq.gz 54-a13ca_S151_L004_R2_001_val_2.fq.gz" }
json
The Samajwadi Party (SP) has expelled former minister Uma Kiran for six years for 'anti-party' activities. The expulsion was announced by SP district president Pramod Tyagi. Tyagi said that Uma Kiran was allegedly demanding party ticket from Purkazi seat and was miffed at not being given. She has been given a ticket from the seat by Azad Samaj Party, led by Chandra Shekhar Azad, and was also seen in a press conference with him, which led to her expulsion.
english
// Targeted by JavaCPP version 1.5.8-SNAPSHOT: DO NOT EDIT THIS FILE package org.bytedeco.bullet.Bullet3OpenCL; import java.nio.*; import org.bytedeco.javacpp.*; import org.bytedeco.javacpp.annotation.*; import static org.bytedeco.javacpp.presets.javacpp.*; import org.bytedeco.bullet.Bullet3Common.*; import static org.bytedeco.bullet.global.Bullet3Common.*; import org.bytedeco.bullet.Bullet3Collision.*; import static org.bytedeco.bullet.global.Bullet3Collision.*; import org.bytedeco.bullet.Bullet3Dynamics.*; import static org.bytedeco.bullet.global.Bullet3Dynamics.*; import org.bytedeco.bullet.LinearMath.*; import static org.bytedeco.bullet.global.LinearMath.*; import static org.bytedeco.bullet.global.Bullet3OpenCL.*; @NoOffset @Properties(inherit = org.bytedeco.bullet.presets.Bullet3OpenCL.class) public class b3BufferInfoCL extends Pointer { static { Loader.load(); } //b3BufferInfoCL(){} // template<typename T> public b3BufferInfoCL(@Cast("cl_mem") Pointer buff, @Cast("bool") boolean isReadOnly/*=false*/) { super((Pointer)null); allocate(buff, isReadOnly); } private native void allocate(@Cast("cl_mem") Pointer buff, @Cast("bool") boolean isReadOnly/*=false*/); public b3BufferInfoCL(@Cast("cl_mem") Pointer buff) { super((Pointer)null); allocate(buff); } private native void allocate(@Cast("cl_mem") Pointer buff); public native @Cast("cl_mem") Pointer m_clBuffer(); public native b3BufferInfoCL m_clBuffer(Pointer setter); public native @Cast("bool") boolean m_isReadOnly(); public native b3BufferInfoCL m_isReadOnly(boolean setter); }
java
{"sha":"\"47e7bc67f932866e4467f7ab8a23bb167405bebd\"","commit":{"author":{"name":"\"<NAME>\"","email":"\"<EMAIL>\"","date":"\"2016-09-01T15:51:09+02:00\""},"committer":{"name":"\"<NAME>\"","email":"\"<EMAIL>\"","date":"\"2016-09-01T15:51:09+02:00\""},"message":"\"Bug 1298345 - Refactor CanvasRenderingContext2D's texture allocation code. r=Bas43fabdf\""},"diff":"\"43fabdf run xptgen from build script, use env vars from xptgen to get mozilla objdir/srcdir paths\\ndiff --git a/services/sync/xptgen b/services/sync/xptgen\\nindex 84eba2b..033f63ce 100755\\n--- a/services/sync/xptgen\\n+++ b/services/sync/xptgen\\n@@ -1,2 +1,12 @@\\n #!/bin/bash\\n-../../mozilla-trunk/obj/firefox/dist/bin/xpidl -m typelib -I ../../mozilla-trunk/mozilla/xpcom/base/ -o nsIBookmarksSyncService nsIBookmarksSyncService.idl\\n+\\n+if [[ ! -d $MOZOBJDIR ]]; then\\n+ echo \\\"MOZOBJDIR environment variable must point to a Mozilla build obj tree (with xptgen)\\\"\\n+ exit 1\\n+fi\\n+if [[ ! -d $MOZSRCDIR ]]; then\\n+ echo \\\"MOZSRCDIR environment variable must point to a Mozilla source tree\\\"\\n+ exit 1\\n+fi\\n+\\n+$MOZOBJDIR/dist/bin/xpidl -m typelib -I $MOZSRCDIR/xpcom/base/ -o nsIBookmarksSyncService nsIBookmarksSyncService.idl\\n\""}
json
# Copyright 2014 Mirantis, Inc. # # Licensed under the Apache License, Version 2.0 (the "License"); # you may not use this file except in compliance with the License. # You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, software # distributed under the License is distributed on an "AS IS" BASIS, # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. # See the License for the specific language governing permissions and # limitations under the License. import mock import os from oslotest import base as test_base import six import StringIO if six.PY2: OPEN_FUNCTION_NAME = '__builtin__.open' else: OPEN_FUNCTION_NAME = 'builtins.open' from fuel_agent import errors from fuel_agent.utils import grub_utils as gu from fuel_agent.utils import utils class TestGrubUtils(test_base.BaseTestCase): @mock.patch.object(os.path, 'isdir') def test_guess_grub2_conf(self, mock_isdir): side_effect_values = { '/target/boot/grub': True, '/target/boot/grub2': False } def side_effect(key): return side_effect_values[key] mock_isdir.side_effect = side_effect self.assertEqual(gu.guess_grub2_conf('/target'), '/boot/grub/grub.cfg') side_effect_values = { '/target/boot/grub': False, '/target/boot/grub2': True } self.assertEqual(gu.guess_grub2_conf('/target'), '/boot/grub2/grub.cfg') @mock.patch.object(os.path, 'isfile') def test_guess_grub2_default(self, mock_isfile): side_effect_values = { '/target/etc/default/grub': True, '/target/etc/sysconfig/grub': False } def side_effect(key): return side_effect_values[key] mock_isfile.side_effect = side_effect self.assertEqual(gu.guess_grub2_default('/target'), '/etc/default/grub') side_effect_values = { '/target/etc/default/grub': False, '/target/etc/sysconfig/grub': True } self.assertEqual(gu.guess_grub2_default('/target'), '/etc/sysconfig/grub') @mock.patch.object(os.path, 'isfile') def test_guess_grub2_mkconfig(self, mock_isfile): side_effect_values = { '/target/sbin/grub-mkconfig': True, '/target/sbin/grub2-mkconfig': False, '/target/usr/sbin/grub-mkconfig': False, '/target/usr/sbin/grub2-mkconfig': False } def side_effect(key): return side_effect_values[key] mock_isfile.side_effect = side_effect self.assertEqual(gu.guess_grub2_mkconfig('/target'), '/sbin/grub-mkconfig') side_effect_values = { '/target/sbin/grub-mkconfig': False, '/target/sbin/grub2-mkconfig': True, '/target/usr/sbin/grub-mkconfig': False, '/target/usr/sbin/grub2-mkconfig': False } self.assertEqual(gu.guess_grub2_mkconfig('/target'), '/sbin/grub2-mkconfig') side_effect_values = { '/target/sbin/grub-mkconfig': False, '/target/sbin/grub2-mkconfig': False, '/target/usr/sbin/grub-mkconfig': True, '/target/usr/sbin/grub2-mkconfig': False } self.assertEqual(gu.guess_grub2_mkconfig('/target'), '/usr/sbin/grub-mkconfig') side_effect_values = { '/target/sbin/grub-mkconfig': False, '/target/sbin/grub2-mkconfig': False, '/target/usr/sbin/grub-mkconfig': False, '/target/usr/sbin/grub2-mkconfig': True } self.assertEqual(gu.guess_grub2_mkconfig('/target'), '/usr/sbin/grub2-mkconfig') @mock.patch.object(gu, 'guess_grub_install') @mock.patch.object(utils, 'execute') def test_guess_grub_version_1(self, mock_exec, mock_ggi): mock_ggi.return_value = '/grub_install' mock_exec.return_value = ('foo 0.97 bar', '') version = gu.guess_grub_version('/target') mock_exec.assert_called_once_with('/target/grub_install', '-v') self.assertEqual(version, 1) @mock.patch.object(gu, 'guess_grub_install') @mock.patch.object(utils, 'execute') def test_guess_grub_version_2(self, mock_exec, mock_ggi): mock_ggi.return_value = '/grub_install' mock_exec.return_value = ('foo bar', '') version = gu.guess_grub_version('/target') mock_exec.assert_called_once_with('/target/grub_install', '-v') self.assertEqual(version, 2) @mock.patch.object(os.path, 'isfile') def test_guess_grub(self, mock_isfile): side_effect_values = { '/target/sbin/grub': True, '/target/usr/sbin/grub': False } def side_effect(key): return side_effect_values[key] mock_isfile.side_effect = side_effect self.assertEqual(gu.guess_grub('/target'), '/sbin/grub') side_effect_values = { '/target/sbin/grub': False, '/target/usr/sbin/grub': True } self.assertEqual(gu.guess_grub('/target'), '/usr/sbin/grub') side_effect_values = { '/target/sbin/grub': False, '/target/usr/sbin/grub': False } self.assertRaises(errors.GrubUtilsError, gu.guess_grub, '/target') @mock.patch.object(os.path, 'isfile') def test_grub_install(self, mock_isfile): side_effect_values = { '/target/sbin/grub-install': True, '/target/sbin/grub2-install': False, '/target/usr/sbin/grub-install': False, '/target/usr/sbin/grub2-install': False } def side_effect(key): return side_effect_values[key] mock_isfile.side_effect = side_effect self.assertEqual(gu.guess_grub_install('/target'), '/sbin/grub-install') side_effect_values = { '/target/sbin/grub-install': False, '/target/sbin/grub2-install': True, '/target/usr/sbin/grub-install': False, '/target/usr/sbin/grub2-install': False } self.assertEqual(gu.guess_grub_install('/target'), '/sbin/grub2-install') side_effect_values = { '/target/sbin/grub-install': False, '/target/sbin/grub2-install': False, '/target/usr/sbin/grub-install': True, '/target/usr/sbin/grub2-install': False } self.assertEqual(gu.guess_grub_install('/target'), '/usr/sbin/grub-install') side_effect_values = { '/target/sbin/grub-install': False, '/target/sbin/grub2-install': False, '/target/usr/sbin/grub-install': False, '/target/usr/sbin/grub2-install': True } self.assertEqual(gu.guess_grub_install('/target'), '/usr/sbin/grub2-install') @mock.patch.object(os, 'listdir') def test_guess_kernel(self, mock_listdir): mock_listdir.return_value = ['1', '2', 'vmlinuz-version', '3'] self.assertEqual(gu.guess_kernel('/target'), 'vmlinuz-version') mock_listdir.return_value = ['1', '2', '3'] self.assertRaises(errors.GrubUtilsError, gu.guess_kernel, '/target') @mock.patch.object(os, 'listdir') def test_guess_initrd(self, mock_listdir): mock_listdir.return_value = ['1', '2', 'initramfs-version', '3'] self.assertEqual(gu.guess_initrd('/target'), 'initramfs-version') mock_listdir.return_value = ['1', '2', 'initrd-version', '3'] self.assertEqual(gu.guess_initrd('/target'), 'initrd-version') mock_listdir.return_value = ['1', '2', '3'] self.assertRaises(errors.GrubUtilsError, gu.guess_initrd, '/target') @mock.patch.object(gu, 'grub1_stage1') @mock.patch.object(gu, 'grub1_mbr') def test_grub1_install(self, mock_mbr, mock_stage1): install_devices = ['/dev/foo', '/dev/bar'] expected_calls_mbr = [] for install_device in install_devices: expected_calls_mbr.append( mock.call(install_device, '/dev/foo', '0', chroot='/target')) gu.grub1_install(install_devices, '/dev/foo1', '/target') self.assertEqual(expected_calls_mbr, mock_mbr.call_args_list) mock_stage1.assert_called_once_with(chroot='/target') # should raise exception if boot_device (second argument) # is not a partition but a whole disk self.assertRaises(errors.GrubUtilsError, gu.grub1_install, '/dev/foo', '/dev/foo', chroot='/target') @mock.patch.object(gu, 'guess_grub') @mock.patch.object(os, 'chmod') @mock.patch.object(utils, 'execute') def test_grub1_mbr_install_differs_boot(self, mock_exec, mock_chmod, mock_guess): mock_guess.return_value = '/sbin/grub' mock_exec.return_value = ('stdout', 'stderr') # install_device != boot_disk batch = 'device (hd0) /dev/foo\n' batch += 'geometry (hd0) 130 255 63\n' batch += 'device (hd1) /dev/bar\n' batch += 'geometry (hd1) 130 255 63\n' batch += 'root (hd1,0)\n' batch += 'setup (hd0)\n' batch += 'quit\n' script = 'cat /tmp/grub.batch | /sbin/grub --no-floppy --batch' mock_open = mock.mock_open() with mock.patch(OPEN_FUNCTION_NAME, new=mock_open, create=True): gu.grub1_mbr('/dev/foo', '/dev/bar', '0', chroot='/target') self.assertEqual( mock_open.call_args_list, [mock.call('/target/tmp/grub.batch', 'wb'), mock.call('/target/tmp/grub.sh', 'wb')] ) mock_open_file = mock_open() self.assertEqual( mock_open_file.write.call_args_list, [mock.call(batch), mock.call(script)] ) mock_chmod.assert_called_once_with('/target/tmp/grub.sh', 0o755) mock_exec.assert_called_once_with( 'chroot', '/target', '/tmp/grub.sh', run_as_root=True, check_exit_code=[0]) @mock.patch.object(gu, 'guess_grub') @mock.patch.object(os, 'chmod') @mock.patch.object(utils, 'execute') def test_grub1_mbr_install_same_as_boot(self, mock_exec, mock_chmod, mock_guess): mock_guess.return_value = '/sbin/grub' mock_exec.return_value = ('stdout', 'stderr') # install_device == boot_disk batch = 'device (hd0) /dev/foo\n' batch += 'geometry (hd0) 130 255 63\n' batch += 'root (hd0,0)\n' batch += 'setup (hd0)\n' batch += 'quit\n' script = 'cat /tmp/grub.batch | /sbin/grub --no-floppy --batch' mock_open = mock.mock_open() with mock.patch(OPEN_FUNCTION_NAME, new=mock_open, create=True): gu.grub1_mbr('/dev/foo', '/dev/foo', '0', chroot='/target') self.assertEqual( mock_open.call_args_list, [mock.call('/target/tmp/grub.batch', 'wb'), mock.call('/target/tmp/grub.sh', 'wb')] ) mock_open_file = mock_open() self.assertEqual( mock_open_file.write.call_args_list, [mock.call(batch), mock.call(script)] ) mock_chmod.assert_called_once_with('/target/tmp/grub.sh', 0o755) mock_exec.assert_called_once_with( 'chroot', '/target', '/tmp/grub.sh', run_as_root=True, check_exit_code=[0]) @mock.patch.object(gu, 'guess_kernel') @mock.patch.object(gu, 'guess_initrd') def test_grub1_cfg_kernel_initrd_are_not_set(self, mock_initrd, mock_kernel): mock_kernel.return_value = 'kernel-version' mock_initrd.return_value = 'initrd-version' config = """ default=0 timeout=5 title Default (kernel-version) kernel /kernel-version kernel-params initrd /initrd-version """ mock_open = mock.mock_open() with mock.patch(OPEN_FUNCTION_NAME, new=mock_open, create=True): gu.grub1_cfg(chroot='/target', kernel_params='kernel-params') mock_open.assert_called_once_with('/target/boot/grub/grub.conf', 'wb') mock_open_file = mock_open() mock_open_file.write.assert_called_once_with(config) def test_grub1_cfg_kernel_initrd_are_set(self): config = """ default=0 timeout=5 title Default (kernel-version-set) kernel /kernel-version-set kernel-params initrd /initrd-version-set """ mock_open = mock.mock_open() with mock.patch(OPEN_FUNCTION_NAME, new=mock_open, create=True): gu.grub1_cfg(kernel='kernel-version-set', initrd='initrd-version-set', chroot='/target', kernel_params='kernel-params') mock_open.assert_called_once_with('/target/boot/grub/grub.conf', 'wb') mock_open_file = mock_open() mock_open_file.write.assert_called_once_with(config) @mock.patch.object(utils, 'execute') @mock.patch.object(gu, 'guess_grub_install') def test_grub2_install(self, mock_guess_grub, mock_exec): mock_guess_grub.return_value = '/sbin/grub' expected_calls = [ mock.call('chroot', '/target', '/sbin/grub', '/dev/foo', run_as_root=True, check_exit_code=[0]), mock.call('chroot', '/target', '/sbin/grub', '/dev/bar', run_as_root=True, check_exit_code=[0]) ] gu.grub2_install(['/dev/foo', '/dev/bar'], chroot='/target') self.assertEqual(mock_exec.call_args_list, expected_calls) @mock.patch.object(gu, 'guess_grub2_conf') @mock.patch.object(gu, 'guess_grub2_mkconfig') @mock.patch.object(utils, 'execute') @mock.patch.object(gu, 'guess_grub2_default') def test_grub2_cfg(self, mock_def, mock_exec, mock_mkconfig, mock_conf): mock_def.return_value = '/etc/default/grub' mock_mkconfig.return_value = '/sbin/grub-mkconfig' mock_conf.return_value = '/boot/grub/grub.cfg' orig_content = """foo GRUB_CMDLINE_LINUX="kernel-params-orig" bar""" new_content = """foo GRUB_CMDLINE_LINUX="kernel-params-new" bar""" # mock_open = mock.mock_open(read_data=orig_content) with mock.patch(OPEN_FUNCTION_NAME, new=mock.mock_open(read_data=orig_content), create=True) as mock_open: mock_open.return_value = mock.MagicMock(spec=file) handle = mock_open.return_value.__enter__.return_value handle.__iter__.return_value = StringIO.StringIO(orig_content) gu.grub2_cfg(kernel_params='kernel-params-new', chroot='/target') self.assertEqual( mock_open.call_args_list, [mock.call('/target/etc/default/grub'), mock.call('/target/etc/default/grub', 'wb')] ) handle.write.assert_called_once_with(new_content) mock_exec.assert_called_once_with('chroot', '/target', '/sbin/grub-mkconfig', '-o', '/boot/grub/grub.cfg', run_as_root=True)
python
The IPL is gearing up for a mega auction ahead of its 15th season that will see it introducing two new franchise based out of Lucknow and Ahmedabad. The need for a mega auction has arose due to the expansion of the T20 league meaning the original eight franchises are in for a major overhaul as far as their squad combination is concerned. The teams were asked to release a majority of their players. However, with he eight teams spending considerable resources into the building of their respective squads over the years, the BCCI gave the team an option to keep up to four players of which a maximum of three could be Indians, two overseas and two uncapped players. Out of the eight, only four franchises including Chennai Super Kings, Mumbai Indians, Kolkata Knight Riders and Delhi Capitals retained four players each. Rajasthan Royals, Royal Challengers Bangalore and Sunrisers Hyderabad kept three players each while Punjab Kings released all but two of their players. While there hasn’t been an official announcement, yet, various media reports claim that the auction will be a two-day affair with February 12 and February 13 being penciled in as the dates. However, a latest report claims that there’s a chance the auction could be pushed forward by a week considering the bind IPL finds itself over the owners of its Ahmedabad franchise. The lawyers of BCCI and CVC are reportedly discussing a suitable terminology for the agreement to be signed for the franchise. In all likeliness, Bengaluru will be the venue. However, with the covid situation in India worsening, there is a possibility of the auction being shifted to a new venue. Kolkata, Kochi and Mumbai are the standby venues but if necessary, the auction could be held outside India as well with UAE the likely destination. Each of the ten teams were given a purse of Rs 90 crore before retention. Of it, the eight teams were allowed to spend up to Rs 42 crore on retaining players.
english
<filename>ql/src/java/org/apache/hadoop/hive/ql/udf/UDFLike.java<gh_stars>0 begin_unit|revision:0.9.5;language:Java;cregit-version:0.0.1 begin_comment comment|/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ end_comment begin_package package|package name|org operator|. name|apache operator|. name|hadoop operator|. name|hive operator|. name|ql operator|. name|udf package|; end_package begin_import import|import name|java operator|. name|util operator|. name|regex operator|. name|Matcher import|; end_import begin_import import|import name|java operator|. name|util operator|. name|regex operator|. name|Pattern import|; end_import begin_import import|import name|org operator|. name|apache operator|. name|hadoop operator|. name|hive operator|. name|ql operator|. name|exec operator|. name|Description import|; end_import begin_import import|import name|org operator|. name|apache operator|. name|hadoop operator|. name|hive operator|. name|ql operator|. name|exec operator|. name|UDF import|; end_import begin_import import|import name|org operator|. name|apache operator|. name|hadoop operator|. name|hive operator|. name|ql operator|. name|exec operator|. name|vector operator|. name|VectorizedExpressions import|; end_import begin_import import|import name|org operator|. name|apache operator|. name|hadoop operator|. name|hive operator|. name|ql operator|. name|exec operator|. name|vector operator|. name|expressions operator|. name|FilterStringColLikeStringScalar import|; end_import begin_import import|import name|org operator|. name|apache operator|. name|hadoop operator|. name|hive operator|. name|ql operator|. name|exec operator|. name|vector operator|. name|expressions operator|. name|SelectStringColLikeStringScalar import|; end_import begin_import import|import name|org operator|. name|apache operator|. name|hadoop operator|. name|io operator|. name|BooleanWritable import|; end_import begin_import import|import name|org operator|. name|apache operator|. name|hadoop operator|. name|io operator|. name|Text import|; end_import begin_comment comment|/** * UDFLike. * */ end_comment begin_class annotation|@ name|Description argument_list|( name|name operator|= literal|"like" argument_list|, name|value operator|= literal|"_FUNC_(str, pattern) - Checks if str matches pattern" argument_list|, name|extended operator|= literal|"Example:\n" operator|+ literal|"> SELECT a.* FROM srcpart a WHERE a.hr _FUNC_ '%2' LIMIT 1;\n" operator|+ literal|" 27 val_27 2008-04-08 12" argument_list|) annotation|@ name|VectorizedExpressions argument_list|( block|{ name|FilterStringColLikeStringScalar operator|. name|class block|, name|SelectStringColLikeStringScalar operator|. name|class block|} argument_list|) specifier|public class|class name|UDFLike extends|extends name|UDF block|{ specifier|private specifier|final name|Text name|lastLikePattern init|= operator|new name|Text argument_list|() decl_stmt|; specifier|private name|Pattern name|p init|= literal|null decl_stmt|; comment|// Doing characters comparison directly instead of regular expression comment|// matching for simple patterns like "%abc%". specifier|private enum|enum name|PatternType block|{ name|NONE block|, comment|// "abc" name|BEGIN block|, comment|// "abc%" name|END block|, comment|// "%abc" name|MIDDLE block|, comment|// "%abc%" name|COMPLEX block|, comment|// all other cases, such as "ab%c_de" block|} specifier|private name|PatternType name|type init|= name|PatternType operator|. name|NONE decl_stmt|; specifier|private specifier|final name|Text name|simplePattern init|= operator|new name|Text argument_list|() decl_stmt|; specifier|private specifier|final name|BooleanWritable name|result init|= operator|new name|BooleanWritable argument_list|() decl_stmt|; specifier|public name|UDFLike parameter_list|() block|{ } specifier|public specifier|static name|String name|likePatternToRegExp parameter_list|( name|String name|likePattern parameter_list|) block|{ name|StringBuilder name|sb init|= operator|new name|StringBuilder argument_list|() decl_stmt|; for|for control|( name|int name|i init|= literal|0 init|; name|i operator|< name|likePattern operator|. name|length argument_list|() condition|; name|i operator|++ control|) block|{ comment|// Make a special case for "\\_" and "\\%" name|char name|n init|= name|likePattern operator|. name|charAt argument_list|( name|i argument_list|) decl_stmt|; if|if condition|( name|n operator|== literal|'\\' operator|&& name|i operator|+ literal|1 operator|< name|likePattern operator|. name|length argument_list|() operator|&& operator|( name|likePattern operator|. name|charAt argument_list|( name|i operator|+ literal|1 argument_list|) operator|== literal|'_' operator||| name|likePattern operator|. name|charAt argument_list|( name|i operator|+ literal|1 argument_list|) operator|== literal|'%' operator|) condition|) block|{ name|sb operator|. name|append argument_list|( name|likePattern operator|. name|charAt argument_list|( name|i operator|+ literal|1 argument_list|) argument_list|) expr_stmt|; name|i operator|++ expr_stmt|; continue|continue; block|} if|if condition|( name|n operator|== literal|'_' condition|) block|{ name|sb operator|. name|append argument_list|( literal|"." argument_list|) expr_stmt|; block|} elseif|else if|if condition|( name|n operator|== literal|'%' condition|) block|{ name|sb operator|. name|append argument_list|( literal|".*?" argument_list|) expr_stmt|; block|} else|else block|{ name|sb operator|. name|append argument_list|( name|Pattern operator|. name|quote argument_list|( name|Character operator|. name|toString argument_list|( name|n argument_list|) argument_list|) argument_list|) expr_stmt|; block|} block|} return|return name|sb operator|. name|toString argument_list|() return|; block|} comment|/** * Parses the likePattern. Based on it is a simple pattern or not, the * function might change two member variables. {@link #type} will be changed * to the corresponding pattern type; {@link #simplePattern} will record the * string in it for later pattern matching if it is a simple pattern. *<p> * Examples:<blockquote> * *<pre> * parseSimplePattern("%abc%") changes {@link #type} to PatternType.MIDDLE * and changes {@link #simplePattern} to "abc" * parseSimplePattern("%ab_c%") changes {@link #type} to PatternType.COMPLEX * and does not change {@link #simplePattern} *</pre> * *</blockquote> * * @param likePattern * the input LIKE query pattern */ specifier|private name|void name|parseSimplePattern parameter_list|( name|String name|likePattern parameter_list|) block|{ name|int name|length init|= name|likePattern operator|. name|length argument_list|() decl_stmt|; name|int name|beginIndex init|= literal|0 decl_stmt|; name|int name|endIndex init|= name|length decl_stmt|; name|char name|lastChar init|= literal|'a' decl_stmt|; name|String name|strPattern init|= operator|new name|String argument_list|() decl_stmt|; name|type operator|= name|PatternType operator|. name|NONE expr_stmt|; for|for control|( name|int name|i init|= literal|0 init|; name|i operator|< name|length condition|; name|i operator|++ control|) block|{ name|char name|n init|= name|likePattern operator|. name|charAt argument_list|( name|i argument_list|) decl_stmt|; if|if condition|( name|n operator|== literal|'_' condition|) block|{ comment|// such as "a_b" if|if condition|( name|lastChar operator|!= literal|'\\' condition|) block|{ comment|// such as "a%bc" name|type operator|= name|PatternType operator|. name|COMPLEX expr_stmt|; return|return; block|} else|else block|{ comment|// such as "abc\%de%" name|strPattern operator|+= name|likePattern operator|. name|substring argument_list|( name|beginIndex argument_list|, name|i operator|- literal|1 argument_list|) expr_stmt|; name|beginIndex operator|= name|i expr_stmt|; block|} block|} elseif|else if|if condition|( name|n operator|== literal|'%' condition|) block|{ if|if condition|( name|i operator|== literal|0 condition|) block|{ comment|// such as "%abc" name|type operator|= name|PatternType operator|. name|END expr_stmt|; name|beginIndex operator|= literal|1 expr_stmt|; block|} elseif|else if|if condition|( name|i operator|< name|length operator|- literal|1 condition|) block|{ if|if condition|( name|lastChar operator|!= literal|'\\' condition|) block|{ comment|// such as "a%bc" name|type operator|= name|PatternType operator|. name|COMPLEX expr_stmt|; return|return; block|} else|else block|{ comment|// such as "abc\%de%" name|strPattern operator|+= name|likePattern operator|. name|substring argument_list|( name|beginIndex argument_list|, name|i operator|- literal|1 argument_list|) expr_stmt|; name|beginIndex operator|= name|i expr_stmt|; block|} block|} else|else block|{ if|if condition|( name|lastChar operator|!= literal|'\\' condition|) block|{ name|endIndex operator|= name|length operator|- literal|1 expr_stmt|; if|if condition|( name|type operator|== name|PatternType operator|. name|END condition|) block|{ comment|// such as "%abc%" name|type operator|= name|PatternType operator|. name|MIDDLE expr_stmt|; block|} else|else block|{ name|type operator|= name|PatternType operator|. name|BEGIN expr_stmt|; comment|// such as "abc%" block|} block|} else|else block|{ comment|// such as "abc\%" name|strPattern operator|+= name|likePattern operator|. name|substring argument_list|( name|beginIndex argument_list|, name|i operator|- literal|1 argument_list|) expr_stmt|; name|beginIndex operator|= name|i expr_stmt|; name|endIndex operator|= name|length expr_stmt|; block|} block|} block|} name|lastChar operator|= name|n expr_stmt|; block|} name|strPattern operator|+= name|likePattern operator|. name|substring argument_list|( name|beginIndex argument_list|, name|endIndex argument_list|) expr_stmt|; name|simplePattern operator|. name|set argument_list|( name|strPattern argument_list|) expr_stmt|; block|} specifier|private specifier|static name|boolean name|find parameter_list|( name|Text name|s parameter_list|, name|Text name|sub parameter_list|, name|int name|startS parameter_list|, name|int name|endS parameter_list|) block|{ name|byte index|[] name|byteS init|= name|s operator|. name|getBytes argument_list|() decl_stmt|; name|byte index|[] name|byteSub init|= name|sub operator|. name|getBytes argument_list|() decl_stmt|; name|int name|lenSub init|= name|sub operator|. name|getLength argument_list|() decl_stmt|; name|boolean name|match init|= literal|false decl_stmt|; for|for control|( name|int name|i init|= name|startS init|; operator|( name|i operator|< name|endS operator|- name|lenSub operator|+ literal|1 operator|) operator|&& operator|( operator|! name|match operator|) condition|; name|i operator|++ control|) block|{ name|match operator|= literal|true expr_stmt|; for|for control|( name|int name|j init|= literal|0 init|; name|j operator|< name|lenSub condition|; name|j operator|++ control|) block|{ if|if condition|( name|byteS index|[ name|j operator|+ name|i index|] operator|!= name|byteSub index|[ name|j index|] condition|) block|{ name|match operator|= literal|false expr_stmt|; break|break; block|} block|} block|} return|return name|match return|; block|} specifier|public name|BooleanWritable name|evaluate parameter_list|( name|Text name|s parameter_list|, name|Text name|likePattern parameter_list|) block|{ if|if condition|( name|s operator|== literal|null operator||| name|likePattern operator|== literal|null condition|) block|{ return|return literal|null return|; block|} if|if condition|( operator|! name|likePattern operator|. name|equals argument_list|( name|lastLikePattern argument_list|) condition|) block|{ name|lastLikePattern operator|. name|set argument_list|( name|likePattern argument_list|) expr_stmt|; name|String name|strLikePattern init|= name|likePattern operator|. name|toString argument_list|() decl_stmt|; name|parseSimplePattern argument_list|( name|strLikePattern argument_list|) expr_stmt|; if|if condition|( name|type operator|== name|PatternType operator|. name|COMPLEX condition|) block|{ name|p operator|= name|Pattern operator|. name|compile argument_list|( name|likePatternToRegExp argument_list|( name|strLikePattern argument_list|) argument_list|, name|Pattern operator|. name|DOTALL argument_list|) expr_stmt|; block|} block|} if|if condition|( name|type operator|== name|PatternType operator|. name|COMPLEX condition|) block|{ name|Matcher name|m init|= name|p operator|. name|matcher argument_list|( name|s operator|. name|toString argument_list|() argument_list|) decl_stmt|; name|result operator|. name|set argument_list|( name|m operator|. name|matches argument_list|() argument_list|) expr_stmt|; block|} else|else block|{ name|int name|startS init|= literal|0 decl_stmt|; name|int name|endS init|= name|s operator|. name|getLength argument_list|() decl_stmt|; comment|// if s is shorter than the required pattern if|if condition|( name|endS operator|< name|simplePattern operator|. name|getLength argument_list|() condition|) block|{ name|result operator|. name|set argument_list|( literal|false argument_list|) expr_stmt|; return|return name|result return|; block|} switch|switch condition|( name|type condition|) block|{ case|case name|BEGIN case|: name|endS operator|= name|simplePattern operator|. name|getLength argument_list|() expr_stmt|; break|break; case|case name|END case|: name|startS operator|= name|endS operator|- name|simplePattern operator|. name|getLength argument_list|() expr_stmt|; break|break; case|case name|NONE case|: if|if condition|( name|simplePattern operator|. name|getLength argument_list|() operator|!= name|s operator|. name|getLength argument_list|() condition|) block|{ name|result operator|. name|set argument_list|( literal|false argument_list|) expr_stmt|; return|return name|result return|; block|} break|break; block|} name|result operator|. name|set argument_list|( name|find argument_list|( name|s argument_list|, name|simplePattern argument_list|, name|startS argument_list|, name|endS argument_list|) argument_list|) expr_stmt|; block|} return|return name|result return|; block|} block|} end_class end_unit
java
The proposed Tidel Park, a joint venture of Tamil Nadu Industrial Development Corporation (TIDCO) and Electronic Corporation of Tamil Nadu (ELCOT), is expected to come as a boon for Information Technology professionals of Tiruchi and neighbouring districts. As per the announcement made by Minister for Industries Thangam Thennarasu in the State Assembly on Thursday, the Tidel Park will come up on 10 acres of land at Panjapur at an estimate of ₹600 crore. It will have a 10 lakh square feet built-up area. Collector M. Pradeep Kumar told The Hindu that a site, owned by the Tiruchi Corporation, near the Integrated Bus Terminus (IBT) at Panjapur, had been shortlisted, out of three sites, for the Tidel Park. The site is located on the Tiruchi-Madurai highway. The process of land transfer was expected to begin soon. The announcement has been received well among industrialists and IT service providers. This will be the second IT park in Tiruchi, a tier-II city. The ELCOT IT Park at Navalpattu, according to the Information Technology and Digital Services Department, is functioning to its full capacity. The IT Park was also being expanded with an additional 1. 16 lakh sq. feet IT Tower . “It is good news for the IT and IT-enabled service providers and IT professionals. More IT companies are evincing interest to foray into Tier-II cities mainly due to the availability of human resources at reasonable pay packages. The proposed park will augur well for both employment providers and employment seekers,” said N. Kanagasabapathy, Chairman of Tiruchi Trade Centre. M. A. Aleem, Tiruchi District Welfare Fund Committee, said that the Tidel Park had potential to accelerate growth of Tiruchi and neighbouring districts. Steps should be taken to begin the construction as early as possible, he added. .
english
<reponame>capselocke/capselocke { "body": "FOR THE STATE WE ARE AT PRESENT IN, NOT BEING THAT OF VISION, WE MUST, IN MANY THINGS, CONTENT OURSELVES WITH FAITH AND PROBABILITY;", "next": "https://raw.githubusercontent.com/CAPSELOCKE/CAPSELOCKE/master/tweets/13881.json" }
json
<gh_stars>1-10 {"type":"Feature","properties":{"type":"barangay","level":"4","label":"Antonino, Alicia, Isabela, Cagayan Valley (Region II), PH","locale":"ph.cagayan-valley-region-ii.isabela.alicia.antonino","country_id":177,"country_reference":177,"country_name":"Philippines","region_id":"3","region_reference":"2","region_name":"Cagayan Valley (Region II)","province_id":"37","province_reference":"37","province_name":"Isabela","city_id":"35","city_reference":"691","city_name":"Alicia","barangay_id":"729","barangay_reference":"17315","barangay_name":"Antonino"},"geometry":{"type":"MultiPolygon","coordinates":[[[[121.715408,16.7904],[121.707031,16.77882],[121.701637,16.780621],[121.710617,16.79295],[121.715408,16.7904]]]]}}
json
Mozilla has added an official translation tool to Firefox that doesn’t rely on cloud processing to do its work, instead performing the machine learning–based process right on your own computer. It’s a huge step forward for a popular service tied strongly to giants like Google and Microsoft. The translation tool, called Firefox Translations, can be added to your browser here. It will need to download some resources the first time it translates a language, and presumably it may download improved models if needed, but the actual translation work is done by your computer, not in a data center a couple hundred miles away. This is important not because many people need to translate in their browsers while offline — like a screen door for a submarine, it’s not really a use case that makes sense — but because the goal is to reduce end reliance on cloud providers with ulterior motives for a task that no longer requires their resources. It’s the result of the E.U.-funded Project Bergamot, which saw Mozilla collaborating with several universities on a set of machine learning tools that would make offline translation possible. Normally this kind of work is done by GPU clusters in data centers, where large language models (gigabytes in size and with billions of parameters) would be deployed to translate a user’s query. But while the cloud-based tools of Google and Microsoft (not to mention DeepL and other upstart competitors) are accurate and (due to having near-unlimited computing power) quick, there’s a fundamental privacy and security risk to sending your data to a third party to be analyzed and sent back. For some this risk is acceptable, while others would prefer not to involve internet ad giants if they don’t have to. If I Google Translate the menu at the tapas place, will I start being targeted for sausage promotions? More importantly, if someone is translating immigration or medical papers with known device ID and location, will ICE come knocking? Doing it all offline makes sense for anyone at all worried about the privacy implications of using a cloud provider for translation, whatever the situation. I quickly tested out the translation quality and found it more than adequate. Here’s a piece of the front page of the Spanish language news outlet El País: Pretty good! Of course, it translated El País as “The Paris” in the tab title, and there were plenty of other questionable phrasings (though it did translate every | as “Oh, it’s a good thing” — rather hilarious). But very little of that got in the way of understanding the gist. And ultimately that’s what most machine translation is meant to do: report basic meaning. For any kind of nuance or subtlety, even a large language model may not be able to replicate idiom, so an actual bilingual person is your best bet. The main limitation is probably a lack of languages. Google Translate supports over a hundred — Firefox Translations does an even dozen: Spanish, Bulgarian, Czech, Estonian, German, Icelandic, Italian, Norwegian Bokmal and Nynorsk, Persian, Portuguese and Russian. That leaves out quite a bit, but remember this is just the first release of a project by a nonprofit and a group of academics — not a marquee product from a multi-billion-dollar globe-spanning internet empire. In fact, the creators are actively soliciting help by exposing a training pipeline to let “enthusiasts” train new models. And they are also soliciting feedback to improve the existing models. This is a usable product, but not a finished one by a long shot!
english
<gh_stars>0 import { async, ComponentFixture, TestBed } from '@angular/core/testing'; import { SimpleClienteDataCardComponent } from './simple-cliente-data-card.component'; describe('SimpleClienteDataCardComponent', () => { let component: SimpleClienteDataCardComponent; let fixture: ComponentFixture<SimpleClienteDataCardComponent>; beforeEach(async(() => { TestBed.configureTestingModule({ declarations: [ SimpleClienteDataCardComponent ] }) .compileComponents(); })); beforeEach(() => { fixture = TestBed.createComponent(SimpleClienteDataCardComponent); component = fixture.componentInstance; fixture.detectChanges(); }); it('should create', () => { expect(component).toBeTruthy(); }); });
typescript
Aisha Sharma has been upping her fashion game and her Instagram timeline is proof. The actress is often spotted with her sister, setting some major fashion trends. Be it unique gym wear or classy beach fit, the actress knows how to ace it all. Recently, the actress posted a couple of stunning pictures on her social media, and fans are swooning over her bold and elegant style. Aisha Sharma posted pictures in an all-black ensemble. She sported a black lace bralette top paired with sheer netted stockings. She enhanced her look with a black blazer. She ditched her footwear and only wore a minimal pendant to accessorise her outfit. She left her hair open with soft curls. The actress boldly captioned the post, “Photos that alter your brain chemistry. ’ Fans reacted to her photos with fire, heart, and awe-faced emoticons. One fan wrote that she is “marvelously beautiful," while others said that she looked “stunning" and “hot. " Last month, fans were adoring Aisha Sharma’s series of sun-kissed photos that she posted on Instagram. She is seen shimmering in a white monokini on an off-white mattress. Aisha Sharma is seen drinking coffee from a fancy mug and putting up a modest smile for the camera. “Caffeine is a stimulant and so am I," Aisha Sharma wrote along with her post. Aisha Sharma and Neha Sharma are trendsetters in activewear. They were spotted dressed in warm-toned attire outside the gym. Aisha Sharma chose a simpler outfit, she was dressed in black shorts with a jacket on top and a red strap sports bra, while Neha Sharma was seen in matching high-waisted tan tights and a single-shoulder, dual-strap sports bra. Ik Vaari, amusic video starring Ayushmann Khurrana, featured Aisha Sharma for the first time on screen. Then, in 2018, she had an appearance alongside Manoj Bajpayee and John Abraham in Milap Zaveri's action drama Satyameva Jayate. Since then, she has appeared in a number of music videos, including Arjun Kanungo's Rangrez and Kudiyan Lahore Diyan by Harrdy Sandhu. Aisha has also worked with her sister Neha Sharma on the Social Swag platform's reality web series Shining with the Sharmas.
english
import fs from 'fs' import path from 'path' import uploadConfig from '../config/upload' import AppError from '../errors/app-error' import ImagesRepository from '../database/local-disk-storage/disk-storage-config' import ImagesDataBase from '../database/typeorm/repositories/images-repository' export default class DeleteImageService { public async execute(file: string): Promise<void> { const imagesDiskRepository = new ImagesRepository() const imagesDataBase = new ImagesDataBase() if (fs.existsSync(path.resolve(uploadConfig.tempFolder, file))) { await imagesDiskRepository.deleteFile(file) } else { throw new AppError('Sorry, unable to find the file') } await imagesDataBase.delete(file) } }
typescript
Hyderabad, Oct 8: Telangana Chief Minister K. Chandrasekhar Rao on Friday appealed to the opposition parties not to curse the state for the sake of politics. Speaking in the State Legislative Assembly, he said while opposition parties were free to speak for politics and criticise the government for its mistakes, they should avoid belittling the state. Claiming that no other state in the country was implementing the kind of welfare schemes launched by Telangana, he said the Telangana Rashtra Samithi (TRS) government was on course to build Telangana envisioned during the movement for separate state. KCR reiterated that during last seven years Telangana not only overcame many problems including shortage of electricity, drinking water and irrigation facilities but also became one of the top contributors to the country's GDP. He has slammed the BJP leaders for their statements that the Centre is providing funds to the state. "It's Telangana which is giving funds to the Centre and what is getting from the Centre is very less compared to its contribution," he said. "When the Centre is not giving funds where is the question of diversion," he asked referring to allegations by BJP leaders that the TRS government is diverting funds received from the Centre. He pointed out that Telangana's per capita income of Rs 2. 37 lakh is double than the average per capita income in the country. He recalled that the people of Telangana were ridiculed in undivided Andhra Pradesh as someone who had no knowledge of agriculture but the same Telangana today has much higher per capita income compared to Rs 1. 70 lakh of Andhra Pradesh. KCR said that once dry lands of Telangana has today transformed into lush green with abundant availability of water due to completion of Kaleshwaram lift irrigation and other projects and round-the-clock electricity supply. He said unlike in the past when people used to migrate from Telangana to other states for employment, it is now attracting workers from all over the country. He claimed that 15 lakh workers from other parts of the country are working in Telangana. The chief minister districts like Mahabubnagar which used to witness large-scale migration of agriculture labourers is today getting migrant labourers from Kurnool (Andhra Pradesh) and other places. He reeled out the figures to compare the achievements of his government compared to the previous Congress governments in undivided Andhra Pradesh. The chief minister also took exception to Majlis-e-Ittehadul Muslimeen (MIM) leader Akbaruddin Owaisi's heaping praise on former chief minister of undivided Andhra Pradesh Y. S. Rajasekhar Reddy. KCR reminded Owaisi that it was also during Rajasekhara Reddy's time that Telangana suffered a lot. "He did injustice to Telangana in all aspects including water and funds. If such a man is praised in Telangana Legislature, it surprise us," he said. The chief minister said it was during YSR's regime that Wakf land belonging to Dargah Hussah Shah Wali was given to Lanco company. He alleged that other Wakf properties were also encroached and put up for sale but he along with Muslim leaders foiled the attempts.
english
- 3 hrs ago International Malala Day 2023: Who Is Malala Yousafzai? Where Is She Celebrating Her 26th Birthday? - News GST Council Meeting Highlights: What Will Be Cheaper, Costlier? - Travel Have you been to Vishveshwaraya Falls in Mandya yet? If not, this is the best time! Is He Suffering From His Childhood Fears? Jacob suffers form Nyctophobia (fear of darkness). It is strange that a stout man like him startles for a second when the light gets switched at the tick of night. When asked the reason for all that goose bumps, he said, "why can't men fear? " True. Men do fear. It's a natural emotion like others such as love, happiness, anger, hurt and sadness. However women may not understand this fear, as men are personified as strong, protective and fearless. In many cases childhood fears are a normal part of growing up but may lead to number of major psychological problems. A recent study shows that a significant number of male children develop full blown anxiety disorders over some common fears. It may relate to anything simple to deadly, like fire, thunder, snakes or spiders. Causes: Here are few instances, which may be the cause of man's fears. Let us consider a simple situation; a child falls into a well and struggles to get out. This child has met death. So, he may develop fear of either enclosed spaces or of water. The fear may even resent him to take part in any water games. Another instance is the sexual assault. Men who are sexually assaulted by the same sex or by women in childhood may develop a fear of commitment and even step back from any sexual practice. No matter how it occurs, whether by external events or internal predisposition these childhood incidents leave a lasting effect on the man's mind. It has to be healed lest he will live with that fear every second of his life. How to deal with fear? The process of overcoming fear is simply an elegant shift from a state of fear to the state of oneness. The first step to deal with fear would be to know your deepest fear. Men although they are scared of certain things deny accepting it as they think fear is not synonymous to masculine. Accept your fear as natural and just another emotion. Note down all your fears on a sheet of paper. Think of everything you must or can't do about it. Which people, places, activities, situations, character traits etc. are you afraid of? After the list is done then get to know the source of all this fear. Step in to the fears with courage. For instance if you are scared of heights go for bungy jumping. Make up your mind that the fears are real and can be tackled. It is better to get rid of it than live with it. So explore yourself, talk it out with someone with whom you can share your deepest feelings. Stop the negative flow in your mind. Think positive win it over since nothing is impossible. So, fight aginst your childhood fears as fear is normal and can be dealt with. Related Articles: - kidsNow, Special Mobiles For Kids! - kidsToo Much TV Can Be Harmful For Kids! - insyncMarlee Matlin's New Book!
english
<gh_stars>0 # carbon-components-vue [![Carbon Components Vue is released under the Apache-2.0 license](https://img.shields.io/badge/license-Apache--2.0-blue.svg)](./LICENSE) [![CircleCI](https://circleci.com/gh/carbon-design-system/carbon-components-vue.svg?style=shield)](https://circleci.com/gh/carbon-design-system/carbon-components-vue) > Vue implementation of the Carbon Design System > A collection of [Carbon Components](https://github.com/carbon-design-system/carbon-components) implemented using <img src="https://vuejs.org/images/logo.png" width="20" alt="Vue logo"> [Vue.js](https://vuejs.org/). <div style="text-align: center"> <img src="./docs/AtCarbonVue.png" alt="@carbon/vue" height="200px"> </div> ## Building and publishing This is a monorepo using `lerna`. The following steps will build and publish the packages: - clone or download the repo; - run `yarn` to install dependencies and bootstrap the packages; - run `yarn build` to build all the packages including the storybook; If you just want to build an individual package you can limit the scope: `yarn build --scope @carbon/vue` `yarn build --scope storybook` To start the storybook in a local server use `yarn start`.
markdown
package pl.Wojtek.filters; import javax.servlet.*; import javax.servlet.annotation.WebFilter; import javax.servlet.http.HttpServletResponse; import java.io.IOException; @WebFilter(value="/") public class RootFilter implements Filter { @Override public void doFilter(ServletRequest servletRequest, ServletResponse servletResponse, FilterChain filterChain) throws IOException, ServletException { HttpServletResponse response = (HttpServletResponse) servletResponse; response.sendRedirect("/game"); } @Override public void init(FilterConfig filterConfig) throws ServletException { } @Override public void destroy() { } }
java
{"id":"78bff606-69d5-4e54-a511-bef3f2256f53","name":"Bedgrove Infant School","code":"B","address":{"addressLine1":"Ingram Avenue","addressLine2":"Aylesbury","town":"Aylesbury","county":"Buckinghamshire","postcode":"HP21 9DJ"},"organisation":{"id":"21cc212c-3fb3-441b-9eeb-ae77ae234ce5","code":"1YP","name":"Bedgrove Infant School"}}
json
<filename>src/Ratio.ts<gh_stars>1-10 function gcd( a: number, b: number ): number { if ( a === b ) { return a } else if ( a > b && a % b === 0) { return b } else if ( b > a && b % a === 0) { return a } else { let c = b while ( b !== 0 ) { c = b b = a % b a = c } return c } } export class Ratio { static ERROR_NUMERATOR_NAN = 'Ratio numerator is NaN' static ERROR_DENOMINATOR_NAN = 'Ratio denominator is NaN' static ERROR_ARGUMENTS_NAN = 'Ratio numerator and denominator are NaN' static ERROR_NUMERATOR_NOT_INTEGER = 'Ratio numerator is not an integer' static ERROR_DENOMINATOR_NOT_INTEGER = 'Ratio denominator is not an integer' static ERROR_ARGUMENTS_NOT_INTEGER = 'Ratio numerator and denominator are not integers' static ERROR_DENOMINATOR_ZERO = 'Ratio denominator is zero' static ERROR_DIVISION_BY_ZERO = 'Ratio divided by ratio with zero numerator' static ERROR_BAD_PARSE_ARGUMENTS = 'Bad arguments passed to parse method' static ERROR_PARSE_OVERFLOW = 'Overflow during parse' static NUMBER_LIMIT = Math.pow( 2, 53 ) readonly _num: number readonly _den: number constructor( num = 0, den = 1, noChecks: boolean = false ) { if ( !noChecks ) { if ( num !== num ) { if ( den !== den ) { throw new Error( Ratio.ERROR_ARGUMENTS_NAN ) } else { throw new Error( Ratio.ERROR_NUMERATOR_NAN ) } } else if ( den !== den ) { throw new Error( Ratio.ERROR_DENOMINATOR_NAN ) } else if ( Math.floor( num ) !== num ) { if ( Math.floor( den ) !== den ) { throw new Error( Ratio.ERROR_ARGUMENTS_NOT_INTEGER ) } else { throw new Error( Ratio.ERROR_NUMERATOR_NOT_INTEGER ) } } else if ( Math.floor( den ) !== den ) { throw new Error( Ratio.ERROR_DENOMINATOR_NOT_INTEGER ) } else if ( den === 0 ) { throw new Error( Ratio.ERROR_DENOMINATOR_ZERO ) } } if ( num === 0 ) { this._num = 0 this._den = 1 } else { const num_ = num > 0 ? num : -num const den_ = den > 0 ? den : -den const positive = (num > 0 && den > 0) || (num < 0 && den < 0) const n = gcd( num_, den_ ) this._num = (positive ? num_ : -num_)/n this._den = den_/n } } add( {_num: num2, _den: den2}: Ratio ): Ratio { const {_num: num1, _den: den1} = this if ( den1 !== den2 ) { return new Ratio( num1*den2 + num2*den1, den1*den2, true ) } else { return new Ratio( num2 + num2, den1, true ) } } sub( {_num: num2, _den: den2}: Ratio ): Ratio { const {_num: num1, _den: den1} = this if ( den1 !== den2 ) { return new Ratio( num1*den2 - num2*den1, den1*den2, true ) } else { return new Ratio( num2 - num2, den1, true ) } } neg(): Ratio { return new Ratio( -this._num, this._den, true ) } mul( {_num: num2, _den: den2}: Ratio ): Ratio { return new Ratio( this._num*num2, this._den*den2, true ) } div( {_num: num2, _den: den2}: Ratio ): Ratio { if ( num2 === 0 ) { throw new Error( Ratio.ERROR_DIVISION_BY_ZERO ) } return new Ratio( this._num*den2, this._den*num2, true ) } eq( {_num, _den}: Ratio ): boolean { return this._num === _num && this._den === _den } lt( {_num,_den}: Ratio ): boolean { if ( this._den === _den ) { return this._num < _num } else { return this._num * _den < _num * this._den } } le( ratio: Ratio ): boolean { return this.eq( ratio ) || this.lt( ratio ) } ne( ratio: Ratio ): boolean { return !this.eq( ratio ) } gt( ratio: Ratio ): boolean { return !this.lt( ratio ) && !this.eq( ratio ) } ge( ratio: Ratio ): boolean { return !this.lt( ratio ) } toString(): string { if ( this._num === 0 ) { return 'Ratio (0)' } else if ( this._den === 1 ) { return `Ratio (${this._num.toString()})` } else { return `Ratio (${this._num.toString() + '/' + this._den.toString()})` } } valueOf(): number { return this._num / this._den } get num(): number { return this._num } get den(): number { return this._den } get int(): Ratio { const i = this._num < 0 ? Math.ceil( this._num/this._den ) : Math.floor( this._num/this._den ) return new Ratio( i, 1, true ) } get frac(): Ratio { return this.sub( this.int ) } static parse( s: number|string, overflowLimit = Ratio.NUMBER_LIMIT ): Ratio { const n = typeof s === 'number' ? s : parseFloat( s ) if ( n !== n ) { throw new Error( Ratio.ERROR_BAD_PARSE_ARGUMENTS ) } else if ( Math.floor( n ) === n ) { if ( n > overflowLimit ) { throw new Error( Ratio.ERROR_PARSE_OVERFLOW ) } return new Ratio( n, 1, true ) } else { const positive = n > 0 const n_ = positive ? n : -n let num1 = n_ let den2 = 1/n_ let den1 = 1 while (Math.floor(num1) !== num1 && Math.floor(den2) !== den2) { num1 *= 10 den2 *= 10 den1 *= 10 if ( num1 > overflowLimit || den2 > overflowLimit || den1 > overflowLimit ) { throw new Error( Ratio.ERROR_PARSE_OVERFLOW ) } } if ( Math.floor(num1) == num1 ) { return new Ratio( positive ? num1 : -num1, den1, true ) } else { return new Ratio( positive ? den1 : -den1, den2, true ) } } } }
typescript
<reponame>uidu-org/guidu import * as React from 'react'; import { HttpError } from '../../api/MentionResource'; import { DefaultAdvisedAction, DefaultHeadline, DifferentText, LoginAgain, } from '../../utils/i18n'; import { GenericErrorIllustration } from './GenericErrorIllustration'; import { MentionListAdviceStyle, MentionListErrorHeadlineStyle, MentionListErrorStyle, } from './styles'; export interface Props { error?: Error; } const advisedActionMessages = { '401': LoginAgain, '403': DifferentText, default: DefaultAdvisedAction, }; export default class MentionListError extends React.PureComponent<Props, {}> { /** * Translate the supplied Error into a message suitable for display in the MentionList. * * @param error the error to be displayed */ private static getAdvisedActionMessage( error: Error | undefined, ): React.ComponentType<{}> { if (error && error.hasOwnProperty('statusCode')) { const httpError = error as HttpError; return ( advisedActionMessages[httpError.statusCode.toString()] || advisedActionMessages.default ); } return advisedActionMessages.default; } render() { const { error } = this.props; const ErrorMessage = MentionListError.getAdvisedActionMessage(error); return ( <MentionListErrorStyle> <GenericErrorIllustration /> <MentionListErrorHeadlineStyle> <DefaultHeadline /> </MentionListErrorHeadlineStyle> <MentionListAdviceStyle> <ErrorMessage /> </MentionListAdviceStyle> </MentionListErrorStyle> ); } }
typescript
<filename>gpflow/utilities/__init__.py from .bijectors import * from .misc import * from .multipledispatch import Dispatcher from .traversal import *
python
After your addio - breathless, banal, the click, Of the telephone, I came out into Corso Vittorio, Emmanuele. Milan's glorious main street: Rows of posh shoe shops, buckles and toecaps, On tip toe behind thick glass; at the end of the, Boulevard the cathedral spires like the tails of, Old seahorses: rigid, brittle and upside down; Sunlight all round me in a hot, close envelope, With its smell of coffee and expensive briefcases; Words on the air from the English lesson I had, Just been teaching: "Sylvia never arrives late. Tom loves pop music and small dogs." This is the present simple for habit. It goes on, And on I was saying. Then down the road, They came: three bright dresses in yellow, pink, And peacock blue, blurring to blobs of floating, Colour inside the tears in my eyes. They jangled, The words, advanced unbearably bright towards, Me: Sylvia loves pop music. Tom never arrives, Late. Small dogs. Small dogs. Never. Loves.
english
Former wicket-keeper batsman Deep Dasgupta has praised the mental strength of the current Indian side, calling them one of the "toughest Indian teams ever. " Team India have earned a lot of praise from the cricketing world for the determination and fight they have shown in the last two Tests against Australia. Deep Dasgupta believes the Men in Blue have shown great character to overcome the numerous injury blows as well as bubble fatigue Down Under. The visitors will be missing Virat Kohli, Ravindra Jadeja, Mohammed Shami, Hanuma Vihari, KL Rahul and Umesh Yadav for the fourth Test against Australia, which starts on Friday. Jasprit Bumrah also remains a major doubt for the match. However, Deep Dasgupta has praised the toughness and fight Ajinkya Rahane's charges have shown so far. He said: "This is a very tough Indian team there are no two ways about it, especially the last two games. This is definitely one of the toughest Indian teams ever. We have to keep the conditions in mind, the series that is happening right now, almost 6 months of staying in the bubble and you have to factor in all of that. Toughness is not just about the sport that we see or the games that we are watching on air. This is a tough tour no doubt, mentally and physically. " Deep Dasgupta also spoke about how mentally tiring it must be for the Indian players to be without their friends and families for nearly six months. The majority of the India squad played in the IPL in Dubai before flying straight to Australia. "The biggest challenge is the mental fatigue (playing the final Test of a series). Even normally when you're there away from home for almost 2 months, anyways it's so tiring physically yes but mentally it's tiring. And all the Indian players, except for maybe Pujara and Vihari, they've been away for almost 6 months," Deep Dasgupta said. India's tour to Australia is almost over, with the team set to return home after the final Test in Brisbane. However, their next challenge is right around the corner, with England set to visit for a full-fledged tour next month.
english
<gh_stars>1-10 {"id": 12840, "name": "<NAME>", "qualified_name": "<NAME>", "examine": "What posseses me to carry these things around?", "members": false, "release_date": "2014-10-23", "quest": false, "weight": 1.0, "value": 1, "tradeable": false, "stackable": false, "noteable": false, "equipable": false, "tradeable_ge": false, "icon": "<KEY>", "wiki_url": "https://oldschool.runescape.wiki/w/Servant's_skull"}
json
<reponame>mayankbh/tanzu-framework import { Component, OnInit } from '@angular/core'; import { FormControl, Validators } from '@angular/forms'; import { takeUntil, debounceTime, distinctUntilChanged } from 'rxjs/operators'; import { TkgEventType } from '../../../../shared/service/Messenger'; import { ValidationService } from './../../wizard/shared/validation/validation.service'; import { StepFormDirective } from '../../wizard/shared/step-form/step-form'; import { Vpc } from '../../../../swagger/models/vpc.model'; import { AwsWizardFormService } from '../../../../shared/service/aws-wizard-form.service'; import Broker from 'src/app/shared/service/broker'; import { AwsField, VpcType } from "../aws-wizard.constants"; import { FieldMapUtilities } from '../../wizard/shared/field-mapping/FieldMapUtilities'; import { AwsVpcStepMapping } from './vpc-step.fieldmapping'; import { StepMapping } from '../../wizard/shared/field-mapping/FieldMapping'; @Component({ selector: 'app-vpc-step', templateUrl: './vpc-step.component.html', styleUrls: ['./vpc-step.component.scss'] }) export class VpcStepComponent extends StepFormDirective implements OnInit { defaultVpcHasChanged: boolean = false; existingVpcs: Array<Vpc>; loadingExistingVpcs: boolean = false; defaultVpcAddress: string = '10.0.0.0/16'; constructor(private validationService: ValidationService, private awsWizardFormService: AwsWizardFormService, private fieldMapUtilities: FieldMapUtilities) { super(); } ngOnInit() { super.ngOnInit(); this.fieldMapUtilities.buildForm(this.formGroup, this.formName, AwsVpcStepMapping); this.formGroup.get(AwsField.VPC_TYPE).valueChanges .pipe( distinctUntilChanged((prev, curr) => JSON.stringify(prev) === JSON.stringify(curr)), takeUntil(this.unsubscribe) ).subscribe((val) => { const existingVpcControl = this.formGroup.get(AwsField.VPC_EXISTING_ID); const existingVpcCidrControl = this.formGroup.get(AwsField.VPC_EXISTING_CIDR); if (val === VpcType.EXISTING) { Broker.messenger.publish({ type: TkgEventType.AWS_VPC_TYPE_CHANGED, payload: { vpcType: VpcType.EXISTING.toString() } }); if (this.existingVpcs && this.existingVpcs.length === 1) { existingVpcControl.setValue(this.existingVpcs[0].id); existingVpcCidrControl.setValue(this.existingVpcs[0].cidr); } this.formGroup.get(AwsField.VPC_NEW_CIDR).clearValidators(); this.clearControlValue(AwsField.VPC_NEW_CIDR); this.clearFieldSavedData(AwsField.VPC_NEW_CIDR); this.setExistingVpcValidators(); } else { existingVpcControl.setValue(''); existingVpcControl.clearValidators(); existingVpcControl.updateValueAndValidity(); existingVpcCidrControl.setValue(''); existingVpcCidrControl.clearValidators(); existingVpcCidrControl.updateValueAndValidity(); this.clearFieldSavedData(AwsField.VPC_EXISTING_CIDR); this.clearFieldSavedData(AwsField.VPC_EXISTING_ID); this.setNewVpcValidators(); Broker.messenger.publish({ type: TkgEventType.AWS_VPC_TYPE_CHANGED, payload: { vpcType: VpcType.NEW.toString() } }); } }); const vpcCidrs = [AwsField.VPC_NEW_CIDR, AwsField.VPC_EXISTING_CIDR]; vpcCidrs.forEach(vpcCidr => { this.formGroup.get(vpcCidr).valueChanges.pipe( distinctUntilChanged((prev, curr) => JSON.stringify(prev) === JSON.stringify(curr)), takeUntil(this.unsubscribe) ).subscribe((cidr) => { Broker.messenger.publish({ type: TkgEventType.NETWORK_STEP_GET_NO_PROXY_INFO, payload: { info: (cidr ? cidr + ',' : '') + '169.254.0.0/16' } }); }); }); /** * Whenever aws region selection changes, update AZ subregion */ Broker.messenger.getSubject(TkgEventType.AWS_REGION_CHANGED) .pipe(takeUntil(this.unsubscribe)) .subscribe(event => { if (this.formGroup.get(AwsField.VPC_EXISTING_ID)) { this.existingVpcs = []; this.clearControlValue(AwsField.VPC_EXISTING_ID); this.clearControlValue(AwsField.VPC_EXISTING_CIDR); } }); this.awsWizardFormService.getErrorStream(TkgEventType.AWS_GET_EXISTING_VPCS) .pipe(takeUntil(this.unsubscribe)) .subscribe(error => { this.errorNotification = error; }); this.awsWizardFormService.getDataStream(TkgEventType.AWS_GET_EXISTING_VPCS) .pipe(takeUntil(this.unsubscribe)) .subscribe((vpcs: Array<Vpc>) => { this.existingVpcs = vpcs; this.loadingExistingVpcs = false; }); // init vpc type to new Broker.messenger.publish({ type: TkgEventType.AWS_VPC_TYPE_CHANGED, payload: { vpcType: VpcType.NEW.toString() } }); this.registerOnValueChange(AwsField.VPC_NON_INTERNET_FACING, this.onNonInternetFacingVPCChange.bind(this)); this.initFormWithSavedData(); } onNonInternetFacingVPCChange(checked: boolean) { Broker.messenger.publish({ type: TkgEventType.AWS_AIRGAPPED_VPC_CHANGE, payload: checked === true }); } initFormWithSavedData() { if (!this.hasSavedData() || this.getSavedValue(AwsField.VPC_NEW_CIDR, '') !== '') { this.setNewVpcValidators(); } else { this.formGroup.get(AwsField.VPC_TYPE).setValue(VpcType.EXISTING); this.setExistingVpcValidators(); } super.initFormWithSavedData(); } /** * @method setNewVpcValidators * helper method to consolidate setting validators for new vpc fields and * re-subscribe to vpc value changes */ setNewVpcValidators() { this.defaultVpcHasChanged = false; this.formGroup.get(AwsField.VPC_NEW_CIDR).setValue(this.getSavedValue(AwsField.VPC_NEW_CIDR, this.defaultVpcAddress)); this.formGroup.get(AwsField.VPC_NEW_CIDR).setValidators([ Validators.required, this.validationService.noWhitespaceOnEnds(), this.validationService.isValidIpNetworkSegment() ]); } setExistingVpcValidators() { this.formGroup.get(AwsField.VPC_EXISTING_ID).setValidators([Validators.required]); this.formGroup.get(AwsField.VPC_EXISTING_ID).updateValueAndValidity(); } /** * @method existingVpcOnChange * helper method to manually set existing VPC CIDR read-only value, and * dispatch message to retrieve VPC subnets by VPC ID * @param existingVpcId */ existingVpcOnChange(existingVpcId: any) { const existingVpc: Array<Vpc> = this.existingVpcs.filter((vpc) => { return vpc.id === existingVpcId; }); if (existingVpc && existingVpc.length > 0) { this.formGroup.get(AwsField.VPC_EXISTING_CIDR).setValue(existingVpc[0].cidr); } else { // onlySelf onption changes value for the current control only. this.formGroup.get(AwsField.VPC_EXISTING_CIDR).setValue('', { onlySelf: true}); } Broker.messenger.publish({ type: TkgEventType.AWS_GET_SUBNETS, payload: { vpcId: existingVpcId } }); Broker.messenger.publish(({ type: TkgEventType.AWS_VPC_CHANGED })); } protected dynamicDescription(): string { const vpc = this.getFieldValue('vpc', true); const publicNodeCidr = this.getFieldValue('publicNodeCidr', true); const privateNodeCidr = this.getFieldValue('privateNodeCidr', true); const awsNodeAz = this.getFieldValue('awsNodeAz', true); if (vpc && publicNodeCidr && privateNodeCidr && awsNodeAz) { return `VPC CIDR: ${vpc}, Public Node CIDR: ${publicNodeCidr}, ` + `Private Node CIDR: ${privateNodeCidr}, Node AZ: ${awsNodeAz}`; } return 'Specify VPC settings for AWS'; } }
typescript
(function () { "use strict"; angular.module("myApp.directives", []) .directive("imgHolder", [function () { return { restrict: "A", link: function (scope, ele) { return Holder.run({ images: ele[0] }) } } }]) .directive("customPage", function () { return { restrict: "A", controller: ["$scope", "$element", "$location", function ($scope, $element, $location) { var addBg, path; return path = function () { return $location.path() }, addBg = function (path) { switch ($element.removeClass("body-wide body-lock"), path) { case "/404": case "/pages/404": case "/pages/500": case "/pages/signin": case "/pages/signup": case "/pages/forgot-password": return $element.addClass("body-wide"); case "/pages/lock-screen": return $element.addClass("body-wide body-lock") } }, addBg($location.path()), $scope.$watch(path, function (newVal, oldVal) { return newVal !== oldVal ? addBg($location.path()) : void 0 }) }] } }) .directive("uiColorSwitch", [function () { return { restrict: "A", link: function (scope, ele) { return ele.find(".color-option").on("click", function (event) { var $this, hrefUrl, style; if ($this = $(this), hrefUrl = void 0, style = $this.data("style"), "loulou" === style) hrefUrl = "css/main.css", $('link[href^="styles/main"]').attr("href", hrefUrl); else { if (!style) return !1; style = "-" + style, hrefUrl = "css/main" + style + ".css", $('link[href^="styles/main"]').attr("href", hrefUrl) } return event.preventDefault() }) } } }]) .directive("goBack", [function () { return { restrict: "A", controller: ["$scope", "$element", "$window", function ($scope, $element, $window) { return $element.on("click", function () { return $window.history.back() }) }] } }]) })();
javascript
{"_id":"55ee5e44b625e5cb89efe5fe","index":326,"guid":"a76e6889-e00d-4af6-8581-701be2103e69","isActive":false,"balance":"$51,590.32","picture":"http://placehold.it/32x32","age":41,"eyeColor":"brown","name":"<NAME>","gender":"male","company":"AVENETRO","email":"<EMAIL>","phone":"+1 (887) 582-3284","address":"283 Robert Street, Sunbury, Nebraska, 5298","about":"Ut reprehenderit voluptate non laborum anim ipsum dolor. Aliqua est anim in proident sunt consequat est quis sint. Ut aute incididunt mollit enim. Minim incididunt dolore ullamco fugiat cillum aliqua aute officia. Ex tempor ipsum ut irure nulla enim eiusmod duis dolore voluptate. Ex culpa incididunt sunt minim qui in sint aute. Sunt tempor deserunt consequat do nostrud.\r\n","registered":"2014-12-15T02:04:44 -07:00","tags":["non","aliqua","aliquip","aliqua","laborum","officia","quis"],"friends":[{"id":0,"name":"<NAME>"},{"id":1,"name":"<NAME>"},{"id":2,"name":"<NAME>"}],"greeting":"Hello, <NAME>! You have 2 unread messages.","favoriteFruit":"apple","location":{"latitude":80.987004,"longitude":-98.923366},"docFormat":"json","triples":[{"triple":{"subject":"/sample-data/data-326.json","predicate":"http://www.w3.org/2000/01/rdf-schema#label","object":"Bartlett Cervantes"}},{"triple":{"subject":"/sample-data/data-326.json","predicate":"http://www.w3.org/1999/02/22-rdf-syntax-ns#type","object":"http://xmlns.com/foaf/0.1/Person"}},{"triple":{"subject":"/sample-data/data-326.json","predicate":"http://xmlns.com/foaf/0.1/knows","object":"/sample-data/data-2590.json"}},{"triple":{"subject":"/sample-data/data-326.json","predicate":"http://xmlns.com/foaf/0.1/knows","object":"/sample-data/data-1615.json"}},{"triple":{"subject":"/sample-data/data-326.json","predicate":"http://xmlns.com/foaf/0.1/knows","object":"/sample-data/data-2743.json"}}]}
json
The 13th edition of the ICC ODI Cricket World Cup is in full swing, it started on October 5 and the final will be played on November 19, 2023. It is the first time that India is hosting the event independently, having co-hosted the event in 1987, 1996, and 2011. So far, India has played well and has qualified for semi-finals. On November 2, India defeated Sri Lanka by 302 runs in Mumbai finalising its position in the Semi-finals. The top three teams so far are India, South Africa and Australia. Rohit Sharma is at top on the list of most sixes among all the players in the ICC World Cup 2023. Virat Kohli is at the 2nd spot for most runs and at the third number for most fours. Dilshan Madushanka from Sri lanka is ranking at the top of most wickets list. From India Jasprit Bumrah is at the fifth position in most wickets among all players. Stay tuned to Mint for comprehensive coverage, in-depth analysis, and unforgettable moments. The 2023 ODI World Cup had a total of 10 teams - India, Afghanistan, Australia, England, Bangladesh, New Zealand, Pakistan, South Africa, the Netherlands and Sri Lanka. The first match of the 2023 World Cup was between reigning champions England and 2019 runners-up New Zealand in Ahmedabad on October 5 while India began their campaign against Australia in Chennai on October 8. The two semi-finals will be played in Mumbai and Kolkata, while the eagerly-anticipated final will be held at the Narendra Modi Stadium in Ahmedabad on November 19. The 2019 Cricket World Cup Final was a One Day International cricket match played at Lord's in London, England, on 14 July 2019 to determine the winner of the 2019 Cricket World Cup. It was contested by the runners-up from the previous tournament, New Zealand, and the host nation, England. It was the fifth time Lord's had hosted the Cricket World Cup Final, the most of any ground.
english
<reponame>LockateMe/hpka.js { "name": "hpka-browser", "version": "1.0.0", "description": "In-browser HPKA implementation", "main": "hpka.js", "directories": { "test": "test" }, "scripts": { "test": "echo \"Error: no test specified\" && exit 1" }, "repository": { "type": "git", "url": "git+https://github.com/LockateMe/hpka.js.git" }, "author": "<NAME>", "license": "MIT", "bugs": { "url": "https://github.com/LockateMe/hpka.js/issues" }, "homepage": "https://github.com/LockateMe/hpka.js#readme", "devDependencies": { "body-parser": "^1.15.0", "express": "^4.13.4", "hpka": "^0.4.1", "phantom": "^2.0.2", "sodium": "git+https://github.com/Mowje/node-sodium.git#3ed92bd41957bc0e0d30e753c4cb630d6617a6b4" } }
json
Bhubaneswar: Following the direction of Chief Minister Naveen Patnaik, Secretary to CM (5T) VK Pandian today visited Kendrapara district and reviewed the progress of various developmental projects. Pandian directed officials for expediting the progress of the projects. Secretary to CM (5T) today visited Kendrapara’s famous Baldevjew Temple, Dadhibamanjew Temple at Golara haat and Ram Chandi Temple at Ramnagar and offered pooja. Pandian discussed with Trust Board members and sevayats (servitors) of Baldevjew Temple for the temple’s development and beautification and ordered the district administration to prepare a DPR (detailed project report) for the same. Similarly, he ordered the district administration to prepare a DPR for the peripheral development and beautification of Dadhibamanjew and Ramchandi temples. Pandian visited the proposed Arcelor Mittal Nippon Steel Plant site at Adoi in Mahakalapada block. There, he discussed with various officials and reviewed the preliminary preparations of the project. He directed the Collector and plant officials to start work immediately. He reviewed the proposed extension of the Marshaghai-Jambu Canal Road. He advised for immediate implementation of the project to be built at a cost of Rs 10 crore. At the Kendrapada Circuit House, Pandian held discussions with about 130 civil society organizations and various associations and discussed the district’s development and problems people’s problems. He directed the Collector to immediately solve the problems that can be solved at the district level. He said that steps will be taken to solve problems at the level of the state government after proper discussion. Pandian first visited the RMC Complex in Kendrapara district and reviewed the construction work of 500 MT cold storage and ordered to complete it soon. Later, he visited the Sankalpa project at Jajang under Kendrapada Block. The golden grass craft project is being implemented here. He interacted with the members of self help groups and enquired about their work and problems. He advised the Handicrafts Department to take steps for proper marketing of various products made of Golden Grass and to involve more and more self help groups in this project. Later Pandian reviewed the fish farming project run by Jai Sankatmochan and Maa Sarala Women Self Help Group in Badmulbasant area. He advised the members get directly involved with the project and take it ahead. Later, 5T Secretary visited the State Institute of Plumbing Technology at Pattamundei. After interacting with the teachers and students, he advised the Principal to take steps so that the children get employment immediately after passing. Pandian inspected the progress of work of Indoor Stadium and Indoor Hall and advised to complete the work soon. At Golra Hut, he visited the Embroidery Stitching Unit run by the Utkal Rural Producers’ Group under Mission Shakti. He advised the district administration to extend more support at the district and state levels to facilitate the marketing of these goods. He visited a Mission Shakti Cafe in Derabish Block and interacted with members of women self-help groups there. He advised people to develop new types of food products and create a market for themselves by considering the needs of the people. In Derabish, he held discussions with around 600 district level, block level, and village panchayat level activists and gave suggestions to create more and more livelihood for the people. He said that there will be no shortage of funds for this sector. During this visit, Chief Minister’s Special Secretary Vineel Krishna, Kendrapara Collector and officials concerned of various departments and officials of the Chief Minister’s office were present.
english
Pitch Reports of ICC World Cup 2023 Stadiums: The ICC Men’s World Cup is just a phone call away, and the stadiums are busy dressing up for the mega event. The event will start rolling on October 5th this year, with the defending champions England facing their previous World Cup finalists New Zealand at the Narendra Modi Stadium in Ahmedabad. Prior to that, IceCric has decided to make detailed Pitch Reports of ICC World Cup 2023 Stadiums, and let’s delve into that. Narendra Modi Stadium is a bowler’s stadium and, in most cases, supports pacers. The deck provides a good amount of bounce, so those who hit the pitch harder could possibly dominate the batters. The M. Chinnaswamy Stadium in Bangalore has a good amount of grass, and because of this, the pitch normally supports fast bowlers. The deck also supports spin very well. MA Chidambaram Stadium is situated in Chennai, Tamil Nadu. The surface is normally dry and hard, which is favorable to batters. The stadium is the home ground of the Chennai Super Kings in the IPL. In one-day internationals, the pitch in Arun Jaitley Cricket Stadium in Delhi normally favors batters in the first innings. But as the game goes on, this advantage fades away. Pitch Reports of ICC World Cup 2023 Stadiums: The Himachal Pradesh Cricket Association Stadium is a bowling paradise. Batters normally struggle here, especially in the latter half of the game. So the team that bats second usually gets crumbled if the pace attack is good. The Bharat Ratna Shri Atal Bihari Vajpayee Ekana Cricket Stadium is sluggish, often twirly-whirly, to support spinners all the way. Batters normally struggle here. Rajiv Gandhi International Cricket Stadium is diverse, supporting batters at first. But in the second inning, the deck tends to support spinners and seamers. Maharashtra Cricket Association Stadium is a favorite for batters. It is seamless to score on the comparatively dry pitch. Eden Gardens is grassy and supports pacers at first. But it gets less difficult for batters when the game reaches a later stage. The Wankhede Stadium in Mumbai is flat and normally supports batters. Even the boundaries in the stadium are short, making it easier for batters to score runs. For more, CHECK OUT: Get ICC World Cup 2023 Live Score & ICC World Cup 2023 Team Squads along with ICC Men’s Cricket World Cup 2023 at IceCric.News and Follow for Live Updates – Twitter, Facebook & Instagram.
english
{ "extends": ["airbnb", "prettier"], "env": {"browser": true, "node": true}, "globals": {"document": false}, "rules": { "global-require": "off", "no-plusplus": "off", "react/jsx-no-bind": "off", "react/jsx-filename-extension": "off", "quotes": ["warn", "single"], "import/no-extraneous-dependencies": ["error", {"devDependencies": true}] } }
json
import { ISLOperation } from '../SLCardSearch/type' import { ISLFormItem } from '../SLFormItem/type' import { ISLTableConfig } from '../SLTable/type' export interface ISLCardTable extends ISLTableConfig { /** * 标题 * 可以传true,当只需要右侧时可以这么用,一般直接传文本 */ title?: string | boolean /** * 标题右侧的按钮,需要设置title */ headerBtns?: ISLOperation[] headerQuery?:ISLFormItem[] headerQueryDefault?:any handleQuery?:(queryParams:any)=>any }
typescript
When you have advanced breast cancer, your loved ones may have some things on their mind. Here are some of the most common questions and concerns. Tips on how to handle your work life after an advanced breast cancer diagnosis. Diagnosed with metastatic breast cancer? Learn more about your treatment options and what to expect.
english
{"vein.js":"sha256-F0g1yNzjE1BejZVYUyUWMllthGTcGsv7F4ujXZTieyU=","vein.min.js":"sha256-mW4wbludLyul1hOaZDVhQDlJCZcBruE/6J+Aa+2rR34="}
json
<filename>TvAssClient/app/src/main/java/com/example/yechy/tvass/injector/component/ServiceComponent.java<gh_stars>0 package com.example.yechy.tvass.injector.component; import android.content.Context; import com.example.yechy.tvass.injector.module.ServiceModule; import com.example.yechy.tvass.injector.qualifier.ContextLife; import com.example.yechy.tvass.injector.scope.PerService; import dagger.Component; /** * Created by yechy on 2017/4/3. */ @PerService @Component(modules = ServiceModule.class, dependencies = ApplicationComponent.class) public interface ServiceComponent { @ContextLife("Service") Context getServiceContext(); @ContextLife Context getApplicationContext(); }
java
{ "type": "project", "license": "MIT", "require-dev": { "squizlabs/php_codesniffer": "^3.5" } }
json
The war of words between Brazil’s MS Bank and Wise appears to have followed Wise securing its own FX broker license from Brazil’s Central Bank in January, meaning that its partnership with MS Bank would soon come to an end. The following month, without prior notice, MS Bank terminated its contract with Wise and informed customers that it was launching its own transfer service called CloudBreak. Without a banking partner, Wise was forced to temporarily suspend its Brazil corridor. On March 12, Wise was able to open its Brazilian real (BRL) to U.S. dollar (USD) corridor again, under its own license, and then things got hostile. In an email sent to customers the same day — and shared with TechCrunch earlier this week — MS Bank alleges that Wise had been committing fraud via customer accounts. Those allegations were also repeated in a YouTube video and text published on MS Bank’s own website and focussed on a discrepancy in the way transactions are registered on a customer’s account and with the Brazilian Central Bank. In a statement provided to TechCrunch, Wise says the accusations “have been timed to raise awareness of the launch of that ex-partner’s competing product”. Wise’s statement in full: In recent weeks Wise has been the subject of a smear campaign by a former business partner in Brazil. The accusations have been timed to raise awareness of the launch of that ex-partner’s competing product. We are not aware of any investigation or accusations against Wise by any regulator or other authority, either in Brazil or anywhere else. Wise maintains its commitment to the transparency and security of our operations for our more than 10 million customers around the world. We are certain that we are not responsible for any fraudulent or improper activity using customer data and/or funds. Wise is taking legal measures to address this matter. Early Stage is the premier “how-to” event for startup entrepreneurs and investors. You’ll hear firsthand how some of the most successful founders and VCs build their businesses, raise money and manage their portfolios. We’ll cover every aspect of company building: Fundraising, recruiting, sales, product-market fit, PR, marketing and brand building. Each session also has audience participation built-in — there’s ample time included for audience questions and discussion. Use code “TCARTICLE at checkout to get 20% off tickets right here.
english
<reponame>dakotagoldberg/react-native-sectioned-multi-select { "name": "react-native-sectioned-multi-select", "version": "0.8.1", "description": "a multi (or single) select component with support for sub categories, search, chips.", "main": "index.js", "directories": { "lib": "lib" }, "scripts": { "test": "echo \"Error: no test specified\" && exit 1" }, "devDependencies": { "babel-eslint": "^8.1.2", "eslint": "^4.15.0", "eslint-config-airbnb": "^16.1.0", "eslint-plugin-import": "^2.8.0", "eslint-plugin-jsx-a11y": "^6.0.3", "eslint-plugin-react": "^7.5.1" }, "peerDependencies": { "prop-types": "^15.6.0" }, "repository": { "type": "git", "url": "git+https://github.com/renrizzolo/react-native-sectioned-multi-select.git" }, "keywords": [ "select", "multiselect", "picker", "category", "react", "native" ], "author": "<NAME>", "license": "MIT", "bugs": { "url": "https://github.com/renrizzolo/react-native-sectioned-multi-select/issues" }, "homepage": "https://github.com/renrizzolo/react-native-sectioned-multi-select#readme" }
json
<gh_stars>0 { "name": "@omega/core", "version": "0.0.1", "main": "dist/index", "license": "MIT", "publishConfig": { "access": "public" }, "bin": { "omega": "../gen/bin/omega.js" }, "files": [ "dist", "dist/__assets__" ], "dependencies": { "pascal-case": "^3.1.1", "yup": "^0.29.3" }, "scripts": { "dev:update-snapshot": "jest --updateSnapshot", "dev:gen-assets": "node --require ts-node/register/transpile-only scripts/gen-assets.ts", "clean": "rimraf -rf dist", "compile": "tsc -p tsconfig.build.json", "build": "run-s dev:gen-assets clean compile", "test": "jest" }, "devDependencies": { "typescript-json-schema": "^0.43.0" } }
json
Industry body COAI on Tuesday expressed deep disappointment over TRAI’s recommendations on 5G and termed the spectrum pricing suggested by the regulator as “too high”. Given the recent reforms for telecom sector announced by the government, these recommendations are “one step backwards than forward” towards building a digitally connected India, COAI said in a statement. The Cellular Operators’ Association of India (COAI) is an apex industry body and its members include Bharti Airtel, Reliance Jio and Vodafone Idea. In a statement, COAI said it is disappointed by TRAI recommendations on 5G spectrum bands. The spectrum pricing recommended by TRAI is too high, it said. “Throughout the consultation process, industry had presented extensive arguments based on global research and benchmarks, for significant reduction in spectrum prices. “Industry recommended 90 per cent lower price, and to see only about 35-40 per cent reduction recommended in prices, therefore is deeply disappointing,” the association said.
english
What do you do when there's an earthquake?' asks Rakesh. Everyone in the Burman household has their own ideas, but when the tremors begin and things start to quake and crumble, they are all taken by surprise. Amidst the destruction, Rakesh's family stays strong. But will they survive the onslaught of yet another earthquake?
english
Inducing Apical Periodontitis in Mice Elisheva Goldman1,2, Eli Reich1, Itzhak Abramovitz*2, Michael Klutstein*1 1Institute of Dental Sciences, Faculty of Dental Medicine, Hebrew University of Jerusalem, 2Department of Endodontics, Hadassah Ein Kerem Medical Center Here, we present a protocol to locally induce apical periodontitis in mice. We show how to drill a hole in the mouse's tooth and expose its pulp, in order to cause local inflammation. Analysis methods to investigate the nature of this inflammation, such as micro-CT and histology, are also demonstrated. Retrospective MicroRNA Sequencing: Complementary DNA Library Preparation Protocol Using Formalin-fixed Paraffin-embedded RNA Specimens Olivier Loudig1,2,3, Christina Liu1,2, Thomas Rohan3, Iddo Z. Ben-Dov4 1Department of Research, Hackensack University Medical Center, 2Department of Medical Sciences, Seton Hall University, 3Department of Epidemiology and Population Health, Albert Einstein College of Medicine, 4Department of Nephrology and Hypertension, Hadassah - Hebrew University Medical Center Formalin-fixed paraffin-embedded specimens represent a valuable source of molecular biomarkers of human diseases. Here we present a laboratory-based cDNA library preparation protocol, initially designed with fresh frozen RNA, and optimized for the analysis of archived microRNAs from tissues stored up to 35 years.
english