content stringlengths 10 4.9M |
|---|
<filename>update_engine/common/utils_unittest.cc
//
// Copyright (C) 2012 The Android Open Source Project
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/... |
<reponame>m-labs/compiler-rt-lm32<gh_stars>0
//===-- tsan_mman.cc ------------------------------------------------------===//
//
// The LLVM Compiler Infrastructure
//
// This file is distributed under the University of Illinois Open Source
// License. See LICENSE.TXT for details.
//
//===----------... |
Kids these days. Just look at them. They've got those headphones in their ears and a gadget in every hand. They speak in tongues and text in code. They wear flip-flops everywhere. Does anyone really understand them?
Only some people do, or so it seems. They are experts who have earned advanced degrees, dissected data,... |
<gh_stars>0
export interface RelayNode {
id?: string | null;
__typename?: string | null;
}
export interface RelayConnection {
__typename?: string;
edges?: RelayEdge[];
pageInfo?: RelayPageInfo;
}
export interface RelayEdge {
__typename?: string | null;
cursor?: string | null;
node?: RelayNode | null;
... |
<reponame>plum-umd/pasket
from functools import partial
import logging
import lib.const as C
import lib.visit as v
from .. import util
from .. import sample
from ..meta import class_lookup
from ..meta.template import Template
from ..meta.clazz import Clazz
from ..meta.method import Method
from ..meta.field import Fie... |
<filename>server/mysite/studygroups/views.py
from django.shortcuts import render
from django.http import JsonResponse
from django.core import serializers
from students.models import Student
from classes.models import Course, CRN
from studygroups.models import Studygroup
import json
def gen_bounds():
"""
For... |
/**
* The collection of all modifications done to a graph (grouped by the rules that did them, divided into two groups: Insertions, Deletions)
* @author Jakub Daniel
*/
public class GraphModificationImpl implements GraphModification {
private static final long serialVersionUID = 1L;
private Map<DataNormaliza... |
package com.thinkaurelius.titan.graphdb.berkeleyje;
import com.thinkaurelius.titan.BerkeleyJeStorageSetup;
import com.thinkaurelius.titan.graphdb.SpeedComparisonPerformanceTest;
import com.thinkaurelius.titan.graphdb.configuration.GraphDatabaseConfiguration;
import org.apache.commons.configuration.Configuration;
/**
... |
<reponame>fakecoinbase/elastosslashElastos.ELA
// Copyright (c) 2017-2020 The Elastos Foundation
// Use of this source code is governed by an MIT
// license that can be found in the LICENSE file.
//
package state
import (
"bytes"
"encoding/hex"
"fmt"
"io"
"math"
"sync"
"github.com/elastos/Elastos.ELA/common"... |
/// Returns a new bounding box with a margin
pub fn margin(&self, margin: f32) -> BoundingBox {
BoundingBox {
origin: self.origin,
extents: self.extents + Vec3::new(0.5, 0.5, 0.5) * margin,
}
} |
Media playback is unsupported on your device Media caption There were chaotic scenes at the al-Shifa hospital in Gaza City, as Orla Guerin reports
Israel's prime minister has vowed the campaign in Gaza will continue "until quiet and security are returned to the citizens of Israel".
Benjamin Netanyahu issued the state... |
Beliefs about sexual behavior and other predictors of Papanicolaou smear screening among Latinas and Anglo women.
BACKGROUND
Latinas use cervical cancer prevention services less often than Anglo women.
OBJECTIVE
To assess whether beliefs about cervical cancer influence the use of Papanicolaou (Pap) smears among Lati... |
/*
This file is part of t8code.
t8code is a C library to manage a collection (a forest) of multiple
connected adaptive space-trees of general element types in parallel.
Copyright (C) 2015 the developers
t8code is free software; you can redistribute it and/or modify
it under the terms of the GNU General Pu... |
/**
* Extract database type from url string.
*
* @param url the url
* @return the string
*/
public static String extractDatabaseTypeFromUrl(String url) {
if (url == null) {
return "";
} else {
url = url.toLowerCase();
if (url.contains(":mysql"... |
<reponame>feiyyx/blog
const num2mon = {
'01': 'Jan',
'02': 'Feb',
'03': 'Mar',
'04': 'Apr',
'05': 'May',
'06': 'Jun',
'07': 'Jul',
'08': 'Aug',
'09': 'Sep',
'10': 'Oct',
'11': 'Nov',
'12': 'Dec',
};
const mon2num = {
'Jan': '01',
'Feb': '02',
'Mar': '03',
'Apr': '04',
'May': '05',
'... |
“Apparently, it’s not enough that UND’s administration is attacking the quality of education by cutting programs and experienced faculty and jacking class sizes,” University of North Dakota Assistant Professor Heidi Czerwiec opines in a letter to grandforksherald.com. “Now, we must also feel under physical attack as we... |
#include <bits/stdc++.h>
using namespace std;
#define PB push_back
#define MP make_pair
#define F first
#define S second
#define MAXI 1000001
typedef long long ll;
typedef vector<int> vi;
typedef pair<int,int>pi;
const ll inf = 1e18;
const int N = 1000000000+7... |
<reponame>Permify/vue-permify<filename>src/Permify.ts<gh_stars>1-10
// @ts-ignore
import Vue from "vue";
import { PermifyService } from "@permify/permify-service-js"
const LOCAL_STORAGE_KEY_USER_ID = "__permifyUserId";
export interface PluginOptions {
workspaceId: string,
publicToken: string
}
let instance:... |
<reponame>soybase/DroneImageScripts<filename>ImageProcess/CalculatePhenotypeSurf.py<gh_stars>1-10
# USAGE
# python /home/nmorales/cxgn/DroneImageScripts/ImageProcess/CalculatePhenotypeSurf.py --image_paths /folder/mypic1.png,/folder/mypic2.png --outfile_paths /export/mychoppedimages/outimage2.png,/export/mychoppedimage... |
Alignment of atmospheric mineral dust due to electric field
Optical polarimetry observations on La Palma, Canary Islands, during a Saharan dust episode show dichroic extinction indicating the presence of vertically aligned parti- cles in the atmosphere. Modelling of the extinction together with particle orientation in... |
// Prefix returns the prefix of a command, if event is a command
func (e *Event) Prefix() string {
_, span := global.Tracer("cacophony.dev/kit").Start(e.Context(), "event.Prefix")
defer span.End()
if e.prefix != "" {
return e.prefix
}
if e.GuildID == "" {
e.prefix = defaultPrefix
return e.prefix
}
prefix, ... |
/**
* Test samples using the provided bins. Values correspond to the bin upper
* limit. It is assumed the values span most of the distribution. Additional
* tests are performed using a region of the distribution sampled.
*
* @param values Bin upper limits
* @param factory Factory to create... |
About a month ago, after some amount of umming and ahhing, I bought a Nintendo 2DS.
I’d been interested in picking one up for a while, and the promise of price-drops around Black Friday had me checking every now and then. I’m not a massive gamer, but there are a handful of games on the system that looked appealing to ... |
/**
* Initialize a {@link Builder} to export the data from input data stream with {@link Row}s into iceberg table. We use
* {@link RowData} inside the sink connector, so users need to provide a {@link TableSchema} for builder to convert
* those {@link Row}s to a {@link RowData} DataStream.
*
* @param inp... |
// Ensures that Messages returns the messages set on the context and the error message
// when an error is set.
func TestMessagesWithError(t *testing.T) {
assert := assert.New(t)
req, _ := http.NewRequest("GET", "http://example.com/foo", nil)
writer := httptest.NewRecorder()
ctx := NewContext(nil, req, writer)
mes... |
export type Grouper<TInp> = (t: TInp) => string | undefined;
export type Aggregator<TStat> = (numbers: number[]) => TStat;
export function groupBy<T>(
objs: readonly T[],
grouper: Grouper<T>,
): Record<string, T[]> {
const grouped: Record<string, T[]> = {};
for (let i = 0; i < objs.length; i++) {
const obj... |
<reponame>flaranda/fn-screener-backend
import * as inversify from 'inversify';
import mongoose from 'mongoose';
import { ITransformer } from '../../../common/interfaces/ITransformer';
import { EntityMongo } from '../../../common/models/mongo/EntityMongo';
import { EntityMongoModelName } from '../../../common/models/mo... |
<reponame>rasidin/LimitEngineV2<gh_stars>0
/***********************************************************
LIMITEngine Header File
Copyright (C), LIMITGAME, 2012
-----------------------------------------------------------
@file LE_Camera2D.h
@brief Camera Class in 2D
@author minseob (https://github.com/rasidin)
--... |
def forward(self, features, labels=None):
bert_inputs = features["bert_input"]["feature"]
token_type_ids = features["token_type"]["feature"]
tagged_sub_token_idxs = features["tagged_sub_token_idxs"]["feature"]
num_tokens = features["num_tokens"]["feature"]
attention_mask = (bert_... |
<reponame>masud-technope/ACER-Replication-Package-ASE2017
/*******************************************************************************
* Copyright (c) 2007, 2011 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Publ... |
<filename>frontend/yang/schemas.service.ts<gh_stars>0
import { Injectable } from '@angular/core';
import { Http, Headers, Response, RequestOptions, URLSearchParams } from '@angular/http';
import { Observable } from 'rxjs/Observable';
import 'rxjs/add/operator/catch';
import 'rxjs/add/operator/map';
import { Schema } f... |
def parse_input_segment(ifile, player):
magic, len = struct.unpack("4sI", ifile.read(8))
if magic != b"FINP":
return None
inputbuf = bytearray(ifile.read(len))
vinput = ie.InputElement.GetRootAsInputElement(inputbuf, 0)
timestamp = datetime.fromtimestamp(vinput.Timestamp() / 1000000)
typ... |
def mi_sklearn(
trace,
var_names,
disc_features=False,
log2=True,
n_neigh=20
):
assert len(var_names)==2, "var_names must contain exactly two elements"
mi_nat = mutual_info_regression(trace.posterior[var_names[0]].values.flatten().reshape(-1,1),
... |
// Returns the inclusive left-most position adjust for clipped bases.
int32_t SamRecord::get0BasedUnclippedStart()
{
myStatus = SamStatus::SUCCESS;
if(myUnclippedStartOffset == -1)
{
parseCigar();
}
return(myRecordPtr->myPosition - myUnclippedStartOffset);
} |
package com.google.android.gms.internal;
import com.google.android.gms.common.internal.zzbo;
import java.util.concurrent.Callable;
import java.util.concurrent.FutureTask;
final class zzcgj<V> extends FutureTask<V> implements Comparable<zzcgj> {
private final String zzbsg;
private /* synthetic */ zzcgg zzbsh;
... |
import {injectable, inject} from 'inversify';
import {Inject} from '../common/Injectables';
import {Intent} from '../intents';
import {IntentResolution, Application} from '../../client/main';
import {FDC3Error, RaiseIntentError} from '../../client/errors';
import {Model} from '../model/Model';
import {APIToClientTopic... |
/**
* @secjs/orm
*
* (c) <NAME> <<EMAIL>>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
import { Model } from '../Model'
import { Is } from '@secjs/utils'
import { DatabaseContract } from '@secjs/database'
import { ModelQueryBui... |
/**
* Adds security groups to the master node of an existing EMR Cluster.
*
* @param request the EMR master security group add request
*
* @return the added EMR master security groups
* @throws Exception if there were any errors adding the security groups to the cluster master.
*/
pro... |
package cn.xy.leetcode.easy.linkedList;
import cn.xy.utils.ListNode;
/**
* @author XiangYu
* @create2021-04-06-21:33 请判断一个链表是否为回文链表。
* <p>
* 示例 1:
* <p>
* 输入: 1->2
* 输出: false
* 示例 2:
* <p>
* 输入: 1->2->2->1
* 输出: true
* 进阶:
* 你能否用 O(n) 时间复杂度和 O(1) 空间复杂度解决此题?
*/
public class A0234PalindromeLinkedList {
... |
import sys, math
readline = sys.stdin.readline
s = readline().split()[0]
def z_Func(s):
n = len(s)
l,r = 0,0
z = [0 for _ in range(n)]
for i in range(1,n):
if i <= r:
z[i] = min(r - i + 1,z[i - l])
while i + z[i] < n and s[z[i]] == s[i + z[i]]:
z[i] += ... |
#!/usr/bin/env python
from __future__ import annotations
import argparse
import contextlib
import datetime
import os
import pandas as pd
import select
import shlex
import subprocess as sp
import time
from pathlib import Path
from typing import Optional
def memory_t(value):
if isinstance(value,... |
/*
Flirt, an SWF rendering library
Copyright (c) 2004-2006 <NAME> <<EMAIL>>
All rights reserved.
http://www.opaque.net/flirt/
This code is distributed under the two-clause BSD license.
Read the LICENSE file or visit the URL above for details
*/
#ifndef DD_PLAYER_DRAWABLE_H_INCLUDED
#define DD_PLAYER_DRAWABLE_... |
#define VMA_IMPLEMENTATION
#ifdef _DEBUG
# define VMA_DEBUG_INITIALIZE_ALLOCATIONS 1
# define VMA_DEBUG_MARGIN 16
# define VMA_DEBUG_DETECT_CORRUPTION 1
#endif
#include <vk_mem_alloc.h>
#ifdef __WINDOWS__
#include <windows.h>
#include <vulkan/vulkan_win32.h>
#else
#define GLFW_INCLUDE_NONE
#define GLFW_INCLUDE_VULKAN
... |
<reponame>leavesster/flat-web
import React, { FC } from "react";
import { PluginProps } from "white-web-sdk";
/** simple wrapper to locate the element on the whiteboard */
export const Transformer: FC<Pick<PluginProps<unknown, unknown>, "size" | "scale">> = ({
size: { width, height },
scale,
children,
}) =... |
Sequential broncho-alveolar lavages reflect distinct pulmonary compartments: clinical and research implications in lung transplantation
Background Bronchoalveolar lavage (BAL) has proven to be very useful to monitor the lung allograft after transplantation. In addition to allowing detection of infections, multiple BAL... |
/*
* Licensed to Elasticsearch B.V. under one or more contributor
* license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright
* ownership. Elasticsearch B.V. licenses this file to you under
* the Apache License, Version 2.0 (the "License"); you may
* not u... |
<filename>openjdk/jdk/test/java/lang/management/ThreadMXBean/ThreadExecutionSynchronizer.java
/*
* Copyright (c) 2004, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
* under ... |
def snapshot(self) -> types.Labfile:
lf = self.file.copy(deep=True)
return lf |
<gh_stars>1-10
module Jaml.Generator.Ast
( astToJS
) where
import Text.Regex.Posix
import Jaml.Types
import Jaml.Generator.Util (bite)
import Jaml.Generator.Node (nodeToJS)
{-
All Generator funs generate (return) Strings of JavaScript.
-}
astToJS :: String -> Ast -> String
astToJS idPrefix (Ast depth node kids) =... |
A year ago Opec decided to maintain market share to battle competition from North America and the strategy worked, but not without some short-term pain
When the Organization of Petroleum Exporting Countries (Opec) meets Friday in Vienna, the cartel will be celebrating a victory of sorts, one that has cost its members ... |
// WithEmptyAzureCredentials sets azure credentials to empty values
func (sc *InstallationDataCreator) WithEmptyAzureCredentials() *InstallationDataCreator {
sc.installationData.AzureBrokerClientID = ""
sc.installationData.AzureBrokerClientSecret = ""
sc.installationData.AzureBrokerSubscriptionID = ""
sc.installati... |
/**
* Waits on sigint to be called then deals with it properly
*/
void* wait_on_sigint(void* thisServer) {
struct ServerData* server = (struct ServerData*) thisServer;
while (1) {
while (sem_wait(&sigintCalled)) {
if (errno == EINTR) {
errno = 0;
} else {
... |
/**
* PUT to update an existing entity.
*
* @param projectCode the code of the project in which to work
* @param code the code of the entity to update
* @param dtoToCreateOrUpdate the entity to update
* @return the ResponseEntity with status 200 (OK) and with body th... |
<filename>src/Logic/Expression/Internal.hs<gh_stars>0
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE BangPatterns #-}
{-# LANGUAGE TupleSections #-}
{-# LANGUAGE ViewPatterns #-}
module Logic.Expression.Internal(
Internal,
true, false,
variable,
xor, and, ands, xors, or, equals, implies, not, ors,
... |
<reponame>atla/owndnd
package entities
//Character header data is an abbrevated version of the character sheet
type Character struct {
*Entity
Name string `json:"name"`
Description string `json:"description"`
Race Race `json:"race"`
Class Class `json:"class"`
}
// NewCharacter creates a ne... |
CD4 T lymphocyte proliferative responses to hepatitis C virus (HCV) antigens in patients coinfected with HCV and human immunodeficiency virus who responded to anti-HCV treatment.
CD4 T lymphocyte proliferative responses to hepatitis C virus (HCV) antigens were evaluated before and during an anti-HCV regimen (interfero... |
// BumpMinor bumps the minor version of the caller
func (v *Version) BumpMinor() {
v.Minor++
v.Patch = 0
v.PreRelease = ""
v.BuildMetaData = ""
} |
<filename>linux-4.14.90-dev/linux-4.14.90/drivers/clk/meson/gxbb-aoclk.h
/*
* Copyright (c) 2017 BayLibre, SAS
* Author: <NAME> <<EMAIL>>
*
* SPDX-License-Identifier: GPL-2.0+
*/
#ifndef __GXBB_AOCLKC_H
#define __GXBB_AOCLKC_H
/* AO Configuration Clock registers offsets */
#define AO_RTI_PWR_CNTL_REG1 0x0c
#defi... |
def _get_narratives_from_wsobjs(self, params, token):
params = self._process_parameters(params)
ws_narrs = self.metrics_dbi.list_ws_narratives(
minT=params['minTime'], maxT=params['maxTime'])
ws_ids = [wnarr['workspace_id'] for wnarr in ws_narrs]
wsobjs = self.metrics_dbi.lis... |
// GetAction retrieves the action specified in manual override if any
func (s *ExperimentSpec) GetAction() ActionType {
if s.ManualOverride != nil {
return s.ManualOverride.Action
}
return ActionType("")
} |
/**
* This class abstract the 'step' related processing and let
* task script class process task specific logic.
*
* @author wangqi
*
*/
public class TaskStep {
private static final Logger logger = LoggerFactory.getLogger(TaskStep.class);
/**
* The Task script should call this method if the user's action... |
The idea that the multiverse is more akin to an art project than a science experiment (or an art experiment, if you’re so inclined) is one of those Occult themes that typically gets dismissed by both overly scientific and religious types alike, even though it quite inarguably resonates now more than ever. One of the st... |
<filename>src/image.rs<gh_stars>10-100
use crate::*;
pub struct Image {
pub width: u32,
pub height: u32,
pub format: vk::Format,
pub usage: vk::ImageUsageFlags,
pub aspect_flags: vk::ImageAspectFlags,
pub vk_image: vk::Image,
pub image_view: vk::ImageView,
pub opt_device_memory: Option<... |
// Copyright 2022 <NAME>.
// All rights reserved.
package main
import (
"reflect"
"sort"
"testing"
)
func TestLookupTable(t *testing.T) {
table := newLookupTable()
for _, f := range []struct {
id fileID
fprint []uint32
}{
{1, []uint32{0x44442222, 0x44441111, 0x33332222, 0x55553333}},
{2, []uint32{0... |
// String returns a textual (brief) representation of the Game
func (g Game) String() string {
return fmt.Sprintf("GameID:%d Champion Played: %d Won:%v KDA:%d/%d/%d",
g.ID,
g.Champion,
g.Stats.Win,
g.Stats.Kills,
g.Stats.Death,
g.Stats.Assists)
} |
/*
* Reset the TODR based on the time value; used when the TODR
* has a preposterous value and also when the time is reset
* by the stime system call. Also called when the TODR goes past
* TODRZERO + 100*(SECYEAR+2*SECDAY) (e.g. on Jan 2 just after midnight)
* to wrap the TODR around.
*/
void
resettodr()
{
#if N... |
/**
* Find and select the next searchable matching text.
*
* @param reverse look forwards or backwards
* @param pos the starting index to start finding from
* @return the location of the next selected, or -1 if not found
*/
private static int findNext(boolean reverse, int pos) {
... |
Investigation of Boundary-Layer Separation for Lifting Surfaces
Flow separation from lifting surfaces such as airfoils is undesirable as it deteriorates performance. For example, when airfoils that are designed for large Reynolds numbers are operated at smaller off-design Reynolds numbers, laminar separation can occur... |
def extract_tree(infile, folder):
def add_files(args, path, files):
folder = args['folder']
root = args['root']
for filename in files:
fullpath = os.path.join(path, filename)
relpath = os.path.relpath(fullpath, root)
if os.path.isdir(fullpath):
... |
import { Hook } from '@oclif/config'
import { getPluginInfo } from '../../commands/plugins/available'
import chalk from 'chalk'
const hook: Hook<'prerun'> = async function (opts) {
// Only for test purpouses to avoid an error of undefined object
if (!opts.Command || !opts.argv) return
// Only plugins command... |
/**
* Utility functions for doing superstep striping.
*
* We need to make sure that partitioning (which uses mod for distributing
* data across workers) is independent from striping itself. So we are using
* fastHash function below, taken from https://code.google.com/p/fast-hash/.
*/
public class StripingUtils {
... |
<reponame>LastKing/core
package kitmw
import (
"context"
"errors"
"fmt"
"google.golang.org/grpc/codes"
"github.com/DoNewsCode/core/unierr"
"github.com/go-kit/kit/endpoint"
)
// ErrorOption is an option that tunes the middleware returned by
// MakeErrorConversionMiddleware
type ErrorOption struct {
AlwaysHTTP... |
<reponame>vipoo/msxrc2014
#define __Z88DK_R2L_CALLING_CONVENTION
#include "spike-ide.h"
#include "msxdos.h"
#include "partition.h"
#include <stdarg.h>
#include <stddef.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
ioBuf buf;
int8_t result;
GPartInfo gResult;
void main() {
printf("spike-ide - ... |
Gad Rausing: Prehistoric boats and ships of North Western Europe. University of Lund: Institute of Archaeology, 1984. (Obtainable Liber Förlag, 205 10 Malmö, Sweden.) 144 pp., 45 figs. £5.50
in the seventeenth century and are now in the National Museum, Copenhagen, Neither the purpose of the book nor its intended audi... |
I say consensus, because among scientists there is no debate. Climate change is real, it is caused by us and it will cause devastating changes to our world if we don’t take decisive action.
Canada’s leaders all accept that climate change is real, and they speak a good game on the need to address it. But their actions,... |
<filename>src/token/TokenType.java
package token;
public enum TokenType {
// Single-character tokens.
LEFT_PAREN, RIGHT_PAREN, LEFT_BRACE, RIGHT_BRACE,
COMMA, DOT, MINUS, PLUS, SEMICOLON, SLASH, STAR,
// One or two character tokens.
BANG, BANG_EQUAL,
EQUAL, EQUAL_EQUAL,
GREATER, GREATER_EQ... |
/**
* Class for create the printer that write the converted content.
* @author Cosmin Duna
*
*/
public class ContentPrinterCreater {
/**
* Private constructor.
*/
private ContentPrinterCreater() {
throw new IllegalStateException("Utility class");
}
/**
* Create a ContentPrinter according to given... |
// process the dhcp packet before sending to server
private void processDhcpPacket(PacketContext context, DHCP dhcpPayload) {
ConnectPoint inPort = context.inPacket().receivedFrom();
Set<Interface> clientServerInterfaces = interfaceService.getInterfacesByPort(inPort);
if (clientServe... |
/**
* @fileName : EditClassStudentPresenter.java
*
* @description :
*
*
* @version : 1.0
*
* @date: 03-Jul-2015
*
* @Author tumbalam
*
* @Reviewer:
*/
public class EditClassStudentPresenter extends PresenterWidget<IsEditClassStudentView> implements EditClassStudentViewUiHandler{
private SimpleAsyncCallba... |
/**
* Created by fhuya on 1/5/15.
*/
public class FollowSplineAbove extends FollowAlgorithm {
private final MavLinkDrone drone;
@Override
public void processNewLocation(Location location) {
LatLong gcsLoc = new LatLong(location.getCoord());
double speed = location.getSpeed();
do... |
/** Returns highest element in tree and moves it to the root */
@NotNull
private SplayTreeNode last() {
if (right == null) {
splay();
return this;
}
return right.last();
} |
/**
* Event to keep making sure player names are highlighted red in clan chat, since the red name goes away frequently
*/
@Subscribe
public void onWidgetHiddenChanged(WidgetHiddenChanged widgetHiddenChanged)
{
if (client.getGameState() != GameState.LOGGED_IN
|| client.getWidget(WidgetInfo.LOGIN_CLICK_TO_PLA... |
<reponame>AstorgaIndustries/viernes
export class Ciudades {
private ciudades: Ciudad[] = [
{
name: 'Santiago',
lng: '-70.6666667',
lat: '-33.4500000',
},
{
name: '<NAME>',
lng: '-70.7166667',
lat: '-33.4166667',
},
{
name: '<NAME>',
lng: '-70.7000000... |
<reponame>josedr120/Java-Practice
package Assigments1;
import java.util.Scanner;
interface manipulate {
void get_total();
void DisplayMarklist();
}
public class Practice6 {
public static void main(String[] args) {
new MarkSheet().DisplayMarklist();
}
}
class Student {
private int Studen... |
package org.jboss.resteasy.plugins.providers.jaxb.json;
import org.jboss.resteasy.plugins.providers.jaxb.JAXBUnmarshalException;
import org.jboss.resteasy.plugins.providers.jaxb.json.i18n.Messages;
import java.io.IOException;
import java.io.Reader;
/**
* @author <a href="mailto:<EMAIL>"><NAME></a>
* @version $Revi... |
// ListCollectionNames implements the IDatabase.ListCollectionNames method.
func (d *Database) ListCollectionNames(ctx context.Context, filter interface{}, opts ...*options.ListCollectionsOptions) ([]string, error) {
res, err := d.ListCollections(ctx, filter, opts...)
if err != nil {
return nil, err
}
csr := res.... |
package descriptions
// UptimeDesc :
const UptimeDesc = `SSHes into a node and runs "uptime"
EXAMPLES
========
$ waggle uptime -n 004
{
"edge processor": [
" 17:05:43 up 8 days, 5 min, 1 user, load average: 0.81, 0.51, 0.40"
],
"node controller": [
" 17:05:41 up 54 days, 1:57, 1 user, load average... |
def _do_getversion(self, client, helper=False):
cachedVersion = None
if not self.opts.noGetVersionCache:
cachedVersion = self._get_cached_getversion(client)
if self.opts.noGetVersionCache or cachedVersion is None or (self.opts.GetVersionCacheOldestDate and cachedVersion['timestamp'] ... |
package shared
import (
"reflect"
kapi "k8s.io/kubernetes/pkg/api"
"k8s.io/kubernetes/pkg/client/cache"
"k8s.io/kubernetes/pkg/runtime"
"k8s.io/kubernetes/pkg/watch"
ocache "github.com/openshift/origin/pkg/client/cache"
quotaapi "github.com/openshift/origin/pkg/quota/api"
)
type ClusterResourceQuotaInformer ... |
import functools
from typing import Union, Optional, Tuple
import dace
from dace import SDFGState, nodes as nd, SDFG, dtypes, data as dt
from daceml.onnx import environments
from daceml.onnx.converters import clean_onnx_name
from daceml.onnx.forward_implementation_abc import ONNXForward
from daceml.onnx.nodes import ... |
<reponame>Alan-love/football-1
use crate::club::Club;
use chrono::prelude::*;
use chrono::Duration;
use chrono::NaiveDate;
use crate::league::{LeagueSettings, Season};
use super::DayMonthPeriod;
use actix_web::web::to;
use std::collections::{HashSet, HashMap};
use rand::prelude::SliceRandom;
use rand::thread_rng;
use c... |
/**
* @return Entry point to manage TenantAccess.
*/
public TenantAccess tenantAccess() {
if (this.tenantAccess == null) {
this.tenantAccess = new TenantAccessImpl(this);
}
return this.tenantAccess;
} |
#include <bits/stdc++.h>
using namespace std;
#define GO ios_base::sync_with_stdio(false);cin.tie(NULL);cout.tie(NULL);
//using ll = int64_t;
//pipe sign |
#define nln "\n"
typedef long long ll;
typedef unsigned long long ull;
int main()
{
GO
int n; cin>>n;
int cnt=0,num;
... |
Penetrating thoracic great vessel injury: impact of admission hemodynamics and preoperative imaging.
BACKGROUND
The management of penetrating great vessel (PGV) injury is challenging. Patients in shock require rapid evaluation, whereas in stable patients, imaging studies may optimize the surgical approach. We reviewed... |
def delete_node(node_name):
nodes = python.force_list(node_name)
objects_to_delete = list()
for node_found in nodes:
if not python.is_string(node_found):
node_found = node.get_name(node_found, fullname=True)
objects_to_delete.append(node_found)
return maya.cmds.delete(objects... |
package com.example.template4fx.control.dialog;
import com.example.template4fx.control.FXControl;
import com.example.template4fx.fx.Popup;
import javafx.beans.property.BooleanProperty;
import javafx.beans.property.SimpleBooleanProperty;
import javafx.beans.property.SimpleStringProperty;
import javafx.beans.property.St... |
// Copyright 2014, Additive Regularization of Topic Models.
#include "artm/core/master_component.h"
#include <algorithm>
#include <fstream> // NOLINT
#include <vector>
#include <set>
#include <sstream>
#include <utility>
#include "boost/algorithm/string.hpp"
#include "boost/algorithm/string/predicate.hpp"
#include ... |
def suspensions(self):
return sum([1 for susp in self.data['susp'] if susp is True]) |
<filename>enderio-decoration/src/main/java/com/enderio/decoration/common/block/painted/PaintedFenceGateBlock.java
package com.enderio.decoration.common.block.painted;
import com.enderio.decoration.common.init.DecorBlockEntities;
import net.minecraft.core.BlockPos;
import net.minecraft.world.level.block.EntityBlock;
im... |
// GetRIB writes the contents of the RIBs specified in the filter to msgCh. filter is a map,
// keyed by the gRIBI AFTType enumeration, if the value is set to true, the AFT is written
// to msgCh, otherwise it is skipped. The contents of the RIB are returned as gRIBI
// GetResponse messages which are written to the sup... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.