;let w="";const v=g.height*2+g.diagramMarginY,b=f+v;let E=0,_="#CCC",S="black",I=0;for(const[B,F]of a.entries()){if(w!==F.section){_=Jbt[E%Jbt.length],I=E%Jbt.length,S=aHt[E%aHt.length];let q=0;const X=F.section;for(let at=B;at<a.length&&a[at].section==X;at++)q=q+1;const rt={x:B*g.taskMargin+B*g.width+B9,y:50,text:F.section,fill:_,num:I,colour:S,taskCount:q};yB.drawSection(i,rt,g),w=F.section,E++}const R=F.people.reduce((q,X)=>(zx[X]&&(q[X]=zx[X]),q),{});F.x=B*g.taskMargin+B*g.width+B9,F.y=b,F.width=g.diagramMarginX,F.height=g.diagramMarginY,F.colour=S,F.fill=_,F.num=I,F.actors=R,yB.drawTask(i,F,g),Xw.insert(F.x,F.y,F.x+F.width+g.taskMargin,300+5*30)}},oHt={setConf:qZe,draw:VZe},GZe=Object.freeze(Object.defineProperty({__proto__:null,diagram:{parser:AZe,db:eHt,renderer:oHt,styles:FZe,init:i=>{oHt.setConf(i.journey),eHt.clear()}}},Symbol.toStringTag,{value:"Module"})),KZe=(i,a,f)=>{const{parentById:g}=f,w=new Set;let v=i;for(;v;){if(w.add(v),v===a)return v;v=g[v]}for(v=a;v;){if(w.has(v))return v;v=g[v]}return"root"};function _X(i){throw new Error('Could not dynamically require "'+i+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var cHt={exports:{}};(function(i,a){(function(f){i.exports=f()})(function(){return function(){function f(g,w,v){function b(S,I){if(!w[S]){if(!g[S]){var B=typeof _X=="function"&&_X;if(!I&&B)return B(S,!0);if(E)return E(S,!0);var F=new Error("Cannot find module '"+S+"'");throw F.code="MODULE_NOT_FOUND",F}var R=w[S]={exports:{}};g[S][0].call(R.exports,function(q){var X=g[S][1][q];return b(X||q)},R,R.exports,f,g,w,v)}return w[S].exports}for(var E=typeof _X=="function"&&_X,_=0;_<v.length;_++)b(v[_]);return b}return f}()({1:[function(f,g,w){Object.defineProperty(w,"__esModule",{value:!0});var v=function(){function S(I,B){for(var F=0;F<B.length;F++){var R=B[F];R.enumerable=R.enumerable||!1,R.configurable=!0,"value"in R&&(R.writable=!0),Object.defineProperty(I,R.key,R)}}return function(I,B,F){return B&&S(I.prototype,B),F&&S(I,F),I}}();function b(S,I){if(!(S instanceof I))throw new TypeError("Cannot call a class as a function")}var E=function(){function S(){var I=this,


,13668,13669,13670,13671,13672,13673,13674,13675,13676,13677,13678,13679,13680, //13680
        13681,13682,13683,13684,13685,13686,13687,13688,13689,13690,13691,13692,13693,13694,13695,13696, //13696
        13697,13698,13699,13700,13701,13702,13703,13704,13705,13706,13707,13708,13709,13710,13711,13712, //13712
        13713,13714,13715,13716,13717,13718,13719,13720,13721,13722,13723,13724,13725,13726,13727,13728, //13728
        13729,13730,13731,13732,13733,13734,13735,13736,13737,13738,13739,13740,13741,13742,13743,13744, //13744
        13745,13746,13747,13748,13749,13750,13751,13752,13753,13754,13755,13756,13757,13758,13759,13760, //13760
        13761,13762,13763,13764,13765,13766,13767,13768,13769,13770,13771,13772,13773,13774,3273,13775, //13776
        13776,13777,13778,13779,13780,13781,13782,13783,13784,13785,13786,13787,13788,13789,13790,13791, //13792
        13792,13793,13794,13795,13796,13797,13798,13799,13800,13801,13802,13803,13804,13805,13806,13807, //13808
        13808,13809,13810,13811,13812,13813,13814,13815,13816,13817,13818,13819,13820,13821,13822,13823, //13824
        13824,13825,13826,13827,13828,13829,13830,13831,13832,13833,13834,13835,13836,13837,13838,13839, //13840
        13840,13841,13842,13843,13844,13845,13846,13847,13848,13849,13850,13851,13852,13853,13854,13855, //13856
        13856,13857,13858,13859,13860,13861,13862,13863,13864,13865,13866,13867,13868,13869,13870,13871, //13872
        13872,13873,13874,13875,13876,13877,13878,13879,13880,13881,13882,13883,13884,13885,13886,13887, //13888
        13888,13889,13890,13891,13892,13893,13894,13895,13896,13897,13898,13899,13900,13901,13902,13903, //13904
        13904,13905,13906,13907,13908,13909,13910,13911,13912,13913,13914,13915,13916,13917,13918,13919, //13920
        13920,13921,13922,13923,13924,13925,13926,13927,13928,13929,13930,13931,13932,13933,13934,13935, //13936
        13936,13937,13938,13939,13940,13941,13942,13943,13944,13945,13946,13947,13948,13949,13950,13951, //13952
        13952,13953,13954,13955,13956,13957,13958,13959,13960,13961,13962,13963,13964,13965,13966,13967, //13968
        13968,13969,13970,13971,13972, //13973
        ****************************************************************************************/
        };

        public BIG5DistributionAnalyser()
        {
            charToFreqOrder = BIG5_CHAR2FREQ_ORDER;
            tableSize = BIG5_TABLE_SIZE;
            typicalDistributionRatio = BIG5_TYPICAL_DISTRIBUTION_RATIO;


            .expect("Failed to generate random number")
            .expose();
        let invite_token = data_encoding::BASE64URL.encode(&random_bytes);

        const TEAM_CAPACITY: i32 = 10;
        let within_capacity: Option<(i32,)> = locked_tx.exec_first(
            "SELECT COUNT(*) < ? AS `within_capacity` FROM `teams`",
            (TEAM_CAPACITY,),
        )?;
        if within_capacity.unwrap_or((0,)).0 != 1 {
            return Err(crate::Error::UserError(StatusCode::FORBIDDEN, "チーム登録数上限です"));
        }

        locked_tx.exec_drop("INSERT INTO `teams` (`name`, `email_address`, `invite_token`, `created_at`) VALUES (?, ?, ?, NOW(6))", (req.team_name, req.email_address, invite_token))?;
        let team_id: Option<(i64,)> = locked_tx.query_first("SELECT LAST_INSERT_ID() AS `id`")?;
        if team_id.is_none() {
            return Err(crate::Error::ServerError(StatusCode::INTERNAL_SERVER_ERROR, "チームを登録できませんでした"));
        }
        let team_id = team_id.unwrap().0;

        locked_tx.exec_drop("UPDATE `contestants` SET `name` = ?, `student` = ?, `team_id` = ? WHERE `id` = ? LIMIT 1", (req.name, req.is_student, team_id, &current_contestant.id))?;

        locked_tx.exec_drop("UPDATE `teams` SET `leader_id` = ? WHERE `id` = ? LIMIT 1", (&current_contestant.id, team_id))?;

        let tx = locked_tx.finish()?;
        tx.commit()?;
        Ok(team_id)
    })
    .await.map_err(crate::unwrap_blocking_error)?;

    HttpResponse::Ok().protobuf(CreateTeamResponse { team_id })
}

#[derive(Debug, serde::Deserialize)]
pub struct GetSessionQuery {
    pub team_id: Option<i64>,
    pub invite_token: Option<String>,
}

pub async fn get_session(
    session: Session,
    db: web::Data<crate::Pool>,
    query: web::Query<GetSessionQuery>,
) -> Result<HttpResponse, AWError> {
    let contestant_id: Option<String> = session.get("contestant_id")?;
    let query = query.0;

    let resp = web::block(move || {
        let mut conn = db.get().expect("Failed to checkout database connection");
        let current_contestant = crate::get_current_contestant(conn.deref_mut(), &contestant_id, false)?;
        let current_team = if let Some(ref current_contestant) = current_contestant {
            crate::get_current_team(conn.deref_mut(), current_contestant, false)?
        } else {
            None
        };
        let team = if current_team.is_some() {
            current_team.clone()
        } else if let (Some(team_id), Some(invite_token)) = (query.team_id, query.invite_token) {
            let t = conn.exec_first("SELECT * FROM `teams` WHERE `id` = ? AND `invite_token` = ? AND `withdrawn` = FALSE LIMIT 1", (team_id, invite_token))?;
            if t.is_some() {
                t
            } else {
                return Err(crate::Error::UserError(StatusCode::NOT_FOUND, "招待URLが無効です"));
            }
        } else {
            None
        };
        let members: Vec<crate::Contestant> = if let Some(ref team) = team {
            conn.exec("SELECT * FROM `contestants` WHERE `team_id` = ?", (team.id,))?
        } else {
            vec![]
        };

        use crate::proto::servic


    /// To leverage the state that the ViewDependentState provides you need to set up the graphics pipelines with the vsg::ViewDescriptorSetLayout,
    /// and add a vsg::BindViewDescriptorSet to a StateGroup.  You don't need to explicitly add these if you have created your scene graph using
    /// vsg::Builder or used loaders like vsgXchange::Assimp.
    class VSG_DECLSPEC ViewDependentState : public Inherit<Object, ViewDependentState>
    {
    public:
        explicit ViewDependentState(View* in_view);

        template<class N, class V>
        static void t_traverse(N& node, V& visitor)
        {
            node.descriptorSet->accept(visitor);
            if (node.preRenderCommandGraph) node.preRenderCommandGraph->accept(visitor);
        }

        void traverse(Visitor& visitor) override { t_traverse(*this, visitor); }
        void traverse(ConstVisitor& visitor) const override { t_traverse(*this, visitor); }
        void traverse(RecordTraversal& rt) const override;

        // containers filled in by RecordTraversal
        std::vector<std::pair<dmat4, const AmbientLight*>> ambientLights;
        std::vector<std::pair<dmat4, const DirectionalLight*>> directionalLights;
        std::vector<std::pair<dmat4, const PointLight*>> pointLights;
        std::vector<std::pair<dmat4, const SpotLight*>> spotLights;

        virtual void init(ResourceRequirements& requirements);
        virtual void update(ResourceRequirements& requirements);

        virtual void clear();
        virtual void bindDescriptorSets(CommandBuffer& commandBuffer, VkPipelineBindPoint pipelineBindPoint, VkPipelineLayout layout, uint32_t firstSet);

        virtual void compile(Context& context);

        View* view = nullptr;

        // ShaderSet to guide the set up of lightData, viewportData and shadowMap Descriptors & DescriptorSet(s).
        ref_ptr<ShaderSet> shaderSet;

        ref_ptr<vec4Array> lightData;
        ref_ptr<BufferInfo> lightDataBufferInfo;

        ref_ptr<vec4Array> viewportData;
        ref_ptr<BufferInfo> viewportDataBufferInfo;

        ref_ptr<Image> shadowDepthImage;

        ref_ptr<DescriptorSetLayout> descriptorSetLayout;
        ref_ptr<DescriptorSet> descriptorSet;

        // shadow map hints
        double maxShadowDistance = 1e8;
        double shadowMapBias = 0.005;
        double lambda = 0.5;

        // map of Light's that we wish to override their ShadowSettings,
        // assigning shadowSettingsOverride[{}] = shadowSettings will override all Light not otherwise explicitly matched.
        std::map<ref_ptr<const Light>, ref_ptr<ShadowSettings>> shadowSettingsOverride;

        virtual ref_ptr<ShadowSettings> getActiveShadowSettings(const Light* light) const;

        // Shadow backend.
        bool compiled = false;
        ref_ptr<CommandGraph> preRenderCommandGraph;
        ref_ptr<Switch> preRenderSwitch;

        struct ShadowMap
        {
            ref_ptr<RenderGraph> renderGraph;
            ref_ptr<View> view;
        };

        mutable std::vector<ShadowMap> shadowMaps;

    protected:
        ~ViewDependentState();
    };
    VSG_type_name(vsg::ViewDependentState);

} // namespace vsg


run()).Should(BeNil())
	})
})

func TestGenCountInfo(t *testing.T) {
	testcases := []struct {
		count int
		res   string
	}{
		{
			count: 3,
			res:   "<10",
		},
		{
			count: 14,
			res:   "<50",
		},
		{
			count: 80,
			res:   "<100",
		},
		{
			count: 350,
			res:   "<500",
		},
		{
			count: 1800,
			res:   "<2000",
		},
		{
			count: 4000,
			res:   "<5000",
		},
		{
			count: 9000,
			res:   "<10000",
		},
		{
			count: 30000,
			res:   ">=10000",
		},
	}
	for _, testcase := range testcases {
		assert.Equal(t, genCountInfo(testcase.count), testcase.res)
	}
}

func TestGenClusterCountInfo(t *testing.T) {
	testcases := []struct {
		count int
		res   string
	}{
		{
			count: 2,
			res:   "<3",
		},
		{
			count: 7,
			res:   "<10",
		},
		{
			count: 34,
			res:   "<50",
		},
		{
			count: 90,
			res:   "<100",
		},
		{
			count: 137,
			res:   "<150",
		},
		{
			count: 170,
			res:   "<200",
		},
		{
			count: 270,
			res:   "<300",
		},
		{
			count: 400,
			res:   "<500",
		},
		{
			count: 520,
			res:   ">=500",
		},
	}
	for _, testcase := range testcases {
		assert.Equal(t, genClusterCountInfo(testcase.count), testcase.res)
	}
}

func TestTopKFrequent(t *testing.T) {
	testCases := []struct {
		def map[string]int
		k   int
		res []string
	}{
		{
			def: map[string]int{
				"rollout": 4,
				"patch":   3,
				"expose":  6,
			},
			k:   3,
			res: []string{"expose", "rollout", "patch"},
		},
		{
			// just return top2
			def: map[string]int{
				"rollout": 4,
				"patch":   3,
				"expose":  6,
			},
			k:   2,
			res: []string{"expose", "rollout"},
		},
	}
	for _, testCase := range testCases {
		assert.DeepEqual(t, topKFrequent(testCase.def, testCase.k), testCase.res)
	}
}

type DataExistMatcher struct{}

// Match matches error.
func (matcher DataExistMatcher) Match(actual interface{}) (success bool, err error) {
	if actual == nil {
		return false, nil
	}
	actualError := actual.(error)
	return errors.Is(actualError, datastore.ErrRecordExist), nil
}

// FailureMessage builds an error message.
func (matcher DataExistMatcher) FailureMessage(actual interface{}) (message string) {
	return format.Message(actual, "to be already exist")
}

// NegatedFailureMessage builds an error message.
func (matcher DataExistMatcher) NegatedFailureMessage(actual interface{}) (message string) {
	return format.Message(actual, "not to be already exist")
}
package populator

import (
	"context"
	"fmt"

	"github.com/kubev2v/forklift/cmd/vsphere-xcopy-volume-populator/internal/vmware"
	"github.com/vmware/govmomi/object"
	"k8s.io/klog/v2"
)

// SSHTaskExecutor implements TaskExecutor for the SSH method
type SSHTaskExecutor struct {
	SSHClient vmware.SSHClient
}

func NewSSHTaskExecutor(sshClient vmware.SSHClient) TaskExecutor {
	return &SSHTaskExecutor{
		SSHClient: sshClient,
	}
}

func (e *SSHTaskExecutor) StartClone(ctx context.Cont


(ACTION_ACCESSIBILITY_SETTINGS != action) {
                data = Uri.parse("package:" + context.packageName)
            }
        })
    } catch (e: Exception) {
        e.printStackTrace()
    }
}

class AudioReader(val bufSize: Int, private val maxFrames: Int) {
    private var currentPos = 0
    private val bufferPool: Array<ByteBuffer>

    init {
        if (maxFrames < 0 || maxFrames > 32) {
            throw Exception("Out of bounds")
        }
        if (bufSize <= 0) {
            throw Exception("Wrong bufSize")
        }
        bufferPool = Array(maxFrames) {
            ByteBuffer.allocateDirect(bufSize)
        }
    }

    private fun next() {
        currentPos++
        if (currentPos >= maxFrames) {
            currentPos = 0
        }
    }

    @RequiresApi(Build.VERSION_CODES.M)
    fun readSync(audioRecord: AudioRecord): ByteBuffer? {
        val buffer = bufferPool[currentPos]
        val res = audioRecord.read(buffer, bufSize, READ_BLOCKING)
        return if (res > 0) {
            next()
            buffer
        } else {
            null
        }
    }
}

fun getScreenSize(windowManager: WindowManager) : Pair<Int, Int>{
    var w = 0
    var h = 0
    @Suppress("DEPRECATION")
    if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) {
        val m = windowManager.maximumWindowMetrics
        w = m.bounds.width()
        h = m.bounds.height()
    } else {
        val dm = DisplayMetrics()
        windowManager.defaultDisplay.getRealMetrics(dm)
        w = dm.widthPixels
        h = dm.heightPixels
    }
    return Pair(w, h)
}

 fun translate(input: String): String {
    Log.d("common", "translate:$LOCAL_NAME")
    return FFI.translateLocale(LOCAL_NAME, input)
}package com.carriez.flutter_hbb

/**
 * Handle remote input and dispatch android gesture
 *
 * Inspired by [droidVNC-NG] https://github.com/bk138/droidVNC-NG
 */

import android.accessibilityservice.AccessibilityService
import android.accessibilityservice.GestureDescription
import android.graphics.Path
import android.os.Build
import android.os.Bundle
import android.os.Handler
import android.os.Looper
import android.util.Log
import android.widget.EditText
import android.view.accessibility.AccessibilityEvent
import android.view.ViewGroup.LayoutParams
import android.view.accessibility.AccessibilityNodeInfo
import android.view.KeyEvent as KeyEventAndroid
import android.view.ViewConfiguration
import android.graphics.Rect
import android.media.AudioManager
import android.accessibilityservice.AccessibilityServiceInfo
import android.accessibilityservice.AccessibilityServiceInfo.FLAG_INPUT_METHOD_EDITOR
import android.accessibilityservice.AccessibilityServiceInfo.FLAG_RETRIEVE_INTERACTIVE_WINDOWS
import android.view.inputmethod.EditorInfo
import androidx.annotation.RequiresApi
import java.util.*
import java.lang.Character
import kotlin.math.abs
import kotlin.math.max
import hbb.MessageOuterClass.KeyEvent
import hbb.MessageOuterClass.KeyboardMode
import hbb.KeyEventConverter

// const val BUTTON_UP = 2
// const val BUTTON_BACK = 0x08

const val LEFT_DOWN = 9
const val LEFT_MOVE = 8
const val LEFT_UP = 10
const val RIGHT_UP = 18
// (BUTTON_BACK << 3) | BUTTON_UP
const val BACK_UP = 66
const val WHEEL_BUTTON_DOWN = 33
const val WHEEL_BUTTON_UP = 34


(t,r,f)}var vX,xX=N(()=>{"use strict";A9();_9();L9();R9();M9();J0();Un();ow();tm();Yv();Js();aX();r2();P9();yX();o(JSe,"baseMergeDeep");vX=JSe});function bX(t,e,r,n,i){t!==e&&X0(e,function(a,s){if(i||(i=new lc),bn(a))vX(t,e,s,r,bX,n,i);else{var l=n?n(n2(t,s),a,s+"",t,e,i):void 0;l===void 0&&(l=a),Jv(t,s,l)}},Cs)}var wX,TX=N(()=>{"use strict";Zv();A9();Z5();xX();Js();Bh();P9();o(bX,"baseMerge");wX=bX});function eCe(t){return t}var ta,Cu=N(()=>{"use strict";o(eCe,"identity");ta=eCe});function tCe(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}var kX,EX=N(()=>{"use strict";o(tCe,"apply");kX=tCe});function rCe(t,e,r){return e=SX(e===void 0?t.length-1:e,0),function(){for(var n=arguments,i=-1,a=SX(n.length-e,0),s=Array(a);++i<a;)s[i]=n[e+i];i=-1;for(var l=Array(e+1);++i<e;)l[i]=n[i];return l[e]=r(s),kX(t,this,l)}}var SX,cw,F9=N(()=>{"use strict";EX();SX=Math.max;o(rCe,"overRest");cw=rCe});function nCe(t){return function(){return t}}var As,$9=N(()=>{"use strict";o(nCe,"constant");As=nCe});var iCe,CX,AX=N(()=>{"use strict";$9();C9();Cu();iCe=q0?function(t,e){return q0(t,"toString",{configurable:!0,enumerable:!1,value:As(e),writable:!0})}:ta,CX=iCe});function lCe(t){var e=0,r=0;return function(){var n=oCe(),i=sCe-(n-r);if(r=n,i>0){if(++e>=aCe)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var aCe,sCe,oCe,_X,DX=N(()=>{"use strict";aCe=800,sCe=16,oCe=Date.now;o(lCe,"shortOut");_X=lCe});var cCe,uw,z9=N(()=>{"use strict";AX();DX();cCe=_X(CX),uw=cCe});function uCe(t,e){return uw(cw(t,e,ta),t+"")}var fc,nm=N(()=>{"use strict";Cu();F9();z9();o(uCe,"baseRest");fc=uCe});function hCe(t,e,r){if(!bn(r))return!1;var n=typeof e;return(n=="number"?ci(r)&&Ph(e,r.length):n=="string"&&e in r)?Ro(r[e],t):!1}var eo,Ld=N(()=>{"use strict


ocsEditable()
@DomName('WebGLShaderPrecisionFormat')
@Native("WebGLShaderPrecisionFormat")
class ShaderPrecisionFormat extends Interceptor {
  // To suppress missing implicit constructor warnings.
  factory ShaderPrecisionFormat._() { throw new UnsupportedError("Not supported"); }

  @DomName('WebGLShaderPrecisionFormat.precision')
  @DocsEditable()
  final int precision;

  @DomName('WebGLShaderPrecisionFormat.rangeMax')
  @DocsEditable()
  final int rangeMax;

  @DomName('WebGLShaderPrecisionFormat.rangeMin')
  @DocsEditable()
  final int rangeMin;
}
// Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.

@DocsEditable()
@DomName('WebGLTexture')
@Native("WebGLTexture")
class Texture extends Interceptor {
  // To suppress missing implicit constructor warnings.
  factory Texture._() { throw new UnsupportedError("Not supported"); }
}
// Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.

@DocsEditable()
@DomName('WebGLUniformLocation')
@Native("WebGLUniformLocation")
class UniformLocation extends Interceptor {
  // To suppress missing implicit constructor warnings.
  factory UniformLocation._() { throw new UnsupportedError("Not supported"); }
}
// Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.

@DocsEditable()
@DomName('WebGLVertexArrayObjectOES')
// http://www.khronos.org/registry/webgl/extensions/OES_vertex_array_object/
@Experimental() // experimental
@Native("WebGLVertexArrayObjectOES")
class VertexArrayObject extends Interceptor {
  // To suppress missing implicit constructor warnings.
  factory VertexArrayObject._() { throw new UnsupportedError("Not supported"); }
}
// Copyright (c) 2012, the Dart project authors.  Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.

@DocsEditable()
@DomName('WebGLRenderingContextBase')
@Experimental() // untriaged
abstract class _WebGLRenderingContextBase extends Interceptor {
  // To suppress missing implicit constructor warnings.
  factory _WebGLRenderingContextBase._() { throw new UnsupportedError("Not supported"); }
}
// Copyright (c) 2013, the Dart project authors.  Please see the AUTHORS file
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.

import "package:expect/expect.dart";

main() {
  testEmpty(name, it, [depth = 2]) {
    Expect.isTrue(it.isEmpty, name);
    Expect.isFalse(it.isNotEmpty, name);
    Expect.equals(0, it.length, name);
    Expect.isFalse(it.contains(null), name);
    Expect.isFalse(it.any((x)=>true), name);
    Expect.isTrue(it.every((x)=>false), name);
    Expect.throws(() => it.first, (e) => e is StateError, name);
    Expect.throws(() => it.last, (e) => e is StateError, name);
    Expect.throws(() => it.single, (e) => e is State


 if we did nothing.
  Coordinate get currentTarget {
    Coordinate? end = _momentum.destination;
    end ??= _contentOffset;
    return end;
  }

  Coordinate get contentOffset => _contentOffset;

  /// Animate the position of the scroller to the specified [x], [y] coordinates
  /// by applying the throw gesture with the correct velocity to end at that
  /// location.
  void throwTo(num x, num y, [num? decelerationFactor]) {
    reconfigure(() {
      final snappedTarget = _snapToBounds(x, y);
      // If a deceleration factor is not specified, use the existing
      // deceleration factor specified by the momentum simulator.
      decelerationFactor ??= _momentum.decelerationFactor;

      if (snappedTarget != currentTarget) {
        _momentum.abort();

        _startDeceleration(
            _momentum.calculateVelocity(
                _contentOffset, snappedTarget, decelerationFactor),
            decelerationFactor);
        if (_onDecelStart != null) {
          _onDecelStart.add(Event(ScrollerEventType.DECEL_START));
        }
      }
    });
  }

  void throwDelta(num deltaX, num deltaY, [num? decelerationFactor]) {
    Coordinate start = _contentOffset;
    Coordinate end = currentTarget;
    int x = end.x.toInt();
    int y = end.y.toInt();
    // If we are throwing in the opposite direction of the existing momentum,
    // cancel the current momentum.
    if (deltaX != 0 && deltaX.isNegative != (end.x - start.x).isNegative) {
      x = start.x as int;
    }
    if (deltaY != 0 && deltaY.isNegative != (end.y - start.y).isNegative) {
      y = start.y as int;
    }
    x += deltaX.toInt();
    y += deltaY.toInt();
    throwTo(x, y, decelerationFactor);
  }

  void setPosition(num x, num y) {
    _momentum.abort();
    _contentOffset.x = x;
    _contentOffset.y = y;
    _snapContentOffsetToBounds();
    _setContentOffset(_contentOffset.x, _contentOffset.y);
  }

  /// Adjusted content size is a size with the combined largest height and width
  /// of both the content and the frame.
  Size _getAdjustedContentSize() {
    return Size(Math.max(_scrollSize.width, _contentSize.width),
        Math.max(_scrollSize.height, _contentSize.height));
  }

  // TODO(jmesserly): these should be properties instead of get* methods
  num getDefaultVerticalOffset() => _maxPoint.y;
  @override
  Element getElement() => _element;
  Element getFrame() => _frame;
  num getHorizontalOffset() => _contentOffset.x;

  /// [x] Value to use as reference for percent measurement. If
  ///      none is provided then the content's current x offset will be used.
  /// Returns the percent of the page scrolled horizontally.
  num getHorizontalScrollPercent([num? x]) {
    x = x ?? _contentOffset.x;
    return (x - _minPoint.x) / (_maxPoint.x - _minPoint.x);
  }

  num getMaxPointY() => _maxPoint.y;
  num getMinPointY() => _minPoint.y;
  Momentum get momentum => _momentum;

  /// Provide access to the touch handler that the scroller created to manage
  /// touch events.
  TouchHandler getTouchHandler() => _touchHandler;
  num getVerticalOffset() => _contentOffset.y;

  /// [y] value is used as reference for percent measurement. If
  /// none is provided then the content's current y offset will be used.
  num getVerticalScrollPercent([num? y]) {
    y = y ?? _contentOffset.y;
    return (y - _minPoint.y) / Math.max(1, _maxPoint.y - _minPoint.y);
  }

  /// Initialize the dom elements necessary for the scrolling to work.
  void _initLayer() {


//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose:
//
// $NoKeywords: $
//=============================================================================//

#ifndef LABELEDCOMMANDCOMBOBOX_H
#define LABELEDCOMMANDCOMBOBOX_H
#ifdef _WIN32
#pragma once
#endif

#include <vgui_controls/ComboBox.h>
#include <vgui_controls/Label.h>
#include <vgui_controls/Panel.h>
#include "utlvector.h"

class CLabeledCommandComboBox : public vgui::ComboBox
{
	DECLARE_CLASS_SIMPLE( CLabeledCommandComboBox, vgui::ComboBox );

public:
	CLabeledCommandComboBox(vgui::Panel *parent, const char *panelName);
	~CLabeledCommandComboBox();

	virtual void DeleteAllItems();
	virtual void AddItem(char const *text, char const *engineCommand);
	virtual void ActivateItem(int itemIndex);
	const char *GetActiveItemCommand();

	void SetInitialItem(int itemIndex);

	void			ApplyChanges();
	void			Reset();
	bool			HasBeenModified();

	enum
	{
		MAX_NAME_LEN = 256,
		MAX_COMMAND_LEN = 256
	};

private:
	MESSAGE_FUNC_CHARPTR( OnTextChanged, "TextChanged", text );

	struct COMMANDITEM
	{
		char			name[ MAX_NAME_LEN ];
		char			command[ MAX_COMMAND_LEN ];
		int				comboBoxID;
	};

	CUtlVector< COMMANDITEM >	m_Items;
	int		m_iCurrentSelection;
	int		m_iStartSelection;
};

#endif // LABELEDCOMMANDCOMBOBOX_H


 delta, void *data = nullptr) {
        for(auto next = handlers.first().size(); next; --next) {
            if(const auto pos = next - 1u; handlers.first()[pos]->update(delta, data)) {
                // updating might spawn/reallocate, cannot hold refs until here
                if(auto &curr = handlers.first()[pos]; curr->next) {
                    curr = std::move(curr->next);
                    // forces the process to exit the uninitialized state
                    curr->update({}, nullptr);
                } else {
                    curr = std::move(handlers.first().back());
                    handlers.first().pop_back();
                }
            }
        }
    }

    /**
     * @brief Aborts all scheduled processes.
     *
     * Unless an immediate operation is requested, the abort is scheduled for
     * the next tick. Processes won't be executed anymore in any case.<br/>
     * Once a process is fully aborted and thus finished, it's discarded along
     * with its child, if any.
     *
     * @param immediate Requests an immediate operation.
     */
    void abort(const bool immediate = false) {
        for(auto &&curr: handlers.first()) {
            curr->abort(immediate);
        }
    }

private:
    compressed_pair<container_type, allocator_type> handlers;
};

} // namespace entt

#endif

// #include "resource/cache.hpp"
#ifndef ENTT_RESOURCE_RESOURCE_CACHE_HPP
#define ENTT_RESOURCE_RESOURCE_CACHE_HPP

#include <cstddef>
#include <functional>
#include <iterator>
#include <memory>
#include <tuple>
#include <type_traits>
#include <utility>
// #include "../container/dense_map.hpp"
#ifndef ENTT_CONTAINER_DENSE_MAP_HPP
#define ENTT_CONTAINER_DENSE_MAP_HPP

#include <cmath>
#include <cstddef>
#include <functional>
#include <iterator>
#include <limits>
#include <memory>
#include <tuple>
#include <type_traits>
#include <utility>
#include <vector>
// #include "../config/config.h"
#ifndef ENTT_CONFIG_CONFIG_H
#define ENTT_CONFIG_CONFIG_H

// #include "version.h"
#ifndef ENTT_CONFIG_VERSION_H
#define ENTT_CONFIG_VERSION_H

// #include "macro.h"
#ifndef ENTT_CONFIG_MACRO_H
#define ENTT_CONFIG_MACRO_H

#define ENTT_STR(arg) #arg
#define ENTT_XSTR(arg) ENTT_STR(arg)

#endif

#define ENTT_VERSION_MAJOR 3
#define ENTT_VERSION_MINOR 13
#define ENTT_VERSION_PATCH 2

#define ENTT_VERSION \
    ENTT_XSTR(ENTT_VERSION_MAJOR) \
    "." ENTT_XSTR(ENTT_VERSION_MINOR) "." ENTT_XSTR(ENTT_VERSION_PATCH)

#endif

#if defined(__cpp_exceptions) && !defined(ENTT_NOEXCEPTION)
#    define ENTT_CONSTEXPR
#    define ENTT_THROW throw
#    define ENTT_TRY try
#    define ENTT_CATCH catch(...)
#else
#    define ENTT_CONSTEXPR constexpr // use only with throwing functions (waiting for C++20)
#    define ENTT_THROW
#    define ENTT_TRY if(true)
#    define ENTT_CATCH if(false)
#endif

#ifdef ENT


     /// <remarks>
        /// This snippet has been automatically generated and should be regarded as a code template only.
        /// It will require modifications to work:
        /// - It may require correct/in-range values for request initialization.
        /// - It may require specifying regional endpoints when creating the service client as shown in
        ///   https://cloud.google.com/dotnet/docs/reference/help/client-configuration#endpoint.
        /// </remarks>
        public void GetIamPolicy()
        {
            // Create client
            CloudBillingClient cloudBillingClient = CloudBillingClient.Create();
            // Initialize request argument(s)
            string resource = "a/wildcard/resource";
            // Make the request
            Policy response = cloudBillingClient.GetIamPolicy(resource);
        }
    }
    // [END cloudbilling_v1_generated_CloudBilling_GetIamPolicy_sync_flattened]
}


: *const PUBase, widget: *const PUBase),
    pub add_layout: extern "C" fn(self_c: *const PUBase, layout: *const PUBase),
    pub update: extern "C" fn(self_c: *const PUBase),
}

#[repr(C)]
#[derive(Copy, Clone)]
pub struct PUVBoxLayout {
    pub funcs: *const PUVBoxLayoutFuncs,
    pub privd: *const PUBase,
}

#[repr(C)]
pub struct PUHBoxLayoutFuncs {
    pub destroy: extern "C" fn(self_c: *const PUBase),
    pub add_widget: extern "C" fn(self_c: *const PUBase, widget: *const PUBase),
    pub add_layout: extern "C" fn(self_c: *const PUBase, layout: *const PUBase),
    pub update: extern "C" fn(self_c: *const PUBase),
}

#[repr(C)]
#[derive(Copy, Clone)]
pub struct PUHBoxLayout {
    pub funcs: *const PUHBoxLayoutFuncs,
    pub privd: *const PUBase,
}

#[repr(C)]
pub struct PU {
    pub create_widget: extern "C" fn(priv_data: *const PUBase) -> PUWidget,
    pub create_push_button: extern "C" fn(priv_data: *const PUBase) -> PUPushButton,
    pub create_painter: extern "C" fn(priv_data: *const PUBase) -> PUPainter,
    pub create_list_widget_item: extern "C" fn(priv_data: *const PUBase) -> PUListWidgetItem,
    pub create_list_widget: extern "C" fn(priv_data: *const PUBase) -> PUListWidget,
    pub create_label: extern "C" fn(priv_data: *const PUBase) -> PULabel,
    pub create_line_edit: extern "C" fn(priv_data: *const PUBase) -> PULineEdit,
    pub create_plain_text_edit: extern "C" fn(priv_data: *const PUBase) -> PUPlainTextEdit,
    pub create_slider: extern "C" fn(priv_data: *const PUBase) -> PUSlider,
    pub create_main_window: extern "C" fn(priv_data: *const PUBase) -> PUMainWindow,
    pub create_frameless_window: extern "C" fn(priv_data: *const PUBase) -> PUFramelessWindow,
    pub create_action: extern "C" fn(priv_data: *const PUBase) -> PUAction,
    pub create_timer: extern "C" fn(priv_data: *const PUBase) -> PUTimer,
    pub create_icon: extern "C" fn(priv_data: *const PUBase) -> PUIcon,
    pub create_font: extern "C" fn(priv_data: *const PUBase) -> PUFont,
    pub create_menu: extern "C" fn(priv_data: *const PUBase) -> PUMenu,
    pub create_menu_bar: extern "C" fn(priv_data: *const PUBase) -> PUMenuBar,
    pub create_application: extern "C" fn(priv_data: *const PUBase) -> PUApplication,
    pub create_v_box_layout: extern "C" fn(priv_data: *const PUBase) -> PUVBoxLayout,
    pub create_h_box_layout: extern "C" fn(priv_data: *const PUBase) -> PUHBoxLayout,
    pub open_files_dialog: extern "C" fn(self_c: *const PUBase) -> PUArray,
    pub privd: *const PUBase,
}

<gh_stars>10-100
// Copyright © 2016 <NAME>
// This program is licensed under the "MIT License".
// Please see the file COPYING in this distribution
// for license terms.

// Advent of Code Day <day>.

extern crate aoc;

pub fn main() {
    let part = aoc::get_part();
    assert!(part == 1);
}

pub mod lua_gen;

<reponame>ThisSeanZhang/proc-macro-workshop
u


.345531,
		},
		randomize_indexes = {},
	},
	lore_grendyl_four_b = {
		randomize_indexes_n = 0,
		sound_events_n = 2,
		sound_events = {
			[1] = "loc_zealot_female_c__lore_grendyl_four_b_01",
			[2] = "loc_zealot_female_c__lore_grendyl_four_b_02",
		},
		sound_events_duration = {
			[1] = 3.720188,
			[2] = 5.345865,
		},
		randomize_indexes = {},
	},
	lore_grendyl_four_c = {
		randomize_indexes_n = 0,
		sound_events_n = 2,
		sound_events = {
			[1] = "loc_zealot_female_c__lore_grendyl_four_c_01",
			[2] = "loc_zealot_female_c__lore_grendyl_four_c_02",
		},
		sound_events_duration = {
			[1] = 4.604177,
			[2] = 6.438833,
		},
		randomize_indexes = {},
	},
	lore_grendyl_one_b = {
		randomize_indexes_n = 0,
		sound_events_n = 2,
		sound_events = {
			[1] = "loc_zealot_female_c__lore_grendyl_one_b_01",
			[2] = "loc_zealot_female_c__lore_grendyl_one_b_02",
		},
		sound_events_duration = {
			[1] = 4.900271,
			[2] = 2.535198,
		},
		randomize_indexes = {},
	},
	lore_grendyl_one_c = {
		randomize_indexes_n = 0,
		sound_events_n = 2,
		sound_events = {
			[1] = "loc_zealot_female_c__lore_grendyl_one_c_01",
			[2] = "loc_zealot_female_c__lore_grendyl_one_c_02",
		},
		sound_events_duration = {
			[1] = 3.329406,
			[2] = 5.646802,
		},
		randomize_indexes = {},
	},
	lore_grendyl_three_b = {
		randomize_indexes_n = 0,
		sound_events_n = 2,
		sound_events = {
			[1] = "loc_zealot_female_c__lore_grendyl_three_b_01",
			[2] = "loc_zealot_female_c__lore_grendyl_three_b_02",
		},
		sound_events_duration = {
			[1] = 2.100135,
			[2] = 3.893417,
		},
		randomize_indexes = {},
	},
	lore_grendyl_three_c = {
		randomize_indexes_n = 0,
		sound_events_n = 2,
		sound_events = {
			[1] = "loc_zealot_female_c__lore_grendyl_three_c_01",
			[2] = "loc_zealot_female_c__lore_grendyl_three_c_02",
		},
		sound_events_duration = {
			[1] = 5.401688,
			[2] = 3.924125,
		},
		randomize_indexes = {},
	},
	lore_grendyl_two_a = {
		randomize_indexes_n = 0,
		sound_events_n = 4,
		sound_events = {
			"loc_zealot_female_c_


mut self) {
        self.is_logging = false;
    }
}

impl<W: Write> Write for LogWriter<W> {
    fn write(&mut self, buf: &[u8]) -> Result<usize> {
        let result = self.inner.write(buf);
        if self.is_logging {
            self.log_data.extend_from_slice(buf);
        }
        result
    }

    fn flush(&mut self) -> Result<()> {
        self.inner.flush()
    }
}

#[cfg(test)]
mod tests {

    use std::io::Write;
    use super::*;
    use io::Log;

    #[test]
    fn test_clear_clears_logged_data() {
        let mut target = LogWriter::new(Vec::new());
        target.write(&[0, 1, 2, 3]).unwrap();
        assert_eq!(target.logged(), &vec![0, 1, 2, 3]);

        target.clear();
        assert_eq!(target.logged(), &Vec::<u8>::new());
    }

    #[test]
    fn test_logged_returns_correct_data() {
        let mut target = LogWriter::new(Vec::new());
        target.write(&[0, 1, 2, 3]).unwrap();
        assert_eq!(target.logged(), &vec![0, 1, 2, 3]);
    }

    #[test]
    fn test_start_and_stop_starts_and_stops_the_logging() {
        let mut target = LogWriter::new(Vec::new());
        target.write(&[0, 1, 2, 3]).unwrap();
        assert_eq!(target.logged(), &vec![0, 1, 2, 3]);

        target.stop();
        target.write(&[4, 5, 6, 7]).unwrap();
        assert_eq!(target.logged(), &vec![0, 1, 2, 3]);

        target.start();
        target.write(&[8, 9, 10, 11]).unwrap();
        assert_eq!(target.logged(), &vec![0, 1, 2, 3, 8, 9, 10, 11]);
    }
}
<filename>tests/test.rs
use anyhow::Result;

#[test]
fn test_parse() {
    let interface_aidl = r#"
        package com.bwa.aidl_test;

        import com.bwa.aidl_test.MyParcelable;
        import com.bwa.aidl_test.MyParcelable;
        import com.bwa.aidl_test.NonExisting;
        import com.bwa.aidl_test.UnusedEnum;

        interface MyInterface {
            void method1(in MyParcelable);
            String method2();
        }
    "#;

    let parcelable_aidl = r#"
        package com.bwa.aidl_test;

        parcelable MyParcelable {
            String name;
            byte[] data;
        }
    "#;

    let enum_aidl = r#"
        package com.bwa.aidl_test;

        enum UnusedEnum {
            VALUE1 = 1,
            VALUE2 = 2,
        }
    "#;

    // Parse AIDL files
    let mut parser = aidl_parser::Parser::new();
    parser.add_content("id1", interface_aidl);
    parser.add_content("id2", parcelable_aidl);
    parser.add_content("id3", enum_aidl);
    let res = parser.validate();

    // For each file, 1 result
    assert_eq!(res.len(), 3);

    // Check AIDL 1
    let ast1 = res.get("id1").expect("result").ast.as_ref().expect("ast");
    let interface = ast1.item.as_interface().expect("interface");
    assert_eq!(interface.name, "MyInterface");

    // Check AIDL 2
    let ast2 = res.get("id2").expect("result").ast.


    buffer.writeInt32(0x9493ff32);

    // Write fields.
    buffer.writeDateTime(date);
    buffer.writeObject(file);

    // Finished serialization.
  }

  @override
  Map<String, dynamic> toJson() {
    final returnValue = <String, dynamic>{
      "\$hash": "9493ff32",
      "\$name": "MessagesSentEncryptedFile",
      "date": date.toIso8601String(),
      "file": file,
    };

    // Finished toJson.
    return returnValue;
  }
}

/// Input Document Empty.
///
/// ID: `72f0eaae`.
class InputDocumentEmpty extends InputDocumentBase {
  /// Input Document Empty constructor.
  const InputDocumentEmpty() : super._();

  /// Deserialize.
  factory InputDocumentEmpty.deserialize(BinaryReader reader) {
    // Construct [InputDocumentEmpty] object.
    final returnValue = InputDocumentEmpty();

    // Now return the deserialized [InputDocumentEmpty].
    return returnValue;
  }

  /// Serialize.
  @override
  void serialize(List<int> buffer) {
    // Write type-id 0x72f0eaae.
    buffer.writeInt32(0x72f0eaae);

    // Finished serialization.
  }

  @override
  Map<String, dynamic> toJson() {
    final returnValue = <String, dynamic>{
      "\$hash": "72f0eaae",
      "\$name": "InputDocumentEmpty",
    };

    // Finished toJson.
    return returnValue;
  }
}

/// Input Document.
///
/// ID: `1abfb575`.
class InputDocument extends InputDocumentBase {
  /// Input Document constructor.
  const InputDocument({
    required this.id,
    required this.accessHash,
    required this.fileReference,
  }) : super._();

  /// Deserialize.
  factory InputDocument.deserialize(BinaryReader reader) {
    // Read [InputDocument] fields.
    final id = reader.readInt64();
    final accessHash = reader.readInt64();
    final fileReference = reader.readBytes();

    // Construct [InputDocument] object.
    final returnValue = InputDocument(
      id: id,
      accessHash: accessHash,
      fileReference: fileReference,
    );

    // Now return the deserialized [InputDocument].
    return returnValue;
  }

  /// Id.
  ///
  /// Field type is Int64.
  final int id;

  /// Access Hash.
  ///
  /// Field type is Int64.
  final int accessHash;

  /// File Reference.
  final Uint8List fileReference;

  /// Serialize.
  @override
  void serialize(List<int> buffer) {
    // Write type-id 0x1abfb575.
    buffer.writeInt32(0x1abfb575);

    // Write fields.
    buffer.writeInt64(id);
    buffer.writeInt64(accessHash);
    buffer.writeBytes(fileReference);

    // Finished serialization.
  }

  @override
  Map<String, dynamic> toJson() {
    final returnValue = <String, dynamic>{
      "\$hash": "1abfb575",
      "\$name": "InputDocument",
      "id": id,
      "accessHash": accessHash,
      "fileReference": fileReference,
    };

    // Finished toJson.
    return returnValue;
  }
}

/// Document Empty.
///
/// ID: `36f8c871`.
class DocumentEmpty extends DocumentBase {
  /// Document Empty constructor.
  const DocumentEmpty({required this.id}) : super._();

  /// Deserialize.
  factory DocumentEmpty.deserialize(BinaryReader reader) {
    // Read [DocumentEmpty] fields.
    final id = reader.readInt64();

    // Construct [DocumentEmpty] object.
    final returnValue = DocumentEmpty(id: id);

    // Now return the deserialized [DocumentEmpty].
    return returnValue;
  }


portant;
              }
            }

            .ant-table-fixed-right {
              .ant-table-body-outer {
                .ant-table-body-inner {
                  overflow-y: auto !important;
                }
              }
            }

            .ant-table-fixed-left {
              .ant-table-body-outer {
                .ant-table-body-inner {
                  overflow-y: auto !important;
                }
              }
            }
          }
        }
      }
    }
  }

  .hide-scrollbar-x {
    .ant-spin-nested-loading {
      .ant-spin-container {
        .ant-table {
          .ant-table-content {
            .ant-table-scroll {
              .ant-table-hide-scrollbar {
                //overflow-x: auto !important;
              }

              .ant-table-content {
                overflow: auto !important;
              }
            }

            .ant-table-fixed-right {
              .ant-table-body-outer {
                .ant-table-body-inner {
                  overflow-x: auto !important;
                }
              }
            }

            .ant-table-fixed-left {
              .ant-table-body-outer {
                .ant-table-body-inner {
                  overflow-x: auto !important;
                }
              }
            }
          }
        }
      }
    }
  }
}
// tabs卡片样式
@prefix-cls-theme-card: ~'@{prefix-cls}.@{prefix-cls}--theme-card';

html[data-theme='dark'] {
  .@{prefix-cls-theme-card} {
    .ant-tabs-tab {
      border-top: none !important;
      border-left: none !important;
      border-right: none !important;
    }
  }
}

html[data-theme='light'] {
  .@{prefix-cls-theme-card} {
    .ant-tabs-tab:not(.ant-tabs-tab-active) {
      border-top: none !important;
      border-left: none !important;
      border-right: none !important;
    }
  }
}

.@{prefix-cls-theme-card} {
  @tabHeight: calc(@multiple-card-height - 10px);

  z-index: 10;
  height: @multiple-card-height;
  line-height: @multiple-card-height;
  background-color: @component-background;
  box-shadow: 0 1px 4px rgb(0 21 41 / 8%);

  .ant-tabs-small {
    height: @multiple-card-height;
  }

  .ant-tabs.ant-tabs-card {
    .ant-tabs-nav {
      height: @multiple-card-height;
      margin: 0;
      background-color: @component-background;
      border: 0;
      box-shadow: none;
      padding-left: 10px;

      .ant-tabs-nav-wrap {
        height: @tabHeight;
        margin-top: 4px;
        padding-top: 0;
      }

      .ant-tabs-tab {
        height: @tabHeight;
        line-height: @tabHeight;
        color: @text-color-base;
        background-color: @component-background;
        padding: 0 20px 0 30px;
        margin: 0 10px 0 0 !important;

        .ant-tabs-tab-btn {
          color: @text-color-call-out;
        }

        &:hover {
          //padding: 0 36px 0 30px;

          .ant-tabs-tab-remove


using System;
using System.IO;
using System.Reflection;
using System.Text;

namespace Lang.Cs.Compiler
{
    public static class _ReflectionExtensions
    {
        private static string GetVisibility(bool isPublic, bool isPrivate)
        {
            if (isPublic)
                return "public";
            return isPrivate ? "private" : "protected";
        }

        public static FileInfo GetCodeLocation(this Assembly a)
        {
            var assemblyPath = a.CodeBase;
            Uri uri;
            if (!Uri.TryCreate(assemblyPath, UriKind.RelativeOrAbsolute, out uri)) return new FileInfo(assemblyPath);
            if (uri.Scheme != Uri.UriSchemeFile)
                throw new Exception(string.Format("Unsupported protocol in URI {0}", assemblyPath));
            return new FileInfo(uri.LocalPath);
        }

        public static string GetMethodHeader(this MethodInfo method)
        {
            var builder = new StringBuilder();
            builder.Append(GetVisibility(meth


l.IsInitialized(baz2.FooSet));
				Assert.IsTrue(NHibernateUtil.IsInitialized(baz3.FooSet));

				Assert.AreEqual(2, baz2.FooSet.Count);

				Assert.IsTrue(baz3.StringSet.Contains("baz"));

				Assert.IsTrue(NHibernateUtil.IsInitialized(baz.StringSet));
				Assert.IsTrue(NHibernateUtil.IsInitialized(baz2.StringSet));
				Assert.IsTrue(NHibernateUtil.IsInitialized(baz3.StringSet));

				Assert.AreEqual(2, baz.StringSet.Count);
				Assert.AreEqual(0, baz2.StringSet.Count);

				await (s.DeleteAsync(baz));
				await (s.DeleteAsync(baz2));
				await (s.DeleteAsync(baz3));

				foreach (var obj in baz.FooSet.Concat(baz2.FooSet))
				{
					await (s.DeleteAsync(obj));
				}

				await (s.FlushAsync());
			}
		}

		[Test]
		public async Task FetchInitializedCollectionAsync()
		{
			ISession s = OpenSession();
			Baz baz = new Baz();
			IList<Foo> fooBag = new List<Foo>();
			fooBag.Add(new Foo());
			fooBag.Add(new Foo());
			baz.FooBag = fooBag;
			await (s.SaveAsync(baz));
			await (s.FlushAsync());
			fooBag = baz.FooBag;
			await (s.CreateQuery("from Baz baz left join fetch baz.FooBag").ListAsync());
			Assert.IsTrue(NHibernateUtil.IsInitialized(fooBag));
			s.Close();

			s = OpenSession();
			baz = (Baz) await (s.LoadAsync(typeof(Baz), baz.Code));
			Object bag = baz.FooBag;
			Assert.IsFalse(NHibernateUtil.IsInitialized(bag));
			await (s.CreateQuery("from Baz baz left join fetch baz.FooBag").ListAsync());
			Assert.IsTrue(bag == baz.FooBag);
			Assert.IsTrue(baz.FooBag.Count == 2);
			await (s.DeleteAsync(baz));
			await (s.FlushAsync());

			s.Close();
		}

		[Test]
		public async Task LateCollectionAddAsync()
		{
			object id;

			using (ISession s = OpenSession())
			{
				Baz baz = new Baz();
				IList<string> l = new List<string>();
				baz.StringList = l;

				l.Add("foo");
				id = await (s.SaveAsync(baz));

				l.Add("bar");
				await (s.FlushAsync());

				l.Add("baz");
				await (s.FlushAsync());
			}

			using (ISession s = OpenSession())
			{
				Baz baz = (Baz) await (s.LoadAsync(typeof(Baz), id));
				Assert.AreEqual(3, baz.StringList.Count);
				Assert.IsTrue(baz.StringList.Contains("foo"));
				Assert.IsTrue(baz.StringList.Contains("bar"));
				Assert.IsTrue(baz.StringList.Contains("baz"));

				await (s.DeleteAsync(baz));
				await (s.FlushAsync());
			}
		}

		[Test]
		public async Task UpdateAsync()
		{
			ISession s = OpenSession();
			Foo foo = new Foo();
			await (s.SaveAsync(foo));
			await (s.FlushAsync());
			s.Close();

			s = OpenSession();
			FooProxy foo2 = (FooProxy) await (s.LoadAsync(typeof(Foo), foo.Key));
			foo2.String = "dirty";
			foo2.Boolean = false;
			foo2.Bytes = new byte[] {1, 2, 3};
			foo2.Date = DateTime.Today;
			foo2.Short = 69;
			await (s.FlushAsync());
			s.Close();

			s = OpenSession();


    super.onInit(...arguments);
    this.toggleStickyRightColumn();
    this.hideHiddenInputsParentElements();
    if (elementorFrontend.isEditMode()) {
      this.elements.$shippingForm.show();
    }
    this.applyButtonsHoverAnimation();
    this.updateWpReferers();
    if (elementorFrontend.isEditMode() || elementorFrontend.isWPPreviewMode()) {
      this.disableActions();
    }
  }

  /**
   * Using the WooCommerce Cart controls (quantity, remove product) in the editor will cause the cart to disappear.
   * This is because WooCommerce does an ajax round trip where it modifies the cart, then loads that cart into the
   * current page and attempts to grab the elements from that page via ajax. In the Editor, if the page is not
   * published yet, it fetches an empty page that does not contain the required elements. As a result, the cart
   * is rendered empty.
   *
   * Due to this issue, the cart controls (quantity, remove product) need to be disabled in the Editor.
   */
  disableActions() {
    const selectors = this.getSettings('selectors');
    this.$element.find(selectors.updateCartButton).attr({
      disabled: 'disabled',
      'aria-disabled': 'true'
    });
    if (elementorFrontend.isEditMode()) {
      this.$element.find(selectors.quantityInput).attr('disabled', 'disabled');
      this.$element.find(selectors.productRemove).css('pointer-events', 'none');
    }
  }
  onElementChange(propertyName) {
    if ('sticky_right_column' === propertyName) {
      this.toggleStickyRightColumn();
    }
    if ('additional_template_select' === propertyName) {
      elementorPro.modules.woocommerce.onTemplateIdChange('additional_template_select');
    }
  }
  onDestroy() {
    super.onDestroy(...arguments);
    this.deactivateStickyRightColumn();
  }
  updateCart() {
    const selectors = this.getSettings('selectors');
    clearTimeout(this._debounce);
    this._debounce = setTimeout(() => {
      this.$element.find(selectors.updateCartButton).trigger('click');
    }, 1500);
  }
  applyButtonsHoverAnimation() {
    const elementSettings = this.getElementSettings();
    if (elementSettings.checkout_button_hover_animation) {
      // This element is recaptured every time because the cart markup can refresh
      jQuery('.checkout-button').addClass('elementor-animation-' + elementSettings.checkout_button_hover_animation);
    }
    if (elementSettings.forms_buttons_hover_animation) {
      // This element is recaptured every time because the cart markup can refresh
      jQuery('.shop_table .button').addClass('elementor-animation-' + elementSettings.forms_buttons_hover_animation);
    }
  }

  /**
   * In the editor, WC Frontend JS does not fire (not registered).
   * This causes that hidden inputs parent paragraph elements do not get display:none
   * as they would have on the front end.
   * So this function manually display:none the parent elements of these hidden inputs to avoid having
   * gaps/spaces in the layout caused by these parent elements' margins/paddings.
   */
  hideHiddenInputsParentElements() {
    if (this.isEdit) {
      if (this.elements.$hiddenInput) {
        this.elements.$hiddenInput.parent('.form-row').addClass('elementor-hidden');
      }
    }
  }
}
exports["default"] = Cart;

/***/ })

}]);
//# sourceMappingURL=woocommerce-cart.79b5dc500681930471c6.bundle.js.map/*! pro-elements -  v3.32.0 - 16-09-2025 */
"use strict";
(self["webpackChunkelementor_pro"] = self["webpackChunkelementor_pro"] || []).push([["taxonomy-filter"],{

/***/ "../assets/dev/js/frontend/utils/flex-horizontal-scroll.js":


%verify "executed"
%verify "class not resolved"
%verify "class cannot be resolved"
%verify "class not initialized"
%verify "class fails to initialize"
%verify "class already resolved/initialized"
%verify "class is abstract or interface"
%verify "allocation fails"
    /*
     * Create a new instance of a class.
     */
    /* new-instance vAA, class@BBBB */
    ldr     r3, [rSELF, #offThread_methodClassDex]    @ r3<- pDvmDex
    FETCH(r1, 1)                        @ r1<- BBBB
    ldr     r3, [r3, #offDvmDex_pResClasses]    @ r3<- pDvmDex->pResClasses
    ldr     r0, [r3, r1, lsl #2]        @ r0<- resolved class
#if defined(WITH_JIT)
    add     r10, r3, r1, lsl #2         @ r10<- &resolved_class
#endif
    EXPORT_PC()                         @ req'd for init, resolve, alloc
    cmp     r0, #0                      @ already resolved?
    beq     .L${opcode}_resolve         @ no, resolve it now
.L${opcode}_resolved:   @ r0=class
    ldrb    r1, [r0, #offClassObject_status]    @ r1<- ClassStatus enum
    cmp     r1, #CLASS_INITIALIZED      @ has class been initialized?
    bne     .L${opcode}_needinit        @ no, init class now
.L${opcode}_initialized: @ r0=class
    mov     r1, #ALLOC_DONT_TRACK       @ flags for alloc call
    bl      dvmAllocObject              @ r0<- new object
    b       .L${opcode}_finish          @ continue
%break

    .balign 32                          @ minimize cache lines
.L${opcode}_finish: @ r0=new object
    mov     r3, rINST, lsr #8           @ r3<- AA
    cmp     r0, #0                      @ failed?
#if defined(WITH_JIT)
    /*
     * The JIT needs the class to be fully resolved before it can
     * include this instruction in a trace.
     */
    ldrh    r1, [rSELF, #offThread_subMode]
    beq     common_exceptionThrown      @ yes, handle the exception
    ands    r1, #kSubModeJitTraceBuild  @ under construction?
    bne     .L${opcode}_jitCheck
#else
    beq     common_exceptionThrown      @ yes, handle the exception
#endif
.L${opcode}_end:
    FETCH_ADVANCE_INST(2)


08 000B5448  90 01 00 14 */	stw r0, 0x14(r1)
/* 800B9F0C 000B544C  93 E1 00 0C */	stw r31, 0xc(r1)
/* 800B9F10 000B5450  7C 7F 1B 78 */	mr r31, r3
/* 800B9F14 000B5454  80 03 00 0C */	lwz r0, 0xc(r3)
/* 800B9F18 000B5458  2C 00 00 00 */	cmpwi r0, 0
/* 800B9F1C 000B545C  41 80 00 74 */	blt lbl_800B9F90
/* 800B9F20 000B5460  80 63 00 00 */	lwz r3, 0(r3)
/* 800B9F24 000B5464  80 9F 00 04 */	lwz r4, 4(r31)
/* 800B9F28 000B5468  48 30 30 01 */	bl func_803BCF28
/* 800B9F2C 000B546C  2C 03 00 00 */	cmpwi r3, 0
/* 800B9F30 000B5470  40 81 00 10 */	ble lbl_800B9F40
/* 800B9F34 000B5474  80 1F 00 0C */	lwz r0, 0xc(r31)
/* 800B9F38 000B5478  2C 00 00 00 */	cmpwi r0, 0
/* 800B9F3C 000B547C  41 80 00 54 */	blt lbl_800B9F90
lbl_800B9F40:
/* 800B9F40 000B5480  80 7F 00 08 */	lwz r3, 8(r31)
/* 800B9F44 000B5484  48 00 2F 61 */	bl func_800BCEA4
/* 800B9F48 000B5488  2C 03 00 00 */	cmpwi r3, 0
/* 800B9F4C 000B548C  41 82 00 1C */	beq lbl_800B9F68
/* 800B9F50 000B5490  80 7F 00 08 */	lwz r3, 8(r31)
/* 800B9F54 000B5494  48 00 2E F9 */	bl func_800BCE4C
/* 800B9F58 000B5498  7C 64 1B 78 */	mr r4, r3
/* 800B9F5C 000B549C  80 7F 00 00 */	lwz r3, 0(r31)
/* 800B9F60 000B54A0  38 A0 00 00 */	li r5, 0
/* 800B9F64 000B54A4  48 33 72 25 */	bl func_803F1188
lbl_800B9F68:
/* 800B9F68 000B54A8  80 7F 00 00 */	lwz r3, 0(r31)
/* 800B9F6C 000B54AC  80 9F 00 04 */	lwz r4, 4(r31)
/* 800B9F70 000B54B0  48 30 2F B9 */	bl func_803BCF28
/* 800B9F74 000B54B4  80 9F 00 0C */	lwz r4, 0xc(r31)
/* 800B9F78 000B54B8  38 04 00 01 */	addi r0, r4, 1
/* 800B9F7C 000B54BC  7C 00 18 00 */	cmpw r0, r3
/* 800B9F80 000B54C0  90 1F 00 0C */	stw r0, 0xc(r31)
/* 800B9F84 000B54C4  40 82 00 0C */	bne lbl_800B9F90
/* 800B9F88 000B54C8  7F E3 FB 78 */	mr r3, r31
/* 800B9F8C 000B54CC  4B FF FE F9 */	bl func_800B9E84
lbl_800B9F90:
/* 800B9F


isted", 2054, 107, 5, 1},
		PollingPlace{2, "NSW", "Robertson", 146, 40, "Umina Beach", 31701, "Current", "Umina Community Hall", "6 Sydney Ave", "", "", "UMINA BEACH", "NSW", 2257, "Community Hall", "6 Sydney Ave", "UMINA BEACH", "", "", "", -33.52179, 151.31615, 1222002, "Assisted", 1324, 153, 3, 2},
		PollingPlace{2, "NSW", "Robertson", 146, 40, "Umina Central", 2628, "Current", "Brisbane Water Secondary College Umina Campus", "Veron Rd", "", "", "UMINA BEACH", "NSW", 2257, "High School", "Veron Rd", "UMINA BEACH", "", "", "", -33.5056, 151.308, 1221912, "Assisted", 1676, 107, 4, 1},
		PollingPlace{2, "NSW", "Robertson", 146, 40, "Umina Mall", 2629, "Current", "Umina Uniting Church Community Centre", "Neptune St", "", "", "UMINA BEACH", "NSW", 2257, "Uniting Church Community Centre", "Neptune St", "UMINA BEACH", "", "", "", -33.5145, 151.318, 1221802, "Assisted", 1952, 101, 4, 1},
		PollingPlace{2, "NSW", "Robertson", 146, 40, "Wamberal (Robertson)", 618, "Appointment", "Wamberal Memorial Hall", "182 Ocean View Dr", "", "", "WAMBERAL", "NSW", 2260, "Memorial Hall", "182 Ocean View Dr", "WAMBERAL", "", "", "Entry from Ocean View Dr", -33.4235, 151.441, 1220806, "Assisted", 1003, 295, 3, 3},
		PollingPlace{2, "NSW", "Robertson", 146, 40, "Woy Woy", 2631, "Current", "Brisbane Water Secondary College Woy Woy Campus", "Edward St", "", "", "WOY WOY", "NSW", 2256, "High School", "Edward St", "WOY WOY", "", "", "", -33.4925, 151.325, 1221504, "Assisted", 1580, 147, 4, 2},
		PollingPlace{2, "NSW", "Robertson", 146, 40, "Woy Woy South", 2633, "Current", "South Woy Woy Progress Association", "cnr Woy Woy Rd & Pier St", "", "", "WOY WOY", "NSW", 2256, "South Woy Woy Progress Association", "cnr Woy Woy Rd & Pier St", "WOY WOY", "", "", "", -33.4958, 151.309, 1221507, "Assisted", 1010, 88, 3, 1},
		PollingPlace{2, "NSW", "Robertson", 146, 40, "Wyoming (Robertson)", 31960, "Current", "Wyoming Public School", "41 Maidens Brush Rd", "", "", "WYOMING", "NSW", 2250, "Wyoming Public School", "41 Maidens Brush Rd", "WYOMING", "", "", "Entry from Maidens Brush Rd", -33.409, 151.356, 1220410, "Assisted", 1203, 30, 3, 1},
		PollingPlace{2, "NSW", "Shortland", 148, 41, "Adamstown Heights (Shortland)", 46408, "Current", "Kotara High School", "65 Lexington Pde", "", "", "ADAMSTOWN HEIGHTS", "NSW", 2289, "Kotara High School", "65 Lexington Pde", "ADAMSTOWN HEIGHTS", "Multi-Purpose Centre", "", "Entrance to polling place: Main door to school multi purpose centre. Entrance to school grounds: Front gate o n Lexington Pde open.", -32.9464, 151.707, 1102114, "Assisted", 465, 2, 1, 0},
		PollingPlace{2, "NSW", "Shortland", 148, 41, "Belmont", 2683, "Current", "All Saints Anglican Church", "24 Church St", ""


(--h6-margin-bottom) * var(--editor-line-height-small-rem)
      );
    }
  }
}

// Style setting
.cc-soft-wrap-code-blocks {
  code[class*="language-"],
  pre[class*="language-"] {
    overflow: hidden;
    white-space: pre-wrap;
  }
}

.cc-seamless-embed {
  .markdown-embed .markdown-preview-view {
    padding: 0;
  }

  .markdown-embed {
    border: none;
    padding: 0;
    margin: 0;
  }

  .markdown-embed-title {
    display: none;
  }

  .is-live-preview .markdown-embed-title {
    display: block;
  }
}

.cc-trim-table-cols {
  td,
  th {
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
    min-width: unset;
    max-width: var(--table-min-cell-width) !important;
  }
}
body {
  --svg-xs: 13px;
  --svg-s: 14px;
  --svg-m: 15px;
  --svg-l: 16px;
  --svg-xl: 18px;
  --svg-xxl: 20px;

  --folder-h: 0deg;
  --folder-s: 100%;
  --folder-b: 100%;
}

body.is-mobile {
  --svg-xs: 17px;
  --svg-s: 18px;
  --svg-m: 19px;
  --svg-l: 20px;
  --svg-xl: 22px;
  --svg-xxl: 24px;
}

.view-action > svg,
.view-header-icon > svg,
.nav-action-button svg,
.workspace-tab-header-inner-icon > svg {
  width: var(--svg-xl);
  height: var(--svg-xl);
}

.side-dock-ribbon-action > svg {
  width: 17px;
  height: 17px;
}

.is-mobile {
  .view-action > svg,
  .side-dock-ribbon-action > svg,
  .view-header-icon > svg,
  .nav-action-button svg,
  .workspace-tab-header-inner-icon > svg {
    width: var(--svg-xxl);
    height: var(--svg-xxl);
  }
}

.workspace-drawer-header-icon > svg {
  width: var(--svg-xxl);
  height: var(--svg-xxl);
}

.menu-item-icon svg {
  width: var(--svg-s);
  height: var(--svg-s);
}

.setting-hotkey-icon.setting-delete-hotkey {
  display: flex;
  line-height: 1;
  margin-left: 6px;
}

.setting-add-hotkey-button,
.setting-restore-hotkey-button {
  line-height: 1;
  height: unset;
  padding: 4px 6px;
  display: flex;
  align-items: center;

  svg {
    position: static;
  }
}

.setting-add-hotkey-button:hover,
.setting-restore-hotkey-button:hover {
  color: var(--text-muted);
  background: var(--shade-plus-darker);
}

.setting-add-hotkey-button > svg {
  width: var(--svg-xl);
  height: var(--svg-xl);
  position: static;
  display: block;
}

.view-header-icon,
.workspace-tab-header,
.side-dock-ribbon-tab {
  background: transparent;
  color: var(--text-muted);
}

.view-header-icon {
  align-items: center;
  border-radius: var(--radius-s);
  color: var(--shade-40);
  cursor: grab;
  display: flex;
  justify-content: center;
  line-height: 1;
  opacity


      {
            let mut num = 5;

            {
                let mut add_num = move |x: i32| num += x;

                add_num(5);
            }

            assert_eq!(5, num);
        }
    }

}

mod implementation{
    // Fn获取&self，
    // FnMut获取&mut self，
    // 而FnOnce获取self。
    pub fn run() {

    }

    mod foo {
        /*
        pub trait Fn<Args> : FnMut<Args> {
            extern "rust-call" fn call(&self, args: Args) -> Self::Output;
        }

        pub trait FnMut<Args> : FnOnce<Args> {
            extern "rust-call" fn call_mut(&mut self, args: Args) -> Self::Output;
        }

        pub trait FnOnce<Args> {
            type Output;

            extern "rust-call" fn call_once(self, args: Args) -> Self::Output;
        }
       */
    }

}

mod as_arg_and_return_value{

    pub fn run(){
        // Taking closures as arguments
        // 现在我们知道了闭包是 trait，我们已经知道了如何接受和返回闭包；就像任何其它的 trait！

        // 这也意味着我们也可以选择静态或动态分发。
        fn call_with_one<F>(some_closure: F) -> i32
        where F: Fn(i32) -> i32
        {
            some_closure(1)
        }

        let answer = call_with_one(|x| x+2 ) ;
        assert_eq!(3, answer) ;

        // 动态分发
        fn call_with_one2(some_closure: &Fn(i32)-> i32) -> i32 {
            some_closure(1)
        }

        // 现在我们取得一个trait对象，一个&Fn
        let answer = call_with_one2(&|x| x + 2) ;
        assert_eq!(3, answer) ;

        // 函数指针 和闭包
        fn add_one(i: i32)-> i32 {
            i + 1
        }
        let f = add_one ;
        let answer = call_with_one2(&f) ;
        assert_eq!(2 , answer) ;
        assert_eq!(2 , call_with_one2(&add_one)) ;

        //
        returning_closures();
    }

    fn returning_closures(){
        // 每个闭包生成了它自己的环境struct并实现了Fn和其它一些东西，这些类型是匿名的。它们只在这个闭包中存在。所以Rust把它们显示为closure <anon>，而不是一些自动生成的名字。
        // fn factory() -> Box<dyn Fn(i32) -> i32> {
        fn factory() -> Box<Fn(i32) -> i32> {
            let num = 5;

            // 通过把内部闭包添加move关键字，我们强制闭包使用 move 的方式捕获环境变量。因为这里的 num 类型是 i32，实际上这里的 move 执行的是 copy, 这样一来，闭包就不再拥有指向环境的指针，而是完整拥有了被捕获的变量。并允许它离开我们的栈帧。
           Box::new( move |x| x + num )
        }

        let f = factory();

        let answer = f(1);
        assert_eq!(6, answer);
    }

}<reponame>cwen0/tikv
// Copyright 2019 TiKV Project Authors. Licensed under Apache-2.0.

mod client;
mod config;
pub mod deadlock;
mod


/*
 * arch/arm/include/asm/arch-rmobile/r8a7791.h
 *
 * Copyright (C) 2013,2014 Renesas Electronics Corporation
 *
 * SPDX-License-Identifier: GPL-2.0
*/

#ifndef __ASM_ARCH_R8A7791_H
#define __ASM_ARCH_R8A7791_H

#include "rcar-base.h"
/*
 * R-Car (R8A7791) I/O Addresses
 */

/* SH-I2C */
#define CONFIG_SYS_I2C_SH_BASE2	0xE60B0000

/* SDHI */
#define CONFIG_SYS_SH_SDHI1_BASE 0xEE140000
#define CONFIG_SYS_SH_SDHI2_BASE 0xEE160000
#define CONFIG_SYS_SH_SDHI_NR_CHANNEL 3

#define DBSC3_1_QOS_R0_BASE	0xE67A1000
#define DBSC3_1_QOS_R1_BASE	0xE67A1100
#define DBSC3_1_QOS_R2_BASE	0xE67A1200
#define DBSC3_1_QOS_R3_BASE	0xE67A1300
#define DBSC3_1_QOS_R4_BASE	0xE67A1400
#define DBSC3_1_QOS_R5_BASE	0xE67A1500
#define DBSC3_1_QOS_R6_BASE	0xE67A1600
#define DBSC3_1_QOS_R7_BASE	0xE67A1700
#define DBSC3_1_QOS_R8_BASE	0xE67A1800
#define DBSC3_1_QOS_R9_BASE	0xE67A1900
#define DBSC3_1_QOS_R10_BASE	0xE67A1A00
#define DBSC3_1_QOS_R11_BASE	0xE67A1B00
#define DBSC3_1_QOS_R12_BASE	0xE67A1C00
#define DBSC3_1_QOS_R13_BASE	0xE67A1D00
#define DBSC3_1_QOS_R14_BASE	0xE67A1E00
#define DBSC3_1_QOS_R15_BASE	0xE67A1F00
#define DBSC3_1_QOS_W0_BASE	0xE67A2000
#define DBSC3_1_QOS_W1_BASE	0xE67A2100
#define DBSC3_1_QOS_W2_BASE	0xE67A2200
#define DBSC3_1_QOS_W3_BASE	0xE67A2300
#define DBSC3_1_QOS_W4_BASE	0xE67A2400
#define DBSC3_1_QOS_W5_BASE	0xE67A2500
#define DBSC3_1_QOS_W6_BASE	0xE67A2600
#define DBSC3_1_QOS_W7_BASE	0xE67A2700
#define DBSC3_1_QOS_W8_BASE	0xE67A2800
#define DBSC3_1_QOS_W9_BASE	0xE67A2900
#define DBSC3_1_QOS_W10_BASE	0xE67A2A00
#define DBSC3_1_QOS_W11_BASE	0xE67A2B00
#define DBSC3_1_QOS_W12_BASE	0xE67A2C00
#define DBSC3_1_QOS_W13_BASE	0xE67A2D00
#define DBSC3_1_QOS_W14_BASE	0xE67A2E00
#define DBSC3_1_QOS_W15_BASE	0xE67A2F00
#define DBSC3_1_DBADJ2		0xE67A00C8

/* Module stop control/status register bits */
#define MSTP0_BITS	0x00640801
#define MSTP1_BITS	0x9B6C9B5A
#define MSTP2_BITS	0x100D21FC
#define MSTP3_BITS	0xF08CD810
#define MSTP4_BITS	0x800001C4
#define MSTP5_BITS	0x44C00046
#define MSTP7_BITS	0x05BFE618
#define MSTP8_BITS	0x40C0FE85
#define MSTP9_BITS	0xFF979FFF
#define MSTP10_BITS	0xFFFEFFE0
#define MSTP11_BITS	0x000001C0

#define R8A7791_CUT_ES2X	2
#define IS_R8A7791_ES2()	\
	(rmobile_get_cpu_rev_integer() == R8A7791_CUT_ES2X)

#endif /* __ASM_ARCH_R8A7791_H */


    // rotate area light in (T1, T2, N) basis
    //mat3 R = transpose(mat3(T1, T2, N));
    mat3 R = transposeMat3( mat3( T1, T2, N ) );
    // polygon (allocate 5 vertices for clipping)
    vec3 L_[ 3 ];
    L_[ 0 ] = R * ( points.coord0 - P );
    L_[ 1 ] = R * ( points.coord1 - P );
    L_[ 2 ] = R * ( points.coord2 - P );

    // init ellipse
    vec3 C  = 0.5 * (L_[0] + L_[2]);
    vec3 V1 = 0.5 * (L_[1] - L_[2]);
    vec3 V2 = 0.5 * (L_[1] - L_[0]);

    C  = Minv * C;
    V1 = Minv * V1;
    V2 = Minv * V2;

    //if(dot(cross(V1, V2), C) > 0.0)
    //    return 0.0;

    // compute eigenvectors of ellipse
    float a, b;
    float d11 = dot(V1, V1);
    float d22 = dot(V2, V2);
    float d12 = dot(V1, V2);
    if (abs(d12) / sqrt(d11 * d22) > 0.0001)
    {
        float tr = d11 + d22;
        float det = -d12 * d12 + d11 * d22;

        // use sqrt matrix to solve for eigenvalues
        det = sqrt(det);
        float u = 0.5 * sqrt(tr - 2.0 * det);
        float v = 0.5 * sqrt(tr + 2.0 * det);
        float e_max = (u + v) * (u + v);
        float e_min = (u - v) * (u - v);

        vec3 V1_, V2_;

        if (d11 > d22)
        {
            V1_ = d12 * V1 + (e_max - d11) * V2;
            V2_ = d12 * V1 + (e_min - d11) * V2;
        }
        else
        {
            V1_ = d12*V2 + (e_max - d22)*V1;
            V2_ = d12*V2 + (e_min - d22)*V1;
        }

        a = 1.0 / e_max;
        b = 1.0 / e_min;
        V1 = normalize(V1_);
        V2 = normalize(V2_);
    }
    else
    {
        a = 1.0 / dot(V1, V1);
        b = 1.0 / dot(V2, V2);
        V1 *= sqrt(a);
        V2 *= sqrt(b);
    }

    vec3 V3 = normalize(cross(V1, V2));
    if (dot(C, V3) < 0.0)
        V3 *= -1.0;

    float L  = dot(V3, C);
    float x0 = dot(V1, C) / L;
    float y0 = dot(V2, C) / L;

    float E1 = inversesqrt(a);
    float E2 = inversesqrt(b);

    a *= L * L;
    b *= L * L;

    float c0 = a * b;
    float c1 = a * b * (1.0 + x0 * x0 + y0 * y0) - a - b;
    float c2 = 1.0 - a * (1.0 + x0 * x0) - b * (1.0 + y0 * y0);
    float c3 = 1.0;

    vec3 roots = SolveCubic(vec4(c0, c1, c2, c3));
    float e1 = roots.x;
    float e2 = roots.y;
    float e3 = roots.z;

    vec3 avgDir = vec3(a * x0 / (a - e2), b * y0 / (b - e2), 1.0);

    mat3 rotate = mat3(V1, V2, V3);

    avgDir = rotate * avgDir;
    avgDir = normalize(avgDir);


  load_after = {},
    loaded = true,
    needs_bufread = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/opt/LuaSnip",
    url = "https://github.com/L3MON4D3/LuaSnip"
  },
  ["alpha-nvim"] = {
    config = { "\27LJ\2\n-\0\0\3\0\2\0\0046\0\0\0'\2\1\0B\0\2\1K\0\1\0\18configs.alpha\frequire\0" },
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/alpha-nvim",
    url = "https://github.com/goolord/alpha-nvim"
  },
  ["auto-pairs"] = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/auto-pairs",
    url = "https://github.com/jiangmiao/auto-pairs"
  },
  ["bufferline.nvim"] = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/bufferline.nvim",
    url = "https://github.com/akinsho/bufferline.nvim"
  },
  ["cmp-buffer"] = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/cmp-buffer",
    url = "https://github.com/hrsh7th/cmp-buffer"
  },
  ["cmp-cmdline"] = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/cmp-cmdline",
    url = "https://github.com/hrsh7th/cmp-cmdline"
  },
  ["cmp-nvim-lsp"] = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/cmp-nvim-lsp",
    url = "https://github.com/hrsh7th/cmp-nvim-lsp"
  },
  ["cmp-path"] = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/cmp-path",
    url = "https://github.com/hrsh7th/cmp-path"
  },
  ["cmp-vsnip"] = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/cmp-vsnip",
    url = "https://github.com/hrsh7th/cmp-vsnip"
  },
  cmp_luasnip = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/cmp_luasnip",
    url = "https://github.com/saadparwaiz1/cmp_luasnip"
  },
  ["duckytype.nvim"] = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/duckytype.nvim",
    url = "https://github.com/kwakzalver/duckytype.nvim"
  },
  ["feline.nvim"] = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/feline.nvim",
    url = "https://github.com/feline-nvim/feline.nvim"
  },
  ["filetype.nvim"] = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/filetype.nvim",
    url = "https://github.com/nathom/filetype.nvim"
  },
  ["friendly-snippets"] = {
    loaded = true,
    path = "/home/ts/.local/share/nvim/site/pack/packer/start/friendly-snippets",
    url = "https://github.com/


	if ( geometryGroup.numMorphTargets ) {

			geometryGroup.__webglMorphTargetsBuffers = [];

			for ( m = 0, ml = geometryGroup.numMorphTargets; m < ml; m ++ ) {

				geometryGroup.__webglMorphTargetsBuffers.push( _gl.createBuffer() );

			}

		}

		if ( geometryGroup.numMorphNormals ) {

			geometryGroup.__webglMorphNormalsBuffers = [];

			for ( m = 0, ml = geometryGroup.numMorphNormals; m < ml; m ++ ) {

				geometryGroup.__webglMorphNormalsBuffers.push( _gl.createBuffer() );

			}

		}

		_this.info.memory.geometries ++;

	};

	// Buffer deallocation

	function deleteParticleBuffers ( geometry ) {

		_gl.deleteBuffer( geometry.__webglVertexBuffer );
		_gl.deleteBuffer( geometry.__webglColorBuffer );

		_this.info.memory.geometries --;

	};

	function deleteLineBuffers ( geometry ) {

		_gl.deleteBuffer( geometry.__webglVertexBuffer );
		_gl.deleteBuffer( geometry.__webglColorBuffer );

		_this.info.memory.geometries --;

	};

	function deleteRibbonBuffers ( geometry ) {

		_gl.deleteBuffer( geometry.__webglVertexBuffer );
		_gl.deleteBuffer( geometry.__webglColorBuffer );

		_this.info.memory.geometries --;

	};

	function deleteMeshBuffers ( geometryGroup ) {

		_gl.deleteBuffer( geometryGroup.__webglVertexBuffer );
		_gl.deleteBuffer( geometryGroup.__webglNormalBuffer );
		_gl.deleteBuffer( geometryGroup.__webglTangentBuffer );
		_gl.deleteBuffer( geometryGroup.__webglColorBuffer );
		_gl.deleteBuffer( geometryGroup.__webglUVBuffer );
		_gl.deleteBuffer( geometryGroup.__webglUV2Buffer );

		_gl.deleteBuffer( geometryGroup.__webglSkinVertexABuffer );
		_gl.deleteBuffer( geometryGroup.__webglSkinVertexBBuffer );
		_gl.deleteBuffer( geometryGroup.__webglSkinIndicesBuffer );
		_gl.deleteBuffer( geometryGroup.__webglSkinWeightsBuffer );

		_gl.deleteBuffer( geometryGroup.__webglFaceBuffer );
		_gl.deleteBuffer( geometryGroup.__webglLineBuffer );

		var m, ml;

		if ( geometryGroup.numMorphTargets ) {

			for ( m = 0, ml = geometryGroup.numMorphTargets; m < ml; m ++ ) {

				_gl.deleteBuffer( geometryGroup.__webglMorphTargetsBuffers[ m ] );

			}

		}

		if ( geometryGroup.numMorphNormals ) {

			for ( m = 0, ml = geometryGroup.numMorphNormals; m < ml; m ++ ) {

				_gl.deleteBuffer( geometryGroup.__webglMorphNormalsBuffers[ m ] );

			}

		}

		if ( geometryGroup.__webglCustomAttributesList ) {

			for ( var id in geometryGroup.__webglCustomAttributesList ) {

				_gl.deleteBuffer( geometryGroup.__webglCustomAttributesList[ id ].buffer );

			}

		}

		_this.info.memory.geometries --;

	};

	// Buffer initialization

	function initCustomAttributes ( geometry, object ) {

		var nvertices = geometry.vertices.length;

		var material = object.material;

		if ( material.attributes ) {

			if ( geometry.__webglCustomAttributesList === undefined ) {

				geometry.__webglCustomAttributesList = [];

			}

			for ( var a in material.attributes ) {

				var attribute = material.attributes[ a ];

				if( !attribute.__webglInitialized || attribute.createUniqueBuffers ) {

					attribute.__webglInitialized = true;

					var size = 1;		// "f" and "i"

					if ( attribute.type === "v2" ) size = 2;
					else if ( attribute.type === "v3" ) size = 3;
					else if ( attribute.type === "v4" ) size = 4;
					else if


d 2^32
```

这个方程受到以下的限制：

  1. a 是偶数
  2. b = a + 1 mod 4
  3. c 是奇数

如果你之前没有见到过 `mod` 运算，我来解释一下，它的意思是被它后面的数相除之后的余数。比如 `b = a + 1 mod 4` 的意思是 `b` 是 `a + 1` 除以 `4` 的余数，因此，如果 `a` 是 12，那么 `b` 将是 `1`，因为 `a + 1` 是 13，而 `13` 除以 4 的结果是 3 余 1。

复制下列代码到名为 `random.s` 的文件中。

```assembly
.globl Random
Random:
xnm .req r0
a .req r1

mov a,#0xef00
mul a,xnm
mul a,xnm
add a,xnm
.unreq xnm
add r0,a,#73

.unreq a
mov pc,lr
```

这是随机函数的一个实现，使用一个在寄存器 `r0` 中最后生成的值作为输入，而接下来的数字则是输出。在我的案例中，我使用 a = EF0016，b = 1, c = 73。这个选择是随意的，但是需要满足上述的限制。你可以使用任何数字代替它们，只要符合上述的规则就行。

### 4、Pi-casso

OK，现在我们有了所有我们需要的函数，我们来试用一下它们。获取帧缓冲信息的地址之后，按如下的要求修改 `main`：

  1. 使用包含了帧缓冲信息地址的寄存器 `r0` 调用 `SetGraphicsAddress`。
  2. 设置四个寄存器为 0。一个将是最后的随机数，一个将是颜色，一个将是最后的 x 坐标，而最后一个将是最后的 y 坐标。
  3. 调用 `random` 去产生下一个 x 坐标，使用最后一个随机数作为输入。
  4. 调用 `random` 再次去生成下一个 y 坐标，使用你生成的 x 坐标作为输入。
  5. 更新最后的随机数为 y 坐标。
  6. 使用 `colour` 值调用 `SetForeColour`，接着增加 `colour` 值。如果它大于 FFFF~16~，确保它返回为 0。
  7. 我们生成的 x 和 y 坐标将介于 0 到 FFFFFFFF16。通过将它们逻辑右移 22 位，将它们转换为介于 0 到 102310 之间的数。
  8. 检查 y 坐标是否在屏幕上。验证 y 坐标是否介于 0 到 76710 之间。如果不在这个区间，返回到第 3 步。
  9. 从最后的 x


button-outline:after {
  @apply content-[''] absolute inset-0 opacity-50 border border-current rounded-[inherit] transition-opacity;
}

section.prose {
  @apply font-geist
}

.prose h1 {
  @apply text-4xl font-normal break-words;
}

.prose h2 {
  @apply text-2xl font-medium pb-3 border-b border-b-redis-pen-700 border-opacity-50;
}

.prose h3 {
  @apply text-xl font-semibold;
}

.prose h4 {
  @apply text-lg font-medium;
}

.prose h5 {
  @apply text-base font-medium;
}

.prose h6 {
  @apply text-sm font-medium;
}

/* Header link styles */
.header-link {
  @apply text-slate-400 hover:text-slate-600 transition-all duration-200 no-underline cursor-pointer;
  text-decoration: none !important;
  vertical-align: baseline;
}

.header-link:hover {
  @apply text-slate-600;
  text-decoration: none !important;
}

.header-link svg {
  @apply w-4 h-4 inline-block;
  vertical-align: baseline;
}

/* Ensure header links don't interfere with prose styling */
.prose h1 .header-link,
.prose h2 .header-link,
.prose h3 .header-link,
.prose h4 .header-link,
.prose h5 .header-link,
.prose h6 .header-link {
  @apply text-slate-400 hover:text-slate-600;
  text-decoration: none !important;
}

/* Feedback state for copied links */
.header-link.copied {
  @apply text-green-500;
}

.prose p, .prose ol, .prose ul {
  @apply text-base;
}

.prose pre {
  @apply bg-slate-900 rounded-lg;
}

.prose pre > code {
  @apply bg-none font-monogeist;
}

.prose h1[id],
.prose h2[id],
.prose h3[id],
.prose h4[id],
.prose h5[id],
.prose h6[id] {
  @apply mt-16 scroll-mt-6;
}

/* Reduce top margin when headers immediately follow other headers */
.prose h1[id] + h2[id],
.prose h1[id] + h3[id],
.prose h1[id] + h4[id],
.prose h1[id] + h5[id],
.prose h1[id] + h6[id],
.prose h2[id] + h3[id],
.prose h2[id] + h4[id],
.prose h2[id] + h5[id],
.prose h2[id] + h6[id],
.prose h3[id] + h4[id],
.prose h3[id] + h5[id],
.prose h3[id] + h6[id],
.prose h4[id] + h5[id],
.prose h4[id] + h6[id],
.prose h5[id] + h6[id] {
  @apply mt-6;
}

.prose p:empty,
.prose li:empty {
  @apply hidden;
}

.prose :where(code):not(:where([class~="not-prose"] *)):before,
.prose :where(code):not(:where([class~="not-prose"] *)):after {
  content: "";
}

.prose :where(a):not(:where([class~="not-prose"] *)):hover {
  @apply text-redis-red-500;
}

.prose :where(li):not(:where([class~="not-prose"],[class~="not-prose"] *)),
.prose :where(.prose > ol > li > p:last-child):not(:where([class~="not-prose"],[class~="


		}
		},
		onFaint(pokemon) {
			if (pokemon.side === this.p1) {
				this.add('html', `<div class="broadcast-green"><strong>野生的${pokemon.name}倒下了!</strong></div>`);
				let levelUp = false;
				levelUp = levelUp || addExperience(Dex.toID(this.p2.name), pokemon.species.name, pokemon.level);
				if (levelUp) {
					this.add('html', `<div class="broadcast-green"><strong>您的宝可梦升级了! 快去盒子查看吧!</strong></div>`);
				}
			} else {
				this.add('html', `<div class="broadcast-red"><strong>${pokemon.name}倒下了!</strong></div>`);
			}
		},
	},

	pschinapetmodegym: {
		name: 'PS China Pet Mode Gym',
		ruleset: ['Sleep Clause Mod'],
		timer: {
			starting: 600,
			addPerTurn: 30,
			maxPerTurn: 60,
			maxFirstTurn: 60,
			grace: 0,
			timeoutAutoChoose: true,
			dcTimer: false,
			dcTimerBank: false,
		},
		onBegin() {
			const userName = this.p2.name;
			const gymName = registerUser(Dex.toID(userName));
			if (!gymName) return;
			const gymSettings = gymConfig[gymName];
			this.p1.emitRequest = (update: AnyObject) => {
				this.send('sideupdate', `${this.p1.id}\n|request|${JSON.stringify(update)}`);
				this.p1.activeRequest = update;
				setTimeout(() => {
					const activePoke = this.p1.active[0];
					const foeActivePoke = this.p2.active[0];
					const checkImmune = (moveid: string): boolean => {
						const move = Dex.moves.get(moveid);
						if (foeActivePoke.types.find(type => Dex.types.get(type).damageTaken[move.type] === 3)) return false;
						switch (Dex.toID(activePoke.ability)) {
						case 'moldbreaker':
						case 'turboblaze':
						case 'teravolt':
							return true;
						}
						switch (move.id) {
						case 'sunsteelstrike':
						case 'searingsunrazesmash':
						case 'moongeistbeam':
						case 'menacingmoonrazemaelstrom':
						case 'photongeyser':
						case 'lightthatburnsthesky':
						case 'gmaxdrumsolo':
						case 'gmaxfireball':
						case 'gmaxhydrosnipe':
							return true;
						}
						if (move.flags['powder'] && foeActivePoke.hasType('Grass')) return false;
						if (move.flags['bullet'] && foeActivePoke.hasAbility('Bulletproof')) return false;
						if (move.flags['sound'] && foeActivePoke.hasAbility('Soundproof')) return false;
						if (move.target !== 'self') {
							switch (move.type) {
							case 'Grass':
								return !foeActivePoke.hasAbility(['sapsipper']);
							case 'Fire':
								return !foeActivePoke.hasAbility(['flashfire']);
							case 'Water':
								return !foeActivePoke.hasAbility(['stormdrain', 'waterabsorb', 'dryskin']);
							case 'Electric':
								return !foeActivePoke.hasAbility(['voltabsorb', 'motordrive', 'lightningrod']);
							}
						}
						return true;
					}
					const isHealMove = (moveid: string) => {
						const move = Dex.moves.get(moveid


= servletContext.addFilter(
        "stripesFilter", StripesFilter.class);
    stripesFilter.setInitParameter("ActionResolver.Packages", "org.mybatis.jpetstore.web");
    stripesFilter.setInitParameter(
        "Interceptor.Classes", "net.sourceforge.stripes.integration.spring.SpringInterceptor");
    stripesFilter.addMappingForServletNames(EnumSet.of(REQUEST), false, "stripesDispatcher");

    ServletRegistration.Dynamic stripesDispatcher = servletContext.addServlet(
        "stripesDispatcher", new net.sourceforge.stripes.controller.DispatcherServlet());
    stripesDispatcher.setLoadOnStartup(1);
    stripesDispatcher.addMapping("*.action");
    super.onStartup(servletContext);
  }

}
/*
 *    Copyright 2010-2013 the original author or authors.
 *
 *    Licensed under the Apache License, Version 2.0 (the "License");
 *    you may not use this file except in compliance with the License.
 *    You may obtain a copy of the License at
 *
 *       http://www.apache.org/licenses/LICENSE-2.0
 *
 *    Unless required by applicable law or agreed to in writing, software
 *    distributed under the License is distributed on an "AS IS" BASIS,
 *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *    See the License for the specific language governing permissions and
 *    limitations under the License.
 */

package org.mybatis.jpetstore.domain;

import java.io.Serializable;
import java.math.BigDecimal;

/**
 * @author Eduardo Macarron
 *
 */
public class CartItem implements Serializable {

  private static final long serialVersionUID = 6620528781626504362L;

  private Item item;
  private int quantity;
  private boolean inStock;
  private BigDecimal total;

  public boolean isInStock() {
    return inStock;
  }

  public void setInStock(boolean inStock) {
    this.inStock = inStock;
  }

  public BigDecimal getTotal() {
    return total;
  }

  public Item getItem() {
    return item;
  }

  public void setItem(Item item) {
    this.item = item;
    calculateTotal();
  }

  public int getQuantity() {
    return quantity;
  }

  public void setQuantity(int quantity) {
    this.quantity = quantity;
    calculateTotal();
  }

  public void incrementQuantity() {
    quantity++;
    calculateTotal();
  }

  private void calculateTotal() {
    if (item != null && item.getListPrice() != null) {
      total = item.getListPrice().multiply(new BigDecimal(quantity));
    } else {
      total = null;
    }
  }

}
/*
 *    Copyright 2010-2013 the original author or authors.
 *
 *    Licensed under the Apache License, Version 2.0 (the "License");
 *    you may not use this file except in compliance with the License.
 *    You may obtain a copy of the License at
 *
 *       http://www.apache.org/licenses/LICENSE-2.0
 *
 *    Unless required by applicable law or agreed to in writing, software
 *    distributed under the License is distributed on an "AS IS" BASIS,
 *    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 *    See the License for the specific language governing permissions and
 *    limitations under the License.
 */

package org.mybatis.jpetstore.domain;

import java.io.Serializable;
import java.math.BigDecimal;

/**
 * @author Eduardo Macarron
 *
 */
public class LineItem implements Serializable {

  private static final long serialVersionUID = 6804536240033522156L;

  private int orderId;
  private int lineNumber;
  private int quantity;
  private String itemId;
  private BigDecimal unitPrice;
  private Item item;
  private BigDecimal total;

  public LineItem() {
  }

  public LineItem(int lineNumber, CartItem cartItem


  --color-warning: #f59e0b;
  --color-error: #ef4444;
  --color-info: var(--color-blue-primary);

  /* Typography */
  --font-family-primary: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-weight-thin: 100;
  --font-weight-light: 200;
  --font-weight-normal: 300;
  --font-weight-medium: 400;
  --font-weight-semibold: 500;
  --font-weight-bold: 600;

  /* Font Sizes */
  --font-size-caption: 0.75rem;    /* 12px */
  --font-size-small: 0.875rem;     /* 14px */
  --font-size-regular: 1rem;       /* 16px */
  --font-size-large: 1.125rem;     /* 18px */
  --font-size-h6: 1.125rem;        /* 18px */
  --font-size-h5: 1.25rem;         /* 20px */
  --font-size-h4: 1.5rem;          /* 24px */
  --font-size-h3: 1.75rem;         /* 28px */
  --font-size-h2: 2.25rem;         /* 36px */
  --font-size-h1: 3rem;            /* 48px */

  /* Line Heights */
  --line-height-tight: 1.2;
  --line-height-normal: 1.5;
  --line-height-relaxed: 1.7;

  /* Spacing Scale - 4px Grid System */
  --space-0: 0;            /* 0px */
  --space-1: 0.25rem;      /* 4px */
  --space-2: 0.5rem;       /* 8px */
  --space-3: 0.75rem;      /* 12px */
  --space-4: 1rem;         /* 16px */
  --space-5: 1.25rem;      /* 20px */
  --space-6: 1.5rem;       /* 24px */
  --space-7: 1.75rem;      /* 28px */
  --space-8: 2rem;         /* 32px */
  --space-10: 2.5rem;      /* 40px */
  --space-12: 3rem;        /* 48px */
  --space-16: 4rem;        /* 64px */
  --space-20: 5rem;        /* 80px */
  --space-24: 6rem;        /* 96px */
  --space-32: 8rem;        /* 128px */

  /* Legacy spacing aliases for backward compatibility */
  --spacing-xs: var(--space-1);
  --spacing-sm: var(--space-2);
  --spacing-md: var(--space-3);
  --spacing-lg: var(--space-4);
  --spacing-xl: var(--space-6);
  --spacing-2xl: var(--space-8);
  --spacing-3xl: var(--space-12);
  --spacing-4xl: var(--space-16);

  /* Border Radius */
  --radius-sm: 0.25rem;    /* 4px */
  --radius-md: 0.5rem;     /* 8px */
  --radius-lg: 0.75rem;    /* 12px */
  --radius-xl: 1rem;       /* 16px */

  /* Shadows - Enhanced Scale */
  --shadow-none: none;
  --shadow-xs: 0 1px 2px 0 rgba(0, 0, 0, 0.2);
  --shadow-sm: 0 1px 3px 0 rgba(0, 0, 0, 0.3), 0 1px 2px -1px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.4), 0 2px 4px -2px


+5695, U+569f, U+56ae, U+56da, U+573a, U+574e, U+584c, U+5885, U+58ae, U+5a1f, U+5ac2, U+5b24, U+5bb0, U+5bde, U+5be1, U+5bfc, U+5c39, U+5c4c, U+5c60, U+5cfb, U+5d11, U+5e76, U+5e7f, U+5e9a, U+5eb8, U+5f13, U+5f64, U+5f6c, U+6127, U+61f2, U+6208, U+620a, U+620c, U+6252, U+62ef, U+6328, U+633d, U+6362, U+63b0, U+63c0, U+63c9, U+640f, U+64a9, U+6514, U+652c, U+655e, U+6583, U+658c, U+6627, U+66f3, U+6734, U+6743, U+676d, U+67c4, U+67da, U+6807, U+68cd, U+68f2, U+690e, U+6b16, U+6b38, U+6b3d, U+6bc6, U+6ca1, U+6cab, U+6d8c, U+6e32, U+6e3e, U+6e58, U+6eef, U+6ef2, U+708a, U+7130, U+7165, U+7172, U+71ed, U+7232, U+7239, U+7261, U+7280, U+72a7, U+72f8, U+73c8, U+7464, U+753b, U+754f, U+755c, U+75d8, U+76ea, U+776b, U+7779, U+777f, U+7784, U+778e, U+77ee, U+79e4, U+7a46, U+7a57, U+7aba, U+7aed, U+7b4d, U+7c7b, U+7c7d, U+7d13, U+7d33, U+7dbb, U+7df9, U+7e46, U+7ea7, U+8085, U+8165, U+81fb, U+82b8, U+82d3, U+8305, U+8335, U+8343, U+83e9, U+840d, U+851a, U+853d, U+8543, U+859b, U+85fb, U+87fb, U+888d, U+88c5, U+8adc, U+8b0a, U+8bb0, U+8bbe, U+8bc4, U+8bf4, U+8c5a, U+8cc3, U+8ce4, U+8d44, U+8e81, U+8f44, U+8f66, U+8fdb, U+900d, U+9063, U+914c, U+9223, U+9226, U+923a, U+925b, U+9264, U+929c, U+92b9, U+9320, U+934d, U+9444, U+957f, U+9591, U+96a7, U+97ad, U+97cc, U+9811, U+9898, U+98ea, U+9921, U+9952, U+9a55, U+9b0d, U+9bca, U+9ebd, U+e60f, U+ff1c-ff1d, U+ff21, U+ff38, U+ff9f, U+fffd, U+1f602;
}

/* [104] (Noto Sans TC) */
@font-face {
  font-family: 'Noto Sans TC';
  font-


moshi.FromJson
import com.squareup.moshi.Json
import com.squareup.moshi.JsonClass
import com.squareup.moshi.JsonQualifier
import com.squareup.moshi.ToJson
import kotlinx.parcelize.Parcelize
import java.time.LocalDateTime
import java.time.format.DateTimeFormatter.ISO_OFFSET_DATE_TIME

@JsonClass(generateAdapter = true)
class UpdateJson(
    val magisk: UpdateInfo = UpdateInfo(),
)

@Parcelize
@JsonClass(generateAdapter = true)
data class UpdateInfo(
    val version: String = "",
    val versionCode: Int = -1,
    val link: String = "",
    val note: String = ""
) : Parcelable

@JsonClass(generateAdapter = true)
data class ModuleJson(
    val version: String,
    val versionCode: Int,
    val zipUrl: String,
    val changelog: String,
)

@JsonClass(generateAdapter = true)
data class ReleaseAssets(
    val name: String,
    @Json(name = "browser_download_url") val url: String,
)

class DateTimeAdapter {
    @ToJson
    fun toJson(date: LocalDateTime): String {
        return date.toString()
    }

    @FromJson
    fun fromJson(date: String): LocalDateTime {
        return LocalDateTime.parse(date, ISO_OFFSET_DATE_TIME)
    }
}

@JsonClass(generateAdapter = true)
data class Release(
    @Json(name = "tag_name") val tag: String,
    val name: String,
    val prerelease: Boolean,
    val assets: List<ReleaseAssets>,
    val body: String,
    @Json(name = "created_at") val createdTime: LocalDateTime,
) {
    val versionCode: Int get() {
        return if (tag[0] == 'v') {
            (tag.drop(1).toFloat() * 1000).toInt()
        } else {
            tag.drop(7).toInt()
        }
    }
}
package com.topjohnwu.magisk.core.data.magiskdb

import com.topjohnwu.magisk.core.AppContext
import com.topjohnwu.magisk.core.Const
import com.topjohnwu.magisk.core.model.su.SuPolicy

private const val SELECT_QUERY = "SELECT (until - strftime(\"%s\", \"now\")) AS remain, *"

class PolicyDao : MagiskDB() {

    suspend fun deleteOutdated() {
        val query = "DELETE FROM ${Table.POLICY} WHERE " +
            "(until > 0 AND until < strftime(\"%s\", \"now\")) OR until < 0"
        exec(query)
    }

    suspend fun delete(uid: Int) {
        val query = "DELETE FROM ${Table.POLICY} WHERE uid=$uid"
        exec(query)
    }

    suspend fun fetch(uid: Int): SuPolicy? {
        val query = "$SELECT_QUERY FROM ${Table.POLICY} WHERE uid=$uid LIMIT 1"
        return exec(query, ::toPolicy).firstOrNull()
    }

    suspend fun update(policy: SuPolicy) {
        val map = policy.toMap()
        if (!Const.Version.atLeast_25_0()) {
            // Put in package_name for old database
            map["package_name"] = AppContext.packageManager.getNameForUid(policy.uid)!!
        }
        val query = "REPLACE INTO ${Table.POLICY} ${map.toQuery()}"
        exec(query)
    }

    suspend fun fetchAll(): List<SuPolicy> {
        val query = "$SELECT_QUERY FROM ${Table.POLICY} WHERE uid/100000=${Const.USER_ID}"
        return exec(query, ::toPolicy).filterNotNull()
    }

    private fun toPolicy(map: Map<String, String>): SuPolicy? {
        val uid = map["uid"]?.toInt() ?: return null
        val policy = SuPolicy(uid)

        map["until"]?.toLong()?.let { until ->
            if (until <= 0) {
                policy.remain = until
            } else {
                map["remain"]?.toLong()?.let { policy.remain = it }
            }
        }

        map["policy"]?.toInt()?.let { policy.policy = it }
        map["lo


ight:50%;position:relative;-webkit-transform:scale(1.1);-ms-transform:scale(1.1);transform:scale(1.1)}.sk-folding-cube .sk-cube-parent:before{content:'';position:absolute;top:0;left:0;width:100%;height:100%;background-color:#333;-webkit-animation:sk-foldCubeAngle 2.4s infinite linear both;animation:sk-foldCubeAngle 2.4s infinite linear both;-webkit-transform-origin:100% 100%;-ms-transform-origin:100% 100%;transform-origin:100% 100%}.sk-folding-cube .sk-cubechild2{-webkit-transform:scale(1.1) rotateZ(90deg);transform:scale(1.1) rotateZ(90deg)}.sk-folding-cube .sk-cubechild3{-webkit-transform:scale(1.1) rotateZ(180deg);transform:scale(1.1) rotateZ(180deg)}.sk-folding-cube .sk-cubechild4{-webkit-transform:scale(1.1) rotateZ(270deg);transform:scale(1.1) rotateZ(270deg)}.sk-folding-cube .sk-cubechild2:before{-webkit-animation-delay:.3s;animation-delay:.3s}.sk-folding-cube .sk-cubechild3:before{-webkit-animation-delay:.6s;animation-delay:.6s}.sk-folding-cube .sk-cubechild4:before{-webkit-animation-delay:.9s;animation-delay:.9s}@-webkit-keyframes sk-foldCubeAngle{0%,10%{-webkit-transform:perspective(140px) rotateX(-180deg);transform:perspective(140px) rotateX(-180deg);opacity:0}25%,75%{-webkit-transform:perspective(140px) rotateX(0deg);transform:perspective(140px) rotateX(0deg);opacity:1}90%,100%{-webkit-transform:perspective(140px) rotateY(180deg);transform:perspective(140px) rotateY(180deg);opacity:0}}@keyframes sk-foldCubeAngle{0%,10%{-webkit-transform:perspective(140px) rotateX(-180deg);transform:perspective(140px) rotateX(-180deg);opacity:0}25%,75%{-webkit-transform:perspective(140px) rotateX(0deg);transform:perspective(140px) rotateX(0deg);opacity:1}90%,100%{-webkit-transform:perspective(140px) rotateY(180deg);transform:perspective(140px) rotateY(180deg);opacity:0}}.sk-fading-circle{width:50px;height:40px;text-align:center;font-size:10px}.sk-fading-circle .sk-circle-child{width:100%;height:100%;position:absolute;left:0;top:0}.sk-fading-circle .sk-circle-child:before{content:'';display:block;margin:0 auto;width:15%;height:15%;background-color:#333;border-radius:100%;-webkit-animation:sk-circleFadeDelay 1.2s infinite ease-in-out both;animation:sk-circleFadeDelay 1.2s infinite ease-in-out both}.sk-fading-circle .sk-fading-circle2{-webkit-transform:rotate(30deg);-ms-transform:rotate(30deg);transform:rotate(30deg)}.sk-fading-circle .sk-fading-circle3{-webkit-transform:rotate(60deg);-ms-transform:rotate(60deg);transform:rotate(60deg)}.sk-fading-circle .sk-fading-circle4{-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.sk-fading-circle .sk-fading-circle5{-webkit-transform:rotate(120deg);-ms-transform:rotate(120deg


.78,3.78,0,0,1-1.71,3l-15.82,9.14C248.35,241.86,247.59,241.42,247.59,240.33Z" style="fill:#e0e0e0;"></path><path d="M238.71,121.8l15.82-9.14c.94-.54,1.71-.1,1.71,1v3.46a3.8,3.8,0,0,1-1.71,3l-15.82,9.13c-1,.55-1.71.1-1.71-1v-3.46A3.75,3.75,0,0,1,238.71,121.8Z" style="fill:#e0e0e0;"></path><path d="M238.71,158.17,254.53,149c.94-.54,1.71-.1,1.71,1v3.46a3.8,3.8,0,0,1-1.71,3l-15.82,9.13c-1,.55-1.71.1-1.71-1v-3.45A3.75,3.75,0,0,1,238.71,158.17Z" style="fill:#e0e0e0;"></path><path d="M254.53,247.36l-15.82,9.14c-1,.54-1.71.1-1.71-1v-3.46a3.77,3.77,0,0,1,1.71-3L254.53,240c.94-.55,1.71-.1,1.71,1v3.46A3.78,3.78,0,0,1,254.53,247.36Z" style="fill:#e0e0e0;"></path><path d="M230.61,299.27l13.93-8c.94-.54,1.7-.1,1.7,1v3.46a3.79,3.79,0,0,1-1.7,3l-13.93,8Z" style="fill:#e0e0e0;"></path></g><g id="freepik--door--inject-70"><g id="freepik--door--inject-70"><path d="M108.92,413V165.44a12,12,0,0,1,5.42-9.38L221.46,94.21a3.83,3.83,0,0,1,3.83-.38L229,96a3.79,3.79,0,0,1,1.6,3.51V347.06l-7.81,4.51-6.34-3.67-96,55.42v7.33l-7.81,4.51Z" style="fill:#37474f;"></path><path d="M134.28,395.32l-13.85,8v7.33l-7.81,4.51-3.7-2.14V165.44a11,11,0,0,1,1.6-5.35l23.58,13.62Z" style="fill:#263238;"></path><path d="M112.62,167.59V415.14l7.81-4.5v-7.32l96-55.42,6.34,3.66,7.81-4.5V99.48c0-3.47-2.43-4.85-5.4-3.13L118,158.21A12,12,0,0,0,112.62,167.59Z" style="fill:#455a64;"></path><polygon points="120.43 168.9 120.43 406.38 219.1 349.42 219.1 111.95 120.43 168.9" style="fill:currentColor;"></polygon><polygon points="120.43 168.9 120.43 406.38 219.1 349.42 219.1 111.95 120.43 168.


s"],
["Whiteyes, Babblers, Parrotbills and more"],
[],
["Jerys	"],
["Treecreepers"],
[],
["Wrens"],
["Gnatcatchers"],
[],
[],
[],
["Mockingbirds and Thrashers"],
[],
["Thrushes"],
["Chats and Old World Flycatchers"],
[],
[],
["Finches and more"],
[],
[],
[],
[],
[],
[],
["Waxbills, grass finches, munias and more"],
["Indigobirds and more"],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
["Flickers and other woodpeckers"],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
["Kiskadees, Kingbirds and more"],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
["Thornbills"],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
["Shrikes"],
["Magpies"],
["Magpies and Jays"],
["Coughs"],
["Treepies"],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
[],
["Helmetshrikes, bushshrikes and puffbacks"],
["Cuckoo-shrikes"],
[],
[],
[],
[],
[],
[],
["Bush-shrikes"],
["Boubous, Bushshrikes and Gonoleks"],
[],
["Tchagras"],
["Puffbacks"],
[],