::from_raw(Box::into_raw(boxed))
        }
    }

    use super::PtrAPI;
    impl<T: PtrValue> PtrAPI<T> for Ptr<T> {
        fn unptr(self) -> T {
            *unsafe { Box::from_raw(self.into_raw()) }
        }
    }

    #[cfg(test)]
    mod tests {
        use super::{Ptr, PtrAPI};
        use crate::{Node, Token};

        #[test]
        fn test_ptr_token() {
            fn make() -> Token {
                Token::new(
                    280,
                    crate::Bytes::new(crate::containers::ExternalList::from(vec![97, 98, 99])),
                    crate::Loc::new(3, 4),
                    crate::LexState { value: 1 },
                    crate::LexState { value: 2 },
                )
            }

            let ptr = Ptr::new(make());
            assert_eq!(ptr.as_ref(), &make());
            assert_eq!(ptr.clone(), Ptr::new(make()));
            assert_eq!(ptr.unptr(), make());
        }

        #[test]
        fn test_ptr_node() {
            fn make() -> Node {
                Node::new_file(crate::Loc::new(1, 2))
            }

            let ptr = Ptr::new(make());
            assert_eq!(ptr.as_ref(), &make());
            assert_eq!(ptr.clone(), Ptr::new(make()));
            assert_eq!(ptr.unptr(), make());
        }
    }
}

/// Shared Ptr API, implemented for both ExternalPtr<T> and Box<T>
pub trait PtrAPI<T> {
    /// Consumes `self` and returns value located on the stack
    /// `Deref` on `Box` is very special, we can't emulate if for our own `Ptr<T>`
    fn unptr(self) -> T
    where
        Self: Sized;
}
<reponame>topcoder1208/contracts
use std::fmt;

use cosmwasm_std::{Addr, Decimal, Deps, StdError, StdResult, Storage, Uint128};
use cw_storage_plus::{Bound, Item, Map};
use schemars::JsonSchema;
use serde::{Deserialize, Serialize};

use valkyrie::common::{OrderBy, Execution, ExecutionMsg};
use valkyrie::governance::enumerations::{PollStatus, VoteOption};
use valkyrie::governance::query_msgs::PollResponse;

use crate::common::states::load_available_balance;
use crate::staking::states::{StakerState, StakingState};

const MAX_LIMIT: u32 = 30;
const DEFAULT_LIMIT: u32 = 10;

const POLL_CONFIG: Item<PollConfig> = Item::new("poll-config");

#[derive(Serialize, Deserialize, Clone, Debug, PartialEq, JsonSchema)]
pub struct PollConfig {
    pub quorum: Decimal,
    pub threshold: Decimal,
    pub voting_period: u64,
    pub execution_delay_period: u64,
    pub proposal_deposit: Uint128,
    pub snapshot_period: u64,
}

impl PollConfig {
    pub fn save(&self, storage: &mut dyn Storage) -> StdResult<()> {
        POLL_CONFIG.save(storage, self)
    }

    pub fn load(storage: &dyn Storage) -> StdResult<PollConfig> {
        POLL_CONFIG.load(storage)
    }
}

const POLL_STATE: Item<PollState> = Item::new("poll-state");

#[derive(Serialize, Deserialize, Clone, Debug, PartialEq, JsonSchema)]
pub struct PollState {
    pub poll_count: u64,
    pub total_deposit: Uin


radius: 4px;
    margin-bottom: 1rem;
}

.field-info i {
    color: #3b82f6;
    margin-right: 0.5rem;
}

[data-theme="dark"] .field-warning {
    background: rgba(251, 191, 36, 0.15);
    border-left: 4px solid #fbbf24;
    color: #fcd34d;
    box-shadow: 0 0 20px rgba(251, 191, 36, 0.1);
}

[data-theme="dark"] .field-warning i {
    color: #fbbf24;
    text-shadow: 0 0 10px rgba(251, 191, 36, 0.5);
}

[data-theme="dark"] .field-info {
    background: rgba(6, 182, 212, 0.15);
    border-left: 4px solid var(--accent-color);
    color: #67e8f9;
    box-shadow: 0 0 20px rgba(6, 182, 212, 0.1);
}

[data-theme="dark"] .field-info i {
    color: var(--accent-color);
    text-shadow: 0 0 10px rgba(6, 182, 212, 0.5);
}

/* ============================================================================ */
/* Field Mapping Button Animations */
/* ============================================================================ */

.btn-auto-map {
    background: var(--gradient-primary);
    border: none;
    color: white;
    transition: all 0.3s ease;
}

.btn-auto-map:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

[data-theme="dark"] .btn-auto-map {
    background: var(--gradient-primary);
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.3);
}

[data-theme="dark"] .btn-auto-map:hover {
    box-shadow: 0 0 25px rgba(168, 85, 247, 0.5),
                var(--shadow-lg);
    transform: translateY(-2px) scale(1.02);
}

/* ============================================================================ */
/* Responsive Design for Field Mapping */
/* ============================================================================ */

@media (max-width: 768px) {
    .field-mapping-row {
        flex-direction: column;
        align-items: stretch;
    }

    .field-arrow {
        transform: rotate(90deg);
        margin: 0.5rem 0;
    }

    .mapping-preview-card {
        padding: 0.75rem;
    }

    .compatibility-score-container {
        padding: 0.75rem;
    }
}
/* Improve code block readability */
pre > code {
  padding: 1em;
  border-radius: 5px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}

/* Better table styling */
table {
  width: 100%;
  margin: 1em 0;
  border-collapse: collapse;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

th {
  background-color: #f2f2f2;
  font-weight: bold;
}

th,
td {
  padding: 10px;
  border: 1px solid #ddd;
}

/* Improve navigation readability */
.sidebar {
  padding: 1em;
  border-right: 1px solid #eee;
  box-shadow: 2px 0 5px rgba(0, 0, 0, 0.05);
}

.chapter {
  padding: 0.5em 0;
}

.chapter li {
  margin: 6px 0;
}

/* Enhanced overall styling */
body {
  line-height: 1.6;
}

h1, h2, h3, h4 {
  color: #2c3e50;
  margin-top: 1.5em;
  m


NESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 */

#include "FilterModelConfig.h"

#include <vector>
#include <cstdint>

namespace reSIDfp
{

FilterModelConfig::FilterModelConfig(
    double vvr,
    double c,
    double vdd,
    double vth,
    double ucox,
    const Spline::Point *opamp_voltage,
    int opamp_size
) :
    C(c),
    Vdd(vdd),
    Vth(vth),
    Vddt(Vdd - Vth),
    vmin(opamp_voltage[0].x),
    vmax(std::max(Vddt, opamp_voltage[0].y)),
    denorm(vmax - vmin),
    norm(1.0 / denorm),
    N16(norm * UINT16_MAX),
    voice_voltage_range(vvr),
    mixer(new unsigned short[mixer_offset<8>::value]),
    summer(new unsigned short[summer_offset<5>::value]),
    volume(new unsigned short[16 * (1 << 16)]),
    resonance(new unsigned short[16 * (1 << 16)])
{
    setUCox(ucox);

    // Convert op-amp voltage transfer to 16 bit values.

    std::vector<Spline::Point> scaled_voltage(opamp_size);

    for (int i = 0; i < opamp_size; i++)
    {
        scaled_voltage[i].x = N16 * (opamp_voltage[i].x - opamp_voltage[i].y) / 2.;
        // We add 32768 to get a positive number in the range [0-65535]
        scaled_voltage[i].x += static_cast<double>(1u << 15);

        scaled_voltage[i].y = N16 * (opamp_voltage[i].x - vmin);
    }

    // Create lookup table mapping capacitor voltage to op-amp input voltage:

    Spline s(scaled_voltage);

    for (int x = 0; x < (1 << 16); x++)
    {
        const Spline::Point out = s.evaluate(x);
        // When interpolating outside range the first elements may be negative
        opamp_rev[x] = out.x > 0. ? to_ushort(out.x) : 0;
    }
}

FilterModelConfig::~FilterModelConfig()
{
    delete [] mixer;
    delete [] summer;
    delete [] volume;
    delete [] resonance;
}

void FilterModelConfig::setUCox(double new_uCox)
{
    uCox = new_uCox;
    currFactorCoeff = denorm * (uCox / 2. * 1.0e-6 / C);
}

} // namespace reSIDfp
/*
 * This file is part of libsidplayfp, a SID player engine.
 *
 * Copyright 2011-2025 Leandro Nini <drfiemost@users.sourceforge.net>
 * Copyright 2007-2010 Antti Lankila
 * Copyright 2004 Dag Lem <resid@nimrod.no>
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; either version 2 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street


= 0; i < b.N; i++ {
		txs[i] = transaction(uint64(i), 100000, key)
	}
	// Benchmark importing the transactions into the queue
	b.ResetTimer()
	for _, tx := range txs {
		pool.AddRemote(tx)
	}
}

// Benchmarks the speed of batched transaction insertion.
func BenchmarkPoolBatchInsert100(b *testing.B)   { benchmarkPoolBatchInsert(b, 100) }
func BenchmarkPoolBatchInsert1000(b *testing.B)  { benchmarkPoolBatchInsert(b, 1000) }
func BenchmarkPoolBatchInsert10000(b *testing.B) { benchmarkPoolBatchInsert(b, 10000) }

func benchmarkPoolBatchInsert(b *testing.B, size int) {
	// Generate a batch of transactions to enqueue into the pool
	pool, key := setupTxPool()
	defer pool.Stop()

	account, _ := deriveSender(transaction(0, 0, key))
	pool.currentState.AddBalance(account, big.NewInt(1000000))

	batches := make([]types.Transactions, b.N)
	for i := 0; i < b.N; i++ {
		batches[i] = make(types.Transactions, size)
		for j := 0; j < size; j++ {
			batches[i][j] = transaction(uint64(size*i+j), 100000, key)
		}
	}
	// Benchmark importing the transactions into the queue
	b.ResetTimer()
	for _, batch := range batches {
		pool.AddRemotes(batch)
	}
}
// Copyright 2016 The go-ethereum Authors
// This file is part of the go-ethereum library.
//
// The go-ethereum library is free software: you can redistribute it and/or modify
// it under the terms of the GNU Lesser General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// The go-ethereum library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with the go-ethereum library. If not, see <http://www.gnu.org/licenses/>.

// This file contains some shares testing functionality, common to  multiple
// different files and modules being tested.

package les

import (
	"crypto/rand"
	"math/big"
	"sync"
	"testing"

	"github.com/ethereum/go-ethereum/common"
	"github.com/ethereum/go-ethereum/consensus/ethash"
	"github.com/ethereum/go-ethereum/core"
	"github.com/ethereum/go-ethereum/core/types"
	"github.com/ethereum/go-ethereum/core/vm"
	"github.com/ethereum/go-ethereum/crypto"
	"github.com/ethereum/go-ethereum/eth"
	"github.com/ethereum/go-ethereum/ethdb"
	"github.com/ethereum/go-ethereum/event"
	"github.com/ethereum/go-ethereum/les/flowcontrol"
	"github.com/ethereum/go-ethereum/light"
	"github.com/ethereum/go-ethereum/p2p"
	"github.com/ethereum/go-ethereum/p2p/discover"
	"github.com/ethereum/go-ethereum/params"
)

var (
	testBankKey, _  = crypto.HexToECDSA("b71c71a67e1177ad4e901695e1b4b9ee17ae16c6668d313eac2f96dbcda3f291")
	testBankAddress = crypto.PubkeyToAddress(testBankKey.PublicKey)


#$2A,(a5)+
	clr.b	(a5)
	rts
;
;----------------------------------------------------------------------------
;
T_3C12:	moveq	#-1,d0
T_3C14:	move	d0,d1
T_3C16:	addq	#1,d0
	cmp.b	0(a5,d0),d2
	beq.s	T_3C14
	tst.b	0(a5,d0)
	bne.s	T_3C16
	tst	d1
	rts
;
;----------------------------------------------------------------------------
;
T_3C28:	move.l	patch_area_3_p-cref(a6),a5
	move.l	a5,a4
	move.l	ref_fsel_path_p-cref(a6),a1
T_3C32:	move.b	(a1)+,(a5)+
	bne.s	T_3C32
T_3C36:	cmpa.l	a4,a5
	beq.s	T_3C02
	cmpi.b	#$5C,-$1(a5)
	beq.s	T_3C02
	cmpi.b	#$3A,-$1(a5)
	beq.s	T_3BFE
	subq.l	#1,a5
	bra.s	T_3C36
;
;------------------------------------
;
T_3C4E:	bsr	T_3B0C
	move	$E6(a6),$E2(a6)
	clr	$E6(a6)
	tst	$FE(a6)
	bne.s	T_3C66
	clr	$10A(a6)
T_3C66:	bsr.s	T_3C28
	move.l	ref_fsel_path_p-cref(a6),a5
	moveq	#$5C,d2
	bsr	T_3C12
	bpl.s	T_3C7A
	moveq	#$3A,d2
	bsr	T_3C12
T_3C7A:	lea	1(a5,d1),a3
	clr	d7
	move	#$17,-(sp)
	pea	(a4)
	move	#$4E,-(sp)
	trap	#1			;Fsfirst
	addq.l	#8,sp
	bra.s	T_3C98
;
;------------------------------------
;
T_3C90:	move	#$4F,-(sp)
	trap	#1			;Fsnext
	addq.l	#2,sp
T_3C98:	tst	d0
	bne.s	T_3CF8
	lea	$1AA(a6),a2
	cmpi.b	#$10,-$1(a2)
	bne.s	T_3CB2
	cmpi.b	#$2E,8(a2)
	beq.s	T_3C90
	bra.s	T_3CCE
;
;------------------------------------
;
T_3CB2:	tst	$B6(a6)
	beq.s	T_3CC2
	move.b	-$1(a2),d0
	andi.b	#6,d0
	bne.s	T_3C90
T_3CC2:	lea	8(a2),a1
	move.l	a3,a0
	bsr	T_3Aa6
	bne.s	T_3C90
T_3CCE:	cmp	$18E(a6),d7
	bcc.s	T_3CE4
	moveq	#$14


/** Tests for InMemoryReader. */
@RunWith(JUnit4.class)
public class InMemoryReaderTest {
  @Rule public ExpectedException expectedException = ExpectedException.none();

  static <T> List<String> encodedElements(List<T> elements, Coder<T> coder) throws Exception {
    List<String> encodedElements = new ArrayList<>();
    for (T element : elements) {
      byte[] encodedElement = encodeToByteArray(coder, element);
      String encodedElementString = byteArrayToJsonString(encodedElement);
      encodedElements.add(encodedElementString);
    }
    return encodedElements;
  }

  <T> void runTestReadInMemory(
      List<T> elements,
      @Nullable Integer startIndex,
      @Nullable Integer endIndex,
      List<T> expectedElements,
      List<Integer> expectedSizes,
      Coder<T> coder)
      throws Exception {
    InMemoryReader<T> inMemoryReader =
        new InMemoryReader<>(encodedElements(elements, coder), startIndex, endIndex, coder);
    ExecutorTestUtils.TestReaderObserver observer =
        new ExecutorTestUtils.TestReaderObserver(inMemoryReader);
    List<T> actualElements = new ArrayList<>();
    try (InMemoryReader<T>.InMemoryReaderIterator iterator = inMemoryReader.iterator()) {
      for (long i = inMemoryReader.startIndex;
          (i == inMemoryReader.startIndex) ? iterator.start() : iterator.advance();
          i++) {
        Assert.assertEquals(
            ReaderTestUtils.approximateProgressAtIndex(i),
            readerProgressToCloudProgress(iterator.getProgress()));
        actualElements.add(iterator.getCurrent());
      }
    }
    assertEquals(expectedElements, actualElements);
    assertEquals(expectedSizes, observer.getActualSizes());
  }

  @Test
  public void testReadAllElements() throws Exception {
    runTestReadInMemory(
        Arrays.asList(33, 44, 55, 66, 77, 88),
        null,
        null,
        Arrays.asList(33, 44, 55, 66, 77, 88),
        Arrays.asList(4, 4, 4, 4, 4, 4),
        BigEndianIntegerCoder.of());
  }

  @Test
  public void testReadElementsFromStart() throws Exception {
    runTestReadInMemory(
        Arrays.asList(33, 44, 55, 66, 77, 88),
        2,
        null,
        Arrays.asList(55, 66, 77, 88),
        Arrays.asList(4, 4, 4, 4),
        BigEndianIntegerCoder.of());
  }

  @Test
  public void testReadElementsToEnd() throws Exception {
    runTestReadInMemory(
        Arrays.asList(33, 44, 55, 66, 77, 88),
        null,
        3,
        Arrays.asList(33, 44, 55),
        Arrays.asList(4, 4, 4),
        BigEndianIntegerCoder.of());
  }

  @Test
  public void testReadElementsFromStartToEnd() throws Exception {
    runTestReadInMemory(
        Arrays.asList(33, 44, 55, 66, 77, 88),
        2,
        5,
        Arrays.asList(55, 66, 77),
        Arrays.asList(4, 4, 4),
        BigEndianIntegerCoder.of());
  }

  @Test
  public void testReadElementsOffEnd() throws Exception {
    runTestReadInMemory(
        Arrays.asList(33, 44, 55, 66, 77, 88),
        null,
        30,
        Arrays.asList(33, 44, 55, 66, 77, 88),
        Arrays.asList(4, 4, 4, 4, 4, 4),
        BigEndianIntegerCoder.of());
  }

  @Test
  public void testReadElementsFromStartPastEnd() throws Exception {
    runTestReadInMemory(
        Arrays.asList(33, 44, 55, 66, 77, 88),
        20,
        null,
        Arrays.<Integer>asList(),
        Arrays.<Integer>asList(),
        BigEndianIntegerCoder.of());
  }

  @Test
  public void testReadElementsFromStartToEnd


# sh testcase for and
# mach:	 all
# as(sh):	-defsym sim_cpu=0
# as(shdsp):	-defsym sim_cpu=1 -dsp

	.include "testutils.inc"

	.align 2
_x:	.long	0xa5a5a5a5
_y:	.long	0x55555555

	start

and_reg_reg_direct:
	set_grs_a5a5
	mov.l	i, r1
	mov.l	j, r2
	and	r1, r2
	test_gr0_a5a5
	assertreg 0xa5a5a5a5 r1
	assertreg 0xa0a0a0a0 r2
	test_gr_a5a5 r3
	test_gr_a5a5 r4
	test_gr_a5a5 r5
	test_gr_a5a5 r6
	test_gr_a5a5 r7
	test_gr_a5a5 r8
	test_gr_a5a5 r9
	test_gr_a5a5 r10
	test_gr_a5a5 r11
	test_gr_a5a5 r12
	test_gr_a5a5 r13
	test_gr_a5a5 r14
	bra	and_imm_reg
	nop

	.align	2
i:	.long	0xa5a5a5a5
j:	.long	0xaaaaaaaa

and_imm_reg:
	set_grs_a5a5
	and	#0xff, r0
	assertre


developerGuide {

    }
}

task books {
    doLast {
        books.each { book ->
            println "$book.name -> $book.sourceFile"
        }
    }
}

class DocumentationPlugin implements Plugin<Project> {
    void apply(Project project) {
        def books = project.container(Book)
        books.all {
            sourceFile = project.file("src/docs/$name")
        }
        project.extensions.books = books
    }
}

class Book {
    final String name
    File sourceFile

    Book(String name) {
        this.name = name
    }
}

Output of gradle -q books

> gradle -q books
developerGuide -> /home/user/gradle/samples/userguide/organizeBuildLogic/customPluginWithDomainObjectContainer/src/docs/developerGuide
quickStart -> /home/user/gradle/samples/userguide/organizeBuildLogic/customPluginWithDomainObjectContainer/src/docs/quick-start
userGuide -> /home/user/gradle/samples/userguide/organizeBuildLogic/customPluginWithDomainObjectContainer/src/docs/userGuide

            The Project.container(java.lang.Class) methods create instances of NamedDomainObjectContainer, that have many useful methods for managing and configuring the objects. In order
            to use a type with any of the project.container methods, it MUST expose a property named “name”
            as the unique, and constant, name for the object. The project.container(Class) variant of the container method creates
            new instances by attempting to invoke the constructor of the class that takes a single string argument, which is the desired name of the object.
            See the above link for project.container method variants that allow custom instantiation strategies.

Previous|Contents|<a xmlns:xslthl="http://xslthl.sf.net" href="javaGradle_plugin.html" title="The Java Gradle Plugin Development Plugin - Gradle User


M drive: %s\n",
                        SDL_GetError());
        exit(2);
    }

    status = SDL_CDStatus(cdrom);
    switch (status) {
        case CD_TRAYEMPTY:
            status_str = "tray empty";
            break;
        case CD_STOPPED:
            status_str = "stopped";
            break;
        case CD_PLAYING:
            status_str = "playing";
            break;
        case CD_PAUSED:
            status_str = "paused";
            break;
        case CD_ERROR:
            status_str = "error state";
            break;
    }
    printf("Drive status: %s\n", status_str);
    if ( status >= CD_PLAYING ) {
        int m, s, f;
        FRAMES_TO_MSF(cdrom->cur_frame, &m, &s, &f);
        printf("Currently playing track %d, %d:%2.2d\n",
        cdrom->track[cdrom->cur_track].id, m, s);
    }

Listing the tracks on a CD

    SDL_CD *cdrom;          /* Assuming this has already been set.. */
    int i;
    int m, s, f;

    SDL_CDStatus(cdrom);
    printf("Drive tracks: %d\n", cdrom->numtracks);
    for ( i=0; i<cdrom->numtracks; ++i ) {
        FRAMES_TO_MSF(cdrom->track[i].length, &m, &s, &f);
        if ( f > 0 )
            ++s;
        printf("\tTrack (index %d) %d: %d:%2.2d\n", i,
        cdrom->track[i].id, m, s);
    }

Play an entire CD

    SDL_CD *cdrom;          /* Assuming this has already been set.. */

    // Play entire CD:
    if ( CD_INDRIVE(SDL_CDStatus(cdrom)) )
        SDL_CDPlayTracks(cdrom, 0, 0, 0, 0);

        // Play last track:
        if ( CD_INDRIVE(SDL_CDStatus(cdrom)) ) {
            SDL_CDPlayTracks(cdrom, cdrom->numtracks-1, 0, 0, 0);
        }

        // Play first and second track and 10 seconds of third track:
        if ( CD_INDRIVE(SDL_CDStatus(cdrom)) )
            SDL_CDPlayTracks(cdrom, 0, 0, 2, CD_FPS * 10);

Prev	Home	<TD
WIDTH="33%"
ALIGN="


'',	'',	'',	'',	'',	'',	'',	'',	'3008001',	'',	'',	'2',	'',	'塔尔博特',	'Talbot',	'[{"id":3008001,"pos":2,"enter":2}]',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'2020352',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	''},
{'2020352',	'',	'当然，让你们当警卫的话，那我未免太没眼光了。',	'',	'',	'',	'',	'',	'',	'',	'',	'9942001',	'',	'',	'2',	'',	'市长',	'mayor',	'[{"id":9942001,"pos":2,"enter":2}]',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'2020353',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	''},
{'2020353',	'',	'我不会限制你们的行动，需要多少警力资源尽管提就好。',	'',	'',	'',	'',	'',	'',	'',	'',	'9942001',	'',	'',	'2',	'',	'市长',	'mayor',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'2020354',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	''},
{'2020354',	'',	'相应的，我希望那天一切都能井然有序。',	'',	'',	'',	'',	'',	'',	'',	'',	'9942001',	'',	'',	'2',	'',	'市长',	'mayor',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'2020355',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	''},
{'2020355',	'',	'也就是说，我的工作就是要把那只蜘蛛从不知哪个地穴或者山洞里揪出来咯。',	'',	'',	'',	'',	'',	'',	'',	'',	'1024001',	'',	'',	'2',	'',	'辉砾',	'Pyroxene',	'[{"id":1024001,"pos":2,"enter":2}]',	'',	'7',	'',	'',	'',	'',	'',	'',	'',	'',	'2020356',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	'',	''},
{'2020356',	'',	'挺有意思的嘛，这份工作我就接下了。',	'',	'',	'',	'',	'',	'',	'',	'',	'1024001',


[dimIndex]);
          },
          typedArray: function (dataItem, property, dataIndex, dimIndex) {
            return dataItem[dimIndex];
          }
        };
      }();
      return DataStore;
    }();

    /**
     * [REQUIREMENT_MEMO]:
     * (0) `metaRawOption` means `dimensions`/`sourceHeader`/`seriesLayoutBy` in raw option.
     * (1) Keep support the feature: `metaRawOption` can be specified both on `series` and
     * `root-dataset`. Them on `series` has higher priority.
     * (2) Do not support to set `metaRawOption` on a `non-root-dataset`, because it might
     * confuse users: whether those props indicate how to visit the upstream source or visit
     * the transform result source, and some transforms has nothing to do with these props,
     * and some transforms might have multiple upstream.
     * (3) Transforms should specify `metaRawOption` in each output, just like they can be
     * declared in `root-dataset`.
     * (4) At present only support visit source in `SERIES_LAYOUT_BY_COLUMN` in transforms.
     * That is for reducing complexity in transforms.
     * PENDING: Whether to provide transposition transform?
     *
     * [IMPLEMENTAION_MEMO]:
     * "sourceVisitConfig" are calculated from `metaRawOption` and `data`.
     * They will not be calculated until `source` is about to be visited (to prevent from
     * duplicate calcuation). `source` is visited only in series and input to transforms.
     *
     * [DIMENSION_INHERIT_RULE]:
     * By default the dimensions are inherited from ancestors, unless a transform return
     * a new dimensions definition.
     * Consider the case:
     * ```js
     * dataset: [{
     *     source: [ ['Product', 'Sales', 'Prise'], ['Cookies', 321, 44.21], ...]
     * }, {
     *     transform: { type: 'filter', ... }
     * }]
     * dataset: [{
     *     dimension: ['Product', 'Sales', 'Prise'],
     *     source: [ ['Cookies', 321, 44.21], ...]
     * }, {
     *     transform: { type: 'filter', ... }
     * }]
     * ```
     * The two types of option should have the same behavior after transform.
     *
     *
     * [SCENARIO]:
     * (1) Provide source data directly:
     * ```js
     * series: {
     *     encode: {...},
     *     dimensions: [...]
     *     seriesLayoutBy: 'row',
     *     data: [[...]]
     * }
     * ```
     * (2) Series refer to dataset.
     * ```js
     * series: [{
     *     encode: {...}
     *     // Ignore datasetIndex means `datasetIndex: 0`
     *     // and the dimensions defination in dataset is used
     * }, {
     *     encode: {...},
     *     seriesLayoutBy: 'column',
     *     datasetIndex: 1
     * }]
     * ```
     * (3) dataset transform
     * ```js
     * dataset: [{
     *     source: [...]
     * }, {
     *     source: [...]
     * }, {
     *     // By default from 0.
     *     transform: { type: 'filter', config: {...} }
     * }, {
     *     // Piped.
     *     transform: [
     *         { type: 'filter', config: {...} },
     *         { type: 'sort', config: {...} }
     *     ]
     * }, {
     *     id: 'regressionData',
     *     fromDatasetIndex: 1,
     *     // Third-party transform
     *     transform: { type: 'ecStat:regression', config: {...} }
     * }, {
     *     // retrieve the extra result.
     *     id: 'regressionFormula',
     *     fromDatasetId: 'regressionData',
     *     fromTransformResult: 1
     * }]
     * ```
     */
    var SourceManager = /** @class */function () {
      function SourceManager(sourceHost) {
        // Cached source. Do not repeat calculating if not dirty.
        this._sourceList = [];


A, B>>): Tuple2<Kind<ForSequenceK, A>,
  Kind<ForSequenceK, B>> = arrow.core.extensions.sequence.unzip.Sequence.unzip().run {
  arrow.core.SequenceK(this@unzipWith).unzipWith<A, B, C>(arg1) as
    arrow.core.Tuple2<arrow.Kind<arrow.core.ForSequenceK, A>, arrow.Kind<arrow.core.ForSequenceK,
        B>>
}

/**
 * cached extension
 */
@PublishedApi()
internal val unzip_singleton: SequenceKUnzip = object : arrow.core.extensions.SequenceKUnzip {}

@Deprecated(
  "Receiver Sequence object is deprecated, prefer to turn Sequence functions into top-level functions",
  level = DeprecationLevel.WARNING
)
object Sequence {
  @Suppress(
    "UNCHECKED_CAST",
    "NOTHING_TO_INLINE"
  )
  @Deprecated(
    "Unzip typeclass is deprecated. Use concrete methods on Sequence",
    level = DeprecationLevel.WARNING
  )
  inline fun unzip(): SequenceKUnzip = unzip_singleton
}
package arrow.core.extensions.sequence.alternative

import arrow.Kind
import arrow.core.ForSequenceK
import arrow.core.Option
import arrow.core.extensions.SequenceKAlternative
import kotlin.sequences.Sequence

@JvmName("some")
@Suppress(
  "UNCHECKED_CAST",
  "USELESS_CAST",
  "EXTENSION_SHADOWED_BY_MEMBER",
  "UNUSED_PARAMETER"
)
@Deprecated(
  "@extension kinded projected functions are deprecated",
  ReplaceWith(
    "this.some()",
    "arrow.core.some"
  ),
  DeprecationLevel.WARNING
)
fun <A> Sequence<A>.some(): Sequence<Sequence<A>> =
  arrow.core.extensions.sequence.alternative.Sequence.alternative().run {
    arrow.core.SequenceK(this@some).some<A>() as
      kotlin.sequences.Sequence<kotlin.sequences.Sequence<A>>
  }

@JvmName("many")
@Suppress(
  "UNCHECKED_CAST",
  "USELESS_CAST",
  "EXTENSION_SHADOWED_BY_MEMBER",
  "UNUSED_PARAMETER"
)
@Deprecated(
  "@extension kinded projected functions are deprecated",
  ReplaceWith(
    "this.many()",
    "arrow.core.many"
  ),
  DeprecationLevel.WARNING
)
fun <A> Sequence<A>.many(): Sequence<Sequence<A>> =
  arrow.core.extensions.sequence.alternative.Sequence.alternative().run {
    arrow.core.SequenceK(this@many).many<A>() as
      kotlin.sequences.Sequence<kotlin.sequences.Sequence<A>>
  }

@JvmName("alt")
@Suppress(
  "UNCHECKED_CAST",
  "USELESS_CAST",
  "EXTENSION_SHADOWED_BY_MEMBER",
  "UNUSED_PARAMETER"
)
@Deprecated(
  "@extension kinded projected functions are deprecated",
  ReplaceWith(
    "this + arg1"
  ),
  DeprecationLevel.WARNING
)
infix fun <A> Sequence<A>.alt(arg1: Sequence<A>): Sequence<A> =
  arrow.core.extensions.sequence.alternative.Sequence.alternative().run {
    arrow.core.SequenceK(this@alt).alt<A>(arrow.core.SequenceK(arg1)) as kotlin.sequences.Sequence<A>
  }

@JvmName("orElse")
@Suppress(
  "UNCHECKED_CAST",
  "USELESS_CAST",
  "EXTENSION_SHADOWED_BY_MEMBER",
  "UNUSED_PARAMETER"
)
@Deprecated(
  "@extension kinded projected functions are deprecated",
  ReplaceWith(
    "this + arg1"


e = 30;
      errorHandler.sync(this);
      _la = tokenStream.LA(1)!;
      if (_la == TOKEN_T__1) {
        state = 28;
        match(TOKEN_T__1);
        state = 29;
        _localctx.attr = match(TOKEN_STRING);
      }

      state = 32;
      match(TOKEN_T__2);
      state = 36;
      errorHandler.sync(this);
      _la = tokenStream.LA(1)!;
      while ((((_la) & ~0x3f) == 0 && ((1 << _la) & 536870894) != 0)) {
        state = 33;
        _localctx.content = element();
        state = 38;
        errorHandler.sync(this);
        _la = tokenStream.LA(1)!;
      }
      state = 39;
      match(TOKEN_T__3);
      state = 40;
      match(TOKEN_STRING);
      state = 41;
      match(TOKEN_T__2);
    } on RecognitionException catch (re) {
      _localctx.exception = re;
      errorHandler.reportError(this, re);
      errorHandler.recover(this, re);
    } finally {
      exitRule();
    }
    return _localctx;
  }

  PlainContext plain() {
    dynamic _localctx = PlainContext(context, state);
    enterRule(_localctx, 6, RULE_plain);
    int _la;
    try {
      int _alt;
      state = 50;
      errorHandler.sync(this);
      switch (tokenStream.LA(1)!) {
      case TOKEN_T__0:
      case TOKEN_T__1:
      case TOKEN_T__2:
      case TOKEN_T__4:
      case TOKEN_T__5:
      case TOKEN_T__6:
      case TOKEN_STRING:
        enterOuterAlt(_localctx, 1);
        state = 44;
        errorHandler.sync(this);
        _alt = 1;
        do {
          switch (_alt) {
          case 1:
            state = 43;
            _la = tokenStream.LA(1)!;
            if (!((((_la) & ~0x3f) == 0 && ((1 << _la) & 268435694) != 0))) {
            errorHandler.recoverInline(this);
            } else {
              if ( tokenStream.LA(1)! == IntStream.EOF ) matchedEOF = true;
              errorHandler.reportMatch(this);
              consume();
            }
            break;
          default:
            throw NoViableAltException(this);
          }
          state = 46;
          errorHandler.sync(this);
          _alt = interpreter!.adaptivePredict(tokenStream, 4, context);
        } while (_alt != 2 && _alt != ATN.INVALID_ALT_NUMBER);
        break;
      case TOKEN_T__7:
        enterOuterAlt(_localctx, 2);
        state = 48;
        match(TOKEN_T__7);
        break;
      case TOKEN_T__8:
        enterOuterAlt(_localctx, 3);
        state = 49;
        match(TOKEN_T__8);
        break;
      default:
        throw NoViableAltException(this);
      }
    } on RecognitionException catch (re) {
      _localctx.exception = re;
      errorHandler.reportError(this, re);
      errorHandler.recover(this, re);
    } finally {
      exitRule();
    }
    return _localctx;
  }

  BgmContext bgm() {
    dynamic _localctx = BgmContext(context, state);
    enterRule(_localctx, 8, RULE_bgm);
    int _la;
    try {
      enterOuterAlt(_localctx, 1);
      state = 52;
      _la = tokenStream.LA(1)!;
      if (!(_la == TO


/components/noticebar/brn_marquee_text.dart';
import 'package:flutter/material.dart';

/// 描述: 左边标签，右边按钮的通知
/// 1. 支持十种默认样式
/// 2. 支持设置或者隐藏左右图标
/// 3. 支持跑马灯

class BrnNoticeBarWithButton extends StatelessWidget {
  /// 通知的内容
  final String content;

  /// 通知的背景色
  final Color? backgroundColor;

  /// 通知的文字颜色
  final Color? contentTextColor;

  /// 左边标签的文字
  final String? leftTagText;

  /// 左边标签的文字颜色
  final Color? leftTagTextColor;

  /// 左边标签的背景颜色
  final Color? leftTagBackgroundColor;

  /// 自定义左边的控件
  final Widget? leftWidget;

  ///右边按钮的文字
  final String? rightButtonText;

  ///右边按钮的文字颜色
  final Color? rightButtonTextColor;

  ///右边按钮的边框颜色
  final Color? rightButtonBorderColor;

  /// 自定义右边的控件
  final Widget? rightWidget;

  /// 是否跑马灯
  /// 默认值false
  final bool marquee;

  /// 右边按钮点击回调
  final VoidCallback? onRightButtonTap;

  /// 最小高度。leftWidget、rightWidget 都为空时，限制的最小高度。
  /// 可以通过该属性控制组件高度，内容会自动垂直居中。默认值 54。
  final double minHeight;

  /// 内容的内边距
  final EdgeInsets? padding;

  const BrnNoticeBarWithButton(
      {Key? key,
      required this.content,
      this.backgroundColor,
      this.contentTextColor,
      this.leftTagText,
      this.leftTagBackgroundColor,
      this.leftTagTextColor,
      this.rightButtonBorderColor,
      this.rightButtonText,
      this.rightButtonTextColor,
      this.onRightButtonTap,
      this.marquee = false,
      this.leftWidget,
      this.rightWidget,
      this.padding,
      this.minHeight = 54})
      : super(key: key);

  @override
  Widget build(BuildContext context) {
    // 如果没有自定义视图，设置最小高度
    return Container(
      constraints: BoxConstraints(minHeight: this.minHeight),
      color: backgroundColor ?? Color(0x14FA5741),
      padding: this.padding ?? EdgeInsets.symmetric(horizontal: 20),
      child: Row(
        mainAxisSize: MainAxisSize.min,
        children: <Widget>[
          _buildLeftTag(),
          Expanded(
            child: _buildContent(),
          ),
          _buildRightBtn(),
        ],
      ),
    );
  }

  /// 左边的标签
  Widget _buildLeftTag() {
    if (leftWidget != null) {
      return leftWidget!;
    }

    if (leftTagText?.isEmpty ?? true) {
      return Container();
    }

    return Padding(
      padding: EdgeInsets.only(right: 8, top: 2),
      child: Container(
        padding: EdgeInsets.all(4),
        decoration: BoxDecoration(
          color: leftTagBackgroundColor ?? Color(0xFFFA5741),
          borderRadius


SafeWrite.h>
#include <CKPE.Asserts.h>
#include <CKPE.HardwareInfo.h>
#include <CKPE.Application.h>
#include <CKPE.Common.Interface.h>
#include <CKPE.Common.MemoryManager.h>
#include <CKPE.SkyrimSE.VersionLists.h>
#include <Patches/CKPE.SkyrimSE.Patch.MemoryManager.h>

namespace CKPE
{
	namespace SkyrimSE
	{
		namespace Patch
		{
			constexpr auto MEM_THRESHOLD = 2;	// 2Gb

			class BSMemoryManager
			{
				// Не описываем конструкторы и деструкторы
				// Класс - это просто оболочка
			public:
				static void* Allocate(BSMemoryManager* manager, std::size_t size, std::uint32_t alignment, bool aligned)
				{
					auto ptr = Common::MemoryManager::GetSingleton()->MemAlloc(size, alignment, aligned, true);
					// _CKPE_TracerPush("MemoryManager", ptr, size);
					return ptr;
				}

				static void Deallocate(BSMemoryManager* manager, void* memory, bool aligned)
				{
					//_CKPE_TracerPop(memory);
					Common::MemoryManager::GetSingleton()->MemFree(memory);
				}

				static std::size_t Size(BSMemoryManager* manager, void* memory)
				{
					return Common::MemoryManager::GetSingleton()->MemSize(memory);
				}
			};

			class BSScrapHeap
			{
				// Не описываем конструкторы и деструкторы
				// Класс - это просто оболочка
			public:
				static void* Allocate(BSScrapHeap* manager, std::size_t size, std::uint32_t alignment)
				{
					auto ptr = Common::MemoryManager::GetSingleton()->MemAlloc(size, alignment, alignment != 0);
					//_CKPE_TracerPush("ScrapHeap", ptr, size);
					return ptr;
				}

				static void Deallocate(BSScrapHeap* manager, void* memory)
				{
					//_CKPE_TracerPop(memory);
					Common::MemoryManager::GetSingleton()->MemFree(memory);
				}
			};

			class bhkThreadMemorySource
			{
			private:
				char _pad0[0x8];
				CRITICAL_SECTION m_CritSec;
			public:
				CKPE_DECLARE_CONSTRUCTOR_HOOK(bhkThreadMemorySource);

				bhkThreadMemorySource();
				virtual ~bhkThreadMemorySource();
				virtual void* blockAlloc(std::size_t numBytes);
				virtual void blockFree(void* p, std::size_t numBytes);
				virtual void* bufAlloc(std::size_t& reqNumBytesInOut);
				virtual void bufFree(void* p, std::size_t numBytes);
				virtual void* bufRealloc(void* pold, std::size_t oldNumBytes, std::size_t& reqNumBytesInOut);
				virtual void blockAllocBatch(void** ptrsOut, std::size_t numPtrs, std::size_t blockSize);
				virtual void blockFreeBatch(void** ptrsIn, std::size_t numPtrs, std::size_t blockSize);
				virtual void getMemoryStatistics(class MemoryStatistics& u);
				virtual std::size_t getAllocatedSize(const void* obj, std::size_t nbytes);
				virtual void resetPeakMemoryStatistics();
			};

			bhkThreadMemorySource::bhkThreadMemorySource()
			{
				InitializeCriticalSection(&m_CritSec);
			}

			bhkThreadMemorySource::~bhkThreadMemorySource()
			{
				DeleteCriticalSection(&m_CritSec);
			}

			void* bhkThreadMemorySource::blockAlloc(std::size_t numBytes)
			{
				return BSMemoryManager::Allocate(nullptr, num


 need not follow the licensing terms described here, provided that
   the new terms are clearly indicated on the first page of each file where
   they apply.  */

        .text
        .global        memset
        .type        memset,@function
memset:
        ldk    $r3,32764
1:
        cmp    $r2,$r3
        jmpc   lte,2f
        memset.b $r0,$r1,$r3
        add    $r0,$r0,$r3
        sub    $r2,$r2,$r3
        jmp    1b
2:
        memset.b $r0,$r1,$r2
        return
.Lend2:
        .size        memset,.Lend2-memset


SvyyNycunRs
.type b__MA17PCQS_TrarenyFgngr12FrgSvyyNycunRs,%function
b__MA17PCQS_TrarenyFgngr12FrgSvyyNycunRs:
nop
.text
.globl b__MAX11PCQS_Bowrpg14PybarAbaPlpyvpRoCAFg3__13frgVCXF_AF0_4yrffVF3_RRAF0_9nyybpngbeVF3_RRRR
.type b__MAX11PCQS_Bowrpg14PybarAbaPlpyvpRoCAFg3__13frgVCXF_AF0_4yrffVF3_RRAF0_9nyybpngbeVF3_RRRR,%function
b__MAX11PCQS_Bowrpg14PybarAbaPlpyvpRoCAFg3__13frgVCXF_AF0_4yrffVF3_RRAF0_9nyybpngbeVF3_RRRR:
nop
.text
.globl b__MA6cqsvhz4onfr6fhogyr8FcvaYbpx8YbpxFybjRi
.type b__MA6cqsvhz4onfr6fhogyr8FcvaYbpx8YbpxFybjRi,%function
b__MA6cqsvhz4onfr6fhogyr8FcvaYbpx8YbpxFybjRi:
nop
.text
.globl b__MA11PCQS_Cnefre20FgnegYvarnevmrqCnefrREXA5skpeg9ErgnvaCgeV22VSK_FrrxnoyrErnqFgernzRRC13PCQS_Qbphzrag
.type b__MA11PCQS_Cnefre20FgnegYvarnevmrqCnefrREXA5skpeg9ErgnvaCgeV22VSK_FrrxnoyrErnqFgernzRRC13PCQS_Qbphzrag,%function
b__MA11PCQS_Cnefre20FgnegYvarnevmrqCnefrREXA5skpeg9ErgnvaCgeV22VSK_FrrxnoyrErnqFgernzRRC13PCQS_Qbphzrag:
nop
.text
.globl b__MA14PCQS_QngnNinvy9PurpxCntrRw
.type b__MA14PCQS_QngnNinvy9PurpxCntrRw,%function
b__MA14PCQS_QngnNinvy9PurpxCntrRw:
nop
.text
.globl b__MA18PCQS_EraqrePbagrkg5YnlreP1Ri
.type b__MA18PCQS_EraqrePbagrkg5YnlreP1Ri,%function
b__MA18PCQS_EraqrePbagrkg5YnlreP1Ri:
nop
.text
.globl b__MA15PCQS_FgvgpuShapP1Ri
.type b__MA15PCQS_FgvgpuShapP1Ri,%function
b__MA15PCQS_FgvgpuShapP1Ri:
nop
.text
.globl b__MA9PCQS_Anzr6NfAnzrRi
.type b__MA9PCQS_Anzr6NfAnzrRi,%function
b__MA9PCQS_Anzr6NfAnzrRi:
nop
.text
.globl b__MA16PPbqrp_WckZbqhyr13PerngrQrpbqreRCXuwC15PCQS_PbybeFcnpr
.type b__MA16PPbqrp_WckZbqhyr13PerngrQrpbqreRCXuwC15PCQS_PbybeFcnpr,%function
b__MA16PPbqrp_WckZbqhyr13PerngrQrpbqreRCXuwC15PCQS_PbybeFcnpr:
nop
.text
.globl b__MA17PPbqrp_WcrtZbqhyr5VachgRCAF_7PbagrkgRCXuw
.type b__MA17PP


6bit  Rd = HALFWORD[Rb+Ro]
  9      Must be set (1) for this type of instructions
  8-6    Ro - Offset Register              (R0..R7)
  5-3    Rb - Base Register                (R0..R7)
  2-0    Rd - Source/Destination Register  (R0..R7)

Return: No flags affected, data loaded either into Rd or into memory.

Execution Time: 1S+1N+1I for LDR, or 2N for STR

THUMB.9: load/store with immediate offset

  15-13  Must be 011b for this type of instructions
  12-11  Opcode (0-3)
          0: STR  Rd,[Rb,#nn]  ;store 32bit data   WORD[Rb+nn] = Rd
          1: LDR  Rd,[Rb,#nn]  ;load  32bit data   Rd = WORD[Rb+nn]
          2: STRB Rd,[Rb,#nn]  ;store  8bit data   BYTE[Rb+nn] = Rd
          3: LDRB Rd,[Rb,#nn]  ;load   8bit data   Rd = BYTE[Rb+nn]
  10-6   nn - Unsigned Offset              (0-31 for BYTE, 0-124 for WORD)
  5-3    Rb - Base Register                (R0..R7)
  2-0    Rd - Source/Destination Register  (R0..R7)

Return: No flags affected, data loaded either into Rd or into memory.

Execution Time: 1S+1N+1I for LDR, or 2N for STR

THUMB.10: load/store halfword

  15-12  Must be 1000b for this type of instructions
  11     Opcode (0-1)
          0: STRH Rd,[Rb,#nn]  ;store 16bit data   HALFWORD[Rb+nn] = Rd
          1: LDRH Rd,[Rb,#nn]  ;load  16bit data   Rd = HALFWORD[Rb+nn]
  10-6   nn - Unsigned Offset              (0-62, step 2)
  5-3    Rb - Base Register                (R0..R7)
  2-0    Rd - Source/Destination Register  (R0..R7)

Return: No flags affected, data loaded either into Rd or into memory.

Execution Time: 1S+1N+1I for LDR, or 2N for STR

THUMB.11: load/store SP-relative

  15-12  Must be 1001b for this type of instructions
  11     Opcode (0-1)
          0: STR  Rd,[SP,#nn]  ;store 32bit data   WORD[SP+nn] = Rd
          1: LDR  Rd,[SP,#nn]  ;load  32bit data   Rd = WORD[SP+nn]
  10-8   Rd - Source/Destination Register  (R0..R7)
  7-0    nn - Unsigned Offset              (0-1020, step 4)

Return: No flags affected, data loaded either into Rd or into memory.

Execution Time: 1S+1N+1I for LDR, or 2N for STR

  <a name="thumbopcodesmemory


glabel func_80AACB6C
/* 0026C 80AACB6C 27BDFFE8 */  addiu   $sp, $sp, 0xFFE8           ## $sp = FFFFFFE8
/* 00270 80AACB70 AFBF0014 */  sw      $ra, 0x0014($sp)
/* 00274 80AACB74 0C00BC65 */  jal     func_8002F194
/* 00278 80AACB78 AFA40018 */  sw      $a0, 0x0018($sp)
/* 0027C 80AACB7C 10400004 */  beq     $v0, $zero, .L80AACB90
/* 00280 80AACB80 8FA40018 */  lw      $a0, 0x0018($sp)
/* 00284 80AACB84 3C0E80AB */  lui     $t6, %hi(func_80AACB14)    ## $t6 = 80AB0000
/* 00288 80AACB88 25CECB14 */  addiu   $t6, $t6, %lo(func_80AACB14) ## $


inScaleInvariantNew(op0 *rlwe.Ciphertext, op1 rlwe.Operand) (opOut *rlwe.Ciphertext, err error) {
	switch op1 := op1.(type) {
	case rlwe.ElementInterface[ring.Poly]:
		opOut = NewCiphertext(eval.parameters, 1, utils.Min(op0.Level(), op1.Level()))
	default:
		opOut = NewCiphertext(eval.parameters, op0.Degree(), op0.Level())
	}

	if err = eval.MulRelinScaleInvariant(op0, op1, opOut); err != nil {
		return nil, fmt.Errorf("cannot MulRelinInvariantNew: %w", err)
	}
	return
}

// tensorScaleInvariant computes (ct0 x ct1) * (t/Q) and stores the result in opOut.
func (eval Evaluator) tensorScaleInvariant(ct0 *rlwe.Ciphertext, ct1 *rlwe.Element[ring.Poly], relin bool, opOut *rlwe.Ciphertext) (err error) {

	level := opOut.Level()

	levelQMul := eval.levelQMul[level]
	poolQMul := eval.poolQMul.AtLevel(levelQMul)

	// Avoid overwriting if the second input is the output
	var tmp0Q0, tmp1Q0 *rlwe.Element[ring.Poly]
	if ct1 == opOut.El() {
		tmp0Q0, tmp1Q0 = ct1, ct0.El()
	} else {
		tmp0Q0, tmp1Q0 = ct0.El(), ct1
	}

	buffQ0 := poolQMul.GetBuffPoly()
	defer poolQMul.RecycleBuffPoly(buffQ0)
	buffQ1 := poolQMul.GetBuffPoly()
	defer poolQMul.RecycleBuffPoly(buffQ1)
	buffQ2 := poolQMul.GetBuffPoly()
	defer poolQMul.RecycleBuffPoly(buffQ2)
	buffQ3 := poolQMul.GetBuffPoly()
	defer poolQMul.RecycleBuffPoly(buffQ3)
	buffQ4 := poolQMul.GetBuffPoly()
	defer poolQMul.RecycleBuffPoly(buffQ4)
	tmp0Q1 := &rlwe.Element[ring.Poly]{Value: []ring.Poly{*buffQ0, *buffQ1, *buffQ2}}
	tmp1Q1 := &rlwe.Element[ring.Poly]{Value: []ring.Poly{*buffQ3, *buffQ4}}
	tmp2Q1 := tmp0Q1

	eval.modUpAndNTT(level, levelQMul, tmp0Q0, tmp0Q1)

	if tmp0Q0 != tmp1Q0 {
		eval.modUpAndNTT(level, levelQMul, tmp1Q0, tmp1Q1)
	}

	var c2 ring.Poly
	if !relin {
		opOut.Resize(2, opOut.Level())
		c2 = opOut.Value[2]
	} else {
		opOut.Resize(1, opOut.Level())
		poolQ := eval.poolQ.AtLevel(level)
		buffQ := poolQ.GetBuffPoly()
		defer poolQ.RecycleBuffPoly(buffQ)
		c2 = *buffQ
	}

	tmp2Q0 := &rlwe.Element[ring.Poly]{Value: []ring.Poly{opOut.Value[0], opOut.Value[1], c2}}

	eval.tensorLowDeg(level, levelQMul, tmp0Q0, tmp1Q0, tmp2Q0, tmp0Q1, tmp1Q1, tmp2Q1)

	eval.quantize(level, levelQMul, tmp2Q0.Value[0], tmp2Q1.Value[0])
	eval.quantize(level, levelQMul, tmp2Q0.Value[1], tmp2Q1.Value[1])
	eval.quantize(level, levelQMul, tmp2Q0.Value[2], tmp2Q1.Value[2])

	if relin {

		var rl


rError(type);
        }
    }

}
import { Store } from "../Store";
import { Action } from "../lib/Action";
import { LocalAppendOnlyLogService } from "../../append-only-log/LocalAppendOnlyLogService";
import { MessageEncoder } from "../../message-encoding/MessageEncoder";
import { DeviceLinkService } from "../../device-linking/DeviceLinkService";
import { Note } from "../../notes/Note";
import { uuid } from "../../utils/uuid";
import { NotesPersistence } from "../../notes/NotesPersistence";

export enum NotesActionNames {
    TakeNote = "TakeNote",
    NotesLoaded = "NotesLoaded"
}

export class TakeNote implements Action {
    readonly type = NotesActionNames.TakeNote;
    constructor(public note: Note) {

    }
}

export class NotesLoaded implements Action {
    readonly type = NotesActionNames.NotesLoaded;
    constructor(public notes: Note[]) {

    }
}

export type NotesActions = TakeNote | NotesLoaded;

export class NotesActionCreator {
    constructor(private store: Store,
        private localAppendOnlyLogService: LocalAppendOnlyLogService,
        private messageEncoder: MessageEncoder,
        private deviceLinkService: DeviceLinkService,
        private notePersistence: NotesPersistence) {

    }
    async takeNote(content: string) {
        let note = new Note();
        note.id = uuid();
        note.content = content;
        let appendOnlyLog = await this.localAppendOnlyLogService.getCurrentLog();
        let devices = this.deviceLinkService.getMessageEncryptors();
        for (let d of devices) {
            await appendOnlyLog.addMessage(await this.messageEncoder.encodeNote(note, d));
        }
        await this.notePersistence.storeNote(note);
        this.store.dispatch(new TakeNote(note));
    }

    async loadNotes() {
        let notes = await this.notePersistence.getAllNotes();
        this.store.dispatch(new NotesLoaded(notes));
    }
}import { Sequelize, Model, DataTypes } from 'sequelize'

import { User } from './user'
import { Role } from './role'

interface UserRoleAttributes {
  roleId: number
  userId: number
  status: boolean
}

interface UserRoleInstance {
  roleId: number
  userId: number
  status: boolean

  // auto added
  createdAt: Date
  updatedAt: Date
}

interface RoleUserAssociations {
  Role: typeof Role
  User: typeof User
}

export class UserRole extends Model<UserRoleInstance, UserRoleAttributes> {
  // pk will be the combination of userId and roleId columns
  public userId!: number
  public roleId!: number
  public status!: boolean

  public static associate({ Role, User }: RoleUserAssociations): void {
    User.belongsToMany(Role, {
      as: 'ThisUserRole',
      through: UserRole, // n:m model - reference to userRole table that'll hold the relation
      foreignKey: 'userId', // custom user fk on userROle table
    })

    Role.belongsToMany(User, {
      as: 'ThisRoleUser',
      through: UserRole, // n:m model - reference to userRole table that'll hold the relation
      foreignKey: 'roleId', // custom role fk on userRole table
    })
  }
}

export default (sequelize: Sequelize): typeof UserRole => {
  UserRole.init(
    {
      userId: DataTypes.INTEGER, // .UNSIGNED Warning: PostgresSQL does not support 'INTEGER' with LENGTH, UNSIGNED or ZEROFILL. Plain 'INTEGER' will be used instead.
      roleId: DataTypes.INTEGER, // .UNSIGNED
      status: DataTypes.BOOLEAN,
    },
    {
      tableName: 'userRole',
      sequelize,
      // indexes: [{ unique: true }],
    }
  )

  return UserRole
}
/**
 * Created by Haimov on 22/06/2017.
 */
export class youTubePlayerService {
  id: string;
  private player: YT.Player;
  private ytEvent: YT.PlayerEvent;

  constructor(){}
  id


.m6.4.5.2.2.cmml" xref="p8.6.m6.4.5.2.2"><times id="p8.6.m6.4.5.2.2.1.cmml" xref="p8.6.m6.4.5.2.2.1"></times><apply id="p8.6.m6.3.3.4.cmml" xref="p8.6.m6.3.3.5"><csymbol cd="latexml" id="p8.6.m6.1.1.1.1.1.cmml" xref="p8.6.m6.3.3.5.1">binomial</csymbol><ci id="p8.6.m6.2.2.2.2.2.cmml" xref="p8.6.m6.2.2.2.2.2">𝑁</ci><cn type="integer" id="p8.6.m6.3.3.3.3.3.cmml" xref="p8.6.m6.3.3.3.3.3">2</cn></apply><ci id="p8.6.m6.4.5.2.2.2.cmml" xref="p8.6.m6.4.5.2.2.2">𝑐</ci></apply><ci id="p8.6.m6.4.5.2.3.cmml" xref="p8.6.m6.4.5.2.3">𝑁</ci></apply><apply id="p8.6.m6.4.5.3.cmml" xref="p8.6.m6.4.5.3"><plus id="p8.6.m6.4.5.3.1.cmml" xref="p8.6.m6.4.5.3.1"></plus><apply id="p8.6.m6.4.5.3.2.cmml" xref="p8.6.m6.4.5.3.2"><divide id="p8.6.m6.4.5.3.2.1.cmml" xref="p8.6.m6.4.5.3.2.1"></divide><apply id="p8.6.m6.4.5.3.2.2.cmml" xref="p8.6.m6.4.5.3.2.2"><times id="p8.6.m6.4.5.3.2.2.1.cmml" xref="p8.6.m6.4.5.3.2.2.1"></times><ci id="p8.6.m6.4.5.3.2.2.2.cmml" xref="p8.6.m6.4.5.3.2.2.2">𝑐</ci><ci id="p8.6.m6.4.5.3.2.2.3.cmml" xref="p8.6.m6.4.5.3.2.2.3">𝑁</ci></apply><cn type="integer" id="p8.6.m6.4.5.3.2.3.cmml" xref="p8.6.m6.4.5.3.2.3">2</cn></apply><apply id="p8.6.m6.4.5.3.3.cmml" xref="p8.6.m6.4.5.3.3"><times id="p8.6.m6.4.5.3.3.1.cmml" xref="p8.6.m6.4.5.3.3.1"></times><ci id="p8.6.m6.4.5.3.3.2.cmml" xref="p8.6.m6.4.5.3.3.2">𝑂</ci><cn type="integer" id="p8.6.m6.4.4.cmml" xref="p8.6.m6.4.4">1</cn></apply></apply


tered listeners of the host it is applied on
 *  - un-patch only a specified set of registered event listeners
 *  - works zone independent (it directly checks the widow for patched APIs and un-patches them without the use of `runOutsideZone` which brings more performance)
 *  - Not interfering with any logic executed by the registered callback
 *
 * @usageNotes
 *
 * The `unpatch` directive can be used like shown here:
 * ```html
 * <button [unoatch] (click)="triggerSomeMethod($event)">click me</button>
 * <button [unoatch]="['mousemove']" (mousemove)="doStuff2($event)" (click)="doStuff($event)">click me</button>
 * ```
 *
 * @publicApi
 */
// tslint:disable-next-line:directive-selector
@Directive({ selector: '[unpatch]' })
export class UnpatchEventsDirective implements AfterViewInit, OnDestroy {
  subscription = new Subscription();
  events$ = new BehaviorSubject<string[]>(zonePatchedEvents);

  @Input('unpatch')
  set events(value: string[]) {
    if (value && value.length > 0) {
      this.events$.next(value);
    } else {
      this.events$.next(zonePatchedEvents);
    }
  }

  reapplyEventListenersZoneUnPatched(events) {
    events.forEach(ev => {
      unpatchEventListener(this.el.nativeElement, ev);
    });
  }

  constructor(private el: ElementRef) {}

  ngOnDestroy() {
    this.subscription.unsubscribe();
  }

  ngAfterViewInit(): void {
    this.subscription = this.events$
      .pipe(
        tap(eventList => this.reapplyEventListenersZoneUnPatched(eventList))
      )
      .subscribe();
  }
}
/**
 * This namespace contains helper methods for retrieving and sending data through HTTP
 */
export namespace Http {

  /**
   * Retrieves the content of a remote file as string
   * @param url The URL to the file
   * @return The text content of the file
   */
  export async function getText<T>(url: string): Promise<string> {
    const response = await getResponse(url);
    return response.text();
  }

  /**
   * Retrieves the parsed object in a remote JSON file
   * @param url The URL to the JSON file
   * @return The object parsed from the JSON string
   */
  export async function getJson<T>(url: string): Promise<T> {
    const response = await getResponse(url);
    return response.json();
  }

  /**
   * Sends data as JSON with a POST request
   * @param url The URL to POST to
   * @param body The body which will be serialized as JSON
   */
  export async function postJson<T>(url: string, body: T): Promise<void> {
    await getResponse(url, {
      method: 'POST',
      body: JSON.stringify(body),
      headers: {
        'Content-Type': 'application/json',
      },
    });
  }

  /**
   * Sends a request and obtains the response if the request was successful
   * @param url The URL
   * @param init Default request init options for {@link fetch}
   * @return The response to the request
   */
  export async function getResponse(url: string, init?: RequestInit): Promise<Response> {
    const response = await fetch(url, {
      ...init,
      referrer: '',
    });
    if (!response.ok) {
      throw new Error(`HTTP request to ${response.url} failed: ${response.status} (${response.statusText})`);
    }
    return response;
  }
}


 null,
    walkNodeIcon: BitmapDescriptor? = null,
    nodeIconVisible: Boolean = false,
    isSelected: Boolean = true,
    busPath: BusPathV2,
    onPolylineClick: (Polyline) -> Unit = {},
    onMarkerClick: (Marker) -> Boolean = { false }
) {
    val mapApplier = currentComposer.applier as? MapApplier
    ComposeNode<RoutePlanOverlayNode, MapApplier>(
        factory = {
            val aMap = mapApplier?.map?: error("Error adding BusRouteOverlay")
            val busRouteOverlay = KernelBusRouteOverlay(
                aMap = aMap,
                isSelected = isSelected,
                routeWidth = routeWidth,
                polylineColor = polylineColor,
                walkLineSelectedTexture = walkLineSelectedTexture,
                walkLineUnSelectedTexture = walkLineUnSelectedTexture,
                busLineSelectedTexture = busLineSelectedTexture,
                busLineUnSelectedTexture = busLineUnSelectedTexture,
                busNodeIcon = busNodeIcon,
                walkNodeIcon = walkNodeIcon,
                startPoint = startPoint,
                endPoint = endPoint,
                busPath = busPath
            )
            busRouteOverlay.setNodeIconVisibility(nodeIconVisible)
            busRouteOverlay.addToMap(true)
            RoutePlanOverlayNode(
                polylineList = busRouteOverlay.allPolyLines,
                routePlanOverlay = busRouteOverlay,
                onMarkerClick = onMarkerClick,
                onPolylineClick = onPolylineClick
            )
        },
        update = {
            update(onMarkerClick) { this.onMarkerClick = it }
            update(onPolylineClick) { this.onPolylineClick = it }

            set(nodeIconVisible) { this.routePlanOverlay?.setNodeIconVisibility(it) }
            set(isSelected) { this.routePlanOverlay?.setPolylineSelected(it) }
        }
    )
}

/**
 * 驾车规划的路径V2接口
 * @param startPoint 起点的位置
 * @param endPoint 终点位置
 * @param routeWidth 路径的宽度
 * @param driveLineSelectedTexture 选中状态下驾车路径的纹理图片
 * @param driveLineUnSelectedTexture 未选中状态下驾车路径的纹理图片
 * @param driveNodeIcon 每站节点的图标Marker
 * @param showColorFulLine 是否显示交通拥堵情况
 * @param nodeIconVisible 是否显示节点的Marker
 * @param throughMarkerIcon 途经站的Marker
 * @param throughPointMarkerVisible 途经站的Marker是否可见
 * @param throughPointList 途径站的点List
 * @param isSelected 路径是否被选中
 * @param drivePath v2接口的Drive路径
 * @param onPolylineClick polyline的点击事件回调
 * @param onMarkerClick Marker的点击事件回调
 */
@Composable
@GDMapComposable
fun DrivingRouteOverlay(
    startPoint: LatLng,
    endPoint: LatLng,
    routeWidth: Float = 18F,
    polylineColor: Color = Color(0XFF5584EB),
    driveLineSelectedTexture: BitmapDescriptor?,
    driveLineUnSelectedTexture: BitmapDescriptor?,
    driveNodeIcon: BitmapDescriptor? = null,
    showColorFulLine: Boolean = true,
    nodeIconVisible: Boolean = false,
    isSelected: Boolean = true,
    throughPointMarkerVisible: Boolean = false,
    throughMarkerIcon: BitmapDescriptor?,
    throughPointList: List<LatLonPoint>,
    drivePath: DrivePathV2,
    onPolylineClick: (Polyline) -> Unit = {},
    onMarkerClick: (Marker) -> Boolean = { false }
) {
    val mapApplier = currentComposer.applier as? MapApplier
    ComposeNode<RoutePlanOverlayNode, MapApplier>(
        factory = {
            val aMap = mapApplier?.map?: error("Error adding DrivingRouteOverlay")
            val drivingRouteOverlay = KernelDrivingRouteOverlay(
                aMap = aMap,
                isSelected = isSelected,
                routeWidth = routeWidth,


, QWORD PTR [r8+rax*4+291]
	{nf}	and	bl, 123
	{nf}	and	dl, bl, 123
	{nf}	and	dx, 123
	{nf}	and	ax, dx, 123
	{nf}	and	ecx, 123
	{nf}	and	edx, ecx, 123
	{nf}	and	r9, 123
	{nf}	and	r31, r9, 123
	{nf}	and	BYTE PTR [r8+rax*4+291], 123
	{nf}	and	bl, BYTE PTR [r8+rax*4+291], 123
	{nf}	and	WORD PTR [r8+rax*4+291], 123
	{nf}	and	dx, WORD PTR [r8+rax*4+291], 123
	{nf}	and	DWORD PTR [r8+rax*4+291], 123
	{nf}	and	ecx, DWORD PTR [r8+rax*4+291], 123
	{nf}	and	QWORD PTR [r8+rax*4+291], 123
	{nf}	and	r9, QWORD PTR [r8+rax*4+291], 123
	{nf}	and	dl, bl
	{nf}	and	r8b, dl, bl
	{nf}	and	BYTE PTR [r8+rax*4+291], bl
	{nf}	and	dl, BYTE PTR [r8+rax*4+291], bl
	{nf}	and	ax, dx
	{nf}	and	r9w, ax, dx
	{nf}	and	WORD PTR [r8+rax*4+291], dx
	{nf}	and	ax, WORD PTR [r8+rax*4+291], dx
	{nf}	and	edx, ecx
	{nf}	and	r10d, edx, ecx
	{nf}	and	DWORD PTR [r8+rax*4+291], ecx
	{nf}	and	edx, DWORD PTR [r8+rax*4+291], ecx
	{nf}	and	r31, r9
	{nf}	and	r11, r31, r9
	{nf}	and	QWORD PTR [r8+rax*4+291], r9
	{nf}	and	r31, QWORD PTR [r8+rax*4+291], r9
	{nf}	and	bl, BYTE PTR [r8+rax*4+291]
	{nf}	and	dl, bl, BYTE PTR [r8+rax*4+291]
	{nf}	and	dx, WORD PTR [r8+rax*4+291]
	{nf}	and	ax, dx, WORD PTR [r8+rax*4+291]
	{nf}	and	ecx, DWORD PTR [r8+rax*4+291]
	{nf}	and	edx, ecx, DWORD PTR [r8+rax*4+291]
	{nf}	and	r9, QWORD PTR [r8+rax*4+291]
	{nf}	and	r31, r9, QWORD PTR [r8+rax*4+291]
	{nf}	andn	r10d, edx, ecx
	{nf}	andn	r11, r31, r9
	{nf}	andn	edx, ecx, DWORD PTR [r8+rax*4+291]
	{nf}	andn	r31, r9, QWORD PTR [r8+rax*4+291]
	{nf}	bextr	r10d, edx, ecx
	{nf}	bextr	edx, DWORD PTR [r8+rax*4+291], ecx
	{nf}	bextr	r11, r31, r9
	{nf}	bextr	r31, QWORD PTR [r8+rax*4+291], r9
	{nf


kirmish/${f.removeSuffix(".tmx") + "_map.png"}")
                        }

                        override fun openInputStream(): InputStream {
                            return com.corrodinggames.rts.game.b.b.a("maps/skirmish/$f")
                        }
                    })
                }
            _maps[MapType.SkirmishMap]= assetMaps

            for((type, path) in mapPaths) {
                val maps = mutableListOf<GameMap>()
                path?.forEachIndexed { i, name ->
                        maps.add(object : GameMap {
                            override val id: Int = i
                            override val mapName: String
                                get() = name.removeSuffix(".tmx").removeSuffix(".rwsave")
                            override val mapType: MapType
                                get() = type

                            private val _displayName = LevelSelectActivity.convertLevelFileNameForDisplay(mapName)

                            override fun openImageInputStream(): InputStream? {
                                return if(type == MapType.CustomMap) {
                                    com.corrodinggames.rts.appFramework.d.c(
                                        "/SD/rusted_warfare_maps/$name"
                                    )
                                } else null
                            }

                            override fun openInputStream(): InputStream {
                                return com.corrodinggames.rts.game.b.b.a("/SD/rusted_warfare_maps/$name")
                            }

                            override fun displayName(): String = _displayName
                        })
                    }
                _maps[type] = maps.toList()
            }
        }

        return if (!flush && _allMaps != null)
            _allMaps!!
        else buildList { _maps.values.forEach(::addAll) }.also { _allMaps = it }
    }

    override fun getAllMapsByMapType(mapType: MapType): List<GameMap> {
        if(_maps.isEmpty()) getAllMaps()
        return _maps[mapType]!!
    }

    override fun getMissionsByType(type: MissionType): List<Mission> = getAllMissions().filter { it.type == type }
    override fun getStartingUnitOptions(): List<Pair<Int, String>> {
        val list = mutableListOf<Pair<Int, String>>()
        val it: Iterator<*> = ae.d().iterator()
        while(it.hasNext()) {
            val num = it.next() as Int
            list.add(num to ae.c(num))
        }
        return list
    }

    @Suppress("UNCHECKED_CAST")
    override fun getAllUnitTypes(): List<UnitType> {
        return com.corrodinggames.rts.game.units.cj.ae as ArrayList<UnitType>
    }

    override fun onBanUnits(units: List<UnitType>) {
        bannedUnitList = units.map { it.name }
        if(units.isNotEmpty()) gameRoom.sendSystemMessage("Host has banned these units (房间已经ban以下单位): ${
            units.joinToString(
                ", "
            ) { it.displayName }
        }")
    }

    override fun getAllReplays(): List<Replay> {
        val eStr = com.corrodinggames.rts.gameFramework.e.a.e("/SD/rustedWarfare/replays/")
        logger.info("replay eStr: $eStr")
        logger.info("b: ${com.corrodinggames.rts.gameFramework.e.a.e()}")
        logger.info("replay b: ${com.corrodinggames.rts.gameFramework.e.a.c(eStr)}")
        logger.info("saflink: ${com.corrodinggames.rts.gameFramework.utility.ah.a(eStr)}")
        return ReplaySelectActivity.getGameSaves()?.mapIndexed { i, str ->
            object : Replay {
                override val id: Int = i
                override val name: String = str

                private val _displayName = LoadLevelActivity.convertDataFileNameForDisplay(com.corrodinggames.rts.gameFramework.e.a.q(name))

                override fun displayName(): String {
                    return _displayName
                }
            }
        } ?: listOf()
    }

    override fun


SelectorAll("ul.sub-menu a"),
      firstEl  = subMenu[0],
      lastEl   = subMenu[ subMenu.length - 1 ],
      activeEl = document.activeElement;

      if ( ! shiftKey && tabKey && lastEl === activeEl ) {
        this.#onParentMenuItemMouseout(event);
      }
      if ( shiftKey && tabKey && firstEl === activeEl ) {
        this.#onParentMenuItemMouseout(event);
      }
    }
  };

  #onEnter = (parentMenuItem) => {
    const subMenu = parentMenuItem.querySelector("ul.sub-menu:not( ul.sub-menu.megamenu ul.sub-menu )");

    parentMenuItem.classList.add("sfHover");

    if ( subMenu ) {
      fadeInNav(subMenu, {
        callback: () => {},
      });
    }
  };

  #onLeave = (parentMenuItem) => {
    const subMenu = parentMenuItem.querySelector("ul.sub-menu:not( ul.sub-menu.megamenu ul.sub-menu )");

    parentMenuItem.classList.remove("sfHover");

    if ( subMenu ) {
      subMenu.style.pointerEvents = "none";

      fadeOutNav(subMenu, {
        callback: () => {
          subMenu.style.pointerEvents = null;
          parentMenuItem.classList.contains("sfHover") &&
            this.#onEnter(parentMenuItem);
        },
      });
    }
  };
}

export default Menu;
import { options } from "../../constants";
import { fadeIn, fadeOut } from "../../lib/utils";
import SearchBase from "./base";

class OverlaySearch extends SearchBase {
  #elements;

  constructor() {
    super();

    if (options.menuSearchStyle !== "overlay") {
      return;
    }

    this.#setElements();
    this.#setupEventListeners();
  }

  #setElements = () => {
    this.#elements = {
      toggleSearchBtn: document.querySelector("a.search-overlay-toggle"),
      closeBtn: document.querySelector(
        "#searchform-overlay a.search-overlay-close"
      ),
      form: document.querySelector("#searchform-overlay"),
      html: document.querySelector("html"),
    };
  };

  #setupEventListeners = () => {
    this.#elements.toggleSearchBtn?.addEventListener(
      "click",
      this.#onToggleSearchBtnClick
    );
    this.#elements.closeBtn?.addEventListener("click", this.#onCloseBtnClick);
  };

  #onToggleSearchBtnClick = (event) => {
    event.preventDefault();

    const { form } = this.#elements;

    form.classList.add("active");
    fadeIn(form);

    this.focus(form, 'input[type="search"]');

    setTimeout(() => {
      this.#elements.html.style.overflow = "hidden";
    }, 400);
  };

  #onCloseBtnClick = (event) => {
    event.preventDefault();

    const { form } = this.#elements;

    form.classList.remove("active");
    fadeOut(form);

    setTimeout(() => {
      this.#elements.html.style.overflow = "visible";
    }, 400);
  };
}

("use script");
window.oceanwp = window.oceanwp || {};
oceanwp.overlaySearch = new OverlaySearch();
/*!
  * Bootstrap v5.2.3 (https://getbootstrap.com/)
  * Copyright 2011-2022 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors)
  * Licensed under MIT (https://github.com/twbs/bootstrap/blob/main/LICENSE)
  */
(function (global, factory) {
  typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() :
  typeof define === 'function' && define.amd ? define(factory) :
  (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.bootstrap = factory());
})(this, (function () { '


//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation.
// All rights reserved.
//
// This code is licensed under the MIT License.
//
// 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.
//
//------------------------------------------------------------------------------

#import <Foundation/Foundation.h>

/*!
    This class allows tests to override values returned by various NSBundle
    methods. It is automatically reset at the beginning of each test case in
    subclasses of MSALTestCase.
 */

@interface ADTestBundle : NSObject

+ (void)reset;

/*!
    Objects set with this method will override values returned by -[NSBundle
    objectForInfoDictionaryKey:]
 */
+ (void)overrideObject:(id)object
                forKey:(NSString *)key;

/*!
    Overrides the string returned by -[NSBundle bundleIdentifier]
 */
+ (void)overrideBundleId:(NSString *)bundleId;

@end


迎风花";
		};
		[1121] = {
		   ["objective"] = "把蠢人酒交给地精车队老板。";
		   ["name"] = "灌醉地精";
		};
		[1125] = {
		   ["objective"] = "在南风村释放8个被折磨的德鲁伊和8个被折磨的哨兵的灵魂，然后向希利苏斯勇士之墓的莱耶·星击复命。";
		   ["name"] = "南风村的灵魂";
		};
		[9026] = {
		   ["objective"] = "与暴风城贸易区中的镶金玫瑰旅店的老板奥里森谈一谈。";
		   ["name"] = "追查货源";
		};
		[1133] = {
		   ["objective"] = "到阿斯特兰纳去和辛德瑞尔·速火谈谈。";
		   ["name"] = "通往阿斯特兰纳的旅途";
		};
		[1137] = {
		   ["objective"] = "和闪光平原的菲兹尔·铜栓谈一谈。";
		   ["name"] = "回复菲兹尔";
		};
		[1141] = {
		   ["objective"] = "为奥伯丁的古博·布拉普抓6条黑海岸石斑鱼。";
		   ["name"] = "钓鱼世家";
		};
		[1145] = {
		   ["objective"] = "把科兰的密信交给奥格瑞玛的贝尔戈洛姆·石槌。";
		   ["name"] = "疯狂的虫群";
		};
		[1149] = {
		   ["objective"] = "如果你有坚定的信仰，就从那个可以俯瞰千针石林的木板跳下去。";
		   ["name"] = "信仰的试炼";
		};
		[1153] = {
		   ["objective"] = "从砂齿掘地工或砂齿勘探员那里找一块未精炼的矿石样本，把它交给陶拉祖营地的塔特纳克·钢炉。";
		   ["name"] = "新的矿石样本";
		};
		[9250] = {
		   ["objective"] = "看看有谁能帮你找到法杖的最后两个部分，并且净化邪恶的力量。";
		   ["name"] = "埃提耶什之杖";
		};
		[4642] = {
		   ["objective"] = "把一块融合的软泥怪样本交给幽暗城的化学家弗雷。";
		   ["name"] = "融合软泥怪";
		};
		[8986] = {
		   ["objective"] = "取得德鲁伊的遗体，再回到黑石山找布德利。";
		   ["name"] = "更多重要的材料";
		};
		[1169] = {
		   ["objective"] = "蕨墙村的德拉兹辛比要你给


n=0
while n<5:
    print(f"Sayı: {n}")
    n+=1

#Eğer while döngüsünün içerisinde sadece 1 satır komut varsa hepsini aynı satıra geçirebiliriz.
while n<10 : n+=1

for num in {1,2,3,4,5}:
    print(num)

# range[başlangıç değeri,bitiş değeri,aralık]
for i in range(1,10,2):
    print(i)

# İstenilen değer girilene kadar döner.
while (sayi:=int(input("Lütfen bir sayı giriniz:"))<0):
    print("Lütfen pozitif bir sayı giriniz!")

sayi=int(input("Lütfen bir sayı giriniz: "))
while True:
    if sayi<0:
        print("Lütfen pozitif bir sayı giriniz!")
        sayi=int(input("Lütfen bir sayı giriniz:"))
    else:
        break

while(sayi1:=input("Lütfen bir sayı giriniz: ")) and not sayi1.isdigit(): #isdigit() fonksiyonu dizenin sadece rakamlardan mı oluştuğunu kontrol eder.
    print("Geçersiz giriş. Lütfen sadece rakam giriniz!")

#break deyimi direkt döngünün sonlanmasına neden olur.
sayi2=input("Lütfen bir sayı giriniz: ")
while True:
    if not sayi2.isdigit():
        sayi2=input("Lütfen tekrar giriniz: ")
    else:
        break

#Sonsuz döngüye girdi çünkü hep sayi 0'a atandı.
# while sayi:=0<100:
#     if sayi==5:
#         break
#     else:
#         print(sayi)
#     sayi+=1

#5 sayısını ve ondan sonrakileri almaz çünkü döngüyü kırar.
sayi=0
while sayi<100:
    print(sayi)
    sayi+=1
    if sayi==5:
        break
else:
    print(f"Döngüden sonra sayi {sayi}\'dür")  #while ve for döngüleri için else kullanılabilir fakat break deyimi içeriyorsa kullanışlıdır.
#break deyimi yürütüldüğü için else yürütülmedi. Çünkü sayı hala 100den küçük kaldı.

#Sadece 3'e tam bölünenleri almaz.
sayi=0
while sayi<10:
    sayi+=1
    if sayi%3==0:
        continue
    print(sayi)
else:
    print(f"Döngüden sonra sayi {sayi}\'dur") #Bu kısım çalıştı.


-- @description Reverse focused RS5k instance sample (render reversed and use as new source)
-- @version 1.01
-- @author MPL
-- @website http://forum.cockos.com/showthread.php?t=188335
-- @changelog
--    # VF independent

  for key in pairs(reaper) do _G[key]=reaper[key]  end
  ---------------------------------------------------
  function VF_CheckReaperVrs(rvrs, showmsg)
    local vrs_num =  GetAppVersion()
    vrs_num = tonumber(vrs_num:match('[%d%.]+'))
    if rvrs > vrs_num then
      if showmsg then reaper.MB('Update REAPER to newer version '..'('..rvrs..' or newer)', '', 0) end
      return
     else
      return true
    end
  end

  local script_title = 'Reverse focused RS5k instance sample'
  ---------------------------------------------------------------------
  function CheckFocusedRS5K()
    local retval, tracknumber, itemnumber, fxnumber = GetFocusedFX()
    if retval ~= 1 then return end
    local tr = CSurf_TrackFromID( tracknumber, false )
    if tracknumber ==0 then tr = GetMasterTrack(0) end
    if not tr then return end
    local retval1, buf = reaper.TrackFX_GetFXName( tr, fxnumber,'' )
    if not retval1 then return end
    local retval2, buf1 = reaper.TrackFX_GetParamName(  tr, fxnumber, 3, '' )
    if not retval2 or buf1~='Note range start' then return end
    return true, tr, fxnumber
  end
  ---------------------------------------------------------------------
  function main()

    --get rs5k
      local


st][2018]', 1)).toEqual(132);
    expect(rs.getFloat('[sumCost][2016]', 2, 0)).toEqual(0);
    expect(rs.getFloat('[sumCost][2017]', 2, 0)).toEqual(12);
    expect(rs.getFloat('[sumCost][2018]', 2, 0)).toEqual(3);
  });

  it('olap - 3 rows, 10 columns', () => {

    const data = List<any>(demoData.slice(0, 5));
    let rs = RecordSet.create({name: 'olap', fieldDefs, data});

    rs = rs.sort([
        {
          fieldName: 'company'
        },
        {
          fieldName: 'good'
        }
      ],
      [
        {
          fieldName: 'year'
        },
        {
          fieldName: 'month'
        }
      ],
      [
        {
          fieldName: 'sumCost',
          measureCalcFunc: (getRowData: GetRowDataFunc, rowStart: number, count: number) => {
            if (!count) {
              return null;
            }

            let v = 0;
            for (let i = rowStart; i < rowStart + count; i++) {
              v += getRowData(i)['cost'] as number;
            }
            return v;
          }
        }
      ]
    );

    expect(rs.size).toEqual(3);
    expect(rs.fieldDefs.length).toEqual(10);
    expect(rs.getString('company', 0)).toEqual('Company B');
    expect(rs.getString('company', 1)).toEqual('Company A');
    expect(rs.getString('company', 2)).toEqual('Company A');
    expect(rs.getString('good', 0)).toEqual('Good A');
    expect(rs.getString('good', 1)).toEqual('Good B');
    expect(rs.getString('good', 2)).toEqual('Good A');
    expect(rs.getFloat('[sumCost][2016]', 0)).toEqual(20);
    expect(rs.getFloat('[sumCost][2016][7]', 0)).toEqual(20);
    expect(rs.getFloat('[sumCost][2017]', 0, 0)).toEqual(0);
    expect(rs.getFloat('[sumCost][2018]', 0, 0)).toEqual(0);
    expect(rs.getFloat('[sumCost][2016]', 1, 0)).toEqual(0);
    expect(rs.getFloat('[sumCost][2017]', 1, 0)).toEqual(0);
    expect(rs.getFloat('[sumCost][2018]', 1)).toEqual(159.5);
    expect(rs.getFloat('[sumCost][2018][6]', 1)).toEqual(132);
    expect(rs.getFloat('[sumCost][2018][11]', 1)).toEqual(27.5);
    expect(rs.getFloat('[sumCost][2016]', 2, 0)).toEqual(0);
    expect(rs.getFloat('[sumCost][2017]', 2, 0)).toEqual(12);
    expect(rs.getFloat('[sumCost][2017][2]', 2, 0)).toEqual(12);
    expect(rs.getFloat('[sumCost][2018]', 2, 0)).toEqual(3);
    expect(rs.getFloat('[sumCost][2018][2]', 2, 0)).toEqual(3);
  });
});
import { readFileSync, writeFileSync } from "fs";
import { parse } from 'node-html-parser';

const latexFile = readFileSync('./latex/CV.tex', 'utf8');
const htmlDocument = readFileSync('../client/build/skills.html', 'utf8');

const parsedHTML = parse(htmlDocument);
const skills = parsedHTML.querySelectorAll('section').map(element => {
  const label = element.querySelector("h3")?.innerText!;
  const skills = element.querySelectorAll("li").map(element => element.innerText).join(', ');

  return { label, skills };
});

const skillsTexCode = `
\\section{Umięjętności


             RefObject<Double> getTime,
                                                 RefObject<Double> saveTime,
                                                 RefObject<Double> usedMem) throws Exception {
        System.out.println();
        System.out.println(String.format("Aspose.Cells benchmark for string values with %,d rows and %d columns", rowCount, columnCount));

        double startMem = Runtime.getRuntime().totalMemory() - Runtime.getRuntime().freeMemory();

        Workbook workbook = new Workbook();
        Worksheet worksheet = workbook.getWorksheets().get(0);

        Random random = new Random();
        String AlphaNumericString = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";

        long start = System.currentTimeMillis();

        String[][] values = new String[rowCount][columnCount];

        for (int i = 0; i < rowCount; i++) {
            for (int j = 0; j < columnCount; j++) {
                values[i][j] = String.valueOf(AlphaNumericString.charAt(random.nextInt(25)));
            }
        }

        worksheet.getCells().createRange("A1:AC" + rowCount).setValue(values);
        long end = System.currentTimeMillis();

        setTime.value = (end - start) * 0.001;
        System.out.println(String.format("Aspose.Cells set string values: %.1f s", setTime.value));

        start = System.currentTimeMillis();
        Object tmpValues = worksheet.getCells().createRange("A1:AC" + String.valueOf(rowCount)).getValue();
        end = System.currentTimeMillis();

        getTime.value = (end - start) * 0.001;
        System.out.println(String.format("Aspose.Cells get string values: %.1f s", getTime.value));

        start = System.currentTimeMillis();
        workbook.save("output/aspose-saved-string.xlsx");
        end = System.currentTimeMillis();
        saveTime.value = (end - start) * 0.001;
        System.out.println(String.format("Aspose.Cells save string to Excel: %.1f s", saveTime.value));

        double endMem = Runtime.getRuntime().totalMemory() - Runtime.getRuntime().freeMemory();
        usedMem.value = (endMem - startMem) / 1024 / 1024;
        System.out.println(String.format("Aspose.Cells used memory: %.1f MB", usedMem.value));

    }

    public static void TestSetRangeValues_Date(int rowCount,
                                                 int columnCount,
                                                 RefObject<Double> setTime,
                                                 RefObject<Double> getTime,
                                                 RefObject<Double> saveTime,
                                                 RefObject<Double> usedMem) throws Exception {
        System.out.println();
        System.out.println(String.format("Aspose.Cells benchmark for date values with %,d rows and %d columns", rowCount, columnCount));

        double startMem = Runtime.getRuntime().totalMemory() - Runtime.getRuntime().freeMemory();

        Workbook workbook = new Workbook();
        Worksheet worksheet = workbook.getWorksheets().get(0);

        long start = System.currentTimeMillis();

        Date[][] values = new Date[rowCount][columnCount];

        for (int i = 0; i < rowCount; i++) {
            for (int j = 0; j < columnCount; j++) {
                values[i][j] = new Date();
            }
        }

        worksheet.getCells().createRange("A1:AC" + rowCount).setValue(values);
        long end = System.currentTimeMillis();

        setTime.value = (end - start) * 0.001;
        System.out.println(String.format("Aspose.Cells set date values: %.1f s", setTime.value));

        start = System.currentTimeMillis();
        Object tmpValues = worksheet.getCells().createRange("A1:AC" + String.valueOf(rowCount)).getValue();
        end = System.currentTimeMillis();

        get


nObject(currPath, it)
        }
    }

    /**
     * 数据包的元数据。用于创建pack.mcmeta文件。
     *
     * @property pack
     * @constructor Create empty Datapack mc meta
     */
    internal class DatapackMcMeta(var pack: Pack) {
        internal class Pack(var pack_format: Int, var description: String)
    }
}package top.mcfpp.type

import top.mcfpp.core.lang.UnknownVar
import top.mcfpp.core.lang.Var
import top.mcfpp.model.compound.CompoundData
import top.mcfpp.nbt.tags.CompoundTag
import top.mcfpp.nbt.tags.Tag
import top.mcfpp.util.LogProcessor

abstract class MCFPPPrivateType(parentType: ArrayList<MCFPPType> = arrayListOf()) : MCFPPType(parentType) {

    abstract fun buildReturnVar(): Var<*>

    final override fun build(identifier: String, value: Any?): Var<*> {
        LogProcessor.error("Cannot build var for type: $typeName")
        return UnknownVar(identifier)
    }

    final override fun buildUnConcrete(identifier: String): Var<*> {
        LogProcessor.error("Cannot build var for type: $typeName")
        return UnknownVar(identifier)
    }

    object CommandReturn: MCFPPPrivateType(parentType = arrayListOf(MCFPPBaseType.Any)){

        override fun buildReturnVar(): Var<*> {
            return top.mcfpp.core.lang.CommandReturn.empty
        }

        override val instanceData by lazy {
            CompoundData("CommandReturn","mcfpp").apply {
                extends(MCFPPBaseType.Any.instanceData)
            }
        }

        override val typeName: String
            get() = "CommandReturn"

        override val nbtType: java.lang.Class<out Tag<*>>
            get() = CompoundTag::class.java
    }

    object MCFPPObjectVarType: MCFPPPrivateType() {
        override val typeName: String
            get() = "ObjectVar"

        override fun buildReturnVar(): Var<*> {
            TODO("Not yet implemented")
        }
    }

    object MCFPPCoordinateDimension: MCFPPPrivateType(){
        override val typeName: String
            get() = "CoordinateDimension"

        override fun buildReturnVar(): Var<*> {
            TODO("Not yet implemented")
        }
    }

    object Void: MCFPPPrivateType(arrayListOf()){
        override fun buildReturnVar(): Var<*> {
            return top.mcfpp.core.lang.Void
        }

        override val objectData: CompoundData
            get() = top.mcfpp.core.lang.Void.data

        override val typeName: String
            get() = "void"

    }

    object Null: MCFPPPrivateType(arrayListOf()){
        override fun buildReturnVar(): Var<*> {
            return top.mcfpp.core.lang.Null
        }

        override val objectData: CompoundData
            get() = top.mcfpp.core.lang.Null.data

        override val typeName: String
            get() = "null"

    }

}package top.mcfpp.core.lang

import top.mcfpp.annotations.InsertCommand
import top.mcfpp.command.Command
import top.mcfpp.command.Commands
import top.mcfpp.core.lang.bool.CommandBoolPart
import top.mcfpp.core.lang.bool.ExecuteBool
import top.mcfpp.core.lang.bool.ScoreBoolConcrete
import top.mcfpp.core.lang.nbt.MCLong
import top.mcfpp.core.lang.nbt.MCLongConcrete
import top.mcfpp.core.lang.nbt.NBTBasedData
import top.mcfpp.core.lang.nbt.NBTBasedDataConcrete
import top.mcfpp.core.lang.obj.DataTemplateObject
import top.mcfpp.core.lang.obj.EnumVar
import top.mcfpp.core.lang.obj.EnumVarConcrete
import top.mcfpp.model.FieldContainer
import top.mcfpp.model.function.


 not an issue really.
                            }
                        }
                        None => {
                            console_log!("state machine channel closed, exiting state machine handler");
                            return;
                        }
                    }
                }
                res = state_get_rx.next() => {
                    match res {
                        Some((k, resp_tx)) => {
                            let val = state.get(k);
                            let _res = resp_tx.send(val);
                        }
                        None => {
                            console_log!("state get channel closed, exiting state machine handler");
                            return;
                        }
                    }
                }
            }
        }
    }

    fn generate_node_id(hostname: &str, session_key: u128) -> NodeId {
        let mut h = DefaultHasher::new();
        hostname.hash(&mut h);
        session_key.hash(&mut h);
        h.finish()
    }

    fn load_peer_configuration(session_key: u128) -> Option<Vec<NodeId>> {
        let key = Self::peer_configuration_key(session_key);
        if let Some(s) = Self::storage().get_item(&key).unwrap() {
            let mut data = Cursor::new(s);
            let buf = base64::read::DecoderReader::new(&mut data, base64::STANDARD);
            let conf = bincode::deserialize_from(buf).unwrap();
            Some(conf)
        } else {
            None
        }
    }

    fn store_peer_configuration(session_key: u128, peers: &[NodeId]) {
        let key = Self::peer_configuration_key(session_key);
        let mut buf = EncoderStringWriter::new(base64::STANDARD);
        bincode::serialize_into(&mut buf, peers).unwrap();
        let data = buf.into_inner();

        Self::storage().set_item(&key, &data).unwrap();
    }

    fn peer_configuration_key(session_key: u128) -> String {
        format!("peer-configuration-{}", session_key)
    }

    fn storage() -> web_sys::Storage {
        let window = web_sys::window().expect("no global window");
        window.local_storage().expect("no local storage").unwrap()
    }
}

impl<St: State> Stream for Raft<St> {
    type Item = St::Notification;

    fn poll_next(
        mut self: std::pin::Pin<&mut Self>,
        cx: &mut std::task::Context<'_>,
    ) -> std::task::Poll<Option<Self::Item>> {
        self.updates_rx.poll_next_unpin(cx)
    }

    fn size_hint(&self) -> (usize, Option<usize>) {
        self.updates_rx.size_hint()
    }
}

pub trait Command: Serialize + DeserializeOwned + Debug + Send + 'static {}

pub trait State: Serialize + DeserializeOwned + Default + 'static {
    type Command: Command;
    type Item;
    type Key;
    type Notification;

    fn apply(&mut self, cmd: Self::Command) -> Self::Notification;
    fn get(&self, key: Self::Key) -> Option<Self::Item>;
}

#[derive(Serialize, Deserialize, Debug)]
pub enum HashMapCommand<K, V> {
    Set(K, V),
    Delete(K),
}

impl<K, V> Command for HashMapCommand<K, V>
where
    K: Serialize + DeserializeOwned + std::cmp::Eq + std::hash::Hash + Send + Debug + 'static,
    V: Serialize + DeserializeOwned + Send + Debug + 'static,
{
}

impl<K, V, S> State for HashMap<K, V, S>
where
    K: Serialize
        + DeserializeOwned
        + Clone
        + std::cmp::Eq
        + std::hash::Hash
        + Send
        + Debug


 can support any scenario. Functional arguments allow overriding without
   * risks that come with subclasses.
   *
   * For example, the default behavior of adjust tone at max contrast to be at a 7.0 ratio with its
   * background is principled and matches accessibility guidance. That does not mean it's the
   * desired approach for _every_ design system, and every color pairing, always, in every case.
   *
   * For opaque colors (colors with alpha = 100%).
   *
   * @param name The name of the dynamic color.
   * @param palette Function that provides a TonalPalette given DynamicScheme. A TonalPalette is
   *   defined by a hue and chroma, so this replaces the need to specify hue/chroma. By providing a
   *   tonal palette, when contrast adjustments are made, intended chroma can be preserved.
   * @param tone Function that provides a tone, given a DynamicScheme.
   * @param isBackground Whether this dynamic color is a background, with some other color as the
   *   foreground.
   * @param background The background of the dynamic color (as a function of a `DynamicScheme`), if
   *   it exists.
   * @param secondBackground A second background of the dynamic color (as a function of a
   *   `DynamicScheme`), if it exists.
   * @param contrastCurve A `ContrastCurve` object specifying how its contrast against its
   *   background should behave in various contrast levels options.
   * @param toneDeltaPair A `ToneDeltaPair` object specifying a tone delta constraint between two
   *   colors. One of them must be the color being constructed.
   * @param opacity A function returning the opacity of a color, as a number between 0 and 1.
   */
  constructor(
    name: String,
    palette: (DynamicScheme) -> TonalPalette,
    tone: (DynamicScheme) -> Double,
    isBackground: Boolean,
    background: ((DynamicScheme) -> DynamicColor?)?,
    secondBackground: ((DynamicScheme) -> DynamicColor?)?,
    contrastCurve: ContrastCurve?,
    toneDeltaPair: ((DynamicScheme) -> ToneDeltaPair?)?,
    opacity: ((DynamicScheme) -> Double?)?,
  ) : this(
    name,
    palette,
    tone,
    isBackground,
    chromaMultiplier = null,
    background,
    secondBackground,
    if (contrastCurve == null) null else { _ -> contrastCurve },
    toneDeltaPair,
    opacity,
  )

  /**
   * Returns an ARGB integer (i.e. a hex code).
   *
   * @param scheme Defines the conditions of the user interface, for example, whether or not it is
   *   dark mode or light mode, and what the desired contrast level is.
   */
  fun getArgb(scheme: DynamicScheme): Int {
    val argb = getHct(scheme).toInt()
    val opacityPercentage = opacity?.invoke(scheme)
    return if (opacityPercentage == null) {
      argb
    } else {
      val alpha = MathUtils.clampInt(0, 255, (opacityPercentage * 255).roundToInt())
      (argb and 0x00ffffff) or (alpha shl 24)
    }
  }

  /**
   * Returns an HCT object.
   *
   * @param scheme Defines the conditions of the user interface, for example, whether or not it is
   *   dark mode or light mode, and what the desired contrast level is.
   */
  fun getHct(scheme: DynamicScheme): Hct {
    val cachedAnswer = hctCache[scheme]
    if (cachedAnswer != null) {
      return cachedAnswer
    }
    val answer = ColorSpecs.get(scheme.specVersion).getHct(scheme, this)
    // NOMUTANTS--trivial test with onerous dependency injection requirement.
    if (hctCache.size > 4) {
      hctCache.clear()
    }
    // NOMUTANTS--trivial test with onerous dependency injection requirement.
    hctCache[scheme] = answer
    return answer
  }

  /** Returns the tone in HCT, ranging


onAssert.AreEqual(new string[]
                                          {
                                              "No game versions specified!",
                                              " ",
                                          }.Concat(help),
                                          user.RaisedErrors);
            }
        }
    }
}


 from 'src/models/category';

@Injectable()
export class CategoryService extends HttpService {

    constructor(protected http: HttpClient) {
        super(http);
        this.apiUrl += 'category';
    };

    /**
     * Obtiene las categorías desde el servidor
     */
    public list() {
        return this.http.get(this.apiUrl, { headers: this.headers });
    }

    /**
     * Crea una nueva categoría
     * @param category Categoría a ser creada
     */
    public create(category: Category) {
        return this.http.post(this.apiUrl, category.JSON() ,{ headers: this.headers });
    }

    /**
     * Obtiene una categoría
     * @param id Identificador de la categoría
     */
    public get(id: string) {
        return this.http.get(`${this.apiUrl}/${id}`, { headers: this.headers });
    }

    /**
     * Actualiza una categoría
     * @param id Identificador de la categoría
     * @param category Contiene la nueva información de la categoría
     */
    public update(id: string, category: Category) {
        return this.http.put(`${this.apiUrl}/${id}`, category.JSON(), { headers: this.headers });
    }

    /**
     * Elimina una categoría
     * @param id Identificador de la categoría
     */
    public delete(id: string) {
        return this.http.delete(`${this.apiUrl}/${id}`, { headers: this.headers });
    }
}import { SpreadSheetDatastore } from "datastore/index";
import { Spreadsheet } from "gas-lib/Spreadsheet";
import { IIntakeValues } from "model/index";
import { advanceTo } from "jest-date-mock";
import { mocked } from "ts-jest/utils";
import {
  createIntakeValues,
  createMakerSheet,
  createMaker,
  createMakerValues,
  createIntakeSheet,
  createSuppliValues,
  createSuppliSheet,
  createSuppliAmountValues,
  createSuppliAmountSheet,
  createTimingValues,
  createTimingSheet,
  createTypeValues,
  createTypeSheet,
  createIntakeDetailValues
} from "test/index";
import { IIntakeDetailValues } from "model/IntakeDetail";

jest.mock("gas-lib/Spreadsheet");

let getAllValuesRV: Array<Array<string | number>>;
let spreadSheetDatastore: SpreadSheetDatastore;
let configure: { spreadSheetId: string };

beforeAll(() => {
  configure = { spreadSheetId: "" };
  getAllValuesRV = [];
});

beforeEach(() => {
  mocked(Spreadsheet.openById).mockReturnValue(Spreadsheet.prototype);
  mocked(Spreadsheet.prototype.getAllValues).mockReturnValue(getAllValuesRV);
  spreadSheetDatastore = new SpreadSheetDatastore(configure);
});

afterEach(() => {
  jest.clearAllMocks();
});

describe("スプレッドシートの操作確認", () => {
  beforeAll(() => {
    configure = { spreadSheetId: "hoge" };
  });
  beforeEach(() => {
    new SpreadSheetDatastore(configure);
  });
  it("指定したIDのスプレッドシートが開かれること", () => {
    expect(Spreadsheet.openById).toBeCalledWith("hoge");
  });
});
describe("キャッシュの確認", () => {
  const sheetValues = createMakerSheet([createMaker(), createMaker()]);
  beforeAll(() => {
    getAllValuesRV = sheetValues;
  });
  beforeEach(() => {
    spreadSheetDatastore.fetchMa


Sps, pLayerInfo.pPps);

      if ((iLastIdD < 0) ||  //case 1: first layer
          (iLastIdD == iCurrIdD)) { //case 2: same uiDId
        InitDqLayerInfo (dq_cur, &pLayerInfo, pNalCur, pCtx->pDec);

        if (!dq_cur->sLayerInfo.pSps->bGapsInFrameNumValueAllowedFlag) {
          const bool kbIdrFlag = dq_cur->sLayerInfo.sNalHeaderExt.bIdrFlag
                                 || (dq_cur->sLayerInfo.sNalHeaderExt.sNalUnitHeader.eNalUnitType == NAL_UNIT_CODED_SLICE_IDR);
          // Subclause 8.2.5.2 Decoding process for gaps in frame_num
          int32_t iPrevFrameNum = pCtx->pLastDecPicInfo->iPrevFrameNum;
          if (pLastThreadCtx != NULL) {
            //call GetPrevFrameNum() to get correct iPrevFrameNum to prevent frame gap warning
            iPrevFrameNum = pCtx->bNewSeqBegin ? 0 : GetPrevFrameNum (pCtx);
          }
          if (!kbIdrFlag  &&
              pSh->iFrameNum != iPrevFrameNum &&
              pSh->iFrameNum != ((iPrevFrameNum + 1) & ((1 << dq_cur->sLayerInfo.pSps->uiLog2MaxFrameNum) -
                                 1))) {
            WelsLog (& (pCtx->sLogCtx), WELS_LOG_WARNING,
                     "referencing pictures lost due frame gaps exist, prev_frame_num: %d, curr_frame_num: %d",
                     iPrevFrameNum,
                     pSh->iFrameNum);

            bAllRefComplete = false;
            pCtx->iErrorCode |= dsRefLost;
            if (pCtx->pParam->eEcActiveIdc == ERROR_CON_DISABLE) {
#ifdef LONG_TERM_REF
              pCtx->bParamSetsLostFlag = true;
#else
              pCtx->bReferenceLostAtT0Flag = true;
#endif
              return GENERATE_ERROR_NO (ERR_LEVEL_SLICE_HEADER, ERR_INFO_REFERENCE_PIC_LOST);
            }
          }
        }

        if (iCurrIdD == kuiDependencyIdMax && iCurrIdQ == BASE_QUALITY_ID && isNewFrame) {
          iRet = InitRefPicList (pCtx, pCtx->uiNalRefIdc, pSh->iPicOrderCntLsb);
          if (iThreadCount > 1) isNewFrame = false;
          if (iRet) {
            pCtx->bRPLRError = true;
            bAllRefComplete = false; // RPLR error, set ref pictures complete flag false
            HandleReferenceLost (pCtx, pNalCur);
            WelsLog (& (pCtx->sLogCtx), WELS_LOG_DEBUG,
                     "reference picture introduced by this frame is lost during transmission! uiTId: %d",
                     pNalCur->sNalHeaderExt.uiTemporalId);
            if (pCtx->pParam->eEcActiveIdc == ERROR_CON_DISABLE) {
              if (pCtx->iTotalNumMbRec == 0)
                pCtx->pDec = NULL;
              return iRet;
            }
          }
        }
        //calculate Colocated mv scaling factor for temporal direct prediction
        if (pSh->eSliceType == B_SLICE && !pSh->iDirectSpatialMvPredFlag)
          ComputeColocatedTemporalScaling (pCtx);

        if (iThreadCount > 1) {
          if (iIdx == 0) {
            memset (&pCtx->lastReadyHeightOffset[0][0], -1, LIST_A * MAX_REF_PIC_COUNT * sizeo


  }

  @$pb.TagNumber(7)
  $core.bool hasAllowsAdminOverrides() => $_has(3);
  @$pb.TagNumber(7)
  void clearAllowsAdminOverrides() => clearField(7);

  ///  The name of the parent metric of this limit.
  ///
  ///  An example name would be:
  ///  `compute.googleapis.com/cpus`
  @$pb.TagNumber(8)
  $core.String get metric => $_getSZ(4);
  @$pb.TagNumber(8)
  set metric($core.String v) {
    $_setString(4, v);
  }

  @$pb.TagNumber(8)
  $core.bool hasMetric() => $_has(4);
  @$pb.TagNumber(8)
  void clearMetric() => clearField(8);

  /// Summary of the enforced quota buckets, organized by quota dimension,
  /// ordered from least specific to most specific (for example, the global
  /// default bucket, with no quota dimensions, will always appear first).
  @$pb.TagNumber(9)
  $core.List<QuotaBucket> get quotaBuckets => $_getList(5);

  /// List of all supported locations.
  /// This field is present only if the limit has a {region} or {zone} dimension.
  @$pb.TagNumber(11)
  $core.List<$core.String> get supportedLocations => $_getList(6);
}

/// A quota bucket is a quota provisioning unit for a specific set of dimensions.
class QuotaBucket extends $pb.GeneratedMessage {
  factory QuotaBucket({
    $fixnum.Int64? effectiveLimit,
    $fixnum.Int64? defaultLimit,
    QuotaOverride? producerOverride,
    QuotaOverride? consumerOverride,
    QuotaOverride? adminOverride,
    $core.Map<$core.String, $core.String>? dimensions,
    ProducerQuotaPolicy? producerQuotaPolicy,
  }) {
    final $result = create();
    if (effectiveLimit != null) {
      $result.effectiveLimit = effectiveLimit;
    }
    if (defaultLimit != null) {
      $result.defaultLimit = defaultLimit;
    }
    if (producerOverride != null) {
      $result.producerOverride = producerOverride;
    }
    if (consumerOverride != null) {
      $result.consumerOverride = consumerOverride;
    }
    if (adminOverride != null) {
      $result.adminOverride = adminOverride;
    }
    if (dimensions != null) {
      $result.dimensions.addAll(dimensions);
    }
    if (producerQuotaPolicy != null) {
      $result.producerQuotaPolicy = producerQuotaPolicy;
    }
    return $result;
  }
  QuotaBucket._() : super();
  factory QuotaBucket.fromBuffer($core.List<$core.int> i,
          [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) =>
      create()..mergeFromBuffer(i, r);
  factory QuotaBucket.fromJson($core.String i,
          [$pb.ExtensionRegistry r = $pb.ExtensionRegistry.EMPTY]) =>
      create()..mergeFromJson(i, r);

  static final $pb.BuilderInfo _i = $pb.BuilderInfo(
      _omitMessageNames ? '' : 'QuotaBucket',
      package: const $pb.PackageName(
          _omitMessageNames ? '' : 'google.api.serviceusage.v1beta1'),
      createEmptyInstance: create)
    ..aInt64(1, _omitFieldNames ? '' : 'effectiveLimit')
    ..aInt64(2, _omitFieldNames ? '' : 'defaultLimit')
    ..aOM<QuotaOverride>(3, _omitFieldNames ? '' : 'producerOverride',
        subBuilder: QuotaOverride.create)
    ..aOM<QuotaOverride>(4, _omitFieldNames ? '' : 'consumerOverride',
        subBuilder: QuotaOverride.crea