  Keyframes(String, VendorPrefix),
  /// A @page rule prelude.
  Page(Vec<PageSelector>),
  /// A @document rule, with its conditional.
  Document,//(DocumentCondition),
  /// A @import rule prelude.
  Import(String, MediaList, Option<SupportsCondition>),
  /// A @namespace rule prelude.
  Namespace(Option<String>, String),
}

impl<'a, 'i> AtRuleParser<'i> for TopLevelRuleParser {
  type PreludeNoBlock = AtRulePrelude;
  type PreludeBlock = AtRulePrelude;
  type AtRule = (SourcePosition, CssRule);
  type Error = ();

  fn parse_prelude<'t>(
      &mut self,
      name: CowRcStr<'i>,
      input: &mut Parser<'i, 't>,
  ) -> Result<AtRuleType<AtRulePrelude, AtRulePrelude>, ParseError<'i, Self::Error>> {
      match_ignore_ascii_case! { &*name,
        "import" => {
          let url_string = input.expect_url_or_string()?.as_ref().to_owned();
          let supports = if input.try_parse(|input| input.expect_function_matching("supports")).is_ok() {
            Some(input.parse_nested_block(|input| {
              input.try_parse(SupportsCondition::parse).or_else(|_| SupportsCondition::parse_declaration(input))
            })?)
          } else {
            None
          };
          let media = MediaList::parse(input);
          return Ok(AtRuleType::WithoutBlock(AtRulePrelude::Import(url_string, media, supports)));
        },
        "namespace" => {
          let prefix = input.try_parse(|input| input.expect_ident_cloned()).map(|v| v.as_ref().to_owned()).ok();
          let namespace = input.expect_url_or_string()?.as_ref().to_owned();
          let prelude = AtRulePrelude::Namespace(prefix, namespace);
          return Ok(AtRuleType::WithoutBlock(prelude));
        },
        // @charset is removed by rust-cssparser if it’s the first rule in the stylesheet
        // anything left is invalid.
        "charset" => {
          return Err(input.new_error(BasicParseErrorKind::AtRuleInvalid(name)))
        },
        _ => {}
      }

      AtRuleParser::parse_prelude(&mut self.nested(), name, input)
  }

  #[inline]
  fn parse_block<'t>(
      &mut self,
      prelude: AtRulePrelude,
      start: &ParserState,
      input: &mut Parser<'i, 't>,
  ) -> Result<Self::AtRule, ParseError<'i, Self::Error>> {
    let rule = AtRuleParser::parse_block(&mut self.nested(), prelude, start, input)?;
    Ok((start.position(), rule))
  }

  #[inline]
  fn rule_without_block(
      &mut self,
      prelude: AtRulePrelude,
      start: &ParserState,
  ) -> Self::AtRule {
      let loc = start.source_location();
      let rule = match prelude {
        AtRulePrelude::Import(url, media, supports) => {
          CssRule::Import(ImportRule {
            url,
            supports,
            media,
            loc
          })
        },
        AtRulePrelude::Namespace(prefix, url) => {
          CssRule::Namespace(NamespaceRule {
            prefix,
            url,
            loc
          })
        },
        _ => unreachable!()
      };

      (start.position(), rule)
  }
}

impl<'a, 'i> QualifiedRuleParser<'


the first time, generate the index
        t.__orderedIndex = __genOrderedIndex( t )
        key = t.__orderedIndex[1]
        return key, t[key]
    end
    -- fetch the next value
    key = nil
    for i = 1,table.getn(t.__orderedIndex) do
        if t.__orderedIndex[i] == state then
            key = t.__orderedIndex[i+1]
        end
    end

    if key then
        return key, t[key]
    end

    -- no more value to return, cleanup
    t.__orderedIndex = nil
    return
end

local function orderedPairs(t)
    -- Equivalent of the pairs() function on tables. Allows to iterate
    -- in order
    return orderedNext, t, nil
end

-- ASSERT FUNCTIONS ------------------------------------------------------------
--
function assertError(f, ...)
	-- assert that calling f with the arguments will raise an error
	-- example: assertError( f, 1, 2 ) => f(1,2) should generate an error
	local has_error, error_msg = not pcall( f, ... )
	if has_error then return end
	error( "No error generated", 2 )
end
assert_error = assertError

function assertEquals(actual, expected)
	-- assert that two values are equal and calls error else
	if not USE_EXPECTED_ACTUAL_IN_ASSERT_EQUALS then
		expected, actual = actual, expected
	end

	if "table" == type(actual) then
		if not deepCompare(actual, expected, true) then
			error("table expected: \n"..toString(expected)..", actual: \n"..toString(actual))
		end
	else
		if  actual ~= expected  then
			local function wrapValue( v )
				if type(v) == 'string' then return "'"..v.."'" end
				return tostring(v)
			end

			local errorMsg
			--if type(expected) == 'string' then
			--	errorMsg = "\nexpected: "..wrapValue(expected).."\n"..
			--					 "actual  : "..wrapValue(actual).."\n"
			--else
				errorMsg = "expected: "..wrapValue(expected)..", actual: "..wrapValue(actual)
			--end
			--print(errorMsg)
			error(errorMsg, 2)
		end
	end
end
assert_equals = assertEquals

-- assert_<type> functions
for _, typename in ipairs(typenames) do
	local tName = typename:lower()
	local assert_typename = "assert"..typename
	_G[assert_typename] = function(actual, msg)
		local actualtype = type(actual)
		if actualtype ~= tName then
			local errorMsg = tName.." expected but was a "..actualtype
			if msg then
				errorMsg = msg.."\n"..errorMsg
			end
			error(errorMsg, 2)
		end

		return actual
	end
	-- Alias to lower underscore naming
	_G["assert_"..tName] = _G[assert_typename]
end

-- assert_not_<type> functions
for _, typename in ipairs(typenames) do
	local tName = typename:lower()
	local assert_not_typename = "assertNot"..typename
	_G[assert_not_typename] = function(actual, msg)
		if type(actual) == tName then
			local errorMsg = tName.." not expected but was one"
			if msg then
				errorMsg = msg.."\n"..errorMsg
			end
			error(errorMsg, 2)
		end
	end
	-- Alias to lower underscore naming
	_G["assert_not_"..tName] = _G[assert_not_typename]
end

-- UNITRESULT CLASS ------------------------------------------------------------
--
local UnitResult = { -- class
	failureCount = 0,
	testCount = 0,
	errorList = {},
	currentClassName = "",
	currentTestName = "",
	testHasFailure = false,
	verbosity = 1
}
	function UnitResult:displayClassName()
		--if self.verbosity == 0 then print("") e


InvokeHelper(0x1ee, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&result, NULL);
	return result;
}

LPDISPATCH _Application::GetExcel4IntlMacroSheets()
{
	LPDISPATCH result;
	InvokeHelper(0x245, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&result, NULL);
	return result;
}

LPDISPATCH _Application::GetExcel4MacroSheets()
{
	LPDISPATCH result;
	InvokeHelper(0x243, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&result, NULL);
	return result;
}

void _Application::ActivateMicrosoftApp(long Index)
{
	static BYTE parms[] =
		VTS_I4;
	InvokeHelper(0x447, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
		 Index);
}

void _Application::AddChartAutoFormat(const VARIANT& Chart, LPCTSTR Name, const VARIANT& Description)
{
	static BYTE parms[] =
		VTS_VARIANT VTS_BSTR VTS_VARIANT;
	InvokeHelper(0xd8, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
		 &Chart, Name, &Description);
}

void _Application::AddCustomList(const VARIANT& ListArray, const VARIANT& ByRow)
{
	static BYTE parms[] =
		VTS_VARIANT VTS_VARIANT;
	InvokeHelper(0x30c, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
		 &ListArray, &ByRow);
}

BOOL _Application::GetAlertBeforeOverwriting()
{
	BOOL result;
	InvokeHelper(0x3a2, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
	return result;
}

void _Application::SetAlertBeforeOverwriting(BOOL bNewValue)
{
	static BYTE parms[] =
		VTS_BOOL;
	InvokeHelper(0x3a2, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
		 bNewValue);
}

CString _Application::GetAltStartupPath()
{
	CString result;
	InvokeHelper(0x139, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
	return result;
}

void _Application::SetAltStartupPath(LPCTSTR lpszNewValue)
{
	static BYTE parms[] =
		VTS_BSTR;
	InvokeHelper(0x139, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
		 lpszNewValue);
}

BOOL _Application::GetAskToUpdateLinks()
{
	BOOL result;
	InvokeHelper(0x3e0, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
	return result;
}

void _Application::SetAskToUpdateLinks(BOOL bNewValue)
{
	static BYTE parms[] =
		VTS_BOOL;
	InvokeHelper(0x3e0, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
		 bNewValue);
}

BOOL _Application::GetEnableAnimations()
{
	BOOL result;
	InvokeHelper(0x49c, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
	return result;
}

void _Application::SetEnableAnimations(BOOL bNewValue)
{
	static BYTE parms[] =
		VTS_BOOL;
	InvokeHelper(0x49c, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
		 bNewValue);
}

LPDISPATCH _Application::GetAutoCorrect()
{
	LPDISPATCH result;
	InvokeHelper(0x


ab': 'GitLab'
        }[op.toLowerCase()] ??
        toCapitalized(op);
    return Row(children: [
      Container(
        height: height,
        width: 200,
        child: Obx(() => ElevatedButton(
            style: ElevatedButton.styleFrom(
              backgroundColor: curOP.value.isEmpty || curOP.value == op
                  ? primaryColor
                  : Colors.grey,
            ).copyWith(elevation: ButtonStyleButton.allOrNull(0.0)),
            onPressed: curOP.value.isEmpty || curOP.value == op ? onTap : null,
            child: Row(
              children: [
                SizedBox(
                  width: 30,
                  child: _IconOP(
                    op: op,
                    icon: icon,
                    margin: EdgeInsets.only(right: 5),
                  ),
                ),
                Expanded(
                  child: FittedBox(
                    fit: BoxFit.scaleDown,
                    child: Center(
                        child: Text('${translate("Continue with")} $opLabel')),
                  ),
                ),
              ],
            ))),
      ),
    ]);
  }
}

class ConfigOP {
  final String op;
  final String? icon;
  ConfigOP({required this.op, required this.icon});
}

class WidgetOP extends StatefulWidget {
  final ConfigOP config;
  final RxString curOP;
  final Function(Map<String, dynamic>) cbLogin;
  const WidgetOP({
    Key? key,
    required this.config,
    required this.curOP,
    required this.cbLogin,
  }) : super(key: key);

  @override
  State<StatefulWidget> createState() {
    return _WidgetOPState();
  }
}

class _WidgetOPState extends State<WidgetOP> {
  Timer? _updateTimer;
  String _stateMsg = '';
  String _failedMsg = '';
  String _url = '';

  @override
  void dispose() {
    super.dispose();
    _updateTimer?.cancel();
  }

  _beginQueryState() {
    _updateTimer = Timer.periodic(Duration(seconds: 1), (timer) {
      _updateState();
    });
  }

  _updateState() {
    bind.mainAccountAuthResult().then((result) {
      if (result.isEmpty) {
        return;
      }
      final resultMap = jsonDecode(result);
      if (resultMap == null) {
        return;
      }
      final String stateMsg = resultMap['state_msg'];
      String failedMsg = resultMap['failed_msg'];
      final String? url = resultMap['url'];
      final authBody = resultMap['auth_body'];
      if (_stateMsg != stateMsg || _failedMsg != failedMsg) {
        if (_url.isEmpty && url != null && url.isNotEmpty) {
          launchUrl(Uri.parse(url), mode: LaunchMode.externalApplication);
          _url = url;
        }
        if (authBody != null) {
          _updateTimer?.cancel();
          widget.curOP.value = '';
          widget.cbLogin(authBody as Map<String, dynamic>);
        }

        setState(() {
          _stateMsg = stateMsg;
          _failedMsg = failedMsg;
          if (failedMsg.isNotEmpty) {
            widget.curOP.value = '';
            _updateTimer?.cancel();
          }
        });
      }
    });
  }

  _resetState() {
    _stateMsg = '';
    _failedMsg = '';
    _url = '';
  }

  @override
  Widget build(BuildContext context) {
    return Column(
      children: [
        ButtonOP(
          op: widget.config.op,
          curOP: widget.curOP,
          icon: widget.config.icon,
          primaryColor: str2color(widget.config.op, 0x7f),


#$16			*hCoPDX
		tst.l	d0
		beq	load_pdx91
		movea.l	d0,a1
		clr.b	(a1)
load_pdx91:
		move.l	d4,d0
		unlk	a6
		movem.l	(sp)+,d1-d4/a0-a2
		rts

*==================================================
*scwǂݍ
*	a0.l <- t@C
*==================================================

LOAD_TDX:
		movem.l	d1-d2/a0-a2,-(sp)
		moveq	#-1,d0
		movea.l	d0,a2

		clr.l	-(sp)			*TDXt@Cǂݍ
		pea	env_MADRV(pc)		*ϐMADRV,mxpT
		pea	(a0)
		bsr	READ_FILE
		lea	12(sp),sp
		move.l	d0,d2
		bmi	load_tdx_err
		movea.l	a0,a2

		MADRV	#$0c			*hCõobt@TDXWJ
		move.l	d0,a1
		bsr	TDX_LOAD
		bne	load_tdx_err

		moveq.l	#-1,d1			*PDXX^oC
		MADRV	#$00
		moveq	#0,d0
		bra	load_tdx90

load_tdx_err:
		moveq	#-2,d0
load_tdx90:
		move.l	d0,d2
		pea	(a2)			*TDX̃J
		bsr	FREE_MEM
		addq.l	#4,sp
		move.l	d2,d0
		movem.l	(sp)+,d1-d2/a0-a2
		rts

*t@CTDXȂEQUԂ
*	a0.l <- t@C

CHECK_TDX:
		movem.l	a0,-(sp)
		moveq	#0,d0
check_tdx10:
		tst.b	(a0)
		beq	check_tdx20
		lsl.l	#8,d0
		move.b	(a0)+,d0
		bra	check_tdx10
check_tdx20:
		andi.l	#$ffdfdfdf,d0
		cmpi.l	#'.TDX',d0
		movem.l	(sp)+,a0
		rts

*==================================================
*ycet@C[h
*	LOAD_ZDF(char *name)
*	name	t@C
*	d0.l -> ȂAG[
*		-1 MDX[hG[
*		-2 PDX[hG[
*		-3 s
*		-4 MDXobt@s
*		-5 PCMobt@s
*		-6 tH[}bgG[
*==================================================

		.offset	-310
zdf_table	.ds.b	54
zoldpdx_name	.ds.b	256
		.text

LOAD_ZDF:
		movem.l	d1-d3/a0-a2,-(sp)
		move.l	(6+1)*4(sp),a0
		link	a6,#-310

		moveq	#-1,d1			*ZDFobt@|C^
		moveq	#-1,d2			*LZZobt@|C^
		moveq	#-1,d3			*MDXobt@|C^

		lea	zoldpdx_name(a6),a2	*MADRVPDXobt@ɎĂ


    private void siftDown(int[] array, int root, int dist, int start, double sleep, boolean isMax) {
        int compareVal = 0;

        if(isMax) compareVal = -1;
        else compareVal = 1;

        while (root <= dist / 2) {
            int leaf = 2 * root;
            if (leaf < dist && Reads.compareValues(array[start + leaf - 1], array[start + leaf]) == compareVal) {
                leaf++;
            }
            Highlights.markArray(1, start + root - 1);
            Highlights.markArray(2, start + leaf - 1);
            Delays.sleep(sleep);
            if (Reads.compareValues(array[start + root - 1], array[start + leaf - 1]) == compareVal) {
                Writes.swap(array, start + root - 1, start + leaf - 1, 0, true, false);
                root = leaf;
            }
            else break;
        }
    }

    protected void heapify(int[] arr, int low, int high, double sleep, boolean isMax) {
        int length = high - low;
        for (int i = length / 2; i >= 1; i--) {
            siftDown(arr, i, length, low, sleep, isMax);
        }
    }

    // This version of heap sort works for max and min variants, alongside sorting
    // partial ranges of an array.
    protected void heapSort(int[] arr, int start, int length, double sleep, boolean isMax) {
        heapify(arr, start, length, sleep, isMax);

        for (int i = length - start; i > 1; i--) {
            Writes.swap(arr, start, start + i - 1, sleep, true, false);
            siftDown(arr, 1, i - 1, start, sleep, isMax);
        }

        if(!isMax) {
            Writes.reversal(arr, start, start + length - 1, 1, true, false);
        }
    }
}
package io.github.arrayv.sorts.templates;

import io.github.arrayv.main.ArrayVisualizer;
import io.github.arrayv.sorts.exchange.OptimizedGnomeSort;

/*
 *
The MIT License (MIT)

Copyright (c) 2013 Andrey Astrelin

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.
 *
 */

/********* Grail sorting *********************************/
/*                                                       */
/* (c) 2013 by Andrey Astrelin                           */
/* Refactored by MusicTheorist                           */
/*                                                       */
/* Stable sorting that works in O(N*log(N)) worst time   */
/* and uses O(1) extra memory                            */
/*                                                       */
/* Define int / SortComparator                           */
/* and then call GrailSort() function                    */
/*                                                       */
/* For sorting w/ fixed external buffer (512 items)      */
/* use GrailSortWithBuffer()                             */
/*


er {
    }
}
declare module FailFast {
    /**
     * FailFast specification.
     *

     * This is to help programmers to follow the FailFast-principle.
     *

     *

     * The FailFast-principle helps you detect and report unexpected errors immediately when they occur.
     *

     *

     * The FailFast-principle favors simple code-fixes over complex runtime error recovery schemes.
     *

     *

     * Read the description and references here: http://en.wikipedia.org/wiki/Fail-fast
     *

     *

     * Implementations of this should be extensible (not final).
     *

     *
     * @author Keld Oelykke
     */
    interface IFailFast extends ICheckerReference, IFailerReference {
    }
}
declare module FailFast {
    /**
     * Failer reference specification.
     *

     * Implement this to manage a reference to a failer.
     *

     * @author Keld Oelykke
     */
    interface IFailerReference {
        /**
         * Retrieves failer.
         *

         * Call methods of this to throw an exception when a check asserts.
         *

         * @return failer.
         */
        getFailer(): IFailer;
        /**
         * Sets the failer.
         *

         * Call methods of this to throw an exception when a check asserts.
         *

         * @param failer
         *          failer to use.
         */
        setFailer(failer: IFailer): void;
    }
}
class Vehiculo {
    private _matricula: string
    private _marca: string

    constructor(_matricula: string, marca: string){
        this._matricula = _matricula
        this._marca = marca
    }
    getMatricula(){
        return this._matricula
    }
    getMarca(){
        return this._marca
    }
    get marca(){
        return this._marca
    }
    setMarca(_marca: string){
        this._marca = _marca
    }
    set marca (_marca: string){
        this._marca = _marca
    }
}
let v1: Vehiculo
let miVehiculo = new Vehiculo("1234ABC", "Opel")
v1 = new Vehiculo("5678XYZ", "Renault")
console.log(`La marca de v1 es: ${v1.getMarca()}`)
v1.setMarca("Seat")
v1.marca = "Maseratti"
console.log(`La marca de v1 es: ${v1.getMarca()}`)
console.log(`Los datos del vehículo son: Matrícula: ${miVehiculo.getMatricula()}, Marca: ${miVehiculo.marca}.`)///<reference path="d/DefinitelyTyped/tsd.d.ts" />

module TGD {
    export class Animation {

        private spritesheet:createjs.SpriteSheet;
        private sprite:createjs.Sprite;

        constructor(callback:()=>void = null) {
            this.spritesheet = new createjs.SpriteSheet({
                "framerate":24,
                "images":[chrome.extension.getURL("img/animations.png")],
                "frames":[
                    [0, 0, 128, 128, 0, 0, -14],
                    [128, 0, 128, 128, 0, 0, -14],
                    [256, 0, 128, 128, 0, 0, -14],
                    [0, 128, 128, 128, 0, 0, -14],
                    [128, 128, 128, 128, 0, 0, -14],
                    [256, 128, 128, 128, 0, 0, -14],
                    [0, 256, 128, 128, 0, 0, -14],
                    [128, 256, 128, 128, 0, 0, -14],
                    [256, 256, 128, 128, 0, 0, -14],
                    [0, 384, 128, 128, 0, 0, -14],
                    [128, 384


    add rsp, 8
    cmp rdi, rsi
    je .ok
notok:
    movabs rdi, offset .L.str.1
    jmp .print
.ok:
    movabs rdi, offset .L.str
    jmp .print
.print:
    mov al, 0
    call printf
    xor rax, rax
    ret

    .type   .L.str,@object                  # @.str
    .section        .rodata.str1.1,"aMS",@progbits,1
.L.str:
    .asciz  "Everything ok\n"
    .size   .L.str, 15

    .type   .L.str.1,@object                # @.str.1
.L.str.1:
    .asciz  "Not ok\n"
    .size   .L.str.1, 8
    .section    .rodata.cst8,"aM",@progbits,8
.L.val:
    .quad 0x3ff8000000000000 # double 1.5


ager on the host system...");
        let cpm = ConfidentialPackageManager::new();
        let _pingres = cpm.ping()?;
        match self.method.as_str() {
            "http" => self.sync_using_http(&cpm),
            "file" => self.sync_using_file(&cpm),
            "azuretwin" => self.sync_using_azure_twin(&cpm),
            _ => {
                println!(
                    "Invalid synchronization method. Please specify either `http` or `azuretwin`."
                );
                Err(Error::ToolError(ToolErrorKind::InvalidSyncMethod))
            }
        }
    }
}
use log::{Level as LogLevel, LevelFilter as LogLevelFilter};
use serde::{Deserialize, Deserializer, Serialize, Serializer};

/// GELF's representation of an error level
///
/// GELF's error levels are equivalent to syslog's severity
/// information (specified in [RFC 5424](https://tools.ietf.org/html/rfc5424))
///
/// The levels dont match `log`s levels, but (lossy) conversion methods
/// are provided. These methods follow this conversion table:
///
/// | GELF / Syslog     | Rust      |
/// |-------------------|-----------|
/// | Emergency (0)     | Error (1) |
/// | Alert (1)         | Error (1) |
/// | Critical (2)      | Error (1) |
/// | Error (3)         | Error (1) |
/// | Warning (4)       | Warn (2)  |
/// | Notice (5)        | Info (3)  |
/// | Informational (6) | Info (3)  |
/// | Debug (7)         | Debug (4) |
/// | Debug (7)         | Trace (5) |
#[derive(Debug, Clone, Copy, PartialEq)]
pub enum Level {
    Emergency = 0,
    Alert = 1,
    Critical = 2,
    Error = 3,
    Warning = 4,
    Notice = 5,
    Informational = 6,
    Debug = 7,
}

impl Level {
    /// Get the GELF error level from given Rust error level
    pub fn from_rust(level: LogLevel) -> Level {
        match level {
            LogLevel::Error => Level::Error,
            LogLevel::Warn => Level::Warning,
            LogLevel::Info => Level::Informational,
            LogLevel::Debug | LogLevel::Trace => Level::Debug,
        }
    }

    /// Get the Rust error level from this GELF error level
    pub fn to_rust(self) -> LogLevel {
        match self {
            Level::Emergency | Level::Alert | Level::Critical | Level::Error => LogLevel::Error,
            Level::Warning => LogLevel::Warn,
            Level::Notice | Level::Informational => LogLevel::Info,
            Level::Debug => LogLevel::Debug,
        }
    }
}

impl<'de> Deserialize<'de> for Level {
    fn deserialize<D>(deserializer: D) -> Result<Self, <D as Deserializer<'de>>::Error> where
        D: Deserializer<'de> {
        serde_json::Value::deserialize(deserializer)?
            .as_f64()
            .map(Level::from)
            .ok_or_else(|| serde::de::Error::custom("Expected i64 for Log Level"))
    }
}

impl Serialize for Level {
    fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
        where S: Serializer {
        serializer.serialize_i8(self.into())
    }
}

impl Into<LogLevel> for Level {
    /// Allow for Into conversion to Rust's LogLevel
    fn into(self) -> LogLevel {
        self.to_rust()
    }
}

impl From<LogLevel> for Level {
    /// Allow for Into conversion from Rust's LogLevel
    fn from(level: LogLevel) -> Level {
        Level::from_rust(level)
    }
}

impl Into<LogLevelFilter> for Level {
    /// Allow for Into conversion from Rust's LogLevelFilter
    fn into(self) -> LogLevelFilter {
        self.to_rust().to_level_filter()
    }
}

impl Into<i8> for &Level {
    fn


:DXImageTransform.Microsoft.gradient(startColorstr='#ffdff0d8', endColorstr='#ffd0e9c6', GradientType=0);background-repeat:repeat-x}.panel-info>.panel-heading{background-image:-webkit-linear-gradient(top,#d9edf7 0,#c4e3f3 100%);background-image:-o-linear-gradient(top,#d9edf7 0,#c4e3f3 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#d9edf7),to(#c4e3f3));background-image:linear-gradient(to bottom,#d9edf7 0,#c4e3f3 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffd9edf7', endColorstr='#ffc4e3f3', GradientType=0);background-repeat:repeat-x}.panel-warning>.panel-heading{background-image:-webkit-linear-gradient(top,#fcf8e3 0,#faf2cc 100%);background-image:-o-linear-gradient(top,#fcf8e3 0,#faf2cc 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#fcf8e3),to(#faf2cc));background-image:linear-gradient(to bottom,#fcf8e3 0,#faf2cc 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fffcf8e3', endColorstr='#fffaf2cc', GradientType=0);background-repeat:repeat-x}.panel-danger>.panel-heading{background-image:-webkit-linear-gradient(top,#f2dede 0,#ebcccc 100%);background-image:-o-linear-gradient(top,#f2dede 0,#ebcccc 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#f2dede),to(#ebcccc));background-image:linear-gradient(to bottom,#f2dede 0,#ebcccc 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#fff2dede', endColorstr='#ffebcccc', GradientType=0);background-repeat:repeat-x}.well{background-image:-webkit-linear-gradient(top,#e8e8e8 0,#f5f5f5 100%);background-image:-o-linear-gradient(top,#e8e8e8 0,#f5f5f5 100%);background-image:-webkit-gradient(linear,left top,left bottom,from(#e8e8e8),to(#f5f5f5));background-image:linear-gradient(to bottom,#e8e8e8 0,#f5f5f5 100%);filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffe8e8e8', endColorstr='#fff5f5f5', GradientType=0);background-repeat:repeat-x;border-color:#dcdcdc;-webkit-box-shadow:inset 0 1px 3px rgba(0,0,0,.05),0 1px 0 rgba(255,255,255,.1);box-shadow:inset 0 1px 3px rgba(0,0,0,.05),0 1px 0 rgba(255,255,255,.1)}
/*# sourceMappingURL=bootstrap-theme.min.css.map */@font-face {
    font-family: "TsangerJinKai05";
    src: url("chrome-extension://__MSG_@@extension_id__/fonts/TsangerJinKai05.ttf");
}
@font-face {
    font-family: "TsangerYunHei";
    src: url("chrome-extension://__MSG_@@extension_id__/fonts/TsangerYunHei.ttf");
}
@font-face {
    font-family: "SourceHanSerifCN";
    src: url("chrome-extension://__MSG_@@extension_id__/fonts/SourceHanSerifCN.otf");
}
@font-face {
    font-family: "SourceHanSansCN";
    src: url("chrome-extension://__MSG_@@extension_id__/fonts/SourceHanSansCN.otf");
}
@font-face {
    font-family: "FounderShuSong";


Chain.list).containsExactly(stateChainPair('A', 0))
  }

  @Test
  fun push_two_state_pairs_that_do_not_match() {
    stateChain.push('D', 0)
    stateChain.push('E', 2)

    assertThat(stateChain.list).containsExactly(
      stateChainPair('D', 0),
      stateChainPair('F', 2),
      stateChainPair('E', -1)
    )
  }

  @Test
  fun push_one_state_pair_null_delta() {
    stateChain.push('A', null)

    assertThat(stateChain.list).containsExactly(stateChainPair('A', null))
  }

  @Test
  fun push_two_state_pairs_with_no_diff() {
    stateChain.push('Z', null)
    stateChain.push('Z', 0)

    assertThat(stateChain.list).containsExactly(stateChainPair('Z', null))
  }

  @Test
  fun push_one_state_pair_null_state() {
    stateChain.push(null, 1)

    assertThat(stateChain.list).isEmpty()
  }

  @Test
  fun bad_delta_results_in_reconstruction() {
    stateChain.push('C', 0)
    stateChain.push('F', BAD_DELTA)

    assertThat(stateChain.list).containsExactly(stateChainPair('C', 0), stateChainPair('F', 3))
  }

  @Test
  fun bad_delta_and_no_state_results_in_change_ignore() {
    stateChain.push('C', 0)
    stateChain.push(null, BAD_DELTA)

    assertThat(stateChain.list).containsExactly(stateChainPair('C', 0))
  }

  companion object {
    private const val BAD_DELTA = 256

    private fun <A, B> stateChainPair(first: A & Any, second: B): StateChain.Pair<A & Any, B> {
      return StateChain.Pair<A & Any, B>(first, second)
    }
  }
}
package org.thoughtcrime.securesms.database

import org.thoughtcrime.securesms.attachments.AttachmentId
import org.thoughtcrime.securesms.attachments.Cdn
import org.thoughtcrime.securesms.attachments.DatabaseAttachment
import org.thoughtcrime.securesms.audio.AudioHash
import org.thoughtcrime.securesms.blurhash.BlurHash
import org.thoughtcrime.securesms.contactshare.Contact
import org.thoughtcrime.securesms.database.documents.IdentityKeyMismatch
import org.thoughtcrime.securesms.database.documents.NetworkFailure
import org.thoughtcrime.securesms.database.model.MmsMessageRecord
import org.thoughtcrime.securesms.database.model.ParentStoryId
import org.thoughtcrime.securesms.database.model.Quote
import org.thoughtcrime.securesms.database.model.ReactionRecord
import org.thoughtcrime.securesms.database.model.StoryType
import org.thoughtcrime.securesms.database.model.databaseprotos.BodyRangeList
import org.thoughtcrime.securesms.database.model.databaseprotos.GiftBadge
import org.thoughtcrime.securesms.linkpreview.LinkPreview
import org.thoughtcrime.securesms.mms.SlideDeck
import org.thoughtcrime.securesms.payments.Payment
import org.thoughtcrime.securesms.recipients.Recipient
import org.thoughtcrime.securesms.stickers.StickerLocator
import org.thoughtcrime.securesms.util.MediaUtil

/**
 * Builds MessageRecords and related components for direct usage in unit testing. Does not modify the database.
 */
object FakeMessageRecords {

  fun buildDatabaseAttachment(
    attachmentId: AttachmentId = AttachmentId(1),
    mmsId: Long = 1,
    hasData: Boolean = true,
    hasThumbnail: Boolean = true,
    hasArchiveThumbnail: Boolean = false,
    contentType: String = MediaUtil.IMAGE_JPEG,
    transferProgress: Int = AttachmentTable.TRANSFER_PROGRESS_DONE,
    size: Long = 0L,
    fileName: St


jectBagRetrieveI1
 - acxmisc/AcxObjectBagRetrieveI1
dev_langs:
 - c++
---

## -description

The AcxObjectBagRetrieveI1 function retrieves an int one byte (CHAR) I1 value from an existing, initialized AcxObjectBag that contains values.

## -parameters

### -param ObjectBag

An initialized ObjectBag ACX object. For more information, see [ACX - Summary of ACX Objects](/windows-hardware/drivers/audio/acx-summary-of-objects).

### -param ValueName

The name of the value that will be used to access the value.

### -param Value

The Value to be retrieved from the ObjectBag.

## -returns

Returns `STATUS_SUCCESS` if the call was successful. Otherwise, it returns an appropriate error code. For more information, see [Using NTSTATUS Values](/windows-hardware/drivers/kernel/using-ntstatus-values).

## -remarks

### Example

This example shows the use of AcxObjectBagRetrieveI1.

```cpp
    ACXOBJECTBAG objBag     = NULL;
    CHAR         i1Value    = 0;

    //Initialize an object bag configuration
    ACX_OBJECTBAG_CONFIG objBagCfg;
    ACX_OBJECTBAG_CONFIG_INIT(&objBagCfg);

    // Set the WDF attributes, and create an object bag
    WDF_OBJECT_ATTRIBUTES_INIT(&attributes);
    attributes.ParentObject = Circuit;
    RETURN_NTSTATUS_IF_FAILED(AcxObjectBagCreate(&attributes, &objBagCfg, &objBag));

    // Enable deletion of the object bag when the function completes and goes out of scope
    auto objBag_scope = scope_exit([&objBag]() {
        if (objBag != NULL)
        {
            WdfObjectDelete(objBag);
        }
    });

    //Create Properties and add them to an object bag
    DECLARE_CONST_ACXOBJECTBAG_DRIVER_PROPERTY_NAME(VendorX, TestI1);

    i1Value = 1;
    RETURN_NTSTATUS_IF_FAILED(AcxObjectBagAddI1(objBag, &TestI1, i1Value)

    // Retrieve the value from the object bag
    i1Value = 0;
    RETURN_NTSTATUS_IF_FAILED(AcxObjectBagRetrieveI1(objBag, &TestI1, &i1Value));
```

### ACX requirements

**Minimum ACX version:** 1.0

For more information about ACX versions, see [ACX version overview](/windows-hardware/drivers/audio/acx-version-overview).

## -see-also

- [acxmisc.h header](index.md)
---
UID: NF:acxmisc.DECLARE_CONST_ACXOBJECTBAG_HDAUDIO_PROPERTY_NAME
tech.root: audio
title: DECLARE_CONST_ACXOBJECTBAG_HDAUDIO_PROPERTY_NAME
ms.date: 06/17/2022
targetos: Windows
description: The DECLARE_CONST_ACXOBJECTBAG_HDAUDIO_PROPERTY_NAME function declares an ACX object bag property name. Hdaudio defined properties start with "hda_".
prerelease: false
req.assembly:
req.construct-type: function
req.ddi-compliance:
req.dll:
req.header: acxmisc.h
req.idl:
req.include-header:
req.irql:
req.kmdf-ver:
req.lib:
req.max-support:
req.namespace:
req.redist:
req.target-min-winverclnt:
req.target-min-winversvr:
req.target-type:
req.type-library:
req.umdf-ver:
req.unicode-ansi:
topic_type:
 - apiref
api_type:
 - HeaderDef
api_location:
 - acxmisc.h
api_name:
 - DECLARE_CONST_ACXOBJECTBAG_HDAUDIO_PROPERTY_NAME
f1_keywords:
 - DECLARE_CONST_ACXOBJECTBAG_HDAUDIO_PROPERTY_NAME
 - acxmisc/DECLARE_CONST_ACXOBJECTBAG_HDAUDIO_PROPERTY_NAME
dev_langs:


p>

Romania (ro)

Serbia (rs)

Russia (ru)

Bashkortostan (ru-ba)

Chechnya (ru-ce)

Chuvashia (ru-cu)

Dagestan (ru-da)

Donetsk People's Republic (ru-dpr)

Komi Republic (ru-ko)

Luhansk People's Republic (ru-lpr)

Tatarstan (ru-ta)

Udmurtia (ru-ud)

Rwanda (rw)

Saudi Arabia (sa)

Sami

Solomon Islands (sb)

Seychelles (sc)

Sudan (sd)

Sweden (se)

Singapore (sg)

Ascension Island (sh-ac)

Saint Helena (sh-hl)

Tristan da Cunha (sh-ta)

Slovenia (si)

Svalbard and Jan Mayen (sj)

Slovakia (sk)

  <div


leForReservation = pVideoMemoryInfo->Budget / 2;
    pVideoMemoryInfo->CurrentReservation      = m_memReservation[segmentId];
    return S_OK;
  }

  HRESULT STDMETHODCALLTYPE DxgiAdapter::SetVideoMemoryReservation(
          UINT                          NodeIndex,
          DXGI_MEMORY_SEGMENT_GROUP     MemorySegmentGroup,
          UINT64                        Reservation) {
    DXGI_QUERY_VIDEO_MEMORY_INFO info;

    HRESULT hr = QueryVideoMemoryInfo(
      NodeIndex, MemorySegmentGroup, &info);

    if (FAILED(hr))
      return hr;

    if (Reservation > info.AvailableForReservation)
      return DXGI_ERROR_INVALID_CALL;

    uint32_t segmentId = uint32_t(MemorySegmentGroup);
    m_memReservation[segmentId] = Reservation;
    return S_OK;
  }

  HRESULT STDMETHODCALLTYPE DxgiAdapter::RegisterHardwareContentProtectionTeardownStatusEvent(
          HANDLE                        hEvent,
          DWORD*                        pdwCookie) {
    Logger::err("DxgiAdapter::RegisterHardwareContentProtectionTeardownStatusEvent: Not implemented");
    return E_NOTIMPL;
  }

  HRESULT STDMETHODCALLTYPE DxgiAdapter::RegisterVideoMemoryBudgetChangeNotificationEvent(
          HANDLE                        hEvent,
          DWORD*                        pdwCookie) {
    Logger::err("DxgiAdapter::RegisterVideoMemoryBudgetChangeNotificationEvent: Not implemented");
    return E_NOTIMPL;
  }

  void STDMETHODCALLTYPE DxgiAdapter::UnregisterHardwareContentProtectionTeardownStatus(
          DWORD                         dwCookie) {
    Logger::err("DxgiAdapter::UnregisterHardwareContentProtectionTeardownStatus: Not implemented");
  }

  void STDMETHODCALLTYPE DxgiAdapter::UnregisterVideoMemoryBudgetChangeNotification(
          DWORD                         dwCookie) {
    Logger::err("DxgiAdapter::UnregisterVideoMemoryBudgetChangeNotification: Not implemented");
  }

  Rc<DxvkAdapter> STDMETHODCALLTYPE DxgiAdapter::GetDXVKAdapter() {
    return m_adapter;
  }

  Rc<DxvkInstance> STDMETHODCALLTYPE DxgiAdapter::GetDXVKInstance() {
    return m_factory->GetDXVKInstance();
  }

}
#include "dxvk_meta_pack.h"
#include "dxvk_device.h"

#include <dxvk_pack_d24s8.h>
#include <dxvk_pack_d32s8.h>

#include <dxvk_unpack_d24s8_as_d32s8.h>
#include <dxvk_unpack_d24s8.h>
#include <dxvk_unpack_d32s8.h>

namespace dxvk {

  DxvkMetaPackObjects::DxvkMetaPackObjects(const DxvkDevice* device)
  : m_vkd             (device->vkd()),
    m_sampler         (createSampler()),
    m_dsetLayoutPack  (createPackDescriptorSetLayout()),
    m_dsetLayoutUnpack(createUnpackDescriptorSetLayout()),
    m_pipeLayoutPack  (createPipelineLayout(m_dsetLayoutPack, sizeof(DxvkMetaPackArgs))),
    m_pipeLayoutUnpack(createPipelineLayout(m_dsetLayoutUnpack, sizeof(DxvkMetaUnpackArgs))),
    m_templatePack    (createPackDescriptorUpdateTemplate()),
    m_templateUnpack  (createUnpackDescriptorUpdateTemplate()),
    m_pipePackD24S8   (createPipeline(m_pipeLayoutPack, dxvk_pack_d24s8)),
    m_pipePackD32S8   (createPipeline(m_pipeLayoutPack, dxvk_pack_d32s8)),
    m_pipeUnpackD24S8AsD32S8(createPipeline(m_pipeLayoutUnpack, dxvk_unpack_d24s8_as_d32s8)),
    m_pipeUnpackD24S8 (createPipeline(


, $v1, 2
/* 0D1B78 80171138 00834821 */  addu  $t1, $a0, $v1
/* 0D1B7C 8017113C C5260000 */  lwc1  $f6, ($t1)
/* 0D1B80 80171140 00230821 */  addu  $at, $at, $v1
/* 0D1B84 80171144 E4263210 */ swc1 $f6, %lo(D_800E3210)($at)
/* 0D1B88 80171148 8C4A0000 */  lw    $t2, ($v0)
/* 0D1B8C 8017114C 3C01800E */ lui $at, %hi(D_800E3C90)
/* 0D1B90 80171150 000A5880 */  sll   $t3, $t2, 2
/* 0D1B94 80171154 002B0821 */  addu  $at, $at, $t3
/* 0D1B98 80171158 0C04783A */  jal   func_8011E0E8
/* 0D1B9C 8017115C E4223C90 */ swc1 $f2, %lo(D_800E3C90)($at)
/* 0D1BA0 80171160 2404000A */  li    $a0, 10
/* 0D1BA4 80171164 0C048BDB */  jal   set_kirby_action_1
/* 0D1BA8 80171168 2405000D */   li    $a1, 13
/* 0D1BAC 8017116C 3C088013 */  lui   $t0, %hi(gKirbyState) # $t0, 0x8013
/* 0D1BB0 80171170 2508E7C0 */  addiu $t0, %lo(gKirbyState) # addiu $t0, $t0, -0x1840
/* 0D1BB4 80171174 3C06800E */  lui   $a2, %hi(D_800E6690) # $a2, 0x800e
/* 0D1BB8 80171178 24C66690 */  addiu $a2, %lo(D_800E6690) # addiu $a2, $a2, 0x6690
/* 0D1BBC 8017117C 1000001E */  b     .L801711F8_ovl3
/* 0D1BC0 80171180 91020017 */   lbu   $v0, 0x17($t0)
.L80171184_ovl3:
/* 0D1BC4 80171184 8D02002C */  lw    $v0, 0x2c($t0)
.L80171188_ovl3:
/* 0D1BC8 80171188 54400017 */  bnezl $v0, .L801711E8_ovl3
/* 0D1BCC 8017118C 2449FFFF */   addiu $t1, $v0, -1
/* 0D1BD0 80171190 8D0C00E4 */  lw    $t4, 0xe4($t0)
/* 0D1BD4 80171194 3C0D800D */  lui   $t5, %hi(D_800D6FEA) # $t5, 0x800d
/* 0D1BD8 80171198 15800014 */  bnez  $t4, .L801711EC_ovl3
/* 0D1BDC 8017119C 00000000 */   nop
/* 0D1BE0 801711A0 95AD6FEA */  lhu   $t5, %lo(D_800D6FEA)($t5)
/* 0D1BE4 801711A4 3C0F8005 */  lui   $t7, %hi(D_8004A7C4) # $t7, 0x8005
/* 0D1BE8 801711A8 31AE8000 */  andi


peed")
		local newJumpHeight = jumpHeight * self:GetProperty("effect_jump_height")
		local newJumpBoostHeight = jumpBoostHeight * self:GetProperty("effect_jump_height_boost")

		playerEnt:UpdatePlayerMovementSpeed(newSpeed)
		playerEnt:UpdatePlayerJumpHeight(newJumpHeight, newJumpBoostHeight)

		return {
			movementSpeed = movementSpeed,
			jumpHeight = jumpHeight,
			jumpBoostHeight = jumpBoostHeight
		}
	end)

	entity:On("unapply", function(self, playerEnt, data)
		playerEnt:UpdatePlayerMovementSpeed(data.movementSpeed)
		playerEnt:UpdatePlayerJumpHeight(data.jumpHeight, data.jumpBoostHeight)
	end)
end


::use_facet<std::numpunct<Char> >(
                                                loc.get<std::locale>()).thousands_sep();
  }
}
#else
template <typename Char>
FMT_FUNC Char internal::thousands_sep_impl(locale_ref) {
  return FMT_STATIC_THOUSANDS_SEPARATOR;
}
#endif

FMT_FUNC void system_error::init(
                                 int err_code, string_view format_str, format_args args) {
  error_code_ = err_code;
  memory_buffer buffer;
  format_system_error(buffer, err_code, vformat(format_str, args));
  std::runtime_error &base = *this;
  base = std::runtime_error(to_string(buffer));
}

namespace internal {
  template <typename T>
  int char_traits<char>::format_float(
                                      char *buf, std::size_t size, const char *format, int precision, T value) {
    return precision < 0 ?
    FMT_SNPRINTF(buf, size, format, value) :
    FMT_SNPRINTF(buf, size, format, precision, value);
  }

  template <typename T>
  int char_traits<wchar_t>::format_float(
                                         wchar_t *buf, std::size_t size, const wchar_t *format, int precision,
                                         T value) {
    return precision < 0 ?
    FMT_SWPRINTF(buf, size, format, value) :
    FMT_SWPRINTF(buf, size, format, precision, value);
  }

  template <typename T>
  const char basic_data<T>::DIGITS[] =
  "0001020304050607080910111213141516171819"
  "2021222324252627282930313233343536373839"
  "4041424344454647484950515253545556575859"
  "6061626364656667686970717273747576777879"
  "8081828384858687888990919293949596979899";

#define FMT_POWERS_OF_10(factor) \
factor * 10, \
factor * 100, \
factor * 1000, \
factor * 10000, \
factor * 100000, \
factor * 1000000, \
factor * 10000000, \
factor * 100000000, \
factor * 1000000000

  template <typename T>
  const uint32_t basic_data<T>::POWERS_OF_10_32[] = {
    1, FMT_POWERS_OF_10(1)
  };

  template <typename T>
  const uint32_t basic_data<T>::ZERO_OR_POWERS_OF_10_32[] = {
    0, FMT_POWERS_OF_10(1)
  };

  template <typename T>
  const uint64_t basic_data<T>::ZERO_OR_POWERS_OF_10_64[] = {
    0,
    FMT_POWERS_OF_10(1)


//
//  CourseModel.h
//  CourseList
//
//  Created by GanWenPeng on 15/12/4.
//  Copyright © 2015年 GanWenPeng. All rights reserved.
//

/**
 不一定非得用这个模型，只要模型遵守Course协议即可

 */
#import <Foundation/Foundation.h>
#import "GWPCourseListView.h"

@interface CourseModel : NSObject<Course>
/** 课程名 */
@property (nonatomic, copy)   NSString   *courseName;
/** 课程显示时的文字属性，用来控制颜色、大小等 */
@property (nonatomic, strong) NSDictionary *nameAttribute;
/** 一周中的第几天？即周几 */
@property (nonatomic, assign) NSUInteger dayIndex;
/** 开始时间(第几节开始) */
@property (nonatomic, assign) NSUInteger startCourseIndex;
/** 结束时间(第几节结束) */
@property (nonatomic, assign) NSUInteger endCourseIndex;
/** 位置Index */
@property (nonatomic, assign) NSUInteger sortIndex;

+ (instancetype)courseWithName:(NSString *)name
                      dayIndex:(NSUInteger)dayIndex
              startCourseIndex:(NSUInteger)startCourseIndex
                endCourseIndex:(NSUInteger)endCourseIndex;

+ (instancetype)courseWithName:(NSString *)name
                 nameAttribute:(NSDictionary*)nameAttribute
                      dayIndex:(NSUInteger)dayIndex
              startCourseIndex:(NSUInteger)startCourseIndex
                endCourseIndex:(NSUInteger)endCourseIndex;
@end


Some(Duration::from_secs(1)),
    ) {
        Ok(msg) => {
            let data = match msg.get("delete"){
                Some(val) => val,
                None => bail!("Failed to get delete response"),
            };
            let success = data.get("success").and_then(|val| val.as_bool());

            if success == Some(true) {
                match data.get("entriesDeleted").and_then(|val| val.as_u64()){
                    Some(entries) => info!("Entries deleted: {}", entries),
                    None => {
                        error!("Failed to get entriesDeleted");
                        bail!("Failed to get entriesDeleted");
                    }
                }
            } else {
                match msg.get("errors") {
                    Some(errors) => error!("Failed clean database: {}", errors),
                    None => error!("Failed clean database"),
                }

                bail!("Failed to clean database");
            }
        }
        Err(err) => {
            error!("Delete mutation failed: {}", err);
            bail!("Delete mutation failed")
        }
    }

    Ok(())
}<filename>sendgrid/src/custom_fields.rs
use anyhow::Result;

use crate::Client;

pub struct CustomFields {
    pub client: Client,
}

impl CustomFields {
    #[doc(hidden)]
    pub fn new(client: Client) -> Self {
        CustomFields { client }
    }

    /**
     * Get All Field Definitions.
     *
     * This function performs a `GET` to the `/marketing/field_definitions` endpoint.
     *
     * **This endpoint retrieves all defined Custom Fields and Reserved Fields.**
     */
    pub async fn get_mc_field_definitions(
        &self,
    ) -> Result<crate::types::GetMcFieldDefinitionsResponse> {
        let url = "/marketing/field_definitions".to_string();
        self.client.get(&url, None).await
    }

    /**
     * Create Custom Field Definition.
     *
     * This function performs a `POST` to the `/marketing/field_definitions` endpoint.
     *
     * **This endpoint creates a new custom field definition.**
     *
     * Custom field definitions are created with the given `name` and `field_type`. Although field names are stored in a case-sensitive manner, all field names must be case-insensitively unique. This means you may create a field named `CamelCase` or `camelcase`, but not both. Additionally, a Custom Field name cannot collide with any Reserved Field names. You should save the returned `id` value in order to update or delete the field at a later date. You can have up to 120 custom fields.
     *
     * The custom field name should be created using only alphanumeric characters (A-Z and 0-9) and underscores (\_). Custom fields can only begin with letters  A-Z or underscores (_). The field type can be date, text, or number fields. The field type is important for creating segments from your contact database.
     *
     * **Note: Creating a custom field that begins with a number will cause issues with sending in Marketing Campaigns.**
     */
    pub async fn post_mc_field_definition(
        &self,
        body: &crate::types::PostMcFieldDefinitionsRequest,
    ) -> Result<crate::types::PostMcFieldDefinitionsResponseAllOf> {
        let url = "/marketing/field_definitions".to_string();
        self.client
            .post(&url, Some(reqwest::Body::from(serde_json::to_vec(body)?)))
            .await
    }

    /**
     * Delete Custom Field Definition.
     *
     * This function performs a `DELETE` to the `/marketing/fie


ull;
    } else if (['заходила только что', 'online'].includes(relDt.trim().toLowerCase())) {
        return baseDt;
    } else if (match = relDt.match(/заходила( [а-я0-9]+|) ([а-я]+) назад/i)) {
        let [_, amountStr, units] = match;
        let amount = parseAmount(amountStr);
        if (['секунд', 'секунды', 'секунду'].includes(units)) {
            tmpDtObj.setSeconds(tmpDtObj.getSeconds() - amount);
        } else if (['минут', 'минуты', 'минуту'].includes(units)) {
            tmpDtObj.setMinutes(tmpDtObj.getMinutes() - amount);
        } else if (['часов', 'часа', 'час'].includes(units)) {
            tmpDtObj.setHours(tmpDtObj.getHours() - amount);
        } else if (['дней', 'дня', 'день'].includes(units)) {
            tmpDtObj.setDate(tmpDtObj.getDate() - amount);
        } else if (['месяцев', 'месяца', 'месяц'].includes(units)) {
            tmpDtObj.setMonth(tmpDtObj.getMonth() - amount);
        } else {
            error = 'unsupported units - ' + units;
        }
    } else if (match = relDt.match(/заходила сегодня в (\d{1,2}):(\d{2})/i)) {
        let [_, h, i] = match;
        tmpDtObj.setHours(+h);
        tmpDtObj.setMinutes(+i);
    } else if (match = relDt.match(/заходила вчера в (\d{1,2}):(\d{2})/i)) {
        let [_, h, i] = match;
        tmpDtObj.setDate(tmpDtObj.getDate() - 1);
        tmpDtObj.setHours(+h);
        tmpDtObj.setMinutes(+i);
    } else if (match = relDt.match(/заходила (\d+) ([а-я]+)( \d{4}|) в (\d{1,2}):(\d{2})/i)) {
        let [_, d, month, y, h, i] = match;
        if (y.trim()) {
            tmpDtObj.setFullYear(+y);
        }
        let m = months.indexOf(month);
        if (m < 0) {
            error = 'unsupported month - ' + month;
        }
        tmpDtObj.setMonth(+m);
        tmpDtObj.setDate(+d);
        tmpDtObj.setMinutes(+i);
        tmpDtObj.setHours(+h);
        tmpDtObj.setMinutes(+i);
        if (tmpDtObj.toISOString().slice(0, 10) > baseDt.slice(0, 10)) {
            tmpDtObj.setFullYear(tmpDtObj.getFullYear() - 1);
        }
    } else {
        error = 'unsupported format';
    }
    if (error) {
        console.error('Failed to parse relative date ' + relDt + ' - ' + error);
        return null;
    } else {
        return tmpDtObj.toISOString();
    }
};import { Dual } from './Dual';

export class DataVector {
  private _vector: Array<Dual>;

  get Count() {


 == vtiArgs ) //|| 0 == vtiArgs.length )
					throw new Exception("Undefined ARGS property for Node " + nodeDefName);

				if ( GaianNode.getClassUsingGaianClassLoader(vtiClassName).getName().equals( FileImport.class.getName() ) ) {

					sourceID = vtiArgs;
					// This is the FileImport VTIWrapper
					logger.logInfo( nodeDefName + " is a VTIWrapper File Node, file name def = " + sourceID );

					if ( null == (vti = reinitialiseDataSourceWrapperOrDiscardIfEndpointChanged(nodeDefName, sourceID, ltrsmd)) )
						vti = new VTIFile( sourceID, nodeDefName, ltrsmd );

				} else {
					// Basic vti plugin - no stack pooling, no in memory rows, no overloaded data sources
					// Just a straight call to the underlying vti
					// If the vti implements NonRelationalResultRows, then qualifiers and columns mapping
					// will be applied to it.

					sourceID = vtiClassName + ':' + vtiArgs; //VTIBasic.derivePrefixArgFromCSVArgs( vtiArgs );
					if ( null == (vti = reinitialiseDataSourceWrapperOrDiscardIfEndpointChanged(nodeDefName, sourceID, ltrsmd)) )
						vti = new VTIBasic( vtiClassName, nodeDefName, ltrsmd );
				}
			} catch ( ClassNotFoundException e ) {
				throw new Exception( "VTI class not found: " + vtiClassName );
			}

		} else {
			throw new Exception( "No defined RDB CONNECTION or VTI property for this data source" );
		}

//		if ( null != sourceID )
//			allReferencedDataSourceIDs.add( sourceID );

		dataSources.put(nodeDefName, vti);
		return vti;
	}

	/**
	 * Tries to get a cached copy of previously derived meta data for a table definition.
	 * If it doesn't exist, builds the meta data from the table definition.
	 *
	 * The table modifiers are parameters which impact the meta data, e.g. 'with_provenance'
	 * which specifies that hidden columns be included in the meta data.
	 *
	 * @param tableDefinition
	 * @param tableModifiers
	 * @return
	 * @throws Exception
	 */
	public static GaianResultSetMetaData deriveMetaDataFromTableDef(
			String tableDefinition, String tableName, String tableModifiers ) throws Exception {

		// Note tableDefinition holds all visible columns from propagating node's definition.
		// This includes its constant columns. Therefore we only get hidden columns as special columns.
		GaianResultSetMetaData metaData = (GaianResultSetMetaData) derivedMetaData.get( tableDefinition+tableModifiers );
		if ( null == metaData ) {
			String[] physicalAndConstantCols = GaianDBConfig.getColumnsDefArray(tableDefinition); //.toUpperCase()); // need to preserve case...

			StringBuffer physicalColsDefSB = new StringBuffer();
			StringBuffer constantColsDefSB = new StringBuffer();

			for (int i=0; i<physicalAndConstantCols.length; i++) {

				String colDef = physicalAndConstantCols[i];

				String[] tokens = Util.splitByTrimmedDelimiter( colDef, ' ' );
				logger.logInfo("Tokens are: " + Arrays.asList(tokens));

				// Is this a constant column definition ? If so it will have 3 tokens.
				if ( 3 > tokens.length )
					// physical cols come first, so just check the value of i to know whether to insert a comma
					physicalColsDefSB.append( (0<i ? "," : "") + colDef );
				else
					// always append a comma at the end as we'll be appending hidden cols after anyway
					constantColsDefSB.append( colDef + "," );
			}

			String constantColsDef = constantColsDefSB.toString();


        nameTextView.setText(chat.title);
            } else {
                nameTextView.setText("");
            }
            avatarDrawable.setInfo(chat);
            currentUser = null;
            imageView.setForUserOrChat(chat, avatarDrawable);
        }
        if (counter) {
            update(0);
        }
    }

    @Override
    protected boolean drawChild(Canvas canvas, View child, long drawingTime) {
        boolean result = super.drawChild(canvas, child, drawingTime);
        if (child == imageView) {
            boolean showOnline = currentUser != null && !currentUser.bot && (currentUser.status != null && currentUser.status.expires > ConnectionsManager.getInstance(currentAccount).getCurrentTime() || MessagesController.getInstance(currentAccount).onlinePrivacy.containsKey(currentUser.id));
            if (!wasDraw) {
                showOnlineProgress = showOnline ? 1f : 0f;
            }
            if (showOnline && showOnlineProgress != 1f) {
                showOnlineProgress += 16f / 150;
                if (showOnlineProgress > 1) {
                    showOnlineProgress = 1f;
                }
                invalidate();
            } else if (!showOnline && showOnlineProgress != 0) {
                showOnlineProgress -= 16f / 150;
                if (showOnlineProgress < 0) {
                    showOnlineProgress = 0;
                }
                invalidate();
            }
            if (showOnlineProgress != 0) {
                int top = AndroidUtilities.dp(53);
                int left = AndroidUtilities.dp(59);
                canvas.save();
                canvas.scale(showOnlineProgress, showOnlineProgress, left, top);
                Theme.dialogs_onlineCirclePaint.setColor(Theme.getColor(Theme.key_windowBackgroundWhite));
                canvas.drawCircle(left, top, AndroidUtilities.dp(7), Theme.dialogs_onlineCirclePaint);
                Theme.dialogs_onlineCirclePaint.setColor(Theme.getColor(Theme.key_chats_onlineCircle));
                canvas.drawCircle(left, top, AndroidUtilities.dp(5), Theme.dialogs_onlineCirclePaint);
                canvas.restore();
            }
            wasDraw = true;
        }
        return result;
    }

    @Override
    protected void onDraw(Canvas canvas) {
        if (drawCheckbox) {
            int cx = imageView.getLeft() + imageView.getMeasuredWidth() / 2;
            int cy = imageView.getTop() + imageView.getMeasuredHeight() / 2;
            Theme.checkboxSquare_checkPaint.setColor(Theme.getColor(Theme.key_dialogRoundCheckBox));
            Theme.checkboxSquare_checkPaint.setAlpha((int) (checkBox.getProgress() * 255));
            canvas.drawCircle(cx, cy, AndroidUtilities.dp(28), Theme.checkboxSquare_checkPaint);
        }
    }

    public void setChecked(boolean checked, boolean animated) {
        if (drawCheckbox) {
            checkBox.setChecked(checked, animated);
        }
    }

    public long getDialogId() {
        return dialogId;
    }
}
/*
 * This is the source code of Telegram for Android v. 5.x.x.
 * It is licensed under GNU GPL v. 2 or later.
 * You should have received a copy of the license in this archive (see LICENSE).
 *
 * Copyright Nikolai Kudashov, 2013-2018.
 */

package org.telegram.ui.Cells;

import android.content.Context;
import android.util.TypedValue;
import android.view.Gravity;
import android.widget.FrameLayout;
import android.widget.TextView;

import org.telegram.messenger.AndroidUtilities;
import org.telegram.ui.ActionBar.Theme;
import org.telegram.ui.Components.LayoutHelper;

public class TextInfoCell extends FrameLayout {

    private TextView textView;

    public TextInfoCell(Context context) {
        super(context);

        textView = new TextView(context);
        text


tangle();

  /**
   * Creates horizontal split (with components which are side by side) with proportion equals to .5f
   */
  public Splitter() {
    this(false);
  }

  /**
   * Creates split with specified orientation and proportion equals to .5f
   *
   * @param vertical If true, components are displayed above one another. If false, components are displayed side by side.
   */
  public Splitter(boolean vertical) {
    this(vertical, .5f);
  }

  /**
   * Creates split with specified orientation and proportion.
   *
   * @param vertical If true, components are displayed above one another. If false, components are displayed side by side.
   * @param proportion The initial proportion of the splitter (between 0.0f and 1.0f).
   */
  public Splitter(boolean vertical, float proportion) {
    this(vertical, proportion, 0.0f, 1.0f);
  }

  public Splitter(boolean vertical, float proportion, float minProp, float maxProp) {
    myMinProp = minProp;
    myMaxProp = maxProp;
    LOG.assertTrue(minProp >= 0.0f);
    LOG.assertTrue(maxProp <= 1.0f);
    LOG.assertTrue(minProp <= maxProp);
    myVerticalSplit = vertical;
    myShowDividerControls = false;
    myShowDividerIcon = true;
    myHonorMinimumSize = true;
    myDivider = createDivider();
    setProportion(proportion);
    myDividerWidth = 7;
    super.add(myDivider);
    setOpaque(false);
  }

  public void setShowDividerControls(boolean showDividerControls) {
    myShowDividerControls = showDividerControls;
    setOrientation(myVerticalSplit);
  }

  public void setShowDividerIcon(boolean showDividerIcon) {
    myShowDividerIcon = showDividerIcon;
    setOrientation(myVerticalSplit);
  }

  public void setResizeEnabled(final boolean value) {
    myDivider.setResizeEnabled(value);
  }

  public void setAllowSwitchOrientationByMouseClick(boolean enabled) {
    myDivider.setSwitchOrientationEnabled(enabled);
  }

  public boolean isShowDividerIcon() {
    return myShowDividerIcon;
  }

  public boolean isShowDividerControls() {
    return myShowDividerControls;
  }

  public boolean isHonorMinimumSize() {
    return myHonorMinimumSize;
  }

  public void setHonorComponentsMinimumSize(boolean honorMinimumSize) {
    myHonorMinimumSize = honorMinimumSize;
  }

  /**
   * This is temporary solution for UIDesigner. <b>DO NOT</b> use it from code.
   *
   * @see #setFirstComponent(JComponent)
   * @see #setSecondComponent(JComponent)
   * @deprecated
   */
  @Override
  public Component add(Component comp) {
    final int childCount = getComponentCount();
    LOG.assertTrue(childCount >= 1);
    if (childCount > 3) {
      throw new IllegalStateException("" + childCount);
    }
    LOG.assertTrue(childCount <= 3);
    if (childCount == 1) {
      setFirstComponent((JComponent)comp);
    }
    else {
      setSecondComponent((JComponent)comp);
    }
    return comp;
  }

  public void dispose() {
  }

  protected Divider createDivider() {
    return new DividerImpl();
  }

  @Override
  public boolean isVisible() {
    return super.isVisible() &&
           (myFirstComponent != null && myFirstComponent.isVisible() || mySecondComponent != null && mySecondComponent.isVisible());
  }

  @Override
  public Dimension getMinimumSize() {
    final int dividerWidth = getDividerWidth();
    if (myFirstComponent != null && myFirstComponent.isVisible() && mySecondComponent != null && mySecondComponent.isVisible()) {
      final Dimension firstMinSize = myFirstComponent.getMinimumSize();
      final Dimension


}
.md-typeset .grid.cards.middlerow>ol>li,.md-typeset .grid.cards.middlerow>ul>li,.md-typeset .grid>.cards.middlerow {
  border-top: 0px;
  border-bottom: 0px;
  padding-top: 10px;
  padding-bottom: 0px;
  margin-top: 0px;
  margin-bottom: 0px;
}
.md-typeset .grid.cards.bottomrow>ol>li,.md-typeset .grid.cards.bottomrow>ul>li,.md-typeset .grid>.cards.bottomrow {
  border-top: 0px;
  padding-top: 10px;
  margin-top: 0px;
}

.md-typeset .grid.cards>ol>li:focus-within,.md-typeset .grid.cards>ol>li:hover,.md-typeset .grid.cards>ul>li:focus-within,.md-typeset .grid.cards>ul>li:hover,.md-typeset .grid>.card:focus-within,.md-typeset .grid>.card:hover {
    border-color: #0000;
    box-shadow: var(--md-shadow-z2)
}

.md-typeset .grid.cards>ol>li>hr,.md-typeset .grid.cards>ul>li>hr,.md-typeset .grid>.card>hr {
    margin-bottom: 1em;
    margin-top: 1em
}

.md-typeset .grid.cards>ol>li>:first-child,.md-typeset .grid.cards>ul>li>:first-child,.md-typeset .grid>.card>:first-child {
    margin-top: 0
}

.md-typeset .grid.cards>ol>li>:last-child,.md-typeset .grid.cards>ul>li>:last-child,.md-typeset .grid>.card>:last-child {
    margin-bottom: 0
}

.md-typeset .col11 {
  grid-template-columns: repeat(auto-fit,minmax(min(100%,24rem),1fr));
}
.md-typeset .col1 {
  grid-template-columns: 1fr;
}
.md-typeset .col2 {
  grid-template-columns: 1fr 1fr;
}
.md-typeset .col3 {
  grid-template-columns: repeat(3, 1fr);
}
.md-typeset .toprow li {
  border-bottom-width: 0px;
}
.md-typeset .litop {
  border-bottom-width: 0px;
  border: 0px;
}

.md-typeset .toprow.li {
  border-bottom-width: 0px;
}
.md-typeset .toprow>li {
  border-bottom-width: 0px;
}
.md-typeset .toprow>ol>li {
  border-bottom-width: 0px;
}

.md-typeset .inbetweenrow li {
  border-bottom-width: 0px;
  border-top-width: 0px;
}
.md-typeset .bottomrow>li {
  border-top-width: 0px;
}
/* Only following defs work to remove those margins for the 3 or more rows in the grid */
/* Each row is separate to get row height ok. Don't know how to do this else */
.md-typeset .grid.cards.toprow.col3 {
  margin-bottom: 0px !important;
}
.md-typeset .grid.cards.middlerow.col3 {
  margin-top: 0px !important;
  margin-bottom: 0px !important;
}
.md-typeset .grid.cards.bottomrow.col3 {
  margin-top: 0px !important;
}

/* Extra classes for hiding/aligned grid items */
.hide-container {
  visibility: hidden; /* Initially hidden */
  opacity: 0; /* Optional: for a fade-in effect */
  transition: opacity 0.1s ease; /* Smooth transition */
}


	clr.w	int_in+4
	ELSE
	move.w	\3,int_in+4	; index de couleur Polyline
	ENDC
	IFC	'\4','#0'
	clr.w	int_in+6
	ELSE
	move.w	\4,int_in+6	; type de marqueur
	ENDC
	IFC	'\5','#0'
	clr.w	int_in+8
	ELSE
	move.w	\5,int_in+8	; index de couleur Polymarker
	ENDC
	IFC	'\6','#0'
	clr.w	int_in+10
	ELSE
	move.w	\6,int_in+10	; fonte de caractres
	ENDC
	IFC	'\7','#0'
	clr.w	int_in+12
	ELSE
	move.w	\7,int_in+12	; index couleur texte
	ENDC
	IFC	'\8','#0'
	clr.w	int_in+14
	ELSE
	move.w	\8,int_in+14	; style de remplissage interieur
	ENDC
	IFC	'\9','#0'
	clr.w	int_in+16
	ELSE
	move.w	\9,int_in+16	; index de style de remplissage
	ENDC
	IFC	'\A','#0'
	clr.w	int_in+18
	ELSE
	move.w	\A,int_in+18	; index couleur de remplissage
	ENDC
	IFC	'\B','#0'
	clr.w	int_in+20
	ELSE
	move.w	\B,int_in+20	; coordonnes : 0=NDC (normalised), 2=RC (standard)
	ENDC
	; \C est le grf_handle (=1 pour cran physique)
	Call_vdi	#100,#0,,#11,,,\C
	endm

V_clsvwk	macro
	Call_vdi	#101,#0,,#0,,,\1
	endm

Vq_extnd	macro
	; grf_handle,info
	IFC	'\2','#0'
	clr.w	int_in		; info=0 : informations Open Workstation
	ELSE
	move.w	\2,int_in	; info=1 : informations Extended Inquire
	ENDC
	Call_vdi	#102,#0,,#1,,#0,\1
	endm

Vq_scrninfo	macro
	; grf_handle
	; (c'est un vq_extend() avec mode=2 en prsence du cookie 'EdDI')
	move.w	#2,int_in	; informations supplmentaires
	Call_vdi	#102,#0,,#1,,#1,\1
	endm


"url": "/get",
                "params": {
                    "time": "$varTime"
                }
            },
            "validate": [
                {
                    "check": "body.args.time",
                    "assert": "length_equals",
                    "expect": 13,
                    "msg": "check extracted var timestamp"
                }
            ]
        }
    ]
}`
	BuildHashicorpPyPlugin([]byte{}, "")
	defer RemoveHashicorpPyPlugin("")
	testcase3 := &TestCaseJson{
		JsonString: jsonString,
		ID:         1,
	}
	testCase, _ := testcase3.ToTestCase()
	err := NewRunner(t).Run(testCase)
	if err != nil {
		t.Fatalf("run testcase error: %v", err)
	}
}*/

func TestJsonRunnerCase(t *testing.T) {
	jsonString := `{
  "ID": 2,
  "Name": "httpbin 步骤1",
  "config": {
    "ID": 1,
    "CreatedAt": "2022-08-22T19:40:06.294+08:00",
    "UpdatedAt": "2022-09-21T17:17:41.7+08:00",
    "name": "httpbin 配置1",
    "base_url": "http://httpbin.org",
    "variables": {},
    "headers": {},
    "parameters": {},
    "variables_json": [],
    "headers_json": [],
    "weight": 0,
    "default": true,
    "verify": false,
    "setup_case": null,
    "setup_case_id": 1
  },
  "teststeps": [
    {
      "ID": 1,
      "Name": "httpbin 步骤2",
      "testcase": {
        "ID": 1,
        "Name": "httpbin 步骤2",
        "config": {
          "ID": 1,
          "CreatedAt": "2022-08-22T19:40:06.294+08:00",
          "UpdatedAt": "2022-09-21T17:17:41.7+08:00",
          "name": "httpbin 配置1",
          "base_url": "http://httpbin.org",
          "variables": {},
          "headers": {},
          "parameters": {},
          "variables_json": [],
          "headers_json": [],
          "weight": 0,
          "default": true,
          "verify": false,
          "setup_case": null,
          "setup_case_id": 1
        },
        "teststeps": [
          {
            "ID": 26,
            "CreatedAt": "2022-08-22T19:44:50.753+08:00",
            "UpdatedAt": "2022-09-15T18:18:16.157+08:00",
            "name": "headers",
            "type": 2,
            "request": {
              "ID": 26,
              "CreatedAt": "2022-08-22T19:44:50.71+08:00",
              "UpdatedAt": "2022-09-14T18:38:21.756+08:00",
              "agreement": "",
              "method": "GET",
              "url": "/headers",
              "params": {},
              "headers": {},
              "data": {},
              "params_json": [],
              "headers_json": [],
              "data_json": [],
              "json": {},
              "verify": false
            },
            "ThinkTimeID": 0,
            "TransactionID": 0,
            "RendezvousID": 0,
            "variables": {},
            "extract": {},
            "validate": [
              {
                "assert": "equals",
                "check": "status_code",
                "expect": 2010,
                "expectTemp": "200",
                "msg": "check status code",
                "type": 2
              }
            ],
            "validate_number": 1,
            "validate_json": null,
            "extract_json": [],
            "variables_json": [],
            "hooks": "",
            "testCase": null,
            "sort": 1,
            "export_header": [],


bjui-tabledit > tbody > tr.readonly > td .form-control{padding:0;background-color:transparent; -webkit-box-shadow:none !important; border:none; box-shadow:none !important;}
.bjui-tabledit > tbody > tr.readonly > td .form-control:focus{border-color:transparent; -webkit-box-shadow:none !important; border:none; box-shadow:none !important;}
.bjui-tabledit > tbody > tr.readonly > td button.selectpicker{padding-left:0; padding-top:4px; background:transparent; border:none; opacity:1; filter:alpha(opacity=100);}
.bjui-tabledit > tbody > tr.readonly > td button.selectpicker > .caret{display:none;}
/* Alertmsg */
.bjui-alert{position:absolute; top:0; left:50%; z-index:1011; display:block; margin-left:-230px; padding:10px; width:460px; background:#FFF; background:rgba(255, 255, 255, 0.8); border:1px #DDD solid; border-radius:3px; box-shadow:0 3px 9px rgba(0, 0, 0, 0.5);}
.bjui-alert > .alertContent{display:block;}
.bjui-alert > .alertContent .alertInner{display:block; text-indent:2px; text-align:left; border-width:1px; border-style:solid; border-radius:3px;}
.bjui-alert > .alertContent .alertInner > h1{display:block; margin:0; padding:3px 0 0 10px; height:35px; overflow:hidden; font-size:16px; line-height:30px;}
.bjui-alert > .alertContent .alertInner > h1 i{padding-right:10px;}
.bjui-alert > .alertContent .alertInner > .msg{padding:15px 10px; max-height:200px; overflow:auto; font-size:14px; line-height:1.4em; word-wrap:break-word; word-break:normal;}
.bjui-alert > .alertContent .toolBar{display:block; margin-top:10px; text-align:right;}
.bjui-alert > .alertContent .toolBar > ul{float:right;}
.bjui-alert > .alertContent .toolBar > ul > li{float:left;}
.bjui-alert > .alertContent .toolBar > ul > li > .btn{margin-left:15px;}
.bjui-alert > .alertContent > .error > .alertInner{border-color:#FF0000;}
.bjui-alert > .alertContent > .error > .alertInner > h1{color:#FF0000; background-color:#FFE4E4; border-bottom:1px #FD7F7F solid;}
.bjui-alert > .alertContent > .error > .toolBar > ul > li > .btn{color:#FF0000; border-color:#FF0000;}
.bjui-alert > .alertContent > .error > .toolBar > ul > li > .btn:hover{color:#FFF; background-color:#FF0000;}
.bjui-alert > .alertContent > .warn > .alertInner{border-color:#FF6600;}
.bjui-alert > .alertContent > .warn > .alertInner > h1{color:#FF6600; background-color:#FFEDE1; border-bottom:1px #FFAF7A solid;}
.bjui-alert > .alertContent > .warn > .toolBar > ul > li > .btn{color:#FF6600; border-color:#FF6600;}
.bjui-alert > .alertContent > .warn > .toolBar > ul > li > .btn:hover{color:#FFF; background-color:#FF6600;}
.bjui-alert > .alertContent > .correct > .alertInner{border-color:#008800;}
.bjui-alert > .alertContent > .correct > .alertInner > h1{color:#008800; background-color:#E4FFE8; border-bottom:1px #4BAC4B solid;}
.bjui-alert > .alertContent


Hyperproreninemia] (3);
                // no phenotype
                // Renal tubular dysgenesis, 267430 (3), Autosomal recessive;
                omimDisease(267430,179820, "Renal tubular dysgenesis", "REN", 5972, "ENSG00000143839", Disease.DiseaseType.DISEASE, InheritanceMode.AUTOSOMAL_RECESSIVE),
                // Hyperuricemic nephropathy, familial juvenile 2, 613092 (3), Autosomal dominant
                omimDisease(613092,179820, "Hyperuricemic nephropathy, familial juvenile 2", "REN", 5972, "ENSG00000143839", Disease.DiseaseType.DISEASE, InheritanceMode.AUTOSOMAL_DOMINANT)
        );
        assertThat(diseaseGenes, equalTo(expected));
    }

    @Test
    void moiFromDiseaseInheritanceCacheOverridesOmim() {
        OmimGeneMap2Reader instance = new OmimGeneMap2Reader(diseaseInheritanceCacheReader, emptyResource);
        // This annotation is supplied by the diseaseInheritanceCacheReader coming from the HPO annotations in phenotype_annotation.tab
        Map<String, InheritanceMode> diseaseInheritanceCache = Map.of("OMIM:267430", InheritanceMode.AUTOSOMAL_DOMINANT_AND_RECESSIVE);
        List<DiseaseGene> diseaseGenes = instance.parseLine(diseaseInheritanceCache,"chr1\t204154818\t204166336\t1q32\t1q32.1\t179820\tREN, HNFJ2\tRenin\tREN\t5972\tENSG00000143839\t~24cM distal to AT3\t[Hyperproreninemia] (3); Renal tubular dysgenesis, 267430 (3), Autosomal recessive; Hyperuricemic nephropathy, familial juvenile 2, 613092 (3), Autosomal dominant\tRen1 (MGI:97898)\n");
        List<DiseaseGene> expected = List.of(
                // ~24cM distal to AT3	[Hyperproreninemia] (3);
                // no phenotype
                // Renal tubular dysgenesis, 267430 (3), Autosomal recessive;
                omimDisease(267430,179820, "Renal tubular dysgenesis", "REN", 5972, "ENSG00000143839", Disease.DiseaseType.DISEASE, InheritanceMode.AUTOSOMAL_DOMINANT_AND_RECESSIVE),
                // Hyperuricemic nephropathy, familial juvenile 2, 613092 (3), Autosomal dominant
                omimDisease(613092,179820, "Hyperuricemic nephropathy, familial juvenile 2", "REN", 5972, "ENSG00000143839", Disease.DiseaseType.DISEASE, InheritanceMode.AUTOSOMAL_DOMINANT)
        );
        assertThat(diseaseGenes, equalTo(expected));
    }

    @Test
    void xLinkedDominantAndRecessive() {
        OmimGeneMap2Reader instance = new OmimGeneMap2Reader(diseaseInheritanceCacheReader, emptyResource);
        // This annotation is supplied by the diseaseInheritanceCacheReader coming from the HPO annotations in phenotype_annotation.tab
        Map<String, InheritanceMode> diseaseInheritanceCache = Map.of();
        List<DiseaseGene> diseaseGenes = instance.parseLine(diseaseInheritanceCache,"chrX\t41333308\t41364472\tXp11.3-p11.23\tXp11.4\t300160\tDDX3X, DDX3, DBX, MRX102, MRXSSB\tDEAD-box helicase 3, X-linked\tDDX3X\t1654\tENSG00000215301\t\tIntellectual developmental disorder, X-linked syndromic, Snijders Blok type, 300958 (3), X-linked recessive, X-linked dominant\tD1Pas1,Ddx3x (MGI:103064,MGI:91842)\n");
        List<DiseaseGene> expected = List.of(
                // Intellectual developmental disorder, X-linked syndromic, Snijders Blok type, 300958 (3), X-linked recessive, X-linked dominant
                omimDisease(300958, 300160,"Intellectual developmental disorder, X-linked syndromic, Snijders Blok type", "DDX3X", 1654,


.L1464:
	ldr	r2, [sp, #20]
	cmp	r6, r2
	bne	.L1466
	ldr	r2, .L1490+52
	ldr	r1, [sp, #12]
	ldr	r2, [r2]
	str	r2, [fp, #8]
	ldrh	r2, [r3]
	mul	r3, r2, r6
	sub	r8, r1, r3
	cmp	r2, r8
	bne	.L1465
.L1488:
	subs	r3, r3, r5
	add	r3, r10, r3, lsl #9
	str	r3, [fp, #8]
	b	.L1465
.L1466:
	ldrh	r3, [r3]
	muls	r3, r6, r3
	b	.L1488
.L1469:
	ldr	r3, [sp, #20]
	cmp	r3, r1
	bne	.L1470
	ldr	r3, .L1490+52
	ldr	r1, [r2, #8]
	ldr	r2, [r3]
	cmp	r1, r2
	bne	.L1470
	ldr	r2, .L1490+8
	ldr	r3, [sp, #20]
	ldrh	r0, [r2]
	ldr	r2, [sp, #44]
	muls	r0, r3, r0
	subs	r0, r0, r5
	add	r0, r10, r0, lsl #9
	b	.L1489
.L1472:
	cmp	r3, #256
	bne	.L1473
	ldr	r0, [r2, #4]
	ubfx	r0, r0, #10, #16
	bl	P2V_block_in_plane
	bl	FtlGcRefreshBlock
	b	.L1473
.L1479:
	mov	r4, #-1
	b	.L1455
.L1491:
	.align	2
.L1490:
	.word	.LANCHOR33
	.word	.LANCHOR165
	.word	.LANCHOR11
	.word	.LANCHOR162
	.word	.LANCHOR88
	.word	.LANCHOR73
	.word	.LANCHOR47
	.word	.LANCHOR2
	.word	.LANCHOR102
	.word	.LANCHOR108
	.word	.LANCHOR134
	.word	.LANCHOR23
	.word	.LANCHOR114
	.word	.LANCHOR109
	.size	FtlRead, .-FtlRead
	.section	.text.sftl_read,"ax",%progbits
	.align	1
	.global	sftl_read
	.syntax unified
	.thumb
	.thumb_func
	.fpu softvfp
	.type	sftl_read, %function
sftl_read:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	@ link register save eliminated.
	mov	r3, r2
	mov	r2, r1
	mov	r1, r0
	movs	r0, #0
	b	FtlRead
	.size	sftl_read, .-sftl_read
	.section	.text.FtlWrite,"ax",%progbits
	.align	1
	.global	FtlWrite
	.syntax unified
	.thumb


// restore stack
        cbnz            w2, 2f

        ret

2:
        ldr             w8, [x5], #4                // load filterPos
        lsl             w8, w8, #1
        add             x9, x3, w8, uxtw            // src + filterPos
        ld1             {v0.4h}, [x9]               // load 4 * uint16_t
        ld1             {v31.4h}, [x4], #8

        uxtl            v0.4s, v0.4h
        sxtl            v31.4s, v31.4h
        subs            w2, w2, #1
        mul             v5.4s, v0.4s, v31.4s
        addv            s0, v5.4s
        sshl            v0.4s, v0.4s, v17.4s
        smin            v0.4s, v0.4s, v18.4s
        st1             {v0.s}[0], [x1], #4
        cbnz            w2, 2b                      // if iterations remain jump to beginning

        ret
endfunc

function ff_hscale16to19_X8_neon_asm, export=1
        // w0               int shift
        // x1               int32_t *dst
        // w2               int dstW
        // x3               const uint8_t *src // treat it as uint16_t *src
        // x4               const uint16_t *filter
        // x5               const int32_t *filterPos
        // w6               int filterSize

        movi            v20.4s, #1
        movi            v21.4s, #1
        shl             v20.4s, v20.4s, #19
        sub             v20.4s, v20.4s, v21.4s
        dup             v21.4s, w0
        neg             v21.4s, v21.4s

        sbfiz           x7, x6, #1, #32             // filterSize*2 (*2 because int16)
1:      ldr             w8, [x5], #4                // filterPos[idx]
        ldr             w10, [x5], #4               // filterPos[idx + 1]
        lsl             w8, w8, #1
        ldr             w11, [x5], #4               // filterPos[idx + 2]
        ldr             w9, [x5], #4                // filterPos[idx + 3]
        mov             x16, x4                     // filter0 = filter
        lsl             w11, w11, #1
        add             x12, x16, x7                // filter1 = filter0 + filterSize*2
        lsl             w9, w9, #1
        add             x13, x12, x7                // filter2 = filter1 + filterSize*2
        lsl             w10, w10, #1
        add             x4, x13, x7                 // filter3 = filter2 + filterSize*2
        movi            v0.16b, #0                  // val sum part 1 (for dst[0])
        movi            v1.16b, #0                  // val sum part 2 (for dst[1])
        movi            v2.16b, #0                  // val sum part 3 (for dst[2])
        movi            v3.16b, #0                  // val sum part 4 (for dst[3])
        add             x17, x3, w8, uxtw           // srcp + filterPos[0]


/*
 * AppArmor security module
 *
 * This file contains basic common functions used in AppArmor
 *
 * Copyright (C) 1998-2008 Novell/SUSE
 * Copyright 2009-2010 Canonical Ltd.
 *
 * 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, version 2 of the
 * License.
 */

#include <linux/mm.h>
#include <linux/slab.h>
#include <linux/string.h>
#include <linux/vmalloc.h>

#include "include/audit.h"
#include "include/apparmor.h"

/**
 * aa_split_fqname - split a fqname into a profile and namespace name
 * @fqname: a full qualified name in namespace profile format (NOT NULL)
 * @ns_name: pointer to portion of the string containing the ns name (NOT NULL)
 *
 * Returns: profile name or NULL if one is not specified
 *
 * Split a namespace name from a profile name (see policy.c for naming
 * description).  If a portion of the name is missing it returns NULL for
 * that portion.
 *
 * NOTE: may modify the @fqname string.  The pointers returned point
 *       into the @fqname string.
 */
char *aa_split_fqname(char *fqname, char **ns_name)
{
	char *name = strim(fqname);

	*ns_name = NULL;
	if (name[0] == ':') {
		char *split = strchr(&name[1], ':');
		*ns_name = skip_spaces(&name[1]);
		if (split) {
			/* overwrite ':' with \0 */
			*split = 0;
			name = skip_spaces(split + 1);
		} else
			/* a ns name without a following profile is allowed */
			name = NULL;
	}
	if (name && *name == 0)
		name = NULL;

	return name;
}

/**
 * aa_info_message - log a none profile related status message
 * @str: message to log
 */
void aa_info_message(const char *str)
{
	if (audit_enabled) {
		struct common_audit_data sa;
		struct apparmor_audit_data aad = {0,};
		sa.type = LSM_AUDIT_DATA_NONE;
		sa.aad = &aad;
		aad.info = str;
		aa_audit_msg(AUDIT_APPARMOR_STATUS, &sa, NULL);
	}
	printk(KERN_INFO "AppArmor: %s\n", str);
}

/**
 * kvmalloc - do allocation preferring kmalloc but falling back to vmalloc
 * @size: size of allocation
 *
 * Return: allocated buffer or NULL if failed
 *
 * It is possible that policy being loaded from the user is larger than
 * what can be allocated by kmalloc, in those cases fall back to vmalloc.
 */
void *kvmalloc(size_t size)
{
	void *buffer = NULL;

	if (size == 0)
		return NULL;

	/* do not attempt kmalloc if we need more than 16 pages at once */
	if (size <= (16*PAGE_SIZE))
		buffer = kmalloc(size, GFP_NOIO | __GFP_NOWARN);
	if (!buffer) {
		/* see kvfree for why size must be at least work_struct size
		 * when allocated via vmalloc
		 */
		if (size < sizeof(struct work_struct))
			size = sizeof(struct work_struct);
		buffer = vmalloc(size);
	}
	return buffer;
}


                    tbBangsal.setValueAt(hppobatranap,pilih,74);
                    tbBangsal.setValueAt(returobat,pilih,75);
                    tbBangsal.setValueAt(tambahanbiaya,pilih,76);
                    tbBangsal.setValueAt(potonganbiaya,pilih,77);
                    tbBangsal.setValueAt(kamar,pilih,78);
                    tbBangsal.setValueAt(reseppulang,pilih,79);
                    tbBangsal.setValueAt(harianranap,pilih,80);
                    tbBangsal.setValueAt(registrasi,pilih,81);
                    tbBangsal.setValueAt(serviceranap,pilih,82);
                    tbBangsal.setValueAt(ppnobat,pilih,83);

                    selisih=0;
                    selisih=(Valid.SetAngka(tbBangsal.getValueAt(pilih,10).toString())+Valid.SetAngka(tbBangsal.getValueAt(pilih,6).toString())+Valid.SetAngka(tbBangsal.getValueAt(pilih,7).toString()))-Valid.SetAngka(tbBangsal.getValueAt(pilih,5).toString());
                    if(selisih>=0){
                        tbBangsal.setValueAt(0,pilih,12);
                        tbBangsal.setValueAt(selisih,pilih,13);
                    }else{
                        selisih=( (bhpralan+bhpranap+bhplabralan+bhplabranap+bhpradiologiralan+bhpradiologiranap+bhpoperasiralan+bhpoperasiranap+reseppulang) * ((100-Valid.SetAngka(tabMode.getValueAt(pilih,11).toString()))/100) );
                        rugihppralan=(hppobatralan-(obatralan*(Valid.SetAngka(tabMode.getValueAt(pilih,11).toString())/100)));
                        if(rugihppralan>0){
                            selisih=selisih+rugihppralan;
                        }
                        rugihppranap=((hppobatranap-returobat)-((obatlangsung+obatranap-returobat)*(Valid.SetAngka(tabMode.getValueAt(pilih,11).toString())/100)));
                        if(rugihppranap>0){
                            selisih=selisih+rugihppranap;
                        }
                        tbBangsal.setValueAt(selisih,pilih,12);
                        tbBangsal.setValueAt(0,pilih,13);
                    }
                }else{
                    JOptionPane.showMessageDialog(null,"Ditemukan perbedaan Total Biaya pada closing billing,\nsilahkan cek data billing dengan Hapus Nota Salah... !!! ");
                    tbBangsal.setValueAt(false,pilih,0);
                    tbBangsal.setValueAt(null,pilih,10);
                    tbBangsal.setValueAt(0,pilih,11);
                    tbBangsal.setValueAt(0,pilih,16);
                    tbBangsal.setValueAt(0,pilih,17);
                    tbBangsal.setValueAt(0,pilih,18);
                    tbBangsal.setValueAt(0,pilih,19);
                    tbBangsal.setValueAt(0,pilih,20);
                    tbBangsal.setValueAt(0,pilih,21);
                    tbBangsal.setValueAt(0,pilih,22);
                    tbBangsal.setValueAt(0,pilih,23);
                    tbBangsal.setValueAt(0,pilih,24


1_camera.html#ab3f35ec6484b5b14ed1d67fda34e42f8">   29    void SetLayerMask(uint32_t layer_mask) { this->layer_mask = layer_mask; }

   30

   31    virtual void Update() = 0;

   32    virtual ~Camera();

   33protected:

   34    vec3 position = {0.0f, 0.0f, 0.0f};

   35    quat rotation = {1.0f, 0.0f, 0.0f, 0.0f};

</


/*
 *   This file is part of DroneBridge: https://github.com/DroneBridge/ESP32
 *
 *   Copyright 2024 Wolfgang Christl
 *
 *   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.
 *
 */

#ifndef DB_ESP32_DB_SERIAL_H
#define DB_ESP32_DB_SERIAL_H

#include "msp_ltm_serial.h"
#include "db_esp32_control.h"

#define UART_NUM UART_NUM_1             // The UART interface of the ESP32 we use
#define DB_SERIAL_READ_TIMEOUT_MS_DEFAULT  50      // Serial read timeout for transparent and MAVLink mode, after that the packet will be sent over the air even when the max. packet size was not reached.

enum DB_MAVLINK_DATA_ORIGIN {
    DB_MAVLINK_DATA_ORIGIN_SERIAL,
    DB_MAVLINK_DATA_ORIGIN_RADIO
};

typedef union {
    float f;
    uint8_t uint8;
    int8_t int8;
    uint16_t uint16;
    int16_t int16;
    uint32_t uint32;
    int32_t int32;
} float_int_union;

int open_serial_socket();
void write_to_serial(const uint8_t data_buffer[], unsigned int data_length);
void db_parse_msp_ltm(int tcp_clients[], udp_conn_list_t *udp_connection, uint8_t msp_message_buffer[],
                      unsigned int *serial_read_bytes,
                      msp_ltm_port_t *db_msp_ltm_port);
void db_read_serial_parse_mavlink(int *tcp_clients, udp_conn_list_t *udp_conns, uint8_t *serial_buffer, unsigned int *serial_buff_pos);
void db_read_serial_parse_transparent(int tcp_clients[], udp_conn_list_t *udp_connection, uint8_t serial_buffer[],
                                      unsigned int *serial_read_bytes);
void db_parse_mavlink_from_radio(int *tcp_clients, udp_conn_list_t *udp_conns, uint8_t *buffer, int bytes_read);
void db_route_mavlink_response(uint8_t *buffer, uint16_t length, enum DB_MAVLINK_DATA_ORIGIN origin, int *tcp_clients,
                               udp_conn_list_t *udp_conns);

#endif //DB_ESP32_DB_SERIAL_H


rthandTest extends PubPackageResolutionTest {
  void assertHasDependentDotShorthand() async {
    var initializer = findNode.singleVariableDeclaration.initializer;
    expect(hasDependentDotShorthand(initializer!), isTrue);
  }

  void assertHasNoDependentDotShorthand() async {
    var initializer = findNode.singleVariableDeclaration.initializer;
    expect(hasDependentDotShorthand(initializer!), isFalse);
  }

  test_constructorInvocation() async {
    await assertNoErrorsInCode(r'''
class A<X> {
  A(X x);
  A.named(X x);
}

A<A> a = A(.named(null));
''');
    assertHasDependentDotShorthand();
  }

  test_constructorInvocation_explicitTypeArgument() async {
    await assertNoErrorsInCode(r'''
class A<X> {
  A(X x);
  A.named(X x);
}

A<A> a = A<A>(.named(null));
''');
    assertHasNoDependentDotShorthand();
  }

  test_constructorInvocation_nested() async {
    await assertNoErrorsInCode(r'''
class A<X> {
  A(X x);
  A.named(X x);
}

X id<X>(X x) => x;

A<A> a = A(id(.named(null)));
''');
    assertHasDependentDotShorthand();
  }

  test_constructorInvocation_noTypeParametersInParameter() async {
    await assertNoErrorsInCode(r'''
class A<X> {
  A(int x);
}

A<String> a = A(.parse('0'));
''');
    assertHasNoDependentDotShorthand();
  }

  test_functionExpression() async {
    await assertNoErrorsInCode(r'''
enum E { a, b, c }

E Function() e = () => .a;
''');
    assertHasDependentDotShorthand();
  }

  test_functionExpression_list() async {
    await assertNoErrorsInCode(r'''
enum E { a, b, c }

List<E> Function() e = () => [.a];
''');
    assertHasDependentDotShorthand();
  }

  test_list() async {
    await assertNoErrorsInCode(r'''
enum E { a, b, c }

List<E> e = [.b];
''');
    assertHasDependentDotShorthand();
  }

  test_map() async {
    await assertNoErrorsInCode(r'''
enum E { a, b, c }

Map<String, E> e = {'test': .b};
''');
    assertHasDependentDotShorthand();
  }

  test_methodInvocation() async {
    await assertNoErrorsInCode(r'''
enum E { a, b, c }
T f<T>(T t) => t;

E e = f(.a);
''');
    assertHasDependentDotShorthand();
  }

  test_methodInvocation_filterTypeArguments() async {
    await assertNoErrorsInCode(r'''
class A {
  A.named();
}

X id<X>(X x) => x;

bar<T extends A>(T t) {
  Map<T, S> baz<S>(T t, S s) => {t: s};
  Map<T, A> m = baz(id(id(id(id(id(id(t)))))), .named());
  print(m);
}
''');
    assertHasDependentDotShorthand();
  }

  test_methodInvocation_functionType_parameter_blockBody() async {
    await assertNoErrorsInCode(r'''
enum E { a, b, c }

S f<S>(S Function() s) => s();

T t<T>(T t) => t;

E e = f(() { return t(.a); });
''');
    assertHasDependentDotShorthand();
  }

  test_methodInvocation_functionType_parameter_blockBody_independent() async {
    await assertNoErrorsInCode(r'''
enum E { a, b, c }

S f<S>(S Function() s) => s();

E eFn(E e) => e;

E e = f(() { return eFn(.a); });
''');
    assertHasNoDependentDotShorthand();
  }

  test_methodInvocation


board--featured::after{bottom:0}}@media all and (max-width:420px){.article__content{margin-top:0}}.article__content video{max-width:100%}.article__content [data-src],[data-src]{display:block;width:100%}.article__content [data-src]:not([data-component]){min-height:350px}.article__content .job-board--featured{padding-top:1.5em;margin-top:-.2em}@media all and (min-width:1025px){.article__content .job-board--featured{width:57%;margin-right:-74%;float:right}}@media (max-width:64em){.article__content .job-board--featured{padding-bottom:2em}}.article__content .job-board--featured h4{margin-top:0}.article__related-posts--mini{position:relative;padding:30em 0;padding-top:1.5em;font-size:.9em}.article__related-posts--mini h4{color:#666;font-size:.9em;font-weight:400}@media (max-width:64em){.article__related-posts--mini{padding:2.5em 0}}@media all and (max-width:1025px){.article .article__related-posts--mini::after,.article .article__related-posts--mini::before{content:'';display:block;position:absolute;margin-top:.75em;margin-bottom:.75em;height:7px;width:100%;background:#d33a2c;background:#d33a2c;border-radius:11px}.article .article__related-posts--mini::before{top:0}.article .article__related-posts--mini::after{bottom:0}}@media (max-width:64em){.article__related-posts--mini{padding-top:2em}}@media all and (min-width:1025px){.article__content .article__related-posts--mini{width:57%;margin-right:-74%;float:right}}.article__content .article__related-posts--mini h4{margin-top:.1em}a.heading-hash{background:0 0;padding:0;position:absolute;left:-25px;top:0;width:1em;height:1em}@media all and (max-width:840px){a.heading-hash{position:static}}.article__content{line-height:1.5;padding:0}.drop-caps+p::first-line{font-weight:700;font-variant:all-small-caps;text-transform:lowercase;letter-spacing:.5px;font-size:1.1em}.drop-caps{width:calc(96px + 1vw);height:calc(120px + 4vw);float:left;margin-right:1.5em;position:relative;left:calc(-1.3em - .5vw);top:.5vw}@media all and (min-width:500px){.drop-caps{width:150px;height:186px;min-width:100px;margin-left:0}}@media screen and (min-width:64em){.drop-caps{display:none}}.drop-caps img{max-width:100%}.drop-caps img:nth-of-type(2){position:absolute;bottom:0;right:-40px;width:75%}.article__tags{margin:1em 0;padding-left:0}.article__tags ul{padding-left:0;list-style-image:none;margin:0}.article__tags ul li{padding-left:0}.article__tag{font-size:calc(.8em + .35vw);font-weight:700;margin-right:.75em;display:inline-block;white-space:nowrap;padding-left:0;font-family:-apple-system,Arial,BlinkMacSystemFont,Roboto Slab,Droid Serif,Segoe UI,Ubuntu,Cantarell,Georgia,serif}.wf-loaded-stage2 .article__tag{font-family:Mija}.article__t


# NVMe initiator related facts collection for Ansible.
#
# This file is part of Ansible
#
# Ansible 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.
#
# Ansible 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 Ansible.  If not, see <http://www.gnu.org/licenses/>.

from __future__ import (absolute_import, division, print_function)
__metaclass__ = type

import sys
import subprocess

from ansible.module_utils.facts.utils import get_file_content
from ansible.module_utils.facts.network.base import NetworkCollector

class NvmeInitiatorNetworkCollector(NetworkCollector):
    name = 'nvme'
    _fact_ids = set()

    def collect(self, module=None, collected_facts=None):
        """
        Currently NVMe is only supported in some Linux distributions.
        If NVMe is configured on the host then a file will have been created
        during the NVMe driver installation. This file holds the unique NQN
        of the host.

        Example of contents of /etc/nvme/hostnqn:

        # cat /etc/nvme/hostnqn
        nqn.2014-08.org.nvmexpress:fc_lif:uuid:2cd61a74-17f9-4c22-b350-3020020c458d

        """

        nvme_facts = {}
        nvme_facts['hostnqn'] = ""
        if sys.platform.startswith('linux'):
            for line in get_file_content('/etc/nvme/hostnqn', '').splitlines():
                if line.startswith('#') or line.startswith(';') or line.strip() == '':
                    continue
                if line.startswith('nqn.'):
                    nvme_facts['hostnqn'] = line
                    break
        return nvme_facts


		defaultAbilityDurations[ability.name] = ability.cooldown
		}
		val ao = abilityOverride
		if (ability == null || (ao != ability.name && ao != null)) {
			ability = PickaxeAbilityData(ao ?: return, defaultAbilityDurations[ao] ?: 120.seconds)
		}
		event.context.matrices.pushMatrix()
		event.context.matrices.translate(MC.window.scaledWidth / 2F, MC.window.scaledHeight / 2F)
		event.context.matrices.scale(TConfig.cooldownScale.toFloat(), TConfig.cooldownScale.toFloat())
		RenderCircleProgress.renderCircle(
			event.context, Identifier.of("firmament", "textures/gui/circle.png"),
			getCooldownPercentage(ability.name, ability.cooldown).toFloat(),
			0f, 1f, 0f, 1f
		)
		event.context.matrices.popMatrix()
	}
}
@file:OptIn(ExperimentalContracts::class)

package moe.nea.firmament.features.inventory.storageoverlay

import kotlin.contracts.ExperimentalContracts
import kotlin.contracts.contract
import net.minecraft.client.gui.screen.Screen
import net.minecraft.client.gui.screen.ingame.GenericContainerScreen
import net.minecraft.screen.GenericContainerScreenHandler
import moe.nea.firmament.util.ifMatches
import moe.nea.firmament.util.unformattedString

/**
 * A handle representing the state of the "server side" screens.
 */
sealed interface StorageBackingHandle {

    sealed interface HasBackingScreen {
        val handler: GenericContainerScreenHandler
    }

    /**
     * The main storage overview is open. Clicking on a slot will open that page. This page is accessible via `/storage`
     */
    data class Overview(override val handler: GenericContainerScreenHandler) : StorageBackingHandle, HasBackingScreen

    /**
     * An individual storage page is open. This may be a backpack or an enderchest page. This page is accessible via
     * the [Overview] or via `/ec <index + 1>` for enderchest pages.
     */
    data class Page(override val handler: GenericContainerScreenHandler, val storagePageSlot: StoragePageSlot) :
        StorageBackingHandle, HasBackingScreen

    companion object {
        private val enderChestName = "^Ender Chest (?:✦ )?\\(([1-9])/[1-9]\\)$".toRegex()
        private val backPackName = "^.+Backpack (?:✦ )?\\(Slot #([0-9]+)\\)$".toRegex()

        /**
         * Parse a screen into a [StorageBackingHandle]. If this returns null it means that the screen is not
         * representable as a [StorageBackingHandle], meaning another screen is open, for example the enderchest icon
         * selection screen.
         */
        @OptIn(ExperimentalContracts::class)
        fun fromScreen(screen: Screen?): StorageBackingHandle? {
	        contract {
		        returnsNotNull() implies (screen != null)
	        }
            if (screen == null) return null
            if (screen !is GenericContainerScreen) return null
            val title = screen.title.unformattedString
            if (title == "Storage") return Overview(screen.screenHandler)
            return title.ifMatches(enderChestName) {
                Page(screen.screenHandler, StoragePageSlot.ofEnderChestPage(it.groupValues[1].toInt()))
            } ?: title.ifMatches(backPackName) {
                Page(screen.screenHandler, StoragePageSlot.ofBackPackPage(it.groupValues[1].toInt()))
            }


%,80%", ["--margin"] = "0,0" },
  previewers    = {
    cat = {
      cmd   = "cat",
      args  = "-n",
      _ctor = previewers.fzf.cmd,
    },
    bat = {
      -- reduce startup time by deferring executable check to previewer constructor (#970)
      cmd   = function() return vim.fn.executable("batcat") == 1 and "batcat" or "bat" end,
      -- args  = "--color=always --style=default",
      args  = "--color=always --style=numbers,changes",
      _ctor = previewers.fzf.bat_async,
    },
    bat_native = {
      cmd   = function() return vim.fn.executable("batcat") == 1 and "batcat" or "bat" end,
      args  = "--color=always --style=numbers,changes",
      -- NOTE: no support for `bat_native` on Windows, it's a hassle for no real
      -- benefit, native previewers will be removed from the code at one point
      _ctor = utils._if_win(previewers.fzf.bat_async, previewers.fzf.bat),
    },
    head = {
      cmd   = "head",
      args  = nil,
      _ctor = previewers.fzf.head,
    },
    git_diff = {
      pager         = M._preview_pager_fn,
      cmd_deleted   = "git diff --color HEAD --",
      cmd_modified  = "git diff --color HEAD",
      cmd_untracked = "git diff --color --no-index /dev/null",
      -- TODO: modify previewer code to accept table cmd
      -- cmd_deleted   = { "git", "diff", "--color", "HEAD", "--" },
      -- cmd_modified  = { "git", "diff", "--color", "HEAD" },
      -- cmd_untracked = { "git", "diff", "--color", "--no-index", "/dev/null" },
      _fn_git_icons = function() return M.globals.git.icons end,
      _ctor         = previewers.fzf.git_diff,
    },
    man = {
      _ctor = previewers.builtin.man_pages,
      cmd = function() return M._man_cmd_fn() end,
    },
    man_native = {
      _ctor = previewers.fzf.man_pages,
      cmd = function() return M._man_cmd_fn(true) end,
    },
    help_tags = { _ctor = previewers.builtin.help_tags },
    help_native = { _ctor = previewers.fzf.help_tags },
    swiper = { _ctor = previewers.swiper.default },
    builtin = {
      syntax            = true,
      syntax_delay      = 0,
      syntax_limit_l    = 0,
      syntax_limit_b    = 1024 * 1024,      -- 1MB
      limit_b           = 1024 * 1024 * 10, -- 10MB
      treesitter        = {
        enabled = true,
        disabled = {},
        -- nvim-treesitter-context config options
        -- https://github.com/nvim-treesitter/nvim-treesitter-context
        context = { max_lines = 1, trim_scope = "inner" }
      },
      ueberzug_scaler   = "cover",
      title_fnamemodify = function(s) return path.tail(s) end,
      render_markdown   = { enabled = true, filetypes = { ["markdown"] = true } },
      snacks_image      = { enabled = true, render_inline = true },
      _ctor             = previewers.builtin.buffer_or_file,
    },
    codeaction = {
      _ctor     = previewers.builtin.codeaction,
      diff_opts = { ctxlen = 3 },
    },
    codeaction_native = {
      _ctor     = previewers.fzf.codeaction,
      diff_opts = { ctxlen = 3 },
      pager     = M._preview_pager_fn,
    },
  },
  formatters    = {
    path = {
      filename_first = {
        -- <Tab> is used as the invisible space between the parent and