code
stringlengths
3
1.05M
repo_name
stringlengths
4
116
path
stringlengths
3
942
language
stringclasses
30 values
license
stringclasses
15 values
size
int32
3
1.05M
'use strict'; const clone = require('../helpers/clone'); class SaveOptions { constructor(obj) { if (obj == null) { return; } Object.assign(this, clone(obj)); } } module.exports = SaveOptions;
aguerny/LacquerTracker
node_modules/mongoose/lib/options/saveOptions.js
JavaScript
mit
216
/* * Xero Payroll AU * This is the Xero Payroll API for orgs in Australia region. * * The version of the OpenAPI document: 2.2.4 * Contact: api@xero.com * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ package com.xero.models.payrollau; import java.util.Objects; import com.fasterxml.jackson.annotation.JsonProperty; import io.swagger.annotations.ApiModelProperty; import com.xero.api.StringUtil; /** HomeAddress */ public class HomeAddress { StringUtil util = new StringUtil(); @JsonProperty("AddressLine1") private String addressLine1; @JsonProperty("AddressLine2") private String addressLine2; @JsonProperty("City") private String city; @JsonProperty("Region") private State region; @JsonProperty("PostalCode") private String postalCode; @JsonProperty("Country") private String country; public HomeAddress addressLine1(String addressLine1) { this.addressLine1 = addressLine1; return this; } /** * Address line 1 for employee home address * * @return addressLine1 */ @ApiModelProperty( example = "123 Main St", required = true, value = "Address line 1 for employee home address") public String getAddressLine1() { return addressLine1; } public void setAddressLine1(String addressLine1) { this.addressLine1 = addressLine1; } public HomeAddress addressLine2(String addressLine2) { this.addressLine2 = addressLine2; return this; } /** * Address line 2 for employee home address * * @return addressLine2 */ @ApiModelProperty(example = "Apt 4", value = "Address line 2 for employee home address") public String getAddressLine2() { return addressLine2; } public void setAddressLine2(String addressLine2) { this.addressLine2 = addressLine2; } public HomeAddress city(String city) { this.city = city; return this; } /** * Suburb for employee home address * * @return city */ @ApiModelProperty(example = "St. Kilda", value = "Suburb for employee home address") public String getCity() { return city; } public void setCity(String city) { this.city = city; } public HomeAddress region(State region) { this.region = region; return this; } /** * Get region * * @return region */ @ApiModelProperty(value = "") public State getRegion() { return region; } public void setRegion(State region) { this.region = region; } public HomeAddress postalCode(String postalCode) { this.postalCode = postalCode; return this; } /** * PostCode for employee home address * * @return postalCode */ @ApiModelProperty(example = "3182", value = "PostCode for employee home address") public String getPostalCode() { return postalCode; } public void setPostalCode(String postalCode) { this.postalCode = postalCode; } public HomeAddress country(String country) { this.country = country; return this; } /** * Country of HomeAddress * * @return country */ @ApiModelProperty(example = "AUSTRALIA", value = "Country of HomeAddress") public String getCountry() { return country; } public void setCountry(String country) { this.country = country; } @Override public boolean equals(java.lang.Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } HomeAddress homeAddress = (HomeAddress) o; return Objects.equals(this.addressLine1, homeAddress.addressLine1) && Objects.equals(this.addressLine2, homeAddress.addressLine2) && Objects.equals(this.city, homeAddress.city) && Objects.equals(this.region, homeAddress.region) && Objects.equals(this.postalCode, homeAddress.postalCode) && Objects.equals(this.country, homeAddress.country); } @Override public int hashCode() { return Objects.hash(addressLine1, addressLine2, city, region, postalCode, country); } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class HomeAddress {\n"); sb.append(" addressLine1: ").append(toIndentedString(addressLine1)).append("\n"); sb.append(" addressLine2: ").append(toIndentedString(addressLine2)).append("\n"); sb.append(" city: ").append(toIndentedString(city)).append("\n"); sb.append(" region: ").append(toIndentedString(region)).append("\n"); sb.append(" postalCode: ").append(toIndentedString(postalCode)).append("\n"); sb.append(" country: ").append(toIndentedString(country)).append("\n"); sb.append("}"); return sb.toString(); } /** * Convert the given object to string with each line indented by 4 spaces (except the first line). */ private String toIndentedString(java.lang.Object o) { if (o == null) { return "null"; } return o.toString().replace("\n", "\n "); } }
SidneyAllen/Xero-Java
src/main/java/com/xero/models/payrollau/HomeAddress.java
Java
mit
5,057
rurc 0.8.x BETA ==================== Copyright (c) 2009-2013 Bitcoin Developers Copyright (c) 2014 Vertcoin Developers Copyright (c) 2015 rurc Developers Distributed under the MIT/X11 software license, see the accompanying file COPYING or http://www.opensource.org/licenses/mit-license.php. This product includes software developed by the OpenSSL Project for use in the [OpenSSL Toolkit](http://www.openssl.org/). This product includes cryptographic software written by Eric Young ([eay@cryptsoft.com](mailto:eay@cryptsoft.com)), and UPnP software written by Thomas Bernard. Intro --------------------- rurc is a free open source peer-to-peer electronic cash system that is completely decentralized, without the need for a central server or trusted parties. Users hold the crypto keys to their own money and transact directly with each other, with the help of a P2P network to check for double-spending. Setup --------------------- You need the Qt4 run-time libraries to run rurc-Qt. On Debian or Ubuntu: `sudo apt-get install libqtgui4` Unpack the files into a directory and run: - bin/32/rurc-qt (GUI, 32-bit) - bin/32/rurcd (headless, 32-bit) - bin/64/rurc-qt (GUI, 64-bit) - bin/64/rurcd (headless, 64-bit) See the documentation at the [rurc GitHub](https://github.org/rurc/rurc) for help and more information. Other Pages --------------------- - [Unix Build Notes](build-unix.md) - [OSX Build Notes](build-osx.md) - [Windows Build Notes](build-msw.md) - [Coding Guidelines](coding.md) - [Release Process](release-process.md) - [Release Notes](release-notes.md) - [Multiwallet Qt Development](multiwallet-qt.md) - [Unit Tests](unit-tests.md) - [Translation Process](translation_process.md)
rurc/rurc
doc/README.md
Markdown
mit
1,707
import React from 'react'; import ShiftKey from './ShiftKey'; import 'scss/vigenere.scss'; export default class VigenereKeys extends React.Component { constructor(props) { super(props); this.state = { keyword: '' }; this.keywordHandler = this.keywordHandler.bind(this); } keywordHandler(event) { this.setState({ keyword: event.target.value }) } render() { const { characters } = this.props; const charactersArray = characters.split(''); let { keyword } = this.state; keyword = keyword.toUpperCase(); return ( <div> <input type='text' value={keyword} onChange={this.keywordHandler} placeholder='Keyword' /> <div className='shift-keys'> { keyword.split('').map((char, index) => ( <div key={index} className='vigenere-char'> <p>{index}</p> <ShiftKey characters={charactersArray} noControls initialShift={charactersArray.indexOf(char)} /> </div> )) } </div> </div> ); } } export const EnglishVigenereKeys = props => ( <VigenereKeys characters='ABCDEFGHIJKLMNOPQRSTUVWXYZ' /> );
pshrmn/cryptonite
src/components/tools/VigenereKeys.js
JavaScript
mit
1,314
import * as React from 'react'; import ActiveButtons from '../active-buttons/ActiveButtons'; import { TextField, FlatButton } from 'material-ui'; import "./References.css"; import Styling from "../jobTheme"; class References extends React.Component<any, any>{ constructor(props: any) { super(props); //state of component this.state = { reference: 1, family: 1, selectedJson: this.props.jsonData, form: { references: [{ name: "", relation: "", telephone: "" }], friendRef: [{ name: "", relation: "" }] }, error: { references: [{ name: { nameError: false, msg: "" }, relation: { relationError: false, msg: "" }, telephone: { telephoneError: false, msg: "" } }], friendRef: [{ name: { nameError: false, msg: "" }, relation: { relationError: false, msg: "" }, }] } }; } //Getting reference form data from local storage componentWillMount() { if (localStorage.getItem('reference-form') !== null) { let data: any = localStorage.getItem('reference-form'); data = JSON.parse(data); let dataArray = this.state.error; let errorHistory: any = []; let friendHistory: any = []; data.references.map((arr: any) => { errorHistory.push({ name: { nameError: false, msg: "" }, relation: { relationError: false, msg: "" }, telephone: { telephoneError: false, msg: "" } }) }); data.friendRef.map((arr: any) => { friendHistory.push({ name: { nameError: false, msg: "" }, relation: { relationError: false, msg: "" }, }) }) dataArray.references = errorHistory; dataArray.friendRef = friendHistory; this.setState({ form: data, family: data.friendRef.length, reference: data.references.length, dataArray }) } } setError = (event: any, name: any, index: any) => { let current = this.state.error[event][index][name]; current[name + "Error"] = true; current["msg"] = name + " field is required"; console.log(current); this.setState(current) } referenceValidationCheck = (event: any, name: any, index: any) => { console.log() } //Handling next state handleNext = () => { var relationDone = false; var friendDone = false; this.state.form.references.map((arr: any, index: any) => { if (arr.name && arr.relation && arr.telephone) { relationDone = true; } else { if (!arr.name) { this.setError('references', 'name', index); } if (!arr.relation) { this.setError('references', 'relation', index); } if (!arr.telephone) { this.setError('references', 'telephone', index); } } }) this.state.form.friendRef.map((arr: any, index: any) => { if (arr.name && arr.relation) { friendDone = true; } else { if (!arr.name) { this.setError('friendRef', 'name', index); } if (!arr.relation) { this.setError('friendRef', 'relation', index); } } }) if (relationDone && friendDone) { this.props.handleNext("reference-form", this.state.form); } // if (this.state.form.street_address) { // } // else { // if (!this.state.form.street_address) { // this.setError('address') // } // } } //Handling previous state handlePrev = () => { this.props.handlePrev(); } //Handling input form state of the component handleTargetEvents = (arrayRef: string, ind: number, event?: any) => { let formRef = this.state.form; formRef[arrayRef][ind][event.target.name] = event.target.value; this.setState(formRef); } //Selecting json according to selected lanugage componentWillReceiveProps(nextProp: any) { this.setState({ selectedJson: nextProp.jsonData }) } //Making and managing multiple references lists handleReference = (action: string) => { let formRef = this.state.form["references"]; let formRefError = this.state.error['references']; if (action === "add") { formRef.push({ name: "", relation: "", telephone: "" }); formRefError.push({ name: { nameError: false, msg: "" }, relation: { relationError: false, msg: "" }, telephone: { telephoneError: false, msg: "" } }) this.setState({ reference: this.state.reference + 1, formRef, formRefError }) } else { formRef.pop(); formRefError.pop(); this.setState({ reference: this.state.reference - 1, formRef, formRefError }) } } //Making and managing multiple friend references list handleFriend = (action: string) => { let formRef = this.state.form["friendRef"]; let formRefError = this.state.error['friendRef']; if (action === "add") { formRef.push({ name: "", relation: "" }); formRefError.push({ name: { nameError: false, msg: "" }, relation: { relationError: false, msg: "" }, }) this.setState({ family: this.state.family + 1, formRef, formRefError }) } else { formRef.pop(); formRefError.pop(); this.setState({ family: this.state.family - 1, formRef, formRefError }) } } //Handling input state of component handleText = (arrRef: string, ind: number, event?: any) => { let formRef = this.state.form; formRef[arrRef][ind][event.target.name] = event.target.value; this.setState(formRef) } render() { const { name, relation, telephone, friends } = this.state.selectedJson; var reference = []; var family = []; for (let i = 0; i < this.state.reference; i++) { reference.push(<div key={i}> <TextField floatingLabelText={name} fullWidth className="text-area" value={this.state.form.references[i].name} errorStyle={Styling.errorMsg} errorText={this.state.error.references[i].name.nameError ? this.state.error.references[i].name.msg : null} name="name" style={{ marginRight: "50px" }} onChange={this.handleText.bind(this, "references", i)} onBlur={this.handleTargetEvents.bind(this, "references", i)} /> <TextField fullWidth className="text-area" floatingLabelText={relation} name="relation" errorStyle={Styling.errorMsg} errorText={this.state.error.references[i].relation.relationError ? this.state.error.references[i].relation.msg : null} value={this.state.form.references[i].relation} style={{ marginRight: "50px" }} onChange={this.handleText.bind(this, "references", i)} onBlur={this.handleTargetEvents.bind(this, "references", i)} /> <TextField fullWidth className="text-area" floatingLabelText={telephone} errorStyle={Styling.errorMsg} errorText={this.state.error.references[i].telephone.telephoneError ? this.state.error.references[i].telephone.msg : null} name="telephone" value={this.state.form.references[i].telephone} onChange={this.handleText.bind(this, "references", i)} onBlur={this.handleTargetEvents.bind(this, "references", i)} /> </div>); } for (let i = 0; i < this.state.family; i++) { family.push(<div key={i}> <TextField floatingLabelText={name} name="name" fullWidth className="text-area" errorStyle={Styling.errorMsg} errorText={this.state.error.friendRef[i].name.nameError ? this.state.error.friendRef[i].name.msg : null} style={{ marginRight: "50px" }} value={this.state.form.friendRef[i].name} onChange={this.handleText.bind(this, "friendRef", i)} onBlur={this.handleTargetEvents.bind(this, "friendRef", i)} /> <TextField floatingLabelText={relation} name="relation" fullWidth className="text-area" errorStyle={Styling.errorMsg} errorText={this.state.error.friendRef[i].relation.relationError ? this.state.error.friendRef[i].relation.msg : null} onChange={this.handleText.bind(this, "friendRef", i)} value={this.state.form.friendRef[i].relation} onBlur={this.handleTargetEvents.bind(this, "friendRef", i)} /> </div>); } return ( <div className="transportation-container"> <p className="title"> References </p> {reference}<br /> <div className="button-group"> <FlatButton className="hovered-class" style={Styling.addButton} labelStyle={Styling.addButtonLabel} label="Add" onClick={() => this.handleReference("add")} /> <FlatButton className="hovered-class" style={Styling.deleteButton} labelStyle={Styling.addButtonLabel} label="Remove" onTouchTap={() => this.state.reference === 1 ? null : this.handleReference("delete")} /> </div> <br /><br /><br /> <p className="title">{friends}</p> {family}<br /> <div className="button-group"> <FlatButton className="hovered-class" labelStyle={Styling.addButtonLabel} style={Styling.addButton} label="Add" onClick={() => this.handleFriend("add")} /> <FlatButton className="hovered-class" labelStyle={Styling.addButtonLabel} style={Styling.deleteButton} label="Remove" onTouchTap={() => this.state.family === 1 ? null : this.handleFriend("delete")} /> </div> <br /><br /><br /><br /> <ActiveButtons handleNext={() => this.handleNext()} handlePrev={() => this.handlePrev()} /> </div> ); } } export default References;
TYLANDER/interspan
client/src/components/job-form/references/References.tsx
TypeScript
mit
11,774
/* * For a detailed explanation regarding each configuration property, visit: * https://jestjs.io/docs/configuration */ module.exports = { // All imported modules in your tests should be mocked automatically // automock: false, // Stop running tests after `n` failures // bail: 0, // The directory where Jest should store its cached dependency information // cacheDirectory: "/private/var/folders/n6/2v5277g578510lpgbl7zbf6r0000gn/T/jest_dx", // Automatically clear mock calls and instances between every test clearMocks: true, // Indicates whether the coverage information should be collected while executing the test collectCoverage: true, // An array of glob patterns indicating a set of files for which coverage information should be collected // collectCoverageFrom: undefined, // The directory where Jest should output its coverage files coverageDirectory: 'coverage', // An array of regexp pattern strings used to skip coverage collection // coveragePathIgnorePatterns: [ // "/node_modules/" // ], // Indicates which provider should be used to instrument code for coverage coverageProvider: 'v8', // A list of reporter names that Jest uses when writing coverage reports // coverageReporters: [ // "json", // "text", // "lcov", // "clover" // ], // An object that configures minimum threshold enforcement for coverage results // coverageThreshold: undefined, // A path to a custom dependency extractor // dependencyExtractor: undefined, // Make calling deprecated APIs throw helpful error messages // errorOnDeprecated: false, // Force coverage collection from ignored files using an array of glob patterns // forceCoverageMatch: [], // A path to a module which exports an async function that is triggered once before all test suites // globalSetup: undefined, // A path to a module which exports an async function that is triggered once after all test suites // globalTeardown: undefined, // A set of global variables that need to be available in all test environments // globals: {}, // The maximum amount of workers used to run your tests. Can be specified as % or a number. E.g. maxWorkers: 10% will use 10% of your CPU amount + 1 as the maximum worker number. maxWorkers: 2 will use a maximum of 2 workers. // maxWorkers: "50%", // An array of directory names to be searched recursively up from the requiring module's location // moduleDirectories: [ // "node_modules" // ], // An array of file extensions your modules use // moduleFileExtensions: [ // "js", // "jsx", // "ts", // "tsx", // "json", // "node" // ], // A map from regular expressions to module names or to arrays of module names that allow to stub out resources with a single module // moduleNameMapper: {}, // An array of regexp pattern strings, matched against all module paths before considered 'visible' to the module loader // modulePathIgnorePatterns: [], // Activates notifications for test results // notify: false, // An enum that specifies notification mode. Requires { notify: true } // notifyMode: "failure-change", // A preset that is used as a base for Jest's configuration // preset: undefined, // Run tests from one or more projects // projects: undefined, // Use this configuration option to add custom reporters to Jest // reporters: undefined, // Automatically reset mock state between every test // resetMocks: false, // Reset the module registry before running each individual test // resetModules: false, // A path to a custom resolver // resolver: undefined, // Automatically restore mock state between every test // restoreMocks: false, // The root directory that Jest should scan for tests and modules within // rootDir: undefined, // A list of paths to directories that Jest should use to search for files in // roots: [ // "<rootDir>" // ], // Allows you to use a custom runner instead of Jest's default test runner // runner: "jest-runner", // The paths to modules that run some code to configure or set up the testing environment before each test // setupFiles: [], // A list of paths to modules that run some code to configure or set up the testing framework before each test // setupFilesAfterEnv: [], // The number of seconds after which a test is considered as slow and reported as such in the results. // slowTestThreshold: 5, // A list of paths to snapshot serializer modules Jest should use for snapshot testing // snapshotSerializers: [], // The test environment that will be used for testing // testEnvironment: "jest-environment-node", // Options that will be passed to the testEnvironment // testEnvironmentOptions: {}, // Adds a location field to test results // testLocationInResults: false, // The glob patterns Jest uses to detect test files // testMatch: [ // "**/__tests__/**/*.[jt]s?(x)", // "**/?(*.)+(spec|test).[tj]s?(x)" // ], // An array of regexp pattern strings that are matched against all test paths, matched tests are skipped // testPathIgnorePatterns: [ // "/node_modules/" // ], // The regexp pattern or array of patterns that Jest uses to detect test files // testRegex: [], // This option allows the use of a custom results processor // testResultsProcessor: undefined, // This option allows use of a custom test runner // testRunner: "jest-circus/runner", // This option sets the URL for the jsdom environment. It is reflected in properties such as location.href // testURL: "http://localhost", // Setting this value to "fake" allows the use of fake timers for functions such as "setTimeout" // timers: "real", // A map from regular expressions to paths to transformers // transform: undefined, // An array of regexp pattern strings that are matched against all source file paths, matched files will skip transformation // transformIgnorePatterns: [ // "/node_modules/", // "\\.pnp\\.[^\\/]+$" // ], // An array of regexp pattern strings that are matched against all modules before the module loader will automatically return a mock for them // unmockedModulePathPatterns: undefined, // Indicates whether each individual test should be reported during the run // verbose: undefined, // An array of regexp patterns that are matched against all source file paths before re-running tests in watch mode // watchPathIgnorePatterns: [], // Whether to use watchman for file crawling // watchman: true, };
C2FO/gofigure
jest.config.js
JavaScript
mit
6,865
using System.Collections.Generic; using System.Threading.Tasks; using AzureStorage; using Common; using Core.Finance; using Microsoft.WindowsAzure.Storage.Table; namespace AzureRepositories.Finance { public class TraderBalanceEntity : TableEntity, ITraderBalance { public static string GeneratePartitionKey(string traderId) { return traderId; } public static string GenerateRowKey(string currency) { return currency.ToUpper(); } public string TraderId => PartitionKey; public string Currency => RowKey; public double Amount { get; set; } public static TraderBalanceEntity Create(string traderId, string currency) { return new TraderBalanceEntity { PartitionKey = GeneratePartitionKey(traderId), RowKey = GenerateRowKey(currency) }; } } public class BalanceRepository : IBalanceRepository { private readonly INoSQLTableStorage<TraderBalanceEntity> _tableStorage; public BalanceRepository(INoSQLTableStorage<TraderBalanceEntity> tableStorage) { _tableStorage = tableStorage; } public async Task<IEnumerable<ITraderBalance>> GetAsync(string traderId) { var partitionKey = TraderBalanceEntity.GeneratePartitionKey(traderId); return await _tableStorage.GetDataAsync(partitionKey); } public async Task ChangeBalanceAsync(string traderId, string currency, double delta) { var partitionKey = TraderBalanceEntity.GeneratePartitionKey(traderId); var rowKey = TraderBalanceEntity.GenerateRowKey(currency); var entity = await _tableStorage.ReplaceAsync(partitionKey, rowKey, itm => { itm.Amount += delta; return itm; }); if (entity != null) return; entity = TraderBalanceEntity.Create(traderId, currency); entity.Amount = delta; await _tableStorage.InsertAsync(entity); } } }
LykkeCity/MarketPlace
AzureRepositories/Finance/BalanceRepository.cs
C#
mit
2,167
'use strict'; import UserNotificationConstants from '../constants/UserNotificationConstants'; import UserNotificationService from '../services/UserNotificationService'; const _initiateRequest = (type, data) => { return { 'type': type, 'data': data }; }; const _returnResponse = (type, data) => { return { 'type': type, 'data': data, 'receivedAt': Date.now() }; }; export default { getByUserId: (id) => { return (dispatch) => { dispatch(_initiateRequest(UserNotificationConstants.INITIATE_USER_NOTIFICATION_REQUEST)); return UserNotificationService.getByUserId(criteria).then((response) => { dispatch(_returnResponse(UserNotificationConstants.GET_USER_NOTIFICATIONS, response.results)); return response.pagination; }); }; }, search: (criteria) => { return (dispatch) => { dispatch(_initiateRequest(UserNotificationConstants.INITIATE_USER_NOTIFICATION_REQUEST)); return UserNotificationService.search(criteria).then((response) => { dispatch(_returnResponse(UserNotificationConstants.GET_USER_NOTIFICATIONS, response.results)); return response.pagination; }); }; }, create: (data) => { return (dispatch) => { dispatch(_initiateRequest(UserNotificationConstants.INITIATE_USER_NOTIFICATION_REQUEST)); return UserNotificationService.create(data).then((userNotification) => { dispatch(_returnResponse(UserNotificationConstants.CREATE_USER_NOTIFICATION, userNotification)); return userNotification; }); }; }, update: (id, data) => { return (dispatch) => { dispatch(_initiateRequest(UserNotificationConstants.INITIATE_USER_NOTIFICATION_REQUEST)); return UserNotificationService.update(id, data).then((userNotification) => { dispatch(_returnResponse(UserNotificationConstants.UPDATE_USER_NOTIFICATION, userNotification)); return userNotification; }); }; }, remove: (id) => { return (dispatch) => { dispatch(_initiateRequest(UserNotificationConstants.INITIATE_USER_NOTIFICATION_REQUEST, id)); return UserNotificationService.remove(id).then((response) => { dispatch(_returnResponse(UserNotificationConstants.REMOVE_USER_NOTIFICATION, id)); return response; }); }; } };
zdizzle6717/battle-comm
src/actions/UserNotificationActions.js
JavaScript
mit
2,189
# `.Q.en` **References:** - https://code.kx.com/q/kb/splayed-tables/ - https://code.kx.com/q/wp/symfiles/ - https://code.kx.com/q/kb/compacting-hdb-sym/ ------------------------------------------------------------------------------------------------------- ## Enumarating symbol columns
denglert/manuals
q/namespaces/dotQ/en.md
Markdown
mit
293
<?php declare(strict_types=1); namespace App\Command; use App\Model\Page\PageRepository; use Symfony\Component\Console\Command\Command; use Symfony\Component\Console\Input\InputArgument; use Symfony\Component\Console\Input\InputInterface; use Symfony\Component\Console\Output\OutputInterface; class AddPageCommand extends Command { /** * @var PageRepository */ private $pageRepository; public function __construct(PageRepository $pageRepository) { $this->pageRepository = $pageRepository; parent::__construct(); } protected function configure() { $this ->setName('app:add-page') ->setDescription('Add new page to the list') ->addArgument('pageId', InputArgument::REQUIRED, 'ID of the Facebook Page'); } protected function execute(InputInterface $input, OutputInterface $output) { $pageId = $input->getArgument('pageId'); if ($this->pageRepository->findById($pageId) !== null) { $this->pageRepository->addPage($pageId); $output->writeln(sprintf('Page "%s" added.', $pageId)); } else { $output->writeln(sprintf('Page "%s" already exists.', $pageId)); } } }
sustmi/fb-post-downloader
src/Command/AddPageCommand.php
PHP
mit
1,246
<?php /** * This file is part of the Spryker Demoshop. * For full license information, please view the LICENSE file that was distributed with this source code. */ namespace Pyz\Zed\Collector\Business; use Generated\Shared\Transfer\LocaleTransfer; use Orm\Zed\Touch\Persistence\SpyTouchQuery; use Spryker\Zed\Collector\Business\Exporter\Reader\ReaderInterface; use Spryker\Zed\Collector\Business\Exporter\Writer\TouchUpdaterInterface; use Spryker\Zed\Collector\Business\Exporter\Writer\WriterInterface; use Spryker\Zed\Collector\Business\Model\BatchResultInterface; use Symfony\Component\Console\Output\OutputInterface; interface CollectorFacadeInterface { /** * @param \Orm\Zed\Touch\Persistence\SpyTouchQuery $baseQuery * @param \Generated\Shared\Transfer\LocaleTransfer $localeTransfer * @param \Spryker\Zed\Collector\Business\Model\BatchResultInterface $result * @param \Spryker\Zed\Collector\Business\Exporter\Reader\ReaderInterface $dataReader * @param \Spryker\Zed\Collector\Business\Exporter\Writer\WriterInterface $dataWriter * @param \Spryker\Zed\Collector\Business\Exporter\Writer\TouchUpdaterInterface $touchUpdater * @param \Symfony\Component\Console\Output\OutputInterface $output * * @return void */ public function runSearchProductCollector( SpyTouchQuery $baseQuery, LocaleTransfer $localeTransfer, BatchResultInterface $result, ReaderInterface $dataReader, WriterInterface $dataWriter, TouchUpdaterInterface $touchUpdater, OutputInterface $output ); /** * @param \Orm\Zed\Touch\Persistence\SpyTouchQuery $baseQuery * @param \Generated\Shared\Transfer\LocaleTransfer $localeTransfer * @param \Spryker\Zed\Collector\Business\Model\BatchResultInterface $result * @param \Spryker\Zed\Collector\Business\Exporter\Reader\ReaderInterface $dataReader * @param \Spryker\Zed\Collector\Business\Exporter\Writer\WriterInterface $dataWriter * @param \Spryker\Zed\Collector\Business\Exporter\Writer\TouchUpdaterInterface $touchUpdater * @param \Symfony\Component\Console\Output\OutputInterface $output * * @return void */ public function runStorageCategoryNodeCollector( SpyTouchQuery $baseQuery, LocaleTransfer $localeTransfer, BatchResultInterface $result, ReaderInterface $dataReader, WriterInterface $dataWriter, TouchUpdaterInterface $touchUpdater, OutputInterface $output ); /** * @param \Orm\Zed\Touch\Persistence\SpyTouchQuery $baseQuery * @param \Generated\Shared\Transfer\LocaleTransfer $localeTransfer * @param \Spryker\Zed\Collector\Business\Model\BatchResultInterface $result * @param \Spryker\Zed\Collector\Business\Exporter\Reader\ReaderInterface $dataReader * @param \Spryker\Zed\Collector\Business\Exporter\Writer\WriterInterface $dataWriter * @param \Spryker\Zed\Collector\Business\Exporter\Writer\TouchUpdaterInterface $touchUpdater * @param \Symfony\Component\Console\Output\OutputInterface $output * * @return void */ public function runStorageNavigationCollector( SpyTouchQuery $baseQuery, LocaleTransfer $localeTransfer, BatchResultInterface $result, ReaderInterface $dataReader, WriterInterface $dataWriter, TouchUpdaterInterface $touchUpdater, OutputInterface $output ); /** * @param \Orm\Zed\Touch\Persistence\SpyTouchQuery $baseQuery * @param \Generated\Shared\Transfer\LocaleTransfer $localeTransfer * @param \Spryker\Zed\Collector\Business\Model\BatchResultInterface $result * @param \Spryker\Zed\Collector\Business\Exporter\Reader\ReaderInterface $dataReader * @param \Spryker\Zed\Collector\Business\Exporter\Writer\WriterInterface $dataWriter * @param \Spryker\Zed\Collector\Business\Exporter\Writer\TouchUpdaterInterface $touchUpdater * @param \Symfony\Component\Console\Output\OutputInterface $output * * @return void */ public function runStorageProductAbstractCollector( SpyTouchQuery $baseQuery, LocaleTransfer $localeTransfer, BatchResultInterface $result, ReaderInterface $dataReader, WriterInterface $dataWriter, TouchUpdaterInterface $touchUpdater, OutputInterface $output ); /** * @param \Orm\Zed\Touch\Persistence\SpyTouchQuery $baseQuery * @param \Generated\Shared\Transfer\LocaleTransfer $localeTransfer * @param \Spryker\Zed\Collector\Business\Model\BatchResultInterface $result * @param \Spryker\Zed\Collector\Business\Exporter\Reader\ReaderInterface $dataReader * @param \Spryker\Zed\Collector\Business\Exporter\Writer\WriterInterface $dataWriter * @param \Spryker\Zed\Collector\Business\Exporter\Writer\TouchUpdaterInterface $touchUpdater * @param \Symfony\Component\Console\Output\OutputInterface $output * * @return void */ public function runStorageRedirectCollector( SpyTouchQuery $baseQuery, LocaleTransfer $localeTransfer, BatchResultInterface $result, ReaderInterface $dataReader, WriterInterface $dataWriter, TouchUpdaterInterface $touchUpdater, OutputInterface $output ); /** * @param \Orm\Zed\Touch\Persistence\SpyTouchQuery $baseQuery * @param \Generated\Shared\Transfer\LocaleTransfer $localeTransfer * @param \Spryker\Zed\Collector\Business\Model\BatchResultInterface $result * @param \Spryker\Zed\Collector\Business\Exporter\Reader\ReaderInterface $dataReader * @param \Spryker\Zed\Collector\Business\Exporter\Writer\WriterInterface $dataWriter * @param \Spryker\Zed\Collector\Business\Exporter\Writer\TouchUpdaterInterface $touchUpdater * @param \Symfony\Component\Console\Output\OutputInterface $output * * @return void */ public function runStorageTranslationCollector( SpyTouchQuery $baseQuery, LocaleTransfer $localeTransfer, BatchResultInterface $result, ReaderInterface $dataReader, WriterInterface $dataWriter, TouchUpdaterInterface $touchUpdater, OutputInterface $output ); /** * @param \Orm\Zed\Touch\Persistence\SpyTouchQuery $baseQuery * @param \Generated\Shared\Transfer\LocaleTransfer $localeTransfer * @param \Spryker\Zed\Collector\Business\Model\BatchResultInterface $result * @param \Spryker\Zed\Collector\Business\Exporter\Reader\ReaderInterface $dataReader * @param \Spryker\Zed\Collector\Business\Exporter\Writer\WriterInterface $dataWriter * @param \Spryker\Zed\Collector\Business\Exporter\Writer\TouchUpdaterInterface $touchUpdater * @param \Symfony\Component\Console\Output\OutputInterface $output * * @return void */ public function runStorageAttributeMapCollector( SpyTouchQuery $baseQuery, LocaleTransfer $localeTransfer, BatchResultInterface $result, ReaderInterface $dataReader, WriterInterface $dataWriter, TouchUpdaterInterface $touchUpdater, OutputInterface $output ); }
spryker/demoshop
src/Pyz/Zed/Collector/Business/CollectorFacadeInterface.php
PHP
mit
7,206
<?xml version="1.0" ?><!DOCTYPE TS><TS language="ar" version="2.1"> <context> <name>AboutDialog</name> <message> <location filename="../forms/aboutdialog.ui" line="+14"/> <source>About CM_CapitalName</source> <translation>عن البلاك كوين</translation> </message> <message> <location line="+39"/> <source>&lt;b&gt;CM_CapitalName&lt;/b&gt; version</source> <translation>جزء البلاك كوين</translation> </message> <message> <location line="+41"/> <source>Copyright © 2009-2014 The Bitcoin developers Copyright © 2012-2014 The NovaCoin developers Copyright © 2014 The BlackCoin developers Copyright © 2015 The CM_CapitalName developers</source> <translation type="unfinished"/> </message> <message> <location line="+15"/> <source> This is experimental software. Distributed under the MIT/X11 software license, see the accompanying file COPYING or &lt;a href=&quot;http://www.opensource.org/licenses/mit-license.php&quot;&gt;http://www.opensource.org/licenses/mit-license.php&lt;/a&gt;. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit (&lt;a href=&quot;https://www.openssl.org/&quot;&gt;https://www.openssl.org/&lt;/a&gt;) and cryptographic software written by Eric Young (&lt;a href=&quot;mailto:eay@cryptsoft.com&quot;&gt;eay@cryptsoft.com&lt;/a&gt;) and UPnP software written by Thomas Bernard.</source> <translation type="unfinished"/> </message> </context> <context> <name>AddressBookPage</name> <message> <location filename="../forms/addressbookpage.ui" line="+14"/> <source>Address Book</source> <translation>كتاب العنوان</translation> </message> <message> <location line="+22"/> <source>Double-click to edit address or label</source> <translation>أنقر على الماوس مرتين لتعديل العنوان</translation> </message> <message> <location line="+24"/> <source>Create a new address</source> <translation>انشأ عنوان جديد</translation> </message> <message> <location line="+10"/> <source>Copy the currently selected address to the system clipboard</source> <translation>قم بنسخ العنوان المختار لحافظة النظام</translation> </message> <message> <location line="-7"/> <source>&amp;New Address</source> <translation>&amp;عنوان جديد</translation> </message> <message> <location line="-43"/> <source>These are your CM_CapitalName addresses for receiving payments. You may want to give a different one to each sender so you can keep track of who is paying you.</source> <translation>هذه هي عناوين البلاك كوين لاستقبال الدفعات. يمكن أن تعطي عنوان مختلف لكل مرسل من اجل أن تتابع من يرسل لك.</translation> </message> <message> <location line="+53"/> <source>&amp;Copy Address</source> <translation>انسخ العنوان</translation> </message> <message> <location line="+7"/> <source>Show &amp;QR Code</source> <translation>اظهار &amp;رمز الاستجابة السريعة</translation> </message> <message> <location line="+7"/> <source>Sign a message to prove you own a CM_CapitalName address</source> <translation>التوقيع علي رسالة لاثبات بانك تملك عنوان البلاك كوين</translation> </message> <message> <location line="+3"/> <source>Sign &amp;Message</source> <translation>وقع &amp;الرسالة</translation> </message> <message> <location line="+17"/> <source>Delete the currently selected address from the list</source> <translation>خذف العنوان الحالي التي تم اختياره من القائمة</translation> </message> <message> <location line="-10"/> <source>Verify a message to ensure it was signed with a specified CM_CapitalName address</source> <translation>تحقق من الرسالة لتثبت بانه تم توقيعه بعنوان بلاك كوين محدد</translation> </message> <message> <location line="+3"/> <source>&amp;Verify Message</source> <translation>&amp;تحقق الرسالة</translation> </message> <message> <location line="+10"/> <source>&amp;Delete</source> <translation>&amp;أمسح</translation> </message> <message> <location filename="../addressbookpage.cpp" line="+65"/> <source>Copy &amp;Label</source> <translation>نسخ &amp;التسمية</translation> </message> <message> <location line="+2"/> <source>&amp;Edit</source> <translation>تعديل</translation> </message> <message> <location line="+250"/> <source>Export Address Book Data</source> <translation>تصدير بيانات كتاب العناوين</translation> </message> <message> <location line="+1"/> <source>Comma separated file (*.csv)</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Error exporting</source> <translation>خطا في التصدير</translation> </message> <message> <location line="+0"/> <source>Could not write to file %1.</source> <translation>لا يمكن الكتابة الي الملف %1.</translation> </message> </context> <context> <name>AddressTableModel</name> <message> <location filename="../addresstablemodel.cpp" line="+145"/> <source>Label</source> <translation>وصف</translation> </message> <message> <location line="+0"/> <source>Address</source> <translation>عنوان</translation> </message> <message> <location line="+36"/> <source>(no label)</source> <translation>(لا وصف)</translation> </message> </context> <context> <name>AskPassphraseDialog</name> <message> <location filename="../forms/askpassphrasedialog.ui" line="+26"/> <source>Passphrase Dialog</source> <translation>حوار كلمة المرور</translation> </message> <message> <location line="+21"/> <source>Enter passphrase</source> <translation>ادخل كلمة المرور</translation> </message> <message> <location line="+14"/> <source>New passphrase</source> <translation>عبارة مرور جديدة</translation> </message> <message> <location line="+14"/> <source>Repeat new passphrase</source> <translation>ادخل الجملة السرية مرة أخرى</translation> </message> <message> <location line="+33"/> <source>Serves to disable the trivial sendmoney when OS account compromised. Provides no real security.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>For staking only</source> <translation type="unfinished"/> </message> <message> <location filename="../askpassphrasedialog.cpp" line="+38"/> <source>Encrypt wallet</source> <translation>تشفير المحفظة</translation> </message> <message> <location line="+7"/> <source>This operation needs your wallet passphrase to unlock the wallet.</source> <translation>هذه العملية تحتاج عبارة المرور محفظتك لفتحها</translation> </message> <message> <location line="+5"/> <source>Unlock wallet</source> <translation>إفتح المحفظة</translation> </message> <message> <location line="+3"/> <source>This operation needs your wallet passphrase to decrypt the wallet.</source> <translation>هذه العملية تحتاج عبارة المرور محفظتك فك تشفيرها</translation> </message> <message> <location line="+5"/> <source>Decrypt wallet</source> <translation>فك تشفير المحفظة</translation> </message> <message> <location line="+3"/> <source>Change passphrase</source> <translation>تغيير عبارة المرور</translation> </message> <message> <location line="+1"/> <source>Enter the old and new passphrase to the wallet.</source> <translation>أدخل عبارة المرور القديمة والجديدة إلى المحفظة.</translation> </message> <message> <location line="+45"/> <source>Confirm wallet encryption</source> <translation>تأكيد التشفير المحفظة</translation> </message> <message> <location line="+1"/> <source>Warning: If you encrypt your wallet and lose your passphrase, you will &lt;b&gt;LOSE ALL OF YOUR COINS&lt;/b&gt;!</source> <translation>تخذير : اذا تم تشفير المحفظة وضيعت كلمة المرور, لن تستطيع الحصول علي البلاك كوين</translation> </message> <message> <location line="+0"/> <source>Are you sure you wish to encrypt your wallet?</source> <translation>هل انت متأكد من رغبتك في تشفير المحفظة؟</translation> </message> <message> <location line="+15"/> <source>IMPORTANT: Any previous backups you have made of your wallet file should be replaced with the newly generated, encrypted wallet file. For security reasons, previous backups of the unencrypted wallet file will become useless as soon as you start using the new, encrypted wallet.</source> <translation type="unfinished"/> </message> <message> <location line="+103"/> <location line="+24"/> <source>Warning: The Caps Lock key is on!</source> <translation type="unfinished"/> </message> <message> <location line="-133"/> <location line="+60"/> <source>Wallet encrypted</source> <translation>محفظة مشفرة</translation> </message> <message> <location line="-140"/> <source>Enter the new passphrase to the wallet.&lt;br/&gt;Please use a passphrase of &lt;b&gt;ten or more random characters&lt;/b&gt;, or &lt;b&gt;eight or more words&lt;/b&gt;.</source> <translation type="unfinished"/> </message> <message> <location line="+82"/> <source>CM_CapitalName will close now to finish the encryption process. Remember that encrypting your wallet cannot fully protect your coins from being stolen by malware infecting your computer.</source> <translation>بلاك كوين</translation> </message> <message> <location line="+13"/> <location line="+7"/> <location line="+44"/> <location line="+6"/> <source>Wallet encryption failed</source> <translation>فشل تشفير المحفظة</translation> </message> <message> <location line="-56"/> <source>Wallet encryption failed due to an internal error. Your wallet was not encrypted.</source> <translation>شل تشفير المحفظة بسبب خطأ داخلي. لم يتم تشفير محفظتك.</translation> </message> <message> <location line="+7"/> <location line="+50"/> <source>The supplied passphrases do not match.</source> <translation>عبارتي المرور ليستا متطابقتان </translation> </message> <message> <location line="-38"/> <source>Wallet unlock failed</source> <translation>فشل فتح المحفظة</translation> </message> <message> <location line="+1"/> <location line="+12"/> <location line="+19"/> <source>The passphrase entered for the wallet decryption was incorrect.</source> <translation>عبارة المرور التي تم إدخالها لفك شفرة المحفظة غير صحيحة. </translation> </message> <message> <location line="-20"/> <source>Wallet decryption failed</source> <translation>فشل فك التشفير المحفظة</translation> </message> <message> <location line="+14"/> <source>Wallet passphrase was successfully changed.</source> <translation>كلمة مرور المحفظة تم تغييره بشكل ناجح</translation> </message> </context> <context> <name>BitcoinGUI</name> <message> <location filename="../bitcoingui.cpp" line="+297"/> <source>Sign &amp;message...</source> <translation>التوقيع و الرسائل</translation> </message> <message> <location line="-64"/> <source>Show general overview of wallet</source> <translation>إظهار نظرة عامة على المحفظة</translation> </message> <message> <location line="+17"/> <source>&amp;Transactions</source> <translation>المعاملات</translation> </message> <message> <location line="+1"/> <source>Browse transaction history</source> <translation>تصفح التاريخ المعاملات</translation> </message> <message> <location line="+5"/> <source>&amp;Address Book</source> <translation>&amp;كتاب العنوان</translation> </message> <message> <location line="+1"/> <source>Edit the list of stored addresses and labels</source> <translation>تعديل قائمة العنوان المحفوظة</translation> </message> <message> <location line="-18"/> <source>Show the list of addresses for receiving payments</source> <translation>اظهار قائمة العناوين التي تستقبل التعاملات</translation> </message> <message> <location line="+34"/> <source>E&amp;xit</source> <translation>خروج</translation> </message> <message> <location line="+1"/> <source>Quit application</source> <translation>الخروج من التطبيق</translation> </message> <message> <location line="+4"/> <source>Show information about CM_CapitalName</source> <translation>اظهار المعلومات عن البلاك كوين</translation> </message> <message> <location line="+2"/> <source>About &amp;Qt</source> <translation>عن</translation> </message> <message> <location line="+1"/> <source>Show information about Qt</source> <translation>اظهر المعلومات</translation> </message> <message> <location line="+2"/> <source>&amp;Options...</source> <translation>خيارات ...</translation> </message> <message> <location line="+4"/> <source>&amp;Encrypt Wallet...</source> <translation>تشفير المحفظة</translation> </message> <message> <location line="+2"/> <source>&amp;Backup Wallet...</source> <translation>حفظ ودعم المحفظة</translation> </message> <message> <location line="+2"/> <source>&amp;Change Passphrase...</source> <translation>تغيير كلمة المرور</translation> </message> <message> <location line="+9"/> <source>&amp;Export...</source> <translation>&amp;تصدير...</translation> </message> <message> <location line="-55"/> <source>Send coins to a CM_CapitalName address</source> <translation>ارسال البلاك كوين الي عنوان اخر</translation> </message> <message> <location line="+39"/> <source>Modify configuration options for CM_CapitalName</source> <translation>تعديل خيارات التكوين للبلاك كوين</translation> </message> <message> <location line="+17"/> <source>Export the data in the current tab to a file</source> <translation>ارسال البيانات الحالية الي ملف</translation> </message> <message> <location line="-13"/> <source>Encrypt or decrypt wallet</source> <translation>تشفير او فك التشفير للمحفظة</translation> </message> <message> <location line="+2"/> <source>Backup wallet to another location</source> <translation>احفظ نسخة احتياطية للمحفظة في مكان آخر</translation> </message> <message> <location line="+2"/> <source>Change the passphrase used for wallet encryption</source> <translation>تغيير عبارة المرور المستخدمة لتشفير المحفظة</translation> </message> <message> <location line="+10"/> <source>&amp;Debug window</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Open debugging and diagnostic console</source> <translation type="unfinished"/> </message> <message> <location line="-5"/> <source>&amp;Verify message...</source> <translation>تأكيد الرسالة</translation> </message> <message> <location line="-214"/> <location line="+551"/> <source>CM_CapitalName</source> <translation>البلاك كوين</translation> </message> <message> <location line="-551"/> <source>Wallet</source> <translation>محفظة</translation> </message> <message> <location line="+193"/> <source>&amp;About CM_CapitalName</source> <translation>عن البلاك كوين</translation> </message> <message> <location line="+9"/> <source>&amp;Show / Hide</source> <translation>اظهار/ اخفاء</translation> </message> <message> <location line="+8"/> <source>Unlock wallet</source> <translation>فتح المحفظة</translation> </message> <message> <location line="+1"/> <source>&amp;Lock Wallet</source> <translation>قفل المحفظة</translation> </message> <message> <location line="+1"/> <source>Lock wallet</source> <translation>قفل المحفظة</translation> </message> <message> <location line="+28"/> <source>&amp;File</source> <translation>ملف</translation> </message> <message> <location line="+8"/> <source>&amp;Settings</source> <translation>الاعدادات</translation> </message> <message> <location line="+8"/> <source>&amp;Help</source> <translation>مساعدة</translation> </message> <message> <location line="+17"/> <source>Tabs toolbar</source> <translation>شريط أدوات علامات التبويب</translation> </message> <message> <location line="+46"/> <location line="+9"/> <source>[testnet]</source> <translation>[testnet]</translation> </message> <message> <location line="+0"/> <location line="+58"/> <source>CM_CapitalName client</source> <translation>برنامج البلاك كوين</translation> </message> <message numerus="yes"> <location line="+70"/> <source>%n active connection(s) to CM_CapitalName network</source> <translation type="unfinished"><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform></translation> </message> <message> <location line="+488"/> <source>Staking.&lt;br&gt;Your weight is %1&lt;br&gt;Network weight is %2&lt;br&gt;Expected time to earn reward is %3</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Not staking because wallet is locked</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Not staking because wallet is offline</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Not staking because wallet is syncing</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Not staking because you don&apos;t have mature coins</source> <translation type="unfinished"/> </message> <message> <location line="-808"/> <source>&amp;Dashboard</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>&amp;Receive</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>&amp;Send</source> <translation type="unfinished"/> </message> <message> <location line="+49"/> <source>&amp;Unlock Wallet...</source> <translation type="unfinished"/> </message> <message> <location line="+273"/> <source>Up to date</source> <translation>محين</translation> </message> <message> <location line="+43"/> <source>Catching up...</source> <translation>اللحاق بالركب ...</translation> </message> <message> <location line="+113"/> <source>Confirm transaction fee</source> <translation>تأكيد رسوم المعاملة</translation> </message> <message> <location line="+27"/> <source>Sent transaction</source> <translation>المعاملات المرسلة</translation> </message> <message> <location line="+1"/> <source>Incoming transaction</source> <translation>المعاملات واردة</translation> </message> <message> <location line="+1"/> <source>Date: %1 Amount: %2 Type: %3 Address: %4 </source> <translation type="unfinished"/> </message> <message> <location line="+100"/> <location line="+15"/> <source>URI handling</source> <translation type="unfinished"/> </message> <message> <location line="-15"/> <location line="+15"/> <source>URI can not be parsed! This can be caused by an invalid CM_CapitalName address or malformed URI parameters.</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>Wallet is &lt;b&gt;not encrypted&lt;/b&gt;</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>Wallet is &lt;b&gt;encrypted&lt;/b&gt; and currently &lt;b&gt;unlocked&lt;/b&gt;</source> <translation>المحفظة مشفرة و مفتوحة حاليا</translation> </message> <message> <location line="+8"/> <source>Wallet is &lt;b&gt;encrypted&lt;/b&gt; and currently &lt;b&gt;locked&lt;/b&gt;</source> <translation>المحفظة مشفرة و مقفلة حاليا</translation> </message> <message> <location line="+24"/> <source>Backup Wallet</source> <translation>النسخ الاحتياطي للمحفظة</translation> </message> <message> <location line="+0"/> <source>Wallet Data (*.dat)</source> <translation>بيانات المحفظة (*.dat)</translation> </message> <message> <location line="+3"/> <source>Backup Failed</source> <translation>فشل الدعم</translation> </message> <message> <location line="+0"/> <source>There was an error trying to save the wallet data to the new location.</source> <translation>خطا في محاولة حفظ بيانات الحفظة في مكان جديد</translation> </message> <message numerus="yes"> <location line="+91"/> <source>%n second(s)</source> <translation type="unfinished"><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform></translation> </message> <message numerus="yes"> <location line="+4"/> <source>%n minute(s)</source> <translation type="unfinished"><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform></translation> </message> <message numerus="yes"> <location line="-429"/> <location line="+433"/> <source>%n hour(s)</source> <translation type="unfinished"><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform></translation> </message> <message> <location line="-456"/> <source>Processed %1 blocks of transaction history.</source> <translation type="unfinished"/> </message> <message numerus="yes"> <location line="+27"/> <location line="+433"/> <source>%n day(s)</source> <translation type="unfinished"><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform></translation> </message> <message numerus="yes"> <location line="-429"/> <location line="+6"/> <source>%n week(s)</source> <translation type="unfinished"><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform></translation> </message> <message> <location line="+0"/> <source>%1 and %2</source> <translation type="unfinished"/> </message> <message numerus="yes"> <location line="+0"/> <source>%n year(s)</source> <translation type="unfinished"><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform></translation> </message> <message> <location line="+5"/> <source>%1 behind</source> <translation type="unfinished"/> </message> <message> <location line="+15"/> <source>Last received block was generated %1 ago.</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Transactions after this will not yet be visible.</source> <translation type="unfinished"/> </message> <message> <location line="+23"/> <source>Error</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Warning</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Information</source> <translation type="unfinished"/> </message> <message> <location line="+69"/> <source>This transaction is over the size limit. You can still send it for a fee of %1, which goes to the nodes that process your transaction and helps to support the network. Do you want to pay the fee?</source> <translation type="unfinished"/> </message> <message> <location line="+324"/> <source>Not staking</source> <translation type="unfinished"/> </message> <message> <location filename="../bitcoin.cpp" line="+104"/> <source>A fatal error occurred. CM_CapitalName can no longer continue safely and will quit.</source> <translation>خطا فادح! بلاك كوين لا يمكن أن يستمر جاري الاغلاق</translation> </message> </context> <context> <name>ClientModel</name> <message> <location filename="../clientmodel.cpp" line="+110"/> <source>Network Alert</source> <translation>تحذير الشبكة</translation> </message> </context> <context> <name>CoinControlDialog</name> <message> <location filename="../forms/coincontroldialog.ui" line="+14"/> <source>Coin Control</source> <translation>سيطرة الكوين</translation> </message> <message> <location line="+31"/> <source>Quantity:</source> <translation>الكمية:</translation> </message> <message> <location line="+32"/> <source>Bytes:</source> <translation type="unfinished"/> </message> <message> <location line="+48"/> <source>Amount:</source> <translation>المبلغ:</translation> </message> <message> <location line="+32"/> <source>Priority:</source> <translation>اهمية:</translation> </message> <message> <location line="+48"/> <source>Fee:</source> <translation>رسوم:</translation> </message> <message> <location line="+35"/> <source>Low Output:</source> <translation type="unfinished"/> </message> <message> <location filename="../coincontroldialog.cpp" line="+552"/> <source>no</source> <translation>لا</translation> </message> <message> <location filename="../forms/coincontroldialog.ui" line="+51"/> <source>After Fee:</source> <translation>بعد الرسوم:</translation> </message> <message> <location line="+35"/> <source>Change:</source> <translation>تغيير:</translation> </message> <message> <location line="+69"/> <source>(un)select all</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Tree mode</source> <translation type="unfinished"/> </message> <message> <location line="+16"/> <source>List mode</source> <translation type="unfinished"/> </message> <message> <location line="+45"/> <source>Amount</source> <translation>المبلغ</translation> </message> <message> <location line="+5"/> <source>Label</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Address</source> <translation>عنوان</translation> </message> <message> <location line="+5"/> <source>Date</source> <translation>التاريخ</translation> </message> <message> <location line="+5"/> <source>Confirmations</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Confirmed</source> <translation>تأكيد</translation> </message> <message> <location line="+5"/> <source>Priority</source> <translation type="unfinished"/> </message> <message> <location filename="../coincontroldialog.cpp" line="-515"/> <source>Copy address</source> <translation> انسخ عنوان</translation> </message> <message> <location line="+1"/> <source>Copy label</source> <translation> انسخ التسمية</translation> </message> <message> <location line="+1"/> <location line="+26"/> <source>Copy amount</source> <translation>نسخ الكمية</translation> </message> <message> <location line="-25"/> <source>Copy transaction ID</source> <translation type="unfinished"/> </message> <message> <location line="+24"/> <source>Copy quantity</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Copy fee</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy after fee</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy bytes</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy priority</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy low output</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy change</source> <translation type="unfinished"/> </message> <message> <location line="+317"/> <source>highest</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>high</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>medium-high</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>medium</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>low-medium</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>low</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>lowest</source> <translation type="unfinished"/> </message> <message> <location line="+155"/> <source>DUST</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>yes</source> <translation>نعم</translation> </message> <message> <location line="+10"/> <source>This label turns red, if the transaction size is bigger than 10000 bytes. This means a fee of at least %1 per kb is required. Can vary +/- 1 Byte per input.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Transactions with higher priority get more likely into a block. This label turns red, if the priority is smaller than &quot;medium&quot;. This means a fee of at least %1 per kb is required.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>This label turns red, if any recipient receives an amount smaller than %1. This means a fee of at least %2 is required. Amounts below 0.546 times the minimum relay fee are shown as DUST.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>This label turns red, if the change is smaller than %1. This means a fee of at least %2 is required.</source> <translation type="unfinished"/> </message> <message> <location line="+36"/> <location line="+66"/> <source>(no label)</source> <translation>(لا وصف)</translation> </message> <message> <location line="-9"/> <source>change from %1 (%2)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>(change)</source> <translation type="unfinished"/> </message> </context> <context> <name>EditAddressDialog</name> <message> <location filename="../forms/editaddressdialog.ui" line="+14"/> <source>Edit Address</source> <translation>عدل العنوان</translation> </message> <message> <location line="+11"/> <source>&amp;Label</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>The label associated with this address book entry</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>&amp;Address</source> <translation>العنوان</translation> </message> <message> <location line="+10"/> <source>The address associated with this address book entry. This can only be modified for sending addresses.</source> <translation type="unfinished"/> </message> <message> <location filename="../editaddressdialog.cpp" line="+21"/> <source>New receiving address</source> <translation>عنوان تلقي جديد</translation> </message> <message> <location line="+4"/> <source>New sending address</source> <translation>عنوان إرسال جديد</translation> </message> <message> <location line="+3"/> <source>Edit receiving address</source> <translation>تعديل عنوان التلقي </translation> </message> <message> <location line="+4"/> <source>Edit sending address</source> <translation>تعديل عنوان الارسال</translation> </message> <message> <location line="+76"/> <source>The entered address &quot;%1&quot; is already in the address book.</source> <translation>هدا العنوان &quot;%1&quot; موجود مسبقا في دفتر العناوين</translation> </message> <message> <location line="-5"/> <source>The entered address &quot;%1&quot; is not a valid CM_CapitalName address.</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>Could not unlock wallet.</source> <translation> يمكن فتح المحفظة.</translation> </message> <message> <location line="+5"/> <source>New key generation failed.</source> <translation>فشل توليد مفتاح جديد.</translation> </message> </context> <context> <name>GUIUtil::HelpMessageBox</name> <message> <location filename="../guiutil.cpp" line="+426"/> <location line="+12"/> <source>CM_CapitalName-Qt</source> <translation type="unfinished"/> </message> <message> <location line="-12"/> <source>version</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Usage:</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>command-line options</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>UI options</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Set language, for example &quot;de_DE&quot; (default: system locale)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Start minimized</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Show splash screen on startup (default: 1)</source> <translation type="unfinished"/> </message> </context> <context> <name>OptionsDialog</name> <message> <location filename="../forms/optionsdialog.ui" line="+14"/> <source>Options</source> <translation>خيارات ...</translation> </message> <message> <location line="+16"/> <source>&amp;Main</source> <translation>الرئيسي</translation> </message> <message> <location line="+6"/> <source>Optional transaction fee per kB that helps make sure your transactions are processed quickly. Most transactions are 1 kB. Fee 0.01 recommended.</source> <translation type="unfinished"/> </message> <message> <location line="+15"/> <source>Pay transaction &amp;fee</source> <translation>ادفع &amp;رسوم المعاملة</translation> </message> <message> <location line="+31"/> <source>Reserved amount does not participate in staking and is therefore spendable at any time.</source> <translation type="unfinished"/> </message> <message> <location line="+15"/> <source>Reserve</source> <translation>حجز</translation> </message> <message> <location line="+31"/> <source>Automatically start CM_CapitalName after logging in to the system.</source> <translation>بد البلاك كوين تلقائي عند الدخول الي الجهاز</translation> </message> <message> <location line="+3"/> <source>&amp;Start CM_CapitalName on system login</source> <translation type="unfinished"/> </message> <message> <location line="+21"/> <source>&amp;Network</source> <translation>&amp;الشبكة</translation> </message> <message> <location line="+6"/> <source>Automatically open the CM_CapitalName client port on the router. This only works when your router supports UPnP and it is enabled.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Map port using &amp;UPnP</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Connect to the CM_CapitalName network through a SOCKS proxy (e.g. when connecting through Tor).</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Connect through SOCKS proxy:</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>Proxy &amp;IP:</source> <translation type="unfinished"/> </message> <message> <location line="+19"/> <source>IP address of the proxy (e.g. 127.0.0.1)</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>&amp;Port:</source> <translation type="unfinished"/> </message> <message> <location line="+19"/> <source>Port of the proxy (e.g. 9050)</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>SOCKS &amp;Version:</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>SOCKS version of the proxy (e.g. 5)</source> <translation type="unfinished"/> </message> <message> <location line="+36"/> <source>&amp;Window</source> <translation>نافذه</translation> </message> <message> <location line="+6"/> <source>Show only a tray icon after minimizing the window.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Minimize to the tray instead of the taskbar</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Minimize instead of exit the application when the window is closed. When this option is enabled, the application will be closed only after selecting Quit in the menu.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>M&amp;inimize on close</source> <translation type="unfinished"/> </message> <message> <location line="+21"/> <source>&amp;Display</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>User Interface &amp;language:</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>The user interface language can be set here. This setting will take effect after restarting CM_CapitalName.</source> <translation type="unfinished"/> </message> <message> <location line="+11"/> <source>&amp;Unit to show amounts in:</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Choose the default subdivision unit to show in the interface and when sending coins.</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>Whether to show coin control features or not.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Display coin &amp;control features (experts only!)</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Whether to select the coin outputs randomly or with minimal coin age.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Minimize weight consumption (experimental)</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Use black visual theme (requires restart)</source> <translation type="unfinished"/> </message> <message> <location line="+71"/> <source>&amp;OK</source> <translation>تم</translation> </message> <message> <location line="+7"/> <source>&amp;Cancel</source> <translation>الغاء</translation> </message> <message> <location line="+10"/> <source>&amp;Apply</source> <translation type="unfinished"/> </message> <message> <location filename="../optionsdialog.cpp" line="+53"/> <source>default</source> <translation>الافتراضي</translation> </message> <message> <location line="+149"/> <location line="+9"/> <source>Warning</source> <translation type="unfinished"/> </message> <message> <location line="-9"/> <location line="+9"/> <source>This setting will take effect after restarting CM_CapitalName.</source> <translation type="unfinished"/> </message> <message> <location line="+29"/> <source>The supplied proxy address is invalid.</source> <translation>عنوان الوكيل توفيره غير صالح.</translation> </message> </context> <context> <name>OverviewPage</name> <message> <location filename="../forms/overviewpage.ui" line="+14"/> <source>Form</source> <translation>نمودج</translation> </message> <message> <location line="+46"/> <location line="+247"/> <source>The displayed information may be out of date. Your wallet automatically synchronizes with the CM_CapitalName network after a connection is established, but this process has not completed yet.</source> <translation type="unfinished"/> </message> <message> <location line="-173"/> <source>Stake:</source> <translation type="unfinished"/> </message> <message> <location line="+32"/> <source>Unconfirmed:</source> <translation type="unfinished"/> </message> <message> <location line="-113"/> <source>Wallet</source> <translation>محفظة</translation> </message> <message> <location line="+49"/> <source>Spendable:</source> <translation type="unfinished"/> </message> <message> <location line="+16"/> <source>Your current spendable balance</source> <translation type="unfinished"/> </message> <message> <location line="+80"/> <source>Immature:</source> <translation>غير ناضجة</translation> </message> <message> <location line="+13"/> <source>Mined balance that has not yet matured</source> <translation type="unfinished"/> </message> <message> <location line="+23"/> <source>Total:</source> <translation>الكامل:</translation> </message> <message> <location line="+16"/> <source>Your current total balance</source> <translation type="unfinished"/> </message> <message> <location line="+50"/> <source>&lt;b&gt;Recent transactions&lt;/b&gt;</source> <translation>اخر المعملات </translation> </message> <message> <location line="-118"/> <source>Total of transactions that have yet to be confirmed, and do not yet count toward the current balance</source> <translation type="unfinished"/> </message> <message> <location line="-32"/> <source>Total of coins that was staked, and do not yet count toward the current balance</source> <translation type="unfinished"/> </message> <message> <location filename="../overviewpage.cpp" line="+116"/> <location line="+1"/> <source>out of sync</source> <translation>خارج المزامنه</translation> </message> </context> <context> <name>PaymentServer</name> <message> <location filename="../paymentserver.cpp" line="+107"/> <source>Cannot start blackcoin: click-to-pay handler</source> <translation type="unfinished"/> </message> </context> <context> <name>QRCodeDialog</name> <message> <location filename="../forms/qrcodedialog.ui" line="+14"/> <source>QR Code Dialog</source> <translation type="unfinished"/> </message> <message> <location line="+59"/> <source>Request Payment</source> <translation type="unfinished"/> </message> <message> <location line="+56"/> <source>Amount:</source> <translation type="unfinished"/> </message> <message> <location line="-44"/> <source>Label:</source> <translation type="unfinished"/> </message> <message> <location line="+19"/> <source>Message:</source> <translation type="unfinished"/> </message> <message> <location line="+71"/> <source>&amp;Save As...</source> <translation type="unfinished"/> </message> <message> <location filename="../qrcodedialog.cpp" line="+62"/> <source>Error encoding URI into QR Code.</source> <translation type="unfinished"/> </message> <message> <location line="+40"/> <source>The entered amount is invalid, please check.</source> <translation type="unfinished"/> </message> <message> <location line="+23"/> <source>Resulting URI too long, try to reduce the text for label / message.</source> <translation type="unfinished"/> </message> <message> <location line="+25"/> <source>Save QR Code</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>PNG Images (*.png)</source> <translation type="unfinished"/> </message> </context> <context> <name>RPCConsole</name> <message> <location filename="../forms/rpcconsole.ui" line="+46"/> <source>Client name</source> <translation>اسم العميل</translation> </message> <message> <location line="+10"/> <location line="+23"/> <location line="+26"/> <location line="+23"/> <location line="+23"/> <location line="+36"/> <location line="+53"/> <location line="+23"/> <source>N/A</source> <translation>غير معروف</translation> </message> <message> <location line="-194"/> <source>Client version</source> <translation>نسخه العميل</translation> </message> <message> <location line="-45"/> <source>&amp;Information</source> <translation>المعلومات</translation> </message> <message> <location line="+68"/> <source>Using OpenSSL version</source> <translation type="unfinished"/> </message> <message> <location line="+49"/> <source>Startup time</source> <translation type="unfinished"/> </message> <message> <location line="+29"/> <source>Network</source> <translation>الشبكه</translation> </message> <message> <location line="+7"/> <source>Number of connections</source> <translation>عدد الاتصالات</translation> </message> <message> <location line="+23"/> <source>On testnet</source> <translation type="unfinished"/> </message> <message> <location line="+23"/> <source>Block chain</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Current number of blocks</source> <translation type="unfinished"/> </message> <message> <location line="+197"/> <source>&amp;Network Traffic</source> <translation type="unfinished"/> </message> <message> <location line="+52"/> <source>&amp;Clear</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Totals</source> <translation type="unfinished"/> </message> <message> <location line="+64"/> <source>In:</source> <translation type="unfinished"/> </message> <message> <location line="+80"/> <source>Out:</source> <translation type="unfinished"/> </message> <message> <location line="-383"/> <source>Last block time</source> <translation type="unfinished"/> </message> <message> <location line="+52"/> <source>&amp;Open</source> <translation>الفتح</translation> </message> <message> <location line="+16"/> <source>Command-line options</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Show the CM_CapitalName-Qt help message to get a list with possible CM_CapitalName command-line options.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Show</source> <translation type="unfinished"/> </message> <message> <location line="+24"/> <source>&amp;Console</source> <translation type="unfinished"/> </message> <message> <location line="-237"/> <source>Build date</source> <translation>وقت البناء</translation> </message> <message> <location line="-104"/> <source>CM_CapitalName - Debug window</source> <translation type="unfinished"/> </message> <message> <location line="+25"/> <source>CM_CapitalName Core</source> <translation type="unfinished"/> </message> <message> <location line="+256"/> <source>Debug log file</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Open the CM_CapitalName debug log file from the current data directory. This can take a few seconds for large log files.</source> <translation type="unfinished"/> </message> <message> <location line="+102"/> <source>Clear console</source> <translation type="unfinished"/> </message> <message> <location filename="../rpcconsole.cpp" line="+325"/> <source>Welcome to the CM_CapitalName RPC console.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Use up and down arrows to navigate history, and &lt;b&gt;Ctrl-L&lt;/b&gt; to clear screen.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Type &lt;b&gt;help&lt;/b&gt; for an overview of available commands.</source> <translation type="unfinished"/> </message> <message> <location line="+127"/> <source>%1 B</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>%1 KB</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>%1 MB</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>%1 GB</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>%1 m</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>%1 h</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>%1 h %2 m</source> <translation type="unfinished"/> </message> </context> <context> <name>SendCoinsDialog</name> <message> <location filename="../forms/sendcoinsdialog.ui" line="+14"/> <location filename="../sendcoinsdialog.cpp" line="+181"/> <location line="+5"/> <location line="+5"/> <location line="+5"/> <location line="+6"/> <location line="+5"/> <location line="+5"/> <source>Send Coins</source> <translation>إرسال Coins</translation> </message> <message> <location line="+76"/> <source>Coin Control Features</source> <translation type="unfinished"/> </message> <message> <location line="+20"/> <source>Inputs...</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>automatically selected</source> <translation type="unfinished"/> </message> <message> <location line="+19"/> <source>Insufficient funds!</source> <translation type="unfinished"/> </message> <message> <location line="+77"/> <source>Quantity:</source> <translation type="unfinished"/> </message> <message> <location line="+22"/> <location line="+35"/> <source>0</source> <translation type="unfinished"/> </message> <message> <location line="-19"/> <source>Bytes:</source> <translation type="unfinished"/> </message> <message> <location line="+51"/> <source>Amount:</source> <translation type="unfinished"/> </message> <message> <location line="+22"/> <location line="+86"/> <location line="+86"/> <location line="+32"/> <source>0.00 CC</source> <translation type="unfinished"/> </message> <message> <location line="-191"/> <source>Priority:</source> <translation type="unfinished"/> </message> <message> <location line="+19"/> <source>medium</source> <translation type="unfinished"/> </message> <message> <location line="+32"/> <source>Fee:</source> <translation type="unfinished"/> </message> <message> <location line="+35"/> <source>Low Output:</source> <translation type="unfinished"/> </message> <message> <location line="+19"/> <source>no</source> <translation type="unfinished"/> </message> <message> <location line="+32"/> <source>After Fee:</source> <translation type="unfinished"/> </message> <message> <location line="+35"/> <source>Change</source> <translation type="unfinished"/> </message> <message> <location line="+50"/> <source>custom change address</source> <translation type="unfinished"/> </message> <message> <location line="+106"/> <source>Send to multiple recipients at once</source> <translation>إرسال إلى عدة مستلمين في وقت واحد</translation> </message> <message> <location line="+3"/> <source>Add &amp;Recipient</source> <translation type="unfinished"/> </message> <message> <location line="+16"/> <source>Remove all transaction fields</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Clear &amp;All</source> <translation>مسح الكل</translation> </message> <message> <location line="+24"/> <source>Balance:</source> <translation>الرصيد:</translation> </message> <message> <location line="+16"/> <source>123.456 CC</source> <translation type="unfinished"/> </message> <message> <location line="+31"/> <source>Confirm the send action</source> <translation>تأكيد الإرسال</translation> </message> <message> <location line="+3"/> <source>S&amp;end</source> <translation type="unfinished"/> </message> <message> <location filename="../sendcoinsdialog.cpp" line="-173"/> <source>Enter a CM_CapitalName address (e.g. B8gZqgY4r2RoEdqYk3QsAqFckyf9pRHN6i)</source> <translation type="unfinished"/> </message> <message> <location line="+15"/> <source>Copy quantity</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy amount</source> <translation>نسخ الكمية</translation> </message> <message> <location line="+1"/> <source>Copy fee</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy after fee</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy bytes</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy priority</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy low output</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy change</source> <translation type="unfinished"/> </message> <message> <location line="+86"/> <source>&lt;b&gt;%1&lt;/b&gt; to %2 (%3)</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Confirm send coins</source> <translation>تأكيد الإرسال Coins</translation> </message> <message> <location line="+1"/> <source>Are you sure you want to send %1?</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source> and </source> <translation type="unfinished"/> </message> <message> <location line="+29"/> <source>The recipient address is not valid, please recheck.</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>The amount to pay must be larger than 0.</source> <translation>المبلغ المدفوع يجب ان يكون اكبر من 0</translation> </message> <message> <location line="+5"/> <source>The amount exceeds your balance.</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>The total exceeds your balance when the %1 transaction fee is included.</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Duplicate address found, can only send to each address once per send operation.</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Error: Transaction creation failed!</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Error: The transaction was rejected. This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here.</source> <translation type="unfinished"/> </message> <message> <location line="+247"/> <source>WARNING: Invalid CM_CapitalName address</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>(no label)</source> <translation>(لا وصف)</translation> </message> <message> <location line="+4"/> <source>WARNING: unknown change address</source> <translation type="unfinished"/> </message> </context> <context> <name>SendCoinsEntry</name> <message> <location filename="../forms/sendcoinsentry.ui" line="+14"/> <source>Form</source> <translation type="unfinished"/> </message> <message> <location line="+15"/> <source>A&amp;mount:</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Pay &amp;To:</source> <translation>ادفع الى </translation> </message> <message> <location line="+34"/> <source>The address to send the payment to (e.g. B8gZqgY4r2RoEdqYk3QsAqFckyf9pRHN6i)</source> <translation type="unfinished"/> </message> <message> <location line="+60"/> <location filename="../sendcoinsentry.cpp" line="+26"/> <source>Enter a label for this address to add it to your address book</source> <translation>إدخال تسمية لهذا العنوان لإضافته إلى دفتر العناوين الخاص بك</translation> </message> <message> <location line="-78"/> <source>&amp;Label:</source> <translation type="unfinished"/> </message> <message> <location line="+28"/> <source>Choose address from address book</source> <translation>اختيار عنوان من كتاب العناوين</translation> </message> <message> <location line="+10"/> <source>Alt+A</source> <translation>Alt+A</translation> </message> <message> <location line="+7"/> <source>Paste address from clipboard</source> <translation>انسخ العنوان من لوحة المفاتيح</translation> </message> <message> <location line="+10"/> <source>Alt+P</source> <translation>Alt+P</translation> </message> <message> <location line="+7"/> <source>Remove this recipient</source> <translation>خذف هذا المستخدم</translation> </message> <message> <location filename="../sendcoinsentry.cpp" line="+1"/> <source>Enter a CM_CapitalName address (e.g. B8gZqgY4r2RoEdqYk3QsAqFckyf9pRHN6i)</source> <translation>ادخال عنوان البلاك كوين (مثلا B8gZqgY4r2RoEdqYk3QsAqFckyf9pRHN6i)</translation> </message> </context> <context> <name>SignVerifyMessageDialog</name> <message> <location filename="../forms/signverifymessagedialog.ui" line="+14"/> <source>Signatures - Sign / Verify a Message</source> <translation>التواقيع - التوقيع /تأكيد الرسالة</translation> </message> <message> <location line="+13"/> <location line="+124"/> <source>&amp;Sign Message</source> <translation>&amp;وقع الرسالة</translation> </message> <message> <location line="-118"/> <source>You can sign messages with your addresses to prove you own them. Be careful not to sign anything vague, as phishing attacks may try to trick you into signing your identity over to them. Only sign fully-detailed statements you agree to.</source> <translation type="unfinished"/> </message> <message> <location line="+18"/> <source>The address to sign the message with (e.g. B8gZqgY4r2RoEdqYk3QsAqFckyf9pRHN6i)</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <location line="+203"/> <source>Choose an address from the address book</source> <translation>اختيار عنوان من كتاب العناوين</translation> </message> <message> <location line="-193"/> <location line="+203"/> <source>Alt+A</source> <translation>Alt+A</translation> </message> <message> <location line="-193"/> <source>Paste address from clipboard</source> <translation>انسخ العنوان من لوحة المفاتيح</translation> </message> <message> <location line="+10"/> <source>Alt+P</source> <translation>Alt+P</translation> </message> <message> <location line="+12"/> <source>Enter the message you want to sign here</source> <translation type="unfinished"/> </message> <message> <location line="+24"/> <source>Copy the current signature to the system clipboard</source> <translation type="unfinished"/> </message> <message> <location line="+21"/> <source>Sign the message to prove you own this CM_CapitalName address</source> <translation type="unfinished"/> </message> <message> <location line="+17"/> <source>Reset all sign message fields</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <location line="+146"/> <source>Clear &amp;All</source> <translation>مسح الكل</translation> </message> <message> <location line="-87"/> <location line="+70"/> <source>&amp;Verify Message</source> <translation type="unfinished"/> </message> <message> <location line="-64"/> <source>Enter the signing address, message (ensure you copy line breaks, spaces, tabs, etc. exactly) and signature below to verify the message. Be careful not to read more into the signature than what is in the signed message itself, to avoid being tricked by a man-in-the-middle attack.</source> <translation type="unfinished"/> </message> <message> <location line="+21"/> <source>The address the message was signed with (e.g. B8gZqgY4r2RoEdqYk3QsAqFckyf9pRHN6i)</source> <translation type="unfinished"/> </message> <message> <location line="+40"/> <source>Verify the message to ensure it was signed with the specified CM_CapitalName address</source> <translation type="unfinished"/> </message> <message> <location line="+17"/> <source>Reset all verify message fields</source> <translation type="unfinished"/> </message> <message> <location filename="../signverifymessagedialog.cpp" line="+27"/> <location line="+3"/> <source>Enter a CM_CapitalName address (e.g. B8gZqgY4r2RoEdqYk3QsAqFckyf9pRHN6i)</source> <translation type="unfinished"/> </message> <message> <location line="-2"/> <source>Click &quot;Sign Message&quot; to generate signature</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Enter CM_CapitalName signature</source> <translation type="unfinished"/> </message> <message> <location line="+82"/> <location line="+81"/> <source>The entered address is invalid.</source> <translation>العنوان المدخل غير صالح</translation> </message> <message> <location line="-81"/> <location line="+8"/> <location line="+73"/> <location line="+8"/> <source>Please check the address and try again.</source> <translation>الرجاء التأكد من العنوان والمحاولة مرة اخرى</translation> </message> <message> <location line="-81"/> <location line="+81"/> <source>The entered address does not refer to a key.</source> <translation>العنوان المدخل لا يشير الى مفتاح</translation> </message> <message> <location line="-73"/> <source>Wallet unlock was cancelled.</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>Private key for the entered address is not available.</source> <translation>المفتاح الخاص للعنوان المدخل غير موجود.</translation> </message> <message> <location line="+12"/> <source>Message signing failed.</source> <translation>فشل توقيع الرسالة.</translation> </message> <message> <location line="+5"/> <source>Message signed.</source> <translation>الرسالة موقعة.</translation> </message> <message> <location line="+59"/> <source>The signature could not be decoded.</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <location line="+13"/> <source>Please check the signature and try again.</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>The signature did not match the message digest.</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Message verification failed.</source> <translation>فشلت عملية التأكد من الرسالة.</translation> </message> <message> <location line="+5"/> <source>Message verified.</source> <translation>تم تأكيد الرسالة.</translation> </message> </context> <context> <name>TrafficGraphWidget</name> <message> <location filename="../trafficgraphwidget.cpp" line="+75"/> <source>KB/s</source> <translation type="unfinished"/> </message> </context> <context> <name>TransactionDesc</name> <message> <location filename="../transactiondesc.cpp" line="+25"/> <source>Open until %1</source> <translation>مفتوح حتى 1٪</translation> </message> <message> <location line="+6"/> <source>conflicted</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>%1/offline</source> <translation>1% غير متواجد</translation> </message> <message> <location line="+2"/> <source>%1/unconfirmed</source> <translation>غير مؤكدة/1%</translation> </message> <message> <location line="+2"/> <source>%1 confirmations</source> <translation>تأكيد %1</translation> </message> <message> <location line="+17"/> <source>Status</source> <translation>الحالة.</translation> </message> <message numerus="yes"> <location line="+7"/> <source>, broadcast through %n node(s)</source> <translation type="unfinished"><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform></translation> </message> <message> <location line="+4"/> <source>Date</source> <translation>التاريخ</translation> </message> <message> <location line="+7"/> <source>Source</source> <translation>المصدر</translation> </message> <message> <location line="+0"/> <source>Generated</source> <translation>تم اصداره.</translation> </message> <message> <location line="+5"/> <location line="+17"/> <source>From</source> <translation>من</translation> </message> <message> <location line="+1"/> <location line="+22"/> <location line="+58"/> <source>To</source> <translation>الى</translation> </message> <message> <location line="-77"/> <location line="+2"/> <source>own address</source> <translation>عنوانه</translation> </message> <message> <location line="-2"/> <source>label</source> <translation type="unfinished"/> </message> <message> <location line="+37"/> <location line="+12"/> <location line="+45"/> <location line="+17"/> <location line="+30"/> <source>Credit</source> <translation type="unfinished"/> </message> <message numerus="yes"> <location line="-102"/> <source>matures in %n more block(s)</source> <translation type="unfinished"><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform></translation> </message> <message> <location line="+2"/> <source>not accepted</source> <translation>غير مقبولة</translation> </message> <message> <location line="+44"/> <location line="+8"/> <location line="+15"/> <location line="+30"/> <source>Debit</source> <translation>دين</translation> </message> <message> <location line="-39"/> <source>Transaction fee</source> <translation>رسوم التحويل</translation> </message> <message> <location line="+16"/> <source>Net amount</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Message</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Comment</source> <translation>تعليق</translation> </message> <message> <location line="+2"/> <source>Transaction ID</source> <translation>رقم المعاملة</translation> </message> <message> <location line="+3"/> <source>Generated coins must mature 101 blocks before they can be spent. When you generated this block, it was broadcast to the network to be added to the block chain. If it fails to get into the chain, its state will change to &quot;not accepted&quot; and it won&apos;t be spendable. This may occasionally happen if another node generates a block within a few seconds of yours.</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Debug information</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>Transaction</source> <translation>معاملة</translation> </message> <message> <location line="+5"/> <source>Inputs</source> <translation type="unfinished"/> </message> <message> <location line="+21"/> <source>Amount</source> <translation>المبلغ</translation> </message> <message> <location line="+1"/> <source>true</source> <translation>صحيح</translation> </message> <message> <location line="+0"/> <source>false</source> <translation>خاطئ</translation> </message> <message> <location line="-209"/> <source>, has not been successfully broadcast yet</source> <translation>لم يتم حتى الآن البث بنجاح</translation> </message> <message numerus="yes"> <location line="-36"/> <source>Open for %n more block(s)</source> <translation type="unfinished"><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform></translation> </message> <message> <location line="+71"/> <source>unknown</source> <translation>غير معروف</translation> </message> </context> <context> <name>TransactionDescDialog</name> <message> <location filename="../forms/transactiondescdialog.ui" line="+14"/> <source>Transaction details</source> <translation>تفاصيل المعاملة</translation> </message> <message> <location line="+6"/> <source>This pane shows a detailed description of the transaction</source> <translation>يبين هذا الجزء وصفا مفصلا لهده المعاملة</translation> </message> </context> <context> <name>TransactionTableModel</name> <message> <location filename="../transactiontablemodel.cpp" line="+231"/> <source>Date</source> <translation>التاريخ</translation> </message> <message> <location line="+0"/> <source>Type</source> <translation>النوع</translation> </message> <message> <location line="+0"/> <source>Address</source> <translation>عنوان</translation> </message> <message> <location line="+0"/> <source>Amount</source> <translation>المبلغ</translation> </message> <message> <location line="+52"/> <source>Open until %1</source> <translation>مفتوح حتى 1٪</translation> </message> <message> <location line="+12"/> <source>Confirmed (%1 confirmations)</source> <translation>تأكيد الإرسال Coins</translation> </message> <message numerus="yes"> <location line="-15"/> <source>Open for %n more block(s)</source> <translation type="unfinished"><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform><numerusform></numerusform></translation> </message> <message> <location line="+6"/> <source>Offline</source> <translation>غير متصل</translation> </message> <message> <location line="+3"/> <source>Unconfirmed</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Confirming (%1 of %2 recommended confirmations)</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Conflicted</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Immature (%1 confirmations, will be available after %2)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>This block was not received by any other nodes and will probably not be accepted!</source> <translation>لم يتم تلقى هذه الكتلة (Block) من قبل أي العقد الأخرى وربما لن تكون مقبولة!</translation> </message> <message> <location line="+3"/> <source>Generated but not accepted</source> <translation>ولدت ولكن لم تقبل</translation> </message> <message> <location line="+42"/> <source>Received with</source> <translation>استقبل مع</translation> </message> <message> <location line="+2"/> <source>Received from</source> <translation>استقبل من</translation> </message> <message> <location line="+3"/> <source>Sent to</source> <translation>أرسل إلى</translation> </message> <message> <location line="+2"/> <source>Payment to yourself</source> <translation>دفع لنفسك</translation> </message> <message> <location line="+2"/> <source>Mined</source> <translation>Mined</translation> </message> <message> <location line="+38"/> <source>(n/a)</source> <translation>غير متوفر</translation> </message> <message> <location line="+194"/> <source>Transaction status. Hover over this field to show number of confirmations.</source> <translation>حالة المعاملة. تحوم حول هذا الحقل لعرض عدد التأكيدات.</translation> </message> <message> <location line="+2"/> <source>Date and time that the transaction was received.</source> <translation>التاريخ والوقت الذي تم فيه تلقي المعاملة.</translation> </message> <message> <location line="+2"/> <source>Type of transaction.</source> <translation>نوع المعاملات</translation> </message> <message> <location line="+2"/> <source>Destination address of transaction.</source> <translation>عنوان وجهة المعاملة</translation> </message> <message> <location line="+2"/> <source>Amount removed from or added to balance.</source> <translation>المبلغ الذي أزيل أو أضيف الى الرصيد</translation> </message> </context> <context> <name>TransactionView</name> <message> <location filename="../transactionview.cpp" line="+54"/> <location line="+17"/> <source>All</source> <translation>الكل</translation> </message> <message> <location line="-16"/> <source>Today</source> <translation>اليوم</translation> </message> <message> <location line="+1"/> <source>This week</source> <translation>هدا الاسبوع</translation> </message> <message> <location line="+1"/> <source>This month</source> <translation>هدا الشهر</translation> </message> <message> <location line="+1"/> <source>Last month</source> <translation>الشهر الماضي</translation> </message> <message> <location line="+1"/> <source>This year</source> <translation>هدا العام</translation> </message> <message> <location line="+1"/> <source>Range...</source> <translation>نطاق</translation> </message> <message> <location line="+12"/> <source>Received with</source> <translation>استقبل مع</translation> </message> <message> <location line="+2"/> <source>Sent to</source> <translation>أرسل إلى</translation> </message> <message> <location line="+2"/> <source>To yourself</source> <translation>إليك</translation> </message> <message> <location line="+1"/> <source>Mined</source> <translation>Mined</translation> </message> <message> <location line="+1"/> <source>Other</source> <translation>اخرى</translation> </message> <message> <location line="+7"/> <source>Enter address or label to search</source> <translation>ادخل عنوان أووصف للبحث</translation> </message> <message> <location line="+7"/> <source>Min amount</source> <translation>الكمية الادني</translation> </message> <message> <location line="+34"/> <source>Copy address</source> <translation> انسخ عنوان</translation> </message> <message> <location line="+1"/> <source>Copy label</source> <translation> انسخ التسمية</translation> </message> <message> <location line="+1"/> <source>Copy amount</source> <translation>نسخ الكمية</translation> </message> <message> <location line="+1"/> <source>Copy transaction ID</source> <translation>نسخ رقم المعاملة</translation> </message> <message> <location line="+1"/> <source>Edit label</source> <translation>عدل الوصف</translation> </message> <message> <location line="+1"/> <source>Show transaction details</source> <translation>اظهار تفاصيل المعاملة</translation> </message> <message> <location line="+138"/> <source>Export Transaction Data</source> <translation>تصدير بيانات المعاملة</translation> </message> <message> <location line="+1"/> <source>Comma separated file (*.csv)</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>Confirmed</source> <translation>تأكيد</translation> </message> <message> <location line="+1"/> <source>Date</source> <translation>التاريخ</translation> </message> <message> <location line="+1"/> <source>Type</source> <translation>النوع</translation> </message> <message> <location line="+1"/> <source>Label</source> <translation>وصف</translation> </message> <message> <location line="+1"/> <source>Address</source> <translation>عنوان</translation> </message> <message> <location line="+1"/> <source>Amount</source> <translation>المبلغ</translation> </message> <message> <location line="+1"/> <source>ID</source> <translation>العنوان</translation> </message> <message> <location line="+4"/> <source>Error exporting</source> <translation>خطا في التصدير</translation> </message> <message> <location line="+0"/> <source>Could not write to file %1.</source> <translation>لا يمكن الكتابة الي الملف %1.</translation> </message> <message> <location line="+100"/> <source>Range:</source> <translation>نطاق:</translation> </message> <message> <location line="+8"/> <source>to</source> <translation>الى</translation> </message> </context> <context> <name>WalletModel</name> <message> <location filename="../walletmodel.cpp" line="+208"/> <source>Sending...</source> <translation>ارسال....</translation> </message> </context> <context> <name>bitcoin-core</name> <message> <location filename="../bitcoinstrings.cpp" line="+173"/> <source>CM_CapitalName version</source> <translation>جزع البلاك كوين</translation> </message> <message> <location line="+1"/> <source>Usage:</source> <translation>المستخدم</translation> </message> <message> <location line="+1"/> <source>Send command to -server or blackcoind</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>List commands</source> <translation>اعرض الأوامر</translation> </message> <message> <location line="+1"/> <source>Get help for a command</source> <translation>مساعدة في كتابة الاوامر</translation> </message> <message> <location line="-147"/> <source>Options:</source> <translation>خيارات: </translation> </message> <message> <location line="+2"/> <source>Specify configuration file (default: blackcoin.conf)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Specify pid file (default: blackcoind.pid)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Specify wallet file (within data directory)</source> <translation type="unfinished"/> </message> <message> <location line="-1"/> <source>Specify data directory</source> <translation>حدد موقع مجلد المعلومات او data directory</translation> </message> <message> <location line="-25"/> <source>%s, you must set a rpcpassword in the configuration file: %s It is recommended you use the following random password: rpcuser=blackcoinrpc rpcpassword=%s (you do not need to remember this password) The username and password MUST NOT be the same. If the file does not exist, create it with owner-readable-only file permissions. It is also recommended to set alertnotify so you are notified of problems; for example: alertnotify=echo %%s | mail -s &quot;CM_CapitalName Alert&quot; admin@foo.com </source> <translation type="unfinished"/> </message> <message> <location line="+27"/> <source>Set database cache size in megabytes (default: 25)</source> <translation>ضع حجم كاش قاعدة البيانات بالميجابايت (الافتراضي: 25)</translation> </message> <message> <location line="+1"/> <source>Set database disk log size in megabytes (default: 100)</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Listen for connections on &lt;port&gt; (default: CM_Port or testnet: CM_Port_Testnet)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Maintain at most &lt;n&gt; connections to peers (default: 125)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Connect to a node to retrieve peer addresses, and disconnect</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Specify your own public address</source> <translation>حدد عنوانك العام هنا</translation> </message> <message> <location line="+4"/> <source>Bind to given address. Use [host]:port notation for IPv6</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Query for peer addresses via DNS lookup, if low on addresses (default: 1 unless -connect)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Always query for peer addresses via DNS lookup (default: 0)</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Threshold for disconnecting misbehaving peers (default: 100)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Number of seconds to keep misbehaving peers from reconnecting (default: 86400)</source> <translation type="unfinished"/> </message> <message> <location line="-37"/> <source>An error occurred while setting up the RPC port %u for listening on IPv4: %s</source> <translation type="unfinished"/> </message> <message> <location line="+65"/> <source>Listen for JSON-RPC connections on &lt;port&gt; (default: CM_RPC or testnet: 25715)</source> <translation type="unfinished"/> </message> <message> <location line="-17"/> <source>Accept command line and JSON-RPC commands</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Run in the background as a daemon and accept commands</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Use the test network</source> <translation>استخدم التحقق من الشبكه</translation> </message> <message> <location line="-24"/> <source>Accept connections from outside (default: 1 if no -proxy or -connect)</source> <translation>قبول الاتصالات من خارج</translation> </message> <message> <location line="-29"/> <source>An error occurred while setting up the RPC port %u for listening on IPv6, falling back to IPv4: %s</source> <translation type="unfinished"/> </message> <message> <location line="+96"/> <source>Set maximum size of high-priority/low-fee transactions in bytes (default: 27000)</source> <translation type="unfinished"/> </message> <message> <location line="+12"/> <source>Warning: -paytxfee is set very high! This is the transaction fee you will pay if you send a transaction.</source> <translation type="unfinished"/> </message> <message> <location line="-103"/> <source>Warning: Please check that your computer&apos;s date and time are correct! If your clock is wrong CM_CapitalName will not work properly.</source> <translation>تحذير : تأكد من ساعة وتاريخ الكمبيوتر! اذا ساعة غير صحيحة بلاك كوين لن يعمل بشكل صحيح</translation> </message> <message> <location line="+132"/> <source>Warning: error reading wallet.dat! All keys read correctly, but transaction data or address book entries might be missing or incorrect.</source> <translation>تحذير : خطا في قراءة wallet.dat! كل المفاتيح تم قرائتة بشكل صحيح لكن بيانات الصفقة او إدخالات كتاب العنوان غير صحيحة او غير موجودة</translation> </message> <message> <location line="-18"/> <source>Warning: wallet.dat corrupt, data salvaged! Original wallet.dat saved as wallet.{timestamp}.bak in %s; if your balance or transactions are incorrect you should restore from a backup.</source> <translation>تخذير :wallet.dat غير صالح تم حفظ البيانات. المحفظة الاصلية تم حفظه ك wallet.{timestamp}.bak %s في ; اذا حسابك او صفقاتك غير صحيح يجب عليك استعادة النسخ الاحتياطي</translation> </message> <message> <location line="-31"/> <source>Attempt to recover private keys from a corrupt wallet.dat</source> <translation>محاولة استرجاع المفاتيح الخاصة من wallet.dat الغير صالح</translation> </message> <message> <location line="+5"/> <source>Block creation options:</source> <translation>خيارات صناعة الكتل</translation> </message> <message> <location line="-69"/> <source>Connect only to the specified node(s)</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Discover own IP address (default: 1 when listening and no -externalip)</source> <translation type="unfinished"/> </message> <message> <location line="+101"/> <source>Failed to listen on any port. Use -listen=0 if you want this.</source> <translation>فشل في الاستماع على أي منفذ. استخدام الاستماع = 0 إذا كنت تريد هذا.</translation> </message> <message> <location line="-91"/> <source>Sync checkpoints policy (default: strict)</source> <translation type="unfinished"/> </message> <message> <location line="+89"/> <source>Invalid -tor address: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Invalid amount for -reservebalance=&lt;amount&gt;</source> <translation type="unfinished"/> </message> <message> <location line="-88"/> <source>Maximum per-connection receive buffer, &lt;n&gt;*1000 bytes (default: 5000)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Maximum per-connection send buffer, &lt;n&gt;*1000 bytes (default: 1000)</source> <translation type="unfinished"/> </message> <message> <location line="-17"/> <source>Only connect to nodes in network &lt;net&gt; (IPv4, IPv6 or Tor)</source> <translation type="unfinished"/> </message> <message> <location line="+31"/> <source>Prepend debug output with timestamp</source> <translation type="unfinished"/> </message> <message> <location line="+41"/> <source>SSL options: (see the Bitcoin Wiki for SSL setup instructions)</source> <translation type="unfinished"/> </message> <message> <location line="-81"/> <source>Select the version of socks proxy to use (4-5, default: 5)</source> <translation type="unfinished"/> </message> <message> <location line="+42"/> <source>Send trace/debug info to console instead of debug.log file</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Send trace/debug info to debugger</source> <translation type="unfinished"/> </message> <message> <location line="+30"/> <source>Set maximum block size in bytes (default: 250000)</source> <translation type="unfinished"/> </message> <message> <location line="-1"/> <source>Set minimum block size in bytes (default: 0)</source> <translation type="unfinished"/> </message> <message> <location line="-35"/> <source>Shrink debug.log file on client startup (default: 1 when no -debug)</source> <translation type="unfinished"/> </message> <message> <location line="-43"/> <source>Specify connection timeout in milliseconds (default: 5000)</source> <translation type="unfinished"/> </message> <message> <location line="+116"/> <source>Unable to sign checkpoint, wrong checkpointkey? </source> <translation type="unfinished"/> </message> <message> <location line="-86"/> <source>Use UPnP to map the listening port (default: 0)</source> <translation type="unfinished"/> </message> <message> <location line="-1"/> <source>Use UPnP to map the listening port (default: 1 when listening)</source> <translation type="unfinished"/> </message> <message> <location line="-26"/> <source>Use proxy to reach tor hidden services (default: same as -proxy)</source> <translation type="unfinished"/> </message> <message> <location line="+47"/> <source>Username for JSON-RPC connections</source> <translation type="unfinished"/> </message> <message> <location line="+51"/> <source>Verifying database integrity...</source> <translation type="unfinished"/> </message> <message> <location line="+44"/> <source>Error: Wallet locked, unable to create transaction!</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds!</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Error: Transaction creation failed!</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Error: The transaction was rejected! This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here.</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Warning</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Information</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>WARNING: syncronized checkpoint violation detected, but skipped!</source> <translation type="unfinished"/> </message> <message> <location line="-1"/> <source>Warning: This version is obsolete, upgrade required!</source> <translation>تحذير هذا الجزء قديم, التجديد مطلوب</translation> </message> <message> <location line="-54"/> <source>wallet.dat corrupt, salvage failed</source> <translation>wallet.dat غير صالح لا يمكن الاسترجاع</translation> </message> <message> <location line="-56"/> <source>Password for JSON-RPC connections</source> <translation type="unfinished"/> </message> <message> <location line="-32"/> <source>Sync time with other nodes. Disable if time on your system is precise e.g. syncing with NTP (default: 1)</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>When creating transactions, ignore inputs with value less than this (default: 0.01)</source> <translation>عند</translation> </message> <message> <location line="+6"/> <source>Output debugging information (default: 0, supplying &lt;category&gt; is optional)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>If &lt;category&gt; is not supplied, output all debugging information.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>&lt;category&gt; can be:</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Enter regression test mode, which uses a special chain in which blocks can be solved instantly. This is intended for regression testing tools and app development.</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>Allow JSON-RPC connections from specified IP address</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Send commands to node running on &lt;ip&gt; (default: 127.0.0.1)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Wait for RPC server to start</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Set the number of threads to service RPC calls (default: 4)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Execute command when the best block changes (%s in cmd is replaced by block hash)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Execute command when a wallet transaction changes (%s in cmd is replaced by TxID)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Require a confirmations for change (default: 0)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Execute command when a relevant alert is received (%s in cmd is replaced by message)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Upgrade wallet to latest format</source> <translation>ارقاء المحفظة الي اخر نسخة</translation> </message> <message> <location line="+1"/> <source>Set key pool size to &lt;n&gt; (default: 100)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Rescan the block chain for missing wallet transactions</source> <translation>اعادة بحث سلسلة الكتلة لايجاد معالمات المحفظة</translation> </message> <message> <location line="+3"/> <source>How thorough the block verification is (0-6, default: 1)</source> <translation>كمية تأكيد الكتل (0-6 التلقائي 1)</translation> </message> <message> <location line="+1"/> <source>Imports blocks from external blk000?.dat file</source> <translation>نقل كتل من ملف blk000.dat خارجي</translation> </message> <message> <location line="+9"/> <source>Use OpenSSL (https) for JSON-RPC connections</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Server certificate file (default: server.cert)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Server private key (default: server.pem)</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>Initialization sanity check failed. CM_CapitalName is shutting down.</source> <translation type="unfinished"/> </message> <message> <location line="+50"/> <source>Error: Wallet unlocked for staking only, unable to create transaction.</source> <translation type="unfinished"/> </message> <message> <location line="+17"/> <source>Error: Disk space is low!</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>This is a pre-release test build - use at your own risk - do not use for mining or merchant applications</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>WARNING: Invalid checkpoint found! Displayed transactions may not be correct! You may need to upgrade, or notify developers.</source> <translation type="unfinished"/> </message> <message> <location line="-174"/> <source>This help message</source> <translation>رسالة المساعدة هذه</translation> </message> <message> <location line="+104"/> <source>Wallet %s resides outside data directory %s.</source> <translation type="unfinished"/> </message> <message> <location line="+37"/> <source>Unable to bind to %s on this computer (bind returned error %d, %s)</source> <translation type="unfinished"/> </message> <message> <location line="-133"/> <source>Connect through socks proxy</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Allow DNS lookups for -addnode, -seednode and -connect</source> <translation type="unfinished"/> </message> <message> <location line="+126"/> <source>Loading addresses...</source> <translation>تحميل العنوان</translation> </message> <message> <location line="-12"/> <source>Error loading blkindex.dat</source> <translation>خظا في تحميل blkindex.dat</translation> </message> <message> <location line="+2"/> <source>Error loading wallet.dat: Wallet corrupted</source> <translation>خطأ عند تنزيل wallet.dat: المحفظة تالفة</translation> </message> <message> <location line="+4"/> <source>Error loading wallet.dat: Wallet requires newer version of CM_CapitalName</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Wallet needed to be rewritten: restart CM_CapitalName to complete</source> <translation>المحفظة يجب أن يعاد كتابته : أعد البلاك كوين لتكتمل</translation> </message> <message> <location line="+1"/> <source>Error loading wallet.dat</source> <translation>خطأ عند تنزيل wallet.dat</translation> </message> <message> <location line="-16"/> <source>Invalid -proxy address: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="-1"/> <source>Unknown network specified in -onlynet: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="-1"/> <source>Unknown -socks proxy version requested: %i</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Cannot resolve -bind address: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Cannot resolve -externalip address: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="-23"/> <source>Invalid amount for -paytxfee=&lt;amount&gt;: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="+60"/> <source>Sending...</source> <translation>ارسال....</translation> </message> <message> <location line="+5"/> <source>Invalid amount</source> <translation>مبلغ خاطئ</translation> </message> <message> <location line="+1"/> <source>Insufficient funds</source> <translation>حسابك لا يكفي</translation> </message> <message> <location line="-40"/> <source>Loading block index...</source> <translation type="unfinished"/> </message> <message> <location line="-110"/> <source>Add a node to connect to and attempt to keep the connection open</source> <translation type="unfinished"/> </message> <message> <location line="+125"/> <source>Unable to bind to %s on this computer. CM_CapitalName is probably already running.</source> <translation type="unfinished"/> </message> <message> <location line="-101"/> <source>Fee per KB to add to transactions you send</source> <translation type="unfinished"/> </message> <message> <location line="+34"/> <source>Minimize weight consumption (experimental) (default: 0)</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>How many blocks to check at startup (default: 500, 0 = all)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Keep at most &lt;n&gt; unconnectable blocks in memory (default: %u)</source> <translation type="unfinished"/> </message> <message> <location line="+11"/> <source>Acceptable ciphers (default: TLSv1.2+HIGH:TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!3DES:@STRENGTH)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Warning: Deprecated argument -debugnet ignored, use -debug=net</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Invalid amount for -mininput=&lt;amount&gt;: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Cannot obtain a lock on data directory %s. CM_CapitalName is probably already running.</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Error initializing wallet database environment %s!</source> <translation type="unfinished"/> </message> <message> <location line="+17"/> <source>Loading wallet...</source> <translation>تحميل المحفظه</translation> </message> <message> <location line="+8"/> <source>Cannot downgrade wallet</source> <translation> لا يمكن خفض المحفظة</translation> </message> <message> <location line="+1"/> <source>Cannot write default address</source> <translation> لا يمكن كتابة العنوان الافتراضي</translation> </message> <message> <location line="+1"/> <source>Rescanning...</source> <translation>إعادة مسح</translation> </message> <message> <location line="+2"/> <source>Done loading</source> <translation>انتهاء التحميل</translation> </message> <message> <location line="-161"/> <source>To use the %s option</source> <translation type="unfinished"/> </message> <message> <location line="+188"/> <source>Error</source> <translation>خطأ</translation> </message> <message> <location line="-18"/> <source>You must set rpcpassword=&lt;password&gt; in the configuration file: %s If the file does not exist, create it with owner-readable-only file permissions.</source> <translation type="unfinished"/> </message> </context> </TS>
realspencerdupre/PoS_Sourcecoin
src/qt/locale/bitcoin_ar.ts
TypeScript
mit
119,926
class RandBnb < Sinatra::Base get '/signin' do redirect '/sessions/new' end get '/sessions/new' do erb :signin end post '/sessions' do user = User.authenticate(params[:email], params[:password]) if user session[:user_id] = user.id session[:new_user] = false redirect("/dashboard") else flash[:error] = "Wrong password" redirect('/sessions/new') end end delete '/sessions' do session.clear flash[:notice] = "Thank you for using RAND-bnb, see you again soon!" redirect ('/sessions/new') end end
sultanhq/RAND-MakersBNB
app/controllers/session_controller.rb
Ruby
mit
580
# [jonaskeutel](http://alexa.amazon.com/#skills/amzn1.ask.skill.4832882a-edf2-4449-8d13-ed6499dbb9af) ![0 stars](../../images/ic_star_border_black_18dp_1x.png)![0 stars](../../images/ic_star_border_black_18dp_1x.png)![0 stars](../../images/ic_star_border_black_18dp_1x.png)![0 stars](../../images/ic_star_border_black_18dp_1x.png)![0 stars](../../images/ic_star_border_black_18dp_1x.png) 0 null *** ### Skill Details * **Invocation Name:** null * **Category:** null * **ID:** amzn1.ask.skill.4832882a-edf2-4449-8d13-ed6499dbb9af * **ASIN:** B01MTUPB0J * **Author:** jonaskeutel * **Release Date:** December 13, 2016 @ 00:50:00 * **In-App Purchasing:** No
dale3h/alexa-skills-list
skills/B01MTUPB0J/README.md
Markdown
mit
659
// // Splines.h // Fingerpaint // // Created by Peter Kämpf on 11.11.14. // Copyright (c) 2014 STABILO digital. All rights reserved. // // Version 1.0 May 18, 2015 // #import "PaintViewData.h" #import "PaintViewLine.h" @interface PaintSplines : NSObject - (instancetype) initWithData:(PaintViewData *)data; - (CGFloat) distanceBetween:(CGPoint)p1 and:(CGPoint)p2; - (NSMutableArray *) splineIncrement:(NSArray *)lineIncr forLine:(PaintViewLine *)newLine; - (void) addLastPointToPath:(CGMutablePathRef)path fromPoints:(NSArray *)points withExtrapolation:(BOOL)extra; - (CGPoint) getPointAtIndex:(NSUInteger)index ofLine:(NSArray *)line; - (NSTimeInterval) getTimeAtIndex:(NSUInteger)index ofLine:(NSArray *)line; - (NSTimeInterval) getFirstTimeOfLine:(NSArray *)line; - (NSTimeInterval) getLastTimeOfLine:(NSArray *)line; @end
STABILOdigital/TouchRecognizerDemoApp
Fingerpaint/PaintSplines.h
C
mit
894
namespace ArchitectNow.ApiStarter.Api.Models.ViewModels { public class LoginResultVm { public string AuthToken { get; set; } public UserVm CurrentUser { get; set; } } }
ArchitectNow/ArchitectNow.ApiStarter
src/ArchitectNow.ApiStarter.Api/Models/ViewModels/LoginResultVm.cs
C#
mit
199
<div> <h3>{{labels[0].details.title}}</h3> <p>{{labels[0].details.selected}}: {{ id }}</p> <form [formGroup]="ficheForm" (ngSubmit)="onSubmit(ficheForm)" novalidate> <div class="field style-4"> <label for="titleInput">{{bookform.title.label}}</label> <input type="text" id="titleInput" placeholder="{{bookform.title.placeholder}}" [formControl]="ficheForm.controls['title']"> </div> <div class="field style-4"> <label for="subTitleInput">{{bookform.subtitle.label}}</label> <input type="text" id="subTitleInput" placeholder="{{bookform.subtitle.placeholder}}" [formControl]="ficheForm.controls['subTitle']"> </div> <div class="field style-4"> <label for="authorInput">{{bookform.author.label}}</label> <input type="text" id="authorInput" placeholder="{{bookform.author.placeholder}}" [formControl]="ficheForm.controls['author']"> </div> <div class="field style-4"> <label for="yearPubInput">{{bookform.year.label}}</label> <input type="number" class="no-spin" id="yearPubInput" placeholder="{{bookform.year.placeholder}}" [formControl]="ficheForm.controls['yearPub']"> </div> <div class="field style-4"> <label for="editorInput">{{bookform.editor.label}}</label> <input type="text" id="editorInput" placeholder="{{bookform.editor.placeholder}}" [formControl]="ficheForm.controls['editor']"> </div> <div class="field style-4"> <label for="collectionInput">{{bookform.collection.label}}</label> <input type="text" id="collectionInput" placeholder="{{bookform.collection.placeholder}}" [formControl]="ficheForm.controls['collection']"> </div> <div class="field style-4"> <label for="pagesInput">{{bookform.pages.label}}</label> <input type="number" class="no-spin" id="pagesInput" placeholder="{{bookform.pages.placeholder}}" [formControl]="ficheForm.controls['pages']"> </div> <div class="field style-4"> <label for="languageInput">{{bookform.language.label}}</label> <input type="text" id="languageInput" placeholder="{{bookform.language.placeholder}}" [formControl]="ficheForm.controls['language']"> </div> <!-- Now the form to add a comment--> <div formArrayName="comments"> <div *ngFor="let comment of ficheForm.controls.comments.controls; let i=index"> <div class="panel-heading"> <div> <span>{{labels[0].details.comment}} {{i + 1}}</span> <button *ngIf="ficheForm.controls.comments.controls.length > 1" (click)="removeComment(i)">(Remove)</button> </div> </div> <div class="panel-body" [formGroupName]="i"> <h4 for="author">{{labels[0].details.author}}</h4> <div class="field style-4"> <input type="text" id="author" placeholder="Author" formControlName="author"> </div> <div> <h4 for="aboutAuthor">{{commentform.aboutauthor.label}}</h4> <textarea id="aboutAuthor" name="aboutAuthor" placeholder="{{commentform.aboutauthor.placeholder}}" formControlName="aboutAuthor"></textarea> </div> <div> <h4 for="aboutGenre">{{commentform.genre.label}}</h4> <textarea id="aboutGenre" placeholder="{{commentform.genre.placeholder}}" formControlName="aboutGenre"></textarea> </div> <div> <h4 for="aboutCadre">{{commentform.context.label}}</h4> <textarea id="aboutCadre" placeholder="{{commentform.context.placeholder}}" formControlName="aboutCadre"></textarea> </div> <div> <h4 for="aboutCharacters">{{commentform.characters.label}}</h4> <textarea id="aboutCharacters" placeholder="{{commentform.characters.placeholder}}" formControlName="aboutCharacters"></textarea> </div> <div> <h4 for="resume">{{commentform.resume.label}}</h4> <textarea id="resume" placeholder="{{commentform.resume.placeholder}}" formControlName="resume"></textarea> </div> <div> <h4 for="extrait">{{commentform.extraits.label}}</h4> <textarea id="extrait" placeholder="{{commentform.extraits.placeholder}}" formControlName="extrait"></textarea> </div> <div> <h4 for="appreciation">{{commentform.appreciation.label}}</h4> <textarea id="appreciation" placeholder="{{commentform.appreciation.placeholder}}" formControlName="appreciation"></textarea> </div> <div> <h4 for="isCompleted">{{commentform.iscompleted.label}}</h4> <md-checkbox class="style-5" id="isCompleted{{i}}" formControlName="isCompleted"> </md-checkbox> </div> </div> </div> </div> <div class="add-comment" style="margin: 2em"> <button type="button" (click)="addComment()" >{{labels[0].details.addcomment}}</button> </div> <div> <div style="margin: 2em"> <button type="submit" class="positive">{{labels[0].details.save}}</button> <button type="reset" class="negative" (click)="revert()" [disabled]="ficheForm.pristine">{{labels[0].details.cancel}}</button> </div> </div> </form> <div style="margin: 2em" *ngIf="!docx"> <button (click)="createFicheDocx()" class="save">{{labels[0].details.docx}}</button> </div> <div style="margin: 2em" *ngIf="docx"> <button (click)="downloadFicheDocx()" class="save">{{labels[0].details.download}}</button> </div> <div class="message-box center"> <div *ngIf="message"> <div class="alert-box {{message.type}}"><span>{{message.text}}</span></div> </div> </div> <p> <button (click)="gotoFiches()">{{labels[0].details.back}}</button> </p> <!--<p>Form value: {{ ficheForm.value | json }}</p>--> </div>
andres0sorio/CodeExperiments
fichemgrfront/src/app/fiches/fiche-detail/fiche-detail.component.html
HTML
mit
5,872
class ExpressionRelationshipType < ActiveRecord::Base attr_accessible :name, :position, :definition, :url acts_as_list end
nabeta/enju_root
app/models/expression_relationship_type.rb
Ruby
mit
127
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8" /> <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" /> <title>index</title> <meta name="description" content="" /> <meta name="author" content="Christoph Oberhofer" /> <meta name="viewport" content="width=device-width; initial-scale=1.0" /> <link rel="stylesheet" type="text/css" href="css/styles.css" /> </head> <body> <header> <div class="headline"> <h1>Add Items</h1> </div> </header> <section id="container" class="container"> <h3>Scan your item</h3> <div class="controls"> <fieldset class="input-group"> <button class="stop">Stop</button> </fieldset> <fieldset class="reader-config-group" style="display: none"> <label> <span>Barcode-Type</span> <select name="decoder_readers"> <option value="upc" selected="selected">UPC</option> </select> </label> <label> <span>Resolution (long side)</span> <select name="input-stream_constraints"> <option value="320x240">320px</option> <option selected="selected" value="640x480">640px</option> <option value="800x600">800px</option> <option value="1280x720">1280px</option> <option value="1600x960">1600px</option> <option value="1920x1080">1920px</option> </select> </label> <label> <span>Patch-Size</span> <select name="locator_patch-size"> <option value="x-small">x-small</option> <option value="small">small</option> <option selected="selected" value="medium">medium</option> <option value="large">large</option> <option value="x-large">x-large</option> </select> </label> <label> <span>Half-Sample</span> <input type="checkbox" checked="checked" name="locator_half-sample" /> </label> <label> <span>Workers</span> <select name="numOfWorkers"> <option value="0">0</option> <option value="1">1</option> <option value="2">2</option> <option selected="selected" value="4">4</option> <option value="8">8</option> </select> </label> </fieldset> </div> <div id="result_strip"> <ul class="thumbnails"></ul> <ul class="collector"></ul> </div> <div id="interactive" class="viewport"></div> </section> <script src="../src/vendor/jquery-1.9.0.min.js" type="text/javascript"></script> <script src="../dist/quagga.js" type="text/javascript"></script> <script src="live_w_locator.js" type="text/javascript"></script> </body> </html>
jinalex/htn-scale
example/live_w_locator.html
HTML
mit
3,322
<?php ############################################################################# # IMDBPHP (c) Giorgos Giagas & Itzchak Rehberg # # written by Giorgos Giagas # # extended & maintained by Itzchak Rehberg <izzysoft AT qumran DOT org> # # http://www.izzysoft.de/ # # ------------------------------------------------------------------------- # # Budget data (c) Isyankar # # ------------------------------------------------------------------------- # # This program is free software; you can redistribute and/or modify it # # under the terms of the GNU General Public License (see doc/LICENSE) # ############################################################################# /* $Id: imdb_budget.class.php 482 2011-10-27 15:24:38Z izzy $ */ require_once (dirname(__FILE__)."/movie_base.class.php"); #============================================================================= #=================================================[ The IMDB class itself ]=== #============================================================================= /** Accessing IMDB Budget Data * @package IMDB * @class imdb_budget * @extends movie_base * @author Isyankar * @author Izzy (izzysoft AT qumran DOT org) * @version $Revision: 482 $ $Date: 2011-10-27 17:24:38 +0200 (Do, 27. Okt 2011) $ */ class imdb_budget extends movie_base { #======================================================[ Common functions ]=== #-----------------------------------------------------------[ Constructor ]--- /** Initialize the class * @constructor imdb_budget * @param string id IMDBID to use for data retrieval */ function __construct($id) { parent::__construct($id); $this->revision = preg_replace('|^.*?(\d+).*$|','$1','$Revision: 482 $'); $this->setid($id); $this->reset_vars(); } #--------------------------------------------------[ Start (over) / Reset ]--- /** Reset page vars * @method protected reset_vars */ protected function reset_vars() { $this->budget = ''; $this->openingWeekend = array(); $this->gross = array(); $this->weekendGross = array(); $this->admissions = array(); $this->filmingDates = array(); } #-------------------------------------------------------------[ Open Page ]--- /** Define page urls * @method protected set_pagename * @param string wt internal name of the page * @return string urlname page URL */ protected function set_pagename($wt) { switch ($wt){ case "BoxOffice" : $urlname="/business"; break; default : $this->page[$wt] = "unknown page identifier"; $this->debug_scalar("Unknown page identifier: $wt"); return false; } return $urlname; } #-----------------------------------------------[ URL to movies main page ]--- /** Set up the URL to the movie title page * @method main_url * @return string url full URL to the current movies main page */ public function main_url(){ return "http://".$this->imdbsite."/title/tt".$this->imdbid()."/"; } #====================================================[ /business page ]=== /* Get budget * @method get_budget * @param ref string budg * @return string * @brief Assuming budget is estimated, and in american dollar * @see IMDB page / (TitlePage) */ private function get_budget(&$budg){ // Tries to get a single entry if (@preg_match("!(.*?)\s*\(estimated\)!ims",$budg,$opWe)){ $result = $opWe[1]; return intval(substr(str_replace(",","",$result), 1)); } else return ""; } // End of get_budget /* Get budget * @method get_budget * @return string * @brief Assuming budget is estimated, and in american dollar * @see IMDB page / (TitlePage) */ public function budget() { if (empty($this->budget)) { if ($this->page["BoxOffice"] == "") $this->openpage ("BoxOffice"); if ($this->page["BoxOffice"] == "cannot open page" ) return $this->budget; // no such page if (@preg_match("!<h5>Budget</h5>\s*\n*(.*?)(<br/>\n*)*<h5!ims",$this->page["BoxOffice"],$bud)) // Opening Weekend $budget = $bud[1]; $this->budget = $this->get_budget($budget); } return $this->budget; } #-------------------------------------------------[ Openingbudget ]--- /** Get opening weekend budget * @method get_openingWeekend * @param ref string listOpening * @return array[0..n] of array[value,country,date,nbScreens] * @see IMDB page */ private function get_openingWeekend(&$listOpening){ $result = array(); $temp = $listOpening; $i = 0; while($temp != NULL){ // Tries to get a single entry if (@preg_match("!(.*?)<br/>!ims",$temp,$opWe)) $entry = $opWe[1]; // Tries to extract the value if (@preg_match("!(.*?)\(!ims",$opWe[1],$value)) $opWe[1] = str_replace($value,"",$opWe[1]); // Tries to extract the country if (@preg_match("!(.*?)\)\s*!ims",$opWe[1],$country)) $opWe[1] = str_replace($country,"",$opWe[1]); // Tries to extract the date if (@preg_match("!\((.*?)\)\s*!ims",$opWe[1],$date)) if (@preg_match("!<a href=\"/date/(.*?)/\">!ims",$date[1],$dayMonth)) if (@preg_match("!<a href=\"/year/(.*?)/\">!ims",$date[1],$year)) $dateValue = $year[1].'-'.$dayMonth[1]; $opWe[1] = str_replace($date,"",$opWe[1]); // Tries to extract the number of screens if (@preg_match("!\((.*?)\)\s*!ims",$opWe[1],$nbScreen)) $opWe[1] = str_replace($nbScreen,"",$opWe[1]); // Parse the results in an array $result[$i] = array( 'value' => $value[1], 'country' => $country[1], 'date' => $dateValue, 'nbScreens' => intval(str_replace(",","",$nbScreen[1])) ); // Remove the entry from the list of entries if (@preg_match("!<br/>(.*?)$!ims",$temp,$temp)) $temp = $temp[1]; $i++; } return $result; } // End of get_openingWeekend /** Opening weekend budget * @method openingWeekend * @return array[0..n] of array[value,country,date,nbScreens] * @see IMDB page */ public function openingWeekend() { if (empty($this->openingWeekend)) { if ($this->page["BoxOffice"] == "") $this->openpage ("BoxOffice"); if ($this->page["BoxOffice"] == "cannot open page" ) return $this->openingWeekend; // no such page if (@preg_match("!<h5>Opening Weekend</h5>\n*(.*?)<br/>\n*<h5!ims",$this->page["BoxOffice"],$opWe)) // Opening Weekend $openingWeekend = $opWe[1]; $this->openingWeekend = $this->get_openingWeekend($openingWeekend); } return $this->openingWeekend; } #-------------------------------------------------[ Gross ]--- /** Get gross budget * @method get_gross * @param ref string listGross * @return array[0..n] of array[value,country,date] * @see IMDB page / (TitlePage) */ private function get_gross(&$listGross) { $result = array(); $temp = $listGross; $i = 0; while($temp != NULL){ // Tries to get a single entry if (@preg_match("!(.*?)<br/>!ims",$temp,$gr)) $entry = $gr[1]; //echo 'ici'.$entry.'ici'; // Tries to extract the value if (@preg_match("!(.*?)\(!ims",$gr[1],$value)) $gr[1] = str_replace($value,"",$gr[1]); // Tries to extract the country if (@preg_match("!(.*?)\)\s*!ims",$gr[1],$country)) $gr[1] = str_replace($country,"",$gr[1]); // Tries to extract the date if (@preg_match("!\((.*?)\)\s*!ims",$gr[1],$date)) if (@preg_match("!<a href=\"/date/(.*?)/\">!ims",$date[1],$dayMonth)) if (@preg_match("!<a href=\"/year/(.*?)/\">!ims",$date[1],$year)) $dateValue = $year[1].'-'.$dayMonth[1]; $gr[1] = str_replace($date,"",$gr[1]); // Parse the results in an array $result[$i] = array( 'value' => $value[1], 'country' => $country[1], 'date' => $dateValue, ); // Remove the entry from the list of entries if (@preg_match("!<br/>(.*?)$!ims",$temp,$temp)) $temp = $temp[1]; $i++; } return $result; } // End of get_gross /** Get gross budget * @method gross * @return array[0..n] of array[value,country,date] * @see IMDB page / (TitlePage) */ public function gross() { if (empty($this->gross)) { if ($this->page["BoxOffice"] == "") $this->openpage ("BoxOffice"); if ($this->page["BoxOffice"] == "cannot open page" ) return $this->gross; // no such page if (@preg_match("!<h5>Gross</h5>\n*(.*?)<br/>\n*<h5!ims",$this->page["BoxOffice"],$gr)) // Gross $gross = $gr[1]; $this->gross = $this->get_gross($gross); } return $this->gross; } #-------------------------------------------------[ Weekend Gross ]--- /** Get weekend gross budget * @method get_weekendGross * @param ref string listweekendGross * @return array[0..n] of array[value,country,date,nbScreens] * @see IMDB page / (TitlePage) */ private function get_weekendGross(&$listweekendGross){ $result = array(); $temp = $listweekendGross; $i = 0; while($temp != NULL){ // Tries to get a single entry if (@preg_match("!(.*?)<br/>!ims",$temp,$weGr)) $entry = $weGr[1]; // Tries to extract the value if (@preg_match("!(.*?)\(!ims",$weGr[1],$value)) $weGr[1] = str_replace($value,"",$weGr[1]); // Tries to extract the country if (@preg_match("!(.*?)\)\s*!ims",$weGr[1],$country)) $weGr[1] = str_replace($country,"",$weGr[1]); // Tries to extract the date if (@preg_match("!\((.*?)\)\s*!ims",$weGr[1],$date)) if (@preg_match("!<a href=\"/date/(.*?)/\">!ims",$date[1],$dayMonth)) if (@preg_match("!<a href=\"/year/(.*?)/\">!ims",$date[1],$year)) $dateValue = $year[1].'-'.$dayMonth[1]; $weGr[1] = str_replace($date,"",$weGr[1]); // Tries to extract the number of screens if (@preg_match("!\((.*?)\)\s*!ims",$weGr[1],$nbScreen)) $weGr[1] = str_replace($nbScreen,"",$weGr[1]); // Parse the results in an array $result[$i] = array( 'value' => $value[1], 'country' => $country[1], 'date' => $dateValue, 'nbScreens' => intval(str_replace(",","",$nbScreen[1])) ); // Remove the entry from the list of entries if (@preg_match("!<br/>(.*?)$!ims",$temp,$temp)) $temp = $temp[1]; $i++; } return $result; } // End of get_weekendGross /** Get weekend gross budget * @method weekendGross * @return array[0..n] of array[value,country,date,nbScreen] * @see IMDB page / (TitlePage) */ public function weekendGross() { if (empty($this->weekendGross)) { if ($this->page["BoxOffice"] == "") $this->openpage ("BoxOffice"); if ($this->page["BoxOffice"] == "cannot open page" ) return $this->weekendGross; // no such page if (@preg_match("!<h5>Weekend Gross</h5>\n*(.*?)<br/>\n*<h5!ims",$this->page["BoxOffice"],$weGr)) // Weekend Gross $weekendGross = $weGr[1]; $this->weekendGross = $this->get_weekendGross($weekendGross); } return $this->weekendGross; } // End of weekendGross #-------------------------------------------------[ Admissions ]--- /** Get admissions budget * @method get_admissions * @param ref string listAdmissions * @return array[0..n] of array[value,country,date] * @see IMDB page / (TitlePage) */ private function get_admissions(&$listAdmissions) { $result = array(); $temp = $listAdmissions; $i = 0; while($temp != NULL){ // Tries to get a single entry if (@preg_match("!(.*?)<br/>!ims",$temp,$adm)) $entry = $adm[1]; // Tries to extract the value if (@preg_match("!(.*?)\(!ims",$adm[1],$value)) $adm[1] = str_replace($value,"",$adm[1]); // Tries to extract the country if (@preg_match("!(.*?)\)\s*!ims",$adm[1],$country)) $adm[1] = str_replace($country,"",$adm[1]); // Tries to extract the date if (@preg_match("!\((.*?)\)\s*!ims",$adm[1],$date)) if (@preg_match("!<a href=\"/date/(.*?)/\">!ims",$date[1],$dayMonth)) if (@preg_match("!<a href=\"/year/(.*?)/\">!ims",$date[1],$year)) $dateValue = $year[1].'-'.$dayMonth[1]; $adm[1] = str_replace($date,"",$adm[1]); // Parse the results in an array $result[$i] = array( 'value' => intval(str_replace(",","",$value[1])), 'country' => $country[1], 'date' => $dateValue, ); // Remove the entry from the list of entries if (@preg_match("!<br/>(.*?)$!ims",$temp,$temp)) $temp = $temp[1]; $i++; } return $result; } // End of get_admissions /** Get admissions budget * @method admissions * @return array[0..n] of array[value,country,date] * @see IMDB page / (TitlePage) */ public function admissions() { if (empty($this->admissions)) { if ($this->page["BoxOffice"] == "") $this->openpage ("BoxOffice"); if ($this->page["BoxOffice"] == "cannot open page" ) return $this->admissions; // no such page if (@preg_match("!<h5>Admissions</h5>\n*(.*?)<br/>\n*<h5!ims",$this->page["BoxOffice"],$weGr)) // Admissions $admissions = $weGr[1]; $this->admissions = $this->get_admissions($admissions); } return $this->admissions; } // End of admissions #-------------------------------------------------[ Filming Dates ]--- /** Get filming dates * @method get_filmingDates * @param ref string listFilmingDates * @return array[0..n] of array[beginning,end] * Time format : YYYY-MM-DD * @see IMDB page / (TitlePage) */ function get_filmingDates($listFilmingDates){ $result = array(); $temp = $listFilmingDates; // Tries to get the beginning if (@preg_match("!(.*?)&nbsp;-!ims",$temp,$beginning)) if (@preg_match("#[A-Z0-9]#",$beginning[1])) { // Check if there is a date if (@preg_match("!<a(.*?)&nbsp;-!ims",$temp)) { // Check if there is a linked date if (@preg_match("!<a href=\"/date/(.*?)/\">!ims",$beginning[1],$dayMonthB)) if (@preg_match("!<a href=\"/year/(.*?)/\">!ims",$beginning[1],$yearB)) $beginningDate = $yearB[1].'-'.$dayMonthB[1]; } else if (@preg_match("!(.*?)&nbsp;-!ims",$temp,$beginning)) { $beginningDate = date('Y-m-d', strtotime($beginning[1])); } } // Tries to get the end if (@preg_match("!-&nbsp;(.*?)$!ims",$temp,$end)) if (@preg_match("#[A-Z0-9]#",$end[1])) { // Check if there is a date if (@preg_match("!-&nbsp;<a(.*?)!ims",$temp)) { // Check if there is a linked date if (@preg_match("!<a href=\"/date/(.*?)/\">!ims",$end[1],$dayMonthE)) if (@preg_match("!<a href=\"/year/(.*?)/\">!ims",$end[1],$yearE)) $endDate = $yearE[1].'-'.$dayMonthE[1]; } else if (@preg_match("!-&nbsp;(.*?)$!ims",$temp,$end)) { $endDate = date('Y-m-d', strtotime($end[1])); } } // Parse the results in an array $result = array( 'beginning' => $beginningDate, 'end' => $endDate ); return $result; } // End of get_filmingDates /** Get filming dates * @method filmingDates * @return array[0..n] of array[beginning,end] * Time format : YYYY-MM-DD * @see IMDB page / (TitlePage) */ public function filmingDates() { if (empty($this->filmingDates)) { if ($this->page["BoxOffice"] == "") $this->openpage ("BoxOffice"); if ($this->page["BoxOffice"] == "cannot open page" ) return $this->filmingDates; // no such page if (@preg_match("!<h5>Filming Dates</h5>\s*\n*(.*?)(<br/>\n*)*<h5!ims",$this->page["BoxOffice"],$filDates)) // Filming Dates $filmingDates = $filDates[1]; $this->filmingDates = $this->get_filmingDates($filmingDates); } return $this->filmingDates; } // End of filmingDates } // end class imdb_budget ?>
rnavarro/Movie-Magic
imdbphp2/imdb_budget.class.php
PHP
mit
15,927
tree_view ========= This is testing project to show my coding style to potential clients Functionality description ========================= Tree structure should be edited, stored and showed in usual Ruby on Rails application with classic RDBMS in the backend. Search field should let user to filter out unneeded elements. Editing and adding new elements should be validated. Empty result should be processed in user-friendly way. Application should be able to work with structures with any number of levels. Code should be covered with tests.
shine/tree_view
README.md
Markdown
mit
549
/*jshint node: true, eqnull: true*/ exports.purge = require('./lib/purge').AkamaiPurge;
patrickkettner/grunt-akamai-clear
node_modules/akamai/akamai.js
JavaScript
mit
88
<!DOCTYPE html> <html xmlns:msxsl="urn:schemas-microsoft-com:xslt"> <head> <meta content="en-us" http-equiv="Content-Language" /> <meta content="text/html; charset=utf-16" http-equiv="Content-Type" /> <title _locid="PortabilityAnalysis0">.NET Portability Report</title> <style> /* Body style, for the entire document */ body { background: #F3F3F4; color: #1E1E1F; font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif; padding: 0; margin: 0; } /* Header1 style, used for the main title */ h1 { padding: 10px 0px 10px 10px; font-size: 21pt; background-color: #E2E2E2; border-bottom: 1px #C1C1C2 solid; color: #201F20; margin: 0; font-weight: normal; } /* Header2 style, used for "Overview" and other sections */ h2 { font-size: 18pt; font-weight: normal; padding: 15px 0 5px 0; margin: 0; } /* Header3 style, used for sub-sections, such as project name */ h3 { font-weight: normal; font-size: 15pt; margin: 0; padding: 15px 0 5px 0; background-color: transparent; } h4 { font-weight: normal; font-size: 12pt; margin: 0; padding: 0 0 0 0; background-color: transparent; } /* Color all hyperlinks one color */ a { color: #1382CE; } /* Paragraph text (for longer informational messages) */ p { font-size: 10pt; } /* Table styles */ table { border-spacing: 0 0; border-collapse: collapse; font-size: 10pt; } table th { background: #E7E7E8; text-align: left; text-decoration: none; font-weight: normal; padding: 3px 6px 3px 6px; } table td { vertical-align: top; padding: 3px 6px 5px 5px; margin: 0px; border: 1px solid #E7E7E8; background: #F7F7F8; } .NoBreakingChanges { color: darkgreen; font-weight:bold; } .FewBreakingChanges { color: orange; font-weight:bold; } .ManyBreakingChanges { color: red; font-weight:bold; } .BreakDetails { margin-left: 30px; } .CompatMessage { font-style: italic; font-size: 10pt; } .GoodMessage { color: darkgreen; } /* Local link is a style for hyperlinks that link to file:/// content, there are lots so color them as 'normal' text until the user mouse overs */ .localLink { color: #1E1E1F; background: #EEEEED; text-decoration: none; } .localLink:hover { color: #1382CE; background: #FFFF99; text-decoration: none; } /* Center text, used in the over views cells that contain message level counts */ .textCentered { text-align: center; } /* The message cells in message tables should take up all avaliable space */ .messageCell { width: 100%; } /* Padding around the content after the h1 */ #content { padding: 0px 12px 12px 12px; } /* The overview table expands to width, with a max width of 97% */ #overview table { width: auto; max-width: 75%; } /* The messages tables are always 97% width */ #messages table { width: 97%; } /* All Icons */ .IconSuccessEncoded, .IconInfoEncoded, .IconWarningEncoded, .IconErrorEncoded { min-width: 18px; min-height: 18px; background-repeat: no-repeat; background-position: center; } /* Success icon encoded */ .IconSuccessEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconSuccess#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAABPElEQVR4Xp1Tv0vDUBi8FqeA4NpBcBLcWnQSApncOnTo4FSnjP0DsnXpH5CxiwbHDg4Zuj4oOEXiJgiC4FDcCkLWmIMc1Pfw+eMgQ77v3Xf3Pe51YKGqqisAEwCR1TIAsiAIblSo6xrdHeJR85Xle3mdmCQKb0PsfqyxxzM8K15HZADl/H5+sHpZwYfxyRjTs+kWwKBx8yoHd2mRiuzF8mkJniWH/13u3Fjrs/EdhsdDFHGB/DLXEJBDLh1MWPAhPo1BLB4WX5yQywHR+m3tVe/t97D52CB/ziG0nIgD/qDuYg8WuCcVZ2YGwlJ3YDugkpR/VNcAEx6GEKhERSr71FuO4YCM4XBdwKvecjIlkSnsO0Hyp/GxSeJAdzBKzpOtnPwyyiPdAZhpZptT04tU+zk7s8czeges//s5C5+CwqrR4/gw+AAAAABJRU5ErkJggg==); } /* Information icon encoded */ .IconInfoEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconInformation#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAABHElEQVR4Xs2TsUoDQRRF7wwoziokjZUKadInhdhukR9YP8DMX1hYW+QvdsXa/QHBbcXC7W0CamWTQnclFutceIQJwwaWNLlwm5k5d94M76mmaeCrrmsLYOocY12FcxZFUeozCqKqqgYA8uevv1H6VuPxcwlfk5N92KHBxfFeCSAxxswlYAW/Xr989x/mv9gkhtyMDhcAxgzRsp7flj8B/HF1RsMXq+NZMkopaHe7lbKxQUEIGbKsYNoGn969060hZBkQex/W8oRQwsQaW2o3Ago2SVcJUzAgY3N0lTCZZm+zPS8HB51gMmS1DEYyOz9acKO1D8JWTlafKIMxdhvlfdyT94Vv5h7P8Ky7nQzACmhvKq3zk3PjW9asz9D/1oigecsioooAAAAASUVORK5CYII=); } /* Warning icon encoded */ .IconWarningEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconWarning#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAA7EAAAOxAGVKw4bAAAAx0lEQVR4XpWSMQ7CMAxFf4xAyBMLCxMrO8dhaBcuwdCJS3RJBw7SA/QGTCxdWJgiQYWKXJWKIXHIlyw5lqr34tQgEOdcBsCOx5yZK3hCCKdYXneQkh4pEfqzLfu+wVDSyyzFoJjfz9NB+pAF+eizx2Vruts0k15mPgvS6GYvpVtQhB61IB/dk6AF6fS4Ben0uIX5odtFe8Q/eW1KvFeH4e8khT6+gm5B+t3juyDt7n0jpe+CANTd+oTUjN/U3yVaABnSUjFz/gFq44JaVSCXeQAAAABJRU5ErkJggg==); } /* Error icon encoded */ .IconErrorEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconError#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAABQElEQVR4XqWTvUoEQRCE6wYPZUA80AfwAQz23uCMjA7MDRQEIzPBVEyNTQUFIw00vcQTTMzuAh/AxEQQT8HF/3G/oGGnEUGuoNnd6qoZuqltyKEsyzVJq5I6rnUp6SjGeGhESikzzlc1eL7opfuVbrqbU1Zw9NCgtQMaZpY0eNnaaL2fHusvTK5vKu7sjSS1Y4y3QUA6K3e3Mau5UFDyMP7tYF9o8cAHZv68vipoIJg971PZIZ5HiwdvYGGvFVFHmGmZ2MxwmQYPXubPl9Up0tfoMQGetXd6mRbvhBw+boZ6WF7Mbv1+GsHRk0fQmPAH1GfmZirbCfDJ61tw3Px8/8pZsPAG4jlVhcPgZ7adwNWBB68lkRQWFiTgFlbnLY3DGGM7izIJIyT/jjIvEJw6fdJTc6krDzh6aMwMP9bvDH4ADSsa9uSWVJkAAAAASUVORK5CYII=); } </style> </head> <body> <h1 _locid="PortabilityReport">.NET Portability Report</h1> <div id="content"> <div id="submissionId" style="font-size:8pt;"> <p> <i> Submission Id&nbsp; 56989926-ca6e-43a1-a5e6-451ca51fd20e </i> </p> </div> <h2 _locid="SummaryTitle"> <a name="Portability Summary"></a>Portability Summary </h2> <div id="summary"> <table> <tbody> <tr> <th>Assembly</th> <th>ASP.NET 5,Version=v1.0</th> <th>Windows,Version=v8.1</th> <th>.NET Framework,Version=v4.6</th> <th>Windows Phone,Version=v8.1</th> </tr> <tr> <td><strong><a href="#Commons.Locale.Helpers.pt_BR">Commons.Locale.Helpers.pt_BR</a></strong></td> <td class="text-center">100.00 %</td> <td class="text-center">100.00 %</td> <td class="text-center">100.00 %</td> <td class="text-center">100.00 %</td> </tr> </tbody> </table> </div> <div id="details"> </div> </div> </body> </html>
kuhlenh/port-to-core
Reports/co/commons.locale.helpers.pt_br.1.1.10/Commons.Locale.Helpers.pt_BR-net35.html
HTML
mit
9,671
() => { const [startDate, setStartDate] = useState(new Date()); let handleColor = (time) => { return time.getHours() > 12 ? "text-success" : "text-error"; }; return ( <DatePicker showTimeSelect selected={startDate} onChange={(date) => setStartDate(date)} timeClassName={handleColor} /> ); };
Hacker0x01/react-datepicker
docs-site/src/examples/customTimeClassName.js
JavaScript
mit
340
'use strict'; var arg = require('../util').arg; var oneDHeightmapFactory = require('../1d-heightmap'); var rng = require('../rng'); var random = rng.float; var randomRange = rng.range; var randomRangeInt = rng.rangeInt; var randomSpacedIndexes = rng.spacedIndexes; var interpolators = require('../interpolators'); var math = require('../math'); var getDistance = math.getDistance; var getNormalizedVector = math.getNormalizedVector; module.exports = { keyIndexes: createKeyIndexes, fromKeyIndexes: fromKeyIndexes, interpolateKeyIndexes: interpolateKeyIndexes, addKeyIndexes: addKeyIndexes, addDisplacementKeyIndexes: addDisplacementKeyIndexes, } function createKeyIndexes(settings) { var defaults = { length: null, startHeight: undefined, endHeight: undefined, minSpacing: undefined, maxSpacing: undefined, interpolator: null, min: 0, max: 100, minSlope: undefined, maxSlope: undefined, }; var s = Object.assign({}, defaults, settings); var length = s.length; var startHeight = s.startHeight; var endHeight = s.endHeight; var minSpacing = arg(s.minSpacing, length * 0.1); var maxSpacing = arg(s.maxSpacing, length * 0.1); var minHeight = s.min; var maxHeight = s.max; var minSlope = s.minSlope; var maxSlope = s.maxSlope; var keyIndexes = randomSpacedIndexes(length, minSpacing, maxSpacing); var prev; var out = keyIndexes.map(function(index, i, data) { var value; if (i === 0 && startHeight !== undefined) { value = startHeight; } else { value = getValue(prev, index, minHeight, maxHeight, minSlope, maxSlope); } var result = { index: index, value: value, }; prev = result; return result; }); if (endHeight !== undefined) { out[out.length - 1].value = endHeight; } return out; } function getValue(prev, index, minHeight, maxHeight, minSlope, maxSlope) { var min = minHeight; var max = maxHeight; if (prev !== undefined) { var prevVal = prev.value; var distance = index - prev.index; if (minSlope !== undefined) { min = Math.max(min, prevVal + (distance * minSlope)); } if (maxSlope !== undefined) { max = Math.min(max, prevVal + (distance * maxSlope)); } } return randomRangeInt(min, max); } function interpolateKeyIndexes(keyIndexes, interpolator) { var results = []; interpolator = arg(interpolator, interpolators.linear); keyIndexes.forEach(function(item, i) { results.push(item.value); var next = keyIndexes[i + 1]; if (!next) { return; } var curerntKeyIndex = item.index; var nextKeyIndex = next.index; var wavelength = Math.abs(nextKeyIndex - curerntKeyIndex - 1); var a = item.value; var b = next.value; for (var j = 0; j < wavelength; j++) { var x = j / wavelength; var interpolatedVal = interpolator(a, b, x); results.push(interpolatedVal); } }); return results; } function fromKeyIndexes(keyIndexes, interpolator) { return oneDHeightmapFactory({ data: this.interpolateKeyIndexes(keyIndexes, interpolator) }); } function addKeyIndexes(settings) { var defaults = { keyIndexes: null, // position on line determined by percent of distance between points posRatioMin: 0.33, posRatioMax: 0.66, // distance from pos on line determined by percent of distance between points distRatioMin: 0.1, distRatioMax: 0.2, // absolute min / max distance distMin: undefined, distMax: undefined, direction: undefined, upDirection: undefined, downDirection: undefined, upPosRatioMin: undefined, upPosRatioMax: undefined, downPosRatioMin: undefined, downPosRatioMax: undefined, upDistRatioMin: undefined, upDistRatioMax: undefined, downDistRatioMin: undefined, downDistRatioMax: undefined, }; var s = Object.assign({}, defaults, settings); var keyIndexes = s.keyIndexes; var result = []; keyIndexes.forEach(function(item, i, data) { var next = data[i + 1]; if (!next) { result.push(item); return; } var splitSettings = Object.assign({ left: item, right: next, }, settings); var add = splitKeyIndexes(splitSettings); result.push(item); result.push(add); }); return result; } function splitKeyIndexes(settings) { var defaults = { left: null, right: null, // position on line determined by percent of distance between points posRatioMin: 0.33, posRatioMax: 0.66, // distance from pos on line determined by percent of distance between points distRatioMin: 0.1, distRatioMax: 0.2, // absolute min / max distance distMin: undefined, distMax: undefined, direction: undefined, upDirection: undefined, downDirection: undefined, upPosRatioMin: undefined, upPosRatioMax: undefined, downPosRatioMin: undefined, downPosRatioMax: undefined, upDistRatioMin: undefined, upDistRatioMax: undefined, downDistRatioMin: undefined, downDistRatioMax: undefined, }; var s = Object.assign({}, defaults, settings); var left = s.left; var right = s.right; var slopeUp = left.value < right.value; var posRatioMin = s.posRatioMin; var posRatioMax = s.posRatioMax; var distRatioMin = s.distRatioMin; var distRatioMax = s.distRatioMax; var direction = s.direction; var distMin = s.distMin; var distMax = s.distMax; if (slopeUp) { posRatioMin = arg(s.upPosRatioMin, posRatioMin); posRatioMax = arg(s.upPosRatioMax, posRatioMax); distRatioMin = arg(s.upDistRatioMin, distRatioMin); distRatioMax = arg(s.upDistRatioMax, distRatioMax); direction = arg(s.upDirection, direction); } else { posRatioMin = arg(s.downPosRatioMin, posRatioMin); posRatioMax = arg(s.downPosRatioMax, posRatioMax); distRatioMin = arg(s.downDistRatioMin, distRatioMin); distRatioMax = arg(s.downDistRatioMax, distRatioMax); direction = arg(s.downDirection, direction); } direction = arg(direction, random() < 0.5 ? 'up' : 'down'); var posRatio = randomRange(posRatioMin, posRatioMax); var distRatio = randomRange(distRatioMin, distRatioMax); var a = { x: left.index, y: left.value, }; var b = { x: right.index, y: right.value, }; var p = generateMidPoint(a, b, posRatio, distRatio, direction, distMin, distMax); return { value: p.y, index: p.x }; } function generateMidPoint(a, b, cPosRatio, distRatio, direction, distMin, distMax) { var vDist = getDistance(a, b); var v = getNormalizedVector(a, b, vDist); var dx = b.x - a.x; var dy = b.y - a.y; // c is a point on line ab at given ratio var c = { x: (dx * cPosRatio), y: (dy * cPosRatio) }; // distance proportional to ab length var dist = vDist * distRatio; if (distMin !== undefined) { dist = Math.max(distMin); } if (distMax !== undefined) { dist = Math.min(distMax); } var vDir = vectorRotate90(v, direction); var d = { x: vDir.x * dist, y: vDir.y * dist, }; // width of line ab var ab = dx; // postion of d offset from c var dC = c.x + d.x; // scale to fit horizontal bounds of ab var scale = false; // d left of a if (dC < 0) { scale = -(c.x / d.x); } // d right of b else if (dC > ab) { scale = (dx - c.x) / (d.x); } if (scale !== false) { d.x *= scale; d.y *= scale; } // add offsets to d d.x += c.x + a.x; d.y += c.y + a.y; d.x = Math.round(d.x); if (d.x === a.x) { d.x += 1; } if (d.x === b.x) { d.x -= 1; } // set c offset for debug // c.x += a.x; // c.y += a.y; return d; } function vectorRotate90(v, direction){ if (direction === 'left' || direction === 'up') { return { x: -v.y, y: v.x, } } else if (direction === 'right' || direction === 'down') { return { x: v.y, y: -v.x, } } } function addDisplacementKeyIndexes(settings) { var defaults = { keyIndexes: null, startingDisplacement: 50, roughness: 0.77, maxIterations: 1, calcDisplacement: defaultCalcDisplacement, }; var s = Object.assign({}, defaults, settings); var keyIndexes = s.keyIndexes; var roughness = s.roughness; var maxIterations = s.maxIterations; var calcDisplacement = s.calcDisplacement; var startingDisplacement = s.startingDisplacement; keyIndexes = keyIndexes.map(function(item) { return Object.assign({}, item); }); var results = []; keyIndexes.forEach(function(item, i, data) { var next = data[i + 1]; if (!next) { results.push(item); return; } var arr = split(item, next, startingDisplacement); results = results.concat(item, arr); }); return results; function defaultCalcDisplacement(current, left, right, iteration) { if (iteration == 1) { return current; } return current * roughness; } function split(left, right, displacement, iteration) { iteration = iteration || 0; iteration++; if (left.index + 1 == right.index) { return false; } displacement = calcDisplacement(displacement, left, right, iteration); var mid = splitNodes(left, right, displacement); if (iteration >= maxIterations) { return mid; } var result = []; var canSplitLeft = left.index + 1 !== mid.index; var canSplitRight = right.index - 1 !== mid.index; if (canSplitLeft) { var leftSplit = split(left, mid, displacement, iteration); if (leftSplit) { result = result.concat(leftSplit); } } result.push(mid); if (canSplitRight) { var rightSplit = split(mid, right, displacement, iteration); if (rightSplit) { result = result.concat(rightSplit); } } return result; } } function splitNodes(left, right, displacement) { var midIndex = Math.floor((left.index + right.index) * 0.5); var midValue = (left.value + right.value) * 0.5; var adjustment = (randomRange(-1, 1) * displacement); return { index: midIndex, value: midValue + adjustment, }; }
unstoppablecarl/1d-heightmap
src/key-indexes/index.js
JavaScript
mit
11,619
namespace PaintShop.Models { using System.Security.Claims; using System.Threading.Tasks; using Microsoft.AspNet.Identity; using Microsoft.AspNet.Identity.EntityFramework; public class ApplicationUser : IdentityUser { public async Task<ClaimsIdentity> GenerateUserIdentityAsync(UserManager<ApplicationUser> manager) { // Note the authenticationType must match the one defined in CookieAuthenticationOptions.AuthenticationType var userIdentity = await manager.CreateIdentityAsync(this, DefaultAuthenticationTypes.ApplicationCookie); // Add custom user claims here return userIdentity; } } }
georgipyaramov/PaintShop
PaintShop/PaintShop.Models/ApplicationUser.cs
C#
mit
693
#include <sol/compatibility/compat-5.3.h> #include <stddef.h> #include <stdlib.h> #include <string.h> #include <ctype.h> #include <errno.h> #include <stdio.h> /* don't compile it again if it already is included via compat53.h */ #ifndef KEPLER_PROJECT_COMPAT53_C_ #define KEPLER_PROJECT_COMPAT53_C_ /* definitions for Lua 5.1 only */ #if defined(LUA_VERSION_NUM) && LUA_VERSION_NUM == 501 #ifndef COMPAT53_FOPEN_NO_LOCK #if defined(_MSC_VER) #define COMPAT53_FOPEN_NO_LOCK 1 #else /* otherwise */ #define COMPAT53_FOPEN_NO_LOCK 0 #endif /* VC++ only so far */ #endif /* No-lock fopen_s usage if possible */ #if defined(_MSC_VER) && COMPAT53_FOPEN_NO_LOCK #include <share.h> #endif /* VC++ _fsopen for share-allowed file read */ #ifndef COMPAT53_HAVE_STRERROR_R #if defined(__GLIBC__) || defined(_POSIX_VERSION) || defined(__APPLE__) || (!defined(__MINGW32__) && defined(__GNUC__) && (__GNUC__ < 6)) #define COMPAT53_HAVE_STRERROR_R 1 #else /* none of the defines matched: define to 0 */ #define COMPAT53_HAVE_STRERROR_R 0 #endif /* have strerror_r of some form */ #endif /* strerror_r */ #ifndef COMPAT53_HAVE_STRERROR_S #if defined(_MSC_VER) || (defined(__STDC_VERSION__) && __STDC_VERSION__ >= 201112L) || (defined(__STDC_LIB_EXT1__) && __STDC_LIB_EXT1__) #define COMPAT53_HAVE_STRERROR_S 1 #else /* not VC++ or C11 */ #define COMPAT53_HAVE_STRERROR_S 0 #endif /* strerror_s from VC++ or C11 */ #endif /* strerror_s */ #ifndef COMPAT53_LUA_FILE_BUFFER_SIZE #define COMPAT53_LUA_FILE_BUFFER_SIZE 4096 #endif /* Lua File Buffer Size */ static char* compat53_strerror(int en, char* buff, size_t sz) { #if COMPAT53_HAVE_STRERROR_R /* use strerror_r here, because it's available on these specific platforms */ if (sz > 0) { buff[0] = '\0'; /* we don't care whether the GNU version or the XSI version is used: */ if (strerror_r(en, buff, sz)) { /* Yes, we really DO want to ignore the return value! * GCC makes that extra hard, not even a (void) cast will do. */ } if (buff[0] == '\0') { /* Buffer is unchanged, so we probably have called GNU strerror_r which * returned a static constant string. Chances are that strerror will * return the same static constant string and therefore be thread-safe. */ return strerror(en); } } return buff; /* sz is 0 *or* strerror_r wrote into the buffer */ #elif COMPAT53_HAVE_STRERROR_S /* for MSVC and other C11 implementations, use strerror_s since it's * provided by default by the libraries */ strerror_s(buff, sz, en); return buff; #else /* fallback, but strerror is not guaranteed to be threadsafe due to modifying * errno itself and some impls not locking a static buffer for it ... but most * known systems have threadsafe errno: this might only change if the locale * is changed out from under someone while this function is being called */ (void)buff; (void)sz; return strerror(en); #endif } COMPAT53_API int lua_absindex(lua_State* L, int i) { if (i < 0 && i > LUA_REGISTRYINDEX) i += lua_gettop(L) + 1; return i; } static void compat53_call_lua(lua_State* L, char const code[], size_t len, int nargs, int nret) { lua_rawgetp(L, LUA_REGISTRYINDEX, (void*)code); if (lua_type(L, -1) != LUA_TFUNCTION) { lua_pop(L, 1); if (luaL_loadbuffer(L, code, len, "=none")) lua_error(L); lua_pushvalue(L, -1); lua_rawsetp(L, LUA_REGISTRYINDEX, (void*)code); } lua_insert(L, -nargs - 1); lua_call(L, nargs, nret); } static const char compat53_arith_code[] = "local op,a,b=...\n" "if op==0 then return a+b\n" "elseif op==1 then return a-b\n" "elseif op==2 then return a*b\n" "elseif op==3 then return a/b\n" "elseif op==4 then return a%b\n" "elseif op==5 then return a^b\n" "elseif op==6 then return -a\n" "end\n"; COMPAT53_API void lua_arith(lua_State* L, int op) { if (op < LUA_OPADD || op > LUA_OPUNM) luaL_error(L, "invalid 'op' argument for lua_arith"); luaL_checkstack(L, 5, "not enough stack slots"); if (op == LUA_OPUNM) lua_pushvalue(L, -1); lua_pushnumber(L, op); lua_insert(L, -3); compat53_call_lua(L, compat53_arith_code, sizeof(compat53_arith_code) - 1, 3, 1); } static const char compat53_compare_code[] = "local a,b=...\n" "return a<=b\n"; COMPAT53_API int lua_compare(lua_State* L, int idx1, int idx2, int op) { int result = 0; switch (op) { case LUA_OPEQ: return lua_equal(L, idx1, idx2); case LUA_OPLT: return lua_lessthan(L, idx1, idx2); case LUA_OPLE: luaL_checkstack(L, 5, "not enough stack slots"); idx1 = lua_absindex(L, idx1); idx2 = lua_absindex(L, idx2); lua_pushvalue(L, idx1); lua_pushvalue(L, idx2); compat53_call_lua(L, compat53_compare_code, sizeof(compat53_compare_code) - 1, 2, 1); result = lua_toboolean(L, -1); lua_pop(L, 1); return result; default: luaL_error(L, "invalid 'op' argument for lua_compare"); } return 0; } COMPAT53_API void lua_copy(lua_State* L, int from, int to) { int abs_to = lua_absindex(L, to); luaL_checkstack(L, 1, "not enough stack slots"); lua_pushvalue(L, from); lua_replace(L, abs_to); } COMPAT53_API void lua_len(lua_State* L, int i) { switch (lua_type(L, i)) { case LUA_TSTRING: lua_pushnumber(L, (lua_Number)lua_objlen(L, i)); break; case LUA_TTABLE: if (!luaL_callmeta(L, i, "__len")) lua_pushnumber(L, (lua_Number)lua_objlen(L, i)); break; case LUA_TUSERDATA: if (luaL_callmeta(L, i, "__len")) break; /* FALLTHROUGH */ default: luaL_error(L, "attempt to get length of a %s value", lua_typename(L, lua_type(L, i))); } } COMPAT53_API int lua_rawgetp(lua_State* L, int i, const void* p) { int abs_i = lua_absindex(L, i); lua_pushlightuserdata(L, (void*)p); lua_rawget(L, abs_i); return lua_type(L, -1); } COMPAT53_API void lua_rawsetp(lua_State* L, int i, const void* p) { int abs_i = lua_absindex(L, i); luaL_checkstack(L, 1, "not enough stack slots"); lua_pushlightuserdata(L, (void*)p); lua_insert(L, -2); lua_rawset(L, abs_i); } COMPAT53_API lua_Number lua_tonumberx(lua_State* L, int i, int* isnum) { lua_Number n = lua_tonumber(L, i); if (isnum != NULL) { *isnum = (n != 0 || lua_isnumber(L, i)); } return n; } COMPAT53_API void luaL_checkversion(lua_State* L) { (void)L; } COMPAT53_API void luaL_checkstack(lua_State* L, int sp, const char* msg) { if (!lua_checkstack(L, sp + LUA_MINSTACK)) { if (msg != NULL) luaL_error(L, "stack overflow (%s)", msg); else { lua_pushliteral(L, "stack overflow"); lua_error(L); } } } COMPAT53_API int luaL_getsubtable(lua_State* L, int i, const char* name) { int abs_i = lua_absindex(L, i); luaL_checkstack(L, 3, "not enough stack slots"); lua_pushstring(L, name); lua_gettable(L, abs_i); if (lua_istable(L, -1)) return 1; lua_pop(L, 1); lua_newtable(L); lua_pushstring(L, name); lua_pushvalue(L, -2); lua_settable(L, abs_i); return 0; } COMPAT53_API lua_Integer luaL_len(lua_State* L, int i) { lua_Integer res = 0; int isnum = 0; luaL_checkstack(L, 1, "not enough stack slots"); lua_len(L, i); res = lua_tointegerx(L, -1, &isnum); lua_pop(L, 1); if (!isnum) luaL_error(L, "object length is not an integer"); return res; } COMPAT53_API void luaL_setfuncs(lua_State* L, const luaL_Reg* l, int nup) { luaL_checkstack(L, nup + 1, "too many upvalues"); for (; l->name != NULL; l++) { /* fill the table with given functions */ int i; lua_pushstring(L, l->name); for (i = 0; i < nup; i++) /* copy upvalues to the top */ lua_pushvalue(L, -(nup + 1)); lua_pushcclosure(L, l->func, nup); /* closure with those upvalues */ lua_settable(L, -(nup + 3)); /* table must be below the upvalues, the name and the closure */ } lua_pop(L, nup); /* remove upvalues */ } COMPAT53_API void luaL_setmetatable(lua_State* L, const char* tname) { luaL_checkstack(L, 1, "not enough stack slots"); luaL_getmetatable(L, tname); lua_setmetatable(L, -2); } COMPAT53_API void* luaL_testudata(lua_State* L, int i, const char* tname) { void* p = lua_touserdata(L, i); luaL_checkstack(L, 2, "not enough stack slots"); if (p == NULL || !lua_getmetatable(L, i)) return NULL; else { int res = 0; luaL_getmetatable(L, tname); res = lua_rawequal(L, -1, -2); lua_pop(L, 2); if (!res) p = NULL; } return p; } static int compat53_countlevels(lua_State* L) { lua_Debug ar; int li = 1, le = 1; /* find an upper bound */ while (lua_getstack(L, le, &ar)) { li = le; le *= 2; } /* do a binary search */ while (li < le) { int m = (li + le) / 2; if (lua_getstack(L, m, &ar)) li = m + 1; else le = m; } return le - 1; } static int compat53_findfield(lua_State* L, int objidx, int level) { if (level == 0 || !lua_istable(L, -1)) return 0; /* not found */ lua_pushnil(L); /* start 'next' loop */ while (lua_next(L, -2)) { /* for each pair in table */ if (lua_type(L, -2) == LUA_TSTRING) { /* ignore non-string keys */ if (lua_rawequal(L, objidx, -1)) { /* found object? */ lua_pop(L, 1); /* remove value (but keep name) */ return 1; } else if (compat53_findfield(L, objidx, level - 1)) { /* try recursively */ lua_remove(L, -2); /* remove table (but keep name) */ lua_pushliteral(L, "."); lua_insert(L, -2); /* place '.' between the two names */ lua_concat(L, 3); return 1; } } lua_pop(L, 1); /* remove value */ } return 0; /* not found */ } static int compat53_pushglobalfuncname(lua_State* L, lua_Debug* ar) { int top = lua_gettop(L); lua_getinfo(L, "f", ar); /* push function */ lua_pushvalue(L, LUA_GLOBALSINDEX); if (compat53_findfield(L, top + 1, 2)) { lua_copy(L, -1, top + 1); /* move name to proper place */ lua_pop(L, 2); /* remove pushed values */ return 1; } else { lua_settop(L, top); /* remove function and global table */ return 0; } } static void compat53_pushfuncname(lua_State* L, lua_Debug* ar) { if (*ar->namewhat != '\0') /* is there a name? */ lua_pushfstring(L, "function " LUA_QS, ar->name); else if (*ar->what == 'm') /* main? */ lua_pushliteral(L, "main chunk"); else if (*ar->what == 'C') { if (compat53_pushglobalfuncname(L, ar)) { lua_pushfstring(L, "function " LUA_QS, lua_tostring(L, -1)); lua_remove(L, -2); /* remove name */ } else lua_pushliteral(L, "?"); } else lua_pushfstring(L, "function <%s:%d>", ar->short_src, ar->linedefined); } #define COMPAT53_LEVELS1 12 /* size of the first part of the stack */ #define COMPAT53_LEVELS2 10 /* size of the second part of the stack */ COMPAT53_API void luaL_traceback(lua_State* L, lua_State* L1, const char* msg, int level) { lua_Debug ar; int top = lua_gettop(L); int numlevels = compat53_countlevels(L1); int mark = (numlevels > COMPAT53_LEVELS1 + COMPAT53_LEVELS2) ? COMPAT53_LEVELS1 : 0; if (msg) lua_pushfstring(L, "%s\n", msg); lua_pushliteral(L, "stack traceback:"); while (lua_getstack(L1, level++, &ar)) { if (level == mark) { /* too many levels? */ lua_pushliteral(L, "\n\t..."); /* add a '...' */ level = numlevels - COMPAT53_LEVELS2; /* and skip to last ones */ } else { lua_getinfo(L1, "Slnt", &ar); lua_pushfstring(L, "\n\t%s:", ar.short_src); if (ar.currentline > 0) lua_pushfstring(L, "%d:", ar.currentline); lua_pushliteral(L, " in "); compat53_pushfuncname(L, &ar); lua_concat(L, lua_gettop(L) - top); } } lua_concat(L, lua_gettop(L) - top); } COMPAT53_API int luaL_fileresult(lua_State* L, int stat, const char* fname) { const char* serr = NULL; int en = errno; /* calls to Lua API may change this value */ char buf[512] = { 0 }; if (stat) { lua_pushboolean(L, 1); return 1; } else { lua_pushnil(L); serr = compat53_strerror(en, buf, sizeof(buf)); if (fname) lua_pushfstring(L, "%s: %s", fname, serr); else lua_pushstring(L, serr); lua_pushnumber(L, (lua_Number)en); return 3; } } static int compat53_checkmode(lua_State* L, const char* mode, const char* modename, int err) { if (mode && strchr(mode, modename[0]) == NULL) { lua_pushfstring(L, "attempt to load a %s chunk (mode is '%s')", modename, mode); return err; } return LUA_OK; } typedef struct { lua_Reader reader; void* ud; int has_peeked_data; const char* peeked_data; size_t peeked_data_size; } compat53_reader_data; static const char* compat53_reader(lua_State* L, void* ud, size_t* size) { compat53_reader_data* data = (compat53_reader_data*)ud; if (data->has_peeked_data) { data->has_peeked_data = 0; *size = data->peeked_data_size; return data->peeked_data; } else return data->reader(L, data->ud, size); } COMPAT53_API int lua_load(lua_State* L, lua_Reader reader, void* data, const char* source, const char* mode) { int status = LUA_OK; compat53_reader_data compat53_data = { reader, data, 1, 0, 0 }; compat53_data.peeked_data = reader(L, data, &(compat53_data.peeked_data_size)); if (compat53_data.peeked_data && compat53_data.peeked_data_size && compat53_data.peeked_data[0] == LUA_SIGNATURE[0]) /* binary file? */ status = compat53_checkmode(L, mode, "binary", LUA_ERRSYNTAX); else status = compat53_checkmode(L, mode, "text", LUA_ERRSYNTAX); if (status != LUA_OK) return status; /* we need to call the original 5.1 version of lua_load! */ #undef lua_load return lua_load(L, compat53_reader, &compat53_data, source); #define lua_load COMPAT53_CONCAT(COMPAT53_PREFIX, _load_53) } typedef struct { int n; /* number of pre-read characters */ FILE* f; /* file being read */ char buff[COMPAT53_LUA_FILE_BUFFER_SIZE]; /* area for reading file */ } compat53_LoadF; static const char* compat53_getF(lua_State* L, void* ud, size_t* size) { compat53_LoadF* lf = (compat53_LoadF*)ud; (void)L; /* not used */ if (lf->n > 0) { /* are there pre-read characters to be read? */ *size = lf->n; /* return them (chars already in buffer) */ lf->n = 0; /* no more pre-read characters */ } else { /* read a block from file */ /* 'fread' can return > 0 *and* set the EOF flag. If next call to 'compat53_getF' called 'fread', it might still wait for user input. The next check avoids this problem. */ if (feof(lf->f)) return NULL; *size = fread(lf->buff, 1, sizeof(lf->buff), lf->f); /* read block */ } return lf->buff; } static int compat53_errfile(lua_State* L, const char* what, int fnameindex) { char buf[512] = { 0 }; const char* serr = compat53_strerror(errno, buf, sizeof(buf)); const char* filename = lua_tostring(L, fnameindex) + 1; lua_pushfstring(L, "cannot %s %s: %s", what, filename, serr); lua_remove(L, fnameindex); return LUA_ERRFILE; } static int compat53_skipBOM(compat53_LoadF* lf) { const char* p = "\xEF\xBB\xBF"; /* UTF-8 BOM mark */ int c; lf->n = 0; do { c = getc(lf->f); if (c == EOF || c != *(const unsigned char*)p++) return c; lf->buff[lf->n++] = (char)c; /* to be read by the parser */ } while (*p != '\0'); lf->n = 0; /* prefix matched; discard it */ return getc(lf->f); /* return next character */ } /* ** reads the first character of file 'f' and skips an optional BOM mark ** in its beginning plus its first line if it starts with '#'. Returns ** true if it skipped the first line. In any case, '*cp' has the ** first "valid" character of the file (after the optional BOM and ** a first-line comment). */ static int compat53_skipcomment(compat53_LoadF* lf, int* cp) { int c = *cp = compat53_skipBOM(lf); if (c == '#') { /* first line is a comment (Unix exec. file)? */ do { /* skip first line */ c = getc(lf->f); } while (c != EOF && c != '\n'); *cp = getc(lf->f); /* skip end-of-line, if present */ return 1; /* there was a comment */ } else return 0; /* no comment */ } COMPAT53_API int luaL_loadfilex(lua_State* L, const char* filename, const char* mode) { compat53_LoadF lf; int status, readstatus; int c; int fnameindex = lua_gettop(L) + 1; /* index of filename on the stack */ if (filename == NULL) { lua_pushliteral(L, "=stdin"); lf.f = stdin; } else { lua_pushfstring(L, "@%s", filename); #if defined(_MSC_VER) /* This code is here to stop a deprecation error that stops builds * if a certain macro is defined. While normally not caring would * be best, some header-only libraries and builds can't afford to * dictate this to the user. A quick check shows that fopen_s this * goes back to VS 2005, and _fsopen goes back to VS 2003 .NET, * possibly even before that so we don't need to do any version * number checks, since this has been there since forever. */ /* TO USER: if you want the behavior of typical fopen_s/fopen, * which does lock the file on VC++, define the macro used below to 0 */ #if COMPAT53_FOPEN_NO_LOCK lf.f = _fsopen(filename, "r", _SH_DENYNO); /* do not lock the file in any way */ if (lf.f == NULL) return compat53_errfile(L, "open", fnameindex); #else /* use default locking version */ if (fopen_s(&lf.f, filename, "r") != 0) return compat53_errfile(L, "open", fnameindex); #endif /* Locking vs. No-locking fopen variants */ #else lf.f = fopen(filename, "r"); /* default stdlib doesn't forcefully lock files here */ if (lf.f == NULL) return compat53_errfile(L, "open", fnameindex); #endif } if (compat53_skipcomment(&lf, &c)) /* read initial portion */ lf.buff[lf.n++] = '\n'; /* add line to correct line numbers */ if (c == LUA_SIGNATURE[0] && filename) { /* binary file? */ #if defined(_MSC_VER) if (freopen_s(&lf.f, filename, "rb", lf.f) != 0) return compat53_errfile(L, "reopen", fnameindex); #else lf.f = freopen(filename, "rb", lf.f); /* reopen in binary mode */ if (lf.f == NULL) return compat53_errfile(L, "reopen", fnameindex); #endif compat53_skipcomment(&lf, &c); /* re-read initial portion */ } if (c != EOF) lf.buff[lf.n++] = (char)c; /* 'c' is the first character of the stream */ status = lua_load(L, &compat53_getF, &lf, lua_tostring(L, -1), mode); readstatus = ferror(lf.f); if (filename) fclose(lf.f); /* close file (even in case of errors) */ if (readstatus) { lua_settop(L, fnameindex); /* ignore results from 'lua_load' */ return compat53_errfile(L, "read", fnameindex); } lua_remove(L, fnameindex); return status; } COMPAT53_API int luaL_loadbufferx(lua_State* L, const char* buff, size_t sz, const char* name, const char* mode) { int status = LUA_OK; if (sz > 0 && buff[0] == LUA_SIGNATURE[0]) { status = compat53_checkmode(L, mode, "binary", LUA_ERRSYNTAX); } else { status = compat53_checkmode(L, mode, "text", LUA_ERRSYNTAX); } if (status != LUA_OK) return status; return luaL_loadbuffer(L, buff, sz, name); } #if !defined(l_inspectstat) \ && (defined(unix) || defined(__unix) || defined(__unix__) || defined(__TOS_AIX__) || defined(_SYSTYPE_BSD) || (defined(__APPLE__) && defined(__MACH__))) /* some form of unix; check feature macros in unistd.h for details */ #include <unistd.h> /* check posix version; the relevant include files and macros probably * were available before 2001, but I'm not sure */ #if defined(_POSIX_VERSION) && _POSIX_VERSION >= 200112L #include <sys/wait.h> #define l_inspectstat(stat, what) \ if (WIFEXITED(stat)) { \ stat = WEXITSTATUS(stat); \ } \ else if (WIFSIGNALED(stat)) { \ stat = WTERMSIG(stat); \ what = "signal"; \ } #endif #endif /* provide default (no-op) version */ #if !defined(l_inspectstat) #define l_inspectstat(stat, what) ((void)0) #endif COMPAT53_API int luaL_execresult(lua_State* L, int stat) { const char* what = "exit"; if (stat == -1) return luaL_fileresult(L, 0, NULL); else { l_inspectstat(stat, what); if (*what == 'e' && stat == 0) lua_pushboolean(L, 1); else lua_pushnil(L); lua_pushstring(L, what); lua_pushinteger(L, stat); return 3; } } COMPAT53_API void luaL_buffinit(lua_State* L, luaL_Buffer_53* B) { /* make it crash if used via pointer to a 5.1-style luaL_Buffer */ B->b.p = NULL; B->b.L = NULL; B->b.lvl = 0; /* reuse the buffer from the 5.1-style luaL_Buffer though! */ B->ptr = B->b.buffer; B->capacity = LUAL_BUFFERSIZE; B->nelems = 0; B->L2 = L; } COMPAT53_API char* luaL_prepbuffsize(luaL_Buffer_53* B, size_t s) { if (B->capacity - B->nelems < s) { /* needs to grow */ char* newptr = NULL; size_t newcap = B->capacity * 2; if (newcap - B->nelems < s) newcap = B->nelems + s; if (newcap < B->capacity) /* overflow */ luaL_error(B->L2, "buffer too large"); newptr = (char*)lua_newuserdata(B->L2, newcap); memcpy(newptr, B->ptr, B->nelems); if (B->ptr != B->b.buffer) lua_replace(B->L2, -2); /* remove old buffer */ B->ptr = newptr; B->capacity = newcap; } return B->ptr + B->nelems; } COMPAT53_API void luaL_addlstring(luaL_Buffer_53* B, const char* s, size_t l) { memcpy(luaL_prepbuffsize(B, l), s, l); luaL_addsize(B, l); } COMPAT53_API void luaL_addvalue(luaL_Buffer_53* B) { size_t len = 0; const char* s = lua_tolstring(B->L2, -1, &len); if (!s) luaL_error(B->L2, "cannot convert value to string"); if (B->ptr != B->b.buffer) lua_insert(B->L2, -2); /* userdata buffer must be at stack top */ luaL_addlstring(B, s, len); lua_remove(B->L2, B->ptr != B->b.buffer ? -2 : -1); } void luaL_pushresult(luaL_Buffer_53* B) { lua_pushlstring(B->L2, B->ptr, B->nelems); if (B->ptr != B->b.buffer) lua_replace(B->L2, -2); /* remove userdata buffer */ } #endif /* Lua 5.1 */ /* definitions for Lua 5.1 and Lua 5.2 */ #if defined(LUA_VERSION_NUM) && LUA_VERSION_NUM <= 502 COMPAT53_API int lua_geti(lua_State* L, int index, lua_Integer i) { index = lua_absindex(L, index); lua_pushinteger(L, i); lua_gettable(L, index); return lua_type(L, -1); } COMPAT53_API int lua_isinteger(lua_State* L, int index) { if (lua_type(L, index) == LUA_TNUMBER) { lua_Number n = lua_tonumber(L, index); lua_Integer i = lua_tointeger(L, index); if (i == n) return 1; } return 0; } COMPAT53_API lua_Integer lua_tointegerx(lua_State* L, int i, int* isnum) { int ok = 0; lua_Number n = lua_tonumberx(L, i, &ok); if (ok) { if (n == (lua_Integer)n) { if (isnum) *isnum = 1; return (lua_Integer)n; } } if (isnum) *isnum = 0; return 0; } static void compat53_reverse(lua_State* L, int a, int b) { for (; a < b; ++a, --b) { lua_pushvalue(L, a); lua_pushvalue(L, b); lua_replace(L, a); lua_replace(L, b); } } COMPAT53_API void lua_rotate(lua_State* L, int idx, int n) { int n_elems = 0; idx = lua_absindex(L, idx); n_elems = lua_gettop(L) - idx + 1; if (n < 0) n += n_elems; if (n > 0 && n < n_elems) { luaL_checkstack(L, 2, "not enough stack slots available"); n = n_elems - n; compat53_reverse(L, idx, idx + n - 1); compat53_reverse(L, idx + n, idx + n_elems - 1); compat53_reverse(L, idx, idx + n_elems - 1); } } COMPAT53_API void lua_seti(lua_State* L, int index, lua_Integer i) { luaL_checkstack(L, 1, "not enough stack slots available"); index = lua_absindex(L, index); lua_pushinteger(L, i); lua_insert(L, -2); lua_settable(L, index); } #if !defined(lua_str2number) #define lua_str2number(s, p) strtod((s), (p)) #endif COMPAT53_API size_t lua_stringtonumber(lua_State* L, const char* s) { char* endptr; lua_Number n = lua_str2number(s, &endptr); if (endptr != s) { while (*endptr != '\0' && isspace((unsigned char)*endptr)) ++endptr; if (*endptr == '\0') { lua_pushnumber(L, n); return endptr - s + 1; } } return 0; } COMPAT53_API const char* luaL_tolstring(lua_State* L, int idx, size_t* len) { if (!luaL_callmeta(L, idx, "__tostring")) { int t = lua_type(L, idx), tt = 0; char const* name = NULL; switch (t) { case LUA_TNIL: lua_pushliteral(L, "nil"); break; case LUA_TSTRING: case LUA_TNUMBER: lua_pushvalue(L, idx); break; case LUA_TBOOLEAN: if (lua_toboolean(L, idx)) lua_pushliteral(L, "true"); else lua_pushliteral(L, "false"); break; default: tt = luaL_getmetafield(L, idx, "__name"); name = (tt == LUA_TSTRING) ? lua_tostring(L, -1) : lua_typename(L, t); lua_pushfstring(L, "%s: %p", name, lua_topointer(L, idx)); if (tt != LUA_TNIL) lua_replace(L, -2); break; } } else { if (!lua_isstring(L, -1)) luaL_error(L, "'__tostring' must return a string"); } return lua_tolstring(L, -1, len); } COMPAT53_API void luaL_requiref(lua_State* L, const char* modname, lua_CFunction openf, int glb) { luaL_checkstack(L, 3, "not enough stack slots available"); luaL_getsubtable(L, LUA_REGISTRYINDEX, "_LOADED"); if (lua_getfield(L, -1, modname) == LUA_TNIL) { lua_pop(L, 1); lua_pushcfunction(L, openf); lua_pushstring(L, modname); lua_call(L, 1, 1); lua_pushvalue(L, -1); lua_setfield(L, -3, modname); } if (glb) { lua_pushvalue(L, -1); lua_setglobal(L, modname); } lua_replace(L, -2); } #endif /* Lua 5.1 and 5.2 */ #endif /* KEPLER_PROJECT_COMPAT53_C_ */ /********************************************************************* * This file contains parts of Lua 5.2's and Lua 5.3's source code: * * Copyright (C) 1994-2014 Lua.org, PUC-Rio. * * Permission is hereby granted, free of charge, to any person obtaining * a copy of this software and associated documentation files (the * "Software"), to deal in the Software without restriction, including * without limitation the rights to use, copy, modify, merge, publish, * distribute, sublicense, and/or sell copies of the Software, and to * permit persons to whom the Software is furnished to do so, subject to * the following conditions: * * The above copyright notice and this permission notice shall be * included in all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. *********************************************************************/
Siv3D/OpenSiv3D
Siv3D/include/ThirdParty/sol/compatibility/compat-5.3.c.h
C
mit
26,430
package ruanmianbao.binetwork; import java.io.BufferedInputStream; import java.io.IOException; import java.io.UnsupportedEncodingException; import java.net.Socket; import java.net.UnknownHostException; import java.nio.ByteBuffer; import java.nio.ByteOrder; import java.text.SimpleDateFormat; import java.util.Calendar; import java.util.Date; import java.util.Scanner; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; public class Main{ boolean running = false; Socket socket; ByteOrder order; String script = ""; public Main(String[] args) throws Exception { String server = "localhost"; int port = 8788; ByteOrder order = ByteOrder.LITTLE_ENDIAN; for(String a: args) { String[] a2 = a.split("=",2); if (a2.length==2) { switch(a2[0]) { case "-s": case "--server": server = a2[1]; break; case "-p": case "--port": port = Integer.parseInt(a2[1]); break; case "-e": case "--endian": order = a2[1].equalsIgnoreCase("be")?ByteOrder.BIG_ENDIAN:ByteOrder.LITTLE_ENDIAN; break; case "-r": case "--run": script = a2[1]; break; } } } Main.log("connect to:"+server+":"+port); socket = new Socket(server, port); socket.setSoTimeout(15000); Main.log("connected."); this.order = order; if (this.script.isEmpty()) { // read from input this.running = true; ExecutorService taskExecutor = Executors.newFixedThreadPool(2); try { taskExecutor.execute(new RecvWorker()); taskExecutor.execute(new SendWorker()); } finally { taskExecutor.shutdown(); } } else { this.running = false; this.RunWorker(); } } /** * 进行一次测试 * @throws Exception */ private void RunWorker() throws Exception { if(script.startsWith("'") && script.endsWith("'")) script = script.substring(1, script.length()-1); Main.log("run script:" + script); sendData(script); recvData(); } private String recvData() throws IOException { int buffer_size = 4096; byte[] buffer = new byte[buffer_size]; BufferedInputStream in = new BufferedInputStream(socket.getInputStream()); int readed = 0, pos = 0; readed = in.read(buffer, pos, buffer.length-pos); if (readed>0) pos+=readed; String msg = toHex(buffer,0,pos); Main.log("recv["+pos+"]:"+msg); return msg; } private void sendData(String line) throws IOException { ByteBuffer outbuffer = ByteBuffer.allocate(4*1024); outbuffer.order(order); String[] items = line.split("\\|"); for(int i=0; i<items.length; i++) { String[] sp = items[i].split(":"); if(sp.length!=3) { Main.log("item ["+i+"] format error:"+items[i]); continue; } switch(sp[0]) { case "b": //二进制 putBin(outbuffer, Integer.parseInt(sp[1]), sp[2]); break; case "o": //八进制 putOct(outbuffer, Integer.parseInt(sp[1]), sp[2]); break; case "d": //十进制 putDec(outbuffer, Integer.parseInt(sp[1]), sp[2]); break; case "x": //十六进制 putHex(outbuffer, Integer.parseInt(sp[1]), sp[2]); break; case "s": //字符串 putStr(outbuffer, sp[1], sp[2]); break; } } outbuffer.flip(); socket.getOutputStream().write(outbuffer.array(), 0, outbuffer.limit()); socket.getOutputStream().flush(); Main.log("send["+outbuffer.limit()+"]"+toHex(outbuffer.array(), 0, outbuffer.limit())); } // 二进制 private void putBin(ByteBuffer outbuffer, int parseInt, String string) { putByte(outbuffer, parseInt, string, 2); } // 八进制 private void putOct(ByteBuffer outbuffer, int parseInt, String string) { putByte(outbuffer, parseInt, string, 8); } // 十进制 private void putDec(ByteBuffer outbuffer, int parseInt, String string) { putByte(outbuffer, parseInt, string, 10); } // 十六进制 private void putHex(ByteBuffer outbuffer, int parseInt, String string) { putByte(outbuffer, parseInt, string, 16); } // 字符串 private void putStr(ByteBuffer outbuffer, String encode, String string) throws UnsupportedEncodingException { byte[] data = string.getBytes(encode); outbuffer.put(data); } /** * 把一个字符串按指定进制转换成字节,存入指定的缓冲区内。如果指定的长度与字符串拆分后的长度不符,则自动补0。 * @param outbuffer 填充的buffer * @param parseInt 单位:1-byte 2-short 4-int 8-long * @param string 待处理字符串 * @param radix 进制(2,8,10,16) */ private void putByte(ByteBuffer outbuffer, int parseInt, String string, int radix) { String[] strs = string.split(" "); for(int i=0; i<strs.length; i++) { if (i<strs.length) { switch(parseInt) { case 1: short b = Short.parseShort(strs[i], radix); outbuffer.put((byte)(b&0x00ff)); break; case 2: int s = Integer.parseInt(strs[i], radix); outbuffer.putShort((short)(s&0x00ffff)); break; case 4: long ii = Long.parseLong(strs[i], radix); outbuffer.putInt((int)(ii&0x00ffffffff)); break; case 8: long l = Long.parseLong(strs[i], radix); outbuffer.putLong(l); break; default: Main.log("unsupport type:"+parseInt); } } } } /** * 发送信息的线程 */ private class SendWorker implements Runnable { @Override public void run() { try { Scanner scan = new Scanner(System.in); while (running) { String line = scan.nextLine(); Main.log("input:"+line); sendData(line); } scan.close(); } catch (Exception e) { running = false; e.printStackTrace(); } } } /** * 接收信息的线程 */ private class RecvWorker implements Runnable{ @Override public void run() { try { byte[] buffer = new byte[4*1024]; BufferedInputStream in = new BufferedInputStream(socket.getInputStream()); while (running) { int readed = in.read(buffer, 0, buffer.length); Main.log("recv["+readed+"]:"+toHex(buffer, 0, readed)); } } catch (Exception e) { running = false; e.printStackTrace(); } } } /** * 统一输出 * @param string 要输出的信息 */ static void log(String msg) { Date dNow = new Date( ); SimpleDateFormat ft = new SimpleDateFormat ("yyyy.MM.dd HH:mm:ss"); System.out.println("["+ft.format(dNow)+"] "+msg); } /** * 入口 * @param args host ip [le|be] */ public static void main(String[] args) { if (args.length==0 || args[0].equalsIgnoreCase("help") || args[0].equalsIgnoreCase("-h") || args[0].equalsIgnoreCase("?") || args[0].equalsIgnoreCase("--help") ) { printHelp("binetwork"); System.exit(0); } try { new Main(args); } catch (Exception e) { e.printStackTrace(); System.exit(-1); } } private static void printHelp(String cmd) { System.out.println("usage: check 'readme.md' for more info.\n\n" + cmd + "[-s|--server]=<host> [-p|--port]=<port> [-e|-endian]=<le|be>\n" + " -host or ip: the host name or ip (default: localhost)\n"+ " -port: the port of server (default: 8080) \n" + " -le: little endian (default)\n"+ " -be: big endian \n\n" + "example:\n"+ " "+ cmd + "-s=127.0.0.1 -p=8080 -e=le -r=\"x:1:fa fb fc fd\"\n"); } /** * 把一个数组用16进制格式输出 * @param buf 需要转换的数据 * @param start 起始位置 * @param length 长度 * @return 16进制字符串 */ private String toHex(byte[] buf, int start, int length) { if (buf == null) return ""; StringBuffer result = new StringBuffer(2 * length); for (int i = start; (( i < start+length) && (i<buf.length)); i++) { appendHex(result, buf[i]); } return result.toString(); } private final static String HEX = "0123456789ABCDEF"; private static void appendHex(StringBuffer sb, byte b) { sb.append(HEX.charAt((b >> 4) & 0x0f)).append(HEX.charAt(b & 0x0f)); } }
flairyu/binetwork
src/ruanmianbao/binetwork/Main.java
Java
mit
7,911
using Keeper.Warm; using System; using System.Collections.Generic; namespace Keeper.Warm { public class QueryResult { private Machine machine; private Variable[] variables; public QueryResult(bool success, Variable[] variables, Machine machine) { this.Success = success; this.variables = variables; this.machine = machine; } public bool Success { get; private set; } public bool CanContinue { get { return this.machine.IsBacktrackAvailable; } } public bool Continue() { bool result = this.machine.Continue(); this.Success = result; return result; } public IEnumerable<Variable> Variables { get { return this.variables; } } public ITerm GetVariable(Variable variable) { int index = Array.IndexOf(variables, variable); if (index < 0) { return null; } else { return BuildTermFromHeap(this.machine, variables.Length - (index + 1)); } } public static ITerm BuildTermFromHeap(Machine machine, int index) { return BuildTermFromAddress(machine, new Address(AddressType.Heap, index)); } public static ITerm BuildTermFromAddress(Machine machine, Address termAddress) { Cell value = new Cell(machine.DereferenceAndLoad(termAddress)); switch (value.Tag) { case Tag.Ref: string name = value.Address.Pointer.ToString(); if(value.Address.Type == AddressType.Retained) { name = "R" + name; } return new Variable(name); case Tag.Str: Cell functorCell = new Cell(machine.DereferenceAndLoad(value.Address)); FunctorDescriptor functor = machine.GetFunctor(functorCell.Address.Pointer); ITerm[] terms = null; if (functor.Arity > 0) { terms = new ITerm[functor.Arity]; for (int termIndex = 0; termIndex < functor.Arity; termIndex++) { terms[termIndex] = BuildTermFromAddress(machine, value.Address + termIndex + 1); } } return new CompoundTerm(functor.Name, terms); case Tag.Con: FunctorDescriptor constantFunctor = machine.GetFunctor(value.Address.Pointer); if (constantFunctor.Name == "[]") { return EmptyList.Instance; } else { return new Atom(constantFunctor.Name); } case Tag.Lis: var headTerm = BuildTermFromAddress(machine, value.Address); var TailTerm = BuildTermFromAddress(machine, (value.Address + 1)); return new ListPair(headTerm, (IListTail)TailTerm); default: throw new Exception("Unexpected tag in term:" + value); } } } }
FacticiusVir/Warm
Keeper.Warm/QueryResult.cs
C#
mit
3,572
using System; using System.IO; using System.Linq; using SharpCompress.IO; namespace SharpCompress.Common.SevenZip { internal class SevenZipFilePart : FilePart { private CompressionType? _type; private readonly Stream _stream; private readonly ArchiveDatabase _database; internal SevenZipFilePart(Stream stream, ArchiveDatabase database, int index, CFileItem fileEntry, ArchiveEncoding archiveEncoding) : base(archiveEncoding) { _stream = stream; _database = database; Index = index; Header = fileEntry; if (Header.HasStream) { Folder = database._folders[database._fileIndexToFolderIndexMap[index]]; } } internal CFileItem Header { get; } internal CFolder? Folder { get; } internal int Index { get; } internal override string FilePartName => Header.Name; internal override Stream? GetRawStream() { return null; } internal override Stream GetCompressedStream() { if (!Header.HasStream) { return null!; } var folderStream = _database.GetFolderStream(_stream, Folder!, _database.PasswordProvider); int firstFileIndex = _database._folderStartFileIndex[_database._folders.IndexOf(Folder!)]; int skipCount = Index - firstFileIndex; long skipSize = 0; for (int i = 0; i < skipCount; i++) { skipSize += _database._files[firstFileIndex + i].Size; } if (skipSize > 0) { folderStream.Skip(skipSize); } return new ReadOnlySubStream(folderStream, Header.Size); } public CompressionType CompressionType { get { if (_type is null) { _type = GetCompression(); } return _type.Value; } } //copied from DecoderRegistry private const uint K_COPY = 0x0; private const uint K_DELTA = 3; private const uint K_LZMA2 = 0x21; private const uint K_LZMA = 0x030101; private const uint K_PPMD = 0x030401; private const uint K_BCJ = 0x03030103; private const uint K_BCJ2 = 0x0303011B; private const uint K_DEFLATE = 0x040108; private const uint K_B_ZIP2 = 0x040202; internal CompressionType GetCompression() { var coder = Folder!._coders.First(); switch (coder._methodId._id) { case K_LZMA: case K_LZMA2: { return CompressionType.LZMA; } case K_PPMD: { return CompressionType.PPMd; } case K_B_ZIP2: { return CompressionType.BZip2; } default: throw new NotImplementedException(); } } internal bool IsEncrypted => Folder!._coders.FindIndex(c => c._methodId._id == CMethodId.K_AES_ID) != -1; } }
adamhathcock/sharpcompress
src/SharpCompress/Common/SevenZip/SevenZipFilePart.cs
C#
mit
3,350
<?xml version="1.0" encoding="UTF-8"?> <CustomMetadata xmlns="http://soap.sforce.com/2006/04/metadata" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <label>Cost</label> <protected>false</protected> <values> <field>Display_Object_Name__c</field> <value xsi:type="xsd:string">Parts</value> </values> <values> <field>Field_API_Name__c</field> <value xsi:type="xsd:string">Last_Cost__c</value> </values> <values> <field>Is_Display__c</field> <value xsi:type="xsd:boolean">false</value> </values> <values> <field>Order_Number__c</field> <value xsi:type="xsd:double">10.0</value> </values> <values> <field>Type__c</field> <value xsi:type="xsd:string">Currency</value> </values> </CustomMetadata>
hiteshgupta1992/BP-Core
bppackaging/src/customMetadata/HomeSearch_Grid_Column.Parts_Cost.md
Markdown
mit
872
using System; using System.Collections.Generic; using Mailer.NET.Mailer.Rendering; using Mailer.NET.Mailer.Transport; using Mailer.NET.Mailer.Internal; using Mailer.NET.Mailer.Response; using System.Threading.Tasks; namespace Mailer.NET.Mailer { public class Email { public AbstractTransport Transport { get; set; } public String Message { get; set; } public String Template { get; set; } public List<TemplateVar> TemplateVars { get; set; } public List<Contact> To { get; set; } public List<Contact> Cco { get; set; } public List<Contact> Bco { get; set; } public Contact From { get; set; } public String Subject { get; set; } public EmailContentType Type { get; set; } public List<Attachment> Attachments { get; set; } public Boolean HasReadNotification { get; set; } public String ReplyTo { get; set; } public Email(AbstractTransport transport, EmailContentType type = EmailContentType.Text) { Transport = transport; Type = type; } public Email(EmailContentType type = EmailContentType.Text) { Transport = AppConfig.DefaultInstance.TryGetDefaultTransport(); Type = type; } public void AddTo(string email, string name = null) { if (To == null) { To = new List<Contact>(); } To.Add(new Contact(){Email = email, Name=name}); } public void AddCco(string email, string name = null) { if (Cco == null) { Cco = new List<Contact>(); } Cco.Add(new Contact() { Email = email, Name = name }); } public void AddBco(string email, string name = null) { if (Bco == null) { Bco = new List<Contact>(); } Bco.Add(new Contact() { Email = email, Name = name }); } public void AddTemplateVar(string name, object data) { if (TemplateVars == null) { TemplateVars = new List<TemplateVar>(); } TemplateVars.Add(new TemplateVar(){Name = name, Data = data}); } public void AddAttachment(Attachment file) { if (Attachments == null) { Attachments = new List<Attachment>(); } Attachments.Add(file); } public EmailResponse Send() { ValidateEmail(); return Transport.SendEmail(this); } public async Task<EmailResponse> SendEmailAsync() { ValidateEmail(); return await Transport.SendEmailAsync(this); } private void ValidateEmail() { if (From == null) { throw new InvalidOperationException("The From is not defined!"); } if (To == null && Bco == null && Cco == null) { throw new InvalidOperationException("You need specify one destination on to, cc or bcc."); } if (Transport == null) { throw new InvalidOperationException("Transport is not defined!"); } if (!String.IsNullOrEmpty(Template)) { Message = EmailRender.RenderEmail(this); } } } }
Inside-Sistemas/mailer.net
src/Mailer.NET/Mailer/Email.cs
C#
mit
3,511
// <copyright file="ParsingTests.cs" company="MIT License"> // Licensed under the MIT License. See LICENSE file in the project root for license information. // </copyright> namespace SmallBasic.Tests.Compiler { using SmallBasic.Compiler; using SmallBasic.Compiler.Diagnostics; using Xunit; public sealed class ParsingTests : IClassFixture<CultureFixture> { [Fact] public void ItReportsUnterminatedSubModules() { new SmallBasicCompilation(@" Sub a").VerifyDiagnostics( // Sub a // ^ // I was expecting to see 'EndSub' after this. new Diagnostic(DiagnosticCode.UnexpectedEndOfStream, ((1, 4), (1, 4)), "EndSub")); } [Fact] public void ItReportsNestedSubModules() { new SmallBasicCompilation(@" If x < 1 Then Sub b EndSub EndIf").VerifyDiagnostics( // Sub b // ^^^ // I didn't expect to see 'Sub' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((2, 0), (2, 2)), "Sub"), // EndSub // ^^^^^^ // I didn't expect to see 'EndSub' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((3, 0), (3, 5)), "EndSub")); } [Fact] public void ItReportsIncompleteNestedSubModules() { new SmallBasicCompilation(@" Sub a Sub b EndSub").VerifyDiagnostics( // Sub b // ^^^ // I didn't expect to see 'Sub' here. I was expecting 'EndSub' instead. new Diagnostic(DiagnosticCode.UnexpectedTokenFound, ((2, 0), (2, 2)), "Sub", "EndSub")); } [Fact] public void ItReportsEndSubWithoutSub() { new SmallBasicCompilation(@" x = 1 EndSub").VerifyDiagnostics( // EndSub // ^^^^^^ // I didn't expect to see 'EndSub' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((2, 0), (2, 5)), "EndSub")); } [Fact] public void ItReportsElseIfWithoutIf() { new SmallBasicCompilation(@" x = 1 ElseIf x < 1 Then EndIf").VerifyDiagnostics( // ElseIf x < 1 Then // ^^^^^^ // I didn't expect to see 'ElseIf' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((2, 0), (2, 5)), "ElseIf"), // EndIf // ^^^^^ // I didn't expect to see 'EndIf' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((3, 0), (3, 4)), "EndIf")); } [Fact] public void ItReportsElseWithoutIf() { new SmallBasicCompilation(@" x = 1 Else EndIf").VerifyDiagnostics( // Else // ^^^^ // I didn't expect to see 'Else' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((2, 0), (2, 3)), "Else"), // EndIf // ^^^^^ // I didn't expect to see 'EndIf' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((3, 0), (3, 4)), "EndIf")); } [Fact] public void ItReportsEndIfWithoutIf() { new SmallBasicCompilation(@" x = 1 EndIf").VerifyDiagnostics( // EndIf // ^^^^^ // I didn't expect to see 'EndIf' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((2, 0), (2, 4)), "EndIf")); } [Fact] public void ItReportsElseIfAfterElse() { new SmallBasicCompilation(@" x = 1 If x > 1 Then Else ElseIf x < 1 EndIf").VerifyDiagnostics( // ElseIf x < 1 // ^^^^^^ // I didn't expect to see 'ElseIf' here. I was expecting 'EndIf' instead. new Diagnostic(DiagnosticCode.UnexpectedTokenFound, ((4, 0), (4, 5)), "ElseIf", "EndIf"), // ElseIf x < 1 // ^^^^^^ // I didn't expect to see 'ElseIf' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((4, 0), (4, 5)), "ElseIf"), // EndIf // ^^^^^ // I didn't expect to see 'EndIf' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((5, 0), (5, 4)), "EndIf")); } [Fact] public void ItReportsEndWhileWithoutWhile() { new SmallBasicCompilation(@" x = 1 EndWhile").VerifyDiagnostics( // EndWhile // ^^^^^^^^ // I didn't expect to see 'EndWhile' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((2, 0), (2, 7)), "EndWhile")); } [Fact] public void ItReportsInvalidStartOfStatements() { new SmallBasicCompilation(@" x = 1 Then").VerifyDiagnostics( // Then // ^^^^ // I didn't expect to see 'Then' here. I was expecting the start of a new statement. new Diagnostic(DiagnosticCode.UnexpectedTokenInsteadOfStatement, ((2, 0), (2, 3)), "Then")); } [Fact] public void ItReportsTokensAfterACompleteStatement() { new SmallBasicCompilation(@" If x = 1 Then y EndIf").VerifyDiagnostics( // If x = 1 Then y // ^ // This statement should go on a new line. new Diagnostic(DiagnosticCode.UnexpectedStatementInsteadOfNewLine, ((1, 14), (1, 14)))); } [Fact] public void ItReportsAssignmentWithNonExpressions() { new SmallBasicCompilation(@" x = .").VerifyDiagnostics( // x = . // ^ // I didn't expect to see '.' here. I was expecting 'identifier' instead. new Diagnostic(DiagnosticCode.UnexpectedTokenFound, ((1, 4), (1, 4)), ".", "identifier")); } [Fact] public void ItReportsAssignmentWithNothing() { new SmallBasicCompilation(@" x =").VerifyDiagnostics( // x = // ^ // I was expecting to see 'identifier' after this. new Diagnostic(DiagnosticCode.UnexpectedEndOfStream, ((1, 2), (1, 2)), "identifier")); } [Fact] public void ItReportsNonExpressionsInWhileLoop() { new SmallBasicCompilation(@" While . EndWhile").VerifyDiagnostics( // While . // ^ // I didn't expect to see '.' here. I was expecting 'identifier' instead. new Diagnostic(DiagnosticCode.UnexpectedTokenFound, ((1, 6), (1, 6)), ".", "identifier")); } [Fact] public void ItReportsMissingThenAfterIf() { new SmallBasicCompilation(@" If x < 1 EndIf").VerifyDiagnostics( // EndIf // ^^^^^ // I didn't expect to see 'EndIf' here. I was expecting 'Then' instead. new Diagnostic(DiagnosticCode.UnexpectedTokenFound, ((2, 0), (2, 4)), "EndIf", "Then")); } [Fact] public void ItReportsMissingThenAfterElseIf() { new SmallBasicCompilation(@" If x < 1 Then ElseIf x > 1 EndIf").VerifyDiagnostics( // EndIf // ^^^^^ // I didn't expect to see 'EndIf' here. I was expecting 'Then' instead. new Diagnostic(DiagnosticCode.UnexpectedTokenFound, ((3, 0), (3, 4)), "EndIf", "Then")); } [Fact] public void ItReportsStepAfterIf() { new SmallBasicCompilation(@" If x < 1 Step EndIf").VerifyDiagnostics( // If x < 1 Step // ^^^^ // I didn't expect to see 'Step' here. I was expecting 'Then' instead. new Diagnostic(DiagnosticCode.UnexpectedTokenFound, ((1, 9), (1, 12)), "Step", "Then"), // If x < 1 Step // ^^^^ // This statement should go on a new line. new Diagnostic(DiagnosticCode.UnexpectedStatementInsteadOfNewLine, ((1, 9), (1, 12)))); } [Fact] public void ItReportsStepAfterElseIf() { new SmallBasicCompilation(@" If x > 1 Then ElseIf x < 1 Step EndIf").VerifyDiagnostics( // ElseIf x < 1 Step // ^^^^ // I didn't expect to see 'Step' here. I was expecting 'Then' instead. new Diagnostic(DiagnosticCode.UnexpectedTokenFound, ((2, 13), (2, 16)), "Step", "Then"), // ElseIf x < 1 Step // ^^^^ // This statement should go on a new line. new Diagnostic(DiagnosticCode.UnexpectedStatementInsteadOfNewLine, ((2, 13), (2, 16)))); } [Fact] public void ItReportsExtraTokensAfterIfStatement() { new SmallBasicCompilation(@" For x = 1 To 2 Step 1 : EndFor").VerifyDiagnostics( // For x = 1 To 2 Step 1 : // ^ // This statement should go on a new line. new Diagnostic(DiagnosticCode.UnexpectedStatementInsteadOfNewLine, ((1, 23), (1, 23)))); } [Fact] public void ItReportsUnevenParenthesis() { new SmallBasicCompilation(@" TextWindow.WriteLine(5").VerifyDiagnostics( // TextWindow.WriteLine(5 // ^ // I was expecting to see ')' after this. new Diagnostic(DiagnosticCode.UnexpectedEndOfStream, ((1, 21), (1, 21)), ")")); } [Fact] public void ItReportsUnevenBrackets() { new SmallBasicCompilation(@" x = a[1").VerifyDiagnostics( // x = a[1 // ^ // I was expecting to see ']' after this. new Diagnostic(DiagnosticCode.UnexpectedEndOfStream, ((1, 6), (1, 6)), "]")); } [Fact] public void ItReportsArgumentsWithoutCommasInInvocation() { new SmallBasicCompilation(@" x = Math.Power(1 4)").VerifyDiagnostics( // x = Math.Power(1 4) // ^ // I didn't expect to see 'number' here. I was expecting ',' instead. new Diagnostic(DiagnosticCode.UnexpectedTokenFound, ((1, 17), (1, 17)), "number", ",")); } [Fact] public void ItReportsCommasWithoutArgumentsInInvocation() { new SmallBasicCompilation(@" x = Math.Sin(, )").VerifyDiagnostics( // x = Math.Sin(, ) // ^ // I didn't expect to see ',' here. I was expecting 'identifier' instead. new Diagnostic(DiagnosticCode.UnexpectedTokenFound, ((1, 13), (1, 13)), ",", "identifier")); } } }
OmarTawfik/SuperBasic
Source/SmallBasic.Tests/Compiler/ParsingTests.cs
C#
mit
11,842
'use strict'; /** * practice Node.js project * * @author Huiming Hou <240050497@qq.com> */ import mongoose from 'mongoose'; module.exports = function(done){ const debug = $.createDebug('init:mongodb'); debug('connecting to MongoDB...'); const conn = mongoose.createConnection($.config.get('db.mongodb')); $.mongodb = conn; $.model = {}; const ObjectId = mongoose.Types.ObjectId; $.utils.ObjectId = ObjectId; done(); };
hhmpro/node-practice-project
src/init/mongodb.js
JavaScript
mit
450
#!/usr/bin/env ruby require 'rubygems' require 'json' require 'net/http' require 'google_drive' require 'yaml' require 'time' require 'twitter' require 'active_support/all' require 'pry' require 'logger' def log_time(input, type = 'info') puts Time.now.to_s + " " + type + ": " + input $LOG.error(input) if type == 'error' $LOG.info(input) if type == 'info' $LOG.warn(input) if type == 'warn' $LOG.debug(input) if type == 'debug' $LOG.fatal(input) if type == 'fatal' end $LOG = Logger.new('log.log') # Set back to default formatter because active_support/all is messing things up $LOG.formatter = Logger::Formatter.new def loadyaml(yaml) begin return YAML::load(File.open(yaml)) rescue Exception => e log_time("error loading #{yaml} - #{e.message}", 'error') end end def fetch_tweets_from_event(twitter_client, event, since_id) log_time("Collecting tweets for " + event[:name] + " since " + since_id.to_s) parameters = { :geocode => "#{event[:lat]},#{event[:long]},#{event[:range]}km", :count => 100, :result_type => 'recent', :since_id => since_id } twitter_client.search( "", parameters ).to_h end def create_sheet_headers(sheet, headers) n = 1 headers.each do |header| sheet[1,n] = header n +=1 end sheet.save() end def stage_tweet(sheet, tweet, row) sheet[row, 1] = "'" + tweet[:id].to_s sheet[row, 2] = tweet[:text] sheet[row, 3] = tweet[:created_at] sheet[row, 4] = tweet[:retweet_count] sheet[row, 5] = tweet[:favorite_count] sheet[row, 6] = tweet[:source] sheet[row, 7] = tweet[:geo][:coordinates][0] sheet[row, 8] = tweet[:geo][:coordinates][1] sheet[row, 9] = "'" + tweet[:user][:id].to_s sheet[row, 10] = tweet[:user][:name] sheet[row, 11] = tweet[:user][:screen_name] sheet[row, 12] = tweet[:user][:created_at] sheet[row, 13] = tweet[:user][:location] sheet[row, 14] = tweet[:user][:description] sheet[row, 15] = tweet[:user][:url] sheet[row, 16] = tweet[:user][:followers_count] sheet[row, 17] = tweet[:user][:friends_count] sheet[row, 18] = tweet[:user][:listed_count] sheet[row, 19] = tweet[:user][:favourites_count] sheet[row, 20] = tweet[:user][:statuses_count] sheet[row, 21] = tweet[:user][:utc_offset] end def stage_media(sheet, tweet, media, row) sheet[row,1] = "'" + media[:id].to_s sheet[row,2] = "'" + tweet[:id].to_s sheet[row,3] = media[:expanded_url] sheet[row,4] = media[:type] end def stage_hashtag(sheet, tweet, hashtag, row) sheet[row,1] = "'" + tweet[:id].to_s sheet[row,2] = hashtag end def stage_url(sheet, tweet, url, row) sheet[row,1] = "'" + tweet[:id].to_s sheet[row,2] = url end def stage_user_mention(sheet, tweet, user_mention, row) sheet[row,1] = "'" + tweet[:id].to_s sheet[row,2] = user_mention[:id] sheet[row,3] = user_mention[:screen_name] end log_time("Loading variables") yml = loadyaml('config.yml') log_time("Seting event parameters") event = { :name => yml['event'].first['name'], :lat => yml['event'].first['lat'], :long => yml['event'].first['long'], :range => yml['event'].first['range']} log_time("Connecting to twitter API") twitter_client = Twitter::REST::Client.new do |config| config.consumer_key = yml['twitter']['consumer_key'] config.consumer_secret = yml['twitter']['consumer_secret'] config.access_token = yml['twitter']['access_token'] config.access_token_secret = yml['twitter']['access_token_secret'] end log_time("Connecting to Google Drive API") session = GoogleDrive.login(yml['google']['user'], yml['google']['password']) log_time("Loading sheets") sheets = {} sheets[:tweets] = session.spreadsheet_by_key(yml['google']['doc']).worksheets[0] sheets[:media] = session.spreadsheet_by_key(yml['google']['doc']).worksheets[1] sheets[:hashtags] = session.spreadsheet_by_key(yml['google']['doc']).worksheets[2] sheets[:urls] = session.spreadsheet_by_key(yml['google']['doc']).worksheets[3] sheets[:user_mentions] = session.spreadsheet_by_key(yml['google']['doc']).worksheets[4] sheets[:meta] = session.spreadsheet_by_key(yml['google']['doc']).worksheets[5] log_time("Loading meta data") meta = {} meta[:since_id] = sheets[:meta][1,2][/\d+/].to_i meta[:tweets_last_row] = sheets[:meta][4,2] meta[:media_last_row] = sheets[:meta][5,2] meta[:hashtags_last_row] = sheets[:meta][6,2] meta[:urls_last_row] = sheets[:meta][7,2] meta[:user_mentions_last_row] = sheets[:meta][8,2] log_time("Setting sheet headers") create_sheet_headers(sheets[:tweets], ['tweet id','text','tweet created_at','retweeted count','favorite count','source','lat','long','user id','user name','screen name','user created_at','user location','user description','user url', 'followers count', 'friends count', 'listed count', 'favourites count', 'statuses count', 'utc offset']) create_sheet_headers(sheets[:media], ['media id','tweet id','expanded url', 'media type']) create_sheet_headers(sheets[:hashtags], ['tweet id', 'hashtag']) create_sheet_headers(sheets[:urls], ['tweet id', 'url']) create_sheet_headers(sheets[:user_mentions], ['tweet id', 'user id', 'user screen name']) loop do log_time("Reloading meta data") sheets[:meta].reload log_time("Collecting last rows meta data") tweet_row = meta[:tweets_last_row].to_i media_row = meta[:media_last_row].to_i hashtag_row = meta[:hashtags_last_row].to_i url_row = meta[:urls_last_row].to_i user_mention_row = meta[:user_mentions_last_row].to_i log_time("Fetching Twitter statuses") tweets = fetch_tweets_from_event(twitter_client, event, meta[:since_id]) log_time("#{tweets[:statuses].length} fetched") log_time("Staging tweets") tweets[:statuses].each do |tweet| tweet_row += 1 stage_tweet(sheets[:tweets], tweet, tweet_row) unless tweet[:entities][:media].nil? tweet[:entities][:media].each do |media| media_row += 1 stage_media(sheets[:media], tweet, media, media_row) end end unless tweet[:entities][:hashtags].nil? tweet[:entities][:hashtags].each do |hashtag| hashtag_row += 1 stage_hashtag(sheets[:hashtags], tweet, hashtag[:text], hashtag_row) end end unless tweet[:entities][:urls].nil? tweet[:entities][:urls].each do |url| url_row += 1 stage_url(sheets[:urls], tweet, url[:expanded_url], url_row) end end unless tweet[:entities][:user_mentions].nil? tweet[:entities][:user_mentions].each do |user_mention| user_mention_row += 1 stage_user_mention(sheets[:user_mentions], tweet, user_mention, user_mention_row) end end end log_time("Saving staged tweets to sheet") sheets[:tweets].save() log_time("Saving staged media to sheet") sheets[:media].save() log_time("Saving staged hashtags to sheet") sheets[:hashtags].save() log_time("Saving staged urls to sheet") sheets[:urls].save() log_time("Saving staged user_mentions to sheet") sheets[:user_mentions].save() log_time("Staging max since_id to " + tweets[:search_metadata][:max_id].to_s) sheets[:meta][1,2] = "'" + tweets[:search_metadata][:max_id].to_s log_time("Staging last rows") sheets[:meta][4,2] = tweet_row sheets[:meta][5,2] = media_row sheets[:meta][6,2] = hashtag_row sheets[:meta][7,2] = url_row sheets[:meta][8,2] = user_mention_row log_time("Saving staged data to sheet") sheets[:meta].save() log_time("sleeping for 60 seconds") sleep 60 end
AmnestyInternational/visor
twitter_to_gdoc.rb
Ruby
mit
7,536
<?php location(BASEURL ."/view/t411/search");
Reeska/restinpi
src/server/plugins/t411/views/index.php
PHP
mit
46
using System; using System.Collections.Generic; using System.Linq; using Polyglot; using Cysharp.Threading.Tasks; using LiteDB; using Sentry; using UnityEngine; #if UNITY_IOS using UnityEngine.iOS; #elif UNITY_ANDROID using Google.Play.Review; #endif public class Player { public string Id => Settings.PlayerId; public LocalPlayerSettings Settings { get; private set; } public bool ShouldMigrate { get; private set; } private readonly LocalPlayerLegacy legacy = new LocalPlayerLegacy(); public void Initialize() { LoadSettings(); ValidateData(); if (!Settings.PlayerId.IsNullOrWhiteSpace()) { SentrySdk.ConfigureScope(scope => scope.User = new User {Username = Settings.PlayerId}); } } public async void BoostStoreReviewConfidence() { Settings.RequestStoreReviewConfidence++; if (Settings.RequestStoreReviewConfidence >= 5 && !Settings.RequestedForStoreReview) { Settings.RequestedForStoreReview = true; await RequestStoreReview(); } SaveSettings(); } public async UniTask RequestStoreReview() { #if UNITY_IOS Device.RequestStoreReview(); #elif UNITY_ANDROID if (Context.Distribution == Distribution.TapTap) { Context.AudioManager.Get("ActionSuccess").Play(); Dialog.Prompt("享受 Cytoid 吗?\n请在 TapTap 上给我们打个分吧!", () => { Application.OpenURL("https://www.taptap.com/app/158749"); }); } else { var reviewManager = new ReviewManager(); var requestFlow = reviewManager.RequestReviewFlow(); await requestFlow; if (requestFlow.Error != ReviewErrorCode.NoError) { Debug.LogWarning("Failed to launch Google Play review request flow"); Debug.LogWarning(requestFlow.Error.ToString()); return; } var reviewInfo = requestFlow.GetResult(); var launchFlow = reviewManager.LaunchReviewFlow(reviewInfo); await launchFlow; if (launchFlow.Error != ReviewErrorCode.NoError) { Debug.LogWarning("Failed to launch Google Play review request flow"); Debug.LogWarning(launchFlow.Error.ToString()); } } #endif } public bool ShouldEnableDebug() { return Id == "tigerhix" || Id == "neo"; } public void ValidateData() { var col = Context.Database.GetCollection<LevelRecord>("level_records"); col.DeleteMany(it => it.LevelId == null); if (!Localization.Instance.SupportedLanguages.Contains((Language) Settings.Language)) { Settings.Language = (int) Language.English; } // Save default Sayaka character meta var characterCol = Context.Database.GetCollection<CharacterMeta>("characters"); if (!characterCol.Exists(it => it.Id == BuiltInData.DefaultCharacterId)) { characterCol.Insert(BuiltInData.DefaultCharacterMeta); } } public void LoadSettings() { Context.Database.Let(it => { if (!it.CollectionExists("settings")) { Debug.LogWarning("Cannot find 'settings' collections"); } var col = it.GetCollection<LocalPlayerSettings>("settings"); var result = col.FindOne(x => true); if (result == null) { Debug.LogWarning("First time startup. Initializing settings..."); // TODO: Remove migration... one day ShouldMigrate = true; result = InitializeSettings(); col.Insert(result); } Settings = result; FillDefault(); Settings.TotalLaunches++; SaveSettings(); }); } public void SaveSettings() { if (Settings == null) throw new InvalidOperationException(); Context.Database.Let(it => { var col = it.GetCollection<LocalPlayerSettings>("settings"); col.DeleteMany(x => true); col.Insert(Settings); }); } private void FillDefault() { var dummy = new LocalPlayerSettings(); Settings.NoteRingColors = dummy.NoteRingColors.WithOverrides(Settings.NoteRingColors); Settings.NoteFillColors = dummy.NoteFillColors.WithOverrides(Settings.NoteFillColors); Settings.NoteFillColorsAlt = dummy.NoteFillColorsAlt.WithOverrides(Settings.NoteFillColorsAlt); if (ShouldOneShot("Reset Graphics Quality")) { Settings.GraphicsQuality = GetDefaultGraphicsQuality(); } if (ShouldOneShot("Enable/Disable Menu Transitions Based On Graphics Quality")) { Settings.UseMenuTransitions = Settings.GraphicsQuality >= GraphicsQuality.High; } } public async UniTask Migrate() { await UniTask.DelayFrame(30); try { Context.Database.Let(it => { foreach (var level in Context.LevelManager.LoadedLocalLevels.Values) { if (level.Id == null) continue; var record = new LevelRecord { LevelId = level.Id, RelativeNoteOffset = legacy.GetLevelNoteOffset(level.Id), AddedDate = legacy.GetAddedDate(level.Id).Let(time => time == default ? DateTimeOffset.MinValue : new DateTimeOffset(time)), LastPlayedDate = legacy.GetLastPlayedDate(level.Id).Let(time => time == default ? DateTimeOffset.MinValue : new DateTimeOffset(time)), BestPerformances = new Dictionary<string, LevelRecord.Performance>(), BestPracticePerformances = new Dictionary<string, LevelRecord.Performance>(), PlayCounts = new Dictionary<string, int>(), }; foreach (var chart in level.Meta.charts) { record.PlayCounts[chart.type] = legacy.GetPlayCount(level.Id, chart.type); if (legacy.HasPerformance(level.Id, chart.type, true)) { var bestPerformance = legacy.GetBestPerformance(level.Id, chart.type, true).Let(p => new LevelRecord.Performance { Score = p.Score, Accuracy = p.Accuracy / 100.0, }); record.BestPerformances[chart.type] = bestPerformance; } if (legacy.HasPerformance(level.Id, chart.type, false)) { var bestPracticePerformance = legacy.GetBestPerformance(level.Id, chart.type, false).Let( p => new LevelRecord.Performance { Score = p.Score, Accuracy = p.Accuracy / 100.0, }); record.BestPracticePerformances[chart.type] = bestPracticePerformance; } } Context.Database.SetLevelRecord(record, true); level.Record = record; } }); } catch (Exception e) { Debug.LogError(e); } } private LocalPlayerSettings InitializeSettings() { var settings = new LocalPlayerSettings { SchemaVersion = 1, PlayerId = PlayerPrefs.GetString("Uid"), LoginToken = SecuredPlayerPrefs.GetString("JwtToken", null), ActiveCharacterId = null, Language = (int) Localization.Instance.ConvertSystemLanguage(Application.systemLanguage) .Let(it => Localization.Instance.SupportedLanguages.Contains(it) ? it : Language.English), PlayRanked = legacy.PlayRanked, EnabledMods = legacy.EnabledMods.ToList(), DisplayBoundaries = true, DisplayEarlyLateIndicators = true, HitboxSizes = new Dictionary<NoteType, int> { {NoteType.Click, legacy.ClickHitboxSize}, {NoteType.DragChild, legacy.DragHitboxSize}, {NoteType.DragHead, legacy.DragHitboxSize}, {NoteType.Hold, legacy.HoldHitboxSize}, {NoteType.LongHold, legacy.HoldHitboxSize}, {NoteType.Flick, legacy.FlickHitboxSize}, }, NoteRingColors = new Dictionary<NoteType, Color> { {NoteType.Click, legacy.GetRingColor(NoteType.Click, false)}, {NoteType.DragChild, legacy.GetRingColor(NoteType.DragChild, false)}, {NoteType.DragHead, legacy.GetRingColor(NoteType.DragHead, false)}, {NoteType.Hold, legacy.GetRingColor(NoteType.Hold, false)}, {NoteType.LongHold, legacy.GetRingColor(NoteType.LongHold, false)}, {NoteType.Flick, legacy.GetRingColor(NoteType.Flick, false)}, }, NoteFillColors = new Dictionary<NoteType, Color> { {NoteType.Click, legacy.GetFillColor(NoteType.Click, false)}, {NoteType.DragChild, legacy.GetFillColor(NoteType.DragChild, false)}, {NoteType.DragHead, legacy.GetFillColor(NoteType.DragHead, false)}, {NoteType.Hold, legacy.GetFillColor(NoteType.Hold, false)}, {NoteType.LongHold, legacy.GetFillColor(NoteType.LongHold, false)}, {NoteType.Flick, legacy.GetFillColor(NoteType.Flick, false)}, }, NoteFillColorsAlt = new Dictionary<NoteType, Color> { {NoteType.Click, legacy.GetFillColor(NoteType.Click, true)}, {NoteType.DragChild, legacy.GetFillColor(NoteType.DragChild, true)}, {NoteType.DragHead, legacy.GetFillColor(NoteType.DragHead, true)}, {NoteType.Hold, legacy.GetFillColor(NoteType.Hold, true)}, {NoteType.LongHold, legacy.GetFillColor(NoteType.LongHold, true)}, {NoteType.Flick, legacy.GetFillColor(NoteType.Flick, true)}, }, HoldHitSoundTiming = (HoldHitSoundTiming) legacy.HoldHitSoundTiming, NoteSize = legacy.NoteSize, HorizontalMargin = legacy.HorizontalMargin, VerticalMargin = legacy.VerticalMargin, CoverOpacity = legacy.CoverOpacity, MusicVolume = legacy.MusicVolume, SoundEffectsVolume = legacy.SoundEffectsVolume, HitSound = "none", HitTapticFeedback = legacy.HitTapticFeedback, DisplayStoryboardEffects = legacy.UseStoryboardEffects, GraphicsQuality = GetDefaultGraphicsQuality(), BaseNoteOffset = legacy.BaseNoteOffset, HeadsetNoteOffset = legacy.HeadsetNoteOffset, ClearEffectsSize = legacy.ClearFXSize, DisplayProfiler = legacy.DisplayProfiler, DisplayNoteIds = legacy.DisplayNoteIds, LocalLevelSort = Enum.TryParse<LevelSort>(legacy.LocalLevelsSortBy, out var sort) ? sort : LevelSort.AddedDate, AndroidDspBufferSize = 1024, // Force 1024 LocalLevelSortIsAscending = legacy.LocalLevelsSortInAscendingOrder }; return settings; } private GraphicsQuality GetDefaultGraphicsQuality() { if (Application.platform == RuntimePlatform.IPhonePlayer) { #if UNITY_IOS if (UnityEngine.iOS.Device.generation >= UnityEngine.iOS.DeviceGeneration.iPadPro2Gen) { return GraphicsQuality.Ultra; } if (UnityEngine.iOS.Device.generation >= UnityEngine.iOS.DeviceGeneration.iPhone8) { return GraphicsQuality.High; } if (UnityEngine.iOS.Device.generation >= UnityEngine.iOS.DeviceGeneration.iPhone7) { return GraphicsQuality.Medium; } return GraphicsQuality.Low; #endif } if (Application.platform == RuntimePlatform.Android) { var freq = SystemInfo.processorFrequency; Debug.Log("Processor count: " + SystemInfo.processorCount); Debug.Log("Processor frequency: "); return GraphicsQuality.Medium; } return GraphicsQuality.Ultra; } public bool ShouldOneShot(string key) { if (Settings == null) throw new InvalidOperationException(); var used = Settings.PerformedOneShots.Contains(key); if (used) return false; Settings.PerformedOneShots.Add(key); SaveSettings(); return true; } public void ClearOneShot(string key) { if (Settings == null) throw new InvalidOperationException(); Settings.PerformedOneShots.Remove(key); SaveSettings(); } public bool ShouldTrigger(string key, bool clear = true) { if (Settings == null) throw new InvalidOperationException(); var set = Settings.SetTriggers.Contains(key); if (!set) return false; if (clear) { Settings.SetTriggers.Remove(key); SaveSettings(); } return true; } public void ClearTrigger(string key) { ShouldTrigger(key); } public void SetTrigger(string key) { if (Settings == null) throw new InvalidOperationException(); Settings.SetTriggers.Add(key); SaveSettings(); } } public class StringKey { public const string FirstLaunch = "First Launch1211111111111"; } public class LocalPlayerLegacy { public bool PlayRanked { get => PlayerPrefsExtensions.GetBool("ranked"); set => PlayerPrefsExtensions.SetBool("ranked", value); } public HashSet<Mod> EnabledMods { get => new HashSet<Mod>(PlayerPrefsExtensions.GetStringArray("mods").Select(it => (Mod) Enum.Parse(typeof(Mod), it)).ToList()); set => PlayerPrefsExtensions.SetStringArray("mods", value.Select(it => it.ToString()).ToArray()); } public bool ShowBoundaries { get => PlayerPrefsExtensions.GetBool("boundaries", false); set => PlayerPrefsExtensions.SetBool("boundaries", value); } public bool DisplayEarlyLateIndicators { get => PlayerPrefsExtensions.GetBool("early_late_indicator", true); set => PlayerPrefsExtensions.SetBool("early_late_indicator", value); } public int ClickHitboxSize { get => PlayerPrefs.GetInt("click hitbox size", 2); set => PlayerPrefs.SetInt("click hitbox size", value); } public int DragHitboxSize { get => PlayerPrefs.GetInt("drag hitbox size", 2); set => PlayerPrefs.SetInt("drag hitbox size", value); } public int HoldHitboxSize { get => PlayerPrefs.GetInt("hold hitbox size", 2); set => PlayerPrefs.SetInt("hold hitbox size", value); } public int FlickHitboxSize { get => PlayerPrefs.GetInt("flick hitbox size", 1); set => PlayerPrefs.SetInt("flick hitbox size", value); } public int HoldHitSoundTiming { get => PlayerPrefs.GetInt("HoldHitSoundTiming", (int) global::HoldHitSoundTiming.Both); set => PlayerPrefs.SetInt("HoldHitSoundTiming", value); } // Bounded by -0.5~0.5. public float NoteSize { get => PlayerPrefs.GetFloat("NoteSize", 0); set => PlayerPrefs.SetFloat("NoteSize", value); } // Bounded by 1~5. public int HorizontalMargin { get => (int) PlayerPrefs.GetFloat("HorizontalMargin", 3); set => PlayerPrefs.SetFloat("HorizontalMargin", value); } // Bounded by 1~5. public int VerticalMargin { get => (int) PlayerPrefs.GetFloat("VerticalMargin", 3); set => PlayerPrefs.SetFloat("VerticalMargin", value); } // Bounded by 0~1. public float CoverOpacity { get => PlayerPrefs.GetFloat("CoverOpacity", 0.15f); set => PlayerPrefs.SetFloat("CoverOpacity", value); } // Bounded by 0~1. public float MusicVolume { get => PlayerPrefs.GetFloat("MusicVolume", 0.85f); set => PlayerPrefs.SetFloat("MusicVolume", value); } // Bounded by 0~1. public float SoundEffectsVolume { get => PlayerPrefs.GetFloat("SoundEffectsVolume", 1f); set => PlayerPrefs.SetFloat("SoundEffectsVolume", value); } public string HitSound { get => PlayerPrefs.GetString("HitSound", "none").ToLower(); set => PlayerPrefs.SetString("HitSound", value.ToLower()); } public bool HitTapticFeedback { get => PlayerPrefsExtensions.GetBool("HitTapticFeedback", true); set => PlayerPrefsExtensions.SetBool("HitTapticFeedback", value); } public bool UseStoryboardEffects { get => PlayerPrefsExtensions.GetBool("StoryboardEffects", true); set => PlayerPrefsExtensions.SetBool("StoryboardEffects", value); } public string GraphicsQuality { get => PlayerPrefs.GetString("GraphicsQuality", Application.platform == RuntimePlatform.Android ? "medium" : "high"); set => PlayerPrefs.SetString("GraphicsQuality", value.ToLower()); } public float BaseNoteOffset { get => PlayerPrefs.GetFloat("main chart offset", Application.platform == RuntimePlatform.Android ? 0.2f : 0.1f); set => PlayerPrefs.SetFloat("main chart offset", value); } public float HeadsetNoteOffset { get => PlayerPrefs.GetFloat("headset chart offset", -0.05f); set => PlayerPrefs.SetFloat("headset chart offset", value); } public float ClearFXSize { get => PlayerPrefs.GetFloat("ClearFXSize", 0); set => PlayerPrefs.SetFloat("ClearFXSize", value); } public bool DisplayProfiler { get => PlayerPrefsExtensions.GetBool("profiler", false); set { PlayerPrefsExtensions.SetBool("profiler", value); Context.UpdateProfilerDisplay(); } } public bool DisplayNoteIds { get => PlayerPrefsExtensions.GetBool("note ids"); set => PlayerPrefsExtensions.SetBool("note ids", value); } public string LocalLevelsSortBy { get => PlayerPrefs.GetString("local levels sort by", LevelSort.AddedDate.ToString()); set => PlayerPrefs.SetString("local levels sort by", value); } public int DspBufferSize { get => PlayerPrefs.GetInt("AndroidDspBufferSize", -1); set => PlayerPrefs.SetInt("AndroidDspBufferSize", value); } public bool LocalLevelsSortInAscendingOrder { get => PlayerPrefsExtensions.GetBool("local levels sort in ascending order", false); set => PlayerPrefsExtensions.SetBool("local levels sort in ascending order", value); } public float GetLevelNoteOffset(string levelId) { return PlayerPrefs.GetFloat($"level {levelId} chart offset", 0); } public void SetLevelNoteOffset(string levelId, float offset) { PlayerPrefs.SetFloat($"level {levelId} chart offset", offset); } public Color GetRingColor(NoteType type, bool alt) { return PlayerPrefsExtensions.GetColor("ring color", "#FFFFFF"); } public void SetRingColor(NoteType type, bool alt, Color color) { PlayerPrefsExtensions.SetColor("ring color", color); } private static Dictionary<NoteType, string> NoteTypeConfigKeyMapping = new Dictionary<NoteType, string> { {NoteType.Click, "click"}, {NoteType.DragHead, "drag"}, {NoteType.DragChild, "drag"}, {NoteType.Hold, "hold"}, {NoteType.LongHold, "long hold"}, {NoteType.Flick, "flick"} }; private static Dictionary<NoteType, string[]> NoteTypeDefaultFillColors = new Dictionary<NoteType, string[]> { {NoteType.Click, new[] {"#35A7FF", "#FF5964"}}, {NoteType.DragHead, new[] {"#39E59E", "#39E59E"}}, {NoteType.DragChild, new[] {"#39E59E", "#39E59E"}}, {NoteType.Hold, new[] {"#35A7FF", "#FF5964"}}, {NoteType.LongHold, new[] {"#F2C85A", "#F2C85A"}}, {NoteType.Flick, new[] {"#35A7FF", "#FF5964"}} }; public Color GetFillColor(NoteType type, bool alt) { return PlayerPrefsExtensions.GetColor($"fill color ({NoteTypeConfigKeyMapping[type]} {(alt ? 2 : 1)})", NoteTypeDefaultFillColors[type][alt ? 1 : 0]); } public void SetFillColor(NoteType type, bool alt, Color color) { PlayerPrefsExtensions.SetColor($"fill color ({NoteTypeConfigKeyMapping[type]} {(alt ? 2 : 1)})", color); } public class Performance { public int Score; public float Accuracy; // 0~100 public string ClearType; } public bool HasPerformance(string levelId, string chartType, bool ranked) { return GetBestPerformance(levelId, chartType, ranked).Score >= 0; } public Performance GetBestPerformance(string levelId, string chartType, bool ranked) { return new Performance { Score = (int) SecuredPlayerPrefs.GetFloat(BestScoreKey(levelId, chartType, ranked), -1), Accuracy = SecuredPlayerPrefs.GetFloat(BestAccuracyKey(levelId, chartType, ranked), -1), ClearType = SecuredPlayerPrefs.GetString(BestClearTypeKey(levelId, chartType, ranked), "") }; } public void SetBestPerformance(string levelId, string chartType, bool ranked, Performance performance) { SecuredPlayerPrefs.SetFloat(BestScoreKey(levelId, chartType, ranked), performance.Score); SecuredPlayerPrefs.SetFloat(BestAccuracyKey(levelId, chartType, ranked), performance.Accuracy); SecuredPlayerPrefs.SetString(BestClearTypeKey(levelId, chartType, ranked), performance.ClearType); } public DateTime GetAddedDate(string levelId) { return SecuredPlayerPrefs.HasKey(AddedKey(levelId)) ? DateTime.Parse(SecuredPlayerPrefs.GetString(AddedKey(levelId), null)) : default; } public void SetAddedDate(string levelId, DateTime dateTime) { SecuredPlayerPrefs.SetString(AddedKey(levelId), dateTime.ToString("s")); } public DateTime GetLastPlayedDate(string levelId) { return SecuredPlayerPrefs.HasKey(LastPlayedKey(levelId)) ? DateTime.Parse(SecuredPlayerPrefs.GetString(LastPlayedKey(levelId), null)) : default; } public void SetLastPlayedDate(string levelId, DateTime dateTime) { SecuredPlayerPrefs.SetString(LastPlayedKey(levelId), dateTime.ToString("s")); } public int GetPlayCount(string levelId, string chartType) { return SecuredPlayerPrefs.GetInt(PlayCountKey(levelId, chartType), 0); } public void SetPlayCount(string levelId, string chartType, int playCount) { SecuredPlayerPrefs.SetInt(PlayCountKey(levelId, chartType), playCount); } private static string AddedKey(string level) => level + " : " + "added"; private static string LastPlayedKey(string level) => level + " : " + "last played"; private static string BestScoreKey(string level, string type, bool ranked) => level + " : " + type + " : " + "best score" + (ranked ? " ranked" : ""); private static string BestAccuracyKey(string level, string type, bool ranked) => level + " : " + type + " : " + "best accuracy" + (ranked ? " ranked" : ""); private static string BestClearTypeKey(string level, string type, bool ranked) => level + " : " + type + " : " + "best clear type" + (ranked ? " ranked" : ""); private static string PlayCountKey(string level, string type) => level + " : " + type + " : " + "play count"; }
TigerHix/Cytoid
Assets/Scripts/Player/Player.cs
C#
mit
24,520
<!-- * @description * * A humpback-view created at Wed Sep 09 2015 15:10:53 GMT-0400 (EDT). --> <!--admin/role/index.ejs--> <div class="admin-header-block"> <div class="grid-content"> <h1>Roles</h1> <p class="lead"> Manage Roles </p> </div> <div class="grid-content"> <a class="button" ui-sref="admin.role.new" > New Role </a> </div> </div> <div class="admin-filters-block" ui-view="filters"> <div class="grid-block"> <div class="grid-content"> <form ng-submit="roles.addFilter()" > <span class="select inline-label"> <select ng-model="roles.filter[0]" ng-options="key as key for (key,value) in roles.model.selected.attributes" > <option value="">-- Search By --</option> </select> <input type="search" placeholder="Search Roles..." ng-model="roles.filter[1]" > <button class="button" > Search </button> </span> </form> <a ng-repeat="(filter, value) in roles.criteria" ng-click="roles.removeFilter(filter)" > <span class="label close">{{ filter }}: {{ value.contains | iif: value.contains : value }}</span> </a> <a ng-click="roles.clearFilters()" > Clear Filters </a> <p> Showing {{ roles.start | number }} - {{ roles.end | number }} of {{ roles.total | number}} </p> </div> </div> <div class="grid-block"> <div class="grid-block"> <div class="grid-content"> <select ng-model="roles.limit" ng-options="items.value as items.name for items in filters.itemsPerPage" ng-change="roles.reset('limit')" > <option value="">-- Items Per Page --</option> </select> </div> </div> <div class="grid-block"> <div class="grid-content"> <select ng-model="roles.sort" ng-options="items.value as items.name for items in filters.itemsSort" ng-change="roles.reset('sort')" > <option value="">-- Sort Items --</option> </select> </div> </div> </div> </div> <div class="admin-body-block" ui-view="content"> <div class="grid-content"> <div class="loader" ng-class="{done: !roles.busy}"> <h2 class="loading-content">Loading Roles...</h2> </div> <div ng-show="roles.visible.length == 0 && !roles.busy" class="not-found text-center"> <h2>No Roles</h2> </div> <div class="admin-well" ng-repeat="role in roles.visible" > <a ui-sref="admin.role.role({id: role.id})"> {{ role.name }} {{ role.createdAt | date }} </a> </div> </div> </div> <div class="admin-footer-block" ui-view="footer"> <div paging class="grid-block align-center" page="roles.page" page-size="roles.limit" total="roles.total" dots="..." adjacent="2" show-prev-next="true" hide-if-empty="true" ul-class="paging-menu-bar" active-class="isActive" disabled-class="isDisabled" paging-action="roles.paging('Paging Clicked', page, pageSize, total)"> </div> </div>
CaliStyle/humpback
assets/app/views/admin/role/index.html
HTML
mit
2,971
namespace GiveCRM.Web.Areas.Admin.Controllers { using System; using System.Web; using System.Web.Mvc; internal class ElmahResult : ActionResult { private readonly string resourceType; public ElmahResult(): this(null) { } public ElmahResult(string resourceType) { this.resourceType = resourceType; } public override void ExecuteResult(ControllerContext context) { var factory = new Elmah.ErrorLogPageFactory(); if (!string.IsNullOrEmpty(this.resourceType)) { var pathInfo = "/" + this.resourceType; context.HttpContext.RewritePath(FilePath(context), pathInfo, context.HttpContext.Request.QueryString.ToString()); } var currentContext = GetCurrentContext(context); var httpHandler = factory.GetHandler(currentContext, null, null, null); var httpAsyncHandler = httpHandler as IHttpAsyncHandler; if (httpAsyncHandler != null) { httpAsyncHandler.BeginProcessRequest(currentContext, r => { }, null); return; } httpHandler.ProcessRequest(currentContext); } private static HttpContext GetCurrentContext(ControllerContext context) { var currentApplication = (HttpApplication)context.HttpContext.GetService(typeof(HttpApplication)); return currentApplication.Context; } private string FilePath(ControllerContext context) { return this.resourceType != "stylesheet" ? context.HttpContext.Request.Path.Replace(String.Format("/{0}", this.resourceType), string.Empty) : context.HttpContext.Request.Path; } } }
GiveCampUK/GiveCRM
src/GiveCRM.Web/Areas/Admin/Controllers/ElmahResult.cs
C#
mit
1,826
<template name="dh_user_menu_label"> <a class="menu-top-level-link" href="#"> <span class="user-menu-label menu-top-level-label"> <!--{{> avatar userId=this._id shape="circle"}} --> <span class="user-menu-username">{{this.getDisplayName}}</span> </span> <span class="menu-items-toggle js-menu-toggle">{{{icon "expand"}}}{{{icon "collapse"}}}</span> </a> </template>
Daz2345/dhPulse
packages/dh-dunnhumby/lib/client/templates/dh_user_menu_label.html
HTML
mit
393
// Copyright (C) 2011-2019 Roki. Distributed under the MIT License #ifndef INCLUDED_SROOK_TMPL_VT_SET_DIFFERENCE_HPP #define INCLUDED_SROOK_TMPL_VT_SET_DIFFERENCE_HPP #include <srook/tmpl/vt/detail/config.hpp> #include <srook/tmpl/vt/unique.hpp> #include <srook/tmpl/vt/concat.hpp> #include <srook/tmpl/vt/not_fn.hpp> #include <srook/tmpl/vt/bind.hpp> #include <srook/tmpl/vt/is_contained_in.hpp> #include <srook/type_traits/conditional.hpp> SROOK_NESTED_NAMESPACE(srook, tmpl, vt) { SROOK_INLINE_NAMESPACE(v1) namespace detail { template <class T, class... U> struct contained_if : conditional<not_fn<is_contained_in>::type<T, U...>::value, T, packer<>> {}; template <class T, class... U> struct contained_if<T, packer<U...>> : contained_if<T, U...> {}; template <class, class> struct set_difference_impl1; template <class X, class... Xs, class R> struct set_difference_impl1<packer<X, Xs...>, R> : concat< SROOK_DEDUCED_TYPENAME contained_if<X, R>::type, SROOK_DEDUCED_TYPENAME set_difference_impl1<packer<Xs...>, R>::type > {}; template <class... R> struct set_difference_impl1<packer<>, packer<R...>> : type_constant<packer<>> {}; template <class L, class R> struct set_difference_impl2 : set_difference_impl1< SROOK_DEDUCED_TYPENAME unique<L>::type, SROOK_DEDUCED_TYPENAME unique<R>::type > {}; } // namespace detail template <class L, class R> struct set_difference : detail::set_difference_impl2<L, R> {}; #if SROOK_CPP_ALIAS_TEMPLATES template <class L, class R> using set_difference_t = SROOK_DEDUCED_TYPENAME set_difference<L, R>::type; #endif SROOK_INLINE_NAMESPACE_END } SROOK_NESTED_NAMESPACE_END(vt, tmpl, srook) #endif
falgon/SrookCppLibraries
srook/tmpl/vt/set_difference.hpp
C++
mit
1,711
/* * The MIT License * * Copyright 2014 Paulius Šukys. * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * THE SOFTWARE. */ package smartfood; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStreamReader; import java.io.UnsupportedEncodingException; import java.net.MalformedURLException; import java.net.URL; import java.net.URLEncoder; import java.util.ArrayList; import java.util.Iterator; import java.util.List; import java.util.logging.Level; import java.util.logging.Logger; import javax.net.ssl.HttpsURLConnection; import org.json.simple.JSONArray; import org.json.simple.JSONObject; import org.json.simple.parser.JSONParser; import org.json.simple.parser.ParseException; /** * A wrapper for Yummly * @author Paulius Šukys */ public class YummlyWrapper { private final Logger logger = jade.util.Logger.getMyLogger(this.getClass().getName()); private final static String API_URL = "https://api.yummly.com/v1/api/"; private final static String APP_ID = "1cf18976"; private final static String APP_KEY = "59bc08e9d8e8d840454478fbca8ae959"; YummlyWrapper() { //exists to defeat instantiation } /** * Searches for a recipe and returns a list of recipes * @param recipe recipe name * @param allowedIngredients list of allowed ingredients * @return list of found recipes */ public List searchRecipe(String recipe, String[] allowedIngredients) { String query = "recipes?q=" + recipe; List<Recipe> recipes; recipes = new ArrayList(); try { query += getAllowedIngredients(allowedIngredients); String response = getResponse(API_URL + query); Iterator<JSONObject> iterator = getJSONmatchArray(response, "matches"); while (iterator.hasNext()) { JSONObject match = iterator.next(); //setting up a Recipe object and appending to arraylist Recipe r = new Recipe(); JSONObject flavors = (JSONObject)match.get("flavors"); if (flavors != null) { r.addFlavor("salty", (double)flavors.get("salty")); r.addFlavor("meaty", (double)flavors.get("meaty")); r.addFlavor("sour", (double)flavors.get("sour")); r.addFlavor("sweet", (double)flavors.get("sweet")); r.addFlavor("bitter", (double)flavors.get("bitter")); } r.setRating((long)match.get("rating")); r.setName((String)match.get("recipeName")); r.setSource((String)match.get("sourceDisplayName")); JSONArray ing = (JSONArray)match.get("ingredients"); Iterator<String> ii = ing.iterator(); while(ii.hasNext()) { r.addIngredient(ii.next()); } r.setId((String)match.get("id")); recipes.add(r); } }catch(UnsupportedEncodingException exc) { logger.log(Level.SEVERE, "Encoding error"); logger.log(Level.SEVERE, exc.getMessage()); } return recipes; } private String getResponse(String query) { StringBuilder response = new StringBuilder(); try { URL url = new URL(query); HttpsURLConnection conn = (HttpsURLConnection)url.openConnection(); conn.setRequestMethod("GET"); conn.setRequestProperty("X-Yummly-App-ID", APP_ID); conn.setRequestProperty("X-Yummly-App-Key", APP_KEY); String res = checkResponse(conn.getResponseCode()); if(!res.isEmpty()) { System.out.println(res); }else { try (BufferedReader in = new BufferedReader(new InputStreamReader( conn.getInputStream()))) { String inputLine = in.readLine(); while (inputLine != null) { response.append(inputLine); inputLine =in.readLine(); } } } conn.disconnect(); }catch(MalformedURLException exc) { logger.log(Level.SEVERE, "Malformed URL:"); logger.log(Level.SEVERE, exc.getMessage()); }catch(IOException exc) { logger.log(Level.SEVERE, "IO error"); logger.log(Level.SEVERE, exc.getMessage()); } return response.toString(); } private String checkResponse(int response) { String msg = ""; switch(response) { case 400: msg = "Bad request"; break; case 409: msg = "API Rate Limit Exceeded"; break; case 500: msg = "Internal Server Error"; break; default: msg = "Unknown error"; break; } return msg; } /** * Simply a method to make a query string for GET request * @param ingredients String array of ingredients * @return query string for GET request part */ private String getAllowedIngredients(String[] ingredients) throws UnsupportedEncodingException { String query = ""; for (String ingredient: ingredients) { query += "&allowedIngredient[]="; query += URLEncoder.encode(ingredient, "UTF-8"); } return query; } /** * Parses JSON into found queried objects iterator * @param content string to parse as json * @param query text to match in json * @return iterator for jsonarray */ private Iterator<JSONObject> getJSONmatchArray(String content, String query) { try { //since response is in json - parse it! JSONParser jsonparser = new JSONParser(); JSONObject obj = (JSONObject)jsonparser.parse(content); //adding all matches to array JSONArray matches = (JSONArray)obj.get(query); return matches.iterator(); } catch (ParseException ex) { logger.log(Level.SEVERE, "Error while parsing JSON"); logger.log(Level.SEVERE, null, ex); } return null; } }
shookees/SmartFood_old
src/smartfood/YummlyWrapper.java
Java
mit
7,629
var request = require('request'), Q = require('q'), xml2js = require('xml2js'), _ = require('lodash'); module.exports = { /** * Helper function that handles the http request * * @param {string} url */ httprequest: function(url) { var deferred = Q.defer(); request(url, function(err, response, body) { if (err) { deferred.reject(new Error(err)); } else if (!err && response.statusCode !== 200) { deferred.reject(new Error(response.statusCode)); } else { deferred.resolve(body); } }); return deferred.promise; }, /** * Helper function that converts xml to json * * @param {xml} xml */ toJson: function(xml) { var deferred = Q.defer(); xml2js.parseString(xml, function(err, result) { if (err) { deferred.reject(new Error(err)); } else { deferred.resolve(result); } }); return deferred.promise; }, /** * Helper function that takes params hash and converts it into query string * * @param {object} params * @param {Number} id */ toQueryString: function(params, id) { var paramsString = ''; for (var key in params) { if (params.hasOwnProperty(key)) { paramsString += '&' + key + '=' + encodeURIComponent(params[key]); } } return 'zws-id=' + id + paramsString; }, /** * Helper function that checks for the required params * * @param {object} params * @param {array} reqParams -- required parameters */ checkParams: function(params, reqParams) { if ( reqParams.length < 1 ) return; if ( (_.isEmpty(params) || !params) && (reqParams.length > 0) ){ throw new Error('Missing parameters: ' + reqParams.join(', ')); } var paramsKeys = _.keys(params); _.each(reqParams, function(reqParam) { if ( paramsKeys.indexOf(reqParam) === -1 ) { throw new Error('Missing parameter: ' + reqParam); } }); } };
LoganArnett/node-zillow
lib/helpers.js
JavaScript
mit
1,998
# frozen_string_literal: true module Signable module Concerns module Query extend ActiveSupport::Concern def save return false unless valid? persisted? ? update : create end def delete self.class.client.delete self.class.entry_point, id end def persisted? id.present? rescue StandardError false end private def update response = self.class.client.update self.class.entry_point, id, self response.ok? end def create response = self.class.client.create self.class.entry_point, self if response.ok? self.attributes = response.object true else false end end module ClassMethods def all(offset: 0, limit: 30) response = client.all(entry_point, offset, limit) if response.ok? List.new(self, response.object) else [] end end def find(id) response = client.find(entry_point, id) new response.object if response.ok? end def entry_point prefix.pluralize end def client @client ||= Signable::Query::Client.new end end end end end
smartpension/signable
lib/signable/concerns/query.rb
Ruby
mit
1,321
var closet = closet || {}; (function($) { closet.folders = (function() { var iconPlus = '<img class="icon" style="width:10px" src="/static/image/16x16/Plus.png"/>'; var iconMinus = '<img class="icon" style="width:10px" src="/static/image/16x16/Minus.png"/>'; var iconEmpty = '<img class="icon" style="width:10px" src="/static/image/16x16/Folder3.png"/>'; var toggle = function($root) { var $children = $root.children('div.children'); var $toggle = $root.children('a.toggle'); if ($children.css('display') === 'none') { $children.css('display', ''); $toggle.html(iconMinus); } else { $children.css('display', 'none'); $toggle.html(iconPlus); } }; var addFolders = function($root, depth, cb) { var root = $root.data('path'); var $children = $root.children('div.children'); toggle($root); var url = '/pcaps/1/list?by=path'; if (depth > 1) { var paths = root.split('/'); var startkey = paths.concat([0]); var endkey = paths.concat([{}]); url += '&startkey=' + JSON.stringify(startkey); url += '&endkey=' + JSON.stringify(endkey); } $.ajax({ url: url, data: { group_level: depth, limit: 20 }, dataType: 'json', success: function(kvs) { if (kvs.rows.length === 0 && depth > 1) { $root.find('a.toggle').replaceWith(iconEmpty); return; } $.each(kvs.rows, function(_, kv) { if (kv.key.length !== depth) { return; } var path = kv.key.join('/'); $children.append( '<div class="folder">' + '<a class="toggle"/>&nbsp;' + '<a class="link" title="' + path + '">' + kv.key[depth-1] + '</a>' + '&nbsp;' + '<sup style="font-size:smaller">' + kv.value + '</sup>' + '<div class="children" style="margin-left:20px;display:none"/>' + '</div>' ).find('div.folder:last').data('path', path); }); $children .find('a.toggle').attr('href', 'javascript:void(0)') .html('<img class="icon" style="width:10px" src="/static/image/16x16/Plus.png"/>') .click(function() { var folder = $(this).parent('div.folder'); var children = $(this).nextAll('div.children'); if (children.children().length === 0) { addFolders(folder, depth+1, cb); } else { toggle(folder); } }) .end() .find('a.link').attr('href', 'javascript:void(0)') .click(function() { cb($(this).parent('div.folder').data('path')); }); } }); }; return { manage: function($root, cb) { var $f = $root.data('folders'); if (!$f) { $f = $('<div class="folder" style="margin-top: 20px;margin-bottom:20px"><div class="children" style="display:none"/></div>'); $f.data('path', '/'); $root.data('folders', $f); addFolders($f, 1, cb); } $root.empty().append($f); } }; }()); }(jQuery));
mudynamics/pcapr-local
lib/pcapr_local/www/static/script/closet/closet.folders.js
JavaScript
mit
3,861
import sys import pdb import svgfig import json import os import math import random def show_help(): print("Usage: main.py input_file [--silent] [--output=<out.svg>]" + " [--order=order.txt]") print("Input file is either a text file containing t u v," + "or a JSON file where the following properties are available:") print(" from") print(" to") print(" time") print(" color: to be chosen in " + "http://www.december.com/html/spec/colorsvg.html") print("The orderFile contains a list of all nodes to display " + "in the order of appearance in orderFile.") def read_argv(argv): for arg in sys.argv: if "=" in arg: content = arg.split("=") arg_name = content[0].replace("--", "") argv[arg_name] = content[1] elif "--" in arg: arg_name = arg.replace("--", "") argv[arg_name] = True def version(): sys.stderr.write("\tLinkStreamViz 1.0 -- Jordan Viard 2015\n") class idGenerator: """generates id""" def __init__(self): self.lookUp = dict() # dict[Node] = id self.idCount = 0 self.reverse = dict() # dict[id] = node def impose(self, node, id_): self.lookUp[node] = id_ self.reverse[id_] = node def contains(self, element): return element in self.lookUp def get(self, element): if element not in self.lookUp: while self.idCount in self.reverse and self.reverse[self.idCount] != element: self.idCount += 1 self.lookUp[element] = self.idCount self.reverse[self.idCount] = element return self.lookUp[element] def size(self): return len(self.lookUp) class Link: def __init__(self, t, u, v, color="black", direction=0, duration=0, duration_color="black"): self.t = float(t) self.u = int(min(u, v)) self.v = int(max(u, v)) self.color = color self.direction = direction self.duration = duration self.duration_color = duration_color @staticmethod def from_dict(link): obj = Link(link["time"], link["from"], link["to"]) obj.color = link.get("color", "black") obj.direction = link.get("direction", 0) obj.duration = float(link.get("duration", 0)) obj.duration_color = link.get("duration_color", "black") return obj class LinkStream: def __init__(self, inputFile, orderFile=""): self.links = [] self.max_time = 0 self.nodeID = idGenerator() self.max_label_len = 0 self.g = svgfig.SVG("g") self.ppux = 10 # piwel per unit time if "json" in inputFile: with open(inputFile, 'r') as inFile: json_struct = json.loads(inFile.read()) for link_json in json_struct: link = Link.from_dict(link_json) self.addNode(link.u) self.addNode(link.v) if (link.t + link.duration) > self.max_time: self.max_time = link.t + link.duration self.links.append(link) else: with open(inputFile, 'r') as inFile: for line in inFile: contents = line.split(" ") t = float(contents[0]) u = int(contents[1]) v = int(contents[2]) d = 0 if len(contents) > 3: d = float(contents[3]) self.addNode(u) self.addNode(v) if t > self.max_time: self.max_time = t self.links.append(Link(t, u, v, duration=d)) if orderFile != "": tmp_nodes = set() with open(orderFile, 'r') as order: for i, n in enumerate(order): node = int(n) tmp_nodes.add(node) if self.nodeID.contains(node): self.nodeID.impose(node, i) self.nodes.append(node) else: print('The node', node, "is not present in the stream") exit() for node in self.nodeID.lookUp: if node not in tmp_nodes: print('The node', node, "is not present in", orderFile) exit() def addNode(self, node): self.nodeID.get(node) if self.max_label_len < len(str(node)): self.max_label_len = len(str(node)) def evaluateOrder(self, order): distance = 0 for link in self.links: distance += abs(order[link.u]-order[link.v]) return distance def findOrder(self): cur_solution = self.nodeID.lookUp cur_reverse = self.nodeID.reverse dist = self.evaluateOrder(cur_solution) sys.stderr.write("Order improved from "+str(dist)) for i in range(0, 10000): i = random.randint(0, len(cur_solution) - 1) j = random.randint(0, len(cur_solution) - 1) cur_reverse[j], cur_reverse[i] = cur_reverse[i], cur_reverse[j] cur_solution[cur_reverse[j]] = j cur_solution[cur_reverse[i]] = i tmp = self.evaluateOrder(cur_solution) if tmp >= dist: # re swap to go back. cur_reverse[j], cur_reverse[i] = cur_reverse[i], cur_reverse[j] cur_solution[cur_reverse[j]] = j cur_solution[cur_reverse[i]] = i else: dist = tmp self.nodeID.lookUp = cur_solution new_order = "new_order.txt" with open(new_order, "w") as out: for node in self.nodeID.reverse: out.write(str(self.nodeID.reverse[node]) + "\n") sys.stderr.write(" to "+str(dist)+". Order saved in:"+new_order+"\n") def addDuration(self, origin, duration, color, amplitude=1): freq = 0.8 # angular frequency duration = duration * self.ppux self.g.append(svgfig.SVG("line", stroke=color, stroke_opacity=0.8, stroke_width=1.1, x1=origin["x"], y1=origin["y"], x2=origin["x"]+duration, y2=origin["y"])) def draw(self, outputFile): self.findOrder() offset = 1.5 * self.ppux # Define dimensions label_margin = 5 * self.max_label_len origleft = label_margin + 1 * self.ppux right_margin = self.ppux width = origleft + self.ppux * math.ceil(self.max_time) + right_margin svgfig._canvas_defaults["width"] = str(width) + 'px' arrow_of_time_height = 5 height = 5 + 10 * int(self.nodeID.size() + 1) + arrow_of_time_height svgfig._canvas_defaults["height"] = str(height) + 'px' origtop = 10 ################ # Draw background lines for node in self.nodeID.lookUp: horizonta_axe = self.ppux * self.nodeID.get(node) + origtop self.g.append(svgfig.SVG("text", str(node), x=str(label_margin), y=horizonta_axe + 2, fill="black", stroke_width=0, text_anchor="end", font_size="6")) self.g.append(svgfig.SVG("line", stroke_dasharray="2,2", stroke_width=0.5, x1=str(origleft-5), y1=horizonta_axe, x2=width - right_margin, y2=horizonta_axe)) # Add timearrow self.g.append(svgfig.SVG("line", stroke_width=0.5, x1=self.ppux , y1=10*(self.nodeID.size()+1), x2=width-5, y2=10*(self.nodeID.size()+1))) self.g.append(svgfig.SVG("line", stroke_width=0.5, x1=width-8, y1=10*(self.nodeID.size()+1)-3, x2=width-5, y2=10*(self.nodeID.size()+1))) self.g.append(svgfig.SVG("line", stroke_width=0.5, x1=width-8, y1=10*(self.nodeID.size()+1)+3, x2=width-5, y2=10*(self.nodeID.size()+1))) self.g.append(svgfig.SVG("text", str("Time"), x=width-19, y=10*(self.nodeID.size()+1)-3, fill="black", stroke_width=0, font_size="6")) # # Add time ticks for i in range(0, int(math.ceil(self.max_time)+1), 5): x_tick = i * self.ppux + origleft self.g.append(svgfig.SVG("line", stroke_width=0.5, x1=str(x_tick), y1=10*(self.nodeID.size()+1)-3, x2=str(x_tick), y2=10*(self.nodeID.size()+1)+3)) self.g.append(svgfig.SVG("text", str(i), x=str(x_tick), y=10*(self.nodeID.size()+1)+7, fill="black", stroke_width=0, font_size="6")) for link in self.links: ts = link.t node_1 = min(self.nodeID.get(link.u), self.nodeID.get(link.v)) node_2 = max(self.nodeID.get(link.u), self.nodeID.get(link.v)) offset = ts * self.ppux + origleft y_node1 = 10 * node_1 + origtop y_node2 = 10 * node_2 + origtop # Add nodes self.g.append(svgfig.SVG("circle", cx=offset, cy=y_node1, r=1, fill=link.color)) self.g.append(svgfig.SVG("circle", cx=offset, cy=y_node2, r=1, fill=link.color)) x = 0.2 * ((10 * node_2 - 10 * node_1) / math.tan(math.pi / 3)) + offset y = (y_node1 + y_node2) / 2 param_d = "M" + str(offset) + "," + str(y_node1) +\ " C" + str(x) + "," + str(y) + " " + str(x) + "," + str(y) +\ " " + str(offset) + "," + str(y_node2) self.g.append(svgfig.SVG("path", stroke=link.color, d=param_d)) self.addDuration({"x": x, "y": (y_node1+y_node2)/2}, link.duration, link.duration_color) # Save to svg file viewBoxparam = "0 0 " + str(width) + " " + str(height) svgfig.canvas(self.g, viewBox=viewBoxparam).save(outputFile) if __name__ == '__main__': if len(sys.argv) < 2 or "--help" in sys.argv or "-h" in sys.argv: show_help() sys.exit() if "-v" in sys.argv or "--version" in sys.argv: version() exit() argv = {"order": "", "silent": False} read_argv(argv) Links = LinkStream(sys.argv[1], argv["order"]) default_output = os.path.basename(sys.argv[1]).split(".")[0]+".svg" argv["output"] = argv.get("output", default_output) Links.draw(argv["output"]) if not argv["silent"]: sys.stderr.write("Output generated to " + argv["output"] + ".\n")
JordanV/LinkStreamViz
main.py
Python
mit
11,963
/** * @license * Copyright Google Inc. All Rights Reserved. * * Use of this source code is governed by an MIT-style license that can be * found in the LICENSE file at https://angular.io/license */ import { Component, OnInit } from '@angular/core'; @Component({ selector: 'app-comp-4719', templateUrl: './comp-4719.component.html', styleUrls: ['./comp-4719.component.css'] }) export class Comp4719Component implements OnInit { constructor() { } ngOnInit() { } }
angular/angular-cli-stress-test
src/app/components/comp-4719/comp-4719.component.ts
TypeScript
mit
484
from django.contrib import admin from player.models import Room, PlaylistTrack from ordered_model.admin import OrderedModelAdmin class RoomAdmin(admin.ModelAdmin): list_display = ('name', 'shuffle', 'current_music', 'can_adjust_volume') class ItemAdmin(OrderedModelAdmin): list_display = ('move_up_down_links', 'order', 'track', 'room') admin.site.register(Room, RoomAdmin) admin.site.register(PlaylistTrack, ItemAdmin)
Amoki/Amoki-Music
player/admin.py
Python
mit
434
define(function(require) { var $ = require('jquery'); var Point = require('joss/geometry/Point'); var _scrollIsRelative = !($.browser.opera || $.browser.safari && $.browser.version < "532"); /** * Returns a DOM element lying at a point * * @param {joss/geometry/Point} p * @return {Element} */ var fromPoint = function(x, y) { if(!document.elementFromPoint) { return null; } var p; if (x.constructor === Point) { p = x; } else { p = new Point(x, y); } if(_scrollIsRelative) { p.x -= $(document).scrollLeft(); p.y -= $(document).scrollTop(); } return document.elementFromPoint(p.x, p.y); }; return fromPoint; });
zship/joss
src/joss/util/elements/fromPoint.js
JavaScript
mit
681
/* Google Material Design Icons */ export declare const sharp10k: string; export declare const sharp10mp: string; export declare const sharp11mp: string; export declare const sharp12mp: string; export declare const sharp13mp: string; export declare const sharp14mp: string; export declare const sharp15mp: string; export declare const sharp16mp: string; export declare const sharp17mp: string; export declare const sharp18mp: string; export declare const sharp19mp: string; export declare const sharp1k: string; export declare const sharp1kPlus: string; export declare const sharp1xMobiledata: string; export declare const sharp20mp: string; export declare const sharp21mp: string; export declare const sharp22mp: string; export declare const sharp23mp: string; export declare const sharp24mp: string; export declare const sharp2k: string; export declare const sharp2kPlus: string; export declare const sharp2mp: string; export declare const sharp30fps: string; export declare const sharp30fpsSelect: string; export declare const sharp360: string; export declare const sharp3dRotation: string; export declare const sharp3gMobiledata: string; export declare const sharp3k: string; export declare const sharp3kPlus: string; export declare const sharp3mp: string; export declare const sharp3p: string; export declare const sharp4gMobiledata: string; export declare const sharp4gPlusMobiledata: string; export declare const sharp4k: string; export declare const sharp4kPlus: string; export declare const sharp4mp: string; export declare const sharp5g: string; export declare const sharp5k: string; export declare const sharp5kPlus: string; export declare const sharp5mp: string; export declare const sharp60fps: string; export declare const sharp60fpsSelect: string; export declare const sharp6FtApart: string; export declare const sharp6k: string; export declare const sharp6kPlus: string; export declare const sharp6mp: string; export declare const sharp7k: string; export declare const sharp7kPlus: string; export declare const sharp7mp: string; export declare const sharp8k: string; export declare const sharp8kPlus: string; export declare const sharp8mp: string; export declare const sharp9k: string; export declare const sharp9kPlus: string; export declare const sharp9mp: string; export declare const sharpAccessAlarm: string; export declare const sharpAccessAlarms: string; export declare const sharpAccessibility: string; export declare const sharpAccessibilityNew: string; export declare const sharpAccessible: string; export declare const sharpAccessibleForward: string; export declare const sharpAccessTime: string; export declare const sharpAccessTimeFilled: string; export declare const sharpAccountBalance: string; export declare const sharpAccountBalanceWallet: string; export declare const sharpAccountBox: string; export declare const sharpAccountCircle: string; export declare const sharpAccountTree: string; export declare const sharpAcUnit: string; export declare const sharpAdb: string; export declare const sharpAdd: string; export declare const sharpAddAlarm: string; export declare const sharpAddAlert: string; export declare const sharpAddAPhoto: string; export declare const sharpAddBox: string; export declare const sharpAddBusiness: string; export declare const sharpAddchart: string; export declare const sharpAddChart: string; export declare const sharpAddCircle: string; export declare const sharpAddCircleOutline: string; export declare const sharpAddComment: string; export declare const sharpAddIcCall: string; export declare const sharpAddLink: string; export declare const sharpAddLocation: string; export declare const sharpAddLocationAlt: string; export declare const sharpAddModerator: string; export declare const sharpAddPhotoAlternate: string; export declare const sharpAddReaction: string; export declare const sharpAddRoad: string; export declare const sharpAddShoppingCart: string; export declare const sharpAddTask: string; export declare const sharpAddToDrive: string; export declare const sharpAddToHomeScreen: string; export declare const sharpAddToPhotos: string; export declare const sharpAddToQueue: string; export declare const sharpAdfScanner: string; export declare const sharpAdjust: string; export declare const sharpAdminPanelSettings: string; export declare const sharpAdsClick: string; export declare const sharpAdUnits: string; export declare const sharpAgriculture: string; export declare const sharpAir: string; export declare const sharpAirlines: string; export declare const sharpAirlineSeatFlat: string; export declare const sharpAirlineSeatFlatAngled: string; export declare const sharpAirlineSeatIndividualSuite: string; export declare const sharpAirlineSeatLegroomExtra: string; export declare const sharpAirlineSeatLegroomNormal: string; export declare const sharpAirlineSeatLegroomReduced: string; export declare const sharpAirlineSeatReclineExtra: string; export declare const sharpAirlineSeatReclineNormal: string; export declare const sharpAirlineStops: string; export declare const sharpAirplanemodeActive: string; export declare const sharpAirplanemodeInactive: string; export declare const sharpAirplaneTicket: string; export declare const sharpAirplay: string; export declare const sharpAirportShuttle: string; export declare const sharpAlarm: string; export declare const sharpAlarmAdd: string; export declare const sharpAlarmOff: string; export declare const sharpAlarmOn: string; export declare const sharpAlbum: string; export declare const sharpAlignHorizontalCenter: string; export declare const sharpAlignHorizontalLeft: string; export declare const sharpAlignHorizontalRight: string; export declare const sharpAlignVerticalBottom: string; export declare const sharpAlignVerticalCenter: string; export declare const sharpAlignVerticalTop: string; export declare const sharpAllInbox: string; export declare const sharpAllInclusive: string; export declare const sharpAllOut: string; export declare const sharpAlternateEmail: string; export declare const sharpAltRoute: string; export declare const sharpAnalytics: string; export declare const sharpAnchor: string; export declare const sharpAndroid: string; export declare const sharpAnimation: string; export declare const sharpAnnouncement: string; export declare const sharpAod: string; export declare const sharpApartment: string; export declare const sharpApi: string; export declare const sharpAppBlocking: string; export declare const sharpAppRegistration: string; export declare const sharpApproval: string; export declare const sharpApps: string; export declare const sharpAppSettingsAlt: string; export declare const sharpAppShortcut: string; export declare const sharpAppsOutage: string; export declare const sharpArchitecture: string; export declare const sharpArchive: string; export declare const sharpAreaChart: string; export declare const sharpArrowBack: string; export declare const sharpArrowBackIos: string; export declare const sharpArrowBackIosNew: string; export declare const sharpArrowCircleDown: string; export declare const sharpArrowCircleUp: string; export declare const sharpArrowDownward: string; export declare const sharpArrowDropDown: string; export declare const sharpArrowDropDownCircle: string; export declare const sharpArrowDropUp: string; export declare const sharpArrowForward: string; export declare const sharpArrowForwardIos: string; export declare const sharpArrowLeft: string; export declare const sharpArrowRight: string; export declare const sharpArrowRightAlt: string; export declare const sharpArrowUpward: string; export declare const sharpArticle: string; export declare const sharpArtTrack: string; export declare const sharpAspectRatio: string; export declare const sharpAssessment: string; export declare const sharpAssignment: string; export declare const sharpAssignmentInd: string; export declare const sharpAssignmentLate: string; export declare const sharpAssignmentReturn: string; export declare const sharpAssignmentReturned: string; export declare const sharpAssignmentTurnedIn: string; export declare const sharpAssistant: string; export declare const sharpAssistantDirection: string; export declare const sharpAssistantPhoto: string; export declare const sharpAtm: string; export declare const sharpAttachEmail: string; export declare const sharpAttachFile: string; export declare const sharpAttachment: string; export declare const sharpAttachMoney: string; export declare const sharpAttractions: string; export declare const sharpAttribution: string; export declare const sharpAudiotrack: string; export declare const sharpAutoAwesome: string; export declare const sharpAutoAwesomeMosaic: string; export declare const sharpAutoAwesomeMotion: string; export declare const sharpAutoDelete: string; export declare const sharpAutoFixHigh: string; export declare const sharpAutoFixNormal: string; export declare const sharpAutoFixOff: string; export declare const sharpAutofpsSelect: string; export declare const sharpAutoGraph: string; export declare const sharpAutorenew: string; export declare const sharpAutoStories: string; export declare const sharpAvTimer: string; export declare const sharpBabyChangingStation: string; export declare const sharpBackHand: string; export declare const sharpBackpack: string; export declare const sharpBackspace: string; export declare const sharpBackup: string; export declare const sharpBackupTable: string; export declare const sharpBadge: string; export declare const sharpBakeryDining: string; export declare const sharpBalance: string; export declare const sharpBalcony: string; export declare const sharpBallot: string; export declare const sharpBarChart: string; export declare const sharpBatchPrediction: string; export declare const sharpBathroom: string; export declare const sharpBathtub: string; export declare const sharpBatteryAlert: string; export declare const sharpBatteryChargingFull: string; export declare const sharpBatteryFull: string; export declare const sharpBatterySaver: string; export declare const sharpBatteryStd: string; export declare const sharpBatteryUnknown: string; export declare const sharpBeachAccess: string; export declare const sharpBed: string; export declare const sharpBedroomBaby: string; export declare const sharpBedroomChild: string; export declare const sharpBedroomParent: string; export declare const sharpBedtime: string; export declare const sharpBeenhere: string; export declare const sharpBento: string; export declare const sharpBikeScooter: string; export declare const sharpBiotech: string; export declare const sharpBlender: string; export declare const sharpBlock: string; export declare const sharpBloodtype: string; export declare const sharpBluetooth: string; export declare const sharpBluetoothAudio: string; export declare const sharpBluetoothConnected: string; export declare const sharpBluetoothDisabled: string; export declare const sharpBluetoothDrive: string; export declare const sharpBluetoothSearching: string; export declare const sharpBlurCircular: string; export declare const sharpBlurLinear: string; export declare const sharpBlurOff: string; export declare const sharpBlurOn: string; export declare const sharpBolt: string; export declare const sharpBook: string; export declare const sharpBookmark: string; export declare const sharpBookmarkAdd: string; export declare const sharpBookmarkAdded: string; export declare const sharpBookmarkBorder: string; export declare const sharpBookmarkRemove: string; export declare const sharpBookmarks: string; export declare const sharpBookOnline: string; export declare const sharpBorderAll: string; export declare const sharpBorderBottom: string; export declare const sharpBorderClear: string; export declare const sharpBorderColor: string; export declare const sharpBorderHorizontal: string; export declare const sharpBorderInner: string; export declare const sharpBorderLeft: string; export declare const sharpBorderOuter: string; export declare const sharpBorderRight: string; export declare const sharpBorderStyle: string; export declare const sharpBorderTop: string; export declare const sharpBorderVertical: string; export declare const sharpBrandingWatermark: string; export declare const sharpBreakfastDining: string; export declare const sharpBrightness1: string; export declare const sharpBrightness2: string; export declare const sharpBrightness3: string; export declare const sharpBrightness4: string; export declare const sharpBrightness5: string; export declare const sharpBrightness6: string; export declare const sharpBrightness7: string; export declare const sharpBrightnessAuto: string; export declare const sharpBrightnessHigh: string; export declare const sharpBrightnessLow: string; export declare const sharpBrightnessMedium: string; export declare const sharpBrokenImage: string; export declare const sharpBrowserNotSupported: string; export declare const sharpBrowserUpdated: string; export declare const sharpBrunchDining: string; export declare const sharpBrush: string; export declare const sharpBubbleChart: string; export declare const sharpBugReport: string; export declare const sharpBuild: string; export declare const sharpBuildCircle: string; export declare const sharpBungalow: string; export declare const sharpBurstMode: string; export declare const sharpBusAlert: string; export declare const sharpBusiness: string; export declare const sharpBusinessCenter: string; export declare const sharpCabin: string; export declare const sharpCable: string; export declare const sharpCached: string; export declare const sharpCake: string; export declare const sharpCalculate: string; export declare const sharpCalendarToday: string; export declare const sharpCalendarViewDay: string; export declare const sharpCalendarViewMonth: string; export declare const sharpCalendarViewWeek: string; export declare const sharpCall: string; export declare const sharpCallEnd: string; export declare const sharpCallMade: string; export declare const sharpCallMerge: string; export declare const sharpCallMissed: string; export declare const sharpCallMissedOutgoing: string; export declare const sharpCallReceived: string; export declare const sharpCallSplit: string; export declare const sharpCallToAction: string; export declare const sharpCamera: string; export declare const sharpCameraAlt: string; export declare const sharpCameraEnhance: string; export declare const sharpCameraFront: string; export declare const sharpCameraIndoor: string; export declare const sharpCameraOutdoor: string; export declare const sharpCameraRear: string; export declare const sharpCameraRoll: string; export declare const sharpCameraswitch: string; export declare const sharpCampaign: string; export declare const sharpCancel: string; export declare const sharpCancelPresentation: string; export declare const sharpCancelScheduleSend: string; export declare const sharpCandlestickChart: string; export declare const sharpCardGiftcard: string; export declare const sharpCardMembership: string; export declare const sharpCardTravel: string; export declare const sharpCarpenter: string; export declare const sharpCarRental: string; export declare const sharpCarRepair: string; export declare const sharpCases: string; export declare const sharpCasino: string; export declare const sharpCast: string; export declare const sharpCastConnected: string; export declare const sharpCastForEducation: string; export declare const sharpCatchingPokemon: string; export declare const sharpCategory: string; export declare const sharpCelebration: string; export declare const sharpCellWifi: string; export declare const sharpCenterFocusStrong: string; export declare const sharpCenterFocusWeak: string; export declare const sharpChair: string; export declare const sharpChairAlt: string; export declare const sharpChalet: string; export declare const sharpChangeCircle: string; export declare const sharpChangeHistory: string; export declare const sharpChargingStation: string; export declare const sharpChat: string; export declare const sharpChatBubble: string; export declare const sharpChatBubbleOutline: string; export declare const sharpCheck: string; export declare const sharpCheckBox: string; export declare const sharpCheckBoxOutlineBlank: string; export declare const sharpCheckCircle: string; export declare const sharpCheckCircleOutline: string; export declare const sharpChecklist: string; export declare const sharpChecklistRtl: string; export declare const sharpCheckroom: string; export declare const sharpChevronLeft: string; export declare const sharpChevronRight: string; export declare const sharpChildCare: string; export declare const sharpChildFriendly: string; export declare const sharpChromeReaderMode: string; export declare const sharpCircle: string; export declare const sharpCircleNotifications: string; export declare const sharpClass: string; export declare const sharpCleanHands: string; export declare const sharpCleaningServices: string; export declare const sharpClear: string; export declare const sharpClearAll: string; export declare const sharpClose: string; export declare const sharpClosedCaption: string; export declare const sharpClosedCaptionDisabled: string; export declare const sharpClosedCaptionOff: string; export declare const sharpCloseFullscreen: string; export declare const sharpCloud: string; export declare const sharpCloudCircle: string; export declare const sharpCloudDone: string; export declare const sharpCloudDownload: string; export declare const sharpCloudOff: string; export declare const sharpCloudQueue: string; export declare const sharpCloudSync: string; export declare const sharpCloudUpload: string; export declare const sharpCo2: string; export declare const sharpCode: string; export declare const sharpCodeOff: string; export declare const sharpCoffee: string; export declare const sharpCoffeeMaker: string; export declare const sharpCollections: string; export declare const sharpCollectionsBookmark: string; export declare const sharpColorize: string; export declare const sharpColorLens: string; export declare const sharpComment: string; export declare const sharpCommentBank: string; export declare const sharpCommentsDisabled: string; export declare const sharpCommit: string; export declare const sharpCommute: string; export declare const sharpCompare: string; export declare const sharpCompareArrows: string; export declare const sharpCompassCalibration: string; export declare const sharpCompost: string; export declare const sharpCompress: string; export declare const sharpComputer: string; export declare const sharpConfirmationNumber: string; export declare const sharpConnectedTv: string; export declare const sharpConnectingAirports: string; export declare const sharpConnectWithoutContact: string; export declare const sharpConstruction: string; export declare const sharpContactless: string; export declare const sharpContactMail: string; export declare const sharpContactPage: string; export declare const sharpContactPhone: string; export declare const sharpContacts: string; export declare const sharpContactSupport: string; export declare const sharpContentCopy: string; export declare const sharpContentCut: string; export declare const sharpContentPaste: string; export declare const sharpContentPasteOff: string; export declare const sharpContentPasteSearch: string; export declare const sharpContrast: string; export declare const sharpControlCamera: string; export declare const sharpControlPoint: string; export declare const sharpControlPointDuplicate: string; export declare const sharpCookie: string; export declare const sharpCoPresent: string; export declare const sharpCopyAll: string; export declare const sharpCopyright: string; export declare const sharpCoronavirus: string; export declare const sharpCorporateFare: string; export declare const sharpCottage: string; export declare const sharpCountertops: string; export declare const sharpCreate: string; export declare const sharpCreateNewFolder: string; export declare const sharpCreditCard: string; export declare const sharpCreditCardOff: string; export declare const sharpCreditScore: string; export declare const sharpCrib: string; export declare const sharpCrop: string; export declare const sharpCrop169: string; export declare const sharpCrop32: string; export declare const sharpCrop54: string; export declare const sharpCrop75: string; export declare const sharpCropDin: string; export declare const sharpCropFree: string; export declare const sharpCropLandscape: string; export declare const sharpCropOriginal: string; export declare const sharpCropPortrait: string; export declare const sharpCropRotate: string; export declare const sharpCropSquare: string; export declare const sharpCrueltyFree: string; export declare const sharpCurrencyFranc: string; export declare const sharpCurrencyLira: string; export declare const sharpCurrencyPound: string; export declare const sharpCurrencyRuble: string; export declare const sharpCurrencyRupee: string; export declare const sharpCurrencyYen: string; export declare const sharpCurrencyYuan: string; export declare const sharpDangerous: string; export declare const sharpDarkMode: string; export declare const sharpDashboard: string; export declare const sharpDashboardCustomize: string; export declare const sharpDataArray: string; export declare const sharpDataExploration: string; export declare const sharpDataObject: string; export declare const sharpDataSaverOff: string; export declare const sharpDataSaverOn: string; export declare const sharpDataUsage: string; export declare const sharpDateRange: string; export declare const sharpDeck: string; export declare const sharpDehaze: string; export declare const sharpDelete: string; export declare const sharpDeleteForever: string; export declare const sharpDeleteOutline: string; export declare const sharpDeleteSweep: string; export declare const sharpDeliveryDining: string; export declare const sharpDepartureBoard: string; export declare const sharpDescription: string; export declare const sharpDesignServices: string; export declare const sharpDesktopAccessDisabled: string; export declare const sharpDesktopMac: string; export declare const sharpDesktopWindows: string; export declare const sharpDetails: string; export declare const sharpDeveloperBoard: string; export declare const sharpDeveloperBoardOff: string; export declare const sharpDeveloperMode: string; export declare const sharpDeviceHub: string; export declare const sharpDevices: string; export declare const sharpDevicesOther: string; export declare const sharpDeviceThermostat: string; export declare const sharpDeviceUnknown: string; export declare const sharpDialerSip: string; export declare const sharpDialpad: string; export declare const sharpDiamond: string; export declare const sharpDining: string; export declare const sharpDinnerDining: string; export declare const sharpDirections: string; export declare const sharpDirectionsBike: string; export declare const sharpDirectionsBoat: string; export declare const sharpDirectionsBoatFilled: string; export declare const sharpDirectionsBus: string; export declare const sharpDirectionsBusFilled: string; export declare const sharpDirectionsCar: string; export declare const sharpDirectionsCarFilled: string; export declare const sharpDirectionsOff: string; export declare const sharpDirectionsRailway: string; export declare const sharpDirectionsRailwayFilled: string; export declare const sharpDirectionsRun: string; export declare const sharpDirectionsSubway: string; export declare const sharpDirectionsSubwayFilled: string; export declare const sharpDirectionsTransit: string; export declare const sharpDirectionsTransitFilled: string; export declare const sharpDirectionsWalk: string; export declare const sharpDirtyLens: string; export declare const sharpDisabledByDefault: string; export declare const sharpDisabledVisible: string; export declare const sharpDiscFull: string; export declare const sharpDns: string; export declare const sharpDock: string; export declare const sharpDocumentScanner: string; export declare const sharpDoDisturb: string; export declare const sharpDoDisturbAlt: string; export declare const sharpDoDisturbOff: string; export declare const sharpDoDisturbOn: string; export declare const sharpDomain: string; export declare const sharpDomainDisabled: string; export declare const sharpDomainVerification: string; export declare const sharpDone: string; export declare const sharpDoneAll: string; export declare const sharpDoneOutline: string; export declare const sharpDoNotDisturb: string; export declare const sharpDoNotDisturbAlt: string; export declare const sharpDoNotDisturbOff: string; export declare const sharpDoNotDisturbOn: string; export declare const sharpDoNotDisturbOnTotalSilence: string; export declare const sharpDoNotStep: string; export declare const sharpDoNotTouch: string; export declare const sharpDonutLarge: string; export declare const sharpDonutSmall: string; export declare const sharpDoorBack: string; export declare const sharpDoorbell: string; export declare const sharpDoorFront: string; export declare const sharpDoorSliding: string; export declare const sharpDoubleArrow: string; export declare const sharpDownhillSkiing: string; export declare const sharpDownload: string; export declare const sharpDownloadDone: string; export declare const sharpDownloadForOffline: string; export declare const sharpDownloading: string; export declare const sharpDrafts: string; export declare const sharpDragHandle: string; export declare const sharpDragIndicator: string; export declare const sharpDraw: string; export declare const sharpDriveEta: string; export declare const sharpDriveFileMove: string; export declare const sharpDriveFileMoveRtl: string; export declare const sharpDriveFileRenameOutline: string; export declare const sharpDriveFolderUpload: string; export declare const sharpDry: string; export declare const sharpDryCleaning: string; export declare const sharpDuo: string; export declare const sharpDvr: string; export declare const sharpDynamicFeed: string; export declare const sharpDynamicForm: string; export declare const sharpEarbuds: string; export declare const sharpEarbudsBattery: string; export declare const sharpEast: string; export declare const sharpEdgesensorHigh: string; export declare const sharpEdgesensorLow: string; export declare const sharpEdit: string; export declare const sharpEditAttributes: string; export declare const sharpEditCalendar: string; export declare const sharpEditLocation: string; export declare const sharpEditLocationAlt: string; export declare const sharpEditNote: string; export declare const sharpEditNotifications: string; export declare const sharpEditOff: string; export declare const sharpEditRoad: string; export declare const sharpEgg: string; export declare const sharpEggAlt: string; export declare const sharpEject: string; export declare const sharpElderly: string; export declare const sharpElectricalServices: string; export declare const sharpElectricBike: string; export declare const sharpElectricCar: string; export declare const sharpElectricMoped: string; export declare const sharpElectricRickshaw: string; export declare const sharpElectricScooter: string; export declare const sharpElevator: string; export declare const sharpEmail: string; export declare const sharpEmergency: string; export declare const sharpEMobiledata: string; export declare const sharpEmojiEmotions: string; export declare const sharpEmojiEvents: string; export declare const sharpEmojiFoodBeverage: string; export declare const sharpEmojiNature: string; export declare const sharpEmojiObjects: string; export declare const sharpEmojiPeople: string; export declare const sharpEmojiSymbols: string; export declare const sharpEmojiTransportation: string; export declare const sharpEngineering: string; export declare const sharpEnhancedEncryption: string; export declare const sharpEqualizer: string; export declare const sharpError: string; export declare const sharpErrorOutline: string; export declare const sharpEscalator: string; export declare const sharpEscalatorWarning: string; export declare const sharpEuro: string; export declare const sharpEuroSymbol: string; export declare const sharpEvent: string; export declare const sharpEventAvailable: string; export declare const sharpEventBusy: string; export declare const sharpEventNote: string; export declare const sharpEventSeat: string; export declare const sharpEvStation: string; export declare const sharpExitToApp: string; export declare const sharpExpand: string; export declare const sharpExpandCircleDown: string; export declare const sharpExpandLess: string; export declare const sharpExpandMore: string; export declare const sharpExplicit: string; export declare const sharpExplore: string; export declare const sharpExploreOff: string; export declare const sharpExposure: string; export declare const sharpExposureNeg1: string; export declare const sharpExposureNeg2: string; export declare const sharpExposurePlus1: string; export declare const sharpExposurePlus2: string; export declare const sharpExposureZero: string; export declare const sharpExtension: string; export declare const sharpExtensionOff: string; export declare const sharpFace: string; export declare const sharpFaceRetouchingNatural: string; export declare const sharpFaceRetouchingOff: string; export declare const sharpFactCheck: string; export declare const sharpFamilyRestroom: string; export declare const sharpFastfood: string; export declare const sharpFastForward: string; export declare const sharpFastRewind: string; export declare const sharpFavorite: string; export declare const sharpFavoriteBorder: string; export declare const sharpFax: string; export declare const sharpFeaturedPlayList: string; export declare const sharpFeaturedVideo: string; export declare const sharpFeed: string; export declare const sharpFeedback: string; export declare const sharpFemale: string; export declare const sharpFence: string; export declare const sharpFestival: string; export declare const sharpFiberDvr: string; export declare const sharpFiberManualRecord: string; export declare const sharpFiberNew: string; export declare const sharpFiberPin: string; export declare const sharpFiberSmartRecord: string; export declare const sharpFileCopy: string; export declare const sharpFileDownload: string; export declare const sharpFileDownloadDone: string; export declare const sharpFileDownloadOff: string; export declare const sharpFileOpen: string; export declare const sharpFilePresent: string; export declare const sharpFileUpload: string; export declare const sharpFilter: string; export declare const sharpFilter1: string; export declare const sharpFilter2: string; export declare const sharpFilter3: string; export declare const sharpFilter4: string; export declare const sharpFilter5: string; export declare const sharpFilter6: string; export declare const sharpFilter7: string; export declare const sharpFilter8: string; export declare const sharpFilter9: string; export declare const sharpFilter9Plus: string; export declare const sharpFilterAlt: string; export declare const sharpFilterAltOff: string; export declare const sharpFilterBAndW: string; export declare const sharpFilterCenterFocus: string; export declare const sharpFilterDrama: string; export declare const sharpFilterFrames: string; export declare const sharpFilterHdr: string; export declare const sharpFilterList: string; export declare const sharpFilterListOff: string; export declare const sharpFilterNone: string; export declare const sharpFilterTiltShift: string; export declare const sharpFilterVintage: string; export declare const sharpFindInPage: string; export declare const sharpFindReplace: string; export declare const sharpFingerprint: string; export declare const sharpFireExtinguisher: string; export declare const sharpFireplace: string; export declare const sharpFirstPage: string; export declare const sharpFitbit: string; export declare const sharpFitnessCenter: string; export declare const sharpFitScreen: string; export declare const sharpFlag: string; export declare const sharpFlagCircle: string; export declare const sharpFlaky: string; export declare const sharpFlare: string; export declare const sharpFlashAuto: string; export declare const sharpFlashlightOff: string; export declare const sharpFlashlightOn: string; export declare const sharpFlashOff: string; export declare const sharpFlashOn: string; export declare const sharpFlatware: string; export declare const sharpFlight: string; export declare const sharpFlightClass: string; export declare const sharpFlightLand: string; export declare const sharpFlightTakeoff: string; export declare const sharpFlip: string; export declare const sharpFlipCameraAndroid: string; export declare const sharpFlipCameraIos: string; export declare const sharpFlipToBack: string; export declare const sharpFlipToFront: string; export declare const sharpFlourescent: string; export declare const sharpFlutterDash: string; export declare const sharpFmdBad: string; export declare const sharpFmdGood: string; export declare const sharpFolder: string; export declare const sharpFolderDelete: string; export declare const sharpFolderOpen: string; export declare const sharpFolderShared: string; export declare const sharpFolderSpecial: string; export declare const sharpFolderZip: string; export declare const sharpFollowTheSigns: string; export declare const sharpFontDownload: string; export declare const sharpFontDownloadOff: string; export declare const sharpFoodBank: string; export declare const sharpFormatAlignCenter: string; export declare const sharpFormatAlignJustify: string; export declare const sharpFormatAlignLeft: string; export declare const sharpFormatAlignRight: string; export declare const sharpFormatBold: string; export declare const sharpFormatClear: string; export declare const sharpFormatColorFill: string; export declare const sharpFormatColorReset: string; export declare const sharpFormatColorText: string; export declare const sharpFormatIndentDecrease: string; export declare const sharpFormatIndentIncrease: string; export declare const sharpFormatItalic: string; export declare const sharpFormatLineSpacing: string; export declare const sharpFormatListBulleted: string; export declare const sharpFormatListNumbered: string; export declare const sharpFormatListNumberedRtl: string; export declare const sharpFormatPaint: string; export declare const sharpFormatQuote: string; export declare const sharpFormatShapes: string; export declare const sharpFormatSize: string; export declare const sharpFormatStrikethrough: string; export declare const sharpFormatTextdirectionLToR: string; export declare const sharpFormatTextdirectionRToL: string; export declare const sharpFormatUnderlined: string; export declare const sharpForum: string; export declare const sharpForward: string; export declare const sharpForward10: string; export declare const sharpForward30: string; export declare const sharpForward5: string; export declare const sharpForwardToInbox: string; export declare const sharpFoundation: string; export declare const sharpFreeBreakfast: string; export declare const sharpFreeCancellation: string; export declare const sharpFrontHand: string; export declare const sharpFullscreen: string; export declare const sharpFullscreenExit: string; export declare const sharpFunctions: string; export declare const sharpGamepad: string; export declare const sharpGames: string; export declare const sharpGarage: string; export declare const sharpGavel: string; export declare const sharpGeneratingTokens: string; export declare const sharpGesture: string; export declare const sharpGetApp: string; export declare const sharpGif: string; export declare const sharpGifBox: string; export declare const sharpGite: string; export declare const sharpGMobiledata: string; export declare const sharpGolfCourse: string; export declare const sharpGppBad: string; export declare const sharpGppGood: string; export declare const sharpGppMaybe: string; export declare const sharpGpsFixed: string; export declare const sharpGpsNotFixed: string; export declare const sharpGpsOff: string; export declare const sharpGrade: string; export declare const sharpGradient: string; export declare const sharpGrading: string; export declare const sharpGrain: string; export declare const sharpGraphicEq: string; export declare const sharpGrass: string; export declare const sharpGrid3x3: string; export declare const sharpGrid4x4: string; export declare const sharpGridGoldenratio: string; export declare const sharpGridOff: string; export declare const sharpGridOn: string; export declare const sharpGridView: string; export declare const sharpGroup: string; export declare const sharpGroupAdd: string; export declare const sharpGroupOff: string; export declare const sharpGroupRemove: string; export declare const sharpGroups: string; export declare const sharpGroupWork: string; export declare const sharpGTranslate: string; export declare const sharpHail: string; export declare const sharpHandyman: string; export declare const sharpHardware: string; export declare const sharpHd: string; export declare const sharpHdrAuto: string; export declare const sharpHdrAutoSelect: string; export declare const sharpHdrEnhancedSelect: string; export declare const sharpHdrOff: string; export declare const sharpHdrOffSelect: string; export declare const sharpHdrOn: string; export declare const sharpHdrOnSelect: string; export declare const sharpHdrPlus: string; export declare const sharpHdrStrong: string; export declare const sharpHdrWeak: string; export declare const sharpHeadphones: string; export declare const sharpHeadphonesBattery: string; export declare const sharpHeadset: string; export declare const sharpHeadsetMic: string; export declare const sharpHeadsetOff: string; export declare const sharpHealing: string; export declare const sharpHealthAndSafety: string; export declare const sharpHearing: string; export declare const sharpHearingDisabled: string; export declare const sharpHeartBroken: string; export declare const sharpHeight: string; export declare const sharpHelp: string; export declare const sharpHelpCenter: string; export declare const sharpHelpOutline: string; export declare const sharpHevc: string; export declare const sharpHexagon: string; export declare const sharpHideImage: string; export declare const sharpHideSource: string; export declare const sharpHighlight: string; export declare const sharpHighlightAlt: string; export declare const sharpHighlightOff: string; export declare const sharpHighQuality: string; export declare const sharpHiking: string; export declare const sharpHistory: string; export declare const sharpHistoryEdu: string; export declare const sharpHistoryToggleOff: string; export declare const sharpHMobiledata: string; export declare const sharpHolidayVillage: string; export declare const sharpHome: string; export declare const sharpHomeMax: string; export declare const sharpHomeMini: string; export declare const sharpHomeRepairService: string; export declare const sharpHomeWork: string; export declare const sharpHorizontalDistribute: string; export declare const sharpHorizontalRule: string; export declare const sharpHorizontalSplit: string; export declare const sharpHotel: string; export declare const sharpHotelClass: string; export declare const sharpHotTub: string; export declare const sharpHourglassBottom: string; export declare const sharpHourglassDisabled: string; export declare const sharpHourglassEmpty: string; export declare const sharpHourglassFull: string; export declare const sharpHourglassTop: string; export declare const sharpHouse: string; export declare const sharpHouseboat: string; export declare const sharpHouseSiding: string; export declare const sharpHowToReg: string; export declare const sharpHowToVote: string; export declare const sharpHPlusMobiledata: string; export declare const sharpHttp: string; export declare const sharpHttps: string; export declare const sharpHub: string; export declare const sharpHvac: string; export declare const sharpIcecream: string; export declare const sharpIceSkating: string; export declare const sharpImage: string; export declare const sharpImageAspectRatio: string; export declare const sharpImageNotSupported: string; export declare const sharpImageSearch: string; export declare const sharpImagesearchRoller: string; export declare const sharpImportantDevices: string; export declare const sharpImportContacts: string; export declare const sharpImportExport: string; export declare const sharpInbox: string; export declare const sharpIncompleteCircle: string; export declare const sharpIndeterminateCheckBox: string; export declare const sharpInfo: string; export declare const sharpInput: string; export declare const sharpInsertChart: string; export declare const sharpInsertChartOutlined: string; export declare const sharpInsertComment: string; export declare const sharpInsertDriveFile: string; export declare const sharpInsertEmoticon: string; export declare const sharpInsertInvitation: string; export declare const sharpInsertLink: string; export declare const sharpInsertPageBreak: string; export declare const sharpInsertPhoto: string; export declare const sharpInsights: string; export declare const sharpIntegrationInstructions: string; export declare const sharpInterests: string; export declare const sharpInventory: string; export declare const sharpInventory2: string; export declare const sharpInvertColors: string; export declare const sharpInvertColorsOff: string; export declare const sharpIosShare: string; export declare const sharpIron: string; export declare const sharpIso: string; export declare const sharpJoinFull: string; export declare const sharpJoinInner: string; export declare const sharpJoinLeft: string; export declare const sharpJoinRight: string; export declare const sharpKayaking: string; export declare const sharpKebabDining: string; export declare const sharpKey: string; export declare const sharpKeyboard: string; export declare const sharpKeyboardAlt: string; export declare const sharpKeyboardArrowDown: string; export declare const sharpKeyboardArrowLeft: string; export declare const sharpKeyboardArrowRight: string; export declare const sharpKeyboardArrowUp: string; export declare const sharpKeyboardBackspace: string; export declare const sharpKeyboardCapslock: string; export declare const sharpKeyboardCommandKey: string; export declare const sharpKeyboardControlKey: string; export declare const sharpKeyboardDoubleArrowDown: string; export declare const sharpKeyboardDoubleArrowLeft: string; export declare const sharpKeyboardDoubleArrowRight: string; export declare const sharpKeyboardDoubleArrowUp: string; export declare const sharpKeyboardHide: string; export declare const sharpKeyboardOptionKey: string; export declare const sharpKeyboardReturn: string; export declare const sharpKeyboardTab: string; export declare const sharpKeyboardVoice: string; export declare const sharpKingBed: string; export declare const sharpKitchen: string; export declare const sharpKitesurfing: string; export declare const sharpLabel: string; export declare const sharpLabelImportant: string; export declare const sharpLabelOff: string; export declare const sharpLan: string; export declare const sharpLandscape: string; export declare const sharpLanguage: string; export declare const sharpLaptop: string; export declare const sharpLaptopChromebook: string; export declare const sharpLaptopMac: string; export declare const sharpLaptopWindows: string; export declare const sharpLastPage: string; export declare const sharpLaunch: string; export declare const sharpLayers: string; export declare const sharpLayersClear: string; export declare const sharpLeaderboard: string; export declare const sharpLeakAdd: string; export declare const sharpLeakRemove: string; export declare const sharpLegendToggle: string; export declare const sharpLens: string; export declare const sharpLensBlur: string; export declare const sharpLibraryAdd: string; export declare const sharpLibraryAddCheck: string; export declare const sharpLibraryBooks: string; export declare const sharpLibraryMusic: string; export declare const sharpLight: string; export declare const sharpLightbulb: string; export declare const sharpLightMode: string; export declare const sharpLinearScale: string; export declare const sharpLineStyle: string; export declare const sharpLineWeight: string; export declare const sharpLink: string; export declare const sharpLinkedCamera: string; export declare const sharpLinkOff: string; export declare const sharpLiquor: string; export declare const sharpList: string; export declare const sharpListAlt: string; export declare const sharpLiveHelp: string; export declare const sharpLiveTv: string; export declare const sharpLiving: string; export declare const sharpLocalActivity: string; export declare const sharpLocalAirport: string; export declare const sharpLocalAtm: string; export declare const sharpLocalBar: string; export declare const sharpLocalCafe: string; export declare const sharpLocalCarWash: string; export declare const sharpLocalConvenienceStore: string; export declare const sharpLocalDining: string; export declare const sharpLocalDrink: string; export declare const sharpLocalFireDepartment: string; export declare const sharpLocalFlorist: string; export declare const sharpLocalGasStation: string; export declare const sharpLocalGroceryStore: string; export declare const sharpLocalHospital: string; export declare const sharpLocalHotel: string; export declare const sharpLocalLaundryService: string; export declare const sharpLocalLibrary: string; export declare const sharpLocalMall: string; export declare const sharpLocalMovies: string; export declare const sharpLocalOffer: string; export declare const sharpLocalParking: string; export declare const sharpLocalPharmacy: string; export declare const sharpLocalPhone: string; export declare const sharpLocalPizza: string; export declare const sharpLocalPlay: string; export declare const sharpLocalPolice: string; export declare const sharpLocalPostOffice: string; export declare const sharpLocalPrintshop: string; export declare const sharpLocalSee: string; export declare const sharpLocalShipping: string; export declare const sharpLocalTaxi: string; export declare const sharpLocationCity: string; export declare const sharpLocationDisabled: string; export declare const sharpLocationOff: string; export declare const sharpLocationOn: string; export declare const sharpLocationSearching: string; export declare const sharpLock: string; export declare const sharpLockClock: string; export declare const sharpLockOpen: string; export declare const sharpLockReset: string; export declare const sharpLogin: string; export declare const sharpLogoDev: string; export declare const sharpLogout: string; export declare const sharpLooks: string; export declare const sharpLooks3: string; export declare const sharpLooks4: string; export declare const sharpLooks5: string; export declare const sharpLooks6: string; export declare const sharpLooksOne: string; export declare const sharpLooksTwo: string; export declare const sharpLoop: string; export declare const sharpLoupe: string; export declare const sharpLowPriority: string; export declare const sharpLoyalty: string; export declare const sharpLteMobiledata: string; export declare const sharpLtePlusMobiledata: string; export declare const sharpLuggage: string; export declare const sharpLunchDining: string; export declare const sharpMail: string; export declare const sharpMailOutline: string; export declare const sharpMale: string; export declare const sharpMan: string; export declare const sharpManageAccounts: string; export declare const sharpManageSearch: string; export declare const sharpMap: string; export declare const sharpMapsHomeWork: string; export declare const sharpMapsUgc: string; export declare const sharpMargin: string; export declare const sharpMarkAsUnread: string; export declare const sharpMarkChatRead: string; export declare const sharpMarkChatUnread: string; export declare const sharpMarkEmailRead: string; export declare const sharpMarkEmailUnread: string; export declare const sharpMarkunread: string; export declare const sharpMarkunreadMailbox: string; export declare const sharpMasks: string; export declare const sharpMaximize: string; export declare const sharpMediaBluetoothOff: string; export declare const sharpMediaBluetoothOn: string; export declare const sharpMediation: string; export declare const sharpMedicalServices: string; export declare const sharpMedication: string; export declare const sharpMeetingRoom: string; export declare const sharpMemory: string; export declare const sharpMenu: string; export declare const sharpMenuBook: string; export declare const sharpMenuOpen: string; export declare const sharpMergeType: string; export declare const sharpMessage: string; export declare const sharpMic: string; export declare const sharpMicExternalOff: string; export declare const sharpMicExternalOn: string; export declare const sharpMicNone: string; export declare const sharpMicOff: string; export declare const sharpMicrowave: string; export declare const sharpMilitaryTech: string; export declare const sharpMinimize: string; export declare const sharpMiscellaneousServices: string; export declare const sharpMissedVideoCall: string; export declare const sharpMms: string; export declare const sharpMobiledataOff: string; export declare const sharpMobileFriendly: string; export declare const sharpMobileOff: string; export declare const sharpMobileScreenShare: string; export declare const sharpMode: string; export declare const sharpModeComment: string; export declare const sharpModeEdit: string; export declare const sharpModeEditOutline: string; export declare const sharpModelTraining: string; export declare const sharpModeNight: string; export declare const sharpModeOfTravel: string; export declare const sharpModeStandby: string; export declare const sharpMonetizationOn: string; export declare const sharpMoney: string; export declare const sharpMoneyOff: string; export declare const sharpMoneyOffCsred: string; export declare const sharpMonitor: string; export declare const sharpMonitorWeight: string; export declare const sharpMonochromePhotos: string; export declare const sharpMood: string; export declare const sharpMoodBad: string; export declare const sharpMoped: string; export declare const sharpMore: string; export declare const sharpMoreHoriz: string; export declare const sharpMoreTime: string; export declare const sharpMoreVert: string; export declare const sharpMotionPhotosAuto: string; export declare const sharpMotionPhotosOff: string; export declare const sharpMotionPhotosOn: string; export declare const sharpMotionPhotosPause: string; export declare const sharpMotionPhotosPaused: string; export declare const sharpMouse: string; export declare const sharpMoveToInbox: string; export declare const sharpMovie: string; export declare const sharpMovieCreation: string; export declare const sharpMovieFilter: string; export declare const sharpMoving: string; export declare const sharpMp: string; export declare const sharpMultilineChart: string; export declare const sharpMultipleStop: string; export declare const sharpMuseum: string; export declare const sharpMusicNote: string; export declare const sharpMusicOff: string; export declare const sharpMusicVideo: string; export declare const sharpMyLocation: string; export declare const sharpNat: string; export declare const sharpNature: string; export declare const sharpNaturePeople: string; export declare const sharpNavigateBefore: string; export declare const sharpNavigateNext: string; export declare const sharpNavigation: string; export declare const sharpNearbyError: string; export declare const sharpNearbyOff: string; export declare const sharpNearMe: string; export declare const sharpNearMeDisabled: string; export declare const sharpNetworkCell: string; export declare const sharpNetworkCheck: string; export declare const sharpNetworkLocked: string; export declare const sharpNetworkWifi: string; export declare const sharpNewLabel: string; export declare const sharpNewReleases: string; export declare const sharpNextPlan: string; export declare const sharpNextWeek: string; export declare const sharpNfc: string; export declare const sharpNightlife: string; export declare const sharpNightlight: string; export declare const sharpNightlightRound: string; export declare const sharpNightShelter: string; export declare const sharpNightsStay: string; export declare const sharpNoAccounts: string; export declare const sharpNoBackpack: string; export declare const sharpNoCell: string; export declare const sharpNoDrinks: string; export declare const sharpNoEncryption: string; export declare const sharpNoEncryptionGmailerrorred: string; export declare const sharpNoFlash: string; export declare const sharpNoFood: string; export declare const sharpNoLuggage: string; export declare const sharpNoMeals: string; export declare const sharpNoMeetingRoom: string; export declare const sharpNoPhotography: string; export declare const sharpNordicWalking: string; export declare const sharpNorth: string; export declare const sharpNorthEast: string; export declare const sharpNorthWest: string; export declare const sharpNoSim: string; export declare const sharpNoStroller: string; export declare const sharpNotAccessible: string; export declare const sharpNote: string; export declare const sharpNoteAdd: string; export declare const sharpNoteAlt: string; export declare const sharpNotes: string; export declare const sharpNotificationAdd: string; export declare const sharpNotificationImportant: string; export declare const sharpNotifications: string; export declare const sharpNotificationsActive: string; export declare const sharpNotificationsNone: string; export declare const sharpNotificationsOff: string; export declare const sharpNotificationsPaused: string; export declare const sharpNotInterested: string; export declare const sharpNotListedLocation: string; export declare const sharpNoTransfer: string; export declare const sharpNotStarted: string; export declare const sharpNumbers: string; export declare const sharpOfflineBolt: string; export declare const sharpOfflinePin: string; export declare const sharpOfflineShare: string; export declare const sharpOndemandVideo: string; export declare const sharpOnlinePrediction: string; export declare const sharpOpacity: string; export declare const sharpOpenInBrowser: string; export declare const sharpOpenInFull: string; export declare const sharpOpenInNew: string; export declare const sharpOpenInNewOff: string; export declare const sharpOpenWith: string; export declare const sharpOtherHouses: string; export declare const sharpOutbound: string; export declare const sharpOutbox: string; export declare const sharpOutdoorGrill: string; export declare const sharpOutlet: string; export declare const sharpOutlinedFlag: string; export declare const sharpPadding: string; export declare const sharpPages: string; export declare const sharpPageview: string; export declare const sharpPaid: string; export declare const sharpPalette: string; export declare const sharpPanorama: string; export declare const sharpPanoramaFishEye: string; export declare const sharpPanoramaHorizontal: string; export declare const sharpPanoramaHorizontalSelect: string; export declare const sharpPanoramaPhotosphere: string; export declare const sharpPanoramaPhotosphereSelect: string; export declare const sharpPanoramaVertical: string; export declare const sharpPanoramaVerticalSelect: string; export declare const sharpPanoramaWideAngle: string; export declare const sharpPanoramaWideAngleSelect: string; export declare const sharpPanTool: string; export declare const sharpParagliding: string; export declare const sharpPark: string; export declare const sharpPartyMode: string; export declare const sharpPassword: string; export declare const sharpPattern: string; export declare const sharpPause: string; export declare const sharpPauseCircle: string; export declare const sharpPauseCircleFilled: string; export declare const sharpPauseCircleOutline: string; export declare const sharpPausePresentation: string; export declare const sharpPayment: string; export declare const sharpPayments: string; export declare const sharpPedalBike: string; export declare const sharpPending: string; export declare const sharpPendingActions: string; export declare const sharpPentagon: string; export declare const sharpPeople: string; export declare const sharpPeopleAlt: string; export declare const sharpPeopleOutline: string; export declare const sharpPercent: string; export declare const sharpPermCameraMic: string; export declare const sharpPermContactCalendar: string; export declare const sharpPermDataSetting: string; export declare const sharpPermDeviceInformation: string; export declare const sharpPermIdentity: string; export declare const sharpPermMedia: string; export declare const sharpPermPhoneMsg: string; export declare const sharpPermScanWifi: string; export declare const sharpPerson: string; export declare const sharpPersonAdd: string; export declare const sharpPersonAddAlt: string; export declare const sharpPersonAddAlt1: string; export declare const sharpPersonAddDisabled: string; export declare const sharpPersonalInjury: string; export declare const sharpPersonalVideo: string; export declare const sharpPersonOff: string; export declare const sharpPersonOutline: string; export declare const sharpPersonPin: string; export declare const sharpPersonPinCircle: string; export declare const sharpPersonRemove: string; export declare const sharpPersonRemoveAlt1: string; export declare const sharpPersonSearch: string; export declare const sharpPestControl: string; export declare const sharpPestControlRodent: string; export declare const sharpPets: string; export declare const sharpPhishing: string; export declare const sharpPhone: string; export declare const sharpPhoneAndroid: string; export declare const sharpPhoneBluetoothSpeaker: string; export declare const sharpPhoneCallback: string; export declare const sharpPhoneDisabled: string; export declare const sharpPhoneEnabled: string; export declare const sharpPhoneForwarded: string; export declare const sharpPhoneInTalk: string; export declare const sharpPhoneIphone: string; export declare const sharpPhonelink: string; export declare const sharpPhonelinkErase: string; export declare const sharpPhonelinkLock: string; export declare const sharpPhonelinkOff: string; export declare const sharpPhonelinkRing: string; export declare const sharpPhonelinkSetup: string; export declare const sharpPhoneLocked: string; export declare const sharpPhoneMissed: string; export declare const sharpPhonePaused: string; export declare const sharpPhoto: string; export declare const sharpPhotoAlbum: string; export declare const sharpPhotoCamera: string; export declare const sharpPhotoCameraBack: string; export declare const sharpPhotoCameraFront: string; export declare const sharpPhotoFilter: string; export declare const sharpPhotoLibrary: string; export declare const sharpPhotoSizeSelectActual: string; export declare const sharpPhotoSizeSelectLarge: string; export declare const sharpPhotoSizeSelectSmall: string; export declare const sharpPiano: string; export declare const sharpPianoOff: string; export declare const sharpPictureAsPdf: string; export declare const sharpPictureInPicture: string; export declare const sharpPictureInPictureAlt: string; export declare const sharpPieChart: string; export declare const sharpPieChartOutline: string; export declare const sharpPin: string; export declare const sharpPinch: string; export declare const sharpPinDrop: string; export declare const sharpPinEnd: string; export declare const sharpPinInvoke: string; export declare const sharpPivotTableChart: string; export declare const sharpPlace: string; export declare const sharpPlagiarism: string; export declare const sharpPlayArrow: string; export declare const sharpPlayCircle: string; export declare const sharpPlayCircleFilled: string; export declare const sharpPlayCircleOutline: string; export declare const sharpPlayDisabled: string; export declare const sharpPlayForWork: string; export declare const sharpPlayLesson: string; export declare const sharpPlaylistAdd: string; export declare const sharpPlaylistAddCheck: string; export declare const sharpPlaylistPlay: string; export declare const sharpPlumbing: string; export declare const sharpPlusOne: string; export declare const sharpPodcasts: string; export declare const sharpPointOfSale: string; export declare const sharpPolicy: string; export declare const sharpPoll: string; export declare const sharpPolymer: string; export declare const sharpPool: string; export declare const sharpPortableWifiOff: string; export declare const sharpPortrait: string; export declare const sharpPostAdd: string; export declare const sharpPower: string; export declare const sharpPowerInput: string; export declare const sharpPowerOff: string; export declare const sharpPowerSettingsNew: string; export declare const sharpPrecisionManufacturing: string; export declare const sharpPregnantWoman: string; export declare const sharpPresentToAll: string; export declare const sharpPreview: string; export declare const sharpPriceChange: string; export declare const sharpPriceCheck: string; export declare const sharpPrint: string; export declare const sharpPrintDisabled: string; export declare const sharpPriorityHigh: string; export declare const sharpPrivacyTip: string; export declare const sharpPrivateConnectivity: string; export declare const sharpProductionQuantityLimits: string; export declare const sharpPsychology: string; export declare const sharpPublic: string; export declare const sharpPublicOff: string; export declare const sharpPublish: string; export declare const sharpPublishedWithChanges: string; export declare const sharpPushPin: string; export declare const sharpQrCode: string; export declare const sharpQrCode2: string; export declare const sharpQrCodeScanner: string; export declare const sharpQueryBuilder: string; export declare const sharpQueryStats: string; export declare const sharpQuestionAnswer: string; export declare const sharpQueue: string; export declare const sharpQueueMusic: string; export declare const sharpQueuePlayNext: string; export declare const sharpQuickreply: string; export declare const sharpQuiz: string; export declare const sharpRadar: string; export declare const sharpRadio: string; export declare const sharpRadioButtonChecked: string; export declare const sharpRadioButtonUnchecked: string; export declare const sharpRailwayAlert: string; export declare const sharpRamenDining: string; export declare const sharpRateReview: string; export declare const sharpRawOff: string; export declare const sharpRawOn: string; export declare const sharpReadMore: string; export declare const sharpRealEstateAgent: string; export declare const sharpReceipt: string; export declare const sharpReceiptLong: string; export declare const sharpRecentActors: string; export declare const sharpRecommend: string; export declare const sharpRecordVoiceOver: string; export declare const sharpRectangle: string; export declare const sharpRecycling: string; export declare const sharpRedeem: string; export declare const sharpRedo: string; export declare const sharpReduceCapacity: string; export declare const sharpRefresh: string; export declare const sharpRememberMe: string; export declare const sharpRemove: string; export declare const sharpRemoveCircle: string; export declare const sharpRemoveCircleOutline: string; export declare const sharpRemoveDone: string; export declare const sharpRemoveFromQueue: string; export declare const sharpRemoveModerator: string; export declare const sharpRemoveRedEye: string; export declare const sharpRemoveShoppingCart: string; export declare const sharpReorder: string; export declare const sharpRepeat: string; export declare const sharpRepeatOn: string; export declare const sharpRepeatOne: string; export declare const sharpRepeatOneOn: string; export declare const sharpReplay: string; export declare const sharpReplay10: string; export declare const sharpReplay30: string; export declare const sharpReplay5: string; export declare const sharpReplayCircleFilled: string; export declare const sharpReply: string; export declare const sharpReplyAll: string; export declare const sharpReport: string; export declare const sharpReportGmailerrorred: string; export declare const sharpReportOff: string; export declare const sharpReportProblem: string; export declare const sharpRequestPage: string; export declare const sharpRequestQuote: string; export declare const sharpResetTv: string; export declare const sharpRestartAlt: string; export declare const sharpRestaurant: string; export declare const sharpRestaurantMenu: string; export declare const sharpRestore: string; export declare const sharpRestoreFromTrash: string; export declare const sharpRestorePage: string; export declare const sharpReviews: string; export declare const sharpRiceBowl: string; export declare const sharpRingVolume: string; export declare const sharpRMobiledata: string; export declare const sharpRoofing: string; export declare const sharpRoom: string; export declare const sharpRoomPreferences: string; export declare const sharpRoomService: string; export declare const sharpRotate90DegreesCcw: string; export declare const sharpRotateLeft: string; export declare const sharpRotateRight: string; export declare const sharpRoundedCorner: string; export declare const sharpRoute: string; export declare const sharpRouter: string; export declare const sharpRowing: string; export declare const sharpRssFeed: string; export declare const sharpRsvp: string; export declare const sharpRtt: string; export declare const sharpRule: string; export declare const sharpRuleFolder: string; export declare const sharpRunCircle: string; export declare const sharpRunningWithErrors: string; export declare const sharpRvHookup: string; export declare const sharpSafetyDivider: string; export declare const sharpSailing: string; export declare const sharpSanitizer: string; export declare const sharpSatellite: string; export declare const sharpSatelliteAlt: string; export declare const sharpSave: string; export declare const sharpSaveAlt: string; export declare const sharpSavedSearch: string; export declare const sharpSavings: string; export declare const sharpScanner: string; export declare const sharpScatterPlot: string; export declare const sharpSchedule: string; export declare const sharpScheduleSend: string; export declare const sharpSchema: string; export declare const sharpSchool: string; export declare const sharpScience: string; export declare const sharpScore: string; export declare const sharpScreenLockLandscape: string; export declare const sharpScreenLockPortrait: string; export declare const sharpScreenLockRotation: string; export declare const sharpScreenRotation: string; export declare const sharpScreenSearchDesktop: string; export declare const sharpScreenShare: string; export declare const sharpScreenshot: string; export declare const sharpSd: string; export declare const sharpSdCard: string; export declare const sharpSdCardAlert: string; export declare const sharpSdStorage: string; export declare const sharpSearch: string; export declare const sharpSearchOff: string; export declare const sharpSecurity: string; export declare const sharpSecurityUpdate: string; export declare const sharpSecurityUpdateGood: string; export declare const sharpSecurityUpdateWarning: string; export declare const sharpSegment: string; export declare const sharpSelectAll: string; export declare const sharpSelfImprovement: string; export declare const sharpSell: string; export declare const sharpSend: string; export declare const sharpSendAndArchive: string; export declare const sharpSendTimeExtension: string; export declare const sharpSendToMobile: string; export declare const sharpSensorDoor: string; export declare const sharpSensors: string; export declare const sharpSensorsOff: string; export declare const sharpSensorWindow: string; export declare const sharpSentimentDissatisfied: string; export declare const sharpSentimentNeutral: string; export declare const sharpSentimentSatisfied: string; export declare const sharpSentimentSatisfiedAlt: string; export declare const sharpSentimentVeryDissatisfied: string; export declare const sharpSentimentVerySatisfied: string; export declare const sharpSetMeal: string; export declare const sharpSettings: string; export declare const sharpSettingsAccessibility: string; export declare const sharpSettingsApplications: string; export declare const sharpSettingsBackupRestore: string; export declare const sharpSettingsBluetooth: string; export declare const sharpSettingsBrightness: string; export declare const sharpSettingsCell: string; export declare const sharpSettingsEthernet: string; export declare const sharpSettingsInputAntenna: string; export declare const sharpSettingsInputComponent: string; export declare const sharpSettingsInputComposite: string; export declare const sharpSettingsInputHdmi: string; export declare const sharpSettingsInputSvideo: string; export declare const sharpSettingsOverscan: string; export declare const sharpSettingsPhone: string; export declare const sharpSettingsPower: string; export declare const sharpSettingsRemote: string; export declare const sharpSettingsSuggest: string; export declare const sharpSettingsSystemDaydream: string; export declare const sharpSettingsVoice: string; export declare const sharpShare: string; export declare const sharpShareLocation: string; export declare const sharpShield: string; export declare const sharpShop: string; export declare const sharpShop2: string; export declare const sharpShoppingBag: string; export declare const sharpShoppingBasket: string; export declare const sharpShoppingCart: string; export declare const sharpShopTwo: string; export declare const sharpShortcut: string; export declare const sharpShortText: string; export declare const sharpShowChart: string; export declare const sharpShower: string; export declare const sharpShuffle: string; export declare const sharpShuffleOn: string; export declare const sharpShutterSpeed: string; export declare const sharpSick: string; export declare const sharpSignalCellular0Bar: string; export declare const sharpSignalCellular4Bar: string; export declare const sharpSignalCellularAlt: string; export declare const sharpSignalCellularConnectedNoInternet0Bar: string; export declare const sharpSignalCellularConnectedNoInternet4Bar: string; export declare const sharpSignalCellularNodata: string; export declare const sharpSignalCellularNoSim: string; export declare const sharpSignalCellularNull: string; export declare const sharpSignalCellularOff: string; export declare const sharpSignalWifi0Bar: string; export declare const sharpSignalWifi4Bar: string; export declare const sharpSignalWifi4BarLock: string; export declare const sharpSignalWifiBad: string; export declare const sharpSignalWifiConnectedNoInternet4: string; export declare const sharpSignalWifiOff: string; export declare const sharpSignalWifiStatusbar4Bar: string; export declare const sharpSignalWifiStatusbarConnectedNoInternet4: string; export declare const sharpSignalWifiStatusbarNull: string; export declare const sharpSimCard: string; export declare const sharpSimCardAlert: string; export declare const sharpSimCardDownload: string; export declare const sharpSingleBed: string; export declare const sharpSip: string; export declare const sharpSkateboarding: string; export declare const sharpSkipNext: string; export declare const sharpSkipPrevious: string; export declare const sharpSledding: string; export declare const sharpSlideshow: string; export declare const sharpSlowMotionVideo: string; export declare const sharpSmartButton: string; export declare const sharpSmartDisplay: string; export declare const sharpSmartphone: string; export declare const sharpSmartScreen: string; export declare const sharpSmartToy: string; export declare const sharpSmokeFree: string; export declare const sharpSmokingRooms: string; export declare const sharpSms: string; export declare const sharpSmsFailed: string; export declare const sharpSnippetFolder: string; export declare const sharpSnooze: string; export declare const sharpSnowboarding: string; export declare const sharpSnowmobile: string; export declare const sharpSnowshoeing: string; export declare const sharpSoap: string; export declare const sharpSocialDistance: string; export declare const sharpSort: string; export declare const sharpSortByAlpha: string; export declare const sharpSoupKitchen: string; export declare const sharpSource: string; export declare const sharpSouth: string; export declare const sharpSouthEast: string; export declare const sharpSouthWest: string; export declare const sharpSpa: string; export declare const sharpSpaceBar: string; export declare const sharpSpaceDashboard: string; export declare const sharpSpeaker: string; export declare const sharpSpeakerGroup: string; export declare const sharpSpeakerNotes: string; export declare const sharpSpeakerNotesOff: string; export declare const sharpSpeakerPhone: string; export declare const sharpSpeed: string; export declare const sharpSpellcheck: string; export declare const sharpSplitscreen: string; export declare const sharpSpoke: string; export declare const sharpSports: string; export declare const sharpSportsBar: string; export declare const sharpSportsBaseball: string; export declare const sharpSportsBasketball: string; export declare const sharpSportsCricket: string; export declare const sharpSportsEsports: string; export declare const sharpSportsFootball: string; export declare const sharpSportsGolf: string; export declare const sharpSportsHandball: string; export declare const sharpSportsHockey: string; export declare const sharpSportsKabaddi: string; export declare const sharpSportsMartialArts: string; export declare const sharpSportsMma: string; export declare const sharpSportsMotorsports: string; export declare const sharpSportsRugby: string; export declare const sharpSportsScore: string; export declare const sharpSportsSoccer: string; export declare const sharpSportsTennis: string; export declare const sharpSportsVolleyball: string; export declare const sharpSquare: string; export declare const sharpSquareFoot: string; export declare const sharpStackedBarChart: string; export declare const sharpStackedLineChart: string; export declare const sharpStairs: string; export declare const sharpStar: string; export declare const sharpStarBorder: string; export declare const sharpStarBorderPurple500: string; export declare const sharpStarHalf: string; export declare const sharpStarOutline: string; export declare const sharpStarPurple500: string; export declare const sharpStarRate: string; export declare const sharpStars: string; export declare const sharpStart: string; export declare const sharpStayCurrentLandscape: string; export declare const sharpStayCurrentPortrait: string; export declare const sharpStayPrimaryLandscape: string; export declare const sharpStayPrimaryPortrait: string; export declare const sharpStickyNote2: string; export declare const sharpStop: string; export declare const sharpStopCircle: string; export declare const sharpStopScreenShare: string; export declare const sharpStorage: string; export declare const sharpStore: string; export declare const sharpStorefront: string; export declare const sharpStoreMallDirectory: string; export declare const sharpStorm: string; export declare const sharpStraighten: string; export declare const sharpStream: string; export declare const sharpStreetview: string; export declare const sharpStrikethroughS: string; export declare const sharpStroller: string; export declare const sharpStyle: string; export declare const sharpSubdirectoryArrowLeft: string; export declare const sharpSubdirectoryArrowRight: string; export declare const sharpSubject: string; export declare const sharpSubscript: string; export declare const sharpSubscriptions: string; export declare const sharpSubtitles: string; export declare const sharpSubtitlesOff: string; export declare const sharpSubway: string; export declare const sharpSummarize: string; export declare const sharpSuperscript: string; export declare const sharpSupervisedUserCircle: string; export declare const sharpSupervisorAccount: string; export declare const sharpSupport: string; export declare const sharpSupportAgent: string; export declare const sharpSurfing: string; export declare const sharpSurroundSound: string; export declare const sharpSwapCalls: string; export declare const sharpSwapHoriz: string; export declare const sharpSwapHorizontalCircle: string; export declare const sharpSwapVert: string; export declare const sharpSwapVerticalCircle: string; export declare const sharpSwipe: string; export declare const sharpSwipeDown: string; export declare const sharpSwipeDownAlt: string; export declare const sharpSwipeLeft: string; export declare const sharpSwipeLeftAlt: string; export declare const sharpSwipeRight: string; export declare const sharpSwipeRightAlt: string; export declare const sharpSwipeUp: string; export declare const sharpSwipeUpAlt: string; export declare const sharpSwipeVertical: string; export declare const sharpSwitchAccessShortcut: string; export declare const sharpSwitchAccessShortcutAdd: string; export declare const sharpSwitchAccount: string; export declare const sharpSwitchCamera: string; export declare const sharpSwitchLeft: string; export declare const sharpSwitchRight: string; export declare const sharpSwitchVideo: string; export declare const sharpSync: string; export declare const sharpSyncAlt: string; export declare const sharpSyncDisabled: string; export declare const sharpSyncLock: string; export declare const sharpSyncProblem: string; export declare const sharpSystemSecurityUpdate: string; export declare const sharpSystemSecurityUpdateGood: string; export declare const sharpSystemSecurityUpdateWarning: string; export declare const sharpSystemUpdate: string; export declare const sharpSystemUpdateAlt: string; export declare const sharpTab: string; export declare const sharpTableBar: string; export declare const sharpTableChart: string; export declare const sharpTableRestaurant: string; export declare const sharpTableRows: string; export declare const sharpTablet: string; export declare const sharpTabletAndroid: string; export declare const sharpTabletMac: string; export declare const sharpTableView: string; export declare const sharpTabUnselected: string; export declare const sharpTag: string; export declare const sharpTagFaces: string; export declare const sharpTakeoutDining: string; export declare const sharpTapAndPlay: string; export declare const sharpTapas: string; export declare const sharpTask: string; export declare const sharpTaskAlt: string; export declare const sharpTaxiAlert: string; export declare const sharpTempleBuddhist: string; export declare const sharpTempleHindu: string; export declare const sharpTerrain: string; export declare const sharpTextDecrease: string; export declare const sharpTextFields: string; export declare const sharpTextFormat: string; export declare const sharpTextIncrease: string; export declare const sharpTextRotateUp: string; export declare const sharpTextRotateVertical: string; export declare const sharpTextRotationAngledown: string; export declare const sharpTextRotationAngleup: string; export declare const sharpTextRotationDown: string; export declare const sharpTextRotationNone: string; export declare const sharpTextsms: string; export declare const sharpTextSnippet: string; export declare const sharpTexture: string; export declare const sharpTheaterComedy: string; export declare const sharpTheaters: string; export declare const sharpThermostat: string; export declare const sharpThermostatAuto: string; export declare const sharpThumbDown: string; export declare const sharpThumbDownAlt: string; export declare const sharpThumbDownOffAlt: string; export declare const sharpThumbsUpDown: string; export declare const sharpThumbUp: string; export declare const sharpThumbUpAlt: string; export declare const sharpThumbUpOffAlt: string; export declare const sharpTimelapse: string; export declare const sharpTimeline: string; export declare const sharpTimer: string; export declare const sharpTimer10: string; export declare const sharpTimer10Select: string; export declare const sharpTimer3: string; export declare const sharpTimer3Select: string; export declare const sharpTimerOff: string; export declare const sharpTimeToLeave: string; export declare const sharpTipsAndUpdates: string; export declare const sharpTitle: string; export declare const sharpToc: string; export declare const sharpToday: string; export declare const sharpToggleOff: string; export declare const sharpToggleOn: string; export declare const sharpToken: string; export declare const sharpToll: string; export declare const sharpTonality: string; export declare const sharpTopic: string; export declare const sharpTouchApp: string; export declare const sharpTour: string; export declare const sharpToys: string; export declare const sharpTrackChanges: string; export declare const sharpTraffic: string; export declare const sharpTrain: string; export declare const sharpTram: string; export declare const sharpTransferWithinAStation: string; export declare const sharpTransform: string; export declare const sharpTransgender: string; export declare const sharpTransitEnterexit: string; export declare const sharpTranslate: string; export declare const sharpTravelExplore: string; export declare const sharpTrendingDown: string; export declare const sharpTrendingFlat: string; export declare const sharpTrendingUp: string; export declare const sharpTripOrigin: string; export declare const sharpTry: string; export declare const sharpTty: string; export declare const sharpTune: string; export declare const sharpTungsten: string; export declare const sharpTurnedIn: string; export declare const sharpTurnedInNot: string; export declare const sharpTv: string; export declare const sharpTvOff: string; export declare const sharpTwoWheeler: string; export declare const sharpUmbrella: string; export declare const sharpUnarchive: string; export declare const sharpUndo: string; export declare const sharpUnfoldLess: string; export declare const sharpUnfoldMore: string; export declare const sharpUnpublished: string; export declare const sharpUnsubscribe: string; export declare const sharpUpcoming: string; export declare const sharpUpdate: string; export declare const sharpUpdateDisabled: string; export declare const sharpUpgrade: string; export declare const sharpUpload: string; export declare const sharpUploadFile: string; export declare const sharpUsb: string; export declare const sharpUsbOff: string; export declare const sharpVerified: string; export declare const sharpVerifiedUser: string; export declare const sharpVerticalAlignBottom: string; export declare const sharpVerticalAlignCenter: string; export declare const sharpVerticalAlignTop: string; export declare const sharpVerticalDistribute: string; export declare const sharpVerticalSplit: string; export declare const sharpVibration: string; export declare const sharpVideoCall: string; export declare const sharpVideocam: string; export declare const sharpVideoCameraBack: string; export declare const sharpVideoCameraFront: string; export declare const sharpVideocamOff: string; export declare const sharpVideogameAsset: string; export declare const sharpVideogameAssetOff: string; export declare const sharpVideoLabel: string; export declare const sharpVideoLibrary: string; export declare const sharpVideoSettings: string; export declare const sharpVideoStable: string; export declare const sharpViewAgenda: string; export declare const sharpViewArray: string; export declare const sharpViewCarousel: string; export declare const sharpViewColumn: string; export declare const sharpViewComfy: string; export declare const sharpViewCompact: string; export declare const sharpViewDay: string; export declare const sharpViewHeadline: string; export declare const sharpViewInAr: string; export declare const sharpViewList: string; export declare const sharpViewModule: string; export declare const sharpViewQuilt: string; export declare const sharpViewSidebar: string; export declare const sharpViewStream: string; export declare const sharpViewWeek: string; export declare const sharpVignette: string; export declare const sharpVilla: string; export declare const sharpVisibility: string; export declare const sharpVisibilityOff: string; export declare const sharpVoiceChat: string; export declare const sharpVoicemail: string; export declare const sharpVoiceOverOff: string; export declare const sharpVolumeDown: string; export declare const sharpVolumeMute: string; export declare const sharpVolumeOff: string; export declare const sharpVolumeUp: string; export declare const sharpVolunteerActivism: string; export declare const sharpVpnKey: string; export declare const sharpVpnLock: string; export declare const sharpVrpano: string; export declare const sharpWallpaper: string; export declare const sharpWarning: string; export declare const sharpWarningAmber: string; export declare const sharpWash: string; export declare const sharpWatch: string; export declare const sharpWatchLater: string; export declare const sharpWatchOff: string; export declare const sharpWater: string; export declare const sharpWaterDamage: string; export declare const sharpWaterDrop: string; export declare const sharpWaterfallChart: string; export declare const sharpWaves: string; export declare const sharpWavingHand: string; export declare const sharpWbAuto: string; export declare const sharpWbCloudy: string; export declare const sharpWbIncandescent: string; export declare const sharpWbIridescent: string; export declare const sharpWbShade: string; export declare const sharpWbSunny: string; export declare const sharpWbTwilight: string; export declare const sharpWc: string; export declare const sharpWeb: string; export declare const sharpWebAsset: string; export declare const sharpWebAssetOff: string; export declare const sharpWeekend: string; export declare const sharpWest: string; export declare const sharpWhatshot: string; export declare const sharpWheelchairPickup: string; export declare const sharpWhereToVote: string; export declare const sharpWidgets: string; export declare const sharpWifi: string; export declare const sharpWifiCalling: string; export declare const sharpWifiCalling3: string; export declare const sharpWifiFind: string; export declare const sharpWifiLock: string; export declare const sharpWifiOff: string; export declare const sharpWifiProtectedSetup: string; export declare const sharpWifiTethering: string; export declare const sharpWifiTetheringError: string; export declare const sharpWifiTetheringOff: string; export declare const sharpWindow: string; export declare const sharpWineBar: string; export declare const sharpWoman: string; export declare const sharpWork: string; export declare const sharpWorkOff: string; export declare const sharpWorkOutline: string; export declare const sharpWorkspacePremium: string; export declare const sharpWorkspaces: string; export declare const sharpWrapText: string; export declare const sharpWrongLocation: string; export declare const sharpWysiwyg: string; export declare const sharpYard: string; export declare const sharpYoutubeSearchedFor: string; export declare const sharpZoomIn: string; export declare const sharpZoomInMap: string; export declare const sharpZoomOut: string; export declare const sharpZoomOutMap: string;
pdanpdan/quasar
extras/material-icons-sharp/index.d.ts
TypeScript
mit
88,356
import gulp from 'gulp'; import runSequence from 'run-sequence'; gulp.task('dev', ['clean'], function(cb) { global.isProd = false; runSequence(['styles', 'images', 'fonts', 'views','vendor'], 'browserify', 'watch', cb); });
tungptvn/tungpts-ng-blog
gulp/tasks/development.js
JavaScript
mit
239
export class AddProduct { public title: string; public description: string; public author: number; public price: number; public photos: any; constructor(data) { this.title = data.title; this.description = data.description; this.author = data.author; this.price = data.price; this.photos = data.photos; } }
PavelVak/sell-it
src/app/shared/models/add-product.model.ts
TypeScript
mit
341
module QueryStringSearch class MatcherFactory def self.build(search_option, build_options) matcher_to_build = build_options.detect { |m| m.build_me?(search_option) } if matcher_to_build matcher = matcher_to_build.new matcher.attribute = search_option.attribute matcher.desired_value = search_option.desired_value matcher.operator = search_option.operator matcher end end end end
umn-asr/query_string_search
lib/query_string_search/matcher_factory.rb
Ruby
mit
473
package formatters import ( "fmt" "testing" ) type str struct{} func (s str) String() string { return "test" } func TestFormatArray(t *testing.T) { testCases := []struct { name string in interface{} ret string }{ {"array string", []string{"value 1", "value 2", "value 3"}, `{"value 1","value 2","value 3"}`}, {"array int", []int{10, 20, 30}, `{10,20,30}`}, {"empty array", []int{}, `{}`}, {"stringer array", []fmt.Stringer{str{}, str{}, str{}}, `{"test","test","test"}`}, {"interface array", nil, `{"value 1","value 2","value 3"}`}, {"nil", nil, ""}, } // define interface array values := make([]interface{}, 3) values[0] = "value 1" values[1] = "value 2" values[2] = "value 3" testCases[4].in = values for _, tc := range testCases { t.Run(tc.name, func(t *testing.T) { ret := FormatArray(tc.in) if ret != tc.ret { t.Errorf("expected %v, but got %v", tc.ret, ret) } }) } }
nuveo/prest
adapters/postgres/formatters/formatters_test.go
GO
mit
931
/* * Generated by class-dump 3.4 (64 bit). * * class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2012 by Steve Nygard. */ #import "NSObject.h" @class DOMHTMLAnchorElement, DOMNode, EditingMessageWebView, NSButton, NSPanel, NSString, NSTextField; @interface HyperlinkEditor : NSObject { NSTextField *_linkTextField; NSButton *_okButton; NSButton *_removeButton; EditingMessageWebView *_webView; id _delegate; DOMHTMLAnchorElement *_selectedAnchor; DOMNode *_selectionContents; NSString *_replacementLink; NSPanel *_linkSheet; } @property(retain, nonatomic) NSPanel *linkSheet; // @synthesize linkSheet=_linkSheet; - (void)_setReplacementLink:(id)arg1; - (void)controlTextDidChange:(id)arg1; - (void)orderOutPanel:(id)arg1; - (void)removeSelectedLink; - (void)editLink; - (id)initForWebView:(id)arg1 delegate:(id)arg2; - (void)dealloc; @end
w-i-n-s/SimplePlugin
MailHeaders/Mavericks_GM/MailUI/HyperlinkEditor.h
C
mit
898
import 'syncfusion-javascript/Scripts/ej/web/ej.radiobutton.min'; import { CommonModule } from '@angular/common'; import { EJComponents } from './core'; import { EventEmitter, Type, Component, ElementRef, ChangeDetectorRef, Input, Output, NgModule, ModuleWithProviders, Directive, forwardRef } from '@angular/core'; import { NG_VALUE_ACCESSOR, ControlValueAccessor } from '@angular/forms'; const noop = () => { }; export const RadioButtonValueAccessor: any = { provide: NG_VALUE_ACCESSOR, useExisting: forwardRef(() => RadioButtonComponent), multi: true }; @Component({ selector: '[ej-radiobutton]', template: '', host: { '(ejchange)': 'onChange($event.value)', '(change)': 'onChange($event.value)', '(focusOut)': 'onTouched()' }, providers: [RadioButtonValueAccessor] }) export class RadioButtonComponent extends EJComponents<any, any> implements ControlValueAccessor { @Input('checked') checked_input: any; @Input('cssClass') cssClass_input: any; @Input('enabled') enabled_input: any; @Input('enablePersistence') enablePersistence_input: any; @Input('enableRTL') enableRTL_input: any; @Input('htmlAttributes') htmlAttributes_input: any; @Input('id') id_input: any; @Input('idPrefix') idPrefix_input: any; @Input('name') name_input: any; @Input('size') size_input: any; @Input('text') text_input: any; @Input('validationMessage') validationMessage_input: any; @Input('validationRules') validationRules_input: any; @Input('value') value_input: any; @Output('beforeChange') beforeChange_output = new EventEmitter(); @Output('change') change_output = new EventEmitter(); @Output('ejchange') ejchange_output = new EventEmitter(); @Output('create') create_output = new EventEmitter(); @Output('destroy') destroy_output = new EventEmitter(); constructor(public el: ElementRef, public cdRef: ChangeDetectorRef) { super('RadioButton', el, cdRef, []); } onChange: (_: any) => void = noop; onTouched: () => void = noop; writeValue(value: any): void { if (this.widget) { this.widget.option('model.value', value); } else { this.model.value = value; } } registerOnChange(fn: (_: any) => void): void { this.onChange = fn; } registerOnTouched(fn: () => void): void { this.onTouched = fn; } } export var EJ_RADIOBUTTON_COMPONENTS: Type<any>[] = [RadioButtonComponent ];
Dyalog/MiServer
PlugIns/Syncfusion-15.3.0.33/assets/angular2/radiobutton.component.ts
TypeScript
mit
2,349
androidappfromwebsite Android app displaying a website, supporting Facebook connect and displaying a loading bar when the user is loading a page. To setup, just change line 28 indicating the starting URL of the app, line 29 with your website prefix, and line 30 with the HTML that the app will display in case of 404 error. Now open the folder with Android studio and just make the APK file. I made this code public because there is too many scams on internet, like websites making you an app but telling you that you have to pay when you reach a certain amount of users to keep the app alive or showing adds to your visitors, or devellopers making you pay a very high price for this kind of app that is easy to code. Enjoy :)
leclem/androidappfromwebsite
README.md
Markdown
mit
731
class HomeController < ApplicationController def index # asdsa end end
shamithc/tailf
test/dummy/app/controllers/home_controller.rb
Ruby
mit
78
<?php require_once 'frontHomeLogin.php'; require_once 'backOpenSession.php'; require_once 'backCloseSession.php'; require_once 'backCheckLogin.php'; manageLogin(); function manageLogin() { $user = (string) $_POST["username"]; $password = (string) $_POST["password"]; if (checkLogin($user, $password)) { createSession(); if (checkCookie()) { header ("Location: frontLogin1.php"); } else { closeSession(); } } else { echo 'Username and/or password incorrect. Please try again.'; } } ?>
martinbosse/exercice_login
middleLogin.php
PHP
mit
626
\documentclass{article} \usepackage[utf8]{inputenc} \usepackage{indentfirst} \title{CS131 B1: HW 4} \author{Duy Nguyen} \date{10 October 2016} \begin{document} \maketitle \section*{Question 1} \subsection*{a.$\forall x \forall y P(x,y)$} When $ x \neq y $ the statement is \textbf{false}. \subsection*{b.$\forall x \exists y P(x,y)$} When $ x = 0 $ there is no $y$ where $ \frac{0}{y} = 1$. \textbf{False}. \subsection*{c.$\exists x \forall y P(x,y)$} There is not an $x$ where it could satisfy the condition. Alternatively, $y=0$ would blow up the statement for every $x$. \textbf{False}. \subsection*{d.$\exists x \exists y P(x,y)$} When $x = y$, and $y \neq 0$, the statement is true\textbf{true}. \section*{Question 2} \subsection*{a. $\exists x \forall y (x+y=y)$} There exists an $x$ such that for every $y$, $x + y = y$. This is \textbf{true} when $ x = 0$. \subsection*{b. $\forall x \forall y ((x \geq 0) \land (y < 0) \rightarrow (x - y > 0))$} For all $x$ greater or equal to zero, and $y$ which is a negative number, $x - y > 0$. Since $x > y$, the equation $x - y$ is greater than 0. \textbf{True}. \subsection*{c. $\forall x \forall y ((x \neq 0) \land (y \neq 0) \leftrightarrow (xy \neq 0))$} For all $x$ and $y$ beside zero, their product is not zero. Since there is no zero being multiply, the result could not be zero. Thus the statement is \textbf{true}. \section*{Question 3} \subsection*{a. Any person who is a female and a parent, is a mother of someone.} \begin{tabular}{rl} Define: & $x$ is a person \\ & $y$ is another person \\ & $F(x)$ is a female person \\ & $P(x)$ is a parent \\ & $M(x,y)$ said x is the mother of y \end{tabular} Then we have: $$\forall x \exists y (F(x) \land P(x) \rightarrow M(x,y))$$ \subsection*{b. There are people who are friends with everyone, people who have some friends, and people who have no friends.} \begin{tabular}{rl} Define: & $a, b, c, x$ are people \\ & $F(x, y)$ said that x is friend with y \end{tabular} Then we have: $$ (\exists a \forall x F(x, y)) \land (\exists b \exists x F(x, y) \land (\exists c \forall x \neg F(x,y))$$ \subsection*{c. For every real number $C>0$, there exists $\epsilon > 0$, such that $f(x) > C$ whenever $0 < x < \epsilon$.} \begin{tabular}{rl} Define: & $C$ is a real number $> 0$ \\ & $\epsilon$ is a small real number $>0$\\ & $x$ is a real number \\ & $f(x)$ is a function on x \end{tabular} Then we have that: $$ \forall C \exists \epsilon (0 < x < \epsilon) \rightarrow (f(x) > C)$$ \subsection*{d. Negation of the previous statement in logical form and in English.} $$ \forall C \exists \epsilon (0 < x < \epsilon) \rightarrow (f(x) > C)$$ Negated: $$ \exists C \forall \epsilon \neg ((0 < x < \epsilon) \rightarrow (f(x) > C))$$ $$ \exists C \forall \epsilon ((0 < x < \epsilon) \land \neg (f(x) > C))$$ $$ \exists C \forall \epsilon ((0 < x < \epsilon) \land (f(x) \leq C))$$ There exists $C$, a real number greater than $0$ where for all $\epsilon$: $x$ is between $0$ and $\epsilon$, and $f(x)$ is less or equal to $C$ \end{document}
zuik/stuff
unnatural_rubber/hw/CS131/hw4.tex
TeX
mit
3,175
<?php /** * Copyright (c) 2017. Puerto Parrot Booklet. Written by Dimitri Mostrey for www.puertoparrot.com * Contact me at admin@puertoparrot.com or dmostrey@yahoo.com */ namespace App\Listeners\Articles\Comments; use App\Events\Articles\Comments\Approved; use App\Mail\Articles\Comments\ApprovedToAdmin; use App\Models\User; use Illuminate\Contracts\Queue\ShouldQueue; use Mail; /** * Class ArticleCommentApprovedEmailAdmin * * @package App\Listeners */ class ApprovedEmailAdmin implements ShouldQueue { /** * @var \Illuminate\Database\Eloquent\Collection|\Illuminate\Database\Eloquent\Model|null|static|static[] */ private $admin; /** * Create the event listener. * */ public function __construct() { $this->admin = User::find(8); } /** * Handle the event. * * @param Approved $event * * @return void */ public function handle(Approved $event) { Mail::to($this->admin)->send(new ApprovedToAdmin($event->user, $event->article, $event->comment)); } /** * */ public function __destruct() { // } }
Dimimo/Booklet
app/Listeners/Articles/Comments/ApprovedEmailAdmin.php
PHP
mit
1,155
/** * * @type {*} * @private */ jDoc.Engines.RTF.prototype._specialControlWords = [ "chpgn", "chftn", "chdate", "chtime", "chatn", "chftnsep", "/", ":", "*", "~", "-", "_", "'hh", "page", "line", "раr", "sect", "tab", "сеll", "row", "colortbl", "fonttbl", "stylesheet", "pict" ];
pavel-voronin/jDoc
js/engines/RTF/reader/private/_specialControlWords.js
JavaScript
mit
383
[ng\:cloak], [ng-cloak], [data-ng-cloak], [x-ng-cloak], .ng-cloak, .x-ng-cloak { display: none !important; } .wiki-logo { height: 2em; } .main { margin-bottom: 40px; } .wiki-article { max-height: 600px; overflow-y: scroll; margin-bottom: 20px; } .pointer { cursor: pointer; }
mudroljub/angular-wiki-search
style.css
CSS
mit
306
//using System; //using Microsoft.EntityFrameworkCore.Infrastructure; //using Discord.Commands; //using Microsoft.Extensions.DependencyInjection; //using System.Collections.Generic; //namespace Discord.Addons.SimplePermissions //{ // /// <summary> </summary> // public sealed class EFCommandServiceExtension : IDbContextOptionsExtension // { // internal CommandService CommandService { get; } // DbContextOptionsExtensionInfo IDbContextOptionsExtension.Info => _info; // private readonly DbContextOptionsExtensionInfo _info; // /// <summary> </summary> // public EFCommandServiceExtension(CommandService commandService) // { // CommandService = commandService; // _info = new ExtensionInfo(this); // } // void IDbContextOptionsExtension.ApplyServices(IServiceCollection services) { } // //=> services.AddSingleton(CommandService); // void IDbContextOptionsExtension.Validate(IDbContextOptions options) { } // private sealed class ExtensionInfo : DbContextOptionsExtensionInfo // { // public override bool IsDatabaseProvider { get; } = false; // public override string LogFragment { get; } = String.Empty; // public ExtensionInfo(IDbContextOptionsExtension extension) // : base(extension) // { // } // public override long GetServiceProviderHashCode() => 0L; // public override void PopulateDebugInfo(IDictionary<string, string> debugInfo) { } // } // } //}
Joe4evr/Discord.Addons
src/Discord.Addons.SimplePermissions.EFProvider/EFCommandServiceExtension.cs
C#
mit
1,588
export default function album() { return { getAlbum: id => this.request(`${this.apiURL}/albums/${id}`), getAlbums: ids => this.request(`${this.apiURL}/albums/?ids=${ids}`), getTracks: id => this.request(`${this.apiURL}/albums/${id}/tracks`), }; }
dtfialho/js-tdd-course
module-06/src/album.js
JavaScript
mit
263
<?xml version="1.0" ?><!DOCTYPE TS><TS language="sah" version="2.0"> <context> <name>AboutDialog</name> <message> <location filename="../forms/aboutdialog.ui" line="+14"/> <source>About NSAcoin Core</source> <translation type="unfinished"/> </message> <message> <location line="+39"/> <source>&lt;b&gt;NSAcoin Core&lt;/b&gt; version</source> <translation type="unfinished"/> </message> <message> <location line="+57"/> <source> This is experimental software. Distributed under the MIT/X11 software license, see the accompanying file COPYING or http://www.opensource.org/licenses/mit-license.php. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit (http://www.openssl.org/) and cryptographic software written by Eric Young (eay@cryptsoft.com) and UPnP software written by Thomas Bernard.</source> <translation type="unfinished"/> </message> <message> <location filename="../utilitydialog.cpp" line="+29"/> <source>Copyright</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>The NSAcoin Core developers</source> <translation type="unfinished"/> </message> </context> <context> <name>AddressBookPage</name> <message> <location filename="../forms/addressbookpage.ui" line="+30"/> <source>Double-click to edit address or label</source> <translation>Аадырыскын уларытаргар иккитэ баттаа</translation> </message> <message> <location line="+27"/> <source>Create a new address</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;New</source> <translation type="unfinished"/> </message> <message> <location line="+11"/> <source>Copy the currently selected address to the system clipboard</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Copy</source> <translation type="unfinished"/> </message> <message> <location line="+52"/> <source>C&amp;lose</source> <translation type="unfinished"/> </message> <message> <location filename="../addressbookpage.cpp" line="+74"/> <source>&amp;Copy Address</source> <translation type="unfinished"/> </message> <message> <location filename="../forms/addressbookpage.ui" line="-41"/> <source>Delete the currently selected address from the list</source> <translation type="unfinished"/> </message> <message> <location line="+27"/> <source>Export the data in the current tab to a file</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Export</source> <translation type="unfinished"/> </message> <message> <location line="-27"/> <source>&amp;Delete</source> <translation type="unfinished"/> </message> <message> <location filename="../addressbookpage.cpp" line="-30"/> <source>Choose the address to send coins to</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Choose the address to receive coins with</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>C&amp;hoose</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Sending addresses</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Receiving addresses</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>These are your NSAcoin addresses for sending payments. Always check the amount and the receiving address before sending coins.</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>These are your NSAcoin addresses for receiving payments. It is recommended to use a new receiving address for each transaction.</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Copy &amp;Label</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>&amp;Edit</source> <translation type="unfinished"/> </message> <message> <location line="+194"/> <source>Export Address List</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Comma separated file (*.csv)</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Exporting Failed</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>There was an error trying to save the address list to %1.</source> <translation type="unfinished"/> </message> </context> <context> <name>AddressTableModel</name> <message> <location filename="../addresstablemodel.cpp" line="+168"/> <source>Label</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>Address</source> <translation type="unfinished"/> </message> <message> <location line="+36"/> <source>(no label)</source> <translation type="unfinished"/> </message> </context> <context> <name>AskPassphraseDialog</name> <message> <location filename="../forms/askpassphrasedialog.ui" line="+26"/> <source>Passphrase Dialog</source> <translation type="unfinished"/> </message> <message> <location line="+21"/> <source>Enter passphrase</source> <translation type="unfinished"/> </message> <message> <location line="+14"/> <source>New passphrase</source> <translation type="unfinished"/> </message> <message> <location line="+14"/> <source>Repeat new passphrase</source> <translation type="unfinished"/> </message> <message> <location filename="../askpassphrasedialog.cpp" line="+40"/> <source>Enter the new passphrase to the wallet.&lt;br/&gt;Please use a passphrase of &lt;b&gt;10 or more random characters&lt;/b&gt;, or &lt;b&gt;eight or more words&lt;/b&gt;.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Encrypt wallet</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>This operation needs your wallet passphrase to unlock the wallet.</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Unlock wallet</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>This operation needs your wallet passphrase to decrypt the wallet.</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Decrypt wallet</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Change passphrase</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Enter the old and new passphrase to the wallet.</source> <translation type="unfinished"/> </message> <message> <location line="+46"/> <source>Confirm wallet encryption</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Warning: If you encrypt your wallet and lose your passphrase, you will &lt;b&gt;LOSE ALL OF YOUR BITCOINS&lt;/b&gt;!</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>Are you sure you wish to encrypt your wallet?</source> <translation type="unfinished"/> </message> <message> <location line="+15"/> <source>IMPORTANT: Any previous backups you have made of your wallet file should be replaced with the newly generated, encrypted wallet file. For security reasons, previous backups of the unencrypted wallet file will become useless as soon as you start using the new, encrypted wallet.</source> <translation type="unfinished"/> </message> <message> <location line="+100"/> <location line="+24"/> <source>Warning: The Caps Lock key is on!</source> <translation type="unfinished"/> </message> <message> <location line="-130"/> <location line="+58"/> <source>Wallet encrypted</source> <translation type="unfinished"/> </message> <message> <location line="-56"/> <source>NSAcoin will close now to finish the encryption process. Remember that encrypting your wallet cannot fully protect your bitcoins from being stolen by malware infecting your computer.</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <location line="+7"/> <location line="+42"/> <location line="+6"/> <source>Wallet encryption failed</source> <translation type="unfinished"/> </message> <message> <location line="-54"/> <source>Wallet encryption failed due to an internal error. Your wallet was not encrypted.</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <location line="+48"/> <source>The supplied passphrases do not match.</source> <translation type="unfinished"/> </message> <message> <location line="-37"/> <source>Wallet unlock failed</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <location line="+11"/> <location line="+19"/> <source>The passphrase entered for the wallet decryption was incorrect.</source> <translation type="unfinished"/> </message> <message> <location line="-20"/> <source>Wallet decryption failed</source> <translation type="unfinished"/> </message> <message> <location line="+14"/> <source>Wallet passphrase was successfully changed.</source> <translation type="unfinished"/> </message> </context> <context> <name>NSAcoinGUI</name> <message> <location filename="../bitcoingui.cpp" line="+295"/> <source>Sign &amp;message...</source> <translation type="unfinished"/> </message> <message> <location line="+335"/> <source>Synchronizing with network...</source> <translation type="unfinished"/> </message> <message> <location line="-407"/> <source>&amp;Overview</source> <translation type="unfinished"/> </message> <message> <location line="-137"/> <source>Node</source> <translation type="unfinished"/> </message> <message> <location line="+138"/> <source>Show general overview of wallet</source> <translation type="unfinished"/> </message> <message> <location line="+20"/> <source>&amp;Transactions</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Browse transaction history</source> <translation type="unfinished"/> </message> <message> <location line="+17"/> <source>E&amp;xit</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Quit application</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Show information about NSAcoin</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <location line="+2"/> <source>About &amp;Qt</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Show information about Qt</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>&amp;Options...</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>&amp;Encrypt Wallet...</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Backup Wallet...</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>&amp;Change Passphrase...</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>&amp;Sending addresses...</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>&amp;Receiving addresses...</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Open &amp;URI...</source> <translation type="unfinished"/> </message> <message> <location line="+325"/> <source>Importing blocks from disk...</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Reindexing blocks on disk...</source> <translation type="unfinished"/> </message> <message> <location line="-405"/> <source>Send coins to a NSAcoin address</source> <translation type="unfinished"/> </message> <message> <location line="+49"/> <source>Modify configuration options for NSAcoin</source> <translation type="unfinished"/> </message> <message> <location line="+12"/> <source>Backup wallet to another location</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Change the passphrase used for wallet encryption</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>&amp;Debug window</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Open debugging and diagnostic console</source> <translation type="unfinished"/> </message> <message> <location line="-4"/> <source>&amp;Verify message...</source> <translation type="unfinished"/> </message> <message> <location line="+430"/> <source>NSAcoin</source> <translation type="unfinished"/> </message> <message> <location line="-643"/> <source>Wallet</source> <translation type="unfinished"/> </message> <message> <location line="+146"/> <source>&amp;Send</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>&amp;Receive</source> <translation type="unfinished"/> </message> <message> <location line="+46"/> <location line="+2"/> <source>&amp;Show / Hide</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Show or hide the main Window</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Encrypt the private keys that belong to your wallet</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Sign messages with your NSAcoin addresses to prove you own them</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Verify messages to ensure they were signed with specified NSAcoin addresses</source> <translation type="unfinished"/> </message> <message> <location line="+48"/> <source>&amp;File</source> <translation type="unfinished"/> </message> <message> <location line="+14"/> <source>&amp;Settings</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>&amp;Help</source> <translation type="unfinished"/> </message> <message> <location line="+15"/> <source>Tabs toolbar</source> <translation type="unfinished"/> </message> <message> <location line="-284"/> <location line="+376"/> <source>[testnet]</source> <translation type="unfinished"/> </message> <message> <location line="-401"/> <source>NSAcoin Core</source> <translation type="unfinished"/> </message> <message> <location line="+163"/> <source>Request payments (generates QR codes and bitcoin: URIs)</source> <translation type="unfinished"/> </message> <message> <location line="+29"/> <location line="+2"/> <source>&amp;About NSAcoin Core</source> <translation type="unfinished"/> </message> <message> <location line="+35"/> <source>Show the list of used sending addresses and labels</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Show the list of used receiving addresses and labels</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Open a bitcoin: URI or payment request</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>&amp;Command-line options</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Show the NSAcoin Core help message to get a list with possible NSAcoin command-line options</source> <translation type="unfinished"/> </message> <message> <location line="+159"/> <location line="+5"/> <source>NSAcoin client</source> <translation type="unfinished"/> </message> <message numerus="yes"> <location line="+142"/> <source>%n active connection(s) to NSAcoin network</source> <translation type="unfinished"><numerusform></numerusform></translation> </message> <message> <location line="+22"/> <source>No block source available...</source> <translation type="unfinished"/> </message> <message> <location line="+12"/> <source>Processed %1 of %2 (estimated) blocks of transaction history.</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Processed %1 blocks of transaction history.</source> <translation type="unfinished"/> </message> <message numerus="yes"> <location line="+23"/> <source>%n hour(s)</source> <translation type="unfinished"><numerusform></numerusform></translation> </message> <message numerus="yes"> <location line="+4"/> <source>%n day(s)</source> <translation type="unfinished"><numerusform></numerusform></translation> </message> <message numerus="yes"> <location line="+4"/> <source>%n week(s)</source> <translation type="unfinished"><numerusform></numerusform></translation> </message> <message> <location line="+4"/> <source>%1 behind</source> <translation type="unfinished"/> </message> <message> <location line="+21"/> <source>Last received block was generated %1 ago.</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Transactions after this will not yet be visible.</source> <translation type="unfinished"/> </message> <message> <location line="+27"/> <source>Error</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Warning</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Information</source> <translation type="unfinished"/> </message> <message> <location line="-85"/> <source>Up to date</source> <translation type="unfinished"/> </message> <message> <location line="+34"/> <source>Catching up...</source> <translation type="unfinished"/> </message> <message> <location line="+130"/> <source>Sent transaction</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>Incoming transaction</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Date: %1 Amount: %2 Type: %3 Address: %4 </source> <translation type="unfinished"/> </message> <message> <location line="+69"/> <source>Wallet is &lt;b&gt;encrypted&lt;/b&gt; and currently &lt;b&gt;unlocked&lt;/b&gt;</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>Wallet is &lt;b&gt;encrypted&lt;/b&gt; and currently &lt;b&gt;locked&lt;/b&gt;</source> <translation type="unfinished"/> </message> <message> <location filename="../bitcoin.cpp" line="+438"/> <source>A fatal error occurred. NSAcoin can no longer continue safely and will quit.</source> <translation type="unfinished"/> </message> </context> <context> <name>ClientModel</name> <message> <location filename="../clientmodel.cpp" line="+119"/> <source>Network Alert</source> <translation type="unfinished"/> </message> </context> <context> <name>CoinControlDialog</name> <message> <location filename="../forms/coincontroldialog.ui" line="+14"/> <source>Coin Control Address Selection</source> <translation type="unfinished"/> </message> <message> <location line="+34"/> <source>Quantity:</source> <translation type="unfinished"/> </message> <message> <location line="+29"/> <source>Bytes:</source> <translation type="unfinished"/> </message> <message> <location line="+45"/> <source>Amount:</source> <translation type="unfinished"/> </message> <message> <location line="+29"/> <source>Priority:</source> <translation type="unfinished"/> </message> <message> <location line="+45"/> <source>Fee:</source> <translation type="unfinished"/> </message> <message> <location line="+32"/> <source>Low Output:</source> <translation type="unfinished"/> </message> <message> <location line="+48"/> <source>After Fee:</source> <translation type="unfinished"/> </message> <message> <location line="+32"/> <source>Change:</source> <translation type="unfinished"/> </message> <message> <location line="+63"/> <source>(un)select all</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Tree mode</source> <translation type="unfinished"/> </message> <message> <location line="+16"/> <source>List mode</source> <translation type="unfinished"/> </message> <message> <location line="+52"/> <source>Amount</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>Address</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Date</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Confirmations</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Confirmed</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Priority</source> <translation type="unfinished"/> </message> <message> <location filename="../coincontroldialog.cpp" line="+42"/> <source>Copy address</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy label</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <location line="+26"/> <source>Copy amount</source> <translation type="unfinished"/> </message> <message> <location line="-25"/> <source>Copy transaction ID</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Lock unspent</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Unlock unspent</source> <translation type="unfinished"/> </message> <message> <location line="+22"/> <source>Copy quantity</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Copy fee</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy after fee</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy bytes</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy priority</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy low output</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy change</source> <translation type="unfinished"/> </message> <message> <location line="+323"/> <source>highest</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>higher</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>high</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>medium-high</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>medium</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>low-medium</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>low</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>lower</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>lowest</source> <translation type="unfinished"/> </message> <message> <location line="+11"/> <source>(%1 locked)</source> <translation type="unfinished"/> </message> <message> <location line="+31"/> <source>none</source> <translation type="unfinished"/> </message> <message> <location line="+140"/> <source>Dust</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>yes</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>no</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>This label turns red, if the transaction size is greater than 1000 bytes.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <location line="+5"/> <source>This means a fee of at least %1 per kB is required.</source> <translation type="unfinished"/> </message> <message> <location line="-4"/> <source>Can vary +/- 1 byte per input.</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Transactions with higher priority are more likely to get included into a block.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>This label turns red, if the priority is smaller than &quot;medium&quot;.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>This label turns red, if any recipient receives an amount smaller than %1.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <location line="+4"/> <source>This means a fee of at least %1 is required.</source> <translation type="unfinished"/> </message> <message> <location line="-3"/> <source>Amounts below 0.546 times the minimum relay fee are shown as dust.</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>This label turns red, if the change is smaller than %1.</source> <translation type="unfinished"/> </message> <message> <location line="+43"/> <location line="+66"/> <source>(no label)</source> <translation type="unfinished"/> </message> <message> <location line="-9"/> <source>change from %1 (%2)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>(change)</source> <translation type="unfinished"/> </message> </context> <context> <name>EditAddressDialog</name> <message> <location filename="../forms/editaddressdialog.ui" line="+14"/> <source>Edit Address</source> <translation type="unfinished"/> </message> <message> <location line="+11"/> <source>&amp;Label</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>The label associated with this address list entry</source> <translation type="unfinished"/> </message> <message> <location line="+17"/> <source>The address associated with this address list entry. This can only be modified for sending addresses.</source> <translation type="unfinished"/> </message> <message> <location line="-10"/> <source>&amp;Address</source> <translation type="unfinished"/> </message> <message> <location filename="../editaddressdialog.cpp" line="+28"/> <source>New receiving address</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>New sending address</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Edit receiving address</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Edit sending address</source> <translation type="unfinished"/> </message> <message> <location line="+76"/> <source>The entered address &quot;%1&quot; is already in the address book.</source> <translation type="unfinished"/> </message> <message> <location line="-5"/> <source>The entered address &quot;%1&quot; is not a valid NSAcoin address.</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>Could not unlock wallet.</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>New key generation failed.</source> <translation type="unfinished"/> </message> </context> <context> <name>FreespaceChecker</name> <message> <location filename="../intro.cpp" line="+65"/> <source>A new data directory will be created.</source> <translation type="unfinished"/> </message> <message> <location line="+22"/> <source>name</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Directory already exists. Add %1 if you intend to create a new directory here.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Path already exists, and is not a directory.</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Cannot create data directory here.</source> <translation type="unfinished"/> </message> </context> <context> <name>HelpMessageDialog</name> <message> <location filename="../forms/helpmessagedialog.ui" line="+19"/> <source>NSAcoin Core - Command-line options</source> <translation type="unfinished"/> </message> <message> <location filename="../utilitydialog.cpp" line="+38"/> <source>NSAcoin Core</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>version</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Usage:</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>command-line options</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>UI options</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Set language, for example &quot;de_DE&quot; (default: system locale)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Start minimized</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Show splash screen on startup (default: 1)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Choose data directory on startup (default: 0)</source> <translation type="unfinished"/> </message> </context> <context> <name>Intro</name> <message> <location filename="../forms/intro.ui" line="+14"/> <source>Welcome</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>Welcome to NSAcoin Core.</source> <translation type="unfinished"/> </message> <message> <location line="+26"/> <source>As this is the first time the program is launched, you can choose where NSAcoin Core will store its data.</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>NSAcoin Core will download and store a copy of the NSAcoin block chain. At least %1GB of data will be stored in this directory, and it will grow over time. The wallet will also be stored in this directory.</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>Use the default data directory</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Use a custom data directory:</source> <translation type="unfinished"/> </message> <message> <location filename="../intro.cpp" line="+85"/> <source>NSAcoin</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Error: Specified data directory &quot;%1&quot; can not be created.</source> <translation type="unfinished"/> </message> <message> <location line="+19"/> <source>Error</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>GB of free space available</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>(of %1GB needed)</source> <translation type="unfinished"/> </message> </context> <context> <name>OpenURIDialog</name> <message> <location filename="../forms/openuridialog.ui" line="+14"/> <source>Open URI</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Open payment request from URI or file</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>URI:</source> <translation type="unfinished"/> </message> <message> <location line="+11"/> <source>Select payment request file</source> <translation type="unfinished"/> </message> <message> <location filename="../openuridialog.cpp" line="+47"/> <source>Select payment request file to open</source> <translation type="unfinished"/> </message> </context> <context> <name>OptionsDialog</name> <message> <location filename="../forms/optionsdialog.ui" line="+14"/> <source>Options</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>&amp;Main</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Optional transaction fee per kB that helps make sure your transactions are processed quickly. Most transactions are 1 kB.</source> <translation type="unfinished"/> </message> <message> <location line="+15"/> <source>Pay transaction &amp;fee</source> <translation type="unfinished"/> </message> <message> <location line="+31"/> <source>Automatically start NSAcoin after logging in to the system.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Start NSAcoin on system login</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>Size of &amp;database cache</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Set database cache size in megabytes (default: 25)</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>MB</source> <translation type="unfinished"/> </message> <message> <location line="+27"/> <source>Number of script &amp;verification threads</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Set the number of script verification threads (up to 16, 0 = auto, &lt;0 = leave that many cores free, default: 0)</source> <translation type="unfinished"/> </message> <message> <location line="+58"/> <source>Connect to the NSAcoin network through a SOCKS proxy.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Connect through SOCKS proxy (default proxy):</source> <translation type="unfinished"/> </message> <message> <location line="+34"/> <source>IP address of the proxy (e.g. IPv4: 127.0.0.1 / IPv6: ::1)</source> <translation type="unfinished"/> </message> <message> <location line="+224"/> <source>Active command-line options that override above options:</source> <translation type="unfinished"/> </message> <message> <location line="+43"/> <source>Reset all client options to default.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Reset Options</source> <translation type="unfinished"/> </message> <message> <location line="-323"/> <source>&amp;Network</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Automatically open the NSAcoin client port on the router. This only works when your router supports UPnP and it is enabled.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Map port using &amp;UPnP</source> <translation type="unfinished"/> </message> <message> <location line="+19"/> <source>Proxy &amp;IP:</source> <translation type="unfinished"/> </message> <message> <location line="+32"/> <source>&amp;Port:</source> <translation type="unfinished"/> </message> <message> <location line="+25"/> <source>Port of the proxy (e.g. 9050)</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>SOCKS &amp;Version:</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>SOCKS version of the proxy (e.g. 5)</source> <translation type="unfinished"/> </message> <message> <location line="+36"/> <source>&amp;Window</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Show only a tray icon after minimizing the window.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Minimize to the tray instead of the taskbar</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Minimize instead of exit the application when the window is closed. When this option is enabled, the application will be closed only after selecting Quit in the menu.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>M&amp;inimize on close</source> <translation type="unfinished"/> </message> <message> <location line="+21"/> <source>&amp;Display</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>User Interface &amp;language:</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>The user interface language can be set here. This setting will take effect after restarting NSAcoin.</source> <translation type="unfinished"/> </message> <message> <location line="+11"/> <source>&amp;Unit to show amounts in:</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Choose the default subdivision unit to show in the interface and when sending coins.</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>Whether to show NSAcoin addresses in the transaction list or not.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Display addresses in transaction list</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Whether to show coin control features or not.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Display coin &amp;control features (experts only)</source> <translation type="unfinished"/> </message> <message> <location line="+136"/> <source>&amp;OK</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>&amp;Cancel</source> <translation type="unfinished"/> </message> <message> <location filename="../optionsdialog.cpp" line="+67"/> <source>default</source> <translation type="unfinished"/> </message> <message> <location line="+57"/> <source>none</source> <translation type="unfinished"/> </message> <message> <location line="+75"/> <source>Confirm options reset</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <location line="+29"/> <source>Client restart required to activate changes.</source> <translation type="unfinished"/> </message> <message> <location line="-29"/> <source>Client will be shutdown, do you want to proceed?</source> <translation type="unfinished"/> </message> <message> <location line="+33"/> <source>This change would require a client restart.</source> <translation type="unfinished"/> </message> <message> <location line="+34"/> <source>The supplied proxy address is invalid.</source> <translation type="unfinished"/> </message> </context> <context> <name>OverviewPage</name> <message> <location filename="../forms/overviewpage.ui" line="+14"/> <source>Form</source> <translation type="unfinished"/> </message> <message> <location line="+50"/> <location line="+231"/> <source>The displayed information may be out of date. Your wallet automatically synchronizes with the NSAcoin network after a connection is established, but this process has not completed yet.</source> <translation type="unfinished"/> </message> <message> <location line="-155"/> <source>Unconfirmed:</source> <translation type="unfinished"/> </message> <message> <location line="-83"/> <source>Wallet</source> <translation type="unfinished"/> </message> <message> <location line="+51"/> <source>Confirmed:</source> <translation type="unfinished"/> </message> <message> <location line="+16"/> <source>Your current spendable balance</source> <translation type="unfinished"/> </message> <message> <location line="+32"/> <source>Total of transactions that have yet to be confirmed, and do not yet count toward the spendable balance</source> <translation type="unfinished"/> </message> <message> <location line="+16"/> <source>Immature:</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Mined balance that has not yet matured</source> <translation type="unfinished"/> </message> <message> <location line="+16"/> <source>Total:</source> <translation type="unfinished"/> </message> <message> <location line="+16"/> <source>Your current total balance</source> <translation type="unfinished"/> </message> <message> <location line="+71"/> <source>&lt;b&gt;Recent transactions&lt;/b&gt;</source> <translation type="unfinished"/> </message> <message> <location filename="../overviewpage.cpp" line="+120"/> <location line="+1"/> <source>out of sync</source> <translation type="unfinished"/> </message> </context> <context> <name>PaymentServer</name> <message> <location filename="../paymentserver.cpp" line="+403"/> <location line="+13"/> <source>URI handling</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>URI can not be parsed! This can be caused by an invalid NSAcoin address or malformed URI parameters.</source> <translation type="unfinished"/> </message> <message> <location line="+96"/> <source>Requested payment amount of %1 is too small (considered dust).</source> <translation type="unfinished"/> </message> <message> <location line="-221"/> <location line="+212"/> <location line="+13"/> <location line="+95"/> <location line="+18"/> <location line="+16"/> <source>Payment request error</source> <translation type="unfinished"/> </message> <message> <location line="-353"/> <source>Cannot start bitcoin: click-to-pay handler</source> <translation type="unfinished"/> </message> <message> <location line="+58"/> <source>Net manager warning</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Your active proxy doesn&apos;t support SOCKS5, which is required for payment requests via proxy.</source> <translation type="unfinished"/> </message> <message> <location line="+52"/> <source>Payment request fetch URL is invalid: %1</source> <translation type="unfinished"/> </message> <message> <location line="+27"/> <source>Payment request file handling</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Payment request file can not be read or processed! This can be caused by an invalid payment request file.</source> <translation type="unfinished"/> </message> <message> <location line="+73"/> <source>Unverified payment requests to custom payment scripts are unsupported.</source> <translation type="unfinished"/> </message> <message> <location line="+59"/> <source>Refund from %1</source> <translation type="unfinished"/> </message> <message> <location line="+43"/> <source>Error communicating with %1: %2</source> <translation type="unfinished"/> </message> <message> <location line="+24"/> <source>Payment request can not be parsed or processed!</source> <translation type="unfinished"/> </message> <message> <location line="+11"/> <source>Bad response from server %1</source> <translation type="unfinished"/> </message> <message> <location line="+33"/> <source>Payment acknowledged</source> <translation type="unfinished"/> </message> <message> <location line="-11"/> <source>Network request error</source> <translation type="unfinished"/> </message> </context> <context> <name>QObject</name> <message> <location filename="../bitcoin.cpp" line="+71"/> <location line="+11"/> <source>NSAcoin</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Error: Specified data directory &quot;%1&quot; does not exist.</source> <translation type="unfinished"/> </message> <message> <location line="-12"/> <source>Error: Invalid combination of -regtest and -testnet.</source> <translation type="unfinished"/> </message> <message> <location filename="../guiutil.cpp" line="+82"/> <source>Enter a NSAcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> <translation type="unfinished"/> </message> </context> <context> <name>QRImageWidget</name> <message> <location filename="../receiverequestdialog.cpp" line="+36"/> <source>&amp;Save Image...</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>&amp;Copy Image</source> <translation type="unfinished"/> </message> <message> <location line="+28"/> <source>Save QR Code</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>PNG Image (*.png)</source> <translation type="unfinished"/> </message> </context> <context> <name>RPCConsole</name> <message> <location filename="../forms/rpcconsole.ui" line="+46"/> <source>Client name</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <location line="+23"/> <location line="+26"/> <location line="+23"/> <location line="+23"/> <location line="+36"/> <location line="+23"/> <location line="+36"/> <location line="+23"/> <location line="+23"/> <location filename="../rpcconsole.cpp" line="+359"/> <source>N/A</source> <translation type="unfinished"/> </message> <message> <location line="-223"/> <source>Client version</source> <translation type="unfinished"/> </message> <message> <location line="-45"/> <source>&amp;Information</source> <translation type="unfinished"/> </message> <message> <location line="-10"/> <source>Debug window</source> <translation type="unfinished"/> </message> <message> <location line="+25"/> <source>General</source> <translation type="unfinished"/> </message> <message> <location line="+53"/> <source>Using OpenSSL version</source> <translation type="unfinished"/> </message> <message> <location line="+49"/> <source>Startup time</source> <translation type="unfinished"/> </message> <message> <location line="+29"/> <source>Network</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Name</source> <translation type="unfinished"/> </message> <message> <location line="+23"/> <source>Number of connections</source> <translation type="unfinished"/> </message> <message> <location line="+29"/> <source>Block chain</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Current number of blocks</source> <translation type="unfinished"/> </message> <message> <location line="+23"/> <source>Estimated total blocks</source> <translation type="unfinished"/> </message> <message> <location line="+23"/> <source>Last block time</source> <translation type="unfinished"/> </message> <message> <location line="+52"/> <source>&amp;Open</source> <translation type="unfinished"/> </message> <message> <location line="+24"/> <source>&amp;Console</source> <translation type="unfinished"/> </message> <message> <location line="+72"/> <source>&amp;Network Traffic</source> <translation type="unfinished"/> </message> <message> <location line="+52"/> <source>&amp;Clear</source> <translation type="unfinished"/> </message> <message> <location line="+13"/> <source>Totals</source> <translation type="unfinished"/> </message> <message> <location line="+64"/> <source>In:</source> <translation type="unfinished"/> </message> <message> <location line="+80"/> <source>Out:</source> <translation type="unfinished"/> </message> <message> <location line="-521"/> <source>Build date</source> <translation type="unfinished"/> </message> <message> <location line="+206"/> <source>Debug log file</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Open the NSAcoin debug log file from the current data directory. This can take a few seconds for large log files.</source> <translation type="unfinished"/> </message> <message> <location line="+76"/> <source>Clear console</source> <translation type="unfinished"/> </message> <message> <location filename="../rpcconsole.cpp" line="-30"/> <source>Welcome to the NSAcoin RPC console.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Use up and down arrows to navigate history, and &lt;b&gt;Ctrl-L&lt;/b&gt; to clear screen.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Type &lt;b&gt;help&lt;/b&gt; for an overview of available commands.</source> <translation type="unfinished"/> </message> <message> <location line="+122"/> <source>%1 B</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>%1 KB</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>%1 MB</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>%1 GB</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>%1 m</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>%1 h</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>%1 h %2 m</source> <translation type="unfinished"/> </message> </context> <context> <name>ReceiveCoinsDialog</name> <message> <location filename="../forms/receivecoinsdialog.ui" line="+107"/> <source>&amp;Amount:</source> <translation type="unfinished"/> </message> <message> <location line="-16"/> <source>&amp;Label:</source> <translation type="unfinished"/> </message> <message> <location line="-37"/> <source>&amp;Message:</source> <translation type="unfinished"/> </message> <message> <location line="-20"/> <source>Reuse one of the previously used receiving addresses. Reusing addresses has security and privacy issues. Do not use this unless re-generating a payment request made before.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>R&amp;euse an existing receiving address (not recommended)</source> <translation type="unfinished"/> </message> <message> <location line="+14"/> <location line="+23"/> <source>An optional message to attach to the payment request, which will be displayed when the request is opened. Note: The message will not be sent with the payment over the NSAcoin network.</source> <translation type="unfinished"/> </message> <message> <location line="-7"/> <location line="+21"/> <source>An optional label to associate with the new receiving address.</source> <translation type="unfinished"/> </message> <message> <location line="-7"/> <source>Use this form to request payments. All fields are &lt;b&gt;optional&lt;/b&gt;.</source> <translation type="unfinished"/> </message> <message> <location line="+23"/> <location line="+22"/> <source>An optional amount to request. Leave this empty or zero to not request a specific amount.</source> <translation type="unfinished"/> </message> <message> <location line="+32"/> <source>Clear all fields of the form.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Clear</source> <translation type="unfinished"/> </message> <message> <location line="+78"/> <source>Requested payments history</source> <translation type="unfinished"/> </message> <message> <location line="-98"/> <source>&amp;Request payment</source> <translation type="unfinished"/> </message> <message> <location line="+120"/> <source>Show the selected request (does the same as double clicking an entry)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Show</source> <translation type="unfinished"/> </message> <message> <location line="+11"/> <source>Remove the selected entries from the list</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Remove</source> <translation type="unfinished"/> </message> <message> <location filename="../receivecoinsdialog.cpp" line="+38"/> <source>Copy label</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy message</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy amount</source> <translation type="unfinished"/> </message> </context> <context> <name>ReceiveRequestDialog</name> <message> <location filename="../forms/receiverequestdialog.ui" line="+29"/> <source>QR Code</source> <translation type="unfinished"/> </message> <message> <location line="+46"/> <source>Copy &amp;URI</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Copy &amp;Address</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>&amp;Save Image...</source> <translation type="unfinished"/> </message> <message> <location filename="../receiverequestdialog.cpp" line="+56"/> <source>Request payment to %1</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Payment information</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>URI</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Address</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Amount</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Label</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Message</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>Resulting URI too long, try to reduce the text for label / message.</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Error encoding URI into QR Code.</source> <translation type="unfinished"/> </message> </context> <context> <name>RecentRequestsTableModel</name> <message> <location filename="../recentrequeststablemodel.cpp" line="+24"/> <source>Date</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>Label</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>Message</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>Amount</source> <translation type="unfinished"/> </message> <message> <location line="+38"/> <source>(no label)</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>(no message)</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>(no amount)</source> <translation type="unfinished"/> </message> </context> <context> <name>SendCoinsDialog</name> <message> <location filename="../forms/sendcoinsdialog.ui" line="+14"/> <location filename="../sendcoinsdialog.cpp" line="+380"/> <location line="+80"/> <source>Send Coins</source> <translation type="unfinished"/> </message> <message> <location line="+76"/> <source>Coin Control Features</source> <translation type="unfinished"/> </message> <message> <location line="+20"/> <source>Inputs...</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>automatically selected</source> <translation type="unfinished"/> </message> <message> <location line="+19"/> <source>Insufficient funds!</source> <translation type="unfinished"/> </message> <message> <location line="+89"/> <source>Quantity:</source> <translation type="unfinished"/> </message> <message> <location line="+35"/> <source>Bytes:</source> <translation type="unfinished"/> </message> <message> <location line="+48"/> <source>Amount:</source> <translation type="unfinished"/> </message> <message> <location line="+32"/> <source>Priority:</source> <translation type="unfinished"/> </message> <message> <location line="+48"/> <source>Fee:</source> <translation type="unfinished"/> </message> <message> <location line="+32"/> <source>Low Output:</source> <translation type="unfinished"/> </message> <message> <location line="+48"/> <source>After Fee:</source> <translation type="unfinished"/> </message> <message> <location line="+32"/> <source>Change:</source> <translation type="unfinished"/> </message> <message> <location line="+44"/> <source>If this is activated, but the change address is empty or invalid, change will be sent to a newly generated address.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Custom change address</source> <translation type="unfinished"/> </message> <message> <location line="+164"/> <source>Send to multiple recipients at once</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Add &amp;Recipient</source> <translation type="unfinished"/> </message> <message> <location line="-23"/> <source>Clear all fields of the form.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Clear &amp;All</source> <translation type="unfinished"/> </message> <message> <location line="+52"/> <source>Balance:</source> <translation type="unfinished"/> </message> <message> <location line="-78"/> <source>Confirm the send action</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>S&amp;end</source> <translation type="unfinished"/> </message> <message> <location filename="../sendcoinsdialog.cpp" line="-229"/> <source>Confirm send coins</source> <translation type="unfinished"/> </message> <message> <location line="-74"/> <location line="+5"/> <location line="+5"/> <location line="+4"/> <source>%1 to %2</source> <translation type="unfinished"/> </message> <message> <location line="-121"/> <source>Copy quantity</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy amount</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy fee</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy after fee</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy bytes</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy priority</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy low output</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy change</source> <translation type="unfinished"/> </message> <message> <location line="+170"/> <source>Total Amount %1 (= %2)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>or</source> <translation type="unfinished"/> </message> <message> <location line="+203"/> <source>The recipient address is not valid, please recheck.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>The amount to pay must be larger than 0.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>The amount exceeds your balance.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>The total exceeds your balance when the %1 transaction fee is included.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Duplicate address found, can only send to each address once per send operation.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Transaction creation failed!</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>The transaction was rejected! This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here.</source> <translation type="unfinished"/> </message> <message> <location line="+113"/> <source>Warning: Invalid NSAcoin address</source> <translation type="unfinished"/> </message> <message> <location line="+20"/> <source>(no label)</source> <translation type="unfinished"/> </message> <message> <location line="-11"/> <source>Warning: Unknown change address</source> <translation type="unfinished"/> </message> <message> <location line="-367"/> <source>Are you sure you want to send?</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>added as transaction fee</source> <translation type="unfinished"/> </message> <message> <location line="+171"/> <source>Payment request expired</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>Invalid payment address %1</source> <translation type="unfinished"/> </message> </context> <context> <name>SendCoinsEntry</name> <message> <location filename="../forms/sendcoinsentry.ui" line="+131"/> <location line="+521"/> <location line="+536"/> <source>A&amp;mount:</source> <translation type="unfinished"/> </message> <message> <location line="-1152"/> <source>Pay &amp;To:</source> <translation type="unfinished"/> </message> <message> <location line="+18"/> <source>The address to send the payment to (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> <translation type="unfinished"/> </message> <message> <location filename="../sendcoinsentry.cpp" line="+30"/> <source>Enter a label for this address to add it to your address book</source> <translation type="unfinished"/> </message> <message> <location filename="../forms/sendcoinsentry.ui" line="+57"/> <source>&amp;Label:</source> <translation type="unfinished"/> </message> <message> <location line="-50"/> <source>Choose previously used address</source> <translation type="unfinished"/> </message> <message> <location line="-40"/> <source>This is a normal payment.</source> <translation type="unfinished"/> </message> <message> <location line="+50"/> <source>Alt+A</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Paste address from clipboard</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>Alt+P</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <location line="+524"/> <location line="+536"/> <source>Remove this entry</source> <translation type="unfinished"/> </message> <message> <location line="-1008"/> <source>Message:</source> <translation type="unfinished"/> </message> <message> <location line="+968"/> <source>This is a verified payment request.</source> <translation type="unfinished"/> </message> <message> <location line="-991"/> <source>Enter a label for this address to add it to the list of used addresses</source> <translation type="unfinished"/> </message> <message> <location line="+33"/> <source>A message that was attached to the bitcoin: URI which will be stored with the transaction for your reference. Note: This message will not be sent over the NSAcoin network.</source> <translation type="unfinished"/> </message> <message> <location line="+426"/> <source>This is an unverified payment request.</source> <translation type="unfinished"/> </message> <message> <location line="+18"/> <location line="+532"/> <source>Pay To:</source> <translation type="unfinished"/> </message> <message> <location line="-498"/> <location line="+536"/> <source>Memo:</source> <translation type="unfinished"/> </message> </context> <context> <name>ShutdownWindow</name> <message> <location filename="../utilitydialog.cpp" line="+48"/> <source>NSAcoin Core is shutting down...</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Do not shut down the computer until this window disappears.</source> <translation type="unfinished"/> </message> </context> <context> <name>SignVerifyMessageDialog</name> <message> <location filename="../forms/signverifymessagedialog.ui" line="+14"/> <source>Signatures - Sign / Verify a Message</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>&amp;Sign Message</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>You can sign messages with your addresses to prove you own them. Be careful not to sign anything vague, as phishing attacks may try to trick you into signing your identity over to them. Only sign fully-detailed statements you agree to.</source> <translation type="unfinished"/> </message> <message> <location line="+18"/> <source>The address to sign the message with (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <location line="+210"/> <source>Choose previously used address</source> <translation type="unfinished"/> </message> <message> <location line="-200"/> <location line="+210"/> <source>Alt+A</source> <translation type="unfinished"/> </message> <message> <location line="-200"/> <source>Paste address from clipboard</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>Alt+P</source> <translation type="unfinished"/> </message> <message> <location line="+12"/> <source>Enter the message you want to sign here</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Signature</source> <translation type="unfinished"/> </message> <message> <location line="+27"/> <source>Copy the current signature to the system clipboard</source> <translation type="unfinished"/> </message> <message> <location line="+21"/> <source>Sign the message to prove you own this NSAcoin address</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Sign &amp;Message</source> <translation type="unfinished"/> </message> <message> <location line="+14"/> <source>Reset all sign message fields</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <location line="+143"/> <source>Clear &amp;All</source> <translation type="unfinished"/> </message> <message> <location line="-84"/> <source>&amp;Verify Message</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Enter the signing address, message (ensure you copy line breaks, spaces, tabs, etc. exactly) and signature below to verify the message. Be careful not to read more into the signature than what is in the signed message itself, to avoid being tricked by a man-in-the-middle attack.</source> <translation type="unfinished"/> </message> <message> <location line="+21"/> <source>The address the message was signed with (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> <translation type="unfinished"/> </message> <message> <location line="+37"/> <source>Verify the message to ensure it was signed with the specified NSAcoin address</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Verify &amp;Message</source> <translation type="unfinished"/> </message> <message> <location line="+14"/> <source>Reset all verify message fields</source> <translation type="unfinished"/> </message> <message> <location filename="../signverifymessagedialog.cpp" line="+30"/> <source>Enter a NSAcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> <translation type="unfinished"/> </message> <message> <location line="-1"/> <source>Click &quot;Sign Message&quot; to generate signature</source> <translation type="unfinished"/> </message> <message> <location line="+84"/> <location line="+80"/> <source>The entered address is invalid.</source> <translation type="unfinished"/> </message> <message> <location line="-80"/> <location line="+8"/> <location line="+72"/> <location line="+8"/> <source>Please check the address and try again.</source> <translation type="unfinished"/> </message> <message> <location line="-80"/> <location line="+80"/> <source>The entered address does not refer to a key.</source> <translation type="unfinished"/> </message> <message> <location line="-72"/> <source>Wallet unlock was cancelled.</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>Private key for the entered address is not available.</source> <translation type="unfinished"/> </message> <message> <location line="+12"/> <source>Message signing failed.</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Message signed.</source> <translation type="unfinished"/> </message> <message> <location line="+58"/> <source>The signature could not be decoded.</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <location line="+13"/> <source>Please check the signature and try again.</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>The signature did not match the message digest.</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Message verification failed.</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Message verified.</source> <translation type="unfinished"/> </message> </context> <context> <name>SplashScreen</name> <message> <location filename="../splashscreen.cpp" line="+28"/> <source>NSAcoin Core</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>The NSAcoin Core developers</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>[testnet]</source> <translation type="unfinished"/> </message> </context> <context> <name>TrafficGraphWidget</name> <message> <location filename="../trafficgraphwidget.cpp" line="+79"/> <source>KB/s</source> <translation type="unfinished"/> </message> </context> <context> <name>TransactionDesc</name> <message> <location filename="../transactiondesc.cpp" line="+28"/> <source>Open until %1</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>%1/offline</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>%1/unconfirmed</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>%1 confirmations</source> <translation type="unfinished"/> </message> <message> <location line="+18"/> <source>Status</source> <translation type="unfinished"/> </message> <message numerus="yes"> <location line="+7"/> <source>, broadcast through %n node(s)</source> <translation type="unfinished"><numerusform></numerusform></translation> </message> <message> <location line="+4"/> <source>Date</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Source</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>Generated</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <location line="+17"/> <source>From</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <location line="+22"/> <location line="+58"/> <source>To</source> <translation type="unfinished"/> </message> <message> <location line="-77"/> <location line="+2"/> <source>own address</source> <translation type="unfinished"/> </message> <message> <location line="-2"/> <source>label</source> <translation type="unfinished"/> </message> <message> <location line="+37"/> <location line="+12"/> <location line="+45"/> <location line="+17"/> <location line="+53"/> <source>Credit</source> <translation type="unfinished"/> </message> <message numerus="yes"> <location line="-125"/> <source>matures in %n more block(s)</source> <translation type="unfinished"><numerusform></numerusform></translation> </message> <message> <location line="+2"/> <source>not accepted</source> <translation type="unfinished"/> </message> <message> <location line="+44"/> <location line="+8"/> <location line="+15"/> <location line="+53"/> <source>Debit</source> <translation type="unfinished"/> </message> <message> <location line="-62"/> <source>Transaction fee</source> <translation type="unfinished"/> </message> <message> <location line="+16"/> <source>Net amount</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <location line="+9"/> <source>Message</source> <translation type="unfinished"/> </message> <message> <location line="-7"/> <source>Comment</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Transaction ID</source> <translation type="unfinished"/> </message> <message> <location line="+18"/> <source>Merchant</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Generated coins must mature %1 blocks before they can be spent. When you generated this block, it was broadcast to the network to be added to the block chain. If it fails to get into the chain, its state will change to &quot;not accepted&quot; and it won&apos;t be spendable. This may occasionally happen if another node generates a block within a few seconds of yours.</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>Debug information</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>Transaction</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Inputs</source> <translation type="unfinished"/> </message> <message> <location line="+23"/> <source>Amount</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>true</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>false</source> <translation type="unfinished"/> </message> <message> <location line="-232"/> <source>, has not been successfully broadcast yet</source> <translation type="unfinished"/> </message> <message numerus="yes"> <location line="-35"/> <source>Open for %n more block(s)</source> <translation type="unfinished"><numerusform></numerusform></translation> </message> <message> <location line="+70"/> <source>unknown</source> <translation type="unfinished"/> </message> </context> <context> <name>TransactionDescDialog</name> <message> <location filename="../forms/transactiondescdialog.ui" line="+14"/> <source>Transaction details</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>This pane shows a detailed description of the transaction</source> <translation type="unfinished"/> </message> </context> <context> <name>TransactionTableModel</name> <message> <location filename="../transactiontablemodel.cpp" line="+234"/> <source>Date</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>Type</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>Address</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>Amount</source> <translation type="unfinished"/> </message> <message> <location line="+59"/> <source>Immature (%1 confirmations, will be available after %2)</source> <translation type="unfinished"/> </message> <message numerus="yes"> <location line="+16"/> <source>Open for %n more block(s)</source> <translation type="unfinished"><numerusform></numerusform></translation> </message> <message> <location line="+3"/> <source>Open until %1</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Offline (%1 confirmations)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Unconfirmed (%1 of %2 confirmations)</source> <translation type="unfinished"/> </message> <message> <location line="-22"/> <location line="+25"/> <source>Confirmed (%1 confirmations)</source> <translation type="unfinished"/> </message> <message> <location line="-22"/> <source>This block was not received by any other nodes and will probably not be accepted!</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Generated but not accepted</source> <translation type="unfinished"/> </message> <message> <location line="+62"/> <source>Received with</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Received from</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Sent to</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Payment to yourself</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Mined</source> <translation type="unfinished"/> </message> <message> <location line="+38"/> <source>(n/a)</source> <translation type="unfinished"/> </message> <message> <location line="+199"/> <source>Transaction status. Hover over this field to show number of confirmations.</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Date and time that the transaction was received.</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Type of transaction.</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Destination address of transaction.</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Amount removed from or added to balance.</source> <translation type="unfinished"/> </message> </context> <context> <name>TransactionView</name> <message> <location filename="../transactionview.cpp" line="+57"/> <location line="+16"/> <source>All</source> <translation type="unfinished"/> </message> <message> <location line="-15"/> <source>Today</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>This week</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>This month</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Last month</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>This year</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Range...</source> <translation type="unfinished"/> </message> <message> <location line="+11"/> <source>Received with</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Sent to</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>To yourself</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Mined</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Other</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Enter address or label to search</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Min amount</source> <translation type="unfinished"/> </message> <message> <location line="+34"/> <source>Copy address</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy label</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy amount</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Copy transaction ID</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Edit label</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Show transaction details</source> <translation type="unfinished"/> </message> <message> <location line="+142"/> <source>Export Transaction History</source> <translation type="unfinished"/> </message> <message> <location line="+19"/> <source>Exporting Failed</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>There was an error trying to save the transaction history to %1.</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Exporting Successful</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>The transaction history was successfully saved to %1.</source> <translation type="unfinished"/> </message> <message> <location line="-22"/> <source>Comma separated file (*.csv)</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>Confirmed</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Date</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Type</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Label</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Address</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Amount</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>ID</source> <translation type="unfinished"/> </message> <message> <location line="+107"/> <source>Range:</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>to</source> <translation type="unfinished"/> </message> </context> <context> <name>WalletFrame</name> <message> <location filename="../walletframe.cpp" line="+26"/> <source>No wallet has been loaded.</source> <translation type="unfinished"/> </message> </context> <context> <name>WalletModel</name> <message> <location filename="../walletmodel.cpp" line="+245"/> <source>Send Coins</source> <translation type="unfinished"/> </message> </context> <context> <name>WalletView</name> <message> <location filename="../walletview.cpp" line="+43"/> <source>&amp;Export</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Export the data in the current tab to a file</source> <translation type="unfinished"/> </message> <message> <location line="+181"/> <source>Backup Wallet</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Wallet Data (*.dat)</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Backup Failed</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>There was an error trying to save the wallet data to %1.</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>The wallet data was successfully saved to %1.</source> <translation type="unfinished"/> </message> <message> <location line="+0"/> <source>Backup Successful</source> <translation type="unfinished"/> </message> </context> <context> <name>bitcoin-core</name> <message> <location filename="../bitcoinstrings.cpp" line="+221"/> <source>Usage:</source> <translation type="unfinished"/> </message> <message> <location line="-54"/> <source>List commands</source> <translation type="unfinished"/> </message> <message> <location line="-14"/> <source>Get help for a command</source> <translation type="unfinished"/> </message> <message> <location line="+26"/> <source>Options:</source> <translation type="unfinished"/> </message> <message> <location line="+22"/> <source>Specify configuration file (default: bitcoin.conf)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Specify pid file (default: bitcoind.pid)</source> <translation type="unfinished"/> </message> <message> <location line="-1"/> <source>Specify data directory</source> <translation type="unfinished"/> </message> <message> <location line="-9"/> <source>Set database cache size in megabytes (default: 25)</source> <translation type="unfinished"/> </message> <message> <location line="-26"/> <source>Listen for connections on &lt;port&gt; (default: 8333 or testnet: 18333)</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Maintain at most &lt;n&gt; connections to peers (default: 125)</source> <translation type="unfinished"/> </message> <message> <location line="-51"/> <source>Connect to a node to retrieve peer addresses, and disconnect</source> <translation type="unfinished"/> </message> <message> <location line="+84"/> <source>Specify your own public address</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Threshold for disconnecting misbehaving peers (default: 100)</source> <translation type="unfinished"/> </message> <message> <location line="-148"/> <source>Number of seconds to keep misbehaving peers from reconnecting (default: 86400)</source> <translation type="unfinished"/> </message> <message> <location line="-36"/> <source>An error occurred while setting up the RPC port %u for listening on IPv4: %s</source> <translation type="unfinished"/> </message> <message> <location line="+34"/> <source>Listen for JSON-RPC connections on &lt;port&gt; (default: 8332 or testnet: 18332)</source> <translation type="unfinished"/> </message> <message> <location line="+45"/> <source>Accept command line and JSON-RPC commands</source> <translation type="unfinished"/> </message> <message> <location line="+80"/> <source>Run in the background as a daemon and accept commands</source> <translation type="unfinished"/> </message> <message> <location line="+39"/> <source>Use the test network</source> <translation type="unfinished"/> </message> <message> <location line="-118"/> <source>Accept connections from outside (default: 1 if no -proxy or -connect)</source> <translation type="unfinished"/> </message> <message> <location line="-95"/> <source>%s, you must set a rpcpassword in the configuration file: %s It is recommended you use the following random password: rpcuser=bitcoinrpc rpcpassword=%s (you do not need to remember this password) The username and password MUST NOT be the same. If the file does not exist, create it with owner-readable-only file permissions. It is also recommended to set alertnotify so you are notified of problems; for example: alertnotify=echo %%s | mail -s &quot;NSAcoin Alert&quot; admin@foo.com </source> <translation type="unfinished"/> </message> <message> <location line="+12"/> <source>Acceptable ciphers (default: TLSv1.2+HIGH:TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!3DES:@STRENGTH)</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>An error occurred while setting up the RPC port %u for listening on IPv6, falling back to IPv4: %s</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Bind to given address and always listen on it. Use [host]:port notation for IPv6</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Cannot obtain a lock on data directory %s. NSAcoin is probably already running.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Enter regression test mode, which uses a special chain in which blocks can be solved instantly. This is intended for regression testing tools and app development.</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Enter regression test mode, which uses a special chain in which blocks can be solved instantly.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Error: The transaction was rejected! This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here.</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds!</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Execute command when a wallet transaction changes (%s in cmd is replaced by TxID)</source> <translation type="unfinished"/> </message> <message> <location line="+18"/> <source>This is a pre-release test build - use at your own risk - do not use for mining or merchant applications</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Use separate SOCKS5 proxy to reach peers via Tor hidden services (default: -proxy)</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Warning: -paytxfee is set very high! This is the transaction fee you will pay if you send a transaction.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Warning: Please check that your computer&apos;s date and time are correct! If your clock is wrong NSAcoin will not work properly.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Warning: The network does not appear to fully agree! Some miners appear to be experiencing issues.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Warning: We do not appear to fully agree with our peers! You may need to upgrade, or other nodes may need to upgrade.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Warning: error reading wallet.dat! All keys read correctly, but transaction data or address book entries might be missing or incorrect.</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Warning: wallet.dat corrupt, data salvaged! Original wallet.dat saved as wallet.{timestamp}.bak in %s; if your balance or transactions are incorrect you should restore from a backup.</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>&lt;category&gt; can be:</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Attempt to recover private keys from a corrupt wallet.dat</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>NSAcoin Core Daemon</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>NSAcoin RPC client version</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Block creation options:</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Connect only to the specified node(s)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Connect through SOCKS proxy</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Connect to JSON-RPC on &lt;port&gt; (default: 8332 or testnet: 18332)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Corrupted block database detected</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Discover own IP address (default: 1 when listening and no -externalip)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Do not load the wallet and disable wallet RPC calls</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Do you want to rebuild the block database now?</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Error initializing block database</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Error initializing wallet database environment %s!</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Error loading block database</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Error opening block database</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Error: Disk space is low!</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Error: Wallet locked, unable to create transaction!</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Error: system error: </source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Failed to listen on any port. Use -listen=0 if you want this.</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Failed to read block info</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Failed to read block</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Failed to sync block index</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Failed to write block index</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Failed to write block info</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Failed to write block</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Failed to write file info</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Failed to write to coin database</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Failed to write transaction index</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Failed to write undo data</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Fee per kB to add to transactions you send</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Find peers using DNS lookup (default: 1 unless -connect)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Generate coins (default: 0)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>How many blocks to check at startup (default: 288, 0 = all)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>How thorough the block verification is (0-4, default: 3)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>If &lt;category&gt; is not supplied, output all debugging information.</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Incorrect or no genesis block found. Wrong datadir for network?</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Invalid -onion address: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="+15"/> <source>Not enough file descriptors available.</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Prepend debug output with timestamp (default: 1)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>RPC client options:</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Rebuild block chain index from current blk000??.dat files</source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Select SOCKS version for -proxy (4 or 5, default: 5)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Send command to NSAcoin server</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Set maximum block size in bytes (default: %d)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Set the number of threads to service RPC calls (default: 4)</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Specify wallet file (within data directory)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Start NSAcoin server</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>This is intended for regression testing tools and app development.</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>Usage (deprecated, use bitcoin-cli):</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Verifying blocks...</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Verifying wallet...</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Wait for RPC server to start</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Wallet %s resides outside data directory %s</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Wallet options:</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Warning: Deprecated argument -debugnet ignored, use -debug=net</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>You need to rebuild the database using -reindex to change -txindex</source> <translation type="unfinished"/> </message> <message> <location line="-79"/> <source>Imports blocks from external blk000??.dat file</source> <translation type="unfinished"/> </message> <message> <location line="-105"/> <source>Execute command when a relevant alert is received or we see a really long fork (%s in cmd is replaced by message)</source> <translation type="unfinished"/> </message> <message> <location line="+14"/> <source>Output debugging information (default: 0, supplying &lt;category&gt; is optional)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Set maximum size of high-priority/low-fee transactions in bytes (default: %d)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Set the number of script verification threads (up to 16, 0 = auto, &lt;0 = leave that many cores free, default: 0)</source> <translation type="unfinished"/> </message> <message> <location line="+89"/> <source>Information</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Invalid amount for -minrelaytxfee=&lt;amount&gt;: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Invalid amount for -mintxfee=&lt;amount&gt;: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>Maintain a full transaction index (default: 0)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Maximum per-connection receive buffer, &lt;n&gt;*1000 bytes (default: 5000)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Maximum per-connection send buffer, &lt;n&gt;*1000 bytes (default: 1000)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Only accept block chain matching built-in checkpoints (default: 1)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Only connect to nodes in network &lt;net&gt; (IPv4, IPv6 or Tor)</source> <translation type="unfinished"/> </message> <message> <location line="+9"/> <source>SSL options: (see the NSAcoin Wiki for SSL setup instructions)</source> <translation type="unfinished"/> </message> <message> <location line="+4"/> <source>Send trace/debug info to console instead of debug.log file</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>Set minimum block size in bytes (default: 0)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Shrink debug.log file on client startup (default: 1 when no -debug)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Signing transaction failed</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Specify connection timeout in milliseconds (default: 5000)</source> <translation type="unfinished"/> </message> <message> <location line="+6"/> <source>System error: </source> <translation type="unfinished"/> </message> <message> <location line="+5"/> <source>Transaction amount too small</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Transaction amounts must be positive</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Transaction too large</source> <translation type="unfinished"/> </message> <message> <location line="+8"/> <source>Use UPnP to map the listening port (default: 0)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Use UPnP to map the listening port (default: 1 when listening)</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Username for JSON-RPC connections</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Warning</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>Warning: This version is obsolete, upgrade required!</source> <translation type="unfinished"/> </message> <message> <location line="+2"/> <source>version</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>wallet.dat corrupt, salvage failed</source> <translation type="unfinished"/> </message> <message> <location line="-58"/> <source>Password for JSON-RPC connections</source> <translation type="unfinished"/> </message> <message> <location line="-70"/> <source>Allow JSON-RPC connections from specified IP address</source> <translation type="unfinished"/> </message> <message> <location line="+80"/> <source>Send commands to node running on &lt;ip&gt; (default: 127.0.0.1)</source> <translation type="unfinished"/> </message> <message> <location line="-132"/> <source>Execute command when the best block changes (%s in cmd is replaced by block hash)</source> <translation type="unfinished"/> </message> <message> <location line="+161"/> <source>Upgrade wallet to latest format</source> <translation type="unfinished"/> </message> <message> <location line="-24"/> <source>Set key pool size to &lt;n&gt; (default: 100)</source> <translation type="unfinished"/> </message> <message> <location line="-11"/> <source>Rescan the block chain for missing wallet transactions</source> <translation type="unfinished"/> </message> <message> <location line="+38"/> <source>Use OpenSSL (https) for JSON-RPC connections</source> <translation type="unfinished"/> </message> <message> <location line="-30"/> <source>Server certificate file (default: server.cert)</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Server private key (default: server.pem)</source> <translation type="unfinished"/> </message> <message> <location line="+16"/> <source>This help message</source> <translation type="unfinished"/> </message> <message> <location line="+7"/> <source>Unable to bind to %s on this computer (bind returned error %d, %s)</source> <translation type="unfinished"/> </message> <message> <location line="-107"/> <source>Allow DNS lookups for -addnode, -seednode and -connect</source> <translation type="unfinished"/> </message> <message> <location line="+60"/> <source>Loading addresses...</source> <translation type="unfinished"/> </message> <message> <location line="-37"/> <source>Error loading wallet.dat: Wallet corrupted</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Error loading wallet.dat: Wallet requires newer version of NSAcoin</source> <translation type="unfinished"/> </message> <message> <location line="+98"/> <source>Wallet needed to be rewritten: restart NSAcoin to complete</source> <translation type="unfinished"/> </message> <message> <location line="-100"/> <source>Error loading wallet.dat</source> <translation type="unfinished"/> </message> <message> <location line="+31"/> <source>Invalid -proxy address: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="+56"/> <source>Unknown network specified in -onlynet: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="-1"/> <source>Unknown -socks proxy version requested: %i</source> <translation type="unfinished"/> </message> <message> <location line="-101"/> <source>Cannot resolve -bind address: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Cannot resolve -externalip address: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="+48"/> <source>Invalid amount for -paytxfee=&lt;amount&gt;: &apos;%s&apos;</source> <translation type="unfinished"/> </message> <message> <location line="+1"/> <source>Invalid amount</source> <translation type="unfinished"/> </message> <message> <location line="-6"/> <source>Insufficient funds</source> <translation type="unfinished"/> </message> <message> <location line="+10"/> <source>Loading block index...</source> <translation type="unfinished"/> </message> <message> <location line="-62"/> <source>Add a node to connect to and attempt to keep the connection open</source> <translation type="unfinished"/> </message> <message> <location line="-32"/> <source>Unable to bind to %s on this computer. NSAcoin is probably already running.</source> <translation type="unfinished"/> </message> <message> <location line="+95"/> <source>Loading wallet...</source> <translation type="unfinished"/> </message> <message> <location line="-56"/> <source>Cannot downgrade wallet</source> <translation type="unfinished"/> </message> <message> <location line="+3"/> <source>Cannot write default address</source> <translation type="unfinished"/> </message> <message> <location line="+67"/> <source>Rescanning...</source> <translation type="unfinished"/> </message> <message> <location line="-58"/> <source>Done loading</source> <translation type="unfinished"/> </message> <message> <location line="+85"/> <source>To use the %s option</source> <translation type="unfinished"/> </message> <message> <location line="-77"/> <source>Error</source> <translation type="unfinished"/> </message> <message> <location line="-35"/> <source>You must set rpcpassword=&lt;password&gt; in the configuration file: %s If the file does not exist, create it with owner-readable-only file permissions.</source> <translation type="unfinished"/> </message> </context> </TS>
nsacoin/nsacoin
src/qt/locale/bitcoin_sah.ts
TypeScript
mit
130,888
package ru.sendto.gwt.client.html; public class Th extends WidgetBase { public Th() { super("th"); } public void setRowspan(String rows){ getElement().setAttribute("rowspan", rows); } public void setColspan(String cols){ getElement().setAttribute("colspan", cols); } }
nleva/gwthtml
HtmlGwt/src/main/java/ru/sendto/gwt/client/html/Th.java
Java
mit
287
using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; // General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information // associated with an assembly. [assembly: AssemblyTitle("Pascal Triangle")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("Hewlett-Packard")] [assembly: AssemblyProduct("Pascal Triangle")] [assembly: AssemblyCopyright("Copyright © Hewlett-Packard 2018")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] // Setting ComVisible to false makes the types in this assembly not visible // to COM components. If you need to access a type in this assembly from // COM, set the ComVisible attribute to true on that type. [assembly: ComVisible(false)] // The following GUID is for the ID of the typelib if this project is exposed to COM [assembly: Guid("7b737ca9-278b-4b45-89ae-e695395f1b17")] // Version information for an assembly consists of the following four values: // // Major Version // Minor Version // Build Number // Revision // // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyVersion("1.0.0.0")] [assembly: AssemblyFileVersion("1.0.0.0")]
spiderbait90/Step-By-Step-In-Coding
C# Fundamentals/C# Advanced/Multidimensional Arrays/Pascal Triangle/Properties/AssemblyInfo.cs
C#
mit
1,431
function airPollution(sofiaMap, forces) { for (let i = 0; i < sofiaMap.length; i++) { sofiaMap[i] = sofiaMap[i].split(' ').map(Number) } for (let i = 0; i < forces.length; i++) { forces[i] = forces[i].split(' ') } for (let i = 0; i < forces.length; i++) { for (let k = 0; k < sofiaMap.length; k++) { for (let l = 0; l < sofiaMap[k].length; l++) { if (forces[i][0] === 'breeze') { if (Number(forces[i][1]) === k) { sofiaMap[k][l] = sofiaMap[k][l] - 15 if (sofiaMap[k][l] < 0) { sofiaMap[k][l] = 0 } } } else if (forces[i][0] === 'gale') { if (Number(forces[i][1]) === l) { sofiaMap[k][l] = sofiaMap[k][l] - 20 if (sofiaMap[k][l] < 0) { sofiaMap[k][l] = 0 } } } else if (forces[i][0] === 'smog') { sofiaMap[k][l] = sofiaMap[k][l] + Number(forces[i][1]) } } } } let isPolluted = false let result = [] let k = 0 for (let i = 0; i < sofiaMap.length; i++) { for (let j = 0; j < sofiaMap[i].length; j++) { if (sofiaMap[i][j] >= 50) { if (!isPolluted) { isPolluted = true } result[k++] = `[${i}-${j}]` } } } if (!isPolluted) { console.log('No polluted areas') } else { console.log('Polluted areas: ' + result.join(', ')) } } airPollution([ "5 7 72 14 4", "41 35 37 27 33", "23 16 27 42 12", "2 20 28 39 14", "16 34 31 10 24", ], ["breeze 1", "gale 2", "smog 25"]) // Polluted areas: [0-2], [1-0], [2-3], [3-3], [4-1]
b0jko3/SoftUni
JavaScript/Core/Fundamentals/Exams/11_Feb_2018/02._Air_Pollution.js
JavaScript
mit
1,937
using System; using System.ComponentModel; using System.Drawing; using System.Drawing.Drawing2D; using System.Windows.Forms; public class GradientPanel : Panel { public Color GradientFirstColor = Color.FromArgb(33, 33, 33); public Color GradientSecondColor = Color.FromArgb(22, 22, 22); public GradientPanel() { this.ResizeRedraw = true; } protected override void OnPaintBackground(PaintEventArgs e) { if (ClientRectangle.Width == 0 || ClientRectangle.Height == 0) return; using (var brush = new LinearGradientBrush(ClientRectangle, GradientFirstColor, GradientSecondColor, LinearGradientMode.Vertical)) { e.Graphics.FillRectangle(brush, this.ClientRectangle); } } protected override void OnScroll(ScrollEventArgs se) { this.Invalidate(); base.OnScroll(se); } }
mikadev001/SublimeText-Overlay
SublimeOverlay/GradientPanel.cs
C#
mit
908
// Copyright (c) Microsoft Corporation. All rights reserved. // Licensed under the MIT License. package com.azure.data.tables.models; import com.azure.core.annotation.Fluent; /** * A model representing configurable metrics settings of the Table service. */ @Fluent public final class TableServiceMetrics { /* * The version of Analytics to configure. */ private String version; /* * Indicates whether metrics are enabled for the Table service. */ private boolean enabled; /* * Indicates whether metrics should generate summary statistics for called API operations. */ private Boolean includeApis; /* * The retention policy. */ private TableServiceRetentionPolicy retentionPolicy; /** * Get the version of Analytics to configure. * * @return The {@code version}. */ public String getVersion() { return this.version; } /** * Set the version of Analytics to configure. * * @param version The {@code version} to set. * * @return The updated {@link TableServiceMetrics} object. */ public TableServiceMetrics setVersion(String version) { this.version = version; return this; } /** * Get a value that indicates whether metrics are enabled for the Table service. * * @return The {@code enabled} value. */ public boolean isEnabled() { return this.enabled; } /** * Set a value that indicates whether metrics are enabled for the Table service. * * @param enabled The {@code enabled} value to set. * * @return The updated {@link TableServiceMetrics} object. */ public TableServiceMetrics setEnabled(boolean enabled) { this.enabled = enabled; return this; } /** * Get a value that indicates whether metrics should generate summary statistics for called API operations. * * @return The {@code includeApis} value. */ public Boolean isIncludeApis() { return this.includeApis; } /** * Set a value that indicates whether metrics should generate summary statistics for called API operations. * * @param includeApis The {@code includeApis} value to set. * * @return The updated {@link TableServiceMetrics} object. */ public TableServiceMetrics setIncludeApis(Boolean includeApis) { this.includeApis = includeApis; return this; } /** * Get the {@link TableServiceRetentionPolicy} for these metrics on the Table service. * * @return The {@link TableServiceRetentionPolicy}. */ public TableServiceRetentionPolicy getTableServiceRetentionPolicy() { return this.retentionPolicy; } /** * Set the {@link TableServiceRetentionPolicy} for these metrics on the Table service. * * @param retentionPolicy The {@link TableServiceRetentionPolicy} to set. * * @return The updated {@link TableServiceMetrics} object. */ public TableServiceMetrics setRetentionPolicy(TableServiceRetentionPolicy retentionPolicy) { this.retentionPolicy = retentionPolicy; return this; } }
Azure/azure-sdk-for-java
sdk/tables/azure-data-tables/src/main/java/com/azure/data/tables/models/TableServiceMetrics.java
Java
mit
3,217
# frozen_string_literal: true module Eve class LocalPlanetsImporter def import Eve::Planet.pluck(:planet_id).each do |planet_id| Eve::UpdatePlanetJob.perform_later(planet_id) end end end end
biow0lf/evemonk
app/importers/eve/local_planets_importer.rb
Ruby
mit
224
package com.scut.picturelibrary.manager; import android.content.Context; import android.media.AudioManager; import android.media.MediaPlayer; import android.media.MediaPlayer.OnCompletionListener; import android.media.MediaPlayer.OnErrorListener; import android.media.MediaPlayer.OnPreparedListener; import android.view.SurfaceHolder; /** * 视频播放管理 * * @author cyc * */ public class VideoManager { private MediaPlayer mediaPlayer; public VideoManager(Context context) { super(); mediaPlayer = new MediaPlayer(); } // 返回MediaPlayer public MediaPlayer getMyMediaPlayer() { return mediaPlayer; } // 播放 public void play(String filePath, SurfaceHolder holder, OnPreparedListener mOnPreparedListener, OnCompletionListener mOnCompletionListener) { try { mediaPlayer.setAudioStreamType(AudioManager.STREAM_MUSIC); // 设置播放源 mediaPlayer.setDataSource(filePath); mediaPlayer.setDisplay(holder); mediaPlayer.prepareAsync(); mediaPlayer.setOnPreparedListener(mOnPreparedListener); mediaPlayer.setOnCompletionListener(mOnCompletionListener); mediaPlayer.setOnErrorListener(new OnErrorListener() { @Override public boolean onError(MediaPlayer arg0, int arg1, int arg2) { // 发生错误 return false; } }); } catch (Exception e) { e.printStackTrace(); } } // 时间显示函数 public String ShowTime(int time) { time /= 1000; int minute = time / 60; int second = time % 60; minute %= 60; return String.format("%02d:%02d", minute, second); } // 暂停 public void pause() { mediaPlayer.pause(); } }
inexistence/PictureLibrary
src/com/scut/picturelibrary/manager/VideoManager.java
Java
mit
1,631
using System; using System.Configuration; using System.Web; using Portal.Core.Content; namespace Portal.Web.Helpers { public static class CookieHelper { private static readonly HttpContext HttpContext; private static readonly string NameCookieContentType; private static readonly string NameCookieScreenWidth; private static readonly string NameCookieSorting; private static readonly string NameCookieSortingDescending; private static SortType? _sortType; private static ContentType? _contentType; private static bool? _isDescending; private static int? _screenWidth; static CookieHelper() { HttpContext = HttpContext.Current; NameCookieContentType = ConfigurationManager.AppSettings["NameCookieContentType"]; NameCookieScreenWidth = ConfigurationManager.AppSettings["NameCookieScreenWidth"]; switch (ContentType) { case ContentType.Books: NameCookieSorting = ConfigurationManager.AppSettings["NameCookieSortingBook"]; NameCookieSortingDescending = ConfigurationManager.AppSettings["NameCookieSortingBookDescending"]; break; case ContentType.Trainings: NameCookieSorting = ConfigurationManager.AppSettings["NameCookieSortingTraining"]; NameCookieSortingDescending = ConfigurationManager.AppSettings["NameCookieSortingTrainingDescending"]; break; default: throw new ArgumentOutOfRangeException(); } } public static SortType SortType { get { if (_sortType == null) { _sortType = GetCookie<SortType>(NameCookieSorting); } return _sortType.Value; } set { SetCookie(value, NameCookieSorting); _sortType = value; } } public static ContentType ContentType { get { if (_contentType == null) { _contentType = GetCookie<ContentType>(NameCookieContentType); } return _contentType.Value; } set { SetCookie(value, NameCookieContentType); _contentType = value; } } public static bool OrderIsDescending { get { if (_isDescending == null) { _isDescending = GetCookie<bool>(NameCookieSortingDescending); } return _isDescending.Value; } set { SetCookie(value, NameCookieSortingDescending); _isDescending = value; } } public static int ScreenWidth { get { if (_screenWidth == null || _screenWidth == 0) { _screenWidth = GetCookie<int>(NameCookieScreenWidth); } return _screenWidth.Value; } set { SetCookie(value, NameCookieScreenWidth); _screenWidth = value; } } private static T GetCookie<T>(string nameCookie) where T : struct { var type = typeof(T); var cookie = HttpContext.Request.Cookies[nameCookie]; if (string.IsNullOrEmpty(cookie?.Value)) { return default(T); } if (type.IsEnum) { return (T)Enum.Parse(type, cookie.Value); } if (type == typeof(int) || type == typeof(bool)) { var changeType = Convert.ChangeType(cookie.Value, type); if (changeType != null) { return (T)changeType; } } throw new ArgumentException(); } private static void SetCookie<T>(T value, string nameCookie) { var cookie = HttpContext.Request.Cookies[nameCookie]; if (cookie == null) { HttpContext.Response.Cookies.Add(new HttpCookie(nameCookie, value.ToString())); } else { cookie.Value = value.ToString(); HttpContext.Response.SetCookie(cookie); } } } }
EtwasGE/InformationPortal
Portal.Web/Helpers/CookieHelper.cs
C#
mit
4,698
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=9"/> <meta name="generator" content="Doxygen 1.8.11"/> <title>V8 API Reference Guide for node.js v6.4.0: Member List</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="dynsections.js"></script> <link href="search/search.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="search/searchdata.js"></script> <script type="text/javascript" src="search/search.js"></script> <script type="text/javascript"> $(document).ready(function() { init_search(); }); </script> <link href="doxygen.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td id="projectalign" style="padding-left: 0.5em;"> <div id="projectname">V8 API Reference Guide for node.js v6.4.0 </div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.8.11 --> <script type="text/javascript"> var searchBox = new SearchBox("searchBox", "search",false,'Search'); </script> <div id="navrow1" class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main&#160;Page</span></a></li> <li><a href="namespaces.html"><span>Namespaces</span></a></li> <li class="current"><a href="annotated.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> <li><a href="examples.html"><span>Examples</span></a></li> <li> <div id="MSearchBox" class="MSearchBoxInactive"> <span class="left"> <img id="MSearchSelect" src="search/mag_sel.png" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" alt=""/> <input type="text" id="MSearchField" value="Search" accesskey="S" onfocus="searchBox.OnSearchFieldFocus(true)" onblur="searchBox.OnSearchFieldFocus(false)" onkeyup="searchBox.OnSearchFieldChange(event)"/> </span><span class="right"> <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a> </span> </div> </li> </ul> </div> <div id="navrow2" class="tabs2"> <ul class="tablist"> <li><a href="annotated.html"><span>Class&#160;List</span></a></li> <li><a href="classes.html"><span>Class&#160;Index</span></a></li> <li><a href="inherits.html"><span>Class&#160;Hierarchy</span></a></li> <li><a href="functions.html"><span>Class&#160;Members</span></a></li> </ul> </div> <!-- window showing the filter options --> <div id="MSearchSelectWindow" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" onkeydown="return searchBox.OnSearchSelectKey(event)"> </div> <!-- iframe showing the search results (closed by default) --> <div id="MSearchResultsWindow"> <iframe src="javascript:void(0)" frameborder="0" name="MSearchResults" id="MSearchResults"> </iframe> </div> <div id="nav-path" class="navpath"> <ul> <li class="navelem"><a class="el" href="namespacev8.html">v8</a></li><li class="navelem"><a class="el" href="classv8_1_1Exception.html">Exception</a></li> </ul> </div> </div><!-- top --> <div class="header"> <div class="headertitle"> <div class="title">v8::Exception Member List</div> </div> </div><!--header--> <div class="contents"> <p>This is the complete list of members for <a class="el" href="classv8_1_1Exception.html">v8::Exception</a>, including all inherited members.</p> <table class="directory"> <tr class="even"><td class="entry"><a class="el" href="classv8_1_1Exception.html#a8d575a721cf0fd5b325afb8b586c0d1e">CreateMessage</a>(Isolate *isolate, Local&lt; Value &gt; exception)</td><td class="entry"><a class="el" href="classv8_1_1Exception.html">v8::Exception</a></td><td class="entry"><span class="mlabel">static</span></td></tr> <tr bgcolor="#f0f0f0"><td class="entry"><b>Error</b>(Local&lt; String &gt; message) (defined in <a class="el" href="classv8_1_1Exception.html">v8::Exception</a>)</td><td class="entry"><a class="el" href="classv8_1_1Exception.html">v8::Exception</a></td><td class="entry"><span class="mlabel">static</span></td></tr> <tr class="even"><td class="entry"><a class="el" href="classv8_1_1Exception.html#a81d1fd3c8d729e9a8d830bc2830bfe77">GetStackTrace</a>(Local&lt; Value &gt; exception)</td><td class="entry"><a class="el" href="classv8_1_1Exception.html">v8::Exception</a></td><td class="entry"><span class="mlabel">static</span></td></tr> <tr bgcolor="#f0f0f0"><td class="entry"><b>RangeError</b>(Local&lt; String &gt; message) (defined in <a class="el" href="classv8_1_1Exception.html">v8::Exception</a>)</td><td class="entry"><a class="el" href="classv8_1_1Exception.html">v8::Exception</a></td><td class="entry"><span class="mlabel">static</span></td></tr> <tr bgcolor="#f0f0f0" class="even"><td class="entry"><b>ReferenceError</b>(Local&lt; String &gt; message) (defined in <a class="el" href="classv8_1_1Exception.html">v8::Exception</a>)</td><td class="entry"><a class="el" href="classv8_1_1Exception.html">v8::Exception</a></td><td class="entry"><span class="mlabel">static</span></td></tr> <tr bgcolor="#f0f0f0"><td class="entry"><b>SyntaxError</b>(Local&lt; String &gt; message) (defined in <a class="el" href="classv8_1_1Exception.html">v8::Exception</a>)</td><td class="entry"><a class="el" href="classv8_1_1Exception.html">v8::Exception</a></td><td class="entry"><span class="mlabel">static</span></td></tr> <tr bgcolor="#f0f0f0" class="even"><td class="entry"><b>TypeError</b>(Local&lt; String &gt; message) (defined in <a class="el" href="classv8_1_1Exception.html">v8::Exception</a>)</td><td class="entry"><a class="el" href="classv8_1_1Exception.html">v8::Exception</a></td><td class="entry"><span class="mlabel">static</span></td></tr> <tr bgcolor="#f0f0f0"><td class="entry"><b>V8_DEPRECATED</b>(&quot;Use version with an Isolate*&quot;, static Local&lt; Message &gt; CreateMessage(Local&lt; Value &gt; exception)) (defined in <a class="el" href="classv8_1_1Exception.html">v8::Exception</a>)</td><td class="entry"><a class="el" href="classv8_1_1Exception.html">v8::Exception</a></td><td class="entry"></td></tr> </table></div><!-- contents --> <!-- start footer part --> <hr class="footer"/><address class="footer"><small> Generated by &#160;<a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/> </a> 1.8.11 </small></address> </body> </html>
v8-dox/v8-dox.github.io
e6887e2/html/classv8_1_1Exception-members.html
HTML
mit
7,064
class RequirementsController < ApplicationController before_filter :authenticate_user! before_filter :require_project_involvement before_filter :find_story def create @requirement = @story.pending_requirements.build(params[:requirement]) if @requirement.save flash[:notice] = 'Requirement added' else flash[:requirement] = @requirement end redirect_to [current_project, @story] end def destroy @requirement = @story.requirements.find(params[:id]) @requirement.destroy redirect_to [current_project, @story], notice: 'Requirement removed' end private def find_story @story = current_project.stories.find(params[:story_id]) end end
avdgaag/storyteller
app/controllers/requirements_controller.rb
Ruby
mit
701
<?php /** * * @author dev * @created 2015-09-17 10:57:04 */ namespace Application; use Application\Parse\TodoGrid; use Bluz; return /** * @return \closure */ function () use ($view) { $view->grid = new TodoGrid(); };
bashmach/bluz-skeleton-parse
application/modules/parse/controllers/grid.php
PHP
mit
231
//================================================================================================= /*! // \file blazemark/armadillo/Complex7.h // \brief Header file for the Armadillo kernel for the complex expression E = ( A + B ) * ( C - D ) // // Copyright (C) 2012-2020 Klaus Iglberger - All Rights Reserved // // This file is part of the Blaze library. You can redistribute it and/or modify it under // the terms of the New (Revised) BSD License. Redistribution and use in source and binary // forms, with or without modification, are permitted provided that the following conditions // are met: // // 1. Redistributions of source code must retain the above copyright notice, this list of // conditions and the following disclaimer. // 2. Redistributions in binary form must reproduce the above copyright notice, this list // of conditions and the following disclaimer in the documentation and/or other materials // provided with the distribution. // 3. Neither the names of the Blaze development group nor the names of its contributors // may be used to endorse or promote products derived from this software without specific // prior written permission. // // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY // EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES // OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT // SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED // TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR // BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN // CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH // DAMAGE. */ //================================================================================================= #ifndef _BLAZEMARK_ARMADILLO_COMPLEX7_H_ #define _BLAZEMARK_ARMADILLO_COMPLEX7_H_ //************************************************************************************************* // Includes //************************************************************************************************* #include <blazemark/system/Types.h> namespace blazemark { namespace armadillo { //================================================================================================= // // KERNEL FUNCTIONS // //================================================================================================= //************************************************************************************************* /*!\name Armadillo kernel functions */ //@{ double complex7( size_t N, size_t steps ); //@} //************************************************************************************************* } // namespace armadillo } // namespace blazemark #endif
camillescott/boink
include/goetia/sketches/sketch/vec/blaze/blazemark/blazemark/armadillo/Complex7.h
C
mit
3,055
#!/bin/sh # CYBERWATCH SAS - 2017 # # Security fix for RHSA-2016:1217 # # Security announcement date: 2016-06-08 17:06:49 UTC # Script generation date: 2017-01-25 21:23:43 UTC # # Operating System: Red Hat 5 # Architecture: x86_64 # # Vulnerable packages fix on version: # - firefox.i386:45.2.0-1.el5_11 # - firefox-debuginfo.i386:45.2.0-1.el5_11 # - firefox.x86_64:45.2.0-1.el5_11 # - firefox-debuginfo.x86_64:45.2.0-1.el5_11 # # Last versions recommanded by security team: # - firefox.i386:45.7.0-1.el5_11 # - firefox-debuginfo.i386:45.7.0-1.el5_11 # - firefox.x86_64:45.7.0-1.el5_11 # - firefox-debuginfo.x86_64:45.7.0-1.el5_11 # # CVE List: # - CVE-2016-2818 # - CVE-2016-2819 # - CVE-2016-2821 # - CVE-2016-2822 # - CVE-2016-2828 # - CVE-2016-2831 # # More details: # - https://www.cyberwatch.fr/vulnerabilites # # Licence: Released under The MIT License (MIT), See LICENSE FILE sudo yum install firefox.i386-45.7.0 -y sudo yum install firefox-debuginfo.i386-45.7.0 -y sudo yum install firefox.x86_64-45.7.0 -y sudo yum install firefox-debuginfo.x86_64-45.7.0 -y
Cyberwatch/cbw-security-fixes
Red_Hat_5/x86_64/2016/RHSA-2016:1217.sh
Shell
mit
1,106
require 'spec_helper' # Specs in this file have access to a helper object that includes # the ProductsHelper. For example: # # describe ProductsHelper do # describe "string concat" do # it "concats two strings with spaces" do # helper.concat_strings("this","that").should == "this that" # end # end # end describe ProductsHelper do end
LRDesign/mizugumo_demo
spec/helpers/products_helper_spec.rb
Ruby
mit
355
<?php namespace Anetwork\Validation; use Anetwork\Validation\ValidationMessages; /** * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since May 21, 2016 */ class ValidationRules { /** * @var boolean */ protected $status; /** * validate persian alphabet and space * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since May 21, 2016 * @return boolean */ public function Alpha($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match("/^[\x{600}-\x{6FF}\x{200c}\x{064b}\x{064d}\x{064c}\x{064e}\x{064f}\x{0650}\x{0651}\s]+$/u", $value); return $this->status ; } /** * validate persian number * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since May 21, 2016 * @return boolean */ public function Num($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match('/^[\x{6F0}-\x{6F9}]+$/u', $value); return $this->status ; } /** * validate persian alphabet, number and space * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since May 21, 2016 * @return boolean */ public function AlphaNum($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match('/^[\x{600}-\x{6FF}\x{200c}\x{064b}\x{064d}\x{064c}\x{064e}\x{064f}\x{0650}\x{0651}\s]+$/u', $value); return $this->status; } /** * validate mobile number * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since May 21, 2016 * @return boolean */ public function IranMobile($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); if ((bool) preg_match('/^(((98)|(\+98)|(0098)|0)(9){1}[0-9]{9})+$/', $value) || (bool) preg_match('/^(9){1}[0-9]{9}+$/', $value)) return true; return false; } /** * validate sheba number * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since May 21, 2016 * @return boolean */ public function Sheba($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $ibanReplaceValues = array(); if (!empty($value)) { $value = preg_replace('/[\W_]+/', '', strtoupper($value)); if (( 4 > strlen($value) || strlen($value) > 34 ) || ( is_numeric($value [ 0 ]) || is_numeric($value [ 1 ]) ) || ( ! is_numeric($value [ 2 ]) || ! is_numeric($value [ 3 ]) )) { return false; } $ibanReplaceChars = range('A', 'Z'); foreach (range(10, 35) as $tempvalue) { $ibanReplaceValues[] = strval($tempvalue); } $tmpIBAN = substr($value, 4) . substr($value, 0, 4); $tmpIBAN = str_replace($ibanReplaceChars, $ibanReplaceValues, $tmpIBAN); $tmpValue = intval(substr($tmpIBAN, 0, 1)); for ($i = 1; $i < strlen($tmpIBAN); $i++) { $tmpValue *= 10; $tmpValue += intval(substr($tmpIBAN, $i, 1)); $tmpValue %= 97; } if ($tmpValue != 1) { return false; } return true; } return false; } /** * validate meliCode number * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since May 21, 2016 * @return boolean */ public function MelliCode($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); if (!preg_match('/^\d{8,10}$/', $value) || preg_match('/^[0]{10}|[1]{10}|[2]{10}|[3]{10}|[4]{10}|[5]{10}|[6]{10}|[7]{10}|[8]{10}|[9]{10}$/', $value)) { return false; } $sub = 0; if (strlen($value) == 8) { $value = '00' . $value; } elseif (strlen($value) == 9) { $value = '0' . $value; } for ($i = 0; $i <= 8; $i++) { $sub = $sub + ( $value[$i] * ( 10 - $i ) ); } if (( $sub % 11 ) < 2) { $control = ( $sub % 11 ); } else { $control = 11 - ( $sub % 11 ); } if ($value[9] == $control) { return true; } else { return false; } } /** * validate string that is not contain persian alphabet and number * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since June 13, 2016 * @return boolean */ public function IsNotPersian($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); if (is_string($value)) { $this->status = (bool) preg_match("/[\x{600}-\x{6FF}]/u", $value); return !$this->status; } return false; } /** * validate array with custom count of array * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since June 13, 2016 * @return boolean */ public function LimitedArray($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); if (is_array($value)) { if (isset($parameters[0])) { return ( (count($value) <= $parameters[0]) ? true : false ); } else { return true; } } return false; } /** * validate number to be unsigned * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since July 22, 2016 * @return boolean */ public function UnSignedNum($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match('/^\d+$/', $value); return $this->status; } /** * validate alphabet and spaces * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since Agu 3, 2016 * @return boolean */ public function AlphaSpace($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match("/^[\pL\s\x{200c}\x{064b}\x{064d}\x{064c}\x{064e}\x{064f}\x{0650}\x{0651}]+$/u", $value); return $this->status; } /** * validate Url * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since Agu 17, 2016 * @return boolean */ public function Url($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match("/^(HTTP|http(s)?:\/\/(www\.)?[A-Za-z0-9]+([\-\.]{1,2}[A-Za-z0-9]+)*\.[A-Za-z]{2,40}(:[0-9]{1,40})?(\/.*)?)$/", $value); return $this->status; } /** * validate Domain * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since Agu 17, 2016 * @return boolean */ public function Domain($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match("/^((www\.)?(\*\.)?[A-Za-z0-9]+([\-\.]{1,2}[A-Za-z0-9]+)*\.[A-Za-z]{2,40}(:[0-9]{1,40})?(\/.*)?)$/", $value); return $this->status; } /** * value must be more than parameters * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since Agu 24, 2016 * @return boolean */ public function More($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); if ( isset( $parameters[0] ) ) { return ( $value > $parameters[0] ? true : false ); } return false; } /** * value must be less than parameters * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since Agu 24, 2016 * @return boolean */ public function Less($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); if ( isset( $parameters[0] ) ) { return ( $value < $parameters[0] ? true : false ); } return false; } /** * iran phone number * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since Agu 24, 2016 * @return boolean */ public function IranPhone($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match('/^[2-9][0-9]{7}+$/', $value) ; return $this->status; } /** * iran phone number with area code * @param $attribute * @param $value * @param $parameters * @param $validator * @author Amir Hosseini <hosseini.sah95@gmail.com> * @since Jan 28, 2019 * @return boolean */ public function IranPhoneWithAreaCode($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match('/^(0[1-9]{2})[2-9][0-9]{7}+$/', $value) ; return $this->status; } /** * payment card number validation * depending on 'http://www.aliarash.com/article/creditcart/credit-debit-cart.htm' article * * @param $attribute * @param $value * @param $parameters * @param $validator * @author Mojtaba Anisi <geevepahlavan@yahoo.com> * @since Oct 1, 2016 * @return boolean */ function CardNumber($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); if (!preg_match('/^\d{16}$/', $value)) { return false; } $sum = 0; for ($position = 1; $position <= 16; $position++){ $temp = $value[$position - 1]; $temp = $position % 2 === 0 ? $temp : $temp * 2; $temp = $temp > 9 ? $temp - 9 : $temp; $sum += $temp; } return (bool)($sum % 10 === 0); } /** * validate alphabet, number and some special characters * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since Oct 7, 2016 * @return boolean */ public function Address($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match("/^[\pL\s\d\-\/\,\،\.\\\\\x{200c}\x{064b}\x{064d}\x{064c}\x{064e}\x{064f}\x{0650}\x{0651}\x{6F0}-\x{6F9}]+$/u", $value); return $this->status; } /** * validate Iran postal code format * @param $attribute * @param $value * @param $parameters * @param $validator * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since Apr 5, 2017 * @return boolean */ public function IranPostalCode($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match("/^(\d{5}-?\d{5})$/", $value); return $this->status; } /** * validate package name of apk * @param $attribute * @param $value * @author Shahrokh Niakan <sh.niakan@anetwork.ir> * @since May 31, 2017 * @return boolean */ public function PackageName($attribute, $value, $parameters, $validator) { ValidationMessages::setCustomMessages( $validator ); $this->status = (bool) preg_match("/^([a-zA-Z]{1}[a-zA-Z\d_]*\.)+[a-zA-Z][a-zA-Z\d_]*$/", $value); return $this->status; } }
anetwork/validation
src/ValidationRules.php
PHP
mit
13,284
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <title>Clantu.js Example</title> <script src="../../dist/clantu.js"></script> </head> <body> <ul> <li><a href="/中文 EN+C">中文 EN+C</a></li> <li><a href="/first-path">first-path</a></li> <li><a href="/path#hash">path#hash</a></li> <li><a href="/query?a=b&name=姓名">query?a=b&name=姓名</a></li> <li><a href="#new-hash">#new-hash</a></li> <li><a href="./relative-path">relative-path</a></li> <li><a href="../parent-path">parent-path</a></li> <li><a href="/self" target="_self">target self</a></li> <li><a href="/blank" target="_blank">target blank</a></li> </ul> <div id="content"></div> <script src="example.js"></script> </body> </html>
Clunt/clantujs
example/basic/index.html
HTML
mit
760
<?php /** * WPSEO plugin file. * * @package WPSEO\Admin\Links */ /** * Represents the link count storage. */ class WPSEO_Meta_Storage implements WPSEO_Installable { const TABLE_NAME = 'yoast_seo_meta'; /** * @var WPSEO_Database_Proxy */ protected $database_proxy; /** * @deprecated * * @var null|string */ protected $table_prefix; /** * Initializes the database table. * * @param string $table_prefix Optional. Deprecated argument. */ public function __construct( $table_prefix = null ) { if ( $table_prefix !== null ) { _deprecated_argument( __METHOD__, 'WPSEO 7.4' ); } $this->database_proxy = new WPSEO_Database_Proxy( $GLOBALS['wpdb'], self::TABLE_NAME, true ); } /** * Returns the table name to use. * * @return string The table name. */ public function get_table_name() { return $this->database_proxy->get_table_name(); } /** * Creates the database table. * * @return boolean True if the table was created, false if something went wrong. */ public function install() { return $this->database_proxy->create_table( array( 'object_id bigint(20) UNSIGNED NOT NULL', 'internal_link_count int(10) UNSIGNED NULL DEFAULT NULL', 'incoming_link_count int(10) UNSIGNED NULL DEFAULT NULL', ), array( 'UNIQUE KEY object_id (object_id)', ) ); } /** * Saves the link count to the database. * * @param int $meta_id The id to save the link count for. * @param array $meta_data The total amount of links. */ public function save_meta_data( $meta_id, array $meta_data ) { $where = array( 'object_id' => $meta_id ); $saved = $this->database_proxy->upsert( array_merge( $where, $meta_data ), $where ); if ( $saved === false ) { WPSEO_Meta_Table_Accessible::set_inaccessible(); } } /** * Updates the incoming link count * * @param array $post_ids The posts to update the incoming link count for. * @param WPSEO_Link_Storage $storage The link storage object. */ public function update_incoming_link_count( array $post_ids, WPSEO_Link_Storage $storage ) { global $wpdb; $query = $wpdb->prepare( ' SELECT COUNT( id ) AS incoming, target_post_id AS post_id FROM ' . $storage->get_table_name() . ' WHERE target_post_id IN(' . implode( ',', array_fill( 0, count( $post_ids ), '%d' ) ) . ') GROUP BY target_post_id', $post_ids ); $results = $wpdb->get_results( $query ); $post_ids_non_zero = array(); foreach ( $results as $result ) { $this->save_meta_data( $result->post_id, array( 'incoming_link_count' => $result->incoming ) ); $post_ids_non_zero[] = $result->post_id; } $post_ids_zero = array_diff( $post_ids, $post_ids_non_zero ); foreach ( $post_ids_zero as $post_id ) { $this->save_meta_data( $post_id, array( 'incoming_link_count' => 0 ) ); } } }
agencja-acclaim/gulp-bower-webapp
wp-content/plugins/wordpress-seo/admin/class-meta-storage.php
PHP
mit
2,857
package net.coding.program.task; import android.support.v4.app.Fragment; import android.support.v4.app.FragmentManager; import android.view.ActionMode; import android.view.Menu; import android.view.MenuInflater; import android.view.MenuItem; import net.coding.program.R; import net.coding.program.common.Global; import net.coding.program.common.base.MDEditFragment; import org.androidannotations.annotations.AfterViews; import org.androidannotations.annotations.EFragment; import org.androidannotations.annotations.FragmentArg; import org.androidannotations.annotations.OptionsItem; @EFragment(R.layout.fragment_task_descrip_md) public class TaskDescripMdFragment extends MDEditFragment { @FragmentArg String contentMd; ActionMode mActionMode; private ActionMode.Callback mActionModeCallback = new ActionMode.Callback() { int id = 0; @Override public boolean onCreateActionMode(ActionMode mode, Menu menu) { menu.clear(); mode.getMenu().clear(); mode.getMenuInflater().inflate(R.menu.task_description_edit, menu); return true; } @Override public boolean onPrepareActionMode(ActionMode mode, Menu menu) { return false; } @Override public boolean onActionItemClicked(ActionMode mode, MenuItem item) { switch (item.getItemId()) { case R.id.action_save: ((TaskDescrip) getActivity()).closeAndSave(edit.getText().toString()); return true; case R.id.action_preview: id = R.id.action_preview; mActionMode.finish(); Global.popSoftkeyboard(getActivity(), edit, false); return true; default: return false; } } @Override public void onDestroyActionMode(ActionMode mode) { FragmentManager fragmentManager = getActivity().getSupportFragmentManager(); fragmentManager.popBackStack(); if (id == R.id.action_preview) { Fragment fragment = TaskDescripHtmlFragment_.builder() .contentMd(edit.getText().toString()) .preview(true) .build(); fragmentManager .beginTransaction() .setCustomAnimations( R.anim.alpha_in, R.anim.alpha_out, R.anim.alpha_in, R.anim.alpha_out) .replace(R.id.container, fragment) .addToBackStack("pre") .commit(); } else { if (fragmentManager.getFragments().size() == 1) { getActivity().finish(); } } } }; @AfterViews void init() { setHasOptionsMenu(true); if (contentMd != null) { edit.setText(contentMd); mActionMode = getActivity().startActionMode(mActionModeCallback); } } @OptionsItem void action_save() { ((TaskDescrip) getActivity()).closeAndSave(edit.getText().toString()); } @Override public void onCreateOptionsMenu(Menu menu, MenuInflater inflater) { inflater.inflate(R.menu.menu_task_description_edit, menu); } }
Coding/Coding-Android
app/src/main/java/net/coding/program/task/TaskDescripMdFragment.java
Java
mit
3,443
"use strict"; exports.default = { type: "html", url: "http://www.xnview.com/en/xnviewmp/", getVersion: function($) { return $("#downloads p") .contains("Download") .find("strong") .version("XnView MP @version"); } };
foxable/app-manager
storage/apps/xnview-mp/versionProvider.js
JavaScript
mit
277
/////////////////////////////////////////////////////////////////////////// // Copyright © Esri. All Rights Reserved. // // 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. /////////////////////////////////////////////////////////////////////////// define({ "_widgetLabel": "Yapı Taslağı Oluşturucu", "newTraverseButtonLabel": "Yeni Çapraz Çizgi Başlat", "invalidConfigMsg": "Geçersiz Yapılandırma", "geometryServiceURLNotFoundMSG": "Geometri Servisi URL’si alınamıyor", "editTraverseButtonLabel": "Çapraz Çizgiyi Düzenle", "mapTooltipForStartNewTraverse": "Başlamak için haritada bir nokta seçin veya aşağıya girin", "mapTooltipForEditNewTraverse": "Düzenlenecek yapıyı seçin", "mapTooltipForUpdateStartPoint": "Başlangıç noktasını güncellemek için tıklayın", "mapTooltipForScreenDigitization": "Yapı noktası eklemek için tıklayın", "mapTooltipForUpdatingRotaionPoint": "Döndürme noktasını güncellemek için tıklayın", "mapTooltipForRotate": "Döndürmek için sürükleyin", "mapTooltipForScale": "Ölçeklendirmek için sürükleyin", "backButtonTooltip": "Geri", "newTraverseTitle": "Yeni Çapraz Çizgi", "editTraverseTitle": "Çapraz Çizgiyi Düzenle", "clearingDataConfirmationMessage": "Değişiklikler atılacak, devam etmek istiyor musunuz?", "unableToFetchParcelMessage": "Yapı alınamıyor.", "unableToFetchParcelLinesMessage": "Yapı çizgileri alınamıyor.", "planSettings": { "planSettingsTitle": "Ayarlar", "directionOrAngleTypeLabel": "Yön veya Açı Türü", "directionOrAngleUnitsLabel": "Yön veya Açı Birimi", "distanceAndLengthUnitsLabel": "Mesafe ve Uzunluk Birimleri", "areaUnitsLabel": "Alan Birimleri:", "circularCurveParameters": "Dairesel Eğri Parametreleri", "northAzimuth": "Kuzey Azimut", "southAzimuth": "Güney Azimut", "quadrantBearing": "Çeyrek Semt Açısı", "radiusAndChordLength": "Yarıçap ve Kiriş Uzunluğu", "radiusAndArcLength": "Yarıçap ve Yay Uzunluğu", "expandGridTooltipText": "Kılavuzu genişlet", "collapseGridTooltipText": "Kılavuzu daralt", "zoomToLocationTooltipText": "Konuma yaklaştır", "onScreenDigitizationTooltipText": "Sayısallaştırma", "updateRotationPointTooltipText": "Döndürme noktasını güncelle" }, "traverseSettings": { "bearingLabel": "Yön", "lengthLabel": "Uzunluk", "radiusLabel": "Yarıçap", "noMiscloseCalculated": "Kapanmama hesaplanamadı", "traverseMiscloseBearing": "Kapanmama Yönü", "traverseAccuracy": "Doğruluk", "accuracyHigh": "Yüksek", "traverseDistance": "Kapanmama Mesafesi", "traverseMiscloseRatio": "Kapanmama Oranı", "traverseStatedArea": "Belirtilen Alan", "traverseCalculatedArea": "Hesaplanan Alan", "addButtonTitle": "Ekle", "deleteButtonTitle": "Kaldır" }, "parcelTools": { "rotationToolLabel": "Açı", "scaleToolLabel": "Ölçek" }, "newTraverse": { "invalidBearingMessage": "Geçersiz Yön.", "invalidLengthMessage": "Geçersiz Uzunluk.", "invalidRadiusMessage": "Geçersiz Yarıçap.", "negativeLengthMessage": "Yalnızca eğriler için geçerlidir", "enterValidValuesMessage": "Geçerli değer girin.", "enterValidParcelInfoMessage": "Kaydedilecek geçerli yapı bilgisi girin.", "unableToDrawLineMessage": "Çizgi çizilemiyor.", "invalidEndPointMessage": "Geçersiz Bitiş Noktası, çizgi çizilemiyor.", "lineTypeLabel": "Çizgi Tipi" }, "planInfo": { "requiredText": "(gerekli)", "optionalText": "(isteğe bağlı)", "parcelNamePlaceholderText": "Yapı adı", "parcelDocumentTypeText": "Belge türü", "planNamePlaceholderText": "Plan adı", "cancelButtonLabel": "İptal Et", "saveButtonLabel": "Kaydet", "saveNonClosedParcelConfirmationMessage": "Girilen yapı kapatılmamış, yine de devam etmek ve yalnızca yapı çizgilerini kaydetmek istiyor musunuz?", "unableToCreatePolygonParcel": "Yapı alanı oluşturulamıyor.", "unableToSavePolygonParcel": "Yapı alanı kaydedilemiyor.", "unableToSaveParcelLines": "Yapı çizgileri kaydedilemiyor.", "unableToUpdateParcelLines": "Yapı çizgileri güncellenemiyor.", "parcelSavedSuccessMessage": "Yapı başarıyla kaydedildi.", "parcelDeletedSuccessMessage": "Parsel başarıyla silindi.", "parcelDeleteErrorMessage": "Parselin silinmesinde hata oluştu.", "enterValidParcelNameMessage": "Geçerli yapı adı girin.", "enterValidPlanNameMessage": "Geçerli plan adı girin.", "enterValidDocumentTypeMessage": "Geçersiz belge türü.", "enterValidStatedAreaNameMessage": "Geçerli belirtilen alan girin." }, "xyInput": { "explanation": "Parsel katmanınızın mekansal referansında" } });
tmcgee/cmv-wab-widgets
wab/2.13/widgets/ParcelDrafter/nls/tr/strings.js
JavaScript
mit
5,323
/*globals $:false, _:false, Firebase:false */ 'use strict'; var url = 'https://jengaship.firebaseio.com/', fb = new Firebase(url), gamesFb = new Firebase(url + 'games'), games, avaGames = [], emptyGames = [], myGames = [], myBoardPositions = [], currentGame, $playerName = $('#playerName'), $chosenName, sunkShips = []; // booleans to check if ships have been placed // Tasks Left: //// 1. Write Jade code which consists of a container for each type of ship, // directing the user to place that type of ship (i.e. 2-destroyer, 3-cruiser, 3-submarine, 4-battleship, or 5-aircraft carrier) // there should be a button in the jade to rotate the ship placement 90 degrees carried out in task 2 // unhide each container on clicking the '.myBoard' container, cycling through each //// 2. Write javascript function that creates a gameboard array every time the user clicks the '.myBoard' container // it should be a length 100 array of mostly 0's but replacing in the correct position a number corresponding // to the boat that the user is currently placing (i.e. the ship container that is not hidden) // it should end with a gameboard array of a user's complete ship placement. Push that to the correct user's gameboard on fb. // you can use findCurrentGameId() to get the necessary fb info //// 3. Write a javascript function that compares the gameboard of the other user stored on fb (written in step 2), // and compares it to the user's '.theirBoard' clicked cell //// 4. Style each type of ship div (2,3,4,5) //// 5. Check for hit or miss and update other user's firebase gameboard with X or M. //// // set .cell height equal to width $(window).ready(function() { console.log('resizing window'); var cw = $('.cell').width(); $('.cell').css({'height':cw+'px'}); }); $(window).on('resize', function() { console.log('resizing window'); var cw = $('.cell').width(); $('.cell').css({'height':cw+'px'}); }); //populate list of available and empty games function checkGames (callback1, callback2) { gamesFb.once('value', function (res) { var data = res.val(); games = _.keys(data); _.forEach(games, function(g){ if(g !== 'undefined'){ var gUrl = new Firebase(url+'games/'+g+'/'); gUrl.once('value', function(games){ var gameValue = games.val(); if (gameValue.user1 && gameValue.user2 === '') { avaGames = []; avaGames.push(g); } else if(gameValue.user1 === $chosenName){ myGames = []; myGames.push(g); } callback1(avaGames); }) } else {} }); }); callback2(avaGames); } //find current game id //this is how we can find which game the curent user is in, at any time // It returns an array in the callback with the current game id and the current user number (i.e. 1 or 2) // used in the cell click function function findCurrentGameId(gamesFb, callback){ var foundGame = []; gamesFb.once('value', function(n){ var games = n.val(), currentUser = $chosenName; _.forEach(games, function(m, key){ if(m.user1===currentUser){ currentGame = key; foundGame.push([key,1]); } else if(m.user2 === currentUser){ currentGame = key; foundGame.push([key,2]); } }); callback(foundGame); }); } //create empty game with host user function createEmptyGame (user1) { var gameBoard1 = [], gameBoard2 = [], user1 = user1, user2 = ''; for (var i = 0;i < 100; i++) { gameBoard1.push(0); gameBoard2.push(0); } var game = {'gameBoard1': gameBoard1, 'gameBoard2': gameBoard2, 'user1': user1, 'user2': user2, 'userTurn': 1}; return game; } //switches the turn of the player function switchTurn (foundGame) { var turnUrl = new Firebase(url + 'games/' + foundGame + '/userTurn'); turnUrl.once('value', function(user){ if (user.val() === 1) { turnUrl.set(2) } else {turnUrl.set(1)} }); } //this gameboard is taken from the local users gameboard layout, just the ship placement //it needs to run when the user's ship placement is done function createMyGameBoard(){ var gameboard = [], $myBoard = $('.myBoard'), $myBoardCells = $myBoard.find('.cell'); _.forEach($myBoardCells, function(cell){ //key: x = hit, m = miss, 2=2 hole ship, 3=3 hole ship, 4=4 hole ship, 5 = 5 hole ship, 0 = untouched var $cell = $(cell); if($cell.hasClass('ship2')){ gameboard.push('2'); } else if($cell.hasClass('ship3')){ gameboard.push('3'); } else if($cell.hasClass('ship4')){ gameboard.push('4'); } else if($cell.hasClass('ship5')){ gameboard.push('5'); } else {gameboard.push(0)}; }); return gameboard; } //this gameboard is taken from the remote users computed hitOrMissArray //this needs to run on cell click function appendMyGuessesGameboard(gb){ var $theirBoard = $('.theirBoard'); for(var i=0;i<gb.length-1;i++){ var $theirBoardCells = $('.theirBoard .cell:eq('+i+')'); if(gb[i] === 'x'){ $theirBoardCells.addClass('hit'); //$('.theirBoard').effect('shake'); } else if(gb[i] === 'm'){ $theirBoardCells.addClass('miss'); } else {} } } function appendTheirGuessesGameboard(gb){ var $myBoard = $('.myBoard'); for(var i=0;i<gb.length-1;i++){ var $myBoardCells = $('.myBoard .cell:eq('+i+')'); if(gb[i] === 'x'){ $myBoardCells.addClass('hit'); } else if(gb[i] === 'm'){ $myBoardCells.addClass('miss'); } else if(gb[i] === '2'){ $myBoardCells.addClass('ship2'); } else if(gb[i] === '3'){ $myBoardCells.addClass('ship3'); } else if(gb[i] === '4'){ $myBoardCells.addClass('ship4'); } else if(gb[i] === '5'){ $myBoardCells.addClass('ship5'); } else{} } } function createBoardPosition(cell) { var $cell = $('.myBoard .cell'), index = $cell.index(cell), currentShip = $('.current'), $shipList = $('.ship-list'), $ship2 = $('.destroyer'), $ship3a = $('.cruiser'), $ship3b = $('.submarine'), $ship4 = $('.battleship'), $ship5 = $('.aircraft-carrier'), vertical = $shipList.hasClass('vertical'), remainingRowCells = cell.nextAll().length, remainingRows = cell.parent().nextAll().length + 1, nextShipInRow = cell.nextUntil('.ship'), shipSize = $('.current').find('li').length; for (var i=0; i < 100; i++) { if (myBoardPositions[i] === undefined) { myBoardPositions[i] = 0; } } // check available cells against ship size before placing if ((!vertical && (remainingRowCells < shipSize)) || (!vertical && (nextShipInRow < shipSize)) || (vertical && remainingRows < shipSize)) { console.log('cant place ship here, not enough cells'); } else if ($ship2.hasClass('current') && vertical) { myBoardPositions[index] = 2; myBoardPositions[index + 10] = 2; $ship2.toggleClass('placed'); appendShipToBoard(cell, 2); console.log('placed destroyer'); } else if ($ship2.hasClass('current')) { myBoardPositions[index] = 2; myBoardPositions[index + 1] = 2; $ship2.toggleClass('placed'); appendShipToBoard(cell, 2); console.log('placed destroyer'); } else if ($ship3a.hasClass('current') && vertical) { myBoardPositions[index] = 3; myBoardPositions[index + 10] = 3; myBoardPositions[index + 20] = 3; $ship3a.toggleClass('placed'); appendShipToBoard(cell, 3); console.log('placed cruiser'); } else if ($ship3a.hasClass('current')) { myBoardPositions[index] = 3; myBoardPositions[index + 1] = 3; myBoardPositions[index + 2] = 3; $ship3a.toggleClass('placed'); appendShipToBoard(cell, 3); console.log('placed cruiser'); } else if ($ship3b.hasClass('current') && vertical) { myBoardPositions[index] = 3; myBoardPositions[index + 10] = 3; myBoardPositions[index + 20] = 3; $ship3b.toggleClass('placed'); appendShipToBoard(cell, 3); console.log('placed submarine'); } else if ($ship3b.hasClass('current')) { myBoardPositions[index] = 3; myBoardPositions[index + 1] = 3; myBoardPositions[index + 2] = 3; $ship3b.toggleClass('placed'); appendShipToBoard(cell, 3); console.log('placed submarine'); } else if ($ship4.hasClass('current') && vertical) { myBoardPositions[index] = 4; myBoardPositions[index + 10] = 4; myBoardPositions[index + 20] = 4; myBoardPositions[index + 30] = 4; $ship4.toggleClass('placed'); appendShipToBoard(cell, 4); console.log('placed battleship'); } else if ($ship4.hasClass('current')) { myBoardPositions[index] = 4; myBoardPositions[index + 1] = 4; myBoardPositions[index + 2] = 4; myBoardPositions[index + 3] = 4; $ship4.toggleClass('placed'); appendShipToBoard(cell, 4); console.log('placed battleship'); } else if ($ship5.hasClass('current') && vertical) { myBoardPositions[index] = 5; myBoardPositions[index + 10] = 5; myBoardPositions[index + 20] = 5; myBoardPositions[index + 30] = 5; myBoardPositions[index + 40] = 5; $ship5.toggleClass('placed'); console.log('placed aircraft carrier'); appendShipToBoard(cell, 5); } else if ($ship5.hasClass('current')) { myBoardPositions[index] = 5; myBoardPositions[index + 1] = 5; myBoardPositions[index + 2] = 5; myBoardPositions[index + 3] = 5; myBoardPositions[index + 4] = 5; $ship5.toggleClass('placed'); appendShipToBoard(cell, 5); console.log('placed aircraft carrier'); } else { console.log('no more ships to play'); } return myBoardPositions; } function sendBoardToFb(user, array) { findCurrentGameId(gamesFb, function(foundGame){ var thisGame = new Firebase (url + 'games/' + foundGame[0][0]), myGameBoard = thisGame.child('gameBoard' + user); myGameBoard.set(array); }); } function appendShipToBoard(cell, shipSize) { var vertical = $('.ship-list').hasClass('vertical'), shipType = 'ship' + shipSize; cell.addClass('ship').addClass(shipType); for (var i=0; i < shipSize - 1; i++) { if (vertical) { cell.parent().nextAll().eq(i).find('.cell').eq(cell.index() - 1).addClass('ship').addClass(shipType); } else { cell.nextAll('.cell').eq(i).addClass('ship').addClass(shipType); } } } function checkBoardForShips (theirGameboard) { function filter3(number){return number === 3}; if ($.inArray(2, theirGameboard) === -1 && $.inArray(2,sunkShips) === -1) { alert('Ship 2 is sunk!'); sunkShips.push(2); } else if (theirGameboard.filter(filter3).length === 3 && $.inArray(8,sunkShips) === -1) { alert('One 3 ship is sunk!'); sunkShips.push(8); } else if ($.inArray(3, theirGameboard) === -1 && $.inArray(9,sunkShips) === -1) { alert('Both 3 ships are sunk!'); sunkShips.push(9); } else if ($.inArray(4, theirGameboard) === -1 && $.inArray(4,sunkShips) === -1) { alert('Ship 4 is sunk'); sunkShips.push(4); } else if ($.inArray(5, theirGameboard) === -1 && $.inArray(5,sunkShips) === -1) { alert('ship 5 is sunk'); sunkShips.push(5); } else if ($.inArray(2, theirGameboard) === -1 && $.inArray(3, theirGameboard) === -1 && $.inArray(4, theirGameboard) === -1 && $.inArray(5, theirGameboard) === -1) { alert('All ships are destroyed!'); } } /////////////////////////////////////////////////// ///////////////// State Listeners ///////////////// /////////////////////////////////////////////////// function listenForUser2(){ findCurrentGameId(gamesFb, function(foundGame){ var thisGameUrl = new Firebase (url + 'games/' + foundGame[0][0]); var otherPlayer = new Firebase (url + 'games/' + foundGame[0][0] + '/user2'); thisGameUrl.on('child_changed', function(childsnap){ var childvalue = childsnap.val(); thisGameUrl.once('value', function(snap){ var p2 = snap.val().user2; if(p2 !== ''){ $('.game-status-p').text('player 2 joined'); thisGameUrl.off('child_changed'); listenforShipPlacement(); } }) }); }); } function listenforShipPlacement(){ //delete stranded game checkGames((function(avaGames){ var deleteGame = new Firebase (url + 'games/' + avaGames[0]); deleteGame.set(null); }),function(avaGames){ }); //attach event listeners to game findCurrentGameId(gamesFb, function(foundGame){ var thisGameUrl = new Firebase (url + 'games/' + foundGame[0][0]); function otherPlayer(){if(foundGame[0][1] === 1){return 2}else{return 1}}; var otherGameboard = new Firebase (url + 'games/' + foundGame[0][0] + '/gameboard'+otherPlayer()); thisGameUrl.on('child_changed', function(childsnap){ var snap = childsnap.val(); if(otherPlayer()===1){ thisGameUrl.once('value', function(g){ if($.inArray(2,g.val().gameBoard1) !== -1){ thisGameUrl.off('child_changed'); listenforMyBoardChange(); listenforTheirBoardChange(); } }) } else { thisGameUrl.once('value', function(g){ if($.inArray(2,g.val().gameBoard2) !== -1){ thisGameUrl.off('child_changed'); listenforMyBoardChange(); listenforTheirBoardChange(); } }) } }); }); } function listenforMyBoardChange(){ findCurrentGameId(gamesFb, function(foundGame){ var thisGameUrl = new Firebase (url + 'games/' + foundGame[0][0]); function otherPlayer(){if(foundGame[0][1] === 1){return 2}else{return 1}}; var otherGameboard = new Firebase (url + 'games/' + foundGame[0][0] + '/gameboard'+otherPlayer()); var myGameboard = new Firebase (url + 'games/' + foundGame[0][0] + '/gameboard'+foundGame[0][1]); thisGameUrl.on('child_changed', function(childsnap){ var snap = childsnap.val(); if(otherPlayer()===1){ thisGameUrl.once('value', function(g){ var mygb = g.val().gameBoard2; appendTheirGuessesGameboard(mygb); checkBoardForShips(mygb); }) } else { thisGameUrl.once('value', function(g){ var mygb = g.val().gameBoard1; appendTheirGuessesGameboard(mygb); checkBoardForShips(mygb); }) } }); }); } function listenforTheirBoardChange(){ findCurrentGameId(gamesFb, function(foundGame){ var thisGameUrl = new Firebase (url + 'games/' + foundGame[0][0]); function otherPlayer(){if(foundGame[0][1] === 1){return 2}else{return 1}}; var otherGameboard = new Firebase (url + 'games/' + foundGame[0][0] + '/gameboard'+otherPlayer()); var myGameboard = new Firebase (url + 'games/' + foundGame[0][0] + '/gameboard'+foundGame[0][1]); thisGameUrl.on('child_changed', function(childsnap){ var snap = childsnap.val(); if(otherPlayer()===1){ thisGameUrl.once('value', function(g){ var mygb = g.val().gameBoard1; appendMyGuessesGameboard(mygb); checkBoardForShips(mygb); }) } else { thisGameUrl.once('value', function(g){ var mygb = g.val().gameBoard2; appendMyGuessesGameboard(mygb); checkBoardForShips(mygb); }) } }); }); } ////////////////////////////////////////////////////// ////////////////// Click Events ////////////////////// ////////////////////////////////////////////////////// // get the current player $playerName.click( function () { if ($('#playerNameValue').val()) { $chosenName = $('#playerNameValue').val(); $('#playerName').toggleClass('hidden'); $('#newGame').toggleClass('hidden'); $('#playerNameValue').toggleClass('hidden'); } }); // send user to an available or empty game $('#newGame').click(function () { $('#newGame').toggleClass('hidden'); $('#newGame').toggleClass('unclicked'); $('.ship-controls').toggleClass('hidden'); checkGames((function(avaGames){ if (avaGames[0]) { var thisGame = new Firebase (url + 'games/' + avaGames[0] + '/user2'); thisGame.set($chosenName); listenforShipPlacement(); } //else {gamesFb.push(createEmptyGame($chosenName))} }), function(){ findCurrentGameId(gamesFb, function(foundGame){ if(!foundGame[0]) { gamesFb.push(createEmptyGame($chosenName)); $('.game-status').toggleClass('hidden'); listenForUser2(); } }); }); }); function gameBoardClick() { $('.theirBoard .cell').click(function(){ var $thisCell = $(this); findCurrentGameId(gamesFb, function(foundGame){ var thisGameUrl = new Firebase (url + 'games/' + foundGame[0][0]), thisGameUserTurn = new Firebase (url + 'games/' + foundGame[0][0] + '/userTurn'); function otherPlayer(){if(foundGame[0][1] === 1){return 2}else{return 1}}; var theirGameboard = new Firebase (url + 'games/' + foundGame[0][0] + '/gameBoard' + otherPlayer()); //the function to check to see if it is a hit or miss should go here //it compares the cell clicked to 'theirGameboard' //it should return a gameboard array of 'x''s,'m''s, and 0's which is passed into the appendYourGuessesGameboard //append computed guesses array to the right gameboard //appendYourGuessesGameboard(hitOrMissArray); var $target = $('.theirBoard .cell').index($thisCell); thisGameUrl.once('value', function(res){ var val = res.val(); function findUser(){ if(val.userTurn === 2){return val.user2} else {return val.user1} } if($chosenName === findUser()){ theirGameboard.once('value', function(gb){ var gbFound = gb.val(); if (gbFound[$target] === 0) { gbFound.splice($target, 1, 'm'); } else if (gbFound[$target] > 0) { gbFound.splice($target, 1, 'x'); } sendBoardToFb(otherPlayer(), gbFound); }); // theirGameboard.once('value', function(gb){ // var updatedGb = gb.val(); // appendMyGuessesGameboard(updatedGb); // }); switchTurn(foundGame[0][0]); } else {} }); }); }); } // end function gameBoardClick gameBoardClick(); // Click a cell to place a ship if placement is valid $('.myBoard .cell').click(function() { var $cell = $(this); if ($cell.hasClass('ship')) { console.log('ship already placed here'); } else if ($('#newGame').hasClass('unclicked')) { console.log('click New Game before placing ships'); } else { createBoardPosition($cell); } }); // Send player's completed board state array to firebase $('.myBoard').click(function() { if ($('.placed').length === 5) { findCurrentGameId(gamesFb, function(foundGame){ if (foundGame[0]) { sendBoardToFb(foundGame[0][1], myBoardPositions); console.log('board sent to firebase'); $('.myBoard').unbind('click'); } else { console.log('could not find game, create a new game first'); } }); } }); // Firebase reset switch for clearing games $('#resetFirebase').click(function () { fb.remove(); }); // Rotate ship $('#rotate').click(function() { $('.ship-list').toggleClass('vertical'); }); // Cycle through ships during placement $('.myBoard').click(function() { var $shipPlaced = $('.ship-controls').find('.current').hasClass('placed'); if ($shipPlaced) { $('.ship-controls').find('.current').next().toggleClass('hidden current'); $('.ship-controls').find('.current').first().toggleClass('hidden current'); } else { console.log('cannot place ship here'); } });
kylemcco/jengaship
app/scripts/index.js
JavaScript
mit
19,418
require_relative "test_helper" class TestService < Mailkick::Service def opt_outs [ {email: "test@example.com", time: Time.current, reason: "bounce"}, {email: "test2@example.com", time: 1.day.ago, reason: "spam"} ] end end class ServiceTest < Minitest::Test def setup super Mailkick.services = [TestService.new] end def teardown super Mailkick.services = [] end def test_process_opt_outs user = User.create!(email: "test@example.com") user.subscribe("sales") user2 = User.create!(email: "test2@example.com") user2.subscribe("sales") previous_method = Mailkick.process_opt_outs_method begin Mailkick.process_opt_outs_method = lambda do |opt_outs| emails = opt_outs.map { |v| v[:email] } subscribers = User.includes(:mailkick_subscriptions).where(email: emails).index_by(&:email) opt_outs.each do |opt_out| subscriber = subscribers[opt_out[:email]] next unless subscriber subscriber.mailkick_subscriptions.each do |subscription| subscription.destroy if subscription.created_at < opt_out[:time] end end end Mailkick.fetch_opt_outs refute user.subscribed?("sales") assert user2.subscribed?("sales") ensure Mailkick.process_opt_outs_method = previous_method end end def test_not_configured error = assert_raises do Mailkick.fetch_opt_outs end assert_equal "process_opt_outs_method not defined", error.message end end
ankane/mailkick
test/service_test.rb
Ruby
mit
1,549
<!DOCTYPE html> <html class="pl"> <head> <title>Pattern Lab</title> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width" /> <link rel="stylesheet" href="/assets/../components/css/pattern-scaffolding.css?1500631430" media="all" /> <link rel="stylesheet" href="/assets/style.css?1500631430" media="all" /> <!-- Begin Pattern Lab (Required for Pattern Lab to run properly) --> <!-- never cache patterns --> <meta http-equiv="cache-control" content="max-age=0" /> <meta http-equiv="cache-control" content="no-cache" /> <meta http-equiv="expires" content="0" /> <meta http-equiv="expires" content="Tue, 01 Jan 1980 1:00:00 GMT" /> <meta http-equiv="pragma" content="no-cache" /> <link rel="stylesheet" href="../../styleguide/css/styleguide.min.css?1500631430" media="all"> <link rel="stylesheet" href="../../styleguide/css/prism-typeahead.min.css?1500631430" media="all" /> <!-- End Pattern Lab --> </head> <body class="b-body"> <main> <!-- for js not found errors (only in styleguide)--> <div class="visually-hidden"> <div id="tabs" class="tabs"></div> </div> <!-- View All Patterns in a Pattern Sub-Type --> <div class="sg-main" role="main"> <!-- Patterns --> <div id="sg-patterns"> <div id="viewall-utilities-u-clearfix" class="sg-subtype"> <h2> <a href="../../patterns/07-utilities-u-clearfix/index.html" class="patternLink" data-patternpartial="viewall-utilities-u-clearfix"> u clearfix </a> </h2> <div class="sg-pattern-body"> </div> </div> <div id="utilities-u-clearfix" class="sg-pattern"> <div class="sg-pattern-head"> <h3 class="sg-pattern-title"> <a href="../../patterns/07-utilities-u-clearfix-u-clearfix/07-utilities-u-clearfix-u-clearfix.html" class="patternLink" data-patternpartial="utilities-u-clearfix" title="Link to Pattern"> Clearfix </a> </h3> <div class="sg-pattern-breadcrumb"> </div> <a href="#" data-patternpartial="utilities-u-clearfix" title="View Pattern Info" id="sg-pattern-extra-toggle-utilities-u-clearfix" class="sg-pattern-extra-toggle"> <span>&#9660;</span> </a> </div> <div class="sg-pattern-extra" id="sg-pattern-extra-utilities-u-clearfix"></div> <div class="sg-pattern-example"> </div> <script type="text/json" id="sg-pattern-data-utilities-u-clearfix" class="sg-pattern-data"> {"lineage":[],"lineageR":[],"patternBreadcrumb":{"patternType":"utilities","patternSubtype":"u clearfix"},"patternDesc":"<h2>Clearfix<\/h2>\n\n<p>A way for an element to automatically clear its child elements. <br\/>\n<a href=\"..\/..\/..\/..\/dist\/sassdoc\/#utility-placeholder-u-clearfix\" target=\"_blank\">Usage and Examples<\/a><\/p>","patternExtension":"twig","patternName":"Clearfix","patternPartial":"utilities-u-clearfix","patternState":""} </script> </div><!--end .sg-pattern--> <div id="viewall-utilities-u-grid-container" class="sg-subtype"> <h2> <a href="../../patterns/07-utilities-u-grid-container/index.html" class="patternLink" data-patternpartial="viewall-utilities-u-grid-container"> u grid container </a> </h2> <div class="sg-pattern-body"> </div> </div> <div id="viewall-utilities-u-modal" class="sg-subtype"> <h2> <a href="../../patterns/07-utilities-u-modal/index.html" class="patternLink" data-patternpartial="viewall-utilities-u-modal"> u modal </a> </h2> <div class="sg-pattern-body"> </div> </div> <div id="viewall-utilities-u-no-scroll" class="sg-subtype"> <h2> <a href="../../patterns/07-utilities-u-no-scroll/index.html" class="patternLink" data-patternpartial="viewall-utilities-u-no-scroll"> u no scroll </a> </h2> <div class="sg-pattern-body"> </div> </div> <div id="viewall-utilities-u-overlay" class="sg-subtype"> <h2> <a href="../../patterns/07-utilities-u-overlay/index.html" class="patternLink" data-patternpartial="viewall-utilities-u-overlay"> u overlay </a> </h2> <div class="sg-pattern-body"> </div> </div> <div id="viewall-utilities-u-remove-child" class="sg-subtype"> <h2> <a href="../../patterns/07-utilities-u-remove-child/index.html" class="patternLink" data-patternpartial="viewall-utilities-u-remove-child"> u remove child </a> </h2> <div class="sg-pattern-body"> </div> </div> <div id="utilities-u-remove-child" class="sg-pattern"> <div class="sg-pattern-head"> <h3 class="sg-pattern-title"> <a href="../../patterns/07-utilities-u-remove-child-u-remove-child/07-utilities-u-remove-child-u-remove-child.html" class="patternLink" data-patternpartial="utilities-u-remove-child" title="Link to Pattern"> Remove child margin top and bottom </a> </h3> <div class="sg-pattern-breadcrumb"> </div> <a href="#" data-patternpartial="utilities-u-remove-child" title="View Pattern Info" id="sg-pattern-extra-toggle-utilities-u-remove-child" class="sg-pattern-extra-toggle"> <span>&#9660;</span> </a> </div> <div class="sg-pattern-extra" id="sg-pattern-extra-utilities-u-remove-child"></div> <div class="sg-pattern-example"> <div class="sg__wrapper--xlight-grey--border"> <!--Only used in demo --> <h1>No Margins from children element are changed</h1> <p>Aliquam vitae ligula iaculis, sodales ligula facilisis, rhoncus lacus. Proin a eros erat. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Praesent velit tellus, auctor sit amet dolor at, consequat pulvinar lacus. </p> </div> <div class="sg__wrapper--xlight-grey--border"> <!--Only used in demo --> <div class="u-remove-child--margin-top-bottom"> <h1>Margin removed from childen elements</h1> <p>Top margin from first child elemnt and bottom margin from last child element are removed. liquam vitae ligula iaculis, sodales ligula facilisis, rhoncus lacus. Proin a eros erat. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices posuere cubilia Curae; Praesent velit tellus, auctor sit amet dolor at, consequat pulvinar lacus. </p> </div> </div> </div> <script type="text/json" id="sg-pattern-data-utilities-u-remove-child" class="sg-pattern-data"> {"lineage":[],"lineageR":[],"patternBreadcrumb":{"patternType":"utilities","patternSubtype":"u remove child"},"patternDesc":"<h2>Remove child margin top and bottom<\/h2>\n\n<p>Remove top and bottom margin from childen elements in a container. This is useful for things like titles in WYSIWYG Fields.<br\/>\n<a href=\"..\/..\/..\/..\/dist\/sassdoc\/#utility-placeholder-u-remove-child--margin-top-bottom\" target=\"_blank\">Usage and Examples<\/a><\/p>","patternExtension":"twig","patternName":"Remove child margin top and bottom","patternPartial":"utilities-u-remove-child","patternState":""} </script> </div><!--end .sg-pattern--> <div id="viewall-utilities-u-strong" class="sg-subtype"> <h2> <a href="../../patterns/07-utilities-u-strong/index.html" class="patternLink" data-patternpartial="viewall-utilities-u-strong"> u strong </a> </h2> <div class="sg-pattern-body"> </div> </div> <div id="viewall-utilities-u-text-hide" class="sg-subtype"> <h2> <a href="../../patterns/07-utilities-u-text-hide/index.html" class="patternLink" data-patternpartial="viewall-utilities-u-text-hide"> u text hide </a> </h2> <div class="sg-pattern-body"> </div> </div> <div id="utilities-u-text-hide" class="sg-pattern"> <div class="sg-pattern-head"> <h3 class="sg-pattern-title"> <a href="../../patterns/07-utilities-u-text-hide-u-text-hide/07-utilities-u-text-hide-u-text-hide.html" class="patternLink" data-patternpartial="utilities-u-text-hide" title="Link to Pattern"> Text Hide </a> </h3> <div class="sg-pattern-breadcrumb"> </div> <a href="#" data-patternpartial="utilities-u-text-hide" title="View Pattern Info" id="sg-pattern-extra-toggle-utilities-u-text-hide" class="sg-pattern-extra-toggle"> <span>&#9660;</span> </a> </div> <div class="sg-pattern-extra" id="sg-pattern-extra-utilities-u-text-hide"></div> <div class="sg-pattern-example"> </div> <script type="text/json" id="sg-pattern-data-utilities-u-text-hide" class="sg-pattern-data"> {"lineage":[],"lineageR":[],"patternBreadcrumb":{"patternType":"utilities","patternSubtype":"u text hide"},"patternDesc":"<h2>Text Hide<\/h2>\n\n<p>Hides text in block elements using text-indent. Useful for accessibility in Icon links etc. <br\/>\n<a href=\"..\/..\/..\/..\/dist\/sassdoc\/#utility-mixin-text-hide\" target=\"_blank\">Usage and Examples<\/a><\/p>","patternExtension":"twig","patternName":"Text Hide","patternPartial":"utilities-u-text-hide","patternState":""} </script> </div><!--end .sg-pattern--> <div id="viewall-utilities-u-visually-hidden" class="sg-subtype"> <h2> <a href="../../patterns/07-utilities-u-visually-hidden/index.html" class="patternLink" data-patternpartial="viewall-utilities-u-visually-hidden"> u visually hidden </a> </h2> <div class="sg-pattern-body"> </div> </div> <div id="utilities-u-visually--hidden" class="sg-pattern"> <div class="sg-pattern-head"> <h3 class="sg-pattern-title"> <a href="../../patterns/07-utilities-u-visually-hidden-u-visually--hidden/07-utilities-u-visually-hidden-u-visually--hidden.html" class="patternLink" data-patternpartial="utilities-u-visually--hidden" title="Link to Pattern"> Visually Hidden </a> </h3> <div class="sg-pattern-breadcrumb"> </div> <a href="#" data-patternpartial="utilities-u-visually--hidden" title="View Pattern Info" id="sg-pattern-extra-toggle-utilities-u-visually--hidden" class="sg-pattern-extra-toggle"> <span>&#9660;</span> </a> </div> <div class="sg-pattern-extra" id="sg-pattern-extra-utilities-u-visually--hidden"></div> <div class="sg-pattern-example"> <p>This is followed by visually hidden text -> <span class="u-visually--hidden">Visually Hidden Text</span></p> <p>Unset by applying visually show class -> <span class="u-visually--shown">Visually Shown Text</span></p> </div> <script type="text/json" id="sg-pattern-data-utilities-u-visually--hidden" class="sg-pattern-data"> {"lineage":[],"lineageR":[],"patternBreadcrumb":{"patternType":"utilities","patternSubtype":"u visually hidden"},"patternDesc":"<h2>Visually Hidden \/ Visually Shown<\/h2>\n\n<p>Accessible way to hide elements on the page (and show them again).\n<a href=\"..\/..\/..\/..\/dist\/sassdoc\/#utility-mixin-visually-hidden\" target=\"_blank\">Usage and Examples<\/a><\/p>","patternExtension":"twig","patternName":"Visually Hidden","patternPartial":"utilities-u-visually--hidden","patternState":""} </script> </div><!--end .sg-pattern--> <div id="viewall-utilities-u-word-break" class="sg-subtype"> <h2> <a href="../../patterns/07-utilities-u-word-break/index.html" class="patternLink" data-patternpartial="viewall-utilities-u-word-break"> u word break </a> </h2> <div class="sg-pattern-body"> </div> </div> <div id="utilities-u-word-break" class="sg-pattern"> <div class="sg-pattern-head"> <h3 class="sg-pattern-title"> <a href="../../patterns/07-utilities-u-word-break-u-word-break/07-utilities-u-word-break-u-word-break.html" class="patternLink" data-patternpartial="utilities-u-word-break" title="Link to Pattern"> Word Break </a> </h3> <div class="sg-pattern-breadcrumb"> </div> <a href="#" data-patternpartial="utilities-u-word-break" title="View Pattern Info" id="sg-pattern-extra-toggle-utilities-u-word-break" class="sg-pattern-extra-toggle"> <span>&#9660;</span> </a> </div> <div class="sg-pattern-extra" id="sg-pattern-extra-utilities-u-word-break"></div> <div class="sg-pattern-example"> <div class="sg__wrapper--xlight-grey"> <!--Only used in demo --> <span class="u-word-break--pipe"> University of Mainspring </span> <span class="u-word-break--pipe"> 123 Street </span> <span class="u-word-break--pipe"> Toronto Ontario, Canada </span> </div> </div> <script type="text/json" id="sg-pattern-data-utilities-u-word-break" class="sg-pattern-data"> {"lineage":[],"lineageR":[],"patternBreadcrumb":{"patternType":"utilities","patternSubtype":"u word break"},"patternDesc":"<h2>Word Break<\/h2>\n\n<p>Based on <a href=\"http:\/\/danielmall.com\/articles\/responsive-line-breaks\/\">Responsive Line Breaks<\/a>.<br\/>\nSpan does a line break on smaller screens, on larger screens appears inline with a trailing pipe. divider<\/p>","patternExtension":"twig","patternName":"Word Break","patternPartial":"utilities-u-word-break","patternState":""} </script> </div><!--end .sg-pattern--> <div id="viewall-utilities-u-wrapper-error" class="sg-subtype"> <h2> <a href="../../patterns/07-utilities-u-wrapper-error/index.html" class="patternLink" data-patternpartial="viewall-utilities-u-wrapper-error"> u wrapper error </a> </h2> <div class="sg-pattern-body"> </div> </div> </div> <!--end #sg-patterns--> </div><!--end .sg-main--> <!--DO NOT REMOVE--> <script type="text/json" id="sg-pattern-data-footer" class="sg-pattern-data"> {"patternPartial":"viewall-scope-s-wysiwyg"} </script> <script> /*! * scriptLoader - v0.1 * * Copyright (c) 2014 Dave Olsen, http://dmolsen.com * Licensed under the MIT license * */ var scriptLoader = { run: function(js,cb,target) { var s = document.getElementById(target+'-'+cb); for (var i = 0; i < js.length; i++) { var src = (typeof js[i] != 'string') ? js[i].src : js[i]; var c = document.createElement('script'); c.src = '../../'+src+'?'+cb; if (typeof js[i] != 'string') { if (js[i].dep !== undefined) { c.onload = function(dep,cb,target) { return function() { scriptLoader.run(dep,cb,target); } }(js[i].dep,cb,target); } } s.parentNode.insertBefore(c,s); } } } </script> <script id="pl-js-polyfill-insert-1500631430"> (function() { if (self != top) { var cb = '1500631430'; var js = []; if (typeof document !== 'undefined' && !('classList' in document.documentElement)) { js.push('styleguide/bower_components/classList.min.js'); } scriptLoader.run(js,cb,'pl-js-polyfill-insert'); } })(); </script> <script id="pl-js-insert-1500631430"> (function() { if (self != top) { var cb = '1500631430'; var js = [ { 'src': 'styleguide/bower_components/jwerty.min.js', 'dep': [ 'styleguide/js/patternlab-pattern.min.js' ] } ]; scriptLoader.run(js,cb,'pl-js-insert'); } })(); </script> <!-- ToDo: Review Paths to all js --> <!-- may need to change these below based on path --> <!-- <script src="../../../../../../../core/assets/vendor/domready/ready.min.js"></script> --> <!-- <script src="../../../../../../../core/misc/drupal.js"></script> --> <script src="https://code.jquery.com/jquery-2.2.4.js" integrity="sha256-iT6Q9iMJYuQiMWNd9lDyBUStIq/8PuOW33aOqmvFpqI=" crossorigin="anonymous"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/velocity/1.4.1/velocity.js"></script> <script src="/assets/js/scripts.js"></script> </main> </body> </html>
AlexKomm/alexkomm.github.io
patterns/07-utilities/index.html
HTML
mit
16,024
<?php namespace {AppNamespace}Components\{ComponentName}; use Teepluss\Component\BaseComponent; use Illuminate\Foundation\Application as Application; use Teepluss\Component\Contracts\BaseComponent as BaseComponentContract; class {ComponentName} extends BaseComponent implements BaseComponentContract { /** * Application. * * @var \Illuminate\Foundation\Application */ protected $app; /** * Component namespace. * * @var string */ protected $namespace = '{ComponentNamespace}'; /** * Component arguments. * * @var mixed */ protected $arguments; /** * Component new instance. * * @param \Illuminate\Foundation\Application $app * @param mixed $arguments */ public function __construct(Application $app, $arguments = array()) { parent::__construct($app, $arguments); } /** * Prepare your code here! * * @return void */ final public function prepare() { // Example add internal assets. // $this->script('name-1', 'script.js'); // $this->script('name-2', 'script-2.js', ['name-1']); // Example add external assets. // $this->script('name-e1', '//code.jquery.com/jquery-2.1.3.min.js'); // $this->style('name-e2', '//maxcdn.bootstrapcdn.com/font-awesome/4.3.0/css/font-awesome.min.css', ['name-e1']); $arguments = array_merge($this->arguments, [ 'component' => $this->getComponentName() ]); $this->view('index', $arguments); return $this; } }
teepluss/laravel-component
src/templates/component/ExampleComponent.php
PHP
mit
1,609
<h1>这仅仅是个测试</h1> <%- include('snippet.html')%> <ul> <% for(var key in locals){ %> <li><%= key %>:<%= locals[key]%></li> <% } %> </ul>
iwfe/koa-rudy
app/views/index/index.html
HTML
mit
163
<?xml version="1.0" encoding="UTF-8" standalone="no"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /> <title>DB-&gt;associate()</title> <link rel="stylesheet" href="apiReference.css" type="text/css" /> <meta name="generator" content="DocBook XSL Stylesheets V1.73.2" /> <link rel="start" href="index.html" title="Berkeley DB C API Reference" /> <link rel="up" href="db.html" title="Chapter 2.  The DB Handle" /> <link rel="prev" href="db.html" title="Chapter 2.  The DB Handle" /> <link rel="next" href="dbassociate_foreign.html" title="DB-&gt;associate_foreign()" /> </head> <body> <div xmlns="" class="navheader"> <div class="libver"> <p>Library Version 11.2.5.3</p> </div> <table width="100%" summary="Navigation header"> <tr> <th colspan="3" align="center">DB-&gt;associate()</th> </tr> <tr> <td width="20%" align="left"><a accesskey="p" href="db.html">Prev</a> </td> <th width="60%" align="center">Chapter 2.  The DB Handle </th> <td width="20%" align="right"> <a accesskey="n" href="dbassociate_foreign.html">Next</a></td> </tr> </table> <hr /> </div> <div class="sect1" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h2 class="title" style="clear: both"><a id="dbassociate"></a>DB-&gt;associate()</h2> </div> </div> </div> <pre class="programlisting">#include &lt;db.h&gt; int DB-&gt;associate(DB *primary, DB_TXN *txnid, DB *secondary, int (*callback)(DB *secondary, const DBT *key, const DBT *data, DBT *result), u_int32_t flags); </pre> <p> The <code class="methodname">DB-&gt;associate()</code> function is used to declare one database a secondary index for a primary database. The <a class="link" href="db.html" title="Chapter 2.  The DB Handle">DB</a> handle that you call the <code class="methodname">associate()</code> method from is the primary database. </p> <p> After a secondary database has been "associated" with a primary database, all updates to the primary will be automatically reflected in the secondary and all reads from the secondary will return corresponding data from the primary. Note that as primary keys must be unique for secondary indices to work, the primary database must be configured without support for duplicate data items. See <a href="../../programmer_reference/am_second.html" class="olink">Secondary Indices</a> in the <em class="citetitle">Berkeley DB Programmer's Reference Guide</em> for more information. </p> <p> The <code class="methodname">DB-&gt;associate()</code> <span> <span> method returns a non-zero error value on failure and 0 on success. </span> </span> </p> <div class="sect2" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h3 class="title"><a id="idp49278832"></a>Parameters</h3> </div> </div> </div> <div class="sect3" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h4 class="title"><a id="idp49294248"></a>primary</h4> </div> </div> </div> <p> The <span class="bold"><strong>primary</strong></span> parameter should be a database handle for the primary database that is to be indexed. </p> </div> <div class="sect3" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h4 class="title"><a id="idp49284296"></a>txnid</h4> </div> </div> </div> <p> If the operation is part of an application-specified transaction, the <span class="bold"><strong>txnid</strong></span> parameter is a transaction handle returned from <a class="xref" href="txnbegin.html" title="DB_ENV-&gt;txn_begin()">DB_ENV-&gt;txn_begin()</a>; if the operation is part of a Berkeley DB Concurrent Data Store group, the <span class="bold"><strong>txnid</strong></span> parameter is a handle returned from <a class="xref" href="envcdsgroup_begin.html" title="DB_ENV-&gt;cdsgroup_begin()">DB_ENV-&gt;cdsgroup_begin()</a>; otherwise NULL. If no transaction handle is specified, but the operation occurs in a transactional database, the operation will be implicitly transaction protected. </p> </div> <div class="sect3" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h4 class="title"><a id="idp49285856"></a>secondary</h4> </div> </div> </div> <p> The <span class="bold"><strong>secondary</strong></span> parameter should be an open database handle of either a newly created and empty database that is to be used to store a secondary index, or of a database that was previously associated with the same primary and contains a secondary index. Note that it is not safe to associate as a secondary database a handle that is in use by another thread of control or has open cursors. If the handle was opened with the <a class="link" href="envopen.html#envopen_DB_THREAD">DB_THREAD</a> flag it is safe to use it in multiple threads of control after the <code class="methodname">DB-&gt;associate()</code> method has returned. Note also that either secondary keys must be unique or the secondary database must be configured with support for duplicate data items. </p> </div> <div class="sect3" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h4 class="title"><a id="idp49289920"></a>callback</h4> </div> </div> </div> <p> The <span class="bold"><strong>callback</strong></span> parameter is a callback function that creates the set of secondary keys corresponding to a given primary key and data pair. </p> <p> The callback parameter may be NULL if both the primary and secondary database handles were opened with the <a class="link" href="dbopen.html#dbopen_DB_RDONLY">DB_RDONLY</a> flag. </p> <p> The callback takes four arguments: </p> <div class="itemizedlist"> <ul type="disc"> <li> <p> <code class="literal">secondary</code> </p> <p> The <span class="bold"><strong>secondary</strong></span> parameter is the database handle for the secondary. </p> </li> <li> <p> <code class="literal">key</code> </p> <p> The <span class="bold"><strong>key</strong></span> parameter is a <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a> referencing the primary key. </p> </li> <li> <p> <code class="literal">data</code> </p> <p> The <span class="bold"><strong>data</strong></span> parameter is a <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a> referencing the primary data item. </p> </li> <li> <p> <code class="literal">result</code> </p> <p> The <span class="bold"><strong>result</strong></span> parameter is a zeroed <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a> in which the callback function should fill in <span class="bold"><strong>data</strong></span> and <span class="bold"><strong>size</strong></span> fields that describe the secondary key or keys. </p> </li> </ul> </div> <div class="note" style="margin-left: 0.5in; margin-right: 0.5in;"> <h3 class="title">Note</h3> <p> Berkeley DB is not re-entrant. Callback functions should not attempt to make library calls (for example, to release locks or close open handles). Re-entering Berkeley DB is not guaranteed to work correctly, and the results are undefined. </p> </div> <p> The result <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a> can have the following flags set in its <span class="bold"><strong>flags</strong></span> field: </p> <div class="itemizedlist"> <ul type="disc"> <li> <p><a id="associate_DB_DBT_APPMALLOC"></a> <code class="literal">DB_DBT_APPMALLOC</code> </p> <p> If the callback function needs to allocate memory for the <span class="bold"><strong>result</strong></span> data field (rather than simply pointing into the primary key or datum), DB_DBT_APPMALLOC should be set in the <span class="bold"><strong>flags</strong></span> field of the <span class="bold"><strong>result</strong></span> <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a>, which indicates that Berkeley DB should free the memory when it is done with it. </p> </li> <li> <p><a id="associate_DB_DBT_MULTIPLE"></a> <code class="literal">DB_DBT_MULTIPLE</code> </p> <p> To return multiple secondary keys, DB_DBT_MULTIPLE should be set in the <span class="bold"><strong>flags</strong></span> field of the <span class="bold"><strong>result</strong></span> <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a>, which indicates Berkeley DB should treat the <span class="bold"><strong>size</strong></span> field as the number of secondary keys (zero or more), and the <span class="bold"><strong>data</strong></span> field as a pointer to an array of that number of <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a>s describing the set of secondary keys. </p> <p> <span class="bold"><strong>When multiple secondary keys are returned, keys may not be repeated</strong></span>. In other words, there must be no repeated record numbers in the array for Recno and Queue databases, and keys must not compare equally using the secondary database's comparison function for Btree and Hash databases. If keys are repeated, operations may fail and the secondary may become inconsistent with the primary. </p> <p> The DB_DBT_APPMALLOC flag may be set for any <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a> in the array of returned <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a>'s to indicate that Berkeley DB should free the memory referenced by that particular <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a>'s data field when it is done with it. </p> <p> The DB_DBT_APPMALLOC flag may be combined with DB_DBT_MULTIPLE in the <span class="bold"><strong>result</strong></span> <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a>'s <span class="bold"><strong>flag</strong></span> field to indicate that Berkeley DB should free the array once it is done with all of the returned keys. </p> </li> </ul> </div> <p> In addition, the callback can optionally return the following special value: </p> <div class="itemizedlist"> <ul type="disc"> <li> <p><a id="associate_DB_DONOTINDEX"></a> <code class="literal">DB_DONOTINDEX</code> </p> <p> If any key/data pair in the primary yields a null secondary key and should be left out of the secondary index, the callback function may optionally return DB_DONOTINDEX. Otherwise, the callback function should return 0 in case of success or an error outside of the Berkeley DB name space in case of failure; the error code will be returned from the Berkeley DB call that initiated the callback. </p> <p> If the callback function returns DB_DONOTINDEX for any key/data pairs in the primary database, the secondary index will not contain any reference to those key/data pairs, and such operations as cursor iterations and range queries will reflect only the corresponding subset of the database. If this is not desirable, the application should ensure that the callback function is well-defined for all possible values and never returns DB_DONOTINDEX. </p> <p> Returning DB_DONOTINDEX is equivalent to setting DB_DBT_MULTIPLE on the <span class="bold"><strong>result</strong></span> <a class="link" href="dbt.html" title="Chapter 4.  The DBT Handle">DBT</a> and setting the <span class="bold"><strong>size</strong></span> field to zero. </p> </li> </ul> </div> </div> <div class="sect3" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h4 class="title"><a id="idp49301168"></a>flags</h4> </div> </div> </div> <p> The <span class="bold"><strong>flags</strong></span> parameter must be set to 0 or by bitwise inclusively <span class="bold"><strong>OR</strong></span>'ing together one or more of the following values: </p> <div class="itemizedlist"> <ul type="disc"> <li> <p><a id="associate_DB_CREATE"></a> <code class="literal">DB_CREATE</code> </p> <p> If the secondary database is empty, walk through the primary and create an index to it in the empty secondary. This operation is potentially very expensive. </p> <p> If the secondary database has been opened in an environment configured with transactions, the entire secondary index creation is performed in the context of a single transaction. </p> <p> Care should be taken not to use a newly-populated secondary database in another thread of control until the <code class="methodname">DB-&gt;associate()</code> call has returned successfully in the first thread. </p> <p> If transactions are not being used, care should be taken not to modify a primary database being used to populate a secondary database, in another thread of control, until the <code class="methodname">DB-&gt;associate()</code> call has returned successfully in the first thread. If transactions are being used, Berkeley DB will perform appropriate locking and the application need not do any special operation ordering. </p> </li> <li> <p><a id="associate_DB_IMMUTABLE_KEY"></a> <code class="literal">DB_IMMUTABLE_KEY</code> </p> <p> Specifies the secondary key is immutable. </p> <p> This flag can be used to optimize updates when the secondary key in a primary record will never be changed after the primary record is inserted. For immutable secondary keys, a best effort is made to avoid calling the secondary callback function when primary records are updated. This optimization may reduce the overhead of update operations significantly if the callback function is expensive. </p> <p> Be sure to specify this flag only if the secondary key in the primary record is never changed. If this rule is violated, the secondary index will become corrupted, that is, it will become out of sync with the primary. </p> </li> </ul> </div> </div> </div> <div class="sect2" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h3 class="title"><a id="idp49348360"></a>Errors</h3> </div> </div> </div> <p> The <code class="methodname">DB-&gt;associate()</code> <span> <span> method may fail and return one of the following non-zero errors: </span> </span> </p> <div class="sect3" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h4 class="title"><a id="idp49313056"></a> DB_REP_HANDLE_DEAD</h4> </div> </div> </div> <p> When a client synchronizes with the master, it is possible for committed transactions to be rolled back. This invalidates all the database and cursor handles opened in the replication environment. Once this occurs, an attempt to use such a handle will return <code class="literal">DB_REP_HANDLE_DEAD</code>. The application will need to discard the handle and open a new one in order to continue processing. </p> </div> <div class="sect3" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h4 class="title"><a id="idp49302160"></a>DB_REP_LOCKOUT</h4> </div> </div> </div> <p> The operation was blocked by client/master synchronization. </p> </div> <div class="sect3" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h4 class="title"><a id="idp49321256"></a>EINVAL</h4> </div> </div> </div> <p> If the secondary database handle has already been associated with this or another database handle; the secondary database handle is not open; the primary database has been configured to allow duplicates; or if an invalid flag value or parameter was specified. </p> </div> </div> <div class="sect2" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h3 class="title"><a id="idp49283880"></a>Class</h3> </div> </div> </div> <p> <a class="link" href="db.html" title="Chapter 2.  The DB Handle">DB</a> </p> </div> <div class="sect2" lang="en" xml:lang="en"> <div class="titlepage"> <div> <div> <h3 class="title"><a id="idm8031240"></a>See Also</h3> </div> </div> </div> <p> <a class="xref" href="db.html#dblist" title="Database and Related Methods">Database and Related Methods</a> </p> </div> </div> <div class="navfooter"> <hr /> <table width="100%" summary="Navigation footer"> <tr> <td width="40%" align="left"><a accesskey="p" href="db.html">Prev</a> </td> <td width="20%" align="center"> <a accesskey="u" href="db.html">Up</a> </td> <td width="40%" align="right"> <a accesskey="n" href="dbassociate_foreign.html">Next</a></td> </tr> <tr> <td width="40%" align="left" valign="top">Chapter 2.  The DB Handle  </td> <td width="20%" align="center"> <a accesskey="h" href="index.html">Home</a> </td> <td width="40%" align="right" valign="top"> DB-&gt;associate_foreign()</td> </tr> </table> </div> </body> </html>
iadix/iadixcoin
db-5.3.28.NC/docs/api_reference/C/dbassociate.html
HTML
mit
24,529
<?php return array ( 'id' => 'alltel_ppc6800_ver1', 'fallback' => 'sprint_ppc6800_ver1_subie711', 'capabilities' => array ( 'brand_name' => 'HTC', 'model_extra_info' => 'Alltel', 'playback_acodec_amr' => 'nb', 'playback_wmv' => '7', ), );
cuckata23/wurfl-data
data/alltel_ppc6800_ver1.php
PHP
mit
266
// Copyright (c) 2017 AB4D d.o.o. // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Software without restriction, including without limitation the rights // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell // copies of the Software, and to permit persons to whom the Software is // furnished to do so, subject to the following conditions: // // The above copyright notice and this permission notice shall be included in // all copies or substantial portions of the Software. // // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. // // Based on OculusWrap project created by MortInfinite and licensed as Ms-PL (https://oculuswrap.codeplex.com/) using System; namespace Ab3d.OculusWrap { /// <summary> /// Specifies sensor flags. /// </summary> /// <see cref="TrackerPose"/> [Flags] public enum TrackerFlags { /// <summary> /// No flags. /// </summary> None = 0, /// <summary> /// The sensor is present, else the sensor is absent or offline. /// </summary> Connected = 0x0020, /// <summary> /// The sensor has a valid pose, else the pose is unavailable. /// This will only be set if TrackerFlags.Connected is set. /// </summary> PoseTracked = 0x0004, } }
ab4d/Ab3d.OculusWrap
Ab3d.OculusWrap/Ab3d.OculusWrap/TrackerFlags.cs
C#
mit
1,882
#include "googletest/googletest/include/gtest/gtest.h" #include "main.h" #include "mocks/mtxdb.h" #include "wallet.h" // how many times to run all the tests to have a chance to catch errors that only show up with particular // random shuffles #define RUN_TESTS 100 // some tests fail 1% of the time due to bad luck. // we repeat those tests this many times and only complain if all iterations of the test fail #define RANDOM_REPEATS 5 using namespace std; typedef set<pair<const CWalletTx*, unsigned int>> CoinSet; static CWallet wallet; static vector<COutput> vCoins; static void add_coin(int64_t nValue, int nAge = 6 * 24, bool fIsFromMe = false, int nInput = 0) { static int i; CTransaction tx; tx.nLockTime = i++; // so all transactions get different hashes tx.vout.resize(nInput + 1); tx.vout[nInput].nValue = nValue; CWalletTx* wtx = new CWalletTx(&wallet, tx); if (fIsFromMe) { // IsFromMe() returns (GetDebit() > 0), and GetDebit() is 0 if vin.empty(), // so stop vin being empty, and cache a non-zero Debit to fake out IsFromMe() wtx->vin.resize(1); wtx->c_DebitCached = 1; } COutput output(wtx, nInput, nAge); vCoins.push_back(output); } static void empty_wallet(void) { for (COutput output : vCoins) delete output.tx; vCoins.clear(); } static bool equal_sets(CoinSet a, CoinSet b) { pair<CoinSet::iterator, CoinSet::iterator> ret = mismatch(a.begin(), a.end(), b.begin()); return ret.first == a.end() && ret.second == b.end(); } TEST(wallet_tests, coin_selection_tests) { boost::shared_ptr<mTxDB> dbMock = boost::make_shared<mTxDB>(); EXPECT_CALL(*dbMock, GetBestChainHeight()) .WillRepeatedly(testing::Return(boost::make_optional<int>(0))); static CoinSet setCoinsRet, setCoinsRet2; static int64_t nValueRet; // test multiple times to allow for differences in the shuffle order for (int i = 0; i < RUN_TESTS; i++) { empty_wallet(); // with an empty wallet we can't even pay one cent EXPECT_TRUE(!wallet.SelectCoinsMinConf(*dbMock, 1 * CENT, GetAdjustedTime(), 1, 6, vCoins, setCoinsRet, nValueRet)); add_coin(1 * CENT, 4); // add a new 1 cent coin // with a new 1 cent coin, we still can't find a mature 1 cent EXPECT_TRUE(!wallet.SelectCoinsMinConf(*dbMock, 1 * CENT, GetAdjustedTime(), 1, 6, vCoins, setCoinsRet, nValueRet)); // but we can find a new 1 cent EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 1 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 1 * CENT); add_coin(2 * CENT); // add a mature 2 cent coin // we can't make 3 cents of mature coins EXPECT_TRUE(!wallet.SelectCoinsMinConf(*dbMock, 3 * CENT, GetAdjustedTime(), 1, 6, vCoins, setCoinsRet, nValueRet)); // we can make 3 cents of new coins EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 3 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 3 * CENT); add_coin(5 * CENT); // add a mature 5 cent coin, add_coin(10 * CENT, 3, true); // a new 10 cent coin sent from one of our own addresses add_coin(20 * CENT); // and a mature 20 cent coin // now we have new: 1+10=11 (of which 10 was self-sent), and mature: 2+5+20=27. total = 38 // we can't make 38 cents only if we disallow new coins: EXPECT_TRUE(!wallet.SelectCoinsMinConf(*dbMock, 38 * CENT, GetAdjustedTime(), 1, 6, vCoins, setCoinsRet, nValueRet)); // we can't even make 37 cents if we don't allow new coins even if they're from us EXPECT_TRUE(!wallet.SelectCoinsMinConf(*dbMock, 38 * CENT, GetAdjustedTime(), 6, 6, vCoins, setCoinsRet, nValueRet)); // but we can make 37 cents if we accept new coins from ourself EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 37 * CENT, GetAdjustedTime(), 1, 6, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 37 * CENT); // and we can make 38 cents if we accept all new coins EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 38 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 38 * CENT); // try making 34 cents from 1,2,5,10,20 - we can't do it exactly EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 34 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_GT(nValueRet, 34 * CENT); // but should get more than 34 cents EXPECT_EQ(setCoinsRet.size(), (unsigned)3); // the best should be 20+10+5. it's incredibly // unlikely the 1 or 2 got included (but possible) // when we try making 7 cents, the smaller coins (1,2,5) are enough. We should see just 2+5 EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 7 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 7 * CENT); EXPECT_EQ(setCoinsRet.size(), (unsigned)2); // when we try making 8 cents, the smaller coins (1,2,5) are exactly enough. EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 8 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_TRUE(nValueRet == 8 * CENT); EXPECT_EQ(setCoinsRet.size(), (unsigned)3); // when we try making 9 cents, no subset of smaller coins is enough, and we get the next bigger // coin (10) EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 9 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 10 * CENT); EXPECT_EQ(setCoinsRet.size(), (unsigned)1); // now clear out the wallet and start again to test choosing between subsets of smaller coins and // the next biggest coin empty_wallet(); add_coin(6 * CENT); add_coin(7 * CENT); add_coin(8 * CENT); add_coin(20 * CENT); add_coin(30 * CENT); // now we have 6+7+8+20+30 = 71 cents total // check that we have 71 and not 72 EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 71 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_TRUE(!wallet.SelectCoinsMinConf(*dbMock, 72 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); // now try making 16 cents. the best smaller coins can do is 6+7+8 = 21; not as good at the next // biggest coin, 20 EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 16 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 20 * CENT); // we should get 20 in one coin EXPECT_EQ(setCoinsRet.size(), (unsigned)1); add_coin(5 * CENT); // now we have 5+6+7+8+20+30 = 75 cents total // now if we try making 16 cents again, the smaller coins can make 5+6+7 = 18 cents, better than // the next biggest coin, 20 EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 16 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 18 * CENT); // we should get 18 in 3 coins EXPECT_EQ(setCoinsRet.size(), (unsigned)3); add_coin(18 * CENT); // now we have 5+6+7+8+18+20+30 // and now if we try making 16 cents again, the smaller coins can make 5+6+7 = 18 cents, the same // as the next biggest coin, 18 EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 16 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 18 * CENT); // we should get 18 in 1 coin EXPECT_EQ(setCoinsRet.size(), (unsigned)1); // because in the event of a tie, the biggest coin wins // now try making 11 cents. we should get 5+6 EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 11 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 11 * CENT); EXPECT_EQ(setCoinsRet.size(), (unsigned)2); // check that the smallest bigger coin is used add_coin(1 * COIN); add_coin(2 * COIN); add_coin(3 * COIN); add_coin(4 * COIN); // now we have 5+6+7+8+18+20+30+100+200+300+400 = 1094 cents EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 95 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 1 * COIN); // we should get 1 BTC in 1 coin EXPECT_EQ(setCoinsRet.size(), (unsigned)1); EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 195 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 2 * COIN); // we should get 2 BTC in 1 coin EXPECT_EQ(setCoinsRet.size(), (unsigned)1); // empty the wallet and start again, now with fractions of a cent, to test sub-cent change // avoidance empty_wallet(); add_coin(0.1 * CENT); add_coin(0.2 * CENT); add_coin(0.3 * CENT); add_coin(0.4 * CENT); add_coin(0.5 * CENT); // try making 1 cent from 0.1 + 0.2 + 0.3 + 0.4 + 0.5 = 1.5 cents // we'll get sub-cent change whatever happens, so can expect 1.0 exactly EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 1 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 1 * CENT); // but if we add a bigger coin, making it possible to avoid sub-cent change, things change: add_coin(1111 * CENT); // try making 1 cent from 0.1 + 0.2 + 0.3 + 0.4 + 0.5 + 1111 = 1112.5 cents EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 1 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 1 * CENT); // we should get the exact amount // if we add more sub-cent coins: add_coin(0.6 * CENT); add_coin(0.7 * CENT); // and try again to make 1.0 cents, we can still make 1.0 cents EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 1 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 1 * CENT); // we should get the exact amount // run the 'mtgox' test (see // http://blockexplorer.com/tx/29a3efd3ef04f9153d47a990bd7b048a4b2d213daaa5fb8ed670fb85f13bdbcf) // they tried to consolidate 10 50k coins into one 500k coin, and ended up with 50k in change empty_wallet(); for (int j = 0; j < 20; j++) add_coin(50000 * COIN); EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 500000 * COIN, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 500000 * COIN); // we should get the exact amount EXPECT_EQ(setCoinsRet.size(), (unsigned)10); // in ten coins // if there's not enough in the smaller coins to make at least 1 cent change (0.5+0.6+0.7 // < 1.0+1.0), we need to try finding an exact subset anyway // sometimes it will fail, and so we use the next biggest coin: empty_wallet(); add_coin(0.5 * CENT); add_coin(0.6 * CENT); add_coin(0.7 * CENT); add_coin(1111 * CENT); EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 1 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 1111 * CENT); // we get the bigger coin EXPECT_EQ(setCoinsRet.size(), (unsigned)1); // but sometimes it's possible, and we use an exact subset (0.4 + 0.6 = 1.0) empty_wallet(); add_coin(0.4 * CENT); add_coin(0.6 * CENT); add_coin(0.8 * CENT); add_coin(1111 * CENT); EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 1 * CENT, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 1 * CENT); // we should get the exact amount EXPECT_EQ(setCoinsRet.size(), (unsigned)2); // in two coins 0.4+0.6 // test avoiding sub-cent change empty_wallet(); add_coin(0.0005 * COIN); add_coin(0.01 * COIN); add_coin(1 * COIN); // trying to make 1.0001 from these three coins EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 1.0001 * COIN, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 1.0105 * COIN); // we should get all coins EXPECT_EQ(setCoinsRet.size(), (unsigned)3); // but if we try to make 0.999, we should take the bigger of the two small coins to avoid // sub-cent change EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 0.999 * COIN, GetAdjustedTime(), 1, 1, vCoins, setCoinsRet, nValueRet)); EXPECT_EQ(nValueRet, 1.01 * COIN); // we should get 1 + 0.01 EXPECT_EQ(setCoinsRet.size(), (unsigned)2); // test randomness { empty_wallet(); for (int i2 = 0; i2 < 100; i2++) add_coin(COIN); // picking 50 from 100 coins doesn't depend on the shuffle, // but does depend on randomness in the stochastic approximation code EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 50 * COIN, GetAdjustedTime(), 1, 6, vCoins, setCoinsRet, nValueRet)); EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 50 * COIN, GetAdjustedTime(), 1, 6, vCoins, setCoinsRet2, nValueRet)); EXPECT_TRUE(!equal_sets(setCoinsRet, setCoinsRet2)); int fails = 0; for (int j = 0; j < RANDOM_REPEATS; j++) { // selecting 1 from 100 identical coins depends on the shuffle; this test will fail 1% of // the time run the test RANDOM_REPEATS times and only complain if all of them fail EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, COIN, GetAdjustedTime(), 1, 6, vCoins, setCoinsRet, nValueRet)); EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, COIN, GetAdjustedTime(), 1, 6, vCoins, setCoinsRet2, nValueRet)); if (equal_sets(setCoinsRet, setCoinsRet2)) fails++; } EXPECT_NE(fails, RANDOM_REPEATS); // add 75 cents in small change. not enough to make 90 cents, // then try making 90 cents. there are multiple competing "smallest bigger" coins, // one of which should be picked at random add_coin(5 * CENT); add_coin(10 * CENT); add_coin(15 * CENT); add_coin(20 * CENT); add_coin(25 * CENT); fails = 0; for (int j = 0; j < RANDOM_REPEATS; j++) { // selecting 1 from 100 identical coins depends on the shuffle; this test will fail 1% of // the time run the test RANDOM_REPEATS times and only complain if all of them fail EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 90 * CENT, GetAdjustedTime(), 1, 6, vCoins, setCoinsRet, nValueRet)); EXPECT_TRUE(wallet.SelectCoinsMinConf(*dbMock, 90 * CENT, GetAdjustedTime(), 1, 6, vCoins, setCoinsRet2, nValueRet)); if (equal_sets(setCoinsRet, setCoinsRet2)) fails++; } EXPECT_NE(fails, RANDOM_REPEATS); } empty_wallet(); } }
NeblioTeam/neblio
wallet/test/wallet_tests.cpp
C++
mit
16,924
# coding:utf-8 require 'test_helper' class VacancyTest < ActiveSupport::TestCase test 'is invalid without a vacancy_id' do vacancy = Factory.build(:vacancy, :vacancy_id => nil) assert_equal false, vacancy.valid? end test '.to_solr_document' do vacancy = Factory.build(:vacancy, :vacancy_id => "TES/1234", :vacancy_title => "Testing Vacancy", :soc_code => "1234", :latitude => 51.0, :longitude => 1.0, :location_name => "Testing Town, County", :is_permanent => true, :hours => 25, :hours_display_text => "25 hours, flexible working", :wage_display_text => "Lots of cash", :vacancy_description => "Work for us", :employer_name => "Alphagov", :how_to_apply => "Send us an email", :received_on => Date.today ) document = DelSolr::Document.new document.add_field 'id', "TES/1234" document.add_field 'title', "Testing Vacancy", :cdata => true document.add_field 'soc_code', '1234' document.add_field 'location', [51.0, 1.0].join(",") document.add_field 'location_name', "Testing Town, County", :cdata => true document.add_field 'is_permanent', true document.add_field 'hours', 25 document.add_field 'hours_display_text', "25 hours, flexible working", :cdata => true document.add_field 'wage_display_text', "Lots of cash", :cdata => true document.add_field 'received_on', "#{Date.today.beginning_of_day.iso8601}Z" document.add_field 'vacancy_description', "Work for us", :cdata => true document.add_field 'employer_name', "Alphagov", :cdata => true document.add_field 'how_to_apply', 'Send us an email', :cdata => true document.add_field 'eligability_criteria', '', :cdata => true assert_equal document.xml, vacancy.to_solr_document.xml end test '.send_to_solr!' do vacancy = Factory.build(:vacancy) vacancy.stubs(:to_solr_document).returns(mock()) $solr.expects(:update!).with(vacancy.to_solr_document, :commitWithin => 300000).returns(true) assert_equal true, vacancy.send_to_solr! end test '.delete_from_solr' do vacancy = Factory.build(:vacancy) $solr.expects(:delete).with(vacancy.vacancy_id).returns(true) assert_equal true, vacancy.delete_from_solr end test '.import_details_from_hash' do vacancy_hash = {:currency=>"GBP", :date_received=>"30082011", :distance_sort_order_id=>"2396.97008934328", :es_vacancy=>"Y", :hours=>"35", :hours_display_text=>"37.5 HOURS OVER 5 DAYS", :hours_qualifier=>"per week", :is_national=>false, :is_regional=>false, :location=>{ :distance_from_origin=>"2396.97008934328", :latitude=>"50.986008297409", :longitude=>"0.9740371746526", :origin_latitude=>"51", :origin_longitude=>"1", :location_name=>"NEW ROMNEY, KENT"}, :location_display_text=>"NEW ROMNEY, KENT", :order_id=>"1", :perm_temp=>"P", :quality=>"86", :received_on=> Time.utc(2011, 8, 30, 0, 0, 0), :soc_code=>"3543", :vacancy_detail=>{ :hours=>"0", :soc_code=>"0"}, :vacancy_id=>"FOK/12116", :vacancy_title=>"CHARITY FUNDRAISER", :wage=>"See details", :wage_display_text=>"£255 TO £1000 PER WEEK", :wage_qualifier=>"NK", :wage_sort_order_id=>"20"} vacancy = Vacancy.new vacancy.import_details_from_hash(vacancy_hash) assert_equal vacancy.vacancy_title, vacancy_hash[:vacancy_title] assert_equal vacancy.received_on, vacancy_hash[:received_on] assert_equal vacancy.soc_code, vacancy_hash[:soc_code] assert_equal vacancy.wage, vacancy_hash[:wage] assert_equal vacancy.wage_qualifier, vacancy_hash[:wage_qualifier] assert_equal vacancy.wage_display_text, vacancy_hash[:wage_display_text] assert_equal vacancy.currency, vacancy_hash[:currency] assert_equal vacancy.is_national, vacancy_hash[:is_national] assert_equal vacancy.is_regional, vacancy_hash[:is_regional] assert_equal vacancy.hours, vacancy_hash[:hours].to_i assert_equal vacancy.hours_qualifier, vacancy_hash[:hours_qualifier] assert_equal vacancy.hours_display_text, vacancy_hash[:hours_display_text] assert_equal vacancy.location_name, vacancy_hash[:location][:location_name] assert_equal vacancy.latitude, vacancy_hash[:location][:latitude].to_f assert_equal vacancy.longitude, vacancy_hash[:location][:longitude].to_f assert_equal vacancy.is_permanent, true end end
gds-attic/jobs
test/unit/vacancy_test.rb
Ruby
mit
5,259
import { Durations } from '../../Constants.js'; const DrawCard = require('../../drawcard.js'); const AbilityDsl = require('../../abilitydsl.js'); class MatsuKoso extends DrawCard { setupCardAbilities() { this.action({ title: 'Lower military skill', condition: context => context.source.isParticipating(), gameAction: AbilityDsl.actions.cardLastingEffect(context => ({ target: context.game.currentConflict.getParticipants(), duration: Durations.UntilEndOfConflict, effect: AbilityDsl.effects.modifyMilitarySkill(card => isNaN(card.printedPoliticalSkill) ? 0 : -card.printedPoliticalSkill) })), effect: 'lower the military skill of {1} by their respective pirnted political skill', effectArgs: context => [context.game.currentConflict.getParticipants()] }); } } MatsuKoso.id = 'matsu-koso'; module.exports = MatsuKoso;
gryffon/ringteki
server/game/cards/12-SoW/MastuKoso.js
JavaScript
mit
964
package typhon import ( "context" "net/http" "testing" "github.com/monzo/terrors" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" ) func TestExpirationFilter(t *testing.T) { t.Parallel() svc := Service(func(req Request) Response { return req.Response("ok") }) svc = svc.Filter(ExpirationFilter) // An unexpired request should be allowed through req := NewRequest(context.Background(), "GET", "/", nil) rsp := svc(req) assert.NoError(t, rsp.Error) assert.Equal(t, http.StatusOK, rsp.StatusCode) b, err := rsp.BodyBytes(true) require.NoError(t, err) assert.Equal(t, []byte(`"ok"`+"\n"), b) // An expired request should be rejected ctx, ccl := context.WithCancel(context.Background()) ccl() req.Context = ctx rsp = svc(req) assert.Error(t, rsp.Error) terr := terrors.Wrap(rsp.Error, nil).(*terrors.Error) terrExpect := terrors.BadRequest("expired", "Request has expired", nil) assert.Equal(t, terrExpect.Message, terr.Message) assert.Equal(t, terrExpect.Code, terr.Code) }
monzo/typhon
expire_test.go
GO
mit
1,033
#include <iostream> #include <vector> #include <cstdlib> #include <ctime> #include <queue> #include "queue.h" #include "../test_helpers.h" template<template<typename T> class ConcreteQueue> void test_queue(TestHelper& th) { { th.message("Default construction"); ConcreteQueue<int> q; th.tassert(); th.message("Destruction"); } th.tassert(); { ConcreteQueue<int> q; th.tassert(q.empty(), true, "Initially empty"); th.tassert(q.size(), (std::size_t)0, "Initially size is 0"); q.enqueue(7); th.tassert(q.empty(), false, "Not empty after pushing element 7"); th.tassert(q.size(), (std::size_t)1, "Size is 1"); q.enqueue(8); th.tassert(q.empty(), false, "Not empty after pushing element 8"); th.tassert(q.size(), (std::size_t)2, "Size is 2"); { th.message("Copy construction"); ConcreteQueue<int> cq(q); th.tassert(); th.tassert(q.to_std_queue() == cq.to_std_queue(), true, "Equal queues"); th.message("Destruction"); } th.tassert(); { th.message("Operator="); ConcreteQueue<int> oeq; oeq = q; th.tassert(); th.tassert(q.to_std_queue() == oeq.to_std_queue(), true, "Equal queues"); th.message("Destruction"); } th.tassert(); { th.message("Move semantics construction"); ConcreteQueue<int> mq(ConcreteQueue<int>{q}); th.tassert(); th.tassert(q.to_std_queue() == mq.to_std_queue(), true, "Equal queues"); th.message("Destruction"); } th.tassert(); { th.message("Pop"); int last = q.dequeue(); th.tassert(); th.tassert(last, 7, "popped == 7"); th.tassert(q.empty(), false, "Not empty"); th.tassert(q.size(), (std::size_t)1, "Size is 1"); } { th.message("Pop"); int last = q.dequeue(); th.tassert(); th.tassert(last, 8, "popped == 8"); th.tassert(q.empty(), true, "Empty"); th.tassert(q.size(), (std::size_t)0, "Size is 0"); } } std::srand((unsigned int)std::time(0)); { ConcreteQueue<int> q; std::queue<int> stdq; th.message("Stress test push"); for(int i = 0; i < 900; ++i) { th.tassert(q.size(), stdq.size(), "Size", true); th.tassert(q.empty(), stdq.empty(), "Empty", true); int r = std::rand(); q.enqueue(r); stdq.push(r); th.tassert(q.to_std_queue() == stdq, true, "Equal queues", true); } th.tassert(); th.message("Stress test pop"); for(int i = 0; i < 500; ++i) { th.tassert(q.size(), stdq.size(), "Size", true); th.tassert(q.empty(), stdq.empty(), "Empty", true); th.tassert(q.to_std_queue() == stdq, true, "Equal queues", true); q.dequeue(); stdq.pop(); } th.tassert(); th.message("Stress test past end"); for(int i = 0; i < 300; ++i) { th.tassert(q.size(), stdq.size(), "Size", true); th.tassert(q.empty(), stdq.empty(), "Empty", true); int r = std::rand(); q.enqueue(r); stdq.push(r); th.tassert(q.to_std_queue() == stdq, true, "Equal queues", true); } th.tassert(); th.message("Stress test pop"); for(int i = 0; i < 500; ++i) { th.tassert(q.size(), stdq.size(), "Size", true); th.tassert(q.empty(), stdq.empty(), "Empty", true); th.tassert(q.to_std_queue() == stdq, true, "Equal queues", true); q.dequeue(); stdq.pop(); } th.tassert(); } } int main(int argc, char const *argv[]) { TestHelper th; std::cout << "[[ List-based Queue ]]" << std::endl << std::endl; test_queue<ListQueue>(th); std::cout << std::endl << "[[ Circular-buffer-based Queue ]]" << std::endl << std::endl; test_queue<CircularBufferQueue>(th); th.summary(); return 0; }
fcarreiro/crashingthecode
structures/queue.test.cc
C++
mit
3,768
// // Copyright (c) 2016 Terry Seyler // // Distributed under the MIT License // See accompanying file LICENSE.md // #include <boost/bind.hpp> #include <core/server/proto_tcp_text_server.hpp> #include <core/client/proto_tcp_text_client.hpp> using namespace boost::asio::ip; namespace proto_net { using namespace client; namespace server { proto_tcp_text_server* proto_tcp_text_server::proto_tcp_text_server_cast(proto_service_ptr ps_ptr) { return dynamic_cast<proto_tcp_text_server*>(ps_ptr.get()); } proto_tcp_text_server::proto_tcp_text_server(unsigned short port_num /* = 80*/) : proto_tcp_server(port_num) {} proto_tcp_text_server::proto_tcp_text_server(proto_net_service_ptr ps_service, unsigned short port_num /*= 80 */) : proto_tcp_server(ps_service, port_num) {} proto_tcp_text_server::proto_tcp_text_server(proto_tcp_text_server& ps) : proto_tcp_server(dynamic_cast<proto_tcp_server&>(ps)) {} void proto_tcp_text_server::ps_start_accept(proto_net_pipeline& ps_pipeline, size_t buffer_size) { proto_tcp_text_session* new_session = new proto_tcp_text_session(ps_service_, ps_pipeline, buffer_size); acceptor_.async_accept(new_session->ps_socket(), boost::bind(&proto_tcp_text_server::handle_accept, this, new_session, boost::asio::placeholders::error)); } void proto_tcp_text_server::handle_accept(proto_tcp_text_session* session, const proto_net_error_code& error) { if (session) { proto_net_pipeline& pipeline = session->ps_pipeline(); // get the session before it gets destroyed below proto_async_io* ds_io = pipeline.ps_proto_io(); // get the downstream io if (ds_io) { proto_tcp_text_client* tcp_client = dynamic_cast<proto_tcp_text_client*>(ds_io); // we are tcp client? if (tcp_client) { proto_net_pipeline& upstream_pipeline = tcp_client->ps_pipeline(); upstream_pipeline.ps_proto_io(session); // set the upstream io to the session } } size_t buffer_size = session->ps_buffer_size(); notify_server_listeners(session); if (!error) session->ps_start(); else delete session; ps_start_accept(pipeline, buffer_size); } else {} // we will drop out because there is no session and no io } } }
tseyler/proto-server
proto_server/core/server/proto_tcp_text_server.cpp
C++
mit
2,872