text
stringlengths
2
100k
meta
dict
// CodeMirror, copyright (c) by Marijn Haverbeke and others // Distributed under an MIT license: http://codemirror.net/LICENSE /* DTD mode Ported to CodeMirror by Peter Kroon <[email protected]> Report bugs/issues here: https://github.com/codemirror/CodeMirror/issues GitHub: @peterkroon */ (function(mod) { if (typeof exports == "object" && typeof module == "object") // CommonJS mod(require("../../lib/codemirror")); else if (typeof define == "function" && define.amd) // AMD define(["../../lib/codemirror"], mod); else // Plain browser env mod(CodeMirror); })(function(CodeMirror) { "use strict"; CodeMirror.defineMode("dtd", function(config) { var indentUnit = config.indentUnit, type; function ret(style, tp) {type = tp; return style;} function tokenBase(stream, state) { var ch = stream.next(); if (ch == "<" && stream.eat("!") ) { if (stream.eatWhile(/[\-]/)) { state.tokenize = tokenSGMLComment; return tokenSGMLComment(stream, state); } else if (stream.eatWhile(/[\w]/)) return ret("keyword", "doindent"); } else if (ch == "<" && stream.eat("?")) { //xml declaration state.tokenize = inBlock("meta", "?>"); return ret("meta", ch); } else if (ch == "#" && stream.eatWhile(/[\w]/)) return ret("atom", "tag"); else if (ch == "|") return ret("keyword", "seperator"); else if (ch.match(/[\(\)\[\]\-\.,\+\?>]/)) return ret(null, ch);//if(ch === ">") return ret(null, "endtag"); else else if (ch.match(/[\[\]]/)) return ret("rule", ch); else if (ch == "\"" || ch == "'") { state.tokenize = tokenString(ch); return state.tokenize(stream, state); } else if (stream.eatWhile(/[a-zA-Z\?\+\d]/)) { var sc = stream.current(); if( sc.substr(sc.length-1,sc.length).match(/\?|\+/) !== null )stream.backUp(1); return ret("tag", "tag"); } else if (ch == "%" || ch == "*" ) return ret("number", "number"); else { stream.eatWhile(/[\w\\\-_%.{,]/); return ret(null, null); } } function tokenSGMLComment(stream, state) { var dashes = 0, ch; while ((ch = stream.next()) != null) { if (dashes >= 2 && ch == ">") { state.tokenize = tokenBase; break; } dashes = (ch == "-") ? dashes + 1 : 0; } return ret("comment", "comment"); } function tokenString(quote) { return function(stream, state) { var escaped = false, ch; while ((ch = stream.next()) != null) { if (ch == quote && !escaped) { state.tokenize = tokenBase; break; } escaped = !escaped && ch == "\\"; } return ret("string", "tag"); }; } function inBlock(style, terminator) { return function(stream, state) { while (!stream.eol()) { if (stream.match(terminator)) { state.tokenize = tokenBase; break; } stream.next(); } return style; }; } return { startState: function(base) { return {tokenize: tokenBase, baseIndent: base || 0, stack: []}; }, token: function(stream, state) { if (stream.eatSpace()) return null; var style = state.tokenize(stream, state); var context = state.stack[state.stack.length-1]; if (stream.current() == "[" || type === "doindent" || type == "[") state.stack.push("rule"); else if (type === "endtag") state.stack[state.stack.length-1] = "endtag"; else if (stream.current() == "]" || type == "]" || (type == ">" && context == "rule")) state.stack.pop(); else if (type == "[") state.stack.push("["); return style; }, indent: function(state, textAfter) { var n = state.stack.length; if( textAfter.match(/\]\s+|\]/) )n=n-1; else if(textAfter.substr(textAfter.length-1, textAfter.length) === ">"){ if(textAfter.substr(0,1) === "<")n; else if( type == "doindent" && textAfter.length > 1 )n; else if( type == "doindent")n--; else if( type == ">" && textAfter.length > 1)n; else if( type == "tag" && textAfter !== ">")n; else if( type == "tag" && state.stack[state.stack.length-1] == "rule")n--; else if( type == "tag")n++; else if( textAfter === ">" && state.stack[state.stack.length-1] == "rule" && type === ">")n--; else if( textAfter === ">" && state.stack[state.stack.length-1] == "rule")n; else if( textAfter.substr(0,1) !== "<" && textAfter.substr(0,1) === ">" )n=n-1; else if( textAfter === ">")n; else n=n-1; //over rule them all if(type == null || type == "]")n--; } return state.baseIndent + n * indentUnit; }, electricChars: "]>" }; }); CodeMirror.defineMIME("application/xml-dtd", "dtd"); });
{ "pile_set_name": "Github" }
// Copyright (c) 2001-2011 Hartmut Kaiser // // Distributed under the Boost Software License, Version 1.0. (See accompanying // file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) #if !defined(SPIRIT_STRICT_RELAXED_APR_22_2010_0959AM) #define SPIRIT_STRICT_RELAXED_APR_22_2010_0959AM #if defined(_MSC_VER) #pragma once #endif #include <boost/spirit/home/support/common_terminals.hpp> #include <boost/spirit/home/support/modify.hpp> #include <boost/spirit/home/karma/domain.hpp> #include <boost/spirit/home/karma/meta_compiler.hpp> namespace boost { namespace spirit { /////////////////////////////////////////////////////////////////////////// // Enablers /////////////////////////////////////////////////////////////////////////// template <> struct use_directive<karma::domain, tag::strict> // enables strict[] : mpl::true_ {}; template <> struct use_directive<karma::domain, tag::relaxed> // enables relaxed[] : mpl::true_ {}; /////////////////////////////////////////////////////////////////////////// template <> struct is_modifier_directive<karma::domain, tag::strict> : mpl::true_ {}; template <> struct is_modifier_directive<karma::domain, tag::relaxed> : mpl::true_ {}; /////////////////////////////////////////////////////////////////////////// // Don't add tag::strict or tag::relaxed if there is already one of those // in the modifier list template <typename Current> struct compound_modifier<Current, tag::strict , typename enable_if<has_modifier<Current, tag::relaxed> >::type> : Current { compound_modifier() : Current() {} compound_modifier(Current const& current, tag::strict const&) : Current(current) {} }; template <typename Current> struct compound_modifier<Current, tag::relaxed , typename enable_if<has_modifier<Current, tag::strict> >::type> : Current { compound_modifier() : Current() {} compound_modifier(Current const& current, tag::relaxed const&) : Current(current) {} }; namespace karma { #ifndef BOOST_SPIRIT_NO_PREDEFINED_TERMINALS using boost::spirit::strict; using boost::spirit::relaxed; #endif using boost::spirit::strict_type; using boost::spirit::relaxed_type; } }} #endif
{ "pile_set_name": "Github" }
// Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. See LICENSE.TXT file in the project root for full license information. #include "precomp.h" #include "CFrostCore.h" #include "CFrostEngine.h" #include "IFrostUserExperience.h" #include "shim.h" using namespace System; using namespace System::Windows::Forms; using namespace System::Runtime::InteropServices; namespace Microsoft { namespace Tools { namespace WindowsInstallerXml { namespace Test { namespace Frost { CFrostEngine::CFrostEngine() { } CFrostEngine::~CFrostEngine() { Uninitialize(); } HRESULTS CFrostEngine::CreateUX(Int32 appHwnd, SETUP_COMMAND setupCommand, IFrostUserExperience^% uxRef) { // TODO: ALSO NEED TO CREATE THE MOCK BURNCORE OBJECT HRESULTS hr = HRESULTS::HR_S_OK; if (UxModule == nullptr) { UxModule = ::LoadLibrary(L"UXEntryPoint.dll"); if( UxModule == nullptr ) { UInt32 err = (UInt32)::GetLastError(); String^ msg = String::Empty; msg->Format("LoadLibrary failed: %x", err); System::Windows::Forms::MessageBox::Show(msg); hr = HRESULTS::HR_FAILURE; } else { PFN_CREATE_USER_EXPERIENCE func = reinterpret_cast<PFN_CREATE_USER_EXPERIENCE>(::GetProcAddress(UxModule, "SetupUXCreate")); //FARPROC func = ::GetProcAddress(UxModule, "CreateUserExperience"); if( func == nullptr ) { System::Windows::Forms::MessageBox::Show("GetProcAddress failed"); hr = HRESULTS::HR_FAILURE; } else { // TODO: use setupCommand BURN_COMMAND cmd; cmd.action = BURN_ACTION_INSTALL; //cmd.display = BURN_DISPLAY_NONE; //cmd.display = BURN_DISPLAY_PASSIVE; cmd.display = BURN_DISPLAY_FULL; cmd.restart = BURN_RESTART_NEVER; pin_ptr<IBurnUserExperience *> p = &pUX; HRESULT result = func(&cmd, p); if( S_OK != result ) { if( ERROR_NOT_SUPPORTED == result ) { System::Windows::Forms::MessageBox::Show(".NET was not found"); } else { System::Windows::Forms::MessageBox::Show("CreateUserExperience failed"); } hr = HRESULTS::HR_FAILURE; } else { FrostCore = gcnew BurnCoreWrapper; if (FrostCore == nullptr) { hr = HRESULTS::HR_FAILURE; } else { FrostCore->pBurnCore = new CFrostCore; burnCoreGCHandle = GCHandle::Alloc(FrostCore, GCHandleType::Pinned); hr = HRESULTS::HR_S_OK; } } } } } else { hr = HRESULTS::HR_S_FALSE; } if (hr == HRESULTS::HR_S_OK) { uxRef = UXProxy = gcnew CFrostEngine(); } return hr; } HRESULTS CFrostEngine::Initialize(Int32 nCmdShow, SETUP_RESUME ResumeState) { BURN_RESUME_TYPE RealBurnInitResumeValue = BURN_RESUME_TYPE_NONE; switch(ResumeState) { case SETUP_RESUME::SETUP_RESUME_NONE: RealBurnInitResumeValue = BURN_RESUME_TYPE_NONE; break; case SETUP_RESUME::SETUP_RESUME_INVALID: RealBurnInitResumeValue = BURN_RESUME_TYPE_INVALID; break; case SETUP_RESUME::SETUP_RESUME_UNEXPECTED: RealBurnInitResumeValue = BURN_RESUME_TYPE_UNEXPECTED; break; case SETUP_RESUME::SETUP_RESUME_REBOOT_PENDING: RealBurnInitResumeValue = BURN_RESUME_TYPE_REBOOT_PENDING; break; case SETUP_RESUME::SETUP_RESUME_REBOOT: RealBurnInitResumeValue = BURN_RESUME_TYPE_REBOOT; break; case SETUP_RESUME::SETUP_RESUME_SUSPEND: RealBurnInitResumeValue = BURN_RESUME_TYPE_SUSPEND; break; case SETUP_RESUME::SETUP_RESUME_ARP: RealBurnInitResumeValue = BURN_RESUME_TYPE_ARP; break; } HRESULT hr = pUX->Initialize(FrostCore->pBurnCore, 0,RealBurnInitResumeValue); if (hr == S_OK) { return HRESULTS::HR_S_OK; } else { return HRESULTS::HR_FAILURE; } } HRESULTS CFrostEngine::Run() { HRESULT hr = pUX->Run(); if (hr == S_OK) { return HRESULTS::HR_S_OK; } else { return HRESULTS::HR_FAILURE; } } void CFrostEngine::Uninitialize() { if (pUX != nullptr) { pUX->Uninitialize(); delete pUX; pUX = nullptr; } if (burnCoreGCHandle.IsAllocated) { burnCoreGCHandle.Free(); } if (FrostCore != nullptr) { if (FrostCore->pBurnCore != nullptr) { delete FrostCore->pBurnCore; FrostCore->pBurnCore = nullptr; } } if (UxModule != nullptr) { ::FreeLibrary(UxModule); // unload UxModule = nullptr; } return; } CommandID CFrostEngine::OnDectectBegin(UInt32 cPackages) { int retValue = pUX->OnDetectBegin(cPackages); CommandID cmdId = (CommandID)retValue; return cmdId; } CommandID CFrostEngine::OnDetectPackageBegin(String^ wzPackageId) { pin_ptr<const wchar_t> cwch = PtrToStringChars(wzPackageId); int retValue = pUX->OnDetectPackageBegin(cwch); CommandID cmdId = (CommandID)retValue; return cmdId; } void CFrostEngine::OnDetectPackageComplete(String^ wzPackageId, HRESULTS hrStatus, CUR_PACKAGE_STATE state) { pin_ptr<const wchar_t> cwch = PtrToStringChars(wzPackageId); PACKAGE_STATE pkgState = GetPkgState(state); pUX->OnDetectPackageComplete(cwch, GetHRESULT(hrStatus), pkgState); } void CFrostEngine::OnDetectComplete(HRESULTS hrStatus) { pUX->OnDetectComplete(GetHRESULT(hrStatus)); } HRESULT CFrostEngine::GetHRESULT(HRESULTS hrStatus) { int temp = (int)hrStatus; HRESULT hr; switch(temp) { case 0: hr = S_OK; break; case 1: hr = S_FALSE; break; default: hr = E_FAIL; break; } return hr; } REQUEST_STATE CFrostEngine::GetReqState(PKG_REQUEST_STATE reqState) { REQUEST_STATE pkgState; switch(safe_cast<int>(reqState)) { case REQUEST_STATE_ABSENT: pkgState = REQUEST_STATE_ABSENT; break; case REQUEST_STATE_CACHE: pkgState = REQUEST_STATE_CACHE; break; case REQUEST_STATE_PRESENT: pkgState = REQUEST_STATE_PRESENT; break; case REQUEST_STATE_REPAIR: pkgState = REQUEST_STATE_REPAIR; break; default: pkgState = REQUEST_STATE_NONE; break; } return pkgState; } PACKAGE_STATE CFrostEngine::GetPkgState(CUR_PACKAGE_STATE state) { PACKAGE_STATE pkgState; switch(safe_cast<int>(state)) { case PACKAGE_STATE_ABSENT: pkgState = PACKAGE_STATE_ABSENT; break; case PACKAGE_STATE_CACHED: pkgState = PACKAGE_STATE_CACHED; break; case PACKAGE_STATE_PRESENT: pkgState = PACKAGE_STATE_PRESENT; break; default: pkgState = PACKAGE_STATE_UNKNOWN; break; } return pkgState; } ACTION_STATE CFrostEngine::GetPkgActionState(PKG_ACTION_STATE state) { ACTION_STATE actionState; switch(safe_cast<int>(state)) { case ACTION_STATE_UNINSTALL: actionState = ACTION_STATE_UNINSTALL; break; case ACTION_STATE_INSTALL: actionState = ACTION_STATE_INSTALL; break; case ACTION_STATE_ADMIN_INSTALL: actionState = ACTION_STATE_ADMIN_INSTALL; break; case ACTION_STATE_MAINTENANCE: actionState = ACTION_STATE_MAINTENANCE; break; case ACTION_STATE_RECACHE: actionState = ACTION_STATE_RECACHE; break; case ACTION_STATE_MINOR_UPGRADE: actionState = ACTION_STATE_MINOR_UPGRADE; break; case ACTION_STATE_MAJOR_UPGRADE: actionState = ACTION_STATE_MAJOR_UPGRADE; break; case ACTION_STATE_PATCH: actionState = ACTION_STATE_PATCH; break; default: actionState = ACTION_STATE_NONE; break; } return actionState; } CommandID CFrostEngine::OnPlanBegin(UInt32 cPackages) { int retValue = pUX->OnPlanBegin(cPackages); CommandID cmdId = (CommandID)retValue; return cmdId; } CommandID CFrostEngine::OnPlanPackageBegin(String^ wzPackageId, PKG_REQUEST_STATE% reqState) { pin_ptr<const wchar_t> cwch = PtrToStringChars(wzPackageId); REQUEST_STATE pkgState = GetReqState(reqState); int retValue = pUX->OnPlanPackageBegin(cwch, &pkgState); reqState = safe_cast<PKG_REQUEST_STATE>(safe_cast<int>(pkgState)); CommandID cmdId = (CommandID)retValue; return cmdId; } void CFrostEngine::OnPlanPackageComplete(String^ wzPackageId,HRESULTS hrStatus,CUR_PACKAGE_STATE state,PKG_REQUEST_STATE requested,PKG_ACTION_STATE execute,PKG_ACTION_STATE rollback) { pin_ptr<const wchar_t> cwch = PtrToStringChars(wzPackageId); pUX->OnPlanPackageComplete(cwch, GetHRESULT(hrStatus), GetPkgState(state), GetReqState(requested), GetPkgActionState(execute), GetPkgActionState(rollback)); } void CFrostEngine::OnPlanComplete(HRESULTS hrStatus) { pUX->OnPlanComplete(GetHRESULT(hrStatus)); } CommandID CFrostEngine::OnApplyBegin() { int retValue = pUX->OnApplyBegin(); CommandID cmdId = (CommandID)retValue; return cmdId; } CommandID CFrostEngine::OnRegisterBegin() { int retValue = pUX->OnRegisterBegin(); CommandID cmdId = (CommandID)retValue; return cmdId; } void CFrostEngine::OnRegisterComplete(HRESULTS hrStatus) { pUX->OnRegisterComplete(GetHRESULT(hrStatus)); } void CFrostEngine::OnUnregisterBegin() { pUX->OnUnregisterBegin(); } void CFrostEngine::OnUnregisterComplete(HRESULTS hrStatus) { pUX->OnUnregisterComplete(GetHRESULT(hrStatus)); } void CFrostEngine::OnCacheComplete(HRESULTS hrStatus) { pUX->OnCacheComplete(GetHRESULT(hrStatus)); } CommandID CFrostEngine::OnExecuteBegin(UInt32 cExecutingPackages) { int retValue = pUX->OnExecuteBegin(cExecutingPackages); CommandID cmdId = (CommandID)retValue; return cmdId; } CommandID CFrostEngine::OnExecutePackageBegin(String^ wzPackageId, bool fExecute) { // TODO: This used to be disabled for some reason... pin_ptr<const wchar_t> cwch = PtrToStringChars(wzPackageId); int retValue = pUX->OnExecutePackageBegin(cwch, fExecute); CommandID cmdId = (CommandID)retValue; return cmdId; } CommandID CFrostEngine::OnError(String^ wzPackageId, UInt32 dwCode, String^ wzError, UInt32 dwUIHint) { pin_ptr<const wchar_t> cwch = PtrToStringChars(wzError); pin_ptr<const wchar_t> cwch2 = PtrToStringChars(wzPackageId); int retValue = pUX->OnError(cwch2, dwCode, cwch, dwUIHint); CommandID cmdId = (CommandID)retValue; return cmdId; } CommandID CFrostEngine::OnProgress(UInt32 dwProgressPercentage, UInt32 dwOverallPercentage) { int retValue = pUX->OnProgress(dwProgressPercentage, dwOverallPercentage); CommandID cmdId = (CommandID)retValue; return cmdId; } CommandID CFrostEngine::OnExecuteMsiMessage(String^ wzPackageID, INSTALLMESSAGE mt, UInt32 uiFlags, String^ wzMessage) { pin_ptr<const wchar_t> cwch = PtrToStringChars(wzPackageID); pin_ptr<const wchar_t> cwch2 = PtrToStringChars(wzMessage); int retValue = pUX->OnExecuteMsiMessage(cwch, mt, uiFlags, cwch2); CommandID cmdId = (CommandID)retValue; return cmdId; } void CFrostEngine::OnExecutePackageComplete(String^ wzPackageId, HRESULTS hrExitCode) { // TODO: This was disabled for some reason pin_ptr<const wchar_t> cwch = PtrToStringChars(wzPackageId); pUX->OnExecutePackageComplete(cwch, GetHRESULT(hrExitCode)); } void CFrostEngine::OnExecuteComplete(HRESULTS hrStatus) { pUX->OnExecuteComplete(GetHRESULT(hrStatus)); } bool CFrostEngine::OnRestartRequired() { return (bool)pUX->OnRestartRequired(); } void CFrostEngine::OnApplyComplete(HRESULTS hrStatus) { pUX->OnApplyComplete(GetHRESULT(hrStatus)); } int CFrostEngine::ResolveSource(String^ wzPackageID, String^ wzPackageOrContainerPath) { pin_ptr<const wchar_t> cwch = PtrToStringChars(wzPackageID); pin_ptr<const wchar_t> cwch2 = PtrToStringChars(wzPackageOrContainerPath); int RetVal = pUX->ResolveSource(cwch,cwch2); return RetVal; } bool CFrostEngine::CanPackageBeDownloaded() { bool RetVal = pUX->CanPackagesBeDownloaded(); return RetVal; } HRESULTS CFrostEngine::GetPackageCount(UInt32% numPackages) { HRESULTS hr; if (UXProxy != nullptr) { PackageCountEventArgs^ e = gcnew PackageCountEventArgs(); UXProxy->GetPackageCountEvent(UXProxy, e); numPackages = e->PackageCount; hr = e->ResultToReturn; } else { numPackages = 0; hr = HRESULTS::HR_FAILURE; } return hr; } HRESULTS CFrostEngine::GetCommandLineParameters(String^% cmdLine, UInt32% pcchCommandLine) { HRESULTS hr; if (UXProxy != nullptr) { StringEventArgs^ e = gcnew StringEventArgs(); UXProxy->GetCommandLineEvent(UXProxy, e); if (e->StringValue != nullptr) { cmdLine = e->StringValue; } else { cmdLine = String::Empty; } hr = e->ResultToReturn; } else { cmdLine = String::Empty; hr = HRESULTS::HR_FAILURE; } return hr; } HRESULTS CFrostEngine::GetPropertyNumeric(String^ propertyName, Int64% propertyValue) { HRESULTS hr; if(UXProxy != nullptr) { LongIntEventArgs^ e = gcnew LongIntEventArgs(); e->StringValue = propertyName; UXProxy->GetVariableNumericEvent(UXProxy,e); propertyValue = e->Number; hr = e->ResultToReturn; } else { hr = HRESULTS::HR_S_FALSE; } return hr; } HRESULTS CFrostEngine::GetPropertyString(String^ propertyName, String^% propertyValue, UInt64% StringSize) { HRESULTS hr; if(UXProxy != nullptr) { StringVariableEventArgs^ e = gcnew StringVariableEventArgs(); e->StringName = propertyName; UXProxy->GetVariableStringEvent(UXProxy,e); propertyValue = e->StringValue; StringSize = (UInt64)e->DWordValue; hr = e->ResultToReturn; } else { hr = HRESULTS::HR_S_FALSE; } return hr; } HRESULTS CFrostEngine::GetPropertyVersion(String^ propertyName, UInt64% propertyValue) { HRESULTS hr; if(UXProxy != nullptr) { LongIntEventArgs^ e = gcnew LongIntEventArgs(); e->StringValue = propertyName; UXProxy->GetVariableVersionEvent(UXProxy,e); propertyValue = e->Number; hr = e->ResultToReturn; } else { hr = HRESULTS::HR_S_FALSE; } return hr; } HRESULTS CFrostEngine::SetPropertyNumeric(String^ propertyName, Int64 propertyValue) { HRESULTS hr; if(UXProxy != nullptr) { LongIntEventArgs^ e = gcnew LongIntEventArgs(); e->StringValue = propertyName; e->Number = propertyValue; UXProxy->SetVariableNumericEvent(UXProxy,e); hr = e->ResultToReturn; } else { hr = HRESULTS::HR_S_FALSE; } return hr; } HRESULTS CFrostEngine::SetPropertyString(String^ propertyName, String^ propertyValue) { HRESULTS hr; if(UXProxy != nullptr) { StringVariableEventArgs^ e = gcnew StringVariableEventArgs(); e->StringName = propertyName; e->StringValue = propertyValue; UXProxy->SetVariableStringEvent(UXProxy,e); hr = e->ResultToReturn; } else { hr = HRESULTS::HR_S_FALSE; } return hr; } HRESULTS CFrostEngine::SetPropertyVersion(String^ propertyName, UInt64 propertyValue) { HRESULTS hr; if(UXProxy != nullptr) { LongIntEventArgs^ e = gcnew LongIntEventArgs(); e->StringValue = propertyName; e->Number = propertyValue; UXProxy->SetVariableVersionEvent(UXProxy,e); hr = e->ResultToReturn; } else { hr = HRESULTS::HR_S_FALSE; } return hr; } HRESULTS CFrostEngine::FormatPropertyString(String^ strIn, String^% strInOut, UInt64% StringSize) { HRESULTS hr; if(UXProxy != nullptr) { FormatStringEventArgs^ e = gcnew FormatStringEventArgs(); e->InValue = strIn; e->InOutValue = strInOut; UXProxy->FormatStringEvent(UXProxy,e); strInOut = e->InOutValue; StringSize = strInOut->Length; hr = e->ResultToReturn; } else { hr = HRESULTS::HR_S_FALSE; } return hr; } HRESULTS CFrostEngine::EscapeString(String^ wzIn, String^% wzOut) { HRESULTS hr; if(UXProxy != nullptr) { FormatStringEventArgs^ e = gcnew FormatStringEventArgs(); e->InValue = wzIn; UXProxy->EscapeStringEvent(UXProxy,e); wzOut = e->InOutValue; hr = e->ResultToReturn; } else { hr = HRESULTS::HR_S_FALSE; } return hr; } HRESULTS CFrostEngine::EvaluateCondition(String^ conditionName, bool% conditionValue) { HRESULTS hr; if(UXProxy != nullptr) { ConditionalEventArgs^ e = gcnew ConditionalEventArgs(); e->StringValue = conditionName; UXProxy->EvaluateConditionEvent(UXProxy,e); conditionValue = e->EvalResult; hr = e->ResultToReturn; } else { hr = HRESULTS::HR_S_FALSE; } return HRESULTS::HR_S_OK; } HRESULTS CFrostEngine::Elevate(/*__in_opt*/ IntPtr^ hwndParent) { // TODO: hwndParent IS IGNORED FOR NOW, NOT QUITE SURE HOW IT IS USED ANYHOW HRESULTS hr; if (UXProxy != nullptr) { ResultReturnArgs^ e = gcnew ResultReturnArgs(); UXProxy->ElevateEvent(UXProxy, e); hr = e->ResultToReturn; } else { hr = HRESULTS::HR_FAILURE; } return hr; } HRESULTS CFrostEngine::Detect() { HRESULTS hr; if (UXProxy != nullptr) { ResultReturnArgs^ e = gcnew ResultReturnArgs(); UXProxy->DetectEvent(UXProxy, e); hr = e->ResultToReturn; } else { hr = HRESULTS::HR_FAILURE; } return hr; } HRESULTS CFrostEngine::Plan(SETUP_ACTION action) { HRESULTS hr; if (UXProxy != nullptr) { SetupActionArgs^ e = gcnew SetupActionArgs(action); UXProxy->PlanEvent(UXProxy, e); hr = e->ResultToReturn; } else { hr = HRESULTS::HR_FAILURE; } return hr; } HRESULTS CFrostEngine::Apply(/*__in_opt*/ IntPtr^ hwndParent) { // TODO: hwndParent IS IGNORED FOR NOW, NOT QUITE SURE HOW IT IS USED ANYHOW HRESULTS hr; if (UXProxy != nullptr) { ResultReturnArgs^ e = gcnew ResultReturnArgs(); UXProxy->ApplyEvent(UXProxy, e); hr = e->ResultToReturn; } else { hr = HRESULTS::HR_FAILURE; } return hr; } HRESULTS CFrostEngine::Suspend( IntPtr^ hwndParent) { //TODO: I'm copying the Apply method, so if it doesnt use the handle, take it out HRESULTS hr; if(UXProxy != nullptr) { ResultReturnArgs^ e = gcnew ResultReturnArgs(); UXProxy->SuspendEvent(UXProxy, e); hr = e->ResultToReturn; } else { hr = HRESULTS::HR_FAILURE; } return hr; } HRESULTS CFrostEngine::Reboot( IntPtr^ hwndParent) { //TODO: I'm copying the Apply method, so if it doesnt use the handle, take it out HRESULTS hr; if(UXProxy != nullptr) { ResultReturnArgs^ e = gcnew ResultReturnArgs(); UXProxy->RebootEvent(UXProxy, e); hr = e->ResultToReturn; } else { hr = HRESULTS::HR_FAILURE; } return hr; } HRESULTS CFrostEngine::SetSource(String^ wzSourcePath) { HRESULTS hr; if(UXProxy != nullptr) { StringEventArgs^ e = gcnew StringEventArgs(); e->StringValue = wzSourcePath; UXProxy->SetSourceEvent(UXProxy,e); hr = e->ResultToReturn; } else { hr = HRESULTS::HR_FAILURE; } return hr; } HRESULTS CFrostEngine::Log(ENGINE_LOG_LEVEL Level, String^ Message) { HRESULTS hr; if(UXProxy != nullptr) { LogEventArgs^ e = gcnew LogEventArgs(); e->StringValue = Message; e->MessageLogLevel = Level; UXProxy->LogEvent(UXProxy,e); hr = e->ResultToReturn; } else { hr = HRESULTS::HR_FAILURE; } return hr; } } } } } }
{ "pile_set_name": "Github" }
fileFormatVersion: 2 guid: f20529f812864439c8f062e55938542d timeCreated: 1506402197 licenseType: Pro MonoImporter: serializedVersion: 2 defaultReferences: [] executionOrder: 0 icon: {instanceID: 0} userData: assetBundleName: assetBundleVariant:
{ "pile_set_name": "Github" }
/*- * SPDX-License-Identifier: BSD-3-Clause * * Copyright (C) 1995, 1996, 1997, and 1998 WIDE Project. * All rights reserved. * * 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 name of the project 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 PROJECT 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 PROJECT 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. * * $KAME: in6.h,v 1.89 2001/05/27 13:28:35 itojun Exp $ */ #if !defined(_NETINET6_IN6_H_) || !defined(_KERNEL) #error "must be included via <netinet6/in6.h> in kernel space" #endif /* XXX nonstandard */ #define s6_addr8 __u6_addr.__u6_addr8 #define s6_addr16 __u6_addr.__u6_addr16 #define s6_addr32 __u6_addr.__u6_addr32 /* * Local definition for masks */ /* XXX nonstandard */ #define IN6MASK0 {{{ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }}} #define IN6MASK32 {{{ 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00, \ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }}} #define IN6MASK64 {{{ 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }}} #define IN6MASK96 {{{ 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ 0xff, 0xff, 0xff, 0xff, 0x00, 0x00, 0x00, 0x00 }}} #define IN6MASK128 {{{ 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, \ 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }}} extern const struct sockaddr_in6 sa6_any; extern const struct in6_addr in6mask0; extern const struct in6_addr in6mask32; extern const struct in6_addr in6mask64; extern const struct in6_addr in6mask96; extern const struct in6_addr in6mask128; /* * Macros started with IPV6_ADDR is KAME local */ /* XXX nonstandard */ #if _BYTE_ORDER == _BIG_ENDIAN #define IPV6_ADDR_INT32_ONE 1 #define IPV6_ADDR_INT32_TWO 2 #define IPV6_ADDR_INT32_MNL 0xff010000 #define IPV6_ADDR_INT32_MLL 0xff020000 #define IPV6_ADDR_INT32_SMP 0x0000ffff #define IPV6_ADDR_INT16_ULL 0xfe80 #define IPV6_ADDR_INT16_USL 0xfec0 #define IPV6_ADDR_INT16_MLL 0xff02 #elif _BYTE_ORDER == _LITTLE_ENDIAN #define IPV6_ADDR_INT32_ONE 0x01000000 #define IPV6_ADDR_INT32_TWO 0x02000000 #define IPV6_ADDR_INT32_MNL 0x000001ff #define IPV6_ADDR_INT32_MLL 0x000002ff #define IPV6_ADDR_INT32_SMP 0xffff0000 #define IPV6_ADDR_INT16_ULL 0x80fe #define IPV6_ADDR_INT16_USL 0xc0fe #define IPV6_ADDR_INT16_MLL 0x02ff #endif /* XXX nonstandard */ #define IPV6_ADDR_SCOPE_NODELOCAL 0x01 #define IPV6_ADDR_SCOPE_INTFACELOCAL 0x01 #define IPV6_ADDR_SCOPE_LINKLOCAL 0x02 #define IPV6_ADDR_SCOPE_SITELOCAL 0x05 #define IPV6_ADDR_SCOPE_ORGLOCAL 0x08 /* just used in this file */ #define IPV6_ADDR_SCOPE_GLOBAL 0x0e #define IPV6_ADDR_MC_SCOPE(a) ((a)->s6_addr[1] & 0x0f) /* refers nonstandard items */ #define IN6_IS_ADDR_MC_NODELOCAL(a) \ (IN6_IS_ADDR_MULTICAST(a) && \ (IPV6_ADDR_MC_SCOPE(a) == IPV6_ADDR_SCOPE_NODELOCAL)) #define IN6_IS_ADDR_MC_INTFACELOCAL(a) \ (IN6_IS_ADDR_MULTICAST(a) && \ (IPV6_ADDR_MC_SCOPE(a) == IPV6_ADDR_SCOPE_INTFACELOCAL)) #define IN6_IS_ADDR_MC_LINKLOCAL(a) \ (IN6_IS_ADDR_MULTICAST(a) && \ (IPV6_ADDR_MC_SCOPE(a) == IPV6_ADDR_SCOPE_LINKLOCAL)) #define IN6_IS_ADDR_MC_SITELOCAL(a) \ (IN6_IS_ADDR_MULTICAST(a) && \ (IPV6_ADDR_MC_SCOPE(a) == IPV6_ADDR_SCOPE_SITELOCAL)) #define IN6_IS_ADDR_MC_ORGLOCAL(a) \ (IN6_IS_ADDR_MULTICAST(a) && \ (IPV6_ADDR_MC_SCOPE(a) == IPV6_ADDR_SCOPE_ORGLOCAL)) #define IN6_IS_ADDR_MC_GLOBAL(a) \ (IN6_IS_ADDR_MULTICAST(a) && \ (IPV6_ADDR_MC_SCOPE(a) == IPV6_ADDR_SCOPE_GLOBAL)) /* nonstandard */ /* * KAME Scope */ #define IN6_IS_SCOPE_LINKLOCAL(a) \ ((IN6_IS_ADDR_LINKLOCAL(a)) || \ (IN6_IS_ADDR_MC_LINKLOCAL(a))) #define IN6_IS_SCOPE_EMBED(a) \ ((IN6_IS_ADDR_LINKLOCAL(a)) || \ (IN6_IS_ADDR_MC_LINKLOCAL(a)) || \ (IN6_IS_ADDR_MC_INTFACELOCAL(a))) #define IFA6_IS_DEPRECATED(a) \ ((a)->ia6_lifetime.ia6t_pltime != ND6_INFINITE_LIFETIME && \ (u_int32_t)((time_uptime - (a)->ia6_updatetime)) > \ (a)->ia6_lifetime.ia6t_pltime) #define IFA6_IS_INVALID(a) \ ((a)->ia6_lifetime.ia6t_vltime != ND6_INFINITE_LIFETIME && \ (u_int32_t)((time_uptime - (a)->ia6_updatetime)) > \ (a)->ia6_lifetime.ia6t_vltime) #define MTAG_ABI_IPV6 1444287380 /* IPv6 ABI */ #define IPV6_TAG_DIRECT 0 /* direct-dispatch IPv6 */ /* RFC2292 options */ #define IPV6_2292PKTINFO 19 /* bool; send/recv if, src/dst addr */ #define IPV6_2292HOPLIMIT 20 /* bool; hop limit */ #define IPV6_2292NEXTHOP 21 /* bool; next hop addr */ #define IPV6_2292HOPOPTS 22 /* bool; hop-by-hop option */ #define IPV6_2292DSTOPTS 23 /* bool; destinaion option */ #define IPV6_2292RTHDR 24 /* bool; routing header */ #define IPV6_2292PKTOPTIONS 25 /* buf/cmsghdr; set/get IPv6 options */ #define IPV6_RECVRTHDRDSTOPTS 41 /* bool; recv dst option before rthdr */ struct cmsghdr; struct ip6_hdr; int in6_cksum_pseudo(struct ip6_hdr *, uint32_t, uint8_t, uint16_t); int in6_cksum(struct mbuf *, u_int8_t, u_int32_t, u_int32_t); int in6_cksum_partial(struct mbuf *, u_int8_t, u_int32_t, u_int32_t, u_int32_t); int in6_localaddr(struct in6_addr *); int in6_localip(struct in6_addr *); int in6_ifhasaddr(struct ifnet *, struct in6_addr *); int in6_addrscope(const struct in6_addr *); char *ip6_sprintf(char *, const struct in6_addr *); struct in6_ifaddr *in6_ifawithifp(struct ifnet *, struct in6_addr *); extern void in6_if_up(struct ifnet *); struct sockaddr; extern u_char ip6_protox[]; void in6_sin6_2_sin(struct sockaddr_in *sin, struct sockaddr_in6 *sin6); void in6_sin_2_v4mapsin6(struct sockaddr_in *sin, struct sockaddr_in6 *sin6); void in6_sin6_2_sin_in_sock(struct sockaddr *nam); void in6_sin_2_v4mapsin6_in_sock(struct sockaddr **nam); extern void addrsel_policy_init(void); #define satosin6(sa) ((struct sockaddr_in6 *)(sa)) #define sin6tosa(sin6) ((struct sockaddr *)(sin6)) #define ifatoia6(ifa) ((struct in6_ifaddr *)(ifa))
{ "pile_set_name": "Github" }
# Requirements [!!] Before continuing, make sure you have a web server (like Apache) configured with the following requirements. - PHP 5.3.3 or newer. - [Iconv Extension](http://php.net/iconv) - [Character Type (CTYPE) Extension](http://php.net/ctype) # Download You can get the latest **stable** release on the [Kohana website](http://kohanaframework.org/). This will give you a fully functional application with an `application`, `modules`, and `system` directory. [!!] You can find information about the file structure on the [Cascading Filesystem](files) page. Once downloaded, you should extract the Kohana application to a directory where the web server can access it. Going forward, we are going to assume you've extracted the application to a `kohana` directory such that `http://localhost/kohana/index.php` is pointing to the `index.php` file in the Kohana release. # Configure Before the application can be run, you will need to make a few changes to the `application/bootstrap.php` file. This file is the first one to be included by `index.php` and sets up most of the global options for the application. Open `application/bootstrap.php` and make the following changes: - Set the default [timezone](http://php.net/timezones) for your application. ~~~ // Example of changing timezone to Sao Paulo, Brazil date_default_timezone_set('America/Sao_Paulo'); ~~~ - Set the `base_url` in the [Kohana::init] call to reflect the location of the kohana folder on your server relative to the document root. ~~~ /** * Example of kohana's installation at /var/www/kohana and * Apache's DocumentRoot configured to /var/www */ Kohana::init(array( 'base_url' => '/kohana/', )); ~~~ - List your trusted hosts. Open `application/config/url.php` and add regex patterns of the hosts you expect your application to be accessible from. [!!] Do not forget to escape your dots (.) as these are regex patterns. These patterns should always fully match, as they are prepended with `^` and appended with `$`. ~~~ return array( 'trusted_hosts' => array( 'example\.org', '.*\.example\.org', ), ); ~~~ - Define a salt for the `Cookie` class. ~~~ Cookie::$salt = 'some-really-long-cookie-salt-here'; ~~~ - Make sure the `application/cache` and `application/logs` directories are writable by the web server. ~~~ sudo chmod -R a+rwx application/cache sudo chmod -R a+rwx application/logs ~~~ [!!] Make sure to use a unique salt for your application and never to share it. Take a look at the [Cookies](cookies) page for more information on how cookies work in Kohana. If you do not define a `Cookie::$salt` value, Kohana will throw an exception when it encounters any cookie on your domain. - Test your installation by opening [http://localhost/kohana](http://localhost/kohana). You should see the installation page. If it reports any errors, you will need to correct them before continuing. ![Install Page](install.png "Example of install page") Once your install page reports that your environment is set up correctly you need to either rename or delete `install.php`. Kohana is now installed and you should see the output of the welcome controller: ![Welcome Page](welcome.png "Example of welcome page") ## Installing Kohana From GitHub The [source code](http://github.com/kohana/kohana) for Kohana is hosted with [GitHub](http://github.com). To install Kohana using the github source code first you need to install [git](http://git-scm.com/). Visit [http://help.github.com](http://help.github.com) for details on how to install git on your platform. [!!] For more information on installing Kohana using git, see the [Working with Git](tutorials/git) tutorial.
{ "pile_set_name": "Github" }
# Contributor Covenant Code of Conduct ## Our Pledge We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation. We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community. ## Our Standards Examples of behavior that contributes to a positive environment for our community include: * Demonstrating empathy and kindness toward other people * Being respectful of differing opinions, viewpoints, and experiences * Giving and gracefully accepting constructive feedback * Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience * Focusing on what is best not just for us as individuals, but for the overall community Examples of unacceptable behavior include: * The use of sexualized language or imagery, and sexual attention or advances of any kind * Trolling, insulting or derogatory comments, and personal or political attacks * Public or private harassment * Publishing others' private information, such as a physical or email address, without their explicit permission * Other conduct which could reasonably be considered inappropriate in a professional setting ## Enforcement Responsibilities Community leaders are responsible for clarifying and enforcing our standards of acceptable behavior and will take appropriate and fair corrective action in response to any behavior that they deem inappropriate, threatening, offensive, or harmful. Community leaders have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, and will communicate reasons for moderation decisions when appropriate. ## Scope This Code of Conduct applies within all community spaces, and also applies when an individual is officially representing the community in public spaces. Examples of representing our community include using an official e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. ## Enforcement Instances of abusive, harassing, or otherwise unacceptable behavior may be reported to the community leaders responsible for enforcement at [INSERT CONTACT METHOD]. All complaints will be reviewed and investigated promptly and fairly. All community leaders are obligated to respect the privacy and security of the reporter of any incident. ## Enforcement Guidelines Community leaders will follow these Community Impact Guidelines in determining the consequences for any action they deem in violation of this Code of Conduct: ### 1. Correction **Community Impact**: Use of inappropriate language or other behavior deemed unprofessional or unwelcome in the community. **Consequence**: A private, written warning from community leaders, providing clarity around the nature of the violation and an explanation of why the behavior was inappropriate. A public apology may be requested. ### 2. Warning **Community Impact**: A violation through a single incident or series of actions. **Consequence**: A warning with consequences for continued behavior. No interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, for a specified period of time. This includes avoiding interactions in community spaces as well as external channels like social media. Violating these terms may lead to a temporary or permanent ban. ### 3. Temporary Ban **Community Impact**: A serious violation of community standards, including sustained inappropriate behavior. **Consequence**: A temporary ban from any sort of interaction or public communication with the community for a specified period of time. No public or private interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, is allowed during this period. Violating these terms may lead to a permanent ban. ### 4. Permanent Ban **Community Impact**: Demonstrating a pattern of violation of community standards, including sustained inappropriate behavior, harassment of an individual, or aggression toward or disparagement of classes of individuals. **Consequence**: A permanent ban from any sort of public interaction within the community. ## Attribution This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 2.0, available at https://www.contributor-covenant.org/version/2/0/ code_of_conduct.html. Community Impact Guidelines were inspired by [Mozilla's code of conduct enforcement ladder](https://github.com/mozilla/diversity). [homepage]: https://www.contributor-covenant.org For answers to common questions about this code of conduct, see the FAQ at https://www.contributor-covenant.org/faq. Translations are available at https:// www.contributor-covenant.org/translations.
{ "pile_set_name": "Github" }
[![Build Status](https://travis-ci.org/libbitcoin/libbitcoin-system.svg?branch=master)](https://travis-ci.org/libbitcoin/libbitcoin-system) [![Coverage Status](https://coveralls.io/repos/libbitcoin/libbitcoin-system/badge.svg)](https://coveralls.io/r/libbitcoin/libbitcoin-system) # Libbitcoin *The Bitcoin Development Library* [Documentation](https://github.com/libbitcoin/libbitcoin/wiki) is available on the wiki. **License Overview** All files in this repository fall under the license specified in [COPYING](COPYING). The project is licensed as [AGPL with a lesser clause](https://www.gnu.org/licenses/agpl-3.0.en.html). It may be used within a proprietary project, but the core library and any changes to it must be published online. Source code for this library must always remain free for everybody to access. **About Libbitcoin** The libbitcoin toolkit is a set of cross platform C++ libraries for building bitcoin applications. The toolkit consists of several libraries, most of which depend on the foundational [libbitcoin](https://github.com/libbitcoin/libbitcoin) library. Each library's repository can be cloned and built using common [automake](http://www.gnu.org/software/automake) 1.14+ instructions. There are no packages yet in distribution however each library includes an installation script (described below) which is regularly verified in the automated build. ## Installation The master branch is a staging area for the next major release and should be used only by libbitcoin developers. The current release branch is version3. Detailed installation instructions are provided below. * [Debian/Ubuntu](#debianubuntu) * [Macintosh](#macintosh) * [Windows](#windows) ### Autotools (advanced users) On Linux and macOS libbitcoin is built using Autotools as follows. ```sh $ ./autogen.sh $ ./configure $ make $ sudo make install $ sudo ldconfig ``` A minimal libbitcoin build requires boost and libsecp256k1. The [libbitcoin/secp256k1](https://github.com/libbitcoin/secp256k1) repository is forked from [bitcoin-core/secp256k1](https://github.com/bitcoin-core/secp256k1) in order to control for changes and to incorporate the necessary Visual Studio build. The original repository can be used directly but recent changes to the public interface may cause build breaks. The `--enable-module-recovery` switch is required. ### Debian/Ubuntu Libbitcoin requires a C++11 compiler, currently minimum [GCC 4.8.0](https://gcc.gnu.org/projects/cxx0x.html) or Clang based on [LLVM 3.5](http://llvm.org/releases/3.5.0/docs/ReleaseNotes.html). Install the [build system](http://wikipedia.org/wiki/GNU_build_system) (Automake minimum 1.14) and git: ```sh $ sudo apt-get install build-essential autoconf automake libtool pkg-config git ``` Next download the [install script](https://github.com/libbitcoin/libbitcoin/blob/version3/install.sh) and enable execution: ```sh $ wget https://raw.githubusercontent.com/libbitcoin/libbitcoin/version3/install.sh $ chmod +x install.sh ``` Finally install libbitcoin with recommended [build options](#build-notes-for-linux--macos): ```sh $ ./install.sh --prefix=/home/me/myprefix --build-boost --disable-shared ``` Libbitcoin is now installed in `/home/me/myprefix/`. ### Macintosh The macOS installation differs from Linux in the installation of the compiler and packaged dependencies. Libbitcoin supports both [Homebrew](http://brew.sh) and [MacPorts](https://www.macports.org) package managers. Both require Apple's [Xcode](https://developer.apple.com/xcode) command line tools. Neither requires Xcode as the tools may be installed independently. Libbitcoin compiles with Clang on macOS and requires C++11 support. Installation has been verified using Clang based on [LLVM 3.5](http://llvm.org/releases/3.5.0/docs/ReleaseNotes.html). This version or newer should be installed as part of the Xcode command line tools. To see your Clang/LLVM version: ```sh $ clang++ --version ``` You may encounter a prompt to install the Xcode command line developer tools, in which case accept the prompt. ``` Apple LLVM version 6.0 (clang-600.0.54) (based on LLVM 3.5svn) Target: x86_64-apple-darwin14.0.0 Thread model: posix ``` If required update your version of the command line tools as follows: ```sh $ xcode-select --install ``` #### Using Homebrew First install [Homebrew](https://brew.sh). Next install the [build system](http://wikipedia.org/wiki/GNU_build_system) (Automake minimum 1.14) and [wget](http://www.gnu.org/software/wget): ```sh $ brew install autoconf automake libtool pkgconfig wget ``` Next download the [install script](https://github.com/libbitcoin/libbitcoin/blob/version3/install.sh) and enable execution: ```sh $ wget https://raw.githubusercontent.com/libbitcoin/libbitcoin/version3/install.sh $ chmod +x install.sh ``` Finally install libbitcoin with recommended [build options](#build-notes-for-linux--macos): ```sh $ ./install.sh --prefix=/home/me/myprefix --build-boost --disable-shared ``` Libbitcoin is now installed in `/home/me/myprefix/`. #### Using MacPorts First install [MacPorts](https://www.macports.org/install.php). Next install the [build system](http://wikipedia.org/wiki/GNU_build_system) (Automake minimum 1.14) and [wget](http://www.gnu.org/software/wget): ```sh $ sudo port install autoconf automake libtool pkgconfig wget ``` Next download the [install script](https://github.com/libbitcoin/libbitcoin/blob/version3/install.sh) and enable execution: ```sh $ wget https://raw.githubusercontent.com/libbitcoin/libbitcoin/version3/install.sh $ chmod +x install.sh ``` Finally install libbitcoin with default [build options](#build-notes-for-linux--macos): ```sh $ ./install.sh --prefix=/home/me/myprefix --build-boost --disable-shared ``` Libbitcoin is now installed in `/home/me/myprefix/`. ### Build Notes for Linux / macOS The [install script](https://github.com/libbitcoin/libbitcoin/blob/version3/install.sh) itself is commented so that the manual build steps for each dependency can be inferred by a developer. You can run the install script from any directory on your system. By default this will build libbitcoin in a subdirectory named `build-libbitcoin` and install it to `/usr/local/`. The install script requires `sudo` only if you do not have access to the installation location, which you can change using the `--prefix` option on the installer command line. The build script clones, builds and installs two unpackaged repositories, namely: - [libbitcoin/secp256k1](https://github.com/libbitcoin/secp256k1) - [libbitcoin/libbitcoin](https://github.com/libbitcoin/libbitcoin) The script builds from the head of their `version4` and `version3` branches respectively. The `master` branch is a staging area for changes. The version branches are considered release quality. #### Build Options Any set of `./configure` options can be passed via the build script, for example: ```sh $ ./install.sh CFLAGS="-Og -g" --prefix=/home/me/myprefix ``` #### Compiling with ICU (International Components for Unicode) Since the addition of [BIP-39](https://github.com/bitcoin/bips/blob/master/bip-0039.mediawiki) and later [BIP-38](https://github.com/bitcoin/bips/blob/master/bip-0038.mediawiki) and [Electrum](https://electrum.org) mnemnoic support, libbitcoin conditionally incorporates [ICU](http://site.icu-project.org). To use passphrase normalization for these features libbitcoin must be compiled with the `--with-icu` option. Currently [libbitcoin-explorer](https://github.com/libbitcoin/libbitcoin-explorer) is the only other library that accesses this feature, so if you do not intend to use passphrase normalization this dependency can be avoided. ```sh $ ./install.sh --with-icu --build-icu --build-boost --disable-shared ``` #### Compiling with QR Code Support Since the addition of [qrcode](https://github.com/evoskuil/libbitcoin/blob/master/src/wallet/qrcode.cpp) support, libbitcoin conditionally incorporates `qrencode`. This requires compiling with the `--with-qrencode` option. Currently [libbitcoin-explorer](https://github.com/libbitcoin/libbitcoin-explorer) is the only other library that accesses this feature, so if you do not intend to use qrcode this dependency can be avoided. ```sh $ ./install.sh --with-qrencode --build-qrencode --build-boost --disable-shared ``` Since the addition of [png](https://github.com/evoskuil/libbitcoin/blob/master/src/utility/png.cpp) support, libbitcoin conditionally incorporates `libpng` (which in turn requires `zlib`). This requires compiling with the `--with-png` option. Currently [libbitcoin-explorer](https://github.com/libbitcoin/libbitcoin-explorer) is the only other library that accesses this feature, so if you do not intend to use png this dependency can be avoided. ```sh $ ./install.sh --with-png --build-png --build-boost --disable-shared ``` #### Building ICU, ZLib, PNG, QREncode and/or Boost The installer can download and install any or all of these dependencies. ICU is a large package that is not typically preinstalled at a sufficient level. Using these builds ensures compiler and configuration compatibility across all of the build components. It is recommended to use a prefix directory when building these components. ```sh $ ./install.sh --prefix=/home/me/myprefix --with-icu --with-png --with-qrencode --build-icu --build-zlib --build-png --build-qrencode --build-boost --disable-shared ``` ### Windows Visual Studio solutions are maintained for all libbitcoin libraries. NuGet packages exist for dependencies with the exceptions of the optional ZLib, PNG, and QREncode (required for QR code functionality). ICU is integrated into Windows and therefore not required as an additional dependency when using ICU features. > The libbitcoin execution environment supports `Windows XP Service Pack 2` and newer. #### Supported Compilers Libbitcoin requires a C++11 compiler, which means Visual Studio 2013 (with a pre-release compiler update) or later. Download and install one of the following free tools as necessary: * [Visual Studio 2017 Express](https://www.visualstudio.com/downloads) * [Visual Studio 2015 Express](https://www.visualstudio.com/vs/older-downloads) * [Visual Studio 2013 Express](https://www.visualstudio.com/vs/older-downloads) * [November 2013 CTP Compiler for Visual Studio 2013](http://www.microsoft.com/en-us/download/details.aspx?id=41151) * [November 2013 CTP Compiler installation issue](http://stackoverflow.com/a/34548651/1172329) #### NuGet Repository Dependencies apart from the libbitcoin libraries are available as [NuGet packages](https://www.nuget.org): * Packages maintained by [sergey.shandar](http://www.nuget.org/profiles/sergey.shandar) * [boost](http://www.nuget.org/packages/boost) * [boost\_atomic](http://www.nuget.org/packages/boost_atomic-vc120) * [boost\_chrono](http://www.nuget.org/packages/boost_chrono-vc120) * [boost\_date\_time](http://www.nuget.org/packages/boost_date_time-vc120) * [boost\_filesystem](http://www.nuget.org/packages/boost_filesystem-vc120) * [boost\_iostreams](http://www.nuget.org/packages/boost_iostreams-vc120) * [boost\_locale](http://www.nuget.org/packages/boost_locale-vc120) * [boost\_log](http://www.nuget.org/packages/boost_log-vc120) * [boost\_log_setup](http://www.nuget.org/packages/boost_log_setup-vc120) * [boost\_program\_options](http://www.nuget.org/packages/boost_program_options-vc120) * [boost\_regex](http://www.nuget.org/packages/boost_regex-vc120) * [boost\_system](http://www.nuget.org/packages/boost_system-vc120) * [boost\_thread](http://www.nuget.org/packages/boost_thread-vc120) * [boost\_unit\_test\_framework](http://www.nuget.org/packages/boost_unit_test_framework-vc120) * Packages maintained by [evoskuil](http://www.nuget.org/profiles/evoskuil) * [secp256k1](http://www.nuget.org/packages/secp256k1_vc120) * [libzmq](http://www.nuget.org/packages/libzmq_vc120) [required for client-server repositories only] The packages can be viewed using the [NuGet package manager](http://docs.nuget.org/docs/start-here/managing-nuget-packages-using-the-dialog) from the libbitcoin solution. The package manager will prompt for download of any missing packages. The libbitcoin solution files are configured with references to these packages. The location of the NuGet repository is controlled by the [nuget.config](https://github.com/libbitcoin/libbitcoin/blob/master/builds/msvc/nuget.config) file `repositoryPath` setting **and** the `NuGetPackageRoot` element of **each** [\[project\].props](https://github.com/libbitcoin/libbitcoin-system/blob/master/builds/msvc/vs2017/libbitcoin-system/libbitcoin-system.props) file. #### Build Libbitcoin Projects After cloning the the repository the libbitcoin build can be performed from within Visual Studio or using the `build_all.bat` script provided in the `builds\msvc\build\` subdirectory. The script automatically downloads all required NuGet packages. > Tip: The `build_all.bat` script builds *all* valid configurations for *all* compilers. The build time can be significantly reduced by disabling all but the desired configuration in `build_base.bat` and `build_all.bat`. The libbitcoin dynamic (DLL) build configurations do not compile, as the exports have not yet been fully implemented. These are currently disabled in the build scripts but you will encounter numerous errors if you build then manually. #### Optional: Building External Dependencies The secp256k1 and libzmq package above are maintained using the same [Visual Studio template](https://github.com/evoskuil/visual-studio-template) as all libbitcoin libraries. If so desired these can be built locally, in the same manner as libbitcoin. * [libbitcoin/secp256k1](https://github.com/libbitcoin/secp256k1/tree/version5/builds/msvc) * [zeromq/libzmq](https://github.com/zeromq/libzmq/tree/master/builds/msvc) This change is properly accomplished by disabling the "NuGet Dependencies" in the Visual Studio properties user interface and then importing `secp256k1.import.props`, which references `secp256k1.import.xml` and `libzmq.import.props`, which references `libzmq.import.xml`. See [boost documentation](http://www.boost.org/doc/libs/1_57_0/more/getting_started/windows.html) for building boost libraries for Visual C++.
{ "pile_set_name": "Github" }
.media { display: flex; align-items: flex-start; } .media-body { flex: 1; }
{ "pile_set_name": "Github" }
const BaseModel = require('../../classes/base_model'); const instanceProps = { tableName: 'series', books: function () { return this.hasMany(require('../books/model')); } }; const classProps = { typeName: 'series', filters: { title: function (qb, value) { return qb.whereIn('title', value); } }, relations: [ 'books', 'books.chapters', 'books.firstChapter' ] }; module.exports = BaseModel.extend(instanceProps, classProps);
{ "pile_set_name": "Github" }
[colors] # Base16 Atelier Cave # Scheme: Bram de Haan (http://atelierbram.github.io/syntax-highlighting/atelier-schemes/cave) foreground = #8b8792 foreground_bold = #8b8792 cursor = #8b8792 background = #19171c # 16 color space color0 = #19171c color1 = #be4678 color2 = #2a9292 color3 = #a06e3b color4 = #576ddb color5 = #955ae7 color6 = #398bc6 color7 = #8b8792 color8 = #655f6d color9 = #be4678 color10 = #2a9292 color11 = #a06e3b color12 = #576ddb color13 = #955ae7 color14 = #398bc6 color15 = #efecf4 # 256 color space color16 = #aa573c color17 = #bf40bf color18 = #26232a color19 = #585260 color20 = #7e7887 color21 = #e2dfe7
{ "pile_set_name": "Github" }
--- - include: section_09_level1.yml tags: - section09 - level1
{ "pile_set_name": "Github" }
--- apiVersion: extensions/v1beta1 kind: Deployment metadata: name: carts-db labels: name: carts-db namespace: sock-shop spec: replicas: 1 template: spec: containers: - name: carts-db image: mongo securityContext: fake: entry
{ "pile_set_name": "Github" }
# https://atcoder.jp/contests/dp/tasks/dp_k import sequtils, strutils let f = stdin.readLine.split.mapIt(it.parseInt) n = f[0] k = f[1] a = stdin.readLine.split.mapIt(it.parseInt) var b = newSeq[bool](k+1) for i in 0..k: for x in a: if i >= x and not b[i - x]: b[i] = true if b[k]: echo "First" else: echo "Second"
{ "pile_set_name": "Github" }
{ "cells": [ { "cell_type": "markdown", "metadata": { "deletable": true, "editable": true }, "source": [ "### osu!nn #6: Rhythm Predictor\n", "\n", "Calculates a map's rhythm from the music and the timing.\n", "\n", "Synthesis of \"rhythmData\"\n", "* rhythmModel x 1\n", "* momentumModel x 1\n", "* timingData x 1\n", "* (Music) x 1\n", "\n", "Synthesis Time: ~2 seconds\n", "\n", "Final edit: 2018/8/16" ] }, { "cell_type": "code", "execution_count": 1, "metadata": { "collapsed": true, "deletable": true, "editable": true }, "outputs": [], "source": [ "import tensorflow as tf\n", "from tensorflow import keras\n", "import pandas as pd\n", "import numpy as np\n", "import matplotlib.pyplot as plt\n", "import os, re" ] }, { "cell_type": "markdown", "metadata": { "deletable": true, "editable": true }, "source": [ "Some parameters here. \n", "\n", "\"note_density\" determines how many notes will be placed on the timeline, ranges from 0 to 1.\n", "\n", "\"slider_favor\" determines how the model favors sliders against circles, ranges from -1 to 1.\n", "\n", "\"dist_multiplier\" determines how the flow model has your distance multiplied. ranges from 0 to +∞. Of course +∞ is not advisable.\n", "\n", "\"divisor_favor\" determines how the model favors notes to be on X divisors starting from a beat (white, blue, red, blue), ranges from -1 to 1 each.\n", "\n", "Ranges not inclusive." ] }, { "cell_type": "code", "execution_count": 2, "metadata": { "collapsed": true, "deletable": true, "editable": true }, "outputs": [], "source": [ "# TODO parameter here!!\n", "dist_multiplier = 1;\n", "note_density = 0.36;\n", "slider_favor = 0;\n", "divisor = 4;\n", "divisor_favor = [0] * divisor;" ] }, { "cell_type": "code", "execution_count": 3, "metadata": { "collapsed": false, "deletable": true, "editable": true }, "outputs": [], "source": [ "model = tf.keras.models.load_model(\n", " \"saved_rhythm_model\",\n", " custom_objects=None,\n", " compile=False\n", ");\n", "model.compile(loss='mse',\n", " optimizer=tf.train.RMSPropOptimizer(0.001),\n", " metrics=[keras.metrics.mae]);" ] }, { "cell_type": "markdown", "metadata": { "deletable": true, "editable": true }, "source": [ "Problem: how italic italics need to be to make the backlash \\ look straight vertical?" ] }, { "cell_type": "code", "execution_count": 4, "metadata": { "collapsed": false, "deletable": true, "editable": true }, "outputs": [], "source": [ "# root = \"..\\\\osureader\\\\mapdata_test\";\n", "fn = \"mapthis.npz\";\n", "\n", "def read_npz(fn):\n", " with np.load(fn) as data:\n", " wav_data = data[\"wav\"];\n", " wav_data = np.swapaxes(wav_data, 2, 3);\n", " ticks = data[\"ticks\"];\n", " timestamps = data[\"timestamps\"];\n", " extra = data[\"extra\"];\n", " \n", " # Extra vars\n", " bpms = extra[0];\n", " slider_lengths = extra[1];\n", " ex1 = (60000 / bpms) / 500 - 1;\n", " ex2 = bpms / 120 - 1;\n", " ex3 = slider_lengths / 150 - 1;\n", " \n", " div_data = np.array([divisor_array(k) + [ex1[k], ex2[k], ex3[k]] for k in ticks]);\n", " return wav_data, div_data, ticks, timestamps;\n", "\n", "def divisor_array(k):\n", " d_range = list(range(0, divisor));\n", " return [int(k % divisor == d) for d in d_range];\n", "\n", "test_data, div_data, ticks, timestamps = read_npz(fn);" ] }, { "cell_type": "code", "execution_count": 5, "metadata": { "collapsed": false, "deletable": true, "editable": true }, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "1001 notes predicted.\n" ] } ], "source": [ "# Make time intervals from test data\n", "time_interval = 16;\n", "if test_data.shape[0]%time_interval > 0:\n", " test_data = test_data[:-(test_data.shape[0]%time_interval)];\n", " div_data = div_data[:-(div_data.shape[0]%time_interval)];\n", "test_data2 = np.reshape(test_data, (-1, time_interval, test_data.shape[1], test_data.shape[2], test_data.shape[3]))\n", "div_data2 = np.reshape(div_data, (-1, time_interval, div_data.shape[1]))\n", "\n", "test_predictions = model.predict([test_data2, div_data2]);\n", "preds = test_predictions.reshape(-1, test_predictions.shape[2]);\n", "\n", "# Favor sliders a little\n", "preds[:, 2] += slider_favor;\n", "divs = div_data2.reshape(-1, div_data2.shape[2]);\n", "margin = np.sum([divisor_favor[k] * divs[:, k] for k in range(0, divisor)]);\n", "\n", "preds[:, 0] += margin;\n", "\n", "# Predict is_obj using note_density\n", "obj_preds = preds[:, 0];\n", "target_count = np.round(note_density * obj_preds.shape[0]).astype(int);\n", "borderline = np.sort(obj_preds)[obj_preds.shape - target_count];\n", "is_obj_pred = np.expand_dims(np.where(preds[:, 0] > borderline, 1, 0), axis=1);\n", "\n", "obj_type_pred = np.sign(preds[:, 1:4] - np.tile(np.expand_dims(np.max(preds[:, 1:4], axis=1), 1), (1, 3))) + 1;\n", "others_pred = (1 + np.sign(preds[:, 4:test_predictions.shape[1]] + 0.5)) / 2;\n", "another_pred_result = np.concatenate([is_obj_pred, is_obj_pred * obj_type_pred, others_pred], axis=1);\n", "\n", "print(\"{} notes predicted.\".format(np.sum(is_obj_pred)));" ] }, { "cell_type": "code", "execution_count": 6, "metadata": { "collapsed": false, "deletable": true, "editable": true }, "outputs": [], "source": [ "def load_momentum_minmax(fn):\n", " data = np.load(fn);\n", " return data;\n", "mommax, mommin = load_momentum_minmax(\"momentum_minmax.npy\");\n", "\n", "momentum_model = tf.keras.models.load_model(\n", " \"saved_rhythm_model_momentums\",\n", " custom_objects=None,\n", " compile=False\n", ");\n", "momentum_model.compile(loss='mse',\n", " optimizer=tf.train.RMSPropOptimizer(0.001),\n", " metrics=[keras.metrics.mae]);" ] }, { "cell_type": "code", "execution_count": 7, "metadata": { "collapsed": false, "deletable": true, "editable": true }, "outputs": [], "source": [ "momentum_predictions_output = momentum_model.predict([test_data2, div_data2]);\n", "momentum_predictions = (momentum_predictions_output.reshape(-1, 2) + 1) / 2 / 0.8 * (mommax - mommin) + mommin;" ] }, { "cell_type": "markdown", "metadata": { "deletable": true, "editable": true }, "source": [ "Save the rhythm data and progress to #7." ] }, { "cell_type": "code", "execution_count": 8, "metadata": { "collapsed": true, "deletable": true, "editable": true }, "outputs": [], "source": [ "np.savez_compressed(\"rhythm_data\", objs = is_obj_pred[:, 0], predictions = another_pred_result, timestamps = timestamps, ticks = ticks, momenta = momentum_predictions, sv = (div_data[:,6] + 1) * 150, dist_multiplier = dist_multiplier);" ] }, { "cell_type": "code", "execution_count": 9, "metadata": { "collapsed": false, "deletable": true, "editable": true }, "outputs": [], "source": [ "import json\n", "\n", "rhythm_json = {\n", " \"objs\": is_obj_pred[:, 0].tolist(), \n", " \"predictions\": another_pred_result.tolist(),\n", " \"timestamps\": timestamps.tolist(),\n", " \"ticks\": ticks.tolist(),\n", " \"momenta\": momentum_predictions.tolist(),\n", " \"sv\": ((div_data[:,6] + 1) * 150).tolist(),\n", " \"distMultiplier\": dist_multiplier\n", "};\n", "with open(\"evaluatedRhythm.json\", \"w\") as er:\n", " json.dump(rhythm_json, er);" ] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.5.2" } }, "nbformat": 4, "nbformat_minor": 2 }
{ "pile_set_name": "Github" }
import './style/index.less'; import button from './button'; import buttonGroup from './button-group'; button.group = buttonGroup; export default button;
{ "pile_set_name": "Github" }
// Common/IntToString.h #ifndef __COMMON_INTTOSTRING_H #define __COMMON_INTTOSTRING_H #include <stddef.h> #include "Types.h" void ConvertUInt64ToString(UInt64 value, char *s, UInt32 base = 10); void ConvertUInt64ToString(UInt64 value, wchar_t *s); void ConvertInt64ToString(Int64 value, char *s); void ConvertInt64ToString(Int64 value, wchar_t *s); #endif
{ "pile_set_name": "Github" }
/* cygwin/sysproto.h This file is part of Cygwin. This software is a copyrighted work licensed under the terms of the Cygwin license. Please consult the file "CYGWIN_LICENSE" for details. */ /* cygwin/sysproto.h header file for Cygwin. */ #ifndef _CYGWIN_SYSPROTO_H #define _CYGWIN_SYSPROTO_H #define _SYS_SYSPROTO_H_ /* Keep it, used by BSD files */ #ifdef __cplusplus extern "C" { #endif #include <sys/types.h> struct msgctl_args { int msqid; int cmd; struct msqid_ds *buf; }; struct msgget_args { key_t key; int msgflg; }; struct msgrcv_args { int msqid; void *msgp; size_t msgsz; long msgtyp; int msgflg; }; struct msgsnd_args { int msqid; const void *msgp; size_t msgsz; int msgflg; }; struct semctl_args { int semid; int semnum; int cmd; union semun *arg; }; struct semget_args { key_t key; int nsems; int semflg; }; struct semop_args { int semid; struct sembuf *sops; size_t nsops; }; struct shmat_args { int shmid; const void *shmaddr; int shmflg; }; struct shmctl_args { int shmid; int cmd; struct shmid_ds *buf; }; struct shmdt_args { const void *shmaddr; }; struct shmget_args { key_t key; size_t size; int shmflg; }; #ifdef __cplusplus } #endif #endif /* _CYGWIN_SYSPROTO_H */
{ "pile_set_name": "Github" }
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd"> <html> <head> <title>Matlab Index</title> <meta name="keywords" content="{DIRS}"> <meta name="description" content="{DIRS}"> <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1"> <meta name="generator" content="m2html &copy; 2003-2005 Guillaume Flandin"> <meta name="robots" content="index, follow"> <link type="text/css" rel="stylesheet" href="{MASTERPATH}m2html.css"> </head> <body> <a name="_top"></a> <h1>Matlab Index</h1> <h2>Matlab Directories</h2> <ul style="list-style-image:url({MASTERPATH}matlabicon.gif)"> <!-- BEGIN rowdir --> <li><a href="{L_DIR}">{DIR}</a></li> <!-- END rowdir --> </ul> <h2>Matlab Files found in these Directories</h2> <table width="100%"> <!-- BEGIN idrow --> <tr> <!-- BEGIN idcolumn --> <td><a href="{L_IDNAME}" title="{T_IDNAME}">{IDNAME}</a></td> <!-- END idcolumn --> </tr> <!-- END idrow --> </table> <!-- BEGIN search --> <h2>Search Engine</h2> <form class="search" action="{PHPFILE}" method="get"> Search for <input class="search" type="text" name="query" value="" size="20" accesskey="s"/> <input type="submit" name="submit" value="Search"> </form> <!-- END search --> <!-- BEGIN graph --> <h2>Dependency Graph</h2> <ul style="list-style-image:url({MASTERPATH}simulinkicon.gif)"> <li>View the <a href="{LGRAPH}">Graph</a>.</li> </ul> <!-- END graph --> <hr><address>Generated on {DATE} by <strong><a href="http://www.artefact.tk/software/matlab/m2html/" title="Matlab Documentation in HTML">m2html</a></strong> &copy; 2005</address> </body> </html>
{ "pile_set_name": "Github" }
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <!-- NewPage --> <html lang="en"> <head> <!-- Generated by javadoc (version 1.7.0_79) on Wed Jul 20 08:39:14 PDT 2016 --> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>AsArraySerializerBase (jackson-databind 2.8.0 API)</title> <meta name="date" content="2016-07-20"> <link rel="stylesheet" type="text/css" href="../../../../../../stylesheet.css" title="Style"> </head> <body> <script type="text/javascript"><!-- if (location.href.indexOf('is-external=true') == -1) { parent.document.title="AsArraySerializerBase (jackson-databind 2.8.0 API)"; } //--> </script> <noscript> <div>JavaScript is disabled on your browser.</div> </noscript> <!-- ========= START OF TOP NAVBAR ======= --> <div class="topNav"><a name="navbar_top"> <!-- --> </a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow"> <!-- --> </a> <ul class="navList" title="Navigation"> <li><a href="../../../../../../overview-summary.html">Overview</a></li> <li><a href="package-summary.html">Package</a></li> <li class="navBarCell1Rev">Class</li> <li><a href="class-use/AsArraySerializerBase.html">Use</a></li> <li><a href="package-tree.html">Tree</a></li> <li><a href="../../../../../../deprecated-list.html">Deprecated</a></li> <li><a href="../../../../../../index-all.html">Index</a></li> <li><a href="../../../../../../help-doc.html">Help</a></li> </ul> </div> <div class="subNav"> <ul class="navList"> <li><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/ArraySerializerBase.html" title="class in com.fasterxml.jackson.databind.ser.std"><span class="strong">Prev Class</span></a></li> <li><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AtomicReferenceSerializer.html" title="class in com.fasterxml.jackson.databind.ser.std"><span class="strong">Next Class</span></a></li> </ul> <ul class="navList"> <li><a href="../../../../../../index.html?com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" target="_top">Frames</a></li> <li><a href="AsArraySerializerBase.html" target="_top">No Frames</a></li> </ul> <ul class="navList" id="allclasses_navbar_top"> <li><a href="../../../../../../allclasses-noframe.html">All Classes</a></li> </ul> <div> <script type="text/javascript"><!-- allClassesLink = document.getElementById("allclasses_navbar_top"); if(window==top) { allClassesLink.style.display = "block"; } else { allClassesLink.style.display = "none"; } //--> </script> </div> <div> <ul class="subNavList"> <li>Summary:&nbsp;</li> <li><a href="#nested_classes_inherited_from_class_com.fasterxml.jackson.databind.JsonSerializer">Nested</a>&nbsp;|&nbsp;</li> <li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li> <li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li> <li><a href="#method_summary">Method</a></li> </ul> <ul class="subNavList"> <li>Detail:&nbsp;</li> <li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li> <li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li> <li><a href="#method_detail">Method</a></li> </ul> </div> <a name="skip-navbar_top"> <!-- --> </a></div> <!-- ========= END OF TOP NAVBAR ========= --> <!-- ======== START OF CLASS DATA ======== --> <div class="header"> <div class="subTitle">com.fasterxml.jackson.databind.ser.std</div> <h2 title="Class AsArraySerializerBase" class="title">Class AsArraySerializerBase&lt;T&gt;</h2> </div> <div class="contentContainer"> <ul class="inheritance"> <li><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li> <li> <ul class="inheritance"> <li><a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">com.fasterxml.jackson.databind.JsonSerializer</a>&lt;T&gt;</li> <li> <ul class="inheritance"> <li><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html" title="class in com.fasterxml.jackson.databind.ser.std">com.fasterxml.jackson.databind.ser.std.StdSerializer</a>&lt;T&gt;</li> <li> <ul class="inheritance"> <li><a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html" title="class in com.fasterxml.jackson.databind.ser">com.fasterxml.jackson.databind.ser.ContainerSerializer</a>&lt;T&gt;</li> <li> <ul class="inheritance"> <li>com.fasterxml.jackson.databind.ser.std.AsArraySerializerBase&lt;T&gt;</li> </ul> </li> </ul> </li> </ul> </li> </ul> </li> </ul> <div class="description"> <ul class="blockList"> <li class="blockList"> <dl> <dt>All Implemented Interfaces:</dt> <dd><a href="../../../../../../com/fasterxml/jackson/databind/jsonFormatVisitors/JsonFormatVisitable.html" title="interface in com.fasterxml.jackson.databind.jsonFormatVisitors">JsonFormatVisitable</a>, <a href="../../../../../../com/fasterxml/jackson/databind/jsonschema/SchemaAware.html" title="interface in com.fasterxml.jackson.databind.jsonschema">SchemaAware</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/ContextualSerializer.html" title="interface in com.fasterxml.jackson.databind.ser">ContextualSerializer</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/io/Serializable.html?is-external=true" title="class or interface in java.io">Serializable</a></dd> </dl> <dl> <dt>Direct Known Subclasses:</dt> <dd><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/CollectionSerializer.html" title="class in com.fasterxml.jackson.databind.ser.std">CollectionSerializer</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/EnumSetSerializer.html" title="class in com.fasterxml.jackson.databind.ser.std">EnumSetSerializer</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/impl/IndexedListSerializer.html" title="class in com.fasterxml.jackson.databind.ser.impl">IndexedListSerializer</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/IterableSerializer.html" title="class in com.fasterxml.jackson.databind.ser.std">IterableSerializer</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/impl/IteratorSerializer.html" title="class in com.fasterxml.jackson.databind.ser.impl">IteratorSerializer</a></dd> </dl> <hr> <br> <pre>public abstract class <span class="strong">AsArraySerializerBase&lt;T&gt;</span> extends <a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html" title="class in com.fasterxml.jackson.databind.ser">ContainerSerializer</a>&lt;T&gt; implements <a href="../../../../../../com/fasterxml/jackson/databind/ser/ContextualSerializer.html" title="interface in com.fasterxml.jackson.databind.ser">ContextualSerializer</a></pre> <div class="block">Base class for serializers that will output contents as JSON arrays; typically serializers used for <a href="http://docs.oracle.com/javase/7/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util"><code>Collection</code></a> and array types.</div> <dl><dt><span class="strong">See Also:</span></dt><dd><a href="../../../../../../serialized-form.html#com.fasterxml.jackson.databind.ser.std.AsArraySerializerBase">Serialized Form</a></dd></dl> </li> </ul> </div> <div class="summary"> <ul class="blockList"> <li class="blockList"> <!-- ======== NESTED CLASS SUMMARY ======== --> <ul class="blockList"> <li class="blockList"><a name="nested_class_summary"> <!-- --> </a> <h3>Nested Class Summary</h3> <ul class="blockList"> <li class="blockList"><a name="nested_classes_inherited_from_class_com.fasterxml.jackson.databind.JsonSerializer"> <!-- --> </a> <h3>Nested classes/interfaces inherited from class&nbsp;com.fasterxml.jackson.databind.<a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a></h3> <code><a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.None.html" title="class in com.fasterxml.jackson.databind">JsonSerializer.None</a></code></li> </ul> </li> </ul> <!-- =========== FIELD SUMMARY =========== --> <ul class="blockList"> <li class="blockList"><a name="field_summary"> <!-- --> </a> <h3>Field Summary</h3> <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Field Summary table, listing fields, and an explanation"> <caption><span>Fields</span><span class="tabEnd">&nbsp;</span></caption> <tr> <th class="colFirst" scope="col">Modifier and Type</th> <th class="colLast" scope="col">Field and Description</th> </tr> <tr class="altColor"> <td class="colFirst"><code>protected <a href="../../../../../../com/fasterxml/jackson/databind/ser/impl/PropertySerializerMap.html" title="class in com.fasterxml.jackson.databind.ser.impl">PropertySerializerMap</a></code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#_dynamicSerializers">_dynamicSerializers</a></strong></code> <div class="block">If element type can not be statically determined, mapping from runtime type to serializer is handled using this object</div> </td> </tr> <tr class="rowColor"> <td class="colFirst"><code>protected <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&gt;</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#_elementSerializer">_elementSerializer</a></strong></code> <div class="block">Value serializer to use, if it can be statically determined</div> </td> </tr> <tr class="altColor"> <td class="colFirst"><code>protected <a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a></code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#_elementType">_elementType</a></strong></code>&nbsp;</td> </tr> <tr class="rowColor"> <td class="colFirst"><code>protected <a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a></code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#_property">_property</a></strong></code> <div class="block">Collection-valued property being serialized with this instance</div> </td> </tr> <tr class="altColor"> <td class="colFirst"><code>protected boolean</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#_staticTyping">_staticTyping</a></strong></code>&nbsp;</td> </tr> <tr class="rowColor"> <td class="colFirst"><code>protected <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a></code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#_unwrapSingle">_unwrapSingle</a></strong></code> <div class="block">Setting for specific local override for "unwrap single element arrays": true for enable unwrapping, false for preventing it, `null` for using global configuration.</div> </td> </tr> <tr class="altColor"> <td class="colFirst"><code>protected <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a></code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#_valueTypeSerializer">_valueTypeSerializer</a></strong></code> <div class="block">Type serializer used for values, if any.</div> </td> </tr> </table> <ul class="blockList"> <li class="blockList"><a name="fields_inherited_from_class_com.fasterxml.jackson.databind.ser.std.StdSerializer"> <!-- --> </a> <h3>Fields inherited from class&nbsp;com.fasterxml.jackson.databind.ser.std.<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html" title="class in com.fasterxml.jackson.databind.ser.std">StdSerializer</a></h3> <code><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#_handledType">_handledType</a></code></li> </ul> </li> </ul> <!-- ======== CONSTRUCTOR SUMMARY ======== --> <ul class="blockList"> <li class="blockList"><a name="constructor_summary"> <!-- --> </a> <h3>Constructor Summary</h3> <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation"> <caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption> <tr> <th class="colFirst" scope="col">Modifier</th> <th class="colLast" scope="col">Constructor and Description</th> </tr> <tr class="altColor"> <td class="colFirst"><code>protected </code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#AsArraySerializerBase(com.fasterxml.jackson.databind.ser.std.AsArraySerializerBase,%20com.fasterxml.jackson.databind.BeanProperty,%20com.fasterxml.jackson.databind.jsontype.TypeSerializer,%20com.fasterxml.jackson.databind.JsonSerializer)">AsArraySerializerBase</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="class in com.fasterxml.jackson.databind.ser.std">AsArraySerializerBase</a>&lt;?&gt;&nbsp;src, <a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;&nbsp;elementSerializer)</code> <div class="block"><strong>Deprecated.</strong>&nbsp; <div class="block"><i>since 2.6: use the overloaded method that takes 'unwrapSingle'</i></div> </div> </td> </tr> <tr class="rowColor"> <td class="colFirst"><code>protected </code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#AsArraySerializerBase(com.fasterxml.jackson.databind.ser.std.AsArraySerializerBase,%20com.fasterxml.jackson.databind.BeanProperty,%20com.fasterxml.jackson.databind.jsontype.TypeSerializer,%20com.fasterxml.jackson.databind.JsonSerializer,%20java.lang.Boolean)">AsArraySerializerBase</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="class in com.fasterxml.jackson.databind.ser.std">AsArraySerializerBase</a>&lt;?&gt;&nbsp;src, <a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;&nbsp;elementSerializer, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a>&nbsp;unwrapSingle)</code>&nbsp;</td> </tr> <tr class="altColor"> <td class="colFirst"><code>protected </code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#AsArraySerializerBase(java.lang.Class,%20com.fasterxml.jackson.databind.JavaType,%20boolean,%20com.fasterxml.jackson.databind.jsontype.TypeSerializer,%20com.fasterxml.jackson.databind.BeanProperty,%20com.fasterxml.jackson.databind.JsonSerializer)">AsArraySerializerBase</a></strong>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a>&lt;?&gt;&nbsp;cls, <a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a>&nbsp;et, boolean&nbsp;staticTyping, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&gt;&nbsp;elementSerializer)</code> <div class="block"><strong>Deprecated.</strong>&nbsp; <div class="block"><i>Since 2.6 Use variants that either take 'src', or do NOT pass BeanProperty</i></div> </div> </td> </tr> <tr class="rowColor"> <td class="colFirst"><code>protected </code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#AsArraySerializerBase(java.lang.Class,%20com.fasterxml.jackson.databind.JavaType,%20boolean,%20com.fasterxml.jackson.databind.jsontype.TypeSerializer,%20com.fasterxml.jackson.databind.JsonSerializer)">AsArraySerializerBase</a></strong>(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a>&lt;?&gt;&nbsp;cls, <a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a>&nbsp;et, boolean&nbsp;staticTyping, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&gt;&nbsp;elementSerializer)</code> <div class="block">Non-contextual, "blueprint" constructor typically called when the first instance is created, without knowledge of property it was used via.</div> </td> </tr> </table> </li> </ul> <!-- ========== METHOD SUMMARY =========== --> <ul class="blockList"> <li class="blockList"><a name="method_summary"> <!-- --> </a> <h3>Method Summary</h3> <table class="overviewSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation"> <caption><span>Methods</span><span class="tabEnd">&nbsp;</span></caption> <tr> <th class="colFirst" scope="col">Modifier and Type</th> <th class="colLast" scope="col">Method and Description</th> </tr> <tr class="altColor"> <td class="colFirst"><code>protected <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&gt;</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#_findAndAddDynamic(com.fasterxml.jackson.databind.ser.impl.PropertySerializerMap,%20java.lang.Class,%20com.fasterxml.jackson.databind.SerializerProvider)">_findAndAddDynamic</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/ser/impl/PropertySerializerMap.html" title="class in com.fasterxml.jackson.databind.ser.impl">PropertySerializerMap</a>&nbsp;map, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a>&lt;?&gt;&nbsp;type, <a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider)</code>&nbsp;</td> </tr> <tr class="rowColor"> <td class="colFirst"><code>protected <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&gt;</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#_findAndAddDynamic(com.fasterxml.jackson.databind.ser.impl.PropertySerializerMap,%20com.fasterxml.jackson.databind.JavaType,%20com.fasterxml.jackson.databind.SerializerProvider)">_findAndAddDynamic</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/ser/impl/PropertySerializerMap.html" title="class in com.fasterxml.jackson.databind.ser.impl">PropertySerializerMap</a>&nbsp;map, <a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a>&nbsp;type, <a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider)</code>&nbsp;</td> </tr> <tr class="altColor"> <td class="colFirst"><code>void</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#acceptJsonFormatVisitor(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper,%20com.fasterxml.jackson.databind.JavaType)">acceptJsonFormatVisitor</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/jsonFormatVisitors/JsonFormatVisitorWrapper.html" title="interface in com.fasterxml.jackson.databind.jsonFormatVisitors">JsonFormatVisitorWrapper</a>&nbsp;visitor, <a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a>&nbsp;typeHint)</code> <div class="block">Default implementation specifies no format.</div> </td> </tr> <tr class="rowColor"> <td class="colFirst"><code><a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#createContextual(com.fasterxml.jackson.databind.SerializerProvider,%20com.fasterxml.jackson.databind.BeanProperty)">createContextual</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;serializers, <a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property)</code> <div class="block">This method is needed to resolve contextual annotations like per-property overrides, as well as do recursive call to <code>createContextual</code> of content serializer, if known statically.</div> </td> </tr> <tr class="altColor"> <td class="colFirst"><code><a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#getContentSerializer()">getContentSerializer</a></strong>()</code> <div class="block">Accessor for serializer used for serializing contents (List and array elements, Map values etc) of the container for which this serializer is used, if it is known statically.</div> </td> </tr> <tr class="rowColor"> <td class="colFirst"><code><a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a></code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#getContentType()">getContentType</a></strong>()</code> <div class="block">Accessor for finding declared (static) element type for type this serializer is used for.</div> </td> </tr> <tr class="altColor"> <td class="colFirst"><code><a href="../../../../../../com/fasterxml/jackson/databind/JsonNode.html" title="class in com.fasterxml.jackson.databind">JsonNode</a></code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#getSchema(com.fasterxml.jackson.databind.SerializerProvider,%20java.lang.reflect.Type)">getSchema</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</a>&nbsp;typeHint)</code> <div class="block">Default implementation simply claims type is "string"; usually overriden by custom serializers.</div> </td> </tr> <tr class="rowColor"> <td class="colFirst"><code>void</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#serialize(T,%20com.fasterxml.jackson.core.JsonGenerator,%20com.fasterxml.jackson.databind.SerializerProvider)">serialize</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&nbsp;value, <a href="http://fasterxml.github.com/jackson-core/javadoc/2.7/com/fasterxml/jackson/core/JsonGenerator.html?is-external=true" title="class or interface in com.fasterxml.jackson.core">JsonGenerator</a>&nbsp;gen, <a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider)</code> <div class="block">Method that can be called to ask implementation to serialize values of type this serializer handles.</div> </td> </tr> <tr class="altColor"> <td class="colFirst"><code>protected abstract void</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#serializeContents(T,%20com.fasterxml.jackson.core.JsonGenerator,%20com.fasterxml.jackson.databind.SerializerProvider)">serializeContents</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&nbsp;value, <a href="http://fasterxml.github.com/jackson-core/javadoc/2.7/com/fasterxml/jackson/core/JsonGenerator.html?is-external=true" title="class or interface in com.fasterxml.jackson.core">JsonGenerator</a>&nbsp;gen, <a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider)</code>&nbsp;</td> </tr> <tr class="rowColor"> <td class="colFirst"><code>void</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#serializeWithType(T,%20com.fasterxml.jackson.core.JsonGenerator,%20com.fasterxml.jackson.databind.SerializerProvider,%20com.fasterxml.jackson.databind.jsontype.TypeSerializer)">serializeWithType</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&nbsp;value, <a href="http://fasterxml.github.com/jackson-core/javadoc/2.7/com/fasterxml/jackson/core/JsonGenerator.html?is-external=true" title="class or interface in com.fasterxml.jackson.core">JsonGenerator</a>&nbsp;gen, <a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;typeSer)</code> <div class="block">Method that can be called to ask implementation to serialize values of type this serializer handles, using specified type serializer for embedding necessary type information.</div> </td> </tr> <tr class="altColor"> <td class="colFirst"><code><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="class in com.fasterxml.jackson.databind.ser.std">AsArraySerializerBase</a>&lt;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&gt;</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#withResolved(com.fasterxml.jackson.databind.BeanProperty,%20com.fasterxml.jackson.databind.jsontype.TypeSerializer,%20com.fasterxml.jackson.databind.JsonSerializer)">withResolved</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;&nbsp;elementSerializer)</code> <div class="block"><strong>Deprecated.</strong>&nbsp; <div class="block"><i>since 2.6: use the overloaded method that takes 'unwrapSingle'</i></div> </div> </td> </tr> <tr class="rowColor"> <td class="colFirst"><code>abstract <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="class in com.fasterxml.jackson.databind.ser.std">AsArraySerializerBase</a>&lt;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&gt;</code></td> <td class="colLast"><code><strong><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html#withResolved(com.fasterxml.jackson.databind.BeanProperty,%20com.fasterxml.jackson.databind.jsontype.TypeSerializer,%20com.fasterxml.jackson.databind.JsonSerializer,%20java.lang.Boolean)">withResolved</a></strong>(<a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;&nbsp;elementSerializer, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a>&nbsp;unwrapSingle)</code>&nbsp;</td> </tr> </table> <ul class="blockList"> <li class="blockList"><a name="methods_inherited_from_class_com.fasterxml.jackson.databind.ser.ContainerSerializer"> <!-- --> </a> <h3>Methods inherited from class&nbsp;com.fasterxml.jackson.databind.ser.<a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html" title="class in com.fasterxml.jackson.databind.ser">ContainerSerializer</a></h3> <code><a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html#_withValueTypeSerializer(com.fasterxml.jackson.databind.jsontype.TypeSerializer)">_withValueTypeSerializer</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html#hasContentTypeAnnotation(com.fasterxml.jackson.databind.SerializerProvider,%20com.fasterxml.jackson.databind.BeanProperty)">hasContentTypeAnnotation</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html#hasSingleElement(T)">hasSingleElement</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html#isEmpty(T)">isEmpty</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html#withValueTypeSerializer(com.fasterxml.jackson.databind.jsontype.TypeSerializer)">withValueTypeSerializer</a></code></li> </ul> <ul class="blockList"> <li class="blockList"><a name="methods_inherited_from_class_com.fasterxml.jackson.databind.ser.std.StdSerializer"> <!-- --> </a> <h3>Methods inherited from class&nbsp;com.fasterxml.jackson.databind.ser.std.<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html" title="class in com.fasterxml.jackson.databind.ser.std">StdSerializer</a></h3> <code><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#createObjectNode()">createObjectNode</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#createSchemaNode(java.lang.String)">createSchemaNode</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#createSchemaNode(java.lang.String,%20boolean)">createSchemaNode</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#findAnnotatedContentSerializer(com.fasterxml.jackson.databind.SerializerProvider,%20com.fasterxml.jackson.databind.BeanProperty)">findAnnotatedContentSerializer</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#findConvertingContentSerializer(com.fasterxml.jackson.databind.SerializerProvider,%20com.fasterxml.jackson.databind.BeanProperty,%20com.fasterxml.jackson.databind.JsonSerializer)">findConvertingContentSerializer</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#findFormatFeature(com.fasterxml.jackson.databind.SerializerProvider,%20com.fasterxml.jackson.databind.BeanProperty,%20java.lang.Class,%20com.fasterxml.jackson.annotation.JsonFormat.Feature)">findFormatFeature</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#findFormatOverrides(com.fasterxml.jackson.databind.SerializerProvider,%20com.fasterxml.jackson.databind.BeanProperty,%20java.lang.Class)">findFormatOverrides</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#findIncludeOverrides(com.fasterxml.jackson.databind.SerializerProvider,%20com.fasterxml.jackson.databind.BeanProperty,%20java.lang.Class)">findIncludeOverrides</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#findPropertyFilter(com.fasterxml.jackson.databind.SerializerProvider,%20java.lang.Object,%20java.lang.Object)">findPropertyFilter</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#getSchema(com.fasterxml.jackson.databind.SerializerProvider,%20java.lang.reflect.Type,%20boolean)">getSchema</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#handledType()">handledType</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#isDefaultSerializer(com.fasterxml.jackson.databind.JsonSerializer)">isDefaultSerializer</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#visitArrayFormat(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper,%20com.fasterxml.jackson.databind.JavaType,%20com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatTypes)">visitArrayFormat</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#visitArrayFormat(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper,%20com.fasterxml.jackson.databind.JavaType,%20com.fasterxml.jackson.databind.JsonSerializer,%20com.fasterxml.jackson.databind.JavaType)">visitArrayFormat</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#visitFloatFormat(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper,%20com.fasterxml.jackson.databind.JavaType,%20com.fasterxml.jackson.core.JsonParser.NumberType)">visitFloatFormat</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#visitIntFormat(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper,%20com.fasterxml.jackson.databind.JavaType,%20com.fasterxml.jackson.core.JsonParser.NumberType)">visitIntFormat</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#visitIntFormat(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper,%20com.fasterxml.jackson.databind.JavaType,%20com.fasterxml.jackson.core.JsonParser.NumberType,%20com.fasterxml.jackson.databind.jsonFormatVisitors.JsonValueFormat)">visitIntFormat</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#visitStringFormat(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper,%20com.fasterxml.jackson.databind.JavaType)">visitStringFormat</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#visitStringFormat(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper,%20com.fasterxml.jackson.databind.JavaType,%20com.fasterxml.jackson.databind.jsonFormatVisitors.JsonValueFormat)">visitStringFormat</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#wrapAndThrow(com.fasterxml.jackson.databind.SerializerProvider,%20java.lang.Throwable,%20java.lang.Object,%20int)">wrapAndThrow</a>, <a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#wrapAndThrow(com.fasterxml.jackson.databind.SerializerProvider,%20java.lang.Throwable,%20java.lang.Object,%20java.lang.String)">wrapAndThrow</a></code></li> </ul> <ul class="blockList"> <li class="blockList"><a name="methods_inherited_from_class_com.fasterxml.jackson.databind.JsonSerializer"> <!-- --> </a> <h3>Methods inherited from class&nbsp;com.fasterxml.jackson.databind.<a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a></h3> <code><a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html#getDelegatee()">getDelegatee</a>, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html#isEmpty(com.fasterxml.jackson.databind.SerializerProvider,%20T)">isEmpty</a>, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html#isUnwrappingSerializer()">isUnwrappingSerializer</a>, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html#properties()">properties</a>, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html#replaceDelegatee(com.fasterxml.jackson.databind.JsonSerializer)">replaceDelegatee</a>, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html#unwrappingSerializer(com.fasterxml.jackson.databind.util.NameTransformer)">unwrappingSerializer</a>, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html#usesObjectId()">usesObjectId</a>, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html#withFilterId(java.lang.Object)">withFilterId</a></code></li> </ul> <ul class="blockList"> <li class="blockList"><a name="methods_inherited_from_class_java.lang.Object"> <!-- --> </a> <h3>Methods inherited from class&nbsp;java.lang.<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3> <code><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#clone()" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#finalize()" title="class or interface in java.lang">finalize</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#toString()" title="class or interface in java.lang">toString</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true#wait(long,%20int)" title="class or interface in java.lang">wait</a></code></li> </ul> </li> </ul> </li> </ul> </div> <div class="details"> <ul class="blockList"> <li class="blockList"> <!-- ============ FIELD DETAIL =========== --> <ul class="blockList"> <li class="blockList"><a name="field_detail"> <!-- --> </a> <h3>Field Detail</h3> <a name="_elementType"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>_elementType</h4> <pre>protected final&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a> _elementType</pre> </li> </ul> <a name="_property"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>_property</h4> <pre>protected final&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a> _property</pre> <div class="block">Collection-valued property being serialized with this instance</div> </li> </ul> <a name="_staticTyping"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>_staticTyping</h4> <pre>protected final&nbsp;boolean _staticTyping</pre> </li> </ul> <a name="_unwrapSingle"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>_unwrapSingle</h4> <pre>protected final&nbsp;<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a> _unwrapSingle</pre> <div class="block">Setting for specific local override for "unwrap single element arrays": true for enable unwrapping, false for preventing it, `null` for using global configuration.</div> <dl><dt><span class="strong">Since:</span></dt> <dd>2.6</dd></dl> </li> </ul> <a name="_valueTypeSerializer"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>_valueTypeSerializer</h4> <pre>protected final&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a> _valueTypeSerializer</pre> <div class="block">Type serializer used for values, if any.</div> </li> </ul> <a name="_elementSerializer"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>_elementSerializer</h4> <pre>protected final&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&gt; _elementSerializer</pre> <div class="block">Value serializer to use, if it can be statically determined</div> </li> </ul> <a name="_dynamicSerializers"> <!-- --> </a> <ul class="blockListLast"> <li class="blockList"> <h4>_dynamicSerializers</h4> <pre>protected&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/ser/impl/PropertySerializerMap.html" title="class in com.fasterxml.jackson.databind.ser.impl">PropertySerializerMap</a> _dynamicSerializers</pre> <div class="block">If element type can not be statically determined, mapping from runtime type to serializer is handled using this object</div> </li> </ul> </li> </ul> <!-- ========= CONSTRUCTOR DETAIL ======== --> <ul class="blockList"> <li class="blockList"><a name="constructor_detail"> <!-- --> </a> <h3>Constructor Detail</h3> <a name="AsArraySerializerBase(java.lang.Class, com.fasterxml.jackson.databind.JavaType, boolean, com.fasterxml.jackson.databind.jsontype.TypeSerializer, com.fasterxml.jackson.databind.JsonSerializer)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>AsArraySerializerBase</h4> <pre>protected&nbsp;AsArraySerializerBase(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a>&lt;?&gt;&nbsp;cls, <a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a>&nbsp;et, boolean&nbsp;staticTyping, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&gt;&nbsp;elementSerializer)</pre> <div class="block">Non-contextual, "blueprint" constructor typically called when the first instance is created, without knowledge of property it was used via.</div> <dl><dt><span class="strong">Since:</span></dt> <dd>2.6</dd></dl> </li> </ul> <a name="AsArraySerializerBase(java.lang.Class, com.fasterxml.jackson.databind.JavaType, boolean, com.fasterxml.jackson.databind.jsontype.TypeSerializer, com.fasterxml.jackson.databind.BeanProperty, com.fasterxml.jackson.databind.JsonSerializer)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>AsArraySerializerBase</h4> <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a> protected&nbsp;AsArraySerializerBase(<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a>&lt;?&gt;&nbsp;cls, <a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a>&nbsp;et, boolean&nbsp;staticTyping, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&gt;&nbsp;elementSerializer)</pre> <div class="block"><span class="strong">Deprecated.</span>&nbsp;<i>Since 2.6 Use variants that either take 'src', or do NOT pass BeanProperty</i></div> </li> </ul> <a name="AsArraySerializerBase(com.fasterxml.jackson.databind.ser.std.AsArraySerializerBase, com.fasterxml.jackson.databind.BeanProperty, com.fasterxml.jackson.databind.jsontype.TypeSerializer, com.fasterxml.jackson.databind.JsonSerializer, java.lang.Boolean)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>AsArraySerializerBase</h4> <pre>protected&nbsp;AsArraySerializerBase(<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="class in com.fasterxml.jackson.databind.ser.std">AsArraySerializerBase</a>&lt;?&gt;&nbsp;src, <a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;&nbsp;elementSerializer, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a>&nbsp;unwrapSingle)</pre> </li> </ul> <a name="AsArraySerializerBase(com.fasterxml.jackson.databind.ser.std.AsArraySerializerBase, com.fasterxml.jackson.databind.BeanProperty, com.fasterxml.jackson.databind.jsontype.TypeSerializer, com.fasterxml.jackson.databind.JsonSerializer)"> <!-- --> </a> <ul class="blockListLast"> <li class="blockList"> <h4>AsArraySerializerBase</h4> <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a> protected&nbsp;AsArraySerializerBase(<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="class in com.fasterxml.jackson.databind.ser.std">AsArraySerializerBase</a>&lt;?&gt;&nbsp;src, <a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;&nbsp;elementSerializer)</pre> <div class="block"><span class="strong">Deprecated.</span>&nbsp;<i>since 2.6: use the overloaded method that takes 'unwrapSingle'</i></div> </li> </ul> </li> </ul> <!-- ============ METHOD DETAIL ========== --> <ul class="blockList"> <li class="blockList"><a name="method_detail"> <!-- --> </a> <h3>Method Detail</h3> <a name="withResolved(com.fasterxml.jackson.databind.BeanProperty, com.fasterxml.jackson.databind.jsontype.TypeSerializer, com.fasterxml.jackson.databind.JsonSerializer)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>withResolved</h4> <pre><a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Deprecated.html?is-external=true" title="class or interface in java.lang">@Deprecated</a> public final&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="class in com.fasterxml.jackson.databind.ser.std">AsArraySerializerBase</a>&lt;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&gt;&nbsp;withResolved(<a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;&nbsp;elementSerializer)</pre> <div class="block"><span class="strong">Deprecated.</span>&nbsp;<i>since 2.6: use the overloaded method that takes 'unwrapSingle'</i></div> </li> </ul> <a name="withResolved(com.fasterxml.jackson.databind.BeanProperty, com.fasterxml.jackson.databind.jsontype.TypeSerializer, com.fasterxml.jackson.databind.JsonSerializer, java.lang.Boolean)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>withResolved</h4> <pre>public abstract&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="class in com.fasterxml.jackson.databind.ser.std">AsArraySerializerBase</a>&lt;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&gt;&nbsp;withResolved(<a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;vts, <a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;&nbsp;elementSerializer, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Boolean.html?is-external=true" title="class or interface in java.lang">Boolean</a>&nbsp;unwrapSingle)</pre> <dl><dt><span class="strong">Since:</span></dt> <dd>2.6</dd></dl> </li> </ul> <a name="createContextual(com.fasterxml.jackson.databind.SerializerProvider, com.fasterxml.jackson.databind.BeanProperty)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>createContextual</h4> <pre>public&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;&nbsp;createContextual(<a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;serializers, <a href="../../../../../../com/fasterxml/jackson/databind/BeanProperty.html" title="interface in com.fasterxml.jackson.databind">BeanProperty</a>&nbsp;property) throws <a href="../../../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind">JsonMappingException</a></pre> <div class="block">This method is needed to resolve contextual annotations like per-property overrides, as well as do recursive call to <code>createContextual</code> of content serializer, if known statically.</div> <dl> <dt><strong>Specified by:</strong></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/ser/ContextualSerializer.html#createContextual(com.fasterxml.jackson.databind.SerializerProvider,%20com.fasterxml.jackson.databind.BeanProperty)">createContextual</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/ser/ContextualSerializer.html" title="interface in com.fasterxml.jackson.databind.ser">ContextualSerializer</a></code></dd> <dt><span class="strong">Parameters:</span></dt><dd><code>serializers</code> - Serializer provider to use for accessing config, other serializers</dd><dd><code>property</code> - Method or field that represents the property (and is used to access value to serialize). Should be available; but there may be cases where caller can not provide it and null is passed instead (in which case impls usually pass 'this' serializer as is)</dd> <dt><span class="strong">Returns:</span></dt><dd>Serializer to use for serializing values of specified property; may be this instance or a new instance.</dd> <dt><span class="strong">Throws:</span></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind">JsonMappingException</a></code></dd></dl> </li> </ul> <a name="getContentType()"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getContentType</h4> <pre>public&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a>&nbsp;getContentType()</pre> <div class="block"><strong>Description copied from class:&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html#getContentType()">ContainerSerializer</a></code></strong></div> <div class="block">Accessor for finding declared (static) element type for type this serializer is used for.</div> <dl> <dt><strong>Specified by:</strong></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html#getContentType()">getContentType</a></code>&nbsp;in class&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html" title="class in com.fasterxml.jackson.databind.ser">ContainerSerializer</a>&lt;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&gt;</code></dd> </dl> </li> </ul> <a name="getContentSerializer()"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getContentSerializer</h4> <pre>public&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;?&gt;&nbsp;getContentSerializer()</pre> <div class="block"><strong>Description copied from class:&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html#getContentSerializer()">ContainerSerializer</a></code></strong></div> <div class="block">Accessor for serializer used for serializing contents (List and array elements, Map values etc) of the container for which this serializer is used, if it is known statically. Note that for dynamic types this may return null; if so, caller has to instead use <a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html#getContentType()"><code>ContainerSerializer.getContentType()</code></a> and <a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html#findValueSerializer(java.lang.Class,%20com.fasterxml.jackson.databind.BeanProperty)"><code>SerializerProvider.findValueSerializer(java.lang.Class&lt;?&gt;, com.fasterxml.jackson.databind.BeanProperty)</code></a>.</div> <dl> <dt><strong>Specified by:</strong></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html#getContentSerializer()">getContentSerializer</a></code>&nbsp;in class&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/ser/ContainerSerializer.html" title="class in com.fasterxml.jackson.databind.ser">ContainerSerializer</a>&lt;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&gt;</code></dd> </dl> </li> </ul> <a name="serialize(java.lang.Object,com.fasterxml.jackson.core.JsonGenerator,com.fasterxml.jackson.databind.SerializerProvider)"> <!-- --> </a><a name="serialize(T, com.fasterxml.jackson.core.JsonGenerator, com.fasterxml.jackson.databind.SerializerProvider)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>serialize</h4> <pre>public&nbsp;void&nbsp;serialize(<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&nbsp;value, <a href="http://fasterxml.github.com/jackson-core/javadoc/2.7/com/fasterxml/jackson/core/JsonGenerator.html?is-external=true" title="class or interface in com.fasterxml.jackson.core">JsonGenerator</a>&nbsp;gen, <a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider) throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> <div class="block"><strong>Description copied from class:&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html#serialize(T,%20com.fasterxml.jackson.core.JsonGenerator,%20com.fasterxml.jackson.databind.SerializerProvider)">JsonSerializer</a></code></strong></div> <div class="block">Method that can be called to ask implementation to serialize values of type this serializer handles.</div> <dl> <dt><strong>Specified by:</strong></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#serialize(T,%20com.fasterxml.jackson.core.JsonGenerator,%20com.fasterxml.jackson.databind.SerializerProvider)">serialize</a></code>&nbsp;in class&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html" title="class in com.fasterxml.jackson.databind.ser.std">StdSerializer</a>&lt;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&gt;</code></dd> <dt><span class="strong">Parameters:</span></dt><dd><code>value</code> - Value to serialize; can <b>not</b> be null.</dd><dd><code>gen</code> - Generator used to output resulting Json content</dd><dd><code>provider</code> - Provider that can be used to get serializers for serializing Objects value contains, if any.</dd> <dt><span class="strong">Throws:</span></dt> <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd></dl> </li> </ul> <a name="serializeWithType(java.lang.Object,com.fasterxml.jackson.core.JsonGenerator,com.fasterxml.jackson.databind.SerializerProvider,com.fasterxml.jackson.databind.jsontype.TypeSerializer)"> <!-- --> </a><a name="serializeWithType(T, com.fasterxml.jackson.core.JsonGenerator, com.fasterxml.jackson.databind.SerializerProvider, com.fasterxml.jackson.databind.jsontype.TypeSerializer)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>serializeWithType</h4> <pre>public&nbsp;void&nbsp;serializeWithType(<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&nbsp;value, <a href="http://fasterxml.github.com/jackson-core/javadoc/2.7/com/fasterxml/jackson/core/JsonGenerator.html?is-external=true" title="class or interface in com.fasterxml.jackson.core">JsonGenerator</a>&nbsp;gen, <a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider, <a href="../../../../../../com/fasterxml/jackson/databind/jsontype/TypeSerializer.html" title="class in com.fasterxml.jackson.databind.jsontype">TypeSerializer</a>&nbsp;typeSer) throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> <div class="block"><strong>Description copied from class:&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html#serializeWithType(T,%20com.fasterxml.jackson.core.JsonGenerator,%20com.fasterxml.jackson.databind.SerializerProvider,%20com.fasterxml.jackson.databind.jsontype.TypeSerializer)">JsonSerializer</a></code></strong></div> <div class="block">Method that can be called to ask implementation to serialize values of type this serializer handles, using specified type serializer for embedding necessary type information. <p> Default implementation will throw <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/UnsupportedOperationException.html?is-external=true" title="class or interface in java.lang"><code>UnsupportedOperationException</code></a> to indicate that proper type handling needs to be implemented. <p> For simple datatypes written as a single scalar value (JSON String, Number, Boolean), implementation would look like: <pre> // note: method to call depends on whether this type is serialized as JSON scalar, object or Array! typeSer.writeTypePrefixForScalar(value, gen); serialize(value, gen, provider); typeSer.writeTypeSuffixForScalar(value, gen); </pre> and implementations for type serialized as JSON Arrays or Objects would differ slightly, as <code>START-ARRAY</code>/<code>END-ARRAY</code> and <code>START-OBJECT</code>/<code>END-OBJECT</code> pairs need to be properly handled with respect to serializing of contents.</div> <dl> <dt><strong>Overrides:</strong></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html#serializeWithType(T,%20com.fasterxml.jackson.core.JsonGenerator,%20com.fasterxml.jackson.databind.SerializerProvider,%20com.fasterxml.jackson.databind.jsontype.TypeSerializer)">serializeWithType</a></code>&nbsp;in class&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&gt;</code></dd> <dt><span class="strong">Parameters:</span></dt><dd><code>value</code> - Value to serialize; can <b>not</b> be null.</dd><dd><code>gen</code> - Generator used to output resulting Json content</dd><dd><code>provider</code> - Provider that can be used to get serializers for serializing Objects value contains, if any.</dd><dd><code>typeSer</code> - Type serializer to use for including type information</dd> <dt><span class="strong">Throws:</span></dt> <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd></dl> </li> </ul> <a name="serializeContents(java.lang.Object,com.fasterxml.jackson.core.JsonGenerator,com.fasterxml.jackson.databind.SerializerProvider)"> <!-- --> </a><a name="serializeContents(T, com.fasterxml.jackson.core.JsonGenerator, com.fasterxml.jackson.databind.SerializerProvider)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>serializeContents</h4> <pre>protected abstract&nbsp;void&nbsp;serializeContents(<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&nbsp;value, <a href="http://fasterxml.github.com/jackson-core/javadoc/2.7/com/fasterxml/jackson/core/JsonGenerator.html?is-external=true" title="class or interface in com.fasterxml.jackson.core">JsonGenerator</a>&nbsp;gen, <a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider) throws <a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></pre> <dl><dt><span class="strong">Throws:</span></dt> <dd><code><a href="http://docs.oracle.com/javase/7/docs/api/java/io/IOException.html?is-external=true" title="class or interface in java.io">IOException</a></code></dd></dl> </li> </ul> <a name="getSchema(com.fasterxml.jackson.databind.SerializerProvider, java.lang.reflect.Type)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>getSchema</h4> <pre>public&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/JsonNode.html" title="class in com.fasterxml.jackson.databind">JsonNode</a>&nbsp;getSchema(<a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/reflect/Type.html?is-external=true" title="class or interface in java.lang.reflect">Type</a>&nbsp;typeHint) throws <a href="../../../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind">JsonMappingException</a></pre> <div class="block"><strong>Description copied from class:&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#getSchema(com.fasterxml.jackson.databind.SerializerProvider,%20java.lang.reflect.Type)">StdSerializer</a></code></strong></div> <div class="block">Default implementation simply claims type is "string"; usually overriden by custom serializers.</div> <dl> <dt><strong>Specified by:</strong></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/jsonschema/SchemaAware.html#getSchema(com.fasterxml.jackson.databind.SerializerProvider,%20java.lang.reflect.Type)">getSchema</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/jsonschema/SchemaAware.html" title="interface in com.fasterxml.jackson.databind.jsonschema">SchemaAware</a></code></dd> <dt><strong>Overrides:</strong></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#getSchema(com.fasterxml.jackson.databind.SerializerProvider,%20java.lang.reflect.Type)">getSchema</a></code>&nbsp;in class&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html" title="class in com.fasterxml.jackson.databind.ser.std">StdSerializer</a>&lt;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&gt;</code></dd> <dt><span class="strong">Parameters:</span></dt><dd><code>provider</code> - The serializer provider.</dd><dd><code>typeHint</code> - A hint about the type.</dd> <dt><span class="strong">Returns:</span></dt><dd><a href="http://json-schema.org/">Json-schema</a> for this serializer.</dd> <dt><span class="strong">Throws:</span></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind">JsonMappingException</a></code></dd></dl> </li> </ul> <a name="acceptJsonFormatVisitor(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper, com.fasterxml.jackson.databind.JavaType)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>acceptJsonFormatVisitor</h4> <pre>public&nbsp;void&nbsp;acceptJsonFormatVisitor(<a href="../../../../../../com/fasterxml/jackson/databind/jsonFormatVisitors/JsonFormatVisitorWrapper.html" title="interface in com.fasterxml.jackson.databind.jsonFormatVisitors">JsonFormatVisitorWrapper</a>&nbsp;visitor, <a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a>&nbsp;typeHint) throws <a href="../../../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind">JsonMappingException</a></pre> <div class="block"><strong>Description copied from class:&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#acceptJsonFormatVisitor(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper,%20com.fasterxml.jackson.databind.JavaType)">StdSerializer</a></code></strong></div> <div class="block">Default implementation specifies no format. This behavior is usually overriden by custom serializers.</div> <dl> <dt><strong>Specified by:</strong></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/jsonFormatVisitors/JsonFormatVisitable.html#acceptJsonFormatVisitor(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper,%20com.fasterxml.jackson.databind.JavaType)">acceptJsonFormatVisitor</a></code>&nbsp;in interface&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/jsonFormatVisitors/JsonFormatVisitable.html" title="interface in com.fasterxml.jackson.databind.jsonFormatVisitors">JsonFormatVisitable</a></code></dd> <dt><strong>Overrides:</strong></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html#acceptJsonFormatVisitor(com.fasterxml.jackson.databind.jsonFormatVisitors.JsonFormatVisitorWrapper,%20com.fasterxml.jackson.databind.JavaType)">acceptJsonFormatVisitor</a></code>&nbsp;in class&nbsp;<code><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/StdSerializer.html" title="class in com.fasterxml.jackson.databind.ser.std">StdSerializer</a>&lt;<a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" title="type parameter in AsArraySerializerBase">T</a>&gt;</code></dd> <dd><code>typeHint</code> - Type of element (entity like property) being visited</dd> <dt><span class="strong">Throws:</span></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind">JsonMappingException</a></code></dd></dl> </li> </ul> <a name="_findAndAddDynamic(com.fasterxml.jackson.databind.ser.impl.PropertySerializerMap, java.lang.Class, com.fasterxml.jackson.databind.SerializerProvider)"> <!-- --> </a> <ul class="blockList"> <li class="blockList"> <h4>_findAndAddDynamic</h4> <pre>protected final&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&gt;&nbsp;_findAndAddDynamic(<a href="../../../../../../com/fasterxml/jackson/databind/ser/impl/PropertySerializerMap.html" title="class in com.fasterxml.jackson.databind.ser.impl">PropertySerializerMap</a>&nbsp;map, <a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Class.html?is-external=true" title="class or interface in java.lang">Class</a>&lt;?&gt;&nbsp;type, <a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider) throws <a href="../../../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind">JsonMappingException</a></pre> <dl><dt><span class="strong">Throws:</span></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind">JsonMappingException</a></code></dd></dl> </li> </ul> <a name="_findAndAddDynamic(com.fasterxml.jackson.databind.ser.impl.PropertySerializerMap, com.fasterxml.jackson.databind.JavaType, com.fasterxml.jackson.databind.SerializerProvider)"> <!-- --> </a> <ul class="blockListLast"> <li class="blockList"> <h4>_findAndAddDynamic</h4> <pre>protected final&nbsp;<a href="../../../../../../com/fasterxml/jackson/databind/JsonSerializer.html" title="class in com.fasterxml.jackson.databind">JsonSerializer</a>&lt;<a href="http://docs.oracle.com/javase/7/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a>&gt;&nbsp;_findAndAddDynamic(<a href="../../../../../../com/fasterxml/jackson/databind/ser/impl/PropertySerializerMap.html" title="class in com.fasterxml.jackson.databind.ser.impl">PropertySerializerMap</a>&nbsp;map, <a href="../../../../../../com/fasterxml/jackson/databind/JavaType.html" title="class in com.fasterxml.jackson.databind">JavaType</a>&nbsp;type, <a href="../../../../../../com/fasterxml/jackson/databind/SerializerProvider.html" title="class in com.fasterxml.jackson.databind">SerializerProvider</a>&nbsp;provider) throws <a href="../../../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind">JsonMappingException</a></pre> <dl><dt><span class="strong">Throws:</span></dt> <dd><code><a href="../../../../../../com/fasterxml/jackson/databind/JsonMappingException.html" title="class in com.fasterxml.jackson.databind">JsonMappingException</a></code></dd></dl> </li> </ul> </li> </ul> </li> </ul> </div> </div> <!-- ========= END OF CLASS DATA ========= --> <!-- ======= START OF BOTTOM NAVBAR ====== --> <div class="bottomNav"><a name="navbar_bottom"> <!-- --> </a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow"> <!-- --> </a> <ul class="navList" title="Navigation"> <li><a href="../../../../../../overview-summary.html">Overview</a></li> <li><a href="package-summary.html">Package</a></li> <li class="navBarCell1Rev">Class</li> <li><a href="class-use/AsArraySerializerBase.html">Use</a></li> <li><a href="package-tree.html">Tree</a></li> <li><a href="../../../../../../deprecated-list.html">Deprecated</a></li> <li><a href="../../../../../../index-all.html">Index</a></li> <li><a href="../../../../../../help-doc.html">Help</a></li> </ul> </div> <div class="subNav"> <ul class="navList"> <li><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/ArraySerializerBase.html" title="class in com.fasterxml.jackson.databind.ser.std"><span class="strong">Prev Class</span></a></li> <li><a href="../../../../../../com/fasterxml/jackson/databind/ser/std/AtomicReferenceSerializer.html" title="class in com.fasterxml.jackson.databind.ser.std"><span class="strong">Next Class</span></a></li> </ul> <ul class="navList"> <li><a href="../../../../../../index.html?com/fasterxml/jackson/databind/ser/std/AsArraySerializerBase.html" target="_top">Frames</a></li> <li><a href="AsArraySerializerBase.html" target="_top">No Frames</a></li> </ul> <ul class="navList" id="allclasses_navbar_bottom"> <li><a href="../../../../../../allclasses-noframe.html">All Classes</a></li> </ul> <div> <script type="text/javascript"><!-- allClassesLink = document.getElementById("allclasses_navbar_bottom"); if(window==top) { allClassesLink.style.display = "block"; } else { allClassesLink.style.display = "none"; } //--> </script> </div> <div> <ul class="subNavList"> <li>Summary:&nbsp;</li> <li><a href="#nested_classes_inherited_from_class_com.fasterxml.jackson.databind.JsonSerializer">Nested</a>&nbsp;|&nbsp;</li> <li><a href="#field_summary">Field</a>&nbsp;|&nbsp;</li> <li><a href="#constructor_summary">Constr</a>&nbsp;|&nbsp;</li> <li><a href="#method_summary">Method</a></li> </ul> <ul class="subNavList"> <li>Detail:&nbsp;</li> <li><a href="#field_detail">Field</a>&nbsp;|&nbsp;</li> <li><a href="#constructor_detail">Constr</a>&nbsp;|&nbsp;</li> <li><a href="#method_detail">Method</a></li> </ul> </div> <a name="skip-navbar_bottom"> <!-- --> </a></div> <!-- ======== END OF BOTTOM NAVBAR ======= --> <p class="legalCopy"><small>Copyright &#169; 2008&#x2013;2016 <a href="http://fasterxml.com/">FasterXML</a>. All rights reserved.</small></p> </body> </html>
{ "pile_set_name": "Github" }
/* * Copyright (C) 2007-2010 Júlio Vilmar Gesser. * Copyright (C) 2011, 2013-2016 The JavaParser Team. * * This file is part of JavaParser. * * JavaParser can be used either under the terms of * a) the GNU Lesser General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * b) the terms of the Apache License * * You should have received a copy of both licenses in LICENCE.LGPL and * LICENCE.APACHE. Please refer to those files for details. * * JavaParser is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU Lesser General Public License for more details. */ package com.github.javaparser.ast.expr; import com.github.javaparser.Range; import com.github.javaparser.ast.nodeTypes.NodeWithName; import com.github.javaparser.ast.visitor.GenericVisitor; import com.github.javaparser.ast.visitor.VoidVisitor; /** * @author Julio Vilmar Gesser */ public class NameExpr extends Expression implements NodeWithName<NameExpr> { private String name; public NameExpr() { } public NameExpr(final String name) { this.name = name; } public NameExpr(Range range, final String name) { super(range); this.name = name; } @Override public <R, A> R accept(final GenericVisitor<R, A> v, final A arg) { return v.visit(this, arg); } @Override public <A> void accept(final VoidVisitor<A> v, final A arg) { v.visit(this, arg); } @Override public final String getName() { return name; } @Override public NameExpr setName(final String name) { this.name = name; return this; } /** * Creates a new {@link NameExpr} from a qualified name.<br> * The qualified name can contains "." (dot) characters. * * @param qualifiedName * qualified name * @return instanceof {@link NameExpr} */ public static NameExpr name(String qualifiedName) { String[] split = qualifiedName.split("\\."); NameExpr ret = new NameExpr(split[0]); for (int i = 1; i < split.length; i++) { ret = new QualifiedNameExpr(ret, split[i]); } return ret; } }
{ "pile_set_name": "Github" }
/* Aggregator is a reporter used by the Ginkgo CLI to aggregate and present parallel test output coherently as tests complete. You shouldn't need to use this in your code. To run tests in parallel: ginkgo -nodes=N where N is the number of nodes you desire. */ package remote import ( "time" "github.com/onsi/ginkgo/config" "github.com/onsi/ginkgo/reporters/stenographer" "github.com/onsi/ginkgo/types" ) type configAndSuite struct { config config.GinkgoConfigType summary *types.SuiteSummary } type Aggregator struct { nodeCount int config config.DefaultReporterConfigType stenographer stenographer.Stenographer result chan bool suiteBeginnings chan configAndSuite aggregatedSuiteBeginnings []configAndSuite beforeSuites chan *types.SetupSummary aggregatedBeforeSuites []*types.SetupSummary afterSuites chan *types.SetupSummary aggregatedAfterSuites []*types.SetupSummary specCompletions chan *types.SpecSummary completedSpecs []*types.SpecSummary suiteEndings chan *types.SuiteSummary aggregatedSuiteEndings []*types.SuiteSummary specs []*types.SpecSummary startTime time.Time } func NewAggregator(nodeCount int, result chan bool, config config.DefaultReporterConfigType, stenographer stenographer.Stenographer) *Aggregator { aggregator := &Aggregator{ nodeCount: nodeCount, result: result, config: config, stenographer: stenographer, suiteBeginnings: make(chan configAndSuite), beforeSuites: make(chan *types.SetupSummary), afterSuites: make(chan *types.SetupSummary), specCompletions: make(chan *types.SpecSummary), suiteEndings: make(chan *types.SuiteSummary), } go aggregator.mux() return aggregator } func (aggregator *Aggregator) SpecSuiteWillBegin(config config.GinkgoConfigType, summary *types.SuiteSummary) { aggregator.suiteBeginnings <- configAndSuite{config, summary} } func (aggregator *Aggregator) BeforeSuiteDidRun(setupSummary *types.SetupSummary) { aggregator.beforeSuites <- setupSummary } func (aggregator *Aggregator) AfterSuiteDidRun(setupSummary *types.SetupSummary) { aggregator.afterSuites <- setupSummary } func (aggregator *Aggregator) SpecWillRun(specSummary *types.SpecSummary) { //noop } func (aggregator *Aggregator) SpecDidComplete(specSummary *types.SpecSummary) { aggregator.specCompletions <- specSummary } func (aggregator *Aggregator) SpecSuiteDidEnd(summary *types.SuiteSummary) { aggregator.suiteEndings <- summary } func (aggregator *Aggregator) mux() { loop: for { select { case configAndSuite := <-aggregator.suiteBeginnings: aggregator.registerSuiteBeginning(configAndSuite) case setupSummary := <-aggregator.beforeSuites: aggregator.registerBeforeSuite(setupSummary) case setupSummary := <-aggregator.afterSuites: aggregator.registerAfterSuite(setupSummary) case specSummary := <-aggregator.specCompletions: aggregator.registerSpecCompletion(specSummary) case suite := <-aggregator.suiteEndings: finished, passed := aggregator.registerSuiteEnding(suite) if finished { aggregator.result <- passed break loop } } } } func (aggregator *Aggregator) registerSuiteBeginning(configAndSuite configAndSuite) { aggregator.aggregatedSuiteBeginnings = append(aggregator.aggregatedSuiteBeginnings, configAndSuite) if len(aggregator.aggregatedSuiteBeginnings) == 1 { aggregator.startTime = time.Now() } if len(aggregator.aggregatedSuiteBeginnings) != aggregator.nodeCount { return } aggregator.stenographer.AnnounceSuite(configAndSuite.summary.SuiteDescription, configAndSuite.config.RandomSeed, configAndSuite.config.RandomizeAllSpecs, aggregator.config.Succinct) totalNumberOfSpecs := 0 if len(aggregator.aggregatedSuiteBeginnings) > 0 { totalNumberOfSpecs = configAndSuite.summary.NumberOfSpecsBeforeParallelization } aggregator.stenographer.AnnounceTotalNumberOfSpecs(totalNumberOfSpecs, aggregator.config.Succinct) aggregator.stenographer.AnnounceAggregatedParallelRun(aggregator.nodeCount, aggregator.config.Succinct) aggregator.flushCompletedSpecs() } func (aggregator *Aggregator) registerBeforeSuite(setupSummary *types.SetupSummary) { aggregator.aggregatedBeforeSuites = append(aggregator.aggregatedBeforeSuites, setupSummary) aggregator.flushCompletedSpecs() } func (aggregator *Aggregator) registerAfterSuite(setupSummary *types.SetupSummary) { aggregator.aggregatedAfterSuites = append(aggregator.aggregatedAfterSuites, setupSummary) aggregator.flushCompletedSpecs() } func (aggregator *Aggregator) registerSpecCompletion(specSummary *types.SpecSummary) { aggregator.completedSpecs = append(aggregator.completedSpecs, specSummary) aggregator.specs = append(aggregator.specs, specSummary) aggregator.flushCompletedSpecs() } func (aggregator *Aggregator) flushCompletedSpecs() { if len(aggregator.aggregatedSuiteBeginnings) != aggregator.nodeCount { return } for _, setupSummary := range aggregator.aggregatedBeforeSuites { aggregator.announceBeforeSuite(setupSummary) } for _, specSummary := range aggregator.completedSpecs { aggregator.announceSpec(specSummary) } for _, setupSummary := range aggregator.aggregatedAfterSuites { aggregator.announceAfterSuite(setupSummary) } aggregator.aggregatedBeforeSuites = []*types.SetupSummary{} aggregator.completedSpecs = []*types.SpecSummary{} aggregator.aggregatedAfterSuites = []*types.SetupSummary{} } func (aggregator *Aggregator) announceBeforeSuite(setupSummary *types.SetupSummary) { aggregator.stenographer.AnnounceCapturedOutput(setupSummary.CapturedOutput) if setupSummary.State != types.SpecStatePassed { aggregator.stenographer.AnnounceBeforeSuiteFailure(setupSummary, aggregator.config.Succinct, aggregator.config.FullTrace) } } func (aggregator *Aggregator) announceAfterSuite(setupSummary *types.SetupSummary) { aggregator.stenographer.AnnounceCapturedOutput(setupSummary.CapturedOutput) if setupSummary.State != types.SpecStatePassed { aggregator.stenographer.AnnounceAfterSuiteFailure(setupSummary, aggregator.config.Succinct, aggregator.config.FullTrace) } } func (aggregator *Aggregator) announceSpec(specSummary *types.SpecSummary) { if aggregator.config.Verbose && specSummary.State != types.SpecStatePending && specSummary.State != types.SpecStateSkipped { aggregator.stenographer.AnnounceSpecWillRun(specSummary) } aggregator.stenographer.AnnounceCapturedOutput(specSummary.CapturedOutput) switch specSummary.State { case types.SpecStatePassed: if specSummary.IsMeasurement { aggregator.stenographer.AnnounceSuccessfulMeasurement(specSummary, aggregator.config.Succinct) } else if specSummary.RunTime.Seconds() >= aggregator.config.SlowSpecThreshold { aggregator.stenographer.AnnounceSuccessfulSlowSpec(specSummary, aggregator.config.Succinct) } else { aggregator.stenographer.AnnounceSuccessfulSpec(specSummary) } case types.SpecStatePending: aggregator.stenographer.AnnouncePendingSpec(specSummary, aggregator.config.NoisyPendings && !aggregator.config.Succinct) case types.SpecStateSkipped: aggregator.stenographer.AnnounceSkippedSpec(specSummary, aggregator.config.Succinct || !aggregator.config.NoisySkippings, aggregator.config.FullTrace) case types.SpecStateTimedOut: aggregator.stenographer.AnnounceSpecTimedOut(specSummary, aggregator.config.Succinct, aggregator.config.FullTrace) case types.SpecStatePanicked: aggregator.stenographer.AnnounceSpecPanicked(specSummary, aggregator.config.Succinct, aggregator.config.FullTrace) case types.SpecStateFailed: aggregator.stenographer.AnnounceSpecFailed(specSummary, aggregator.config.Succinct, aggregator.config.FullTrace) } } func (aggregator *Aggregator) registerSuiteEnding(suite *types.SuiteSummary) (finished bool, passed bool) { aggregator.aggregatedSuiteEndings = append(aggregator.aggregatedSuiteEndings, suite) if len(aggregator.aggregatedSuiteEndings) < aggregator.nodeCount { return false, false } aggregatedSuiteSummary := &types.SuiteSummary{} aggregatedSuiteSummary.SuiteSucceeded = true for _, suiteSummary := range aggregator.aggregatedSuiteEndings { if !suiteSummary.SuiteSucceeded { aggregatedSuiteSummary.SuiteSucceeded = false } aggregatedSuiteSummary.NumberOfSpecsThatWillBeRun += suiteSummary.NumberOfSpecsThatWillBeRun aggregatedSuiteSummary.NumberOfTotalSpecs += suiteSummary.NumberOfTotalSpecs aggregatedSuiteSummary.NumberOfPassedSpecs += suiteSummary.NumberOfPassedSpecs aggregatedSuiteSummary.NumberOfFailedSpecs += suiteSummary.NumberOfFailedSpecs aggregatedSuiteSummary.NumberOfPendingSpecs += suiteSummary.NumberOfPendingSpecs aggregatedSuiteSummary.NumberOfSkippedSpecs += suiteSummary.NumberOfSkippedSpecs aggregatedSuiteSummary.NumberOfFlakedSpecs += suiteSummary.NumberOfFlakedSpecs } aggregatedSuiteSummary.RunTime = time.Since(aggregator.startTime) aggregator.stenographer.SummarizeFailures(aggregator.specs) aggregator.stenographer.AnnounceSpecRunCompletion(aggregatedSuiteSummary, aggregator.config.Succinct) return true, aggregatedSuiteSummary.SuiteSucceeded }
{ "pile_set_name": "Github" }
Hello there! Thank you for wanting to add more awesome speakers! How to add new speakers: - Add people that you believe hold awesome talks (you can also add yourself ☺️) - For privacy reasons, let people know you are adding them here ([example tweet](https://twitter.com/karlhorky/status/927550556570357760)) Format ([example pull request](https://github.com/karlhorky/awesome-speakers/pull/156)): - An image (Twitter profile picture is best) - Line 1: Name of the speaker - Line 2: Topics they talk about, capitalized (future topics in parentheses) - Line 3: Contact link (Twitter and GitHub accepted) Also please always write backslashes at the end of Line 1 and 2 to create newlines in Markdown. Thank you for reading! [Karl Horky](https://twitter.com/karlhorky) [Sara Vieira](https://twitter.com/NikkitaFTW)
{ "pile_set_name": "Github" }
# #-- 03-testbound.test --# # source the master var file when it's there [ -f ../.tpkg.var.master ] && source ../.tpkg.var.master # use .tpkg.var.test for in test variable passing [ -f .tpkg.var.test ] && source .tpkg.var.test . ../common.sh PRE="../.." get_make (cd $PRE ; $MAKE testbound) exitval=0 # quiet="" to make verbose if test -f $PRE/unbound_do_valgrind_in_test; then do_valgrind=yes else do_valgrind=no fi VALGRIND_FLAGS="--leak-check=full --show-leak-kinds=all" # valgrind mode for debug #if grep "staticexe=-static" $PRE/Makefile >/dev/null 2>&1; then # if test -x "`which valgrind`"; then # do_valgrind=yes # fi #fi # self-test (unit test of testbound) if test $do_valgrind = "yes"; then echo "valgrind yes" echo if (valgrind $VALGRIND_FLAGS $PRE/testbound -s >tmpout 2>&1;); then echo "selftest OK " else echo "selftest FAILED" exit 1 fi if grep "All heap blocks were freed -- no leaks are possible" tmpout; then : # clean else cat tmpout echo "Memory leaked in selftest" grep "in use at exit" tmpout exit 1 fi if grep "ERROR SUMMARY: 0 errors from 0 contexts" tmpout; then : # clean else cat tmpout echo "Errors in selftest" grep "ERROR SUMMARY" tmpout exit 1 fi else if ($PRE/testbound -s >/dev/null 2>&1;); then echo "selftest OK " else echo "selftest FAILED" exit 1 fi fi # the .crpl are not always supported and need checking for SHA256 and GOST # support. # the .rpl should work on any system (portable). for input in $PRE/testdata/*.rpl $PRE/testdata/*.crpl; do header=`grep SCENARIO_BEGIN $input | head -1 | sed -e 's/SCENARIO_BEGIN //'` cleaninput=`echo $input | sed -e "s?$PRE/testdata/??"` # detect if SHA256 is needed if echo $cleaninput | grep sha2 >/dev/null 2>&1; then if $PRE/testbound -2 >/dev/null 2>&1; then : # the SHA256 is supported else continue fi fi # detect if GOST is needed if echo $cleaninput | grep gost >/dev/null 2>&1; then if $PRE/testbound -g >/dev/null 2>&1; then : # GOST is supported else continue fi fi # detect if CLIENT_SUBNET is needed if echo $cleaninput | grep subnet >/dev/null 2>&1; then if $PRE/testbound -c >/dev/null 2>&1; then : # CLIENT_SUBNET is supported else continue fi fi # detect if IPSECMOD is needed if echo $cleaninput | grep ipsecmod >/dev/null 2>&1; then if $PRE/testbound -i >/dev/null 2>&1; then : # IPSECMOD is supported else continue fi fi if test $do_valgrind = "yes"; then echo if (valgrind $VALGRIND_FLAGS $PRE/testbound -p $input >tmpout 2>&1;); then echo " OK $cleaninput: $header" else echo "FAILED $cleaninput: $header" exitval=1 fi if grep "All heap blocks were freed -- no leaks are possible" tmpout; then : # clean else grep "^==" tmpout echo "Memory leaked in $cleaninput" grep "in use at exit" tmpout exitval=1 fi if grep "ERROR SUMMARY: 0 errors from 0 contexts" tmpout; then : # clean else grep "^==" tmpout echo "Errors in $cleaninput" grep "ERROR SUMMARY" tmpout exitval=1 fi else # do valgrind=no if ($PRE/testbound -p $input >/dev/null 2>&1;); then echo " OK $cleaninput: $header" else echo "FAILED $cleaninput: $header" exitval=1 fi fi if test -f ublocktrace.0; then if $PRE/lock-verify ublocktrace.*; then #echo "lock-verify test $input worked." i=i else echo "lock-verify test $input failed." exitval=1 fi fi done exit $exitval
{ "pile_set_name": "Github" }
/* Copyright (c) 2011 Xiph.Org Foundation Written by Jean-Marc Valin */ /* Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: - Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. - 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. 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 OWNER 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. */ #ifdef HAVE_CONFIG_H #include "config.h" #endif #include "../include/opus_multistream.h" #include "../include/opus.h" #include "opus_private.h" #include "../celt/stack_alloc.h" #include <stdarg.h> #include "../celt/float_cast.h" #include "../celt/os_support.h" struct OpusMSDecoder { ChannelLayout layout; /* Decoder states go here */ }; /* DECODER */ opus_int32 opus_multistream_decoder_get_size(int nb_streams, int nb_coupled_streams) { int coupled_size; int mono_size; if(nb_streams<1||nb_coupled_streams>nb_streams||nb_coupled_streams<0)return 0; coupled_size = opus_decoder_get_size(2); mono_size = opus_decoder_get_size(1); return align(sizeof(OpusMSDecoder)) + nb_coupled_streams * align(coupled_size) + (nb_streams-nb_coupled_streams) * align(mono_size); } int opus_multistream_decoder_init( OpusMSDecoder *st, opus_int32 Fs, int channels, int streams, int coupled_streams, const unsigned char *mapping ) { int coupled_size; int mono_size; int i, ret; char *ptr; if ((channels>255) || (channels<1) || (coupled_streams>streams) || (coupled_streams+streams>255) || (streams<1) || (coupled_streams<0)) return OPUS_BAD_ARG; st->layout.nb_channels = channels; st->layout.nb_streams = streams; st->layout.nb_coupled_streams = coupled_streams; for (i=0;i<st->layout.nb_channels;i++) st->layout.mapping[i] = mapping[i]; if (!validate_layout(&st->layout)) return OPUS_BAD_ARG; ptr = (char*)st + align(sizeof(OpusMSDecoder)); coupled_size = opus_decoder_get_size(2); mono_size = opus_decoder_get_size(1); for (i=0;i<st->layout.nb_coupled_streams;i++) { ret=opus_decoder_init((OpusDecoder*)ptr, Fs, 2); if(ret!=OPUS_OK)return ret; ptr += align(coupled_size); } for (;i<st->layout.nb_streams;i++) { ret=opus_decoder_init((OpusDecoder*)ptr, Fs, 1); if(ret!=OPUS_OK)return ret; ptr += align(mono_size); } return OPUS_OK; } OpusMSDecoder *opus_multistream_decoder_create( opus_int32 Fs, int channels, int streams, int coupled_streams, const unsigned char *mapping, int *error ) { int ret; OpusMSDecoder *st; if ((channels>255) || (channels<1) || (coupled_streams>streams) || (coupled_streams+streams>255) || (streams<1) || (coupled_streams<0)) { if (error) *error = OPUS_BAD_ARG; return NULL; } st = (OpusMSDecoder *)opus_alloc(opus_multistream_decoder_get_size(streams, coupled_streams)); if (st==NULL) { if (error) *error = OPUS_ALLOC_FAIL; return NULL; } ret = opus_multistream_decoder_init(st, Fs, channels, streams, coupled_streams, mapping); if (error) *error = ret; if (ret != OPUS_OK) { opus_free(st); st = NULL; } return st; } typedef void (*opus_copy_channel_out_func)( void *dst, int dst_stride, int dst_channel, const opus_val16 *src, int src_stride, int frame_size ); static int opus_multistream_packet_validate(const unsigned char *data, opus_int32 len, int nb_streams, opus_int32 Fs) { int s; int count; unsigned char toc; opus_int16 size[48]; int samples=0; opus_int32 packet_offset; for (s=0;s<nb_streams;s++) { int tmp_samples; if (len<=0) return OPUS_INVALID_PACKET; count = opus_packet_parse_impl(data, len, s!=nb_streams-1, &toc, NULL, size, NULL, &packet_offset); if (count<0) return count; tmp_samples = opus_packet_get_nb_samples(data, packet_offset, Fs); if (s!=0 && samples != tmp_samples) return OPUS_INVALID_PACKET; samples = tmp_samples; data += packet_offset; len -= packet_offset; } return samples; } static int opus_multistream_decode_native( OpusMSDecoder *st, const unsigned char *data, opus_int32 len, void *pcm, opus_copy_channel_out_func copy_channel_out, int frame_size, int decode_fec, int soft_clip ) { opus_int32 Fs; int coupled_size; int mono_size; int s, c; char *ptr; int do_plc=0; VARDECL(opus_val16, buf); ALLOC_STACK; /* Limit frame_size to avoid excessive stack allocations. */ opus_multistream_decoder_ctl(st, OPUS_GET_SAMPLE_RATE(&Fs)); frame_size = IMIN(frame_size, Fs/25*3); ALLOC(buf, 2*frame_size, opus_val16); ptr = (char*)st + align(sizeof(OpusMSDecoder)); coupled_size = opus_decoder_get_size(2); mono_size = opus_decoder_get_size(1); if (len==0) do_plc = 1; if (len < 0) { RESTORE_STACK; return OPUS_BAD_ARG; } if (!do_plc && len < 2*st->layout.nb_streams-1) { RESTORE_STACK; return OPUS_INVALID_PACKET; } if (!do_plc) { int ret = opus_multistream_packet_validate(data, len, st->layout.nb_streams, Fs); if (ret < 0) { RESTORE_STACK; return ret; } else if (ret > frame_size) { RESTORE_STACK; return OPUS_BUFFER_TOO_SMALL; } } for (s=0;s<st->layout.nb_streams;s++) { OpusDecoder *dec; int packet_offset, ret; dec = (OpusDecoder*)ptr; ptr += (s < st->layout.nb_coupled_streams) ? align(coupled_size) : align(mono_size); if (!do_plc && len<=0) { RESTORE_STACK; return OPUS_INTERNAL_ERROR; } packet_offset = 0; ret = opus_decode_native(dec, data, len, buf, frame_size, decode_fec, s!=st->layout.nb_streams-1, &packet_offset, soft_clip); data += packet_offset; len -= packet_offset; if (ret <= 0) { RESTORE_STACK; return ret; } frame_size = ret; if (s < st->layout.nb_coupled_streams) { int chan, prev; prev = -1; /* Copy "left" audio to the channel(s) where it belongs */ while ( (chan = get_left_channel(&st->layout, s, prev)) != -1) { (*copy_channel_out)(pcm, st->layout.nb_channels, chan, buf, 2, frame_size); prev = chan; } prev = -1; /* Copy "right" audio to the channel(s) where it belongs */ while ( (chan = get_right_channel(&st->layout, s, prev)) != -1) { (*copy_channel_out)(pcm, st->layout.nb_channels, chan, buf+1, 2, frame_size); prev = chan; } } else { int chan, prev; prev = -1; /* Copy audio to the channel(s) where it belongs */ while ( (chan = get_mono_channel(&st->layout, s, prev)) != -1) { (*copy_channel_out)(pcm, st->layout.nb_channels, chan, buf, 1, frame_size); prev = chan; } } } /* Handle muted channels */ for (c=0;c<st->layout.nb_channels;c++) { if (st->layout.mapping[c] == 255) { (*copy_channel_out)(pcm, st->layout.nb_channels, c, NULL, 0, frame_size); } } RESTORE_STACK; return frame_size; } #if !defined(DISABLE_FLOAT_API) static void opus_copy_channel_out_float( void *dst, int dst_stride, int dst_channel, const opus_val16 *src, int src_stride, int frame_size ) { float *float_dst; opus_int32 i; float_dst = (float*)dst; if (src != NULL) { for (i=0;i<frame_size;i++) #if defined(FIXED_POINT) float_dst[i*dst_stride+dst_channel] = (1/32768.f)*src[i*src_stride]; #else float_dst[i*dst_stride+dst_channel] = src[i*src_stride]; #endif } else { for (i=0;i<frame_size;i++) float_dst[i*dst_stride+dst_channel] = 0; } } #endif static void opus_copy_channel_out_short( void *dst, int dst_stride, int dst_channel, const opus_val16 *src, int src_stride, int frame_size ) { opus_int16 *short_dst; opus_int32 i; short_dst = (opus_int16*)dst; if (src != NULL) { for (i=0;i<frame_size;i++) #if defined(FIXED_POINT) short_dst[i*dst_stride+dst_channel] = src[i*src_stride]; #else short_dst[i*dst_stride+dst_channel] = FLOAT2INT16(src[i*src_stride]); #endif } else { for (i=0;i<frame_size;i++) short_dst[i*dst_stride+dst_channel] = 0; } } #ifdef FIXED_POINT int opus_multistream_decode( OpusMSDecoder *st, const unsigned char *data, opus_int32 len, opus_int16 *pcm, int frame_size, int decode_fec ) { return opus_multistream_decode_native(st, data, len, pcm, opus_copy_channel_out_short, frame_size, decode_fec, 0); } #ifndef DISABLE_FLOAT_API int opus_multistream_decode_float(OpusMSDecoder *st, const unsigned char *data, opus_int32 len, float *pcm, int frame_size, int decode_fec) { return opus_multistream_decode_native(st, data, len, pcm, opus_copy_channel_out_float, frame_size, decode_fec, 0); } #endif #else int opus_multistream_decode(OpusMSDecoder *st, const unsigned char *data, opus_int32 len, opus_int16 *pcm, int frame_size, int decode_fec) { return opus_multistream_decode_native(st, data, len, pcm, opus_copy_channel_out_short, frame_size, decode_fec, 1); } int opus_multistream_decode_float( OpusMSDecoder *st, const unsigned char *data, opus_int32 len, float *pcm, int frame_size, int decode_fec ) { return opus_multistream_decode_native(st, data, len, pcm, opus_copy_channel_out_float, frame_size, decode_fec, 0); } #endif int opus_multistream_decoder_ctl(OpusMSDecoder *st, int request, ...) { va_list ap; int coupled_size, mono_size; char *ptr; int ret = OPUS_OK; va_start(ap, request); coupled_size = opus_decoder_get_size(2); mono_size = opus_decoder_get_size(1); ptr = (char*)st + align(sizeof(OpusMSDecoder)); switch (request) { case OPUS_GET_BANDWIDTH_REQUEST: case OPUS_GET_SAMPLE_RATE_REQUEST: case OPUS_GET_GAIN_REQUEST: case OPUS_GET_LAST_PACKET_DURATION_REQUEST: { OpusDecoder *dec; /* For int32* GET params, just query the first stream */ opus_int32 *value = va_arg(ap, opus_int32*); dec = (OpusDecoder*)ptr; ret = opus_decoder_ctl(dec, request, value); } break; case OPUS_GET_FINAL_RANGE_REQUEST: { int s; opus_uint32 *value = va_arg(ap, opus_uint32*); opus_uint32 tmp; if (!value) { goto bad_arg; } *value = 0; for (s=0;s<st->layout.nb_streams;s++) { OpusDecoder *dec; dec = (OpusDecoder*)ptr; if (s < st->layout.nb_coupled_streams) ptr += align(coupled_size); else ptr += align(mono_size); ret = opus_decoder_ctl(dec, request, &tmp); if (ret != OPUS_OK) break; *value ^= tmp; } } break; case OPUS_RESET_STATE: { int s; for (s=0;s<st->layout.nb_streams;s++) { OpusDecoder *dec; dec = (OpusDecoder*)ptr; if (s < st->layout.nb_coupled_streams) ptr += align(coupled_size); else ptr += align(mono_size); ret = opus_decoder_ctl(dec, OPUS_RESET_STATE); if (ret != OPUS_OK) break; } } break; case OPUS_MULTISTREAM_GET_DECODER_STATE_REQUEST: { int s; opus_int32 stream_id; OpusDecoder **value; stream_id = va_arg(ap, opus_int32); if (stream_id<0 || stream_id >= st->layout.nb_streams) ret = OPUS_BAD_ARG; value = va_arg(ap, OpusDecoder**); if (!value) { goto bad_arg; } for (s=0;s<stream_id;s++) { if (s < st->layout.nb_coupled_streams) ptr += align(coupled_size); else ptr += align(mono_size); } *value = (OpusDecoder*)ptr; } break; case OPUS_SET_GAIN_REQUEST: { int s; /* This works for int32 params */ opus_int32 value = va_arg(ap, opus_int32); for (s=0;s<st->layout.nb_streams;s++) { OpusDecoder *dec; dec = (OpusDecoder*)ptr; if (s < st->layout.nb_coupled_streams) ptr += align(coupled_size); else ptr += align(mono_size); ret = opus_decoder_ctl(dec, request, value); if (ret != OPUS_OK) break; } } break; default: ret = OPUS_UNIMPLEMENTED; break; } va_end(ap); return ret; bad_arg: va_end(ap); return OPUS_BAD_ARG; } void opus_multistream_decoder_destroy(OpusMSDecoder *st) { opus_free(st); }
{ "pile_set_name": "Github" }
fileFormatVersion: 2 guid: 98a2d8b0832fa7d43817129a4a09c8a0 timeCreated: 1503273260 licenseType: Free NativeFormatImporter: mainObjectFileID: 2100000 userData: assetBundleName: assetBundleVariant:
{ "pile_set_name": "Github" }
//////////////////////////////////////////////// // // radiance hints // //////////////////////////////////////////////// lazyshader 0 "rsmsky" [ attribute vec4 vvertex; uniform mat4 rsmmatrix; void main(void) { gl_Position = rsmmatrix * vvertex; } ] [ fragdata(0) vec4 gcolor; fragdata(1) vec4 gnormal; void main(void) { gcolor = vec4(0.0, 0.0, 0.0, 1.0); gnormal = vec4(0.5, 0.5, 0.5, 0.0); } ] rhtapoffsets12 = [ "0.0565813, 0.61211, 0.763359" "0.375225, 0.285592, 0.987915" "0.615192, 0.668996, 0.604938" "0.963195, 0.355937, 0.175787" "0.0295724, 0.484268, 0.265694" "0.917783, 0.88702, 0.201972" "0.408948, 0.0675985, 0.427564" "0.19071, 0.923612, 0.0553606" "0.968078, 0.403943, 0.847224" "0.384503, 0.922269, 0.990844" "0.480605, 0.342418, 0.00195318" "0.956664, 0.923643, 0.915799" ] rhtapoffsets20 = [ "0.0540788, 0.411725, 0.134068" "0.0163579, 0.416211, 0.992035" "0.692068, 0.549272, 0.886502" "0.305795, 0.781854, 0.571337" "0.791681, 0.139042, 0.247047" "0.83929, 0.973663, 0.460982" "0.0336314, 0.0867641, 0.582324" "0.148198, 0.961974, 0.0378124" "0.948729, 0.0713828, 0.916379" "0.586413, 0.591845, 0.031251" "0.00189215, 0.973968, 0.932981" "0.435865, 0.0853603, 0.995148" "0.36848, 0.820612, 0.942717" "0.500107, 0.0658284, 0.623005" "0.580187, 0.4485, 0.379223" "0.258614, 0.0201422, 0.241005" "0.987152, 0.441664, 0.43318" "0.925108, 0.917203, 0.921506" "0.988372, 0.822047, 0.12479" "0.330393, 0.43611, 0.762566" ] rhtapoffsets32 = [ "0.0553911, 0.675924, 0.22129" "0.562975, 0.508286, 0.549883" "0.574816, 0.703452, 0.0513016" "0.981017, 0.930479, 0.243873" "0.889309, 0.133091, 0.319071" "0.329112, 0.00759911, 0.472213" "0.314463, 0.985839, 0.54442" "0.407697, 0.202643, 0.985748" "0.998169, 0.760369, 0.792932" "0.0917692, 0.0666829, 0.0169683" "0.0157781, 0.632954, 0.740806" "0.938139, 0.235878, 0.87936" "0.442305, 0.184942, 0.0901212" "0.578051, 0.863948, 0.799554" "0.0698569, 0.259194, 0.667592" "0.872494, 0.576312, 0.344157" "0.10123, 0.930082, 0.959929" "0.178594, 0.991302, 0.046205" "0.690176, 0.527543, 0.930509" "0.982025, 0.389447, 0.0344554" "0.033845, 0.0156865, 0.963866" "0.655293, 0.154271, 0.640553" "0.317881, 0.598621, 0.97998" "0.247261, 0.398206, 0.121586" "0.822626, 0.985076, 0.655232" "0.00201422, 0.434278, 0.388348" "0.511399, 0.977416, 0.278695" "0.32371, 0.540147, 0.361187" "0.365856, 0.41493, 0.758232" "0.792871, 0.979217, 0.0309763" "0.0509049, 0.459151, 0.996277" "0.0305185, 0.13422, 0.306009" ] rsmtapoffsets12 = [ "0.031084, 0.572114" "0.040671, 0.95653" "0.160921, 0.367819" "0.230518, 0.134321" "0.247078, 0.819415" "0.428665, 0.440522" "0.49846, 0.80717" "0.604285, 0.0307766" "0.684075, 0.283001" "0.688304, 0.624171" "0.833995, 0.832414" "0.975397, 0.189911" ] rsmtapoffsets20 = [ "0.00240055, 0.643992" "0.0356464, 0.851616" "0.101733, 0.21876" "0.166119, 0.0278085" "0.166438, 0.474999" "0.24991, 0.766405" "0.333714, 0.130407" "0.400681, 0.374781" "0.424067, 0.888211" "0.448511, 0.678962" "0.529383, 0.213568" "0.608569, 0.47715" "0.617996, 0.862528" "0.631784, 0.0515881" "0.740969, 0.20753" "0.788203, 0.41923" "0.794066, 0.615141" "0.834504, 0.836612" "0.89446, 0.0677863" "0.975609, 0.446056" ] rsmtapoffsets32 = [ "0.0262032, 0.215221" "0.0359769, 0.0467256" "0.0760799, 0.713481" "0.115087, 0.461431" "0.119488, 0.927444" "0.22346, 0.319747" "0.225964, 0.679227" "0.238626, 0.0618425" "0.243326, 0.535066" "0.29832, 0.90826" "0.335208, 0.212103" "0.356438, 0.751969" "0.401021, 0.478664" "0.412027, 0.0245297" "0.48477, 0.320659" "0.494311, 0.834621" "0.515007, 0.165552" "0.534574, 0.675536" "0.585357, 0.432483" "0.600102, 0.94139" "0.650182, 0.563571" "0.672336, 0.771816" "0.701811, 0.187078" "0.734207, 0.359024" "0.744775, 0.924466" "0.763628, 0.659075" "0.80735, 0.521281" "0.880585, 0.107684" "0.898505, 0.904047" "0.902536, 0.718989" "0.928022, 0.347802" "0.971243, 0.504885" ] radiancehintsshader = [ numtaps = (cond [> $arg1 20] 32 [> $arg1 12] 20 12) shader 0 [radiancehints@arg1] [ attribute vec4 vvertex; attribute vec3 vtexcoord0; uniform mat4 rsmtcmatrix; varying vec3 rhcenter; varying vec2 rsmcenter; void main(void) { gl_Position = vvertex; rhcenter = vtexcoord0; rsmcenter = (rsmtcmatrix * vec4(vtexcoord0, 1.0)).xy; } ] [ uniform sampler2DRect tex0, tex1, tex2; uniform mat4 rsmworldmatrix; uniform vec2 rsmspread; uniform float rhatten, rhspread, rhaothreshold, rhaoatten, rhaoheight; uniform vec3 rsmdir; varying vec3 rhcenter; varying vec2 rsmcenter; fragdata(0) vec4 rhr; fragdata(1) vec4 rhg; fragdata(2) vec4 rhb; fragdata(3) vec4 rha; void calcrhsample(vec3 rhtap, vec2 rsmtap, inout vec4 shr, inout vec4 shg, inout vec4 shb, inout vec4 sha) { vec3 rhpos = rhcenter + rhtap*rhspread; vec2 rsmtc = rsmcenter + rsmtap*rsmspread; float rsmdepth = texture2DRect(tex0, rsmtc).x; vec3 rsmcolor = texture2DRect(tex1, rsmtc).rgb; vec3 rsmnormal = texture2DRect(tex2, rsmtc).xyz*2.0 - 1.0; vec3 rsmpos = (rsmworldmatrix * vec4(rsmtc, rsmdepth, 1.0)).xyz; vec3 dir = rhpos - rsmpos; sha += step(rhaothreshold, dir.z) * vec4(normalize(vec3(dir.xy, min(dot(dir.xy, dir.xy) * rhaoatten - rhaoheight, 0.0))), 1.0); float dist = dot(dir, dir); if(dist > 0.000049) dir = normalize(dir); float atten = clamp(dot(dir, rsmnormal), 0.0, 1.0) / (0.1 + dist*rhatten); rsmcolor *= atten; shr += vec4(rsmcolor.r*dir, rsmcolor.r); shg += vec4(rsmcolor.g*dir, rsmcolor.g); shb += vec4(rsmcolor.b*dir, rsmcolor.b); } void main(void) { vec4 shr = vec4(0.0), shg = vec4(0.0), shb = vec4(0.0), sha = vec4(0.0); @(loopconcat i $numtaps [result [ calcrhsample(vec3(@(at $[rhtapoffsets@numtaps] $i))*2.0 - 1.0, vec2(@(at $[rsmtapoffsets@numtaps] $i))*2.0 - 1.0, shr, shg, shb, sha); ]]) rhr = shr * (vec4(0.5, 0.5, 0.5, 1.0)/@(+f $numtaps)) + vec4(0.5, 0.5, 0.5, 0.0); rhg = shg * (vec4(0.5, 0.5, 0.5, 1.0)/@(+f $numtaps)) + vec4(0.5, 0.5, 0.5, 0.0); rhb = shb * (vec4(0.5, 0.5, 0.5, 1.0)/@(+f $numtaps)) + vec4(0.5, 0.5, 0.5, 0.0); rha = sha * (vec4(0.5, 0.5, 0.5, 1.0)/@(+f $numtaps)) + vec4(0.5, 0.5, 0.5, 0.0); } ] ] lazyshader 0 radiancehintsborder [ attribute vec4 vvertex; attribute vec3 vtexcoord0; varying vec3 texcoord0; void main(void) { gl_Position = vvertex; texcoord0 = vtexcoord0; } ] [ uniform sampler3D tex3, tex4, tex5, tex6; uniform vec3 bordercenter, borderrange, borderscale; varying vec3 texcoord0; fragdata(0) vec4 rhr; fragdata(1) vec4 rhg; fragdata(2) vec4 rhb; fragdata(3) vec4 rha; void main(void) { float outside = clamp(borderscale.z*(abs(texcoord0.z - bordercenter.z) - borderrange.z), 0.0, 1.0); vec3 tc = vec3(texcoord0.xy, clamp(texcoord0.z, bordercenter.z - borderrange.z, bordercenter.z + borderrange.z)); rhr = mix(texture3D(tex3, tc), vec4(0.5, 0.5, 0.5, 0.0), outside); rhg = mix(texture3D(tex4, tc), vec4(0.5, 0.5, 0.5, 0.0), outside); rhb = mix(texture3D(tex5, tc), vec4(0.5, 0.5, 0.5, 0.0), outside); rha = mix(texture3D(tex6, tc), vec4(0.5, 0.5, 0.5, 0.0), outside); } ] lazyshader 0 radiancehintscached [ attribute vec4 vvertex; attribute vec3 vtexcoord0; varying vec3 texcoord0; void main(void) { gl_Position = vvertex; texcoord0 = vtexcoord0; } ] [ uniform sampler3D tex7, tex8, tex9, tex10; varying vec3 texcoord0; fragdata(0) vec4 rhr; fragdata(1) vec4 rhg; fragdata(2) vec4 rhb; fragdata(3) vec4 rha; void main(void) { rhr = texture3D(tex7, texcoord0); rhg = texture3D(tex8, texcoord0); rhb = texture3D(tex9, texcoord0); rha = texture3D(tex10, texcoord0); } ] lazyshader 0 radiancehintsdisable [ attribute vec4 vvertex; uniform vec3 rhcenter; uniform float rhbounds; void main(void) { gl_Position = vec4((vvertex.xy - rhcenter.xy)/rhbounds, vvertex.zw); } ] [ fragdata(0) vec4 rhr; fragdata(1) vec4 rhg; fragdata(2) vec4 rhb; fragdata(3) vec4 rha; void main(void) { rhr = vec4(0.5, 0.5, 0.5, 0.0); rhg = vec4(0.5, 0.5, 0.5, 0.0); rhb = vec4(0.5, 0.5, 0.5, 0.0); rha = vec4(0.5, 0.5, 0.5, 0.0); } ]
{ "pile_set_name": "Github" }
<?php /** * Zend Framework * * LICENSE * * This source file is subject to the new BSD license that is bundled * with this package in the file LICENSE.txt. * It is also available through the world-wide-web at this URL: * http://framework.zend.com/license/new-bsd * If you did not receive a copy of the license and are unable to * obtain it through the world-wide-web, please send an email * to [email protected] so we can send you a copy immediately. * * @category Zend * @package Zend_Media * @subpackage ID3 * @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License * @version $Id: Tcop.php 177 2010-03-09 13:13:34Z svollbehr $ */ /**#@+ @ignore */ require_once 'Zend/Media/Id3/TextFrame.php'; /**#@-*/ /** * The <i>Copyright message</i> frame, in which the string must begin with a * year and a space character (making five characters), is intended for the * copyright holder of the original sound, not the audio file itself. The * absence of this frame means only that the copyright information is * unavailable or has been removed, and must not be interpreted to mean that the * audio is public domain. Every time this field is displayed the field must be * preceded with 'Copyright ' (C) ' ', where (C) is one character showing a C in * a circle. * * @category Zend * @package Zend_Media * @subpackage ID3 * @author Sven Vollbehr <[email protected]> * @copyright Copyright (c) 2005-2009 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License * @version $Id: Tcop.php 177 2010-03-09 13:13:34Z svollbehr $ */ final class Zend_Media_Id3_Frame_Tcop extends Zend_Media_Id3_TextFrame {}
{ "pile_set_name": "Github" }
with AWS.Config; with AWS.Response; with AWS.Services.Dispatchers.URI; with AWS.Status; package @[email protected] is use AWS; procedure Initialize (Web_Config : in Config.Object); -- Initialize state in this package depending on the HTTP configuration. -- For example it sets the web root for all dispatchers. All resources -- (templates, images, CSS file...) will be searched under this root -- directory. ------------- -- Default -- ------------- type Default is new Services.Dispatchers.URI.Handler with private; -- Handle everything not covered by the other dispatchers (CSS, Image) overriding function Dispatch (Dispatcher : in Default; Request : in Status.Data) return Response.Data; --------- -- CSS -- --------- type CSS is new Services.Dispatchers.URI.Handler with private; overriding function Dispatch (Dispatcher : in CSS; Request : in Status.Data) return Response.Data; ----------- -- Image -- ----------- type Image is new Services.Dispatchers.URI.Handler with private; overriding function Dispatch (Dispatcher : in Image; Request : in Status.Data) return Response.Data; private type Default is new Services.Dispatchers.URI.Handler with null record; type CSS is new Services.Dispatchers.URI.Handler with null record; type Image is new Services.Dispatchers.URI.Handler with null record; end @[email protected];
{ "pile_set_name": "Github" }
{% if not nav_item.children %} <li {% if nav_item.active %}class="active"{% endif %}> <a href="{{ nav_item.url }}">{{ nav_item.title }}</a> </li> {% else %} {% if nav_item.title == "Spells" or nav_item.title == "Monsters" or nav_item.title == "Magic items" %} {% else %} <li class="dropdown-submenu"> <a tabindex="-1" href="">{{ nav_item.title }}</a> <ul class="dropdown-menu"> {% for nav_item in nav_item.children %} {% include "nav-sub.html" %} {% endfor %} </ul> </li> {% endif %} {% endif %}
{ "pile_set_name": "Github" }
//===-- llvm-dis.cpp - The low-level LLVM disassembler --------------------===// // // The LLVM Compiler Infrastructure // // This file is distributed under the University of Illinois Open Source // License. See LICENSE.TXT for details. // //===----------------------------------------------------------------------===// // // This utility may be invoked in the following manner: // llvm-dis [options] - Read LLVM bitcode from stdin, write asm to stdout // llvm-dis [options] x.bc - Read LLVM bitcode from the x.bc file, write asm // to the x.ll file. // Options: // --help - Output information about command line switches // //===----------------------------------------------------------------------===// #include "llvm/IR/LLVMContext.h" #include "llvm/Bitcode/BitcodeReader.h" #include "llvm/IR/AssemblyAnnotationWriter.h" #include "llvm/IR/DebugInfo.h" #include "llvm/IR/DiagnosticInfo.h" #include "llvm/IR/DiagnosticPrinter.h" #include "llvm/IR/IntrinsicInst.h" #include "llvm/IR/Module.h" #include "llvm/IR/Type.h" #include "llvm/Support/CommandLine.h" #include "llvm/Support/Error.h" #include "llvm/Support/FileSystem.h" #include "llvm/Support/FormattedStream.h" #include "llvm/Support/ManagedStatic.h" #include "llvm/Support/MemoryBuffer.h" #include "llvm/Support/PrettyStackTrace.h" #include "llvm/Support/Signals.h" #include "llvm/Support/ToolOutputFile.h" #include <system_error> using namespace llvm; static cl::opt<std::string> InputFilename(cl::Positional, cl::desc("<input bitcode>"), cl::init("-")); static cl::opt<std::string> OutputFilename("o", cl::desc("Override output filename"), cl::value_desc("filename")); static cl::opt<bool> Force("f", cl::desc("Enable binary output on terminals")); static cl::opt<bool> DontPrint("disable-output", cl::desc("Don't output the .ll file"), cl::Hidden); static cl::opt<bool> ShowAnnotations("show-annotations", cl::desc("Add informational comments to the .ll file")); static cl::opt<bool> PreserveAssemblyUseListOrder( "preserve-ll-uselistorder", cl::desc("Preserve use-list order when writing LLVM assembly."), cl::init(false), cl::Hidden); static cl::opt<bool> MaterializeMetadata("materialize-metadata", cl::desc("Load module without materializing metadata, " "then materialize only the metadata")); namespace { static void printDebugLoc(const DebugLoc &DL, formatted_raw_ostream &OS) { OS << DL.getLine() << ":" << DL.getCol(); if (DILocation *IDL = DL.getInlinedAt()) { OS << "@"; printDebugLoc(IDL, OS); } } class CommentWriter : public AssemblyAnnotationWriter { public: void emitFunctionAnnot(const Function *F, formatted_raw_ostream &OS) override { OS << "; [#uses=" << F->getNumUses() << ']'; // Output # uses OS << '\n'; } void printInfoComment(const Value &V, formatted_raw_ostream &OS) override { bool Padded = false; if (!V.getType()->isVoidTy()) { OS.PadToColumn(50); Padded = true; // Output # uses and type OS << "; [#uses=" << V.getNumUses() << " type=" << *V.getType() << "]"; } if (const Instruction *I = dyn_cast<Instruction>(&V)) { if (const DebugLoc &DL = I->getDebugLoc()) { if (!Padded) { OS.PadToColumn(50); Padded = true; OS << ";"; } OS << " [debug line = "; printDebugLoc(DL,OS); OS << "]"; } if (const DbgDeclareInst *DDI = dyn_cast<DbgDeclareInst>(I)) { if (!Padded) { OS.PadToColumn(50); OS << ";"; } OS << " [debug variable = " << DDI->getVariable()->getName() << "]"; } else if (const DbgValueInst *DVI = dyn_cast<DbgValueInst>(I)) { if (!Padded) { OS.PadToColumn(50); OS << ";"; } OS << " [debug variable = " << DVI->getVariable()->getName() << "]"; } } } }; } // end anon namespace static void diagnosticHandler(const DiagnosticInfo &DI, void *Context) { raw_ostream &OS = errs(); OS << (char *)Context << ": "; switch (DI.getSeverity()) { case DS_Error: OS << "error: "; break; case DS_Warning: OS << "warning: "; break; case DS_Remark: OS << "remark: "; break; case DS_Note: OS << "note: "; break; } DiagnosticPrinterRawOStream DP(OS); DI.print(DP); OS << '\n'; if (DI.getSeverity() == DS_Error) exit(1); } static ExitOnError ExitOnErr; static std::unique_ptr<Module> openInputFile(LLVMContext &Context) { std::unique_ptr<MemoryBuffer> MB = ExitOnErr(errorOrToExpected(MemoryBuffer::getFileOrSTDIN(InputFilename))); std::unique_ptr<Module> M = ExitOnErr(getOwningLazyBitcodeModule(std::move(MB), Context, /*ShouldLazyLoadMetadata=*/true)); if (MaterializeMetadata) ExitOnErr(M->materializeMetadata()); else ExitOnErr(M->materializeAll()); return M; } int main(int argc, char **argv) { // Print a stack trace if we signal out. sys::PrintStackTraceOnErrorSignal(argv[0]); PrettyStackTraceProgram X(argc, argv); ExitOnErr.setBanner(std::string(argv[0]) + ": error: "); LLVMContext Context; llvm_shutdown_obj Y; // Call llvm_shutdown() on exit. Context.setDiagnosticHandler(diagnosticHandler, argv[0]); cl::ParseCommandLineOptions(argc, argv, "llvm .bc -> .ll disassembler\n"); std::unique_ptr<Module> M = openInputFile(Context); // Just use stdout. We won't actually print anything on it. if (DontPrint) OutputFilename = "-"; if (OutputFilename.empty()) { // Unspecified output, infer it. if (InputFilename == "-") { OutputFilename = "-"; } else { StringRef IFN = InputFilename; OutputFilename = (IFN.endswith(".bc") ? IFN.drop_back(3) : IFN).str(); OutputFilename += ".ll"; } } std::error_code EC; std::unique_ptr<tool_output_file> Out( new tool_output_file(OutputFilename, EC, sys::fs::F_None)); if (EC) { errs() << EC.message() << '\n'; return 1; } std::unique_ptr<AssemblyAnnotationWriter> Annotator; if (ShowAnnotations) Annotator.reset(new CommentWriter()); // All that llvm-dis does is write the assembly to a file. if (!DontPrint) M->print(Out->os(), Annotator.get(), PreserveAssemblyUseListOrder); // Declare success. Out->keep(); return 0; }
{ "pile_set_name": "Github" }
<?xml version='1.0' encoding='utf-8'?> <section xmlns="https://code.dccouncil.us/schemas/dc-library" xmlns:codified="https://code.dccouncil.us/schemas/codified" xmlns:codify="https://code.dccouncil.us/schemas/codify" xmlns:xi="http://www.w3.org/2001/XInclude" containing-doc="D.C. Code"> <num>16-4502</num> <reason>Repealed</reason> <heading>Definitions.</heading> <text>Repealed.</text> <annotations> <annotation doc="D.C. Law 4-200" type="History">Mar. 10, 1983, D.C. Law 4-200, § 2, 30 DCR 125</annotation> <annotation doc="D.C. Law 5-159" type="History">Mar. 14, 1985, D.C. Law 5-159, § 2, 32 DCR 30</annotation> <annotation doc="D.C. Law 13-293" type="History">Apr. 27, 2001, D.C. Law 13-293, § 2(c) 48 DCR 2214</annotation> <annotation type="Editor's Notes">Uniform Law: This section is based upon §  2 of the Uniform Child Custody Jurisdiction Act.</annotation> <annotation type="Prior Codifications">1981 Ed., § 16-4502.</annotation> </annotations> </section>
{ "pile_set_name": "Github" }
# SOME DESCRIPTIVE TITLE. # Copyright (C) YEAR Red Hat, Inc. # This file is distributed under the same license as the PACKAGE package. # # Translators: # Guido Grazioli <[email protected]>, 2011 # Milo Casagrande <[email protected]>, 2019. #zanata msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: [email protected]\n" "POT-Creation-Date: 2020-07-24 13:05+0200\n" "PO-Revision-Date: 2019-03-06 08:57-0500\n" "Last-Translator: Milo Casagrande <[email protected]>\n" "Language-Team: Italian (http://www.transifex.com/projects/p/sssd/language/" "it/)\n" "Language: it\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" "X-Generator: Zanata 4.6.2\n" #: src/config/SSSDConfig/sssdoptions.py:20 #: src/config/SSSDConfig/sssdoptions.py:21 msgid "Set the verbosity of the debug logging" msgstr "Imposta il livello di dettaglio dei messaggi di debug" #: src/config/SSSDConfig/sssdoptions.py:22 msgid "Include timestamps in debug logs" msgstr "Include marcatura temporale nei messaggi di registro" #: src/config/SSSDConfig/sssdoptions.py:23 msgid "Include microseconds in timestamps in debug logs" msgstr "Include i microsecondi nella marcatura temporale per il debug" #: src/config/SSSDConfig/sssdoptions.py:24 msgid "Write debug messages to logfiles" msgstr "Scrive i messaggi di debug nei file di registro" #: src/config/SSSDConfig/sssdoptions.py:25 msgid "Watchdog timeout before restarting service" msgstr "Timeout di controllo prima di riavviare il servizio" #: src/config/SSSDConfig/sssdoptions.py:26 msgid "Command to start service" msgstr "Comando per avviare il servizio" #: src/config/SSSDConfig/sssdoptions.py:27 msgid "Number of times to attempt connection to Data Providers" msgstr "Numero di tentativi di connessione ai provider dati" #: src/config/SSSDConfig/sssdoptions.py:28 msgid "The number of file descriptors that may be opened by this responder" msgstr "" "Il numero di descrittori file che possono essere aperti da questo responder" #: src/config/SSSDConfig/sssdoptions.py:29 #, fuzzy msgid "Idle time before automatic disconnection of a client" msgstr "" "Tempo di attesa prima di interrompere automaticamente una connessione client" #: src/config/SSSDConfig/sssdoptions.py:30 #, fuzzy msgid "Idle time before automatic shutdown of the responder" msgstr "Tempo di attesa prima di chiudere automaticamente il responder" #: src/config/SSSDConfig/sssdoptions.py:31 msgid "Always query all the caches before querying the Data Providers" msgstr "Interrogare tutte le cache prima dei provider dati" #: src/config/SSSDConfig/sssdoptions.py:32 msgid "" "When SSSD switches to offline mode the amount of time before it tries to go " "back online will increase based upon the time spent disconnected. This value " "is in seconds and calculated by the following: offline_timeout + " "random_offset." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:38 msgid "" "Indicates what is the syntax of the config file. SSSD 0.6.0 and later use " "version 2." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:39 msgid "SSSD Services to start" msgstr "Servizi SSD da avviare" #: src/config/SSSDConfig/sssdoptions.py:40 msgid "SSSD Domains to start" msgstr "Domini SSD da avviare" #: src/config/SSSDConfig/sssdoptions.py:41 msgid "Timeout for messages sent over the SBUS" msgstr "Timeout dei messaggi inviati tramite SBUS" #: src/config/SSSDConfig/sssdoptions.py:42 msgid "Regex to parse username and domain" msgstr "Espressione regolare per leggere nome utente e dominio" #: src/config/SSSDConfig/sssdoptions.py:43 msgid "Printf-compatible format for displaying fully-qualified names" msgstr "Formato compatibile con printf per la visualizzazione di nomi completi" #: src/config/SSSDConfig/sssdoptions.py:44 msgid "" "Directory on the filesystem where SSSD should store Kerberos replay cache " "files." msgstr "Directory dove salvare file di cache delle risposte Kerberos" #: src/config/SSSDConfig/sssdoptions.py:45 msgid "Domain to add to names without a domain component." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:46 msgid "The user to drop privileges to" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:47 msgid "Tune certificate verification" msgstr "Regola il controllo del certificato" #: src/config/SSSDConfig/sssdoptions.py:48 msgid "All spaces in group or user names will be replaced with this character" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:49 msgid "Tune sssd to honor or ignore netlink state changes" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:50 msgid "Enable or disable the implicit files domain" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:51 msgid "A specific order of the domains to be looked up" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:52 msgid "" "Controls if SSSD should monitor the state of resolv.conf to identify when it " "needs to update its internal DNS resolver." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:54 msgid "" "SSSD monitors the state of resolv.conf to identify when it needs to update " "its internal DNS resolver. By default, we will attempt to use inotify for " "this, and will fall back to polling resolv.conf every five seconds if " "inotify cannot be used." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:59 msgid "Enumeration cache timeout length (seconds)" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:60 msgid "Entry cache background update timeout length (seconds)" msgstr "Durata timeout aggiornamento cache in background (secondi)" #: src/config/SSSDConfig/sssdoptions.py:61 #: src/config/SSSDConfig/sssdoptions.py:115 msgid "Negative cache timeout length (seconds)" msgstr "Durata timeout negative cache (secondi)" #: src/config/SSSDConfig/sssdoptions.py:62 msgid "Files negative cache timeout length (seconds)" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:63 msgid "Users that SSSD should explicitly ignore" msgstr "Utenti che SSSD dovrebbe ignorare esplicitamente" #: src/config/SSSDConfig/sssdoptions.py:64 msgid "Groups that SSSD should explicitly ignore" msgstr "Gruppi che SSSD dovrebbe ignorare esplicitamente" #: src/config/SSSDConfig/sssdoptions.py:65 msgid "Should filtered users appear in groups" msgstr "Indica se mostrare gli utenti filtrati nei gruppi" #: src/config/SSSDConfig/sssdoptions.py:66 msgid "The value of the password field the NSS provider should return" msgstr "" "Il valore del campo password che deve essere ritornato dal provider NSS" #: src/config/SSSDConfig/sssdoptions.py:67 msgid "Override homedir value from the identity provider with this value" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:68 msgid "" "Substitute empty homedir value from the identity provider with this value" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:69 msgid "Override shell value from the identity provider with this value" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:70 msgid "The list of shells users are allowed to log in with" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:71 msgid "" "The list of shells that will be vetoed, and replaced with the fallback shell" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:72 msgid "" "If a shell stored in central directory is allowed but not available, use " "this fallback" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:73 msgid "Shell to use if the provider does not list one" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:74 msgid "How long will be in-memory cache records valid" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:75 msgid "" "Size (in megabytes) of the data table allocated inside fast in-memory cache " "for passwd requests" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:76 msgid "" "Size (in megabytes) of the data table allocated inside fast in-memory cache " "for group requests" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:77 msgid "" "Size (in megabytes) of the data table allocated inside fast in-memory cache " "for initgroups requests" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:78 msgid "" "The value of this option will be used in the expansion of the " "override_homedir option if the template contains the format string %H." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:80 msgid "" "Specifies time in seconds for which the list of subdomains will be " "considered valid." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:82 msgid "" "The entry cache can be set to automatically update entries in the background " "if they are requested beyond a percentage of the entry_cache_timeout value " "for the domain." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:87 msgid "How long to allow cached logins between online logins (days)" msgstr "Per quanto tempo accettare login in cache tra login online (giorni)" #: src/config/SSSDConfig/sssdoptions.py:88 msgid "How many failed logins attempts are allowed when offline" msgstr "Numero di tentativi di login falliti quando offline" #: src/config/SSSDConfig/sssdoptions.py:90 msgid "" "How long (minutes) to deny login after offline_failed_login_attempts has " "been reached" msgstr "" "Per quanto tempo (minuti) negare i tentativi di login dopo che " "offline_failed_login_attemps è stato raggiunto" #: src/config/SSSDConfig/sssdoptions.py:91 msgid "What kind of messages are displayed to the user during authentication" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:92 msgid "Filter PAM responses sent to the pam_sss" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:93 msgid "How many seconds to keep identity information cached for PAM requests" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:94 msgid "How many days before password expiration a warning should be displayed" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:95 msgid "List of trusted uids or user's name" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:96 msgid "List of domains accessible even for untrusted users." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:97 msgid "Message printed when user account is expired." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:98 msgid "Message printed when user account is locked." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:99 msgid "Allow certificate based/Smartcard authentication." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:100 msgid "Path to certificate database with PKCS#11 modules." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:101 msgid "How many seconds will pam_sss wait for p11_child to finish" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:102 msgid "Which PAM services are permitted to contact application domains" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:103 msgid "Allowed services for using smartcards" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:104 msgid "Additional timeout to wait for a card if requested" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:105 msgid "" "PKCS#11 URI to restrict the selection of devices for Smartcard authentication" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:106 msgid "When shall the PAM responder force an initgroups request" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:109 msgid "Whether to evaluate the time-based attributes in sudo rules" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:110 msgid "If true, SSSD will switch back to lower-wins ordering logic" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:111 msgid "" "Maximum number of rules that can be refreshed at once. If this is exceeded, " "full refresh is performed." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:118 msgid "Whether to hash host names and addresses in the known_hosts file" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:119 msgid "" "How many seconds to keep a host in the known_hosts file after its host keys " "were requested" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:121 msgid "Path to storage of trusted CA certificates" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:122 msgid "Allow to generate ssh-keys from certificates" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:123 msgid "" "Use the following matching rules to filter the certificates for ssh-key " "generation" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:127 msgid "List of UIDs or user names allowed to access the PAC responder" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:128 msgid "How long the PAC data is considered valid" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:131 msgid "List of user attributes the InfoPipe is allowed to publish" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:134 msgid "The provider where the secrets will be stored in" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:135 msgid "The maximum allowed number of nested containers" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:136 msgid "The maximum number of secrets that can be stored" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:137 msgid "The maximum number of secrets that can be stored per UID" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:138 msgid "The maximum payload size of a secret in kilobytes" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:140 msgid "The URL Custodia server is listening on" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:141 msgid "The method to use when authenticating to a Custodia server" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:142 msgid "" "The name of the headers that will be added into a HTTP request with the " "value defined in auth_header_value" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:144 msgid "The value sssd-secrets would use for auth_header_name" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:145 msgid "" "The list of the headers to forward to the Custodia server together with the " "request" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:146 msgid "" "The username to use when authenticating to a Custodia server using basic_auth" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:147 msgid "" "The password to use when authenticating to a Custodia server using basic_auth" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:148 msgid "If true peer's certificate is verified if proxy_url uses https protocol" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:149 msgid "" "If false peer's certificate may contain different hostname than proxy_url " "when https protocol is used" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:151 msgid "Path to directory where certificate authority certificates are stored" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:152 msgid "Path to file containing server's CA certificate" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:153 msgid "Path to file containing client's certificate" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:154 msgid "Path to file containing client's private key" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:157 msgid "" "One of the following strings specifying the scope of session recording: none " "- No users are recorded. some - Users/groups specified by users and groups " "options are recorded. all - All users are recorded." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:160 msgid "" "A comma-separated list of users which should have session recording enabled. " "Matches user names as returned by NSS. I.e. after the possible space " "replacement, case changes, etc." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:162 msgid "" "A comma-separated list of groups, members of which should have session " "recording enabled. Matches group names as returned by NSS. I.e. after the " "possible space replacement, case changes, etc." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:167 msgid "Identity provider" msgstr "Provider di identità" #: src/config/SSSDConfig/sssdoptions.py:168 msgid "Authentication provider" msgstr "Provider di autenticazione" #: src/config/SSSDConfig/sssdoptions.py:169 msgid "Access control provider" msgstr "Provider di access control" #: src/config/SSSDConfig/sssdoptions.py:170 msgid "Password change provider" msgstr "Provider di cambio password" #: src/config/SSSDConfig/sssdoptions.py:171 msgid "SUDO provider" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:172 msgid "Autofs provider" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:173 msgid "Host identity provider" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:174 msgid "SELinux provider" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:175 msgid "Session management provider" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:176 msgid "Resolver provider" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:179 msgid "Whether the domain is usable by the OS or by applications" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:180 #, fuzzy msgid "Enable or disable the domain" msgstr "Abilita la validazione delle credenziali" #: src/config/SSSDConfig/sssdoptions.py:181 msgid "Minimum user ID" msgstr "ID utente minimo" #: src/config/SSSDConfig/sssdoptions.py:182 msgid "Maximum user ID" msgstr "ID utente massimo" #: src/config/SSSDConfig/sssdoptions.py:183 msgid "Enable enumerating all users/groups" msgstr "Consentire l'enumerazione di tutti gli utenti/gruppi" #: src/config/SSSDConfig/sssdoptions.py:184 msgid "Cache credentials for offline login" msgstr "Salvare in cache le credenziali per login offline" #: src/config/SSSDConfig/sssdoptions.py:185 msgid "Display users/groups in fully-qualified form" msgstr "Mostrare utenti/gruppi in formato fully-qualified" #: src/config/SSSDConfig/sssdoptions.py:186 msgid "Don't include group members in group lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:187 #: src/config/SSSDConfig/sssdoptions.py:197 #: src/config/SSSDConfig/sssdoptions.py:198 #: src/config/SSSDConfig/sssdoptions.py:199 #: src/config/SSSDConfig/sssdoptions.py:200 #: src/config/SSSDConfig/sssdoptions.py:201 #: src/config/SSSDConfig/sssdoptions.py:202 #: src/config/SSSDConfig/sssdoptions.py:203 msgid "Entry cache timeout length (seconds)" msgstr "Durata timeout elementi in cache (secondi)" #: src/config/SSSDConfig/sssdoptions.py:188 msgid "" "Restrict or prefer a specific address family when performing DNS lookups" msgstr "" "Restringere o preferire una specifica famiglia di indirizzi per l'esecuzione " "di lookup DNS" #: src/config/SSSDConfig/sssdoptions.py:189 msgid "How long to keep cached entries after last successful login (days)" msgstr "" "Per quanto tempo tenere in cache gli elementi dopo un login che ha avuto " "successo (giorni)" #: src/config/SSSDConfig/sssdoptions.py:190 msgid "" "How long should SSSD talk to single DNS server before trying next server " "(miliseconds)" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:192 msgid "How long should keep trying to resolve single DNS query (seconds)" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:193 msgid "How long to wait for replies from DNS when resolving servers (seconds)" msgstr "Il tempo di attesa per le richieste DNS (secondi)" #: src/config/SSSDConfig/sssdoptions.py:194 msgid "The domain part of service discovery DNS query" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:195 msgid "Override GID value from the identity provider with this value" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:196 msgid "Treat usernames as case sensitive" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:204 msgid "How often should expired entries be refreshed in background" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:205 msgid "Whether to automatically update the client's DNS entry" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:206 #: src/config/SSSDConfig/sssdoptions.py:236 msgid "The TTL to apply to the client's DNS entry after updating it" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:207 #: src/config/SSSDConfig/sssdoptions.py:237 msgid "The interface whose IP should be used for dynamic DNS updates" msgstr "" "L'interfaccia il cui indirizzo IP dovrebbe essere usato per aggiornamenti " "DNS dinamici." #: src/config/SSSDConfig/sssdoptions.py:208 msgid "How often to periodically update the client's DNS entry" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:209 msgid "Whether the provider should explicitly update the PTR record as well" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:210 msgid "Whether the nsupdate utility should default to using TCP" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:211 msgid "What kind of authentication should be used to perform the DNS update" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:212 msgid "Override the DNS server used to perform the DNS update" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:213 msgid "Control enumeration of trusted domains" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:214 msgid "How often should subdomains list be refreshed" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:215 msgid "List of options that should be inherited into a subdomain" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:216 msgid "Default subdomain homedir value" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:217 msgid "How long can cached credentials be used for cached authentication" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:218 msgid "Whether to automatically create private groups for users" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:219 msgid "Display a warning N days before the password expires." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:220 msgid "" "Various tags stored by the realmd configuration service for this domain." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:221 msgid "" "The provider which should handle fetching of subdomains. This value should " "be always the same as id_provider." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:223 msgid "" "How many seconds to keep a host ssh key after refresh. IE how long to cache " "the host key for." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:225 msgid "" "If 2-Factor-Authentication (2FA) is used and credentials should be saved " "this value determines the minimal length the first authentication factor " "(long term password) must have to be saved as SHA512 hash into the cache." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:231 msgid "IPA domain" msgstr "Dominio IPA" #: src/config/SSSDConfig/sssdoptions.py:232 msgid "IPA server address" msgstr "Indirizzo del server IPA" #: src/config/SSSDConfig/sssdoptions.py:233 msgid "Address of backup IPA server" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:234 msgid "IPA client hostname" msgstr "Hostname del client IPA" #: src/config/SSSDConfig/sssdoptions.py:235 msgid "Whether to automatically update the client's DNS entry in FreeIPA" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:238 msgid "Search base for HBAC related objects" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:239 msgid "" "The amount of time between lookups of the HBAC rules against the IPA server" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:240 msgid "" "The amount of time in seconds between lookups of the SELinux maps against " "the IPA server" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:242 msgid "If set to false, host argument given by PAM will be ignored" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:243 msgid "The automounter location this IPA client is using" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:244 msgid "Search base for object containing info about IPA domain" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:245 msgid "Search base for objects containing info about ID ranges" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:246 #: src/config/SSSDConfig/sssdoptions.py:300 msgid "Enable DNS sites - location based service discovery" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:247 msgid "Search base for view containers" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:248 msgid "Objectclass for view containers" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:249 msgid "Attribute with the name of the view" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:250 msgid "Objectclass for override objects" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:251 msgid "Attribute with the reference to the original object" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:252 msgid "Objectclass for user override objects" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:253 msgid "Objectclass for group override objects" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:254 msgid "Search base for Desktop Profile related objects" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:255 msgid "" "The amount of time in seconds between lookups of the Desktop Profile rules " "against the IPA server" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:257 msgid "" "The amount of time in minutes between lookups of Desktop Profiles rules " "against the IPA server when the last request did not find any rule" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:260 msgid "The LDAP attribute that contains FQDN of the host." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:261 #: src/config/SSSDConfig/sssdoptions.py:284 msgid "The object class of a host entry in LDAP." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:262 msgid "Use the given string as search base for host objects." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:263 msgid "The LDAP attribute that contains the host's SSH public keys." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:264 msgid "The LDAP attribute that contains NIS domain name of the netgroup." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:265 msgid "The LDAP attribute that contains the names of the netgroup's members." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:266 msgid "" "The LDAP attribute that lists FQDNs of hosts and host groups that are " "members of the netgroup." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:268 msgid "" "The LDAP attribute that lists hosts and host groups that are direct members " "of the netgroup." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:270 msgid "The LDAP attribute that lists netgroup's memberships." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:271 msgid "" "The LDAP attribute that lists system users and groups that are direct " "members of the netgroup." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:273 msgid "The LDAP attribute that corresponds to the netgroup name." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:274 msgid "The object class of a netgroup entry in LDAP." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:275 msgid "" "The LDAP attribute that contains the UUID/GUID of an LDAP netgroup object." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:276 msgid "" "The LDAP attribute that contains whether or not is user map enabled for " "usage." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:278 msgid "The LDAP attribute that contains host category such as 'all'." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:279 msgid "" "The LDAP attribute that contains all hosts / hostgroups this rule match " "against." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:281 msgid "" "The LDAP attribute that contains all users / groups this rule match against." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:283 msgid "The LDAP attribute that contains the name of SELinux usermap." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:285 msgid "" "The LDAP attribute that contains DN of HBAC rule which can be used for " "matching instead of memberUser and memberHost." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:287 msgid "The LDAP attribute that contains SELinux user string itself." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:288 msgid "The LDAP attribute that contains user category such as 'all'." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:289 msgid "The LDAP attribute that contains unique ID of the user map." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:290 msgid "" "The option denotes that the SSSD is running on IPA server and should perform " "lookups of users and groups from trusted domains differently." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:292 msgid "Use the given string as search base for trusted domains." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:295 msgid "Active Directory domain" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:296 msgid "Enabled Active Directory domains" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:297 msgid "Active Directory server address" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:298 msgid "Active Directory backup server address" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:299 msgid "Active Directory client hostname" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:301 #: src/config/SSSDConfig/sssdoptions.py:492 msgid "LDAP filter to determine access privileges" msgstr "Filtro LDAP per determinare i privilegi di accesso" #: src/config/SSSDConfig/sssdoptions.py:302 msgid "Whether to use the Global Catalog for lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:303 msgid "Operation mode for GPO-based access control" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:304 msgid "" "The amount of time between lookups of the GPO policy files against the AD " "server" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:305 msgid "" "PAM service names that map to the GPO (Deny)InteractiveLogonRight policy " "settings" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:307 msgid "" "PAM service names that map to the GPO (Deny)RemoteInteractiveLogonRight " "policy settings" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:309 msgid "" "PAM service names that map to the GPO (Deny)NetworkLogonRight policy settings" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:310 msgid "" "PAM service names that map to the GPO (Deny)BatchLogonRight policy settings" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:311 msgid "" "PAM service names that map to the GPO (Deny)ServiceLogonRight policy settings" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:312 msgid "PAM service names for which GPO-based access is always granted" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:313 msgid "PAM service names for which GPO-based access is always denied" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:314 msgid "" "Default logon right (or permit/deny) to use for unmapped PAM service names" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:315 msgid "a particular site to be used by the client" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:316 msgid "" "Maximum age in days before the machine account password should be renewed" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:318 msgid "Option for tuning the machine account renewal task" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:319 msgid "Whether to update the machine account password in the Samba database" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:321 msgid "Use LDAPS port for LDAP and Global Catalog requests" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:324 #: src/config/SSSDConfig/sssdoptions.py:325 msgid "Kerberos server address" msgstr "Indirizzo del server Kerberos" #: src/config/SSSDConfig/sssdoptions.py:326 msgid "Kerberos backup server address" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:327 msgid "Kerberos realm" msgstr "Realm Kerberos" #: src/config/SSSDConfig/sssdoptions.py:328 msgid "Authentication timeout" msgstr "Timeout di autenticazione" #: src/config/SSSDConfig/sssdoptions.py:329 msgid "Whether to create kdcinfo files" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:330 msgid "Where to drop krb5 config snippets" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:333 msgid "Directory to store credential caches" msgstr "Directory in cui salvare le credenziali" #: src/config/SSSDConfig/sssdoptions.py:334 msgid "Location of the user's credential cache" msgstr "Percorso della cache delle credenziali utente" #: src/config/SSSDConfig/sssdoptions.py:335 msgid "Location of the keytab to validate credentials" msgstr "Percorso del keytab per la validazione delle credenziali" #: src/config/SSSDConfig/sssdoptions.py:336 msgid "Enable credential validation" msgstr "Abilita la validazione delle credenziali" #: src/config/SSSDConfig/sssdoptions.py:337 msgid "Store password if offline for later online authentication" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:338 msgid "Renewable lifetime of the TGT" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:339 msgid "Lifetime of the TGT" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:340 msgid "Time between two checks for renewal" msgstr "Intervallo di tempo tra due controlli di rinnovo" #: src/config/SSSDConfig/sssdoptions.py:341 msgid "Enables FAST" msgstr "Abilita FAST" #: src/config/SSSDConfig/sssdoptions.py:342 msgid "Selects the principal to use for FAST" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:343 msgid "Enables principal canonicalization" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:344 msgid "Enables enterprise principals" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:345 msgid "A mapping from user names to Kerberos principal names" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:348 #: src/config/SSSDConfig/sssdoptions.py:349 msgid "Server where the change password service is running if not on the KDC" msgstr "" "Server dove viene eseguito il servizio di cambio password, se non nel KDC" #: src/config/SSSDConfig/sssdoptions.py:352 msgid "ldap_uri, The URI of the LDAP server" msgstr "ldap_uri, l'indirizzo del server LDAP" #: src/config/SSSDConfig/sssdoptions.py:353 msgid "ldap_backup_uri, The URI of the LDAP server" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:354 msgid "The default base DN" msgstr "Il base DN predefinito" #: src/config/SSSDConfig/sssdoptions.py:355 msgid "The Schema Type in use on the LDAP server, rfc2307" msgstr "Lo Schema Type utilizzato dal server LDAP, rfc2307" #: src/config/SSSDConfig/sssdoptions.py:356 msgid "Mode used to change user password" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:357 msgid "The default bind DN" msgstr "Il bind DN predefinito" #: src/config/SSSDConfig/sssdoptions.py:358 msgid "The type of the authentication token of the default bind DN" msgstr "Il tipo di token di autenticazione del bind DN predefinito" #: src/config/SSSDConfig/sssdoptions.py:359 msgid "The authentication token of the default bind DN" msgstr "Il token di autenticazione del bind DN predefinito" #: src/config/SSSDConfig/sssdoptions.py:360 msgid "Length of time to attempt connection" msgstr "Durata del tentativo di connessione" #: src/config/SSSDConfig/sssdoptions.py:361 msgid "Length of time to attempt synchronous LDAP operations" msgstr "Durata del tentativo di esecuzione di operazioni LDAP sincrone" #: src/config/SSSDConfig/sssdoptions.py:362 msgid "Length of time between attempts to reconnect while offline" msgstr "Durata tra tentativi di riconnessione quando offline" #: src/config/SSSDConfig/sssdoptions.py:363 msgid "Use only the upper case for realm names" msgstr "Usare solo maiuscole per i nomi dei realm" #: src/config/SSSDConfig/sssdoptions.py:364 msgid "File that contains CA certificates" msgstr "File contenente i certificati CA" #: src/config/SSSDConfig/sssdoptions.py:365 msgid "Path to CA certificate directory" msgstr "Percorso della directory dei cerficati della CA" #: src/config/SSSDConfig/sssdoptions.py:366 msgid "File that contains the client certificate" msgstr "File contenente il certificato client" #: src/config/SSSDConfig/sssdoptions.py:367 msgid "File that contains the client key" msgstr "File contenente la chiave client" #: src/config/SSSDConfig/sssdoptions.py:368 msgid "List of possible ciphers suites" msgstr "Lista delle possibili cipher suite" #: src/config/SSSDConfig/sssdoptions.py:369 msgid "Require TLS certificate verification" msgstr "Richiedere la verifica del certificato TLS" #: src/config/SSSDConfig/sssdoptions.py:370 msgid "Specify the sasl mechanism to use" msgstr "Specificare il meccanismo sasl da usare" #: src/config/SSSDConfig/sssdoptions.py:371 msgid "Specify the sasl authorization id to use" msgstr "Specificare l'id di autorizzazione sasl da usare" #: src/config/SSSDConfig/sssdoptions.py:372 msgid "Specify the sasl authorization realm to use" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:373 msgid "Specify the minimal SSF for LDAP sasl authorization" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:374 msgid "Specify the maximal SSF for LDAP sasl authorization" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:375 msgid "Kerberos service keytab" msgstr "Keytab del servizio Kerberos" #: src/config/SSSDConfig/sssdoptions.py:376 msgid "Use Kerberos auth for LDAP connection" msgstr "Usare autorizzazione Kerberos per la connessione LDAP" #: src/config/SSSDConfig/sssdoptions.py:377 msgid "Follow LDAP referrals" msgstr "Seguire i referral LDAP" #: src/config/SSSDConfig/sssdoptions.py:378 msgid "Lifetime of TGT for LDAP connection" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:379 msgid "How to dereference aliases" msgstr "Metodo di deferenziazione degli alias" #: src/config/SSSDConfig/sssdoptions.py:380 msgid "Service name for DNS service lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:381 msgid "The number of records to retrieve in a single LDAP query" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:382 msgid "The number of members that must be missing to trigger a full deref" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:383 msgid "" "Whether the LDAP library should perform a reverse lookup to canonicalize the " "host name during a SASL bind" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:385 msgid "" "Allows to retain local users as members of an LDAP group for servers that " "use the RFC2307 schema." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:388 msgid "entryUSN attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:389 msgid "lastUSN attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:391 msgid "How long to retain a connection to the LDAP server before disconnecting" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:394 msgid "Disable the LDAP paging control" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:395 msgid "Disable Active Directory range retrieval" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:398 msgid "Length of time to wait for a search request" msgstr "Durata attesa per le richieste di ricerca" #: src/config/SSSDConfig/sssdoptions.py:399 msgid "Length of time to wait for a enumeration request" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:400 msgid "Length of time between enumeration updates" msgstr "Durata tra gli aggiornamenti alle enumeration" #: src/config/SSSDConfig/sssdoptions.py:401 msgid "Length of time between cache cleanups" msgstr "Intervallo di tempo per la pulizia cache" #: src/config/SSSDConfig/sssdoptions.py:402 msgid "Require TLS for ID lookups" msgstr "Richiedere TLS per gli ID lookup" #: src/config/SSSDConfig/sssdoptions.py:403 msgid "Use ID-mapping of objectSID instead of pre-set IDs" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:404 msgid "Base DN for user lookups" msgstr "Base DN per i lookup utente" #: src/config/SSSDConfig/sssdoptions.py:405 msgid "Scope of user lookups" msgstr "Ambito di applicazione dei lookup utente" #: src/config/SSSDConfig/sssdoptions.py:406 msgid "Filter for user lookups" msgstr "Filtro per i lookup utente" #: src/config/SSSDConfig/sssdoptions.py:407 msgid "Objectclass for users" msgstr "Objectclass per gli utenti" #: src/config/SSSDConfig/sssdoptions.py:408 msgid "Username attribute" msgstr "Attributo del nome utente" #: src/config/SSSDConfig/sssdoptions.py:409 msgid "UID attribute" msgstr "Attributo UID" #: src/config/SSSDConfig/sssdoptions.py:410 msgid "Primary GID attribute" msgstr "Attributo del GID primario" #: src/config/SSSDConfig/sssdoptions.py:411 msgid "GECOS attribute" msgstr "Attributo GECOS" #: src/config/SSSDConfig/sssdoptions.py:412 msgid "Home directory attribute" msgstr "Attributo della home directory" #: src/config/SSSDConfig/sssdoptions.py:413 msgid "Shell attribute" msgstr "Attributo della shell" #: src/config/SSSDConfig/sssdoptions.py:414 msgid "UUID attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:415 #: src/config/SSSDConfig/sssdoptions.py:453 msgid "objectSID attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:416 msgid "Active Directory primary group attribute for ID-mapping" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:417 msgid "User principal attribute (for Kerberos)" msgstr "Attributo user principal (per Kerberos)" #: src/config/SSSDConfig/sssdoptions.py:418 msgid "Full Name" msgstr "Nome completo" #: src/config/SSSDConfig/sssdoptions.py:419 msgid "memberOf attribute" msgstr "Attributo memberOf" #: src/config/SSSDConfig/sssdoptions.py:420 msgid "Modification time attribute" msgstr "Attributo data di modifica" #: src/config/SSSDConfig/sssdoptions.py:421 msgid "shadowLastChange attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:422 msgid "shadowMin attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:423 msgid "shadowMax attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:424 msgid "shadowWarning attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:425 msgid "shadowInactive attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:426 msgid "shadowExpire attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:427 msgid "shadowFlag attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:428 msgid "Attribute listing authorized PAM services" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:429 msgid "Attribute listing authorized server hosts" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:430 msgid "Attribute listing authorized server rhosts" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:431 msgid "krbLastPwdChange attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:432 msgid "krbPasswordExpiration attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:433 msgid "Attribute indicating that server side password policies are active" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:434 msgid "accountExpires attribute of AD" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:435 msgid "userAccountControl attribute of AD" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:436 msgid "nsAccountLock attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:437 msgid "loginDisabled attribute of NDS" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:438 msgid "loginExpirationTime attribute of NDS" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:439 msgid "loginAllowedTimeMap attribute of NDS" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:440 msgid "SSH public key attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:441 msgid "attribute listing allowed authentication types for a user" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:442 msgid "attribute containing the X509 certificate of the user" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:443 msgid "attribute containing the email address of the user" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:444 msgid "A list of extra attributes to download along with the user entry" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:446 msgid "Base DN for group lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:447 msgid "Objectclass for groups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:448 msgid "Group name" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:449 msgid "Group password" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:450 msgid "GID attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:451 msgid "Group member attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:452 msgid "Group UUID attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:454 msgid "Modification time attribute for groups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:455 msgid "Type of the group and other flags" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:456 msgid "The LDAP group external member attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:457 msgid "Maximum nesting level SSSD will follow" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:458 msgid "Filter for group lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:459 msgid "Scope of group lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:461 msgid "Base DN for netgroup lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:462 msgid "Objectclass for netgroups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:463 msgid "Netgroup name" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:464 msgid "Netgroups members attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:465 msgid "Netgroup triple attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:466 msgid "Modification time attribute for netgroups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:468 msgid "Base DN for service lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:469 msgid "Objectclass for services" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:470 msgid "Service name attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:471 msgid "Service port attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:472 msgid "Service protocol attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:474 msgid "Lower bound for ID-mapping" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:475 msgid "Upper bound for ID-mapping" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:476 msgid "Number of IDs for each slice when ID-mapping" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:477 msgid "Use autorid-compatible algorithm for ID-mapping" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:478 msgid "Name of the default domain for ID-mapping" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:479 msgid "SID of the default domain for ID-mapping" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:480 msgid "Number of secondary slices" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:482 msgid "Whether to use Token-Groups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:483 msgid "Set lower boundary for allowed IDs from the LDAP server" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:484 msgid "Set upper boundary for allowed IDs from the LDAP server" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:485 msgid "DN for ppolicy queries" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:486 msgid "How many maximum entries to fetch during a wildcard request" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:489 msgid "Policy to evaluate the password expiration" msgstr "Politica per controllare la scadenza della password" #: src/config/SSSDConfig/sssdoptions.py:493 msgid "Which attributes shall be used to evaluate if an account is expired" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:494 msgid "Which rules should be used to evaluate access control" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:497 msgid "URI of an LDAP server where password changes are allowed" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:498 msgid "URI of a backup LDAP server where password changes are allowed" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:499 msgid "DNS service name for LDAP password change server" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:500 msgid "" "Whether to update the ldap_user_shadow_last_change attribute after a " "password change" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:504 msgid "Base DN for sudo rules lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:505 msgid "Automatic full refresh period" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:506 msgid "Automatic smart refresh period" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:507 msgid "Whether to filter rules by hostname, IP addresses and network" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:508 msgid "" "Hostnames and/or fully qualified domain names of this machine to filter sudo " "rules" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:509 msgid "IPv4 or IPv6 addresses or network of this machine to filter sudo rules" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:510 msgid "Whether to include rules that contains netgroup in host attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:511 msgid "" "Whether to include rules that contains regular expression in host attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:512 msgid "Object class for sudo rules" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:513 msgid "Name of attribute that is used as object class for sudo rules" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:514 msgid "Sudo rule name" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:515 msgid "Sudo rule command attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:516 msgid "Sudo rule host attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:517 msgid "Sudo rule user attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:518 msgid "Sudo rule option attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:519 msgid "Sudo rule runas attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:520 msgid "Sudo rule runasuser attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:521 msgid "Sudo rule runasgroup attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:522 msgid "Sudo rule notbefore attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:523 msgid "Sudo rule notafter attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:524 msgid "Sudo rule order attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:527 msgid "Object class for automounter maps" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:528 msgid "Automounter map name attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:529 msgid "Object class for automounter map entries" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:530 msgid "Automounter map entry key attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:531 msgid "Automounter map entry value attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:532 msgid "Base DN for automounter map lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:533 msgid "The name of the automount master map in LDAP." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:536 msgid "Base DN for IP hosts lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:537 msgid "Object class for IP hosts" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:538 msgid "IP host name attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:539 msgid "IP host number (address) attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:540 msgid "IP host entryUSN attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:541 msgid "Base DN for IP networks lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:542 msgid "Object class for IP networks" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:543 msgid "IP network name attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:544 msgid "IP network number (address) attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:545 msgid "IP network entryUSN attribute" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:548 msgid "Comma separated list of allowed users" msgstr "Lista separata da virgola degli utenti abilitati" #: src/config/SSSDConfig/sssdoptions.py:549 msgid "Comma separated list of prohibited users" msgstr "Lista separata da virgola degli utenti non abilitati" #: src/config/SSSDConfig/sssdoptions.py:550 msgid "" "Comma separated list of groups that are allowed to log in. This applies only " "to groups within this SSSD domain. Local groups are not evaluated." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:552 msgid "" "Comma separated list of groups that are explicitly denied access. This " "applies only to groups within this SSSD domain. Local groups are not " "evaluated." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:556 msgid "Base for home directories" msgstr "Base delle home directory" #: src/config/SSSDConfig/sssdoptions.py:557 msgid "Indicate if a home directory should be created for new users." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:558 msgid "Indicate if a home directory should be removed for deleted users." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:559 msgid "Specify the default permissions on a newly created home directory." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:560 msgid "The skeleton directory." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:561 msgid "The mail spool directory." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:562 msgid "The command that is run after a user is removed." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:565 msgid "The number of preforked proxy children." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:568 msgid "The name of the NSS library to use" msgstr "Il nome della libreria NSS da usare" #: src/config/SSSDConfig/sssdoptions.py:569 msgid "The name of the NSS library to use for hosts and networks lookups" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:570 msgid "Whether to look up canonical group name from cache if possible" msgstr "" #: src/config/SSSDConfig/sssdoptions.py:573 msgid "PAM stack to use" msgstr "Stack PAM da usare" #: src/config/SSSDConfig/sssdoptions.py:576 msgid "Path of passwd file sources." msgstr "" #: src/config/SSSDConfig/sssdoptions.py:577 msgid "Path of group file sources." msgstr "" #: src/monitor/monitor.c:2375 msgid "Become a daemon (default)" msgstr "Esegui come demone (default)" #: src/monitor/monitor.c:2377 msgid "Run interactive (not a daemon)" msgstr "Esegui interattivamente (non come demone)" #: src/monitor/monitor.c:2380 msgid "Disable netlink interface" msgstr "" #: src/monitor/monitor.c:2382 src/tools/sssctl/sssctl_config.c:77 #: src/tools/sssctl/sssctl_logs.c:310 msgid "Specify a non-default config file" msgstr "Specificare un file di configurazione specifico" #: src/monitor/monitor.c:2384 msgid "Refresh the configuration database, then exit" msgstr "" #: src/monitor/monitor.c:2387 msgid "Similar to --genconf, but only refreshes the given section" msgstr "" #: src/monitor/monitor.c:2390 msgid "Print version number and exit" msgstr "" #: src/monitor/monitor.c:2536 msgid "SSSD is already running\n" msgstr "" #: src/providers/krb5/krb5_child.c:3233 src/providers/ldap/ldap_child.c:638 msgid "Debug level" msgstr "Livello debug" #: src/providers/krb5/krb5_child.c:3235 src/providers/ldap/ldap_child.c:640 msgid "Add debug timestamps" msgstr "Includi timestamp di debug" #: src/providers/krb5/krb5_child.c:3237 src/providers/ldap/ldap_child.c:642 msgid "Show timestamps with microseconds" msgstr "" #: src/providers/krb5/krb5_child.c:3239 src/providers/ldap/ldap_child.c:644 msgid "An open file descriptor for the debug logs" msgstr "Un descrittore di file aperto per l'output di debug" #: src/providers/krb5/krb5_child.c:3242 src/providers/ldap/ldap_child.c:646 msgid "Send the debug output to stderr directly." msgstr "" #: src/providers/krb5/krb5_child.c:3245 msgid "The user to create FAST ccache as" msgstr "" #: src/providers/krb5/krb5_child.c:3247 msgid "The group to create FAST ccache as" msgstr "" #: src/providers/krb5/krb5_child.c:3249 msgid "Kerberos realm to use" msgstr "" #: src/providers/krb5/krb5_child.c:3251 msgid "Requested lifetime of the ticket" msgstr "" #: src/providers/krb5/krb5_child.c:3253 msgid "Requested renewable lifetime of the ticket" msgstr "" #: src/providers/krb5/krb5_child.c:3255 msgid "FAST options ('never', 'try', 'demand')" msgstr "" #: src/providers/krb5/krb5_child.c:3258 msgid "Specifies the server principal to use for FAST" msgstr "" #: src/providers/krb5/krb5_child.c:3260 msgid "Requests canonicalization of the principal name" msgstr "" #: src/providers/krb5/krb5_child.c:3262 msgid "Use custom version of krb5_get_init_creds_password" msgstr "" #: src/providers/data_provider_be.c:674 msgid "Domain of the information provider (mandatory)" msgstr "Dominio del provider di informazioni (obbligatorio)" #: src/sss_client/common.c:1079 msgid "Privileged socket has wrong ownership or permissions." msgstr "Il socket privilegiato ha permessi o propritario non validi." #: src/sss_client/common.c:1082 msgid "Public socket has wrong ownership or permissions." msgstr "Il socket pubblico ha permessi o propritario non validi." #: src/sss_client/common.c:1085 msgid "Unexpected format of the server credential message." msgstr "" #: src/sss_client/common.c:1088 msgid "SSSD is not run by root." msgstr "SSSD non è eseguito da root." #: src/sss_client/common.c:1091 msgid "SSSD socket does not exist." msgstr "" #: src/sss_client/common.c:1094 msgid "Cannot get stat of SSSD socket." msgstr "" #: src/sss_client/common.c:1099 msgid "An error occurred, but no description can be found." msgstr "" #: src/sss_client/common.c:1105 msgid "Unexpected error while looking for an error description" msgstr "" #: src/sss_client/pam_sss.c:68 msgid "Permission denied. " msgstr "" #: src/sss_client/pam_sss.c:69 src/sss_client/pam_sss.c:781 #: src/sss_client/pam_sss.c:792 msgid "Server message: " msgstr "Messaggio del server:" #: src/sss_client/pam_sss.c:299 msgid "Passwords do not match" msgstr "Le password non coincidono" #: src/sss_client/pam_sss.c:487 msgid "Password reset by root is not supported." msgstr "" #: src/sss_client/pam_sss.c:528 msgid "Authenticated with cached credentials" msgstr "Autenticato con le credenziali nella cache" #: src/sss_client/pam_sss.c:529 msgid ", your cached password will expire at: " msgstr ", la password in cache scadrà il: " #: src/sss_client/pam_sss.c:559 #, c-format msgid "Your password has expired. You have %1$d grace login(s) remaining." msgstr "" #: src/sss_client/pam_sss.c:605 #, c-format msgid "Your password will expire in %1$d %2$s." msgstr "" #: src/sss_client/pam_sss.c:654 msgid "Authentication is denied until: " msgstr "L'autenticazione verrà negata fino al: " #: src/sss_client/pam_sss.c:675 msgid "System is offline, password change not possible" msgstr "Il sistema è offline, non è possibile richiedere un cambio password" #: src/sss_client/pam_sss.c:690 msgid "" "After changing the OTP password, you need to log out and back in order to " "acquire a ticket" msgstr "" #: src/sss_client/pam_sss.c:778 src/sss_client/pam_sss.c:791 msgid "Password change failed. " msgstr "Cambio password fallito." #: src/sss_client/pam_sss.c:2015 msgid "New Password: " msgstr "Nuova password: " #: src/sss_client/pam_sss.c:2016 msgid "Reenter new Password: " msgstr "Conferma nuova password: " #: src/sss_client/pam_sss.c:2178 src/sss_client/pam_sss.c:2181 msgid "First Factor: " msgstr "" #: src/sss_client/pam_sss.c:2179 src/sss_client/pam_sss.c:2353 msgid "Second Factor (optional): " msgstr "" #: src/sss_client/pam_sss.c:2182 src/sss_client/pam_sss.c:2356 msgid "Second Factor: " msgstr "" #: src/sss_client/pam_sss.c:2200 msgid "Password: " msgstr "Password: " #: src/sss_client/pam_sss.c:2352 src/sss_client/pam_sss.c:2355 msgid "First Factor (Current Password): " msgstr "" #: src/sss_client/pam_sss.c:2359 msgid "Current Password: " msgstr "Password corrente: " #: src/sss_client/pam_sss.c:2716 msgid "Password expired. Change your password now." msgstr "Password scaduta. Cambiare la password ora." #: src/sss_client/ssh/sss_ssh_authorizedkeys.c:41 #: src/sss_client/ssh/sss_ssh_knownhostsproxy.c:186 src/tools/sss_useradd.c:48 #: src/tools/sss_groupadd.c:41 src/tools/sss_groupdel.c:44 #: src/tools/sss_groupmod.c:42 src/tools/sss_groupshow.c:668 #: src/tools/sss_userdel.c:136 src/tools/sss_usermod.c:47 #: src/tools/sss_cache.c:719 msgid "The debug level to run with" msgstr "Il livello di debug da utilizzare" #: src/sss_client/ssh/sss_ssh_authorizedkeys.c:43 #: src/sss_client/ssh/sss_ssh_knownhostsproxy.c:190 msgid "The SSSD domain to use" msgstr "" #: src/sss_client/ssh/sss_ssh_authorizedkeys.c:57 src/tools/sss_useradd.c:74 #: src/tools/sss_groupadd.c:59 src/tools/sss_groupdel.c:54 #: src/tools/sss_groupmod.c:66 src/tools/sss_groupshow.c:680 #: src/tools/sss_userdel.c:154 src/tools/sss_usermod.c:79 #: src/tools/sss_cache.c:765 msgid "Error setting the locale\n" msgstr "Errore di impostazione del locale\n" #: src/sss_client/ssh/sss_ssh_authorizedkeys.c:64 msgid "Not enough memory\n" msgstr "" #: src/sss_client/ssh/sss_ssh_authorizedkeys.c:83 msgid "User not specified\n" msgstr "" #: src/sss_client/ssh/sss_ssh_authorizedkeys.c:97 msgid "Error looking up public keys\n" msgstr "" #: src/sss_client/ssh/sss_ssh_knownhostsproxy.c:188 msgid "The port to use to connect to the host" msgstr "" #: src/sss_client/ssh/sss_ssh_knownhostsproxy.c:192 msgid "Print the host ssh public keys" msgstr "" #: src/sss_client/ssh/sss_ssh_knownhostsproxy.c:234 msgid "Invalid port\n" msgstr "" #: src/sss_client/ssh/sss_ssh_knownhostsproxy.c:239 msgid "Host not specified\n" msgstr "" #: src/sss_client/ssh/sss_ssh_knownhostsproxy.c:245 msgid "The path to the proxy command must be absolute\n" msgstr "" #: src/sss_client/ssh/sss_ssh_knownhostsproxy.c:326 #, c-format msgid "sss_ssh_knownhostsproxy: unable to proxy data: %s\n" msgstr "" #: src/sss_client/ssh/sss_ssh_knownhostsproxy.c:330 #, c-format msgid "sss_ssh_knownhostsproxy: connect to host %s port %d: %s\n" msgstr "" #: src/sss_client/ssh/sss_ssh_knownhostsproxy.c:334 #, c-format msgid "sss_ssh_knownhostsproxy: Could not resolve hostname %s\n" msgstr "" #: src/tools/sss_useradd.c:49 src/tools/sss_usermod.c:48 msgid "The UID of the user" msgstr "L'UID dell'utente" #: src/tools/sss_useradd.c:50 src/tools/sss_usermod.c:50 msgid "The comment string" msgstr "La stringa di commento" #: src/tools/sss_useradd.c:51 src/tools/sss_usermod.c:51 msgid "Home directory" msgstr "Home directory" #: src/tools/sss_useradd.c:52 src/tools/sss_usermod.c:52 msgid "Login shell" msgstr "Shell di login" #: src/tools/sss_useradd.c:53 msgid "Groups" msgstr "Gruppi" #: src/tools/sss_useradd.c:54 msgid "Create user's directory if it does not exist" msgstr "Creare la directory utente se non esiste" #: src/tools/sss_useradd.c:55 msgid "Never create user's directory, overrides config" msgstr "Non creare mai le directory utente, forza la configurazione" #: src/tools/sss_useradd.c:56 msgid "Specify an alternative skeleton directory" msgstr "Specificare una directory skeleton alternativa" #: src/tools/sss_useradd.c:57 src/tools/sss_usermod.c:60 msgid "The SELinux user for user's login" msgstr "" #: src/tools/sss_useradd.c:87 src/tools/sss_groupmod.c:79 #: src/tools/sss_usermod.c:92 msgid "Specify group to add to\n" msgstr "" #: src/tools/sss_useradd.c:111 msgid "Specify user to add\n" msgstr "Specificare un utente da aggiungere\n" #: src/tools/sss_useradd.c:121 src/tools/sss_groupadd.c:86 #: src/tools/sss_groupdel.c:80 src/tools/sss_groupmod.c:113 #: src/tools/sss_groupshow.c:714 src/tools/sss_userdel.c:200 #: src/tools/sss_usermod.c:162 msgid "Error initializing the tools - no local domain\n" msgstr "Errore durante l'inizializzazione degli strumenti - nessun dominio\n" #: src/tools/sss_useradd.c:123 src/tools/sss_groupadd.c:88 #: src/tools/sss_groupdel.c:82 src/tools/sss_groupmod.c:115 #: src/tools/sss_groupshow.c:716 src/tools/sss_userdel.c:202 #: src/tools/sss_usermod.c:164 msgid "Error initializing the tools\n" msgstr "Errore durante l'inizializzazione degli strumenti\n" #: src/tools/sss_useradd.c:132 src/tools/sss_groupadd.c:97 #: src/tools/sss_groupdel.c:91 src/tools/sss_groupmod.c:123 #: src/tools/sss_groupshow.c:725 src/tools/sss_userdel.c:211 #: src/tools/sss_usermod.c:173 msgid "Invalid domain specified in FQDN\n" msgstr "Il dominio specificato nel FQDN non è valido\n" #: src/tools/sss_useradd.c:142 src/tools/sss_groupmod.c:144 #: src/tools/sss_groupmod.c:173 src/tools/sss_usermod.c:197 #: src/tools/sss_usermod.c:226 msgid "Internal error while parsing parameters\n" msgstr "Errore interno nel parsing dei parametri\n" #: src/tools/sss_useradd.c:151 src/tools/sss_usermod.c:206 #: src/tools/sss_usermod.c:235 msgid "Groups must be in the same domain as user\n" msgstr "I gruppi devono essere nello stesso dominio dell'utente\n" #: src/tools/sss_useradd.c:159 #, c-format msgid "Cannot find group %1$s in local domain\n" msgstr "" #: src/tools/sss_useradd.c:174 src/tools/sss_userdel.c:221 msgid "Cannot set default values\n" msgstr "Impossibile impostare i valori predefiniti\n" #: src/tools/sss_useradd.c:181 src/tools/sss_usermod.c:187 msgid "The selected UID is outside the allowed range\n" msgstr "L'UID specificato non rientra nel range permesso\n" #: src/tools/sss_useradd.c:210 src/tools/sss_usermod.c:305 msgid "Cannot set SELinux login context\n" msgstr "" #: src/tools/sss_useradd.c:224 msgid "Cannot get info about the user\n" msgstr "Impossibile determinare le informazioni dell'utente\n" #: src/tools/sss_useradd.c:236 msgid "User's home directory already exists, not copying data from skeldir\n" msgstr "" "La directory home dell'utente esiste, non vengono copiati dati dalla " "directory skeleton\n" #: src/tools/sss_useradd.c:239 #, c-format msgid "Cannot create user's home directory: %1$s\n" msgstr "" #: src/tools/sss_useradd.c:250 #, c-format msgid "Cannot create user's mail spool: %1$s\n" msgstr "" #: src/tools/sss_useradd.c:270 msgid "Could not allocate ID for the user - domain full?\n" msgstr "Impossibile allocare l'ID utente - dominio pieno?\n" #: src/tools/sss_useradd.c:274 msgid "A user or group with the same name or ID already exists\n" msgstr "Utente o gruppo con lo stesso nome o ID già presente\n" #: src/tools/sss_useradd.c:280 msgid "Transaction error. Could not add user.\n" msgstr "Errore nella transazione. L'utente non è stato aggiunto.\n" #: src/tools/sss_groupadd.c:43 src/tools/sss_groupmod.c:48 msgid "The GID of the group" msgstr "Il GID del gruppo" #: src/tools/sss_groupadd.c:76 msgid "Specify group to add\n" msgstr "Specificare un gruppo da aggiungere\n" #: src/tools/sss_groupadd.c:106 src/tools/sss_groupmod.c:198 msgid "The selected GID is outside the allowed range\n" msgstr "Il GID specificato non è nel range permesso\n" #: src/tools/sss_groupadd.c:143 msgid "Could not allocate ID for the group - domain full?\n" msgstr "Impossibile allocare l'ID per il gruppo - dominio pieno?\n" #: src/tools/sss_groupadd.c:147 msgid "A group with the same name or GID already exists\n" msgstr "Gruppo con lo stesso nome o GID già esistente\n" #: src/tools/sss_groupadd.c:153 msgid "Transaction error. Could not add group.\n" msgstr "Errore della transazione. Impossibile aggiungere il gruppo.\n" #: src/tools/sss_groupdel.c:70 msgid "Specify group to delete\n" msgstr "Specificare il gruppo da eliminare\n" #: src/tools/sss_groupdel.c:104 #, c-format msgid "Group %1$s is outside the defined ID range for domain\n" msgstr "" #: src/tools/sss_groupdel.c:119 src/tools/sss_groupmod.c:225 #: src/tools/sss_groupmod.c:232 src/tools/sss_groupmod.c:239 #: src/tools/sss_userdel.c:297 src/tools/sss_usermod.c:282 #: src/tools/sss_usermod.c:289 src/tools/sss_usermod.c:296 #, c-format msgid "NSS request failed (%1$d). Entry might remain in memory cache.\n" msgstr "" #: src/tools/sss_groupdel.c:132 msgid "" "No such group in local domain. Removing groups only allowed in local " "domain.\n" msgstr "" "Gruppo non presente nel dominio locale. L'eliminazione di gruppi è permessa " "solo nel dominio locale.\n" #: src/tools/sss_groupdel.c:137 msgid "Internal error. Could not remove group.\n" msgstr "Errore interno. Impossibile rimuovere il gruppo.\n" #: src/tools/sss_groupmod.c:44 msgid "Groups to add this group to" msgstr "Gruppi a cui aggiungere questo gruppo" #: src/tools/sss_groupmod.c:46 msgid "Groups to remove this group from" msgstr "Gruppi da cui eliminare questo gruppo" #: src/tools/sss_groupmod.c:87 src/tools/sss_usermod.c:100 msgid "Specify group to remove from\n" msgstr "" #: src/tools/sss_groupmod.c:101 msgid "Specify group to modify\n" msgstr "Specificare il gruppo da modificare\n" #: src/tools/sss_groupmod.c:130 msgid "" "Cannot find group in local domain, modifying groups is allowed only in local " "domain\n" msgstr "" "Gruppo non presente nel dominio locale. La modifica dei gruppi è permessa " "solo nel dominio locale.\n" #: src/tools/sss_groupmod.c:153 src/tools/sss_groupmod.c:182 msgid "Member groups must be in the same domain as parent group\n" msgstr "" "I gruppi membri devono appartenere allo stesso dominio del gruppo radice\n" #: src/tools/sss_groupmod.c:161 src/tools/sss_groupmod.c:190 #: src/tools/sss_usermod.c:214 src/tools/sss_usermod.c:243 #, c-format msgid "" "Cannot find group %1$s in local domain, only groups in local domain are " "allowed\n" msgstr "" #: src/tools/sss_groupmod.c:257 msgid "Could not modify group - check if member group names are correct\n" msgstr "" "Impossibile modificare il gruppo - controllare che i nomi dei gruppi siano " "corretti\n" #: src/tools/sss_groupmod.c:261 msgid "Could not modify group - check if groupname is correct\n" msgstr "" "Impossibile modificare il gruppo - controllare che il nome del gruppo sia " "corretto\n" #: src/tools/sss_groupmod.c:265 msgid "Transaction error. Could not modify group.\n" msgstr "Errore della transazione. Impossibile modificare il gruppo.\n" #: src/tools/sss_groupshow.c:616 msgid "Magic Private " msgstr "Magic Private " #: src/tools/sss_groupshow.c:615 #, c-format msgid "%1$s%2$sGroup: %3$s\n" msgstr "" #: src/tools/sss_groupshow.c:618 #, c-format msgid "%1$sGID number: %2$d\n" msgstr "" #: src/tools/sss_groupshow.c:620 #, c-format msgid "%1$sMember users: " msgstr "" #: src/tools/sss_groupshow.c:627 #, c-format msgid "" "\n" "%1$sIs a member of: " msgstr "" #: src/tools/sss_groupshow.c:634 #, c-format msgid "" "\n" "%1$sMember groups: " msgstr "" #: src/tools/sss_groupshow.c:670 msgid "Print indirect group members recursively" msgstr "Mostra ricorsivamente i membri indiretti del gruppo" #: src/tools/sss_groupshow.c:704 msgid "Specify group to show\n" msgstr "Specificare il gruppo da mostrate\n" #: src/tools/sss_groupshow.c:744 msgid "" "No such group in local domain. Printing groups only allowed in local " "domain.\n" msgstr "" "Gruppo non presente nel dominio locale. La stampa dei gruppi è permessa solo " "nel dominio locale.\n" #: src/tools/sss_groupshow.c:749 msgid "Internal error. Could not print group.\n" msgstr "Errore interno. Impossibile stampare il gruppo.\n" #: src/tools/sss_userdel.c:138 msgid "Remove home directory and mail spool" msgstr "Eliminare home directory e spool di mail" #: src/tools/sss_userdel.c:140 msgid "Do not remove home directory and mail spool" msgstr "Non eliminare la home directory e lo spool di mail" #: src/tools/sss_userdel.c:142 msgid "Force removal of files not owned by the user" msgstr "Forza la rimozione dei file non di proprietà dell'utente" #: src/tools/sss_userdel.c:144 msgid "Kill users' processes before removing him" msgstr "" #: src/tools/sss_userdel.c:190 msgid "Specify user to delete\n" msgstr "Specificare l'utente da cancellare\n" #: src/tools/sss_userdel.c:236 #, c-format msgid "User %1$s is outside the defined ID range for domain\n" msgstr "" #: src/tools/sss_userdel.c:261 msgid "Cannot reset SELinux login context\n" msgstr "" #: src/tools/sss_userdel.c:273 #, c-format msgid "WARNING: The user (uid %1$lu) was still logged in when deleted.\n" msgstr "" #: src/tools/sss_userdel.c:278 msgid "Cannot determine if the user was logged in on this platform" msgstr "" #: src/tools/sss_userdel.c:283 msgid "Error while checking if the user was logged in\n" msgstr "" #: src/tools/sss_userdel.c:290 #, c-format msgid "The post-delete command failed: %1$s\n" msgstr "" #: src/tools/sss_userdel.c:310 msgid "Not removing home dir - not owned by user\n" msgstr "Home directory non eliminata - non appartiene all'utente\n" #: src/tools/sss_userdel.c:312 #, c-format msgid "Cannot remove homedir: %1$s\n" msgstr "" #: src/tools/sss_userdel.c:326 msgid "" "No such user in local domain. Removing users only allowed in local domain.\n" msgstr "" "Utente non presente nel dominio locale. L'eliminazione degli utenti è " "permessa solo nel dominio locale.\n" #: src/tools/sss_userdel.c:331 msgid "Internal error. Could not remove user.\n" msgstr "Errore interno. Impossibile rimuovere l'utente.\n" #: src/tools/sss_usermod.c:49 msgid "The GID of the user" msgstr "Il GID dell'utente" #: src/tools/sss_usermod.c:53 msgid "Groups to add this user to" msgstr "Gruppi a cui aggiungere questo utente" #: src/tools/sss_usermod.c:54 msgid "Groups to remove this user from" msgstr "Gruppi da cui rimuovere questo utente" #: src/tools/sss_usermod.c:55 msgid "Lock the account" msgstr "Bloccare l'account" #: src/tools/sss_usermod.c:56 msgid "Unlock the account" msgstr "Sbloccare l'account" #: src/tools/sss_usermod.c:57 msgid "Add an attribute/value pair. The format is attrname=value." msgstr "" #: src/tools/sss_usermod.c:58 msgid "Delete an attribute/value pair. The format is attrname=value." msgstr "" #: src/tools/sss_usermod.c:59 msgid "" "Set an attribute to a name/value pair. The format is attrname=value. For " "multi-valued attributes, the command replaces the values already present" msgstr "" #: src/tools/sss_usermod.c:117 src/tools/sss_usermod.c:126 #: src/tools/sss_usermod.c:135 msgid "Specify the attribute name/value pair(s)\n" msgstr "" #: src/tools/sss_usermod.c:152 msgid "Specify user to modify\n" msgstr "Specificare l'utente da modificare\n" #: src/tools/sss_usermod.c:180 msgid "" "Cannot find user in local domain, modifying users is allowed only in local " "domain\n" msgstr "" "Utente non presente nel dominio locale. La modifica degli utenti è permessa " "solo nel dominio locale.\n" #: src/tools/sss_usermod.c:322 msgid "Could not modify user - check if group names are correct\n" msgstr "" "Impossibile modificare l'utente - controllare che i nomi dei gruppi siano " "corretti\n" #: src/tools/sss_usermod.c:326 msgid "Could not modify user - user already member of groups?\n" msgstr "Impossibile modificare l'utente - utente già membro di gruppi?\n" #: src/tools/sss_usermod.c:330 msgid "Transaction error. Could not modify user.\n" msgstr "Errore nella transazione. Impossibile modificare l'utente.\n" #: src/tools/sss_cache.c:245 msgid "No cache object matched the specified search\n" msgstr "" #: src/tools/sss_cache.c:536 #, c-format msgid "Couldn't invalidate %1$s\n" msgstr "" #: src/tools/sss_cache.c:543 #, c-format msgid "Couldn't invalidate %1$s %2$s\n" msgstr "" #: src/tools/sss_cache.c:721 msgid "Invalidate all cached entries" msgstr "" #: src/tools/sss_cache.c:723 msgid "Invalidate particular user" msgstr "" #: src/tools/sss_cache.c:725 msgid "Invalidate all users" msgstr "" #: src/tools/sss_cache.c:727 msgid "Invalidate particular group" msgstr "" #: src/tools/sss_cache.c:729 msgid "Invalidate all groups" msgstr "" #: src/tools/sss_cache.c:731 msgid "Invalidate particular netgroup" msgstr "" #: src/tools/sss_cache.c:733 msgid "Invalidate all netgroups" msgstr "" #: src/tools/sss_cache.c:735 msgid "Invalidate particular service" msgstr "" #: src/tools/sss_cache.c:737 msgid "Invalidate all services" msgstr "" #: src/tools/sss_cache.c:740 msgid "Invalidate particular autofs map" msgstr "" #: src/tools/sss_cache.c:742 msgid "Invalidate all autofs maps" msgstr "" #: src/tools/sss_cache.c:746 msgid "Invalidate particular SSH host" msgstr "" #: src/tools/sss_cache.c:748 msgid "Invalidate all SSH hosts" msgstr "" #: src/tools/sss_cache.c:752 msgid "Invalidate particular sudo rule" msgstr "" #: src/tools/sss_cache.c:754 msgid "Invalidate all cached sudo rules" msgstr "" #: src/tools/sss_cache.c:757 msgid "Only invalidate entries from a particular domain" msgstr "" #: src/tools/sss_cache.c:811 msgid "" "Unexpected argument(s) provided, options that invalidate a single object " "only accept a single provided argument.\n" msgstr "" #: src/tools/sss_cache.c:821 msgid "Please select at least one object to invalidate\n" msgstr "" #: src/tools/sss_cache.c:904 #, c-format msgid "" "Could not open domain %1$s. If the domain is a subdomain (trusted domain), " "use fully qualified name instead of --domain/-d parameter.\n" msgstr "" #: src/tools/sss_cache.c:909 msgid "Could not open available domains\n" msgstr "" #: src/tools/tools_util.c:202 #, c-format msgid "Name '%1$s' does not seem to be FQDN ('%2$s = TRUE' is set)\n" msgstr "" #: src/tools/tools_util.c:309 msgid "Out of memory\n" msgstr "Memoria esaurita\n" #: src/tools/tools_util.h:40 #, c-format msgid "%1$s must be run as root\n" msgstr "" #: src/tools/sssctl/sssctl.c:35 msgid "yes" msgstr "" #: src/tools/sssctl/sssctl.c:37 msgid "no" msgstr "" #: src/tools/sssctl/sssctl.c:39 msgid "error" msgstr "" #: src/tools/sssctl/sssctl.c:42 msgid "Invalid result." msgstr "" #: src/tools/sssctl/sssctl.c:78 msgid "Unable to read user input\n" msgstr "" #: src/tools/sssctl/sssctl.c:91 #, c-format msgid "Invalid input, please provide either '%s' or '%s'.\n" msgstr "" #: src/tools/sssctl/sssctl.c:109 src/tools/sssctl/sssctl.c:114 msgid "Error while executing external command\n" msgstr "" #: src/tools/sssctl/sssctl.c:156 msgid "SSSD needs to be running. Start SSSD now?" msgstr "" #: src/tools/sssctl/sssctl.c:195 msgid "SSSD must not be running. Stop SSSD now?" msgstr "" #: src/tools/sssctl/sssctl.c:231 msgid "SSSD needs to be restarted. Restart SSSD now?" msgstr "" #: src/tools/sssctl/sssctl_cache.c:31 #, c-format msgid " %s is not present in cache.\n" msgstr "" #: src/tools/sssctl/sssctl_cache.c:33 msgid "Name" msgstr "" #: src/tools/sssctl/sssctl_cache.c:34 msgid "Cache entry creation date" msgstr "" #: src/tools/sssctl/sssctl_cache.c:35 msgid "Cache entry last update time" msgstr "" #: src/tools/sssctl/sssctl_cache.c:36 msgid "Cache entry expiration time" msgstr "" #: src/tools/sssctl/sssctl_cache.c:37 msgid "Cached in InfoPipe" msgstr "" #: src/tools/sssctl/sssctl_cache.c:522 #, c-format msgid "Error: Unable to get object [%d]: %s\n" msgstr "" #: src/tools/sssctl/sssctl_cache.c:538 #, c-format msgid "%s: Unable to read value [%d]: %s\n" msgstr "" #: src/tools/sssctl/sssctl_cache.c:566 msgid "Specify name." msgstr "" #: src/tools/sssctl/sssctl_cache.c:576 #, c-format msgid "Unable to parse name %s.\n" msgstr "" #: src/tools/sssctl/sssctl_cache.c:602 src/tools/sssctl/sssctl_cache.c:649 msgid "Search by SID" msgstr "" #: src/tools/sssctl/sssctl_cache.c:603 msgid "Search by user ID" msgstr "" #: src/tools/sssctl/sssctl_cache.c:612 msgid "Initgroups expiration time" msgstr "" #: src/tools/sssctl/sssctl_cache.c:650 msgid "Search by group ID" msgstr "" #: src/tools/sssctl/sssctl_config.c:79 msgid "" "Specify a non-default snippet dir (The default is to look in the same place " "where the main config file is located. For example if the config is set to " "\"/my/path/sssd.conf\", the snippet dir \"/my/path/conf.d\" is used)" msgstr "" #: src/tools/sssctl/sssctl_config.c:118 #, c-format msgid "Failed to open %s\n" msgstr "" #: src/tools/sssctl/sssctl_config.c:123 #, c-format msgid "File %1$s does not exist.\n" msgstr "" #: src/tools/sssctl/sssctl_config.c:127 msgid "" "File ownership and permissions check failed. Expected root:root and 0600.\n" msgstr "" #: src/tools/sssctl/sssctl_config.c:133 #, c-format msgid "Failed to load configuration from %s.\n" msgstr "" #: src/tools/sssctl/sssctl_config.c:139 msgid "Error while reading configuration directory.\n" msgstr "" #: src/tools/sssctl/sssctl_config.c:147 msgid "" "There is no configuration. SSSD will use default configuration with files " "provider.\n" msgstr "" #: src/tools/sssctl/sssctl_config.c:159 msgid "Failed to run validators" msgstr "" #: src/tools/sssctl/sssctl_config.c:163 #, c-format msgid "Issues identified by validators: %zu\n" msgstr "" #: src/tools/sssctl/sssctl_config.c:174 #, c-format msgid "Messages generated during configuration merging: %zu\n" msgstr "" #: src/tools/sssctl/sssctl_config.c:185 #, c-format msgid "Used configuration snippet files: %zu\n" msgstr "" #: src/tools/sssctl/sssctl_data.c:89 #, c-format msgid "Unable to create backup directory [%d]: %s" msgstr "" #: src/tools/sssctl/sssctl_data.c:95 msgid "SSSD backup of local data already exists, override?" msgstr "" #: src/tools/sssctl/sssctl_data.c:111 msgid "Unable to export user overrides\n" msgstr "" #: src/tools/sssctl/sssctl_data.c:118 msgid "Unable to export group overrides\n" msgstr "" #: src/tools/sssctl/sssctl_data.c:134 src/tools/sssctl/sssctl_data.c:217 msgid "Override existing backup" msgstr "" #: src/tools/sssctl/sssctl_data.c:164 msgid "Unable to import user overrides\n" msgstr "" #: src/tools/sssctl/sssctl_data.c:173 msgid "Unable to import group overrides\n" msgstr "" #: src/tools/sssctl/sssctl_data.c:194 src/tools/sssctl/sssctl_domains.c:82 #: src/tools/sssctl/sssctl_domains.c:328 msgid "Start SSSD if it is not running" msgstr "" #: src/tools/sssctl/sssctl_data.c:195 msgid "Restart SSSD after data import" msgstr "" #: src/tools/sssctl/sssctl_data.c:218 msgid "Create clean cache files and import local data" msgstr "" #: src/tools/sssctl/sssctl_data.c:219 msgid "Stop SSSD before removing the cache" msgstr "" #: src/tools/sssctl/sssctl_data.c:220 msgid "Start SSSD when the cache is removed" msgstr "" #: src/tools/sssctl/sssctl_data.c:235 msgid "Creating backup of local data...\n" msgstr "" #: src/tools/sssctl/sssctl_data.c:238 msgid "Unable to create backup of local data, can not remove the cache.\n" msgstr "" #: src/tools/sssctl/sssctl_data.c:243 msgid "Removing cache files...\n" msgstr "" #: src/tools/sssctl/sssctl_data.c:246 msgid "Unable to remove cache files\n" msgstr "" #: src/tools/sssctl/sssctl_data.c:251 msgid "Restoring local data...\n" msgstr "" #: src/tools/sssctl/sssctl_domains.c:83 msgid "Show domain list including primary or trusted domain type" msgstr "" #: src/tools/sssctl/sssctl_domains.c:105 src/tools/sssctl/sssctl_domains.c:367 #: src/tools/sssctl/sssctl_user_checks.c:95 msgid "Unable to connect to system bus!\n" msgstr "" #: src/tools/sssctl/sssctl_domains.c:167 msgid "Online" msgstr "" #: src/tools/sssctl/sssctl_domains.c:167 msgid "Offline" msgstr "" #: src/tools/sssctl/sssctl_domains.c:167 #, c-format msgid "Online status: %s\n" msgstr "" #: src/tools/sssctl/sssctl_domains.c:213 msgid "This domain has no active servers.\n" msgstr "" #: src/tools/sssctl/sssctl_domains.c:218 msgid "Active servers:\n" msgstr "" #: src/tools/sssctl/sssctl_domains.c:230 msgid "not connected" msgstr "" #: src/tools/sssctl/sssctl_domains.c:267 msgid "No servers discovered.\n" msgstr "" #: src/tools/sssctl/sssctl_domains.c:273 #, c-format msgid "Discovered %s servers:\n" msgstr "" #: src/tools/sssctl/sssctl_domains.c:285 msgid "None so far.\n" msgstr "" #: src/tools/sssctl/sssctl_domains.c:325 msgid "Show online status" msgstr "" #: src/tools/sssctl/sssctl_domains.c:326 msgid "Show information about active server" msgstr "" #: src/tools/sssctl/sssctl_domains.c:327 msgid "Show list of discovered servers" msgstr "" #: src/tools/sssctl/sssctl_domains.c:333 msgid "Specify domain name." msgstr "" #: src/tools/sssctl/sssctl_domains.c:355 msgid "Out of memory!\n" msgstr "" #: src/tools/sssctl/sssctl_domains.c:375 src/tools/sssctl/sssctl_domains.c:385 msgid "Unable to get online status\n" msgstr "" #: src/tools/sssctl/sssctl_domains.c:395 msgid "Unable to get server list\n" msgstr "" #: src/tools/sssctl/sssctl_logs.c:46 msgid "\n" msgstr "" #: src/tools/sssctl/sssctl_logs.c:236 msgid "Delete log files instead of truncating" msgstr "" #: src/tools/sssctl/sssctl_logs.c:247 msgid "Deleting log files...\n" msgstr "" #: src/tools/sssctl/sssctl_logs.c:250 msgid "Unable to remove log files\n" msgstr "" #: src/tools/sssctl/sssctl_logs.c:256 msgid "Truncating log files...\n" msgstr "" #: src/tools/sssctl/sssctl_logs.c:259 msgid "Unable to truncate log files\n" msgstr "" #: src/tools/sssctl/sssctl_logs.c:285 msgid "Out of memory!" msgstr "" #: src/tools/sssctl/sssctl_logs.c:288 #, c-format msgid "Archiving log files into %s...\n" msgstr "" #: src/tools/sssctl/sssctl_logs.c:291 msgid "Unable to archive log files\n" msgstr "" #: src/tools/sssctl/sssctl_logs.c:316 msgid "Specify debug level you want to set" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:117 msgid "SSSD InfoPipe user lookup result:\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:167 #, c-format msgid "dlopen failed with [%s].\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:174 #, c-format msgid "dlsym failed with [%s].\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:182 msgid "malloc failed.\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:189 #, c-format msgid "sss_getpwnam_r failed with [%d].\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:194 msgid "SSSD nss user lookup result:\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:195 #, c-format msgid " - user name: %s\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:196 #, c-format msgid " - user id: %d\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:197 #, c-format msgid " - group id: %d\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:198 #, c-format msgid " - gecos: %s\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:199 #, c-format msgid " - home directory: %s\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:200 #, c-format msgid "" " - shell: %s\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:232 msgid "PAM action [auth|acct|setc|chau|open|clos], default: " msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:235 msgid "PAM service, default: " msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:240 msgid "Specify user name." msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:247 #, c-format msgid "" "user: %s\n" "action: %s\n" "service: %s\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:252 #, c-format msgid "User name lookup with [%s] failed.\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:257 #, c-format msgid "InfoPipe User lookup with [%s] failed.\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:263 #, c-format msgid "pam_start failed: %s\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:268 msgid "" "testing pam_authenticate\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:272 #, c-format msgid "pam_get_item failed: %s\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:275 #, c-format msgid "" "pam_authenticate for user [%s]: %s\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:278 msgid "" "testing pam_chauthtok\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:280 #, c-format msgid "" "pam_chauthtok: %s\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:282 msgid "" "testing pam_acct_mgmt\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:284 #, c-format msgid "" "pam_acct_mgmt: %s\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:286 msgid "" "testing pam_setcred\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:288 #, c-format msgid "" "pam_setcred: [%s]\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:290 msgid "" "testing pam_open_session\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:292 #, c-format msgid "" "pam_open_session: %s\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:294 msgid "" "testing pam_close_session\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:296 #, c-format msgid "" "pam_close_session: %s\n" "\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:298 msgid "unknown action\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:301 msgid "PAM Environment:\n" msgstr "" #: src/tools/sssctl/sssctl_user_checks.c:309 msgid " - no env -\n" msgstr "" #: src/util/util.h:82 msgid "The user ID to run the server as" msgstr "" #: src/util/util.h:84 msgid "The group ID to run the server as" msgstr "" #: src/util/util.h:92 msgid "Informs that the responder has been socket-activated" msgstr "" #: src/util/util.h:94 msgid "Informs that the responder has been dbus-activated" msgstr ""
{ "pile_set_name": "Github" }
/* * PURPOSE: * Class representing an articulated rigid body. Stores the body's * current state, allows forces and torques to be set, handles * timestepping and implements Featherstone's algorithm. * * COPYRIGHT: * Copyright (C) Stephen Thompson, <[email protected]>, 2011-2013 * Portions written By Erwin Coumans: connection to LCP solver, various multibody constraints, replacing Eigen math library by Bullet LinearMath and a dedicated 6x6 matrix inverse (solveImatrix) * Portions written By Jakub Stepien: support for multi-DOF constraints, introduction of spatial algebra and several other improvements This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software. Permission is granted to anyone to use this software for any purpose, including commercial applications, and to alter it and redistribute it freely, subject to the following restrictions: 1. The origin of this software must not be misrepresented; you must not claim that you wrote the original software. If you use this software in a product, an acknowledgment in the product documentation would be appreciated but is not required. 2. Altered source versions must be plainly marked as such, and must not be misrepresented as being the original software. 3. This notice may not be removed or altered from any source distribution. */ #ifndef BT_MULTIBODY_H #define BT_MULTIBODY_H #include "LinearMath/btScalar.h" #include "LinearMath/btVector3.h" #include "LinearMath/btQuaternion.h" #include "LinearMath/btMatrix3x3.h" #include "LinearMath/btAlignedObjectArray.h" ///serialization data, don't change them if you are not familiar with the details of the serialization mechanisms #ifdef BT_USE_DOUBLE_PRECISION #define btMultiBodyData btMultiBodyDoubleData #define btMultiBodyDataName "btMultiBodyDoubleData" #define btMultiBodyLinkData btMultiBodyLinkDoubleData #define btMultiBodyLinkDataName "btMultiBodyLinkDoubleData" #else #define btMultiBodyData btMultiBodyFloatData #define btMultiBodyDataName "btMultiBodyFloatData" #define btMultiBodyLinkData btMultiBodyLinkFloatData #define btMultiBodyLinkDataName "btMultiBodyLinkFloatData" #endif //BT_USE_DOUBLE_PRECISION #include "btMultiBodyLink.h" class btMultiBodyLinkCollider; ATTRIBUTE_ALIGNED16(class) btMultiBody { public: BT_DECLARE_ALIGNED_ALLOCATOR(); // // initialization // btMultiBody(int n_links, // NOT including the base btScalar mass, // mass of base const btVector3 &inertia, // inertia of base, in base frame; assumed diagonal bool fixedBase, // whether the base is fixed (true) or can move (false) bool canSleep, bool deprecatedMultiDof=true); virtual ~btMultiBody(); //note: fixed link collision with parent is always disabled void setupFixed(int linkIndex, btScalar mass, const btVector3 &inertia, int parent, const btQuaternion &rotParentToThis, const btVector3 &parentComToThisPivotOffset, const btVector3 &thisPivotToThisComOffset, bool deprecatedDisableParentCollision=true); void setupPrismatic(int i, btScalar mass, const btVector3 &inertia, int parent, const btQuaternion &rotParentToThis, const btVector3 &jointAxis, const btVector3 &parentComToThisPivotOffset, const btVector3 &thisPivotToThisComOffset, bool disableParentCollision); void setupRevolute(int linkIndex, // 0 to num_links-1 btScalar mass, const btVector3 &inertia, int parentIndex, const btQuaternion &rotParentToThis, // rotate points in parent frame to this frame, when q = 0 const btVector3 &jointAxis, // in my frame const btVector3 &parentComToThisPivotOffset, // vector from parent COM to joint axis, in PARENT frame const btVector3 &thisPivotToThisComOffset, // vector from joint axis to my COM, in MY frame bool disableParentCollision=false); void setupSpherical(int linkIndex, // 0 to num_links-1 btScalar mass, const btVector3 &inertia, int parent, const btQuaternion &rotParentToThis, // rotate points in parent frame to this frame, when q = 0 const btVector3 &parentComToThisPivotOffset, // vector from parent COM to joint axis, in PARENT frame const btVector3 &thisPivotToThisComOffset, // vector from joint axis to my COM, in MY frame bool disableParentCollision=false); void setupPlanar(int i, // 0 to num_links-1 btScalar mass, const btVector3 &inertia, int parent, const btQuaternion &rotParentToThis, // rotate points in parent frame to this frame, when q = 0 const btVector3 &rotationAxis, const btVector3 &parentComToThisComOffset, // vector from parent COM to this COM, in PARENT frame bool disableParentCollision=false); const btMultibodyLink& getLink(int index) const { return m_links[index]; } btMultibodyLink& getLink(int index) { return m_links[index]; } void setBaseCollider(btMultiBodyLinkCollider* collider)//collider can be NULL to disable collision for the base { m_baseCollider = collider; } const btMultiBodyLinkCollider* getBaseCollider() const { return m_baseCollider; } btMultiBodyLinkCollider* getBaseCollider() { return m_baseCollider; } // // get parent // input: link num from 0 to num_links-1 // output: link num from 0 to num_links-1, OR -1 to mean the base. // int getParent(int link_num) const; // // get number of m_links, masses, moments of inertia // int getNumLinks() const { return m_links.size(); } int getNumDofs() const { return m_dofCount; } int getNumPosVars() const { return m_posVarCnt; } btScalar getBaseMass() const { return m_baseMass; } const btVector3 & getBaseInertia() const { return m_baseInertia; } btScalar getLinkMass(int i) const; const btVector3 & getLinkInertia(int i) const; // // change mass (incomplete: can only change base mass and inertia at present) // void setBaseMass(btScalar mass) { m_baseMass = mass; } void setBaseInertia(const btVector3 &inertia) { m_baseInertia = inertia; } // // get/set pos/vel/rot/omega for the base link // const btVector3 & getBasePos() const { return m_basePos; } // in world frame const btVector3 getBaseVel() const { return btVector3(m_realBuf[3],m_realBuf[4],m_realBuf[5]); } // in world frame const btQuaternion & getWorldToBaseRot() const { return m_baseQuat; } // rotates world vectors into base frame btVector3 getBaseOmega() const { return btVector3(m_realBuf[0],m_realBuf[1],m_realBuf[2]); } // in world frame void setBasePos(const btVector3 &pos) { m_basePos = pos; } void setBaseWorldTransform(const btTransform& tr) { setBasePos(tr.getOrigin()); setWorldToBaseRot(tr.getRotation().inverse()); } btTransform getBaseWorldTransform() const { btTransform tr; tr.setOrigin(getBasePos()); tr.setRotation(getWorldToBaseRot().inverse()); return tr; } void setBaseVel(const btVector3 &vel) { m_realBuf[3]=vel[0]; m_realBuf[4]=vel[1]; m_realBuf[5]=vel[2]; } void setWorldToBaseRot(const btQuaternion &rot) { m_baseQuat = rot; //m_baseQuat asumed to ba alias!? } void setBaseOmega(const btVector3 &omega) { m_realBuf[0]=omega[0]; m_realBuf[1]=omega[1]; m_realBuf[2]=omega[2]; } // // get/set pos/vel for child m_links (i = 0 to num_links-1) // btScalar getJointPos(int i) const; btScalar getJointVel(int i) const; btScalar * getJointVelMultiDof(int i); btScalar * getJointPosMultiDof(int i); const btScalar * getJointVelMultiDof(int i) const ; const btScalar * getJointPosMultiDof(int i) const ; void setJointPos(int i, btScalar q); void setJointVel(int i, btScalar qdot); void setJointPosMultiDof(int i, btScalar *q); void setJointVelMultiDof(int i, btScalar *qdot); // // direct access to velocities as a vector of 6 + num_links elements. // (omega first, then v, then joint velocities.) // const btScalar * getVelocityVector() const { return &m_realBuf[0]; } /* btScalar * getVelocityVector() { return &real_buf[0]; } */ // // get the frames of reference (positions and orientations) of the child m_links // (i = 0 to num_links-1) // const btVector3 & getRVector(int i) const; // vector from COM(parent(i)) to COM(i), in frame i's coords const btQuaternion & getParentToLocalRot(int i) const; // rotates vectors in frame parent(i) to vectors in frame i. // // transform vectors in local frame of link i to world frame (or vice versa) // btVector3 localPosToWorld(int i, const btVector3 &vec) const; btVector3 localDirToWorld(int i, const btVector3 &vec) const; btVector3 worldPosToLocal(int i, const btVector3 &vec) const; btVector3 worldDirToLocal(int i, const btVector3 &vec) const; // // transform a frame in local coordinate to a frame in world coordinate // btMatrix3x3 localFrameToWorld(int i, const btMatrix3x3 &mat) const; // // calculate kinetic energy and angular momentum // useful for debugging. // btScalar getKineticEnergy() const; btVector3 getAngularMomentum() const; // // set external forces and torques. Note all external forces/torques are given in the WORLD frame. // void clearForcesAndTorques(); void clearConstraintForces(); void clearVelocities(); void addBaseForce(const btVector3 &f) { m_baseForce += f; } void addBaseTorque(const btVector3 &t) { m_baseTorque += t; } void addLinkForce(int i, const btVector3 &f); void addLinkTorque(int i, const btVector3 &t); void addBaseConstraintForce(const btVector3 &f) { m_baseConstraintForce += f; } void addBaseConstraintTorque(const btVector3 &t) { m_baseConstraintTorque += t; } void addLinkConstraintForce(int i, const btVector3 &f); void addLinkConstraintTorque(int i, const btVector3 &t); void addJointTorque(int i, btScalar Q); void addJointTorqueMultiDof(int i, int dof, btScalar Q); void addJointTorqueMultiDof(int i, const btScalar *Q); const btVector3 & getBaseForce() const { return m_baseForce; } const btVector3 & getBaseTorque() const { return m_baseTorque; } const btVector3 & getLinkForce(int i) const; const btVector3 & getLinkTorque(int i) const; btScalar getJointTorque(int i) const; btScalar * getJointTorqueMultiDof(int i); // // dynamics routines. // // timestep the velocities (given the external forces/torques set using addBaseForce etc). // also sets up caches for calcAccelerationDeltas. // // Note: the caller must provide three vectors which are used as // temporary scratch space. The idea here is to reduce dynamic // memory allocation: the same scratch vectors can be re-used // again and again for different Multibodies, instead of each // btMultiBody allocating (and then deallocating) their own // individual scratch buffers. This gives a considerable speed // improvement, at least on Windows (where dynamic memory // allocation appears to be fairly slow). // void computeAccelerationsArticulatedBodyAlgorithmMultiDof(btScalar dt, btAlignedObjectArray<btScalar> &scratch_r, btAlignedObjectArray<btVector3> &scratch_v, btAlignedObjectArray<btMatrix3x3> &scratch_m, bool isConstraintPass=false ); ///stepVelocitiesMultiDof is deprecated, use computeAccelerationsArticulatedBodyAlgorithmMultiDof instead void stepVelocitiesMultiDof(btScalar dt, btAlignedObjectArray<btScalar> &scratch_r, btAlignedObjectArray<btVector3> &scratch_v, btAlignedObjectArray<btMatrix3x3> &scratch_m, bool isConstraintPass=false) { computeAccelerationsArticulatedBodyAlgorithmMultiDof(dt,scratch_r,scratch_v,scratch_m,isConstraintPass); } // calcAccelerationDeltasMultiDof // input: force vector (in same format as jacobian, i.e.: // 3 torque values, 3 force values, num_links joint torque values) // output: 3 omegadot values, 3 vdot values, num_links q_double_dot values // (existing contents of output array are replaced) // calcAccelerationDeltasMultiDof must have been called first. void calcAccelerationDeltasMultiDof(const btScalar *force, btScalar *output, btAlignedObjectArray<btScalar> &scratch_r, btAlignedObjectArray<btVector3> &scratch_v) const; void applyDeltaVeeMultiDof2(const btScalar * delta_vee, btScalar multiplier) { for (int dof = 0; dof < 6 + getNumDofs(); ++dof) { m_deltaV[dof] += delta_vee[dof] * multiplier; } } void processDeltaVeeMultiDof2() { applyDeltaVeeMultiDof(&m_deltaV[0],1); for (int dof = 0; dof < 6 + getNumDofs(); ++dof) { m_deltaV[dof] = 0.f; } } void applyDeltaVeeMultiDof(const btScalar * delta_vee, btScalar multiplier) { //for (int dof = 0; dof < 6 + getNumDofs(); ++dof) // printf("%.4f ", delta_vee[dof]*multiplier); //printf("\n"); //btScalar sum = 0; //for (int dof = 0; dof < 6 + getNumDofs(); ++dof) //{ // sum += delta_vee[dof]*multiplier*delta_vee[dof]*multiplier; //} //btScalar l = btSqrt(sum); //if (l>m_maxAppliedImpulse) //{ // multiplier *= m_maxAppliedImpulse/l; //} for (int dof = 0; dof < 6 + getNumDofs(); ++dof) { m_realBuf[dof] += delta_vee[dof] * multiplier; btClamp(m_realBuf[dof],-m_maxCoordinateVelocity,m_maxCoordinateVelocity); } } // timestep the positions (given current velocities). void stepPositionsMultiDof(btScalar dt, btScalar *pq = 0, btScalar *pqd = 0); // // contacts // // This routine fills out a contact constraint jacobian for this body. // the 'normal' supplied must be -n for body1 or +n for body2 of the contact. // 'normal' & 'contact_point' are both given in world coordinates. void fillContactJacobianMultiDof(int link, const btVector3 &contact_point, const btVector3 &normal, btScalar *jac, btAlignedObjectArray<btScalar> &scratch_r, btAlignedObjectArray<btVector3> &scratch_v, btAlignedObjectArray<btMatrix3x3> &scratch_m) const { fillConstraintJacobianMultiDof(link, contact_point, btVector3(0, 0, 0), normal, jac, scratch_r, scratch_v, scratch_m); } //a more general version of fillContactJacobianMultiDof which does not assume.. //.. that the constraint in question is contact or, to be more precise, constrains linear velocity only void fillConstraintJacobianMultiDof(int link, const btVector3 &contact_point, const btVector3 &normal_ang, const btVector3 &normal_lin, btScalar *jac, btAlignedObjectArray<btScalar> &scratch_r, btAlignedObjectArray<btVector3> &scratch_v, btAlignedObjectArray<btMatrix3x3> &scratch_m) const; // // sleeping // void setCanSleep(bool canSleep) { m_canSleep = canSleep; } bool getCanSleep()const { return m_canSleep; } bool isAwake() const { return m_awake; } void wakeUp(); void goToSleep(); void checkMotionAndSleepIfRequired(btScalar timestep); bool hasFixedBase() const { return m_fixedBase; } int getCompanionId() const { return m_companionId; } void setCompanionId(int id) { //printf("for %p setCompanionId(%d)\n",this, id); m_companionId = id; } void setNumLinks(int numLinks)//careful: when changing the number of m_links, make sure to re-initialize or update existing m_links { m_links.resize(numLinks); } btScalar getLinearDamping() const { return m_linearDamping; } void setLinearDamping( btScalar damp) { m_linearDamping = damp; } btScalar getAngularDamping() const { return m_angularDamping; } void setAngularDamping( btScalar damp) { m_angularDamping = damp; } bool getUseGyroTerm() const { return m_useGyroTerm; } void setUseGyroTerm(bool useGyro) { m_useGyroTerm = useGyro; } btScalar getMaxCoordinateVelocity() const { return m_maxCoordinateVelocity ; } void setMaxCoordinateVelocity(btScalar maxVel) { m_maxCoordinateVelocity = maxVel; } btScalar getMaxAppliedImpulse() const { return m_maxAppliedImpulse; } void setMaxAppliedImpulse(btScalar maxImp) { m_maxAppliedImpulse = maxImp; } void setHasSelfCollision(bool hasSelfCollision) { m_hasSelfCollision = hasSelfCollision; } bool hasSelfCollision() const { return m_hasSelfCollision; } void finalizeMultiDof(); void useRK4Integration(bool use) { m_useRK4 = use; } bool isUsingRK4Integration() const { return m_useRK4; } void useGlobalVelocities(bool use) { m_useGlobalVelocities = use; } bool isUsingGlobalVelocities() const { return m_useGlobalVelocities; } bool isPosUpdated() const { return __posUpdated; } void setPosUpdated(bool updated) { __posUpdated = updated; } //internalNeedsJointFeedback is for internal use only bool internalNeedsJointFeedback() const { return m_internalNeedsJointFeedback; } void forwardKinematics(btAlignedObjectArray<btQuaternion>& scratch_q,btAlignedObjectArray<btVector3>& scratch_m); void compTreeLinkVelocities(btVector3 *omega, btVector3 *vel) const; void updateCollisionObjectWorldTransforms(btAlignedObjectArray<btQuaternion>& scratch_q,btAlignedObjectArray<btVector3>& scratch_m); virtual int calculateSerializeBufferSize() const; ///fills the dataBuffer and returns the struct name (and 0 on failure) virtual const char* serialize(void* dataBuffer, class btSerializer* serializer) const; const char* getBaseName() const { return m_baseName; } ///memory of setBaseName needs to be manager by user void setBaseName(const char* name) { m_baseName = name; } ///users can point to their objects, userPointer is not used by Bullet void* getUserPointer() const { return m_userObjectPointer; } int getUserIndex() const { return m_userIndex; } int getUserIndex2() const { return m_userIndex2; } ///users can point to their objects, userPointer is not used by Bullet void setUserPointer(void* userPointer) { m_userObjectPointer = userPointer; } ///users can point to their objects, userPointer is not used by Bullet void setUserIndex(int index) { m_userIndex = index; } void setUserIndex2(int index) { m_userIndex2 = index; } private: btMultiBody(const btMultiBody &); // not implemented void operator=(const btMultiBody &); // not implemented void solveImatrix(const btVector3& rhs_top, const btVector3& rhs_bot, float result[6]) const; void solveImatrix(const btSpatialForceVector &rhs, btSpatialMotionVector &result) const; void updateLinksDofOffsets() { int dofOffset = 0, cfgOffset = 0; for(int bidx = 0; bidx < m_links.size(); ++bidx) { m_links[bidx].m_dofOffset = dofOffset; m_links[bidx].m_cfgOffset = cfgOffset; dofOffset += m_links[bidx].m_dofCount; cfgOffset += m_links[bidx].m_posVarCount; } } void mulMatrix(btScalar *pA, btScalar *pB, int rowsA, int colsA, int rowsB, int colsB, btScalar *pC) const; private: btMultiBodyLinkCollider* m_baseCollider;//can be NULL const char* m_baseName;//memory needs to be manager by user! btVector3 m_basePos; // position of COM of base (world frame) btQuaternion m_baseQuat; // rotates world points into base frame btScalar m_baseMass; // mass of the base btVector3 m_baseInertia; // inertia of the base (in local frame; diagonal) btVector3 m_baseForce; // external force applied to base. World frame. btVector3 m_baseTorque; // external torque applied to base. World frame. btVector3 m_baseConstraintForce; // external force applied to base. World frame. btVector3 m_baseConstraintTorque; // external torque applied to base. World frame. btAlignedObjectArray<btMultibodyLink> m_links; // array of m_links, excluding the base. index from 0 to num_links-1. btAlignedObjectArray<btMultiBodyLinkCollider*> m_colliders; // // realBuf: // offset size array // 0 6 + num_links v (base_omega; base_vel; joint_vels) MULTIDOF [sysdof x sysdof for D matrices (TOO MUCH!) + pos_delta which is sys-cfg sized] // 6+num_links num_links D // // vectorBuf: // offset size array // 0 num_links h_top // num_links num_links h_bottom // // matrixBuf: // offset size array // 0 num_links+1 rot_from_parent // btAlignedObjectArray<btScalar> m_deltaV; btAlignedObjectArray<btScalar> m_realBuf; btAlignedObjectArray<btVector3> m_vectorBuf; btAlignedObjectArray<btMatrix3x3> m_matrixBuf; btMatrix3x3 m_cachedInertiaTopLeft; btMatrix3x3 m_cachedInertiaTopRight; btMatrix3x3 m_cachedInertiaLowerLeft; btMatrix3x3 m_cachedInertiaLowerRight; bool m_cachedInertiaValid; bool m_fixedBase; // Sleep parameters. bool m_awake; bool m_canSleep; btScalar m_sleepTimer; void* m_userObjectPointer; int m_userIndex2; int m_userIndex; int m_companionId; btScalar m_linearDamping; btScalar m_angularDamping; bool m_useGyroTerm; btScalar m_maxAppliedImpulse; btScalar m_maxCoordinateVelocity; bool m_hasSelfCollision; bool __posUpdated; int m_dofCount, m_posVarCnt; bool m_useRK4, m_useGlobalVelocities; ///the m_needsJointFeedback gets updated/computed during the stepVelocitiesMultiDof and it for internal usage only bool m_internalNeedsJointFeedback; }; struct btMultiBodyLinkDoubleData { btQuaternionDoubleData m_zeroRotParentToThis; btVector3DoubleData m_parentComToThisComOffset; btVector3DoubleData m_thisPivotToThisComOffset; btVector3DoubleData m_jointAxisTop[6]; btVector3DoubleData m_jointAxisBottom[6]; btVector3DoubleData m_linkInertia; // inertia of the base (in local frame; diagonal) double m_linkMass; int m_parentIndex; int m_jointType; int m_dofCount; int m_posVarCount; double m_jointPos[7]; double m_jointVel[6]; double m_jointTorque[6]; double m_jointDamping; double m_jointFriction; char *m_linkName; char *m_jointName; btCollisionObjectDoubleData *m_linkCollider; char *m_paddingPtr; }; struct btMultiBodyLinkFloatData { btQuaternionFloatData m_zeroRotParentToThis; btVector3FloatData m_parentComToThisComOffset; btVector3FloatData m_thisPivotToThisComOffset; btVector3FloatData m_jointAxisTop[6]; btVector3FloatData m_jointAxisBottom[6]; btVector3FloatData m_linkInertia; // inertia of the base (in local frame; diagonal) int m_dofCount; float m_linkMass; int m_parentIndex; int m_jointType; float m_jointPos[7]; float m_jointVel[6]; float m_jointTorque[6]; int m_posVarCount; float m_jointDamping; float m_jointFriction; char *m_linkName; char *m_jointName; btCollisionObjectFloatData *m_linkCollider; char *m_paddingPtr; }; ///do not change those serialization structures, it requires an updated sBulletDNAstr/sBulletDNAstr64 struct btMultiBodyDoubleData { btTransformDoubleData m_baseWorldTransform; btVector3DoubleData m_baseInertia; // inertia of the base (in local frame; diagonal) double m_baseMass; char *m_baseName; btMultiBodyLinkDoubleData *m_links; btCollisionObjectDoubleData *m_baseCollider; char *m_paddingPtr; int m_numLinks; char m_padding[4]; }; ///do not change those serialization structures, it requires an updated sBulletDNAstr/sBulletDNAstr64 struct btMultiBodyFloatData { char *m_baseName; btMultiBodyLinkFloatData *m_links; btCollisionObjectFloatData *m_baseCollider; btTransformFloatData m_baseWorldTransform; btVector3FloatData m_baseInertia; // inertia of the base (in local frame; diagonal) float m_baseMass; int m_numLinks; }; #endif
{ "pile_set_name": "Github" }
/* Copyright 2012 Yaqiang Wang, * [email protected] * * This library is free software; you can redistribute it and/or modify it * under the terms of the GNU Lesser General Public License as published by * the Free Software Foundation; either version 2.1 of the License, or (at * your option) any later version. * * This library is distributed in the hope that it will be useful, but * WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser * General Public License for more details. */ package org.meteoinfo.desktop.forms; import org.meteoinfo.global.Extent; import org.meteoinfo.map.MapView; import javax.swing.JOptionPane; /** * * @author User */ public class FrmZoomToExtent extends javax.swing.JDialog { private final FrmMain parent; /** * Creates new form FrmZoomToExtent * @param parent * @param modal */ public FrmZoomToExtent(java.awt.Frame parent, boolean modal) { super(parent, modal); this.parent = (FrmMain) parent; initComponents(); } /** * This method is called from within the constructor to initialize the form. * WARNING: Do NOT modify this code. The content of this method is always * regenerated by the Form Editor. */ @SuppressWarnings("unchecked") // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents private void initComponents() { jPanel1 = new javax.swing.JPanel(); jLabel1 = new javax.swing.JLabel(); jTextField_MinLon = new javax.swing.JTextField(); jLabel2 = new javax.swing.JLabel(); jTextField_MaxLon = new javax.swing.JTextField(); jLabel3 = new javax.swing.JLabel(); jTextField_MinLat = new javax.swing.JTextField(); jLabel4 = new javax.swing.JLabel(); jTextField_MaxLat = new javax.swing.JTextField(); jButton_Zoom = new javax.swing.JButton(); jButton_Close = new javax.swing.JButton(); setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE); addWindowListener(new java.awt.event.WindowAdapter() { public void windowOpened(java.awt.event.WindowEvent evt) { formWindowOpened(evt); } }); jPanel1.setBorder(javax.swing.BorderFactory.createTitledBorder("Lon/Lat Extent")); jLabel1.setText("Min Lon:"); jTextField_MinLon.setText("jTextField1"); jLabel2.setText("Max Lon:"); jTextField_MaxLon.setText("jTextField1"); jLabel3.setText("Min Lat:"); jTextField_MinLat.setText("jTextField1"); jLabel4.setText("Max Lat:"); jTextField_MaxLat.setText("jTextField1"); javax.swing.GroupLayout jPanel1Layout = new javax.swing.GroupLayout(jPanel1); jPanel1.setLayout(jPanel1Layout); jPanel1Layout.setHorizontalGroup( jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(jPanel1Layout.createSequentialGroup() .addGap(18, 18, 18) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(jPanel1Layout.createSequentialGroup() .addComponent(jLabel1) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jTextField_MinLon, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(jPanel1Layout.createSequentialGroup() .addComponent(jLabel3) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jTextField_MinLat, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))) .addGap(26, 26, 26) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(jPanel1Layout.createSequentialGroup() .addComponent(jLabel4) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jTextField_MaxLat, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(jPanel1Layout.createSequentialGroup() .addComponent(jLabel2) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED) .addComponent(jTextField_MaxLon, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) ); jPanel1Layout.setVerticalGroup( jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(jPanel1Layout.createSequentialGroup() .addContainerGap() .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jLabel1) .addComponent(jTextField_MinLon, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addComponent(jLabel2) .addComponent(jTextField_MaxLon, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jLabel4) .addComponent(jTextField_MaxLat, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)) .addGroup(jPanel1Layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jLabel3) .addComponent(jTextField_MinLat, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) ); jButton_Zoom.setText("Zoom"); jButton_Zoom.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jButton_ZoomActionPerformed(evt); } }); jButton_Close.setText("Close"); jButton_Close.addActionListener(new java.awt.event.ActionListener() { public void actionPerformed(java.awt.event.ActionEvent evt) { jButton_CloseActionPerformed(evt); } }); javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane()); getContentPane().setLayout(layout); layout.setHorizontalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addContainerGap() .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup() .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE) .addComponent(jButton_Zoom) .addGap(65, 65, 65) .addComponent(jButton_Close) .addGap(69, 69, 69)) ); layout.setVerticalGroup( layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING) .addGroup(layout.createSequentialGroup() .addContainerGap() .addComponent(jPanel1, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE) .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED) .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE) .addComponent(jButton_Zoom) .addComponent(jButton_Close)) .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)) ); pack(); }// </editor-fold>//GEN-END:initComponents private void formWindowOpened(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_formWindowOpened // TODO add your handling code here: double minLon, maxLon, minLat, maxLat; MapView mapView = ((FrmMain) parent).getMapDocument().getActiveMapFrame().getMapView(); if (mapView.getProjection().isLonLatMap()) { minLon = mapView.getViewExtent().minX; maxLon = mapView.getViewExtent().maxX; minLat = mapView.getViewExtent().minY; maxLat = mapView.getViewExtent().maxY; } else { minLon = 0; maxLon = 0; minLat = 0; maxLat = 0; } this.jTextField_MinLon.setText(String.format("%.2f", minLon)); this.jTextField_MaxLon.setText(String.format("%.2f", maxLon)); this.jTextField_MinLat.setText(String.format("%.2f", minLat)); this.jTextField_MaxLat.setText(String.format("%.2f", maxLat)); }//GEN-LAST:event_formWindowOpened private void jButton_ZoomActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton_ZoomActionPerformed // TODO add your handling code here: //Check lon/lat set double minLon, maxLon, minLat, maxLat; minLon = Double.parseDouble(this.jTextField_MinLon.getText()); maxLon = Double.parseDouble(this.jTextField_MaxLon.getText()); minLat = Double.parseDouble(this.jTextField_MinLat.getText()); maxLat = Double.parseDouble(this.jTextField_MaxLat.getText()); if (minLon >= maxLon || minLat >= maxLat) { JOptionPane.showMessageDialog(this, "Lon/Lat set error!", "Error", JOptionPane.ERROR_MESSAGE); return; } //Zoom to lon/lat extent Extent aExtent = new Extent(); aExtent.minX = minLon; aExtent.maxX = maxLon; aExtent.minY = minLat; aExtent.maxY = maxLat; FrmMain frmMain = (FrmMain) parent; if (frmMain.getMainTab().getSelectedIndex() == 0) { frmMain.getMapDocument().getActiveMapFrame().getMapView().zoomToExtentLonLatEx(aExtent); } else if (frmMain.getMainTab().getSelectedIndex() == 1) { frmMain.getMapDocument().getMapLayout().getActiveLayoutMap().zoomToExtentLonLatEx(aExtent); frmMain.getMapDocument().getMapLayout().paintGraphics(); } }//GEN-LAST:event_jButton_ZoomActionPerformed private void jButton_CloseActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton_CloseActionPerformed // TODO add your handling code here: this.dispose(); }//GEN-LAST:event_jButton_CloseActionPerformed /** * @param args the command line arguments */ public static void main(String args[]) { /* Set the Nimbus look and feel */ //<editor-fold defaultstate="collapsed" desc=" Look and feel setting code (optional) "> /* If Nimbus (introduced in Java SE 6) is not available, stay with the default look and feel. * For details see http://download.oracle.com/javase/tutorial/uiswing/lookandfeel/plaf.html */ try { for (javax.swing.UIManager.LookAndFeelInfo info : javax.swing.UIManager.getInstalledLookAndFeels()) { if ("Nimbus".equals(info.getName())) { javax.swing.UIManager.setLookAndFeel(info.getClassName()); break; } } } catch (ClassNotFoundException ex) { java.util.logging.Logger.getLogger(FrmZoomToExtent.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } catch (InstantiationException ex) { java.util.logging.Logger.getLogger(FrmZoomToExtent.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } catch (IllegalAccessException ex) { java.util.logging.Logger.getLogger(FrmZoomToExtent.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } catch (javax.swing.UnsupportedLookAndFeelException ex) { java.util.logging.Logger.getLogger(FrmZoomToExtent.class.getName()).log(java.util.logging.Level.SEVERE, null, ex); } //</editor-fold> /* Create and display the dialog */ java.awt.EventQueue.invokeLater(new Runnable() { public void run() { FrmZoomToExtent dialog = new FrmZoomToExtent(new javax.swing.JFrame(), true); dialog.addWindowListener(new java.awt.event.WindowAdapter() { @Override public void windowClosing(java.awt.event.WindowEvent e) { System.exit(0); } }); dialog.setVisible(true); } }); } // Variables declaration - do not modify//GEN-BEGIN:variables private javax.swing.JButton jButton_Close; private javax.swing.JButton jButton_Zoom; private javax.swing.JLabel jLabel1; private javax.swing.JLabel jLabel2; private javax.swing.JLabel jLabel3; private javax.swing.JLabel jLabel4; private javax.swing.JPanel jPanel1; private javax.swing.JTextField jTextField_MaxLat; private javax.swing.JTextField jTextField_MaxLon; private javax.swing.JTextField jTextField_MinLat; private javax.swing.JTextField jTextField_MinLon; // End of variables declaration//GEN-END:variables }
{ "pile_set_name": "Github" }
1. Get the application URL by running these commands: {{- if .Values.ingress.enabled }} {{- range .Values.ingress.hosts }} http{{ if $.Values.ingress.tls }}s{{ end }}://{{ . }}{{ $.Values.ingress.path }} {{- end }} {{- else if contains "NodePort" .Values.service.type }} export NODE_PORT=$(kubectl get --namespace {{ .Release.Namespace }} -o jsonpath="{.spec.ports[0].nodePort}" services {{ template "clear.fullname" . }}) export NODE_IP=$(kubectl get nodes --namespace {{ .Release.Namespace }} -o jsonpath="{.items[0].status.addresses[0].address}") echo http://$NODE_IP:$NODE_PORT {{- else if contains "LoadBalancer" .Values.service.type }} NOTE: It may take a few minutes for the LoadBalancer IP to be available. You can watch the status of by running 'kubectl get svc -w {{ template "clear.fullname" . }}' export SERVICE_IP=$(kubectl get svc --namespace {{ .Release.Namespace }} {{ template "clear.fullname" . }} -o jsonpath='{.status.loadBalancer.ingress[0].ip}') echo http://$SERVICE_IP:{{ .Values.service.port }} {{- else if contains "ClusterIP" .Values.service.type }} export POD_NAME=$(kubectl get pods --namespace {{ .Release.Namespace }} -l "app={{ template "clear.name" . }},release={{ .Release.Name }}" -o jsonpath="{.items[0].metadata.name}") echo "Visit http://127.0.0.1:8080 to use your application" kubectl port-forward $POD_NAME 8080:80 {{- end }}
{ "pile_set_name": "Github" }
* There are currently three very similar families of dpdfiles that look like Fock matrices: Fock <X|X> - An intermediate used during construction of the Fock matrix. Just the J/K part. F <X|X> - The Fock matrix without diagonal elements FD <X|X> - The Fock matrix * Ideally, those can be condensed. The F uses in the amplitude conditions will change to FD upon changing the conditions from = to += form As for Fock uses, reconsider if that's the best way to construct the Fock matrix. If it is, then rename it.
{ "pile_set_name": "Github" }
<?xml version="1.0" encoding="utf-8"?> <!--Generated by crowdin.net--> <resources> <string-array name="pref_automatic_action_entries"> <item>Demander</item> <item>Refuser</item> <item>Autoriser</item> </string-array> <string-array name="pref_status_icon_type_entries"> <item>Point</item> <item>Émoticône</item> </string-array> <string-array name="pref_date_format_entries"> <item>Par défaut du système</item> <item>12/31/2011</item> <item>31/12/2011</item> <item>2011/12/31</item> </string-array> <string-array name="pref_notifications_type_entries"> <item>Toast</item> <item>Barre d\'état</item> </string-array> <string-array name="pref_toast_location_entries"> <item>Par défaut</item> <item>En haut</item> <item>Au centre</item> <item>En bas</item> </string-array> </resources>
{ "pile_set_name": "Github" }
/* * Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this * particular file as subject to the "Classpath" exception as provided * by Oracle in the LICENSE file that accompanied this code. * * This code is distributed in the hope that it will be useful, but WITHOUT * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License * version 2 for more details (a copy is included in the LICENSE file that * accompanied this code). * * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * questions. */ package java8.util.function; /** * A place for static default implementations of the new Java 8 * default interface methods and static interface methods in the * {@link UnaryOperator} interface. */ public final class UnaryOperators { /** * Returns a unary operator that always returns its input argument. * * @param <T> the type of the input and output of the operator * @return a unary operator that always returns its input argument */ public static <T> UnaryOperator<T> identity() { return t -> t; } private UnaryOperators() { } }
{ "pile_set_name": "Github" }
package router import ( "fmt" "io/ioutil" "log" "time" "github.com/AsynkronIT/protoactor-go/actor" "github.com/stretchr/testify/mock" ) var nilPID *actor.PID func init() { // discard all logging in tests log.SetOutput(ioutil.Discard) } // mockContext type mockContext struct { mock.Mock } // // Interface: Context // func (m *mockContext) Parent() *actor.PID { args := m.Called() return args.Get(0).(*actor.PID) } func (m *mockContext) Self() *actor.PID { args := m.Called() return args.Get(0).(*actor.PID) } func (m *mockContext) Sender() *actor.PID { args := m.Called() return args.Get(0).(*actor.PID) } func (m *mockContext) Actor() actor.Actor { args := m.Called() return args.Get(0).(actor.Actor) } func (m *mockContext) ReceiveTimeout() time.Duration { args := m.Called() return args.Get(0).(time.Duration) } func (m *mockContext) Children() []*actor.PID { args := m.Called() return args.Get(0).([]*actor.PID) } func (m *mockContext) Respond(response interface{}) { m.Called(response) } func (m *mockContext) Stash() { m.Called() } func (m *mockContext) Watch(pid *actor.PID) { m.Called(pid) } func (m *mockContext) Unwatch(pid *actor.PID) { m.Called(pid) } func (m *mockContext) SetReceiveTimeout(d time.Duration) { m.Called(d) } func (m *mockContext) CancelReceiveTimeout() { m.Called() } func (m *mockContext) Forward(pid *actor.PID) { m.Called() } func (m *mockContext) AwaitFuture(f *actor.Future, cont func(res interface{}, err error)) { m.Called(f, cont) } // // Interface: SenderContext // func (m *mockContext) Message() interface{} { args := m.Called() return args.Get(0) } func (m *mockContext) MessageHeader() actor.ReadonlyMessageHeader { args := m.Called() return args.Get(0).(actor.ReadonlyMessageHeader) } func (m *mockContext) Send(pid *actor.PID, message interface{}) { m.Called() p, _ := actor.ProcessRegistry.Get(pid) p.SendUserMessage(pid, message) } func (m *mockContext) Request(pid *actor.PID, message interface{}) { args := m.Called() p, _ := actor.ProcessRegistry.Get(pid) env := &actor.MessageEnvelope{ Header: nil, Message: message, Sender: args.Get(0).(*actor.PID), } p.SendUserMessage(pid, env) } func (m *mockContext) RequestWithCustomSender(pid *actor.PID, message interface{}, sender *actor.PID) { m.Called() p, _ := actor.ProcessRegistry.Get(pid) env := &actor.MessageEnvelope{ Header: nil, Message: message, Sender: sender, } p.SendUserMessage(pid, env) } func (m *mockContext) RequestFuture(pid *actor.PID, message interface{}, timeout time.Duration) *actor.Future { args := m.Called() m.Called() p, _ := actor.ProcessRegistry.Get(pid) p.SendUserMessage(pid, message) return args.Get(0).(*actor.Future) } // // Interface: ReceiverContext // func (m *mockContext) Receive(envelope *actor.MessageEnvelope) { m.Called(envelope) } // // Interface: SpawnerContext // func (m *mockContext) Spawn(p *actor.Props) *actor.PID { args := m.Called(p) return args.Get(0).(*actor.PID) } func (m *mockContext) SpawnPrefix(p *actor.Props, prefix string) *actor.PID { args := m.Called(p, prefix) return args.Get(0).(*actor.PID) } func (m *mockContext) SpawnNamed(p *actor.Props, name string) (*actor.PID, error) { args := m.Called(p, name) return args.Get(0).(*actor.PID), args.Get(1).(error) } // // Interface: StopperContext // func (m *mockContext) Stop(pid *actor.PID) { m.Called(pid) } func (m *mockContext) StopFuture(pid *actor.PID) *actor.Future { args := m.Called(pid) return args.Get(0).(*actor.Future) } func (m *mockContext) Poison(pid *actor.PID) { m.Called(pid) } func (m *mockContext) PoisonFuture(pid *actor.PID) *actor.Future { args := m.Called(pid) return args.Get(0).(*actor.Future) } // mockProcess type mockProcess struct { mock.Mock } func spawnMockProcess(name string) (*actor.PID, *mockProcess) { p := &mockProcess{} pid, ok := actor.ProcessRegistry.Add(p, name) if !ok { panic(fmt.Errorf("did not spawn named process '%s'", name)) } return pid, p } func removeMockProcess(pid *actor.PID) { actor.ProcessRegistry.Remove(pid) } func (m *mockProcess) SendUserMessage(pid *actor.PID, message interface{}) { m.Called(pid, message) } func (m *mockProcess) SendSystemMessage(pid *actor.PID, message interface{}) { m.Called(pid, message) } func (m *mockProcess) Stop(pid *actor.PID) { m.Called(pid) }
{ "pile_set_name": "Github" }
fileFormatVersion: 2 guid: 1efcf3b84c99d3041b869d559d696634 TextureImporter: serializedVersion: 2 mipmaps: mipMapMode: 0 enableMipMap: 1 linearTexture: 0 correctGamma: 0 fadeOut: 0 borderMipMap: 0 mipMapFadeDistanceStart: 1 mipMapFadeDistanceEnd: 3 bumpmap: convertToNormalMap: 0 externalNormalMap: 0 heightScale: .25 normalMapFilter: 0 isReadable: 0 grayScaleToAlpha: 0 generateCubemap: 0 seamlessCubemap: 0 textureFormat: -1 maxTextureSize: 1024 textureSettings: filterMode: -1 aniso: -1 mipBias: -1 wrapMode: -1 nPOTScale: 1 lightmap: 0 compressionQuality: 50 spriteMode: 0 spriteExtrude: 1 spriteMeshType: 1 alignment: 0 spritePivot: {x: .5, y: .5} spriteBorder: {x: 0, y: 0, z: 0, w: 0} spritePixelsToUnits: 100 alphaIsTransparency: 0 textureType: -1 buildTargetSettings: [] spriteSheet: sprites: [] spritePackingTag: userData:
{ "pile_set_name": "Github" }
/* Font Awesome uses the Unicode Private Use Area (PUA) to ensure screen readers do not read off random characters that represent icons */ .#{$fa-css-prefix}-glass:before { content: $fa-var-glass; } .#{$fa-css-prefix}-music:before { content: $fa-var-music; } .#{$fa-css-prefix}-search:before { content: $fa-var-search; } .#{$fa-css-prefix}-envelope-o:before { content: $fa-var-envelope-o; } .#{$fa-css-prefix}-heart:before { content: $fa-var-heart; } .#{$fa-css-prefix}-star:before { content: $fa-var-star; } .#{$fa-css-prefix}-star-o:before { content: $fa-var-star-o; } .#{$fa-css-prefix}-user:before { content: $fa-var-user; } .#{$fa-css-prefix}-film:before { content: $fa-var-film; } .#{$fa-css-prefix}-th-large:before { content: $fa-var-th-large; } .#{$fa-css-prefix}-th:before { content: $fa-var-th; } .#{$fa-css-prefix}-th-list:before { content: $fa-var-th-list; } .#{$fa-css-prefix}-check:before { content: $fa-var-check; } .#{$fa-css-prefix}-remove:before, .#{$fa-css-prefix}-close:before, .#{$fa-css-prefix}-times:before { content: $fa-var-times; } .#{$fa-css-prefix}-search-plus:before { content: $fa-var-search-plus; } .#{$fa-css-prefix}-search-minus:before { content: $fa-var-search-minus; } .#{$fa-css-prefix}-power-off:before { content: $fa-var-power-off; } .#{$fa-css-prefix}-signal:before { content: $fa-var-signal; } .#{$fa-css-prefix}-gear:before, .#{$fa-css-prefix}-cog:before { content: $fa-var-cog; } .#{$fa-css-prefix}-trash-o:before { content: $fa-var-trash-o; } .#{$fa-css-prefix}-home:before { content: $fa-var-home; } .#{$fa-css-prefix}-file-o:before { content: $fa-var-file-o; } .#{$fa-css-prefix}-clock-o:before { content: $fa-var-clock-o; } .#{$fa-css-prefix}-road:before { content: $fa-var-road; } .#{$fa-css-prefix}-download:before { content: $fa-var-download; } .#{$fa-css-prefix}-arrow-circle-o-down:before { content: $fa-var-arrow-circle-o-down; } .#{$fa-css-prefix}-arrow-circle-o-up:before { content: $fa-var-arrow-circle-o-up; } .#{$fa-css-prefix}-inbox:before { content: $fa-var-inbox; } .#{$fa-css-prefix}-play-circle-o:before { content: $fa-var-play-circle-o; } .#{$fa-css-prefix}-rotate-right:before, .#{$fa-css-prefix}-repeat:before { content: $fa-var-repeat; } .#{$fa-css-prefix}-refresh:before { content: $fa-var-refresh; } .#{$fa-css-prefix}-list-alt:before { content: $fa-var-list-alt; } .#{$fa-css-prefix}-lock:before { content: $fa-var-lock; } .#{$fa-css-prefix}-flag:before { content: $fa-var-flag; } .#{$fa-css-prefix}-headphones:before { content: $fa-var-headphones; } .#{$fa-css-prefix}-volume-off:before { content: $fa-var-volume-off; } .#{$fa-css-prefix}-volume-down:before { content: $fa-var-volume-down; } .#{$fa-css-prefix}-volume-up:before { content: $fa-var-volume-up; } .#{$fa-css-prefix}-qrcode:before { content: $fa-var-qrcode; } .#{$fa-css-prefix}-barcode:before { content: $fa-var-barcode; } .#{$fa-css-prefix}-tag:before { content: $fa-var-tag; } .#{$fa-css-prefix}-tags:before { content: $fa-var-tags; } .#{$fa-css-prefix}-book:before { content: $fa-var-book; } .#{$fa-css-prefix}-bookmark:before { content: $fa-var-bookmark; } .#{$fa-css-prefix}-print:before { content: $fa-var-print; } .#{$fa-css-prefix}-camera:before { content: $fa-var-camera; } .#{$fa-css-prefix}-font:before { content: $fa-var-font; } .#{$fa-css-prefix}-bold:before { content: $fa-var-bold; } .#{$fa-css-prefix}-italic:before { content: $fa-var-italic; } .#{$fa-css-prefix}-text-height:before { content: $fa-var-text-height; } .#{$fa-css-prefix}-text-width:before { content: $fa-var-text-width; } .#{$fa-css-prefix}-align-left:before { content: $fa-var-align-left; } .#{$fa-css-prefix}-align-center:before { content: $fa-var-align-center; } .#{$fa-css-prefix}-align-right:before { content: $fa-var-align-right; } .#{$fa-css-prefix}-align-justify:before { content: $fa-var-align-justify; } .#{$fa-css-prefix}-list:before { content: $fa-var-list; } .#{$fa-css-prefix}-dedent:before, .#{$fa-css-prefix}-outdent:before { content: $fa-var-outdent; } .#{$fa-css-prefix}-indent:before { content: $fa-var-indent; } .#{$fa-css-prefix}-video-camera:before { content: $fa-var-video-camera; } .#{$fa-css-prefix}-photo:before, .#{$fa-css-prefix}-image:before, .#{$fa-css-prefix}-picture-o:before { content: $fa-var-picture-o; } .#{$fa-css-prefix}-pencil:before { content: $fa-var-pencil; } .#{$fa-css-prefix}-map-marker:before { content: $fa-var-map-marker; } .#{$fa-css-prefix}-adjust:before { content: $fa-var-adjust; } .#{$fa-css-prefix}-tint:before { content: $fa-var-tint; } .#{$fa-css-prefix}-edit:before, .#{$fa-css-prefix}-pencil-square-o:before { content: $fa-var-pencil-square-o; } .#{$fa-css-prefix}-share-square-o:before { content: $fa-var-share-square-o; } .#{$fa-css-prefix}-check-square-o:before { content: $fa-var-check-square-o; } .#{$fa-css-prefix}-arrows:before { content: $fa-var-arrows; } .#{$fa-css-prefix}-step-backward:before { content: $fa-var-step-backward; } .#{$fa-css-prefix}-fast-backward:before { content: $fa-var-fast-backward; } .#{$fa-css-prefix}-backward:before { content: $fa-var-backward; } .#{$fa-css-prefix}-play:before { content: $fa-var-play; } .#{$fa-css-prefix}-pause:before { content: $fa-var-pause; } .#{$fa-css-prefix}-stop:before { content: $fa-var-stop; } .#{$fa-css-prefix}-forward:before { content: $fa-var-forward; } .#{$fa-css-prefix}-fast-forward:before { content: $fa-var-fast-forward; } .#{$fa-css-prefix}-step-forward:before { content: $fa-var-step-forward; } .#{$fa-css-prefix}-eject:before { content: $fa-var-eject; } .#{$fa-css-prefix}-chevron-left:before { content: $fa-var-chevron-left; } .#{$fa-css-prefix}-chevron-right:before { content: $fa-var-chevron-right; } .#{$fa-css-prefix}-plus-circle:before { content: $fa-var-plus-circle; } .#{$fa-css-prefix}-minus-circle:before { content: $fa-var-minus-circle; } .#{$fa-css-prefix}-times-circle:before { content: $fa-var-times-circle; } .#{$fa-css-prefix}-check-circle:before { content: $fa-var-check-circle; } .#{$fa-css-prefix}-question-circle:before { content: $fa-var-question-circle; } .#{$fa-css-prefix}-info-circle:before { content: $fa-var-info-circle; } .#{$fa-css-prefix}-crosshairs:before { content: $fa-var-crosshairs; } .#{$fa-css-prefix}-times-circle-o:before { content: $fa-var-times-circle-o; } .#{$fa-css-prefix}-check-circle-o:before { content: $fa-var-check-circle-o; } .#{$fa-css-prefix}-ban:before { content: $fa-var-ban; } .#{$fa-css-prefix}-arrow-left:before { content: $fa-var-arrow-left; } .#{$fa-css-prefix}-arrow-right:before { content: $fa-var-arrow-right; } .#{$fa-css-prefix}-arrow-up:before { content: $fa-var-arrow-up; } .#{$fa-css-prefix}-arrow-down:before { content: $fa-var-arrow-down; } .#{$fa-css-prefix}-mail-forward:before, .#{$fa-css-prefix}-share:before { content: $fa-var-share; } .#{$fa-css-prefix}-expand:before { content: $fa-var-expand; } .#{$fa-css-prefix}-compress:before { content: $fa-var-compress; } .#{$fa-css-prefix}-plus:before { content: $fa-var-plus; } .#{$fa-css-prefix}-minus:before { content: $fa-var-minus; } .#{$fa-css-prefix}-asterisk:before { content: $fa-var-asterisk; } .#{$fa-css-prefix}-exclamation-circle:before { content: $fa-var-exclamation-circle; } .#{$fa-css-prefix}-gift:before { content: $fa-var-gift; } .#{$fa-css-prefix}-leaf:before { content: $fa-var-leaf; } .#{$fa-css-prefix}-fire:before { content: $fa-var-fire; } .#{$fa-css-prefix}-eye:before { content: $fa-var-eye; } .#{$fa-css-prefix}-eye-slash:before { content: $fa-var-eye-slash; } .#{$fa-css-prefix}-warning:before, .#{$fa-css-prefix}-exclamation-triangle:before { content: $fa-var-exclamation-triangle; } .#{$fa-css-prefix}-plane:before { content: $fa-var-plane; } .#{$fa-css-prefix}-calendar:before { content: $fa-var-calendar; } .#{$fa-css-prefix}-random:before { content: $fa-var-random; } .#{$fa-css-prefix}-comment:before { content: $fa-var-comment; } .#{$fa-css-prefix}-magnet:before { content: $fa-var-magnet; } .#{$fa-css-prefix}-chevron-up:before { content: $fa-var-chevron-up; } .#{$fa-css-prefix}-chevron-down:before { content: $fa-var-chevron-down; } .#{$fa-css-prefix}-retweet:before { content: $fa-var-retweet; } .#{$fa-css-prefix}-shopping-cart:before { content: $fa-var-shopping-cart; } .#{$fa-css-prefix}-folder:before { content: $fa-var-folder; } .#{$fa-css-prefix}-folder-open:before { content: $fa-var-folder-open; } .#{$fa-css-prefix}-arrows-v:before { content: $fa-var-arrows-v; } .#{$fa-css-prefix}-arrows-h:before { content: $fa-var-arrows-h; } .#{$fa-css-prefix}-bar-chart-o:before, .#{$fa-css-prefix}-bar-chart:before { content: $fa-var-bar-chart; } .#{$fa-css-prefix}-twitter-square:before { content: $fa-var-twitter-square; } .#{$fa-css-prefix}-facebook-square:before { content: $fa-var-facebook-square; } .#{$fa-css-prefix}-camera-retro:before { content: $fa-var-camera-retro; } .#{$fa-css-prefix}-key:before { content: $fa-var-key; } .#{$fa-css-prefix}-gears:before, .#{$fa-css-prefix}-cogs:before { content: $fa-var-cogs; } .#{$fa-css-prefix}-comments:before { content: $fa-var-comments; } .#{$fa-css-prefix}-thumbs-o-up:before { content: $fa-var-thumbs-o-up; } .#{$fa-css-prefix}-thumbs-o-down:before { content: $fa-var-thumbs-o-down; } .#{$fa-css-prefix}-star-half:before { content: $fa-var-star-half; } .#{$fa-css-prefix}-heart-o:before { content: $fa-var-heart-o; } .#{$fa-css-prefix}-sign-out:before { content: $fa-var-sign-out; } .#{$fa-css-prefix}-linkedin-square:before { content: $fa-var-linkedin-square; } .#{$fa-css-prefix}-thumb-tack:before { content: $fa-var-thumb-tack; } .#{$fa-css-prefix}-external-link:before { content: $fa-var-external-link; } .#{$fa-css-prefix}-sign-in:before { content: $fa-var-sign-in; } .#{$fa-css-prefix}-trophy:before { content: $fa-var-trophy; } .#{$fa-css-prefix}-github-square:before { content: $fa-var-github-square; } .#{$fa-css-prefix}-upload:before { content: $fa-var-upload; } .#{$fa-css-prefix}-lemon-o:before { content: $fa-var-lemon-o; } .#{$fa-css-prefix}-phone:before { content: $fa-var-phone; } .#{$fa-css-prefix}-square-o:before { content: $fa-var-square-o; } .#{$fa-css-prefix}-bookmark-o:before { content: $fa-var-bookmark-o; } .#{$fa-css-prefix}-phone-square:before { content: $fa-var-phone-square; } .#{$fa-css-prefix}-twitter:before { content: $fa-var-twitter; } .#{$fa-css-prefix}-facebook:before { content: $fa-var-facebook; } .#{$fa-css-prefix}-github:before { content: $fa-var-github; } .#{$fa-css-prefix}-unlock:before { content: $fa-var-unlock; } .#{$fa-css-prefix}-credit-card:before { content: $fa-var-credit-card; } .#{$fa-css-prefix}-rss:before { content: $fa-var-rss; } .#{$fa-css-prefix}-hdd-o:before { content: $fa-var-hdd-o; } .#{$fa-css-prefix}-bullhorn:before { content: $fa-var-bullhorn; } .#{$fa-css-prefix}-bell:before { content: $fa-var-bell; } .#{$fa-css-prefix}-certificate:before { content: $fa-var-certificate; } .#{$fa-css-prefix}-hand-o-right:before { content: $fa-var-hand-o-right; } .#{$fa-css-prefix}-hand-o-left:before { content: $fa-var-hand-o-left; } .#{$fa-css-prefix}-hand-o-up:before { content: $fa-var-hand-o-up; } .#{$fa-css-prefix}-hand-o-down:before { content: $fa-var-hand-o-down; } .#{$fa-css-prefix}-arrow-circle-left:before { content: $fa-var-arrow-circle-left; } .#{$fa-css-prefix}-arrow-circle-right:before { content: $fa-var-arrow-circle-right; } .#{$fa-css-prefix}-arrow-circle-up:before { content: $fa-var-arrow-circle-up; } .#{$fa-css-prefix}-arrow-circle-down:before { content: $fa-var-arrow-circle-down; } .#{$fa-css-prefix}-globe:before { content: $fa-var-globe; } .#{$fa-css-prefix}-wrench:before { content: $fa-var-wrench; } .#{$fa-css-prefix}-tasks:before { content: $fa-var-tasks; } .#{$fa-css-prefix}-filter:before { content: $fa-var-filter; } .#{$fa-css-prefix}-briefcase:before { content: $fa-var-briefcase; } .#{$fa-css-prefix}-arrows-alt:before { content: $fa-var-arrows-alt; } .#{$fa-css-prefix}-group:before, .#{$fa-css-prefix}-users:before { content: $fa-var-users; } .#{$fa-css-prefix}-chain:before, .#{$fa-css-prefix}-link:before { content: $fa-var-link; } .#{$fa-css-prefix}-cloud:before { content: $fa-var-cloud; } .#{$fa-css-prefix}-flask:before { content: $fa-var-flask; } .#{$fa-css-prefix}-cut:before, .#{$fa-css-prefix}-scissors:before { content: $fa-var-scissors; } .#{$fa-css-prefix}-copy:before, .#{$fa-css-prefix}-files-o:before { content: $fa-var-files-o; } .#{$fa-css-prefix}-paperclip:before { content: $fa-var-paperclip; } .#{$fa-css-prefix}-save:before, .#{$fa-css-prefix}-floppy-o:before { content: $fa-var-floppy-o; } .#{$fa-css-prefix}-square:before { content: $fa-var-square; } .#{$fa-css-prefix}-navicon:before, .#{$fa-css-prefix}-reorder:before, .#{$fa-css-prefix}-bars:before { content: $fa-var-bars; } .#{$fa-css-prefix}-list-ul:before { content: $fa-var-list-ul; } .#{$fa-css-prefix}-list-ol:before { content: $fa-var-list-ol; } .#{$fa-css-prefix}-strikethrough:before { content: $fa-var-strikethrough; } .#{$fa-css-prefix}-underline:before { content: $fa-var-underline; } .#{$fa-css-prefix}-table:before { content: $fa-var-table; } .#{$fa-css-prefix}-magic:before { content: $fa-var-magic; } .#{$fa-css-prefix}-truck:before { content: $fa-var-truck; } .#{$fa-css-prefix}-pinterest:before { content: $fa-var-pinterest; } .#{$fa-css-prefix}-pinterest-square:before { content: $fa-var-pinterest-square; } .#{$fa-css-prefix}-google-plus-square:before { content: $fa-var-google-plus-square; } .#{$fa-css-prefix}-google-plus:before { content: $fa-var-google-plus; } .#{$fa-css-prefix}-money:before { content: $fa-var-money; } .#{$fa-css-prefix}-caret-down:before { content: $fa-var-caret-down; } .#{$fa-css-prefix}-caret-up:before { content: $fa-var-caret-up; } .#{$fa-css-prefix}-caret-left:before { content: $fa-var-caret-left; } .#{$fa-css-prefix}-caret-right:before { content: $fa-var-caret-right; } .#{$fa-css-prefix}-columns:before { content: $fa-var-columns; } .#{$fa-css-prefix}-unsorted:before, .#{$fa-css-prefix}-sort:before { content: $fa-var-sort; } .#{$fa-css-prefix}-sort-down:before, .#{$fa-css-prefix}-sort-desc:before { content: $fa-var-sort-desc; } .#{$fa-css-prefix}-sort-up:before, .#{$fa-css-prefix}-sort-asc:before { content: $fa-var-sort-asc; } .#{$fa-css-prefix}-envelope:before { content: $fa-var-envelope; } .#{$fa-css-prefix}-linkedin:before { content: $fa-var-linkedin; } .#{$fa-css-prefix}-rotate-left:before, .#{$fa-css-prefix}-undo:before { content: $fa-var-undo; } .#{$fa-css-prefix}-legal:before, .#{$fa-css-prefix}-gavel:before { content: $fa-var-gavel; } .#{$fa-css-prefix}-dashboard:before, .#{$fa-css-prefix}-tachometer:before { content: $fa-var-tachometer; } .#{$fa-css-prefix}-comment-o:before { content: $fa-var-comment-o; } .#{$fa-css-prefix}-comments-o:before { content: $fa-var-comments-o; } .#{$fa-css-prefix}-flash:before, .#{$fa-css-prefix}-bolt:before { content: $fa-var-bolt; } .#{$fa-css-prefix}-sitemap:before { content: $fa-var-sitemap; } .#{$fa-css-prefix}-umbrella:before { content: $fa-var-umbrella; } .#{$fa-css-prefix}-paste:before, .#{$fa-css-prefix}-clipboard:before { content: $fa-var-clipboard; } .#{$fa-css-prefix}-lightbulb-o:before { content: $fa-var-lightbulb-o; } .#{$fa-css-prefix}-exchange:before { content: $fa-var-exchange; } .#{$fa-css-prefix}-cloud-download:before { content: $fa-var-cloud-download; } .#{$fa-css-prefix}-cloud-upload:before { content: $fa-var-cloud-upload; } .#{$fa-css-prefix}-user-md:before { content: $fa-var-user-md; } .#{$fa-css-prefix}-stethoscope:before { content: $fa-var-stethoscope; } .#{$fa-css-prefix}-suitcase:before { content: $fa-var-suitcase; } .#{$fa-css-prefix}-bell-o:before { content: $fa-var-bell-o; } .#{$fa-css-prefix}-coffee:before { content: $fa-var-coffee; } .#{$fa-css-prefix}-cutlery:before { content: $fa-var-cutlery; } .#{$fa-css-prefix}-file-text-o:before { content: $fa-var-file-text-o; } .#{$fa-css-prefix}-building-o:before { content: $fa-var-building-o; } .#{$fa-css-prefix}-hospital-o:before { content: $fa-var-hospital-o; } .#{$fa-css-prefix}-ambulance:before { content: $fa-var-ambulance; } .#{$fa-css-prefix}-medkit:before { content: $fa-var-medkit; } .#{$fa-css-prefix}-fighter-jet:before { content: $fa-var-fighter-jet; } .#{$fa-css-prefix}-beer:before { content: $fa-var-beer; } .#{$fa-css-prefix}-h-square:before { content: $fa-var-h-square; } .#{$fa-css-prefix}-plus-square:before { content: $fa-var-plus-square; } .#{$fa-css-prefix}-angle-double-left:before { content: $fa-var-angle-double-left; } .#{$fa-css-prefix}-angle-double-right:before { content: $fa-var-angle-double-right; } .#{$fa-css-prefix}-angle-double-up:before { content: $fa-var-angle-double-up; } .#{$fa-css-prefix}-angle-double-down:before { content: $fa-var-angle-double-down; } .#{$fa-css-prefix}-angle-left:before { content: $fa-var-angle-left; } .#{$fa-css-prefix}-angle-right:before { content: $fa-var-angle-right; } .#{$fa-css-prefix}-angle-up:before { content: $fa-var-angle-up; } .#{$fa-css-prefix}-angle-down:before { content: $fa-var-angle-down; } .#{$fa-css-prefix}-desktop:before { content: $fa-var-desktop; } .#{$fa-css-prefix}-laptop:before { content: $fa-var-laptop; } .#{$fa-css-prefix}-tablet:before { content: $fa-var-tablet; } .#{$fa-css-prefix}-mobile-phone:before, .#{$fa-css-prefix}-mobile:before { content: $fa-var-mobile; } .#{$fa-css-prefix}-circle-o:before { content: $fa-var-circle-o; } .#{$fa-css-prefix}-quote-left:before { content: $fa-var-quote-left; } .#{$fa-css-prefix}-quote-right:before { content: $fa-var-quote-right; } .#{$fa-css-prefix}-spinner:before { content: $fa-var-spinner; } .#{$fa-css-prefix}-circle:before { content: $fa-var-circle; } .#{$fa-css-prefix}-mail-reply:before, .#{$fa-css-prefix}-reply:before { content: $fa-var-reply; } .#{$fa-css-prefix}-github-alt:before { content: $fa-var-github-alt; } .#{$fa-css-prefix}-folder-o:before { content: $fa-var-folder-o; } .#{$fa-css-prefix}-folder-open-o:before { content: $fa-var-folder-open-o; } .#{$fa-css-prefix}-smile-o:before { content: $fa-var-smile-o; } .#{$fa-css-prefix}-frown-o:before { content: $fa-var-frown-o; } .#{$fa-css-prefix}-meh-o:before { content: $fa-var-meh-o; } .#{$fa-css-prefix}-gamepad:before { content: $fa-var-gamepad; } .#{$fa-css-prefix}-keyboard-o:before { content: $fa-var-keyboard-o; } .#{$fa-css-prefix}-flag-o:before { content: $fa-var-flag-o; } .#{$fa-css-prefix}-flag-checkered:before { content: $fa-var-flag-checkered; } .#{$fa-css-prefix}-terminal:before { content: $fa-var-terminal; } .#{$fa-css-prefix}-code:before { content: $fa-var-code; } .#{$fa-css-prefix}-mail-reply-all:before, .#{$fa-css-prefix}-reply-all:before { content: $fa-var-reply-all; } .#{$fa-css-prefix}-star-half-empty:before, .#{$fa-css-prefix}-star-half-full:before, .#{$fa-css-prefix}-star-half-o:before { content: $fa-var-star-half-o; } .#{$fa-css-prefix}-location-arrow:before { content: $fa-var-location-arrow; } .#{$fa-css-prefix}-crop:before { content: $fa-var-crop; } .#{$fa-css-prefix}-code-fork:before { content: $fa-var-code-fork; } .#{$fa-css-prefix}-unlink:before, .#{$fa-css-prefix}-chain-broken:before { content: $fa-var-chain-broken; } .#{$fa-css-prefix}-question:before { content: $fa-var-question; } .#{$fa-css-prefix}-info:before { content: $fa-var-info; } .#{$fa-css-prefix}-exclamation:before { content: $fa-var-exclamation; } .#{$fa-css-prefix}-superscript:before { content: $fa-var-superscript; } .#{$fa-css-prefix}-subscript:before { content: $fa-var-subscript; } .#{$fa-css-prefix}-eraser:before { content: $fa-var-eraser; } .#{$fa-css-prefix}-puzzle-piece:before { content: $fa-var-puzzle-piece; } .#{$fa-css-prefix}-microphone:before { content: $fa-var-microphone; } .#{$fa-css-prefix}-microphone-slash:before { content: $fa-var-microphone-slash; } .#{$fa-css-prefix}-shield:before { content: $fa-var-shield; } .#{$fa-css-prefix}-calendar-o:before { content: $fa-var-calendar-o; } .#{$fa-css-prefix}-fire-extinguisher:before { content: $fa-var-fire-extinguisher; } .#{$fa-css-prefix}-rocket:before { content: $fa-var-rocket; } .#{$fa-css-prefix}-maxcdn:before { content: $fa-var-maxcdn; } .#{$fa-css-prefix}-chevron-circle-left:before { content: $fa-var-chevron-circle-left; } .#{$fa-css-prefix}-chevron-circle-right:before { content: $fa-var-chevron-circle-right; } .#{$fa-css-prefix}-chevron-circle-up:before { content: $fa-var-chevron-circle-up; } .#{$fa-css-prefix}-chevron-circle-down:before { content: $fa-var-chevron-circle-down; } .#{$fa-css-prefix}-html5:before { content: $fa-var-html5; } .#{$fa-css-prefix}-css3:before { content: $fa-var-css3; } .#{$fa-css-prefix}-anchor:before { content: $fa-var-anchor; } .#{$fa-css-prefix}-unlock-alt:before { content: $fa-var-unlock-alt; } .#{$fa-css-prefix}-bullseye:before { content: $fa-var-bullseye; } .#{$fa-css-prefix}-ellipsis-h:before { content: $fa-var-ellipsis-h; } .#{$fa-css-prefix}-ellipsis-v:before { content: $fa-var-ellipsis-v; } .#{$fa-css-prefix}-rss-square:before { content: $fa-var-rss-square; } .#{$fa-css-prefix}-play-circle:before { content: $fa-var-play-circle; } .#{$fa-css-prefix}-ticket:before { content: $fa-var-ticket; } .#{$fa-css-prefix}-minus-square:before { content: $fa-var-minus-square; } .#{$fa-css-prefix}-minus-square-o:before { content: $fa-var-minus-square-o; } .#{$fa-css-prefix}-level-up:before { content: $fa-var-level-up; } .#{$fa-css-prefix}-level-down:before { content: $fa-var-level-down; } .#{$fa-css-prefix}-check-square:before { content: $fa-var-check-square; } .#{$fa-css-prefix}-pencil-square:before { content: $fa-var-pencil-square; } .#{$fa-css-prefix}-external-link-square:before { content: $fa-var-external-link-square; } .#{$fa-css-prefix}-share-square:before { content: $fa-var-share-square; } .#{$fa-css-prefix}-compass:before { content: $fa-var-compass; } .#{$fa-css-prefix}-toggle-down:before, .#{$fa-css-prefix}-caret-square-o-down:before { content: $fa-var-caret-square-o-down; } .#{$fa-css-prefix}-toggle-up:before, .#{$fa-css-prefix}-caret-square-o-up:before { content: $fa-var-caret-square-o-up; } .#{$fa-css-prefix}-toggle-right:before, .#{$fa-css-prefix}-caret-square-o-right:before { content: $fa-var-caret-square-o-right; } .#{$fa-css-prefix}-euro:before, .#{$fa-css-prefix}-eur:before { content: $fa-var-eur; } .#{$fa-css-prefix}-gbp:before { content: $fa-var-gbp; } .#{$fa-css-prefix}-dollar:before, .#{$fa-css-prefix}-usd:before { content: $fa-var-usd; } .#{$fa-css-prefix}-rupee:before, .#{$fa-css-prefix}-inr:before { content: $fa-var-inr; } .#{$fa-css-prefix}-cny:before, .#{$fa-css-prefix}-rmb:before, .#{$fa-css-prefix}-yen:before, .#{$fa-css-prefix}-jpy:before { content: $fa-var-jpy; } .#{$fa-css-prefix}-ruble:before, .#{$fa-css-prefix}-rouble:before, .#{$fa-css-prefix}-rub:before { content: $fa-var-rub; } .#{$fa-css-prefix}-won:before, .#{$fa-css-prefix}-krw:before { content: $fa-var-krw; } .#{$fa-css-prefix}-bitcoin:before, .#{$fa-css-prefix}-btc:before { content: $fa-var-btc; } .#{$fa-css-prefix}-file:before { content: $fa-var-file; } .#{$fa-css-prefix}-file-text:before { content: $fa-var-file-text; } .#{$fa-css-prefix}-sort-alpha-asc:before { content: $fa-var-sort-alpha-asc; } .#{$fa-css-prefix}-sort-alpha-desc:before { content: $fa-var-sort-alpha-desc; } .#{$fa-css-prefix}-sort-amount-asc:before { content: $fa-var-sort-amount-asc; } .#{$fa-css-prefix}-sort-amount-desc:before { content: $fa-var-sort-amount-desc; } .#{$fa-css-prefix}-sort-numeric-asc:before { content: $fa-var-sort-numeric-asc; } .#{$fa-css-prefix}-sort-numeric-desc:before { content: $fa-var-sort-numeric-desc; } .#{$fa-css-prefix}-thumbs-up:before { content: $fa-var-thumbs-up; } .#{$fa-css-prefix}-thumbs-down:before { content: $fa-var-thumbs-down; } .#{$fa-css-prefix}-youtube-square:before { content: $fa-var-youtube-square; } .#{$fa-css-prefix}-youtube:before { content: $fa-var-youtube; } .#{$fa-css-prefix}-xing:before { content: $fa-var-xing; } .#{$fa-css-prefix}-xing-square:before { content: $fa-var-xing-square; } .#{$fa-css-prefix}-youtube-play:before { content: $fa-var-youtube-play; } .#{$fa-css-prefix}-dropbox:before { content: $fa-var-dropbox; } .#{$fa-css-prefix}-stack-overflow:before { content: $fa-var-stack-overflow; } .#{$fa-css-prefix}-instagram:before { content: $fa-var-instagram; } .#{$fa-css-prefix}-flickr:before { content: $fa-var-flickr; } .#{$fa-css-prefix}-adn:before { content: $fa-var-adn; } .#{$fa-css-prefix}-bitbucket:before { content: $fa-var-bitbucket; } .#{$fa-css-prefix}-bitbucket-square:before { content: $fa-var-bitbucket-square; } .#{$fa-css-prefix}-tumblr:before { content: $fa-var-tumblr; } .#{$fa-css-prefix}-tumblr-square:before { content: $fa-var-tumblr-square; } .#{$fa-css-prefix}-long-arrow-down:before { content: $fa-var-long-arrow-down; } .#{$fa-css-prefix}-long-arrow-up:before { content: $fa-var-long-arrow-up; } .#{$fa-css-prefix}-long-arrow-left:before { content: $fa-var-long-arrow-left; } .#{$fa-css-prefix}-long-arrow-right:before { content: $fa-var-long-arrow-right; } .#{$fa-css-prefix}-apple:before { content: $fa-var-apple; } .#{$fa-css-prefix}-windows:before { content: $fa-var-windows; } .#{$fa-css-prefix}-android:before { content: $fa-var-android; } .#{$fa-css-prefix}-linux:before { content: $fa-var-linux; } .#{$fa-css-prefix}-dribbble:before { content: $fa-var-dribbble; } .#{$fa-css-prefix}-skype:before { content: $fa-var-skype; } .#{$fa-css-prefix}-foursquare:before { content: $fa-var-foursquare; } .#{$fa-css-prefix}-trello:before { content: $fa-var-trello; } .#{$fa-css-prefix}-female:before { content: $fa-var-female; } .#{$fa-css-prefix}-male:before { content: $fa-var-male; } .#{$fa-css-prefix}-gittip:before { content: $fa-var-gittip; } .#{$fa-css-prefix}-sun-o:before { content: $fa-var-sun-o; } .#{$fa-css-prefix}-moon-o:before { content: $fa-var-moon-o; } .#{$fa-css-prefix}-archive:before { content: $fa-var-archive; } .#{$fa-css-prefix}-bug:before { content: $fa-var-bug; } .#{$fa-css-prefix}-vk:before { content: $fa-var-vk; } .#{$fa-css-prefix}-weibo:before { content: $fa-var-weibo; } .#{$fa-css-prefix}-renren:before { content: $fa-var-renren; } .#{$fa-css-prefix}-pagelines:before { content: $fa-var-pagelines; } .#{$fa-css-prefix}-stack-exchange:before { content: $fa-var-stack-exchange; } .#{$fa-css-prefix}-arrow-circle-o-right:before { content: $fa-var-arrow-circle-o-right; } .#{$fa-css-prefix}-arrow-circle-o-left:before { content: $fa-var-arrow-circle-o-left; } .#{$fa-css-prefix}-toggle-left:before, .#{$fa-css-prefix}-caret-square-o-left:before { content: $fa-var-caret-square-o-left; } .#{$fa-css-prefix}-dot-circle-o:before { content: $fa-var-dot-circle-o; } .#{$fa-css-prefix}-wheelchair:before { content: $fa-var-wheelchair; } .#{$fa-css-prefix}-vimeo-square:before { content: $fa-var-vimeo-square; } .#{$fa-css-prefix}-turkish-lira:before, .#{$fa-css-prefix}-try:before { content: $fa-var-try; } .#{$fa-css-prefix}-plus-square-o:before { content: $fa-var-plus-square-o; } .#{$fa-css-prefix}-space-shuttle:before { content: $fa-var-space-shuttle; } .#{$fa-css-prefix}-slack:before { content: $fa-var-slack; } .#{$fa-css-prefix}-envelope-square:before { content: $fa-var-envelope-square; } .#{$fa-css-prefix}-wordpress:before { content: $fa-var-wordpress; } .#{$fa-css-prefix}-openid:before { content: $fa-var-openid; } .#{$fa-css-prefix}-institution:before, .#{$fa-css-prefix}-bank:before, .#{$fa-css-prefix}-university:before { content: $fa-var-university; } .#{$fa-css-prefix}-mortar-board:before, .#{$fa-css-prefix}-graduation-cap:before { content: $fa-var-graduation-cap; } .#{$fa-css-prefix}-yahoo:before { content: $fa-var-yahoo; } .#{$fa-css-prefix}-google:before { content: $fa-var-google; } .#{$fa-css-prefix}-reddit:before { content: $fa-var-reddit; } .#{$fa-css-prefix}-reddit-square:before { content: $fa-var-reddit-square; } .#{$fa-css-prefix}-stumbleupon-circle:before { content: $fa-var-stumbleupon-circle; } .#{$fa-css-prefix}-stumbleupon:before { content: $fa-var-stumbleupon; } .#{$fa-css-prefix}-delicious:before { content: $fa-var-delicious; } .#{$fa-css-prefix}-digg:before { content: $fa-var-digg; } .#{$fa-css-prefix}-pied-piper:before { content: $fa-var-pied-piper; } .#{$fa-css-prefix}-pied-piper-alt:before { content: $fa-var-pied-piper-alt; } .#{$fa-css-prefix}-drupal:before { content: $fa-var-drupal; } .#{$fa-css-prefix}-joomla:before { content: $fa-var-joomla; } .#{$fa-css-prefix}-language:before { content: $fa-var-language; } .#{$fa-css-prefix}-fax:before { content: $fa-var-fax; } .#{$fa-css-prefix}-building:before { content: $fa-var-building; } .#{$fa-css-prefix}-child:before { content: $fa-var-child; } .#{$fa-css-prefix}-paw:before { content: $fa-var-paw; } .#{$fa-css-prefix}-spoon:before { content: $fa-var-spoon; } .#{$fa-css-prefix}-cube:before { content: $fa-var-cube; } .#{$fa-css-prefix}-cubes:before { content: $fa-var-cubes; } .#{$fa-css-prefix}-behance:before { content: $fa-var-behance; } .#{$fa-css-prefix}-behance-square:before { content: $fa-var-behance-square; } .#{$fa-css-prefix}-steam:before { content: $fa-var-steam; } .#{$fa-css-prefix}-steam-square:before { content: $fa-var-steam-square; } .#{$fa-css-prefix}-recycle:before { content: $fa-var-recycle; } .#{$fa-css-prefix}-automobile:before, .#{$fa-css-prefix}-car:before { content: $fa-var-car; } .#{$fa-css-prefix}-cab:before, .#{$fa-css-prefix}-taxi:before { content: $fa-var-taxi; } .#{$fa-css-prefix}-tree:before { content: $fa-var-tree; } .#{$fa-css-prefix}-spotify:before { content: $fa-var-spotify; } .#{$fa-css-prefix}-deviantart:before { content: $fa-var-deviantart; } .#{$fa-css-prefix}-soundcloud:before { content: $fa-var-soundcloud; } .#{$fa-css-prefix}-database:before { content: $fa-var-database; } .#{$fa-css-prefix}-file-pdf-o:before { content: $fa-var-file-pdf-o; } .#{$fa-css-prefix}-file-word-o:before { content: $fa-var-file-word-o; } .#{$fa-css-prefix}-file-excel-o:before { content: $fa-var-file-excel-o; } .#{$fa-css-prefix}-file-powerpoint-o:before { content: $fa-var-file-powerpoint-o; } .#{$fa-css-prefix}-file-photo-o:before, .#{$fa-css-prefix}-file-picture-o:before, .#{$fa-css-prefix}-file-image-o:before { content: $fa-var-file-image-o; } .#{$fa-css-prefix}-file-zip-o:before, .#{$fa-css-prefix}-file-archive-o:before { content: $fa-var-file-archive-o; } .#{$fa-css-prefix}-file-sound-o:before, .#{$fa-css-prefix}-file-audio-o:before { content: $fa-var-file-audio-o; } .#{$fa-css-prefix}-file-movie-o:before, .#{$fa-css-prefix}-file-video-o:before { content: $fa-var-file-video-o; } .#{$fa-css-prefix}-file-code-o:before { content: $fa-var-file-code-o; } .#{$fa-css-prefix}-vine:before { content: $fa-var-vine; } .#{$fa-css-prefix}-codepen:before { content: $fa-var-codepen; } .#{$fa-css-prefix}-jsfiddle:before { content: $fa-var-jsfiddle; } .#{$fa-css-prefix}-life-bouy:before, .#{$fa-css-prefix}-life-buoy:before, .#{$fa-css-prefix}-life-saver:before, .#{$fa-css-prefix}-support:before, .#{$fa-css-prefix}-life-ring:before { content: $fa-var-life-ring; } .#{$fa-css-prefix}-circle-o-notch:before { content: $fa-var-circle-o-notch; } .#{$fa-css-prefix}-ra:before, .#{$fa-css-prefix}-rebel:before { content: $fa-var-rebel; } .#{$fa-css-prefix}-ge:before, .#{$fa-css-prefix}-empire:before { content: $fa-var-empire; } .#{$fa-css-prefix}-git-square:before { content: $fa-var-git-square; } .#{$fa-css-prefix}-git:before { content: $fa-var-git; } .#{$fa-css-prefix}-hacker-news:before { content: $fa-var-hacker-news; } .#{$fa-css-prefix}-tencent-weibo:before { content: $fa-var-tencent-weibo; } .#{$fa-css-prefix}-qq:before { content: $fa-var-qq; } .#{$fa-css-prefix}-wechat:before, .#{$fa-css-prefix}-weixin:before { content: $fa-var-weixin; } .#{$fa-css-prefix}-send:before, .#{$fa-css-prefix}-paper-plane:before { content: $fa-var-paper-plane; } .#{$fa-css-prefix}-send-o:before, .#{$fa-css-prefix}-paper-plane-o:before { content: $fa-var-paper-plane-o; } .#{$fa-css-prefix}-history:before { content: $fa-var-history; } .#{$fa-css-prefix}-circle-thin:before { content: $fa-var-circle-thin; } .#{$fa-css-prefix}-header:before { content: $fa-var-header; } .#{$fa-css-prefix}-paragraph:before { content: $fa-var-paragraph; } .#{$fa-css-prefix}-sliders:before { content: $fa-var-sliders; } .#{$fa-css-prefix}-share-alt:before { content: $fa-var-share-alt; } .#{$fa-css-prefix}-share-alt-square:before { content: $fa-var-share-alt-square; } .#{$fa-css-prefix}-bomb:before { content: $fa-var-bomb; } .#{$fa-css-prefix}-soccer-ball-o:before, .#{$fa-css-prefix}-futbol-o:before { content: $fa-var-futbol-o; } .#{$fa-css-prefix}-tty:before { content: $fa-var-tty; } .#{$fa-css-prefix}-binoculars:before { content: $fa-var-binoculars; } .#{$fa-css-prefix}-plug:before { content: $fa-var-plug; } .#{$fa-css-prefix}-slideshare:before { content: $fa-var-slideshare; } .#{$fa-css-prefix}-twitch:before { content: $fa-var-twitch; } .#{$fa-css-prefix}-yelp:before { content: $fa-var-yelp; } .#{$fa-css-prefix}-newspaper-o:before { content: $fa-var-newspaper-o; } .#{$fa-css-prefix}-wifi:before { content: $fa-var-wifi; } .#{$fa-css-prefix}-calculator:before { content: $fa-var-calculator; } .#{$fa-css-prefix}-paypal:before { content: $fa-var-paypal; } .#{$fa-css-prefix}-google-wallet:before { content: $fa-var-google-wallet; } .#{$fa-css-prefix}-cc-visa:before { content: $fa-var-cc-visa; } .#{$fa-css-prefix}-cc-mastercard:before { content: $fa-var-cc-mastercard; } .#{$fa-css-prefix}-cc-discover:before { content: $fa-var-cc-discover; } .#{$fa-css-prefix}-cc-amex:before { content: $fa-var-cc-amex; } .#{$fa-css-prefix}-cc-paypal:before { content: $fa-var-cc-paypal; } .#{$fa-css-prefix}-cc-stripe:before { content: $fa-var-cc-stripe; } .#{$fa-css-prefix}-bell-slash:before { content: $fa-var-bell-slash; } .#{$fa-css-prefix}-bell-slash-o:before { content: $fa-var-bell-slash-o; } .#{$fa-css-prefix}-trash:before { content: $fa-var-trash; } .#{$fa-css-prefix}-copyright:before { content: $fa-var-copyright; } .#{$fa-css-prefix}-at:before { content: $fa-var-at; } .#{$fa-css-prefix}-eyedropper:before { content: $fa-var-eyedropper; } .#{$fa-css-prefix}-paint-brush:before { content: $fa-var-paint-brush; } .#{$fa-css-prefix}-birthday-cake:before { content: $fa-var-birthday-cake; } .#{$fa-css-prefix}-area-chart:before { content: $fa-var-area-chart; } .#{$fa-css-prefix}-pie-chart:before { content: $fa-var-pie-chart; } .#{$fa-css-prefix}-line-chart:before { content: $fa-var-line-chart; } .#{$fa-css-prefix}-lastfm:before { content: $fa-var-lastfm; } .#{$fa-css-prefix}-lastfm-square:before { content: $fa-var-lastfm-square; } .#{$fa-css-prefix}-toggle-off:before { content: $fa-var-toggle-off; } .#{$fa-css-prefix}-toggle-on:before { content: $fa-var-toggle-on; } .#{$fa-css-prefix}-bicycle:before { content: $fa-var-bicycle; } .#{$fa-css-prefix}-bus:before { content: $fa-var-bus; } .#{$fa-css-prefix}-ioxhost:before { content: $fa-var-ioxhost; } .#{$fa-css-prefix}-angellist:before { content: $fa-var-angellist; } .#{$fa-css-prefix}-cc:before { content: $fa-var-cc; } .#{$fa-css-prefix}-shekel:before, .#{$fa-css-prefix}-sheqel:before, .#{$fa-css-prefix}-ils:before { content: $fa-var-ils; } .#{$fa-css-prefix}-meanpath:before { content: $fa-var-meanpath; }
{ "pile_set_name": "Github" }
/************* Reset Styles *************/ html,body,div,span,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,abbr,address,cite,code,del,dfn,em,img,ins,kbd,q,samp,small,strong,sub,sup,var,b,i,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,figcaption,figure,footer,header,hgroup,menu,nav,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;outline:0;font-size:100%;vertical-align:baseline;}body{line-height:1}article,aside,details,figcaption,figure,footer,header,hgroup,menu,nav,section{display:block}nav ul{list-style:none}blockquote,q{quotes:none}blockquote:before,blockquote:after,q:before,q:after{content:none}a{margin:0;padding:0;font-size:100%;vertical-align:baseline;}ins{color:#000;text-decoration:none}mark{color:#000;font-style:italic;font-weight:bold}del{text-decoration:line-through}abbr[title],dfn[title]{border-bottom:1px dotted;cursor:help}table{border-collapse:collapse;border-spacing:0}hr{display:block;height:1px;border:0;border-top:1px solid #ccc;margin:1em 0;padding:0}input,select{vertical-align:middle} /************* Helper Styles *************/ .text-white{ color: #fff; } .vhq{ transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; } .left-mrv{ float: left; } .vix{ float: right; } .vih{ display: none !important; } .vig{ width: 100% !important; } .vdw { outline: 1px solid #333 !important; } .mail-list-form { display: none !important; } .vaz{ display: none !important; } .ui-sortable div, .vjd > li { cursor: move; } .subnav { cursor: pointer; } .vje { background-color: #eee; outline: 1px dashed #ccc; display: inline-block; float: left !important; border-radius: 10px; opacity: 0.7 } body [contenteditable] { cursor: text; } .vba{ opacity: 0 !important; } /* Allows hovering on email-forms to edit the success and failure messages. */ .email-form:hover .form-success, .email-form:hover .form-error{ opacity: 1 !important; display: block !important; } .vle { -webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; } /************* Icon Styles *************/ .vaa:before, .vaa span.vhz:before, .vca:before, .vly:before, .vly:after, .vma:after { font-family: 'Icons'; display: inline-block; speak: none; line-height: 1; vertical-align: baseline; font-weight: normal; font-style: normal; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } /************* Structure Styles *************/ .vhv{ overflow: hidden; font-smoothing: antialiased; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; } .vjc{ opacity: 1; width: 48px; height: 100%; position: fixed; left: 0px; color: #666666; font-size: 15px; z-index: 200; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.26); opacity: 1; } .vjc ul{ margin: 0px; padding: 0px; list-style: none; overflow: hidden; } @media all and (max-height: 800px){ .vjc{ font-size: 13px; } } .viu{ padding-left: 48px; overflow-x: hidden; width: 100%; height: 100%; position: absolute; right: 0px; background: #eee; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; overflow-y: scroll} .vjc, .vin, .vjq, .vhe, .vjr{ font-family: 'Roboto',"Helvetica Neue", "Helvetica", Helvetica, "Arimo", Arial, sans-serif !important; } /************* Button Styles *************/ .vhs{ display: inline-block; text-align: center; font-size: 13px; font-weight: 500; cursor: pointer; height: 32px; line-height: 32px; text-transform: uppercase; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease;-webkit-touch-callout: none; -webkit-user-select: none; -khtml-user-select: none; -moz-user-select: none; -ms-user-select: none; user-select: none; } .vhm{ text-align: center; width: 320px; position: relative; top: 50%; transform: translateY(-50%); -webkit-transform: translateY(-50%); margin: 0 auto; } .vhe{ display: inline-block; width: 100%; height: 180px; padding: 12px; font-size: 20px; font-weight: normal; color: #aaa; border: 1px dashed #aaa; margin-bottom: 32px; cursor: pointer; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; } .vhe span{ display: block; position: relative; top: 50%; -webkit-transform: translateY(-50%); -ms-transform: translateY(-50%); transform: translateY(-50%); } .vhe:last-child{ margin-bottom: 0px; } .vhe:hover{ background: rgba(255,255,255,0.4); } /************* Sidebar Styles *************/ .vkm{ background: #e9ecf1; height: 100%; position: absolute; margin-left: 48px; overflow: hidden; width: 288px; top: 0; transition: all .3s ease; -webkit-transition: all .3s ease; -moz-transition: all .3s ease; transform: translateX(-288px); -webkit-transform: translateX(-288px); box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.26); opacity: 0; } .vkm.vkl{ transform: translateX(0px); -webkit-transform: translateX(0px); } .vjc:hover .vkm{ transform: translateX(0px); -webkit-transform: translateX(0px); opacity: .94; } .vgx{ height: 100%; width: 288px; overflow: hidden; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; position: absolute; top: 0; } .vll{ position: absolute; bottom: 0; left: 0; } .vlv, .vlo, .vmb{ position: absolute; top: 0; width: 288px; float: left; height: 100%; transition: all .3s ease; -webkit-transition: all .3s ease; -moz-transition: all .3s ease; -webkit-backface-visibility: hidden; } .vlp{ opacity: 0; z-index: -1; } .vlp.vhr{ opacity: 1 !important; z-index: 1; } .vlf{ width: 48px; overflow: hidden; background: #2b2b2b; height: 100%; line-height: 48px; box-shadow: 0 8px 17px 0 rgba(0, 0, 0, 0.2); position: relative; z-index: 99; position: relative; } .vlf li{ height: 48px; line-height: 55px; text-align: center; cursor: pointer; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; color: #fff; opacity: 0.6; } .vlf .oi{ font-size: 20px; color: #fff; } .vlf li.vhr{ opacity: 1; background: #4c4c4c; } .vlf li:hover{ opacity: 1; } @media all and (max-height: 800px){ .vlf .oi{ font-size: 18px; } } .vlq{ height: 64px; line-height: 64px; font-size: 15px; font-weight: 500; color: #333; padding: 0 32px; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; text-transform: capitalize; } @media all and (max-height: 800px){ .vlq{ height: 48px; line-height: 48px; } } .vlw{ margin: 0 16px; height: 48px; line-height: 48px; position: relative; padding: 0 16px; box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.26); background: #fff; margin-bottom: 32px; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; overflow: hidden; } .vlw .vei{ opacity: 0.5; width: 208px; display: inline-block; overflow: hidden; height: 48px; line-height: 48px; white-space: nowrap; } .vlw .vei:focus{ opacity: 1; } .vlw .oi{ font-size: 18px; margin-top: 3px; float: right; position: absolute; } @media all and (max-height: 800px){ .vlw{ height: 32px; line-height: 32px; margin-bottom: 16px; } .vlw .vei{ height: 32px; line-height: 32px; } } .vmd{ background: #fff; width: 100%; padding: 16px 0; position: relative; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; } @media all and (max-height: 800px){ .vmd{ padding: 8px 0; } } .sidebar-padding{ padding: 24px; display: inline-block; } .vjz, .vka, .vme, .vkc{ opacity: .94 !important; transform: translateX(0px) !important; -webkit-transform: translateX(0px) !important; -moz-transform: translateX(0px) !important; } .vgu{ padding: 11px 24px; position: relative; overflow: hidden; opacity: 0.7; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; } .vgu:hover{ opacity: 1; background: #383E47; } .vgu .variant-pen{ float: right; cursor: pointer; position: relative; top: 2px; } .vfp{ cursor: pointer; cursor: pointer; transform: rotate(0deg); } .vei{ font-weight: 500; } .vho{ padding: 0 32px; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; overflow: hidden; } .vho span{ position: relative; cursor: pointer; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; } .vly{ display: block; height: 40px; line-height: 40px; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; } .vly:before{ font-size: 16px; margin-right: 16px; position: relative; top: 2px; } .vly:after{ font-size: 10px; opacity: .8; float:right; position: relative; top: 16px; content: '\e034'; } @media all and (max-height: 800px){ .vly{ height: 32px; line-height: 32px; } .vly:before{ font-size: 15px; top: 3px; } .vly:after{ font-size: 10px; top: 11px; } } .vho ul{ transition: all .4s ease; -webkit-transition: all .4s ease; -moz-transition: all .4s ease; max-height: 0px; } .vho li{ height: 40px; line-height: 40px; padding-left: 34px; cursor: pointer; overflow: hidden; position: relative; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; } .vho li:first-child{ } .vho li:hover{ color: #60A0B3; } .vho.vhr .vly{ color: #60A0B3; } .vho.vhr .vly .oi[data-glyph="chevron-bottom"]:before{ content:'\e037'; } .vho.vhr ul{ max-height: 800px; } .vho.vhr .vfn{ margin-bottom: 16px; } @media all and (max-height: 800px){ .vho li{ height: 32px; line-height: 32px; } } .vby, .vbx{ float: right; height: 48px; line-height: 48px; font-size: 13px; color: #b71a1a; cursor: pointer; } .vho li:hover .vby, .vho li:hover .vbx{ transform: translateX(0px); -webkit-transform: translateX(0px); -moz-transform: translateX(0px); } .vay{ overflow-y: auto !important; } .vho .vax{ float: left; height: 12px;} .vay span{ margin: 0px; padding: 0px; display: none; } .vay li { margin-bottom: 16px; padding-left: 32px !important; height: 12px; } .vac{ transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; z-index: 99; text-align: center; width: 64px; height: 64px; border-radius: 50%; background: #60A0B3; color: #fff; line-height: 60px; cursor: pointer; position: absolute; bottom: -32px; right: 32px; box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.26); } .vac span{ display: inline-block; margin-left: 1px; margin-top: 1px; } .vac span:before{ content: '+'; font-size: 32px; } .vem{ width: 100%; height-auto; overflow-y: auto; min-height: 128px; margin-top: 16px; padding: 16px 0; border-top: 1px solid rgba(0,0,0,0.12); transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; position: relative; } .vem.empty-vem:before{ content: 'NO BLOCKS ADDED'; font-size: 12px; font-weight: 500; position: absolute; width: 100%; top: 50%; text-align: center; color: #333; opacity: .4; margin-top: -6px; } .vaa{ cursor: move; padding: 0 32px; position: relative; height: 40px; line-height: 40px; overflow-x: hidden; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; -o-text-overflow: ellipsis; } .vaa:before{ content:'\e071'; position: relative; bottom: 14px; margin-right: 16px; opacity: 0.5; } .vaa span{ font-size: 15px; } .vab{ display: inline-block; max-width: 170px; overflow: hidden; } .vab span{ text-overflow: ellipsis; cursor: text; padding-right: 8px; } @media all and (max-height: 800px){ .vaa{ height: 32px; line-height: 32px; } .vaa:before{ bottom: 12px; } .vaa span{ font-size: 13px; } } .vaa span.vhz:before{ content:'\e048'; margin-right: 16px; display: inline-block; position: relative; top: 2px; } .vaa span.vir:before{ content: ''; } .vaa span:focus{ z-index: 9999 } .vca{ position: absolute; right: 36px; height: 40px; width: 15px; line-height: 40px; top: 0px; font-size: 13px; text-align: right; cursor: pointer; transform: translateX(100px); -webkit-transform: translateX(100px); -moz-transform: translateX(100px); } .vca:before{ content:'\e0db'; font-size: 13px; color: #b71a1a; } .vaa:hover .vca{ transform: translateX(0px); -webkit-transform: translateX(0px); -moz-transform: translateX(0px); } .vmf{ transform: translate3d(0,-257px,0); -webkit-transform: translate3d(0,-257px,0); } .vmf .vem{ padding-bottom: 0; min-height: 120px !important; max-height: 120px !important; border-color: #fff !important; } .vmf .vem:hover{ max-height: 500px !important; } .vmf .vad{ opacity: 1 !important; } .vmf .vls{ transform: translate3d(0,257px,0); -webkit-transform: translate3d(0,257px,0); box-shadow: 0px 0px 48px 48px #e9ecf1; z-index: 999; } .vmf .vac{ transform: rotate(44deg) scale(0.7); -webkit-transform: rotate(44deg) scale(0.7); background: #b71a1a; } .vmf .vac span{ position: relative; right: 0px; } .vmf .vad:before{ width: 0; height: 0; } .vmf .vgm{ transform: translate3d(0,0px,0); -webkit-transform: translate3d(0,0px,0); } .vmf .vgr{ display: none; } @media all and (max-height: 800px){ .vmf{ transform: translate3d(0,-185px,0); -webkit-transform: translate3d(0,-185px,0); } .vmf .vls{ transform: translate3d(0,185px,0); -webkit-transform: translate3d(0,185px,0); } } .vls{ background: #e9ecf1; width: 288px; line-height: 48px; height: 48px; position: absolute; bottom: 0; z-index: 99; text-align: center; opacity: 1; transition: all .3s ease; -webkit-transition: all .3s ease; -moz-transition: all .3s ease; -webkit-backface-visibility: hidden; } .vlm, .vgw{ width: 48px; text-align: center; height: 48px; line-height: 48px; font-size: 18px; color: #fff; opacity: 0.5; top: 0; cursor: pointer; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; } .vlm:hover, .vgw:hover{ opacity: 1; } .vgw.vmg{ opacity: 1; } .vgw.vmg .oi:before{ content:'\e08a'; } .vdq{ display: inline-block; color: #333; height:48px; line-height: 48px; font-size: 15px; text-transform: uppercase; font-weight: 500; cursor: pointer; } .vgr, .vdv{ font-size: 13px; text-transform: uppercase; font-weight: 500; margin-top: 16px; margin-left: 32px; cursor: pointer; height: 16px; line-height: 16px; opacity: .4; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; position: absolute; z-index: 99; } .vgr .oi, .vdv .oi{ position: relative; top: 1px; } .vgr:hover{ opacity: 1; } .vgr.vhr, .vdv.vhr{ opacity: 1; } .vlo .vgc{ margin-left: 32px; } .vlo .ved{ float: right; margin-right: 32px; } .vlo .vlt{ font-size: 15px; color: #333; font-weight: 500; text-transform: uppercase; height: 48px; line-height: 48px; cursor: pointer; } .vlo .vlt .oi{ font-size: 10px; position: relative; margin-left: 4px; } .vlu{ position: absolute; width: 152px; background: #fff; border-radius: 2px; box-shadow: 0 2px 10px 0 rgba(0, 0, 0, 0.16), 0 2px 5px 0 rgba(0, 0, 0, 0.26); margin-left: 76px; z-index: 101; bottom: 44px; transition: all .2s ease; -webkit-transition: all .2s ease; -moz-transition: all .2s ease; transform: scale(0); opacity: 0; } .vlt:hover .vlu{ transform: scale(1); opacity: 1; } .vlu .vhs{ color: #666; width: 100%; height: 48px; line-height: 48px; transition: all .2s ease; -webkit-transition: all .2s ease; -moz-transition: all .2s ease; } .vlu .vhs:hover{ color: #60A0B3; } /************* Modal Styles *************/ .vjq{ display: none; width: 350px; background: rgba(47,52,60,0.9); height: 100%; overflow: hidden; position: absolute; left: 250px; border-left: 1px solid rgba(255,255,255,0.2); font-size: 14px; transform: translateX(-600px); -webkit-transform: translateX(-600px); -moz-transform: translateX(-600px); transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; z-index: 100; } .vhn{ padding-top: 24px; border-top: 1px solid rgba(255,255,255,0.2); } .vhn .vhs{ margin-bottom: 24px; } .vfw{ max-height: 400px; overflow-y: auto; min-height: 128px; } .empty-vfw:before{ content: 'NO SAVED PAGES'; font-size: 12px; font-weight: 500; position: absolute; width: 100%; top: 50%; text-align: center; color: #333; opacity: .4; margin-top: -9px; } .ves{ height: 40px; line-height: 40px; padding: 0 32px; cursor: pointer; } @media all and (max-height: 800px){ .ves{ height: 32px; line-height: 32px; } } .vef{ width: 0px; height: 0px; overflow: hidden; } .vbz, .vdj{ cursor: pointer; } .vdj{ margin-right: 16px; position: relative; top: 4px; font-size: 18px; color: #60A0B3; } .vbz{ float: right; font-size: 13px; color: #b71a1a; display: none; } .ves:hover .vbz{ display: block; } .vad{ opacity: 0; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; position: relative; } .vad:before{ content: ''; width: 100%; height: 100%; z-index: 10; cursor: default; position: absolute; } .vlz{ height: 48px; position: relative; width: 100%; text-align: center; box-shadow: 0px 2px 5px 0 rgba(0, 0, 0, 0.26); z-index: 101; background: #60A0B3; } .vma{ font-weight: 500; font-size: 15px; text-transform: uppercase; display: inline-block; text-align: center; height: 48px; line-height: 48px; cursor: pointer; color: #fff; transition: all .2s ease; -webkit-transition: all .2s ease; -moz-transition: all .2s ease; } .vma:after{ content: '\e02d'; font-size: 10px; } .vma.vhr, .vma:hover{ color: #fff; } .vgi{ position: absolute; width: 240px; background: #fff; overflow: hidden; top: 48px; z-index: 101; margin-left: 32px; border-radius: 2px; box-shadow: 0 2px 10px 0 rgba(0, 0, 0, 0.16), 0 2px 5px 0 rgba(0, 0, 0, 0.26); transition: all .2s ease; -webkit-transition: all .2s ease; -moz-transition: all .2s ease; transform: scale(0); -webkit-transform: scale(0); opacity: 0; } .vgh{ width: 50%; float: left; height: 40px; line-height: 40px; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; text-transform: capitalize; text-align: left; padding-left: 32px; cursor: pointer; } .vgh.vhr{ color: #60A0B3; } .vgh:hover{ color: #60A0B3; } .vgi.vhr{ transform: scale(1); -webkit-transform: scale(1); opacity: 1; } @media all and (max-height: 800px){ .vgh{ height: 32px; line-height: 32px; } } .vgm{ height: 0px; overflow-y: auto; overflow-x: hidden; transform: translate3d(0,200px,0); transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; } .vgl{ cursor: pointer; margin: 16px 32px 0px 32px; position: relative; transition: all .2s ease; -webkit-transition: all .2s ease; -moz-transition: all .2s ease; overflow: hidden; } .vgl:first-child{ margin-top: 32px; } .vgl .vjl{ display: block; width: 100%; color: #fff; background: #333; padding: 8px 16px; font-size: 13px; } .vgl img{ width: 100%; } .vgl .vgj{ right: 0; height: 35px; width: auto; position: absolute; bottom: 5px; right: 5px; } .vgl.vih{ display: block !important; height: 0 !important; margin-top: 0; } .vgq{ transform: translateX(0px); -webkit-transform: translateX(0px); -moz-transform: translateX(0px); } .vds{ width: 400px; } .vdo{ width: 455px; } .vcw, .vde{ width: 288px; } .vcl{ width: 592px; } .vin{ -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; background: #fff; display: none; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; box-shadow: 0 8px 17px 0 rgba(0, 0, 0, 0.2); } .vin .vfa{ cursor: move; padding: 0 24px; color: #333; font-weight: 500; font-size: 18px; position: relative; height: 64px; line-height: 64px; } .vin .vew{ padding: 0 24px; } .vin input[type="text"]{ border-radius: 0px !important; background: none !important; max-width: 100% !important; } .vew p{ font-size: 15px; line-height: 24px; } .vew p:last-child{ } .vez{ box-sizing: border-box !important; box-shadow: none !important; border-right: none; border-left: none; border-top: none; } .vez:focus{ outline: none; } .vjp{ height: 48px; line-height: 48px; overflow: hidden; clear: both; padding: 0 24px; text-align: right; } .vjp .vhs{ display: inline-block; height: 48px; line-height: 48px; margin-left: 24px; color: #60A0B3; } .vej{ overflow: hidden; margin-bottom: 16px; position: relative; } .vej span:first-child{ display: block; height: 32px; line-height: 32px; } .vej .oi{ color: #333; font-size: 15px; float: left; position: relative; top: 7px; } .vej input[type="text"]{ height: 32px; line-height: 32px; border-bottom: 1px solid rgba(0,0,0,0.12); padding-left: 32px; position: relative; right: 24px; color: rgba(0,0,0,0.4); margin-bottom: 0; } .vej input[type="text"]:focus{ color: #333; } .vej .vja{ height: 32px; line-height: 32px; border-radius: 0px; margin-left: 8px; } .vej:last-child{ margin-bottom: 0px; } .vcl{ -webkit-transition: all .5s ease; -moz-transition: all .5s ease; transform: translateY(0px); } .vcl.vhr{ transform: translateY(-184px); -webkit-transform: translateY(-184px); } .vcl.vhr .vhp{ transform: scale(0.7) rotate(44deg); -webkit-transform: scale(0.7) rotate(44deg); background: #b71a1a; } .vcl.vhr .vhp .oi:before{ opacity: 0; } .vcl.vhr .vhp .oi:after{ content: '+'; font-size: 32px; position: relative; right: 9px; bottom: 2px; } .vcl .vew{ position: relative; z-index: 2; background: #fff; } .vcl .vjp{ padding: 0; } .vea .vey:first-child{ width: 45%; } .vea .vey{ width: 55%; } .vhp{ position: absolute; width: 64px; height: 64px; border-radius: 50%; background: #60A0B3; cursor: pointer; right: 36px; top: -32px; color: #fff; font-size: 20px; line-height: 69px; box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.26); transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; } .vey{ float: left; } #simplemodal-container{ height: auto !important; position: relative; top: 50%; transform: translateY(-50%); -webkit-transform: translateY(-50%); } .simplemodal-container, .simplemodal-overlay{ opacity: 0; transition: 0.3s; } .simplemodal-container.vko{ opacity: 1 !important; } .simplemodal-overlay.vko{ opacity: 0.4 !important; } .vcm{ padding-left: 24px; text-align: center; cursor: pointer; } .vcm .veb{ font-size: 13px; } .vcp{ max-height: 220px; max-width: 100%; } .vch{ width: 0px; height: 0px; overflow: hidden; } .veb{ display: block; height: 24px; line-height: 24px; text-align: left; } .vdz{ width: 100%; z-index: -1; position: absolute; padding: 0 24px; background: #60A0B3; height: 367px; overflow: hidden; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; opacity: 0; transform: translateY(-250px); -webkit-transform: translateY(-250px); } .vdz.vhr{ opacity: 1; transform: translateY(0px); -webkit-transform: translateY(0px); } .vdz .vhs{ height: 48px; line-height: 48px; color: #fff; float: right; } .vdx{ height: 319px; overflow: hidden; overflow-y: scroll; box-shadow: inset 0 -10px 10px -10px rgba(0, 0, 0, 0.26); } .vdy{ width: 100%; overflow: hidden; position: relative; margin-bottom: 11px; background: url('../img/checkerboard.png'); } .vdy img{ max-height: 100%; cursor: pointer; } .vdy.no-image{ background-image: none !important; background-color: #D74B4B; color: #fff !important; cursor: pointer; padding: 12px; line-height: 20px; } .vec{ position: absolute; z-index: 2; bottom: 8px; right: 8px; color: #fff; font-weight: bold; font-size: 12px; text-shadow: 1px 1px 2px #333; } .vmh{ float: left; width: 32%; margin-top: 24px; } .vmh:nth-child(2){ margin-right: 2%; margin-left: 2%; } .vcd{ width: 656px; } .vce{ overflow: hidden; max-height: 500px; overflow-y: auto; } .vam{ width: 50px; height: 50px; margin: 0px 10px 10px 0px; font-size: 28px; text-align: center; float: left; cursor: pointer; transition: all .5s ease; -webkit-transition: all .5s ease; -moz-transition: all .5s ease; line-height: 48px; } .vam:hover{ color: #333; } .vdr{ width: 592px; } .vft{ width: 100%; height: 420px; overflow: auto; border: 1px solid #ccc; } .vfu{ width: 2000px; box-sizing: border-box; height: 420px; margin: 0px; background: none; border: none; box-shadow: none; font-size: 12px; font-family: 'Courier New'; line-height: 18px; } .vfu:focus{ outline: none; } .vgy{ margin-left: 24px;} .global-vfr{ background: #2b2b2b; padding: 24px; text-align: center; } .global-vfr img{ max-width: 160px; } .global-vfr img:last-of-type{ max-height: 40px; } .global-vfr .vew{ margin: 32px 0px; } .global-vfr .vhs{ width: 50%; height: 48px; line-height: 48px; color: #fff; opacity: 0.7; } .global-vfr .vhs:hover{ opacity: 1; } /************* Context Menu Styles *************/ .vjr { position: absolute; display: none; z-index: 1000; box-shadow: 0 2px 10px 0 rgba(0, 0, 0, 0.16), 0 2px 5px 0 rgba(0, 0, 0, 0.26); border-radius: 0px 0px 2px 2px; } .vau{ height: 48px; line-height: 48px; background: #60A0B3; color: #fff; font-size: 15px; font-weight: 500; padding: 0 16px; border-radius: 2px 2px 0px 0px; } .vaw { padding: 0 32px 0 16px; height: 48px; line-height: 48px; background-color: #fff; font-size: 15px; border-top: 1px solid #ccc; min-width: 150px; color: #666; transition: all .3s ease; } .vav:hover { cursor: pointer; color: #60A0B3; } .vct:before, .vcg:before, .vdc:before, .vcc:before, .veg:before, .vbt:before, .vas:before, .vcb:before, .var:before, .vbw:before, .vdh:before{ font-family: 'Icons'; display: inline-block; speak: none; line-height: 1; vertical-align: baseline; font-weight: normal; font-style: normal; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; margin-right: 8px; } .vct:before{ content:'\e086'; } .vcg:before{ content:'\e079'; } .vdc:before{ content:'\e0d4'; } .vcc:before{ content:'\e0c2'; } .veg:before{ content:'\e061'; } .vbt:before{ content:'\e062'; } .vas:before{ content:'\e0a4'; } .vcb:before{ content:'\e017'; } .var:before{ content:'\e0a4'; } .vbw:before{ content:'\e017'; } .vdh:before{ content:'\e0a3'; } /************* Context Menu Styles *************/ .vib{ display: none !important; } .vjb{ opacity: 0.5; border: 1px solid #e26060; } /************* Optional Class Styles *************/ .vky{ width: 100%; overflow: hidden; border-radius: 2px; } .vks{ cursor:pointer; width: 50%; color: #fff; background-color:rgba(255,255,255, 0.1); float:left; display:inline-block; text-align: center; } .vks:nth-child(1){ border-radius: 2px 0px 0px 2px; } .vks:nth-child(2){ border-radius: 0px 2px 2px 0px; } .vks.vkr,.vks.vkr:hover{ color: #fff; background-color: #3498db; } .vks:hover{ color: #fff; background-color:rgba(255,255,255, 0.2); transition: 0.5s all; } .vkz{ width: 100%; cursor: default; } .vkz .oi{ margin-right: 16px; position: relative; top: 3px; font-size: 18px; } .vkt{ width: 32px; display: inline-block; float: right; line-height: 16px; height: 16px; position: relative; z-index: 2; top: 13px; cursor: pointer; transition: all .2s ease; -webkit-transition: all .2s ease; -moz-transition: all .2s ease; } .vkt:before{ height: 8px; width: 32px; border-radius: 4px; background: #999; content: ''; position: relative; top: 5px; position: absolute; z-index: 0; } .vmi{ width: 16px; height: 16px; border-radius: 50%; background: #fff; box-shadow: 0 2px 10px 0 rgba(0, 0, 0, 0.16), 0 2px 5px 0 rgba(0, 0, 0, 0.26); position: relative; z-index: 2; transition: all .2s ease; -webkit-transition: all .2s ease; -moz-transition: all .2s ease; } .vku:before{ background: #92bdb5; } .vku .vmi{ background: #60A0B3; transform: translateX(16px); -webkit-transform: translateX(16px); } @media all and (max-height: 800px){ .vkt{ top: 8px; } } .vmj{ width: 100%; overflow: hidden; border-radius: 2px; } .vkv:first-child{ border-radius: 2px 2px 0px 0px; } .vkv:last-child{ border-radius: 0px 0px 2px 2px; } .vkv{ cursor:pointer; width: 100%; color: #fff; background-color:rgba(255,255,255, 0.1); display:inline-block; text-align: center; } .vkv.vkw,.vkv.vkw:hover{ color: #fff; background-color: #3498db; } .vkv:hover{ color: #fff; background-color:rgba(255,255,255, 0.2); transition: 0.5s all; } .vkx li{ padding: 0 32px; height: 40px; line-height: 40px; } @media all and (max-height: 800px){ .vkx li{ height: 32px; line-height: 32px; } } /************* Template Specific Style Fixes *************/ /** PIVOT **/ .video-wrapper video{ width: 130% !important; } .main-container{ opacity: 1 !important; } nav{ opacity: 1 !important; } /************* Embedded Videos *************/ .vju:before{ content: ''; position: absolute; top: 0px; left: 0px; height: 80%; z-index: 2; background: none; opacity: 0; width: 100%; } /************* Purchase Link *************/ .vml{ font-family: 'Roboto',"Helvetica Neue", "Helvetica", Helvetica, "Arimo", Arial, sans-serif !important; display:block; position: absolute; bottom: 32px; right: 32px; z-index: 9999; display: inline-block; color: #fff; height: 48px; width: 144px; text-align: center; background: #6dc77a; line-height: 48px; font-size: 15px; text-transform: uppercase; font-weight: 500; opacity: 0.9; transition: all .2s ease; -webkit-transition: all .2s ease; -moz-transition: all .2s ease; box-shadow: 0 2px 5px 0 rgba(0, 0, 0, 0.26); text-decoration: none; } .vml:hover{ opacity: 1; color: #fff; } .vml:active,.vml:visited{ color: #fff; text-decoration: none; }
{ "pile_set_name": "Github" }
package net.perfectdreams.loritta.website import com.github.benmanes.caffeine.cache.Caffeine import com.mrpowergamerbr.loritta.Loritta import com.mrpowergamerbr.loritta.utils.WebsiteUtils import com.mrpowergamerbr.loritta.utils.locale.BaseLocale import com.mrpowergamerbr.loritta.utils.loritta import com.mrpowergamerbr.loritta.website.LoriWebCode import com.mrpowergamerbr.loritta.website.WebsiteAPIException import io.ktor.application.call import io.ktor.application.install import io.ktor.features.CachingHeaders import io.ktor.features.StatusPages import io.ktor.http.CacheControl import io.ktor.http.ContentType import io.ktor.http.HttpStatusCode import io.ktor.http.content.* import io.ktor.request.* import io.ktor.response.respondRedirect import io.ktor.routing.Routing import io.ktor.routing.RoutingApplicationCall import io.ktor.routing.get import io.ktor.routing.routing import io.ktor.server.engine.embeddedServer import io.ktor.server.netty.Netty import io.ktor.server.netty.NettyApplicationEngine import io.ktor.sessions.* import io.ktor.util.AttributeKey import io.ktor.util.hex import kotlinx.html.* import kotlinx.html.stream.appendHTML import mu.KotlinLogging import net.perfectdreams.loritta.platform.discord.plugin.LorittaDiscordPlugin import net.perfectdreams.loritta.website.blog.Blog import net.perfectdreams.loritta.website.routes.LocalizedRoute import net.perfectdreams.loritta.website.session.LorittaJsonWebSession import net.perfectdreams.loritta.website.utils.LorittaHtmlProvider import net.perfectdreams.loritta.website.utils.ScriptingUtils import net.perfectdreams.loritta.website.utils.extensions.* import net.perfectdreams.temmiediscordauth.TemmieDiscordAuth import org.apache.commons.lang3.exception.ExceptionUtils import java.io.File import java.lang.RuntimeException import java.util.* import java.util.concurrent.ConcurrentHashMap import java.util.concurrent.TimeUnit import kotlin.reflect.full.createType /** * Clone of the original "LorittaWebsite" from the "sweet-morenitta" module * * This is used as a "hack" until the new website is done */ class LorittaWebsite(val loritta: Loritta) { companion object { lateinit var INSTANCE: LorittaWebsite val versionPrefix = "/v2" private val logger = KotlinLogging.logger {} private val TimeToProcess = AttributeKey<Long>("TimeToProcess") val cachedFanArtThumbnails = Caffeine.newBuilder() .expireAfterAccess(1, TimeUnit.HOURS) .build<String, CachedThumbnail>() class CachedThumbnail( val type: ContentType, val thumbnailBytes: ByteArray ) } val pathCache = ConcurrentHashMap<File, Any>() var config = WebsiteConfig() val blog = Blog() val pageProvider: LorittaHtmlProvider get() = loritta.pluginManager.plugins.filterIsInstance<LorittaDiscordPlugin>().mapNotNull { it.htmlProvider }.firstOrNull() ?: throw RuntimeException("Can't find any plugins providing a valid Html Provider!") lateinit var server: NettyApplicationEngine private val typesToCache = listOf( ContentType.Text.CSS, ContentType.Text.JavaScript, ContentType.Application.JavaScript, ContentType.Image.Any ) fun start() { INSTANCE = this val routes = DefaultRoutes.defaultRoutes(loritta) val server = embeddedServer(Netty, loritta.instanceConfig.loritta.website.port) { install(CachingHeaders) { options { outgoingContent -> val contentType = outgoingContent.contentType if (contentType != null) { val contentTypeWithoutParameters = contentType.withoutParameters() val matches = typesToCache.any { contentTypeWithoutParameters.match(it) || contentTypeWithoutParameters == it } if (matches) CachingOptions(CacheControl.MaxAge(maxAgeSeconds = 365 * 24 * 3600)) else null } else null } } install(StatusPages) { status(HttpStatusCode.NotFound) { if (call.alreadyHandledStatus) return@status val html = ScriptingUtils.evaluateWebPageFromTemplate( File( "${INSTANCE.config.websiteFolder}/views/error_404.kts" ), mapOf( "path" to call.request.path().split("/").drop(2).joinToString("/"), "websiteUrl" to INSTANCE.config.websiteUrl, "locale" to ScriptingUtils.WebsiteArgumentType(BaseLocale::class.createType(nullable = false), loritta.locales["default"]!!) ) ) call.respondHtml(html, HttpStatusCode.NotFound) } exception<TemmieDiscordAuth.TokenUnauthorizedException> { cause -> if (call.request.path().startsWith("/api/v1/")) { logger.warn { "Unauthorized token! Throwing a WebsiteAPIException... $cause" } call.sessions.clear<LorittaJsonWebSession>() call.respondJson( WebsiteUtils.createErrorPayload( LoriWebCode.UNAUTHORIZED, "Invalid Discord Authorization" ), HttpStatusCode.Unauthorized ) } else { logger.warn { "Unauthorized token! Redirecting to dashboard... $cause" } val hostHeader = call.request.host() call.sessions.clear<LorittaJsonWebSession>() call.respondRedirect("https://$hostHeader/dashboard", true) } } exception<TemmieDiscordAuth.TokenExchangeException> { cause -> if (call.request.path().startsWith("/api/v1/")) { logger.warn { "Token exchange exception! Throwing a WebsiteAPIException... $cause" } call.sessions.clear<LorittaJsonWebSession>() call.respondJson( WebsiteUtils.createErrorPayload( LoriWebCode.UNAUTHORIZED, "Invalid Discord Authorization" ), HttpStatusCode.Unauthorized ) } else { logger.warn { "Token exchange exception! Redirecting to dashboard... $cause" } val hostHeader = call.request.host() call.sessions.clear<LorittaJsonWebSession>() call.respondRedirect("https://$hostHeader/dashboard", true) } } exception<WebsiteAPIException> { cause -> call.alreadyHandledStatus = true call.respondJson(cause.payload, cause.status) } exception<HttpRedirectException> { e -> call.respondRedirect(e.location, permanent = e.permanent) } exception<Throwable> { cause -> val userAgent = call.request.userAgent() val trueIp = call.request.trueIp val queryString = call.request.urlQueryString val httpMethod = call.request.httpMethod.value logger.error(cause) { "Something went wrong when processing ${trueIp} (${userAgent}): ${httpMethod} ${call.request.path()}${queryString}" } call.respondHtml( StringBuilder().appendHTML() .html { head { title { + "Uh, oh! Something went wrong!" } } body { pre { + ExceptionUtils.getStackTrace(cause) } } } .toString(), status = HttpStatusCode.InternalServerError ) } } install(Sessions) { val secretHashKey = hex(loritta.config.loritta.website.sessionHex) cookie<LorittaJsonWebSession>(loritta.config.loritta.website.sessionName) { cookie.path = "/" cookie.domain = loritta.instanceConfig.loritta.website.url.split("/").dropLast(1).last().split(":").first() cookie.maxAgeInSeconds = 365L * 24 * 3600 // one year transform(SessionTransportTransformerMessageAuthentication(secretHashKey, "HmacSHA256")) } } routing { static { staticRootFolder = File("${config.websiteFolder}/static/") files(".") } File("${config.websiteFolder}/static/").listFiles().filter { it.isFile }.forEach { file(it.name, it) } for (route in (routes + loritta.pluginManager.plugins.filterIsInstance<LorittaDiscordPlugin>().flatMap { it.routes })) { if (route is LocalizedRoute) { get(route.originalPath) { val acceptLanguage = call.request.header("Accept-Language") ?: "en-US" val ranges = Locale.LanguageRange.parse(acceptLanguage).reversed() var localeId = "en-us" for (range in ranges) { localeId = range.range.toLowerCase() if (localeId == "pt-br" || localeId == "pt") { localeId = "default" } if (localeId == "en") { localeId = "en-us" } } val locale = loritta.getLocaleById(localeId) redirect("/${locale.path}${call.request.uri}") } } route.register(this) logger.info { "Registered ${route.getMethod().value} ${route.path} (${route::class.simpleName})" } } } this.environment.monitor.subscribe(Routing.RoutingCallStarted) { call: RoutingApplicationCall -> call.attributes.put(TimeToProcess, System.currentTimeMillis()) val userAgent = call.request.userAgent() val trueIp = call.request.trueIp val queryString = call.request.urlQueryString val httpMethod = call.request.httpMethod.value logger.info("${trueIp} (${userAgent}): ${httpMethod} ${call.request.path()}${queryString}") /* if (loritta.config.loritta.website.blockedIps.contains(trueIp)) { logger.warn("$trueIp ($userAgent): ${httpMethod} ${call.request.path()}$queryString - Request was IP blocked") this.finish() } if (loritta.config.loritta.website.blockedUserAgents.contains(trueIp)) { logger.warn("$trueIp ($userAgent): ${httpMethod} ${call.request.path()}$queryString - Request was User-Agent blocked") this.finish() } */ } this.environment.monitor.subscribe(Routing.RoutingCallFinished) { call: RoutingApplicationCall -> val originalStartTime = call.attributes[TimeToProcess] val queryString = call.request.urlQueryString val userAgent = call.request.userAgent() logger.info("${call.request.trueIp} (${userAgent}): ${call.request.httpMethod.value} ${call.request.path()}${queryString} - OK! ${System.currentTimeMillis() - originalStartTime}ms") } } this.server = server server.start(wait = true) } fun stop() { server.stop(1000L, 5000L) } fun restart() { stop() start() } fun loadBlogPosts() { blog.posts = blog.loadAllBlogPosts() } class WebsiteConfig { val websiteUrl: String get() = loritta.instanceConfig.loritta.website.url.removeSuffix("/") val websiteFolder = File(loritta.instanceConfig.loritta.website.folder) } }
{ "pile_set_name": "Github" }
package controllers import ( "encoding/json" service "goERP/services" "goERP/utils" "strconv" ) // LoginController 登录模块 type LoginController struct { BaseController } // Post 登录请求 func (ctl *LoginController) Post() { response := make(map[string]interface{}) var requestBody map[string]string json.Unmarshal(ctl.Ctx.Input.RequestBody, &requestBody) username := requestBody["username"] password := requestBody["password"] if user, ok := service.ServiceUserLogin(username, password); ok { user.Password = "" ctl.SetSession("User", *user) response["code"] = utils.SuccessCode response["msg"] = utils.SuccessMsg data := make(map[string]interface{}) data["user"] = &user response["data"] = data if groups, err := service.ServiceGetUserGroups(user.IsAdmin, user.ID); err == nil { leng := len(groups) groupIDs := make([]int64, leng, leng) for index, group := range groups { groupIDs[index] = group.ID } if len(groupIDs) == 0 { data["groups"] = make([]int, 0, 0) } else { data["groups"] = groupIDs } } } else { response["code"] = utils.FailedCode response["msg"] = utils.FailedMsg } ctl.Data["json"] = response ctl.ServeJSON() } // Get 注销登录请求 func (ctl *LoginController) Get() { response := make(map[string]interface{}) IDStr := ctl.Ctx.Input.Param(":id") if ID, err := strconv.ParseInt(IDStr, 10, 64); err == nil { service.ServiceUserLogout(ID) response["code"] = utils.SuccessCode response["msg"] = utils.SuccessMsg } else { response["code"] = utils.FailedCode response["msg"] = utils.FailedMsg } ctl.Data["json"] = response ctl.ServeJSON() }
{ "pile_set_name": "Github" }
package com.gettipsi.stripe.util; /** * Created by ngoriachev on 13/03/2018. */ public abstract class PayParams { public static final String CURRENCY_CODE = "currency_code"; public static final String BILLING_ADDRESS_REQUIRED = "billing_address_required"; public static final String SHIPPING_ADDRESS_REQUIRED = "shipping_address_required"; public static final String PHONE_NUMBER_REQUIRED = "phone_number_required"; public static final String EMAIL_REQUIRED = "email_required"; public static final String TOTAL_PRICE = "total_price"; public static final String UNIT_PRICE = "unit_price"; public static final String LINE_ITEMS = "line_items"; public static final String QUANTITY = "quantity"; public static final String DESCRIPTION = "description"; }
{ "pile_set_name": "Github" }
/* TEMPLATE GENERATED TESTCASE FILE Filename: CWE124_Buffer_Underwrite__new_char_cpy_22b.cpp Label Definition File: CWE124_Buffer_Underwrite__new.label.xml Template File: sources-sink-22b.tmpl.cpp */ /* * @description * CWE: 124 Buffer Underwrite * BadSource: Set data pointer to before the allocated memory buffer * GoodSource: Set data pointer to the allocated memory buffer * Sink: cpy * BadSink : Copy string to data using strcpy * Flow Variant: 22 Control flow: Flow controlled by value of a global variable. Sink functions are in a separate file from sources. * * */ #include "std_testcase.h" #include <wchar.h> namespace CWE124_Buffer_Underwrite__new_char_cpy_22 { #ifndef OMITBAD /* The global variable below is used to drive control flow in the source function. Since it is in a C++ namespace, it doesn't need a globally unique name. */ extern int badGlobal; char * badSource(char * data) { if(badGlobal) { { char * dataBuffer = new char[100]; memset(dataBuffer, 'A', 100-1); dataBuffer[100-1] = '\0'; /* FLAW: Set data pointer to before the allocated memory buffer */ data = dataBuffer - 8; } } return data; } #endif /* OMITBAD */ #ifndef OMITGOOD /* The global variables below are used to drive control flow in the source functions. Since they are in a C++ namespace, they don't need globally unique names. */ extern int goodG2B1Global; extern int goodG2B2Global; /* goodG2B1() - use goodsource and badsink by setting the global variable to false instead of true */ char * goodG2B1Source(char * data) { if(goodG2B1Global) { /* INCIDENTAL: CWE 561 Dead Code, the code below will never run */ printLine("Benign, fixed string"); } else { { char * dataBuffer = new char[100]; memset(dataBuffer, 'A', 100-1); dataBuffer[100-1] = '\0'; /* FIX: Set data pointer to the allocated memory buffer */ data = dataBuffer; } } return data; } /* goodG2B2() - use goodsource and badsink by reversing the blocks in the if in the source function */ char * goodG2B2Source(char * data) { if(goodG2B2Global) { { char * dataBuffer = new char[100]; memset(dataBuffer, 'A', 100-1); dataBuffer[100-1] = '\0'; /* FIX: Set data pointer to the allocated memory buffer */ data = dataBuffer; } } return data; } #endif /* OMITGOOD */ } /* close namespace */
{ "pile_set_name": "Github" }
# Sets default memory used for gradle commands. Can be overridden by user or command line properties. # This is required to provide enough memory for the Minecraft decompilation process. org.gradle.jvmargs=-Xmx2G # SkyblockAddons Properties modId = skyblockaddons modName = SkyblockAddons version = 1.5.4 acceptedMinecraftVersions = [1.8.9] minecraftVersion = 1.8.9 forgeVersion = 11.15.1.2318-1.8.9 mappings = stable_22 updateJSON = https://raw.githubusercontent.com/BiscuitDevelopment/SkyblockAddons/master/.github/versions/release-versions.json
{ "pile_set_name": "Github" }
<?xml version="1.0" encoding="utf-8"?> <resources xmlns:tools="http://schemas.android.com/tools"> <string name="unknown_artist">Onbekende artiest</string> <string name="unknown_album">Onbekend album</string> <string name="unknown_genre">Onbekend genre</string> <string name="various_artists">Diverse artiesten</string> </resources>
{ "pile_set_name": "Github" }
## Hybrid API gateway pattern ### Introduction In all the deployment patterns mentioned above, the management aspect of the deployment needs to be handled by the enterprise. It gives them the utmost flexibility and control over the platform. But sometimes, organizations with limited IT staff and skill set wants to outsource some of the management and hosting capabilties of the platform while keeping the important components. This is what exactly the hybrid API gateway pattern provides. ### Architecture ![Hybrid API Gateway pattern](images/Microgateway-Pattern6-Hybrid-API-Gateway.png) Figure 1: Hybrid API gateway pattern In this deployment pattern, the critical runtime component of the API platform which is the gateway will be running under the control of the enterprise. It can be run on a private data center, public IaaS cloud or both. In the meantime, the management components of API publisher, Developer Portal, Analytics and Key manager will be hosted and maintained by WSO2 within their public API Cloud.
{ "pile_set_name": "Github" }
[Mesh] [gen] type = GeneratedMeshGenerator dim = 2 nx = 10 ny = 10 elem_type = QUAD4 [] [] [Variables] [u] order = CONSTANT family = MONOMIAL [] [v][] [] [Functions] [force] type = ParsedFunction value = t [] [] [Kernels] [diff] type = Diffusion variable = v [] [force] type = BodyForce variable = v function = force [] [] [FVKernels] [diff] type = FVDiffusion variable = u coeff = coeff [] [force] type = FVBodyForce variable = u function = force [] [] [FVBCs] [right] type = FVDirichletBC variable = u boundary = right value = 1 [] [left] type = FVDirichletBC variable = u boundary = left value = 0 [] [] [BCs] [right] type = DirichletBC variable = v boundary = right value = 1 [] [left] type = DirichletBC variable = v boundary = left value = 0 [] [] [Materials] [diff] type = ADGenericConstantMaterial prop_names = 'coeff' prop_values = '1' [] [] [Executioner] type = Transient num_steps = 2 dt = 1 solve_type = 'NEWTON' [] [Problem] kernel_coverage_check = false [] [Adaptivity] marker = box initial_steps = 1 [Markers] [box] bottom_left = '0.3 0.3 0' inside = refine top_right = '0.6 0.6 0' outside = do_nothing type = BoxMarker [] [] [] [Outputs] exodus = true []
{ "pile_set_name": "Github" }
/* * Copyright 2015-2020 Amazon.com, Inc. or its affiliates. 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. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file 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. */ package com.amazonaws.services.kms.model.transform; import java.math.*; import javax.annotation.Generated; import com.amazonaws.services.kms.model.*; import com.amazonaws.transform.SimpleTypeJsonUnmarshallers.*; import com.amazonaws.transform.*; import com.fasterxml.jackson.core.JsonToken; import static com.fasterxml.jackson.core.JsonToken.*; /** * KeyUnavailableException JSON Unmarshaller */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class KeyUnavailableExceptionUnmarshaller extends EnhancedJsonErrorUnmarshaller { private KeyUnavailableExceptionUnmarshaller() { super(com.amazonaws.services.kms.model.KeyUnavailableException.class, "KeyUnavailableException"); } @Override public com.amazonaws.services.kms.model.KeyUnavailableException unmarshallFromContext(JsonUnmarshallerContext context) throws Exception { com.amazonaws.services.kms.model.KeyUnavailableException keyUnavailableException = new com.amazonaws.services.kms.model.KeyUnavailableException(null); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) { return null; } while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return keyUnavailableException; } private static KeyUnavailableExceptionUnmarshaller instance; public static KeyUnavailableExceptionUnmarshaller getInstance() { if (instance == null) instance = new KeyUnavailableExceptionUnmarshaller(); return instance; } }
{ "pile_set_name": "Github" }
<?xml version="1.0" encoding="utf-8"?> <android.support.design.widget.CoordinatorLayout xmlns:android="http://schemas.android.com/apk/res/android" xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent" android:layout_height="match_parent" tools:context="net.idik.crepecake.sample.MainActivity"> <android.support.design.widget.AppBarLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:theme="@style/AppTheme.AppBarOverlay"> <android.support.v7.widget.Toolbar android:id="@+id/toolbar" android:layout_width="match_parent" android:layout_height="?attr/actionBarSize" android:background="?attr/colorPrimary" app:popupTheme="@style/AppTheme.PopupOverlay" /> </android.support.design.widget.AppBarLayout> <include layout="@layout/content_main" /> <android.support.design.widget.FloatingActionButton android:id="@+id/fab" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="bottom|end" android:layout_margin="@dimen/fab_margin" app:srcCompat="@android:drawable/ic_dialog_email" /> </android.support.design.widget.CoordinatorLayout>
{ "pile_set_name": "Github" }
// Copyright 2017, OpenCensus Authors // // 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. package trace import ( "encoding/binary" ) const defaultSamplingProbability = 1e-4 // Sampler decides whether a trace should be sampled and exported. type Sampler func(SamplingParameters) SamplingDecision // SamplingParameters contains the values passed to a Sampler. type SamplingParameters struct { ParentContext SpanContext TraceID TraceID SpanID SpanID Name string HasRemoteParent bool } // SamplingDecision is the value returned by a Sampler. type SamplingDecision struct { Sample bool } // ProbabilitySampler returns a Sampler that samples a given fraction of traces. // // It also samples spans whose parents are sampled. func ProbabilitySampler(fraction float64) Sampler { if !(fraction >= 0) { fraction = 0 } else if fraction >= 1 { return AlwaysSample() } traceIDUpperBound := uint64(fraction * (1 << 63)) return Sampler(func(p SamplingParameters) SamplingDecision { if p.ParentContext.IsSampled() { return SamplingDecision{Sample: true} } x := binary.BigEndian.Uint64(p.TraceID[0:8]) >> 1 return SamplingDecision{Sample: x < traceIDUpperBound} }) } // AlwaysSample returns a Sampler that samples every trace. // Be careful about using this sampler in a production application with // significant traffic: a new trace will be started and exported for every // request. func AlwaysSample() Sampler { return func(p SamplingParameters) SamplingDecision { return SamplingDecision{Sample: true} } } // NeverSample returns a Sampler that samples no traces. func NeverSample() Sampler { return func(p SamplingParameters) SamplingDecision { return SamplingDecision{Sample: false} } }
{ "pile_set_name": "Github" }
require 'spec_helper' RSpec.describe 'Tokenize integration specs' do client = Cryptoexchange::Client.new let(:btc_eth_pair) { Cryptoexchange::Models::MarketPair.new(base: 'eth', target: 'btc', market: 'tokenize') } it 'fetch pairs' do pairs = client.pairs('tokenize') expect(pairs).not_to be_empty pair = pairs.first expect(pair.base).to_not be nil expect(pair.target).to_not be nil expect(pair.market).to eq 'tokenize' end it 'fetch ticker' do ticker = client.ticker(btc_eth_pair) expect(ticker.base).to eq 'ETH' expect(ticker.target).to eq 'BTC' expect(ticker.market).to eq 'tokenize' expect(ticker.volume).to be_a Numeric expect(ticker.last).to be_a Numeric expect(ticker.high).to be_a Numeric expect(ticker.low).to be_a Numeric expect(ticker.bid).to be_a Numeric expect(ticker.ask).to be_a Numeric expect(ticker.timestamp).to be nil expect(ticker.payload).to_not be nil end it 'give trade url' do trade_page_url = client.trade_page_url 'tokenize', base: btc_eth_pair.base, target: btc_eth_pair.target expect(trade_page_url).to eq "https://tokenize.exchange/market/BTC-ETH" end it 'fetch order book' do order_book = client.order_book(btc_eth_pair) expect(order_book.base).to eq 'ETH' expect(order_book.target).to eq 'BTC' expect(order_book.market).to eq 'tokenize' expect(order_book.asks).to_not be_empty expect(order_book.bids).to_not be_empty expect(order_book.asks.first.price).to_not be_nil expect(order_book.bids.first.amount).to_not be_nil expect(order_book.bids.first.timestamp).to be_nil expect(order_book.timestamp).to be_nil expect(order_book.payload).to_not be nil end end
{ "pile_set_name": "Github" }
Clazz.declarePackage ("JM"); Clazz.load (["J.api.JmolMeasurementClient"], "JM.MeasurementData", ["java.lang.Float", "JU.BS", "$.Lst", "JM.Measurement", "JU.BSUtil"], function () { c$ = Clazz.decorateAsClass (function () { this.client = null; this.measurementStrings = null; this.measurements = null; this.points = null; this.mustBeConnected = false; this.mustNotBeConnected = false; this.tickInfo = null; this.tokAction = 1060866; this.radiusData = null; this.strFormat = null; this.note = null; this.isAll = false; this.colix = 0; this.intramolecular = null; this.mad = 0; this.thisID = null; this.text = null; this.atoms = null; this.units = null; this.minArray = null; this.ms = null; this.vwr = null; this.iFirstAtom = 0; this.justOneModel = true; this.htMin = null; Clazz.instantialize (this, arguments); }, JM, "MeasurementData", null, J.api.JmolMeasurementClient); Clazz.makeConstructor (c$, function () { }); Clazz.defineMethod (c$, "init", function (id, vwr, points) { this.vwr = vwr; this.points = points; this.thisID = id; return this; }, "~S,JV.Viewer,JU.Lst"); Clazz.defineMethod (c$, "setModelSet", function (m) { this.ms = m; return this; }, "JM.ModelSet"); Clazz.defineMethod (c$, "set", function (tokAction, htMin, radiusData, strFormat, units, tickInfo, mustBeConnected, mustNotBeConnected, intramolecular, isAll, mad, colix, text) { this.ms = this.vwr.ms; this.tokAction = tokAction; if (this.points.size () >= 2 && Clazz.instanceOf (this.points.get (0), JU.BS) && Clazz.instanceOf (this.points.get (1), JU.BS)) { this.justOneModel = JU.BSUtil.haveCommon (this.vwr.ms.getModelBS (this.points.get (0), false), this.vwr.ms.getModelBS (this.points.get (1), false)); }this.htMin = htMin; this.radiusData = radiusData; this.strFormat = strFormat; this.units = units; this.tickInfo = tickInfo; this.mustBeConnected = mustBeConnected; this.mustNotBeConnected = mustNotBeConnected; this.intramolecular = intramolecular; this.isAll = isAll; this.mad = mad; this.colix = colix; this.text = text; return this; }, "~N,java.util.Map,J.atomdata.RadiusData,~S,~S,JM.TickInfo,~B,~B,Boolean,~B,~N,~N,JM.Text"); Clazz.defineMethod (c$, "processNextMeasure", function (m) { var value = m.getMeasurement (null); if (this.htMin != null && !m.isMin (this.htMin) || this.radiusData != null && !m.isInRange (this.radiusData, value)) return; if (this.measurementStrings == null && this.measurements == null) { var f = this.minArray[this.iFirstAtom]; m.value = value; value = m.fixValue (this.units, false); this.minArray[this.iFirstAtom] = (1 / f == -Infinity ? value : Math.min (f, value)); return; }if (this.measurementStrings != null) this.measurementStrings.addLast (m.getStringUsing (this.vwr, this.strFormat, this.units)); else this.measurements.addLast (Float.$valueOf (m.getMeasurement (null))); }, "JM.Measurement"); Clazz.defineMethod (c$, "getMeasurements", function (asArray, asMinArray) { if (asMinArray) { this.minArray = Clazz.newFloatArray ((this.points.get (0)).cardinality (), 0); for (var i = 0; i < this.minArray.length; i++) this.minArray[i] = -0.0; this.define (null, this.ms); return this.minArray; }if (asArray) { this.measurements = new JU.Lst (); this.define (null, this.ms); return this.measurements; }this.measurementStrings = new JU.Lst (); this.define (null, this.ms); return this.measurementStrings; }, "~B,~B"); Clazz.defineMethod (c$, "define", function (client, modelSet) { this.client = (client == null ? this : client); this.atoms = modelSet.at; var nPoints = this.points.size (); if (nPoints < 2) return; var modelIndex = -1; var pts = new Array (4); var indices = Clazz.newIntArray (5, 0); var m = new JM.Measurement ().setPoints (modelSet, indices, pts, null); m.setCount (nPoints); var ptLastAtom = -1; for (var i = 0; i < nPoints; i++) { var obj = this.points.get (i); if (Clazz.instanceOf (obj, JU.BS)) { var bs = obj; var nAtoms = bs.cardinality (); if (nAtoms == 0) return; if (nAtoms > 1) modelIndex = 0; ptLastAtom = i; if (i == 0) this.iFirstAtom = 0; indices[i + 1] = bs.nextSetBit (0); } else { pts[i] = obj; indices[i + 1] = -2 - i; }} this.nextMeasure (0, ptLastAtom, m, modelIndex); }, "J.api.JmolMeasurementClient,JM.ModelSet"); Clazz.defineMethod (c$, "nextMeasure", function (thispt, ptLastAtom, m, thisModel) { if (thispt > ptLastAtom) { if (m.isValid () && (!this.mustBeConnected || m.isConnected (this.atoms, thispt)) && (!this.mustNotBeConnected || !m.isConnected (this.atoms, thispt)) && (this.intramolecular == null || m.isIntramolecular (this.atoms, thispt) == this.intramolecular.booleanValue ())) this.client.processNextMeasure (m); return; }var bs = this.points.get (thispt); var indices = m.countPlusIndices; var thisAtomIndex = (thispt == 0 ? 2147483647 : indices[thispt]); if (thisAtomIndex < 0) { this.nextMeasure (thispt + 1, ptLastAtom, m, thisModel); return; }var haveNext = false; for (var i = bs.nextSetBit (0), pt = 0; i >= 0; i = bs.nextSetBit (i + 1), pt++) { if (i == thisAtomIndex) continue; var modelIndex = this.atoms[i].getModelIndex (); if (thisModel >= 0 && this.justOneModel) { if (thispt == 0) thisModel = modelIndex; else if (thisModel != modelIndex) continue; }indices[thispt + 1] = i; if (thispt == 0) this.iFirstAtom = pt; haveNext = true; this.nextMeasure (thispt + 1, ptLastAtom, m, thisModel); } if (!haveNext) this.nextMeasure (thispt + 1, ptLastAtom, m, thisModel); }, "~N,~N,JM.Measurement,~N"); });
{ "pile_set_name": "Github" }
gs://k8s-artifacts-kind/ has no CORS configuration.
{ "pile_set_name": "Github" }
# # This is the Apache server configuration file providing SSL support. # It contains the configuration directives to instruct the server how to # serve pages over an https connection. For detailing information about these # directives see <URL:http://httpd.apache.org/docs/2.2/mod/mod_ssl.html> # # Do NOT simply read the instructions in here without understanding # what they do. They're here only as hints or reminders. If you are unsure # consult the online docs. You have been warned. # LoadModule ssl_module modules/mod_ssl.so # # When we also provide SSL we have to listen to the # the HTTPS port in addition. # Listen 443 ## ## SSL Global Context ## ## All SSL configuration in this context applies both to ## the main server and all SSL-enabled virtual hosts. ## # # Some MIME-types for downloading Certificates and CRLs # AddType application/x-x509-ca-cert .crt AddType application/x-pkcs7-crl .crl # Pass Phrase Dialog: # Configure the pass phrase gathering process. # The filtering dialog program (`builtin' is a internal # terminal dialog) has to provide the pass phrase on stdout. SSLPassPhraseDialog builtin # Inter-Process Session Cache: # Configure the SSL Session Cache: First the mechanism # to use and second the expiring timeout (in seconds). #SSLSessionCache dc:UNIX:/var/cache/mod_ssl/distcache SSLSessionCache shmcb:/var/cache/mod_ssl/scache(512000) SSLSessionCacheTimeout 300 # Semaphore: # Configure the path to the mutual exclusion semaphore the # SSL engine uses internally for inter-process synchronization. SSLMutex default # Pseudo Random Number Generator (PRNG): # Configure one or more sources to seed the PRNG of the # SSL library. The seed data should be of good random quality. # WARNING! On some platforms /dev/random blocks if not enough entropy # is available. This means you then cannot use the /dev/random device # because it would lead to very long connection times (as long as # it requires to make more entropy available). But usually those # platforms additionally provide a /dev/urandom device which doesn't # block. So, if available, use this one instead. Read the mod_ssl User # Manual for more details. SSLRandomSeed startup file:/dev/urandom 256 SSLRandomSeed connect builtin #SSLRandomSeed startup file:/dev/random 512 #SSLRandomSeed connect file:/dev/random 512 #SSLRandomSeed connect file:/dev/urandom 512 # # Use "SSLCryptoDevice" to enable any supported hardware # accelerators. Use "openssl engine -v" to list supported # engine names. NOTE: If you enable an accelerator and the # server does not start, consult the error logs and ensure # your accelerator is functioning properly. # SSLCryptoDevice builtin #SSLCryptoDevice ubsec ## ## SSL Virtual Host Context ## <VirtualHost _default_:443> # General setup for the virtual host, inherited from global configuration #DocumentRoot "/var/www/html" #ServerName www.example.com:443 # Use separate log files for the SSL virtual host; note that LogLevel # is not inherited from httpd.conf. ErrorLog logs/ssl_error_log TransferLog logs/ssl_access_log LogLevel warn # SSL Engine Switch: # Enable/Disable SSL for this virtual host. SSLEngine on # SSL Protocol support: # List the enable protocol levels with which clients will be able to # connect. Disable SSLv2 access by default: SSLProtocol all -SSLv2 # SSL Cipher Suite: # List the ciphers that the client is permitted to negotiate. # See the mod_ssl documentation for a complete list. SSLCipherSuite ALL:!ADH:!EXPORT:!SSLv2:RC4+RSA:+HIGH:+MEDIUM:+LOW # Server Certificate: # Point SSLCertificateFile at a PEM encoded certificate. If # the certificate is encrypted, then you will be prompted for a # pass phrase. Note that a kill -HUP will prompt again. A new # certificate can be generated using the genkey(1) command. SSLCertificateFile /etc/pki/tls/certs/ca.crt # Server Private Key: # If the key is not combined with the certificate, use this # directive to point at the key file. Keep in mind that if # you've both a RSA and a DSA private key you can configure # both in parallel (to also allow the use of DSA ciphers, etc.) SSLCertificateKeyFile /etc/pki/tls/private/ca.key # Server Certificate Chain: # Point SSLCertificateChainFile at a file containing the # concatenation of PEM encoded CA certificates which form the # certificate chain for the server certificate. Alternatively # the referenced file can be the same as SSLCertificateFile # when the CA certificates are directly appended to the server # certificate for convinience. #SSLCertificateChainFile /etc/pki/tls/certs/server-chain.crt # Certificate Authority (CA): # Set the CA certificate verification path where to find CA # certificates for client authentication or alternatively one # huge file containing all of them (file must be PEM encoded) #SSLCACertificateFile /etc/pki/tls/certs/ca-bundle.crt # Client Authentication (Type): # Client certificate verification type and depth. Types are # none, optional, require and optional_no_ca. Depth is a # number which specifies how deeply to verify the certificate # issuer chain before deciding the certificate is not valid. #SSLVerifyClient require #SSLVerifyDepth 10 # Access Control: # With SSLRequire you can do per-directory access control based # on arbitrary complex boolean expressions containing server # variable checks and other lookup directives. The syntax is a # mixture between C and Perl. See the mod_ssl documentation # for more details. #<Location /> #SSLRequire ( %{SSL_CIPHER} !~ m/^(EXP|NULL)/ \ # and %{SSL_CLIENT_S_DN_O} eq "Snake Oil, Ltd." \ # and %{SSL_CLIENT_S_DN_OU} in {"Staff", "CA", "Dev"} \ # and %{TIME_WDAY} >= 1 and %{TIME_WDAY} <= 5 \ # and %{TIME_HOUR} >= 8 and %{TIME_HOUR} <= 20 ) \ # or %{REMOTE_ADDR} =~ m/^192\.76\.162\.[0-9]+$/ #</Location> # SSL Engine Options: # Set various options for the SSL engine. # o FakeBasicAuth: # Translate the client X.509 into a Basic Authorisation. This means that # the standard Auth/DBMAuth methods can be used for access control. The # user name is the `one line' version of the client's X.509 certificate. # Note that no password is obtained from the user. Every entry in the user # file needs this password: `xxj31ZMTZzkVA'. # o ExportCertData: # This exports two additional environment variables: SSL_CLIENT_CERT and # SSL_SERVER_CERT. These contain the PEM-encoded certificates of the # server (always existing) and the client (only existing when client # authentication is used). This can be used to import the certificates # into CGI scripts. # o StdEnvVars: # This exports the standard SSL/TLS related `SSL_*' environment variables. # Per default this exportation is switched off for performance reasons, # because the extraction step is an expensive operation and is usually # useless for serving static content. So one usually enables the # exportation for CGI and SSI requests only. # o StrictRequire: # This denies access when "SSLRequireSSL" or "SSLRequire" applied even # under a "Satisfy any" situation, i.e. when it applies access is denied # and no other module can change it. # o OptRenegotiate: # This enables optimized SSL connection renegotiation handling when SSL # directives are used in per-directory context. #SSLOptions +FakeBasicAuth +ExportCertData +StrictRequire <Files ~ "\.(cgi|shtml|phtml|php3?)$"> SSLOptions +StdEnvVars </Files> <Directory "/var/www/cgi-bin"> SSLOptions +StdEnvVars </Directory> # SSL Protocol Adjustments: # The safe and default but still SSL/TLS standard compliant shutdown # approach is that mod_ssl sends the close notify alert but doesn't wait for # the close notify alert from client. When you need a different shutdown # approach you can use one of the following variables: # o ssl-unclean-shutdown: # This forces an unclean shutdown when the connection is closed, i.e. no # SSL close notify alert is send or allowed to received. This violates # the SSL/TLS standard but is needed for some brain-dead browsers. Use # this when you receive I/O errors because of the standard approach where # mod_ssl sends the close notify alert. # o ssl-accurate-shutdown: # This forces an accurate shutdown when the connection is closed, i.e. a # SSL close notify alert is send and mod_ssl waits for the close notify # alert of the client. This is 100% SSL/TLS standard compliant, but in # practice often causes hanging connections with brain-dead browsers. Use # this only for browsers where you know that their SSL implementation # works correctly. # Notice: Most problems of broken clients are also related to the HTTP # keep-alive facility, so you usually additionally want to disable # keep-alive for those clients, too. Use variable "nokeepalive" for this. # Similarly, one has to force some clients to use HTTP/1.0 to workaround # their broken HTTP/1.1 implementation. Use variables "downgrade-1.0" and # "force-response-1.0" for this. SetEnvIf User-Agent ".*MSIE.*" \ nokeepalive ssl-unclean-shutdown \ downgrade-1.0 force-response-1.0 # Per-Server Logging: # The home of a custom SSL log file. Use this when you want a # compact non-error SSL logfile on a virtual host basis. CustomLog logs/ssl_request_log \ "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b" </VirtualHost>
{ "pile_set_name": "Github" }
<?php /* * This file is part of the PHP_Timer package. * * (c) Sebastian Bergmann <[email protected]> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ /** * Utility class for timing. * * @since Class available since Release 1.0.0 */ class PHP_Timer { /** * @var array */ private static $times = array( 'hour' => 3600000, 'minute' => 60000, 'second' => 1000 ); /** * @var array */ private static $startTimes = array(); /** * @var float */ public static $requestTime; /** * Starts the timer. */ public static function start() { array_push(self::$startTimes, microtime(true)); } /** * Stops the timer and returns the elapsed time. * * @return float */ public static function stop() { return microtime(true) - array_pop(self::$startTimes); } /** * Formats the elapsed time as a string. * * @param float $time * @return string */ public static function secondsToTimeString($time) { $ms = round($time * 1000); foreach (self::$times as $unit => $value) { if ($ms >= $value) { $time = floor($ms / $value * 100.0) / 100.0; return $time . ' ' . ($time == 1 ? $unit : $unit . 's'); } } return $ms . ' ms'; } /** * Formats the elapsed time since the start of the request as a string. * * @return string */ public static function timeSinceStartOfRequest() { return self::secondsToTimeString(microtime(true) - self::$requestTime); } /** * Returns the resources (time, memory) of the request as a string. * * @return string */ public static function resourceUsage() { return sprintf( 'Time: %s, Memory: %4.2fMB', self::timeSinceStartOfRequest(), memory_get_peak_usage(true) / 1048576 ); } } if (isset($_SERVER['REQUEST_TIME_FLOAT'])) { PHP_Timer::$requestTime = $_SERVER['REQUEST_TIME_FLOAT']; } elseif (isset($_SERVER['REQUEST_TIME'])) { PHP_Timer::$requestTime = $_SERVER['REQUEST_TIME']; } else { PHP_Timer::$requestTime = microtime(true); }
{ "pile_set_name": "Github" }
require 'spec_helper' describe service('nagios') do it { should be_enabled } it { should be_running } it { should be_running.under('systemd') } end ['nagios', 'nagios-plugins', 'nagios-devel', 'nagios-plugins-load', 'nagios-plugins-http'].each do |p| describe package("#{p}") do it { should be_installed } end end ['/var/log/nagios/nagios.log', '/var/log/nagios/host.perflog'].each do |f| describe file("#{f}") do it { should be_file } it { should exist } it { should be_owned_by 'nagios' } it { should be_grouped_into 'nagios' } it { should be_readable } end end
{ "pile_set_name": "Github" }
<?php namespace DeepCopy\TypeFilter\Spl; /** * @deprecated Use {@see SplDoublyLinkedListFilter} instead. */ class SplDoublyLinkedList extends SplDoublyLinkedListFilter { }
{ "pile_set_name": "Github" }
# Map & Tuple <nav> <a href="#一映射Map">一、映射(Map)</a><br/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#11-构造Map">1.1 构造Map</a><br/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#12-获取值">1.2 获取值</a><br/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#13-新增修改删除值">1.3 新增/修改/删除值</a><br/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#14-遍历Map">1.4 遍历Map</a><br/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#15-yield关键字">1.5 yield关键字</a><br/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#16-其他Map结构">1.6 其他Map结构</a><br/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#17-可选方法">1.7 可选方法</a><br/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#18-与Java互操作">1.8 与Java互操作</a><br/> <a href="#二元组Tuple">二、元组(Tuple)</a><br/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#21--模式匹配">2.1 模式匹配</a><br/> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<a href="#22-zip方法">2.2 zip方法</a><br/> </nav> ## 一、映射(Map) ### 1.1 构造Map ```scala // 初始化一个空 map val scores01 = new HashMap[String, Int] // 从指定的值初始化 Map(方式一) val scores02 = Map("hadoop" -> 10, "spark" -> 20, "storm" -> 30) // 从指定的值初始化 Map(方式二) val scores03 = Map(("hadoop", 10), ("spark", 20), ("storm", 30)) ``` 采用上面方式得到的都是不可变 Map(immutable map),想要得到可变 Map(mutable map),则需要使用: ```scala val scores04 = scala.collection.mutable.Map("hadoop" -> 10, "spark" -> 20, "storm" -> 30) ``` ### 1.2 获取值 ```scala object ScalaApp extends App { val scores = Map("hadoop" -> 10, "spark" -> 20, "storm" -> 30) // 1.获取指定 key 对应的值 println(scores("hadoop")) // 2. 如果对应的值不存在则使用默认值 println(scores.getOrElse("hadoop01", 100)) } ``` ### 1.3 新增/修改/删除值 可变 Map 允许进行新增、修改、删除等操作。 ```scala object ScalaApp extends App { val scores = scala.collection.mutable.Map("hadoop" -> 10, "spark" -> 20, "storm" -> 30) // 1.如果 key 存在则更新 scores("hadoop") = 100 // 2.如果 key 不存在则新增 scores("flink") = 40 // 3.可以通过 += 来进行多个更新或新增操作 scores += ("spark" -> 200, "hive" -> 50) // 4.可以通过 -= 来移除某个键和值 scores -= "storm" for (elem <- scores) {println(elem)} } // 输出内容如下 (spark,200) (hadoop,100) (flink,40) (hive,50) ``` 不可变 Map 不允许进行新增、修改、删除等操作,但是允许由不可变 Map 产生新的 Map。 ```scala object ScalaApp extends App { val scores = Map("hadoop" -> 10, "spark" -> 20, "storm" -> 30) val newScores = scores + ("spark" -> 200, "hive" -> 50) for (elem <- scores) {println(elem)} } // 输出内容如下 (hadoop,10) (spark,200) (storm,30) (hive,50) ``` ### 1.4 遍历Map ```java object ScalaApp extends App { val scores = Map("hadoop" -> 10, "spark" -> 20, "storm" -> 30) // 1. 遍历键 for (key <- scores.keys) { println(key) } // 2. 遍历值 for (value <- scores.values) { println(value) } // 3. 遍历键值对 for ((key, value) <- scores) { println(key + ":" + value) } } ``` ### 1.5 yield关键字 可以使用 `yield` 关键字从现有 Map 产生新的 Map。 ```scala object ScalaApp extends App { val scores = Map("hadoop" -> 10, "spark" -> 20, "storm" -> 30) // 1.将 scores 中所有的值扩大 10 倍 val newScore = for ((key, value) <- scores) yield (key, value * 10) for (elem <- newScore) { println(elem) } // 2.将键和值互相调换 val reversalScore: Map[Int, String] = for ((key, value) <- scores) yield (value, key) for (elem <- reversalScore) { println(elem) } } // 输出 (hadoop,100) (spark,200) (storm,300) (10,hadoop) (20,spark) (30,storm) ``` ### 1.6 其他Map结构 在使用 Map 时候,如果不指定,默认使用的是 HashMap,如果想要使用 `TreeMap` 或者 `LinkedHashMap`,则需要显式的指定。 ```scala object ScalaApp extends App { // 1.使用 TreeMap,按照键的字典序进行排序 val scores01 = scala.collection.mutable.TreeMap("B" -> 20, "A" -> 10, "C" -> 30) for (elem <- scores01) {println(elem)} // 2.使用 LinkedHashMap,按照键值对的插入顺序进行排序 val scores02 = scala.collection.mutable.LinkedHashMap("B" -> 20, "A" -> 10, "C" -> 30) for (elem <- scores02) {println(elem)} } // 输出 (A,10) (B,20) (C,30) (B,20) (A,10) (C,30) ``` ### 1.7 可选方法 ```scala object ScalaApp extends App { val scores = scala.collection.mutable.TreeMap("B" -> 20, "A" -> 10, "C" -> 30) // 1. 获取长度 println(scores.size) // 2. 判断是否为空 println(scores.isEmpty) // 3. 判断是否包含特定的 key println(scores.contains("A")) } ``` ### 1.8 与Java互操作 ```scala import java.util import scala.collection.{JavaConverters, mutable} object ScalaApp extends App { val scores = Map("hadoop" -> 10, "spark" -> 20, "storm" -> 30) // scala map 转 java map val javaMap: util.Map[String, Int] = JavaConverters.mapAsJavaMap(scores) // java map 转 scala map val scalaMap: mutable.Map[String, Int] = JavaConverters.mapAsScalaMap(javaMap) for (elem <- scalaMap) {println(elem)} } ``` ## 二、元组(Tuple) 元组与数组类似,但是数组中所有的元素必须是同一种类型,而元组则可以包含不同类型的元素。 ```scala scala> val tuple=(1,3.24f,"scala") tuple: (Int, Float, String) = (1,3.24,scala) ``` ### 2.1 模式匹配 可以通过模式匹配来获取元组中的值并赋予对应的变量: ```scala scala> val (a,b,c)=tuple a: Int = 1 b: Float = 3.24 c: String = scala ``` 如果某些位置不需要赋值,则可以使用下划线代替: ```scala scala> val (a,_,_)=tuple a: Int = 1 ``` ### 2.2 zip方法 ```scala object ScalaApp extends App { val array01 = Array("hadoop", "spark", "storm") val array02 = Array(10, 20, 30) // 1.zip 方法得到的是多个 tuple 组成的数组 val tuples: Array[(String, Int)] = array01.zip(array02) // 2.也可以在 zip 后调用 toMap 方法转换为 Map val map: Map[String, Int] = array01.zip(array02).toMap for (elem <- tuples) { println(elem) } for (elem <- map) {println(elem)} } // 输出 (hadoop,10) (spark,20) (storm,30) (hadoop,10) (spark,20) (storm,30) ``` ## 参考资料 1. Martin Odersky . Scala 编程 (第 3 版)[M] . 电子工业出版社 . 2018-1-1 2. 凯.S.霍斯特曼 . 快学 Scala(第 2 版)[M] . 电子工业出版社 . 2017-7
{ "pile_set_name": "Github" }
// Boost.Signals2 library // Copyright Frank Mori Hess 2007,2009. // Copyright Timmo Stange 2007. // Copyright Douglas Gregor 2001-2004. Use, modification and // distribution is subject to the Boost Software License, Version // 1.0. (See accompanying file LICENSE_1_0.txt or copy at // http://www.boost.org/LICENSE_1_0.txt) // Compatibility class to ease porting from the original // Boost.Signals library. However, // boost::signals2::trackable is NOT thread-safe. // For more information, see http://www.boost.org #ifndef BOOST_SIGNALS2_TRACKABLE_HPP #define BOOST_SIGNALS2_TRACKABLE_HPP #include <boost/assert.hpp> #include <boost/shared_ptr.hpp> namespace boost { namespace signals2 { namespace detail { class tracked_objects_visitor; } class trackable { protected: trackable(): _tracked_ptr(static_cast<int*>(0)) {} trackable(const trackable &): _tracked_ptr(static_cast<int*>(0)) {} trackable& operator=(const trackable &) { return *this; } ~trackable() {} private: friend class detail::tracked_objects_visitor; const shared_ptr<void>& get_shared_ptr() const { return _tracked_ptr; } shared_ptr<void> _tracked_ptr; }; } // end namespace signals2 } // end namespace boost #endif // BOOST_SIGNALS2_TRACKABLE_HPP
{ "pile_set_name": "Github" }
(* * Copyright 2014, General Dynamics C4 Systems * * SPDX-License-Identifier: GPL-2.0-only *) theory KHeap_AI imports "./$L4V_ARCH/ArchKHeap_AI" begin context begin interpretation Arch . requalify_consts obj_is_device valid_vso_at non_vspace_obj vspace_obj_pred requalify_facts pspace_in_kernel_window_atyp_lift valid_vspace_objs_lift_weak vs_lookup_vspace_obj_at_lift vs_lookup_pages_vspace_obj_at_lift valid_arch_caps_lift_weak valid_global_objs_lift_weak valid_asid_map_lift valid_ioports_lift valid_kernel_mappings_lift equal_kernel_mappings_lift valid_global_vspace_mappings_lift valid_machine_state_lift valid_vso_at_lift valid_vso_at_lift_aobj_at valid_arch_state_lift_aobj_at in_user_frame_lift in_user_frame_obj_pred_lift set_object_v_ker_map non_vspace_objs vspace_obj_predE vspace_pred_imp in_user_frame_obj_upd in_device_frame_obj_upd device_mem_obj_upd_dom user_mem_obj_upd_dom pspace_respects_region_cong cap_is_device_obj_is_device storeWord_device_state_inv state_hyp_refs_of_ep_update state_hyp_refs_of_ntfn_update state_hyp_refs_of_tcb_state_update state_hyp_refs_of_tcb_bound_ntfn_update arch_valid_obj_same_type default_arch_object_not_live default_tcb_not_live getActiveIRQ_neq_non_kernel dmo_getActiveIRQ_non_kernel valid_arch_tcb_same_type valid_arch_tcb_typ_at valid_tcb_arch_ref_lift end lemmas cap_is_device_obj_is_device[simp] = cap_is_device_obj_is_device lemmas storeWord_device_state_hoare[wp] = storeWord_device_state_inv declare non_vspace_objs[intro] context notes get_object_wp [wp] begin method get_simple_ko_method = (wpsimp simp: get_simple_ko_def partial_inv_def the_equality split: kernel_object.splits) lemma get_simple_ko_wp: "\<lbrace>\<lambda>s. \<forall>ntfn. ko_at (f ntfn) ntfnptr s \<longrightarrow> P ntfn s\<rbrace> get_simple_ko f ntfnptr \<lbrace>P\<rbrace>" by get_simple_ko_method lemma get_object_inv [wp]: "\<lbrace>P\<rbrace> get_object t \<lbrace>\<lambda>rv. P\<rbrace>" by wpsimp lemma get_tcb_rev: "kheap s p = Some (TCB t)\<Longrightarrow> get_tcb p s = Some t" by (clarsimp simp:get_tcb_def) lemma get_tcb_obj_atE[elim!]: "\<lbrakk> get_tcb t s = Some tcb; get_tcb t s = Some tcb \<Longrightarrow> P (TCB tcb) \<rbrakk> \<Longrightarrow> obj_at P t s" by (clarsimp dest!: get_tcb_SomeD simp: obj_at_def) lemma a_type_TCB[simp]: "a_type (TCB x) = ATCB" by (simp add: a_type_def) lemma pspace_aligned_obj_update: assumes obj: "obj_at P t s" assumes pa: "pspace_aligned s" assumes R: "\<And>k. P k \<Longrightarrow> a_type k = a_type k'" shows "pspace_aligned (s\<lparr>kheap := kheap s(t \<mapsto> k')\<rparr>)" using pa obj apply (simp add: pspace_aligned_def cong: conj_cong) apply (clarsimp simp: obj_at_def obj_bits_T dest!: R) apply (fastforce dest: bspec [OF _ domI]) done lemma cte_at_same_type: "\<lbrakk>cte_at t s; a_type k = a_type ko; kheap s p = Some ko\<rbrakk> \<Longrightarrow> cte_at t (s\<lparr>kheap := kheap s(p \<mapsto> k)\<rparr>)" apply (clarsimp simp: cte_at_cases del: disjCI) apply (elim exE disjE) apply (clarsimp simp: a_type_def well_formed_cnode_n_def length_set_helper split: Structures_A.kernel_object.split_asm if_split_asm) apply clarsimp done lemma untyped_same_type: "\<lbrakk>valid_untyped (cap.UntypedCap dev r n f) s; a_type k = a_type ko; kheap s p = Some ko\<rbrakk> \<Longrightarrow> valid_untyped (cap.UntypedCap dev r n f) (s\<lparr>kheap := kheap s(p \<mapsto> k)\<rparr>)" unfolding valid_untyped_def by (clarsimp simp: obj_range_def obj_bits_T) lemma valid_cap_same_type: "\<lbrakk> s \<turnstile> cap; a_type k = a_type ko; kheap s p = Some ko \<rbrakk> \<Longrightarrow> s\<lparr>kheap := kheap s(p \<mapsto> k)\<rparr> \<turnstile> cap" apply (simp add: valid_cap_def split: cap.split) apply (auto elim!: typ_at_same_type untyped_same_type simp: ntfn_at_typ ep_at_typ tcb_at_typ cap_table_at_typ split: option.split sum.split) by (intro hoare_to_pure_kheap_upd[OF valid_arch_cap_typ, simplified obj_at_def], assumption, auto) lemma valid_obj_same_type: "\<lbrakk> valid_obj p' obj s; valid_obj p k s; kheap s p = Some ko; a_type k = a_type ko \<rbrakk> \<Longrightarrow> valid_obj p' obj (s\<lparr>kheap := kheap s(p \<mapsto> k)\<rparr>)" apply (cases obj; simp) apply (clarsimp simp add: valid_obj_def valid_cs_def) apply (drule (1) bspec) apply (erule (2) valid_cap_same_type) apply (clarsimp simp: valid_obj_def valid_tcb_def valid_bound_ntfn_def valid_arch_tcb_same_type) apply (fastforce elim: valid_cap_same_type typ_at_same_type simp: valid_tcb_state_def ep_at_typ ntfn_at_typ tcb_at_typ split: Structures_A.thread_state.splits option.splits) apply (clarsimp simp add: valid_obj_def valid_ep_def) apply (fastforce elim: typ_at_same_type simp: tcb_at_typ split: Structures_A.endpoint.splits) apply (clarsimp simp add: valid_obj_def valid_ntfn_def valid_bound_tcb_def) apply (auto elim: typ_at_same_type simp: tcb_at_typ split: Structures_A.ntfn.splits option.splits) apply (clarsimp simp add: valid_obj_def) apply (auto intro: arch_valid_obj_same_type) done lemma set_object_valid_objs[wp]: "\<lbrace>valid_objs and valid_obj p k\<rbrace> set_object p k \<lbrace>\<lambda>r. valid_objs\<rbrace>" apply (wpsimp wp: set_object_wp_strong simp: obj_at_def) apply (clarsimp simp: valid_objs_def dom_def) apply (intro conjI impI; fastforce intro: valid_obj_same_type) done lemma set_object_aligned[wp]: "set_object p k \<lbrace>pspace_aligned\<rbrace>" apply (wpsimp wp: set_object_wp_strong) apply (clarsimp elim!: pspace_aligned_obj_update) done lemma assert_get_tcb: "\<lbrace> P \<rbrace> gets_the (get_tcb t) \<lbrace> \<lambda>r. P and tcb_at t \<rbrace>" by (clarsimp simp: valid_def in_monad gets_the_def tcb_at_def) (* This rule is not always safe. However, we make it [wp] while we're only doing proofs that don't involve extended state, and then remove it from [wp] in Deterministic_AI. *) lemma dxo_wp_weak[wp]: assumes xopv: "\<And>s f. P (trans_state f s) = P s" shows "\<lbrace>P\<rbrace> do_extended_op x \<lbrace>\<lambda>_. P\<rbrace>" unfolding do_extended_op_def apply (simp add: split_def) apply wp apply (clarsimp simp: mk_ef_def) apply (simp add: xopv[simplified trans_state_update']) done crunch ct[wp]: set_thread_state "\<lambda>s. P (cur_thread s)" lemma sts_ep_at_inv[wp]: "\<lbrace> ep_at ep \<rbrace> set_thread_state t s \<lbrace> \<lambda>rv. ep_at ep \<rbrace>" apply (simp add: set_thread_state_def) apply (wp | simp add: set_object_def)+ apply (clarsimp simp: obj_at_def is_ep is_tcb get_tcb_def) done lemma sts_ntfn_at_inv[wp]: "\<lbrace> ntfn_at ep \<rbrace> set_thread_state t s \<lbrace> \<lambda>rv. ntfn_at ep \<rbrace>" apply (simp add: set_thread_state_def) apply (wp | simp add: set_object_def)+ apply (clarsimp simp: obj_at_def is_ntfn is_tcb get_tcb_def) done lemma sbn_ep_at_inv[wp]: "\<lbrace> ep_at ep \<rbrace> set_bound_notification t ntfn \<lbrace> \<lambda>rv. ep_at ep \<rbrace>" apply (simp add: set_bound_notification_def) apply (wp | simp add: set_object_def)+ apply (clarsimp simp: obj_at_def is_ep is_tcb get_tcb_def) done lemma sbn_ntfn_at_inv[wp]: "\<lbrace> ntfn_at ep \<rbrace> set_bound_notification t ntfn \<lbrace> \<lambda>rv. ntfn_at ep \<rbrace>" apply (simp add: set_bound_notification_def) apply (wp | simp add: set_object_def)+ apply (clarsimp simp: obj_at_def is_ntfn is_tcb get_tcb_def) done lemma prefix_to_eq: "\<lbrakk> take n xs \<le> ys; length xs = length ys; drop n xs = drop n ys \<rbrakk> \<Longrightarrow> xs = ys" apply (induct n arbitrary: xs ys) apply simp apply (case_tac xs) apply simp apply (case_tac ys) apply simp apply simp done lemma set_cdt_inv: assumes P: "\<And>s. P s \<Longrightarrow> P (cdt_update (\<lambda>_. m) s)" shows "\<lbrace>P\<rbrace> set_cdt m \<lbrace>\<lambda>_. P\<rbrace>" apply (simp add: set_cdt_def) apply wp apply (erule P) done lemmas cte_wp_at_cdt = cdt_update.cte_wp_at_update lemmas obj_at_cdt = cdt_update.obj_at_update lemmas valid_cap_cdt = cdt_update.valid_cap_update lemma set_object_at_obj3: "\<lbrace>K (P obj)\<rbrace> set_object p obj \<lbrace>\<lambda>rv. obj_at P p\<rbrace>" by (clarsimp simp: set_object_def obj_at_def valid_def in_monad) lemma set_object_valid_cap: "set_object p ko \<lbrace>valid_cap c\<rbrace>" by (wpsimp wp: set_object_wp_strong simp: obj_at_def valid_cap_same_type) lemma set_object_cte_at: "set_object p ko \<lbrace>cte_at c\<rbrace>" by (wpsimp wp: set_object_wp_strong simp: obj_at_def cte_at_same_type) lemma obj_at_ko_atD: "obj_at P x s \<Longrightarrow> \<exists>k. ko_at k x s \<and> P k" by (clarsimp simp: obj_at_def) lemma set_object_ko: "\<lbrace>ko_at obj ptr and K (x \<noteq> ptr)\<rbrace> set_object x ko \<lbrace>\<lambda>rv. ko_at obj ptr\<rbrace>" by (clarsimp simp add: valid_def set_object_def get_object_def in_monad obj_at_def) lemma tcb_aligned: "\<lbrakk> invs s; tcb_at t s \<rbrakk> \<Longrightarrow> is_aligned t tcb_bits" apply (clarsimp simp: invs_def valid_state_def valid_pspace_def pspace_aligned_def) apply (clarsimp simp: tcb_at_def, drule get_tcb_SomeD) apply (erule my_BallE [where y=t]) apply clarsimp apply simp done lemma set_object_ko_at: "\<lbrace>\<top>\<rbrace> set_object p ko \<lbrace>\<lambda>_. ko_at ko p\<rbrace>" by (wpsimp wp: set_object_wp simp: obj_at_def) lemma get_simple_ko_sp: "\<lbrace>P\<rbrace> get_simple_ko f p \<lbrace>\<lambda>ep. ko_at (f ep) p and P\<rbrace>" by get_simple_ko_method lemma get_simple_ko_inv[wp]: "\<lbrace>P\<rbrace> get_simple_ko f ep \<lbrace>\<lambda>rv. P\<rbrace>" by get_simple_ko_method lemma get_simple_ko_actual_ko[wp]: "\<lbrace> obj_at (\<lambda>ko. bound (partial_inv f ko)) ep \<rbrace> get_simple_ko f ep \<lbrace> \<lambda>rv. obj_at (\<lambda>k. k = f rv) ep \<rbrace>" by (fastforce simp: get_simple_ko_def get_object_def bind_def partial_inv_def valid_def gets_def get_def return_def in_fail assert_def obj_at_def split_def the_equality split: kernel_object.splits option.splits) lemma get_object_valid [wp]: "\<lbrace>valid_objs\<rbrace> get_object oref \<lbrace> valid_obj oref \<rbrace>" apply (simp add: get_object_def) apply wp apply (clarsimp simp add: valid_pspace_def valid_objs_def dom_def) apply fastforce done lemma get_object_valid_obj_simple [wp]: notes valid_simple_obj_def[simp del] shows "\<lbrace>valid_objs\<rbrace> get_object oref \<lbrace> valid_simple_obj \<rbrace>" apply (simp add: get_object_def) apply wp apply (clarsimp simp: valid_pspace_def valid_objs_def dom_def intro!: valid_obj_imp_valid_simple) apply fastforce done lemma get_object_valid_simple [wp]: "\<lbrace>valid_simple_objs\<rbrace> get_object oref \<lbrace> valid_simple_obj \<rbrace>" apply (simp add: get_object_def) apply wp apply (clarsimp simp add: valid_pspace_def valid_simple_objs_def dom_def) apply fastforce done lemma get_simple_ko_valid [wp]: "\<lbrace>valid_objs\<rbrace> get_simple_ko f oref \<lbrace> \<lambda>r s. valid_simple_obj (f r) s\<rbrace>" apply (simp add: get_simple_ko_def) apply (wpsimp) apply (drule valid_objs_imp_valid_simple_objs) apply (clarsimp simp: valid_simple_objs_def partial_inv_def obj_at_def the_equality split: if_splits) apply (drule_tac x=oref in bspec) apply (clarsimp simp: the_equality split: kernel_object.splits)+ done lemma get_simple_ko_valid_obj[wp]: "\<lbrace> valid_objs and obj_at (\<lambda>ko. bound (partial_inv f ko)) ep \<rbrace> get_simple_ko f ep \<lbrace> \<lambda>r. valid_obj ep (f r) \<rbrace>" apply (simp add: get_simple_ko_def) apply (rule hoare_seq_ext) prefer 2 apply (rule hoare_pre_imp [OF _ get_object_valid]) apply (simp add: invs_def valid_state_def valid_pspace_def) apply (wpsimp simp: partial_inv_def the_equality valid_obj_def split: option.splits) done lemma get_simple_ko_valid_simple_obj[wp]: notes valid_simple_obj_def[simp del] shows "\<lbrace> valid_objs and obj_at (\<lambda>ko. bound (partial_inv f ko)) ep \<rbrace> get_simple_ko f ep \<lbrace> \<lambda>r. valid_simple_obj (f r) \<rbrace>" apply (simp add: get_simple_ko_def) apply (rule hoare_seq_ext) prefer 2 apply (rule hoare_pre_imp [OF _ get_object_valid]) apply (simp add: invs_def valid_state_def valid_pspace_def) apply (wpsimp simp: partial_inv_def the_equality valid_obj_imp_valid_simple split: option.splits) done lemma get_ntfn_valid_ntfn[wp]: "\<lbrace> valid_objs and ntfn_at ntfn \<rbrace> get_notification ntfn \<lbrace> valid_ntfn \<rbrace>" by (wpsimp simp: ntfn_at_def2 valid_ntfn_def2 simp_del: valid_simple_obj_def) lemma get_ep_valid_ep[wp]: "\<lbrace> invs and ep_at ep \<rbrace> get_endpoint ep \<lbrace> valid_ep \<rbrace>" by (wpsimp simp: ep_at_def2 valid_ep_def2 simp_del: valid_simple_obj_def) lemma set_simple_ko_valid_objs[wp]: "\<lbrace> valid_objs and valid_simple_obj (f v) and K (is_simple_type (f v))\<rbrace> set_simple_ko f ptr v \<lbrace>\<lambda>rv s. valid_objs s\<rbrace>" unfolding set_simple_ko_def by (wpsimp wp: set_object_valid_objs[THEN hoare_set_object_weaken_pre] simp: valid_obj_def obj_at_def a_type_def partial_inv_def valid_ntfn_def2 valid_ep_def2 split: kernel_object.splits simp_del: valid_simple_obj_def) method set_simple_ko_method uses wp_thm simp_thm = (unfold set_simple_ko_def; wpsimp wp: wp_thm simp: simp_thm valid_obj_def obj_at_def a_type_def partial_inv_def the_equality split: kernel_object.splits) lemma set_simple_ko_aligned[wp]: "set_simple_ko f ptr v \<lbrace>pspace_aligned\<rbrace>" by (set_simple_ko_method wp_thm: set_object_aligned[THEN hoare_set_object_weaken_pre]) lemma set_simple_ko_typ_at [wp]: "set_simple_ko f p' ep \<lbrace>\<lambda>s. P (typ_at T p s)\<rbrace>" by (set_simple_ko_method wp_thm: set_object_typ_at) lemma set_simple_ko_cte_wp_at [wp]: "set_simple_ko f p' ep \<lbrace>cte_wp_at P p\<rbrace>" by (set_simple_ko_method wp_thm: set_object_wp simp_thm: cte_wp_at_cases; fastforce) lemma get_simple_ko_ko_at: "\<lbrace>\<top>\<rbrace> get_simple_ko f ep \<lbrace>\<lambda>rv. ko_at (f rv) ep\<rbrace>" by get_simple_ko_method lemma obj_set_prop_at: "\<lbrace>\<lambda>s. P obj \<rbrace> set_object p obj \<lbrace>\<lambda>rv. obj_at P p\<rbrace>" apply (simp add: set_object_def) apply wp apply (simp add: obj_at_def) done lemma simple_obj_set_prop_at: "\<lbrace>\<lambda>s. P (f v) \<rbrace> set_simple_ko f p v \<lbrace>\<lambda>rv. obj_at P p\<rbrace>" by (set_simple_ko_method wp_thm: obj_set_prop_at) lemma set_simple_ko_refs_of[wp]: "\<lbrace>\<lambda>s. P ((state_refs_of s) (ep := refs_of (f val)))\<rbrace> set_simple_ko f ep val \<lbrace>\<lambda>rv s. P (state_refs_of s)\<rbrace>" apply (set_simple_ko_method wp_thm: set_object_wp simp_thm: set_object_def) by (fastforce simp: state_refs_of_def elim!: rsubst[where P=P]) lemma set_ep_refs_of[wp]: "\<lbrace>\<lambda>s. P ((state_refs_of s) (ep := ep_q_refs_of val))\<rbrace> set_endpoint ep val \<lbrace>\<lambda>rv s. P (state_refs_of s)\<rbrace>" by (wp; fastforce simp: state_refs_of_def elim!: rsubst[where P=P]) lemma set_simple_ko_hyp_refs_of[wp]: "set_simple_ko f ep val \<lbrace>\<lambda>s. P (state_hyp_refs_of s)\<rbrace>" apply (set_simple_ko_method wp_thm: set_object_wp_strong) apply (rule conjI; clarsimp elim!: rsubst[where P=P]) apply (subst state_hyp_refs_of_ep_update[of ep, symmetric]) apply (clarsimp simp: obj_at_def) apply (simp add: fun_upd_def) apply (subst state_hyp_refs_of_ntfn_update[of ep, symmetric]) apply (clarsimp simp: obj_at_def) apply (simp add: fun_upd_def) done lemma set_ntfn_refs_of[wp]: "\<lbrace>\<lambda>s. P ((state_refs_of s) (ntfnptr := ntfn_q_refs_of (ntfn_obj ntfn) \<union> ntfn_bound_refs (ntfn_bound_tcb ntfn)))\<rbrace> set_notification ntfnptr ntfn \<lbrace>\<lambda>rv s. P (state_refs_of s)\<rbrace>" by (wp; fastforce simp: state_refs_of_def elim!: rsubst[where P=P]) lemma pspace_distinct_same_type: "\<lbrakk> kheap s t = Some ko; a_type ko = a_type ko'; pspace_distinct s\<rbrakk> \<Longrightarrow> pspace_distinct (s\<lparr>kheap := kheap s(t \<mapsto> ko')\<rparr>)" apply (clarsimp simp add: pspace_distinct_def obj_bits_T) apply fastforce done lemma set_object_distinct[wp]: "set_object p ko' \<lbrace>pspace_distinct\<rbrace>" by (wpsimp wp: set_object_wp_strong simp: obj_at_def pspace_distinct_same_type) lemma set_simple_ko_distinct[wp]: "set_simple_ko f ep v \<lbrace>pspace_distinct\<rbrace>" by (set_simple_ko_method wp_thm: set_object_distinct[THEN hoare_set_object_weaken_pre]) lemma set_simple_ko_cur_tcb[wp]: "set_simple_ko f ep v \<lbrace>cur_tcb\<rbrace>" by (set_simple_ko_method wp_thm: set_object_wp simp_thm: cur_tcb_def is_tcb is_ep; fastforce) lemma assert_pre: "\<lbrace>P\<rbrace> do s <- get; assert (P s); f od \<lbrace>Q\<rbrace> \<Longrightarrow> \<lbrace>P\<rbrace> f \<lbrace>Q\<rbrace>" by (simp add: valid_def assert_def get_def bind_def return_def) lemma set_object_pspace_in_kernel_window: "set_object p k \<lbrace>pspace_in_kernel_window\<rbrace>" unfolding set_object_def apply (rule assert_pre) apply (rule hoare_pre) apply (rule pspace_in_kernel_window_atyp_lift) apply (wp; clarsimp simp add: obj_at_def)+ by simp lemma set_object_pspace_respects_device_region: "set_object p k \<lbrace>pspace_respects_device_region\<rbrace>" apply (simp add: set_object_def, wp) apply (clarsimp simp: pspace_respects_device_region_def device_mem_obj_upd_dom user_mem_obj_upd_dom obj_at_def in_user_frame_obj_upd in_device_frame_obj_upd split: if_split_asm) done lemma set_simple_ko_kernel_window[wp]: "set_simple_ko f ptr val \<lbrace>pspace_in_kernel_window\<rbrace>" by (set_simple_ko_method wp_thm: set_object_pspace_in_kernel_window[THEN hoare_set_object_weaken_pre]) lemma set_simple_ko_respect_device_region[wp]: "set_simple_ko f ptr val \<lbrace>pspace_respects_device_region\<rbrace>" by (set_simple_ko_method wp_thm: set_object_pspace_respects_device_region[THEN hoare_set_object_weaken_pre]) lemma swp_apply [simp]: "swp f x y = f y x" by (simp add: swp_def) lemma hoare_cte_wp_caps_of_state_lift: assumes c: "\<And>P. \<lbrace>\<lambda>s. P (caps_of_state s)\<rbrace> f \<lbrace>\<lambda>r s. P (caps_of_state s)\<rbrace>" shows "\<lbrace>\<lambda>s. cte_wp_at P p s\<rbrace> f \<lbrace>\<lambda>r s. cte_wp_at P p s\<rbrace>" apply (simp add: cte_wp_at_caps_of_state) apply (rule c) done lemma valid_mdb_lift: assumes c: "\<And>P. \<lbrace>\<lambda>s. P (caps_of_state s)\<rbrace> f \<lbrace>\<lambda>r s. P (caps_of_state s)\<rbrace>" assumes m: "\<And>P. \<lbrace>\<lambda>s. P (cdt s)\<rbrace> f \<lbrace>\<lambda>r s. P (cdt s)\<rbrace>" assumes r: "\<And>P. \<lbrace>\<lambda>s. P (is_original_cap s)\<rbrace> f \<lbrace>\<lambda>r s. P (is_original_cap s)\<rbrace>" shows "\<lbrace>valid_mdb\<rbrace> f \<lbrace>\<lambda>r. valid_mdb\<rbrace>" apply (clarsimp simp add: valid_def valid_mdb_def mdb_cte_at_def) apply (frule_tac P1="(=) (cdt s)" in use_valid [OF _ m], rule refl) apply (rule conjI) apply clarsimp apply (erule allE)+ apply (erule (1) impE) apply clarsimp apply (rule conjI) apply (erule use_valid [OF _ c [THEN hoare_cte_wp_caps_of_state_lift]]) apply simp apply (erule use_valid [OF _ c [THEN hoare_cte_wp_caps_of_state_lift]]) apply simp apply (rule use_valid [OF _ c], assumption+) apply (rule use_valid [OF _ r], assumption) apply simp done crunch no_cdt[wp]: set_simple_ko "\<lambda>s. P (cdt s)" (wp: crunch_wps) lemma set_simple_ko_caps_of_state [wp]: "set_simple_ko f p ep \<lbrace>\<lambda>s. P (caps_of_state s)\<rbrace>" apply (set_simple_ko_method simp_thm: bind_assoc wp_thm: set_object_wp_strong) apply (rule conjI; clarsimp split: if_splits; subst cte_wp_caps_of_lift; assumption?) apply (auto simp: cte_wp_at_cases) done lemma set_simple_ko_revokable [wp]: "set_simple_ko f p ep \<lbrace>\<lambda> s. P (is_original_cap s)\<rbrace>" by (set_simple_ko_method wp_thm: set_object_wp) lemma set_ep_mdb [wp]: "set_simple_ko f p ep \<lbrace>valid_mdb\<rbrace>" by (wp valid_mdb_lift) lemma cte_wp_at_after_update: "\<lbrakk> obj_at (same_caps val) p' s \<rbrakk> \<Longrightarrow> cte_wp_at P p (kheap_update (\<lambda>a b. if b = p' then Some val else kheap s b) s) = cte_wp_at P p s" by (fastforce simp: obj_at_def cte_wp_at_cases split: if_split_asm dest: bspec [OF _ ranI]) lemma cte_wp_at_after_update': "\<lbrakk> obj_at (same_caps val) p' s \<rbrakk> \<Longrightarrow> cte_wp_at P p (s\<lparr>kheap := kheap s(p' \<mapsto> val)\<rparr>) = cte_wp_at P p s" by (fastforce simp: obj_at_def cte_wp_at_cases split: if_split_asm dest: bspec [OF _ ranI]) lemma ex_cap_to_after_update: "\<lbrakk> ex_nonz_cap_to p s; obj_at (same_caps val) p' s \<rbrakk> \<Longrightarrow> ex_nonz_cap_to p (kheap_update (\<lambda>a b. if b = p' then Some val else kheap s b) s)" by (clarsimp simp: ex_nonz_cap_to_def cte_wp_at_after_update) lemma ex_cap_to_after_update': "\<lbrakk> ex_nonz_cap_to p s; obj_at (same_caps val) p' s \<rbrakk> \<Longrightarrow> ex_nonz_cap_to p (s\<lparr>kheap := kheap s(p' \<mapsto> val)\<rparr>)" by (clarsimp simp: ex_nonz_cap_to_def cte_wp_at_after_update') lemma ex_cte_cap_to_after_update: "\<lbrakk> ex_cte_cap_wp_to P p s; obj_at (same_caps val) p' s \<rbrakk> \<Longrightarrow> ex_cte_cap_wp_to P p (kheap_update (\<lambda>a b. if b = p' then Some val else kheap s b) s)" by (clarsimp simp: ex_cte_cap_wp_to_def cte_wp_at_after_update) lemma set_object_iflive: "\<lbrace>\<lambda>s. if_live_then_nonz_cap s \<and> (live val \<longrightarrow> ex_nonz_cap_to p s) \<and> obj_at (same_caps val) p s\<rbrace> set_object p val \<lbrace>\<lambda>rv. if_live_then_nonz_cap\<rbrace>" apply (wpsimp wp: set_object_wp) by (fastforce simp: if_live_then_nonz_cap_def obj_at_def elim!: ex_cap_to_after_update') lemma set_object_ifunsafe[wp]: "\<lbrace>if_unsafe_then_cap and obj_at (same_caps val) p\<rbrace> set_object p val \<lbrace>\<lambda>rv. if_unsafe_then_cap\<rbrace>" apply (simp add: set_object_def) apply wp apply (clarsimp simp: if_unsafe_then_cap_def simp: cte_wp_at_after_update dest!: caps_of_state_cteD) apply (clarsimp simp: cte_wp_at_caps_of_state) apply (fastforce elim!: ex_cte_cap_to_after_update) done lemma set_object_zombies[wp]: "\<lbrace>zombies_final and obj_at (same_caps val) p\<rbrace> set_object p val \<lbrace>\<lambda>rv. zombies_final\<rbrace>" apply (simp add: set_object_def) apply wp apply (clarsimp simp: zombies_final_def is_final_cap'_def2 cte_wp_at_after_update) done lemma set_simple_ko_iflive[wp]: "\<lbrace>\<lambda>s. if_live_then_nonz_cap s \<and> (live (f ep) \<longrightarrow> ex_nonz_cap_to p s)\<rbrace> set_simple_ko f p ep \<lbrace>\<lambda>rv. if_live_then_nonz_cap\<rbrace>" apply (set_simple_ko_method wp_thm: set_object_iflive[THEN hoare_set_object_weaken_pre]) apply (rule conjI; clarsimp elim!: obj_at_weakenE split: Structures_A.kernel_object.splits simp: is_ep_def is_ntfn_def) done lemma set_simple_ko_ifunsafe[wp]: "\<lbrace>if_unsafe_then_cap\<rbrace> set_simple_ko f p val \<lbrace>\<lambda>rv. if_unsafe_then_cap\<rbrace>" apply (set_simple_ko_method wp_thm: set_object_ifunsafe[THEN hoare_set_object_weaken_pre]) by (clarsimp elim!: obj_at_weakenE simp: is_ep_def is_ntfn_def) lemma set_simple_ko_zombies[wp]: "\<lbrace>zombies_final\<rbrace> set_simple_ko f p val \<lbrace>\<lambda>rv. zombies_final\<rbrace>" apply (set_simple_ko_method wp_thm: set_object_zombies[THEN hoare_set_object_weaken_pre]) by (clarsimp elim!: obj_at_weakenE simp: is_ep_def is_ntfn_def) lemma set_object_cap_refs_in_kernel_window: "\<lbrace>cap_refs_in_kernel_window and obj_at (same_caps ko) p\<rbrace> set_object p ko \<lbrace>\<lambda>r. cap_refs_in_kernel_window\<rbrace>" apply (simp add: set_object_def, wp) apply (clarsimp simp: cap_refs_in_kernel_window_def) apply (clarsimp simp: valid_refs_def cte_wp_at_after_update) done lemma set_object_cap_refs_respects_device_region: "\<lbrace>cap_refs_respects_device_region and obj_at (same_caps ko) p\<rbrace> set_object p ko \<lbrace>\<lambda>r. cap_refs_respects_device_region\<rbrace>" apply (simp add: set_object_def, wp) apply (clarsimp simp: cap_refs_respects_device_region_def) apply (drule_tac x = a in spec) apply (drule_tac x = b in spec) apply (clarsimp simp: valid_refs_def cte_wp_at_after_update cap_range_respects_device_region_def) apply (erule notE) apply (erule cte_wp_at_weakenE) apply auto done crunch no_revokable[wp]: set_simple_ko "\<lambda>s. P (is_original_cap s)" (wp: crunch_wps) lemma get_object_ret: "\<lbrace>obj_at P addr\<rbrace> get_object addr \<lbrace>\<lambda>r s. P r\<rbrace>" unfolding get_object_def by (wp, clarsimp elim!: obj_atE)+ lemma captable_case_helper: "\<lbrakk> \<forall>sz cs. ob \<noteq> CNode sz cs \<rbrakk> \<Longrightarrow> (case ob of CNode sz cs \<Rightarrow> P sz cs | _ \<Rightarrow> Q) = Q" by (case_tac ob, simp_all add: not_ex[symmetric]) lemma null_filter_caps_of_stateD: "null_filter (caps_of_state s) p = Some c \<Longrightarrow> cte_wp_at (\<lambda>c'. c' = c \<and> c' \<noteq> cap.NullCap) p s" apply (simp add: null_filter_def split: if_split_asm) apply (drule caps_of_state_cteD) apply (simp add: cte_wp_at_def) done lemma caps_of_state_after_update: "obj_at (same_caps val) p s \<Longrightarrow> (caps_of_state (kheap_update (\<lambda>a b. if b = p then Some val else kheap s b) s)) = caps_of_state s" by (simp add: caps_of_state_cte_wp_at cte_wp_at_after_update cong: if_cong) lemma elim_CNode_case: "\<lbrakk> (case x of CNode sz ct \<Rightarrow> False | _ \<Rightarrow> True) \<rbrakk> \<Longrightarrow> (case x of CNode sz ct \<Rightarrow> f sz ct | _ \<Rightarrow> k) = k" by (simp split: Structures_A.kernel_object.split_asm) lemma no_fail_obj_at [wp]: "no_fail (obj_at \<top> ptr) (get_object ptr)" apply (simp add: get_object_def) apply (rule no_fail_pre, wp) apply (fastforce simp: obj_at_def) done lemma do_machine_op_obj_at[wp]: "\<lbrace>\<lambda>s. P (obj_at Q p s)\<rbrace> do_machine_op f \<lbrace>\<lambda>_ s. P (obj_at Q p s)\<rbrace>" by (clarsimp simp: do_machine_op_def split_def | wp)+ lemma dmo_cur_tcb[wp]: "\<lbrace>cur_tcb\<rbrace> do_machine_op f \<lbrace>\<lambda>_. cur_tcb\<rbrace>" apply (simp add: do_machine_op_def split_def) apply wp apply (clarsimp simp: cur_tcb_def) done lemma valid_irq_states_machine_state_updateI: "(\<And>irq. interrupt_states s irq = IRQInactive \<Longrightarrow> irq_masks m irq) \<Longrightarrow> valid_irq_states (s\<lparr>machine_state := m\<rparr>)" apply(simp add: valid_irq_states_def valid_irq_masks_def) done lemma valid_irq_statesE: "\<lbrakk>valid_irq_states s; (\<And> irq. interrupt_states s irq = IRQInactive \<Longrightarrow> irq_masks (machine_state s) irq) \<Longrightarrow> R\<rbrakk> \<Longrightarrow> R" by(auto simp: valid_irq_states_def valid_irq_masks_def) lemma cap_refs_respects_region_cong: "\<lbrakk>caps_of_state a = caps_of_state b; device_state (machine_state a) = device_state (machine_state b)\<rbrakk> \<Longrightarrow> cap_refs_respects_device_region a = cap_refs_respects_device_region b" by (simp add: cap_refs_respects_device_region_def cte_wp_at_caps_of_state dom_def cap_range_respects_device_region_def) lemmas device_region_congs[cong] = pspace_respects_region_cong cap_refs_respects_region_cong lemma dmo_invs1: assumes valid_mf: "\<And>P. \<lbrace>\<lambda>ms. P (device_state ms)\<rbrace> f \<lbrace>\<lambda>r ms. P (device_state ms)\<rbrace>" shows "\<lbrace>(\<lambda>s. \<forall>m. \<forall>(r,m')\<in>fst (f m). m = machine_state s \<longrightarrow> (\<forall>p. in_user_frame p s \<or> underlying_memory m' p = underlying_memory m p) \<and> ((\<forall>irq. (interrupt_states s irq = IRQInactive \<longrightarrow> irq_masks m' irq) \<or> (irq_masks m' irq = irq_masks m irq)))) and invs\<rbrace> do_machine_op f \<lbrace>\<lambda>_. invs\<rbrace>" apply (simp add: do_machine_op_def split_def) apply wp apply (clarsimp simp: invs_def cur_tcb_def valid_state_def valid_machine_state_def intro!: valid_irq_states_machine_state_updateI elim: valid_irq_statesE) apply (frule_tac P1 = "(=) (device_state (machine_state s))" in use_valid[OF _ valid_mf]) apply simp apply clarsimp apply (intro conjI) apply (fastforce simp: invs_def cur_tcb_def valid_state_def valid_machine_state_def intro: valid_irq_states_machine_state_updateI elim: valid_irq_statesE) apply fastforce done lemma dmo_invs: assumes valid_mf: "\<And>P. \<lbrace>\<lambda>ms. P (device_state ms)\<rbrace> f \<lbrace>\<lambda>r ms. P (device_state ms)\<rbrace>" shows "\<lbrace>(\<lambda>s. \<forall>m. \<forall>(r,m')\<in>fst (f m). (\<forall>p. in_user_frame p s \<or> underlying_memory m' p = underlying_memory m p) \<and> ((\<forall>irq. m = machine_state s \<longrightarrow> (interrupt_states s irq = IRQInactive \<longrightarrow> irq_masks m' irq) \<or> (irq_masks m' irq = irq_masks m irq)))) and invs\<rbrace> do_machine_op f \<lbrace>\<lambda>_. invs\<rbrace>" apply (wp dmo_invs1 valid_mf) apply clarsimp apply (drule spec, drule(1) bspec) apply simp done lemma as_user_bind[wp]: "as_user t (f >>= g) = (as_user t f) >>= (\<lambda>x. as_user t (g x))" apply (monad_eq simp: as_user_def select_f_def set_object_def get_object_def gets_the_def get_tcb_def) apply (clarsimp split: option.splits kernel_object.splits) apply (intro conjI impI allI; match premises in "kheap _ t = Some (TCB _)" \<Rightarrow> succeed \<bar> _ \<Rightarrow> fastforce) apply clarsimp apply (rename_tac value_g s tcb fail_g value_f fail_f) apply (rule_tac x="value_f" in exI) apply (rule_tac x="s\<lparr>kheap := kheap s(t \<mapsto> TCB (tcb\<lparr>tcb_arch := arch_tcb_context_set fail_f (tcb_arch tcb)\<rparr>))\<rparr>" in exI) apply fastforce apply clarsimp apply (rename_tac value_g ta s tcb value_f fail_g ko) apply (drule_tac x="ko" in spec) apply clarsimp apply (case_tac ko; blast?) apply (rename_tac tcb_2) apply (drule_tac x=tcb_2 in spec) apply clarsimp apply blast apply (rename_tac tcb_2) apply (case_tac "snd (f (arch_tcb_context_get (tcb_arch tcb_2)))") apply simp apply clarsimp apply (rule iffI) apply fastforce apply clarsimp apply (case_tac "kheap s' t = None") apply fastforce apply clarsimp apply (rename_tac ko) apply (case_tac ko; (solves auto)?) apply clarsimp apply blast done lemma as_user_typ_at[wp]: "\<lbrace>\<lambda>s. P (typ_at T p s)\<rbrace> as_user t m \<lbrace>\<lambda>rv s. P (typ_at T p s)\<rbrace>" unfolding as_user_def apply (wpsimp wp: set_object_wp_strong) apply (clarsimp simp: obj_at_def) done lemma as_user_no_del_ntfn[wp]: "\<lbrace>ntfn_at p\<rbrace> as_user t m \<lbrace>\<lambda>rv. ntfn_at p\<rbrace>" by (simp add: ntfn_at_typ, rule as_user_typ_at) lemma as_user_no_del_ep[wp]: "\<lbrace>ep_at p\<rbrace> as_user t m \<lbrace>\<lambda>rv. ep_at p\<rbrace>" by (simp add: ep_at_typ, rule as_user_typ_at) lemma set_simple_ko_tcb[wp]: "set_simple_ko f ep v \<lbrace> tcb_at t \<rbrace>" by (simp add: tcb_at_typ) wp lemma set_simple_ko_pred_tcb_at [wp]: "set_simple_ko g ep v \<lbrace> pred_tcb_at proj f t \<rbrace>" by(set_simple_ko_method wp_thm: set_object_at_obj2 simp_thm: pred_tcb_at_def) lemma set_endpoint_ep_at[wp]: "set_endpoint ptr val \<lbrace>ep_at ptr'\<rbrace>" by (simp add: ep_at_typ, wp) lemma set_notification_ntfn_at[wp]: "set_notification ptr val \<lbrace>ntfn_at ptr'\<rbrace>" by (simp add: ntfn_at_typ, wp) lemma cte_wp_at_neg2: "(\<not> cte_wp_at P p s) = (cte_at p s \<longrightarrow> cte_wp_at (\<lambda>cap. \<not> P cap) p s)" by (fastforce simp: cte_wp_at_def) lemma cte_wp_at_neg: "cte_wp_at (\<lambda>cap. \<not> P cap) p s = (cte_at p s \<and> \<not> cte_wp_at P p s)" by (fastforce simp: cte_wp_at_def) lemma valid_cte_at_neg_typ: assumes x: "\<And>P T p. \<lbrace>\<lambda>s. P (typ_at T p s)\<rbrace> f \<lbrace>\<lambda>rv s. P (typ_at T p s)\<rbrace>" shows "\<lbrace>\<lambda>s. \<not> cte_at p s\<rbrace> f \<lbrace>\<lambda>rv s. \<not> cte_at p s\<rbrace>" apply (simp add: cte_at_typ) apply (rule hoare_vcg_conj_lift [OF x]) apply (simp only: imp_conv_disj) apply (rule hoare_vcg_disj_lift [OF x]) apply (rule hoare_vcg_prop) done lemma ex_nonz_cap_to_pres: assumes y: "\<And>P p. \<lbrace>cte_wp_at P p\<rbrace> f \<lbrace>\<lambda>rv. cte_wp_at P p\<rbrace>" shows "\<lbrace>ex_nonz_cap_to p\<rbrace> f \<lbrace>\<lambda>rv. ex_nonz_cap_to p\<rbrace>" apply (simp only: ex_nonz_cap_to_def not_ex) apply (intro hoare_vcg_disj_lift hoare_vcg_ex_lift y hoare_vcg_all_lift valid_cte_at_neg_typ) done lemma set_simple_ko_ex_cap[wp]: "set_simple_ko f p' v \<lbrace>ex_nonz_cap_to p\<rbrace>" by (wp ex_nonz_cap_to_pres) crunch it[wp]: set_simple_ko "\<lambda>s. P (idle_thread s)" (wp: crunch_wps simp: crunch_simps) lemma set_simple_ko_idle[wp]: "\<lbrace>obj_at (\<lambda>ko. partial_inv f ko \<noteq> None) ptr and valid_idle\<rbrace> set_simple_ko f ptr ep \<lbrace>\<lambda>_. valid_idle\<rbrace>" by (set_simple_ko_method simp_thm: obj_at_def valid_idle_def pred_tcb_at_def wp_thm: set_object_wp) (* FIXME-NTFN *) lemma ep_redux_simps: "valid_ep (case xs of [] \<Rightarrow> Structures_A.IdleEP | y # ys \<Rightarrow> Structures_A.SendEP (y # ys)) = (\<lambda>s. distinct xs \<and> (\<forall>t\<in>set xs. tcb_at t s))" "valid_ep (case xs of [] \<Rightarrow> Structures_A.IdleEP | y # ys \<Rightarrow> Structures_A.RecvEP (y # ys)) = (\<lambda>s. distinct xs \<and> (\<forall>t\<in>set xs. tcb_at t s))" "valid_ntfn (ntfn\<lparr>ntfn_obj := (case xs of [] \<Rightarrow> Structures_A.IdleNtfn | y # ys \<Rightarrow> Structures_A.WaitingNtfn (y # ys))\<rparr>) = (\<lambda>s. distinct xs \<and> (\<forall>t\<in>set xs. tcb_at t s) \<and> (case ntfn_bound_tcb ntfn of Some t \<Rightarrow> tcb_at t s \<and> (case xs of y # ys \<Rightarrow> xs = [t] | _ \<Rightarrow> True) | _ \<Rightarrow> True))" "ep_q_refs_of (case xs of [] \<Rightarrow> Structures_A.IdleEP | y # ys \<Rightarrow> Structures_A.SendEP (y # ys)) = (set xs \<times> {EPSend})" "ep_q_refs_of (case xs of [] \<Rightarrow> Structures_A.IdleEP | y # ys \<Rightarrow> Structures_A.RecvEP (y # ys)) = (set xs \<times> {EPRecv})" "ntfn_q_refs_of (case xs of [] \<Rightarrow> Structures_A.IdleNtfn | y # ys \<Rightarrow> Structures_A.WaitingNtfn (y # ys)) = (set xs \<times> {NTFNSignal})" by (fastforce split: list.splits option.splits simp: valid_ep_def valid_ntfn_def valid_bound_tcb_def intro!: ext)+ crunch arch[wp]: set_simple_ko "\<lambda>s. P (arch_state s)" (wp: crunch_wps simp: crunch_simps) crunch irq_node_inv[wp]: set_simple_ko "\<lambda>s. P (interrupt_irq_node s)" (wp: crunch_wps) lemma set_simple_ko_global_refs [wp]: "set_simple_ko f ntfn p \<lbrace>valid_global_refs\<rbrace>" by (rule valid_global_refs_cte_lift; wpsimp) lemma set_simple_ko_reply[wp]: "set_simple_ko f p ep \<lbrace>valid_reply_caps\<rbrace>" by (wp valid_reply_caps_st_cte_lift) lemma set_simple_ko_reply_masters[wp]: "set_simple_ko f p ep \<lbrace>valid_reply_masters\<rbrace>" by (wp valid_reply_masters_cte_lift) lemma obj_at_ko_atE: "\<lbrakk> obj_at P ptr s; ko_at k ptr s; P k \<Longrightarrow> Q \<rbrakk> \<Longrightarrow> Q" by (clarsimp simp: obj_at_def) crunch interrupt_states[wp]: set_simple_ko "\<lambda>s. P (interrupt_states s)" (wp: crunch_wps) lemma set_object_non_arch: "arch_obj_pred P' \<Longrightarrow> \<lbrace>(\<lambda>s. P (obj_at P' p' s)) and K(non_arch_obj ko) and obj_at non_arch_obj p \<rbrace> set_object p ko \<lbrace>\<lambda>r s. P (obj_at P' p' s)\<rbrace>" unfolding set_object_def apply wp apply clarsimp apply (erule_tac P=P in rsubst) apply (clarsimp simp: obj_at_def) by (rule arch_obj_predE) lemma set_object_non_pagetable: "vspace_obj_pred P' \<Longrightarrow> \<lbrace>(\<lambda>s. P (obj_at P' p' s)) and K(non_vspace_obj ko) and obj_at non_vspace_obj p \<rbrace> set_object p ko \<lbrace>\<lambda>r s. P (obj_at P' p' s)\<rbrace>" unfolding set_object_def apply wp apply clarsimp apply (erule_tac P=P in rsubst) apply (clarsimp simp: obj_at_def) by (rule vspace_obj_predE) lemma set_object_memory[wp]: "\<lbrace>\<lambda>s. P (underlying_memory (machine_state s))\<rbrace> set_object p ko \<lbrace>\<lambda>_ s. P (underlying_memory (machine_state s))\<rbrace>" unfolding set_object_def apply wp by simp end locale non_aobj_op = fixes f assumes aobj_at: "\<And>P P' p. arch_obj_pred P' \<Longrightarrow> \<lbrace>\<lambda>s. P (obj_at P' p s)\<rbrace> f \<lbrace>\<lambda>r s. P (obj_at P' p s)\<rbrace>" and arch_state[wp]: "\<And>P. \<lbrace>\<lambda>s. P (arch_state s)\<rbrace> f \<lbrace>\<lambda>r s. P (arch_state s)\<rbrace>" context non_aobj_op begin lemma valid_arch_state[wp]:"\<lbrace>valid_arch_state\<rbrace> f \<lbrace>\<lambda>_. valid_arch_state\<rbrace>" by (rule valid_arch_state_lift_aobj_at; wp aobj_at; simp) end locale non_vspace_op = fixes f assumes vsobj_at: "\<And>P P' p. vspace_obj_pred P' \<Longrightarrow> \<lbrace>\<lambda>s. P (obj_at P' p s)\<rbrace> f \<lbrace>\<lambda>r s. P (obj_at P' p s)\<rbrace>" and arch_state'[wp]: "\<And>P. \<lbrace>\<lambda>s. P (arch_state s)\<rbrace> f \<lbrace>\<lambda>r s. P (arch_state s)\<rbrace>" sublocale non_aobj_op < non_vspace_op apply (unfold_locales) apply (auto simp: vspace_pred_imp arch_state aobj_at) done context non_vspace_op begin lemma valid_vspace_obj[wp]:"f \<lbrace>valid_vspace_objs\<rbrace>" by (rule valid_vspace_objs_lift_weak; wp vsobj_at; simp) lemma vs_lookup[wp]: "f \<lbrace>\<lambda>s. P (vs_lookup s)\<rbrace>" by (rule vs_lookup_vspace_obj_at_lift; wp vsobj_at; simp) lemma vs_lookup_pages[wp]: "f \<lbrace>\<lambda>s. P (vs_lookup_pages s)\<rbrace>" by (rule vs_lookup_pages_vspace_obj_at_lift; wp vsobj_at; simp) lemma valid_global_objs[wp]: "f \<lbrace>valid_global_objs\<rbrace>" by (rule valid_global_objs_lift_weak, (wp vsobj_at)+) lemma valid_global_vspace_mappings[wp]: "f \<lbrace>valid_global_vspace_mappings\<rbrace>" by (rule valid_global_vspace_mappings_lift, (wp vsobj_at)+) lemma valid_asid_map[wp]: "f \<lbrace>valid_asid_map\<rbrace>" by (rule valid_asid_map_lift, (wp vsobj_at)+) lemma valid_kernel_mappings[wp]: "f \<lbrace>valid_kernel_mappings\<rbrace>" by (rule valid_kernel_mappings_lift, (wp vsobj_at)+) lemma equal_kernel_mappings[wp]: "f \<lbrace>equal_kernel_mappings\<rbrace>" by (rule equal_kernel_mappings_lift; wp vsobj_at) lemma in_user_frame[wp]:"f \<lbrace>in_user_frame p\<rbrace>" by (rule in_user_frame_obj_pred_lift; wp vsobj_at; simp) end locale non_mem_op = fixes f assumes memory[wp]: "\<And>P. f \<lbrace>\<lambda>s. P (underlying_memory (machine_state s))\<rbrace>" (* non_vspace_op version *) locale non_vspace_non_mem_op = non_vspace_op f + non_mem_op f for f begin lemma valid_machine_state[wp]: "\<lbrace>valid_machine_state\<rbrace> f \<lbrace>\<lambda>rv. valid_machine_state\<rbrace>" unfolding valid_machine_state_def by (wp hoare_vcg_disj_lift hoare_vcg_all_lift vsobj_at memory) end locale non_aobj_non_mem_op = non_aobj_op f + non_mem_op f for f sublocale non_aobj_non_mem_op < non_vspace_non_mem_op .. (* non_vspace_op version *) locale non_cap_op = fixes f assumes caps[wp]: "\<And>P. f \<lbrace>\<lambda>s. P (caps_of_state s)\<rbrace>" locale non_vspace_non_cap_op = non_vspace_op f + non_cap_op f for f begin lemma valid_arch_caps[wp]: "\<lbrace>valid_arch_caps\<rbrace> f \<lbrace>\<lambda>_. valid_arch_caps\<rbrace>" by (rule valid_arch_caps_lift_weak[OF arch_state' vsobj_at caps]) end locale non_aobj_non_cap_op = non_aobj_op f + non_cap_op f for f sublocale non_aobj_non_cap_op < non_vspace_non_cap_op .. (* non_vspace_op version *) locale non_vspace_non_cap_non_mem_op = non_vspace_non_mem_op f + non_vspace_non_cap_op f for f locale non_aobj_non_cap_non_mem_op = non_aobj_non_mem_op f + non_aobj_non_cap_op f for f sublocale non_aobj_non_cap_non_mem_op < non_vspace_non_cap_non_mem_op .. lemma shows sts_caps_of_state[wp]: "set_thread_state t st \<lbrace>\<lambda>s. P (caps_of_state s)\<rbrace>" and set_bound_caps_of_state[wp]: "set_bound_notification t e \<lbrace>\<lambda>s. P (caps_of_state s)\<rbrace>" and as_user_caps_of_state[wp]: "as_user p f \<lbrace>\<lambda>s. P (caps_of_state s)\<rbrace>" unfolding set_thread_state_def set_bound_notification_def as_user_def set_object_def get_object_def set_mrs_def apply (all \<open>(wp | wpc | simp)+ ; clarsimp, erule rsubst[where P=P], rule cte_wp_caps_of_lift\<close>) by (auto simp: cte_wp_at_cases2 tcb_cnode_map_def dest!: get_tcb_SomeD) lemma store_word_offs_caps_of_state[wp]: "store_word_offs a b c \<lbrace>\<lambda>s. P (caps_of_state s)\<rbrace>" unfolding store_word_offs_def do_machine_op_def[abs_def] by wpsimp lemma set_mrs_caps_of_state[wp]: "set_mrs thread buf msgs \<lbrace>\<lambda>s. P (caps_of_state s)\<rbrace>" unfolding set_mrs_def set_object_def[abs_def] get_object_def apply (wp mapM_x_inv_wp | wpc | simp add: zipWithM_x_mapM_x split del: if_split | clarsimp)+ apply (safe; erule rsubst[where P=P], rule cte_wp_caps_of_lift) by (auto simp: cte_wp_at_cases2 tcb_cnode_map_def dest!: get_tcb_SomeD) interpretation set_simple_ko: non_aobj_non_cap_non_mem_op "set_simple_ko c p ep" + sts: non_aobj_non_cap_non_mem_op "set_thread_state p st" + sbn: non_aobj_non_cap_non_mem_op "set_bound_notification p b" + as_user: non_aobj_non_cap_non_mem_op "as_user p g" + thread_set: non_aobj_non_mem_op "thread_set f p" + set_cap: non_aobj_non_mem_op "set_cap cap p'" apply (all \<open>unfold_locales; (wp ; fail)?\<close>) unfolding set_simple_ko_def set_thread_state_def set_bound_notification_def thread_set_def set_cap_def[simplified split_def] as_user_def set_mrs_def apply - apply (all \<open>(wp set_object_non_arch[THEN hoare_set_object_weaken_pre] get_object_wp | wpc | simp split del: if_split)+\<close>) apply (auto simp: obj_at_def[abs_def] partial_inv_def the_equality split: Structures_A.kernel_object.splits)[1] by (fastforce simp: obj_at_def[abs_def] a_type_def split: Structures_A.kernel_object.splits)+ lemmas set_cap_arch[wp] = set_cap.arch_state interpretation store_word_offs: non_aobj_non_cap_op "store_word_offs a b c" apply unfold_locales unfolding store_word_offs_def do_machine_op_def[abs_def] by wpsimp+ lemma store_word_offs_obj_at_P[wp]: "store_word_offs a b c \<lbrace>\<lambda>s. P (obj_at P' p s)\<rbrace>" unfolding store_word_offs_def by (wp | fastforce)+ interpretation set_mrs: non_aobj_non_cap_op "set_mrs thread buf msgs" apply unfold_locales apply (all \<open>(wp ; fail)?\<close>) unfolding set_mrs_def set_object_def get_object_def apply (all \<open>(wp mapM_x_inv_wp | wpc | simp add: zipWithM_x_mapM_x split del: if_split | clarsimp)+\<close>) apply (rule drop_imp) apply (clarsimp simp: obj_at_def get_tcb_def split: kernel_object.splits option.splits) subgoal for _ P' by (subst arch_obj_predE[where P="P'"]) auto done lemma valid_irq_handlers_lift: assumes x: "\<And>P. f \<lbrace>\<lambda>s. P (caps_of_state s)\<rbrace>" assumes y: "\<And>P. f \<lbrace>\<lambda>s. P (interrupt_states s)\<rbrace>" shows "f \<lbrace>valid_irq_handlers\<rbrace>" apply (simp add: valid_irq_handlers_def irq_issued_def) apply (rule hoare_use_eq [where f=caps_of_state, OF x y]) done lemmas set_simple_ko_valid_irq_handlers[wp] = valid_irq_handlers_lift [OF set_simple_ko_caps_of_state set_simple_ko_interrupt_states] crunch irq_node[wp]: set_simple_ko "\<lambda>s. P (interrupt_irq_node s)" lemmas hoare_use_eq_irq_node = hoare_use_eq[where f=interrupt_irq_node] lemma cap_table_at_lift_valid: "\<lbrakk> \<And>T. f \<lbrace>typ_at T p\<rbrace> \<rbrakk> \<Longrightarrow> f \<lbrace>cap_table_at n p\<rbrace>" by (simp add: cap_table_at_typ) lemmas cap_table_at_lift_irq = hoare_use_eq_irq_node [OF _ cap_table_at_lift_valid] crunch interrupt_states[wp]: set_notification "\<lambda>s. P (interrupt_states s)" (wp: crunch_wps) lemma set_simple_ko_only_idle [wp]: "set_simple_ko f p ntfn \<lbrace>only_idle\<rbrace>" by (wp only_idle_lift) lemma set_simple_ko_cap_refs_kernel_window[wp]: "set_simple_ko f p ep \<lbrace>cap_refs_in_kernel_window\<rbrace>" by (set_simple_ko_method wp_thm: set_object_cap_refs_in_kernel_window[THEN hoare_set_object_weaken_pre] get_object_wp simp_thm: is_ep_def is_ntfn_def) lemma set_simple_ko_cap_refs_respects_device_region[wp]: "set_simple_ko f p ep \<lbrace>cap_refs_respects_device_region\<rbrace>" by (set_simple_ko_method wp_thm: set_object_cap_refs_respects_device_region[THEN hoare_set_object_weaken_pre] get_object_wp simp_thm: is_ep_def is_ntfn_def) crunch v_ker_map[wp]: set_simple_ko "valid_kernel_mappings" (ignore: set_object wp: set_object_v_ker_map crunch_wps simp: set_simple_ko_def) (* There are two wp rules for preserving valid_ioc over set_object. First, the more involved rule for CNodes and TCBs *) lemma set_object_valid_ioc_caps: "\<lbrace>\<lambda>s. valid_ioc s \<and> typ_at (a_type obj) ptr s \<and> (\<forall>b. is_original_cap s (ptr,b) \<longrightarrow> null_filter (cap_of obj) b \<noteq> None)\<rbrace> set_object ptr obj \<lbrace>\<lambda>_ s. valid_ioc s\<rbrace>" apply (wpsimp wp: set_object_wp_strong) apply (clarsimp simp add: valid_ioc_def) apply (drule spec, drule spec, erule impE, assumption) apply (case_tac "a=ptr", simp_all add: cte_wp_at_cases) apply (drule spec, erule impE, assumption) apply (erule disjE) apply (rule disjI1) apply (clarsimp simp add: obj_at_def a_type_simps) apply (fastforce simp: a_type_def cap_of_def null_filter_def split: Structures_A.kernel_object.splits if_split_asm) apply (rule disjI2) apply (clarsimp simp add: obj_at_def a_type_simps) apply (fastforce simp: a_type_def cap_of_def tcb_cnode_map_def null_filter_def split: Structures_A.kernel_object.splits if_split_asm) done (* Second, the simpler rule suitable for all objects except CNodes and TCBs. *) lemma set_object_valid_ioc_no_caps: "\<lbrace>\<lambda>s. valid_ioc s \<and> typ_at (a_type obj) ptr s \<and> \<not> is_tcb obj \<and> (\<forall>n. \<not> is_cap_table n obj) \<rbrace> set_object ptr obj \<lbrace>\<lambda>_ s. valid_ioc s\<rbrace>" apply (wpsimp wp: set_object_wp_strong simp: obj_at_def) apply (clarsimp simp add: valid_ioc_def cte_wp_at_cases is_tcb) apply (drule spec, drule spec, erule impE, assumption) apply (elim disjE) prefer 2 apply (fastforce simp: obj_at_def a_type_def split: Structures_A.kernel_object.splits if_split_asm) apply (fastforce simp: obj_at_def a_type_def is_cap_table_def well_formed_cnode_n_def split: Structures_A.kernel_object.splits if_split_asm) done lemma set_simple_ko_valid_ioc[wp]: "set_simple_ko f ptr val \<lbrace>valid_ioc\<rbrace>" by (set_simple_ko_method wp_thm: set_object_valid_ioc_no_caps[THEN hoare_set_object_weaken_pre] get_object_wp simp_thm: is_tcb_def is_cap_table_def) lemma set_object_machine_state[wp]: "set_object p ko \<lbrace>\<lambda>s. P (machine_state s)\<rbrace>" by (wpsimp wp: set_object_wp_strong) lemma valid_irq_states_triv: assumes irqs: "\<And>P. \<lbrace>\<lambda>s. P (interrupt_states s)\<rbrace> f \<lbrace>\<lambda>_ s. P (interrupt_states s)\<rbrace>" assumes ms: "\<And>P. \<lbrace>\<lambda>s. P (machine_state s)\<rbrace> f \<lbrace>\<lambda>_ s. P (machine_state s)\<rbrace>" shows "\<lbrace> valid_irq_states \<rbrace> f \<lbrace>\<lambda>_. valid_irq_states \<rbrace>" apply(clarsimp simp: valid_def valid_irq_states_def valid_irq_masks_def) apply(case_tac "interrupt_states s irq = IRQInactive") apply(erule use_valid[OF _ ms]) apply blast apply(drule_tac P1="\<lambda>x. x irq \<noteq> IRQInactive" in use_valid[OF _ irqs]) apply assumption by blast crunch valid_irq_states[wp]: set_simple_ko "valid_irq_states" (wp: crunch_wps simp: crunch_simps rule: valid_irq_states_triv) crunch valid_irq_states[wp]: set_cap "valid_irq_states" (wp: crunch_wps simp: crunch_simps) crunch valid_irq_states[wp]: thread_set "valid_irq_states" (wp: crunch_wps simp: crunch_simps) crunch valid_irq_states[wp]: set_thread_state, set_bound_notification "valid_irq_states" (wp: crunch_wps simp: crunch_simps) lemma set_ntfn_minor_invs: "\<lbrace>invs and ntfn_at ptr and obj_at (\<lambda>ko. refs_of ko = ntfn_q_refs_of (ntfn_obj val) \<union> ntfn_bound_refs (ntfn_bound_tcb val)) ptr and valid_ntfn val and (\<lambda>s. \<forall>typ. (idle_thread s, typ) \<notin> ntfn_q_refs_of (ntfn_obj val)) and (\<lambda>s. live (Notification val) \<longrightarrow> ex_nonz_cap_to ptr s)\<rbrace> set_notification ptr val \<lbrace>\<lambda>rv. invs\<rbrace>" apply (simp add: invs_def valid_state_def valid_pspace_def) apply (wp set_simple_ko_valid_objs valid_irq_node_typ valid_irq_handlers_lift valid_ioports_lift) apply (clarsimp simp: ntfn_at_def2 elim!: rsubst[where P=sym_refs] intro!: ext dest!: obj_at_state_refs_ofD) done crunch asid_map[wp]: set_bound_notification "valid_asid_map" lemma dmo_aligned[wp]: "do_machine_op f \<lbrace>pspace_aligned\<rbrace>" apply (simp add: do_machine_op_def split_def) apply (wp select_wp) apply (clarsimp simp: pspace_aligned_def) done lemma do_machine_op_result[wp]: "\<lbrace>P\<rbrace> mop \<lbrace>\<lambda>rv s. Q rv\<rbrace> \<Longrightarrow> \<lbrace>\<lambda>s. P (machine_state s)\<rbrace> do_machine_op mop \<lbrace>\<lambda>rv s. Q rv\<rbrace>" apply (simp add: do_machine_op_def split_def) apply wp apply clarsimp apply (erule(2) use_valid) done lemma dmo_zombies[wp]: "do_machine_op oper \<lbrace>zombies_final\<rbrace>" apply (simp add: do_machine_op_def split_def) apply wp apply (clarsimp elim!: zombies_final_pspaceI) done lemma dmo_iflive[wp]: "do_machine_op oper \<lbrace>if_live_then_nonz_cap\<rbrace>" apply (simp add: do_machine_op_def split_def) apply wp apply (clarsimp elim!: iflive_pspaceI) done lemma dmo_ifunsafe[wp]: "do_machine_op oper \<lbrace>if_unsafe_then_cap\<rbrace>" apply (simp add: do_machine_op_def split_def) apply wp apply (clarsimp elim!: ifunsafe_pspaceI) done lemma dmo_refs_of[wp]: "do_machine_op oper \<lbrace>\<lambda>s. P (state_refs_of s)\<rbrace>" apply (simp add: do_machine_op_def split_def) apply wp apply (clarsimp elim!: state_refs_of_pspaceI) done lemma dmo_hyp_refs_of[wp]: "do_machine_op oper \<lbrace>\<lambda>s. P (state_hyp_refs_of s)\<rbrace>" apply (simp add: do_machine_op_def split_def) apply wp apply (clarsimp elim!: state_hyp_refs_of_pspaceI) done crunch it[wp]: do_machine_op "\<lambda>s. P (idle_thread s)" crunch irq_node[wp]: do_machine_op "\<lambda>s. P (interrupt_irq_node s)" crunch cte_wp_at[wp]: do_machine_op "\<lambda>s. P (cte_wp_at P' c s)" (wp: crunch_wps) crunch valid_idle[wp]: do_machine_op "valid_idle" (wp: crunch_wps simp: crunch_simps) crunch reply[wp]: do_machine_op "valid_reply_caps" crunch reply_masters[wp]: do_machine_op "valid_reply_masters" crunch valid_irq_handlers[wp]: do_machine_op "valid_irq_handlers" crunch valid_global_objs[wp]: do_machine_op "valid_global_objs" crunch valid_global_vspace_mappings[wp]: do_machine_op "valid_global_vspace_mappings" crunch valid_arch_caps[wp]: do_machine_op "valid_arch_caps" lemma dmo_cap_to[wp]: "do_machine_op mop \<lbrace>ex_nonz_cap_to p\<rbrace>" by (simp add: ex_nonz_cap_to_def, wp hoare_vcg_ex_lift) lemma dmo_st_tcb [wp]: "do_machine_op f \<lbrace>pred_tcb_at proj P t\<rbrace>" apply (simp add: do_machine_op_def split_def) apply (wp select_wp) apply (clarsimp simp: pred_tcb_at_def obj_at_def) done crunch ct[wp]: do_machine_op "\<lambda>s. P (cur_thread s)" (wp: select_wp) lemma do_machine_op_arch [wp]: "do_machine_op f \<lbrace>\<lambda>s. P (arch_state s)\<rbrace>" apply (simp add: do_machine_op_def split_def) apply wp apply simp done crunches do_machine_op for aobjs_of[wp]: "\<lambda>s. P (aobjs_of s)" lemma do_machine_op_valid_arch [wp]: "do_machine_op f \<lbrace>valid_arch_state\<rbrace>" by (rule valid_arch_state_lift; wpsimp) lemma do_machine_op_vs_lookup [wp]: "do_machine_op f \<lbrace>\<lambda>s. P (vs_lookup s)\<rbrace>" apply (rule vs_lookup_vspace_obj_at_lift) apply (simp add: do_machine_op_def split_def) apply (wp | simp)+ done lemma dmo_inv: assumes R: "\<And>P. \<lbrace>P\<rbrace> f \<lbrace>\<lambda>_. P\<rbrace>" shows "\<lbrace>P\<rbrace> do_machine_op f \<lbrace>\<lambda>_. P\<rbrace>" apply (simp add: do_machine_op_def split_def) apply (wp select_f_wp) apply (clarsimp simp del: ) apply (drule in_inv_by_hoareD [OF R]) apply simp done lemma dom_objs [wp]: "do_machine_op f \<lbrace>valid_objs\<rbrace>" apply (simp add: do_machine_op_def split_def) apply (wp select_wp) apply (fastforce intro: valid_objs_pspaceI) done lemma tcb_cap_wp_at: "\<lbrakk>tcb_at t s; valid_objs s; ref \<in> dom tcb_cap_cases; \<forall>cap st getF setF restr. tcb_cap_cases ref = Some (getF, setF, restr) \<and> restr t st cap \<longrightarrow> Q cap\<rbrakk> \<Longrightarrow> cte_wp_at Q (t, ref) s" apply (clarsimp simp: cte_wp_at_cases tcb_at_def dest!: get_tcb_SomeD) apply (rename_tac getF setF restr) apply (erule(1) valid_objsE) apply (clarsimp simp add: valid_obj_def valid_tcb_def) apply (erule_tac x="(getF, setF, restr)" in ballE) apply (fastforce simp add: ranI)+ done lemma tcb_cap_valid_caps_of_stateD: "\<lbrakk> caps_of_state s p = Some cap; valid_objs s \<rbrakk> \<Longrightarrow> tcb_cap_valid cap p s" apply (rule cte_wp_tcb_cap_valid) apply (simp add: cte_wp_at_caps_of_state) apply assumption done lemma add_mask_eq: "\<lbrakk>is_aligned (w::'a::len word) n; x \<le> 2 ^ n - 1; n < len_of TYPE('a)\<rbrakk> \<Longrightarrow> (w + x) && mask n = x" by (drule is_aligned_add_helper) auto lemma thread_get_wp': "\<lbrace>\<lambda>s. \<forall>tcb. ko_at (TCB tcb) ptr s \<longrightarrow> P (f tcb) s\<rbrace> thread_get f ptr \<lbrace>P\<rbrace>" apply (simp add: thread_get_def) apply wp apply clarsimp apply (clarsimp simp: obj_at_def dest!: get_tcb_SomeD) done crunch valid_ioc[wp]: do_machine_op valid_ioc crunch inv[wp]: get_irq_slot "P" lemmas set_object_typ_ats [wp] = abs_typ_at_lifts [OF set_object_typ_at] lemma typ_at_pspace_aligned: assumes type_invs: "\<And>T p. f \<lbrace>typ_at T p\<rbrace>" assumes dom_shrink: "\<And>x. f \<lbrace>\<lambda>s. x \<notin> dom (kheap s)\<rbrace>" shows "f \<lbrace>pspace_aligned\<rbrace>" apply (clarsimp simp: valid_def pspace_aligned_def) apply (drule_tac x = x in bspec) subgoal indom apply (rule ccontr) apply (drule(1) use_valid[OF _ dom_shrink]) apply force done apply (frule(1) indom) apply (clarsimp simp: dom_def obj_bits_T) apply (drule use_valid[OF _ type_invs]) apply (simp add: obj_at_def) apply (intro exI conjI, simp+) apply (simp add: obj_at_def) done lemmas set_object_typ_at[wp] = set_object_typ_at[where P="\<lambda>x. x"] lemma set_object_dom_shrink[wp]: "set_object pt obj \<lbrace>\<lambda>s. p \<notin> dom (kheap s)\<rbrace>" apply (wp set_object_typ_at get_object_wp | simp add: set_object_def)+ apply (clarsimp simp: obj_at_def split: if_split_asm) done lemma set_aobject_zombies[wp]: "set_object ptr (ArchObj obj) \<lbrace>\<lambda>s. zombies_final s\<rbrace>" apply (wp set_object_zombies[THEN hoare_set_object_weaken_pre]) apply (clarsimp simp: obj_at_def same_caps_def a_type_def split: kernel_object.split_asm if_split_asm) done lemma set_aobject_state_refs[wp]: "set_object p (ArchObj obj) \<lbrace>\<lambda>s. P (state_refs_of s)\<rbrace>" apply (wpsimp wp: set_object_wp_strong simp: obj_at_def a_type_def split: kernel_object.split_asm if_split_asm) apply (erule rsubst [where P=P]) apply (rule ext) by (clarsimp simp: state_refs_of_def) lemma set_aobject_caps_of_state [wp]: "set_object ptr (ArchObj obj) \<lbrace>\<lambda>s. P (caps_of_state s)\<rbrace>" apply (wpsimp wp: set_object_wp_strong simp: obj_at_def a_type_def) apply (subst cte_wp_caps_of_lift) prefer 2 apply assumption subgoal for _ y by (cases y, auto simp: cte_wp_at_cases a_type_def) done lemma set_aobject_cte_wp_at: "set_object ptr (ArchObj obj) \<lbrace>\<lambda>s. P (cte_wp_at P' p s)\<rbrace>" apply (simp add: cte_wp_at_caps_of_state) apply wp done lemma set_object_is_original_cap[wp]: "set_object a b \<lbrace>\<lambda>s. P (is_original_cap s)\<rbrace>" by (wpsimp wp: get_object_wp simp: set_object_def) lemma set_aobject_valid_mdb[wp]: "set_object ptr (ArchObj obj) \<lbrace>\<lambda>s. valid_mdb s\<rbrace>" apply (rule valid_mdb_lift) apply (wp set_object_no_cdt) apply (clarsimp simp: set_object_def) apply (wp get_object_wp | simp)+ done lemma set_aobject_pred_tcb_at[wp]: "set_object ptr (ArchObj obj) \<lbrace>pred_tcb_at proj P t\<rbrace>" apply (simp add: set_object_def) apply (wp get_object_wp) apply (clarsimp simp: pred_tcb_at_def obj_at_def a_type_def) done lemma set_aobject_cur_tcb [wp]: "set_object ptr (ArchObj obj) \<lbrace>\<lambda>s. cur_tcb s\<rbrace>" unfolding cur_tcb_def by (rule hoare_lift_Pf [where f=cur_thread]) wp+ crunch arch [wp]: set_object "\<lambda>s. P (arch_state s)" (wp: get_object_wp) lemma set_aobject_valid_idle[wp]: "set_object ptr (ArchObj obj) \<lbrace>\<lambda>s. valid_idle s\<rbrace>" by (wpsimp wp: valid_idle_lift) lemma set_aobject_reply_caps[wp]: "set_object ptr (ArchObj obj) \<lbrace>\<lambda>s. valid_reply_caps s\<rbrace>" by (wp valid_reply_caps_st_cte_lift) lemma set_aobject_reply_masters[wp]: "set_object ptr (ArchObj obj) \<lbrace>valid_reply_masters\<rbrace>" by (wp valid_reply_masters_cte_lift) crunch arch [wp]: set_object "\<lambda>s. P (arch_state s)" (wp: crunch_wps) crunch idle [wp]: set_object "\<lambda>s. P (idle_thread s)" (wp: crunch_wps) crunch irq [wp]: set_object "\<lambda>s. P (interrupt_irq_node s)" (wp: crunch_wps) crunch interrupt_states[wp]: set_object "\<lambda>s. P (interrupt_states s)" (wp: crunch_wps) end
{ "pile_set_name": "Github" }
package com.yuqiyu.chapter25; import org.junit.Test; import org.junit.runner.RunWith; import org.springframework.boot.test.context.SpringBootTest; import org.springframework.test.context.junit4.SpringRunner; @RunWith(SpringRunner.class) @SpringBootTest public class Chapter25ApplicationTests { @Test public void contextLoads() { } }
{ "pile_set_name": "Github" }
using UnityEngine; namespace BehaviorDesigner.Runtime.Tasks.Basic.UnityParticleSystem { [TaskCategory("Basic/ParticleSystem")] [TaskDescription("Is the Particle System stopped?")] public class IsStopped : Conditional { [Tooltip("The GameObject that the task operates on. If null the task GameObject is used.")] public SharedGameObject targetGameObject; private ParticleSystem particleSystem; private GameObject prevGameObject; public override void OnStart() { var currentGameObject = GetDefaultGameObject(targetGameObject.Value); if (currentGameObject != prevGameObject) { particleSystem = currentGameObject.GetComponent<ParticleSystem>(); prevGameObject = currentGameObject; } } public override TaskStatus OnUpdate() { if (particleSystem == null) { Debug.LogWarning("ParticleSystem is null"); return TaskStatus.Failure; } return particleSystem.isStopped ? TaskStatus.Success : TaskStatus.Failure; } public override void OnReset() { targetGameObject = null; } } }
{ "pile_set_name": "Github" }
import { RequestType, RequestHandler, HandlerResult, CancellationToken } from 'vscode-jsonrpc'; export interface ConfigurationClientCapabilities { /** * The workspace client capabilities */ workspace: { /** * The client supports `workspace/configuration` requests. */ configuration?: boolean; }; } /** * The 'workspace/configuration' request is sent from the server to the client to fetch a certain * configuration setting. */ export declare namespace ConfigurationRequest { const type: RequestType<ConfigurationParams, any[], void, void>; type HandlerSignature = RequestHandler<ConfigurationParams, any[], void>; type MiddlewareSignature = (params: ConfigurationParams, token: CancellationToken, next: HandlerSignature) => HandlerResult<any[], void>; } export interface ConfigurationItem { /** * The scope to get the configuration section for. */ scopeUri?: string; /** * The configuration section asked for. */ section?: string; } /** * The parameters of a configuration request. */ export interface ConfigurationParams { items: ConfigurationItem[]; }
{ "pile_set_name": "Github" }
@{ Layout = "_Layout"; }
{ "pile_set_name": "Github" }
global.this = typeof this
{ "pile_set_name": "Github" }
-- -- Created by SQL::Translator::Producer::PostgreSQL -- Created on Tue May 29 19:00:46 2018 -- ; -- -- Table: bugs -- CREATE TABLE bugs ( id serial NOT NULL, bugid text NOT NULL, title text, priority text, assigned boolean, assignee text, open boolean, status text, resolution text, existing boolean DEFAULT '1' NOT NULL, refreshed boolean DEFAULT '0' NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT bugs_bugid UNIQUE (bugid) ); ; -- -- Table: gru_tasks -- CREATE TABLE gru_tasks ( id serial NOT NULL, taskname text NOT NULL, args text NOT NULL, run_at timestamp NOT NULL, priority integer NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id) ); CREATE INDEX gru_tasks_run_at_reversed on gru_tasks (run_at DESC); ; -- -- Table: job_group_parents -- CREATE TABLE job_group_parents ( id serial NOT NULL, name text NOT NULL, default_size_limit_gb integer, default_keep_logs_in_days integer, default_keep_important_logs_in_days integer, default_keep_results_in_days integer, default_keep_important_results_in_days integer, default_priority integer, sort_order integer, description text, build_version_sort boolean DEFAULT '1' NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT job_group_parents_name UNIQUE (name) ); ; -- -- Table: job_modules -- CREATE TABLE job_modules ( id serial NOT NULL, job_id integer NOT NULL, name text NOT NULL, script text NOT NULL, category text NOT NULL, milestone integer DEFAULT 0 NOT NULL, important integer DEFAULT 0 NOT NULL, fatal integer DEFAULT 0 NOT NULL, result character varying DEFAULT 'none' NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id) ); CREATE INDEX job_modules_idx_job_id on job_modules (job_id); CREATE INDEX idx_job_modules_result on job_modules (result); ; -- -- Table: job_settings -- CREATE TABLE job_settings ( id serial NOT NULL, key text NOT NULL, value text NOT NULL, job_id integer NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id) ); CREATE INDEX job_settings_idx_job_id on job_settings (job_id); CREATE INDEX idx_value_settings on job_settings (key, value); CREATE INDEX idx_job_id_value_settings on job_settings (job_id, key, value); ; -- -- Table: machine_settings -- CREATE TABLE machine_settings ( id serial NOT NULL, machine_id integer NOT NULL, key text NOT NULL, value text NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT machine_settings_machine_id_key UNIQUE (machine_id, key) ); CREATE INDEX machine_settings_idx_machine_id on machine_settings (machine_id); ; -- -- Table: machines -- CREATE TABLE machines ( id serial NOT NULL, name text NOT NULL, backend text NOT NULL, description text, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT machines_name UNIQUE (name) ); ; -- -- Table: needle_dirs -- CREATE TABLE needle_dirs ( id serial NOT NULL, path text NOT NULL, name text NOT NULL, PRIMARY KEY (id), CONSTRAINT needle_dirs_path UNIQUE (path) ); ; -- -- Table: product_settings -- CREATE TABLE product_settings ( id serial NOT NULL, product_id integer NOT NULL, key text NOT NULL, value text NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT product_settings_product_id_key UNIQUE (product_id, key) ); CREATE INDEX product_settings_idx_product_id on product_settings (product_id); ; -- -- Table: products -- CREATE TABLE products ( id serial NOT NULL, name text NOT NULL, distri text NOT NULL, version text DEFAULT '' NOT NULL, arch text NOT NULL, flavor text NOT NULL, description text, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT products_distri_version_arch_flavor UNIQUE (distri, version, arch, flavor) ); ; -- -- Table: screenshots -- CREATE TABLE screenshots ( id serial NOT NULL, filename text NOT NULL, t_created timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT screenshots_filename UNIQUE (filename) ); ; -- -- Table: secrets -- CREATE TABLE secrets ( id serial NOT NULL, secret text NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT secrets_secret UNIQUE (secret) ); ; -- -- Table: test_suite_settings -- CREATE TABLE test_suite_settings ( id serial NOT NULL, test_suite_id integer NOT NULL, key text NOT NULL, value text NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT test_suite_settings_test_suite_id_key UNIQUE (test_suite_id, key) ); CREATE INDEX test_suite_settings_idx_test_suite_id on test_suite_settings (test_suite_id); ; -- -- Table: test_suites -- CREATE TABLE test_suites ( id serial NOT NULL, name text NOT NULL, description text, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT test_suites_name UNIQUE (name) ); ; -- -- Table: users -- CREATE TABLE users ( id serial NOT NULL, username text NOT NULL, email text, fullname text, nickname text, is_operator integer DEFAULT 0 NOT NULL, is_admin integer DEFAULT 0 NOT NULL, feature_version integer DEFAULT 1 NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT users_username UNIQUE (username) ); ; -- -- Table: worker_properties -- CREATE TABLE worker_properties ( id serial NOT NULL, key text NOT NULL, value text NOT NULL, worker_id integer NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id) ); CREATE INDEX worker_properties_idx_worker_id on worker_properties (worker_id); ; -- -- Table: api_keys -- CREATE TABLE api_keys ( id serial NOT NULL, key text NOT NULL, secret text NOT NULL, user_id integer NOT NULL, t_expiration timestamp, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT api_keys_key UNIQUE (key) ); CREATE INDEX api_keys_idx_user_id on api_keys (user_id); ; -- -- Table: audit_events -- CREATE TABLE audit_events ( id serial NOT NULL, user_id integer, connection_id text, event text NOT NULL, event_data text, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id) ); CREATE INDEX audit_events_idx_user_id on audit_events (user_id); ; -- -- Table: comments -- CREATE TABLE comments ( id serial NOT NULL, job_id integer, group_id integer, text text NOT NULL, user_id integer NOT NULL, flags integer DEFAULT 0, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id) ); CREATE INDEX comments_idx_group_id on comments (group_id); CREATE INDEX comments_idx_job_id on comments (job_id); CREATE INDEX comments_idx_user_id on comments (user_id); ; -- -- Table: job_groups -- CREATE TABLE job_groups ( id serial NOT NULL, name text NOT NULL, parent_id integer, size_limit_gb integer, exclusively_kept_asset_size bigint, keep_logs_in_days integer, keep_important_logs_in_days integer, keep_results_in_days integer, keep_important_results_in_days integer, default_priority integer, sort_order integer, description text, build_version_sort boolean DEFAULT '1' NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT job_groups_name_parent_id UNIQUE (name, parent_id) ); CREATE INDEX job_groups_idx_parent_id on job_groups (parent_id); ; -- -- Table: workers -- CREATE TABLE workers ( id serial NOT NULL, host text NOT NULL, instance integer NOT NULL, job_id integer, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT workers_host_instance UNIQUE (host, instance), CONSTRAINT workers_job_id UNIQUE (job_id) ); CREATE INDEX workers_idx_job_id on workers (job_id); ; -- -- Table: needles -- CREATE TABLE needles ( id serial NOT NULL, dir_id integer NOT NULL, filename text NOT NULL, last_seen_time timestamp, last_seen_module_id integer, last_matched_time timestamp, last_matched_module_id integer, file_present boolean DEFAULT '1' NOT NULL, tags text[], t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT needles_dir_id_filename UNIQUE (dir_id, filename) ); CREATE INDEX needles_idx_dir_id on needles (dir_id); CREATE INDEX needles_idx_last_matched_module_id on needles (last_matched_module_id); CREATE INDEX needles_idx_last_seen_module_id on needles (last_seen_module_id); ; -- -- Table: jobs -- CREATE TABLE jobs ( id serial NOT NULL, result_dir text, state character varying DEFAULT 'scheduled' NOT NULL, priority integer DEFAULT 50 NOT NULL, result character varying DEFAULT 'none' NOT NULL, clone_id integer, backend character varying, backend_info text, TEST text NOT NULL, DISTRI text DEFAULT '' NOT NULL, VERSION text DEFAULT '' NOT NULL, FLAVOR text DEFAULT '' NOT NULL, ARCH text DEFAULT '' NOT NULL, BUILD text DEFAULT '' NOT NULL, MACHINE text, group_id integer, assigned_worker_id integer, t_started timestamp, t_finished timestamp, logs_present boolean DEFAULT '1' NOT NULL, passed_module_count integer DEFAULT 0 NOT NULL, failed_module_count integer DEFAULT 0 NOT NULL, softfailed_module_count integer DEFAULT 0 NOT NULL, skipped_module_count integer DEFAULT 0 NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id) ); CREATE INDEX jobs_idx_assigned_worker_id on jobs (assigned_worker_id); CREATE INDEX jobs_idx_clone_id on jobs (clone_id); CREATE INDEX jobs_idx_group_id on jobs (group_id); CREATE INDEX idx_jobs_state on jobs (state); CREATE INDEX idx_jobs_result on jobs (result); CREATE INDEX idx_jobs_build_group on jobs (BUILD, group_id); CREATE INDEX idx_jobs_scenario on jobs (VERSION, DISTRI, FLAVOR, TEST, MACHINE, ARCH); ; -- -- Table: assets -- CREATE TABLE assets ( id serial NOT NULL, type text NOT NULL, name text NOT NULL, size bigint, checksum text, last_use_job_id integer, fixed boolean DEFAULT '0' NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT assets_type_name UNIQUE (type, name) ); CREATE INDEX assets_idx_last_use_job_id on assets (last_use_job_id); ; -- -- Table: job_dependencies -- CREATE TABLE job_dependencies ( child_job_id integer NOT NULL, parent_job_id integer NOT NULL, dependency integer NOT NULL, PRIMARY KEY (child_job_id, parent_job_id, dependency) ); CREATE INDEX job_dependencies_idx_child_job_id on job_dependencies (child_job_id); CREATE INDEX job_dependencies_idx_parent_job_id on job_dependencies (parent_job_id); CREATE INDEX idx_job_dependencies_dependency on job_dependencies (dependency); ; -- -- Table: job_locks -- CREATE TABLE job_locks ( name text NOT NULL, owner integer NOT NULL, locked_by text, count integer DEFAULT 1 NOT NULL, PRIMARY KEY (name, owner) ); CREATE INDEX job_locks_idx_owner on job_locks (owner); ; -- -- Table: job_networks -- CREATE TABLE job_networks ( name text NOT NULL, job_id integer NOT NULL, vlan integer NOT NULL, PRIMARY KEY (name, job_id) ); CREATE INDEX job_networks_idx_job_id on job_networks (job_id); ; -- -- Table: gru_dependencies -- CREATE TABLE gru_dependencies ( job_id integer NOT NULL, gru_task_id integer NOT NULL, PRIMARY KEY (job_id, gru_task_id) ); CREATE INDEX gru_dependencies_idx_gru_task_id on gru_dependencies (gru_task_id); CREATE INDEX gru_dependencies_idx_job_id on gru_dependencies (job_id); ; -- -- Table: job_templates -- CREATE TABLE job_templates ( id serial NOT NULL, product_id integer NOT NULL, machine_id integer NOT NULL, test_suite_id integer NOT NULL, prio integer NOT NULL, group_id integer NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, PRIMARY KEY (id), CONSTRAINT job_templates_product_id_machine_id_test_suite_id UNIQUE (product_id, machine_id, test_suite_id) ); CREATE INDEX job_templates_idx_group_id on job_templates (group_id); CREATE INDEX job_templates_idx_machine_id on job_templates (machine_id); CREATE INDEX job_templates_idx_product_id on job_templates (product_id); CREATE INDEX job_templates_idx_test_suite_id on job_templates (test_suite_id); ; -- -- Table: jobs_assets -- CREATE TABLE jobs_assets ( job_id integer NOT NULL, asset_id integer NOT NULL, created_by boolean DEFAULT '0' NOT NULL, t_created timestamp NOT NULL, t_updated timestamp NOT NULL, CONSTRAINT jobs_assets_job_id_asset_id UNIQUE (job_id, asset_id) ); CREATE INDEX jobs_assets_idx_asset_id on jobs_assets (asset_id); CREATE INDEX jobs_assets_idx_job_id on jobs_assets (job_id); ; -- -- Table: screenshot_links -- CREATE TABLE screenshot_links ( screenshot_id integer NOT NULL, job_id integer NOT NULL ); CREATE INDEX screenshot_links_idx_job_id on screenshot_links (job_id); CREATE INDEX screenshot_links_idx_screenshot_id on screenshot_links (screenshot_id); ; -- -- Foreign Key Definitions -- ; ALTER TABLE job_modules ADD CONSTRAINT job_modules_fk_job_id FOREIGN KEY (job_id) REFERENCES jobs (id) ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE job_settings ADD CONSTRAINT job_settings_fk_job_id FOREIGN KEY (job_id) REFERENCES jobs (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE machine_settings ADD CONSTRAINT machine_settings_fk_machine_id FOREIGN KEY (machine_id) REFERENCES machines (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE product_settings ADD CONSTRAINT product_settings_fk_product_id FOREIGN KEY (product_id) REFERENCES products (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE test_suite_settings ADD CONSTRAINT test_suite_settings_fk_test_suite_id FOREIGN KEY (test_suite_id) REFERENCES test_suites (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE worker_properties ADD CONSTRAINT worker_properties_fk_worker_id FOREIGN KEY (worker_id) REFERENCES workers (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE api_keys ADD CONSTRAINT api_keys_fk_user_id FOREIGN KEY (user_id) REFERENCES users (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE audit_events ADD CONSTRAINT audit_events_fk_user_id FOREIGN KEY (user_id) REFERENCES users (id) DEFERRABLE; ; ALTER TABLE comments ADD CONSTRAINT comments_fk_group_id FOREIGN KEY (group_id) REFERENCES job_groups (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE comments ADD CONSTRAINT comments_fk_job_id FOREIGN KEY (job_id) REFERENCES jobs (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE comments ADD CONSTRAINT comments_fk_user_id FOREIGN KEY (user_id) REFERENCES users (id) DEFERRABLE; ; ALTER TABLE job_groups ADD CONSTRAINT job_groups_fk_parent_id FOREIGN KEY (parent_id) REFERENCES job_group_parents (id) ON DELETE SET NULL ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE workers ADD CONSTRAINT workers_fk_job_id FOREIGN KEY (job_id) REFERENCES jobs (id) ON DELETE CASCADE DEFERRABLE; ; ALTER TABLE needles ADD CONSTRAINT needles_fk_dir_id FOREIGN KEY (dir_id) REFERENCES needle_dirs (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE needles ADD CONSTRAINT needles_fk_last_matched_module_id FOREIGN KEY (last_matched_module_id) REFERENCES job_modules (id) ON DELETE SET NULL DEFERRABLE; ; ALTER TABLE needles ADD CONSTRAINT needles_fk_last_seen_module_id FOREIGN KEY (last_seen_module_id) REFERENCES job_modules (id) ON DELETE SET NULL DEFERRABLE; ; ALTER TABLE jobs ADD CONSTRAINT jobs_fk_assigned_worker_id FOREIGN KEY (assigned_worker_id) REFERENCES workers (id) ON DELETE SET NULL ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE jobs ADD CONSTRAINT jobs_fk_clone_id FOREIGN KEY (clone_id) REFERENCES jobs (id) ON DELETE SET NULL DEFERRABLE; ; ALTER TABLE jobs ADD CONSTRAINT jobs_fk_group_id FOREIGN KEY (group_id) REFERENCES job_groups (id) ON DELETE SET NULL ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE assets ADD CONSTRAINT assets_fk_last_use_job_id FOREIGN KEY (last_use_job_id) REFERENCES jobs (id) ON DELETE SET NULL ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE job_dependencies ADD CONSTRAINT job_dependencies_fk_child_job_id FOREIGN KEY (child_job_id) REFERENCES jobs (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE job_dependencies ADD CONSTRAINT job_dependencies_fk_parent_job_id FOREIGN KEY (parent_job_id) REFERENCES jobs (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE job_locks ADD CONSTRAINT job_locks_fk_owner FOREIGN KEY (owner) REFERENCES jobs (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE job_networks ADD CONSTRAINT job_networks_fk_job_id FOREIGN KEY (job_id) REFERENCES jobs (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE gru_dependencies ADD CONSTRAINT gru_dependencies_fk_gru_task_id FOREIGN KEY (gru_task_id) REFERENCES gru_tasks (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE gru_dependencies ADD CONSTRAINT gru_dependencies_fk_job_id FOREIGN KEY (job_id) REFERENCES jobs (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE job_templates ADD CONSTRAINT job_templates_fk_group_id FOREIGN KEY (group_id) REFERENCES job_groups (id) DEFERRABLE; ; ALTER TABLE job_templates ADD CONSTRAINT job_templates_fk_machine_id FOREIGN KEY (machine_id) REFERENCES machines (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE job_templates ADD CONSTRAINT job_templates_fk_product_id FOREIGN KEY (product_id) REFERENCES products (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE job_templates ADD CONSTRAINT job_templates_fk_test_suite_id FOREIGN KEY (test_suite_id) REFERENCES test_suites (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE jobs_assets ADD CONSTRAINT jobs_assets_fk_asset_id FOREIGN KEY (asset_id) REFERENCES assets (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE jobs_assets ADD CONSTRAINT jobs_assets_fk_job_id FOREIGN KEY (job_id) REFERENCES jobs (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE screenshot_links ADD CONSTRAINT screenshot_links_fk_job_id FOREIGN KEY (job_id) REFERENCES jobs (id) ON DELETE CASCADE ON UPDATE CASCADE DEFERRABLE; ; ALTER TABLE screenshot_links ADD CONSTRAINT screenshot_links_fk_screenshot_id FOREIGN KEY (screenshot_id) REFERENCES screenshots (id) ON UPDATE CASCADE DEFERRABLE; ;
{ "pile_set_name": "Github" }
module MailerHelper end
{ "pile_set_name": "Github" }
/* * Copyright 2020 Red Hat, Inc. and/or its affiliates. * * 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. */ package org.optaplanner.examples.curriculumcourse.domain; import org.optaplanner.examples.common.domain.AbstractPersistable; import com.thoughtworks.xstream.annotations.XStreamAlias; @XStreamAlias("Timeslot") public class Timeslot extends AbstractPersistable { private static final String[] TIMES = { "08:00", "09:00", "10:00", "11:00", "13:00", "14:00", "15:00", "16:00", "17:00", "18:00" }; private int timeslotIndex; public Timeslot(int timeslotIndex) { super(timeslotIndex); this.timeslotIndex = timeslotIndex; } public int getTimeslotIndex() { return timeslotIndex; } public void setTimeslotIndex(int timeslotIndex) { this.timeslotIndex = timeslotIndex; } public String getLabel() { String time = TIMES[timeslotIndex % TIMES.length]; if (timeslotIndex > TIMES.length) { return "Timeslot " + timeslotIndex; } return time; } @Override public String toString() { return Integer.toString(timeslotIndex); } }
{ "pile_set_name": "Github" }
# This file is Copyright 2019 Volatility Foundation and licensed under the Volatility Software License 1.0 # which is available at https://www.volatilityfoundation.org/license/vsl-v1.0 # """Renderers. Renderers display the unified output format in some manner (be it text or file or graphical output """ import collections import datetime import logging from collections import abc from typing import Any, Callable, Iterable, List, Optional, Tuple, TypeVar, Union from volatility.framework import interfaces from volatility.framework.interfaces import renderers vollog = logging.getLogger(__name__) class UnreadableValue(interfaces.renderers.BaseAbsentValue): """Class that represents values which are empty because the data cannot be read.""" class UnparsableValue(interfaces.renderers.BaseAbsentValue): """Class that represents values which are empty because the data cannot be interpreted correctly.""" class NotApplicableValue(interfaces.renderers.BaseAbsentValue): """Class that represents values which are empty because they don't make sense for this node.""" class NotAvailableValue(interfaces.renderers.BaseAbsentValue): """Class that represents values which cannot be provided now (but might in a future run) This might occur when information packed with volatility (such as symbol information) is not available, but a future version or a different run may later have that information available (ie, it could be applicable, but we can't get it and it's not because it's unreadable or unparsable). Unreadable and Unparsable should be used in preference, and only if neither fits should this be used. """ class TreeNode(interfaces.renderers.TreeNode): """Class representing a particular node in a tree grid.""" def __init__(self, path: str, treegrid: 'TreeGrid', parent: Optional['TreeNode'], values: List[interfaces.renderers.BaseTypes]) -> None: if not isinstance(treegrid, TreeGrid): raise TypeError("Treegrid must be an instance of TreeGrid") self._treegrid = treegrid self._parent = parent self._path = path self._validate_values(values) self._values = treegrid.RowStructure(*values) # type: ignore def __repr__(self) -> str: return "<TreeNode [{}] - {}>".format(self.path, self._values) def __getitem__(self, item: Union[int, slice]) -> Any: return self._treegrid.children(self).__getitem__(item) def __len__(self) -> int: return len(self._treegrid.children(self)) def _validate_values(self, values: List[interfaces.renderers.BaseTypes]) -> None: """A function for raising exceptions if a given set of values is invalid according to the column properties.""" if not (isinstance(values, abc.Sequence) and len(values) == len(self._treegrid.columns)): raise TypeError( "Values must be a list of objects made up of simple types and number the same as the columns") for index in range(len(self._treegrid.columns)): column = self._treegrid.columns[index] val = values[index] if not isinstance(val, (column.type, interfaces.renderers.BaseAbsentValue)): raise TypeError( "Values item with index {} is the wrong type for column {} (got {} but expected {})".format( index, column.name, type(val), column.type)) # TODO: Consider how to deal with timezone naive/aware datetimes (and alert plugin uses to be precise) # if isinstance(val, datetime.datetime): # tznaive = val.tzinfo is None or val.tzinfo.utcoffset(val) is None @property def values(self) -> List[interfaces.renderers.BaseTypes]: """Returns the list of values from the particular node, based on column index.""" return self._values @property def path(self) -> str: """Returns a path identifying string. This should be seen as opaque by external classes, Parsing of path locations based on this string are not guaranteed to remain stable. """ return self._path @property def parent(self) -> Optional['TreeNode']: """Returns the parent node of this node or None.""" return self._parent @property def path_depth(self) -> int: """Return the path depth of the current node.""" return len(self.path.split(TreeGrid.path_sep)) def path_changed(self, path: str, added: bool = False) -> None: """Updates the path based on the addition or removal of a node higher up in the tree. This should only be called by the containing TreeGrid and expects to only be called for affected nodes. """ components = self._path.split(TreeGrid.path_sep) changed = path.split(TreeGrid.path_sep) changed_index = len(changed) - 1 if int(components[changed_index]) >= int(changed[-1]): components[changed_index] = str(int(components[changed_index]) + (1 if added else -1)) self._path = TreeGrid.path_sep.join(components) def RowStructureConstructor(names: List[str]): return collections.namedtuple("RowStructure", [TreeGrid.sanitize_name(name) for name in names]) class TreeGrid(interfaces.renderers.TreeGrid): """Class providing the interface for a TreeGrid (which contains TreeNodes) The structure of a TreeGrid is designed to maintain the structure of the tree in a single object. For this reason each TreeNode does not hold its children, they are managed by the top level object. This leaves the Nodes as simple data carries and prevents them being used to manipulate the tree as a whole. This is a data structure, and is not expected to be modified much once created. Carrying the children under the parent makes recursion easier, but then every node is its own little tree and must have all the supporting tree functions. It also allows for a node to be present in several different trees, and to create cycles. """ path_sep = "|" def __init__(self, columns: List[Tuple[str, interfaces.renderers.BaseTypes]], generator: Optional[Iterable[Tuple[int, Tuple]]]) -> None: """Constructs a TreeGrid object using a specific set of columns. The TreeGrid itself is a root element, that can have children but no values. The TreeGrid does *not* contain any information about formatting, these are up to the renderers and plugins. Args: columns: A list of column tuples made up of (name, type). generator: An iterable containing row for a tree grid, each row contains a indent level followed by the values for each column in order. """ self._populated = False self._row_count = 0 self._children = [] # type: List[TreeNode] converted_columns = [] # type: List[interfaces.renderers.Column] if len(columns) < 1: raise ValueError("Columns must be a list containing at least one column") for (name, column_type) in columns: is_simple_type = issubclass(column_type, self.base_types) if not is_simple_type: raise TypeError("Column {}'s type is not a simple type: {}".format(name, column_type.__class__.__name__)) converted_columns.append(interfaces.renderers.Column(name, column_type)) self.RowStructure = RowStructureConstructor([column.name for column in converted_columns]) self._columns = converted_columns if generator is None: generator = [] generator = iter(generator) self._generator = generator @staticmethod def sanitize_name(text: str) -> str: output = "" for letter in text.lower(): if letter != ' ': output += (letter if letter in 'abcdefghiljklmnopqrstuvwxyz_0123456789' else '_') return output def populate(self, function: interfaces.renderers.VisitorSignature = None, initial_accumulator: Any = None, fail_on_errors: bool = True) -> Optional[Exception]: """Populates the tree by consuming the TreeGrid's construction generator Func is called on every node, so can be used to create output on demand. This is equivalent to a one-time visit. Args: function: The visitor to be called on each row of the treegrid initial_accumulator: The initial value for an accumulator passed to the visitor to allow it to maintain state fail_on_errors: A boolean defining whether exceptions should be caught or bubble up """ accumulator = initial_accumulator if function is None: def function(_x: interfaces.renderers.TreeNode, _y: Any) -> Any: return None if not self.populated: try: prev_nodes = [] # type: List[TreeNode] for (level, item) in self._generator: parent_index = min(len(prev_nodes), level) parent = prev_nodes[parent_index - 1] if parent_index > 0 else None treenode = self._append(parent, item) prev_nodes = prev_nodes[0:parent_index] + [treenode] if function is not None: accumulator = function(treenode, accumulator) self._row_count += 1 except Exception as excp: if fail_on_errors: raise vollog.debug("Exception during population: {}".format(excp)) self._populated = True return excp self._populated = True return None @property def populated(self): """Indicates that population has completed and the tree may now be manipulated separately.""" return self._populated @property def columns(self) -> List[interfaces.renderers.Column]: """Returns the available columns and their ordering and types.""" return self._columns @property def row_count(self) -> int: """Returns the number of rows populated.""" return self._row_count def children(self, node) -> List[interfaces.renderers.TreeNode]: """Returns the subnodes of a particular node in order.""" return [node for node, _ in self._find_children(node)] def _find_children(self, node): """Returns the children list associated with a particular node. Returns None if the node does not exist """ children = self._children try: if node is not None: for path_component in node.path.split(self.path_sep): _, children = children[int(path_component)] except IndexError: return [] return children def values(self, node): """Returns the values for a particular node. The values returned are mutable, """ if node is None: raise TypeError("Node must be a valid node within the TreeGrid") return node.values def _append(self, parent, values): """Adds a new node at the top level if parent is None, or under the parent node otherwise, after all other children.""" children = self.children(parent) return self._insert(parent, len(children), values) def _insert(self, parent, position, values): """Inserts an element into the tree at a specific position.""" parent_path = "" children = self._find_children(parent) if parent is not None: parent_path = parent.path + self.path_sep newpath = parent_path + str(position) tree_item = TreeNode(newpath, self, parent, values) for node, _ in children[position:]: self.visit(node, lambda child, _: child.path_changed(newpath, True), None) children.insert(position, (tree_item, [])) return tree_item def is_ancestor(self, node, descendant): """Returns true if descendent is a child, grandchild, etc of node.""" return descendant.path.startswith(node.path) def max_depth(self): """Returns the maximum depth of the tree.""" return self.visit(None, lambda n, a: max(a, self.path_depth(n)), 0) _T = TypeVar("_T") def visit(self, node: Optional[interfaces.renderers.TreeNode], function: Callable[[interfaces.renderers.TreeNode, _T], _T], initial_accumulator: _T, sort_key: Optional[interfaces.renderers.ColumnSortKey] = None): """Visits all the nodes in a tree, calling function on each one. function should have the signature function(node, accumulator) and return new_accumulator If accumulators are not needed, the function must still accept a second parameter. The order of that the nodes are visited is always depth first, however, the order children are traversed can be set based on a sort_key function which should accept a node's values and return something that can be sorted to receive the desired order (similar to the sort/sorted key). We use the private _find_children function so that we don't have to re-traverse the tree for every node we descend further down """ if not self.populated: self.populate() # Find_nodes is path dependent, whereas _visit is not # So in case the function modifies the node's path, find the nodes first children = self._find_children(node) accumulator = initial_accumulator # We split visit into two, so that we don't have to keep calling find_children to traverse the tree if node is not None: accumulator = function(node, initial_accumulator) if children is not None: if sort_key is not None: sort_key_not_none = sort_key # Only necessary because of mypy children = sorted(children, key = lambda x: sort_key_not_none(x[0].values)) if not sort_key.ascending: children = reversed(children) accumulator = self._visit(children, function, accumulator, sort_key) return accumulator def _visit(self, list_of_children: List['TreeNode'], function: Callable, accumulator: _T, sort_key: Optional[interfaces.renderers.ColumnSortKey] = None) -> _T: """Visits all the nodes in a tree, calling function on each one.""" if list_of_children is not None: for n, children in list_of_children: accumulator = function(n, accumulator) if sort_key is not None: sort_key_not_none = sort_key # Only necessary because of mypy children = sorted(children, key = lambda x: sort_key_not_none(x[0].values)) if not sort_key.ascending: children = reversed(children) accumulator = self._visit(children, function, accumulator, sort_key) return accumulator class ColumnSortKey(interfaces.renderers.ColumnSortKey): def __init__(self, treegrid: TreeGrid, column_name: str, ascending: bool = True) -> None: _index = None self._type = None self.ascending = ascending for i in range(len(treegrid.columns)): column = treegrid.columns[i] if column.name.lower() == column_name.lower(): _index = i self._type = column.type if _index is None: raise ValueError("Column not found in TreeGrid columns: {}".format(column_name)) self._index = _index def __call__(self, values: List[Any]) -> Any: """The key function passed as the sort key.""" value = values[self._index] if isinstance(value, interfaces.renderers.BaseAbsentValue): if self._type == datetime.datetime: value = datetime.datetime.min elif self._type in [int, float]: value = -1 elif self._type == bool: value = False elif self._type in [str, renderers.Disassembly]: value = "-" elif self._type == bytes: value = b"" return value
{ "pile_set_name": "Github" }
var searchData= [ ['wa',['WA',['../structrlSiemensTCP_1_1WA.html',1,'rlSiemensTCP']]], ['wh',['WH',['../structrlSiemensTCP_1_1WH.html',1,'rlSiemensTCP']]], ['worker_5fdata',['WORKER_DATA',['../structWORKER__DATA.html',1,'']]], ['wsemaphore',['WSEMAPHORE',['../structWSEMAPHORE.html',1,'']]] ];
{ "pile_set_name": "Github" }
/////////////////////////////////////////////////////////////// // Copyright 2012 John Maddock. Distributed under the Boost // Software License, Version 1.0. (See accompanying file // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_ // // Compare arithmetic results using fixed_int to GMP results. // #ifdef _MSC_VER # define _SCL_SECURE_NO_WARNINGS #endif #include <boost/multiprecision/gmp.hpp> #include <boost/multiprecision/fixed_int.hpp> #include <boost/random/mersenne_twister.hpp> #include <boost/random/uniform_int.hpp> #include "test.hpp" template <class T> T generate_random(unsigned bits_wanted) { static boost::random::mt19937 gen; typedef boost::random::mt19937::result_type random_type; T max_val; unsigned digits; if(std::numeric_limits<T>::is_bounded && (bits_wanted == std::numeric_limits<T>::digits)) { max_val = (std::numeric_limits<T>::max)(); digits = std::numeric_limits<T>::digits; } else { max_val = T(1) << bits_wanted; digits = bits_wanted; } unsigned bits_per_r_val = std::numeric_limits<random_type>::digits - 1; while((random_type(1) << bits_per_r_val) > (gen.max)()) --bits_per_r_val; unsigned terms_needed = digits / bits_per_r_val + 1; T val = 0; for(unsigned i = 0; i < terms_needed; ++i) { val *= (gen.max)(); val += gen(); } val %= max_val; return val; } int main() { using namespace boost::multiprecision; typedef number<fixed_int<1024, true> > packed_type; unsigned last_error_count = 0; for(int i = 0; i < 1000; ++i) { mpz_int a = generate_random<mpz_int>(1000); mpz_int b = generate_random<mpz_int>(512); mpz_int c = generate_random<mpz_int>(256); mpz_int d = generate_random<mpz_int>(32); int si = d.convert_to<int>(); packed_type a1 = a.str(); packed_type b1 = b.str(); packed_type c1 = c.str(); packed_type d1 = d.str(); BOOST_CHECK_EQUAL(a.str(), a1.str()); BOOST_CHECK_EQUAL(b.str(), b1.str()); BOOST_CHECK_EQUAL(c.str(), c1.str()); BOOST_CHECK_EQUAL(d.str(), d1.str()); BOOST_CHECK_EQUAL(mpz_int(a+b).str(), packed_type(a1 + b1).str()); BOOST_CHECK_EQUAL(mpz_int(a-b).str(), packed_type(a1 - b1).str()); BOOST_CHECK_EQUAL(mpz_int(mpz_int(-a)+b).str(), packed_type(packed_type(-a1) + b1).str()); BOOST_CHECK_EQUAL(mpz_int(mpz_int(-a)-b).str(), packed_type(packed_type(-a1) - b1).str()); BOOST_CHECK_EQUAL(mpz_int(c * d).str(), packed_type(c1 * d1).str()); BOOST_CHECK_EQUAL(mpz_int(c * -d).str(), packed_type(c1 * -d1).str()); BOOST_CHECK_EQUAL(mpz_int(-c * d).str(), packed_type(-c1 * d1).str()); BOOST_CHECK_EQUAL(mpz_int(b * c).str(), packed_type(b1 * c1).str()); BOOST_CHECK_EQUAL(mpz_int(a / b).str(), packed_type(a1 / b1).str()); BOOST_CHECK_EQUAL(mpz_int(a / -b).str(), packed_type(a1 / -b1).str()); BOOST_CHECK_EQUAL(mpz_int(-a / b).str(), packed_type(-a1 / b1).str()); BOOST_CHECK_EQUAL(mpz_int(a / d).str(), packed_type(a1 / d1).str()); BOOST_CHECK_EQUAL(mpz_int(a % b).str(), packed_type(a1 % b1).str()); BOOST_CHECK_EQUAL(mpz_int(a % -b).str(), packed_type(a1 % -b1).str()); BOOST_CHECK_EQUAL(mpz_int(-a % b).str(), packed_type(-a1 % b1).str()); BOOST_CHECK_EQUAL(mpz_int(a % d).str(), packed_type(a1 % d1).str()); // bitwise ops: BOOST_CHECK_EQUAL(mpz_int(a|b).str(), packed_type(a1 | b1).str()); BOOST_CHECK_EQUAL(mpz_int(a&b).str(), packed_type(a1 & b1).str()); BOOST_CHECK_EQUAL(mpz_int(a^b).str(), packed_type(a1 ^ b1).str()); // Now check operations involving integers: BOOST_CHECK_EQUAL(mpz_int(a + si).str(), packed_type(a1 + si).str()); BOOST_CHECK_EQUAL(mpz_int(a + -si).str(), packed_type(a1 + -si).str()); BOOST_CHECK_EQUAL(mpz_int(-a + si).str(), packed_type(-a1 + si).str()); BOOST_CHECK_EQUAL(mpz_int(si + a).str(), packed_type(si + a1).str()); BOOST_CHECK_EQUAL(mpz_int(a - si).str(), packed_type(a1 - si).str()); BOOST_CHECK_EQUAL(mpz_int(a - -si).str(), packed_type(a1 - -si).str()); BOOST_CHECK_EQUAL(mpz_int(-a - si).str(), packed_type(-a1 - si).str()); BOOST_CHECK_EQUAL(mpz_int(si - a).str(), packed_type(si - a1).str()); BOOST_CHECK_EQUAL(mpz_int(b * si).str(), packed_type(b1 * si).str()); BOOST_CHECK_EQUAL(mpz_int(b * -si).str(), packed_type(b1 * -si).str()); BOOST_CHECK_EQUAL(mpz_int(-b * si).str(), packed_type(-b1 * si).str()); BOOST_CHECK_EQUAL(mpz_int(si * b).str(), packed_type(si * b1).str()); BOOST_CHECK_EQUAL(mpz_int(a / si).str(), packed_type(a1 / si).str()); BOOST_CHECK_EQUAL(mpz_int(a / -si).str(), packed_type(a1 / -si).str()); BOOST_CHECK_EQUAL(mpz_int(-a / si).str(), packed_type(-a1 / si).str()); BOOST_CHECK_EQUAL(mpz_int(a % si).str(), packed_type(a1 % si).str()); BOOST_CHECK_EQUAL(mpz_int(a % -si).str(), packed_type(a1 % -si).str()); BOOST_CHECK_EQUAL(mpz_int(-a % si).str(), packed_type(-a1 % si).str()); BOOST_CHECK_EQUAL(mpz_int(a|si).str(), packed_type(a1 | si).str()); BOOST_CHECK_EQUAL(mpz_int(a&si).str(), packed_type(a1 & si).str()); BOOST_CHECK_EQUAL(mpz_int(a^si).str(), packed_type(a1 ^ si).str()); BOOST_CHECK_EQUAL(mpz_int(si|a).str(), packed_type(si|a1).str()); BOOST_CHECK_EQUAL(mpz_int(si&a).str(), packed_type(si&a1).str()); BOOST_CHECK_EQUAL(mpz_int(si^a).str(), packed_type(si^a1).str()); BOOST_CHECK_EQUAL(mpz_int(gcd(a, b)).str(), packed_type(gcd(a1, b1)).str()); BOOST_CHECK_EQUAL(mpz_int(lcm(c, d)).str(), packed_type(lcm(c1, d1)).str()); if(last_error_count != boost::detail::test_errors()) { last_error_count = boost::detail::test_errors(); std::cout << std::hex << std::showbase; std::cout << "a = " << a << std::endl; std::cout << "a1 = " << a1 << std::endl; std::cout << "b = " << b << std::endl; std::cout << "b1 = " << b1 << std::endl; std::cout << "c = " << c << std::endl; std::cout << "c1 = " << c1 << std::endl; std::cout << "d = " << d << std::endl; std::cout << "d1 = " << d1 << std::endl; std::cout << "a + b = " << a+b << std::endl; std::cout << "a1 + b1 = " << a1+b1 << std::endl; std::cout << std::dec; std::cout << "a - b = " << a-b << std::endl; std::cout << "a1 - b1 = " << a1-b1 << std::endl; std::cout << "-a + b = " << mpz_int(-a)+b << std::endl; std::cout << "-a1 + b1 = " << packed_type(-a1)+b1 << std::endl; std::cout << "-a - b = " << mpz_int(-a)-b << std::endl; std::cout << "-a1 - b1 = " << packed_type(-a1)-b1 << std::endl; std::cout << "c*d = " << c*d << std::endl; std::cout << "c1*d1 = " << c1*d1 << std::endl; std::cout << "b*c = " << b*c << std::endl; std::cout << "b1*c1 = " << b1*c1 << std::endl; std::cout << "a/b = " << a/b << std::endl; std::cout << "a1/b1 = " << a1/b1 << std::endl; std::cout << "a/d = " << a/d << std::endl; std::cout << "a1/d1 = " << a1/d1 << std::endl; std::cout << "a%b = " << a%b << std::endl; std::cout << "a1%b1 = " << a1%b1 << std::endl; std::cout << "a%d = " << a%d << std::endl; std::cout << "a1%d1 = " << a1%d1 << std::endl; } } return boost::report_errors(); }
{ "pile_set_name": "Github" }
<?php # Generated by the protocol buffer compiler. DO NOT EDIT! # source: google/devtools/clouderrorreporting/v1beta1/error_stats_service.proto namespace Google\Cloud\ErrorReporting\V1beta1; use Google\Protobuf\Internal\GPBType; use Google\Protobuf\Internal\RepeatedField; use Google\Protobuf\Internal\GPBUtil; /** * The number of errors in a given time period. * All numbers are approximate since the error events are sampled * before counting them. * * Generated from protobuf message <code>google.devtools.clouderrorreporting.v1beta1.TimedCount</code> */ class TimedCount extends \Google\Protobuf\Internal\Message { /** * Approximate number of occurrences in the given time period. * * Generated from protobuf field <code>int64 count = 1;</code> */ private $count = 0; /** * Start of the time period to which `count` refers (included). * * Generated from protobuf field <code>.google.protobuf.Timestamp start_time = 2;</code> */ private $start_time = null; /** * End of the time period to which `count` refers (excluded). * * Generated from protobuf field <code>.google.protobuf.Timestamp end_time = 3;</code> */ private $end_time = null; /** * Constructor. * * @param array $data { * Optional. Data for populating the Message object. * * @type int|string $count * Approximate number of occurrences in the given time period. * @type \Google\Protobuf\Timestamp $start_time * Start of the time period to which `count` refers (included). * @type \Google\Protobuf\Timestamp $end_time * End of the time period to which `count` refers (excluded). * } */ public function __construct($data = NULL) { \GPBMetadata\Google\Devtools\Clouderrorreporting\V1Beta1\ErrorStatsService::initOnce(); parent::__construct($data); } /** * Approximate number of occurrences in the given time period. * * Generated from protobuf field <code>int64 count = 1;</code> * @return int|string */ public function getCount() { return $this->count; } /** * Approximate number of occurrences in the given time period. * * Generated from protobuf field <code>int64 count = 1;</code> * @param int|string $var * @return $this */ public function setCount($var) { GPBUtil::checkInt64($var); $this->count = $var; return $this; } /** * Start of the time period to which `count` refers (included). * * Generated from protobuf field <code>.google.protobuf.Timestamp start_time = 2;</code> * @return \Google\Protobuf\Timestamp */ public function getStartTime() { return isset($this->start_time) ? $this->start_time : null; } public function hasStartTime() { return isset($this->start_time); } public function clearStartTime() { unset($this->start_time); } /** * Start of the time period to which `count` refers (included). * * Generated from protobuf field <code>.google.protobuf.Timestamp start_time = 2;</code> * @param \Google\Protobuf\Timestamp $var * @return $this */ public function setStartTime($var) { GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); $this->start_time = $var; return $this; } /** * End of the time period to which `count` refers (excluded). * * Generated from protobuf field <code>.google.protobuf.Timestamp end_time = 3;</code> * @return \Google\Protobuf\Timestamp */ public function getEndTime() { return isset($this->end_time) ? $this->end_time : null; } public function hasEndTime() { return isset($this->end_time); } public function clearEndTime() { unset($this->end_time); } /** * End of the time period to which `count` refers (excluded). * * Generated from protobuf field <code>.google.protobuf.Timestamp end_time = 3;</code> * @param \Google\Protobuf\Timestamp $var * @return $this */ public function setEndTime($var) { GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); $this->end_time = $var; return $this; } }
{ "pile_set_name": "Github" }
// Copyright (c) Microsoft Open Technologies, Inc. All rights reserved. See License.txt in the project root for license information. using System.Diagnostics.Contracts; using System.Globalization; using System.Linq; using System.Web.Http.OData.Properties; using Microsoft.Data.Edm; using Microsoft.Data.OData; namespace System.Web.Http.OData.Query { public class SkipQueryOption { private int? _value; /// <summary> /// Initialize a new instance of <see cref="OrderByQueryOption"/> based on the raw $skip value and /// an EdmModel from <see cref="ODataQueryContext"/>. /// </summary> /// <param name="rawValue">The raw value for $skip query. It can be null or empty.</param> /// <param name="context">The <see cref="ODataQueryContext"/> which contains the <see cref="IEdmModel"/> and some type information</param> public SkipQueryOption(string rawValue, ODataQueryContext context) { if (context == null) { throw Error.ArgumentNull("context"); } if (String.IsNullOrEmpty(rawValue)) { throw Error.ArgumentNullOrEmpty("rawValue"); } Context = context; RawValue = rawValue; } /// <summary> /// Gets the given <see cref="ODataQueryContext"/>. /// </summary> public ODataQueryContext Context { get; private set; } /// <summary> /// Gets the raw $skip value. /// </summary> public string RawValue { get; private set; } /// <summary> /// Gets the value of the $skip as a parsed integer. /// </summary> public int Value { get { if (_value == null) { try { _value = Convert.ToInt32(RawValue, CultureInfo.InvariantCulture); } catch (FormatException exception) { throw new ODataException(Error.Format(SRResources.CanNotParseInteger, RawValue), exception); } } Contract.Assert(_value.HasValue); return _value.Value; } } /// <summary> /// Apply the $skip query to the given IQueryable. /// </summary> /// <param name="query">The IQueryable that we are applying skip query against.</param> /// <returns>The query that the skip query has been applied to.</returns> public IQueryable<T> ApplyTo<T>(IQueryable<T> query) { return ApplyToCore(query) as IOrderedQueryable<T>; } /// <summary> /// Apply the $skip query to the given IQueryable. /// </summary> /// <param name="query">The IQueryable that we are applying skip query against.</param> /// <returns>The query that the skip query has been applied to.</returns> public IQueryable ApplyTo(IQueryable query) { return ApplyToCore(query); } private IQueryable ApplyToCore(IQueryable query) { return ExpressionHelpers.Skip(query, Value, Context.EntityClrType); } } }
{ "pile_set_name": "Github" }
# Project-wide Gradle settings. # IDE (e.g. Android Studio) users: # Gradle settings configured through the IDE *will override* # any settings specified in this file. # For more details on how to configure your build environment visit # http://www.gradle.org/docs/current/userguide/build_environment.html # Specifies the JVM arguments used for the daemon process. # The setting is particularly useful for tweaking memory settings. # Default value: -Xmx10248m -XX:MaxPermSize=256m # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 # When configured, Gradle will run in incubating parallel mode. # This option should only be used with decoupled projects. More details, visit # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects # org.gradle.parallel=true org.gradle.jvmargs=-Xmx2048M
{ "pile_set_name": "Github" }
#! /usr/bin/env python3 """Keywords (from "graminit.c") This file is automatically generated; please don't muck it up! To update the symbols in this file, 'cd' to the top directory of the python source tree after building the interpreter and run: ./python Lib/keyword.py """ __all__ = ["iskeyword", "kwlist"] kwlist = [ #--start keywords-- 'False', 'None', 'True', 'and', 'as', 'assert', 'break', 'class', 'continue', 'def', 'del', 'elif', 'else', 'except', 'finally', 'for', 'from', 'global', 'if', 'import', 'in', 'is', 'lambda', 'nonlocal', 'not', 'or', 'pass', 'raise', 'return', 'try', 'while', 'with', 'yield', #--end keywords-- ] iskeyword = frozenset(kwlist).__contains__ def main(): import sys, re args = sys.argv[1:] iptfile = args and args[0] or "Python/graminit.c" if len(args) > 1: optfile = args[1] else: optfile = "Lib/keyword.py" # load the output skeleton from the target, taking care to preserve its # newline convention. with open(optfile, newline='') as fp: format = fp.readlines() nl = format[0][len(format[0].strip()):] if format else '\n' # scan the source file for keywords with open(iptfile) as fp: strprog = re.compile('"([^"]+)"') lines = [] for line in fp: if '{1, "' in line: match = strprog.search(line) if match: lines.append(" '" + match.group(1) + "'," + nl) lines.sort() # insert the lines of keywords into the skeleton try: start = format.index("#--start keywords--" + nl) + 1 end = format.index("#--end keywords--" + nl) format[start:end] = lines except ValueError: sys.stderr.write("target does not contain format markers\n") sys.exit(1) # write the output file with open(optfile, 'w', newline='') as fp: fp.writelines(format) if __name__ == "__main__": main()
{ "pile_set_name": "Github" }
"plus_tinker_march_damage" { "template" "tinker_march_damage" "tier" "1" "<total_damage>" { "1" { "1200" "1" } "2" { "2400" "1" } "3" { "3600" "1" } } "challenge_ranks" "3" }
{ "pile_set_name": "Github" }
/* * Copyright (C) 2015 Apple Inc. All rights reserved. * * 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. * * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS 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 APPLE INC. OR ITS 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. */ #if USE(APPLE_INTERNAL_SDK) #import <WebContentAnalysis/WebFilterEvaluator.h> #else #import <TargetConditionals.h> enum { kWFEStateAllowed = 0, kWFEStateBlocked = 1, kWFEStateBuffering = 2, kWFEStateEvaluating = 3 }; @interface WebFilterEvaluator : NSObject @end @interface WebFilterEvaluator () + (BOOL)isManagedSession; - (BOOL)wasBlocked; - (NSData *)addData:(NSData *)receivedData; - (NSData *)dataComplete; - (OSStatus)filterState; - (id)initWithResponse:(NSURLResponse *)response; #if TARGET_OS_IPHONE - (void)unblockWithCompletion:(void (^)(BOOL unblocked, NSError *error))completion; #endif @end #endif
{ "pile_set_name": "Github" }
; ; Java Information Dynamics Toolkit (JIDT) ; Copyright (C) 2012, Joseph T. Lizier ; ; This program is free software: you can redistribute it and/or modify ; it under the terms of the GNU General Public License as published by ; the Free Software Foundation, either version 3 of the License, or ; (at your option) any later version. ; ; This program is distributed in the hope that it will be useful, ; but WITHOUT ANY WARRANTY; without even the implied warranty of ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ; GNU General Public License for more details. ; ; You should have received a copy of the GNU General Public License ; along with this program. If not, see <http://www.gnu.org/licenses/>. ; ;; = Example 1 - Transfer entropy on binary data = ; Simple transfer entropy (TE) calculation on binary data using the discrete TE calculator: ; Import relevant classes: (import infodynamics.measures.discrete.TransferEntropyCalculatorDiscrete) (let ; Generate some random binary data. [sourceArray (int-array (take 100 (repeatedly #(rand-int 2)))) destArray (int-array (cons 0 (butlast sourceArray))) ; shifts sourceArray by 1 sourceArray2 (int-array (take 100 (repeatedly #(rand-int 2)))) ; Create TE calculator teCalc (TransferEntropyCalculatorDiscrete. 2 1) ] ; Initialise the TE calculator and run it: (.initialise teCalc) (.addObservations teCalc sourceArray destArray) (println "For copied source, result should be close to 1 bit : " (.computeAverageLocalOfObservations teCalc)) (.initialise teCalc) (.addObservations teCalc sourceArray2 destArray) (println "For random source, result should be close to 0 bits : " (.computeAverageLocalOfObservations teCalc)) )
{ "pile_set_name": "Github" }
{ "name": "director", "description": "A client Side/Server Side Router", "author": "Charlie Robbins <[email protected]>", "version": "1.2.5", "maintainers": [ "hij1nx <[email protected]>", "beaugunderson <[email protected]>" ], "repository": { "type": "git", "url": "http://github.com/flatiron/director.git" }, "keywords": [ "URL", "router", "http", "cli", "flatiron", "client side", "ender" ], "devDependencies": { "api-easy": "0.4.x", "codesurgeon": "https://github.com/hij1nx/codesurgeon/tarball/master", "colors": "~1.0.3", "qunitjs": "~1.9.x", "request": "~2.49.0", "uglify-js": "~2.4.15", "vows": "0.7.x" }, "ender": "./build/ender.js", "browserify": "./build/director", "main": "./lib/director", "engines": { "node": ">= 0.8.0" }, "scripts": { "test": "vows test/server/*/*-test.js --spec" } }
{ "pile_set_name": "Github" }
#include <linux/pm.h> #include <linux/acpi.h> struct usb_hub_descriptor; struct dev_state; /* Functions local to drivers/usb/core/ */ extern int usb_create_sysfs_dev_files(struct usb_device *dev); extern void usb_remove_sysfs_dev_files(struct usb_device *dev); extern void usb_create_sysfs_intf_files(struct usb_interface *intf); extern void usb_remove_sysfs_intf_files(struct usb_interface *intf); extern int usb_create_ep_devs(struct device *parent, struct usb_host_endpoint *endpoint, struct usb_device *udev); extern void usb_remove_ep_devs(struct usb_host_endpoint *endpoint); extern void usb_enable_endpoint(struct usb_device *dev, struct usb_host_endpoint *ep, bool reset_toggle); extern void usb_enable_interface(struct usb_device *dev, struct usb_interface *intf, bool reset_toggles); extern void usb_disable_endpoint(struct usb_device *dev, unsigned int epaddr, bool reset_hardware); extern void usb_disable_interface(struct usb_device *dev, struct usb_interface *intf, bool reset_hardware); extern void usb_release_interface_cache(struct kref *ref); extern void usb_disable_device(struct usb_device *dev, int skip_ep0); extern int usb_deauthorize_device(struct usb_device *); extern int usb_authorize_device(struct usb_device *); extern void usb_detect_quirks(struct usb_device *udev); extern void usb_detect_interface_quirks(struct usb_device *udev); extern int usb_remove_device(struct usb_device *udev); extern int usb_get_device_descriptor(struct usb_device *dev, unsigned int size); extern int usb_get_bos_descriptor(struct usb_device *dev); extern void usb_release_bos_descriptor(struct usb_device *dev); extern char *usb_cache_string(struct usb_device *udev, int index); extern int usb_set_configuration(struct usb_device *dev, int configuration); extern int usb_choose_configuration(struct usb_device *udev); static inline unsigned usb_get_max_power(struct usb_device *udev, struct usb_host_config *c) { /* SuperSpeed power is in 8 mA units; others are in 2 mA units */ unsigned mul = (udev->speed == USB_SPEED_SUPER ? 8 : 2); return c->desc.bMaxPower * mul; } extern void usb_kick_khubd(struct usb_device *dev); extern int usb_match_one_id_intf(struct usb_device *dev, struct usb_host_interface *intf, const struct usb_device_id *id); extern int usb_match_device(struct usb_device *dev, const struct usb_device_id *id); extern void usb_forced_unbind_intf(struct usb_interface *intf); extern void usb_unbind_and_rebind_marked_interfaces(struct usb_device *udev); extern int usb_hub_claim_port(struct usb_device *hdev, unsigned port, struct dev_state *owner); extern int usb_hub_release_port(struct usb_device *hdev, unsigned port, struct dev_state *owner); extern void usb_hub_release_all_ports(struct usb_device *hdev, struct dev_state *owner); extern bool usb_device_is_owned(struct usb_device *udev); extern int usb_hub_init(void); extern void usb_hub_cleanup(void); extern int usb_major_init(void); extern void usb_major_cleanup(void); #ifdef CONFIG_PM extern int usb_suspend(struct device *dev, pm_message_t msg); extern int usb_resume(struct device *dev, pm_message_t msg); extern int usb_resume_complete(struct device *dev); extern int usb_port_suspend(struct usb_device *dev, pm_message_t msg); extern int usb_port_resume(struct usb_device *dev, pm_message_t msg); #else static inline int usb_port_suspend(struct usb_device *udev, pm_message_t msg) { return 0; } static inline int usb_port_resume(struct usb_device *udev, pm_message_t msg) { return 0; } #endif #ifdef CONFIG_PM_RUNTIME extern void usb_autosuspend_device(struct usb_device *udev); extern int usb_autoresume_device(struct usb_device *udev); extern int usb_remote_wakeup(struct usb_device *dev); extern int usb_runtime_suspend(struct device *dev); extern int usb_runtime_resume(struct device *dev); extern int usb_runtime_idle(struct device *dev); extern int usb_set_usb2_hardware_lpm(struct usb_device *udev, int enable); #else #define usb_autosuspend_device(udev) do {} while (0) static inline int usb_autoresume_device(struct usb_device *udev) { return 0; } static inline int usb_remote_wakeup(struct usb_device *udev) { return 0; } static inline int usb_set_usb2_hardware_lpm(struct usb_device *udev, int enable) { return 0; } #endif extern struct bus_type usb_bus_type; extern struct device_type usb_device_type; extern struct device_type usb_if_device_type; extern struct device_type usb_ep_device_type; extern struct device_type usb_port_device_type; extern struct usb_device_driver usb_generic_driver; static inline int is_usb_device(const struct device *dev) { return dev->type == &usb_device_type; } static inline int is_usb_interface(const struct device *dev) { return dev->type == &usb_if_device_type; } static inline int is_usb_endpoint(const struct device *dev) { return dev->type == &usb_ep_device_type; } static inline int is_usb_port(const struct device *dev) { return dev->type == &usb_port_device_type; } /* Do the same for device drivers and interface drivers. */ static inline int is_usb_device_driver(struct device_driver *drv) { return container_of(drv, struct usbdrv_wrap, driver)-> for_devices; } /* for labeling diagnostics */ extern const char *usbcore_name; /* sysfs stuff */ extern const struct attribute_group *usb_device_groups[]; extern const struct attribute_group *usb_interface_groups[]; /* usbfs stuff */ extern struct mutex usbfs_mutex; extern struct usb_driver usbfs_driver; extern const struct file_operations usbfs_devices_fops; extern const struct file_operations usbdev_file_operations; extern void usbfs_conn_disc_event(void); extern int usb_devio_init(void); extern void usb_devio_cleanup(void); /* internal notify stuff */ extern void usb_notify_add_device(struct usb_device *udev); extern void usb_notify_remove_device(struct usb_device *udev); extern void usb_notify_add_bus(struct usb_bus *ubus); extern void usb_notify_remove_bus(struct usb_bus *ubus); extern enum usb_port_connect_type usb_get_hub_port_connect_type(struct usb_device *hdev, int port1); extern void usb_set_hub_port_connect_type(struct usb_device *hdev, int port1, enum usb_port_connect_type type); extern void usb_hub_adjust_deviceremovable(struct usb_device *hdev, struct usb_hub_descriptor *desc); #ifdef CONFIG_ACPI extern int usb_acpi_register(void); extern void usb_acpi_unregister(void); extern acpi_handle usb_get_hub_port_acpi_handle(struct usb_device *hdev, int port1); #else static inline int usb_acpi_register(void) { return 0; }; static inline void usb_acpi_unregister(void) { }; #endif
{ "pile_set_name": "Github" }
/** * @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 */ // tslint:disable:no-console self.addEventListener('install', event => { self.skipWaiting(); }); self.addEventListener('activate', event => { event.waitUntil(self.clients.claim()); self.registration.unregister().then( () => { console.log('NGSW Safety Worker - unregistered old service worker'); }); });
{ "pile_set_name": "Github" }
<?php /** * The MIT License (MIT) * * Webzash - Easy to use web based double entry accounting software * * Copyright (c) 2014 Prashant Shah <[email protected]> * * 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. */ ?> <script type="text/javascript"> $(document).ready(function() { /* Setup jQuery datepicker ui */ $('#WzaccountFyStart').datepicker({ dateFormat: $("#WzaccountDateFormat").val().split('|')[1], /* Read the Javascript date format value */ numberOfMonths: 1, onClose: function(selectedDate) { $("#WzaccountFyEnd").datepicker("option", "minDate", selectedDate); } }); $('#WzaccountFyEnd').datepicker({ dateFormat: $("#WzaccountDateFormat").val().split('|')[1], /* Read the Javascript date format value */ numberOfMonths: 1, onClose: function(selectedDate) { $("#WzaccountFyStart").datepicker("option", "maxDate", selectedDate); } }); $("#WzaccountDateFormat").change(function() { /* Read the Javascript date format value */ dateFormat = $(this).val().split('|')[1]; $("#WzaccountFyStart").datepicker("option", "dateFormat", dateFormat); $("#WzaccountFyEnd").datepicker("option", "dateFormat", dateFormat); }); }); </script> <div class="wzaccount create form"> <?php echo $this->Form->create('Wzaccount', array( 'inputDefaults' => array( 'div' => 'form-group', 'wrapInput' => false, 'class' => 'form-control', ), )); echo $this->Form->input('label', array( 'label' => __d('webzash', 'Label'), 'afterInput' => '<span class="help-block">' . __d('webzash', 'Note : It is recommended to use a descriptive label like "sample20142105" which includes both a short name and the accounting year.') . '</span>', )); echo $this->Form->input('name', array('required' => 'required', 'div' => 'form-group required', 'label' => __d('webzash', 'Company / Personal Name'))); echo $this->Form->input('address', array('type' => 'textarea', 'label' => __d('webzash', 'Address'), 'rows' => '3')); echo $this->Form->input('email', array('label' => __d('webzash', 'Email'))); echo $this->Form->input('currency_symbol', array('label' => __d('webzash', 'Currency symbol'))); echo $this->Form->input('currency_format', array( 'type' => 'select', 'options' => $this->Generic->currency_format_options(), 'label' => __d('webzash', 'Currency format'), 'afterInput' => '<span class="help-block">' . __d('webzash', 'Note : Check the wiki if you want to create a custom format for currency.') . '</span>', )); echo $this->Form->input('decimal_places', array( 'type' => 'select', 'options' => $this->Generic->decimal_places_options(), 'label' => __d('webzash', 'Decimal places'), 'afterInput' => '<span class="help-block">' . __d('webzash', 'Note : This options cannot be changed later on.') . '</span>', )); echo $this->Form->input('date_format', array('type' => 'select', 'options' => $this->Generic->dateformat_options(), 'required' => 'required', 'div' => 'form-group required', 'label' => __d('webzash', 'Date format'))); echo $this->Form->input('fy_start', array('type' => 'text', 'required' => 'required', 'div' => 'form-group required', 'label' => __d('webzash', 'Financial year start'))); echo $this->Form->input('fy_end', array('type' => 'text', 'required' => 'required', 'div' => 'form-group required', 'label' => __d('webzash', 'Financial year end'))); echo "<fieldset><legend>Database Settings</legend>"; // TODO echo $this->Form->input('create_db', array('type' => 'checkbox', 'label' => __d('webzash', 'Create database if it does not exists'))); echo $this->Form->input('db_datasource', array('type' => 'select', 'options' => $this->Generic->wzaccount_dbtype_options(), 'label' => __d('webzash', 'Database type'))); echo $this->Form->input('db_database', array('label' => __d('webzash', 'Database name'))); echo $this->Form->input('db_schema', array( 'label' => __d('webzash', 'Database schema'), 'afterInput' => '<span class="help-block">' . __d('webzash', 'Note : Database schema is required for Postgres database connection. Leave it blank for MySQL connections.') . '</span>', )); echo $this->Form->input('db_host', array('label' => __d('webzash', 'Database host'), 'default' => 'localhost')); echo $this->Form->input('db_port', array('label' => __d('webzash', 'Database port'), 'default' => '3306' )); echo $this->Form->input('db_login', array('label' => __d('webzash', 'Database login'))); echo $this->Form->input('db_password', array('type' => 'password', 'label' => __d('webzash', 'Database password'))); echo $this->Form->input('db_prefix', array( 'label' => __d('webzash', 'Database prefix'), 'afterInput' => '<span class="help-block">' . __d('webzash', 'Note : Database table prefix to use (optional). All tables for this account will be created with this prefix, useful if you have only one database available and want to use multiple accounts.') . '</span>', )); echo $this->Form->input('db_persistent', array('type' => 'checkbox', 'label' => __d('webzash', 'Use persistent connection'), 'class' => 'checkbox')); echo $this->Form->input('db_settings', array( 'label' => __d('webzash', 'Database settings'), 'afterInput' => '<span class="help-block">' . __d('webzash', 'Note : Any additional settings to pass on to the database connection.') . '</span>', )); echo "</fieldset>"; echo '<div class="form-group">'; echo $this->Form->submit(__d('webzash', 'Submit'), array( 'div' => false, 'class' => 'btn btn-primary' )); echo $this->Html->tag('span', '', array('class' => 'link-pad')); echo $this->Html->link(__d('webzash', 'Cancel'), array('plugin' => 'webzash', 'controller' => 'admin', 'action' => 'index'), array('class' => 'btn btn-default')); echo '</div>'; echo $this->Form->end(); ?> </div>
{ "pile_set_name": "Github" }
# Installing qsimcirq The qsim-Cirq Python interface is available as a PyPI package for Linux users. For all other users, Dockerfiles are provided to install qsim in a contained environment. **Note:** The core qsim library (under [lib/](/lib)) can be included directly in C++ code without installing this interface. ## Linux installation Prior to installation, consider opening a [virtual environment](https://packaging.python.org/guides/installing-using-pip-and-virtual-environments/). The qsim-Cirq interface uses [CMake](https://cmake.org/) to ensure stable compilation of its C++ libraries across a variety of Linux distributions. CMake can be installed from their website, or with the command `apt-get install cmake`. Other prerequisites (including pybind11 and pytest) are included in the [`requirements.txt`](/requirements.txt) file, and will be automatically installed along with qsimcirq. To install the qsim-Cirq interface on Linux, simply run `pip3 install qsimcirq`. For examples of how to use this package, see the tests in [qsim/qsimcirq_tests/](/qsimcirq_tests/). ## MacOS and Windows installation For users interested in running qsim on a MacOS or Windows device, we strongly recommend using the [Docker config](/docs/docker.md) provided with this repository. ### Experimental install process Alternatively, MacOS and Windows users can follow the Linux install process, but it is currently untested on those platforms. Users are encouraged to report any issues seen with this process. ## Testing After installing qsimcirq on your machine, you can test the installation by copying [qsimcirq_tests/qsimcirq_test.py](qsimcirq_tests/qsimcirq_test.py) to your machine and running `python3 -m pytest qsimcirq_test.py`. **Note:** Because of how Python searches for modules, the test file cannot be run from inside a clone of the qsim repository, or from any parent directory of such a repository. Failure to meet this criteria may result in misbehaving tests (e.g. false positives after a failed install).
{ "pile_set_name": "Github" }
{ "assigned_to_str": "Allan L. Gropper", "case_name": "Enron Creditors Recovery Corp. - Adversary Proceeding", "cause": "", "court_id": "nysb", "date_converted": null, "date_discharged": null, "date_filed": "2003-09-24", "date_terminated": "2014-04-22", "demand": "", "docket_entries": [ { "date_filed": "2003-09-24", "description": "Complaint against Citigroup Inc. et al. Filed by Togut, Segal & Segal LLP, Scott Eric Ratner, Susman Godfrey L.L.P., Enron Corp. and Enron North America Corp., on behalf of Enron Corp. and Enron North America Corp.,. (Ratner, Scott) (Entered: 09/24/2003)", "document_number": "1", "pacer_doc_id": "12606962401", "pacer_seq_no": null }, { "date_filed": "2003-09-26", "description": "Summons and Notice of Pre-Trial Conference against Citigroup Inc. et al. Answer Due: 10/27/2003. Filed by Clerk's Office of the U.S. Bankruptcy Court. (Rodriguez, Maria) (Entered: 09/26/2003)", "document_number": "2", "pacer_doc_id": "12602935851", "pacer_seq_no": null }, { "date_filed": "2003-09-26", "description": "Summons and Notice of Pre-Trial Conference against Citigroup Inc. et al. Answer Due: 10/27/2003. Filed by Clerk's Office of the U.S. Bankruptcy Court. with Pre-Trial Conference set for 12/4/2003 at 10:00 AM at Courtroom 523 (AJG), (Rodriguez, Maria) (Entered: 09/26/2003)", "document_number": "3", "pacer_doc_id": "12606965212", "pacer_seq_no": null }, { "date_filed": "2003-10-08", "description": "Affidavit of Service of Summons and Notice of Pretrial Conference and Debtors' Complaint (related document(s)1, 2, 3) filed by Scott Eric Ratner on behalf of Enron Corp. and Enron North America Corp.,. (Attachments: 1 Service List)(Ratner, Scott) (Entered: 10/08/2003)", "document_number": "4", "pacer_doc_id": "12602984648", "pacer_seq_no": null } ], "docket_number": "03-09266", "jurisdiction": "", "jury_demand": "", "mdl_status": "", "nature_of_suit": "454 Recover Money/Property", "parties": [ { "attorneys": [ { "contact": "Crowell & Moring LLP\n153 East 53rd Street\n31st Street\nNew York, NY 10022\n(212) 223-4000\nFax : (212) 223-4134\nEmail:\n", "name": "William J. McSherry, Jr.", "roles": [ "LEAD ATTORNEY" ] }, { "contact": "Kelley Drye & Warren LLP\n101 Park Avnue\nNew York, NY 10178\n212-808-7800\nFax : 212-808-7897\nEmail:\n", "name": "Stacia A. Neeley", "roles": [ "LEAD ATTORNEY" ] } ], "date_terminated": null, "extra_info": "", "name": "Enron Development Funding, Ltd.", "type": "Plaintiff" }, { "attorneys": [ { "contact": "Crowell & Moring LLP\n153 East 53rd Street\n31st Street\nNew York, NY 10022\n(212) 223-4000\nFax : (212) 223-4134\nEmail:\n", "name": "William J. McSherry, Jr.", "roles": [ "LEAD ATTORNEY" ] }, { "contact": "Kelley Drye & Warren LLP\n101 Park Avnue\nNew York, NY 10178\n212-808-7800\nFax : 212-808-7897\nEmail:\n", "name": "Stacia A. Neeley", "roles": [ "LEAD ATTORNEY" ] } ], "date_terminated": null, "extra_info": "", "name": "Enron Energy Services, Inc.", "type": "Plaintiff" }, { "attorneys": [ { "contact": "Crowell & Moring LLP\n153 East 53rd Street\n31st Street\nNew York, NY 10022\n(212) 223-4000\nFax : (212) 223-4134\nEmail:\n", "name": "William J. McSherry, Jr.", "roles": [ "LEAD ATTORNEY" ] }, { "contact": "Kelley Drye & Warren LLP\n101 Park Avnue\nNew York, NY 10178\n212-808-7800\nFax : 212-808-7897\nEmail:\n", "name": "Stacia A. Neeley", "roles": [ "LEAD ATTORNEY" ] } ], "date_terminated": null, "extra_info": "", "name": "Enron Broadband Services, Inc.", "type": "Plaintiff" }, { "attorneys": [ { "contact": "Crowell & Moring LLP\n153 East 53rd Street\n31st Street\nNew York, NY 10022\n(212) 223-4000\nFax : (212) 223-4134\nEmail:\n", "name": "William J. McSherry, Jr.", "roles": [ "LEAD ATTORNEY" ] }, { "contact": "Kelley Drye & Warren LLP\n101 Park Avnue\nNew York, NY 10178\n212-808-7800\nFax : 212-808-7897\nEmail:\n", "name": "Stacia A. Neeley", "roles": [ "LEAD ATTORNEY" ] } ], "date_terminated": null, "extra_info": "", "name": "Enron Natural Gas Marketing Corp.", "type": "Plaintiff" }, { "attorneys": [ { "contact": "Crowell & Moring LLP\n153 East 53rd Street\n31st Street\nNew York, NY 10022\n(212) 223-4000\nFax : (212) 223-4134\nEmail:\n", "name": "William J. McSherry, Jr.", "roles": [ "LEAD ATTORNEY" ] }, { "contact": "Kelley Drye & Warren LLP\n101 Park Avnue\nNew York, NY 10178\n212-808-7800\nFax : 212-808-7897\nEmail:\n", "name": "Stacia A. Neeley", "roles": [ "LEAD ATTORNEY" ] } ], "date_terminated": null, "extra_info": "", "name": "Enron North America Corp.", "type": "Plaintiff" }, { "attorneys": [ { "contact": "Kasowitz, Benson, Torres & Friedman LLP\n1633 Broadway\nNew York, NY 10019\n(212) 506-1913\nFax : (212) 506-1800\nEmail:\n", "name": "Richard F. Casher", "roles": [] }, { "contact": "Kasowitz Benson Torres LLP\n1633 Broadway\nNew York, NY 10019\n(212 506-1990\nFax : (212) 506-1800\nEmail:\n", "name": "David J. Mark", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Bank of New York, as Indenture Trustee and Collateral Agent, Yosemite Securities Trust I, Yosemite Securities Company, Ltd., Enron Credit Linked Notes Trust, Enron Credit Linked Notes Trust II", "type": "Plaintiff" }, { "attorneys": [], "date_terminated": null, "extra_info": "", "name": "Enron Sterling Credit Linked Notes Trust and Enron Euro Credit Linked Notes Trust", "type": "Plaintiff" }, { "attorneys": [ { "contact": "Klee, Tuchin, Bogdanoff & Stern LLP\n1999 Avenue of Stars\n39th Floor\nLos Angeles, CA 90067\n(310) 407-4000\nFax : (310) 407-9090\nEmail:\n", "name": "Martin R. Barash", "roles": [] }, { "contact": "Klee, Tuchin, Bogdanoff & Stern LLP\n1999 Avenue of the Stars\n39th Floor\nLos Angeles, CA 90067\n(310) 407-4000\nFax : (310) 407-9090\nEmail:\n", "name": "Matthew Christopher Heyn", "roles": [] }, { "contact": "Crowell & Moring LLP\n590 Madison Avenue\n20th Fl\nNew York, NY 10022\n212-223-4000\nFax : 212-223-4134\nEmail:\n", "name": "Mark S. Lichtenstein", "roles": [] }, { "contact": "Crowell & Moring LLP\n153 East 53rd Street\n31st Street\nNew York, NY 10022\n(212) 223-4000\nFax : (212) 223-4134\nEmail:\n", "name": "William J. McSherry, Jr.", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Enron Creditors Recovery Corp., et al", "type": "Plaintiff" }, { "attorneys": [ { "contact": "Paul Weiss Rifkind Wharton\n& Garrison LLP\n1285 Avenue of the Americas\nNew York, NY 10019-6064\n(212) 373-3130\nFax : (212) 373-2377\nEmail:\n", "name": "Douglas R. Davis", "roles": [] }, { "contact": "Paul, Weiss, Rifkind, Wharton\n& Garrison LLP\n1285 Avenue of the Americas\nNew York, NY 10019\n(212) 373-3000\nFax : (212) 757-3990\nEmail:\n", "name": "Brad S. Karp", "roles": [] }, { "contact": "Curtis, Mallet-Prevost, Colt & Mosle LLP\n101 Park Avenue\nNew York, NY 10178\n212-696-6065\nFax : (212) 697-1559\nEmail:\n", "name": "Steven J. Reisman", "roles": [] }, { "contact": "Paul, Weiss, Rifkind, Wharton\n& Garrison LLP\n1285 Avenue of the Americas\nNew York, NY 10019\n(212) 373-3133\nFax : (212) 757-3990\nEmail:\n", "name": "Stephen J. Shimshak", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Citigroup Inc. et al.", "type": "Defendant" }, { "attorneys": [ { "contact": "Jones Day\n222 East 41st Street\nNew York, NY 10017\n(212) 326-8340\nFax : (212) 755-7306\nEmail:\n", "name": "Lee A. Armstrong", "roles": [] }, { "contact": "Jones Day\n222 East 41st Street\nNew York, NY 10017\n(212) 326-3939\nFax : (212) 755-7306\nEmail:\n", "name": "Sevan Ogulluk", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Royal Bank of Scotland plc", "type": "Defendant" }, { "attorneys": [ { "contact": "Ropes & Gray, LLP\nPrudential Tower\n800 Boylston Street\nBoston, MA 02199\n617-951-7589\nEmail:\n", "name": "Matthew M. Burke", "roles": [ "LEAD ATTORNEY" ] }, { "contact": "Ropes & Gray LLP\n1211 Avenue of the Americas\nNew York, NY 10036-8704\n(212) 596-9000\nFax : (212) 596-9090\nEmail:\n", "name": "David S. Elkind", "roles": [] }, { "contact": "Ropes & Gray, LLP\n45 Rockefeller Plaza\nNew York, NY 10111\n(212) 841-5700\nFax : (212) 841-5725\nEmail:\n", "name": "John C. Ertman", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Long Lane Master Trust IV", "type": "Defendant" }, { "attorneys": [ { "contact": "Ropes & Gray, LLP\nPrudential Tower\n800 Boylston Street\nBoston, MA 02199\n617-951-7589\nEmail:\n", "name": "Matthew M. Burke", "roles": [ "LEAD ATTORNEY" ] }, { "contact": "Ropes & Gray LLP\n1211 Avenue of the Americas\nNew York, NY 10036-8704\n(212) 596-9000\nFax : (212) 596-9090\nEmail:\n", "name": "David S. Elkind", "roles": [] }, { "contact": "Ropes & Gray, LLP\n45 Rockefeller Plaza\nNew York, NY 10111\n(212) 841-5700\nFax : (212) 841-5725\nEmail:\n", "name": "John C. Ertman", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Fleet National Bank", "type": "Defendant" }, { "attorneys": [ { "contact": "Ropes & Gray, LLP\nPrudential Tower\n800 Boylston Street\nBoston, MA 02199\n617-951-7589\nEmail:\n", "name": "Matthew M. Burke", "roles": [ "LEAD ATTORNEY" ] }, { "contact": "Ropes & Gray LLP\n1211 Avenue of the Americas\nNew York, NY 10036-8704\n(212) 596-9000\nFax : (212) 596-9090\nEmail:\n", "name": "David S. Elkind", "roles": [] }, { "contact": "Ropes & Gray, LLP\n45 Rockefeller Plaza\nNew York, NY 10111\n(212) 841-5700\nFax : (212) 841-5725\nEmail:\n", "name": "John C. Ertman", "roles": [] }, { "contact": "Ropes & Gray, LLP\n1211 Avenue of the Americas\nNew York, NY 10036-8704\n(212) 596-9000\nFax : (212) 596-9090\nEmail:\n", "name": "Marc F. Skapof", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "FleetBoston Financial Corp.", "type": "Defendant" }, { "attorneys": [ { "contact": "Butzel Long\n380 Madison\nNew York, NY 10017\n(212) 323-8616\nEmail:\n", "name": "Andrew D. Shaffer", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Canadian Imperial Bank of Commerce", "type": "Defendant" }, { "attorneys": [ { "contact": "Ropes & Gray LLP\n1211 Avenue of the Americas\nNew York, NY 10036-8704\n(212) 596-9000\nFax : (212) 596-9090\nEmail:\n", "name": "Mark I Bane", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "J.P. Morgan Chase & Co., JPMorgan Chase Bank and J.P. Morgan Securities Inc.", "type": "Defendant" }, { "attorneys": [], "date_terminated": null, "extra_info": "", "name": "Mahonia Limited, Mahonia Natural Gas Limited and Stoneville Aegean Limited", "type": "Defendant" }, { "attorneys": [ { "contact": "Dentons US LLP\n1221 Avenue of the Americas\nNew York, NY 10020\n(212) 768-6700\nFax : (212) 768-6800\nEmail:\n", "name": "Hugh M. McDonald", "roles": [] }, { "contact": "Sullivan & Cromwell, LLP\n125 Broad Street\nNew York, NY 10004-2498\n(212) 558-4715\nFax : (212) 558-3588\nEmail:\n", "name": "Michael T. Tomaino, Jr.", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Barclays Capital Inc.", "type": "Defendant" }, { "attorneys": [ { "contact": "Dentons US LLP\n1221 Avenue of the Americas\nNew York, NY 10020\n(212) 768-6700\nFax : (212) 768-6800\nEmail:\n", "name": "Hugh M. McDonald", "roles": [] }, { "contact": "Sullivan & Cromwell, LLP\n125 Broad Street\nNew York, NY 10004-2498\n(212) 558-4715\nFax : (212) 558-3588\nEmail:\n", "name": "Michael T. Tomaino, Jr.", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Barclays Bank PLC", "type": "Defendant" }, { "attorneys": [ { "contact": "Dentons US LLP\n1221 Avenue of the Americas\nNew York, NY 10020\n(212) 768-6700\nFax : (212) 768-6800\nEmail:\n", "name": "Hugh M. McDonald", "roles": [] }, { "contact": "Sullivan & Cromwell, LLP\n125 Broad Street\nNew York, NY 10004-2498\n(212) 558-4715\nFax : (212) 558-3588\nEmail:\n", "name": "Michael T. Tomaino, Jr.", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Barclays PLC", "type": "Defendant" }, { "attorneys": [ { "contact": "Law Office of Jeffrey S. Saltz, P.C.\nTwo Penn Center Plaza, Suite 1930\n1500 John F. Kennedy Boulevard\nPhiladelphia, PA 19102\n(215) 523-5317\nFax : (215) 523-5339\nEmail:\n", "name": "Jeffrey S. Saltz", "roles": [] } ], "date_terminated": null, "extra_info": "PO Box 1040 Harbour Center\n2nd Floor\nN. Church Street\nGeorge Town, Cayman Isl.\nWest Indie", "name": "Delta Energy Corporation", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Credit Suisse First Boston International (USA), Inc.", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Credit Suisse First Boston, Inc.", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Pershing LLC", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "ERNB Ltd.", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Credit Suisse First Boston International", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "DLJ Capital Funding, Inc.", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Credit Suisse First Boston LLC", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Merchant Capital, Inc.", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Credit Suisse First Boston (USA), Inc.", "type": "Defendant" }, { "attorneys": [ { "contact": "Gibson, Dunn & Crutcher, LLP\n200 Park Avenue\nNew York, NY 10166-0193\n(212) 351-4000\nFax : (212) 351-4035\n", "name": "Michelle Craven", "roles": [] }, { "contact": "Shearman & Sterling LLP\n599 Lexington Avenue\nNew York, NY 10022\n(212) 848-4575\nFax : (646) 848-4575\n", "name": "Seth M. Kean", "roles": [] }, { "contact": "Vedder Price\n1633 Broadway\n47th Floor\nNew York, NY 10019\n(212) 407 7700\nEmail:\n", "name": "Michael J. Riela", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Gibson, Dunn & Crutcher LLP\n200 Park Avenue\nNew York, NY 10166", "name": "Merrill Lynch Capital Services, Inc.", "type": "Defendant" }, { "attorneys": [ { "contact": "Gibson, Dunn & Crutcher, LLP\n200 Park Avenue\nNew York, NY 10166-0193\n(212) 351-4000\nFax : (212) 351-4035\n", "name": "Michelle Craven", "roles": [] }, { "contact": "Shearman & Sterling LLP\n599 Lexington Avenue\nNew York, NY 10022\n(212) 848-4575\nFax : (646) 848-4575\n", "name": "Seth M. Kean", "roles": [] }, { "contact": "Vedder Price\n1633 Broadway\n47th Floor\nNew York, NY 10019\n(212) 407 7700\nEmail:\n", "name": "Michael J. Riela", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Gibson Dunn & Crutcher, LLP\n200 Park Avenue\nNew York, NY 10166\n(212) 351-4000", "name": "Merrill Lynch & Co., Inc.", "type": "Defendant" }, { "attorneys": [ { "contact": "Seward & Kissel, LLP\nOne Battery Park Plaza\nNew York, NY 10006\n(212) 574-1200\nFax : (212) 480-8421\nEmail:\n", "name": "John R. Ashmead", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel LLP\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1200", "name": "RBC Dominion Securities Corporation", "type": "Defendant" }, { "attorneys": [ { "contact": "Seward & Kissel, LLP\nOne Battery Park Plaza\nNew York, NY 10006\n(212) 574-1200\nFax : (212) 480-8421\nEmail:\n", "name": "John R. Ashmead", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel LLP\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1200", "name": "RBC Holdings (USA) Inc.", "type": "Defendant" }, { "attorneys": [ { "contact": "Seward & Kissel, LLP\nOne Battery Park Plaza\nNew York, NY 10006\n(212) 574-1200\nFax : (212) 480-8421\nEmail:\n", "name": "John R. Ashmead", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel LLP\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1200", "name": "RBC Dominion Securities Limited", "type": "Defendant" }, { "attorneys": [ { "contact": "Seward & Kissel, LLP\nOne Battery Park Plaza\nNew York, NY 10006\n(212) 574-1200\nFax : (212) 480-8421\nEmail:\n", "name": "John R. Ashmead", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel LLP\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1200", "name": "RBC Dominion Securities Inc.", "type": "Defendant" }, { "attorneys": [ { "contact": "Seward & Kissel, LLP\nOne Battery Park Plaza\nNew York, NY 10006\n(212) 574-1200\nFax : (212) 480-8421\nEmail:\n", "name": "John R. Ashmead", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel LLP\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1200", "name": "Royal Bank Holding Inc.", "type": "Defendant" }, { "attorneys": [ { "contact": "Seward & Kissel, LLP\nOne Battery Park Plaza\nNew York, NY 10006\n(212) 574-1200\nFax : (212) 480-8421\nEmail:\n", "name": "John R. Ashmead", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel LLP\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1200", "name": "Royal Bank of Canada", "type": "Defendant" }, { "attorneys": [ { "contact": "Fox Rothschild LLP\n101 Park Avenue\nSuite 1700\nNew York, NY 10178\n(212) 878-7900\nFax : (212) 692-0940\nEmail:\n", "name": "Yann Geron", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Hawaii II 125-0 Trust", "type": "Defendant" }, { "attorneys": [ { "contact": "Fox Rothschild LLP\n101 Park Avenue\nSuite 1700\nNew York, NY 10178\n(212) 878-7900\nFax : (212) 692-0940\nEmail:\n", "name": "Yann Geron", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Hawaii I 125-0 Trust", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Credit Suisse First Boston, Cayman Island Branch", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "DLJ Fund Investment Partners III, L.P.", "type": "Defendant" }, { "attorneys": [ { "contact": "Cravath, Swaine & Moore, LLP\n825 Eighth Avenue\nNew York, NY 10019\n(212) 474-1000\nFax : (212) 474-3700\nEmail:\n", "name": "Richard W. Clary", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Credit Suisse First Boston", "type": "Defendant" }, { "attorneys": [ { "contact": "Thacher Proffitt & Wood LLP\nTwo World Financial Center\nNew York, NY 10281\n(212) 912-7679\nFax : (212) 912-7751\n", "name": "Jonathan D. Forstot", "roles": [] } ], "date_terminated": null, "extra_info": "", "name": "Colonnade Limited", "type": "Defendant" }, { "attorneys": [], "date_terminated": null, "extra_info": "", "name": "The Bank of New York, as Indenture Trustee and Collateral Agent, Yosemite Securities Trust I, Yosemite Securities Company, Ltd., Enron Credit Linked Notes Trust, Enron Credit Linked Notes Trust II", "type": "Trustee" }, { "attorneys": [], "date_terminated": null, "extra_info": "", "name": "Enron Creditors Recovery Corp., et al", "type": "Counter-Defendant" }, { "attorneys": [ { "contact": "Seward & Kissel\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1515\nFax : (212) 480-8421\nEmail:\n", "name": "Ronald L. Cohen", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel", "name": "Enron Euro Credit Linked Notes Trust", "type": "Counter-Claimant" }, { "attorneys": [ { "contact": "Seward & Kissel\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1515\nFax : (212) 480-8421\nEmail:\n", "name": "Ronald L. Cohen", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel", "name": "Enron Sterling Credit Linked Notes Trust", "type": "Counter-Claimant" }, { "attorneys": [ { "contact": "Seward & Kissel\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1515\nFax : (212) 480-8421\nEmail:\n", "name": "Ronald L. Cohen", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel", "name": "Enron Credit Linked Notes Trust II", "type": "Counter-Claimant" }, { "attorneys": [ { "contact": "Seward & Kissel\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1515\nFax : (212) 480-8421\nEmail:\n", "name": "Ronald L. Cohen", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel", "name": "Enron Credit Linked Notes Trust", "type": "Counter-Claimant" }, { "attorneys": [ { "contact": "Seward & Kissel\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1515\nFax : (212) 480-8421\nEmail:\n", "name": "Ronald L. Cohen", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel", "name": "Yosemite Securities Company, Ltd.", "type": "Counter-Claimant" }, { "attorneys": [ { "contact": "Kasowitz, Benson, Torres & Friedman LLP\n1633 Broadway\nNew York, NY 10019\n(212) 506-1913\nFax : (212) 506-1800\nEmail:\n", "name": "Richard F. Casher", "roles": [] }, { "contact": "Seward & Kissel\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1515\nFax : (212) 480-8421\nEmail:\n", "name": "Ronald L. Cohen", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Seward & Kissel\nOne Battery Park Plaza\nNY, NY 10004\n(212) 574-1200", "name": "Yosemite Securities Trust I", "type": "Counter-Claimant" }, { "attorneys": [ { "contact": "Seward & Kissel\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1515\nFax : (212) 480-8421\nEmail:\n", "name": "Ronald L. Cohen", "roles": [] } ], "date_terminated": null, "extra_info": "as Indenture Trustee and Collateral Agent\nc/o Seward & Kissel\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1200", "name": "The Bank of New York, as Indenture Trustee and Collateral Agent", "type": "Counter-Claimant" }, { "attorneys": [], "date_terminated": null, "extra_info": "c/o Seward & Kissel", "name": "Enron Credit Linked Notes Trust", "type": "Counter-Claimant" }, { "attorneys": [], "date_terminated": null, "extra_info": "c/o Seward & Kissel", "name": "Enron Credit Linked Notes Trust II", "type": "Counter-Claimant" }, { "attorneys": [], "date_terminated": null, "extra_info": "c/o Seward & Kissel", "name": "Enron Euro Credit Linked Notes Trust", "type": "Counter-Claimant" }, { "attorneys": [], "date_terminated": null, "extra_info": "c/o Seward & Kissel", "name": "Enron Sterling Credit Linked Notes Trust", "type": "Counter-Claimant" }, { "attorneys": [], "date_terminated": null, "extra_info": "as Indenture Trustee and Collateral Agent\nc/o Seward & Kissel\nOne Battery Park Plaza\nNew York, NY 10004\n(212) 574-1200", "name": "The Bank of New York, as Indenture Trustee and Collateral Agent", "type": "Counter-Claimant" }, { "attorneys": [], "date_terminated": null, "extra_info": "c/o Seward & Kissel", "name": "Yosemite Securities Company, Ltd.", "type": "Counter-Claimant" }, { "attorneys": [], "date_terminated": null, "extra_info": "c/o Seward & Kissel\nOne Battery Park Plaza\nNY, NY 10004\n(212) 574-1200", "name": "Yosemite Securities Trust I", "type": "Counter-Claimant" }, { "attorneys": [ { "contact": "Dentons US LLP\n1221 Avenue of the Americas\nNew York, NY 10020\n(212) 768-6700\nFax : (212) 768-6800\nEmail:\n", "name": "Hugh M. McDonald", "roles": [] } ], "date_terminated": null, "extra_info": "54 Lombard Street\nLondon EC 3P 3AH\nEngland", "name": "Barclays Metals Limited", "type": "3rd Party Plaintiff" }, { "attorneys": [ { "contact": "Dentons US LLP\n1221 Avenue of the Americas\nNew York, NY 10020\n(212) 768-6700\nFax : (212) 768-6800\nEmail:\n", "name": "Hugh M. McDonald", "roles": [] } ], "date_terminated": null, "extra_info": "f/k/a Barclays (Metals) Holdings Limited\n54 Lombard Street\nLondon EC 3P 3AH\nEngland", "name": "Barclays Physical Trading Limited, f/k/a Barclays (Metals) Holdings Limited", "type": "3rd Party Plaintiff" }, { "attorneys": [ { "contact": "Dentons US LLP\n1221 Avenue of the Americas\nNew York, NY 10020\n(212) 768-6700\nFax : (212) 768-6800\nEmail:\n", "name": "Hugh M. McDonald", "roles": [] } ], "date_terminated": null, "extra_info": "54 Lombard Street\nLondon EC 3P 3AH\nEngland", "name": "Barclays Capital Securities Limited", "type": "3rd Party Plaintiff" }, { "attorneys": [ { "contact": "Dentons US LLP\n1221 Avenue of the Americas\nNew York, NY 10020\n(212) 768-6700\nFax : (212) 768-6800\nEmail:\n", "name": "Hugh M. McDonald", "roles": [] } ], "date_terminated": null, "extra_info": "54 Lombard Street\nLondon EC 3P 3AH\nEngland", "name": "Barclays Bank PLC", "type": "3rd Party Plaintiff" }, { "attorneys": [ { "contact": "260 Madison Avenue\n18th Floor\nNew York, NY 10016\n(212) 532-8000\nFax : (212) 679-8998\nEmail:\n", "name": "Kenneth A. Zitter", "roles": [] } ], "date_terminated": null, "extra_info": "33 W. Monroe\nChicago, Il 60603", "name": "Arthur Andersen LLP", "type": "3rd Pty Defendant" }, { "attorneys": [ { "contact": "Shearman & Sterling LLP\n599 Lexington Avenue\nNew York, NY 10022\n(212) 848-4575\nFax : (646) 848-4575\n", "name": "Seth M. Kean", "roles": [] } ], "date_terminated": null, "extra_info": "c/o Gibson, Dunn & Crutcher LLP\n200 Park Avenue\nNew York, NY 10166", "name": "Merrill Lynch, Pierce, Fenner & Smith, Inc.", "type": "3rd Party Plaintiff" }, { "attorneys": [ { "contact": "Curtis, Mallet-Prevost, Colt & Mosle LLP\n101 Park Avenue\nNew York, NY 10178\n212-696-6065\nFax : (212) 697-1559\nEmail:\n", "name": "Steven J. Reisman", "roles": [] }, { "contact": "260 Madison Avenue\n18th Floor\nNew York, NY 10016\n(212) 532-8000\nFax : (212) 679-8998\nEmail:\n", "name": "Kenneth A. Zitter", "roles": [] } ], "date_terminated": null, "extra_info": "33 W. Monroe\nChicago, Il 60603", "name": "Arthur Andersen LLP", "type": "3rd Pty Defendant" } ], "referred_to_str": "" }
{ "pile_set_name": "Github" }
/* * Copyright (C) 2014 The Android Open Source Project * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/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. */ package com.android.server.hdmi; import android.hardware.hdmi.HdmiControlManager; import android.hardware.hdmi.HdmiDeviceInfo; import android.hardware.hdmi.IHdmiControlCallback; import android.hardware.tv.cec.V1_0.SendMessageResult; import android.os.PowerManager; import android.os.PowerManager.WakeLock; import android.os.SystemProperties; import android.provider.Settings.Global; import android.util.Slog; import com.android.internal.annotations.VisibleForTesting; import com.android.internal.app.LocalePicker; import com.android.internal.app.LocalePicker.LocaleInfo; import com.android.internal.util.IndentingPrintWriter; import com.android.server.hdmi.HdmiAnnotations.ServiceThreadOnly; import com.android.server.hdmi.HdmiControlService.SendMessageCallback; import java.io.UnsupportedEncodingException; import java.util.List; import java.util.Locale; /** * Represent a logical device of type Playback residing in Android system. */ public class HdmiCecLocalDevicePlayback extends HdmiCecLocalDeviceSource { private static final String TAG = "HdmiCecLocalDevicePlayback"; private static final boolean WAKE_ON_HOTPLUG = SystemProperties.getBoolean(Constants.PROPERTY_WAKE_ON_HOTPLUG, true); private static final boolean SET_MENU_LANGUAGE = SystemProperties.getBoolean(Constants.PROPERTY_SET_MENU_LANGUAGE, false); // Used to keep the device awake while it is the active source. For devices that // cannot wake up via CEC commands, this address the inconvenience of having to // turn them on. True by default, and can be disabled (i.e. device can go to sleep // in active device status) by explicitly setting the system property // persist.sys.hdmi.keep_awake to false. // Lazily initialized - should call getWakeLock() to get the instance. private ActiveWakeLock mWakeLock; // If true, turn off TV upon standby. False by default. private boolean mAutoTvOff; // Local active port number used for Routing Control. // Default 0 means HOME is the current active path. Temp solution only. // TODO(amyjojo): adding system constants for input ports to TIF mapping. private int mLocalActivePath = 0; HdmiCecLocalDevicePlayback(HdmiControlService service) { super(service, HdmiDeviceInfo.DEVICE_PLAYBACK); mAutoTvOff = mService.readBooleanSetting(Global.HDMI_CONTROL_AUTO_DEVICE_OFF_ENABLED, false); // The option is false by default. Update settings db as well to have the right // initial setting on UI. mService.writeBooleanSetting(Global.HDMI_CONTROL_AUTO_DEVICE_OFF_ENABLED, mAutoTvOff); } @Override @ServiceThreadOnly protected void onAddressAllocated(int logicalAddress, int reason) { assertRunOnServiceThread(); if (reason == mService.INITIATED_BY_ENABLE_CEC) { mService.setAndBroadcastActiveSource(mService.getPhysicalAddress(), getDeviceInfo().getDeviceType(), Constants.ADDR_BROADCAST); } mService.sendCecCommand(HdmiCecMessageBuilder.buildReportPhysicalAddressCommand( mAddress, mService.getPhysicalAddress(), mDeviceType)); mService.sendCecCommand(HdmiCecMessageBuilder.buildDeviceVendorIdCommand( mAddress, mService.getVendorId())); if (mService.audioSystem() == null) { // If current device is not a functional audio system device, // send message to potential audio system device in the system to get the system // audio mode status. If no response, set to false. mService.sendCecCommand(HdmiCecMessageBuilder.buildGiveSystemAudioModeStatus( mAddress, Constants.ADDR_AUDIO_SYSTEM), new SendMessageCallback() { @Override public void onSendCompleted(int error) { if (error != SendMessageResult.SUCCESS) { HdmiLogger.debug( "AVR did not respond to <Give System Audio Mode Status>"); mService.setSystemAudioActivated(false); } } }); } startQueuedActions(); } @Override @ServiceThreadOnly protected int getPreferredAddress() { assertRunOnServiceThread(); return SystemProperties.getInt(Constants.PROPERTY_PREFERRED_ADDRESS_PLAYBACK, Constants.ADDR_UNREGISTERED); } @Override @ServiceThreadOnly protected void setPreferredAddress(int addr) { assertRunOnServiceThread(); mService.writeStringSystemProperty(Constants.PROPERTY_PREFERRED_ADDRESS_PLAYBACK, String.valueOf(addr)); } @ServiceThreadOnly void queryDisplayStatus(IHdmiControlCallback callback) { assertRunOnServiceThread(); List<DevicePowerStatusAction> actions = getActions(DevicePowerStatusAction.class); if (!actions.isEmpty()) { Slog.i(TAG, "queryDisplayStatus already in progress"); actions.get(0).addCallback(callback); return; } DevicePowerStatusAction action = DevicePowerStatusAction.create(this, Constants.ADDR_TV, callback); if (action == null) { Slog.w(TAG, "Cannot initiate queryDisplayStatus"); invokeCallback(callback, HdmiControlManager.RESULT_EXCEPTION); return; } addAndStartAction(action); } @Override @ServiceThreadOnly void onHotplug(int portId, boolean connected) { assertRunOnServiceThread(); mCecMessageCache.flushAll(); // We'll not clear mIsActiveSource on the hotplug event to pass CETC 11.2.2-2 ~ 3. if (WAKE_ON_HOTPLUG && connected && mService.isPowerStandbyOrTransient()) { mService.wakeUp(); } if (!connected) { getWakeLock().release(); } } @Override @ServiceThreadOnly protected void onStandby(boolean initiatedByCec, int standbyAction) { assertRunOnServiceThread(); if (!mService.isControlEnabled() || initiatedByCec || !mAutoTvOff) { return; } switch (standbyAction) { case HdmiControlService.STANDBY_SCREEN_OFF: mService.sendCecCommand( HdmiCecMessageBuilder.buildStandby(mAddress, Constants.ADDR_TV)); break; case HdmiControlService.STANDBY_SHUTDOWN: // ACTION_SHUTDOWN is taken as a signal to power off all the devices. mService.sendCecCommand( HdmiCecMessageBuilder.buildStandby(mAddress, Constants.ADDR_BROADCAST)); break; } } @Override @ServiceThreadOnly void setAutoDeviceOff(boolean enabled) { assertRunOnServiceThread(); mAutoTvOff = enabled; } @ServiceThreadOnly @VisibleForTesting void setIsActiveSource(boolean on) { assertRunOnServiceThread(); mIsActiveSource = on; if (on) { getWakeLock().acquire(); } else { getWakeLock().release(); } } @ServiceThreadOnly private ActiveWakeLock getWakeLock() { assertRunOnServiceThread(); if (mWakeLock == null) { if (SystemProperties.getBoolean(Constants.PROPERTY_KEEP_AWAKE, true)) { mWakeLock = new SystemWakeLock(); } else { // Create a dummy lock object that doesn't do anything about wake lock, // hence allows the device to go to sleep even if it's the active source. mWakeLock = new ActiveWakeLock() { @Override public void acquire() { } @Override public void release() { } @Override public boolean isHeld() { return false; } }; HdmiLogger.debug("No wakelock is used to keep the display on."); } } return mWakeLock; } @Override protected boolean canGoToStandby() { return !getWakeLock().isHeld(); } @ServiceThreadOnly protected boolean handleUserControlPressed(HdmiCecMessage message) { assertRunOnServiceThread(); wakeUpIfActiveSource(); return super.handleUserControlPressed(message); } @Override protected void wakeUpIfActiveSource() { if (!mIsActiveSource) { return; } // Wake up the device if the power is in standby mode, or its screen is off - // which can happen if the device is holding a partial lock. if (mService.isPowerStandbyOrTransient() || !mService.getPowerManager().isScreenOn()) { mService.wakeUp(); } } @Override protected void maySendActiveSource(int dest) { if (mIsActiveSource) { mService.sendCecCommand(HdmiCecMessageBuilder.buildActiveSource( mAddress, mService.getPhysicalAddress())); // Always reports menu-status active to receive RCP. mService.sendCecCommand(HdmiCecMessageBuilder.buildReportMenuStatus( mAddress, dest, Constants.MENU_STATE_ACTIVATED)); } } @ServiceThreadOnly protected boolean handleSetMenuLanguage(HdmiCecMessage message) { assertRunOnServiceThread(); if (!SET_MENU_LANGUAGE) { return false; } try { String iso3Language = new String(message.getParams(), 0, 3, "US-ASCII"); Locale currentLocale = mService.getContext().getResources().getConfiguration().locale; if (currentLocale.getISO3Language().equals(iso3Language)) { // Do not switch language if the new language is the same as the current one. // This helps avoid accidental country variant switching from en_US to en_AU // due to the limitation of CEC. See the warning below. return true; } // Don't use Locale.getAvailableLocales() since it returns a locale // which is not available on Settings. final List<LocaleInfo> localeInfos = LocalePicker.getAllAssetLocales( mService.getContext(), false); for (LocaleInfo localeInfo : localeInfos) { if (localeInfo.getLocale().getISO3Language().equals(iso3Language)) { // WARNING: CEC adopts ISO/FDIS-2 for language code, while Android requires // additional country variant to pinpoint the locale. This keeps the right // locale from being chosen. 'eng' in the CEC command, for instance, // will always be mapped to en-AU among other variants like en-US, en-GB, // an en-IN, which may not be the expected one. LocalePicker.updateLocale(localeInfo.getLocale()); return true; } } Slog.w(TAG, "Can't handle <Set Menu Language> of " + iso3Language); return false; } catch (UnsupportedEncodingException e) { Slog.w(TAG, "Can't handle <Set Menu Language>", e); return false; } } @Override protected boolean handleSetSystemAudioMode(HdmiCecMessage message) { // System Audio Mode only turns on/off when Audio System broadcasts on/off message. // For device with type 4 and 5, it can set system audio mode on/off // when there is another audio system device connected into the system first. if (message.getDestination() != Constants.ADDR_BROADCAST || message.getSource() != Constants.ADDR_AUDIO_SYSTEM || mService.audioSystem() != null) { return true; } boolean setSystemAudioModeOn = HdmiUtils.parseCommandParamSystemAudioStatus(message); if (mService.isSystemAudioActivated() != setSystemAudioModeOn) { mService.setSystemAudioActivated(setSystemAudioModeOn); } return true; } @Override protected boolean handleSystemAudioModeStatus(HdmiCecMessage message) { // Only directly addressed System Audio Mode Status message can change internal // system audio mode status. if (message.getDestination() == mAddress && message.getSource() == Constants.ADDR_AUDIO_SYSTEM) { boolean setSystemAudioModeOn = HdmiUtils.parseCommandParamSystemAudioStatus(message); if (mService.isSystemAudioActivated() != setSystemAudioModeOn) { mService.setSystemAudioActivated(setSystemAudioModeOn); } } return true; } @Override protected int findKeyReceiverAddress() { return Constants.ADDR_TV; } @Override protected int findAudioReceiverAddress() { if (mService.isSystemAudioActivated()) { return Constants.ADDR_AUDIO_SYSTEM; } return Constants.ADDR_TV; } @Override @ServiceThreadOnly protected void disableDevice(boolean initiatedByCec, PendingActionClearedCallback callback) { super.disableDevice(initiatedByCec, callback); assertRunOnServiceThread(); if (!initiatedByCec && mIsActiveSource && mService.isControlEnabled()) { mService.sendCecCommand(HdmiCecMessageBuilder.buildInactiveSource( mAddress, mService.getPhysicalAddress())); } setIsActiveSource(false); checkIfPendingActionsCleared(); } private void routeToPort(int portId) { // TODO(AMYJOJO): route to specific input of the port mLocalActivePath = portId; } @VisibleForTesting protected int getLocalActivePath() { return mLocalActivePath; } @Override protected void dump(final IndentingPrintWriter pw) { super.dump(pw); pw.println("mIsActiveSource: " + mIsActiveSource); pw.println("mAutoTvOff:" + mAutoTvOff); } // Wrapper interface over PowerManager.WakeLock private interface ActiveWakeLock { void acquire(); void release(); boolean isHeld(); } private class SystemWakeLock implements ActiveWakeLock { private final WakeLock mWakeLock; public SystemWakeLock() { mWakeLock = mService.getPowerManager().newWakeLock(PowerManager.PARTIAL_WAKE_LOCK, TAG); mWakeLock.setReferenceCounted(false); } @Override public void acquire() { mWakeLock.acquire(); HdmiLogger.debug("active source: %b. Wake lock acquired", mIsActiveSource); } @Override public void release() { mWakeLock.release(); HdmiLogger.debug("Wake lock released"); } @Override public boolean isHeld() { return mWakeLock.isHeld(); } } }
{ "pile_set_name": "Github" }
coder=1 flags=+loop cmp=+chroma partitions=-parti8x8-parti4x4-partp8x8-partb8x8 me_method=dia subq=2 me_range=16 g=250 keyint_min=25 sc_threshold=40 i_qfactor=0.71 b_strategy=1 qcomp=0.6 qmin=10 qmax=51 qdiff=4 bf=3 refs=1 directpred=1 trellis=0 flags2=+bpyramid-mixed_refs+wpred-dct8x8+fastpskip wpredp=0 rc_lookahead=10
{ "pile_set_name": "Github" }
/** @file ACPI DSDT table Copyright (c) 2017, Intel Corporation. All rights reserved.<BR> SPDX-License-Identifier: BSD-2-Clause-Patent **/ /////////////////////////////////////////////////////////////////////////////////// //Values are set like this to have ASL compiler reserve enough space for objects /////////////////////////////////////////////////////////////////////////////////// // // Available Sleep states // Name(SS1,0) Name(SS2,0) Name(SS3,1) Name(SS4,1)
{ "pile_set_name": "Github" }
/*============================================================================= Copyright (c) 2001-2011 Joel de Guzman Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) ==============================================================================*/ #if !defined(FUSION_REVERSE_VIEW_ITERATOR_07202005_0835) #define FUSION_REVERSE_VIEW_ITERATOR_07202005_0835 #include <boost/fusion/support/config.hpp> #include <boost/fusion/support/iterator_base.hpp> #include <boost/fusion/support/category_of.hpp> #include <boost/fusion/iterator/mpl/convert_iterator.hpp> #include <boost/fusion/adapted/mpl/mpl_iterator.hpp> #include <boost/fusion/view/reverse_view/detail/deref_impl.hpp> #include <boost/fusion/view/reverse_view/detail/next_impl.hpp> #include <boost/fusion/view/reverse_view/detail/prior_impl.hpp> #include <boost/fusion/view/reverse_view/detail/advance_impl.hpp> #include <boost/fusion/view/reverse_view/detail/distance_impl.hpp> #include <boost/fusion/view/reverse_view/detail/value_of_impl.hpp> #include <boost/fusion/view/reverse_view/detail/deref_data_impl.hpp> #include <boost/fusion/view/reverse_view/detail/value_of_data_impl.hpp> #include <boost/fusion/view/reverse_view/detail/key_of_impl.hpp> #include <boost/type_traits/is_base_of.hpp> #include <boost/static_assert.hpp> namespace boost { namespace fusion { struct reverse_view_iterator_tag; template <typename First> struct reverse_view_iterator : iterator_base<reverse_view_iterator<First> > { typedef convert_iterator<First> converter; typedef typename converter::type first_type; typedef reverse_view_iterator_tag fusion_tag; typedef typename traits::category_of<first_type>::type category; BOOST_STATIC_ASSERT(( is_base_of< bidirectional_traversal_tag , category>::value)); BOOST_CONSTEXPR BOOST_FUSION_GPU_ENABLED reverse_view_iterator(First const& in_first) : first(converter::call(in_first)) {} first_type first; private: // silence MSVC warning C4512: assignment operator could not be generated reverse_view_iterator& operator= (reverse_view_iterator const&); }; }} #ifdef BOOST_FUSION_WORKAROUND_FOR_LWG_2408 namespace std { template <typename First> struct iterator_traits< ::boost::fusion::reverse_view_iterator<First> > { }; } #endif #endif
{ "pile_set_name": "Github" }
/* Copyright (C) 1993-2012 Hewlett-Packard Company */ /* libraried performance include file */ /* the define NOPERFEXTERN tels us not to re-define all the */ /* defines and defaults */ #define HOSTNAMESIZE 255 #define PORTBUFSIZE 10 #define DEFAULT_SIZE 32768 #define HOST_NAME "127.0.0.1" #define TEST_PORT "12865" /* output controlling variables */ #define DEBUG 0 /* debugging level */ #define VERBOSITY 0 /* verbosity level */ /* the end-test conditions for the tests - either transactions, bytes, */ /* or time. different vars used for clarity - space is cheap ;-) */ #define TEST_TIME 10 /* test ends by time */ #define TEST_BYTES 0 /* test ends on byte count */ #define TEST_TRANS 0 /* test ends on tran count */ /* the alignment conditions for the tests */ #define LOC_RECV_ALIGN 4 /* alignment for local receives */ #define LOC_SEND_ALIGN 4 /* alignment for local sends */ #define REM_RECV_ALIGN 4 /* alignment for remote receive */ #define REM_SEND_ALIGN 4 /* alignment for remote sends */ /* which way are we going and what are we doing in this handbasket?-) */ #define NETPERF_XMIT 0x2 #define NETPERF_RECV 0x4 #define NETPERF_IS_RR(x) (((x & NETPERF_XMIT) && (x & NETPERF_RECV)) || \ (!((x & NETPERF_XMIT) || (x & NETPERF_RECV)))) #define NETPERF_RECV_ONLY(x) ((x & NETPERF_RECV) && !(x & NETPERF_XMIT)) #define NETPERF_XMIT_ONLY(x) ((x & NETPERF_XMIT) && !(x & NETPERF_RECV)) #define NETPERF_CC(x) (!(x & NETPERF_XMIT) && !(x & NETPERF_RECV)) /* misc defines for the hell of it */ #ifndef MAXLONG #define MAXLONG 4294967295UL #endif /* MAXLONG */ #ifdef WANT_DCCP /* include netinet/in.h to see if SOCK_DCCP and IPPROTO_DCCP are there */ #include <netinet/in.h> #ifndef SOCK_DCCP #define DCCP_WARNING #define SOCK_DCCP 6 #endif #ifndef IPPROTO_DCCP #define DCCP_WARNING #define IPPROTO_DCCP 33 /* defined by the IANA */ #endif #ifndef SOL_DCCP #define DCCP_WARNING #define SOL_DCCP 269 #endif #ifdef DCCP_WARNING #warning This platform is missing one of sock_dccp ipproto_dccp or sol_dccp #endif #endif #ifndef NETSH extern char *program; /* program invocation name */ extern char *command_line; /* how we were invoked */ extern char *passphrase; /* stuff to say where this test is going */ extern char host_name[HOSTNAMESIZE];/* remote host name or ip addr */ extern char local_host_name[HOSTNAMESIZE]; extern char test_port[PORTBUFSIZE]; /* where is the test waiting */ extern char local_test_port[PORTBUFSIZE]; extern int address_family; extern int local_address_family; extern int parse_address_family(char family_string[]); extern int parse_socket_type(char socket_string[]); extern int parse_protocol(char protocol_string[]); extern int parse_direction(char direction_string[]); extern void set_defaults(); extern void scan_cmd_line(int argc, char *argv[]); extern void dump_globals(); extern void break_args(char *s, char *arg1, char *arg2); extern void break_args_explicit(char *s, char *arg1, char *arg2); extern void break_args_explicit_sep(char *s, int sep, char *arg1, char *arg2); extern void print_netserver_usage(); /* output controlling variables */ extern int debug, /* debugging level */ print_headers, /* do/don't print test headers */ verbosity, /* verbosity level */ keep_histogram, /* do we keep a histogram of interesting times? */ keep_statistics; /* do we keep/calculate expensive statistics? */ /* the end-test conditions for the tests - either transactions, bytes, */ /* or time. different vars used for clarity - space is cheap ;-) */ extern int test_time, /* test ends by time */ test_len_ticks, test_bytes, /* test ends on byte count */ test_trans; /* test ends on tran count */ /* wait time between control/data connection establishment and start of data traffic */ extern int wait_time_secs; /* the alignment conditions for the tests */ extern int local_recv_align, /* alignment for local receives */ local_send_align, /* alignment for local sends */ remote_recv_align, /* alignment for remote receives */ remote_send_align, /* alignment for remote sends */ local_send_offset, local_recv_offset, remote_send_offset, remote_recv_offset, remote_send_width, remote_recv_width; /* hoist these above the #if to deal with either netperf or netserver configured for it */ extern int interval_usecs; extern int interval_wate; extern int interval_burst; extern int remote_interval_usecs; extern int remote_interval_burst; #ifdef DIRTY extern int rem_dirty_count; extern int rem_clean_count; extern int loc_dirty_count; extern int loc_clean_count; #endif /* DIRTY */ /* stuff for confidence intervals */ extern int confidence_level; extern int iteration_min; extern int iteration_max; extern int result_confidence_only; extern double interval; extern double interval_pct; extern int cpu_binding_requested; /* stuff to control the bufferspace "width" */ extern int send_width; extern int recv_width; /* control the socket priority */ extern int local_socket_prio; extern int remote_socket_prio; extern int local_socket_tos; extern int remote_socket_tos; /* address family */ extern int af; /* different options for other things */ extern int local_cpu_usage, remote_cpu_usage; extern float local_cpu_rate, remote_cpu_rate; extern int shell_num_cpus; extern char test_name[BUFSIZ]; extern char local_fill_file[BUFSIZ], remote_fill_file[32]; extern char * result_brand; extern int no_control; #ifdef WANT_DLPI extern int loc_ppa, rem_ppa; extern int dlpi_sap; #endif /* WANT_DLPI */ #endif extern int parse_ipqos(const char *cp); extern const char * iptos2str(int iptos);
{ "pile_set_name": "Github" }
[package] name = "bb" version = "0.4.0" authors = ["Manos Pitsidianakis <[email protected]>"] license = "GPL-3.0-or-later" readme = "README.md" description = "clean simple fast process viewer" homepage = "https://nessuent.xyz/bb.html" repository = "https://github.com/epilys/bb.git" categories = ["command-line-utilities", ] keywords = ["process", "processes", "top", "ps"] edition = "2018" build = "build.rs" # See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html [[bin]] name = "bb" path = "src/main.rs" [dependencies] crossbeam = "0.7" signal-hook = "0.1.10" termion = "1.5.3" libc = "0.2.62" unicode-segmentation = "1.2.1" nix = "0.15.0" cassowary = "^0.3.0" [profile.release] opt-level = 'z' # Optimize for size. lto = true codegen-units = 1 panic = 'abort'
{ "pile_set_name": "Github" }
/* Copyright (C) 1997-2001 Id Software, Inc. This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #ifndef __linux__ #ifndef __FreeBSD__ #error You shouldnt be including this file on non-Linux platforms #endif #endif #ifndef __GLW_LINUX_H__ #define __GLW_LINUX_H__ typedef struct { void *OpenGLLib; // instance of OpenGL library FILE *log_fp; } glwstate_t; extern glwstate_t glw_state; #endif
{ "pile_set_name": "Github" }
# These components will be loaded when running Microsoft.Powershell (i.e. Not Visual Studio) Push-Location (Join-Path (Split-Path -parent $profile) "components") # From within the ./components directory... . .\visualstudio.ps1 . .\console.ps1 Pop-Location
{ "pile_set_name": "Github" }
// // Generated by class-dump 3.5 (64 bit) (Debug version compiled Jun 9 2015 22:53:21). // // class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2014 by Steve Nygard. // #import "Element.h" @interface UIElement : Element { struct __AXUIElement *_ref; unsigned int _classCode; } - (id)valueInUiActionsWithName:(id)arg1; - (id)uiActions; - (id)uiAttributes; - (id)uiPopovers; - (id)uiColorWells; - (id)uiSplitters; - (id)uiSplitGroups; - (id)uiMenuItems; - (id)uiMenus; - (id)uiMenuBarItems; - (id)uiMenuBars; - (id)uiStaticTexts; - (id)uiTextAreas; - (id)uiTextFields; - (id)uiToolbars; - (id)uiRelevanceIndicators; - (id)uiProgressIndicators; - (id)uiBusyIndicators; - (id)uiIncrementors; - (id)uiSliders; - (id)uiComboBoxes; - (id)uiValueIndicators; - (id)uiGroups; - (id)uiLists; - (id)uiRadioGroups; - (id)uiScrollBars; - (id)uiScrollAreas; - (id)uiBrowsers; - (id)uiOutlines; - (id)uiRows; - (id)uiColumns; - (id)uiTables; - (id)uiTabGroups; - (id)uiMenuButtons; - (id)uiPopUpButtons; - (id)uiCheckBoxes; - (id)uiRadioButtons; - (id)uiButtons; - (id)uiImages; - (id)uiGrowAreas; - (id)uiDrawers; - (id)uiSheets; - (id)uiWindows; - (id)uiSystemWides; - (id)uiApplications; - (id)uiElementsWithRole:(struct __CFString *)arg1; - (id)uiElements; - (id)getUIElementForRef:(struct __AXUIElement *)arg1; - (id)deriveName; - (void)privateSetClassCode:(unsigned int)arg1; - (unsigned int)classCode; - (id)entireContents; - (void)setSelected:(BOOL)arg1; - (id)selected; - (id)orientation; - (void)setSize:(id)arg1; - (id)size; - (void)setPosition:(id)arg1; - (id)position; - (void)setFocused:(id)arg1; - (id)focused; - (id)enabled; - (id)maximumValue; - (id)minimumValue; - (void)setValue:(id)arg1; - (id)value; - (id)title; - (id)help; - (id)scriptingDescription; - (id)axDescription; - (id)subrole; - (id)roleDescription; - (id)role; - (id)getComplexValueForAttribute:(struct __CFString *)arg1; - (void)setValue:(void *)arg1 forAttribute:(struct __CFString *)arg2; - (void *)getValueForAttribute:(struct __CFString *)arg1; - (id)select:(id)arg1; - (id)cancel:(id)arg1; - (id)pick:(id)arg1; - (id)confirm:(id)arg1; - (id)decrement:(id)arg1; - (id)increment:(id)arg1; - (id)click:(id)arg1; - (void)setRef:(struct __AXUIElement *)arg1; - (struct __AXUIElement *)ref; - (void)dealloc; - (id)initUIElementWithParent:(id)arg1 andSiblings:(id)arg2; @end
{ "pile_set_name": "Github" }
.device ATtiny10 ; +====+ ; (PWMA) PB0 |* | PB3 (RESET) ; GND | | Vcc ; (PWMB) PB1 | | PB2 ; +====+ ; available fuses: ckout, wdton, rstdisbl .fuses ckout .DSEG .CSEG .org 0 ;Interrupt vector table rjmp reset ; All Resets reti ; External Interrupt Request 0 reti ; Pin Change Interrupt Request 0 reti ; Timer/Counter0 Input Capture reti ; Timer/Counter0 Overflow reti ; Timer/Counter0 Compare Match A reti ; Timer/Counter0 Compare Match B reti ; Analog Comparator reti ; Watchdog Time-out reti ; VCC Voltage Level Monitor reti ; ADC Conversion Complete reset: ; Set Stack Pointer (SP) ldi r16, 0x00 out SPH, r16 ldi r16, 0x5F out SPL, r16 ; Set clock to 8MHz ldi r16, 0xD8 ; Unprotect CLKPSR reg out CCP, r16 ldi r16, 0 ; Divide by 1 out CLKPSR, r16 ; Calibrate Oscillator ldi r16, 0x95 ; Measured Value out OSCCAL, r16 ; Setup I/O Port ldi r16, (1<<PINB3) | (1<<PINB2) | (0<<PINB1) | (1<<PINB0) out DDRB, r16 ; Pullup PINB1 ldi r16, (1<<PINB3) | (1<<PINB2) | (0<<PINB1) | (1<<PINB0) out PORTB, r16 ; Setup CTC to toggle Pin 1 on count ldi r16, 0x40 ; Clear Timer on Compare (CTC) Mode out TCCR0A, r16 ldi r16, 0x0C ; CTC and prescale = /256 out TCCR0B, r16 ; Set Output Compare Register to 0x7A12 (8000000 / 256) ldi r16, 0x7A out OCR0AH, r16 ldi r16, 0x12 out OCR0AL, r16 wait: ldi r17, 8 ; Bit counter ldi r18, 0 ; Bit accumulator bit_wait: add r18, r18 ; Shift left r18 rcall pulse_in breq wait ; Reset byte loop cpi r16, 64 brlo zero_bit inc r18 zero_bit: dec r17 brne bit_wait ; Get her with received byte in r18 out OSCCAL, r18 rjmp wait ; ; Wait for pint to go low, then measure length of pulse ; Return r16 as pulse width, else carry set if timeout pulse_in: sbic PINB, PINB1 ; skip if PINB1 is LOW rjmp pulse_in ; wait for pin to go LOW ldi r16, 1 pulse_loop: sbic PINB, PINB1 ; skip if PINB1 is LOW ret inc r16 brne pulse_loop end_wait: sbis PINB, PINB1 rjmp end_wait ret
{ "pile_set_name": "Github" }
from galaxy import model from galaxy.managers.markdown_util import resolve_invocation_markdown, validate_galaxy_markdown from .test_workflow_progress import TEST_WORKFLOW_YAML from .workflow_support import MockTrans, yaml_to_model def test_workflow_section_expansion(): workflow_markdown = """ ## Workflow ```galaxy workflow_display() ``` """ galaxy_markdown = resolved_markdown(workflow_markdown) assert "## Workflow\n" in galaxy_markdown assert "```galaxy\nworkflow_display(workflow_id=342)\n```\n" in galaxy_markdown def test_inputs_section_expansion(): workflow_markdown = """ ## Workflow Inputs ```galaxy invocation_inputs() ``` """ galaxy_markdown = resolved_markdown(workflow_markdown) assert "## Workflow Inputs" in galaxy_markdown assert "```galaxy\nhistory_dataset_display(history_dataset_id=567)\n" in galaxy_markdown assert len(galaxy_markdown.split("```")) == 3 def test_outputs_section_expansion(): workflow_markdown = """ ## Workflow Outputs ```galaxy invocation_outputs() ``` """ galaxy_markdown = resolved_markdown(workflow_markdown) assert "## Workflow Outputs" in galaxy_markdown assert "```galaxy\nhistory_dataset_display(history_dataset_id=563)" in galaxy_markdown def test_input_reference_mapping(): workflow_markdown = """ And outputs... ```galaxy history_dataset_peek(input=input1) ``` """ galaxy_markdown = resolved_markdown(workflow_markdown) assert "```galaxy\nhistory_dataset_peek(history_dataset_id=567)\n```" in galaxy_markdown def test_output_reference_mapping(): workflow_markdown = """ And outputs... ```galaxy history_dataset_as_image(output=output_label) ``` """ galaxy_markdown = resolved_markdown(workflow_markdown) assert "```galaxy\nhistory_dataset_as_image(history_dataset_id=563)\n```" in galaxy_markdown def resolved_markdown(workflow_markdown): # Convert workflow markdown to internal Galaxy markdown with object id references # and with sections expanded. trans = MockTrans() validate_galaxy_markdown(workflow_markdown) galaxy_markdown = resolve_invocation_markdown(trans, example_invocation(trans), workflow_markdown) return galaxy_markdown def example_invocation(trans): invocation = model.WorkflowInvocation() workflow = yaml_to_model(TEST_WORKFLOW_YAML) workflow.id = 342 invocation.workflow = workflow # TODO: fix this to use workflow id and eliminate hack. stored_workflow = model.StoredWorkflow() stored_workflow.id = 342 invocation.workflow.stored_workflow = stored_workflow hda = model.HistoryDatasetAssociation(create_dataset=True, sa_session=trans.sa_session) hda.id = 567 invocation.add_input(hda, step=workflow.steps[0]) out_hda = model.HistoryDatasetAssociation(create_dataset=True, sa_session=trans.sa_session) out_hda.id = 563 wf_output = model.WorkflowOutput(workflow.steps[2], label="output_label") invocation.add_output(wf_output, workflow.steps[2], out_hda) return invocation
{ "pile_set_name": "Github" }
// +build !ignore_autogenerated /* Copyright The Kubernetes Authors. 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. */ // Code generated by defaulter-gen. DO NOT EDIT. package v1 import ( runtime "k8s.io/apimachinery/pkg/runtime" ) // RegisterDefaults adds defaulters functions to the given scheme. // Public to allow building arbitrary schemes. // All generated defaulters are covering - they call all nested defaulters. func RegisterDefaults(scheme *runtime.Scheme) error { return nil }
{ "pile_set_name": "Github" }