content stringlengths 10 4.9M |
|---|
<reponame>philconst/dynatrace-service<filename>internal/sli/dashboard/custom_charting_tile_processing.go
package dashboard
import (
"fmt"
"github.com/keptn-contrib/dynatrace-service/internal/adapter"
"github.com/keptn-contrib/dynatrace-service/internal/common"
"github.com/keptn-contrib/dynatrace-service/internal/d... |
/**
* Publish a message to /light topic
*/
public void publishPin(String time, String name) {
pin = StringUtil.getRandomNumberString();
String payload = pin + "-" + time + "-" + name;
byte[] encodedPayload = new byte[0];
try {
encodedPayload = payload.getBytes("UTF-... |
<reponame>jeffhain/jadecy
/*
* Copyright 2016 <NAME>
*
* 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 applica... |
// Copyright 2018 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include <errno.h>
#include <fcntl.h>
#include <stdlib.h>
#include <unistd.h>
#include <fbl/algorithm.h>
#include <fbl/string.h>
#include <fbl/unique_fd.h... |
<gh_stars>0
import React from 'react';
import { shallow } from 'enzyme';
import toJson from 'enzyme-to-json';
import IconButton from './IconButton';
describe('IconButton', () => {
const icon = (
<svg viewBox="0 0 64 64">
<path d="M58.245 12.152C54.943 5.81 49.81 3.455 44.231 4.91c-5.098 1.33-9.79 5.742-11... |
Coming to a Laundromat Near You: Video Game-controlled Washing Machines!
Doing laundry may no longer be the boring, meaningless task it’s been for the past several hundred centuries. In fact, successfully getting your digs clean in the future might depend on how well coordinated you are…and a handful of extra laundry ... |
<filename>src/ADempiere/modules/dashboard/store/Dashboard/actions.ts<gh_stars>1-10
import { ActionContext, ActionTree } from 'vuex'
import { requestListDashboards, DashboardState } from '@/ADempiere/modules/dashboard'
import { IRootState } from '@/store'
import { getCurrentRole } from '@/ADempiere/shared/utils/auth'
i... |
What are the factors affecting survival after autologous stem cell transplantation in patients with multiple myeloma?
Introduction: High-dose chemotherapy (HDC) and autologous stem cell transplantation(ASCT) still remains in the treatment of myeloma patients even during the period of new agents. Materials and Methods:... |
R + C Factors and Sacro Occipital Technique Orthopedic Blocking: a pilot study using pre and post VAS assessment.
INTRODUCTION
The concept of a systematic or predictive relationship between distant vertebral levels distinct from accumulative functional compensatory mechanisms, such as in scoliosis, has been perpetuate... |
/*
Copyright 2015 <NAME> L.P.
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 wri... |
class FileHierarchy:
"""
This class can be used to populate the calculated fields on the Files model (like project,
privileges, etc.). This class uses the query results returned by
:func:`build_file_hierarchy_query` that are returned in a specific way
(aka has the right queried columns).
"""
... |
def main():
sys.tracebacklimit = 0
args = commands()
for filename in args.filenames:
convert(filename, args.dos) |
def generate_bucket_http_url(bucket_config: BucketConfig, path_in_bucket: Union[None, str, PurePosixPath],
with_credentials: bool = False) -> urllib.parse.ParseResult:
url = generate_bucketfs_http_url(bucket_config.bucketfs_config, with_credentials)
if path_in_bucket is not None:
... |
Metformin in the treatment of polycystic ovary syndrome.
Polycystic ovary syndrome (PCOS) is one of the most frequent diseases that affects women in their reproductive age. The heterogeneity of PCOS makes not only the diagnosis but also the choice of an adequate treatment difficult. The biguanide, N, N' dimethyl-bigua... |
import { createStore } from "vuex";
import { Coin } from "@/types";
const allCoins = [
new Coin("bitcoin", "BTC", "Bitcoin", "icons/btc.png"),
new Coin("ethereum", "ETH", "Ethereum", "icons/eth.png"),
new Coin("cardano", "ADA", "Cardano", "icons/ada.jpg"),
new Coin("binancecoin", "BNB", "Binance Coin", "icons/... |
/////////////////////////////////////////////////////////////////////////////
// Name: src/palmos/menu.cpp
// Purpose: wxMenu, wxMenuBar, wxMenuItem
// Author: <NAME> - minimal working wxPalmOS port
// Modified by:
// Created: 10/12/04
// RCS-ID: $Id: menu.cpp,v 1.6 2005/07/01 19:36:56 ABX Exp ... |
'You don't need to look far to research' terrorists, Cumberbatch tells MTV News about playing the 'Into Darkness' villain.
Is he Khan? Is he Gary Mitchell? For now, he's John Harrison — and beyond that "name," the only thing we really know about Benedict Cumberbatch's "Star Trek Into Darkness" villain is that he is a ... |
#include <cstdio>
#include <iostream>
using namespace std;
typedef long long int Lint;
const int MAXN=100100;
int N,res;
Lint T;
Lint sum[MAXN];
int main(){
cin >> N >> T;
for( int a,i=1 ; i<=N ; i++ ){
scanf(" %d",&a);
sum[i]+=sum[i-1]+a;
}
int b=1,e=1;
while( e<=N ){
if( sum[e]-sum[b-1]<=T... |
def django_settings(default_settings_module='settings'):
denv = dot_env()
env.django_settings_module = denv.get('DJANGO_SETTINGS_MODULE', default_settings_module)
os.environ.setdefault('DJANGO_SETTINGS_MODULE', env.django_settings_module)
from django.conf import settings
import django
django.set... |
/**
* Parses the move string into int representation, with corresponding
* en passant, pawn start, castle, capture and promotion bits set.
*
* @param boardStructure
* @param moveStr
* @return int representation of move
* @throws NullPointerException if the BoardStructure is null
... |
def _get_json_pile(fn, container):
with open(fn, encoding='ascii') as f:
for line in f:
entry = container(*json.loads(line))
yield entry |
/// Use big-endian to ensure byte ordering.
impl From<Height> for HeightKey {
fn from(height: Height) -> HeightKey {
HeightKey(u64::to_be_bytes(height.get()))
}
} |
export { treatments } from './treatments-number';
export { mostInvolvedTeeth } from './most-involved-teeth';
export { genderPie } from './gender-pie';
export { ageBar } from './age-bar';
export { mostAppliedTreatments } from './most-applied-treatments';
export { appointmentsByDate } from './appointments-by-day';
export... |
<reponame>18580255110/Guns-1<filename>guns-rest/src/main/java/com/stylefeng/guns/rest/modular/education/requester/StudentAddRequester.java<gh_stars>0
package com.stylefeng.guns.rest.modular.education.requester;
import com.stylefeng.guns.modular.system.model.Attachment;
import com.stylefeng.guns.rest.core.SimpleRequ... |
<filename>projects/ngx-dynamic-dashboard/src/modules/shared/index.ts
// export * from "./shared-directives/dynamic-component-load.directive";
// export * from "./shared-directives/template-reference.directive";
// export * from "./shared-directives/validation.directive";
// export * from "./shared-services/shared-filte... |
class Solution:
def longestCommonPrefix(self, strs: List[str]) -> str:
n = len(strs)
# exceptions
if n == 0:
return ""
elif n == 1:
return strs[0]
# traverse the list
ans = strs[0]
ix = 1
while ix < n:
jx = ... |
// Connected flags a vehicle as connected
func (v vehicleList) Connected(vehicleID string) {
db.SetWithTTL(v.connectionKey(vehicleID), true, time.Second*5)
v.Publish(nil)
} |
<filename>src/main/java/com/ebstrada/formreturn/manager/ui/frame/ErrorLogFrame.java
package com.ebstrada.formreturn.manager.ui.frame;
import java.awt.GridBagConstraints;
import java.awt.GridBagLayout;
import java.awt.Insets;
import java.awt.Toolkit;
import java.awt.datatransfer.Clipboard;
import java.awt.datatransfer.... |
use crate::core::{
integrator::{Integrator, SamplerIntegrator, SamplerIntegratorBase},
geometry::{Bounds2i, Ray, Vector3f, Normal3},
camera::Camera,
sampler::{Sampler},
profiler::Profiler,
scene::Scene,
pbrt::{Spectrum, Float},
interaction::{Interaction, SurfaceInteraction},
material... |
<filename>graphics/shader/shader_set.hpp<gh_stars>0
#pragma once
#include "../api.h"
#include "../protos.h"
#include "../typedefs.h"
#include "shader.hpp"
namespace natus
{
namespace graphics
{
class NATUS_GRAPHICS_API shader_set
{
natus_this_typedefs( shader_set ) ;
priv... |
/* eslint-disable no-unused-expressions */
import { exec, ExecOptions } from 'child_process';
import { Uri } from 'vscode';
import { GnuPGGlobal } from './gnupgglobal';
import { GnuPGKey } from './gnupgkey';
import { i18n } from './i18n';
import { call, callStreaming, decrypt, decryptToFile, encrypt } from './lib/gpg';... |
<reponame>Muflhi01/apex<filename>apex/transformer/_data/__init__.py
from apex.transformer._data._batchsampler import MegatronPretrainingRandomSampler
from apex.transformer._data._batchsampler import MegatronPretrainingSampler
__all__ = [
"MegatronPretrainingRandomSampler",
"MegatronPretrainingSampler",
]
|
import React from 'react';
import H2 from '@govtnz/ds/build/react-ts/H2';
import P from '@govtnz/ds/build/react-ts/P';
import A from '@govtnz/ds/build/react-ts/A';
import './color-swatch.scss';
type Props = {
title: string;
};
const GetInTouch = ({ title }: Props) => (
<div className="g-inset-text g-inset-text--b... |
<reponame>netzeln/EatenList-CR<filename>app/calorie-calculate.component.ts
import {Component, EventEmitter} from 'angular2/core';
import {Eaten} from './eaten.model';
import {EatenDetailsComponent} from './eaten-details.component';
@Component({
selector: 'calorie-calc',
inputs: ['eatenFoods'],
// outputs:['count... |
//search through the specified EB, find the last PP that was written to, then get the latest PPOmap[] from it and return the latest LSImarker value
static unsigned short readmap_PPO(unsigned short EBI)
{
unsigned short LSImarker;
unsigned short PageAddr;
unsigned char i;
unsigned char SplitSize = 32;
if(EB... |
/**
* Frame input buffer for HTTP/2 blocking connections.
*
* @since 5.0
*/
public final class FrameInputBuffer {
private final BasicH2TransportMetrics metrics;
private final int maxFramePayloadSize;
private final byte[] buffer;
private int off;
private int dataLen;
FrameInputBuffer(final... |
package ca.corefacility.bioinformatics.irida.ria.integration.analysis;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
import java.util.List;
import java.util.Locale;
import java.util.Map;
import java.util.Set;
import org.junit.After;
import org.junit.Before;
import org.junit.... |
<filename>benches/benchmark.rs
use criterion::{criterion_group, criterion_main, Criterion, BenchmarkId, Throughput, black_box};
extern crate magnet_url;
use magnet_url::Magnet;
fn criterion_benchmark(c: &mut Criterion) {
let magnet = black_box("magnet:?xt=urn:btih:08ada5a7a6183aae1e09d831df6748d566095a10&dn=Sinte... |
def calculateC_sam(C0_sam, B):
layers = B.shape[0]
C_all = zeros((layers, 4), dtype='complex')
for l in range(layers):
C_all[l] = B[l] * C0_sam
return C_all |
def path_order (x, y):
if x == y:
return 0
xg = get_grist (x)
yg = get_grist (y)
if yg and not xg:
return -1
elif xg and not yg:
return 1
else:
if not xg:
x = feature.expand_subfeatures([x])
y = feature.expand_subfeatures([y])
... |
// FromCtx retrieves the current span from the context.
func FromCtx(ctx context.Context) *Span {
span := opentracing.SpanFromContext(ctx)
if span != nil {
if sp, ok := span.(*Span); ok {
return sp
}
return NewSpan(span)
}
return nil
} |
/**
* @file parms_viewer.h
* @author Zhongze Li
* @date Tue Oct 17 12:01:47 2006
*
* @brief Functions related to parms_Viewer objects.
*
*/
#ifndef _PARMS_VIEWER_H_
#define _PARMS_VIEWER_H_
#include <stdio.h>
#include <string.h>
#include "parms_sys.h"
PARMS_CXX_BEGIN
typedef struct parms_Viewer_ *par... |
<filename>3.7.0/lldb-3.7.0.src/test/functionalities/command_script/import/thepackage/TPunitB.py
def command(debugger, command, result, internal_dict):
result.PutCString(u"hello world B")
return None
|
a = input().split()
x = int(a[0])//int(a[2])+(int(a[0])%int(a[2]) != 0)
y = int(a[1])//int(a[2])+(int(a[1])%int(a[2]) != 0)
print(x*y)
|
/// Remove the marble at the given position relative to the active marble.
///
/// Positive offsets represent the clockwise direction
/// Negative offsets represent the counter-clockwise direction
fn remove(&mut self, offset: isize) -> usize {
assert!(!self.nodes.is_empty());
let to_remove = self.walk(s... |
package nssac.utility;
import java.io.BufferedWriter;
import java.io.FileWriter;
import java.io.IOException;
import java.nio.file.Files;
import java.nio.file.Paths;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
public class OutputProcessor {
public static void ma... |
// GetNode retrieves a nodegroup that represents all inherited values for a node
func (enc *ENC) GetNode(nodeName string) (*Nodegroup, error) {
var (
matchedNodegroups []*Nodegroup
)
chains, err := enc.GetChains(nodeName)
errCheck(err)
commonChain, alteredChains := enc.findCommonChain(chains)
masterNodegroup :=... |
You can now cast a ballot for your favourite type of marijuana — medical, that is.
Voting is now open for the first annual Canadian Cannabis Awards.
The contest, the first of its kind in Canada, wants members of the marijuana community to vote on their favourite smoke shop, marijuana strains and weed-related social m... |
/**
* Collection of settings for the fuzzing process
*/
public class FuzzerParam extends AbstractParam {
private static final String DEFAULT_CATEGORY = "fuzzer.defaultCategory";
private static final String THREADS_PER_SCAN = "fuzzer.threadPerScan";
private static final String DELAY_IN_MS = "fuzzer.delayInMs... |
Exploring AI & Machine Intelligence With Google, Facebook, MIT & More
By Yulia Ivanova, Summit Creator - RE•WORK
August 14, 2016
Following the success of the inaugural RE•WORK Machine Intelligence Summit in Berlin, the summit is now coming to New York!
On, over 200 attendees will come together in New York to hear k... |
import json
import os
import unittest
from monero.backends.offline import OfflineWallet
from monero.wallet import Wallet
from tests.utils import classproperty
class Tests(object):
@classproperty
def __test__(cls):
return issubclass(cls, unittest.TestCase)
def setUp(self):
self.subaddress... |
// String returns the name of the primary environment variable for the
// directory.
func (d Dir) String() string {
if d.env == "" {
panic("xdgdir.Dir.String() on zero Dir")
}
return d.env
} |
"""
The GUI of matlego 1.5.
"""
from PyQt5 import QtCore, QtGui, QtWidgets
import pyqtgraph.opengl as gl
from PyQt5.QtCore import pyqtSignal
import copy
class mytreewidget(QtWidgets.QTreeWidget):
""" To rewrite the Qtwidgets.QTreeWidget. """
def __init__(self):
super(mytreewidget, se... |
Systematic Analysis of Cluster Similarity Indices: How to Validate Validation Measures
Many cluster similarity indices are used to evaluate clustering algorithms, and choosing the best one for a particular task remains an open problem. We demonstrate that this problem is crucial: there are many disagreements among the... |
#include <bits/stdc++.h>
using namespace std;
#define f first
#define s second
#define mp make_pair
#define pb push_back
#define ll long long
bool myfun(long a,long b)
{
if(a>b)
return 1;
else
return 0;
}
long long findmin(int a[],int n,int vis[])
{
long long mn=INT_MAX,ind;
for(long long i=0;i<n;i++)
{
if(m... |
<gh_stars>0
#ifdef vxWorks
#include <vxWorks.h>
#endif
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include <ctype.h>
#include <tickLib.h>
#include "dbDefs.h"
#include "sCalcPostfix.h"
#include "sCalcPostfixPvt.h" /* need USES_STRING for testing */
#include "postfix.h"
long test_sCalcPostfix(char *pin... |
<reponame>wmc3721/jwt
import {Component} from '@angular/core';
import {IonicPage, NavController, NavParams} from 'ionic-angular';
import {LockFeatureConfirmPage} from '../lock-feature-confirm/lock-feature-confirm'
import {InOrOutDisplayFunctionSelectionPage} from '../in-or-out-display-function-selection/in-or-out-displ... |
/**
*
* Test Suite for Role Inheritance
*
*/
@RunWith(Suite.class)
@Suite.SuiteClasses({
// Propagation Tests
AccessPropagationNotInherited.class, //
AccessPropagation.class, //
DeletedAccessPropagation.class,
// Inheritance Tests
HorizontalInheritance.class, //
VerticalInheritance.class,... |
<filename>thread/incoming/deck/precon_deck.go
package deck
type PreconDeck struct {
Id string `json:"id"`
Name string `json:"name"`
Description string `json:"description"`
Format string `json:"format"`
ResourceId string `json:"resourceId"`
DeckTileId int `json:"deckTileId"`
... |
/**
* Replaces placeholder tags in notification meta in the subscription JSON string with valid
* notification meta.
*
* @param text JSON string containing replaceable tags
* @return Processed content
*/
private String replaceTagsInNotificationMeta(String text) {
text = text.replac... |
import { SFASRecordIdentification } from "../../sfas-integration/sfas-files/sfas-record-identification";
/**
* Common method that services importing data from SFAS must
* implement to process a SFAS record being imported.
*/
export interface SFASDataImporter {
/**
* Process the import process of a SFAS record.... |
<reponame>gasparakos/airbyte<gh_stars>0
import styled from "styled-components";
type IProps = {
center?: boolean;
};
export const H1 = styled.h1<IProps>`
font-style: normal;
font-weight: 500;
font-size: 28px;
line-height: 34px;
display: block;
text-align: ${props => (props.center ? "center" : "left")};
... |
A former GCHQ whistleblower has condemned plans by government lawyers to increase prison sentences and expand the definition of espionage for the digital age.
Katharine Gun, a former translator for the monitoring agency who leaked details of an operation to bug United Nations offices before the 2003 invasion of Iraq, ... |
from data_resource.shared_utils.log_factory import LogFactory
logger = LogFactory.get_console_logger("generator:resource-delete")
class ResourceDelete:
def delete_one(self, id, data_resource):
"""Delete a single object from the data model based on it's primary
key.
Args:
id ... |
// TCPPort returns a TCP corev1.ServicePort
func TCPPort(name string, port int32, targetPort intstr.IntOrString) corev1.ServicePort {
return corev1.ServicePort{
Name: name,
Port: port,
TargetPort: targetPort,
Protocol: corev1.ProtocolTCP,
}
} |
/*
* Function: Positions the kwin dialog either to the saved location
* or the center of the screen if no saved location.
*
* Parameters:
* hwnd - the window to center on the screen.
*/
static void
position_dialog(HWND hwnd)
{
int scrwidth, scrheight;
HDC hdc;
int x, y, cx, cy;
if (hwnd == NULL)
ret... |
// CopyInto copies from sv into target - it creates new slices and fills them
// with the pre-release and build IDs
func (sv SV) CopyInto(target *SV) {
target.Major = sv.Major
target.Minor = sv.Minor
target.Patch = sv.Patch
target.PreRelIDs = make([]string, len(sv.PreRelIDs))
copy(target.PreRelIDs, sv.PreRelIDs)
... |
def polygon_to_mask(poly, x, y, width, downsample):
mask = Image.new('L', (int(width/downsample), int(width/downsample)), 0)
mapp = mapping(poly)
if mapp['type'] == 'Polygon' or mapp['type'] == 'MultiPolygon':
coords = mapp['coordinates']
elif mapp['type'] == 'GeometryCollection':
coords... |
#include <iostream>
#include<set>
#define ll long long
using namespace std;
set<ll>V,H;
multiset<ll>mV,mH;
int main() {
ll h,v,n,x;
cin>>v>>h>>n;
char s;
V.insert(0);
V.insert(v);
H.insert(0);
H.insert(h);
mV.insert(v);
mH.insert(h);
for(int i=0;i<n;++i)
{
cin>>s>>x;
if(s=='H')
{
... |
<reponame>ahochul/MegaFS-webdav<gh_stars>10-100
/*
* Copyright 1999,2004 The Apache Software Foundation.
*
* 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/... |
def is_ignored(release_info, section_name="filter_ignore"):
release_name = release_info.release_name.lower()
if any((pattern.search(release_name) for pattern in pattern_season)):
return True
for key in app.config.options(section_name):
value = app.config.get_default(section_name, key, None)
... |
import pyper
import pandas as pd
# Python で CSV のデータを読み出す
wine = pd.read_csv("wine.csv")
# R のインスタンスを作る
r = pyper.R(use_pandas='True')
# Python のオブジェクトを R に渡す
r.assign("data", wine)
# R のソースコードを実行する
r("source(file='scatter.R')")
print("wine")
# R のコードを実行する
r("res1 = cor.test(data$WRAIN, data$LPRICE2)")
r("data1 = ... |
// NukeKeysForSecret blows away all keys for a given secret
// due to the fact that they all need to be updated when a secret is updated.
func NukeKeysForSecret(secret Secret) error {
_, err := db.DeleteFrom("keys").
Where("secret = $1", secret.ID).
Exec()
return err
} |
publicunofficial
YaBB God
Posts: 8,101
angryGreatnessYaBB GodPosts: 8,101
Re: DSA hits 25K members - Largest Socialist group in the country since WWII « Reply #11 on: August 06, 2017, 12:41:27 pm » Quote from: Famous Mortimer on August 06, 2017, 01:24:04 am Quote from: Badger on August 06, 2017, 01:00:20 am Quote f... |
The Anti Austerity Alliance (AAA) was refused a permit to collect money because of its involvement in protests which led to public disorder, a Garda chief superintendent has said.
Chief Supt Orla McPartlin said the alliance had been involved in protests which had led to arrests, and some of those arrested were members... |
package logplus
import (
"fmt"
)
type LogMessage struct {
message string
color Color
}
func NewFormattedLogMessage(color Color, format string, log ...interface{}) *LogMessage {
return &LogMessage{
message: fmt.Sprintf(format, log...),
color: color,
}
}
func NewLogMessage(color Color, log ...interface{}... |
More than 40 percent of homeowners seeking help from the Obama administration's flagship effort to rescue those at risk of foreclosure have dropped out of the program.
The latest report on the program suggests foreclosures could rise in the second half of the year and weaken an ailing housing market.
About 530,000 bo... |
<filename>packages/nest-lunr/dist/types/suggest/types/ignore-options.d.ts
export interface IgnoreOptions {
reset?: boolean;
}
|
def plot_recordings(self, data):
plot_recording(data.T, self.fs) |
async def content_as_bytes(self, max_connections=1):
stream = BytesIO()
await self.download_to_stream(stream, max_connections=max_connections)
return stream.getvalue() |
package project
import (
"bytes"
"fmt"
"os"
"path/filepath"
"runtime"
"github.com/pkg/errors"
"github.com/spf13/cobra"
"github.com/mutagen-io/mutagen/cmd"
"github.com/mutagen-io/mutagen/cmd/mutagen/daemon"
"github.com/mutagen-io/mutagen/cmd/mutagen/forward"
"github.com/mutagen-io/mutagen/cmd/mutagen/sync... |
<filename>node_modules/@ethersproject/hash/src.ts/_version.ts
export const version = "hash/5.4.0";
|
/**
* Receives data sent from GeocodeIntentService and updates the UI in MainActivity.
*/
@Override
protected void onReceiveResult(int resultCode, Bundle resultData) {
if (getActivity() == null) {
return;
}
Log.v(LOG_TAG, "onReceiveResul... |
<reponame>mmaquevice/harbor
import { async, ComponentFixture, TestBed } from '@angular/core/testing';
import { InlineAlertComponent } from "../../shared/inline-alert/inline-alert.component";
import { ImmutableTagComponent } from './immutable-tag.component';
import { ClarityModule } from '@clr/angular';
import { FormsM... |
def attach_application_by_name(self, name, msg=None):
self._module.action(Application.Action.ATTACH_APPLICATION_BY_NAME,
Application.create_value_container(name=name, msg=msg),
msg) |
import type { NextPage } from 'next';
import Head from 'next/head';
import { useRouter } from 'next/router';
import { useEffect, useState } from 'react';
import Wrapper from '../src/components/ui/Wrapper/wrapper';
import { useAuth } from '../src/hooks/useAuth';
import MapBoxContainer from '../src/components/containers/... |
#include<stdio.h>
#define INF 1000000000
#define NMAX 200
int dist[NMAX][NMAX], visit[NMAX], r[NMAX];
void Floyd(int);
int Dfs(int, int, int, int);
int main(void)
{
int i, j, v, e, vr, s, t, d, res;
scanf("%d %d %d", &v, &e, &vr);
for (i = 0; i < v; i++) {
for (j = 0; j < v; j++) {
dist[i][j] = ((i == ... |
#pragma once
#include <string>
#include <functional>
#include <msw/std/memory.hpp>
#include <rubetek/remote_link/channel.hpp>
#include <rubetek/remote_link/channel_set.hpp>
namespace rubetek {
namespace client {
struct remote_channels
: remote_channel_set<unique_client_id::type>
{
typedef... |
/**
* Create encoder corresponding to given codec.
* @param options Erasure codec options
* @return erasure encoder
*/
public static ErasureEncoder createEncoder(Configuration conf,
ErasureCodecOptions options) {
Preconditions.checkNotNull(conf);
Preconditions.checkNotNull(options);
String... |
<gh_stars>0
const cheerio = require('cheerio') as CheerioAPI
interface WallHaven {
url: string,
downloadUrl: string,
resolution: string
}
/**
* 根据 WallHaven 返回的 html 解析来获取搜索后的地址信息
* @param html
*/
export default function getWallHavenUrls (html: string): Array<WallHaven> {
const result: Array<WallHaven> = []... |
<gh_stars>0
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE TypeFamilies #-}
module Database (
Database (..),
ListTasks (..),
AddTask (..),
UpdateTask (..),
DeleteTasks (..),
tasks,
openDatabase
) where
import ViewModels.Task
import Data.Acid
import Data.SafeCopy
import Control.Monad.Reader (asks, ask)
i... |
French Fiasco
How does one describe the Model F1 French Grand Prix? In two words: Total chaos.
Felipe Massa and Pastor Maldonado qualified 7th and 11th on the grid for the race, respectively. The chaos already began before the five lights even went out, when McLaren did not show up for the third time this season. Mal... |
#include <stdio.h>
#include <set>
#include <vector>
#include <algorithm>
#include <utility>
#define ii std::pair<int,int>
#define iii std::pair<int,ii>
int main(void){
int n,k;
scanf("%d %d",&n,&k);
std::vector<int> seq;
std::vector<int> kk;
std::vector<int> nc;
std::vector<iii> lis;
s... |
<reponame>WANGXiaowen0904/Lance
#!/usr/bin/env python
descr = """Python module to compute the RESCAL tensor factorization"""
import os
import sys
from pkg_resources import require
DISTNAME = 'rescal'
DESCRIPTION = descr
LONG_DESCRIPTION = descr
MAINTAINER = '<NAME>',
MAINTAINER_EMAIL = '<EMAIL>',
URL = 'http://github... |
/**
* Defines behavior for a Parent Node that only accepts one input
*
* @author Mariusz Derezinski-Choo
*/
public abstract class UnaryOperationNode extends ParentNode {
/**
* Construct a UnaryOperationNode
* @param text the user-inputted text associated with this construction
*/
public Unary... |
/**
* Destroy an image buffer, freeing native resources that it uses
* (such as native memory used to hold a pixmap). In Desktop java,
* this does nothing, because this is left to the garbage collector.
* In GEM-based systems, it should be equivalent to
* DVBBufferedImage.dispose(). See
*... |
a, b, c, d = map(int, input().split())
alice = []
bob = []
for i in range(a, b+1):
alice.append(i)
#print(alice)
for j in range(c, d+1):
bob.append(j)
#print(bob)
count=0
for i in range(len(alice)):
if alice[i] in bob:
count += 1
if count>0:
print(count-1)
else:
print(count) |
A Mass-Change Model for the Estimation of Debris-Flow Runout, a Second Discussion: Conditions for the Application of the Rocket Equation
A geology colleague, Dr. Alan Benimoff, brought to my attention the article on debris flow in this journal written by Cannon and Savage (1988) and the subsequent discussion by Hungr ... |
// Write implements fs.FileOperations.Write.
func (s *SocketOperations) Write(ctx context.Context, _ *fs.File, src usermem.IOSequence, _ int64) (int64, error) {
f := &ioSequencePayload{ctx: ctx, src: src}
n, resCh, err := s.Endpoint.Write(f, tcpip.WriteOptions{})
if err == tcpip.ErrWouldBlock {
return 0, syserror.... |
use core::fmt;
use std::fmt::{Display, Formatter};
use crate::lexer::token_kinds::kind::TokenKind;
#[derive(Clone)]
pub struct Token {
pub kind: TokenKind,
pub line_number: u64,
pub column_number: u64,
}
impl Token {
pub fn new(kind: TokenKind, line_number: u64, column_number: u64) -> Self {
S... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.