 {
    id: 0,
    name: '',
    active: false
  };

  courses: any[] = [
    {id: 1, name: 'Learn Angular', active: false},
    {id: 2, name: 'Learn VueJS', active: false},
    {id: 3, name: 'Learn Spring', active: true},
    {id: 4, name: 'Learn Laravel', active: false}
  ];

  myPicture = "https://process.fs.teachablecdn.com/ADNupMnWyR7kCWRvm76Laz/resize=width:705/https://www.filepicker.io/api/file/Xkl7CSRPTwstEiOYIWsg";

  constructor() { }

  addCourse() {
    //spread operators
    this.courses = [this.myCourse, ...this.courses];
    this.myCourse = '';
  }

  deleteCourse(index) {

    Swal.fire({
      title: 'Are you sure?',
      text: 'You will not be able to recover this imaginary file!',
      icon: 'question',
      showCancelButton: true,
      confirmButtonText: 'Delete',
      cancelButtonText: 'Cancel'
    }).then((result) => {
      if (result.value) {

        this.courses.splice(index, 1);

        Swal.fire({
          title: 'Deleted !',
          text: 'This course is deleted !',
          icon: 'success',
          timer: 5000
        })
      // For more information about handling dismissals please visit
      // https://sweetalert2.github.io/#handling-dismissals
      }
    })
  }

  editCourse(course) {
    this.editable = true;
    this.myCourse = course;
  }

  updateCourse() {
    this.editable = false;
    this.myCourse = {
      id: 0,
      name: '',
      active: false
    }
  }

  changeDisplay() {
    this.toggleDisplay = !this.toggleDisplay
  }

}
import { transform } from 'framer-motion';

const scale = 1.1;

export const marks = {
  enterScreen: 0.1,
  beginFirstPoint: 0.2,
  beginFirstScale: 0.3,
  endFirstScale: 0.4,
  endFirstPoint: 0.5,
  beginSecondPoint: 0.6,
  beginSecondScale: 0.7,
  endSecondScale: 0.8,
  endSecondPoint: 0.9,
  exitScreen: 1
};

export function mapPosX(ratio: number, width: number): number {
  const enterPosX = width / 2;
  const FirstPosX = width / 8;
  const SecondPosX = -FirstPosX;
  const exitPosX = -enterPosX;

  const {
    enterScreen,
    beginFirstPoint,
    endFirstPoint,
    beginSecondPoint,
    endSecondPoint,
    exitScreen
  } = marks;

  return ratio <= enterScreen
    ? enterPosX
    : ratio <= beginFirstPoint
    ? transform(ratio, [enterScreen, beginFirstPoint], [enterPosX, FirstPosX])
    : ratio <= endFirstPoint
    ? FirstPosX
    : ratio <= beginSecondPoint
    ? transform(ratio, [endFirstPoint, beginSecondPoint], [FirstPosX, SecondPosX])
    : ratio <= endSecondPoint
    ? SecondPosX
    : ratio <= exitScreen
    ? transform(ratio, [endSecondPoint, exitScreen], [SecondPosX, exitPosX])
    : exitPosX;
}

export function mapFirstImgScale(ratio: number) {
  const { beginFirstPoint, beginFirstScale, endFirstScale, endFirstPoint } = marks;

  return ratio <= beginFirstPoint
    ? 1
    : ratio <= beginFirstScale
    ? transform(ratio, [beginFirstPoint, beginFirstScale], [1, scale])
    : ratio <= endFirstScale
    ? scale
    : ratio <= endFirstPoint
    ? transform(ratio, [endFirstScale, endFirs


	scrollbar.isVisible = true
		animator = scrollbar
			.animate()
			.translationX(0f)
			.alpha(1f)
			.setListener(null)
			.setDuration(animationDuration)
	}

	fun hide() {
		if (!scrollbar.isVisible || isHiding) {
			return
		}
		animator?.cancel()
		isHiding = true
		animator = scrollbar.animate().apply {
			translationX(scrollbarPaddingEnd)
			alpha(0f)
			duration = animationDuration
			setListener(HideListener(this))
		}
	}

	private inner class HideListener(
		private val viewPropertyAnimator: ViewPropertyAnimator,
	) : AnimatorListenerAdapter() {

		private var isCancelled = false

		override fun onAnimationCancel(animation: Animator) {
			super.onAnimationCancel(animation)
			isCancelled = true
		}

		override fun onAnimationEnd(animation: Animator) {
			super.onAnimationEnd(animation)
			if (!isCancelled && this@ScrollbarAnimator.animator === viewPropertyAnimator) {
				scrollbar.isInvisible = true
				isHiding = false
				this@ScrollbarAnimator.animator = null
			}
		}
	}
}
package org.koitharu.kotatsu.core.network.imageproxy

import coil3.request.ImageRequest
import coil3.size.Dimension
import coil3.size.isOriginal
import okhttp3.HttpUrl
import okhttp3.Request

class WsrvNlProxyInterceptor : BaseImageProxyInterceptor() {

	override suspend fun onInterceptImageRequest(request: ImageRequest, url: HttpUrl): ImageRequest {
		val newUrl = HttpUrl.Builder()
			.scheme("https")
			.host("wsrv.nl")
			.addQueryParameter("url", url.toString())
			.addQueryParameter("we", null)
		val size = request.sizeResolver.size()
		if (!size.isOriginal) {
			newUrl.addQueryParameter("crop", "cover")
			(size.height as? Dimension.Pixels)?.let { newUrl.addQueryParameter("h", it.toString()) }
			(size.width as? Dimension.Pixels)?.let { newUrl.addQueryParameter("w", it.toString()) }
		}

		return request.newBuilder()
			.data(newUrl.build())
			.build()
	}

	override suspend fun onInterceptPageRequest(request: Request): Request {
		val sourceUrl = request.url
		val targetUrl = HttpUrl.Builder()
			.scheme("https")
			.host("wsrv.nl")
			.addQueryParameter("url", sourceUrl.toString())
			.addQueryParameter("we", null)
		return request.newBuilder()
			.url(targetUrl.build())
			.build()
	}
}
package org.koitharu.kotatsu.core.network.webview.adblock

import androidx.annotation.CheckResult
import okhttp3.HttpUrl
import okhttp3.HttpUrl.Companion.toHttpUrlOrNull

/**
 * Very simple implementation of adblock list parser
 * Not all features are supported
 */
class RulesList {

	private val blockRules = ArrayList<Rule>()
	private val allowRules = ArrayList<Rule>()

	operator fun get(url: HttpUrl, baseUrl: HttpUrl?): Rule? {
		val rule = blockRules.find { x -> x(url, baseUrl) }
		return rule?.takeIf { allowRules.none { x -> x(url, baseUrl) } }
	}

	fun add(line: String) {
		val parts = line.lowercase().trim().split('$')
		parts.first().addImpl(isWhitelist = false, modifiers = parts.getOrNull(1))
	}

	fun trimToSize() {
		blockRules.trimToSize()
		allowRules.trimToSize()
	}

	private fun String.addImpl(i


]interface{}{}
	if len(patchAnnotations) > 0 {
		gssPatch["metadata"] = map[string]map[string]string{"annotations": patchAnnotations}
	}
	if gss.Spec.ScaleStrategy.ScaleDownStrategyType == gameKruiseV1alpha1.ReserveIdsScaleDownStrategyType && !origGssSpecReservedIds.Equal(gssSpecReservedIds) {
		gssPatch["spec"] = map[string]interface{}{
			"reserveGameServerIds": util.OrdinalSetToIntStrSlice(gssSpecReservedIds),
		}
	}
	if len(gssPatch) == 0 {
		return nil
	}
	patchGssBytes, _ := json.Marshal(gssPatch)
	err = c.Patch(ctx, gss, client.RawPatch(types.MergePatchType, patchGssBytes))
	if err != nil {
		klog.Errorf("failed to patch GameServerSet %s in %s,because of %s.", gss.GetName(), gss.GetNamespace(), err.Error())
		return err
	}

	return nil
}

// computeToScaleGs is to compute what the id list the pods should be existed in cluster, and what the asts reserve id list should be.
// gssSpecReservedIds is the newest explicit id list.
// gssAnnotationsReservedIds is the previous explicit id list.
// astsImplicitReservedIds is the implicit id list.
// pods is the pods that managed by gss now.
func computeToScaleGs(gssSpecReservedIds, gssAnnotationsReservedIds, astsImplicitReservedIds sets.Set[int], expectedReplicas int, pods []corev1.Pod) (workloadManageIds sets.Set[int], newReserveIds sets.Set[int]) {
	// 1. Get newest implicit list & explicit.
	newAddExplicit := util.GetSetInANotInB(gssSpecReservedIds, gssAnnotationsReservedIds)
	newDeleteExplicit := util.GetSetInANotInB(gssAnnotationsReservedIds, gssSpecReservedIds)
	newImplicit := util.GetSetInANotInB(astsImplicitReservedIds, newAddExplicit)
	newImplicit = newImplicit.Union(newDeleteExplicit)
	newExplicit := gssSpecReservedIds

	// 2. Remove the pods ids is in newExplicit.
	workloadManageIds = sets.New[int]()
	var newPods []corev1.Pod
	deletingPodIds := sets.New[int]()
	preDeletingPodIds := sets.New[int]()
	for _, pod := range pods {
		index := util.GetIndexFromGsName(pod.Name)

		// if pod is deleting, exclude it.
		if pod.GetDeletionTimestamp() != nil {
			deletingPodIds.Insert(index)
			continue
		}
		// if pod is preDeleting, exclude it.
		if lifecycleState, exist := pod.GetLabels()[kruisePub.LifecycleStateKey]; exist && lifecycleState == string(kruisePub.LifecycleStatePreparingDelete) {
			preDeletingPodIds.Insert(index)
			continue
		}

		if newExplicit.Has(index) {
			continue
		}
		workloadManageIds.Insert(index)
		newPods = append(newPods, pod)
	}

	// 3. Continue to delete or add pods based on the current and expected number of pods.
	existReplicas := len(workloadManageIds)

	if existReplicas < expectedReplicas {
		// Add pods.
		num := 0
		var toAdd []int
		for i := 0; num < expectedReplicas-existReplicas; i++ {
			if workloadManageIds.Has(i) || newExplicit.Has(i) || preDeletingPodIds.Has(i) {
				continue
			}
			if newImplicit.Has(i) {
				newImplicit.Delete(i)
			}
			toAdd = append(toAdd


colorSpans.size.toLong())
        assertEquals(Color.WHITE.toLong(), colorSpans[0].foregroundColor.toLong())

        val sizeSpans = styledText.getSpans(0, 5, AbsoluteSizeSpan::class.java)
        assertEquals(1, sizeSpans.size.toLong())
        assertEquals(16, sizeSpans[0].size.toLong())

        val fontSpans = styledText.getSpans(0, 5, TypefaceSpan::class.java)
        assertEquals(1, fontSpans.size.toLong())
        assertEquals("serif", fontSpans[0].family)
    }

    @Test
    fun colorIntToHex_correctStringValuesReturned() {
        assertEquals(
            "#FF000000",
            CustomizeUtils.colorIntToHex(Color.parseColor("#FF000000"))
        )
        assertEquals(
            "#00FFFFFF",
            CustomizeUtils.colorIntToHex(Color.parseColor("#00FFFFFF"))
        )
        assertEquals(
            "#FFFFFFFF",
            CustomizeUtils.colorIntToHex(Color.parseColor("#FFFFFFFF"))
        )
        assertEquals(
            "#00000000",
            CustomizeUtils.colorIntToHex(Color.parseColor("#00000000"))
        )
        assertEquals(
            "#12345678",
            CustomizeUtils.colorIntToHex(Color.parseColor("#12345678"))
        )
    }
}
package com.stripe.android.stripe3ds2.views

import android.view.View
import androidx.test.core.app.ApplicationProvider
import org.junit.runner.RunWith
import org.robolectric.RobolectricTestRunner
import kotlin.test.Test
import kotlin.test.assertEquals
import kotlin.test.assertTrue

@RunWith(RobolectricTestRunner::class)
class InformationZoneViewTest {

    private val informationZoneView = InformationZoneView(
        ApplicationProvider.getApplicationContext()
    )

    @Test
    fun setWhyInfo_shouldSetWhyTextViews() {
        informationZoneView.setWhyInfo(WHY_INFO_LABEL, WHY_INFO_TEXT)
        assertEquals(WHY_INFO_LABEL, informationZoneView.whyLabel.text)
        assertEquals(WHY_INFO_TEXT, informationZoneView.whyText.text)
        assertEquals(View.VISIBLE, informationZoneView.whyContainer.visibility)
        assertEquals(View.GONE, informationZoneView.whyText.visibility)
    }

    @Test
    fun setWhyInfo_emptyLabel_shouldNotSetWhyTextViews() {
        informationZoneView.setWhyInfo("", WHY_INFO_TEXT)
        assertTrue(informationZoneView.whyLabel.text.isEmpty())
        assertTrue(informationZoneView.whyText.text.isEmpty())
        assertEquals(View.GONE, informationZoneView.whyContainer.visibility)
        assertEquals(View.GONE, informationZoneView.whyText.visibility)
    }

    @Test
    fun setExpandInfo_shouldSetExpandTextViews() {
        informationZoneView.setExpandInfo(EXPAND_INFO_LABEL, EXPAND_INFO_TEXT)
        assertEquals(EXPAND_INFO_LABEL, informationZoneView.expandLabel.text)
        assertEquals(EXPAND_INFO_TEXT, informationZoneView.expandText.text)
        assertEquals(View.VISIBLE, informationZoneView.expandContainer.visibility)
        assertEquals(View.GONE, informationZoneView.expandText.visibility)
    }

    @Test
    fun setExpandInfo_emptyLabel_shouldNotSetExpandTextViews() {
        informationZoneView.setExpandInfo(null, EXPAND_INFO_TEXT)
        assertTrue(informationZoneView.expandLabel.text.isEmpty())
        assertTrue(informationZoneView.expandText.text.isEmpty())
        assertEquals(
            View.GONE,
            informationZoneView.expandContainer.visibility
        )
        assertEquals(
            View.GONE,
            informationZoneView.expandText.visibility
        )
    }

    @Test
    fun


-item-object-oxy_mega_menu .dropdown-menu > li > ul > li > a:hover {
    background: #090a0a;
    color: #E7E5D9;
  }
  .swatch-black-beige .menu-item-object-oxy_mega_menu .dropdown-menu > li:before, [class*="swatch-"] .swatch-black-beige .menu-item-object-oxy_mega_menu .dropdown-menu > li:before {
    display: none;
  }
}
.swatch-black-beige .pagination > li > a, [class*="swatch-"] .swatch-black-beige .pagination > li > a {
  background: #E6E5D8;
  color: #34383B;
}
.swatch-black-beige .pagination > .active > a, .swatch-black-beige .pagination > .active > span, .swatch-black-beige .pagination > li > a:hover, [class*="swatch-"] .swatch-black-beige .pagination > .active > a, [class*="swatch-"] .swatch-black-beige .pagination > .active > span, [class*="swatch-"] .swatch-black-beige .pagination > li > a:hover {
  background: rgba(230, 229, 216, 0.8);
}
.swatch-black-beige .pagination > .active > a i, .swatch-black-beige .pagination > .active > span i, .swatch-black-beige .pagination > li > a:hover i, [class*="swatch-"] .swatch-black-beige .pagination > .active > a i, [class*="swatch-"] .swatch-black-beige .pagination > .active > span i, [class*="swatch-"] .swatch-black-beige .pagination > li > a:hover i {
  color: #34383B;
}
.swatch-black-beige .pagination > li:first-child i, [class*="swatch-"] .swatch-black-beige .pagination > li:first-child i {
  color: #34383B;
}
.swatch-black-beige .pagination > li:first-child a:after, [class*="swatch-"] .swatch-black-beige .pagination > li:first-child a:after {
  border-right-color: #E6E5D8;
}
.swatch-black-beige .pagination > li:first-child a:hover, [class*="swatch-"] .swatch-black-beige .pagination > li:first-child a:hover {
  background: rgba(230, 229, 216, 0.8);
}
.swatch-black-beige .pagination > li:first-child a:hover:after, [class*="swatch-"] .swatch-black-beige .pagination > li:first-child a:hover:after {
  border-right-color: rgba(230, 229, 216, 0.8);
}
.swatch-black-beige .pagination > li:last-child i, [class*="swatch-"] .swatch-black-beige .pagination > li:last-child i {
  color: #34383B;
}
.swatch-black-beige .pagination > li:last-child a:after, [class*="swatch-"] .swatch-black-beige .pagination > li:last-child a:after {
  border-left-color: #E6E5D8;
}
.swatch-black-beige .pagination > li:last-child a:hover, [class*="swatch-"] .swatch-black-beige .pagination > li:last-child a:hover {
  background: rgba(230, 229, 216, 0.8);
}
.swatch-black-beige .pagination > li:last-child a:hover:after, [cla


哪都戴个智能手表或者电子手环，随时记录自己的一举一动。

还有一种生活黑客要求自己家里所有的电器都上网，并且通过人工智能 —— 至少也要通过语音助手 —— 自动化控制。有人要求每天早上闹钟一响，家里的咖啡壶就开始自动煮好咖啡……如果市面上的智能咖啡壶不听苹果 Siri 的指挥，他就宁可花十几个小时黑进咖啡壶的操作系统，自己实现这个功能。

包括所谓“把妹达人”，也算是生活黑客的一门。这一门黑的是两性关系这个系统 —— 他们像钻研电子游戏一样钻研女性的心理，琢磨怎么和女生搭讪，如何试探、取得反馈。他们使用数据分析的技术手段寻找下一个“女朋友”。

总而言之，只要你发现了生活中的一个什么小窍门，以极客的精神钻研，特别是愿意把你钻研的成果跟人分享，你就是一个生活黑客。如果再进一步，你居然还总结出一套黑客的“道”，大张旗鼓地去宣扬和卖钱，你就是宗师级的黑客。

《巨人的工具》，其作者蒂姆·费里斯（Tim Ferriss），就是一位宗师级的生活黑客。费里斯的成名作是一本叫做《每周工作4小时》的书，这本书说的是生活黑客的钻研成果  ，而且也是用生活黑客的手段写成的。比如作为一个第一次出书的作者，怎么推广自己的新书？费里斯使用了 A/B 测试。

他想了好几个书名，利用 Google 的 Adwords，只花了400美元就测试出哪个书名更容易吸引到来自搜索引擎的点击。什么样的封面能增加销量呢？费里斯做了几种设计，把书摆在公共书店里，他自己找个地方暗中观察，看看哪个封面更容易被读者拿起来。

试问有多少作者下过这样的功夫？而黑客就得舍得下功夫。你可能听说过一位著名的未来学家，《奇点临近》那本书的作者，雷·库兹韦尔（Ray Kurzweil）—— 这位老兄是 1948 年生人，为了活到 2050 年奇点到来的时刻，现在每天吃超过 100 粒（！）各种养生药


dev.azure.com/djtheredstoner/DevAuth/_packaging/public/maven/v1")
    maven("https://repo.viaversion.com")
    maven("https://maven.maxhenkel.de/repository/public")
    maven("https://api.modrinth.com/maven") {
        content {
            includeGroup("maven.modrinth")
        }
    }
}

println("loaderName: $loaderName")
println("mcVersion: $mcVersion")

dependencies {
    minecraft("com.mojang:minecraft:$mcVersionString")
    @Suppress("UnstableApiUsage")
    mappings(loom.layered {
        officialMojangMappings {
            nameSyntheticMembers = true
        }
        when {
            mcVersion >= 1_21_04 -> "1.21.4:2025.03.23"
            mcVersion >= 1_21_03 -> "1.21.3:2024.12.07"
            mcVersion >= 1_21_01 -> "1.21.1:2024.11.17"
            mcVersion >= 1_20_04 -> "1.20.4:2024.04.14"
            mcVersion >= 1_20_01 -> "1.20.1:2023.09.03"
            mcVersion >= 1_19_04 -> "1.19.4:2023.06.26"
            mcVersion >= 1_19_02 -> "1.19.2:2022.11.27"
            else -> null
        }?.let {
            parchment("org.parchmentmc.data:parchment-$it@zip")
        }
    })

    when {
        isFabric -> modImplementation("net.fabricmc:fabric-loader:0.16.10")
        isForge ->
            when (mcVersion) {
                1_20_01 -> "47.1.3"
                1_19_04 -> "45.1.0"
                1_19_02 -> "43.2.0"
                else -> throw IllegalStateException("Unknown Forge version for $mcVersionString")
            }.let { "forge"("net.minecraftforge:forge:$mcVersionString-$it") }
        isNeoForge ->
            when (mcVersion) {
                1_21_05 -> "21.5.26-beta"
                1_21_04 -> "21.4.121"
                1_21_03 -> "21.3.56"
                1_21_01 -> "21.1.1"
                1_20_04 -> "20.4.167"
                else -> throw IllegalStateException("Unknown NeoForge version for $mcVersionString")
            }.let { "neoForge"("net.neoforged:neoforge:$it") }
    }

    fun simpleJavaLibrary(notation: Any) = minecraftRuntimeLibraries(include(implementation(notation)!!)!!)

    simpleJavaLibrary("org.quiltmc.parsers:json:0.3.0")
    simpleJavaLibrary("org.semver4j:semver4j:5.3.0")

    if (isFabric) {
        when (mcVersion) {
            1_21_05 -> "14.0.0-rc.2"
            1_21_04 -> "13.0.3"
            1_21_03 -> "12.0.0"
            1_21_01 -> "11.0.3"
            1_20_04 -> "9.0.0"
            1_20_01 -> "7.2.2"
            1_19_04 -> "6.3.1"
            1_19_02 -> "4.2.0-beta.2"
            else -> null
        }?.let {
            modImplementation("com.terraformersmc:modmenu:$it")
        }
    }

    when {
        isFabric -> "fabric"
        isForge -> "forge-latest"
        isNeoForge -> "neoforge"
        else -> null
    }?.let { modRuntimeOn


for kmsKeyPrimaryState to set.
     * @return This builder for chaining.
     */
    public Builder setKmsKeyPrimaryStateValue(int value) {
      kmsKeyPrimaryState_ = value;
      bitField0_ |= 0x00000004;
      onChanged();
      return this;
    }

    /**
     *
     *
     *

     * Output only. The state of the primary version of the KMS key perceived by
     * the system. This field is not populated in backups.
     *

     *
     *
     * .google.cloud.redis.cluster.v1beta1.EncryptionInfo.KmsKeyState kms_key_primary_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
     *
     *
     * @return The kmsKeyPrimaryState.
     */
    @java.lang.Override
    public com.google.cloud.redis.cluster.v1beta1.EncryptionInfo.KmsKeyState
        getKmsKeyPrimaryState() {
      com.google.cloud.redis.cluster.v1beta1.EncryptionInfo.KmsKeyState result =
          com.google.cloud.redis.cluster.v1beta1.EncryptionInfo.KmsKeyState.forNumber(
              kmsKeyPrimaryState_);
      return result == null
          ? com.google.cloud.redis.cluster.v1beta1.EncryptionInfo.KmsKeyState.UNRECOGNIZED
          : result;
    }

    /**
     *
     *
     *

     * Output only. The state of the primary version of the KMS key perceived by
     * the system. This field is not populated in backups.
     *

     *
     *
     * .google.cloud.redis.cluster.v1beta1.EncryptionInfo.KmsKeyState kms_key_primary_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
     *
     *
     * @param value The kmsKeyPrimaryState to set.
     * @return This builder for chaining.
     */
    public Builder setKmsKeyPrimaryState(
        com.google.cloud.redis.cluster.v1beta1.EncryptionInfo.KmsKeyState value) {
      if (value == null) {
        throw new NullPointerException();
      }
      bitField0_ |= 0x00000004;
      kmsKeyPrimaryState_ = value.getNumber();
      onChanged();
      return this;
    }

    /**
     *
     *
     *

     * Output only. The state of the primary version of the KMS key perceived by
     * the system. This field is not populated in backups.
     *

     *
     *
     * .google.cloud.redis.cluster.v1beta1.EncryptionInfo.KmsKeyState kms_key_primary_state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
     *
     *
     * @return This builder for chaining.
     */
    public Builder clearKmsKeyPrimaryState() {
      bitField0_ = (bitField0_ & ~0x00000004);
      kmsKeyPrimaryState_ = 0;
      onChanged();
      return this;
    }

    private com.google.protobuf.Timestamp lastUpdateTime_;
    private com.google.protobuf.SingleFieldBuilderV3<
            com.google.protobuf.Timestamp,
            com.google.protobuf.Timestamp.Builder,
            com.google.protobuf.TimestampOrBuilder>
        lastUpdateTimeBuilder_;

    /**
     *
     *
     *

     * Output only. The most recent time when the encryption info was updated.
     *

     *
     *
     * .google.protobuf.Timestamp last_update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
     *
     *
     * @return Whether the lastUpdateTime field is set.
     */
    public boolean hasLastUpdateTime() {
      return ((bitField0_ & 0x00000008) != 0);
    }

    /**
     *


foByTime()
				local wOffsetInput = ({['周日']=0,['周一']=1,['周二']=2,['周三']=3,['周四']=4,['周五']=5,['周六']=6})[candTxt_lower]

				--调整 base
				timeBase.day = timeBase.day + wOffsetInput - wInfo.offset2Sun
				wInfo = wInfoByTime(os.time(timeBase))
				jqTime, jqName = jqInfoByTime(os.time(timeBase))
				dateInfo = dateInfoByDaysOffset(wOffsetInput-tonumber(os.date('%w')))
				local daysDiff = daysDiffName(os.time(),os.time(timeBase))

				eventsList = getEventsByTime(os.time(timeBase))
				local eventsStr = ''
				for idx = 1, #eventsList do
					thisEvent = eventsList[idx]
					if '' ~= eventsStr then
						eventsStr = eventsStr..'\r[🔊]'..thisEvent.c3
					else
						eventsStr = '[🔊]'..thisEvent.c3
					end
				end

				local commentStr = ''
				if '今天'==daysDiff then
					commentStr = '[🚩]'
				elseif ''~=daysDiff then
					if os.time() < os.time(timeBase) then
						commentStr = '[👉'..daysDiff..']'
					else
						commentStr = '['..daysDiff..'👈]'
					end
				end

				if ''~=jqName then
					if ''==commentStr then
						commentStr = jqName
					else
						commentStr = commentStr..'\r'..jqName
					end
				end
				if ''~=eventsStr then
					if ''==commentStr then
						commentStr = eventsStr
					else
						commentStr = commentStr..'\r'..eventsStr
					end
				end

				dateInfoList = {dateInfo.date_YYYYMMDD_1,dateInfo.date_YYYYMMDD_2,dateInfo.date_M_Dth_YYYY_1,dateInfo.date_YYYYMMDD}
				for idx = 1, #dateInfoList do
					thisTxt = dateInfoList[idx]
					if nil == cands[thisTxt] then
						if 1==idx and ''~=commentStr then
							yield(Candidate("word", cand.start, cand._end, thisTxt, commentStr))
						else
							yield(Candidate("word", cand.start, cand._end, thisTxt, '💡'))
						end
						cands[thisTxt]=true
					end
				end
			elseif ({['lunar']=true,['农历']=true,['节气']=true})[candTxt_lower] then
				--处理农历信息
				lunarList,jqList,timeList = jqListComming()

				theCands={}

				for idx = 1, math.min(6,#lunarList) do
					thisJq = jqList[idx]
					thisTime = timeList[idx]

					dateInfo = dateInfoByTime(thisTime)
					thisLunar = dateInfo.lunarInfo.lunarDate_4

					if os.date("%Y/%m/%d",thisTime) == os.date("%Y/%m/%d") then
						thisJq = '🚩/'..dateInfo.lunarInfo.jiJieLogo..thisJq
					else
						local daysDiff = daysDiffName(os.time(),thisTime)
						if '' ~= daysDiff then
							if os.time() < thisTime then
								daysDiff = '[👉'..daysDiff..']'
							else
								daysDiff = '['..daysDiff..'�


eturn 0;
}

/*
 *  Lock mutex
 */

int pthread_mutex_lock(pthread_mutex_t *mutex)
{
	if (mutex->ptm_magic != _PT_MUTEX_MAGIC)
		return EINVAL;

	acquire_spinlock(&mutex->ptm_lock);
	return 0;
}

/*
 *  Try to lock mutex
 */

int pthread_mutex_trylock(pthread_mutex_t *mutex)
{
	if (mutex->ptm_magic != _PT_MUTEX_MAGIC)
		return EINVAL;

	if (!try_acquire_spinlock(&mutex->ptm_lock))
		return EBUSY;
	return 0;
}

/*
 *  Unlock mutex
 */

int pthread_mutex_unlock(pthread_mutex_t *mutex)
{
	if (mutex->ptm_magic != _PT_MUTEX_MAGIC)
		return EINVAL;

	release_spinlock(&mutex->ptm_lock);
	return 0;
}

/*
 *  Create mutex attribute
 */

int pthread_mutexattr_init(pthread_mutexattr_t *attr)
{
	attr->ptma_magic = _PT_MUTEXATTR_MAGIC;
	return 0;
}

/*
 *  Destroy mutex attribute
 */

int pthread_mutexattr_destroy(pthread_mutexattr_t *attr)
{
	if (attr->ptma_magic != _PT_MUTEXATTR_MAGIC)
		return EINVAL;
	return 0;
}

/*
 *  Init semaphore
 */

int sem_init(sem_t *psem, int pshared, unsigned int value)
{
	sem_t sem = malloc(sizeof(*sem));
	if (sem == NULL) {
		errno = ENOSPC;
		return 0;
	}
	*psem = sem;
	sem->sem_magic = SEM_MAGIC;
	sem->sem_lock.status = 0;
	sem->sem_lock.spinlock = 0;
	sem->sem_value = value;
	sem->sem_waiting = 0;
	return 0;
}

/*
 *  Delete remaphore
 */

int sem_destroy(sem_t *sem)
{
	if (sem == NULL || *sem == NULL || (*sem)->sem_magic != SEM_MAGIC) {
		errno = EINVAL;
		return -1;
	}

	free(*sem);
	return 0;
}

/*
 *  Wait on semaphore
 */

void null_handler(int sig)
{
}

int sem_wait(sem_t *psem)
{
	sem_t sem;
	if (psem == NULL || (sem = *psem) == NULL || sem->sem_magic != SEM_MAGIC) {
		errno = EINVAL;
		return -1;
	}
	acquire_spinlock(&sem->sem_lock.spinlock);
	if (sem->sem_value > 0)
		atomic_add(&sem->sem_value, -1);
	else {
		sigset_t mask;
		if (!sem->sem_lock.status) {
			struct sigaction sa;
			sem->sem_lock.status = SIGUSR2;
			sa.sa_handler = null_handler;
			sa.sa_flags = SA_RESTART;
			sigemptyset(&sa.sa_mask);
			sigaction(sem->sem_lock.status, &sa, NULL);
		}
		sem->sem_waiting = getpid();
		sigemptyset(&mask);
		sigsuspend(&mask);
		sem->sem_waiting = 0;
	}
	release_spinlock(&sem->sem_lock.spinlock);
	return 0;
}

/*
 *  Post semaphore
 */

int sem_post(sem_t *psem)
{
	sem_t sem;
	if (psem == NULL || (sem = *psem) == NULL || sem->sem_magic != SEM_MAGIC) {
		errno = EINVAL;
		return -1;
	}
	acquire_spinlock(&sem->sem_lock.spinlock);
	if (sem->sem_waiting == 0)
		atomic_add(&sem->sem_value, 1);
	else
		kill(sem->sem_waiting, sem->sem_lock.status);
	release_spinlock(&sem->sem_lock.spinlock);
	return 0;
}

/*
 *  Simple producer/consumer test program
 */

#ifdef TEST
#include <stdio.h>

static sem_t p_sem, c_sem;
static int data = 0;

static void *producer_func(void *arg)
{
	int i, n = (int)arg;
	for (i = 0; i < n; i++) {
		sem_wait(&p_sem);
		data++;
		sem_post(&c_sem);
	}
	return NULL;
}

static void *consumer_func(void *arg)
{
	int i, n = (int)arg;
	for (i = 0; i < n; i++) {
		sem_wait(&c_sem);
		printf("data: %d\n", data);
		sem_post(&p_sem);
	}
	sleep(1); // for testing pthread_join()
	return NULL;
}

int main(void)
{
	pthread_t producer_thread, consumer_thread;
	static const int N = 5;

	if (sem_init(&c_sem, 0, 0) < 0)
		return 1;
	if (sem_init(&p_sem, 0, 1) < 0)
		return 2;
	if (pthread_create(&producer_thread, NULL, producer_func, (void *)N) != 0)
		return 3;
	if (pthread_create(&consumer_thread, NULL, consumer_func, (void *)N) != 0)
		return 4;
	pthread_join(producer_thread, NULL);
	pthread_join(consumer_thread, NULL);
	sem_destroy(&p_sem);
	sem_destroy(&c_sem);
	if (data != N)
		return 5;
	return 0;
}
#endif


		"\n" +
			"public class X {\n" +
			"  void f(Object o){\n" +
			"		 ((Map.Entry)o).setValue(\"bug\");\n" +
			"		 		 \n" +
			"		 Map.Entry me= (Map.Entry)o; \n" +
			"		 me.setValue(\"ok\");\n" +
			"		 		 \n" +
			"		 ((Vector)o).add(\"ok\");\n" +
			"  }\n" +
			" Zork z;\n" +
			"}\n",
		},
		"----------\n" +
		"1. WARNING in X.java (at line 5)\n" +
		"	((Map.Entry)o).setValue(\"bug\");\n" +
		"	^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^\n" +
		"Type safety: The method setValue(Object) belongs to the raw type Map.Entry. References to generic type Map.Entry<K,V> should be parameterized\n" +
		"----------\n" +
		"2. WARNING in X.java (at line 5)\n" +
		"	((Map.Entry)o).setValue(\"bug\");\n" +
		"	  ^^^^^^^^^\n" +
		"Map.Entry is a raw type. References to generic type Map.Entry<K,V> should be parameterized\n" +
		"----------\n" +
		"3. WARNING in X.java (at line 7)\n" +
		"	Map.Entry me= (Map.Entry)o; \n" +
		"	^^^^^^^^^\n" +
		"Map.Entry is a raw type. References to generic type Map.Entry<K,V> should be parameterized\n" +
		"----------\n" +
		"4. WARNING in X.java (at line 7)\n" +
		"	Map.Entry me= (Map.Entry)o; \n" +
		"	               ^^^^^^^^^\n" +
		"Map.Entry is a raw type. References to generic type Map.Entry<K,V> should be parameterized\n" +
		"----------\n" +
		"5. WARNING in X.java (at line 8)\n" +
		"	me.setValue(\"ok\");\n" +
		"	^^^^^^^^^^^^^^^^^\n" +
		"Type safety: The method setValue(Object) belongs to the raw type Map.Entry. References to generic type Map.Entry<K,V> should be parameterized\n" +
		"----------\n" +
		"6. WARNING in X.java (at line 10)\n" +
		"	((Vector)o).add(\"ok\");\n" +
		"	^^^^^^^^^^^^^^^^^^^^^\n" +
		"Type safety: The method add(Object) belongs to the raw type Vector. References to generic type Vector<E> should be parameterized\n" +
		"----------\n" +
		"7. WARNING in X.java (at line 10)\n" +
		"	((Vector)o).add(\"ok\");\n" +
		"	  ^^^^^^\n" +
		"Vector is a raw type. References to generic type Vector<E> should be parameterized\n" +
		"----------\n" +
		"8. ERROR in X.java (at line 12)\n" +
		"	Zork z;\n" +
		"	^^^^\n" +
		"Zork cannot be resolved to a type\n" +
		"----------\n");
}
//https://bugs.eclipse.org/bugs/show_bug.cgi?id=97219
public void test0706() {
	if (this.complianceLevel < ClassFileConstants.JDK1_7) return;
	this.runNegativeTest(
		new String[] {
			"X.java",
			"public class X {\n" +
			"	void foo


is.traveller[jid].primogems = trv.primogems - 160;
				this.traveller[jid].acquaint = trv.acquaint + 1;
				this.save();this
				this.traveller[jid].primogems = trv.primogems - 160;
				this.traveller[jid].interwined = trv.interwined + 1;
				this.save();
				return 'Sukses tukar 1 interwined fate dengan 160 primogems!';
			}
		} else {
			return 'Maaf, anda belum terdaftar dalam genshin game!';
		}
	}
	buy10(jid: string, type: boolean) {
		if (this.isExist(jid)) {
			const trv = this.getUser(jid);
			if (trv.primogems < 1600) return 'Maaf, primogems anda tidak cukup';
			if (type) {
				this.traveller[jid].primogems = trv.primogems - 1600;
				this.traveller[jid].acquaint = trv.acquaint + 10;
				this.save();
				return 'Sukses tukar 10 acquaint fate dengan 1600 primogems!';
			} else {
				this.traveller[jid].primogems = trv.primogems - 1600;
				this.traveller[jid].interwined = trv.interwined + 10;
				this.save();
				return 'Sukses tukar 10 interwined fate dengan 1600 primogems!';
			}
		} else {
			return 'Maaf, anda belum terdaftar dalam genshin game!';
		}
	}
	wishStandart(jid: string, times: number): any {
		if (this.isExist(jid)) {
			const trv = this.getUser(jid);
			if (trv.interwined > times || trv.primogems > 160 * times) {
				const charArry = [],
					weapArry = [];
				for (let i = 0; i < times; i++) {
					let draw = uniform(0, 100),
						rarity,
						itemType,
						drop,
						char,
						weapOrChar,
						weap;
					if (trv.standard5pity === 69) draw = 0.1;
					else if (trv.standard4pity === 9) draw = 1.0;
					if (0 <= draw && draw <= 0.6) {
						rarity = '★★★★★';
						weapOrChar = random(1);
						if (weapOrChar) {
							itemType = 'Character';
							char = random(this.standart().fiveStarChar.length);
							drop = this.standart().fiveStarChar[char];
						} else {
							itemType = 'Weapon';
							weap = random(this.standart().fiveStarWeap.length);
							drop = this.standart().fiveStarWeap[weap];
						}
						this.traveller[jid].standard5pity = 0;
					} else if (0.7 <= draw && draw <= 5.8) {
						rarity = '★★★★';
						weapOrChar = random(1);
						this.traveller[jid].standard5pity += 1;
						if (weapOrChar === 0) {
							itemType = 'Weapon';
							weap = random(this.standart().fourStarWeap.length);
							drop = this.standart().fourStarWeap[weap];
						} else {
							itemType = 'Character';
							char = random(this.standart().fourStarChar.length);
							drop = this.standart().fourStarChar[char];
						}
						this.t


3bdad: 0x6e3f8c20, 0x3bdae: 0x6e3f8e20, 0x3bdaf: 0x6e3f9020,
	0x3bdb0: 0x6e3f9220, 0x3bdb1: 0x6e3f9420, 0x3bdb2: 0x6e3f9620, 0x3bdb3: 0x6e3f9820,
	0x3bdb4: 0x6e3f9a20, 0x3bdb5: 0x6e3f9c20, 0x3bdb6: 0x6e3f9e20, 0x3bdb7: 0x6e3fa020,
	0x3bdb8: 0x6e3fa220, 0x3bdb9: 0x6e3fa420, 0x3bdba: 0x6e3fa620, 0x3bdbb: 0x6e3fa820,
	0x3bdbc: 0x6e3faa20, 0x3bdbd: 0x6e3fac20, 0x3bdbe: 0x6e3fae20, 0x3bdbf: 0x6e3fb020,
	// Block 0xef7, offset 0x3bdc0
	0x3bdc0: 0x6e3fb220, 0x3bdc1: 0x6e3fb420, 0x3bdc2: 0x6e3fb620, 0x3bdc3: 0x6e420020,
	0x3bdc4: 0x6e420220, 0x3bdc5: 0x6e420420, 0x3bdc6: 0x6e420620, 0x3bdc7: 0x6e420820,
	0x3bdc8: 0x6e420a20, 0x3bdc9: 0x6e420c20, 0x3bdca: 0x6e420e20, 0x3bdcb: 0x6e421020,
	0x3bdcc: 0x6e421220, 0x3bdcd: 0x6e421420, 0x3bdce: 0x6e421620, 0x3bdcf: 0x6e421820,
	0x3bdd0: 0x6e421a20, 0x3bdd1: 0x6e421c20, 0x3bdd2: 0x6e421e20, 0x3bdd3: 0x6e422020,
	0x3bdd4: 0x6e422220, 0x3bdd5: 0x6e422420, 0x3bdd6: 0x6e422620, 0x3bdd7: 0x6e422820,
	0x3bdd8: 0x6e43c620, 0x3bdd9: 0x6e43c820, 0x3bdda: 0x6e43ca20, 0x3bddb: 0x6e43cc20,
	0x3bddc: 0x6e43ce20, 0x3bddd: 0x6e43d020, 0x3bdde: 0x6e43d220, 0x3bddf: 0x6e43d420,
	0x3bde0: 0x6e43d620, 0x3bde1: 0x6e43d820, 0x3bde2: 0x6e43da20, 0x3bde3: 0x6e43dc20,
	0x3bde4: 0x6e43de20, 0x3bde5: 0x6e44ea20, 0x3bde6: 0x6e44ec20, 0x3bde7: 0x6e44ee20,
	0x3bde8: 0x6e44f020, 0x3bde9: 0x6e44f220, 0x3bdea: 0x6e44f420, 0x3bdeb: 0x6e44f620,
	0x3bdec: 0x6e44f820, 0x3bded: 0x6e44fa20, 0x3bd


#  Gas station.py
import salabim as sim

#  based on SimPy example model

GAS_STATION_SIZE = 200.0  # liters
THRESHOLD = 25.0  # Threshold for calling the tank truck (in %)
FUEL_TANK_SIZE = 50.0  # liters
# Min/max levels of fuel tanks (in liters)
FUEL_TANK_LEVEL = sim.Uniform(5, 25)
REFUELING_SPEED = 2.0  # liters / second
TANK_TRUCK_TIME = 300.0  # Seconds it takes the tank truck to arrive
T_INTER = sim.Uniform(10, 100)  # Create a car every [min, max] seconds
SIM_TIME = 200000  # Simulation time in seconds

class Car(sim.Component):
    """
    A car arrives at the gas station for refueling.

    It requests one of the gas station's fuel pumps and tries to get the
    desired amount of gas from it. If the stations reservoir is
    depleted, the car has to wait for the tank truck to arrive.

    """

    def process(self):
        fuel_tank_level = int(FUEL_TANK_LEVEL.sample())
        self.request(gas_station)
        liters_required = FUEL_TANK_SIZE - fuel_tank_level
        if (fuel_pump.available_quantity() - liters_required) / fuel_pump.capacity() * 100 < THRESHOLD:
            TankTruck()
        self.get((fuel_pump, liters_required))
        self.hold(liters_required / REFUELING_SPEED)

class TankTruck(sim.Component):
    def process(self):
        self.hold(TANK_TRUCK_TIME)
        amount = fuel_pump.claimed_quantity()
        self.put((fuel_pump, amount))

class CarGenerator(sim.Component):
    """
    Generate new cars that arrive at the gas station.
    """

    def process(self):
        while True:
            self.hold(T_INTER.sample())
            Car()

# Setup and start the simulation
env = sim.Environment(trace=False)
print("Gas Station refuelling")

# Create environment and start processes
gas_station = sim.Resource("gas_station", 2)
fuel_pump = sim.Resource("fuel_pump", capacity=GAS_STATION_SIZE, anonymous=True)
tank_truck = TankTruck()
CarGenerator()

env.run(SIM_TIME)

fuel_pump.capacity.print_histogram()
fuel_pump.claimed_quantity.print_histogram()
fuel_pump.available_quantity.print_histogram()

gas_station.requesters().length.print_histogram()
gas_station.requesters().length_of_stay.print_histogram(30, 0, 10)


수 있을 테니... 직접 싸워야 한다면 분명 아주 큰 싸움이 벌어질 거요."}, {"가젯잔에 있는 선임기술자 빌지위즐에게 자동 탐사막대를 가져가야 합니다."}},
[2769] = {"브라스볼츠 형제", {"브라스볼츠 형제를 만나 보셨나요? 칼림도어의 소금 평원에서 고블린들과 로켓 자동차 경주를 하면서 지내는데, 늘 그들 형제가 이긴답니다. 그리 놀랄 만한 일도 아닌 게 고블린 로켓 자동차는 워낙 폭발이 잦아서 결승선까지 가는 일이 드물거든요!","하지만 그렇다 해도 브라스볼츠 형제는 늘 자기들 로켓 자동차를 더 빨리 달리게 할 방법을 연구하고 있죠. 위즐 말로는 아주 희귀한 부품이 필요하다고 하더군요.","틀림없이 당신의 도움이 필요할 거예요. 위즐에게 가서 알아보세요."}, {"소금 평원에 있는 위즐 브라스볼츠와 대화하십시오."}},
[2770] = {"가즈릴라", {"타나리스에는 줄파락이라고 하는 트롤들의 모래 도시가 있소. 깊숙이 들어가면 신성한 웅덩이가 하나 있소. 트롤 녀석들은 이 웅덩이에서 커다란 괴물을 소환한다오! 가즈릴라! 이 광포한 녀석은 비늘조차도 에너지가 넘쳐 흐른다오. 바로 그 힘을 내 차에 이용하고 싶소!","가즈릴라의 전기 비늘을 가져와 주시오!","가즈릴라를 소환하는 법은 트롤이 철저히 비밀로 지키고 있으니 녀석과 맞서려면 먼저 트롤에게서 비밀을 캐내야 할 거요."}, {"소금 평원에 있는 위즐 브라�


form"]:before{border:1px solid #ddd;outline:1px solid transparent;transition:border-color .1s linear,box-shadow .1s linear}@media (prefers-reduced-motion:reduce){div[data-type="core/freeform"]:before{transition-delay:0s;transition-duration:0s}}div[data-type="core/freeform"].is-selected:before{border-color:#1e1e1e}div[data-type="core/freeform"] .block-editor-block-contextual-toolbar+div{margin-top:0;padding-top:0}div[data-type="core/freeform"].is-selected .block-library-rich-text__tinymce:after{clear:both;content:"";display:table}.mce-toolbar-grp .mce-btn.mce-active button,.mce-toolbar-grp .mce-btn.mce-active i,.mce-toolbar-grp .mce-btn.mce-active:hover button,.mce-toolbar-grp .mce-btn.mce-active:hover i{color:#1e1e1e}.mce-toolbar-grp .mce-rtl .mce-flow-layout-item.mce-last{margin-left:8px;margin-right:0}.mce-toolbar-grp .mce-btn i{font-style:normal}.block-library-classic__toolbar{border:1px solid #ddd;border-bottom:none;border-radius:2px;display:none;margin:0 0 8px;padding:0;position:sticky;top:0;width:auto;z-index:31}div[data-type="core/freeform"].is-selected .block-library-classic__toolbar{border-color:#1e1e1e;display:block}.block-library-classic__toolbar .mce-tinymce{box-shadow:none}@media (min-width:600px){.block-library-classic__toolbar{padding:0}}.block-library-classic__toolbar:empty{background:#f5f5f5;border-bottom:1px solid #e2e4e7;display:block}.block-library-classic__toolbar:empty:before{color:#555d66;content:attr(data-placeholder);font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Oxygen-Sans,Ubuntu,Cantarell,Helvetica Neue,sans-serif;font-size:13px;line-height:37px;padding:14px}.block-library-classic__toolbar div.mce-toolbar-grp{border-bottom:1px solid #1e1e1e}.block-library-classic__toolbar .mce-menubar,.block-library-classic__toolbar .mce-menubar>div,.block-library-classic__toolbar .mce-tinymce-inline,.block-library-classic__toolbar .mce-tinymce-inline>div,.block-library-classic__toolbar div.mce-toolbar-grp,.block-library-classic__toolbar div.mce-toolbar-grp>div{height:auto!important;width:100%!important}.block-library-classic__toolbar .mce-container-body.mce-abs-layout{overflow:visible}.block-library-classic__toolbar .mce-menubar,.block-library-classic__toolbar div.mce-toolbar-grp{position:static}.block-library-classic__toolbar .mce-toolbar-grp>div{padding:1px 3px}.block-library-classic__toolbar .mce-toolbar-grp .mce-toolbar:not(:first-child){display:none}.block-library-classic__toolbar.has-advanced-toolbar .mce-toolbar-grp .mce-toolbar{display:block}.block-editor-freeform-modal .block-editor-freeform-modal__content .mce-edit-area iframe{height:50vh!important}@media (min-width:960px){.block-editor-freeform-modal .block-editor-freeform-modal__content:not(.is-full-screen){height:9999rem}.


/* SPDX-License-Identifier: GPL-2.0-or-later */

#include "gcs.h"

#define GCSPUSHM  "sys #3, c7, c7, #0, %[push]"
#define GCSPOPM   "sysl %[pop], #3, c7, c7, #1"

static void test_sigsegv(int sig, siginfo_t *info, void *vuc)
{
    ucontext_t *uc = vuc;
    uint64_t inst_sigsegv;

    __asm__("adr %0, inst_sigsegv" : "=r"(inst_sigsegv));
    assert(uc->uc_mcontext.pc == inst_sigsegv);
    assert(info->si_code == SEGV_CPERR);
    /* TODO: Dig for ESR and verify syndrome. */
    uc->uc_mcontext.pc += 4;
}

static void test_sigill(int sig, siginfo_t *info, void *vuc)
{
    ucontext_t *uc = vuc;
    uint64_t inst_sigill;

    __asm__("adr %0, inst_sigill" : "=r"(inst_sigill));
    assert(uc->uc_mcontext.pc == inst_sigill);
    assert(info->si_code == ILL_ILLOPC);
    uc->uc_mcontext.pc += 4;
}

int main()
{
    struct sigaction sa = { .sa_flags = SA_SIGINFO };
    uint64_t old, new;

    sa.sa_sigaction = test_sigsegv;
    if (sigaction(SIGSEGV, &sa, NULL) < 0) {
        perror("sigaction");
        exit(1);
    }

    sa.sa_sigaction = test_sigill;
    if (sigaction(SIGILL, &sa, NULL) < 0) {
        perror("sigaction");
        exit(1);
    }

    /* Pushm is disabled -- SIGILL via EC_SYSTEMREGISTERTRAP */
    asm volatile("inst_sigill:\t" GCSPUSHM
                 : : [push] "r" (1));

    enable_gcs(PR_SHADOW_STACK_PUSH);

    /* Valid value -- low 2 bits clear */
    old = 0xdeadbeeffeedcaec;
    asm volatile(GCSPUSHM "\n\t" GCSPOPM
                 : [pop] "=r" (new)
                 : [push] "r" (old)
                 : "memory");
    assert(old == new);

    /* Invalid value -- SIGSEGV via EC_GCS */
    asm volatile(GCSPUSHM "\n"
                 "inst_sigsegv:\t" GCSPOPM
                 : [pop] "=r" (new)
                 : [push] "r" (1)
                 : "memory");

    exit(0);
}


hrink a grid, so we create a new
    // one.
    if (grid) delete grid;
    grid = new QGridLayout(this);
    grid->setContentsMargins(1, 1, 1, 1);
    grid->setSpacing(0);

    int ccol = 0, crow = 0;
    for (int i = 0; i < items.size(); ++i) {
        if (items.at(i)) {
            widgetAt[crow][ccol] = items.at(i);
            grid->addWidget(items.at(i), crow, ccol++);
            if (ccol == columns) {
                ++crow;
                ccol = 0;
            }
        }
    }

    if (moreButton) {
	grid->addWidget(moreButton, crow, ccol);
	widgetAt[crow][ccol] = moreButton;
    }
    updateGeometry();
}

/*! \internal

    Copies the color dialog's currently selected item and emits
    itemSelected().
*/
void ColorPickerPopup::getColorFromDialog()
{
    QColor col = QColorDialog::getColor(lastSel.rgba(), parentWidget());
    if (!col.isValid())
	return;

    insertColor(col, tr("Custom"), -1);
    lastSel = col;
    emit selected(col);
}

/*!
    Constructs a ColorPickerItem whose color is set to \a color, and
    whose name is set to \a text.
*/
ColorPickerItem::ColorPickerItem(const QColor &color, const QString &text,
				     QWidget *parent)
    : QFrame(parent), c(color), t(text), sel(false)
{
    setToolTip(t);
    setFixedWidth(24);
    setFixedHeight(21);
}

/*!
    Destructs a ColorPickerItem.
 */
ColorPickerItem::~ColorPickerItem()
{
}

/*!
    Returns the item's color.

    \sa text()
*/
QColor ColorPickerItem::color() const
{
    return c;
}

/*!
    Returns the item's text.

    \sa color()
*/
QString ColorPickerItem::text() const
{
    return t;
}

/*!

*/
bool ColorPickerItem::isSelected() const
{
    return sel;
}

/*!

*/
void ColorPickerItem::setSelected(bool selected)
{
    sel = selected;
    update();
}

/*!
    Sets the item's color to \a color, and its name to \a text.
*/
void ColorPickerItem::setColor(const QColor &color, const QString &text)
{
    c = color;
    t = text;
    setToolTip(t);
    update();
}

/*!

*/
void ColorPickerItem::mouseMoveEvent(QMouseEvent *)
{
    setFocus();
    update();
}

/*!

*/
void ColorPickerItem::mouseReleaseEvent(QMouseEvent *)
{
    sel = true;
    emit selected();
}

/*!

*/
void ColorPickerItem::mousePressEvent(QMouseEvent *)
{
    setFocus();
    update();
}

/*!

*/
void ColorPickerItem::paintEvent(QPaintEvent *)
{
    QPainter p(this);
    int w = width();			// width of cell in pixels
    int h = height();			// height of cell in pixels

    p.setPen( QPen( Qt::gray, 0, Qt::SolidLine ) );

    if (sel)
	p.drawRect(1, 1, w - 3, h - 3);

    p.setPen( QPen( Qt::black, 0, Qt::SolidLine ) );
    p.drawRect(3, 3, w - 7, h - 7);
    p.fillRect(QRect(4, 4, w - 8, h - 8), QBrush(c));

    if (hasFocus())
	p.drawRect(0, 0, w - 1, h - 1);
}

/*!

*/
ColorPickerButton::ColorPickerButton(QWidget *parent)
    : QFrame(parent)
{
    setFrameStyle(StyledPanel);


; 	Institution  	Adjusted Pub Count	   Faculty

';
	}
	s = s + "
";
	/* As long as there is at least one thing selected, compute and display a ranking. */
	if (numAreas > 0) {
	    let ties = 1;               /* number of tied entries so far (1 = no tie yet); used to implement "competition rankings" */
	    let rank = 0;               /* index */
	    let oldv = 9999999.999;     /* old number - to track ties */
	    /* Sort the university aggregate count from largest to smallest. */
	    let keys2 = CSRankings.sortIndex(univagg);
	    /* Display rankings until we have shown `minToRank` items or
	       while there is a tie (those all get the same rank). */
	    for (let ind = 0; ind < keys2.length; ind++) {
		const dept = keys2[ind];
		const v = Math.round(10.0 * univagg[dept]) / 10.0;

		if ((ind >= minToRank) && (v != oldv)) {
		    break;
		}
		if (v === 0.0) {
		    break;
		}
		if (oldv != v) {
		    if (CSRankings.useDenseRankings) {
			rank = rank + 1;
		    } else {
			rank = rank + ties;
			ties = 0;
		    }
		}
		const esc = escape(dept);
		s += "\n
" + rank + "	";
		s += ""
		    + "" + "" + CSRankings.RightTriangle + " "
		    + "" + dept + "";
		s += " " + "" + CSRankings.PieChart + "";
		//	    s += '
' + '
';
		s += "	";

		s += '' + (Math.round(10.0 * v) / 10.0).toFixed(1)  + "	";
		s += '' + deptCounts[dept] + "
"; /* number of faculty */
		s += "	";
		s += "
\n";
		s += '

' + '

';
		s += '

' + univtext[dept] + '

';
		ties++;
		oldv = v;
	    }
	    s += "
" + "
" + "
";
	    if (CSRankings.allowRankingChange) {
		/* Disable option to change ranking approach for now. */
		if (CSRankings.useDenseRankings) {
		    s += 'Using dense rankings. Click to use competition rankings.';
		} else {
		    s += 'Using competition rankings. Click to use dense rankings.';
		}
	    }
	    s += "
" + "
" + "\n";
	    s += "
" + "" + "";
	} else {
	    /* Nothing selected. */
	    s = "
Please select at least one


 A (4 bytes)
        VLDM        r3!, {s0}               // A0
        VLDM        r9!, {d8-d11}           // B0
        VLDM        r12!, {s2}              // A1
        VLDM        r10!, {s4}              // A2
        VLDM        r0!, {s6}               // A3
        VMLA.F32    q8, q4, d0[0]
        VMLA.F32    q9, q5, d0[0]
        VMLA.F32    q10, q4, d1[0]
        VMLA.F32    q11, q5, d1[0]
        VMLA.F32    q12, q4, d2[0]
        VMLA.F32    q13, q5, d2[0]
        VMLA.F32    q14, q4, d3[0]
        VMLA.F32    q15, q5, d3[0]
        B           3b

        # Store odd width
5:
        TST         r1, 4
        BEQ         6f
        VST1.32     {d28-d29},  [r6]!
        VST1.32     {d24-d25},  [r8]!
        VMOV        q14, q15
        VMOV        q12, q13
        VST1.32     {d20-d21},  [r4]!
        VST1.32     {d16-d17}, [r11]!
        VMOV        q10, q11
        VMOV        q8,  q9

6:
        TST         r1, 2
        BEQ         7f
        VST1.32     {d28},  [r6]!
        VST1.32     {d24},  [r8]!
        VMOV        d28, d29
        VMOV        d24, d25
        VST1.32     {d20},  [r4]!
        VST1.32     {d16}, [r11]!
        VMOV        d20, d21
        VMOV        d16, d17

7:
        TST         r1, 1
        BEQ         8f
        VST1.32     {d28[0]},  [r6]!
        VST1.32     {d24[0]},  [r8]!
        VST1.32     {d20[0]},  [r4]!
        VST1.32     {d16[0]}, [r11]!

8:
        VPOP        {d8-d15}
        ADD         sp, sp, 12              // skip pad, r2, r3
        POP         {r4, r5, r6, r7, r8, r9, r10, r11, pc}

END_FUNCTION xnn_f32_igemm_minmax_ukernel_4x8__asm_aarch32_neon_ld64

#ifdef __ELF__
.section ".note.GNU-stack","",%progbits
#endif


// SPDX-FileCopyrightText: Copyright (C) 2015 swift Project Community / Contributors
// SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-swift-pilot-client-1

//! \file

#ifndef SWIFT_GUI_AIRCRAFTCOMBINEDTYPESELECTOR_H
#define SWIFT_GUI_AIRCRAFTCOMBINEDTYPESELECTOR_H

#include <QFrame>
#include <QObject>
#include <QScopedPointer>
#include <QString>

#include "gui/swiftguiexport.h"
#include "misc/aviation/aircrafticaocode.h"

namespace Ui
{
    class CAircraftCombinedTypeSelector;
}
namespace swift::misc::aviation
{
    class CAircraftIcaoCode;
}
namespace swift::gui::components
{
    /*!
     * Select by comined type ("L2J", "H1T", ...)
     */
    class SWIFT_GUI_EXPORT CAircraftCombinedTypeSelector : public QFrame
    {
        Q_OBJECT

    public:
        //! Constructor
        explicit CAircraftCombinedTypeSelector(QWidget *parent = nullptr);

        //! Destructor
        virtual ~CAircraftCombinedTypeSelector() override;

        //! Set comined code, e.g. L1P
        void setCombinedType(const QString &combinedCode);

        //! Combined code from aircraft ICAO
        void setCombinedType(const swift::misc::aviation::CAircraftIcaoCode &icao);

        //! Clear
        void clear();

        //! Read only
        void setReadOnly(bool readOnly);

        //! Get the combined type, e.g. "L2P"
        QString getCombinedType() const;

    signals:
        //! Combined type has beend changed
        void changedCombinedType(const QString &cominedType);

    private:
        //! Code has been entered
        void combinedTypeEntered();

        //! Changed combobox
        void changedComboBox(const QString &text);

        //! Combined type from comboboxes
        QString getCombinedTypeFromComboBoxes() const;

        QString m_cc;
        QScopedPointer<Ui::CAircraftCombinedTypeSelector> ui;
    };
} // namespace swift::gui::components

#endif // SWIFT_GUI_AIRCRAFTCOMBINEDTYPESELECTOR_H


            file.outputStream().use { output ->
                    this?.copyTo(output)
                }

                file
            }
            cmd += " -m ${lkmFile.absolutePath}"
        }

        is LkmSelection.KmiString -> {
            cmd += " --kmi ${lkm.value}"
        }

        LkmSelection.KmiNone -> {
            // do nothing
        }
    }

    // output dir
    val downloadsDir =
        Environment.getExternalStoragePublicDirectory(Environment.DIRECTORY_DOWNLOADS)
    cmd += " -o $downloadsDir"

    val result = flashWithIO("${getKsuDaemonPath()} $cmd", onStdout, onStderr)
    Log.i("KernelSU", "install boot result: ${result.isSuccess}")

    bootFile?.delete()
    lkmFile?.delete()

    // if boot uri is empty, it is direct install, when success, we should show reboot button
    return FlashResult(result, bootUri == null && result.isSuccess)
}

fun reboot(reason: String = "") {
    val shell = getRootShell()
    if (reason == "recovery") {
        // KEYCODE_POWER = 26, hide incorrect "Factory data reset" message
        ShellUtils.fastCmd(shell, "/system/bin/input keyevent 26")
    }
    ShellUtils.fastCmd(shell, "/system/bin/svc power reboot $reason || /system/bin/reboot $reason")
}

fun rootAvailable(): Boolean {
    val shell = getRootShell()
    return shell.isRoot
}

fun isAbDevice(): Boolean {
    val shell = getRootShell()
    return ShellUtils.fastCmd(shell, "getprop ro.build.ab_update").trim().toBoolean()
}

fun isInitBoot(): Boolean {
    return !Os.uname().release.contains("android12-")
}

suspend fun getCurrentKmi(): String = withContext(Dispatchers.IO) {
    val shell = getRootShell()
    val cmd = "boot-info current-kmi"
    ShellUtils.fastCmd(shell, "${getKsuDaemonPath()} $cmd")
}

suspend fun getSupportedKmis(): List<String> = withContext(Dispatchers.IO) {
    val shell = getRootShell()
    val cmd = "boot-info supported-kmi"
    val out = shell.newJob().add("${getKsuDaemonPath()} $cmd").to(ArrayList(), null).exec().out
    out.filter { it.isNotBlank() }.map { it.trim() }
}

fun overlayFsAvailable(): Boolean {
    val shell = getRootShell()
    // check /proc/filesystems
    return ShellUtils.fastCmdResult(shell, "cat /proc/filesystems | grep overlay")
}

fun hasMagisk(): Boolean {
    val shell = getRootShell(true)
    val result = shell.newJob().add("which magisk").exec()
    Log.i(TAG, "has magisk: ${result.isSuccess}")
    return result.isSuccess
}

fun isSepolicyValid(rules: String?): Boolean {
    if (rules == null) {
        return true
    }
    val shell = getRootShell()
    val result =
        shell.newJob().add("${getKsuDaemonPath()} sepolicy check '$rules'").to(ArrayList(), null)
            .exec()
    return result.isSuccess
}

fun getSepolicy(pkg: String): String {
    val shell = getRootShell()
    val result =
        shell.newJob().add("${getKsuDaemonPath()} profile get-sepolicy $pkg").to(ArrayList(), null)
            .exec()
    Log.i(TAG, "code: ${result.code}, out: ${result.out}, err: ${result.err}")
    return result.out.joinToString("\n")
}

fun setSepolicy(pkg: String, rules: String): Boolean {
    val shell = getRootShell()
    val result = shell.newJob().add("${


*/
  public static _toUnixTimestamp(time: Date);
  public static _toUnixTimestamp(time: number);
  public static _toUnixTimestamp(time: any): number {
    if (typeof time === 'number') {
      return time;
    } else if (time instanceof Date) {
      return time.getTime() / 1000;
    }
    throw new Error("Cannot parse time: " + time);
  }

  /**
   * **NONSTANDARD**: Grab the FileSystem instance that backs this API.
   * @return [BrowserFS.FileSystem | null] Returns null if the file system has
   *   not been initialized.
   */
  public static getRootFS(): file_system.FileSystem {
    if (fs.root) {
      return fs.root;
    } else {
      return null;
    }
  }

  // FILE OR DIRECTORY METHODS

  /**
   * Asynchronous rename. No arguments other than a possible exception are given
   * to the completion callback.
   * @param [String] oldPath
   * @param [String] newPath
   * @param [Function(BrowserFS.ApiError)] callback
   */
  public static rename(oldPath: string, newPath: string, cb: (err?: api_error.ApiError) => void = nopCb): void {
    var newCb = <(err?: api_error.ApiError) => void> wrapCb(cb, 1);
    try {
      fs.root.rename(normalizePath(oldPath), normalizePath(newPath), newCb);
    } catch (e) {
      newCb(e);
    }
  }

  /**
   * Synchronous rename.
   * @param [String] oldPath
   * @param [String] newPath
   */
  public static renameSync(oldPath: string, newPath: string): void {
    fs.root.renameSync(normalizePath(oldPath), normalizePath(newPath));
  }

  /**
   * Test whether or not the given path exists by checking with the file system.
   * Then call the callback argument with either true or false.
   * @example Sample invocation
   *   fs.exists('/etc/passwd', function (exists) {
   *     util.debug(exists ? "it's there" : "no passwd!");
   *   });
   * @param [String] path
   * @param [Function(Boolean)] callback
   */
  public static exists(path: string, cb: (exists: boolean) => void = nopCb): void {
    var newCb = <(exists: boolean) => void> wrapCb(cb, 1);
    try {
      return fs.root.exists(normalizePath(path), newCb);
    } catch (e) {
      // Doesn't return an error. If something bad happens, we assume it just
      // doesn't exist.
      return newCb(false);
    }
  }

  /**
   * Test whether or not the given path exists by checking with the file system.
   * @param [String] path
   * @return [boolean]
   */
  public static existsSync(path: string): boolean {
    try {
      return fs.root.existsSync(normalizePath(path));
    } catch (e) {
      // Doesn't return an error. If something bad happens, we assume it just
      // doesn't exist.
      return false;
    }
  }

  /**
   * Asynchronous `stat`.
   * @param [String] path
   * @param [Function(BrowserFS.ApiError, BrowserFS.node.fs.Stats)] callback
   */
  public static stat(path: string, cb: (err: api_error.ApiError, stats?: node_fs_stats.Stats) => any = nopCb): void {
    var newCb = <(err: api_error.ApiError, stats?: node_fs_stats.Stats) => any> wrapCb(cb, 2);
    try


in("/api/v1/releasestream", stream, "release", tag), out)
	return out, err
}

// https://amd64.ocp.releases.ci.openshift.org/releasetag/4.15.0-0.nightly-2023-11-28-101923/json
//
// This returns raw bytes for now so we can use a dynamic JSON pathing library
// to parse it to avoid fighting with go mod.
//
// The raw bytes returned are very similar to the ones returned by $ oc adm
// release info. The sole difference seems to be that $ oc adm release info
// returns the fully qualified pullspec for the release instead of the tagged
// pullspec.
func (r *ReleaseController) GetReleaseInfo(tag string) ([]byte, error) {
	return r.doHTTPRequestIntoBytes(filepath.Join("releasetag", tag, "json"))
}

func (r *ReleaseController) doHTTPRequest(path string) (*http.Response, error) {
	u := url.URL{
		Scheme: "https",
		Host:   string(*r),
		Path:   path,
	}

	resp, err := http.Get(u.String())

	if err != nil {
		return nil, err
	}

	if resp.StatusCode == http.StatusNotFound {
		return nil, fmt.Errorf("got HTTP 404 from %s", u.String())
	}

	return resp, nil
}

func (r *ReleaseController) doHTTPRequestIntoStruct(path string, out interface{}) error {
	resp, err := r.doHTTPRequest(path)
	if err != nil {
		return err
	}

	defer resp.Body.Close()

	return json.NewDecoder(resp.Body).Decode(out)
}

func (r *ReleaseController) doHTTPRequestIntoBytes(path string) ([]byte, error) {
	resp, err := r.doHTTPRequest(path)
	if err != nil {
		return nil, err
	}

	defer resp.Body.Close()

	out := bytes.NewBuffer([]byte{})

	if _, err := io.Copy(out, resp.Body); err != nil {
		return nil, err
	}

	return out.Bytes(), nil
}

const (
	Amd64OcpReleaseController   ReleaseController = "amd64.ocp.releases.ci.openshift.org"
	Arm64OcpReleaseController   ReleaseController = "arm64.ocp.releases.ci.openshift.org"
	Ppc64leOcpReleaseController ReleaseController = "ppc64le.ocp.releases.ci.openshift.org"
	S390xOcpReleaseController   ReleaseController = "s390x.ocp.releases.ci.openshift.org"
	MultiOcpReleaseController   ReleaseController = "multi.ocp.releases.ci.openshift.org"
	Amd64OkdReleaseController   ReleaseController = "amd64.origin.releases.ci.openshift.org"
)

type ReleaseTags struct {
	Name string    `json:"name"`
	Tags []Release `json:"tags"`
}

type Release struct {
	Name        string `json:"name"`
	Phase       string `json:"phase"`
	Pullspec    string `json:"pullSpec"`
	DownloadURL string `json:"downloadURL"`
}

func GetReleaseController(kind, arch string) (ReleaseController, error) {
	rcs := map[string]map[string]ReleaseController{
		"ocp": {
			"amd64": Amd64OcpReleaseController,
			"arm64": Arm64OcpReleaseController,
			"multi": MultiOcpReleaseController,
		},
		"okd": {
			"amd64": Amd64OkdReleaseController,
		},
		"okd-scos": {
			"amd64": Amd64OkdReleaseController,
		},
	}

	if _, ok := rcs[kind]; !ok {
		return "", fmt.Errorf("invalid kind %q", kind)
	}

	if _, ok := rcs[kind][arch]; !ok {
		return "", fmt.Errorf("invalid arch %q for kind %q",


JSON.stringify({ error: arg.error, message }))
	}
	return arg
}
/*!
 * Copyright 2020 Cognite AS
 */

import { HtmlOverlayHelper } from '@/utilities/HtmlOverlayHelper';
import * as THREE from 'three';

describe('HtmlOverlayHelper', () => {
  const renderer: THREE.Renderer = {
    domElement: document.createElement('canvas')
  } as any;
  const camera = new THREE.PerspectiveCamera();

  test('addOverlayElement() only accepts absolute position', () => {
    // Arrange
    const helper = new HtmlOverlayHelper();
    const htmlElement = document.createElement('div');
    htmlElement.className = 'overlay';
    htmlElement.style.position = 'relative';
    const position = new THREE.Vector3();

    // Act & Assert
    expect(() => helper.addOverlayElement(htmlElement, position)).toThrowError();
  });

  test('updatePositions() places overlays correctly', () => {
    // Arrange
    const helper = new HtmlOverlayHelper();
    const htmlElement = document.createElement('div');
    htmlElement.style.position = 'absolute';
    expect(htmlElement.style.top).toBeEmpty();
    expect(htmlElement.style.left).toBeEmpty();
    const position = new THREE.Vector3(1, 1, 1);
    helper.addOverlayElement(htmlElement, position);

    // Act
    helper.updatePositions(renderer, camera);

    // Assert
    expect(htmlElement.style.top).not.toBeEmpty();
    expect(htmlElement.style.left).not.toBeEmpty();
  });
});
export const valueToString = (value: number): string =>
  `${value <= 9 ? '0' : ''}${value}`;

export const angleToValue = (
  angle: number,
  type: 'minutes' | 'hours'
): number => {
  angle %= 360;
  if (angle < 0) {
    angle += 360;
  }

  const value = type === 'minutes' ? angle / 6 : angle / 30;

  return type !== 'minutes' && value === 0 ? 12 : value;
};

/**
 *
Snaps given value to the nearest defined value.

 *
 *
author: Lukasz 'Severiaan' Grela

 * @param	value value to be "snapped"
 * @param	snapStep snap value
 * @param	p_bUseRound if false then snaping occures on full snapStep change not on half (true). i.e. when true then snapTo(5, 10) = 10 when false it is still 0
 * @return
 * @author Lukasz 'Severiaan' Grela
 */
export const snapTo = (
  value: number,
  snapStep: number,
  p_bUseRound: boolean = true
): number => {
  if (isNaN(value)) return NaN;
  if (isNaN(snapStep)) return value;
  //
  var x: number = value;
  var diff: number;
  var step: number = snapStep;
  var mod: number = x % step;

  if (mod > step >> 1 && p_bUseRound) {
    diff = -(step - mod);
  } else {
    diff = mod;
  }
  return x - diff;
};

export const getMousePosition = (
  cx: number,
  cy: number,
  matrix: DOMMatrix
): { x: number; y: number } => {
  return {
    x: (cx - matrix.e) / matrix.a,
    y: (cy - matrix.f) / matrix.d,
  };
};
export const closestEquivalentAngle = (from: number, to: number): number => {
  var delta = ((((to - from) % 360) + 540) % 360) - 180;
  return from + delta;
};
import { Injectable, Inject } from '@angular/core';

@Injectable()
export class DateService {
  public voteCutoff: Date


mp {
	font-family: monospace;
	color: inherit;
	font-size: 15px;
}

body#tinymce.wp-editor.content pre {
	border: 1px solid #dcd7ca;
	line-height: 1.5;
	margin: 40px 0;
	overflow: auto;
	padding: 30px;
	text-align: left;
}

body#tinymce.wp-editor.content a,
body#tinymce.wp-editor.content a:focus,
body#tinymce.wp-editor.content a:hover {
	color: #cd2653;
	text-decoration: underline;
}

body#tinymce.wp-editor.content img {
	height: auto;
	max-width: 100%;
}

body#tinymce.wp-editor.content img[data-wp-more] {
	height: 16px;
}

body#tinymce.wp-editor.content hr {
	border: none;
	border-top: 1px solid #dcd7ca;
	margin: 2em auto;
	width: 100%;
}

body#tinymce.wp-editor.content hr:not(.is-style-dots) {
	background: linear-gradient(to left, currentColor calc(50% - 16px), transparent calc(50% - 16px), transparent calc(50% + 16px), currentColor calc(50% + 16px));
	border: none;
	color: #6d6d6d;
	height: 1px;
	margin: 80px 0;
	overflow: visible;
	position: relative;
}

body#tinymce.wp-editor.content hr:not(.is-style-dots)::before,
body#tinymce.wp-editor.content hr:not(.is-style-dots)::after {
	background: currentColor;
	content: "";
	display: block;
	height: 16px;
	position: absolute;
	top: calc(50% - 8px);
	transform: rotate(22.5deg);
	width: 1px;
}

body#tinymce.wp-editor.content hr::before {
	left: calc(50% - 5px);
}

body#tinymce.wp-editor.content hr::after {
	right: calc(50% - 5px);
}

body#tinymce.wp-editor.content dt {
	font-weight: 600;
}

body#tinymce.wp-editor.content dd {
	line-height: 1.5;
}

body#tinymce.wp-editor.content dd + dt {
	margin-top: 1.5rem;
}

/* Font Families ----------------------------- */

body#tinymce.wp-editor.content figcaption,
body#tinymce.wp-editor.content .wp-caption-text,
body#tinymce.wp-editor.content .wp-caption-dd,
body#tinymce.wp-editor.content cite,
body#tinymce.wp-editor.content table {
	font-family: -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, sans-serif;
	line-height: 1;
}

@supports ( font-variation-settings: normal ) {

	body#tinymce.wp-editor.content figcaption,
	body#tinymce.wp-editor.content .wp-caption-text,
	body#tinymce.wp-editor.content .wp-caption-dd,
	body#tinymce.wp-editor.content cite,
	body#tinymce.wp-editor.content table {
		font-family: "Inter var", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Helvetica, sans-serif;
	}
}

/* Titles ------------------------------------ */

body#tinymce.wp-editor.content h1,
body#tinymce.wp-editor.content h2,
body#tinymce.wp-editor.content h3,
body#tinymce


务型交通信号控制方面有六大能力需要去打造：全时空的感知；跨领域的研判；个性化的服务；区域性协调；开放式支撑；精细化管控。- [华为：全息路口解决方案](https://holosens.e.huawei.com/road.html?lang=zh)

# 行业痛点

随着城市规模不断扩张，车辆保有数量井喷，形成海量交通大数据，包含人、车、路、视频、图片等各类数据。传统交通治理依赖前端摄像机抓拍图片视频，后端人工审核处理，并存在诸多问题：

-  传统路口是单方向视角，不容易看；
-  事故通过人工方式报警，处警时间长，小事故大拥堵；
-  传统信号控制是车看灯，红绿灯固定配时；
-  从历史事故数据中分析得出交通黑点、隐患发现，后知后觉。

# 方案介绍

全息路口解决方案采用多方向雷视拟合技术，结合高精度地图呈现路口全息视角，通过对交通事故、事件的自动感知，精准数据辅助定责，可节约处警时间，降低次生事故发生；提供精准车道级流量数据，支持路口信控自适应配时；通过实时交通热力图和路网出行规律，快速发现交通隐患点，缩短治理周期，并依据数据分析给出交通组织优化的合理建议。

![方案介绍](https://holosens.e.huawei.com/imgs/road/introduce.png)

方案亮点

- 全息视角

由传统路口四个方向的视频转换成数字化全息视角，结合高精度地图，全面刻画十字路口、丁字路口、X型路口、Y型路口、立交桥等多种交通路口的运行状况。

- 信控优化

通过机非人精准数据，全面分析交通运行状态，路口信号灯控制从原来“车看灯”固定模式到“灯看车”实时模式，提升通行效率。

- 辅助定责

事故从人工报警到自动发现、自动报警，精准轨迹辅助定责，减少交警处警时间。


hierarchy">FHIR Version(s) this Implementation Guide targets
FHIRVersion (Required)

 dependsOn 	Σ	0..*	BackboneElement	Another Implementation guide this depends on

 <a href="implementationguide-definitions.html#ImplementationGuide.dependsOn.uri" title="ImplementationGuide.dependsOn.uri : A canonical


        super.onResume()
        taskHandler.post(task)
    }

    override fun onPause() {
        super.onPause()
        GSYVideoManager.onPause()
    }
    override fun onDestroy() {
        super.onDestroy()
        GSYVideoManager.releaseAllVideos()
        //移除数据绑定，否则第二次设置适配器出错
        banner.destroy()
    }

}/*
 * Copyright (c) 2020. Fulton Browne
 *  This program is free software: you can redistribute it and/or modify
 *     it under the terms of the GNU General Public License as published by
 *     the Free Software Foundation, either version 3 of the License, or
 *     (at your option) any later version.
 *
 *     This program is distributed in the hope that it will be useful,
 *     but WITHOUT ANY WARRANTY; without even the implied warranty of
 *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *     GNU General Public License for more details.
 *
 *     You should have received a copy of the GNU General Public License
 *     along with this program.  If not, see <https://www.gnu.org/licenses/>.
 */

package com.andromeda.ara.search

import com.andromeda.ara.constants.ServerUrl
import com.andromeda.ara.constants.User
import com.andromeda.ara.models.OutputModel
import com.andromeda.ara.util.JsonParse
import java.net.URL
import java.util.*

/**
 * AraSearch class, returns a json parse of url.
 */

class AraSearch {

    fun arrayOfOutputModels(search: String, log: String, lat: String): ArrayList<OutputModel>? {
        //get URL

        val url = URL("${ServerUrl.url}/api/$search&log=$log&lat=$lat&cc=${Locale.getDefault().country}&key=${User.id}")

        println(url)
        var text = "[{\"title\":\"Blank Input Received\",\"link\":\"https://github.com/fultonbrowne/ara-android\",\"description\":\"Please Try Again\",\"OutputTxt\":\"Error Was Encountered\",\"exes\":\"\"}]"
        //parse Json
        try {
            text = url.readText()

        } catch (e: Exception) {

        }

        return JsonParse().search(text)

    }
    fun arrayOfOutputModels2(search: String): ArrayList<OutputModel>? {
        //get URL

        val url = URL(search)

        println(url)
        var text = "[{\"title\":\"Blank Input Received\",\"link\":\"https://github.com/fultonbrowne/ara-android\",\"description\":\"Please Try Again\",\"OutputTxt\":\"Error Was Encountered\",\"exes\":\"\"}]"
        //parse Json
        try {
            text = url.readText()

        } catch (e: Exception) {

        }

        return JsonParse().search(text)

    }

}/*
 * Copyright (c) 2020. Fulton Browne
 *  This program is free software: you can redistribute it and/or modify
 *     it under the terms of the GNU General Public License as published by
 *     the Free Software Foundation, either version 3 of the License, or
 *     (at your option) any later version.
 *
 *     This program is distributed in the hope that it will be useful,
 *     but WITHOUT ANY WARRANTY; without even the implied warranty of
 *     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *     GNU General Public License for more details.
 *
 *     You should have received a copy of the GNU General Public License


atter="fmtInt" relWidth="1">Int
					Children
					Parent
					Widget

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
	"http://www.w3.org/TR/html4/loose.dtd">

	<title>Test dojox.grid.DataGrid Relative Width</title>
	<meta http-equiv="Content-Type" content="text/html; charset=utf-8"></meta>

dojox.grid.DataGrid Relative Width Test

				Country/Continent Name
				Type
				Population

Relwidth mixed with %

				Country/Continent Name
				<th field="type" relWidth=


/
  netif->linkoutput = bridgeif_output;

  /* set MAC hardware address length */
  netif->hwaddr_len = ETH_HWADDR_LEN;

  /* set MAC hardware address */
  memcpy(netif->hwaddr, &br->ethaddr, ETH_HWADDR_LEN);

  /* maximum transfer unit */
  netif->mtu = 1500;

  /* device capabilities */
  /* don't set NETIF_FLAG_ETHARP if this device is not an ethernet one */
  netif->flags = NETIF_FLAG_BROADCAST | NETIF_FLAG_ETHARP | NETIF_FLAG_ETHERNET | NETIF_FLAG_IGMP | NETIF_FLAG_MLD6 | NETIF_FLAG_LINK_UP;

#if LWIP_IPV6 && LWIP_IPV6_MLD
  /*
   * For hardware/netifs that implement MAC filtering.
   * All-nodes link-local is handled by default, so we must let the hardware know
   * to allow multicast packets in.
   * Should set mld_mac_filter previously. */
  if (netif->mld_mac_filter != NULL) {
    ip6_addr_t ip6_allnodes_ll;
    ip6_addr_set_allnodes_linklocal(&ip6_allnodes_ll);
    netif->mld_mac_filter(netif, &ip6_allnodes_ll, NETIF_ADD_MAC_FILTER);
  }
#endif /* LWIP_IPV6 && LWIP_IPV6_MLD */
#ifdef CONFIG_CONCURRENT_MODE
  rpt_handle_init(netif->hwaddr);
#endif
  return ERR_OK;
}

/**
 * @ingroup bridgeif
 * Add a port to the bridge
 */
err_t
bridgeif_add_port(struct netif *bridgeif, struct netif *portif)
{
  bridgeif_private_t *br;
  bridgeif_port_t *port;

  LWIP_ASSERT("bridgeif != NULL", bridgeif != NULL);
  LWIP_ASSERT("bridgeif->state != NULL", bridgeif->state != NULL);
  LWIP_ASSERT("portif != NULL", portif != NULL);

  if (!(portif->flags & NETIF_FLAG_ETHARP) || !(portif->flags & NETIF_FLAG_ETHERNET)) {
    /* can only add ETHERNET/ETHARP interfaces */
    return ERR_VAL;
  }

  br = (bridgeif_private_t *)bridgeif->state;

  if (br->num_ports >= br->max_ports) {
    return ERR_VAL;
  }
  port = &br->ports[br->num_ports];
  port->port_netif = portif;
  port->port_num = br->num_ports;
  port->bridge = br;
  br->num_ports++;

  /* let the port call us on input */
#if BRIDGEIF_PORT_NETIFS_OUTPUT_DIRECT
  portif->input = bridgeif_input;
#else
  portif->input = bridgeif_tcpip_input;
#endif
  /* store pointer to bridge in netif */
  netif_set_client_data(portif, bridgeif_netif_client_id, port);
  /* remove ETHARP flag to prevent sending report events on netif-up */
  netif_clear_flags(portif, NETIF_FLAG_ETHARP);

  return ERR_OK;
}

err_t bridgeif_mac_init(struct netif *netif, char *bmac)
{
  bridgeif_private_t *br;
  br = netif->state;

  memcpy(&br->ethaddr, bmac, sizeof(br->ethaddr));
  memcpy(netif->hwaddr, &br->ethaddr, ETH_HWADDR_LEN);

  return 0;
}

void show_bridgeif_fdbd(struct netif *netif)
{
  bridgeif_private_t *br;
  br = netif->state;
  bridgeif_fdbd_dump(br->fdbd);

}
u8_t bridgeif_get_portnum(struct netif *bridgeif)
{
  bridgeif_private_t *br;
  br = (bridgeif_private_t *)bridgeif->state;
  return br->num_ports;
}
#endif /* LWIP_NUM_NETIF_CLIENT_DATA */


				CreateParams createParams = base.CreateParams;
				createParams.ExStyle |= (int)Win32.WindowExStyles.WS_EX_TOOLWINDOW;
				return createParams;
			}
		}
		protected override void WndProc(ref Message m)
		{
			if (m.Msg == (int)Win32.Msgs.WM_NCHITTEST)
			{
				m.Result = (IntPtr)Win32.HitTest.HTTRANSPARENT;
				return;
			}
			base.WndProc (ref m);
		}
		public virtual void Show(bool bActivate)
		{
			if (bActivate)
				Show();
			else
				NativeMethods.ShowWindow(Handle, (int)Win32.ShowWindowStyles.SW_SHOWNOACTIVATE);
		}
	}
}


" xml:space="preserve">
<g>
	<g>
		<circle cx="129.6" cy="130" r="66.4"></circle>
		<path fill="currentColor" d="M129.6,201.3c-39.3,0-71.4-32-71.4-71.4c0-39.3,32-71.4,71.4-71.4s71.4,32,71.4,71.4    C200.9,169.3,168.9,201.3,129.6,201.3z M129.6,68.6c-33.8,0-61.4,27.5-61.4,61.4c0,33.8,27.5,61.4,61.4,61.4s61.4-27.5,61.4-61.4    C190.9,96.2,163.4,68.6,129.6,68.6z"></path>
	</g>
	<path fill="currentColor" d="M130.1,9c-2.7,0-5,2.2-5,5v19.9c0,2.7,2.2,5,5,5c2.7,0,5-2.2,5-5V14C135,11.2,132.8,9,130.1,9z"></path>
	<path fill="currentColor" d="M76.3,26.8c-0.7-1.1-1.7-2-3-2.3c-0.4-0.1-0.9-0.2-1.3-0.2c-0.9,0-1.7,0.2-2.5,0.7c-2.4,1.4-3.2,4.4-1.8,6.8   l9.9,17.2c0.7,1.1,1.7,2,3,2.3c1.3,0.3,2.6,0.2,3.8-0.5c1.1-0.7,2-1.7,2.3-3c0.3-1.3,0.2-2.6-0.5-3.8L76.3,26.8z"></path>
	<path fill="currentColor" d="M49,77.2l-17.2-9.9c-0.8-0.4-1.6-0.7-2.5-0.7c-1.7,0-3.4,0.9-4.3,2.5c-0.7,1.1-0.8,2.5-0.5,3.8   c0.3,1.3,1.2,2.3,2.3,3l17.2,9.9c1.1,0.7,2.5,0.8,3.8,0.5c1.3-0.3,2.3-1.2,3-2.3c0.7-1.1,0.8-2.5,0.5-3.8   C51,78.9,50.2,77.8,49,77.2z"></path>
	<path fill="currentColor" d="M33.4,124.5H13.5c-2.7,0-5,2.2-5,5c0,2.7,2.2,5,5,5h19.9c2.7,0,5-2.2,5-5C38.3,126.7,36.1,124.5,33.4,124.5z"></path>
	<path fill="currentColor" d="M46,172.7c-0.8,0-1.7,0.2-2.5,0.7l-17.2,9.9c-2.4,1.4-3.2,4.4-1.8,6.8c0


# Kicad currently does not support adding keepout zones directly to footprints
# For this reason the library maintainance team decided to communicate keepouts as follows:
#  - A polygone outlining the keepout area (on layer Dwgs.User)
#  - Hatching of this area on the same layer
#  - Text on Cmts.User: KEEPOUT (with additional information if necessary)

import sys, os
sys.path.append(os.path.join(sys.path[0],"..","..")) # load kicad_mod path
from KicadModTree import *  # NOQA
from math import sqrt

KEEPOUT_DEFAULT_CONFIG={
    'graphical_layer':'Dwgs.User',
    'line_width': 0.1,
    'hatching_spacing': 2,
    'text':{
        'size':[1,1],
        'fontwidth':0.15,
        'position':'center',
        'layer':'Cmts.User'
    }
}
def addRectangularKeepout(kicad_mod, center, size, text='KEEPOUT', config=KEEPOUT_DEFAULT_CONFIG):
    keepout_edges={
        'left': center[0] - (size[0] / 2),
        'top': center[1] - (size[1] / 2)
    }
    keepout_edges['right'] = keepout_edges['left'] + size[0]
    keepout_edges['bottom'] = keepout_edges['top'] + size[1]
    kicad_mod.append(RectLine(
        start=[keepout_edges['left'], keepout_edges['top']],
        end=[keepout_edges['right'], keepout_edges['bottom']],
        layer=config['graphical_layer'], width=config['line_width']))

    if size[0] >= size[1]:
        rot = 0
        longer_size = size[0]
    else:
        longer_size = size[1]
        rot = 90

    fs = round(longer_size/len(text), 2)
    if fs > config['text']['size'][0]:
        size = config['text']['size']
        thickness = config['text']['fontwidth']
    else:
        size = [fs, fs]
        thickness = config['text']['fontwidth'] * fs

    kicad_mod.append(Text(type='user', text=text,
        at=center, rotation=rot,
        layer=config['text']['layer'], size=size,
        thickness=thickness))

    p1 = {'x':keepout_edges['left'], 'y':keepout_edges['top']}
    p2 = {'x':keepout_edges['left'], 'y':keepout_edges['top']}
    # 45° hatching
    step = config['hatching_spacing']
    step_x = step/sqrt(2)
    step_y = step_x

    p1_direction = 'move_right'
    p2_direction = 'move_down'

    while (1):
        if p1_direction == 'move_right':
            p1['x'] += step_x
            if p1['x'] > keepout_edges['right']:
                p1_direction = 'move_down'
                dx = keepout_edges['right'] - (p1['x'] - step_x)
                dy = step_y - dx
                p1['x'] = keepout_edges['right']
                p1['y'] += dy
        else:
            p1['y'] += step_y

        if p2_direction == 'move_down':
            p2['y'] += step_y
            if p2['y'] > keepout_edges['bottom']:
                p2_direction = 'move_right'
                dy = keepout_edges['bottom'] - (p2['y'] - step_y)
                dx = step_x - dy
                p2['x'] += dx
                p2['y'] = keepout_edges['bottom']
        else:
            p2['x'] += step_x

        if p1['y'] > keepout_edges['bottom']:
            return

        kicad_mod.append(Line(start=p1, end=p2,
            layer=config['graphical_layer'], width=config['line_width']))


 { title: 'title9', dataIndex: 'b', key: 'i', width: 100 }, { title: 'title10', dataIndex: 'b', key: 'j', width: 100 }, { title: 'title11', dataIndex: 'b', key: 'k', width: 100 }, { title: 'title12', dataIndex: 'b', key: 'l', width: 100 }];

var data = [{ a: '123', b: 'xxxxxxxx xxxxxxxx', d: 3, key: '1' }, { a: 'cdd', b: 'edd12221 edd12221', d: 3, key: '2' }, { a: '133', c: 'edd12221 edd12221', d: 2, key: '3' }, { a: '133', c: 'edd12221 edd12221', d: 2, key: '4' }, { a: '133', c: 'edd12221 edd12221', d: 2, key: '5' }, { a: '133', c: 'edd12221 edd12221', d: 2, key: '6' }, { a: '133', c: 'edd12221 edd12221', d: 2, key: '7' }, { a: '133', c: 'edd12221 edd12221', d: 2, key: '8' }, { a: '133', c: 'edd12221 edd12221', d: 2, key: '9' }];
export default {
  render: function render() {
    var h = arguments[0];

    return h('div', [h('h2', ['Scroll X/Y']), h(Table, {
      attrs: {
        useFixedHeader: true,

        scroll: { x: 1500, y: 300 },
        columns: columns,
        data: data
      },
      style: { width: '800px' } })]);
  }
};/* eslint-disable no-console,func-names,react/no-multi-comp */
import Table from '../index';
import '../assets/index.less';
import Menu from '../../menu';
var Item = Menu.Item;
var Divider = Menu.Divider;
import DropDown from '../../dropdown';

var data = [];
for (var i = 0; i < 10; i++) {
  data.push({
    key: i,
    a: 'a' + i,
    b: 'b' + i,
    c: 'c' + i
  });
}

export default {
  data: function data() {
    this.filters = [];
    return {
      visible: false
    };
  },

  methods: {
    handleVisibleChange: function handleVisibleChange(visible) {
      this.visible = visible;
    },
    handleSelect: function handleSelect(selected) {
      this.filters.push(selected);
    },
    handleDeselect: function handleDeselect(key) {
      var index = this.filters.indexOf(key);
      if (index !== -1) {
        this.filters.splice(index, 1);
      }
    },
    confirmFilter: function confirmFilter() {
      console.log(this.filters.join(','));
      this.visible = false;
    }
  },

  render: function render() {
    var h = arguments[0];

    var menu = h(
      Menu,
      {
        style: { width: '200px' },
        attrs: { multiple: true,
          selectable: true
        },
        on: {
          'select': this.handleSelect,
          'deselect': this.handleDeselect
        }
      },
      [h(
        Item,
        { key: '1' },
        ['one']
      ), h(
        Item,
        { key: '2' },
        ['two']
      ), h(
        Item,
        { key: '3' },
        ['three']
      ), h(Divider), h(
        Item,
        {
          attrs: { disabled: true }
        },
        [h(
          'button',
          {


d(accum.Red);
            }

            if (samples > 0)
            {
                attribs.Add((int)Agl.PixelFormatAttribute.AGL_SAMPLE_BUFFERS_ARB);
                attribs.Add(1);
                attribs.Add((int)Agl.PixelFormatAttribute.AGL_SAMPLES_ARB);
                attribs.Add(samples);
            }

            if (stereo)
            {
                attribs.Add((int)Agl.PixelFormatAttribute.AGL_STEREO);
            }

            attribs.Add(0);
            attribs.Add(0);

            IntPtr pixelformat = Agl.aglChoosePixelFormat(IntPtr.Zero, 0, attribs.ToArray());
            return pixelformat;
        }
    }
}


C0A00000
/* 069C8 8093F698 0C0294D3 */  jal     func_800A534C
/* 069CC 8093F69C 24840568 */  addiu   $a0, $a0, 0x0568           ## $a0 = 80950568
/* 069D0 8093F6A0 10000018 */  beq     $zero, $zero, .L8093F704
/* 069D4 8093F6A4 86020152 */  lh      $v0, 0x0152($s0)           ## 00000152
.L8093F6A8:
/* 069D8 8093F6A8 8C84C848 */  lw      $a0, %lo(D_8094C848)($a0)
/* 069DC 8093F6AC 3C050600 */  lui     $a1, 0x0600                ## $a1 = 06000000
/* 069E0 8093F6B0 24A51D10 */  addiu   $a1, $a1, 0x1D10           ## $a1 = 06001D10
/* 069E4 8093F6B4 3C06C0A0 */  lui     $a2, 0xC0A0                ## $a2 = C0A00000
/* 069E8 8093F6B8 0C0294D3 */  jal     func_800A534C
/* 069EC 8093F6BC 24840568 */  addiu   $a0, $a0, 0x0568           ## $a0 = 00000568
/* 069F0 8093F6C0 10000010 */  beq     $zero, $zero, .L8093F704
/* 069F4 8093F6C4 86020152 */  lh      $v0, 0x0152($s0)           ## 00000152
.L8093F6C8:
/* 069F8 8093F6C8 8C84C848 */  lw      $a0, %lo(D_8094C848)($a0)
/* 069FC 8093F6CC 3C050600 */  lui     $a1, 0x0600                ## $a1 = 06000000
/* 06A00 8093F6D0 24A517E0 */  addiu   $a1, $a1, 0x17E0           ## $a1 = 060017E0
/* 06A04 8093F6D4 3C06C0A0 */  lui     $a2, 0xC0A0                ## $a2 = C0A00000
/* 06A08 8093F6D8 0C0294D3 */  jal     func_800A534C
/* 06A0C 8093F6DC 24840568 */  addiu   $a0, $a0, 0x0568           ## $a0 = 00000568
/* 06A10 8093F6E0 10000008 */  beq     $zero, $zero, .L8093F704
/* 06A14 8093F6E4 86020152 */  lh      $v0, 0x0152($s0)           ## 00000152
.L8093F6E8:
/* 06A18 8093F6E8 8C84C848 */  lw      $a0, %lo(D_8094C848)($a0)
/* 06A1C 8093F6EC 3C050600 */  lui     $a1, 0x0600                ## $a1 = 06000000
/* 06A20 8093F6F0 24A512A4 */  addiu   $a1, $a1, 0x12A4           ## $a1 = 060012A4
/* 06A24 8093F6F4 3C06C0A0 */  lui     $a2, 0xC0A0                ## $a2 = C0A00000
/* 06A28 8093F6F8 0C0294D3 */  jal     func_800A534C
/* 06A2C 8093F6FC 24840568 */  addiu   $a0, $a0, 0x0568           ## $a0 = 00000568
/* 06A30 8093F700 86020152 */  lh      $v0,


pe Mask = { type: "mask"; value: string };
type Write = { type: "write"; value: bigint; address: number };

type Operation = Mask | Write;

function isMask(o: Operation): o is Mask {
  return o.type === "mask";
}
export function applyMask(mask: string, value: bigint): bigint {
  const setOnes = BigInt("0b" + mask.replace(/X/g, "0"));
  const setZeros = BigInt("0b" + mask.replace(/X/g, "1"));
  let one = value | setOnes;
  let zero = one & setZeros;
  // console.log(setOnes.toString(2), setZeros.toString(2));
  // console.log("one", one.toString(2));
  // console.log("zero", zero.toString(2));
  return zero;
}

const solve: Solver = (filename: string): string => {
  const memory: { [address: number]: bigint } = {};
  let mask = "";
  const x = read(filename)
    .filter((l) => l !== "")
    .map((line) => {
      if (line.includes("mask")) {
        let [, value] = /mask = (.+)$/.exec(line) as RegExpMatchArray;
        return {
          type: "mask",
          value,
        } as Mask;
      } else {
        let [, address, value] = /mem\[(\d+)] = (\d+)/.exec(
          line
        ) as RegExpMatchArray;
        return {
          type: "write",
          address: parseInt(address, 10),
          value: BigInt(parseInt(value, 10)),
        } as Write;
      }
    });

  for (const o of x) {
    if (isMask(o)) {
      mask = o.value;
    } else {
      memory[o.address] = applyMask(mask, o.value);
    }
  }
  // console.log(memory);
  const nonZero = Object.values(memory).reduce((a, b) => a + b);

  return nonZero.toString();
};

export default solve;
export type NamedServiceType = any | any[];
// | string | string[]
// | Function |
// | {
//       name: string;
//   };
export type ServiceType = any;

export type Properties = Record<string, any>;

export type Properties2<P> = {
    [Property in keyof P]: P[Property];
};

export type FilterType = string | Properties;

export interface IActivator {
    /**
     * Called when this bundle is started
     *
     * @param ctx IBundleContext
     */
    start?(ctx: IBundleContext): Promise<void>;

    /**
     * Called when this bundle is stopped
     *
     * @param ctx IBundleContext
     */
    stop?(ctx: IBundleContext): Promise<void>;
}

export interface IModule extends IActivator {
    path: string;
    name: string;
    Activator?: new () => IActivator;
    [key: string]: any;
}

export interface ILoader {
    loadBundle(name: string): Promise<IModule>;
    unloadBundle(name: string): Promise<void>;
}

export interface IDisposable {
    dispose(): void;
}

export type IDisposableLike = () => {} | IDisposable | undefined;

export interface IFramework extends IBundle {
    getProperty<T>(name: string, defaultValue?: T): T;
    getProperties<P extends Properties>(): P;
    hasBundle(bundle: IBundle): boolean;
    getBundle(bundleId: number): IBundle;
    getBundles(): Array<IBundle>;
    installBundle(name: string, autostart: boolean): Promise<IBundle>;
    uninstallBundle(bundle: IBundle): Promise<boolean>;
    startBundle(bundle: IBundle): Promise<void>;
    stopBundle(bundle: IBundle): Promise<void>;
    reloadBundle(bundle: IBundle, autostart: boolean): Promise<void>;

    addServiceListener(
        bundle: IBundle,
        listener: IServiceListener,
        name: NamedServiceType,
        filter: string
    ): IDisposable;


Ausbreitung hindeutet. Ich denke, es wäre logisch, wenn man die Untersuchungen bei den Furbolgs fortsetzen würde. Würdet Ihr wohl eines ihrer Lager aufsuchen und zu mir zurückkehren, falls Ihr dort irgendwelche Anzeichen von Verderbnis entdeckt?",
    ["O"] = "Sucht in Dunkelküste nach einem verderbten Furbolglager und kehrt dann zu Terenthis in Auberdine zurück.",
    ["T"] = "Wie groß ist die Bedrohung?",
  },
  [985] = {
    ["D"] = "Ihr habt Euer Talent im Ausspähen unserer Feinde bereits unter Beweis gestellt, $n. Aber habt Ihr auch das Zeug dazu, sie zu bekämpfen?$B$BNicht alle Abenteurer ziehen ein offenes Gefecht der Kunst der Verstohlenheit und des Ausweichens vor.$B$BWenn Ihr glaubt, der Aufgabe gewachsen zu sein, solltet Ihr Euch das Furbolglager südlich von Auberdine vornehmen. Das stellt momentan die größte Bedrohung für unser Volk dar. Ihr werdet dort ein paar Mitglieder des Schwarzfellstamms finden. Tötet 8 Pfadfinder und 5 Windsprecher und kommt dann zu mir zurück.",
    ["O"] = "Tötet 8 Pfadfinder der Schwarzfelle und 5 Windsprecher und kehrt dann zu Terenthis in Auberdine zurück.",
    ["T"] = "Wie groß ist die Bedrohung?",
  },
  [986] = {
    ["D"] = "$N, Eure Fertigkeiten haben mir bei meinen Bemühungen sehr geholfen. Kann ich es wagen, Euch dennoch erneut zu bitten, Grimmklaue und seinem Meister Volcor zu helfen? Ich könnte Euch dazu einen magischen Umhang anfertigen, mit dem Ihr ungehindert an den Kreaturen Dunkelküstes vorbeigelangt, während Ihr nach ihm sucht.$B$BUm den Umhang anzufertigen, benötige ich fünf Mondpirscherpelze von einer Mondpirschermatriarchin oder einem Mondpirscherpatriarchen, um genügend Material zur Verfügung zu haben. Die Katzen findet Ihr südlich von hier, in der Nähe des Flusses Wildbend, oder noch weiter im Süden, in der Nähe von Ashenvale.",
    ["O"] = "Sucht 5 feine Mondpirscherpelze und bringt sie Terenthis in Auberdine.",
    ["T"] = "Ein verirrter Meister",
  },
  [987] = {
    ["D"] = "",
    ["O"] = "",
    ["T"] = "<UNUSED>",
  },
  [990] = {
    ["D"] = "$N, meine Herrin Raene Wolfrunner erwartet Euch in Astranaar in Ashenvale. Mit Eurer Hilfe könnten wir vielleicht wenigstens eines Teils der Verderbnis Herr werden, die sich dort breit gemacht hat.$B$BGeht von hier aus nach Süden und haltet Euch dicht an der Straße. Wenn Ihr Euch an diese Richtungsangaben haltet, erreicht Ihr problemlos Euer Ziel.",
    ["O"] = "Sucht Raene Wolfrunner in Ashenvale auf.",
    ["T"] = "Marsch nach Ashenvale",
  },
  [991] = {
    ["D"] = "$N, ein alter Freund von mir unterstützt hier in Ashenvale ebenfalls die Schildwachen, aber er ist noch nicht zurückgekehrt.$B$BEr ging einer Spur nach, die zu einem Gegenstand führte, der seiner Meinung nach die Angriffe der Furbolgs auf unser Volk ver


_perp{-diag_dir2[1], diag_dir2[0]};
    std::vector<Vec2f> p{{0, 0}, {width, 0}, {width, depth}, {0, depth}};
    Polyline           p_render;
    for (auto &x : p) p_render.points.push_back(scaled(x));
    res.points[0] = scaled(Vec2f{p[0].x(), p[0].y() + w / sintheta});
    res.points[1] = scaled(Vec2f{p[0] - diag_dir1 * l + diag_dir1_perp * w});
    res.points[2] = scaled(Vec2f{p[0] - diag_dir1 * l - diag_dir1_perp * w});
    res.points[3] = scaled(Vec2f{p[0].x() + w / costheta, p[0].y()});

    res.points[4] = scaled(Vec2f{p[1].x() - w / costheta, p[1].y()});
    res.points[5] = scaled(Vec2f{p[1] - diag_dir2 * l + diag_dir2_perp * w});
    res.points[6] = scaled(Vec2f{p[1] - diag_dir2 * l - diag_dir2_perp * w});
    res.points[7] = scaled(Vec2f{p[1].x(), p[1].y() + w / sintheta});

    res.points[8]  = scaled(Vec2f{p[2].x(), p[2].y() - w / sintheta});
    res.points[9]  = scaled(Vec2f{p[2] + diag_dir1 * l - diag_dir1_perp * w});
    res.points[10] = scaled(Vec2f{p[2] + diag_dir1 * l + diag_dir1_perp * w});
    res.points[11] = scaled(Vec2f{p[2].x() - w / costheta, p[2].y()});

    res.points[12] = scaled(Vec2f{p[3].x() + w / costheta, p[3].y()});
    res.points[13] = scaled(Vec2f{p[3] + diag_dir2 * l - diag_dir2_perp * w});
    res.points[14] = scaled(Vec2f{p[3] + diag_dir2 * l + diag_dir2_perp * w});
    res.points[15] = scaled(Vec2f{p[3].x(), p[3].y() - w / sintheta});
    res.remove_duplicate_points();
    if (fillet_wall) { res = rounding_polygon(res); }
    res.points.shrink_to_fit();
    return res;
}

TriangleMesh WipeTower::its_make_rib_tower(float width, float depth, float height, float rib_length, float rib_width, bool fillet_wall)
{
    TriangleMesh res;
    Polygon      bottom = rib_section(width, depth, rib_length, rib_width, fillet_wall);
    Polygon      top    = rib_section(width, depth, std::sqrt(width * width + depth * depth), rib_width, fillet_wall);
    if (fillet_wall)
        assert(bottom.points.size() == top.points.size());
    int     offset       = bottom.points.size();
    res.its.vertices.reserve(offset * 2);
    if (bottom.area() < scaled(EPSILON) || top.area() < scaled(EPSILON) || bottom.points.size() != top.points.size()) return res;
    auto    faces_bottom = Triangulation::triangulate(bottom);
    auto    faces_top    = Triangulation::triangulate(top);
    res.its.indices.reserve(offset * 2 + faces_bottom.size() + faces_top.size());
    for (auto &t : faces_bottom) res.its.indices.push_back({t[1], t[0], t[


from django.contrib import admin
from django.contrib.auth import get_user_model

from reviews.models import Category, Comment, Genre, Review, Title

User = get_user_model()

class UserAdmin(admin.ModelAdmin):
    list_display = (
        'username',
        'email',
        'role',
        'first_name',
        'last_name',
        'is_staff',
    )
    list_filter = ('role', 'is_staff')
    search_fields = ('username', 'email')
    list_editable = ('role',)
    empty_value_display = '-пусто-'

class CategoryAdmin(admin.ModelAdmin):
    list_display = ('name', 'slug')
    search_fields = ('name', 'slug')
    prepopulated_fields = {'slug': ('name',)}
    list_per_page = 20

class GenreAdmin(admin.ModelAdmin):
    list_display = ('name', 'slug')
    search_fields = ('name', 'slug')
    prepopulated_fields = {'slug': ('name',)}
    list_per_page = 20

class GenreInline(admin.TabularInline):
    model = Title.genre.through
    extra = 1
    verbose_name = 'Жанр'
    verbose_name_plural = 'Жанры'

class TitleAdmin(admin.ModelAdmin):
    list_display = (
        'name',
        'year',
        'category',
        'display_genres',
        'description_short',
    )
    list_filter = ('category', 'genre', 'year')
    search_fields = ('name', 'category__name', 'genre__name')
    inlines = (GenreInline,)
    exclude = ('genre',)
    list_per_page = 20

    def display_genres(self, obj):
        return ', '.join([genre.name for genre in obj.genre.all()])

    display_genres.short_description = 'Жанры'

    def description_short(self, obj):
        return (
            obj.description[:50] + '...'
            if len(obj.description) > 50
            else obj.description
        )

    description_short.short_description = 'Описание'

class ReviewAdmin(admin.ModelAdmin):
    list_display = ('title', 'author', 'score', 'text_short', 'pub_date')
    list_filter = ('score', 'pub_date')
    search_fields = ('text', 'author__username', 'title__name')
    raw_id_fields = ('title', 'author')
    list_per_page = 20

    def text_short(self, obj):
        return obj.text[:100] + '...' if len(obj.text) > 100 else obj.text

    text_short.short_description = 'Текст отзыва'

class CommentAdmin(admin.ModelAdmin):
    list_display = ('review', 'author', 'text_short', 'pub_date')
    search_fields = ('text', 'author__username', 'review__text')
    raw_id_fields = ('review', 'author')
    list_per_page = 20

    def text_short(self, obj):
        return obj.text[:50] + '...' if len(obj.text) > 50 else obj.text

    text_short.short_description = 'Текст комментария'

admin.site.register(Category, CategoryAdmin)
admin.site.register(Genre, GenreAdmin)
admin.site.register(Title, TitleAdmin)
admin.site.register(Review, ReviewAdmin)
admin.site.register(Comment, CommentAdmin)


__all__ = ["db"]


x19, x0
	mov	x0, x30
	bl	_mcount
	ldr	x1, [x19, 2360]
	cbz	x1, .L2790
	ldr	w0, [x19, 244]
	bl	HEVC_ReleaseNAL
	str	xzr, [x19, 2360]
.L2790:
	mov	w0, 0
	ldr	x19, [sp, 16]
	ldp	x29, x30, [sp], 32
	ret
	.size	HEVC_ClearCurrSlice, .-HEVC_ClearCurrSlice
	.global	_mcount
	.align	2
	.p2align 3,,7
	.global	HEVC_ClearCurrNal
	.type	HEVC_ClearCurrNal, %function
HEVC_ClearCurrNal:
	stp	x29, x30, [sp, -32]!
	add	x29, sp, 0
	str	x19, [sp, 16]
	mov	x19, x0
	mov	x0, x30
	bl	_mcount
	mov	x0, x19
	bl	HEVC_ClearCurrSlice
	ldr	x19, [sp, 16]
	ldp	x29, x30, [sp], 32
	ret
	.size	HEVC_ClearCurrNal, .-HEVC_ClearCurrNal
	.global	_mcount
	.align	2
	.p2align 3,,7
	.global	HEVC_ClearAllSlice
	.type	HEVC_ClearAllSlice, %function
HEVC_ClearAllSlice:
	stp	x29, x30, [sp, -48]!
	add	x29, sp, 0
	stp	x19, x20, [sp, 16]
	stp	x21, x22, [sp, 32]
	mov	x21, x0
	mov	x0, x30
	mov	w20, 0
	add	x22, x21, 65536
	bl	_mcount
	ldr	w2, [x21, 160]
	cbz	w2, .L2799
	.p2align 2
.L2802:
	uxtw	x0, w20
	ldr	x1, [x22, 3664]
	lsl	x19, x0, 5
	add	w20, w20, 1
	add	x19, x19, x0, lsl 3
	add	x0, x1, x19
	ldr	x0, [x0, 32]
	mov	x1, x0
	cbz	x0, .L2797
	ldr	w0, [x21, 244]
	bl	HEVC_ReleaseNAL
	ldr	x0, [x22, 3664]
	add	x0, x0, x19
	str	xzr, [x0, 32]
	ldr	w2, [x21, 160]
.L2797:
	cmp	w2, w20
	bhi	.L2802
.L2799:
	strb	wzr, [x21, 9]
	mov	w0, 2
	str	wzr, [x21, 208]
	str	w0, [x21, 172]
	mov	w0, 0
	str	wzr, [x21, 216]
	str	wzr, [x21, 224]
	ldp	x19, x20, [sp, 16]
	ldp	x21, x22, [sp, 32]
	ldp	x29, x30, [sp], 48
	ret
	.size	HEVC_ClearAllSlice, .-HEVC_ClearAllSlice
	.global	_mcount
	.align	2
	.p2align 3,,7
	.global	HEVC_InitDPB
	.type	HEVC_InitDPB, %function
HEVC_InitDPB:
	stp	x29, x30, [sp, -48]!
	add	x29,


-Patterson AFB OH, 1992.

^ Rosenberg, L.B. (1993). "Virtual Fixtures: Perceptual Overlays for Telerobotic Manipulation". In Proc. of the IEEE Annual Int. Symposium on Virtual Reality (1993): pp. 76–82.

^ "Arcade Heroes Sega's Wonderful Simulation Games Over The Years – Arcade Heroes". Arcade Heroes. 2013-06-06. Retrieved 20 October 2015.<link href="mw-data:TemplateStyles:r951705291" rel="mw-deduplicated-inline-style"/>

^ "System 16 – Sega Medium Scale Attractions Hardware (Sega)". system16.com. Retrieved 20 October 2015.<link href="mw-data:TemplateStyles:r951705291" rel="mw-deduplicated-inline-style"/>

^


peof undefined) {
        if (!window.SUNEDITOR_LANG) {
            Object.defineProperty(window, 'SUNEDITOR_LANG', {
                enumerable: true,
                writable: false,
                configurable: false,
                value: {}
            });
        }

        Object.defineProperty(window.SUNEDITOR_LANG, 'ur', {
            enumerable: true,
            writable: true,
            configurable: true,
            value: lang
        });
    }

    return lang;
}));/*
 * wysiwyg web editor
 *
 * suneditor.js
 * Copyright 2017 JiHong Lee.
 * MIT license.
 */
'use strict';

(function (global, factory) {
    if (typeof module === 'object' && typeof module.exports === 'object') {
        module.exports = global.document ?
            factory(global, true) :
            function (w) {
                if (!w.document) {
                    throw new Error('SUNEDITOR_LANG a window with a document');
                }
                return factory(w);
            };
    } else {
        factory(global);
    }
}(typeof window !== 'undefined' ? window : this, function (window, noGlobal) {
    const lang = {
        code: 'lv',
        toolbar: {
            default: 'Noklusējuma',
            save: 'Saglabāt',
            font: 'Fonts',
            formats: 'Formāti',
            fontSize: 'Fonta lielums',
            bold: 'Treknraksts',
            underline: 'Pasvītrot',
            italic: 'Slīpraksts',
            strike: 'Pārsvītrojums',
            subscript: 'Apakšraksts',
            superscript: 'Augšraksts',
            removeFormat: 'Noņemt formātu',
            fontColor: 'Fonta krāsa',
            hiliteColor: 'Teksta iezīmēšanas krāsa',
            indent: 'Palielināt atkāpi',
            outdent: 'Samazināt atkāpi',
            align: 'Izlīdzināt',
            alignLeft: 'Līdzināt pa kreisi',
            alignRight: 'Līdzināt pa labi',
            alignCenter: 'Centrēt',
            alignJustify: 'Taisnot',
            list: 'Saraksts',
            orderList: 'Numerācija',
            unorderList: 'Aizzimes',
            horizontalRule: 'Horizontāla līnija',
            hr_solid: 'Ciets',
            hr_dotted: 'Punktiņš',
            hr_dashed: 'Braša',
            table: 'Tabula',
            link: 'Saite',
            math: 'Matemātika',
            image: 'Attēls',
            video: 'Video',
            audio: 'Audio',
            fullScreen: 'Pilnekrāna režīms',
            showBlocks: 'Parādit blokus',
            codeView: 'Koda skats',
            undo: 'Atsaukt',
            redo: 'Atkārtot',
            preview: 'Priekšskatījums',
            print: 'Drukāt',
            tag_p: 'Paragrāfs',
            tag_div: 'Normāli (DIV)',
            tag_