ter_types! {
	pub const MaxBorrowCap: Balance = MAX_BORROW_CAP;
}

impl controller::Config for Runtime {
	type Event = Event;
	type MultiCurrency = Currencies;
	type PriceSource = Prices;
	type LiquidityPoolsManager = LiquidityPools;
	type MinterestModelManager = MinterestModel;
	type MaxBorrowCap = MaxBorrowCap;
	type UpdateOrigin = EnsureRootOrHalfMinterestCouncil;
	type ControllerWeightInfo = weights::controller::WeightInfo<Runtime>;
	type MntManager = MntToken;
}

impl module_prices::Config for Runtime {
	type Event = Event;
	type Source = AggregatedDataProvider;
	type LockOrigin = EnsureRootOrTwoThirdsMinterestCouncil;
	type WeightInfo = weights::prices::WeightInfo<Runtime>;
}

parameter_types! {
	pub const BlocksPerYear: u128 = BLOCKS_PER_YEAR;
}

impl minterest_model::Config for Runtime {
	type Event = Event;
	type BlocksPerYear = BlocksPerYear;
	type ModelUpdateOrigin = EnsureRootOrHalfMinterestCouncil;
	type WeightInfo = weights::minterest_model::WeightInfo<Runtime>;
}

parameter_types! {
	pub const RiskManagerPriority: TransactionPriority = TransactionPriority::max_value();
	pub const LiquidityPoolsPriority: TransactionPriority = TransactionPriority::max_value() - 1;
	pub const PartialLiquidationMinSum: Balance = PARTIAL_LIQUIDATION_MIN_SUM;
	pub const PartialLiquidationMaxAttempts: u8 = PARTIAL_LIQUIDATION_MAX_ATTEMPTS;
	pub const MaxLiquidationFee: Rate = MAX_LIQUIDATION_FEE;
	pub const RiskManagerWorkerMaxDurationMs: u64 = RISK_MANAGER_WORKER_MAX_DURATION_MS;
}

impl risk_manager::Config for Runtime {
	type Event = Event;
	type UnsignedPriority = RiskManagerPriority;
	type PriceSource = Prices;
	type UserCollateral = LiquidityPools;
	type PartialLiquidationMinSum = PartialLiquidationMinSum;
	type PartialLiquidationMaxAttempts = PartialLiquidationMaxAttempts;
	type MaxLiquidationFee = MaxLiquidationFee;
	type RiskManagerUpdateOrigin = EnsureRootOrHalfMinterestCouncil;
	type ControllerManager = Controller;
	type LiquidityPoolsManager = LiquidityPools;
	type LiquidationPoolsManager = LiquidationPools;
	type MinterestProtocolManager = MinterestProtocol;
	type OffchainWorkerMaxDurationMs = RiskManagerWorkerMaxDurationMs;
	type MultiCurrency = Currencies;
}

parameter_types! {
	pub MntTokenAccountId: AccountId = MntTokenPalletId::get().into_account();
}

impl mnt_token::Config for Runtime {
	type Event = Event;
	type PriceSource = Prices;
	type UpdateOrigin = EnsureRootOrTwoThirdsMinterestCouncil;
	type LiquidityPoolsManager = LiquidityPools;
	type MultiCurrency = Currencies;
	type ControllerManager = Controller;
	type MntTokenAccountId = MntTokenAccountId;
	type MntTokenWeightInfo = weights::mnt_token::WeightInfo<Runtime>;
}

impl<C> frame_system::offchain::SendTransactionTypes<C> for Runtime
where
	Call: From<C>,
{
	type OverarchingCall = Call;
	type Extrinsic = UncheckedExtrinsic;
}

parameter_types! {
	pub LiquidationPoolAccountId: AccountId = LiquidationPoolsPalletId::get().into_account();
}

impl liquidation_pools::Config for Runtime {
	type Event = Event;
	type MultiCurrency = Currencies;
	type UnsignedPriority = LiquidityPoolsPriority;
	type LiquidationPoolAccountId = LiquidationPoolAccountId;
	type PriceSource = Prices;
	type LiquidationPoolsPalletId = LiquidationPoolsPalletId;
	type UpdateOrigin = EnsureRootOr


bis,1)
	call_pal op_mtpr_tbis
	RET
	END(tbis)

/*
 *	Object:
 *		tbiap			EXPORTED function
 *
 *		Invalidate Process-owned TLB entries
 *
 *	Arguments:
 *		none
 *
 */
LEAF(tbiap,0)
	call_pal op_mtpr_tbiap
	RET
	END(tbiap)

/*
 *	Object:
 *		tbia			EXPORTED function
 *
 *		Invalidate all TLB entries
 *
 *	Arguments:
 *		none
 *
 */
LEAF(tbia,0)
	call_pal op_mtpr_tbia
	RET
	END(tbia)

/*
 *	Object:
 *		rpcc			EXPORTED function
 *
 *		Read process cycle counter
 *
 *	Arguments:
 *		none
 *
 */
LEAF(rpcc,0)
	rpcc	v0
	RET
	END(rpcc)

/*
 *	Object:
 *		delay			EXPORTED function
 *		machine_cycles_per_usec	EXPORTED unsigned long
 *
 *		Busy loop for a given number of microseconds
 *
 *	Arguments:
 *		usecs			unsigned long
 *
 *	I thought of using the internal Cycle Counter, but it
 *	is only 32 bits and the masking and overflow issues
 *	would take more than necessary.  Besides,


rojectBrandingThemeBody) HasLogoUrl() bool {
	if o != nil && !IsNil(o.LogoUrl) {
		return true
	}

	return false
}

// SetLogoUrl gets a reference to the given string and assigns it to the LogoUrl field.
func (o *SetProjectBrandingThemeBody) SetLogoUrl(v string) {
	o.LogoUrl = &v
}

// GetName returns the Name field value if set, zero value otherwise.
func (o *SetProjectBrandingThemeBody) GetName() string {
	if o == nil || IsNil(o.Name) {
		var ret string
		return ret
	}
	return *o.Name
}

// GetNameOk returns a tuple with the Name field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *SetProjectBrandingThemeBody) GetNameOk() (*string, bool) {
	if o == nil || IsNil(o.Name) {
		return nil, false
	}
	return o.Name, true
}

// HasName returns a boolean if a field has been set.
func (o *SetProjectBrandingThemeBody) HasName() bool {
	if o != nil && !IsNil(o.Name) {
		return true
	}

	return false
}

// SetName gets a reference to the given string and assigns it to the Name field.
func (o *SetProjectBrandingThemeBody) SetName(v string) {
	o.Name = &v
}

// GetTheme returns the Theme field value if set, zero value otherwise.
func (o *SetProjectBrandingThemeBody) GetTheme() ProjectBrandingColors {
	if o == nil || IsNil(o.Theme) {
		var ret ProjectBrandingColors
		return ret
	}
	return *o.Theme
}

// GetThemeOk returns a tuple with the Theme field value if set, nil otherwise
// and a boolean to check if the value has been set.
func (o *SetProjectBrandingThemeBody) GetThemeOk() (*ProjectBrandingColors, bool) {
	if o == nil || IsNil(o.Theme) {
		return nil, false
	}
	return o.Theme, true
}

// HasTheme returns a boolean if a field has been set.
func (o *SetProjectBrandingThemeBody) HasTheme() bool {
	if o != nil && !IsNil(o.Theme) {
		return true
	}

	return false
}

// SetTheme gets a reference to the given ProjectBrandingColors and assigns it to the Theme field.
func (o *SetProjectBrandingThemeBody) SetTheme(v ProjectBrandingColors) {
	o.Theme = &v
}

func (o SetProjectBrandingThemeBody) MarshalJSON() ([]byte, error) {
	toSerialize,err := o.ToMap()
	if err != nil {
		return []byte{}, err
	}
	return json.Marshal(toSerialize)
}

func (o SetProjectBrandingThemeBody) ToMap() (map[string]interface{}, error) {
	toSerialize := map[string]interface{}{}
	if !IsNil(o.FaviconType) {
		toSerialize["favicon_type"] = o.FaviconType
	}
	if !IsNil(o.FaviconUrl) {
		toSerialize["favicon_url"] = o.FaviconUrl
	}
	if !IsNil(o.LogoType) {
		toSerialize["logo_type"] = o.LogoType
	}
	if !IsNil(o.LogoUrl) {
		toSerialize["logo_url"] = o.LogoUrl
	}
	if !IsNil(o.Name) {
		toSerialize["name"] = o.Name
	}
	if !IsNil(o.Theme) {
		toSerialize["theme"] = o.Theme
	}

	for key, value := range o.AdditionalProperties {
		toSerialize[key] = value
	}

	return toSerialize, nil
}

func (o *SetProjectBrandingThemeBody) UnmarshalJSON


rénrénzhìshì",
    "仁人义士|||仁人義士|rénrényìshì",
    "仁兄|||仁兄|rénxiōng",
    "仁化|||仁化|Rénhuà",
    "仁化县|||仁化縣|RénhuàXiàn",
    "仁厚|||仁厚|rénhòu",
    "仁和|||仁和|Rénhé",
    "仁和区|||仁和區|Rénhéqū",
    "仁和县|||仁和縣|Rénhéxiàn",
    "仁寿|||仁壽|Rénshòu",
    "仁寿县|||仁壽縣|RénshòuXiàn",
    "仁川|||仁川|Rénchuān",
    "仁川市|||仁川市|Rénchuānshì",
    "仁川广域市|||仁川廣域市|RénchuānGuǎngyùshì",
    "仁布|||仁布|Rénbù",
    "仁布县|||仁布縣|Rénbùxiàn",
    "仁弟|||仁弟|réndì",
    "仁德|||仁德|Réndé",
    "仁德乡|||仁德鄉|Réndéxiāng",
    "仁心仁术|||仁心仁術|rénxīnrénshù",
    "仁惠|||仁惠|rénhuì",
    "仁爱|||仁愛|Rén'ài",
    "仁爱区|||仁愛區|Rén'àiqū",
    "仁爱乡|||仁愛鄉|Rén'àixiāng",
    "仁慈|||仁慈|réncí",
    "仁怀|||仁懷|Rénhuái",
    "仁怀市|||仁懷市|Rénhuáishì",
    "仁怀县|||仁懷縣|Rénhuáixiàn",
    "仁政|||仁政|rénzhèng",
    "仁武|||仁武|Rénwǔ",
    "仁武乡|||仁武鄉|Rénwǔxiāng",
    "仁民爱物|||仁民愛物|rénmín'àiwù",
    "仁波切|||仁波切|Rénbōqiè",
    "仁义|||仁義|rényì",
    "仁义道德|||仁義道德|rényìdàodé",
    "仁者见仁，智者见智|||仁者見仁，智者見智|rénzhějiànrén, zhìzhějiànzhì",
    "仁至义尽|||仁至義盡|rénzhìyìjìn",
    "仁术|||仁術|rénshù",
    "仁言利博|||仁言利博|rényánlìbó",
    "仂|||仂|lè",


le una estrella! Así ayudas a que otros también lo descubran.

# Guía de Despliegue

## Visión General
Esta aplicación ahora utiliza rutas API locales de Next.js en lugar de Supabase Edge Functions para la integración con Stripe. Esto simplifica el despliegue y te permite usar archivos .env estándar para la configuración.

## Configuración de Variables de Entorno

### 1. Crear archivo .env.local
Copia `.env.example` a `.env.local` y rellena con tus valores reales:

```bash
cp .env.example .env.local
```
### 2. Variables de Entorno Requeridas

#### Configuración de Supabase
- `NEXT_PUBLIC_SUPABASE_URL` - La URL de tu proyecto Supabase
- `NEXT_PUBLIC_SUPABASE_ANON_KEY` - Tu clave anónima de Supabase
- `SUPABASE_SERVICE_ROLE_KEY` - Tu clave de rol de servicio de Supabase (solo del lado del servidor)

#### Configuración de Stripe (opcional)
- `STRIPE_SECRET_KEY` - Tu clave secreta de Stripe (solo del lado del servidor)
- `NEXT_PUBLIC_STRIPE_PUBLISHABLE_KEY` - Tu clave pública de Stripe
- `STRIPE_WEBHOOK_SECRET` - Tu secreto de webhook de Stripe

#### Configuración del Sitio
- `NEXT_PUBLIC_SITE_URL` - La URL de tu sitio (para producción)
- `NEXTAUTH_URL` - La URL de tu sitio (igual que la anterior)
- `NEXTAUTH_SECRET` - Un secreto aleatorio para NextAuth

## Desarrollo Local

1. Instala las dependencias:

```bash
npm install
```
2. Configura tus variables de entorno en `.env.local`

3. Ejecuta el servidor de desarrollo:

```bash
npm run dev
```
4. Pruebe los webhooks de Stripe localmente usando Stripe CLI:

```bash
stripe listen --forward-to localhost:3000/api/stripe/webhook
```
## Despliegue de Producción

### Despliegue en Vercel

1. **Desplegar en Vercel:**

```bash
npx vercel
```
2. **Variables de Entorno:**
   Agrega todas las variables de entorno a través del panel de Vercel o CLI

3. **Configuración del Webhook de Stripe:**
   - Apunta el webhook a: `https://your-domain.vercel.app/api/stripe/webhook`

## Endpoints de la API

La aplicación ahora utiliza estas rutas API locales:

- `POST /api/stripe/checkout` - Crea sesiones de pago de Stripe
- `POST /api/stripe/webhook` - Maneja eventos de webhooks de Stripe

## Beneficios de las Rutas API Locales

1. **Despliegue Más Simple** - No es necesario desplegar funciones edge por separado
2. **Variables de Entorno** - Soporte estándar para archivos .env
3. **Mejor Depuración** - Más fácil de depurar localmente
4. **Integración con Framework** - Mejor integración con Next.js
5. **Sin Bloqueo de Proveedor** - Puedes desplegar en cualquier plataforma que soporte Next.js

## Solución de Problemas

1. **Problemas con Webhook:**
   - Asegúrate de que `STRIPE_WEBHOOK_SECRET` coincida con tu endpo


de;
$blue-cool-60v: #07648d;
$blue-cool-80v: #002d3f;
$blue-vivid-5v: #e8f5ff;
$blue-warm-5: #ecf1f7;
$blue-warm-10: #e1e7f1;
$blue-vivid-70: #0B4778;
$blue-warm-5v: #edf5ff;
$blue-warm-40v: #5994f6;
$blue-warm-60: #345d96;
$blue-warm-60v: #0050d8;
$blue-warm-70v: #1A4480;
$blue-warm-80: #252f3e;
$indigo-cool-5v: #edf0ff;
$indigo-5v: #f0f0ff;
$indigo-50v: #656bd7;
$indigo-60v: #4a50c4;
$indigo-70v: #3333a3;
$indigo-cool-40v: #628EF4;
$indigo-cool-80v: #1B2B85;
$violet-20v: #D5BFFF;
$violet-50v: #9355DC;
$violet-60v: #783cb9;
$violet-70v: #54278f;
$gray-cool-1: #FBFCFD;
$gray-2: #F9F9F9;
$gray-10: #E6E6E6;
$gray-cool-30: #a9aeb1;
$gray-80: #2E2E2E;
$gray-90: #1B1B1B;
$gray-cool-50: #71767a;
$gray-cool-60: #565C65;
$gray-60: #5C5C5C;
$gray-cool-2: #f7f9fa;
$gray-cool-3: #f5f6f7;
$gray-cool-5: #edeff0;
$gray-cool-10: #dfe1e2;
$gray-cool-20: #c6cace;
$gray-cool-90: #1c1d1f;
$green-cool-5v: #E3F5E1;
$green-cool-20v: #70E17B;
$green-cool-30v: #21C834;

// Theme Colors
$theme-color-1: $blue-50;
$theme-color-2: $cyan-50;
$theme-color-3: $blue-warm-70v;
$theme-color-4: $indigo-cool-80v;
$theme-color-5: $blue-warm-5v;
$theme-color-6: $blue-60v;
$theme-color-7: $cyan-10;
$theme-color-accent-1: $mint-40;
$theme-color-accent-2: $cyan-30v;
$theme-color-accent-3: $violet-50v;
$theme-color-accent-4: $orange-warm-40v;
$theme-color-accent-4-light: $orange-warm-10v;
$theme-color-accent-5: $orange-30v;
$theme-color-accent-6: $cyan-40;
$theme-color-accent-7: $blue-vivid-5v;
$theme-color-accent-8: $blue-60v;
$theme-color-accent-9: $mint-5;
$theme-color-accent-10: $cyan-5v;
$theme-color-accent-11: $indigo-5v;
$theme-color-accent-12: $cyan-40v;
$theme-color-accent-13: $violet-60v;
$theme-color-accent-14: $indigo-60v;
$theme-color-accent-15: $blue-warm-60v;
$theme-color-accent-16: $indigo-50v;

$theme-color-headline:


D/lineJoin 2D Canvas lineJoin]属性，
			并且会被[page:WebGLRenderer WebGL]渲染器忽略。

[property:String wireframeLinejoin]

			定义线连接节点的样式。可选值为 'round', 'bevel' 和 'miter'。默认值为 'round'。

			该属性对应[link:https://developer.mozilla.org/en/docs/Web/API/CanvasRenderingContext2D/lineJoin 2D Canvas lineJoin]属性，
			并且会被[page:WebGLRenderer WebGL]渲染器忽略。

[property:Float wireframeLinewidth]

控制线框宽度。默认值为1。

			由于[link:https://www.khronos.org/registry/OpenGL/specs/gl/glspec46.core.pdf OpenGL Core Profile]与大多数平台上[page:WebGLRenderer WebGL]渲染器的限制，无论如何设置该值，线宽始终为1。

方法(Methods)

共有方法请参见其基类[page:Material]。

源码(Source)

			[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]

<!DOCTYPE html>

		<meta charset="utf-8" />
		<base href="../../../" />

		<link type="text/css" rel="stylesheet" href="page.css" />

骨架（[name]）

			使用一个[page:Bone bones]数组来创建一个可以由[page:SkinnedMesh]使用的骨架。

代码示例

		// Create a simple "arm"

		const bones = [];

		const shoulder = new THREE.Bone();
		const elbow = new THREE.Bone();
		const hand = new THREE.Bone();

		shoulder.add( elbow );
		elbow.add( hand );

		bones.push( shoulder );
		bones.push( elbow );
		bones.push( hand );

		shoulder.position.y = -5;
		elbow.position.y = 0;
		hand.position.y = 5;

		const armSkeleton = new THREE.Skeleton( bones );

			请查看[page:SkinnedMesh]页面，来查看其在标准的[page:BufferGeometry]中使用的示例。

构造器

[name]( [param:Array bones], [param:Array boneInverses] )

		[page:Array bones] —— 包含有一组[page:Bone bone]的数组，默认值是一个空数组。

		[page:Array boneInverses] —— （可选） 包含[page:Matrix4 Matrix4]的数组。

		创建一个新的[name].

属性

[property:Array bones]

		包含有一组[pag


 "TWD"  # 預設貨幣

    def test_get_currency_symbol(self):
        """測試獲取貨幣符號"""
        assert self.formatter.get_currency_symbol("USD") == "$"
        assert self.formatter.get_currency_symbol("TWD") == "NT$"
        assert self.formatter.get_currency_symbol("EUR") == "€"
        assert self.formatter.get_currency_symbol("INVALID") == ""

    def test_get_currency_name_chinese(self):
        """測試獲取中文貨幣名稱"""
        self.mock_language_switcher.get_current_language.return_value = "zh_TW"

        assert self.formatter.get_currency_name("USD") == "美元"
        assert self.formatter.get_currency_name("TWD") == "新台幣"
        assert self.formatter.get_currency_name("CNY") == "人民幣"

    def test_get_currency_name_english(self):
        """測試獲取英文貨幣名稱"""
        self.mock_language_switcher.get_current_language.return_value = "en_US"

        assert self.formatter.get_currency_name("USD") == "US Dollar"
        assert self.formatter.get_currency_name("TWD") == "Taiwan Dollar"
        assert self.formatter.get_currency_name("CNY") == "Chinese Yuan"

    def test_get_supported_currencies(self):
        """測試獲取支援的貨幣列表"""
        currencies = self.formatter.get_supported_currencies()

        assert "USD" in currencies
        assert "TWD" in currencies
        assert "EUR" in currencies
        assert "JPY" in currencies
        assert currencies["USD"]["symbol"] == "$"

    def test_format_percentage_basic(self):
        """測試基本百分比格式化"""
        result = self.formatter.format_percentage(0.1234)
        assert result == "12.34%"

    def test_format_percentage_custom_decimals(self):
        """測試自訂小數位數的百分比格式化"""
        result = self.formatter.format_percentage(0.123456, decimal_places=3)
        assert result == "12.346%"

    def test_format_percentage_zero_decimals(self):
        """測試零小數位數的百分比格式化"""
        result = self.formatter.format_percentage(0.1234, decimal_places=0)
        assert result == "12%"

    def test_format_percentage_negative(self):
        """測試負百分比格式化"""
        result = self.formatter.format_percentage(-0.1234)
        assert result == "-12.34%"

class TestCurrencyFormatterEdgeCases:
    """貨幣格式化器邊界情況測試"""

    def setup_method(self):
        """測試前設定"""
        mock_language_switcher = MagicMock()
        mock_language_switcher.get_current_language.return_value = "zh_TW"
        mock_language_switcher.get_number_format.return_value = {
            "decimal_separator": ".",
            "thousand_separator": ","
        }

        with patch('src.ui.localization.currency_formatter.get_language_switcher',
                  return_value=mock_language_switcher):
            self.formatter = CurrencyFormatter()

    def test_format_currency_zero(self):
        """測試零值格式化"""
        result = self.formatter.format_currency(0, "USD")
        assert result == "$0.00"

    def test_format_currency_very_small(self):
        """測試極小值格式化"""
        result = self.formatter.format_currency(0.01, "USD")
        assert result == "$0.01"

    def test_format_currency_very_large(self):
        """測試極大值格式化"""
        result = self.formatter.format_currency(999999999999.99, "USD")
        assert result == "$999,999,999,999.99"

    def test_format_currency_invalid_string(self):
        """測試無效字串輸入"""
        result = self.formatter.format_currency("invalid", "USD")
        assert result == "invalid"  # 應該返回原始輸入

    def test_format_currency_empty_string(self):
        """測試空字串輸入"""
        result = self.formatter.format_currency("", "USD")
        assert result == "$0.00"

    def test_parse_currency_invalid_input(self):
        """測試解析無效輸入"""
        result = self.formatter.parse_currency("invalid input")

        assert result["amount"] == 0.0
        assert result["currency_code"] == "TWD"
        assert "error" in result

    def test_format_currency_unknown_currency(self):
        """測試未知貨幣代碼"""
        result = self.formatter.format_currency(1234.56, "UNKNOWN")
        # 應該回退到預設貨幣
        assert result == "NT$1,234.56"

class TestGlobalFunctions:
    """全域函數測試類"""

    @patch('src.ui.localization.currency_formatter.get_currency_formatter')
    def test_format_currency_function(self, mock_get_formatter):
        """測試全域 format_currency 函數"""
        mock_formatter = MagicMock()
        mock_formatter.format_currency.return_value = "$1,234.56"
        mock_get_formatter.return_value = mock_formatter


ics.LEFT;
		// 			}
		//
		// 		} else {
		//
		// 			overlap = box1.x - box2.width - box2.x;
		// 			if ((-overlap > maxOverlap) || !(phys1.allowCollisions & ArcadePhysics.LEFT) || !(phys2.allowCollisions & ArcadePhysics.RIGHT)) {
		// 				overlap = 0;
		// 			} else {
		// 				phys1.touching |= ArcadePhysics.LEFT;
		// 				phys2.touching |= ArcadePhysics.RIGHT;
		// 			}
		//
		// 		}
		//
		//
		// 	}
		//
		//
		// 	if (overlap != 0) {
		//
		//
		// 		//Get the average velocity
		// 		var obj1v: number = phys1.velocity.x;
		// 		var obj2v: number = phys2.velocity.x;
		//
		//
		// 		if (!phys1.immovable && !phys2.immovable) {
		// 			overlap *= 0.5;
		// 			phys1.transform.x = phys1.transform.x - overlap;
		// 			phys2.transform.x = phys2.transform.x + overlap;
		//
		// 			var obj1velocity: number = Math.sqrt((obj2v * obj2v * phys2.mass) / phys1.mass) * ((obj2v > 0) ? 1 : -1);
		// 			var obj2velocity: number = Math.sqrt((obj1v * obj1v * phys1.mass) / phys2.mass) * ((obj1v > 0) ? 1 : -1);
		// 			var average: number = (obj1velocity + obj2velocity) * 0.5;
		// 			obj1velocity -= average;
		// 			obj2velocity -= average;
		// 			phys1.velocity.x = average + obj1velocity * phys1.elasticity;
		// 			phys2.velocity.x = average + obj2velocity * phys2.elasticity;
		//
		//
		// 		} else if (!phys1.immovable) {
		// 			phys1.transform.x = phys1.transform.x - overlap;
		// 			phys1.velocity.x = obj2v - obj1v * phys1.elasticity;
		//
		//
		// 		} else if (!phys2.immovable) {
		// 			phys2.transform.x = phys2.transform.x + overlap;
		// 			phys2.velocity.x = obj1v - obj2v * phys2.elasticity;
		//
		// 		}
		// 		return true;
		//
		// 	}
		//
		// 	return false;
		// }
		//
		//
		// /**
		// * Separates two GameObject on the y-axis. This method is executed from the 'separate' method.
		// * Both objects need to have both an ArcadePhysics Component and a Box component in order for the separate process to succeed.
		// * This method is not recommended to be directly used but instead use a 'collide/overlaps' method instead.
		// *
		// * @method seperateY
		// * @param object1 {Kiwi.Entity} The first GameObject.
		// * @param object2 {Kiwi.Entity} The second GameObject.
		// * @return {boolean} Whether the objects in fact touched and were separated along the Y axis.
		// * @static
		// * @public
		// */
		// public static separateY(object1: Kiwi.Entity, object2: Kiwi.Entity): boolean {
		//
		//
		// 	//Get the Arcade Physics Components
		// 	v


noscript>

<!doctype html>

	<meta charset='utf-8'>
	<title>Ractive.js load plugin</title>

	<link href='http://fonts.googleapis.com/css?family=Voltaire' rel='stylesheet' type='text/css'>
	<link rel='stylesheet' href='main.css'>

	Fork me on GitHub

Ractive.js load plugin

			download: ractive-load.js
			more plugins at ractivejs.org/plugins

The ractive-load plugin allows you to load component files, which are a way of encapsulating markup, styles, behaviours and default data into a single file. It's ideal for quick prototypes and smaller apps - if you need something more production-grade that integrates into your build process, try one of the alternative component loaders.

Copyright © 2014 Rich Harris. Licensed MIT


			name: "72h in renew range",
			// This time should be inside the renewal range.
			now:      "2018-01-02 20:00:20",
			issued:   "2018-01-01 00:00:00",
			lifetime: 72 * time.Hour,
			// Min should be the "now" time
			wantMin: "2018-01-02 20:00:20",
			wantMax: "2018-01-03 16:48:00",
		},
		{
			name: "72h in hard renew",
			// This time should be inside the renewal range.
			now:      "2018-01-03 18:00:00",
			issued:   "2018-01-01 00:00:00",
			lifetime: 72 * time.Hour,
			// Min and max should both be the "now" time
			wantMin: "2018-01-03 18:00:00",
			wantMax: "2018-01-03 18:00:00",
		},
		{
			name: "72h expired",
			// This time is after expiry
			now:      "2018-01-05 00:00:00",
			issued:   "2018-01-01 00:00:00",
			lifetime: 72 * time.Hour,
			// Min and max should both be the "now" time
			wantMin: "2018-01-05 00:00:00",
			wantMax: "2018-01-05 00:00:00",
		},
		{
			name:     "1h just issued",
			now:      "2018-01-01 00:00:01",
			issued:   "2018-01-01 00:00:00",
			lifetime: 1 * time.Hour,
			// Should jitter between 60% and 90% of the lifetime which is 36/54 mins
			// hours after issued
			wantMin: "2018-01-01 00:36:00",
			wantMax: "2018-01-01 00:54:00",
		},
		{
			name: "1h in renew range",
			// This time should be inside the renewal range.
			now:      "2018-01-01 00:40:00",
			issued:   "2018-01-01 00:00:00",
			lifetime: 1 * time.Hour,
			// Min should be the "now" time
			wantMin: "2018-01-01 00:40:00",
			wantMax: "2018-01-01 00:54:00",
		},
		{
			name: "1h in hard renew",
			// This time should be inside the renewal range.
			now:      "2018-01-01 00:55:00",
			issued:   "2018-01-01 00:00:00",
			lifetime: 1 * time.Hour,
			// Min and max should both be the "now" time
			wantMin: "2018-01-01 00:55:00",
			wantMax: "2018-01-01 00:55:00",
		},
		{
			name: "1h expired",
			// This time is after expiry
			now:      "2018-01-01 01:01:01",
			issued:   "2018-01-01 00:00:00",
			lifetime: 1 * time.Hour,
			// Min and max should both be the "now" time
			wantMin: "2018-01-01 01:01:01",
			wantMax: "2018-01-01 01:01:01",
		},
		{
			name: "too short lifetime",
			// This time is after expiry
			now:      "2018-01-01 01:01:01",
			issued:   "2018-01-01 00:00:00",
			lifetime: 1 * time.Minute,
			// Min and max should both be the "now" time
			wantMin: "2018-01-01 01:01:01",
			wantMax: "2018-01-01 01:01:01",
		},
	}

	for _, tc := range tests {
		t.Run(tc.name, func(t *testing.T) {
			now, err := time.Parse("2006-01-02 15:04:05", tc.now)
			require.NoError(t, err)
			issued, err := time.Parse("2006-01-02 15:04:05", tc.issued)
			require.NoError(t, err)
			wantMin, err := time.Parse("2006-01-02 15:04:05", tc.wantMin)
			require.NoError(t, err)
			want


tionalConstraints,
            )

            // Then the composite constraint should match the time.
            expect(composite.isBusinessTime(time.getMoment())).toBeTruthy()
        },
    )

    test.each(someMatchingWednesdayOnePm())(
        "orAlternatively some match",
        (additionalConstraints: IBusinessTimeConstraint[]) => {
            // Given we have a constraint which matches a business time;
            const time = wednesdayOnePm()
            const constraint = new AnyTime()
            expect(constraint.isBusinessTime(time.getMoment())).toBeTruthy()

            // When we use orAlternatively() to combine it with other
            // constraints only some of which match.
            const composite = constraint.orAlternatively(
                ...additionalConstraints,
            )

            // Then the composite constraint should match the time.
            expect(composite.isBusinessTime(time.getMoment())).toBeTruthy()
        },
    )
})
/**
 * Error definitions for the application
 */
import { HttpException, HttpStatus } from '@nestjs/common';

export const userNotFound = (userId: string) => {
  throw new HttpException(
    `user with ${userId} is not found.`,
    HttpStatus.NOT_FOUND,
  );
};

export const invalidDisplayName = (name: string) => {
  throw new HttpException(
    `${name} display name is invalid.`,
    HttpStatus.BAD_REQUEST,
  );
};

export const invalidCountryCode = (code: string) => {
  throw new HttpException(
    `${name} code is not a invalid country code.`,
    HttpStatus.BAD_REQUEST,
  );
};

export const invalidObjectId = () => {
  throw new HttpException('invalid object id.', HttpStatus.BAD_REQUEST);
};

export const invalidScore = () => {
  throw new HttpException(
    'Invalid score it must be higher than 0',
    HttpStatus.BAD_REQUEST,
  );
};
// /**
//  * 硬盘 {多个盘片={独立磁头(所有记录面上的相同序号的磁道构成一个圆柱面，其编号与与磁道编号相同
//  *      将文件存储在在硬盘上时尽量放在同一个柱面或相邻柱面上 这样可以缩短寻道时间)，
//  *      } => 盘片组}
//  * 将盘片划分为许多同心圆，称为磁道，从外住里编 最外面是0
//  * 沿径向的单位距离称为密度单位tpi(每英寸磁道数)
//  * 将磁道沿首圆周等分为若干段，第段称为一个扇区或扇段，每个扇区内可存放固定长度的数据块，如512b
//  * 磁道上单位距离可以记录的位数称为位密度，单位bpi(每英寸位数)
//  * 每条磁道扇区数相同 扇区大小又不一样 每条磁道记录同样多的信息
//  * 里圈磁道圆周比外圈磁道圆周小 所以里圈磁道的位密码比外圈磁道高 最内圈的位密度称为最大位密度
//  *
//  * 硬盘的寻信息同硬盘的驱动号、圆柱面号、磁头号（记录面号）、数据块号(或扇区号) 以及交换量组成
//  * 磁盘容量分两种：1 非格式化容量 它指一个磁盘所能存储的总位数
//  * 非 = 面数 * (磁道数/面) * 内周长 * 最大位密度
//  * 2格式化容量 它指各个扇区中数据区容量的总和
//  * 格 = 面数 * (磁道数/面) * (扇区数/道) * (字节数/扇区)
//  *
//  * 多中断信号线法 每一个中断源都有属于自已的一根中断请求信号线向cpu提出中断请求
//  * 中断软件查询法 当CPU检测到一个请法求信号以后，即转入到中断服务程序去轮询每个中断源以确定是是谁发出了中断请求信号 对各个设
//  * 备的响应优先级由软件设定
//  * 菊花链法 软件查�


0xffff;
            R0 = (R0 - expandedKey[i - 4] - (R3 & R2) - (~R3 & R1)) & 0xffff;
        }

        out[outOfs    ] = (byte)R0;
        out[outOfs + 1] = (byte)(R0 >> 8);
        out[outOfs + 2] = (byte)R1;
        out[outOfs + 3] = (byte)(R1 >> 8);
        out[outOfs + 4] = (byte)R2;
        out[outOfs + 5] = (byte)(R2 >> 8);
        out[outOfs + 6] = (byte)R3;
        out[outOfs + 7] = (byte)(R3 >> 8);
    }

}
/*
 * Copyright (c) 2001, 2025, Oracle and/or its affiliates. All rights reserved.
 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
 *
 * This code is free software; you can redistribute it and/or modify it
 * under the terms of the GNU General Public License version 2 only, as
 * published by the Free Software Foundation.
 *
 * This code is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
 * version 2 for more details (a copy is included in the LICENSE file that
 * accompanied this code).
 *
 * You should have received a copy of the GNU General Public License version
 * 2 along with this work; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 *
 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
 * or visit www.oracle.com if you need additional information or have any
 * questions.
 */

package nsk.jdi.Value._itself_;

import nsk.share.*;
import nsk.share.jpda.*;
import nsk.share.jdi.*;

import com.sun.jdi.*;
import java.util.*;
import java.io.*;

import com.sun.jdi.event.*;
import com.sun.jdi.request.*;

/**
 * The test for the implementation of an object of the type

 * Value.

 *

 * The test checks up that a Value object, mirroring neither

 * a primitive type value nor a void, is casted to both

 * ObjectReference and a corresponding object reference;

 * the tested are ArrayReference, ClassObjectReference,

 * StringReference, ThreadReference, and ThreadGroupReference.

 *

 * The test contains two test cases with different ways to get

 * a tested Value object:

 *   Value = ReferenceType.getValue(Field);

 *     tested types are all of five mentioned above

 *   Value = StackFrame.getValue(LocalVariable);

 *     tested types are String, Array, and ClassObject only

 */

public class value001 {

    //----------------------------------------------------- templete section
    static final


        --vtcolor1:  #ebb1c2;
        --vtcolor2: #804309;

        /* ! Header Image*/
        --dhead-img: url("https://github.com/Emrie-Candera/Bubble-Space-Theme/blob/main/theme%20image/Red%20Moon.png?raw=true");
        --dhi-h: 80px;
        --dhi-w: 230px;
        --dhi-mt: -8px;
        --dhi-mb: -10px;
        --dhi-ml: 3%;

         /* ! Header Icon */
         --hic-ico: var(--lhic-ico);
         --lhic-ico: var(--svg-vault);
         --hic-fsize: 5px;

         /* ! Header Text */
         --lht-text: 👋 I hope you have a great day!;
         --lht-fsize: 20px;
         --ht-fcol: rgb(90, 171, 236);

        /* ! Folder Container*/
        --fx-folcol: rgb(231, 164, 40);
        --fx-tfolcol: rgb(231, 238, 245);
        --fx-ficol: var(--text-normal);
        --fi-act: rgb(235, 91, 91);
        --fcol-in: var(--pink3);

        /* ! Iterative Folder Colors*/
        --fgrad1: rgb(128, 27, 27);
        --fgrad2: rgb(136, 9, 9);
        --fgrad3: rgba(255, 0, 0, 0.568);
        --fgrad4: rgb(114, 17, 17);
        --fgrad5: rgba(126, 11, 11, 0.836);
        --fgrad6: rgba(92, 16, 16, 0.849);
        --fgrad7: rgb(65, 7, 7);
        --fgrad8: rgba(255, 2, 2, 0.685);

        /* ! Active Note Title Bar*/
        --m-vhead: rgba(66, 6, 6, 0.824);

        --ant-col1: rgba(139, 69, 12, 0.63);
        --ant-col2: rgba(179, 61, 52, 0.71);
        --ant-col3: rgba(237, 85, 85, 0.24) ;

        --act-svg: rgb(179, 169, 139);

        /* ! Metadata Codeblock*/
        --trule: rgb(235, 95, 95);
        --tstring: rgb(241, 240, 235);

        /* ! Document Search */
        --ds-bg: rgb(48, 5, 5);
        --ds-err: rgba(104, 88, 53, 0.664);

        /* ! Empty Note*/
        --es-con: "(◕‸◕ )";
        --es-col: rgb(139, 35, 35);
        --es-dfsize: 1.5em;
        --es-dtfize: 1.5em;

        /* ! Workspace Tab Header*/
        --wth-hov: rgb(230, 103, 103);
        --col-tbar: rgb(247, 121, 90);

        /* ! Tag Pane Flair*/
        --dfborder: 3px;
        --dtree-b4: "★";
        --dfl-fil: rgb(151, 39, 39) 0px 0px 5px, rgb(184, 71, 71) 0px 0px 10px, rgb(216, 137, 137) 0px 0px 15px, #ff2d2d 0px 0px 20px, #ff2d2db6 0px 0px 30px, 2px 2px 2px rgba(206, 55, 55, 0);
        --dhov-sh: 10px 10px 4px rgb(194, 60, 60);

        --flair1: rgb(216, 161, 60);
        --flair2: rgb(255, 192, 192);
        --flair3: rgb(214, 209, 218);
        --flair4: rgb(243, 218, 186);
        --flair5: rgb(186, 240, 17


assertEquals(Int.SIZE_BYTES, intBytes.size)
		assertEquals(0x12.toByte(), intBytes[0])
		assertEquals(0x34.toByte(), intBytes[1])
		assertEquals(0x56.toByte(), intBytes[2])
		assertEquals(0x78.toByte(), intBytes[3])

		val longBytes = 0x123456789abcdef0.toByteArray()
		assertEquals(Long.SIZE_BYTES, longBytes.size)
		assertEquals(0x12.toByte(), longBytes[0])
		assertEquals(0x34.toByte(), longBytes[1])
		assertEquals(0x56.toByte(), longBytes[2])
		assertEquals(0x78.toByte(), longBytes[3])
		assertEquals(0x9a.toByte(), longBytes[4])
		assertEquals(0xbc.toByte(), longBytes[5])
		assertEquals(0xde.toByte(), longBytes[6])
		assertEquals(0xf0.toByte(), longBytes[7])

		val floatBytes = 1234.5677f.toByteArray()
		assertEquals(Float.SIZE_BYTES, floatBytes.size)
		assertEquals(0x44.toByte(), floatBytes[0])
		assertEquals(0x9a.toByte(), floatBytes[1])
		assertEquals(0x52.toByte(), floatBytes[2])
		assertEquals(0x2b.toByte(), floatBytes[3])

		val doubleBytes = 1234.56789.toByteArray()
		assertEquals(Double.SIZE_BYTES, doubleBytes.size)
		assertEquals(0x40.toByte(), doubleBytes[0])
		assertEquals(0x93.toByte(), doubleBytes[1])
		assertEquals(0x4a.toByte(), doubleBytes[2])
		assertEquals(0x45.toByte(), doubleBytes[3])
		assertEquals(0x84.toByte(), doubleBytes[4])
		assertEquals(0xf4.toByte(), doubleBytes[5])
		assertEquals(0xc6.toByte(), doubleBytes[6])
		assertEquals(0xe7.toByte(), doubleBytes[7])
	}

	@Test
	fun primitiveToByteArrayLittleEndian() {
		val shortBytes = 0x1234.toShort().toByteArray(ByteOrder.LITTLE_ENDIAN)
		assertEquals(Short.SIZE_BYTES, shortBytes.size)
		assertEquals(0x12.toByte(), shortBytes[1])
		assertEquals(0x34.toByte(), shortBytes[0])

		val intBytes = 0x12345678.toByteArray(ByteOrder.LITTLE_ENDIAN)
		assertEquals(Int.SIZE_BYTES, intBytes.size)
		assertEquals(0x12.toByte(), intBytes[3])
		assertEquals(0x34.toByte(), intBytes[2])
		assertEquals(0x56.toByte(), intBytes[1])
		assertEquals(0x78.toByte(), intBytes[0])

		val longBytes = 0x123456789abcdef0.toByteArray(ByteOrder.LITTLE_ENDIAN)
		assertEquals(Long.SIZE_BYTES, longBytes.size)
		assertEquals(0x12.toByte(), longBytes[7])
		assertEquals(0x34.toByte(), longBytes[6])
		assertEquals(0x56.toByte(), longBytes[5])
		assertEquals(0x78.toByte(), longBytes[4])
		assertEquals(0x9a.toByte(), longBytes[3])
		assertEquals(0xbc.toByte(), longBytes[2])
		assertEquals(0xde.toByte(), longBytes[1])
		assertEquals(0xf0.toByte(), longBytes[0])

		val floatBytes = 1234.5677f.toByteArray(ByteOrder.LITTLE_ENDIAN)
		assertEquals(Float.SIZE_BYTES, floatBytes.size)
		assertEquals(0x44.toByte(), floatBytes[3])
		assertEquals(0x9a.toByte(), floatBytes[2])
		assertEquals(0x52.toByte(), floatBytes[1])
		assertEquals(0x2b.toByte(), floatBytes[0])

		val doubleBytes = 123


因是什么，有哪些关键因素？ |
| 客户画像                                        | 分析一下我们公司主要客户的特征，例如性别、年龄、职业等方面的数据分布情况。 |
| 文本分类                                        | 给你这段文本，可以帮我判断一下它属于哪个类别：政治、经济、文化、娱乐、体育？ |
| 计算机编程                                    | 给我讲一下Java语言中的多线程编程，包括如何创建线程、同步、互斥等方面的知识点。 |
| 烹饪食谱                                | 如何制作美味的奶油意大利面？                                                                                |
| 艺术史                                  | 您能列出文艺复兴时期最著名的三位画家及其代表作品是什么吗？                                                                           |
| 医学知识                                | 心脏病的早期症状有哪些，如何预防心脏病？                                                                                |
| 环保科技                                | 请介绍一种可持续发展的新型能源，以及它与传统能源相比的优势和不足。                                                                     |
| 品牌营销                                | 如果您是某个新兴品牌的市场营销经理，请提出一份高效的广告策略，以吸引更多目标客户的关注。                                           |
| 社交礼仪                                | 在约会时，如何让对方感到舒适自在，建立良好的社交关系？                                                                              |
| 人工智能                                | 利用神经网络算法构建一款新型的人脸识别系统，并设计一个评估指标来衡量该算法的准确性和可靠性。                                          |
| 电影评论                                | 您认为《泰坦尼克号》这部电影中最具有感染力的情节是什么，为什么？                                                                       |
| 金


 .nav-collapse .dropdown-menu a:focus{background-color:#111}.nav-collapse.in .btn-group{padding:0;margin-top:5px}.nav-collapse .dropdown-menu{position:static;top:auto;left:auto;display:none;float:none;max-width:none;padding:0;margin:0 15px;background-color:transparent;border:0;-webkit-border-radius:0;-moz-border-radius:0;border-radius:0;-webkit-box-shadow:none;-moz-box-shadow:none;box-shadow:none}.nav-collapse .open>.dropdown-menu{display:block}.nav-collapse .dropdown-menu:before,.nav-collapse .dropdown-menu:after{display:none}.nav-collapse .dropdown-menu .divider{display:none}.nav-collapse .nav>li>.dropdown-menu:before,.nav-collapse .nav>li>.dropdown-menu:after{display:none}.nav-collapse .navbar-form,.nav-collapse .navbar-search{float:none;padding:10px 15px;margin:10px 0;border-top:1px solid #f2f2f2;border-bottom:1px solid #f2f2f2;-webkit-box-shadow:inset 0 1px 0 rgba(255,255,255,0.1),0 1px 0 rgba(255,255,255,0.1);-moz-box-shadow:inset 0 1px 0 rgba(255,255,255,0.1),0 1px 0 rgba(255,255,255,0.1);box-shadow:inset 0 1px 0 rgba(255,255,255,0.1),0 1px 0 rgba(255,255,255,0.1)}.navbar-inverse .nav-collapse .navbar-form,.navbar-inverse .nav-collapse .navbar-search{border-top-color:#111;border-bottom-color:#111}.navbar .nav-collapse .nav.pull-right{float:none;margin-left:0}.nav-collapse,.nav-collapse.collapse{height:0;overflow:hidden}.navbar .btn-navbar{display:block}.navbar-static .navbar-inner{padding-right:10px;padding-left:10px}}@media(min-width:980px){.nav-collapse.collapse{height:auto!important;overflow:visible!important}}
/*
 * Copyright (C) 2009-2025 by the geOrchestra PSC
 *
 * This file is part of geOrchestra.
 *
 * geOrchestra is free software: you can redistribute it and/or modify it under
 * the terms of the GNU General Public License as published by the Free
 * Software Foundation, either version 3 of the License, or (at your option)
 * any later version.
 *
 * geOrchestra is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
 * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
 * more details.
 *
 * You should have received a copy of the GNU General Public License along with
 * geOrchestra.  If not, see <http://www.gnu.org/licenses/>.
 */

@lightblue: #009FE3;
svg {
  background: white;
}

.chartist {
  height: 25em;
}
.ct-label {
  font-size: 1rem;
}
.ct-barlabel {
  font-size: 1rem;
  fill: white;
}
.ct-series-a
.ct-bar,
.ct-series-a
.ct-line,
.ct-series-a
.ct-point,
.ct-series-a
.ct-slice-donut
{
  stroke: @lightblue;
}

text {
  font-size   : 11px;
  font-family : Arial;
  fill        : #AAA;
}
.btn-default,.btn-primary,.btn-success,.btn-info,.btn-warning,.btn-danger{text-shadow:0 -1px 0 rgba(0,0,0,0.2);-webkit-box-shadow:inset 0 1px 0 rgba(255,255,


pBound opInfo = new OpRelOpBound("P", RelOp.GEQ, 0.0);
		opsAndBounds.add(opInfo, Operator.P_GE, 0.0, -1, -1);
	}

	//Prints info about the product model in multi-objective
	protected void outputProductMulti(NondetModel modelProduct) throws PrismException
	{
		// Print product info
		mainLog.println();
		modelProduct.printTransInfo(mainLog, prism.getExtraDDInfo());

		// Output product, if required
		if (prism.getExportProductTrans()) {
			try {
				ModelExportOptions exportOptions = new ModelExportOptions();
				exportOptions.setModelPrecision(getSettings().getInteger(PrismSettings.PRISM_EXPORT_MODEL_PRECISION));
				mainLog.println("\nExporting product transition matrix to file \"" + prism.getExportProductTransFilename() + "\"...");
				modelProduct.exportToFile(new File(prism.getExportProductTransFilename()), exportOptions);
			} catch (FileNotFoundException e) {
				mainLog.printWarning("Could not export product transition matrix to file \"" + prism.getExportProductTransFilename() + "\"");
			}
		}
		if (prism.getExportProductStates()) {
			mainLog.println("\nExporting product state space to file \"" + prism.getExportProductStatesFilename() + "\"...");
			PrismFileLog out = new PrismFileLog(prism.getExportProductStatesFilename());
			modelProduct.exportStates(Prism.EXPORT_PLAIN, out);
			out.close();
		}
	}

	// Model checking functions

	/**
	 * Compute probabilities for the contents of a P operator.
	 * The result will have valid results at least for the states of interest (use model.getReach().copy() for all reachable states)
	 *
[ REFS: result, DEREFS: statesOfInterest ]
	 */
	protected StateValues checkProbPathFormula(Expression expr, boolean qual, boolean min, JDDNode statesOfInterest) throws PrismException
	{
		// Test whether this is a simple path formula (i.e. PCTL)
		// and whether we want to use the corresponding algorithms
		boolean useSimplePathAlgo = expr.isSimplePathFormula();

		if (useSimplePathAlgo &&
		    prism.getSettings().getBoolean(PrismSettings.PRISM_PATH_VIA_AUTOMATA) &&
		    LTLModelChecker.isSupportedLTLFormula(model.getModelType(), expr)) {
			// If PRISM_PATH_VIA_AUTOMATA is true, we want to use the LTL engine
			// whenever possible
			useSimplePathAlgo = false;
		}

		if (useSimplePathAlgo) {
			return checkProbPathFormulaSimple(expr, qual, min, statesOfInterest);
		} else {
			return checkProbPathFormulaLTL(expr, qual, min, statesOfInterest);
		}
	}

	/**
	 * Compute probabilities for a simple, non-LTL path operator.
	 * The result will have valid results at least for the states of interest (use model.getReach().copy() for all reachable states)
	 *
[ REFS: result, DEREFS: statesOfInterest ]
	 */
	protected StateValues checkProbPathFormulaSimple(Expression expr, boolean qual, boolean min, JDDNode statesOfInterest) throws PrismException
	{
		boolean negated = false;
		StateValues probs = null;

		expr = Expression.convertSimplePathFormulaToCanonicalForm(expr);

		// Negation
		if (expr instanceof ExpressionUnaryOp &&
		    ((ExpressionUnaryOp)expr).getOperator() == ExpressionUnaryOp.NOT) {
			// mark as negated, switch from min to max and vice versa
			negated = true;
			min = !min;
			expr = ((ExpressionUnaryOp)expr).getOperand();
		}

		if (expr


                self.to_glib_none().0,
                v2.to_glib_none().0,
                epsilon,
            ))
        }
    }

    pub fn negate(&self) -> Vec4 {
        unsafe {
            let mut res = Vec4::uninitialized();
            ffi::graphene_vec4_negate(self.to_glib_none().0, res.to_glib_none_mut().0);
            res
        }
    }

    pub fn normalize(&self) -> Vec4 {
        unsafe {
            let mut res = Vec4::uninitialized();
            ffi::graphene_vec4_normalize(self.to_glib_none().0, res.to_glib_none_mut().0);
            res
        }
    }

    pub fn scale(&self, factor: f32) -> Vec4 {
        unsafe {
            let mut res = Vec4::uninitialized();
            ffi::graphene_vec4_scale(self.to_glib_none().0, factor, res.to_glib_none_mut().0);
            res
        }
    }

    pub fn subtract(&self, b: &Vec4) -> Vec4 {
        unsafe {
            let mut res = Vec4::uninitialized();
            ffi::graphene_vec4_subtract(
                self.to_glib_none().0,
                b.to_glib_none().0,
                res.to_glib_none_mut().0,
            );
            res
        }
    }

    //pub fn to_float(&self, dest: /*Unimplemented*/FixedArray TypeId { ns_id: 0, id: 20 }; 4) {
    //    unsafe { TODO: call ffi:graphene_vec4_to_float() }
    //}

    pub fn one() -> Vec4 {
        assert_initialized_main_thread!();
        unsafe { from_glib_none(ffi::graphene_vec4_one()) }
    }

    pub fn w_axis() -> Vec4 {
        assert_initialized_main_thread!();
        unsafe { from_glib_none(ffi::graphene_vec4_w_axis()) }
    }

    pub fn x_axis() -> Vec4 {
        assert_initialized_main_thread!();
        unsafe { from_glib_none(ffi::graphene_vec4_x_axis()) }
    }

    pub fn y_axis() -> Vec4 {
        assert_initialized_main_thread!();
        unsafe { from_glib_none(ffi::graphene_vec4_y_axis()) }
    }

    pub fn z_axis() -> Vec4 {
        assert_initialized_main_thread!();
        unsafe { from_glib_none(ffi::graphene_vec4_z_axis()) }
    }

    pub fn zero() -> Vec4 {
        assert_initialized_main_thread!();
        unsafe { from_glib_none(ffi::graphene_vec4_zero()) }
    }
}

impl PartialEq for Vec4 {
    #[inline]
    fn eq(&self, other: &Self) -> bool {
        self.equal(other)
    }
}

impl Eq for Vec4 {}
#![feature(proc_macro_hygiene, decl_macro)]

#[macro_use] extern crate rocket;
extern crate rusqlite;

#[cfg(test)] mod tests;

use std::sync::Mutex;
use rocket::{Rocket, State};
use rusqlite::{Connection, Error};

type DbConn = Mutex<Connection>;

fn init_database(conn: &Connection) {
    conn.execute("CREATE TABLE entries (
                  id              INTEGER PRIMARY KEY,
                  name            TEXT NOT NULL
                  )", &[])
        .expect("create entries table");

    conn.execute("INSERT INTO entries (id, name) VALUES ($1, $2)",
            &[&0, &"Rocketeer"])
        .expect("insert single entry into entries table");
}

#[get("/")]
fn hello(db_conn: State<DbConn>) -> Result<String, Error>  {
    db_conn.lock()
        .expect("db connection lock")


,
    "path_attributes":
        "fill=\"#FFBD39\"|fill=\"#FFD644\"|fill=\"#FFD644\"|fill=\"#FF5F82\";opacity=\".6\"|fill=\"#872A2A\"|fill=\"#541300\"|fill=\"#541300\"|fill=\"#541300\""
  },
  {
    "id": 37132961,
    "name": "飞吻",
    "project_id": 4228868,
    "projectId": 4228868,
    "show_svg":
        "<svg class=\"icon\" style=\"width: 1em;height: 1em;vertical-align: middle;fill: currentColor;overflow: hidden;\" viewBox=\"0 0 1024 1024\" version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M450.4 883.2C654.9664 883.2 820.8 717.3664 820.8 512.8S654.9664 142.4 450.4 142.4 80 308.2336 80 512.8 245.8336 883.2 450.4 883.2z\" fill=\"#FFBD39\" /><path d=\"M449.6576 865.6c194.8464 0 352.8-157.9536 352.8-352.8S644.504 160 449.6576 160c-194.8448 0-352.8 157.9536-352.8 352.8S254.8128 865.6 449.6576 865.6z\" fill=\"#FFD644\" /><path d=\"M449.6576 865.6c194.8464 0 352.8-157.9536 352.8-352.8S644.504 160 449.6576 160c-194.8448 0-352.8 157.9536-352.8 352.8S254.8128 865.6 449.6576 865.6z\" fill=\"#FFD644\" /><path d=\"M326.9088 566.5232c0 27.3392-23.9776 49.4848-53.6064 49.4848-29.6288 0-53.608-22.1456-53.608-49.4848 0-27.3376 23.9792-49.4832 53.608-49.4832 29.6288 0.152 53.6064 22.2976 53.6064 49.4832zM682.1536 566.5232c0 27.3392-23.9792 49.4848-53.608 49.4848s-53.6064-22.1456-53.6064-49.4848c0-27.3376 23.9776-49.4832 53.6064-49.4832 29.4768 0.152 53.608 22.2976 53.608 49.4832z\" fill=\"#FF5F82\" opacity=\".6\" /><path d=\"M546.9888 478.248c-14.5088-12.2192 7.0256-49.0256 64.7568-49.0256s78.1968 35.8912 66.1312 49.0256c-10.3856 11.3008-23.0624-17.2592-64.7568-17.2592-41.6944 0.1536-53.912 27.6448-66.1312 17.2592zM300.7936 385.3888c-77.128 4.888-56.2048 118.3648 5.8032 116.2256 61.8544-2.1376 71.1712-121.2656-5.8032-116.2256z\" fill=\"#541300\" /><path d=\"M434.888 519.7888c4.4288-12.6768 93.7744 6.72 90.72 30.6992-3.0544 23.9776-38.7936 26.4208-37.1136 35.8896 1.528 9.3168 38.64 9.4688 37.1136 33.448-1.3744 23.0608-82.9312 43.832-87.5136 35.1264-6.4144-11.76 47.9568-20.


otNull
    assertThat(node.isForceViewWrapping).isFalse
  }

  @Test
  fun testPaddingFromDrawable() {
    val c = lithoTestRule.context
    val component =
        Column.create(c)
            .child(Text.create(c).text("Hello World").backgroundRes(background_with_padding))
            .build()
    val testLithoView = lithoTestRule.render { component }
    val result = testLithoView.currentRootNode!!.getChildAt(0)
    assertThat(result.paddingLeft).isEqualTo(48)
    assertThat(result.paddingTop).isEqualTo(0)
    assertThat(result.paddingRight).isEqualTo(0)
    assertThat(result.paddingBottom).isEqualTo(0)
  }

  @Test
  fun testPaddingFromDrawableIsOverwritten() {
    val c = lithoTestRule.context
    val component =
        Column.create(c)
            .child(
                Text.create(c)
                    .text("Hello World")
                    .backgroundRes(background_with_padding)
                    .paddingPx(YogaEdge.LEFT, 8)
                    .paddingPx(YogaEdge.RIGHT, 8)
                    .paddingPx(YogaEdge.TOP, 8)
                    .paddingPx(YogaEdge.BOTTOM, 8))
            .build()
    val testLithoView = lithoTestRule.render { component }
    val result = testLithoView.currentRootNode!!.getChildAt(0)
    assertThat(result.paddingLeft).isEqualTo(8)
    assertThat(result.paddingTop).isEqualTo(8)
    assertThat(result.paddingRight).isEqualTo(8)
    assertThat(result.paddingBottom).isEqualTo(8)
  }

  @Test
  fun testSameObjectEquivalentTo() {
    assertThat(commonProps.isEquivalentTo(commonProps)).isEqualTo(true)
  }

  @Test
  fun testNullObjectEquivalentTo() {
    assertThat(commonProps.isEquivalentTo(null)).isEqualTo(false)
  }

  @Test
  fun testDifferentObjectWithSameContentEquivalentTo() {
    commonProps = CommonProps()
    setCommonProps(commonProps)
    val commonProps2 = CommonProps()
    setCommonProps(commonProps2)
    assertThat(commonProps.isEquivalentTo(commonProps2)).isEqualTo(true)
  }

  @Test
  fun testDifferentObjectWithDifferentContentEquivalentTo() {
    commonProps = CommonProps()
    setCommonProps(commonProps)
    commonProps.duplicateParentState(false)
    val commonProps2 = CommonProps()
    setCommonProps(commonProps2)
    commonProps2.duplicateParentState(true)
    assertThat(commonProps.isEquivalentTo(commonProps2)).isEqualTo(false)
  }

  private fun setCommonProps(commonProps: CommonProps) {
    commonProps.layoutDirection(YogaDirection.INHERIT.toLayoutDirection())
    commonProps.alignSelf(YogaAlign.AUTO)
    commonProps.positionType(YogaPositionType.ABSOLUTE)
    commonProps.flex(2f)
    commonProps.flexGrow(3f)
    commonProps.flexShrink(4f)
    commonProps.flexBasisPx(5)
    commonProps.flexBasisPercent(6f)
    commonProps.importantForAccessibility(IMPORTANT_FOR_ACCESSIBILITY_AUTO)
    commonProps.duplicateParentState(false)
    commonProps.marginPx(YogaEdge.ALL, 5)
    commonProps.marginPx(YogaEdge.RIGHT, 6)
    commonProps.marginPx(YogaEdge.LEFT, 4)
    commonProps.marginPercent(YogaEdge.ALL, 10f)
    commonProps.marginPercent(YogaEdge.VERTICAL, 12f)
    commonProps.marginPercent(YogaEdge.RIGHT, 5f)


 name: 'explo_2', url: 'img/explosion 2.png', x: 8, y: 8 },
      { name: 'explo_3', url: 'img/explosion 3.png', x: 8, y: 8 },
      // { name: 'explo_4', url: 'img/explosion 4.png', x: 8, y: 8 },

      // { name: 'smoke_1', url: 'img/smoke_11x1.png', x: 11, y: 1 },

      { name: 'level_up', url: 'img/level_up_8x1.png', x: 8, y: 1 },
      { name: 'rank_up', url: 'img/prom_8x1.png', x: 8, y: 1 },

      // { name: 'magic_1', url: 'img/magic_1.png', x: 5, y: 1 },
      { name: 'magic_2', url: 'img/magic_2.png', x: 6, y: 5 },
      // { name: 'magic_3', url: 'img/magic_3_29x1.png', x: 29, y: 1 },

      // { name: 'ciy_phoenix', url: 'img/icy_phoenix_17x1.png', x: 17, y: 1 },
      { name: 'icicle', url: 'img/icicle_1_10x1.png', x: 10, y: 1 },

      { name: 'healing_1', url: 'img/heal_11x1.png', x: 11, y: 1 },

      {
        name: 'sparkle',
        url: 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAQAAAACACAYAAADktbcKAAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3QUUFBMzsP/BwQAAIABJREFUeNrtnXmYHFd19n+3qnqZRdJINVpbkiWNLBlb3hfAC9jYxtiYADYJGMMDBAIBnAAxIfn4QjCQBPJhCAFCEkLYYiCQYOxAbGyMDQYb8IK8Y1saWZbVWmbmajSapbeqOt8f99aoNZpNM9UzllTv8/TT3dVV9Vbfuufcc869dQ6kSJEiRYoUKVKkSJEiRYoUKVKkSJEiRYoUKVKkmEGI4IuwbJL7qgl+z6YtenhBa71Ua71mkvuqCX7Ppy16eCqB94pw7Di/rxbhPROc4xUinJe25mGpBP5Ba33qOL9v0Fp/ZoJzvE1r/dq0NacuhDkRWqd4rJMA/zdFuGzkNYiw0P52w2i8IqwQ4fMivCa9i9MSwiat9fwpHutMg1fZ9ye11m/v6emZN+L3Ffa3TaMc62qt12mt79ZajztAOIeRIKrRTFkR3BHfvYlM4kOBUlSAN4uwYBTu5SJcPca1XgqsSuASPg18EOZ/VITXibBWhMuBvwf3GMgtFuFllnee


rictModeTSAlwaysStrict
	}

	// Determine whether or not this file is ESM
	p.isFileConsideredToHaveESMExports =
		p.esmExportKeyword.Len > 0 ||
			p.esmImportMeta.Len > 0 ||
			p.topLevelAwaitKeyword.Len > 0 ||
			p.options.moduleTypeData.Type.IsESM()
	p.isFileConsideredESM =
		p.isFileConsideredToHaveESMExports ||
			p.esmImportStatementKeyword.Len > 0

	// Legacy HTML comments are not allowed in ESM files
	if p.isFileConsideredESM && p.lexer.LegacyHTMLCommentRange.Len > 0 {
		_, notes := p.whyESModule()
		p.log.AddErrorWithNotes(&p.tracker, p.lexer.LegacyHTMLCommentRange,
			"Legacy HTML single-line comments are not allowed in ECMAScript modules", notes)
	}

	// ECMAScript modules are always interpreted as strict mode. This has to be
	// done before "hoistSymbols" because strict mode can alter hoisting (!).
	if p.isFileConsideredESM {
		p.moduleScope.RecursiveSetStrictMode(js_ast.ImplicitStrictModeESM)
	}

	p.hoistSymbols(p.moduleScope)

	if p.options.mode != config.ModePassThrough {
		p.requireRef = p.declareCommonJSSymbol(ast.SymbolUnbound, "require")
	} else {
		p.requireRef = p.newSymbol(ast.SymbolUnbound, "require")
	}

	// CommonJS-style exports are only enabled if this isn't using ECMAScript-
	// style exports. You can still use "require" in ESM, just not "module" or
	// "exports". You can also still use "import" in CommonJS.
	if p.options.mode != config.ModePassThrough && !p.isFileConsideredToHaveESMExports {
		// CommonJS-style exports
		p.exportsRef = p.declareCommonJSSymbol(ast.SymbolHoisted, "exports")
		p.moduleRef = p.declareCommonJSSymbol(ast.SymbolHoisted, "module")
	} else {
		// ESM-style exports
		p.exportsRef = p.newSymbol(ast.SymbolHoisted, "exports")
		p.moduleRef = p.newSymbol(ast.SymbolHoisted, "module")
	}

	// Handle "@jsx" and "@jsxFrag" pragmas now that lexing is done
	if p.options.jsx.Parse {
		if jsxRuntime := p.lexer.JSXRuntimePragmaComment; jsxRuntime.Text != "" {
			if jsxRuntime.Text == "automatic" {
				p.options.jsx.AutomaticRuntime = true
			} else if jsxRuntime.Text == "classic" {
				p.options.jsx.AutomaticRuntime = false
			} else {
				p.log.AddIDWithNotes(logger.MsgID_JS_UnsupportedJSXComment, logger.Warning, &p.tracker, jsxRuntime.Range,
					fmt.Sprintf("Invalid JSX runtime: %q", jsxRuntime.Text),
					[]logger.MsgData{{Text: "The JSX runtime can only be set to either \"classic\" or \"automatic\"."}})
			}
		}

		if jsxFactory := p.lexer.JSXFactoryPragmaComment; jsxFactory.Text != "" {
			if p.options.jsx.AutomaticRuntime {
				p.log.AddID(logger.MsgID_JS_UnsupportedJSXComment, logger.Warning, &p.tracker, jsxFactory.Range,
					"The JSX factory cannot be set when using React's \"automatic\" JSX transform")
			} else if expr, _ := ParseDefineExpr(jsxFactory.Text); len(expr.Parts) > 0 {
				p.options.jsx.Factory = expr
			} else {
				p.log.AddID(logger.MsgID_JS_UnsupportedJSXComment, logger.Warning, &p.tracker, jsxFactory.Range,
					fmt.Sprintf("Invalid JSX factory: %s", jsxFactory.Text))
			}
		}

		if jsxFragment := p.lexer.JSXFragment


  ATT_OP_EXCHANGE_MTU_REQ){
				blc_att_responseMtuSizeExchange(conn_handle, ATT_RX_MTU_SIZE_MAX);
			}

			u16 peer_mtu_size = (pMtu->mtu[0] | pMtu->mtu[1]<<8);
			final_MTU_size = min(ATT_RX_MTU_SIZE_MAX, peer_mtu_size);

			blt_att_setEffectiveMtuSize(conn_handle , final_MTU_size); //stack API, user can not change
		}
		else if(pAtt->opcode == ATT_OP_READ_BY_TYPE_RSP)  //slave ack ATT_OP_READ_BY_TYPE_REQ data
		{
			#if (BLE_MASTER_OTA_ENABLE)
				//when use ATT_OP_READ_BY_TYPE_REQ to find ota atthandle, should get the result
				extern void host_find_slave_ota_attHandle(u8 *p);
				host_find_slave_ota_attHandle( (u8 *)pAtt );
			#endif
			//u16 slave_ota_handle;
		}
		else if(pAtt->opcode == ATT_OP_HANDLE_VALUE_NOTI)  //slave handle notify
		{

			if(attHandle == HID_HANDLE_CONSUME_REPORT)
			{
				static u32 app_key;
				app_key++;
				att_keyboard_media (conn_handle, pAtt->dat);
			}
			else if(attHandle == HID_HANDLE_KEYBOARD_REPORT)
			{
				static u32 app_key;
				app_key++;
				att_keyboard (conn_handle, pAtt->dat);

			}
//			else if(HID_HANDLE_MOUSE_REPORT){
//				static u32 app_mouse_dat;
//				att_mouse(conn_handle,pAtt->dat);
//			}
			else if(attHandle == AUDIO_HANDLE_MIC)
			{
				static u32 app_mic;
				app_mic	++;
				att_mic (conn_handle, pAtt->dat);
			}
			else
			{

			}
		}
		else if (pAtt->opcode == ATT_OP_HANDLE_VALUE_IND)
		{

		}

	}
	else if(ptrL2cap->chanId == L2CAP_CID_SIG_CHANNEL)  //signal
	{
		if(ptrL2cap->opcode == L2CAP_CMD_CONN_UPD_PARA_REQ)  //slave send conn param update req on l2cap
		{
			rf_packet_l2cap_connParaUpReq_t  * req = (rf_packet_l2cap_connParaUpReq_t *)ptrL2cap;

			u32 interval_us = req->min_interval*1250;  //1.25ms unit
			u32 timeout_us = req->timeout*10000; //10ms unit
			u32 long_suspend_us = interval_us * (req->latency+1);

			//interval < 200ms
			//long suspend < 11S
			// interval * (latency +1)*2 <= timeout
			if( interval_us < 200000 && long_suspend_us < 20000000 && (long_suspend_us*2<=timeout_us) )
			{
				//when master host accept slave's conn param update req, should send a conn param update response on l2cap
				//with CONN_PARAM_UPDATE_ACCEPT; if not accpet,should send  CONN_PARAM_UPDATE_REJECT
				blc_l2cap_SendConnParamUpdateResponse(conn_handle, req->id, CONN_PARAM_UPDATE_ACCEPT);  //send SIG Connection Param Update Response

				//if accept, master host should mark this, add will send  update conn param req on link layer later
				//set a flag here, then send update conn param req in mainloop
				host_update_conn_param_req = clock_time() | 1 ; //in case zero value
				host_update_conn_min = req->min_interval;  //backup update param
				host_update_conn_latency = req->latency;
				host_update_conn_timeout = req->timeout;
			}
			else
			{
				blc_l2cap_SendConnParamUpdateResponse(conn_handle, req->id, CONN_PARAM_UPDATE_REJECT);  //send SIG Connection Param Update Response
			}
		}

	}
	else if(ptrL2cap->chanId == L2CAP_CID_SMP) //smp
	{
		#if (BLE_HOST_SMP_ENABLE)
			if(app_host_smp_sdp_pending == SMP_PENDING)
			{
				blm_host_smp_handler(conn_handle, (u8 *)ptrL2cap);
			}

		#endif
	}
	else
	{

	}

	return 0;
}


local setting = {
	{
		tpPos = { x = 33176, y = 31894, z = 15 },
		tpDestination = { x = 33166, y = 31894, z = 15 },
		boss = "The False God",
	},
	{
		tpPos = { x = 33125, y = 31950, z = 15 },
		tpDestination = { x = 33136, y = 31948, z = 15 },
		boss = "Ravenous Hunger",
	},
	{
		tpPos = { x = 33096, y = 31963, z = 15 },
		tpDestination = { x = 33095, y = 31953, z = 15 },
		boss = "Essence of Malice",
	},
	{
		tpPos = { x = 33114, y = 31887, z = 15 },
		tpDestination = { x = 33131, y = 31899, z = 15 },
		boss = "The Souldespoiler",
	},
	{
		tpPos = { x = 33072, y = 31871, z = 15 },
		tpDestination = { x = 33078, y = 31889, z = 15 },
		boss = "The Source Of Corruption",
	},
	{
		tpPos = { x = 33178, y = 31845, z = 15 },
		tpDestination = { x = 33164, y = 31866, z = 15 },
		boss = "The Armored Voidborn",
	},
}

local bossTimer = MoveEvent()

-- Utility function to localize time
local function formatTimeLeft(seconds)
	if seconds <= 0 then
		return "a few seconds"
	end

	local days = math.floor(seconds / 86400)
	local hours = math.floor((seconds % 86400) / 3600)
	local minutes = math.floor((seconds % 3600) / 60)
	local secs = seconds % 60

	local parts = {}

	if days > 0 then
		table.insert(parts, days .. " day" .. (days > 1 and "s" or ""))
	end
	if hours > 0 then
		table.insert(parts, hours .. " hour" .. (hours > 1 and "s" or ""))
	end
	if minutes > 0 then
		table.insert(parts, minutes .. " minute" ..


4
5bo= 2605
IHF1ZXN0 2606
IOCmlQ== 2607
IHN0YXRl 2608
aWdl 2609
RmllbGQ= 2610
LkI= 2611
cGFjZQ== 2612
IG5leHQ= 2613
cGxveQ== 2614
IGxpZmU= 2615
IHJlcXVlc3Q= 2616
IHRob3Nl 2617
ISE= 2618
UGF0aA== 2619
Y3Rpb25z 2620
IGVhcw== 2621
IGZvbGxvdw== 2622
dHJhbnM= 2623
c2VhcmNo 2624
4K6+ 2625
aXRpYWw= 2626
55w= 2627
aW5kb3dz 2628
4buL 2629
IOCkpg== 2630
IGNhcmU= 2631
IFNv 2632
aXJh 2633
2Lo= 2634
0YvQvQ== 2635
MzY= 2636
IG11 2637
INiu 2638
IHZvbA== 2639
IHZp 2640
bGlzdA== 2641
dHJhY3Q= 2642
dW1w 2643
IGFycmF5 2644
aWNsZQ== 2645
QWQ= 2646
IGRpZmZlcmVudA== 2647
KG5ldw== 2648
YWluaW5n 2649
IG9wZXI= 2650
IOCksA== 2651
wq0= 2652
Rm9y 2653
SUw= 2654
IExpc3Q= 2655
IHByb3Y= 2656
5oA= 2657
VXA= 2658
LmxvZw== 2659
4YOj4YM= 2660
4LmJ 2661
IGJlZw== 2662
PD8= 2663
0LDRgQ== 2664
IGV4cGVjdA== 2665
cmFwaA== 2666
IG1vdg== 2667
cm93cw== 2668
7IQ= 2669
d2Vy 2670
IGRhbnM= 2671
IFNjaA== 2672
IFRl 2673
IG1hcg== 2674
IOCktQ== 2675
IOCksg== 2676
b3Rz 2677
IgoK 2678
0L7RgdGC 2679
4LSk 2680
IG9yZ2Fu 2681
aWFz 2682
4LmA4Lg= 2683
IHNhbWU= 2684
QVA= 2685
IEFk 2686
w64= 2687
ZGVmaW5l 2688
LmFwcA== 2689
aXZpbmc= 2690
IyMjIyMjIyM= 2691
IGNvdW4= 2692
IGludGVybg== 2693
SU5H 2694
bGVzcw== 2695
XVs= 2696
Ll8= 2697
IGxvY2Fs 2698
TE8= 2699
IGA= 2700
Tm9kZQ== 2701
IHNpdGU= 2702
bmVjdA== 2703
5Yw= 2704
dXJh 2705
ZnVuY3Rpb24= 2706
IHJlY2U= 2707
c3RhbmNl 2708
IH0pOwo= 2709
4LSo 2710
IHByb2JsZQ== 2711
bWVu 2712
IHN0eWxl 2713
IHJlZg== 2714
IHJlYWxseQ== 2715
aXJk 2716
ZWxh 2717
15s= 2718
TG9n 2719
aWZpZWQ= 2720
X19fXw== 2721
b21i 2722
fSwK 2723
5YY= 2724
QXJyYXk= 2725
dWls 2726
aXNzaW9u 2727
zrM= 2728
X0Y= 2729
IGlr 2730


    data
}

fn store_data(context: &mut CpuContext, address: u32, data: u32, args: &StoreArguments) {
    match args.data_size {
        StoreDataSize::Word => context.write_word(address, data),
        StoreDataSize::Byte => context.write_byte(address, (data & 0x000000ff) as u8),
        StoreDataSize::HalfWord => context.write_half_word(address, (data & 0x0000ffff) as u16),
        _ => panic!("Data type {:?} not supported", args.data_size),
    }
}

fn execute_move_half_word(context: &mut CpuContext, args: &LargeImmediateArguments) {
    context.set_register(args.register.into(), args.immediate as u32);
}

fn execute_move_half_word_top(context: &mut CpuContext, args: &LargeImmediateArguments) {
    let original = context.get_register(args.register.into());
    let shifted_immediate = (args.immediate as u32) << 16;

    let value = original & 0x0000ffff | shifted_immediate;

    context.set_register(args.register.into(), value);
}

fn execute_supervisor_call(context: &mut CpuContext, arg: &u24) {
    const SYSTEM_CALL: u32 = 0;

    if *arg != u24::new(SYSTEM_CALL) {
        panic!("Unsupported supervisor call {:0>6X}", *arg);
    }

    syscall::execute_system_call(context);
}

fn execute_move_status_to_register(context: &mut CpuContext, register: &Register) {
    let status = context.get_status();

    let negative_value: u32 = if status.negative { 1 } else { 0 };
    let zero_value: u32 = if status.zero { 1 } else { 0 };
    let carry_value: u32 = if status.carry { 1 } else { 0 };
    let overflow_value: u32 = if status.overflow { 1 } else { 0 };
    let value = (negative_value << 31)
                  | (zero_value << 30)
                  | (carry_value << 29)
                  | (overflow_value << 28);

    context.set_register((*register).into(), value);
}

fn get_sign(value: u32) -> bool {
    value & 0x80000000 != 0
}

fn get_data_arguments(context: &CpuContext, args: &DataArguments) -> (Register, u32, bool) {
    match args {
        DataArguments::Immediate(args) => {
            (args.register, args.immediate, if args.rotate == 0 { context.get_status().carry } else { args.carry })
        },
        DataArguments::Register(args) => {
            let (operand, carry) = apply_shift_operand(context, &args.operand_register, &args.shift_type, &args.shift_operand);
            (args.register, operand, carry)
        }
    }
}

fn get_read_write_data_arguments(context: &CpuContext, args: &ReadWriteDataArguments) -> (Register, u32, u32, bool) {
    match args {
        ReadWriteDataArguments::Immediate(args) => {
            let original = context.get_register(args.source_register.into());
            (args.destination_register, original, args.immediate, args.carry)
        },
        ReadWriteDataArguments::Register(args) => {
            let original = context.get_register(args.source_register.into());
            let (operand, carry) = apply_shift_operand(context, &args.operand_register, &args.shift_type, &args.shift_operand);

            (args.destination_register, original, operand, carry)
        }
    }
}

fn apply_shift_operand(context: &CpuContext, register: &u4, shift_type: &ShiftType, shift


/*
 * FloorToGrain accepts a timestamp in microsecond precision
 * and returns it in microseconds, rounded down to the nearest
 * ClockGrain value.
 */
uint64_t Fuzzyfox::FloorToGrain(uint64_t aValue) {
  return aValue - (aValue % StaticPrefs::privacy_fuzzyfox_clockgrainus());
}

/*
 * FloorToGrain accepts a timestamp and returns it, rounded down
 * to the nearest ClockGrain value.
 */
TimeStamp Fuzzyfox::FloorToGrain(TimeStamp aValue) {
#ifdef XP_WIN
  // grain is in us
  uint64_t grain = StaticPrefs::privacy_fuzzyfox_clockgrainus();
  // GTC and QPS are stored in |mt| and need to be converted to
  uint64_t GTC = mt2ms(aValue.mValue.mGTC) * 1000;
  uint64_t QPC = mt2ms(aValue.mValue.mQPC) * 1000;

  return TimeStamp(TimeStampValue(ms2mt((GTC - (GTC % grain)) / 1000),
                                  ms2mt((QPC - (QPC % grain)) / 1000),
                                  aValue.mValue.mHasQPC, true));
#else
  return TimeStamp(TimeStampValue(
      true, US_TO_NS(FloorToGrain(NS_TO_US(aValue.mValue.mTimeStamp)))));
#endif
}

/*
 * CeilToGrain accepts a timestamp in microsecond precision
 * and returns it in microseconds, rounded up to the nearest
 * ClockGrain value.
 */
uint64_t Fuzzyfox::CeilToGrain(uint64_t aValue) {
  return (aValue / StaticPrefs::privacy_fuzzyfox_clockgrainus()) *
         StaticPrefs::privacy_fuzzyfox_clockgrainus();
}

/*
 * CeilToGrain accepts a timestamp and returns it, rounded up
 * to the nearest ClockGrain value.
 */
TimeStamp Fuzzyfox::CeilToGrain(TimeStamp aValue) {
#ifdef XP_WIN
  // grain is in us
  uint64_t grain = StaticPrefs::privacy_fuzzyfox_clockgrainus();
  // GTC and QPS are stored in |mt| and need to be converted
  uint64_t GTC = mt2ms(aValue.mValue.mGTC) * 1000;
  uint64_t QPC = mt2ms(aValue.mValue.mQPC) * 1000;

  return TimeStamp(TimeStampValue(ms2mt(((GTC / grain) * grain) / 1000),
                                  ms2mt(((QPC / grain) * grain) / 1000),
                                  aValue.mValue.mHasQPC, true));
#else
  return TimeStamp(TimeStampValue(
      true, US_TO_NS(CeilToGrain(NS_TO_US(aValue.mValue.mTimeStamp)))));
#endif
}
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */

#include "nsCOMPtr.h"
#include "nsAppDirectoryServiceDefs.h"
#include "nsArrayUtils.h"
#include "nsCRT.h"
#include "nsIObserverService.h"
#include "nsIPermissionManager.h"
#include "nsIPrefBranch.h"
#include "nsIXULRuntime.h"
#include "nsToolkitCompsCID.h"
#include "nsUrlClassifierDBService.h"
#include "nsUrlClassifierUtils.h"
#include "nsUrlClassifierProxies.h"
#include "nsURILoader.h"
#include "nsString.h"
#include "nsReadableUtils.h"
#include "nsTArra


/*
 * Copyright 2003 James Bursa <bursa@users.sourceforge.net>
 *
 * This file is part of NetSurf, http://www.netsurf-browser.org/
 *
 * NetSurf is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation; version 2 of the License.
 *
 * NetSurf is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 */

/**
 * \file
 * Declaration of content enumerations.
 *
 * The content enumerations are defined here.
 */

#ifndef NETSURF_CONTENT_TYPE_H
#define NETSURF_CONTENT_TYPE_H

/** Debugging dump operations */
enum content_debug {
	/** Debug the contents rendering. */
	CONTENT_DEBUG_RENDER,

	/** Debug the contents Document Object. */
	CONTENT_DEBUG_DOM,

	/** Debug redraw operations. */
	CONTENT_DEBUG_REDRAW
};

/** Content encoding information types */
enum content_encoding_type {
	/** The content encoding */
	CONTENT_ENCODING_NORMAL,

	/** The content encoding source */
	CONTENT_ENCODING_SOURCE
};

/** The type of a content. */
typedef enum {
	/** no type for content */
	CONTENT_NONE		= 0x00,

	/** content is HTML */
	CONTENT_HTML		= 0x01,

	/** content is plain text */
	CONTENT_TEXTPLAIN	= 0x02,

	/** content is CSS */
	CONTENT_CSS		= 0x04,

	/** All images */
	CONTENT_IMAGE		= 0x08,

	/** Navigator API Plugins */
	CONTENT_PLUGIN		= 0x10,

	/** RISC OS themes content */
	CONTENT_THEME		= 0x20,

	/** Javascript */
	CONTENT_JS		= 0x40,

	/** All script types. */
	CONTENT_SCRIPT		= 0x40,

	/** Any content matches */
	CONTENT_ANY		= 0x7f
} content_type;

/** Status of a content */
typedef enum {
	/** Content is being fetched or converted and is not safe to display. */
	CONTENT_STATUS_LOADING,

	/** Some parts of content still being loaded, but can be displayed. */
	CONTENT_STATUS_READY,

	/** Content has completed all processing. */
	CONTENT_STATUS_DONE,

	/** Error occurred, content will be destroyed imminently. */
	CONTENT_STATUS_ERROR
} content_status;

/**
 * Used in callbacks to indicate what has occurred.
 */
typedef enum {
	/** Content wishes to log something */
	CONTENT_MSG_LOG,

	/** Content is from SSL and this is its chain */
	CONTENT_MSG_SSL_CERTS,

	/** fetching or converting */
	CONTENT_MSG_LOADING,

	/** may be displayed */
	CONTENT_MSG_READY,

	/** content has finished processing */
	CONTENT_MSG_DONE,

	/** error occurred */
	CONTENT_MSG_ERROR,

	/** fetch url redirect occured */
	CONTENT_MSG_REDIRECT,

	/** new status string */
	CONTENT_MSG_STATUS,

	/** content_reformat done */
	CONTENT_MSG_REFORMAT,

	/** needs redraw (eg. new animation frame) */
	CONTENT_MSG_REDRAW,

	/** wants refresh */
	CONTENT_MSG_REFRESH,

	/** download, not for display */
	CONTENT_MSG_DOWNLOAD,

	/** RFC5988 link */
	CONTENT_MSG_LINK,

	/** Javascript thread */
	CONTENT_MSG_GETTHREAD,

	/** Get viewport dimensions. */
	CONTENT_MSG_GETDIMS,

	/** Request to scroll content */
	CONTENT_MSG_SCROLL,

	/** Allow drag saving of content */
	CONTENT_MSG_DRAGSAVE,

	/** Allow URL to be saved */
	CONTENT_MSG_SAVELINK,

	/** Wants a specific mouse pointer set */
	CONTENT_MSG_POINTER,

	/** A selection made or cleared */
	CONTENT_MSG_SELECTION,

	/** Caret movement / hiding */
	CONTENT_MSG_CARET,

	/** A drag started or ended */
	CONTENT_MSG_DRAG,

	/** Create a select menu */
	CONTENT_MSG_SELECTMENU,

	/** A gadget has been clicked on (mainly for file) */
	CONTENT_MSG_GADGETCLICK,

	/** A free text search action has occurred */
	CONTENT_MSG_TEXTSEARCH
} content_msg;

#endif


color: #4C56AF; font-family: cursive; ">Save This Entry</button>

Your Entries :)

                {% for entry in entries %}

{{entry["date"]}}

{{entry["entry"]}}

{{entry["emotion"]}}

                {% endfor %}

{% import 'appbuilder/baselib.html' as baselib with context %}

{% if appbuilder %}
    {% set app_name = appbuilder.app_name %}
{% endif %}

<!DOCTYPE html>

    <title>{% block page_title %}{{app_name}}{% endblock %}</title>

    {% block head_meta %}
        <meta name="viewport" content="width=device-width, initial-scale=1.0">
        <meta name="description" content="">
        <meta name="author" content="">
    {% endblock %}
    {% block head_css %}
        <link href="{{url_for('appbuilder.static',filename='css/bootstrap.min.css')}}" rel="stylesheet">
        <link href="{{url_for('appbuilder.static',filename='css/font-awesome.min.css')}}" rel="stylesheet">
        {% if appbuilder.app_theme %}
           <link href="{{url_for('appbuilder.static',filename='css/themes/'+ appbuilder.app_theme )}}"  rel="stylesheet">
        {% endif %}

        <link href="{{url_for('appbuilder.static',filename='datepicker/bootstrap-datepicker.css')}}" rel="stylesheet">
        <link href="{{url_for('appbuilder.static',filename='select2/select2.css')}}" rel="stylesheet">
        <link href="{{url_for('appbuilder.static',filename='css/flags/flags16.css')}}" rel="stylesheet">
        <link href="{{url_for('appbuilder.static',filename='css/ab.css')}}" rel="stylesheet">
    {% endblock %}
    {% block head_js %}


			input: "0 < 1",
			expected: &CompareOpNode{
				Kind:  CompareOpNodeKindLess,
				Left:  &IntNode{Value: 0},
				Right: &IntNode{Value: 1},
			},
		},
		{
			what:  "! operator",
			input: "!true",
			expected: &NotOpNode{
				Operand: &BoolNode{Value: true},
			},
		},
		{
			what:  "! operator twice",
			input: "!!true",
			expected: &NotOpNode{
				Operand: &NotOpNode{
					Operand: &BoolNode{Value: true},
				},
			},
		},
		{
			what:  "<= operator",
			input: "0 <= 1",
			expected: &CompareOpNode{
				Kind:  CompareOpNodeKindLessEq,
				Left:  &IntNode{Value: 0},
				Right: &IntNode{Value: 1},
			},
		},
		{
			what:  "> operator",
			input: "0 > 1",
			expected: &CompareOpNode{
				Kind:  CompareOpNodeKindGreater,
				Left:  &IntNode{Value: 0},
				Right: &IntNode{Value: 1},
			},
		},
		{
			what:  ">= operator",
			input: "0 >= 1",
			expected: &CompareOpNode{
				Kind:  CompareOpNodeKindGreaterEq,
				Left:  &IntNode{Value: 0},
				Right: &IntNode{Value: 1},
			},
		},
		{
			what:  "== operator",
			input: "0 == 1",
			expected: &CompareOpNode{
				Kind:  CompareOpNodeKindEq,
				Left:  &IntNode{Value: 0},
				Right: &IntNode{Value: 1},
			},
		},
		{
			what:  "!= operator",
			input: "0 != 1",
			expected: &CompareOpNode{
				Kind:  CompareOpNodeKindNotEq,
				Left:  &IntNode{Value: 0},
				Right: &IntNode{Value: 1},
			},
		},
		{
			what:  "&& operator",
			input: "true && false",
			expected: &LogicalOpNode{
				Kind:  LogicalOpNodeKindAnd,
				Left:  &BoolNode{Value: true},
				Right: &BoolNode{Value: false},
			},
		},
		{
			what:  "|| operator",
			input: "true || false",
			expected: &LogicalOpNode{
				Kind:  LogicalOpNodeKindOr,
				Left:  &BoolNode{Value: true},
				Right: &BoolNode{Value: false},
			},
		},
		{
			what:     "nested value",
			input:    "(42)",
			expected: &IntNode{Value: 42},
		},
		{
			what:     "very nested value",
			input:    "((((((((((((((((((42))))))))))))))))))",
			expected: &IntNode{Value: 42},
		},
		{
			what:  "object property dereference",
			input: "a.b",
			expected: &ObjectDerefNode{
				Receiver: &VariableNode{Name: "a"},
				Property: "b",
			},
		},
		{
			what:  "object property dereference with uppercase name",
			input: "github.EVENT",
			expected: &ObjectDerefNode{
				Receiver: &VariableNode{Name: "github"},
				Property: "event",
			},
		},
		{
			what:  "nested object property dereference",
			input: "a.b.c.d",
			expected: &ObjectDerefNode{
				Property: "d",
				Receiver: &ObjectDerefNode{
					Property: "c",
					Receiver: &ObjectDerefNode{
						Property: "b",
						Receiver: &VariableNode{Name: "a"},
					},
				},
			},
		},
		{
			what:  "property includes uppercase character",


.Price
//import tech.edgx.prise.indexer.model.prices.CandleDTO
//import tech.edgx.prise.indexer.repository.BaseCandleRepository
//import tech.edgx.prise.indexer.service.AssetService
//import tech.edgx.prise.indexer.Base
//import tech.edgx.prise.indexer.service.CandleService
//import tech.edgx.prise.indexer.util.Helpers
//import java.io.File
//import java.math.BigDecimal
//import java.time.Duration
//import java.time.LocalDateTime
//import java.time.temporal.ChronoUnit
//import java.util.*
//import java.util.stream.Stream
//
//@TestInstance(TestInstance.Lifecycle.PER_CLASS)
//class HistoricalPriceServiceIT : Base() {
//
//    val historicalPriceService: HistoricalPriceService by inject { parametersOf(config) }
//    val candleService: CandleService by inject { parametersOf(config) }
//    val baseCandleRepository: BaseCandleRepository by inject { parametersOf(config.appDatabase) }
//    val latestPriceService: LatestPriceService by inject { parametersOf(config) }
//
//    @Test
//    fun testMakeKnownFifteenCandle() {
//        baseCandleRepository.truncateAllCandles()
//
//        // Prices: where dtg >= 118544409 and dtg < 118545309
//        val prices = listOf(
//            Price {
//                provider = 1
//                asset_id = 1L
//                quote_asset_id = 2L
//                price = 0.34743066245122084
//                dtg = 118544843L
//                tx_hash = "37e3a61df516df10e982e002a8edb34f30b0e7874a5806bb6466ab23457e0674"
//                amount1 = BigDecimal("3044755254")
//                amount2 = BigDecimal("8763634253")
//                operation = 1
//            },
//            Price {
//                provider = 2
//                asset_id = 1L
//                quote_asset_id = 2L
//                price = 0.34933788810242455
//                dtg = 118545044L
//                tx_hash = "5614ee00eb985516967d7b6668d73a9534eb6dd1753b97f97a937a9b647dfb1a"
//                amount1 = BigDecimal("1454121764")
//                amount2 = BigDecimal("4165587265")
//                operation = 0
//            },
//            Price {
//                provider = 1
//                asset_id = 1L
//                quote_asset_id = 2L
//                price = 0.34933788810242455
//                dtg = 118545170L
//                tx_hash = "a4b8224f1926c3663dc7b9df7818ba60c3a0661893df899ad577e9ffacb27520"
//                amount1 = BigDecimal("1900760542")
//                amount2 = BigDecimal("5441037479")
//                operation = 0
//            }
//        )
//
//        val candleDtg = Helpers.toNearestDiscreteDate(Duration.ofMinutes(15), LocalDateTime.ofEpochSecond(prices[1].dtg, 0, Helpers.zoneOffset))
//
//        val candlesMade = historicalPriceService.makeCandlesFromPrices(candleDtg, Helpers.smallestDuration, prices)
//        println("Made candles for: $candlesMade")
//
//        val candles = candleService.getFifteenById(prices[0].quote_asset_id.toString())
//            .map { CandleDTO(it.asset_id, "", it.time, it.open, it.high, it.low, it.close, it.volume) }
//        println("Made candles: $candles")
//
//        assertTrue(candles.isNotEmpty())
//        val candle = candles.find { it.time == 1710110700L }
//        assertTrue(candle != null)
//        assertEquals(0.347430662451


= None  # type: ignore[assignment]

    return sock

async def _connect_sock(
    loop: asyncio.AbstractEventLoop,
    exceptions: List[List[OSError]],
    addr_info: AddrInfoType,
    local_addr_infos: Optional[Sequence[AddrInfoType]] = None,
) -> socket.socket:
    """Create, bind and connect one socket."""
    my_exceptions: list[OSError] = []
    exceptions.append(my_exceptions)
    family, type_, proto, _, address = addr_info
    sock = None
    try:
        sock = socket.socket(family=family, type=type_, proto=proto)
        sock.setblocking(False)
        if local_addr_infos is not None:
            for lfamily, _, _, _, laddr in local_addr_infos:
                # skip local addresses of different family
                if lfamily != family:
                    continue
                try:
                    sock.bind(laddr)
                    break
                except OSError as exc:
                    msg = (
                        f"error while attempting to bind on "
                        f"address {laddr!r}: "
                        f"{exc.strerror.lower()}"
                    )
                    exc = OSError(exc.errno, msg)
                    my_exceptions.append(exc)
            else:  # all bind attempts failed
                if my_exceptions:
                    raise my_exceptions.pop()
                else:
                    raise OSError(f"no matching local address with {family=} found")
        await loop.sock_connect(sock, address)
        return sock
    except OSError as exc:
        my_exceptions.append(exc)
        if sock is not None:
            sock.close()
        raise
    except:
        if sock is not None:
            sock.close()
        raise
    finally:
        exceptions = my_exceptions = None  # type: ignore[assignment]

def _interleave_addrinfos(
    addrinfos: Sequence[AddrInfoType], first_address_family_count: int = 1
) -> List[AddrInfoType]:
    """Interleave list of addrinfo tuples by family."""
    # Group addresses by family
    addrinfos_by_family: collections.OrderedDict[int, List[AddrInfoType]] = (
        collections.OrderedDict()
    )
    for addr in addrinfos:
        family = addr[0]
        if family not in addrinfos_by_family:
            addrinfos_by_family[family] = []
        addrinfos_by_family[family].append(addr)
    addrinfos_lists = list(addrinfos_by_family.values())

    reordered: List[AddrInfoType] = []
    if first_address_family_count > 1:
        reordered.extend(addrinfos_lists[0][: first_address_family_count - 1])
        del addrinfos_lists[0][: first_address_family_count - 1]
    reordered.extend(
        a
        for a in itertools.chain.from_iterable(itertools.zip_longest(*addrinfos_lists))
        if a is not None
    )
    return reordered


 = &Silence{}

// ValidateCreate implements webhook.Validator so a webhook will be registered for the type
func (s *Silence) ValidateCreate() (warnings admission.Warnings, err error) {

	return s.validateSilence()
}

// ValidateUpdate implements webhook.Validator so a webhook will be registered for the type
func (s *Silence) ValidateUpdate(_ runtime.Object) (warnings admission.Warnings, err error) {
	return s.validateSilence()
}

// ValidateDelete implements webhook.Validator so a webhook will be registered for the type
func (s *Silence) ValidateDelete() (warnings admission.Warnings, err error) {
	return admission.Warnings{}, nil
}

func (s *Silence) validateSilence() (warnings admission.Warnings, err error) {
	var allErrs field.ErrorList

	if err := validateSelector(s.Spec.Matcher); err != nil {
		allErrs = append(allErrs, field.Invalid(field.NewPath("spec", "matcher"), s.Spec.Matcher, err.Error()))
	}

	if s.Spec.Schedule != "" {
		if _, err := cron.ParseStandard(s.Spec.Schedule); err != nil {
			allErrs = append(allErrs, field.Invalid(field.NewPath("spec", "schedule"), s.Spec.Schedule, err.Error()))
		}
	}

	if allErrs == nil || len(allErrs) == 0 {
		return admission.Warnings{}, nil
	}

	return admission.Warnings{}, errors.NewInvalid(
		schema.GroupKind{Group: "notification.kubesphere.io", Kind: "Receiver"},
		s.Name, allErrs)
}
package agent

import (
	"encoding/json"
	"fmt"
)

type Config struct {
	// Protocol version
	Version string

	// Name of the agent
	Name string

	// Token used to authenticate with proxy server
	Token string

	// Kubernetes apiserver host
	KubernetesSvcHost string

	// KubeSphere apigateway host
	KubeSphereSvcHost string

	// agent certificates
	// CertData holds PEM-encoded bytes (typically read from a client certificate file).
	CertData []byte `json:",omitempty"`
	// KeyData holds PEM-encoded bytes (typically read from a client certificate key file).
	KeyData []byte `json:",omitempty"`
	// CAData holds PEM-encoded bytes (typically read from a root certificates bundle).
	CAData []byte `json:",omitempty"`

	// Server requires Bearer authentication. This client will not attempt to use
	// refresh tokens for an OAuth2 flow.
	BearerToken []byte `json:",omitempty"`
}

func (c *Config) Unmarshal(b []byte) error {
	err := json.Unmarshal(b, c)
	if err != nil {
		return fmt.Errorf("invalid json config")
	}
	return nil
}

func (c *Config) Marshal() ([]byte, error) {
	return json.Marshal(c)
}
package utils

import (
	"net"
	"time"

	"github.com/gorilla/websocket"
	"k8s.io/klog/v2"
)

type wsConn struct {
	*websocket.Conn
	buff []byte
}

func NewWebSocketConn(websocketConn *websocket.Conn) net.Conn {
	c := wsConn{
		Conn: websocketConn,
	}
	return &c
}

// Read is not threadsafe tho


 same failure domain (v1beta1)",
			cluster:              cluster.DeepCopy(),
			infraRef:             generateInfraClusterV1Beta1(true),
			contract:             "v1beta1",
			expectFailureDomains: newFailureDomain,
		},
		{
			name:                 "expect failure domain to be updated if infra config has updates to failure domain (v1beta1)",
			cluster:              clusterWithNewFailureDomainUpdated.DeepCopy(),
			infraRef:             generateInfraClusterV1Beta1(true),
			contract:             "v1beta1",
			expectFailureDomains: newFailureDomain,
		},
		{
			name:                 "expect failure domain to be reset if infra config have different failure domain (v1beta1)",
			cluster:              clusterWithOldFailureDomain.DeepCopy(),
			infraRef:             generateInfraClusterV1Beta1(true),
			contract:             "v1beta1",
			expectFailureDomains: newFailureDomain,
		},
		{
			name:      "expect error because InfraCluster uses v1beta2 but contract is v1beta1",
			cluster:   clusterWithOldFailureDomain.DeepCopy(),
			infraRef:  generateInfraCluster(true),
			contract:  "v1beta1",
			expectErr: true,
		},
		{
			name:      "expect error because InfraCluster uses v1beta1 but contract is v1beta2",
			cluster:   clusterWithOldFailureDomain.DeepCopy(),
			infraRef:  generateInfraClusterV1Beta1(true),
			contract:  "v1beta2",
			expectErr: true,
		},
	}

	for _, tt := range tests {
		t.Run(tt.name, func(t *testing.T) {
			g := NewWithT(t)

			crd := builder.GenericInfrastructureClusterCRD.DeepCopy()
			crd.Labels = map[string]string{
				// Set contract label for tt.contract.
				fmt.Sprintf("%s/%s", clusterv1.GroupVersion.Group, tt.contract): clusterv1.GroupVersionInfrastructure.Version,
			}

			objs := []client.Object{crd, tt.cluster}
			if tt.infraRef != nil {
				objs = append(objs, &unstructured.Unstructured{Object: tt.infraRef})
			}

			c := fake.NewClientBuilder().WithObjects(objs...).Build()
			r := &Reconciler{
				Client:   c,
				recorder: record.NewFakeRecorder(32),
				externalTracker: external.ObjectTracker{
					Controller:      externalfake.Controller{},
					Cache:           &informertest.FakeInformers{},
					Scheme:          c.Scheme(),
					PredicateLogger: ptr.To(logr.New(log.NullLogSink{})),
				},
			}

			s := &scope{
				cluster: tt.cluster,
			}
			_, err := r.reconcileInfrastructure(ctx, s)
			if tt.expectErr {
				g.Expect(err).To(HaveOccurred())
				return
			}
			g.Expect(err).ToNot(HaveOccurred())
			g.Expect(tt.cluster.Status.FailureDomains).To(BeEquivalentTo(tt.expectFailureDomains))
		})
	}
}

func generateInfraCluster(withFailureDomain bool) map[string]interface{} {
	infraRef := map[string]interface{}{
		"kind":       "GenericInfrastructureCluster",
		"apiVersion": clusterv1.GroupVersionInfrastructure.String(),
		"metadata": map[string]interface{}{
			"name":              "test",
			"namespace":         "test-namespace",
			"deletionTimestamp": "sometime",
		},
		"status": map[string]interface{}{
			"ready": true,
		},
	}

	if withFailureDomain {
		infraRef["status"] = map[string]interface{}{
			"failureDomains": []interface{}{
				map[string]interface{}{
					"name":         "newdo


	const val BROWSE1_LABEL_MODEL = 417
		const val BROWSE1_ACTIONS_COMPONENT = 51
		const val BROWSE1_ACTIONS_MODEL = 420
		const val BROWSE1_MUSIC_COMPONENT = 53
		const val BROWSE1_MUSIC_MODEL = 422
		const val BROWSE2_STATE = 12
		const val BROWSE2_LABEL_COMPONENT = 60
		const val BROWSE2_LABEL_MODEL = 430
		const val BROWSE2_MUSIC_COMPONENT = 65
		const val BROWSE2_MUSIC_MODEL = 435
		const val BROWSE3_STATE = 10
		const val BROWSE3_MUSIC_MODEL = 409
		const val BROWSE3_MUSIC_COMPONENT = 41

		const val INPUT_STATE = 17
		const val INPUT_COMPONENT = 119
		const val INPUT_RESULT_MODEL = 512
		const val INPUT_SUGGEST_MODEL = 509

		const val AUDIO_STATE = 24
		const val AUDIOSTATE_TITLE_MODEL = 444
		const val AUDIOSTATE_PROVIDER_MODEL = 457
		const val AUDIOSTATE_COVERART_MODEL = 456
		const val AUDIOSTATE_ARTIST_MODEL = 445
		const val AUDIOSTATE_ALBUM_MODEL = 446
		const val AUDIOSTATE_TRACK_MODEL = 447
		const val AUDIOSTATE_CURRENT_TIME_MODEL = 451
		const val AUDIOSTATE_MAX_TIME_MODEL = 452
		const val AUDIOSTATE_PLAYBACK_PROGRESS_MODEL = 462
		const val AUDIOSTATE_PLAYLIST_MODEL = 458
		const val AUDIOSTATE_PLAYLIST_INDEX_MODEL = 459
	}

	val handler = mock<Handler> {
		on { looper } doAnswer { Looper.myLooper() }
	}

	val iDriveConnectionStatus = mock<IDriveConnectionStatus>()
	val securityAccess = mock<SecurityAccess> {
		on { signChallenge(any(), any() )} doReturn ByteArray(512)
	}
	val carAppResources = mock<CarAppResources> {
		on { getAppCertificate() } doReturn ByteArrayInputStream(ByteArray(0))
		on { getUiDescription() } doAnswer { this.javaClass.classLoader!!.getResourceAsStream("ui_description_multimedia_v2.xml") }
		on { getImagesDB(any()) } doReturn ByteArrayInputStream(ByteArray(0))
		on { getTextsDB(any()) } doReturn ByteArrayInputStream(ByteArray(0))
	}

	val phoneAppResources = mock<PhoneAppResources> {
		on { getAppName(any()) } doReturn "Test AppName"
		on { getAppIcon(any())} doReturn mock<Drawable>()
		on { getIconDrawable(any())} doReturn mock<Drawable>()
	}

	val graphicsHelpers = mock<GraphicsHelpers> {
		on { isDark(any()) } doReturn false
		on { compress(isA<Drawable>(), any(), any(), any(), any()) } doAnswer {"Drawable{${it.arguments[1]}x${it.arguments[2]}}".toByteArray()}
		on { compress(isA<Bitmap>(), any(), any(), any(), any()) } doAnswer {"Bitmap{${it.arguments[1]}x${it.arguments[2]}}".toByteArray()}
	}

	val musicAppDiscovery = mock<MusicAppDiscovery>()

	val musicController = mock<MusicController> {
		on { getMetadata() } doReturn MusicMetadata("testId", queueId=10,
				duration=180000L,
				icon=mock(), coverArt=mock(),
				artist="Artist", album="Album", title="Title")
		on { getPlaybackPosition() } doReturn PlaybackPosition(false, false, 0, 5000L, 180000L)
		on { isSupportedAction(any()) } doReturn true


n-width: 576px){.header__title{font-size:3.875em}}.header__description{clear:left;float:left;line-height:1.2;font-size:1.125em;position:relative;margin-bottom:.96em}@media (min-width: 576px){.header__description{font-size:1.3755em}}.category__header--blue .header__description .display-1{color:#fff}.category__header--blue .header__description .display-2{color:#fff}.category__header--blue .header__description .display-3{color:#fff}.category__header--blue .header__description .display-4{color:#fff}.category__header--blue .header__description .display-5{color:#fff}.category__header--blue .header__description .display-6{color:#fff}.category__header--blue .header__description a{color:#fff;border-color:#fff}.category__header--blue .header__description a[rel~='external']:after{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 128 128'%3E   %3Cpath fill='%23fff' d='M24.002 8C15.155 8 8 15.164 8 24.002v79.996C8 112.845 15.164 120 24.002 120h79.996c8.847 0 16.002-7.164    16.002-16.002V82.005c0-1.107-.895-2.005-1.994-2.005h-12.012c-1.1 0-1.994.893-1.994 1.995v16.008c0 3.312-2.685 5.997-5.997 5.997H29.997C26.685    104 24 101.315 24 98.003V29.997C24 26.685 26.685 24 29.997 24h16.008C47.107 24 48 23.105 48 22.006V9.994C48 8.894 47.103 8 45.995 8H24.002z'/%3E   %3Cpath fill='%23fff' d='M127.416.584c-.36-.36-.86-.584-1.41-.584H73.994C72.904 0 72 .893 72 1.994v12.012c0 1.1.892 1.994 1.993 1.994H96L49.41    62.59c-.777.777-.774 2.046.01 2.83l13.16 13.16c.793.793 2.052.788 2.83.01L112 32v22.007c0 1.09.893 1.993 1.994 1.993h12.012c1.1 0 1.994-.892    1.994-1.993V1.993c0-.545-.223-1.043-.584-1.405V.584z'/%3E   %3C/svg%3E")}.category__header--blue .header__description a:focus,.category__header--blue .header__description a:hover{color:#313131;border:0}.category__header--blue .header__description a:focus{outline:1px solid #fff}.footer{font-size:14px;border-top:0;padding:2.8em 0 1.6em 0}.footer a{color:#fff;border-color:#fff}.footer a[rel~='external']:after{background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 128 128'%3E   %3Cpath fill='%23fff' d='M24.002 8C15.155 8 8 15.164 8 24.002v79.996C8 112.845 15.164 120 24.002 120h79.996c8.847 0 16.002-7.164   16.002-16.002V82.005c0-1.107-.895-2.005-1.994-2.005h-12.012c-1.1 0-1.994.893-1.994 1.995v16.008c0 3.312-2.685 5.997-5.997 5.997H29.997C26


T512 416v-64q0-13 9.5-22.5T544 320h64q13 0 22.5 9.5T640 352v64q0 13-9.5 22.5T608 448zM416 832h-64q-13 0-22.5-9.5T320 800v-64q0-13 9.5-22.5T352 704h64q13 0 22.5 9.5T448 736v64q0 13-9.5 22.5T416 832zm0-192h-64q-13 0-22.5-9.5T320 608v-64q0-13 9.5-22.5T352 512h64q13 0 22.5 9.5T448 544v64q0 13-9.5 22.5T416 640zm0-192h-64q-13 0-22.5-9.5T320 416v-64q0-13 9.5-22.5T352 320h64q13 0 22.5 9.5T448 352v64q0 13-9.5 22.5T416 448zM224 832h-64q-13 0-22.5-9.5T128 800v-64q0-13 9.5-22.5T160 704h64q13 0 22.5 9.5T256 736v64q0 13-9.5 22.5T224 832zm0-192h-64q-13 0-22.5-9.5T128 608v-64q0-13 9.5-22.5T160 512h64q13 0 22.5 9.5T256 544v64q0 13-9.5 22.5T224 640z"/></svg>';
  static const String caligraphy =
      '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="1024" height="1024" preserveAspectRatio="xMidYMid meet" viewBox="0 0 1024 1024"><path fill="currentColor" d="M832 704q-53 0-90.5 37.5T704 832q0 80-56 136t-136 56q-106 0-181-75t-75-181 75-181 181-75q53 0 90.5-37.5T640 384q0-80-65.5-136T416 192q-95 0-159.5 44.5T192 352q0 40-28 68t-68 28-68-28-28-68q0-104 52-185T191 43 384 0q104 0 192.5 51.5t140 140T768 384q0 106-75 181t-181 75q-53 0-90.5 47T384 800t37.5 113 90.5 47 90.5-37.5T640 832q0-80 56-136t136-56 136 56 56 136q-4-4-18.5-19T986 793.5t-18-17-19-17.5l-18-15-19.5-14-18.5-10.5-20-9-19.5-4.5-21.5-2z"/></svg>';
  static const String call =
      '<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="1025" height="1023" preserveAspectRatio="xMidYMid meet" viewBox="0 0 1025 1023"><path fill="currentColor" d="m308 288-88 87q18 65 95 160.5T487.5 708 649 803l87-87q15-15 53-12.5t76.5 12T929 737q56 27 82 66.5t3 61.5L907 972q-43 44-117 49.5t-160-23T448 908 265 759 115.5 575.5 24.5 393t-23-159.5T51 117L158 10q


));
}<gh_stars>0
//! Axis Aligned Bounding Box.

use crate::bounding_volume::{BoundingVolume, HasBoundingVolume, BoundingSphere};
use crate::math::{Isometry, Point, Vector};
use crate::utils::IsometryOps;
use na::{self, RealField};

// Seems useful to help type inference. See issue #84.
/// Computes the axis-aligned bounding box of a shape `g` transformed by `m`.
///
/// Same as `g.aabb(m)`.
#[inline]
pub fn aabb<N, G: ?Sized>(g: &G, m: &Isometry<N>) -> AABB<N>
where
    N: RealField,
    G: HasBoundingVolume<N, AABB<N>>,
{
    g.bounding_volume(m)
}

// Seems useful to help type inference. See issue #84.
/// Computes the axis-aligned bounding box of a shape `g`.
///
/// Same as `g.local_aabb(m)`.
#[inline]
pub fn local_aabb<N, G: ?Sized>(g: &G) -> AABB<N>
where
    N: RealField,
    G: HasBoundingVolume<N, AABB<N>>,
{
    g.local_bounding_volume()
}

/// An Axis Aligned Bounding Box.
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
#[derive(Debug, PartialEq, Clone)]
pub struct AABB<N: RealField> {
    mins: Point<N>,
    maxs: Point<N>,
}

impl<N: RealField> AABB<N> {
    /// Creates a new AABB.
    ///
    /// # Arguments:
    ///   * `mins` - position of the point with the smallest coordinates.
    ///   * `maxs` - position of the point with the highest coordinates. Each component of `mins`
    ///   must be smaller than the related components of `maxs`.
    #[inline]
    pub fn new(mins: Point<N>, maxs: Point<N>) -> AABB<N> {
        // assert!(na::partial_le(&mins, &maxs));
        AABB {
            mins: mins,
            maxs: maxs,
        }
    }

    /// Creates a new AABB from its scenter and its half-extents.
    #[inline]
    pub fn from_half_extents(center: Point<N>, half_extents: Vector<N>) -> Self {
        Self::new(center - half_extents, center + half_extents)
    }

    /// Reference to the AABB point with the smallest components along each axis.
    #[inline]
    pub fn mins(&self) -> &Point<N> {
        &self.mins
    }

    /// Reference to the AABB point with the biggest components along each axis.
    #[inline]
    pub fn maxs(&self) -> &Point<N> {
        &self.maxs
    }

    /// The center of this AABB.
    #[inline]
    pub fn center(&self) -> Point<N> {
        na::center(&self.mins, &self.maxs)
    }

    /// The half extents of this AABB.
    #[inline]
    pub fn half_extents(&self) -> Vector<N> {
        let half: N = na::convert(0.5);
        (self.maxs - self.mins) * half
    }

    /// The extents of this AABB.
    #[inline]
    pub fn extents(&self) -> Vector<N> {
        self.maxs - self.mins
    }

    /// Computes the AABB bounding `self` transformed by `m`.
    #[inline]
    pub fn transform_by(&self, m: &Isometry<N>) -> Self {
        let ls_center = self.center();
        let center = m * ls_center;
        let ws_half_extents = m.absolute_transform_vector(&self.half_extents());

        AABB::new(center + (-ws


Load
          Load
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide
          Normal

Oxide

        For ExtremeReactors' Yellorium or Blutonium, click LEU-235 Normal and then click here once.

        For IC2's Enriched Uranium Nuclear Fuel, click LEU-235 Normal and then click here once.

        For IC2's MOX Nuclear Fu


// Licensed to the .NET Foundation under one or more agreements.
// The .NET Foundation licenses this file to you under the MIT license.

using Xunit;

namespace System.Diagnostics.TraceSourceTests
{
    public class SourceFilterClassTests
    {
        [Fact]
        public void ConstructorTest()
        {
            var filter = new SourceFilter("TestSource");
            Assert.Equal("TestSource", filter.Source);
        }

        [Fact]
        public void ShouldTraceTest()
        {
            var sourceName = "TestSource";
            var cache = new TraceEventCache();
            var filter = new SourceFilter(sourceName);
            Assert.True(filter.ShouldTrace(cache,