hexsha stringlengths 40 40 | size int64 5 1.05M | ext stringclasses 98
values | lang stringclasses 21
values | max_stars_repo_path stringlengths 3 945 | max_stars_repo_name stringlengths 4 118 | max_stars_repo_head_hexsha stringlengths 40 78 | max_stars_repo_licenses listlengths 1 10 | max_stars_count int64 1 368k ⌀ | max_stars_repo_stars_event_min_datetime stringlengths 24 24 ⌀ | max_stars_repo_stars_event_max_datetime stringlengths 24 24 ⌀ | max_issues_repo_path stringlengths 3 945 | max_issues_repo_name stringlengths 4 118 | max_issues_repo_head_hexsha stringlengths 40 78 | max_issues_repo_licenses listlengths 1 10 | max_issues_count int64 1 134k ⌀ | max_issues_repo_issues_event_min_datetime stringlengths 24 24 ⌀ | max_issues_repo_issues_event_max_datetime stringlengths 24 24 ⌀ | max_forks_repo_path stringlengths 3 945 | max_forks_repo_name stringlengths 4 135 | max_forks_repo_head_hexsha stringlengths 40 78 | max_forks_repo_licenses listlengths 1 10 | max_forks_count int64 1 105k ⌀ | max_forks_repo_forks_event_min_datetime stringlengths 24 24 ⌀ | max_forks_repo_forks_event_max_datetime stringlengths 24 24 ⌀ | content stringlengths 5 1.05M | avg_line_length float64 1 1.03M | max_line_length int64 2 1.03M | alphanum_fraction float64 0 1 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
64d6cea235efbf895987581afc82f14882b24458 | 2,701 | java | Java | app/src/main/java/com/mooc/ppjoke/utils/NavGraphBuilder.java | Petermaodan/ppjoke | a6dbabc9a845cb2cf70b8265b13f7fa6351d77ea | [
"Apache-2.0"
] | 1 | 2021-06-09T09:27:53.000Z | 2021-06-09T09:27:53.000Z | app/src/main/java/com/mooc/ppjoke/utils/NavGraphBuilder.java | Petermaodan/ppjoke | a6dbabc9a845cb2cf70b8265b13f7fa6351d77ea | [
"Apache-2.0"
] | null | null | null | app/src/main/java/com/mooc/ppjoke/utils/NavGraphBuilder.java | Petermaodan/ppjoke | a6dbabc9a845cb2cf70b8265b13f7fa6351d77ea | [
"Apache-2.0"
] | null | null | null | package com.mooc.ppjoke.utils;
import android.content.ComponentName;
import androidx.fragment.app.FragmentActivity;
import androidx.navigation.ActivityNavigator;
import androidx.navigation.NavController;
import androidx.navigation.NavGraph;
import androidx.navigation.NavGraphNavigator;
import androidx.navigation.NavigatorProvider;
import androidx.navigation.fragment.FragmentNavigator;
import com.mooc.libcommon.global.AppGlobals;
import com.mooc.ppjoke.FixFragmentNavigator;
import com.mooc.ppjoke.model.Destination;
import java.util.HashMap;
public class NavGraphBuilder {
//需要和NavController相关联,所以该方法的参数就为此
//需要外部传入activity和containId
public static void build(NavController controller,FragmentActivity activity,int containerId){
//通过响应的Navigate创建相应的页面节点
NavigatorProvider provider = controller.getNavigatorProvider();
//分别获取FragmentNavigator和ActivityNavigator对象
// FragmentNavigator fragmentNavigator = provider.getNavigator(FragmentNavigator.class);
//使用自建的导航器FixFragmentNavigator
FixFragmentNavigator fragmentNavigator=new FixFragmentNavigator(activity,activity.getSupportFragmentManager(),containerId);
//创建完成之后需要添加到NavigatorProvider的hashMap中去
provider.addNavigator(fragmentNavigator);
ActivityNavigator activityNavigator=provider.getNavigator(ActivityNavigator.class);
//后面的数据要添加到改NavGraph中
NavGraph navGraph=new NavGraph(new NavGraphNavigator(provider));
HashMap<String, Destination> destConfig=AppConfig.getDestConfig();
for (Destination value : destConfig.values()) {
if (value.isFragment){
FragmentNavigator.Destination destination=fragmentNavigator.createDestination();
//向destination中填相应的字段
destination.setClassName(value.className);
destination.setId(value.id);
destination.addDeepLink(value.pageUrl);
navGraph.addDestination(destination);
}else {
ActivityNavigator.Destination destination=activityNavigator.createDestination();
destination.setId(value.id);
destination.addDeepLink(value.pageUrl);
destination.setComponentName(new ComponentName(AppGlobals.getApplication().getPackageName(),value.className));
navGraph.addDestination(destination);
}
//如果value是默认启动页
if (value.asStarter){
navGraph.setStartDestination(value.id);
}
}
//将navGraph赋值给controller
controller.setGraph(navGraph);
}
}
| 37.513889 | 132 | 0.701222 |
02e7fd625375e4dd802e507b8842403878e7f240 | 194 | kt | Kotlin | event/src/api/kotlin/su/jfdev/anci/event/EventLoop.kt | anrelic/Anci-OSS | bf11562be3274d14396630ad5eb6258f58d8b33b | [
"MIT"
] | null | null | null | event/src/api/kotlin/su/jfdev/anci/event/EventLoop.kt | anrelic/Anci-OSS | bf11562be3274d14396630ad5eb6258f58d8b33b | [
"MIT"
] | null | null | null | event/src/api/kotlin/su/jfdev/anci/event/EventLoop.kt | anrelic/Anci-OSS | bf11562be3274d14396630ad5eb6258f58d8b33b | [
"MIT"
] | null | null | null | package su.jfdev.anci.event
interface EventLoop {
fun <E: Any> handle(subscribers: Collection<(E) -> Unit>, event: E)
fun <E: Any> sync(subscribers: Collection<(E) -> Unit>, event: E)
} | 32.333333 | 71 | 0.664948 |
8b989448b15ef95c8bc41431e4159b44c0ea33db | 1,551 | sql | SQL | parte001/ex145_empleados_campos_default_columnas.sql | Fhernd/MySQL-Ejercicios | fe899fc5264e0a9f5f80e0a3665fdaed02e034e2 | [
"MIT"
] | 6 | 2021-06-18T23:15:37.000Z | 2022-03-20T11:53:27.000Z | parte001/ex145_empleados_campos_default_columnas.sql | Fhernd/MySQL-Ejercicios | fe899fc5264e0a9f5f80e0a3665fdaed02e034e2 | [
"MIT"
] | null | null | null | parte001/ex145_empleados_campos_default_columnas.sql | Fhernd/MySQL-Ejercicios | fe899fc5264e0a9f5f80e0a3665fdaed02e034e2 | [
"MIT"
] | 2 | 2021-07-04T05:33:49.000Z | 2022-03-27T03:25:35.000Z | -- 1. Elimine la tabla, si existe:
DROP TABLE IF EXISTS empleados;
-- 2. Cree la tabla:
CREATE TABLE empleados(
nombre VARCHAR(20),
documento CHAR(8) NOT NULL,
sexo CHAR(1),
domicilio VARCHAR(30),
fechaingreso DATE NOT NULL,
fechanacimiento DATE,
sueldo DECIMAL(5,2) unsigned NOT NULL
);
DESCRIBE empleados;
-- 3. Agregue los siguientes registros para ver cómo guarda MySQL los valores no ingresados:
INSERT INTO empleados (nombre,documento,sexo)
VALUES('Marcela Medina','22333444','f');
INSERT INTO empleados (domicilio,fechaingreso)
VALUES('Avellaneda 200','2005-08-16');
INSERT INTO empleados (fechanacimiento,sueldo)
VALUES('1970-09-26',500.90);
-- 4- Seleccione todos los datos de los empleados para ver cómo guardó MySQL los valores no ingresados.
-- En el primer registro ingresado, en los campos "domicilio" y "fechanacimiento" ingresará "null",
-- porque ninguno de los campos están definidos como "NOT NULL"; en el campo "fechaingreso"
-- almacena "000-00-00" ya que dicho campo no admite valores nulos; en el campo "sueldo" guarda "0.00"
-- porque el campo no admite valores nulos. En el segundo registro ingresado se almacena "null" en los
-- campos "nombre", "sexo" y "fechanacimiento" pues estos campos admiten valores "null"; en el
-- campo "documento", que no admite valores nulos, se almacena una cadena vacía. En el tercer registro
-- guarda "null" en los campos "nombre", "sexo" y "domicilio", ya que los permiten; en el
-- campo "documento", almacena una cadena vacía.
SELECT * FROM empleados;
| 40.815789 | 103 | 0.738233 |
2f26a83260fa558c83dbd89d080baa0cf38aaa82 | 685 | php | PHP | resources/views/kolicinaCipke/form.blade.php | msoldo1/LT | 9b4e5fa9a75a1c2a526351e5a3e52e5937242865 | [
"MIT"
] | null | null | null | resources/views/kolicinaCipke/form.blade.php | msoldo1/LT | 9b4e5fa9a75a1c2a526351e5a3e52e5937242865 | [
"MIT"
] | null | null | null | resources/views/kolicinaCipke/form.blade.php | msoldo1/LT | 9b4e5fa9a75a1c2a526351e5a3e52e5937242865 | [
"MIT"
] | null | null | null | <div class="form-group">
<div class="row">
<div class="col">
<label for="nazivCipke">Naziv Cipke:</label>
<p>{{ $cipka->nazivCipke }}</p>
</div>
<div class="col">
<label for="cipka_id">Id Cipke:</label>
<input type="text" name="cipka_id" class="form-control" value="{{ $cipka->id }}" readonly>
</div>
</div>
</div>
<div class="form-group">
<label for="kolicina" >Unesite količinu cipke:</label>
<input type="text" name="kolicina" class="form-control" value="{{ old('kolicina') ?? $kolicina->kolicina }}">
<div class="alert-danger">{{ $errors->first("kolicina") }}</div>
</div>
| 26.346154 | 113 | 0.548905 |
2690ec4995337603d35405f4c209fb81c176b43b | 475 | java | Java | checkers/src/com/eddienicole/checkers/AbstractAI.java | power-cosmic/cosc561_checkers | 5ae514f3fd33740ad1ba8b014c2f0d0ad7315f8f | [
"MIT"
] | null | null | null | checkers/src/com/eddienicole/checkers/AbstractAI.java | power-cosmic/cosc561_checkers | 5ae514f3fd33740ad1ba8b014c2f0d0ad7315f8f | [
"MIT"
] | null | null | null | checkers/src/com/eddienicole/checkers/AbstractAI.java | power-cosmic/cosc561_checkers | 5ae514f3fd33740ad1ba8b014c2f0d0ad7315f8f | [
"MIT"
] | null | null | null | package com.eddienicole.checkers;
import java.util.ArrayList;
public abstract class AbstractAI extends AbstractPlayer {
public AbstractAI(boolean isRed) {
super(isRed);
}
public abstract MoveInterface computeMove(
ArrayList<MoveInterface> legalMoves);
public abstract double evaluateBoard(
ImaginaryBoard theImaginaryBoardToReturn);
@Override
public MoveInterface getMove(ArrayList<MoveInterface> legalMoves) {
return this.computeMove(legalMoves);
}
}
| 21.590909 | 68 | 0.797895 |
c3c6c0fac86bf59578d0b2949bc4f5cf6f42f0c7 | 1,508 | swift | Swift | RxSonosLib/iOS Demo App/Presentation/More/MoreViewController.swift | nicktrienensfuzz/RxSonosLib | 884754cc4865079ed46ba6cf30bf9b79185c0ece | [
"Apache-2.0"
] | 10 | 2018-12-31T04:48:46.000Z | 2021-11-23T21:02:37.000Z | RxSonosLib/iOS Demo App/Presentation/More/MoreViewController.swift | nicktrienensfuzz/RxSonosLib | 884754cc4865079ed46ba6cf30bf9b79185c0ece | [
"Apache-2.0"
] | 4 | 2018-06-18T14:03:43.000Z | 2020-03-05T09:46:07.000Z | RxSonosLib/iOS Demo App/Presentation/More/MoreViewController.swift | nicktrienensfuzz/RxSonosLib | 884754cc4865079ed46ba6cf30bf9b79185c0ece | [
"Apache-2.0"
] | 8 | 2018-06-18T13:58:13.000Z | 2021-07-06T09:53:56.000Z | //
// MoreViewController.swift
// iOS Demo App
//
// Created by Stefan Renne on 10/04/2018.
// Copyright © 2018 Uberweb. All rights reserved.
//
import UIKit
import RxSwift
import RxCocoa
class MoreViewController: UIViewController {
internal var router: MoreRouter!
@IBOutlet var table: UITableView!
let disposeBag = DisposeBag()
override func viewDidLoad() {
super.viewDidLoad()
title = "More"
setupTableViewItems()
setupCellTapHandling()
}
override var preferredStatusBarStyle: UIStatusBarStyle {
return UIStatusBarStyle.lightContent
}
func setupTableViewItems() {
table.register(UINib(nibName: String(describing: MoreTableViewCell.self), bundle: Bundle.main), forCellReuseIdentifier: MoreTableViewCell.identifier)
var moreItems = [MoreType]()
moreItems.append(.musicproviders)
Observable
.just(moreItems)
.bind(to: table.rx.items(cellIdentifier: MoreTableViewCell.identifier, cellType: MoreTableViewCell.self)) { (_, type, cell) in
cell.model = MoreViewModel(type: type)
}
.disposed(by: disposeBag)
}
func setupCellTapHandling() {
table
.rx
.modelSelected(MoreType.self)
.subscribe(onNext: { [weak self] (type) in
self?.router.didSelect(type: type)
})
.disposed(by: disposeBag)
}
}
| 26.928571 | 157 | 0.614721 |
2925e2d4b395bf3bea52e885813871f3b7985632 | 977 | py | Python | experiment/merge_tmaps.py | andreagrusso/rtRSA | 7878772fd9415f6dbedbede2a8aa8d2b8f1de7cd | [
"MIT"
] | 2 | 2021-11-17T12:20:28.000Z | 2022-01-21T12:56:29.000Z | experiment/merge_tmaps.py | andreagrusso/rtRSA | 7878772fd9415f6dbedbede2a8aa8d2b8f1de7cd | [
"MIT"
] | null | null | null | experiment/merge_tmaps.py | andreagrusso/rtRSA | 7878772fd9415f6dbedbede2a8aa8d2b8f1de7cd | [
"MIT"
] | null | null | null | # -*- coding: utf-8 -*-
"""
Created on Mon Aug 31 14:20:30 2020
@author: Andrea Gerardo Russo, Biomedical Engineer
PhD candidate in Neuroscience
University of Salerno, Fisciano, Italy
"""
from rtrsa import utils
from tkinter import filedialog
import os, glob
name = input('Insert name of the newly created rtRSA object: ')
metric = input('Insert name of the metric to use for the RSA (pearson, euclidean, mean_diff): ')
if not metric:
metric ='pearson'
single_maps = filedialog.askdirectory(title='Select the directory where the single t-values maps are')
merged_maps = filedialog.askdirectory(title='Select the output directory')
max_comp = len(glob.glob(os.path.join(single_maps,'*.tvals')))-1
n_comp = int(input('Insert the number of dimension of the RS (min 2, max '+ str(max_comp) + '): '))
if not n_comp:
metric = 2
out_name = input('Insert name of the output: ')
utils.merge_tmaps(name,metric,n_comp,single_maps,merged_maps,out_name)
| 23.829268 | 102 | 0.725691 |
6ba91d9210ad866b541f0223cbabdfd8ce47080f | 9,711 | h | C | src/sdk/smsdk_ext.h | Dreae/sm-ext-rpc | 41f633447c3fc5d7b035a6ae475e23e707d5e9fa | [
"Apache-2.0"
] | null | null | null | src/sdk/smsdk_ext.h | Dreae/sm-ext-rpc | 41f633447c3fc5d7b035a6ae475e23e707d5e9fa | [
"Apache-2.0"
] | 3 | 2016-10-11T20:05:34.000Z | 2016-10-17T04:07:40.000Z | src/sdk/smsdk_ext.h | Dreae/sm-ext-rpc | 41f633447c3fc5d7b035a6ae475e23e707d5e9fa | [
"Apache-2.0"
] | null | null | null | /**
* vim: set ts=4 :
* =============================================================================
* SourceMod Base Extension Code
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
* =============================================================================
*
* This program is free software; you can redistribute it and/or modify it under
* the terms of the GNU General Public License, version 3.0, as published by the
* Free Software Foundation.
*
* 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 <http://www.gnu.org/licenses/>.
*
* As a special exception, AlliedModders LLC gives you permission to link the
* code of this program (as well as its derivative works) to "Half-Life 2," the
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
* by the Valve Corporation. You must obey the GNU General Public License in
* all respects for all other code used. Additionally, AlliedModders LLC grants
* this exception to all derivative works. AlliedModders LLC defines further
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
* or <http://www.sourcemod.net/license.php>.
*
* Version: $Id$
*/
#ifndef _INCLUDE_SOURCEMOD_EXTENSION_BASESDK_H_
#define _INCLUDE_SOURCEMOD_EXTENSION_BASESDK_H_
/**
* @file smsdk_ext.h
* @brief Contains wrappers for making Extensions easier to write.
*/
#include "smsdk_config.h"
#include <IExtensionSys.h>
#include <IHandleSys.h>
#include <sp_vm_api.h>
#include <sm_platform.h>
#include <ISourceMod.h>
#if defined SMEXT_ENABLE_FORWARDSYS
#include <IForwardSys.h>
#endif //SMEXT_ENABLE_FORWARDSYS
#if defined SMEXT_ENABLE_PLAYERHELPERS
#include <IPlayerHelpers.h>
#endif //SMEXT_ENABLE_PlAYERHELPERS
#if defined SMEXT_ENABLE_DBMANAGER
#include <IDBDriver.h>
#endif //SMEXT_ENABLE_DBMANAGER
#if defined SMEXT_ENABLE_GAMECONF
#include <IGameConfigs.h>
#endif
#if defined SMEXT_ENABLE_MEMUTILS
#include <IMemoryUtils.h>
#endif
#if defined SMEXT_ENABLE_GAMEHELPERS
#include <IGameHelpers.h>
#endif
#if defined SMEXT_ENABLE_TIMERSYS
#include <ITimerSystem.h>
#endif
#if defined SMEXT_ENABLE_ADTFACTORY
#include <IADTFactory.h>
#endif
#if defined SMEXT_ENABLE_THREADER
#include <IThreader.h>
#endif
#if defined SMEXT_ENABLE_LIBSYS
#include <ILibrarySys.h>
#endif
#if defined SMEXT_ENABLE_PLUGINSYS
#include <IPluginSys.h>
#endif
#if defined SMEXT_CONF_METAMOD
#include <ISmmPlugin.h>
#include <eiface.h>
#endif
#if !defined METAMOD_PLAPI_VERSION
#include <metamod_wrappers.h>
#endif
using namespace SourceMod;
using namespace SourcePawn;
class SDKExtension :
#if defined SMEXT_CONF_METAMOD
public ISmmPlugin,
#endif
public IExtensionInterface
{
public:
/** Constructor */
SDKExtension();
public:
/**
* @brief This is called after the initial loading sequence has been processed.
*
* @param error Error message buffer.
* @param maxlength Size of error message buffer.
* @param late Whether or not the module was loaded after map load.
* @return True to succeed loading, false to fail.
*/
virtual bool SDK_OnLoad(char *error, size_t maxlength, bool late);
/**
* @brief This is called right before the extension is unloaded.
*/
virtual void SDK_OnUnload();
/**
* @brief This is called once all known extensions have been loaded.
*/
virtual void SDK_OnAllLoaded();
/**
* @brief Called when the pause state is changed.
*/
virtual void SDK_OnPauseChange(bool paused);
#if defined SMEXT_CONF_METAMOD
/**
* @brief Called when Metamod is attached, before the extension version is called.
*
* @param error Error buffer.
* @param maxlength Maximum size of error buffer.
* @param late Whether or not Metamod considers this a late load.
* @return True to succeed, false to fail.
*/
virtual bool SDK_OnMetamodLoad(ISmmAPI *ismm, char *error, size_t maxlength, bool late);
/**
* @brief Called when Metamod is detaching, after the extension version is called.
* NOTE: By default this is blocked unless sent from SourceMod.
*
* @param error Error buffer.
* @param maxlength Maximum size of error buffer.
* @return True to succeed, false to fail.
*/
virtual bool SDK_OnMetamodUnload(char *error, size_t maxlength);
/**
* @brief Called when Metamod's pause state is changing.
* NOTE: By default this is blocked unless sent from SourceMod.
*
* @param paused Pause state being set.
* @param error Error buffer.
* @param maxlength Maximum size of error buffer.
* @return True to succeed, false to fail.
*/
virtual bool SDK_OnMetamodPauseChange(bool paused, char *error, size_t maxlength);
#endif
public: //IExtensionInterface
virtual bool OnExtensionLoad(IExtension *me, IShareSys *sys, char *error, size_t maxlength, bool late);
virtual void OnExtensionUnload();
virtual void OnExtensionsAllLoaded();
/** Returns whether or not this is a Metamod-based extension */
virtual bool IsMetamodExtension();
/**
* @brief Called when the pause state changes.
*
* @param state True if being paused, false if being unpaused.
*/
virtual void OnExtensionPauseChange(bool state);
/** Returns name */
virtual const char *GetExtensionName();
/** Returns URL */
virtual const char *GetExtensionURL();
/** Returns log tag */
virtual const char *GetExtensionTag();
/** Returns author */
virtual const char *GetExtensionAuthor();
/** Returns version string */
virtual const char *GetExtensionVerString();
/** Returns description string */
virtual const char *GetExtensionDescription();
/** Returns date string */
virtual const char *GetExtensionDateString();
#if defined SMEXT_CONF_METAMOD
public: //ISmmPlugin
/** Called when the extension is attached to Metamod. */
virtual bool Load(PluginId id, ISmmAPI *ismm, char *error, size_t maxlength, bool late);
/** Returns the author to MM */
virtual const char *GetAuthor();
/** Returns the name to MM */
virtual const char *GetName();
/** Returns the description to MM */
virtual const char *GetDescription();
/** Returns the URL to MM */
virtual const char *GetURL();
/** Returns the license to MM */
virtual const char *GetLicense();
/** Returns the version string to MM */
virtual const char *GetVersion();
/** Returns the date string to MM */
virtual const char *GetDate();
/** Returns the logtag to MM */
virtual const char *GetLogTag();
/** Called on unload */
virtual bool Unload(char *error, size_t maxlength);
/** Called on pause */
virtual bool Pause(char *error, size_t maxlength);
/** Called on unpause */
virtual bool Unpause(char *error, size_t maxlength);
private:
bool m_SourceMMLoaded;
bool m_WeAreUnloaded;
bool m_WeGotPauseChange;
#endif
};
extern SDKExtension *g_pExtensionIface;
extern IExtension *myself;
extern IShareSys *g_pShareSys;
extern IShareSys *sharesys; /* Note: Newer name */
extern ISourceMod *g_pSM;
extern ISourceMod *smutils; /* Note: Newer name */
/* Optional interfaces are below */
#if defined SMEXT_ENABLE_FORWARDSYS
extern IForwardManager *g_pForwards;
extern IForwardManager *forwards; /* Note: Newer name */
#endif //SMEXT_ENABLE_FORWARDSYS
#if defined SMEXT_ENABLE_HANDLESYS
extern IHandleSys *g_pHandleSys;
extern IHandleSys *handlesys; /* Note: Newer name */
#endif //SMEXT_ENABLE_HANDLESYS
#if defined SMEXT_ENABLE_PLAYERHELPERS
extern IPlayerManager *playerhelpers;
#endif //SMEXT_ENABLE_PLAYERHELPERS
#if defined SMEXT_ENABLE_DBMANAGER
extern IDBManager *dbi;
#endif //SMEXT_ENABLE_DBMANAGER
#if defined SMEXT_ENABLE_GAMECONF
extern IGameConfigManager *gameconfs;
#endif //SMEXT_ENABLE_DBMANAGER
#if defined SMEXT_ENABLE_MEMUTILS
extern IMemoryUtils *memutils;
#endif
#if defined SMEXT_ENABLE_GAMEHELPERS
extern IGameHelpers *gamehelpers;
#endif
#if defined SMEXT_ENABLE_TIMERSYS
extern ITimerSystem *timersys;
#endif
#if defined SMEXT_ENABLE_ADTFACTORY
extern IADTFactory *adtfactory;
#endif
#if defined SMEXT_ENABLE_THREADER
extern IThreader *threader;
#endif
#if defined SMEXT_ENABLE_LIBSYS
extern ILibrarySys *libsys;
#endif
#if defined SMEXT_ENABLE_PLUGINSYS
extern SourceMod::IPluginManager *plsys;
#endif
#if defined SMEXT_CONF_METAMOD
PLUGIN_GLOBALVARS();
extern IVEngineServer *engine;
extern IServerGameDLL *gamedll;
#endif
/** Creates a SourceMod interface macro pair */
#define SM_MKIFACE(name) SMINTERFACE_##name##_NAME, SMINTERFACE_##name##_VERSION
/** Automates retrieving SourceMod interfaces */
#define SM_GET_IFACE(prefix, addr) \
if (!g_pShareSys->RequestInterface(SM_MKIFACE(prefix), myself, (SMInterface **)&addr)) \
{ \
if (error != NULL && maxlength) \
{ \
size_t len = snprintf(error, maxlength, "Could not find interface: %s", SMINTERFACE_##prefix##_NAME); \
if (len >= maxlength) \
{ \
error[maxlength - 1] = '\0'; \
} \
} \
return false; \
}
/** Automates retrieving SourceMod interfaces when needed outside of SDK_OnLoad() */
#define SM_GET_LATE_IFACE(prefix, addr) \
g_pShareSys->RequestInterface(SM_MKIFACE(prefix), myself, (SMInterface **)&addr)
/** Validates a SourceMod interface pointer */
#define SM_CHECK_IFACE(prefix, addr) \
if (!addr) \
{ \
if (error != NULL && maxlength) \
{ \
size_t len = snprintf(error, maxlength, "Could not find interface: %s", SMINTERFACE_##prefix##_NAME); \
if (len >= maxlength) \
{ \
error[maxlength - 1] = '\0'; \
} \
} \
return false; \
}
#endif // _INCLUDE_SOURCEMOD_EXTENSION_BASESDK_H_
| 31.22508 | 106 | 0.731439 |
6064637b56dc41e8dce9e866224a4d631b0c29e3 | 343 | asm | Assembly | libsrc/adt/linkedlist/adt_ListConcat.asm | meesokim/z88dk | 5763c7778f19a71d936b3200374059d267066bb2 | [
"ClArtistic"
] | null | null | null | libsrc/adt/linkedlist/adt_ListConcat.asm | meesokim/z88dk | 5763c7778f19a71d936b3200374059d267066bb2 | [
"ClArtistic"
] | null | null | null | libsrc/adt/linkedlist/adt_ListConcat.asm | meesokim/z88dk | 5763c7778f19a71d936b3200374059d267066bb2 | [
"ClArtistic"
] | null | null | null | ; void adt_ListConcat(struct adt_List *list1, struct sp_List *list2)
; CALLER linkage for function pointers
PUBLIC adt_ListConcat
EXTERN adt_ListConcat_callee
EXTERN ASMDISP_ADT_LISTCONCAT_CALLEE
.adt_ListConcat
pop bc
pop hl
pop de
push de
push hl
push bc
jp adt_ListConcat_callee + ASMDISP_ADT_LISTCONCAT_CALLEE
| 18.052632 | 68 | 0.781341 |
d1c10ffdcb38977c2bce0ccb1bdbdc91870679ec | 139 | sql | SQL | campscrape/schema.sql | jafow/campscrape | faf140e08cff0e37c5f1b314121cd78ba2d40d00 | [
"Apache-2.0"
] | null | null | null | campscrape/schema.sql | jafow/campscrape | faf140e08cff0e37c5f1b314121cd78ba2d40d00 | [
"Apache-2.0"
] | null | null | null | campscrape/schema.sql | jafow/campscrape | faf140e08cff0e37c5f1b314121cd78ba2d40d00 | [
"Apache-2.0"
] | null | null | null | create table if not exists messages (
id INTEGER PRIMARY KEY AUTOINCREMENT,
content BYTES NOT NULL,
created_at TEXT NOT NULL
)
| 23.166667 | 41 | 0.733813 |
e80dd60a1183b8e6e7a37328b76b27a9afc5dd31 | 20,407 | kt | Kotlin | kmath-optimization/src/commonMain/tmp/minuit/MnUserParameterState.kt | ivandev0/kmath | 8974164ec05dcfa5feab830cfa8223291e1dbb79 | [
"ECL-2.0",
"Apache-2.0"
] | 34 | 2018-04-23T03:37:49.000Z | 2019-02-19T16:19:30.000Z | kmath-optimization/src/commonMain/tmp/minuit/MnUserParameterState.kt | ivandev0/kmath | 8974164ec05dcfa5feab830cfa8223291e1dbb79 | [
"ECL-2.0",
"Apache-2.0"
] | 34 | 2018-04-22T13:29:45.000Z | 2019-02-19T21:36:48.000Z | kmath-optimization/src/commonMain/tmp/minuit/MnUserParameterState.kt | ivandev0/kmath | 8974164ec05dcfa5feab830cfa8223291e1dbb79 | [
"ECL-2.0",
"Apache-2.0"
] | 7 | 2018-05-01T15:08:41.000Z | 2019-02-08T05:33:22.000Z | /*
* Copyright 2015 Alexander Nozik.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package ru.inr.mass.minuit
import ru.inr.mass.minuit.*
/**
* The class MnUserParameterState contains the MnUserParameters and the
* MnUserCovariance. It can be created on input by the user, or by MINUIT itself
* as user representable format of the result of the minimization.
*
* @version $Id$
* @author Darksnake
*/
class MnUserParameterState {
private var theCovariance: MnUserCovariance
private var theCovarianceValid = false
private var theEDM = 0.0
private var theFVal = 0.0
private var theGCCValid = false
private var theGlobalCC: MnGlobalCorrelationCoeff? = null
private var theIntCovariance: MnUserCovariance
private var theIntParameters: MutableList<Double>
private var theNFcn = 0
private var theParameters: MnUserParameters
private var theValid: Boolean
internal constructor() {
theValid = false
theCovarianceValid = false
theParameters = MnUserParameters()
theCovariance = MnUserCovariance()
theIntParameters = java.util.ArrayList<Double>()
theIntCovariance = MnUserCovariance()
}
private constructor(other: MnUserParameterState) {
theValid = other.theValid
theCovarianceValid = other.theCovarianceValid
theGCCValid = other.theGCCValid
theFVal = other.theFVal
theEDM = other.theEDM
theNFcn = other.theNFcn
theParameters = other.theParameters.copy()
theCovariance = other.theCovariance
theGlobalCC = other.theGlobalCC
theIntParameters = java.util.ArrayList<Double>(other.theIntParameters)
theIntCovariance = other.theIntCovariance.copy()
}
/**
* construct from user parameters (before minimization)
* @param par
* @param err
*/
internal constructor(par: DoubleArray, err: DoubleArray) {
theValid = true
theParameters = MnUserParameters(par, err)
theCovariance = MnUserCovariance()
theGlobalCC = MnGlobalCorrelationCoeff()
theIntParameters = java.util.ArrayList<Double>(par.size)
for (i in par.indices) {
theIntParameters.add(par[i])
}
theIntCovariance = MnUserCovariance()
}
internal constructor(par: MnUserParameters) {
theValid = true
theParameters = par
theCovariance = MnUserCovariance()
theGlobalCC = MnGlobalCorrelationCoeff()
theIntParameters = java.util.ArrayList(par.variableParameters())
theIntCovariance = MnUserCovariance()
val i = 0
for (ipar in par.parameters()) {
if (ipar.isConst() || ipar.isFixed()) {
continue
}
if (ipar.hasLimits()) {
theIntParameters.add(ext2int(ipar.number(), ipar.value()))
} else {
theIntParameters.add(ipar.value())
}
}
}
/**
* construct from user parameters + covariance (before minimization)
* @param nrow
* @param cov
*/
internal constructor(par: DoubleArray, cov: DoubleArray, nrow: Int) {
theValid = true
theCovarianceValid = true
theCovariance = MnUserCovariance(cov, nrow)
theGlobalCC = MnGlobalCorrelationCoeff()
theIntParameters = java.util.ArrayList<Double>(par.size)
theIntCovariance = MnUserCovariance(cov, nrow)
val err = DoubleArray(par.size)
for (i in par.indices) {
assert(theCovariance[i, i] > 0.0)
err[i] = sqrt(theCovariance[i, i])
theIntParameters.add(par[i])
}
theParameters = MnUserParameters(par, err)
assert(theCovariance.nrow() === variableParameters())
}
internal constructor(par: DoubleArray, cov: MnUserCovariance) {
theValid = true
theCovarianceValid = true
theCovariance = cov
theGlobalCC = MnGlobalCorrelationCoeff()
theIntParameters = java.util.ArrayList<Double>(par.size)
theIntCovariance = cov.copy()
require(!(theCovariance.nrow() !== variableParameters())) { "Bad covariance size" }
val err = DoubleArray(par.size)
for (i in par.indices) {
require(theCovariance[i, i] > 0.0) { "Bad covariance" }
err[i] = sqrt(theCovariance[i, i])
theIntParameters.add(par[i])
}
theParameters = MnUserParameters(par, err)
}
internal constructor(par: MnUserParameters, cov: MnUserCovariance) {
theValid = true
theCovarianceValid = true
theParameters = par
theCovariance = cov
theGlobalCC = MnGlobalCorrelationCoeff()
theIntParameters = java.util.ArrayList<Double>()
theIntCovariance = cov.copy()
theIntCovariance.scale(0.5)
val i = 0
for (ipar in par.parameters()) {
if (ipar.isConst() || ipar.isFixed()) {
continue
}
if (ipar.hasLimits()) {
theIntParameters.add(ext2int(ipar.number(), ipar.value()))
} else {
theIntParameters.add(ipar.value())
}
}
assert(theCovariance.nrow() === variableParameters())
}
/**
* construct from internal parameters (after minimization)
* @param trafo
* @param up
*/
internal constructor(st: MinimumState, up: Double, trafo: MnUserTransformation) {
theValid = st.isValid()
theCovarianceValid = false
theGCCValid = false
theFVal = st.fval()
theEDM = st.edm()
theNFcn = st.nfcn()
theParameters = MnUserParameters()
theCovariance = MnUserCovariance()
theGlobalCC = MnGlobalCorrelationCoeff()
theIntParameters = java.util.ArrayList<Double>()
theIntCovariance = MnUserCovariance()
for (ipar in trafo.parameters()) {
if (ipar.isConst()) {
add(ipar.name(), ipar.value())
} else if (ipar.isFixed()) {
add(ipar.name(), ipar.value(), ipar.error())
if (ipar.hasLimits()) {
if (ipar.hasLowerLimit() && ipar.hasUpperLimit()) {
setLimits(ipar.name(), ipar.lowerLimit(), ipar.upperLimit())
} else if (ipar.hasLowerLimit() && !ipar.hasUpperLimit()) {
setLowerLimit(ipar.name(), ipar.lowerLimit())
} else {
setUpperLimit(ipar.name(), ipar.upperLimit())
}
}
fix(ipar.name())
} else if (ipar.hasLimits()) {
val i: Int = trafo.intOfExt(ipar.number())
val err: Double = if (st.hasCovariance()) sqrt(2.0 * up * st.error().invHessian()[i, i]) else st.parameters().dirin().getEntry(i)
add(ipar.name(),
trafo.int2ext(i, st.vec().getEntry(i)),
trafo.int2extError(i, st.vec().getEntry(i), err))
if (ipar.hasLowerLimit() && ipar.hasUpperLimit()) {
setLimits(ipar.name(), ipar.lowerLimit(), ipar.upperLimit())
} else if (ipar.hasLowerLimit() && !ipar.hasUpperLimit()) {
setLowerLimit(ipar.name(), ipar.lowerLimit())
} else {
setUpperLimit(ipar.name(), ipar.upperLimit())
}
} else {
val i: Int = trafo.intOfExt(ipar.number())
val err: Double = if (st.hasCovariance()) sqrt(2.0 * up * st.error().invHessian()[i, i]) else st.parameters().dirin().getEntry(i)
add(ipar.name(), st.vec().getEntry(i), err)
}
}
theCovarianceValid = st.error().isValid()
if (theCovarianceValid) {
theCovariance = trafo.int2extCovariance(st.vec(), st.error().invHessian())
theIntCovariance = MnUserCovariance(st.error().invHessian().data().clone(), st.error().invHessian().nrow())
theCovariance.scale(2.0 * up)
theGlobalCC = MnGlobalCorrelationCoeff(st.error().invHessian())
theGCCValid = true
assert(theCovariance.nrow() === variableParameters())
}
}
/**
* add free parameter name, value, error
*
* @param err a double.
* @param val a double.
* @param name a [String] object.
*/
fun add(name: String, `val`: Double, err: Double) {
theParameters.add(name, `val`, err)
theIntParameters.add(`val`)
theCovarianceValid = false
theGCCValid = false
theValid = true
}
/**
* add limited parameter name, value, lower bound, upper bound
*
* @param name a [String] object.
* @param val a double.
* @param low a double.
* @param err a double.
* @param up a double.
*/
fun add(name: String, `val`: Double, err: Double, low: Double, up: Double) {
theParameters.add(name, `val`, err, low, up)
theCovarianceValid = false
theIntParameters.add(ext2int(index(name), `val`))
theGCCValid = false
theValid = true
}
/**
* add const parameter name, value
*
* @param name a [String] object.
* @param val a double.
*/
fun add(name: String, `val`: Double) {
theParameters.add(name, `val`)
theValid = true
}
/**
*
* copy.
*
* @return a [hep.dataforge.MINUIT.MnUserParameterState] object.
*/
fun copy(): MnUserParameterState {
return MnUserParameterState(this)
}
/**
* Covariance matrix in the external representation
*
* @return a [hep.dataforge.MINUIT.MnUserCovariance] object.
*/
fun covariance(): MnUserCovariance {
return theCovariance
}
/**
* Returns the expected vertival distance to the minimum (EDM)
*
* @return a double.
*/
fun edm(): Double {
return theEDM
}
/**
*
* error.
*
* @param index a int.
* @return a double.
*/
fun error(index: Int): Double {
return theParameters.error(index)
}
/**
*
* error.
*
* @param name a [String] object.
* @return a double.
*/
fun error(name: String?): Double {
return error(index(name))
}
/**
*
* errors.
*
* @return an array of double.
*/
fun errors(): DoubleArray {
return theParameters.errors()
}
fun ext2int(i: Int, `val`: Double): Double {
return theParameters.trafo().ext2int(i, `val`)
}
/**
*
* extOfInt.
*
* @param internal a int.
* @return a int.
*/
fun extOfInt(internal: Int): Int {
return theParameters.trafo().extOfInt(internal)
}
/// interaction via external number of parameter
/**
*
* fix.
*
* @param e a int.
*/
fun fix(e: Int) {
val i = intOfExt(e)
if (theCovarianceValid) {
theCovariance = MnCovarianceSqueeze.squeeze(theCovariance, i)
theIntCovariance = MnCovarianceSqueeze.squeeze(theIntCovariance, i)
}
theIntParameters.removeAt(i)
theParameters.fix(e)
theGCCValid = false
}
/// interaction via name of parameter
/**
*
* fix.
*
* @param name a [String] object.
*/
fun fix(name: String?) {
fix(index(name))
}
/**
* returns the function value at the minimum
*
* @return a double.
*/
fun fval(): Double {
return theFVal
}
/**
* transformation internal <-> external
* @return
*/
fun getTransformation(): MnUserTransformation {
return theParameters.trafo()
}
fun globalCC(): MnGlobalCorrelationCoeff? {
return theGlobalCC
}
/**
* Returns
* <CODE>true</CODE> if the the state has a valid covariance,
* <CODE>false</CODE> otherwise.
*
* @return a boolean.
*/
fun hasCovariance(): Boolean {
return theCovarianceValid
}
/**
*
* hasGlobalCC.
*
* @return a boolean.
*/
fun hasGlobalCC(): Boolean {
return theGCCValid
}
/**
* convert name into external number of parameter
*
* @param name a [String] object.
* @return a int.
*/
fun index(name: String?): Int {
return theParameters.index(name)
}
// transformation internal <-> external
fun int2ext(i: Int, `val`: Double): Double {
return theParameters.trafo().int2ext(i, `val`)
}
fun intCovariance(): MnUserCovariance {
return theIntCovariance
}
fun intOfExt(ext: Int): Int {
return theParameters.trafo().intOfExt(ext)
}
/**
* Minuit internal representation
* @return
*/
fun intParameters(): List<Double> {
return theIntParameters
}
/**
* Returns
* <CODE>true</CODE> if the the state is valid,
* <CODE>false</CODE> if not
*
* @return a boolean.
*/
fun isValid(): Boolean {
return theValid
}
// facade: forward interface of MnUserParameters and MnUserTransformation
fun minuitParameters(): List<MinuitParameter> {
return theParameters.parameters()
}
/**
* convert external number into name of parameter
*
* @param index a int.
* @return a [String] object.
*/
fun name(index: Int): String {
return theParameters.name(index)
}
/**
* Returns the number of function calls during the minimization.
*
* @return a int.
*/
fun nfcn(): Int {
return theNFcn
}
fun parameter(i: Int): MinuitParameter {
return theParameters.parameter(i)
}
//user external representation
fun parameters(): MnUserParameters {
return theParameters
}
/**
* access to parameters and errors in column-wise representation
*
* @return an array of double.
*/
fun params(): DoubleArray {
return theParameters.params()
}
/**
*
* precision.
*
* @return a [hep.dataforge.MINUIT.MnMachinePrecision] object.
*/
fun precision(): MnMachinePrecision {
return theParameters.precision()
}
/**
*
* release.
*
* @param e a int.
*/
fun release(e: Int) {
theParameters.release(e)
theCovarianceValid = false
theGCCValid = false
val i = intOfExt(e)
if (parameter(e).hasLimits()) {
theIntParameters.add(i, ext2int(e, parameter(e).value()))
} else {
theIntParameters.add(i, parameter(e).value())
}
}
/**
*
* release.
*
* @param name a [String] object.
*/
fun release(name: String?) {
release(index(name))
}
/**
*
* removeLimits.
*
* @param e a int.
*/
fun removeLimits(e: Int) {
theParameters.removeLimits(e)
theCovarianceValid = false
theGCCValid = false
if (!parameter(e).isFixed() && !parameter(e).isConst()) {
theIntParameters[intOfExt(e)] = value(e)
}
}
/**
*
* removeLimits.
*
* @param name a [String] object.
*/
fun removeLimits(name: String?) {
removeLimits(index(name))
}
/**
*
* setError.
*
* @param e a int.
* @param err a double.
* @param err a double.
*/
fun setError(e: Int, err: Double) {
theParameters.setError(e, err)
}
/**
*
* setError.
*
* @param name a [String] object.
* @param err a double.
*/
fun setError(name: String?, err: Double) {
setError(index(name), err)
}
/**
*
* setLimits.
*
* @param e a int.
* @param low a double.
* @param up a double.
*/
fun setLimits(e: Int, low: Double, up: Double) {
theParameters.setLimits(e, low, up)
theCovarianceValid = false
theGCCValid = false
if (!parameter(e).isFixed() && !parameter(e).isConst()) {
val i = intOfExt(e)
if (low < theIntParameters[i] && theIntParameters[i] < up) {
theIntParameters[i] = ext2int(e, theIntParameters[i])
} else {
theIntParameters[i] = ext2int(e, 0.5 * (low + up))
}
}
}
/**
*
* setLimits.
*
* @param name a [String] object.
* @param low a double.
* @param up a double.
*/
fun setLimits(name: String?, low: Double, up: Double) {
setLimits(index(name), low, up)
}
/**
*
* setLowerLimit.
*
* @param e a int.
* @param low a double.
*/
fun setLowerLimit(e: Int, low: Double) {
theParameters.setLowerLimit(e, low)
theCovarianceValid = false
theGCCValid = false
if (!parameter(e).isFixed() && !parameter(e).isConst()) {
val i = intOfExt(e)
if (low < theIntParameters[i]) {
theIntParameters[i] = ext2int(e, theIntParameters[i])
} else {
theIntParameters[i] = ext2int(e, low + 0.5 * abs(low + 1.0))
}
}
}
/**
*
* setLowerLimit.
*
* @param name a [String] object.
* @param low a double.
*/
fun setLowerLimit(name: String?, low: Double) {
setLowerLimit(index(name), low)
}
/**
*
* setPrecision.
*
* @param eps a double.
*/
fun setPrecision(eps: Double) {
theParameters.setPrecision(eps)
}
/**
*
* setUpperLimit.
*
* @param e a int.
* @param up a double.
*/
fun setUpperLimit(e: Int, up: Double) {
theParameters.setUpperLimit(e, up)
theCovarianceValid = false
theGCCValid = false
if (!parameter(e).isFixed() && !parameter(e).isConst()) {
val i = intOfExt(e)
if (theIntParameters[i] < up) {
theIntParameters[i] = ext2int(e, theIntParameters[i])
} else {
theIntParameters[i] = ext2int(e, up - 0.5 * abs(up + 1.0))
}
}
}
/**
*
* setUpperLimit.
*
* @param name a [String] object.
* @param up a double.
*/
fun setUpperLimit(name: String?, up: Double) {
setUpperLimit(index(name), up)
}
/**
*
* setValue.
*
* @param e a int.
* @param val a double.
*/
fun setValue(e: Int, `val`: Double) {
theParameters.setValue(e, `val`)
if (!parameter(e).isFixed() && !parameter(e).isConst()) {
val i = intOfExt(e)
if (parameter(e).hasLimits()) {
theIntParameters[i] = ext2int(e, `val`)
} else {
theIntParameters[i] = `val`
}
}
}
/**
*
* setValue.
*
* @param name a [String] object.
* @param val a double.
*/
fun setValue(name: String?, `val`: Double) {
setValue(index(name), `val`)
}
/** {@inheritDoc} */
override fun toString(): String {
return MnPrint.toString(this)
}
/**
*
* value.
*
* @param index a int.
* @return a double.
*/
fun value(index: Int): Double {
return theParameters.value(index)
}
/**
*
* value.
*
* @param name a [String] object.
* @return a double.
*/
fun value(name: String?): Double {
return value(index(name))
}
/**
*
* variableParameters.
*
* @return a int.
*/
fun variableParameters(): Int {
return theParameters.variableParameters()
}
} | 26.993386 | 145 | 0.552408 |
fd8c9cfc44ca8211681105dd5e536e230fb82b06 | 287 | c | C | tests/threads/main_thread_pthread_exit_test.c | cohortfsllc/cohort-cocl2-sandbox | 0ac6669d1a459d65a52007b80d5cffa4ef330287 | [
"BSD-3-Clause"
] | 2,151 | 2020-04-18T07:31:17.000Z | 2022-03-31T08:39:18.000Z | tests/threads/main_thread_pthread_exit_test.c | cohortfsllc/cohort-cocl2-sandbox | 0ac6669d1a459d65a52007b80d5cffa4ef330287 | [
"BSD-3-Clause"
] | 395 | 2020-04-18T08:22:18.000Z | 2021-12-08T13:04:49.000Z | tests/threads/main_thread_pthread_exit_test.c | cohortfsllc/cohort-cocl2-sandbox | 0ac6669d1a459d65a52007b80d5cffa4ef330287 | [
"BSD-3-Clause"
] | 338 | 2020-04-18T08:03:10.000Z | 2022-03-29T12:33:22.000Z | /*
* Copyright (c) 2011 The Native Client Authors. All rights reserved.
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
#include <pthread.h>
int main(void) {
pthread_exit(NULL);
/* Should never get here */
return 1;
}
| 20.5 | 73 | 0.686411 |
20d9c3c67c8361700e386a3aa4f8a5eef1d62c5f | 784 | css | CSS | app/app.css | rrdlpl/cn-test | dfc72b9d07f3943291bd7fedb710cec03559ae5d | [
"MIT"
] | null | null | null | app/app.css | rrdlpl/cn-test | dfc72b9d07f3943291bd7fedb710cec03559ae5d | [
"MIT"
] | null | null | null | app/app.css | rrdlpl/cn-test | dfc72b9d07f3943291bd7fedb710cec03559ae5d | [
"MIT"
] | null | null | null | /* app css stylesheet */
.menu {
list-style: none;
border-bottom: 0.1em solid black;
margin-bottom: 2em;
padding: 0 0 0.5em;
}
.menu:before {
content: "[";
}
.menu:after {
content: "]";
background-color: #2fc95d;
}
.menu > li {
display: inline;
}
.menu > li:before {
content: "|";
padding-right: 0.3em;
}
.menu > li:nth-child(1):before {
content: "";
padding: 0;
}
.footer{
background-color: #5f2c85;
display: inline-block;
position: fixed;
padding-top: 60px;
width: 100%;
bottom: 0;
color:white;
font-family:sans-serif;
font-size: 8pt;
}
.footer ul{
list-style-type: none;
}
.footer a{
color: white;
}
.footer a:hover{
color: #dfc3ec;
}
nav{
background-color: white;
}
nav ul a {
color: #5f2c85;
font-weight: bold;
}
| 12.25 | 35 | 0.608418 |
3d65f2207aea6172701d2488a6c0fe0807bca09b | 1,581 | rs | Rust | src/maze/square_maze/dfs.rs | Colocasian/maze-generator-two | 007b8083dd4866389c455feca0a7bd06e83f2590 | [
"0BSD"
] | 2 | 2021-04-29T21:31:28.000Z | 2021-06-06T15:12:45.000Z | src/maze/square_maze/dfs.rs | Colocasian/maze-generator-two | 007b8083dd4866389c455feca0a7bd06e83f2590 | [
"0BSD"
] | null | null | null | src/maze/square_maze/dfs.rs | Colocasian/maze-generator-two | 007b8083dd4866389c455feca0a7bd06e83f2590 | [
"0BSD"
] | null | null | null | extern crate alloc;
use super::{SqDir, SquareMaze};
use alloc::vec::Vec;
use bit_vec::BitVec;
use rand::prelude::*;
use rand::rngs::SmallRng;
impl SquareMaze {
pub fn init_dfs(&mut self) {
let mut rng = SmallRng::seed_from_u64(self.seed);
let mut stk = Vec::new();
let mut visited = BitVec::from_elem(self.width * self.height, false);
let init_pos = rng.gen_range(0..self.width * self.height);
let mut dir_buf = Vec::with_capacity(4);
stk.push((init_pos, None));
while !stk.is_empty() {
let (at, dir) = stk.pop().unwrap();
if !visited[at] {
visited.set(at, true);
if let Some(dir) = dir {
self.walls.set(self.get_wall(at, dir).unwrap(), true);
}
let y = at / self.width;
let x = at % self.width;
dir_buf.clear();
if y != 0 {
dir_buf.push((at - self.width, Some(SqDir::Down)));
}
if x != 0 {
dir_buf.push((at - 1, Some(SqDir::Right)));
}
if y != self.height - 1 {
dir_buf.push((at + self.width, Some(SqDir::Up)));
}
if x != self.width - 1 {
dir_buf.push((at + 1, Some(SqDir::Left)));
}
dir_buf.shuffle(&mut rng);
for neighbor in dir_buf.iter() {
stk.push(*neighbor);
}
}
}
}
}
| 31.62 | 77 | 0.44845 |
4febee0a39094c90ffc2cb7b6e3b58f013560761 | 871 | swift | Swift | GINcose/Messages/TransmitterStatus.swift | gintechsystems/GINcose-iOS | 8471289cf314d049308f819a6df1f7378e44f25f | [
"MIT"
] | 1 | 2018-03-26T12:46:29.000Z | 2018-03-26T12:46:29.000Z | GINcose/Messages/TransmitterStatus.swift | gintechsystems/GINcose-iOS | 8471289cf314d049308f819a6df1f7378e44f25f | [
"MIT"
] | null | null | null | GINcose/Messages/TransmitterStatus.swift | gintechsystems/GINcose-iOS | 8471289cf314d049308f819a6df1f7378e44f25f | [
"MIT"
] | null | null | null | //
// TransmitterStatus.swift
// GINcose
//
// Created by Joe Ginley on 3/28/16.
// Copyright © 2016 GINtech Systems. All rights reserved.
//
import Foundation
public enum TransmitterStatus {
public typealias RawValue = UInt8
case ok
case lowBattery
case unknown(RawValue)
init(rawValue: RawValue) {
switch rawValue {
case 0:
self = .ok
case 0x81:
self = .lowBattery
default:
self = .unknown(rawValue)
}
}
}
extension TransmitterStatus: Equatable { }
public func ==(lhs: TransmitterStatus, rhs: TransmitterStatus) -> Bool {
switch (lhs, rhs) {
case (.ok, .ok), (.lowBattery, .lowBattery):
return true
case (.unknown(let left), .unknown(let right)) where left == right:
return true
default:
return false
}
}
| 19.795455 | 72 | 0.591274 |
72fde34daa8ecce5f17993cd2d076a6475970b0e | 4,008 | go | Go | delete.go | kirinse/mogo | ac55338150dc5929227d2a262638011b88781543 | [
"MIT"
] | 27 | 2018-12-12T17:16:40.000Z | 2022-03-16T21:34:41.000Z | delete.go | kirinse/mogo | ac55338150dc5929227d2a262638011b88781543 | [
"MIT"
] | 2 | 2020-03-11T11:50:30.000Z | 2021-03-08T09:02:48.000Z | delete.go | kirinse/mogo | ac55338150dc5929227d2a262638011b88781543 | [
"MIT"
] | 6 | 2020-07-22T21:33:31.000Z | 2021-03-09T09:32:05.000Z | package mogo
import (
"github.com/globalsign/mgo"
"github.com/globalsign/mgo/bson"
)
// Remove removes the passed document from database, executing
// before and after delete hooks
func (c *Collection) Remove(doc Document) error {
var err error
// Create a new session per mgo's suggestion to avoid blocking
sess := c.Connection.Session.Clone()
defer sess.Close()
col := c.collectionOnSession(sess)
if hook, ok := doc.(BeforeDeleteHook); ok {
err := hook.BeforeDelete()
if err != nil {
return err
}
}
err = col.RemoveId(doc.GetID())
if err != nil {
return err
}
if hook, ok := doc.(AfterDeleteHook); ok {
err = hook.AfterDelete()
if err != nil {
return err
}
}
return nil
}
// RemoveAll removes all documents passed in slice executing,
// for each one, the before and after delete hooks.
// Document in slice can belong to different collections.
func (c *Collection) RemoveAll(docs []Document) map[bson.ObjectId]error {
var err error
var errs = make(map[bson.ObjectId]error, 0)
var col *mgo.Collection
// Create a new session per mgo's suggestion to avoid blocking
sess := c.Connection.Session.Clone()
defer sess.Close()
for _, d := range docs {
col = d.GetColl().collectionOnSession(sess)
if hook, ok := d.(BeforeDeleteHook); ok {
err = hook.BeforeDelete()
if err != nil {
errs[d.GetID()] = err
continue
}
}
err = col.Remove(d.BsonID)
if err != nil {
errs[d.GetID()] = err
continue
}
if hook, ok := d.(AfterDeleteHook); ok {
err = hook.AfterDelete()
if err != nil {
errs[d.GetID()] = err
continue
}
}
}
if l := len(errs); l == 0 {
return nil
}
return errs
}
// RemoveBySelector is a wrapper aorund mgo.Remove method.
// This is faster the Collection.Remove method but it doesn't run
// before / after delete hooks
func (c *Collection) RemoveBySelector(selector interface{}) error {
var err error
// Create a new session per mgo's suggestion to avoid blocking
sess := c.Connection.Session.Clone()
defer sess.Close()
col := c.collectionOnSession(sess)
err = col.Remove(selector)
if err != nil {
return err
}
return nil
}
// RemoveAllBySelector is a wrapper aorund mgo.RemoveAll method.
//
// This is faster then Collection.RemoveAll method but it doesn't
// run before / after delete hooks.
//
// The selectors argument is a map[Model]interface{},
// where the key is the model (collection) on which we are going
// to apply the selector and the interface is the mgo selector.
//
//
func (c *Collection) RemoveAllBySelector(selectors map[Model]interface{}) map[string]*ChangeInfoWithError {
var err error
var info *mgo.ChangeInfo
var errs = make(map[string]*ChangeInfoWithError)
// Create a new session per mgo's suggestion to avoid blocking
sess := c.Connection.Session.Clone()
defer sess.Close()
for m, s := range selectors {
col := m.GetColl().collectionOnSession(sess)
info, err = col.RemoveAll(s)
if err != nil {
iname, _ := m.GetMe()
errs[iname] = &ChangeInfoWithError{Info: info, Err: err}
}
}
if len(errs) > 0 {
return errs
}
return nil
}
// Remove is a convenience (haha) method for Document.Remove
func Remove(doc Document) error {
return doc.Remove()
}
// RemoveAll is convenience method for Collection.RemoveAll
func RemoveAll(docs []Document) map[bson.ObjectId]error {
if l := len(docs); l > 0 {
d := docs[0]
return d.GetColl().RemoveAll(docs)
}
return nil
}
// RemoveBySelector is convenience method for Collection.RemoveBySelector
// The model argument here is used to reference its Collection to call
// the mgo driver on it.
func RemoveBySelector(model Model, selector interface{}) error {
return model.GetColl().RemoveBySelector(selector)
}
// RemoveAllBySelector is convenience method for Collection.RemoveAllBySelector
func RemoveAllBySelector(selectors map[Model]interface{}) map[string]*ChangeInfoWithError {
for m := range selectors {
return m.GetColl().RemoveAllBySelector(selectors)
}
return nil
}
| 23.715976 | 107 | 0.700599 |
1742346572c4913a1049ce6b53dbc9518bc47230 | 4,597 | html | HTML | compendium/monster/Remliel-Angel-of-Prophecy.html | nonjosh/dnd4e-data-html | 83eb6201d7992e5f0c3812c9e18a17d5897891d8 | [
"MIT"
] | null | null | null | compendium/monster/Remliel-Angel-of-Prophecy.html | nonjosh/dnd4e-data-html | 83eb6201d7992e5f0c3812c9e18a17d5897891d8 | [
"MIT"
] | null | null | null | compendium/monster/Remliel-Angel-of-Prophecy.html | nonjosh/dnd4e-data-html | 83eb6201d7992e5f0c3812c9e18a17d5897891d8 | [
"MIT"
] | null | null | null |
<!DOCTYPE HTML>
<html>
<head id="Head1"><title>
Remliel, Angel of Prophecy
</title><meta http-equiv="X-UA-Compatible" content="IE=EmulateIE7" /><link href="styles/detail.css" media="screen" rel="stylesheet" type="text/css" /><link href="styles/print.css" media="print" rel="stylesheet" type="text/css" /><link href="styles/mobile.css" media="handheld" rel="stylesheet" type="text/css" />
</head>
<body>
<form name="form1" method="post" action="display.aspx?page=monster&id=2312" id="form1">
<div>
<div>
<div id="detail">
<h1 class="monster">Remliel, Angel of Prophecy<br/><span class="type">Huge immortal humanoid (angel)</span><br/><span class="level">Level 23 Solo Skirmisher<span class="xp"> XP 4800</span></span> </h1> <p class="flavor"><b>Initiative</b> +20 <b>Senses</b> Perception +23<br/><b>HP</b> 872; <b>Bloodied</b> 436 ; see also prophecy of rebirth<br/><b>AC</b> 40; <b>Fortitude</b> 38, <b>Reflex</b> 37, <b>Will</b> 37<br/><b>Immune</b> disease, fear; <b>Resist</b> 15 thunder, 15 cold, 15 radiant<br/><b>Saving Throws</b> +5<br/><b>Speed</b> 8, fly 12 (hover)<br/><b>Action Points</b> 2</p><p class="flavor alt"><img src="http://www.wizards.com/dnd/images/symbol/S2.gif" /> <b>Katar</b> (standard, at-will) <img src="http://www.wizards.com/dnd/images/symbol/x.gif" /> <b>Cold, Radiant, Weapon</b></p><p class="flavorIndent">Reach 3; +28 vs AC; 1d10+8 damage plus 2d8 cold and radiant damage (crit 18 + 1d10 damage plus 16 cold and radiant damage). </p><p class="flavor alt"><img src="http://www.wizards.com/dnd/images/symbol/Z2a.gif" /> <b>Katar Death Dance</b> (standard, at-will) </p><p class="flavorIndent">Remliel can make katar attacks against four different enemies. After each attack (hit or miss), Remliel can shift 2 squares</p><p class="flavor alt"><img src="http://www.wizards.com/dnd/images/symbol/Z2a.gif" /> <b>Mark of Prophecy</b> (minor, at-will) </p><p class="flavorIndent">Reach 3; +26 vs Will; the target is under the effects of Remliel’s mark of prophecy. Remliel can only have one creature under the effects of a mark of prophecy at time. The mark of prophecy has the following effects: the target is marked by Remliel, and while marked and within sight of Remliel, when the target hits Remliel, the angel can force it to reroll the attack at a -2 penalty. Also, once on each of his turns as a free action, if Remliel misses the target with a melee attack, the angel can reroll that attack. </p><p class="flavor alt"><img src="http://www.wizards.com/dnd/images/symbol/Z1a.gif" /> <b>Word of Prophecy</b> (free, when first bloodied, encounter) <img src="http://www.wizards.com/dnd/images/symbol/x.gif" /> <b>Thunder, Fear</b></p><p class="flavorIndent">Close burst 3; +23 vs Will; 3d8+9 thunder damage, and the target is pushed 3 squares and takes ongoing 10 psychic and is slowed (save ends both). </p><p class="flavor alt"> <b>Angelic Presence</b> (while not bloodied) </p><p class="flavorIndent">Any attack against Remliel takes a -2 penalty to the attack roll.</p><p class="flavor alt"> <b>Prophecy of Rebirth</b></p><p class="flavorIndent">The first time each day that Remliel is reduced to 0 or fewer hit points, he gains regeneration 10 until he regains hit points equal to his bloodied amount or is reduced to 0 or fewer hit points again, whichever comes first.</p><p class="flavor alt"> <b>Threatening Reach</b></p><p class="flavorIndent">Remliel can make opportunity attacks against all enemies within his reach (3 squares).</p><p class="flavor alt"><b>Alignment</b> Any <b> Languages</b> Supernal<br/><b>Skills</b> Acrobatics +23, Insight +23, Intimidate +24<br/><b>Str</b> 29 (+20) <b>Dex</b> 24 (+18) <b>Wis</b> 25 (+18)<br/><b>Con</b> 26 (+19) <b>Int</b> 19 (+15) <b>Cha</b> 27 (+19)</p><p class="flavor alt"><b>Equipment</b>: <a target="_new" href="http://ww2.wizards.com/dnd/insider/item.aspx?fid=28&ftype=3">katar</a> x2, <a target="_new" href="http://ww2.wizards.com/dnd/insider/item.aspx?fid=6&ftype=2">plate armor</a> .</p><br/><p class="publishedIn">Published in <a href="http://www.wizards.com/default.asp?x=dnd/dutoc/162" target="_new">Dungeon Magazine 162</a>, page(s) 50, <a href="http://www.wizards.com/dnd/Product.aspx?x=dnd/products/dndacc/250317200" target="_new">Dungeon Magazine Annual</a>, page(s) 47.</p>
</div>
</form>
</body>
</html>
| 148.290323 | 3,964 | 0.691103 |
b689f0d7885373eb2bbc5f60b750774b48c0f4a5 | 1,401 | dart | Dart | test/launch_appengine_api_server_test.dart | bwu-dart/bwu_datastore_launcher | d71c3602198640b9f28d30e98ce79a616e7fedeb | [
"MIT"
] | null | null | null | test/launch_appengine_api_server_test.dart | bwu-dart/bwu_datastore_launcher | d71c3602198640b9f28d30e98ce79a616e7fedeb | [
"MIT"
] | null | null | null | test/launch_appengine_api_server_test.dart | bwu-dart/bwu_datastore_launcher | d71c3602198640b9f28d30e98ce79a616e7fedeb | [
"MIT"
] | null | null | null | @TestOn('vm')
library bwu_datastore_launcher.test.launch_app_engine_api_server;
import 'package:path/path.dart' as path;
import 'package:test/test.dart';
import 'package:bwu_datastore_launcher/bwu_datastore_launcher.dart';
import 'package:bwu_utils/bwu_utils_server.dart' as srv_utils;
import 'package:logging/logging.dart' show Logger, Level;
import 'package:quiver_log/log.dart' show PrintAppender, BASIC_LOG_FORMATTER;
final _log =
new Logger('bwu_datastore_launcher.test.launch_app_engine_api_server');
main() {
Logger.root.level = Level.FINEST;
var appender = new PrintAppender(BASIC_LOG_FORMATTER);
appender.attachLogger(Logger.root);
group('launch AppEngine API Server', () {
test('start and remoteSuthdown', () {
var exitCalled = expectAsync(() {});
// Create an instance of the server launcher.
final server = new AppEngineApiServer(path.join(
srv_utils.packageRoot().absolute.path,
'test/.tmp_data/appengine_api_server'), 'test-app',
clearDatastore: true);
// launch the Gcloud Datastore Local Development Server
return server.start().then((success) {
expect(success, isTrue);
server.onExit.first.then((code) {
expect(code, equals(-15));
exitCalled();
});
return server.kill().then((success) => expect(success, isTrue));
});
});
});
}
| 32.581395 | 77 | 0.68808 |
814549751f6c7c6f4b427ec5d1c2c70a9a0ac790 | 451 | go | Go | session/bool.go | vladimirok5959/golang-server-sessions | 8aeddc1f515fabb50f99d1c40e516df0ecdb7529 | [
"MIT"
] | 21 | 2019-02-05T11:38:02.000Z | 2021-07-07T15:12:50.000Z | session/bool.go | vladimirok5959/golang-server-sessions | 8aeddc1f515fabb50f99d1c40e516df0ecdb7529 | [
"MIT"
] | 4 | 2019-03-07T21:58:58.000Z | 2021-09-28T20:26:07.000Z | session/bool.go | vladimirok5959/golang-server-sessions | 8aeddc1f515fabb50f99d1c40e516df0ecdb7529 | [
"MIT"
] | 5 | 2019-08-24T21:55:17.000Z | 2021-10-01T13:35:07.000Z | package session
func (this *Session) IsSetBool(name string) bool {
if _, ok := this.v.Bool[name]; ok {
return true
} else {
return false
}
}
func (this *Session) GetBool(name string, def bool) bool {
if v, ok := this.v.Bool[name]; ok {
return v
} else {
return def
}
}
func (this *Session) SetBool(name string, value bool) {
isset := this.IsSetBool(name)
this.v.Bool[name] = value
if isset || value != false {
this.c = true
}
}
| 17.346154 | 58 | 0.636364 |
bb17e87e033a3e25971f1686160b0589ce66b79d | 2,671 | html | HTML | app/views/beta-sprint-6-private-beta/create-overseas-account-OLD/gov-pay.html | neilp78/landreg | ac6f10788b183d48b59902ed89837d2eb0014636 | [
"MIT"
] | 2 | 2019-06-25T16:23:02.000Z | 2019-09-10T10:08:05.000Z | app/views/beta-sprint-6-private-beta/create-overseas-account-OLD/gov-pay.html | LandRegistry/dps-prototype | b4872f59d5a9a6a22db8ea286b93871f44bc7ab9 | [
"MIT"
] | 2 | 2019-02-26T15:14:58.000Z | 2022-02-12T02:42:59.000Z | app/views/beta-sprint-6-private-beta/create-overseas-account-OLD/gov-pay.html | neilp78/landreg | ac6f10788b183d48b59902ed89837d2eb0014636 | [
"MIT"
] | 1 | 2021-04-11T05:23:16.000Z | 2021-04-11T05:23:16.000Z |
{% extends "layout.html" %}
{% block pageTitle %}
GOV.UK Prototype Kit
{% endblock %}
{% block content %}
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="theme-color" content="#0b0c0c">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<link rel="shortcut icon" sizes="16x16 32x32 48x48" href="https://www.payments.service.gov.uk/assets/images/favicon.ico" type="image/x-icon">
<link rel="mask-icon" href="https://www.payments.service.gov.uk/assets/images/govuk-mask-icon.svg" color="#0b0c0c">
<link rel="apple-touch-icon" sizes="180x180" href="https://www.payments.service.gov.uk/assets/images/govuk-apple-touch-icon-180x180.png">
<link rel="apple-touch-icon" sizes="167x167" href="https://www.payments.service.gov.uk/assets/images/govuk-apple-touch-icon-167x167.png">
<link rel="apple-touch-icon" sizes="152x152" href="https://www.payments.service.gov.uk/assets/images/govuk-apple-touch-icon-152x152.png">
<link rel="apple-touch-icon" href="https://www.payments.service.gov.uk/assets/images/govuk-apple-touch-icon.png">
<!--[if IE 8]>
<link href="/govuk-frontend/all-ie8.css" rel="stylesheet" />
<![endif]-->
<!--[if lt IE 9]>
<script src="/html5-shiv/html5shiv.js"></script>
<![endif]-->
<link href="./govpay-01_files/application.1a72a29.css" media="screen" rel="stylesheet" type="text/css">
<script async="" src="./govpay-01_files/analytics.js"></script><script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function()
{ (i[r].q=i[r].q||[]).push(arguments)}
,i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-72121642-2', 'auto');
ga('set', 'anonymizeIp', true);
ga('set', 'transport', 'beacon');
ga('send', 'pageview', {
'page': '/card_details/ri2vsjh3gevaadt6skimdbqtq9',
'dimension1': '',
'dimension2': 'test',
'dimension3': 'sandbox',
'dimension4': 'original',
});
</script>
<meta property="og:image" content="/assets/images/govuk-opengraph-image.png">
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<a href="2-6-createaccount-check-answers" class="govuk-back-link">Back</a>
<br>
<br>
<div class="govuk-grid-row">
<div class="govuk-grid-column-two-thirds">
<img style="width: 200%;" src="/public/images/gov-pay-example.jpg">
</div>
</div>
<br>
<a class="govuk-button" href="2-6-createaccount-confirmation" role="button">
Continue
</a>
</div>
{% endblock %}
| 36.094595 | 143 | 0.661924 |
c24740f948170ba2270b0196c235e6da92d31ff7 | 793 | go | Go | pkg/git/info.go | joaopapereira/kpack-resource | 68a166b9546a3f87885bd2e4b1c7ce9a6294ec41 | [
"Apache-2.0"
] | 2 | 2019-10-25T03:01:55.000Z | 2019-10-25T04:40:13.000Z | pkg/git/info.go | joaopapereira/kpack-resource | 68a166b9546a3f87885bd2e4b1c7ce9a6294ec41 | [
"Apache-2.0"
] | null | null | null | pkg/git/info.go | joaopapereira/kpack-resource | 68a166b9546a3f87885bd2e4b1c7ce9a6294ec41 | [
"Apache-2.0"
] | null | null | null | package git
import (
"github.com/cloudboss/ofcourse/ofcourse"
"github.com/pkg/errors"
"gopkg.in/src-d/go-git.v4"
)
type Git struct {
Repository string
Commit string
}
type InfoRetriever struct {
Logger *ofcourse.Logger
}
func (i InfoRetriever) FromPath(path string) (Git, error) {
i.Logger.Debugf("Checking git repo on: %s", path)
repository, err := git.PlainOpen(path)
if err != nil {
return Git{}, errors.Wrap(err, "reading git folder")
}
head, err := repository.Head()
if err != nil {
return Git{}, errors.Wrap(err, "reading git HEAD")
}
remote, err := repository.Remote("origin")
if err != nil {
return Git{}, errors.Wrap(err, "retrieving 'origin' remote")
}
return Git{
Repository: remote.Config().URLs[0],
Commit: head.Hash().String(),
}, nil
}
| 20.333333 | 62 | 0.669609 |
818c51bd5e238187d6a4a651531c5596d9b5e88f | 1,394 | go | Go | asset.go | WhoBrokeTheBuild/go-bindata | 80a5b1bafc3c7674656823e927f606c7aa62c596 | [
"CC0-1.0"
] | null | null | null | asset.go | WhoBrokeTheBuild/go-bindata | 80a5b1bafc3c7674656823e927f606c7aa62c596 | [
"CC0-1.0"
] | null | null | null | asset.go | WhoBrokeTheBuild/go-bindata | 80a5b1bafc3c7674656823e927f606c7aa62c596 | [
"CC0-1.0"
] | null | null | null | // Copyright 2018 The go-bindata Authors. All rights reserved.
// Use of this source code is governed by a CC0 1.0 Universal (CC0 1.0)
// Public Domain Dedication license that can be found in the LICENSE file.
package bindata
import (
"os"
"path/filepath"
"unicode"
)
//
// Asset holds information about a single asset to be processed.
//
type Asset struct {
// Path contains full file path.
Path string
// Name contains key used in TOC -- name by which asset is referenced.
Name string
// Function name for the procedure returning the asset contents.
Func string
// fi field contains the file information (to minimize calling os.Stat
// on the same file while processing).
fi os.FileInfo
}
func normalize(in string) (out string) {
up := true
for _, r := range in {
if unicode.IsLetter(r) || unicode.IsDigit(r) {
if up {
out += string(unicode.ToUpper(r))
up = false
} else {
out += string(r)
}
continue
}
if r == '/' {
up = true
}
}
return
}
//
// NewAsset will create, initialize, and return new asset based on file
// path and real path if its symlink.
//
func NewAsset(path, name, realPath string, fi os.FileInfo) (a Asset) {
a = Asset{
Path: path,
Name: filepath.ToSlash(name),
fi: fi,
}
if len(realPath) == 0 {
a.Func = "bindata" + normalize(name)
} else {
a.Func = "bindata" + normalize(realPath)
}
return
}
| 19.914286 | 74 | 0.664993 |
90ba5f3827b0a4dadfc95761ecc4cc9253d6d5fe | 17,611 | py | Python | spyder/plugins/layout/api.py | Earthman100/spyder | 949ce0f9100a69504c70a5678e8589a05aee7d38 | [
"MIT"
] | 7,956 | 2015-02-17T01:19:09.000Z | 2022-03-31T21:52:15.000Z | spyder/plugins/layout/api.py | Earthman100/spyder | 949ce0f9100a69504c70a5678e8589a05aee7d38 | [
"MIT"
] | 16,326 | 2015-02-16T23:15:21.000Z | 2022-03-31T23:34:34.000Z | spyder/plugins/layout/api.py | Earthman100/spyder | 949ce0f9100a69504c70a5678e8589a05aee7d38 | [
"MIT"
] | 1,918 | 2015-02-20T19:26:26.000Z | 2022-03-31T19:03:25.000Z | # -*- coding: utf-8 -*-
#
# Copyright © Spyder Project Contributors
# Licensed under the terms of the MIT License
# (see spyder/__init__.py for details)
"""
Layout Plugin API.
"""
# Standard libray imports
import copy
# Third party imports
from qtpy.QtCore import QRectF, Qt
from qtpy.QtWidgets import (QGridLayout, QPlainTextEdit, QWidget)
# Local imports
from spyder.api.exceptions import SpyderAPIError
from spyder.api.translations import get_translation
# Localization
_ = get_translation("spyder")
class BaseGridLayoutType:
"""
A base layout type to create custom layouts for Spyder panes.
The API for this plugin is a subset of a QGridLayout, so the same
concepts, like row, column, spans and stretches apply.
Notes
-----
See: https://doc.qt.io/qt-5/qgridlayout.html
"""
ID = None
"""Unique string identifier for the layout."""
def __init__(self, parent_plugin):
self.plugin = parent_plugin
self._plugin = parent_plugin
self._areas = []
self._area_rects = []
self._column_stretchs = {}
self._row_stretchs = {}
self._default_added = False
self._default_area = None
self._visible_areas = []
self._rows = 0
self._cols = 0
self._plugin_ids = []
# --- Private API
# ------------------------------------------------------------------------
def _check_layout_validity(self):
"""
Check the current layout is a valid one.
"""
self._visible_areas = []
# Check ID
if self.ID is None:
raise SpyderAPIError("A Layout must define an `ID` class "
"attribute!")
# Check name
self.get_name()
# All layouts need to add at least 1 area
if not self._areas:
raise SpyderAPIError("A Layout must define add least one area!")
default_areas = []
area_zero_zero = False
for area in self._areas:
default_areas.append(area["default"])
if area["default"]:
self._default_area = area
self._visible_areas.append(area["visible"])
if area_zero_zero and area["row"] == 0 and area["column"] == 0:
raise SpyderAPIError(
"Multiple areas defined their row and column as 0!")
if area["row"] == 0 and area["column"] == 0:
area_zero_zero = True
if not set(area["hidden_plugin_ids"]) <= set(area["plugin_ids"]):
raise SpyderAPIError(
"At least 1 hidden plugin id is not being specified "
"in the area plugin ids list!\n SpyderLayout: {}\n "
"hidden_plugin_ids: {}\n"
"plugin_ids: {}".format(self.get_name(),
area["hidden_plugin_ids"],
area["plugin_ids"]))
# Check that there is at least 1 visible!
if not any(self._visible_areas):
raise SpyderAPIError("At least 1 area must be `visible`")
# Check that there is a `default` area!
if not any(default_areas):
raise SpyderAPIError("No area is the `default`!")
# Check that there is 1 `default` area!
if default_areas.count(True) != 1:
raise SpyderAPIError("Only 1 area can be the `default`!")
# Check one area has row zero and column zero
if not area_zero_zero:
raise SpyderAPIError(
"1 area needs to be specified with row 0 and column 0!")
# Check Area
self._check_area()
def _check_area(self):
"""
Check if the current layout added areas cover the entire rectangle.
Rectangle given by the extreme points for the added areas.
"""
self._area_rects = []
height = self._rows + 1
area_float_rects = []
delta = 0.0001
for index, area in enumerate(self._areas):
# These areas are used with a small delta to ensure if they are
# next to each other they will not overlap.
rectf = QRectF()
rectf.setLeft(area["column"] + delta)
rectf.setRight(area["column"] + area["col_span"] - delta)
rectf.setTop(height - area["row"] - delta)
rectf.setBottom(height - area["row"] - area["row_span"] + delta)
rectf.index = index
rectf.plugin_ids = area["plugin_ids"]
area_float_rects.append(rectf)
# These areas are used to calculate the actual total area
rect = QRectF()
rect.setLeft(area["column"])
rect.setRight(area["column"] + area["col_span"])
rect.setTop(height - area["row"])
rect.setBottom(height - area["row"] - area["row_span"])
rect.index = index
rect.plugin_ids = area["plugin_ids"]
self._area_rects.append(rect)
# Check if areas are overlapping!
for rect_1 in area_float_rects:
for rect_2 in area_float_rects:
if rect_1.index != rect_2.index:
if rect_1.intersects(rect_2):
raise SpyderAPIError(
"Area with plugins {0} is overlapping area "
"with plugins {1}".format(rect_1.plugin_ids,
rect_2.plugin_ids))
# Check the total area (using corner points) versus the sum of areas
total_area = 0
tops = []
rights = []
for index, rect in enumerate(self._area_rects):
tops.append(rect.top())
rights.append(rect.right())
area = abs(rect.width() * rect.height())
total_area += area
self._areas[index]["area"] = area
if total_area != max(rights)*max(tops):
raise SpyderAPIError(
"Areas are not covering the entire section!\n"
"Either an area is missing or col_span/row_span are "
"not correctly set!"
)
# --- SpyderGridLayout API
# ------------------------------------------------------------------------
def get_name(self):
"""
Return the layout localized name.
Returns
-------
str
Localized name of the layout.
Notes
-----
This is a method to be able to update localization without a restart.
"""
raise NotImplementedError("A layout must define a `get_name` method!")
# --- Public API
# ------------------------------------------------------------------------
def add_area(self,
plugin_ids,
row,
column,
row_span=1,
col_span=1,
default=False,
visible=True,
hidden_plugin_ids=[]):
"""
Add a new area and `plugin_ids` that will populate it to the layout.
The area will start at row, column spanning row_pan rows and
column_span columns.
Parameters
----------
plugin_ids: list
List of plugin ids that will be in the area
row: int
Initial row where the area starts
column: int
Initial column where the area starts
row_span: int, optional
Number of rows that the area covers
col_span: int, optional
Number of columns the area covers
default: bool, optiona
Defines an area as the default one, i.e all other plugins that where
not passed in the `plugins_ids` will be added to the default area.
By default is False.
visible: bool, optional
Defines if the area is visible when setting up the layout.
Default is True.
Notes
-----
See: https://doc.qt.io/qt-5/qgridlayout.html
"""
if self._default_added and default:
raise SpyderAPIError("A default location has already been "
"defined!")
self._plugin_ids += plugin_ids
self._rows = max(row, self._rows)
self._cols = max(column, self._cols)
self._default_added = default
self._column_stretchs[column] = 1
self._row_stretchs[row] = 1
self._areas.append(
dict(
plugin_ids=plugin_ids,
row=row,
column=column,
row_span=row_span,
col_span=col_span,
default=default,
visible=visible,
hidden_plugin_ids=hidden_plugin_ids,
)
)
def set_column_stretch(self, column, stretch):
"""
Set the factor of column to stretch.
The stretch factor is relative to the other columns in this grid.
Columns with a higher stretch factor take more of the available space.
Parameters
----------
column: int
The column number. The first column is number 0.
stretch: int
Column stretch factor.
Notes
-----
See: https://doc.qt.io/qt-5/qgridlayout.html
"""
self._column_stretchs[column] = stretch
def set_row_stretch(self, row, stretch):
"""
Set the factor of row to stretch.
The stretch factor is relative to the other rows in this grid.
Rows with a higher stretch factor take more of the available space.
Parameters
----------
row: int
The row number. The first row is number 0.
stretch: int
Row stretch factor.
Notes
-----
See: https://doc.qt.io/qt-5/qgridlayout.html
"""
self._row_stretchs[row] = stretch
def preview_layout(self, show_hidden_areas=False):
"""
Show the layout with placeholder texts using a QWidget.
"""
from spyder.utils.qthelpers import qapplication
app = qapplication()
widget = QWidget()
layout = QGridLayout()
for area in self._areas:
label = QPlainTextEdit()
label.setReadOnly(True)
label.setPlainText("\n".join(area["plugin_ids"]))
if area["visible"] or show_hidden_areas:
layout.addWidget(
label,
area["row"],
area["column"],
area["row_span"],
area["col_span"],
)
# label.setVisible(area["visible"])
if area["default"]:
label.setStyleSheet(
"QPlainTextEdit {background-color: #ff0000;}")
if not area["visible"]:
label.setStyleSheet(
"QPlainTextEdit {background-color: #eeeeee;}")
for row, stretch in self._row_stretchs.items():
layout.setRowStretch(row, stretch)
for col, stretch in self._column_stretchs.items():
layout.setColumnStretch(col, stretch)
widget.setLayout(layout)
widget.showMaximized()
app.exec_()
def set_main_window_layout(self, main_window, dockable_plugins):
"""
Set the given mainwindow layout.
First validate the current layout definition, then clear the mainwindow
current layout and finally calculate and set the new layout.
"""
# Define plugins assigned to areas, all the available plugins and
# initial docks for each area
all_plugin_ids = []
# Before applying a new layout all plugins need to be hidden
for plugin in dockable_plugins:
all_plugin_ids.append(plugin.NAME)
plugin.toggle_view(False)
# Add plugins without an area assigned to the default area and made
# them hidden. Deep copy needed since test can run multiple times with
# the same Mainwindow instance when using the 'main_window' fixture
patched_default_area = copy.deepcopy(self._default_area)
unassgined_plugin_ids = list(
set(self._plugin_ids) ^ set(all_plugin_ids))
patched_default_area["plugin_ids"] += unassgined_plugin_ids
patched_default_area["hidden_plugin_ids"] += unassgined_plugin_ids
patched_areas = [
patched_default_area if area["default"] else area
for area in self._areas]
# Define initial dock for each area
docks = {}
for area in patched_areas:
current_area = area
plugin_id = current_area["plugin_ids"][0]
plugin = main_window.get_plugin(plugin_id, error=False)
if plugin:
dock = plugin.dockwidget
docks[(current_area["row"], current_area["column"])] = dock
dock.area = area["area"]
dock.col_span = area["col_span"]
dock.row_span = area["row_span"]
plugin.toggle_view(area["visible"])
# Define base layout (distribution of dockwidgets
# following defined areas)
layout_data = []
# Find dock splits in the horizontal direction
direction = Qt.Horizontal
for row in range(0, self._rows + 1):
dock = None
for col in range(0, self._cols + 1):
key = (row, col)
if key in docks:
if dock is None:
dock = docks[key]
else:
layout_data.append(
(1/docks[key].area,
key,
dock,
docks[key],
direction))
dock = docks[key]
main_window.addDockWidget(
Qt.LeftDockWidgetArea, dock, direction)
# Find dock splits in the vertical direction
direction = Qt.Vertical
for col in range(0, self._cols + 1):
dock = None
for row in range(0, self._rows + 1):
key = (row, col)
if key in docks:
if dock is None:
dock = docks[key]
else:
layout_data.append(
(1/docks[key].area,
key,
dock,
docks[key],
direction))
dock = docks[key]
# We sort based on the inverse of the area, then the row and then
# the column. This allows to make the dock splits in the right order.
sorted_data = sorted(layout_data, key=lambda x: (x[0], x[1]))
for area, key, first, second, direction in sorted_data:
main_window.splitDockWidget(first, second, direction)
plugins_to_tabify = []
for area in patched_areas:
area_visible = area["visible"]
base_plugin = main_window.get_plugin(
area["plugin_ids"][0], error=False)
if base_plugin:
plugin_ids = area["plugin_ids"][1:]
hidden_plugin_ids = area["hidden_plugin_ids"]
for plugin_id in plugin_ids:
current_plugin = main_window.get_plugin(
plugin_id, error=False)
if current_plugin:
if (plugin_id in unassgined_plugin_ids and
hasattr(current_plugin, 'TABIFY')):
plugins_to_tabify.append(
(current_plugin, base_plugin))
else:
main_window.tabify_plugins(
base_plugin, current_plugin)
if plugin_id not in hidden_plugin_ids:
current_plugin.toggle_view(area_visible)
else:
current_plugin.toggle_view(False)
# Raise front widget per area
if area["visible"]:
base_plugin.dockwidget.show()
base_plugin.dockwidget.raise_()
# try to use the TABIFY attribute to add the plugin to the layout.
# Otherwise use the default area base plugin
for plugin, base_plugin in plugins_to_tabify:
if not main_window.tabify_plugin(plugin):
main_window.tabify_plugins(base_plugin, plugin)
current_plugin.toggle_view(False)
column_docks = []
column_stretches = []
for key, dock in docks.items():
for col, stretch in self._column_stretchs.items():
if key[1] == col and dock.col_span == 1:
column_docks.append(dock)
column_stretches.append(stretch)
row_docks = []
row_stretches = []
for key, dock in docks.items():
for row, stretch in self._row_stretchs.items():
if key[0] == row and dock.row_span == 1:
row_docks.append(dock)
row_stretches.append(stretch)
main_window.showMaximized()
main_window.resizeDocks(column_docks, column_stretches, Qt.Horizontal)
main_window.resizeDocks(row_docks, row_stretches, Qt.Vertical)
| 35.794715 | 80 | 0.534382 |
e7656f91e844e0af84259c8943a7a3e721a56df2 | 14,242 | js | JavaScript | dist/pages/main/index.js | layaCoder/wxAuthLogin | 1069c5519d944e27b4e680546122d22a8fe911be | [
"MIT"
] | null | null | null | dist/pages/main/index.js | layaCoder/wxAuthLogin | 1069c5519d944e27b4e680546122d22a8fe911be | [
"MIT"
] | null | null | null | dist/pages/main/index.js | layaCoder/wxAuthLogin | 1069c5519d944e27b4e680546122d22a8fe911be | [
"MIT"
] | null | null | null | (wx["webpackJsonp"] = wx["webpackJsonp"] || []).push([["pages/main/index"],{
/***/ "./node_modules/@tarojs/mini-runner/dist/loaders/wxTransformerLoader.js?!./src/pages/main/index.jsx?taro&type=script&parse=PAGE&":
/*!************************************************************************************************************************************************!*\
!*** ./node_modules/@tarojs/mini-runner/dist/loaders/wxTransformerLoader.js??ref--6-0!./src/pages/main/index.jsx?taro&type=script&parse=PAGE& ***!
\************************************************************************************************************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
var _class, _temp2;
var _taroWeapp = __webpack_require__(/*! @tarojs/taro-weapp */ "./node_modules/@tarojs/taro-weapp/index.js");
var _taroWeapp2 = _interopRequireDefault(_taroWeapp);
__webpack_require__(/*! ./index.less */ "./src/pages/main/index.less");
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
function _possibleConstructorReturn(self, call) { if (!self) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return call && (typeof call === "object" || typeof call === "function") ? call : self; }
function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function, not " + typeof superClass); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, enumerable: false, writable: true, configurable: true } }); if (superClass) Object.setPrototypeOf ? Object.setPrototypeOf(subClass, superClass) : subClass.__proto__ = superClass; }
var Index = (_temp2 = _class = function (_BaseComponent) {
_inherits(Index, _BaseComponent);
function Index() {
var _ref;
var _temp, _this2, _ret;
_classCallCheck(this, Index);
for (var _len = arguments.length, args = Array(_len), _key = 0; _key < _len; _key++) {
args[_key] = arguments[_key];
}
return _ret = (_temp = (_this2 = _possibleConstructorReturn(this, (_ref = Index.__proto__ || Object.getPrototypeOf(Index)).call.apply(_ref, [this].concat(args))), _this2), _this2.$usedState = ["user", "token"], _this2.config = {
navigationBarTitleText: 'Main'
}, _this2.customComponents = [], _temp), _possibleConstructorReturn(_this2, _ret);
}
_createClass(Index, [{
key: "_constructor",
value: function _constructor() {
this.state = {
user: null,
token: null
};
this.handleUpdateUserInfo = this.handleUpdateUserInfo.bind(this);
this.$$refs = new _taroWeapp2.default.RefsArray();
}
}, {
key: "componentWillMount",
value: function componentWillMount() {}
}, {
key: "componentWillMount",
value: function componentWillMount() {
var _this = this;
_taroWeapp2.default.getStorage({
key: 'user',
success: function success(res) {
var _JSON$parse = JSON.parse(res.data),
user = _JSON$parse.user,
token = _JSON$parse.token;
var checkSession = _taroWeapp2.default.request({
url: 'http://localhost:2000/wx/get/checkSession', //仅为示例,并非真实的接口地址
method: 'GET',
header: {
'content-type': 'application/json', // 默认值
'Authorization': 'Bearer ' + token
}
});
checkSession.then(function (res) {
if (res.data.auth) {
_this.setState({
user: user,
token: token
});
} else {
_taroWeapp2.default.redirectTo({
url: '/pages/login/index'
});
}
});
},
fail: function fail(err) {
_taroWeapp2.default.redirectTo({
url: '/pages/login/index'
});
}
});
}
}, {
key: "handleUpdateUserInfo",
value: function handleUpdateUserInfo() {
var token = this.state.token;
_taroWeapp2.default.request({
url: 'http://localhost:2000/wx/post/updateUserInfo', //仅为示例,并非真实的接口地址
method: 'POST',
data: {
param: 'test param here'
},
header: {
'content-type': 'application/json', // 默认值
'Authorization': 'Bearer ' + token
},
success: function success(res) {
console.log('getUser res...>', res.data);
}
});
}
}, {
key: "_createData",
value: function _createData() {
this.__state = arguments[0] || this.state || {};
this.__props = arguments[1] || this.props || {};
var __isRunloopRef = arguments[2];
var __prefix = this.$prefix;
;
Object.assign(this.__state, {});
return this.__state;
}
}]);
return Index;
}(_taroWeapp.Component), _class.$$events = ["handleUpdateUserInfo"], _class.$$componentPath = "pages/main/index", _temp2);
exports.default = Index;
Component(__webpack_require__(/*! @tarojs/taro-weapp */ "./node_modules/@tarojs/taro-weapp/index.js").default.createComponent(Index, true));
/***/ }),
/***/ "./node_modules/file-loader/dist/cjs.js?name=[path][name].wxml&context=/Users/laya/Documents/GitWorkSpace/wxAuthLogin/wxAuthLogin/src!./node_modules/@tarojs/mini-runner/dist/loaders/miniTemplateLoader.js!./node_modules/@tarojs/mini-runner/dist/loaders/wxTransformerLoader.js?!./src/pages/main/index.jsx?taro&type=template&parse=PAGE&":
/*!*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************!*\
!*** ./node_modules/file-loader/dist/cjs.js?name=[path][name].wxml&context=/Users/laya/Documents/GitWorkSpace/wxAuthLogin/wxAuthLogin/src!./node_modules/@tarojs/mini-runner/dist/loaders/miniTemplateLoader.js!./node_modules/@tarojs/mini-runner/dist/loaders/wxTransformerLoader.js??ref--6-0!./src/pages/main/index.jsx?taro&type=template&parse=PAGE& ***!
\*************************************************************************************************************************************************************************************************************************************************************************************************************************************************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
module.exports = __webpack_require__.p + "pages/main/index.wxml";
/***/ }),
/***/ "./src/pages/main/index.jsx":
/*!**********************************!*\
!*** ./src/pages/main/index.jsx ***!
\**********************************/
/*! no static exports found */
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _index_jsx_taro_type_template_parse_PAGE___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./index.jsx?taro&type=template&parse=PAGE& */ "./src/pages/main/index.jsx?taro&type=template&parse=PAGE&");
/* harmony import */ var _index_jsx_taro_type_script_parse_PAGE___WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./index.jsx?taro&type=script&parse=PAGE& */ "./src/pages/main/index.jsx?taro&type=script&parse=PAGE&");
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _index_jsx_taro_type_script_parse_PAGE___WEBPACK_IMPORTED_MODULE_1__) if(__WEBPACK_IMPORT_KEY__ !== 'default') (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _index_jsx_taro_type_script_parse_PAGE___WEBPACK_IMPORTED_MODULE_1__[key]; }) }(__WEBPACK_IMPORT_KEY__));
/***/ }),
/***/ "./src/pages/main/index.jsx?taro&type=script&parse=PAGE&":
/*!***************************************************************!*\
!*** ./src/pages/main/index.jsx?taro&type=script&parse=PAGE& ***!
\***************************************************************/
/*! no static exports found */
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _node_modules_tarojs_mini_runner_dist_loaders_wxTransformerLoader_js_ref_6_0_index_jsx_taro_type_script_parse_PAGE___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!../../../node_modules/@tarojs/mini-runner/dist/loaders/wxTransformerLoader.js??ref--6-0!./index.jsx?taro&type=script&parse=PAGE& */ "./node_modules/@tarojs/mini-runner/dist/loaders/wxTransformerLoader.js?!./src/pages/main/index.jsx?taro&type=script&parse=PAGE&");
/* harmony import */ var _node_modules_tarojs_mini_runner_dist_loaders_wxTransformerLoader_js_ref_6_0_index_jsx_taro_type_script_parse_PAGE___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_node_modules_tarojs_mini_runner_dist_loaders_wxTransformerLoader_js_ref_6_0_index_jsx_taro_type_script_parse_PAGE___WEBPACK_IMPORTED_MODULE_0__);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _node_modules_tarojs_mini_runner_dist_loaders_wxTransformerLoader_js_ref_6_0_index_jsx_taro_type_script_parse_PAGE___WEBPACK_IMPORTED_MODULE_0__) if(__WEBPACK_IMPORT_KEY__ !== 'default') (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _node_modules_tarojs_mini_runner_dist_loaders_wxTransformerLoader_js_ref_6_0_index_jsx_taro_type_script_parse_PAGE___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
/* harmony default export */ __webpack_exports__["default"] = (_node_modules_tarojs_mini_runner_dist_loaders_wxTransformerLoader_js_ref_6_0_index_jsx_taro_type_script_parse_PAGE___WEBPACK_IMPORTED_MODULE_0___default.a);
/***/ }),
/***/ "./src/pages/main/index.jsx?taro&type=template&parse=PAGE&":
/*!*****************************************************************!*\
!*** ./src/pages/main/index.jsx?taro&type=template&parse=PAGE& ***!
\*****************************************************************/
/*! no static exports found */
/***/ (function(module, __webpack_exports__, __webpack_require__) {
"use strict";
__webpack_require__.r(__webpack_exports__);
/* harmony import */ var _file_loader_name_path_name_wxml_context_Users_laya_Documents_GitWorkSpace_wxAuthLogin_wxAuthLogin_src_node_modules_tarojs_mini_runner_dist_loaders_miniTemplateLoader_js_node_modules_tarojs_mini_runner_dist_loaders_wxTransformerLoader_js_ref_6_0_index_jsx_taro_type_template_parse_PAGE___WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! -!file-loader?name=[path][name].wxml&context=/Users/laya/Documents/GitWorkSpace/wxAuthLogin/wxAuthLogin/src!../../../node_modules/@tarojs/mini-runner/dist/loaders/miniTemplateLoader.js!../../../node_modules/@tarojs/mini-runner/dist/loaders/wxTransformerLoader.js??ref--6-0!./index.jsx?taro&type=template&parse=PAGE& */ "./node_modules/file-loader/dist/cjs.js?name=[path][name].wxml&context=/Users/laya/Documents/GitWorkSpace/wxAuthLogin/wxAuthLogin/src!./node_modules/@tarojs/mini-runner/dist/loaders/miniTemplateLoader.js!./node_modules/@tarojs/mini-runner/dist/loaders/wxTransformerLoader.js?!./src/pages/main/index.jsx?taro&type=template&parse=PAGE&");
/* harmony import */ var _file_loader_name_path_name_wxml_context_Users_laya_Documents_GitWorkSpace_wxAuthLogin_wxAuthLogin_src_node_modules_tarojs_mini_runner_dist_loaders_miniTemplateLoader_js_node_modules_tarojs_mini_runner_dist_loaders_wxTransformerLoader_js_ref_6_0_index_jsx_taro_type_template_parse_PAGE___WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_file_loader_name_path_name_wxml_context_Users_laya_Documents_GitWorkSpace_wxAuthLogin_wxAuthLogin_src_node_modules_tarojs_mini_runner_dist_loaders_miniTemplateLoader_js_node_modules_tarojs_mini_runner_dist_loaders_wxTransformerLoader_js_ref_6_0_index_jsx_taro_type_template_parse_PAGE___WEBPACK_IMPORTED_MODULE_0__);
/* harmony reexport (unknown) */ for(var __WEBPACK_IMPORT_KEY__ in _file_loader_name_path_name_wxml_context_Users_laya_Documents_GitWorkSpace_wxAuthLogin_wxAuthLogin_src_node_modules_tarojs_mini_runner_dist_loaders_miniTemplateLoader_js_node_modules_tarojs_mini_runner_dist_loaders_wxTransformerLoader_js_ref_6_0_index_jsx_taro_type_template_parse_PAGE___WEBPACK_IMPORTED_MODULE_0__) if(__WEBPACK_IMPORT_KEY__ !== 'default') (function(key) { __webpack_require__.d(__webpack_exports__, key, function() { return _file_loader_name_path_name_wxml_context_Users_laya_Documents_GitWorkSpace_wxAuthLogin_wxAuthLogin_src_node_modules_tarojs_mini_runner_dist_loaders_miniTemplateLoader_js_node_modules_tarojs_mini_runner_dist_loaders_wxTransformerLoader_js_ref_6_0_index_jsx_taro_type_template_parse_PAGE___WEBPACK_IMPORTED_MODULE_0__[key]; }) }(__WEBPACK_IMPORT_KEY__));
/***/ }),
/***/ "./src/pages/main/index.less":
/*!***********************************!*\
!*** ./src/pages/main/index.less ***!
\***********************************/
/*! no static exports found */
/***/ (function(module, exports, __webpack_require__) {
// extracted by mini-css-extract-plugin
/***/ })
},[["./src/pages/main/index.jsx","runtime","taro","vendors"]]]); | 65.031963 | 1,022 | 0.665075 |
ddd1c5fdaefd83a90ba7d2244df98a8f81723080 | 964 | php | PHP | resources/views/admin/email/form_massage.blade.php | popkovslava/dzen | d84d30f74180d3e0896a375060e4b9353250e99f | [
"MIT"
] | null | null | null | resources/views/admin/email/form_massage.blade.php | popkovslava/dzen | d84d30f74180d3e0896a375060e4b9353250e99f | [
"MIT"
] | null | null | null | resources/views/admin/email/form_massage.blade.php | popkovslava/dzen | d84d30f74180d3e0896a375060e4b9353250e99f | [
"MIT"
] | null | null | null | @section('email.form_message')
<div style="background: #fff;padding:20px">
@if(session('success'))
<div class="alert alert-success alert-message">
<button type="button" data-dismiss="alert" aria-label="Close" class="close"><span aria-hidden="true">?</span></button>
<i class="fa fa-check fa-lg"></i> {{session('success')}}
</div>
@endif
<form method="post" action="email_client_massage" >
<input name="_token" type="hidden" value="{{ csrf_token() }}"/>
<div class="form-group form-element-wysiwyg ">
<label>Email client massage</label>
<textarea id="ckview" name="massage_email" class="form-control" cols="30" rows="10">{{($massage)?$massage->massage_email:''}}</textarea>
</div>
<button type="submit" class="btn btn-primary">Save</button>
</form>
</div>
@show
| 22.418605 | 155 | 0.551867 |
87091db712534a0f891de14982806f28a4318f7e | 2,201 | rs | Rust | src/solution/s0673_number_of_longest_increasing_subsequence.rs | tan-wei/my-leetcode-rust | 3d7892a42294fe4891db396573b8ba81e9294380 | [
"Apache-2.0"
] | null | null | null | src/solution/s0673_number_of_longest_increasing_subsequence.rs | tan-wei/my-leetcode-rust | 3d7892a42294fe4891db396573b8ba81e9294380 | [
"Apache-2.0"
] | null | null | null | src/solution/s0673_number_of_longest_increasing_subsequence.rs | tan-wei/my-leetcode-rust | 3d7892a42294fe4891db396573b8ba81e9294380 | [
"Apache-2.0"
] | null | null | null | /**
* [0673] Number of Longest Increasing Subsequence
*
* Given an integer array nums, return the number of longest increasing subsequences.
* Notice that the sequence has to be strictly increasing.
*
* Example 1:
*
* Input: nums = [1,3,5,4,7]
* Output: 2
* Explanation: The two longest increasing subsequences are [1, 3, 4, 7] and [1, 3, 5, 7].
*
* Example 2:
*
* Input: nums = [2,2,2,2,2]
* Output: 5
* Explanation: The length of longest continuous increasing subsequence is 1, and there are 5 subsequences' length is 1, so output 5.
*
*
* Constraints:
*
* 1 <= nums.length <= 2000
* -10^6 <= nums[i] <= 10^6
*
*/
pub struct Solution {}
// problem: https://leetcode.com/problems/number-of-longest-increasing-subsequence/
// discuss: https://leetcode.com/problems/number-of-longest-increasing-subsequence/discuss/?currentPage=1&orderBy=most_votes&query=
// submission codes start here
impl Solution {
pub fn find_number_of_lis(nums: Vec<i32>) -> i32 {
let mut result = 0;
let mut max_len = 0;
// dp[i]: (length, number of LIS which ends with nums[i])
let mut dp = vec![(1, 1); nums.len()];
for i in 0..nums.len() {
for j in 0..i {
if nums[i] > nums[j] {
if dp[i].0 == dp[j].0 + 1 {
dp[i].1 += dp[j].1;
}
if dp[i].0 < dp[j].0 + 1 {
dp[i] = (dp[j].0 + 1, dp[j].1);
}
}
}
if max_len == dp[i].0 {
result += dp[i].1;
}
if max_len < dp[i].0 {
max_len = dp[i].0;
result = dp[i].1;
}
}
result
}
}
// submission codes end
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn test_0673_example_1() {
let nums = vec![1, 3, 5, 4, 7];
let result = 2;
assert_eq!(Solution::find_number_of_lis(nums), result);
}
#[test]
fn test_0673_example_2() {
let nums = vec![2, 2, 2, 2, 2];
let result = 5;
assert_eq!(Solution::find_number_of_lis(nums), result);
}
}
| 24.730337 | 133 | 0.51522 |
dd79e174db012fee91e8dec95fb5826f7c11d2ed | 1,532 | php | PHP | app/Notifications/Auth/ContractEmail.php | kleitz/irent | 330eaa374b538fffed04e06441ed23bb67be5b4b | [
"MIT"
] | 3 | 2021-05-15T16:16:06.000Z | 2021-09-29T08:36:33.000Z | app/Notifications/Auth/ContractEmail.php | reinhardodhiambo/irent | a9a3e363dfa4e4bc8067b2c26dd353bcff9b8f66 | [
"MIT"
] | null | null | null | app/Notifications/Auth/ContractEmail.php | reinhardodhiambo/irent | a9a3e363dfa4e4bc8067b2c26dd353bcff9b8f66 | [
"MIT"
] | 3 | 2018-04-16T11:30:46.000Z | 2021-05-15T16:16:07.000Z | <?php
namespace App\Notifications\Auth;
use Illuminate\Bus\Queueable;
use Illuminate\Notifications\Notification;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Notifications\Messages\MailMessage;
class ContractEmail extends Notification
{
use Queueable;
/**
* Create a new notification instance.
*
* @return void
*/
public function __construct()
{
//
}
/**
* Get the notification's delivery channels.
*
* @param mixed $notifiable
* @return array
*/
public function via($notifiable)
{
return ['mail'];
}
/**
* Get the mail representation of the notification.
*
* @param mixed $notifiable
* @return \Illuminate\Notifications\Messages\MailMessage
*/
public function toMail($notifiable)
{
$mailMessage = new MailMessage();
$mailMessage->subject('House Contract');
$mailMessage->greeting('Hi '.$notifiable->name);
$mailMessage->line('Find your attached contract below.');
$mailMessage->line('Fill, Scan and email it back');
$mailMessage->attach(public_path('/').'sample.pdf', [
'as' => 'sample.pdf',
'mime' => 'application/pdf',
]);
return $mailMessage;
}
/**
* Get the array representation of the notification.
*
* @param mixed $notifiable
* @return array
*/
public function toArray($notifiable)
{
return [
//
];
}
}
| 21.885714 | 65 | 0.586815 |
40b01b98905dbd306e4d65b59d6a41571cf14955 | 280 | py | Python | gnsstools/util.py | wumouyan/GNSS-SDR-Python | 61292c2ba151724538808663e2a6d0b048635401 | [
"MIT"
] | 68 | 2015-06-23T17:30:06.000Z | 2022-03-29T22:06:54.000Z | gnsstools/util.py | wumouyan/GNSS-SDR-Python | 61292c2ba151724538808663e2a6d0b048635401 | [
"MIT"
] | 4 | 2018-03-01T05:14:36.000Z | 2021-12-05T11:07:39.000Z | gnsstools/util.py | wumouyan/GNSS-SDR-Python | 61292c2ba151724538808663e2a6d0b048635401 | [
"MIT"
] | 43 | 2015-06-26T10:27:05.000Z | 2022-03-30T02:47:09.000Z | def parse_list_ranges(s,sep='-'):
r = []
x = s.split(',')
for y in x:
z = y.split(sep)
if len(z)==1:
r += [int(z[0])]
else:
r += range(int(z[0]),int(z[1])+1)
return list(r)
def parse_list_floats(s):
x = s.split(',')
return list(map(float, x))
| 18.666667 | 39 | 0.503571 |
b964a1191fc332cf6f399dba1559b32d092e743a | 1,539 | h | C | digsby/ext/src/Animation/TextLayer.h | ifwe/digsby | f5fe00244744aa131e07f09348d10563f3d8fa99 | [
"Python-2.0"
] | 35 | 2015-08-15T14:32:38.000Z | 2021-12-09T16:21:26.000Z | digsby/ext/src/Animation/TextLayer.h | niterain/digsby | 16a62c7df1018a49eaa8151c0f8b881c7e252949 | [
"Python-2.0"
] | 4 | 2015-09-12T10:42:57.000Z | 2017-02-27T04:05:51.000Z | digsby/ext/src/Animation/TextLayer.h | niterain/digsby | 16a62c7df1018a49eaa8151c0f8b881c7e252949 | [
"Python-2.0"
] | 15 | 2015-07-10T23:58:07.000Z | 2022-01-23T22:16:33.000Z | #ifndef _ANIMATION_TEXTLAYER_H__
#define _ANIMATION_TEXTLAYER_H__
#include "Layer.h"
enum AlignmentMode
{
AlignmentNatural,
AlignmentLeft,
AlignmentRight,
AlignmentCenter,
AlignmentJustified
};
enum TruncationMode
{
TruncationNone,
TruncationStart,
TruncationEnd,
TruncationMiddle
};
class TextLayer : public Layer
{
public:
TextLayer();
TextLayer(Layer* modelLayer);
TextLayer(const String& string);
virtual ~TextLayer() {}
virtual void _init();
Font font() const { return m_font; }
void setFont(const Font& font);
AlignmentMode alignmentMode() const;
void setAlignmentMode(AlignmentMode alignmentMode);
float fontSize() const { return m_fontSize; }
void setFontSize(float fontSize);
Color foregroundColor() const { return Color(m_red*255, m_green*255, m_blue*255, m_alpha*255); }
void setForegroundColor(const Color& foregroundColor);
String string() const { return m_string; }
void setString(const String& string);
TruncationMode truncationMode() const { return m_truncationMode; }
void setTruncationMode(TruncationMode truncationMode);
protected:
virtual Layer* createPresentationLayer(Layer* modelLayer) { return new TextLayer(modelLayer); }
virtual void renderContent(GraphicsContext* context);
Font m_font;
float m_fontSize;
double m_red, m_green, m_blue, m_alpha;
String m_string;
TruncationMode m_truncationMode;
AlignmentMode m_alignmentMode;
};
#endif _ANIMATION_TEXTLAYER_H__
| 23.676923 | 100 | 0.732294 |
97d7262d0937bf3e30fa498971aa831f1b5a07fd | 459 | asm | Assembly | oeis/025/A025932.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 11 | 2021-08-22T19:44:55.000Z | 2022-03-20T16:47:57.000Z | oeis/025/A025932.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 9 | 2021-08-29T13:15:54.000Z | 2022-03-09T19:52:31.000Z | oeis/025/A025932.asm | neoneye/loda-programs | 84790877f8e6c2e821b183d2e334d612045d29c0 | [
"Apache-2.0"
] | 3 | 2021-08-22T20:56:47.000Z | 2021-09-29T06:26:12.000Z | ; A025932: Expansion of 1/((1-2x)(1-3x)(1-5x)(1-8x)).
; Submitted by Jon Maiga
; 1,18,213,2114,19173,165354,1384741,11393778,92748645,750039290,6040740069,48528576642,389243479717,3119026937226,24977625311397,199948094540306,1600220345577189,12804941098049562,102455421613293925
mov $1,1
mov $2,$0
mov $3,$0
lpb $2
mov $0,$3
sub $2,1
sub $0,$2
seq $0,17521 ; Expansion of 1/((1-3*x)*(1-5*x)*(1-8*x)).
sub $0,$1
mul $1,3
add $1,$0
lpe
mov $0,$1
| 25.5 | 199 | 0.688453 |
1583e948262b2edf61b474ca3050fbc808f41714 | 13,804 | kt | Kotlin | kafka-connect-neo4j/src/test/kotlin/streams/kafka/connect/sink/Neo4jValueConverterTest.kt | larusba/neo4j-streams | e1245cc06a02bc66549acd7a85e9c991657f9b8e | [
"Apache-2.0"
] | null | null | null | kafka-connect-neo4j/src/test/kotlin/streams/kafka/connect/sink/Neo4jValueConverterTest.kt | larusba/neo4j-streams | e1245cc06a02bc66549acd7a85e9c991657f9b8e | [
"Apache-2.0"
] | null | null | null | kafka-connect-neo4j/src/test/kotlin/streams/kafka/connect/sink/Neo4jValueConverterTest.kt | larusba/neo4j-streams | e1245cc06a02bc66549acd7a85e9c991657f9b8e | [
"Apache-2.0"
] | null | null | null | package streams.kafka.connect.sink
import org.apache.kafka.connect.data.*
import org.junit.Test
import org.neo4j.driver.Value
import org.neo4j.driver.Values
import org.neo4j.driver.internal.value.*
import streams.kafka.connect.sink.converters.Neo4jValueConverter
import java.math.BigDecimal
import java.time.Instant
import java.time.ZoneId
import java.util.Date
import kotlin.test.assertEquals
import kotlin.test.assertTrue
class Neo4jValueConverterTest {
@Test
fun `should convert tree struct into map of neo4j values`() {
// given
// this test generates a simple tree structure like this
// body
// / \
// p ul
// |
// li
val body = getTreeStruct()
// when
val result = Neo4jValueConverter().convert(body) as Map<*, *>
// then
val expected = getExpectedMap()
assertEquals(expected, result)
}
@Test
fun `should convert tree simple map into map of neo4j values`() {
// given
// this test generates a simple tree structure like this
// body
// / \
// p ul
// |
// li
val body = getTreeMap()
// when
val result = Neo4jValueConverter().convert(body) as Map<*, *>
// then
val expected = getExpectedMap()
assertEquals(expected, result)
}
@Test
fun `should convert tree with mixes types into map of neo4j values`() {
val utc = ZoneId.of("UTC")
val result = Neo4jValueConverter().convert(Struct(TEST_SCHEMA)) as Map<String, Value?>
val target = result["target"]
assertTrue{ target is FloatValue }
assertEquals(123.4, target?.asDouble())
val largeDecimal = result["largeDecimal"]
assertTrue{ largeDecimal is StringValue }
assertEquals(BigDecimal.valueOf(Double.MAX_VALUE).pow(2).toPlainString(), largeDecimal?.asString())
val byteArray = result["byteArray"]
assertTrue{ byteArray is BytesValue }
assertEquals("Foo".toByteArray().map { it }, byteArray?.asByteArray()?.map { it })
val int64 = result["int64"]
assertTrue{ int64 is IntegerValue }
assertEquals(Long.MAX_VALUE, int64?.asLong())
val int64Timestamp = result["int64Timestamp"]
assertTrue{ int64Timestamp is LocalDateTimeValue }
assertEquals(Date.from(Instant.ofEpochMilli(789)).toInstant().atZone(utc).toLocalDateTime(), int64Timestamp?.asLocalDateTime())
val int32 = result["int32"]
assertTrue{ int32 is IntegerValue }
assertEquals(123, int32?.asInt())
val int32Date = result["int32Date"]
assertTrue{ int32Date is DateValue }
assertEquals(Date.from(Instant.ofEpochMilli(456)).toInstant().atZone(utc).toLocalDate(), int32Date?.asLocalDate())
val int32Time = result["int32Time"]
assertTrue{ int32Time is LocalTimeValue }
assertEquals(Date.from(Instant.ofEpochMilli(123)).toInstant().atZone(utc).toLocalTime(), int32Time?.asLocalTime())
val nullField = result["nullField"]
assertTrue{ nullField is NullValue }
val nullFieldBytes = result["nullFieldBytes"]
assertTrue{ nullFieldBytes is NullValue }
}
@Test
fun `should convert BigDecimal into String neo4j value if is a positive less than Double MIN_VALUE`() {
val number = BigDecimal.valueOf(Double.MIN_VALUE).pow(2)
val result = Neo4jValueConverter().convert(getItemElement(number))
val item = result["item"]
assertTrue{ item is StringValue }
assertEquals(number.toPlainString(), item?.asString())
val result2 = Neo4jValueConverter().convert(getItemElement(null))
val item2 = result2["item"]
assertTrue{ item2 is NullValue }
}
@Test
fun `should convert BigDecimal into String neo4j value if is a negative less than Double MAX_VALUE`() {
val number = - (BigDecimal.valueOf(Double.MAX_VALUE)).multiply(BigDecimal.valueOf(2))
val result = Neo4jValueConverter().convert(getItemElement(number))
val item = result["item"]
assertTrue{ item is StringValue }
assertEquals(number.toPlainString(), item?.asString())
}
@Test
fun `should convert BigDecimal into String neo4j value if is greater than Double MAX_VALUE`() {
val number = BigDecimal.valueOf(Double.MAX_VALUE).pow(2)
val result = Neo4jValueConverter().convert(getItemElement(number))
val item = result["item"]
assertTrue{ item is StringValue }
assertEquals(number.toPlainString(), item?.asString())
}
@Test
fun `should convert BigDecimal into Double neo4j value if is less than Double MAX_VALUE and greater than Double MIN_VALUE`() {
val number = 3456.78
val result = Neo4jValueConverter().convert(getItemElement(BigDecimal.valueOf(number)))
val item = result["item"]
assertTrue{ item is FloatValue }
assertEquals(number, item?.asDouble())
}
@Test
fun `should convert BigDecimal into Double neo4j value if is equal to Double MAX_VALUE`() {
val number = Double.MAX_VALUE
val result = Neo4jValueConverter().convert(getItemElement(BigDecimal.valueOf(number)))
val item = result["item"]
assertTrue{ item is FloatValue }
assertEquals(number, item?.asDouble())
}
@Test
fun `should convert properly mixed items`() {
val double = Double.MAX_VALUE
val long = Long.MAX_VALUE
val bigDouble = BigDecimal.valueOf(Double.MAX_VALUE).pow(2)
val string = "FooBar"
val date = Date()
val result = Neo4jValueConverter().convert(mapOf(
"double" to double,
"long" to long,
"bigDouble" to bigDouble,
"string" to string,
"date" to date))
assertEquals(double, result["double"]?.asDouble())
assertEquals(long, result["long"]?.asLong())
assertEquals(bigDouble.toPlainString(), result["bigDouble"]?.asString())
assertEquals(string, result["string"]?.asString())
assertEquals(date.toInstant().atZone(ZoneId.of("UTC")).toLocalDateTime(), result["date"]?.asLocalDateTime())
}
@Test
fun `should be able to process a nested AVRO structure`() {
val trainSchema = SchemaBuilder.struct()
.field("internationalTrainNumber", Schema.STRING_SCHEMA)
.field("trainDate", Schema.STRING_SCHEMA).build()
val mySchema = SchemaBuilder.struct()
.field("trainId", trainSchema)
.field("coreId", Schema.STRING_SCHEMA).build()
val trainIdStruct = Struct(trainSchema)
.put("internationalTrainNumber", "46261")
.put("trainDate", "2021-05-20")
val rootStruct = Struct(mySchema)
.put("trainId", trainIdStruct)
.put("coreId", "000000046261")
val result = Neo4jValueConverter().convert(rootStruct) as Map<*, *>
}
companion object {
private val LI_SCHEMA = SchemaBuilder.struct().name("org.neo4j.example.html.LI")
.field("value", Schema.OPTIONAL_STRING_SCHEMA)
.field("class", SchemaBuilder.array(Schema.STRING_SCHEMA).optional())
.build()
private val UL_SCHEMA = SchemaBuilder.struct().name("org.neo4j.example.html.UL")
.field("value", SchemaBuilder.array(LI_SCHEMA))
.build()
private val P_SCHEMA = SchemaBuilder.struct().name("org.neo4j.example.html.P")
.field("value", Schema.OPTIONAL_STRING_SCHEMA)
.build()
private val BODY_SCHEMA = SchemaBuilder.struct().name("org.neo4j.example.html.BODY")
.field("ul", SchemaBuilder.array(UL_SCHEMA).optional())
.field("p", SchemaBuilder.array(P_SCHEMA).optional())
.build()
private val TEST_SCHEMA = SchemaBuilder.struct().name("test.schema")
.field("target",
ConnectSchema(Schema.Type.BYTES,
false,
BigDecimal.valueOf(123.4),
Decimal.LOGICAL_NAME,
null, null))
.field("largeDecimal",
ConnectSchema(Schema.Type.BYTES,
false,
BigDecimal.valueOf(Double.MAX_VALUE).pow(2),
Decimal.LOGICAL_NAME,
null, null))
.field("byteArray",
ConnectSchema(Schema.Type.BYTES,
false,
"Foo".toByteArray(),
"name.byteArray",
null, null))
.field("int64",
ConnectSchema(Schema.Type.INT64,
false,
Long.MAX_VALUE,
"name.int64",
null, null))
.field("int64Timestamp",
ConnectSchema(Schema.Type.INT64,
false,
Date.from(Instant.ofEpochMilli(789)),
Timestamp.LOGICAL_NAME,
null, null))
.field("int32",
ConnectSchema(Schema.Type.INT32,
false,
123,
"name.int32",
null, null))
.field("int32Date",
ConnectSchema(Schema.Type.INT32,
false,
Date.from(Instant.ofEpochMilli(456)),
org.apache.kafka.connect.data.Date.LOGICAL_NAME,
null, null))
.field("int32Time",
ConnectSchema(Schema.Type.INT32,
false,
Date.from(Instant.ofEpochMilli(123)),
Time.LOGICAL_NAME,
null, null))
.field("nullField",
ConnectSchema(Schema.Type.INT64,
false,
null,
Time.LOGICAL_NAME,
null, null))
.field("nullFieldBytes",
ConnectSchema(Schema.Type.BYTES,
false,
null,
Time.LOGICAL_NAME,
null, null))
.build()
fun getTreeStruct(): Struct? {
val firstUL = Struct(UL_SCHEMA).put("value", listOf(
Struct(LI_SCHEMA).put("value", "First UL - First Element"),
Struct(LI_SCHEMA).put("value", "First UL - Second Element")
.put("class", listOf("ClassA", "ClassB"))
))
val secondUL = Struct(UL_SCHEMA).put("value", listOf(
Struct(LI_SCHEMA).put("value", "Second UL - First Element"),
Struct(LI_SCHEMA).put("value", "Second UL - Second Element")
))
val ulList = listOf(firstUL, secondUL)
val pList = listOf(
Struct(P_SCHEMA).put("value", "First Paragraph"),
Struct(P_SCHEMA).put("value", "Second Paragraph")
)
return Struct(BODY_SCHEMA)
.put("ul", ulList)
.put("p", pList)
}
fun getExpectedMap(): Map<String, Value> {
val firstULMap = mapOf("value" to listOf(
mapOf("value" to Values.value("First UL - First Element"), "class" to Values.NULL),
mapOf("value" to Values.value("First UL - Second Element"), "class" to Values.value(listOf("ClassA", "ClassB")))))
val secondULMap = mapOf("value" to listOf(
mapOf("value" to Values.value("Second UL - First Element"), "class" to Values.NULL),
mapOf("value" to Values.value("Second UL - Second Element"), "class" to Values.NULL)))
val ulListMap = Values.value(listOf(firstULMap, secondULMap))
val pListMap = Values.value(listOf(mapOf("value" to Values.value("First Paragraph")),
mapOf("value" to Values.value("Second Paragraph"))))
return mapOf("ul" to ulListMap, "p" to pListMap)
}
fun getTreeMap(): Map<String, Any?> {
val firstULMap = mapOf("value" to listOf(
mapOf("value" to "First UL - First Element", "class" to null),
mapOf("value" to "First UL - Second Element", "class" to listOf("ClassA", "ClassB"))))
val secondULMap = mapOf("value" to listOf(
mapOf("value" to "Second UL - First Element", "class" to null),
mapOf("value" to "Second UL - Second Element", "class" to null)))
val ulListMap = listOf(firstULMap, secondULMap)
val pListMap = listOf(mapOf("value" to "First Paragraph"),
mapOf("value" to "Second Paragraph"))
return mapOf("ul" to ulListMap, "p" to pListMap)
}
fun getItemElement(number: Any?): Map<String, Any?> = mapOf("item" to number)
}
}
| 41.083333 | 135 | 0.544118 |
81d8475e2244c8b6893249e8b8b0843874725d2b | 3,378 | go | Go | topology/probes/k8s/deployment.go | ErwanAliasr1/skydive | b0b52d5be515b9dc98c026d0b869e8b62198b103 | [
"Apache-2.0"
] | null | null | null | topology/probes/k8s/deployment.go | ErwanAliasr1/skydive | b0b52d5be515b9dc98c026d0b869e8b62198b103 | [
"Apache-2.0"
] | null | null | null | topology/probes/k8s/deployment.go | ErwanAliasr1/skydive | b0b52d5be515b9dc98c026d0b869e8b62198b103 | [
"Apache-2.0"
] | null | null | null | /*
* Copyright (C) 2018 IBM, Inc.
*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance
* with the License. You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*
*/
package k8s
import (
"fmt"
"github.com/skydive-project/skydive/logging"
"github.com/skydive-project/skydive/probe"
"github.com/skydive-project/skydive/topology/graph"
"k8s.io/api/extensions/v1beta1"
"k8s.io/client-go/tools/cache"
)
type deployProbe struct {
defaultKubeCacheEventHandler
*kubeCache
graph *graph.Graph
}
func dumpDeployment(deploy *v1beta1.Deployment) string {
return fmt.Sprintf("deployment{Namespace: %s, Name: %s}", deploy.Namespace, deploy.Name)
}
func (p *deployProbe) newMetadata(deploy *v1beta1.Deployment) graph.Metadata {
m := newMetadata("deployment", deploy.Namespace, deploy.Name, deploy)
m.SetFieldAndNormalize("Selector", deploy.Spec.Selector)
m.SetField("DesiredReplicas", int32ValueOrDefault(deploy.Spec.Replicas, 1))
m.SetField("Replicas", deploy.Status.Replicas)
m.SetField("ReadyReplicas", deploy.Status.ReadyReplicas)
m.SetField("AvailableReplicas", deploy.Status.AvailableReplicas)
m.SetField("UnavailableReplicas", deploy.Status.UnavailableReplicas)
return m
}
func deployUID(deploy *v1beta1.Deployment) graph.Identifier {
return graph.Identifier(deploy.GetUID())
}
func (p *deployProbe) OnAdd(obj interface{}) {
if deploy, ok := obj.(*v1beta1.Deployment); ok {
p.graph.Lock()
defer p.graph.Unlock()
newNode(p.graph, deployUID(deploy), p.newMetadata(deploy))
logging.GetLogger().Debugf("Added %s", dumpDeployment(deploy))
}
}
func (p *deployProbe) OnUpdate(oldObj, newObj interface{}) {
if deploy, ok := newObj.(*v1beta1.Deployment); ok {
p.graph.Lock()
defer p.graph.Unlock()
if deployNode := p.graph.GetNode(deployUID(deploy)); deployNode != nil {
addMetadata(p.graph, deployNode, deploy)
logging.GetLogger().Debugf("Updated %s", dumpDeployment(deploy))
}
}
}
func (p *deployProbe) OnDelete(obj interface{}) {
if deploy, ok := obj.(*v1beta1.Deployment); ok {
p.graph.Lock()
defer p.graph.Unlock()
if deployNode := p.graph.GetNode(deployUID(deploy)); deployNode != nil {
p.graph.DelNode(deployNode)
logging.GetLogger().Debugf("Deleted %s", dumpDeployment(deploy))
}
}
}
func (p *deployProbe) Start() {
p.kubeCache.Start()
}
func (p *deployProbe) Stop() {
p.kubeCache.Stop()
}
func newDeploymentKubeCache(handler cache.ResourceEventHandler) *kubeCache {
return newKubeCache(getClientset().ExtensionsV1beta1().RESTClient(), &v1beta1.Deployment{}, "deployments", handler)
}
func newDeploymentProbe(g *graph.Graph) probe.Probe {
p := &deployProbe{
graph: g,
}
p.kubeCache = newDeploymentKubeCache(p)
return p
}
| 29.631579 | 116 | 0.736827 |
e9602ffd39379fc692b860e71a3accd443cd3dba | 666 | swift | Swift | Agent/Classes/Response.swift | miuP/Agent | 6138632e1334ed1e3ef6b7fe1f8db9abf58b0e03 | [
"MIT"
] | 1 | 2017-10-13T07:43:54.000Z | 2017-10-13T07:43:54.000Z | Agent/Classes/Response.swift | miuP/Agent | 6138632e1334ed1e3ef6b7fe1f8db9abf58b0e03 | [
"MIT"
] | null | null | null | Agent/Classes/Response.swift | miuP/Agent | 6138632e1334ed1e3ef6b7fe1f8db9abf58b0e03 | [
"MIT"
] | null | null | null | //
// Response.swift
// Agent
//
// Created by miup on 2017/10/12.
//
import Foundation
public enum AlgoliaResponseError: Error {
case cannnotDecodeResponse
}
public struct AlgoliaResponse<T: Decodable>: Decodable {
typealias HitType = T
let page: Int
let params: String
let processingTimeMS: Int
let query: String
let exhaustiveNbHits: Int
let nbPages: Int
let hits: [HitType]
let hitsPerPage: Int
let nbHits: Int
}
public struct FacetValuesResponse: Decodable {
struct Content: Decodable {
let value: String
let highlighted: String
let count: Int
}
let facetHits: [Content]
}
| 18.5 | 56 | 0.668168 |
290a9fdb3a242adb86cc82372bc6461f0b689ed5 | 100 | py | Python | python/y2020/d14/__main__.py | luke-dixon/aoc | 94851a5866a1ef29e3ba10098160cba883882683 | [
"MIT"
] | 1 | 2021-01-12T20:04:01.000Z | 2021-01-12T20:04:01.000Z | python/y2020/d14/__main__.py | luke-dixon/aoc | 94851a5866a1ef29e3ba10098160cba883882683 | [
"MIT"
] | null | null | null | python/y2020/d14/__main__.py | luke-dixon/aoc | 94851a5866a1ef29e3ba10098160cba883882683 | [
"MIT"
] | null | null | null | import sys
from .day14 import Day14
if __name__ == '__main__':
Day14(args=sys.argv[1:]).run()
| 14.285714 | 34 | 0.67 |
aff5448312b59599a70708dfb24968134f4a9795 | 983 | podspec | Ruby | IncrementableLabel.podspec | s4cha/IncrementableLabel | 8e0bed46a0dbb012a3fd9ceae642a1a0297d767e | [
"MIT"
] | 61 | 2016-11-16T11:25:08.000Z | 2022-02-04T19:20:02.000Z | IncrementableLabel.podspec | s4cha/IncrementableLabel | 8e0bed46a0dbb012a3fd9ceae642a1a0297d767e | [
"MIT"
] | 6 | 2017-03-14T19:14:28.000Z | 2020-02-21T08:57:09.000Z | IncrementableLabel.podspec | s4cha/IncrementableLabel | 8e0bed46a0dbb012a3fd9ceae642a1a0297d767e | [
"MIT"
] | 11 | 2017-07-14T20:22:45.000Z | 2022-02-04T19:20:07.000Z | Pod::Spec.new do |s|
# ――― Spec Metadata ―――――――――――――――――――――――――――――――――――――――――――――――――――――――――― #
s.name = "IncrementableLabel"
s.module_name = "IncrementableLabel"
s.version = "4.0.0"
s.summary = "IncrementableLabel is the easiest way to have incrementable numbers in an UILabel!"
s.description = "IncrementableLabel is the easiest way to have incrementable numbers in an UILabel! Available on iOS and tVOS"
s.homepage = "https://github.com/recisio/IncrementableLabel"
s.license = { :type => "MIT", :file => "LICENSE" }
s.author = { "Recisio" => "tom.baranes@gmail.com" }
s.source = { :git => "https://github.com/recisio/IncrementableLabel.git", :tag => "#{s.version}" }
# ――― Spec tech ――――――――――――――――――――――――――――――――――――――――――――――――――――――――――― #
s.ios.deployment_target = '8.0'
s.tvos.deployment_target = '9.0'
s.requires_arc = true
s.source_files = 'Source/*.swift'
end
| 40.958333 | 132 | 0.547304 |
cd7cdca85cf8c96f41b2dcac8a47c1b3bed54453 | 555 | asm | Assembly | solutions/48 - Community Training Day/size-6_speed-6.asm | michaelgundlach/7billionhumans | 02c6f3963364362c95cb516cbc6ef1efc073bb2e | [
"MIT"
] | 45 | 2018-09-05T04:56:59.000Z | 2021-11-22T08:57:26.000Z | solutions/48 - Community Training Day/size-6_speed-6.asm | michaelgundlach/7billionhumans | 02c6f3963364362c95cb516cbc6ef1efc073bb2e | [
"MIT"
] | 36 | 2018-09-01T11:34:26.000Z | 2021-05-19T23:20:49.000Z | solutions/48 - Community Training Day/size-6_speed-6.asm | michaelgundlach/7billionhumans | 02c6f3963364362c95cb516cbc6ef1efc073bb2e | [
"MIT"
] | 36 | 2018-09-01T07:44:19.000Z | 2021-09-10T19:07:35.000Z | -- 7 Billion Humans (2087) --
-- 48: Community Training Day --
-- Author: landfillbaby
-- Size: 6
-- Speed: 6
comment 0
if n != wall:
listenfor go
endif
takefrom s
tell everyone go
mem1 = nearest shredder
giveto mem1
DEFINE COMMENT 0
eJztj8FKQlEURde4iUSDQIwcNJAI8UlEREWEiEhDB9EgIvUlUSEvqpelbRpEA4lo1Ff0BX1BIwfS97S9
/kW4YXE5556977k1rGtKJBR14fOcdTpsmz1iarQ4MYnapDqjxxXiDumBlD5dDTjliQYDKq53ebT3xhmW
Ys/EvKvJt/lRixFtxurwq0vTZcwzI2d8qcen7hkq5SV459kyR1rgNdRZCmaDJe+07FcmvTkOydDQInX3
q+TZV947TP2J52KtcBzqyP6ITZU5cMqtCbmsUmaNgn+eC3NFPoh48/2QHW8300z/XH/f1jyv; | 25.227273 | 80 | 0.845045 |
76db222c1292ce5e3685701f8f7ec1d36691e1ea | 210,850 | c | C | OpenYuma/netconf/src/agt/agt_val.c | 5GExchange/escape | eb35d460597a0386b18dd5b6a5f62a3f30eed5fa | [
"Apache-2.0"
] | 10 | 2016-11-16T16:26:16.000Z | 2021-04-26T17:20:28.000Z | OpenYuma/netconf/src/agt/agt_val.c | 5GExchange/escape | eb35d460597a0386b18dd5b6a5f62a3f30eed5fa | [
"Apache-2.0"
] | 3 | 2017-04-20T11:29:17.000Z | 2017-11-06T17:12:12.000Z | OpenYuma/netconf/src/agt/agt_val.c | 5GExchange/escape | eb35d460597a0386b18dd5b6a5f62a3f30eed5fa | [
"Apache-2.0"
] | 10 | 2017-03-27T13:58:52.000Z | 2020-06-24T22:42:51.000Z | /*
* Copyright (c) 2008 - 2012, Andy Bierman, All Rights Reserved.
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied. See the License for the
* specific language governing permissions and limitations
* under the License.
*/
/* FILE: agt_val.c
Manage Server callbacks for YANG-based config manipulation
*********************************************************************
* *
* C H A N G E H I S T O R Y *
* *
*********************************************************************
date init comment
----------------------------------------------------------------------
20may06 abb begun
03dec11 abb convert tree traversal validation to
optimized validation task list
*********************************************************************
* *
* I N C L U D E F I L E S *
* *
*********************************************************************/
#include <stdio.h>
#include <stdlib.h>
#include <memory.h>
#include <assert.h>
#include "procdefs.h"
#include "agt.h"
#include "agt_acm.h"
#include "agt_cap.h"
#include "agt_cb.h"
#include "agt_cfg.h"
#include "agt_commit_complete.h"
#include "agt_ncx.h"
#include "agt_util.h"
#include "agt_val.h"
#include "agt_val_parse.h"
#include "cap.h"
#include "cfg.h"
#include "dlq.h"
#include "log.h"
#include "ncx.h"
#include "ncxconst.h"
#include "obj.h"
#include "op.h"
#include "plock.h"
#include "rpc.h"
#include "rpc_err.h"
#include "status.h"
#include "typ.h"
#include "tstamp.h"
#include "val.h"
#include "val_util.h"
#include "xmlns.h"
#include "xpath.h"
#include "xpath_yang.h"
#include "xpath1.h"
#include "yangconst.h"
/********************************************************************
* *
* C O N S T A N T S *
* *
*********************************************************************/
/* recursive callback function foward decls */
static status_t
invoke_btype_cb (agt_cbtyp_t cbtyp,
op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target,
val_value_t *newval,
val_value_t *curval,
val_value_t *curparent );
static status_t
handle_user_callback (agt_cbtyp_t cbtyp,
op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *newnode,
val_value_t *curnode,
boolean lookparent,
boolean indelete);
static status_t
apply_commit_deletes (ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target,
val_value_t *candval,
val_value_t *runval);
/********************************************************************
* *
* T Y P E S *
* *
*********************************************************************/
typedef struct unique_set_t_ {
dlq_hdr_t qhdr;
dlq_hdr_t uniqueQ; /* Q of val_unique_t */
val_value_t *valnode; /* value tree back-ptr */
} unique_set_t;
/********************************************************************
* *
* V A R I A B L E S *
* *
*********************************************************************/
/********************************************************************
* FUNCTION cvt_editop
* Determine the effective edit (if OP_EDITOP_COMMIT)
*
* \param editop the edit operation to check
* \param newnode the newval
* \param curnode the curval
*
* \return the converted editoperation
*********************************************************************/
static op_editop_t cvt_editop( op_editop_t editop,
const val_value_t *newval,
const val_value_t *curval)
{
op_editop_t retop = editop;
if (editop == OP_EDITOP_COMMIT) {
if (newval && curval) {
/***********************************
* keep this simple so SIL code does not need to
* worry about with-defaults basic-mode in use
if (val_set_by_default(newval)) {
retop = OP_EDITOP_DELETE;
} else if (val_set_by_default(curval)) {
retop = OP_EDITOP_CREATE;
} else {
retop = OP_EDITOP_REPLACE;
}
***************************************/
retop = OP_EDITOP_REPLACE;
} else if (newval && !curval) {
retop = OP_EDITOP_CREATE;
} else if (!newval && curval) {
retop = OP_EDITOP_DELETE;
} else {
retop = OP_EDITOP_REPLACE; // error: both NULL!!
}
}
return retop;
} /* cvt_editop */
/********************************************************************
* FUNCTION skip_obj_commit_test
*
* Check if the commit tests should be skipped for this object
* These tests on the object tree are more strict than the data tree
* because the data tree will never contain instances of obsolete,
* non-database, or disabled objects
*
* INPUTS:
* obj ==obj object to check
*
* RETURNS:
* TRUE if object should be skipped
* FALSE if object should not be skipped
*********************************************************************/
static boolean skip_obj_commit_test(obj_template_t *obj)
{
if (obj_is_cli(obj) ||
!obj_has_name(obj) ||
!obj_is_config(obj) ||
(obj_is_abstract(obj) && !obj_is_root(obj)) ||
/* removed because ncx_delete_all_obsolete_objects() has
* already been called
* obj_get_status(obj) == NCX_STATUS_OBSOLETE || */
!obj_is_enabled(obj)) {
return TRUE;
}
return FALSE;
} /* skip_obj_commit_test */
/********************************************************************
* FUNCTION clean_node
*
* Clean the value node and its ancestors from editvars and flags
*
* INPUTS:
* val == node to check
*
*********************************************************************/
static void
clean_node (val_value_t *val)
{
if (val == NULL) {
return;
}
if (obj_is_root(val->obj)) {
return;
}
if (val->parent) {
clean_node(val->parent);
}
val_free_editvars(val);
} /* clean_node */
/********************************************************************
* Create and store a change-audit record, if needed
* this function generates a log message if log level
* set to LOG_INFO or higher; An audit record for a sysConfigChange
* event is also generated
*
* \note !!! ONLY CALLED FOR RUNNING CONFIG !!!!
*
* \param editop edit operation requested
* \param scb session control block
* \param msg RPC message in progress
* \param newnode top new value node involved in edit
* \param curnode top cur value node involved in edit
*********************************************************************/
static void
handle_audit_record (op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *newnode,
val_value_t *curnode)
{
if (editop == OP_EDITOP_LOAD) {
return;
}
xmlChar *ibuff = NULL;
const xmlChar *name = NULL;
xmlChar tbuff[TSTAMP_MIN_SIZE+1];
ncx_cfg_t cfgid;
cfg_transaction_id_t txid;
ses_id_t sid = (scb) ? SES_MY_SID(scb) : 0;
const xmlChar *username = (scb && scb->username) ? scb->username
: (const xmlChar *)"nobody";
const xmlChar *peeraddr = (scb && scb->peeraddr) ? scb->peeraddr :
(const xmlChar *)"localhost";
editop = cvt_editop(editop, newnode, curnode);
if (msg && msg->rpc_txcb) {
cfgid = msg->rpc_txcb->cfg_id;
name = cfg_get_config_name(cfgid);
txid = msg->rpc_txcb->txid;
} else {
cfgid = NCX_CFGID_RUNNING;
name = NCX_EL_RUNNING;
txid = 0;
}
/* generate a log record */
tstamp_datetime(tbuff);
val_value_t *usenode = newnode ? newnode : curnode;
if (usenode) {
status_t res = val_gen_instance_id(NULL, usenode, NCX_IFMT_XPATH1,
&ibuff);
if (res != NO_ERR) {
log_error("\nError: Generate instance id failed (%s)",
get_error_string(res));
}
}
log_info( "\nedit-transaction %llu: operation %s on session %d by %s@%s"
"\n at %s on target '%s'\n data: %s\n",
(unsigned long long)txid, op_editop_name(editop), sid,
username, peeraddr, tbuff, name,
(ibuff) ? (const char *)ibuff : "??" );
if (cfgid == NCX_CFGID_RUNNING && log_audit_is_open()) {
log_audit_write( "\nedit-transaction %llu: operation %s on "
"session %d by %s@%s\n at %s on target 'running'"
"\n data: %s\n",
(unsigned long long)txid, op_editop_name(editop),
sid, username, peeraddr, tbuff,
(ibuff) ? (const char *)ibuff : "??");
}
/* generate a sysConfigChange notification */
if ( cfgid == NCX_CFGID_RUNNING && msg && msg->rpc_txcb && ibuff ) {
agt_cfg_audit_rec_t *auditrec = agt_cfg_new_auditrec(ibuff, editop);
if ( !auditrec ) {
log_error("\nError: malloc failed for audit record");
} else {
dlq_enque(auditrec, &msg->rpc_txcb->auditQ);
}
}
if (ibuff) {
m__free(ibuff);
}
} /* handle_audit_record */
/********************************************************************
* FUNCTION handle_subtree_node_callback
*
* Compare current node if config
* find the nodes that changed and call the
* relevant user callback functions
*
* INPUTS:
* scb == session control block invoking the callback
* msg == RPC message in progress
* cbtyp == agent callback type
* editop == edit operation applied to newnode oand/or curnode
* newnode == new node in operation
* curnode == current node in operation
*
* RETURNS:
* status of the operation (usually returned from the callback)
* NO USER CALLBACK FOUND == NO_ERR
*********************************************************************/
static status_t
handle_subtree_node_callback (agt_cbtyp_t cbtyp,
op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *newnode,
val_value_t *curnode)
{
const xmlChar *name;
status_t res;
if (newnode != NULL) {
name = newnode->name;
} else if (curnode != NULL) {
name = curnode->name;
} else {
name = NULL;
}
if (newnode && curnode) {
int retval;
if (newnode->parent &&
newnode->parent->editop == OP_EDITOP_REPLACE &&
newnode->parent->editvars &&
newnode->parent->editvars->operset) {
/* replace parent was explicitly requested and this
* function would not have been called unless something
* in the replaced node changed.
* Invoke the SIL callbacks for the child nodes
* even if oldval == newval;
*
* Operation must be explicitly set w/ operation="replace"
* attribute because <copy-config> will also
* appear to be a replace operation and the unchanged
* subtrees must be skipped in this mode
*/
retval = -1;
} else {
retval = val_compare_ex(newnode, curnode, TRUE);
if (retval == 0) {
/* apply here but nothing to do,
* so skip this entire subtree
*/
if (LOGDEBUG) {
log_debug("\nagt_val: Skipping subtree node "
"'%s', no changes",
(name) ? name : (const xmlChar *)"--");
}
}
}
if (retval == 0) {
return NO_ERR;
}
}
res = handle_user_callback(cbtyp, editop, scb, msg, newnode,
curnode, FALSE,
(editop == OP_EDITOP_DELETE) ? TRUE : FALSE);
return res;
} /* handle_subtree_node_callback */
/********************************************************************
* FUNCTION handle_subtree_callback
*
* Search the subtrees and find the correct user callback
* functions and invoke them
*
* INPUTS:
* cbtyp == agent callback type
* editop == edit operation applied to newnode oand/or curnode
* scb == session control block invoking the callback
* msg == RPC message in progress
* newnode == new node in operation
* curnode == current node in operation
*
* RETURNS:
* status of the operation (usually returned from the callback)
* NO USER CALLBACK FOUND == NO_ERR
*********************************************************************/
static status_t
handle_subtree_callback (agt_cbtyp_t cbtyp,
op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *newnode,
val_value_t *curnode)
{
val_value_t *newchild, *curchild;
status_t res = NO_ERR;
if (newnode == NULL) {
return SET_ERROR(ERR_INTERNAL_VAL);
}
for (newchild = val_get_first_child(newnode);
newchild != NULL;
newchild = val_get_next_child(newchild)) {
if (!obj_is_config(newchild->obj)) {
continue;
}
if (curnode != NULL) {
curchild = val_first_child_match(curnode, newchild);
} else {
curchild = NULL;
}
res = handle_subtree_node_callback(cbtyp, editop, scb,
msg, newchild, curchild);
if (res != NO_ERR) {
return res;
}
}
if (curnode == NULL) {
return NO_ERR;
}
for (curchild = val_get_first_child(curnode);
curchild != NULL;
curchild = val_get_next_child(curchild)) {
if (!obj_is_config(curchild->obj)) {
continue;
}
newchild = val_first_child_match(newnode, curchild);
if (newchild == NULL) {
res = handle_subtree_node_callback(cbtyp, OP_EDITOP_DELETE,
scb, msg, NULL, curchild);
if (res != NO_ERR) {
return res;
}
}
}
return res;
} /* handle_subtree_callback */
/********************************************************************
* FUNCTION delete_children_first
*
* Doing a delete operation and checking for the
* sil-delete-children-first flag. Just calling the
* SIL callback functions, not actually removing the
* child nodes in case a rollback is needed
*
* Calls recursively for all child nodes where sil-delete-children-first
* is set, then invokes the SIL callback for the 'curnode' last
*
* INPUTS:
* cbtyp == agent callback type
* scb == session control block invoking the callback
* msg == RPC message in progress
* curnode == current node in operation
*
* RETURNS:
* status of the operation (usually returned from the callback)
* NO USER CALLBACK FOUND == NO_ERR
*********************************************************************/
static status_t
delete_children_first (agt_cbtyp_t cbtyp,
ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *curnode)
{
val_value_t *curchild;
status_t res = NO_ERR;
if (curnode == NULL) {
return SET_ERROR(ERR_INTERNAL_VAL);
}
if (LOGDEBUG2) {
log_debug2("\nEnter delete_children_first for '%s'", curnode->name);
}
for (curchild = val_get_first_child(curnode);
curchild != NULL;
curchild = val_get_next_child(curchild)) {
if (!obj_is_config(curchild->obj)) {
continue;
}
if (obj_is_leafy(curchild->obj)) {
continue;
}
if (obj_is_sil_delete_children_first(curchild->obj)) {
res = delete_children_first(cbtyp, scb, msg, curchild);
} else {
res = handle_subtree_node_callback(cbtyp, OP_EDITOP_DELETE, scb,
msg, NULL, curchild);
}
if (res != NO_ERR) {
return res;
}
}
if (!obj_is_leafy(curnode->obj)) {
res = handle_subtree_node_callback(cbtyp, OP_EDITOP_DELETE, scb,
msg, NULL, curnode);
}
return res;
} /* delete_children_first */
/********************************************************************
* FUNCTION handle_user_callback
*
* Find the correct user callback function and invoke it
*
* INPUTS:
* cbtyp == agent callback type
* editop == edit operation applied to newnode oand/or curnode
* scb == session control block invoking the callback
* !!! This parm should not be NULL because only the
* !!! agt_val_root_check in agt.c calls with scb==NULL and
* !!! that never invokes any SIL callbacks
* msg == RPC message in progress
* newnode == new node in operation
* curnode == current node in operation
* lookparent == TRUE if the parent should be checked for
* a callback function; FALSE otherwise
* indelete == TRUE if in middle of a sil-delete-children-first
* callback; FALSE if not
* RETURNS:
* status of the operation (usually returned from the callback)
* NO USER CALLBACK FOUND == NO_ERR
*********************************************************************/
static status_t
handle_user_callback (agt_cbtyp_t cbtyp,
op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *newnode,
val_value_t *curnode,
boolean lookparent,
boolean indelete)
{
agt_cb_fnset_t *cbset;
val_value_t *val;
status_t res;
boolean done;
if (newnode) {
val = newnode;
} else if (curnode) {
val = curnode;
} else {
return SET_ERROR(ERR_INTERNAL_VAL);
}
if (obj_is_root(val->obj)) {
return NO_ERR;
}
if (LOGDEBUG4) {
log_debug4("\nChecking for %s user callback for %s edit on %s:%s",
agt_cbtype_name(cbtyp),
op_editop_name(editop),
val_get_mod_name(val),
val->name);
}
/* no difference during apply stage, and validate
* stage checks differences before callback invoked
* so treat remove the same as a delete for user callback purposes
*/
if (editop == OP_EDITOP_REMOVE) {
editop = OP_EDITOP_DELETE;
}
/* check if this is a child-first delete
* the child nodes may have SIL callbacks and not the
* parent, so the recursion is done before the
* SIL callback is found for the current node
* Only call during COMMIT phase
*/
if (obj_is_sil_delete_children_first(val->obj) &&
!obj_is_leafy(val->obj) &&
!indelete &&
editop == OP_EDITOP_DELETE &&
cbtyp == AGT_CB_COMMIT) {
res = delete_children_first(cbtyp, scb, msg, curnode);
return res;
}
/* find the right callback function to call */
done = FALSE;
while (!done) {
cbset = NULL;
if (val->obj && val->obj->cbset) {
cbset = val->obj->cbset;
}
if (cbset != NULL && cbset->cbfn[cbtyp] != NULL) {
if (LOGDEBUG2) {
log_debug2("\nFound %s user callback for %s:%s",
agt_cbtype_name(cbtyp),
op_editop_name(editop),
val_get_mod_name(val),
val->name);
}
editop = cvt_editop(editop, newnode, curnode);
res = (*cbset->cbfn[cbtyp])(scb, msg, cbtyp, editop,
newnode, curnode);
if (val->res == NO_ERR) {
val->res = res;
}
if (LOGDEBUG && res != NO_ERR) {
log_debug("\n%s user callback failed (%s) for %s on %s:%s",
agt_cbtype_name(cbtyp),
get_error_string(res),
op_editop_name(editop),
val_get_mod_name(val),
val->name);
}
if (res == NO_ERR) {
switch (editop) {
case OP_EDITOP_CREATE:
case OP_EDITOP_MERGE:
case OP_EDITOP_REPLACE:
case OP_EDITOP_LOAD:
if (cbtyp != AGT_CB_VALIDATE) {
res = handle_subtree_callback(cbtyp, editop, scb, msg,
newnode, curnode);
}
break;
default:
;
}
}
return res;
} else if (!lookparent) {
done = TRUE;
} else if (val->parent != NULL &&
!obj_is_root(val->parent->obj) &&
val_get_nsid(val) == val_get_nsid(val->parent)) {
val = val->parent;
} else {
done = TRUE;
}
}
return NO_ERR;
} /* handle_user_callback */
/********************************************************************
* FUNCTION add_undo_node
*
* Add an undo node to the msg->undoQ
*
* INPUTS:
* msg == RPC message in progress
* editop == edit-config operation attribute value
* newnode == node from PDU
* newnode_marker == newnode placeholder
* curnode == node from database (if any)
* curnode_marker == curnode placeholder
* parentnode == parent of curnode (or would be)
* OUTPUTS:
* agt_cfg_undo_rec_t struct added to msg->undoQ
*
* RETURNS:
* pointer to new undo record, in case any extra_deleteQ
* items need to be added; NULL on ERR_INTERNAL_MEM error
*********************************************************************/
static agt_cfg_undo_rec_t *
add_undo_node (rpc_msg_t *msg,
op_editop_t editop,
val_value_t *newnode,
val_value_t *newnode_marker,
val_value_t *curnode,
val_value_t *curnode_marker,
val_value_t *parentnode)
{
agt_cfg_undo_rec_t *undo;
/* create an undo record for this merge */
undo = agt_cfg_new_undorec();
if (!undo) {
return NULL;
}
/* save a copy of the current value in case it gets modified
* in a merge operation;; done for leafs only!!!
*/
if (curnode && obj_is_leafy(curnode->obj)) {
undo->curnode_clone = val_clone(curnode);
if (!undo->curnode_clone) {
agt_cfg_free_undorec(undo);
return NULL;
}
}
undo->editop = cvt_editop(editop, newnode, curnode);
undo->newnode = newnode;
undo->newnode_marker = newnode_marker;
undo->curnode = curnode;
undo->curnode_marker = curnode_marker;
undo->parentnode = parentnode;
dlq_enque(undo, &msg->rpc_txcb->undoQ);
return undo;
} /* add_undo_node */
/********************************************************************
* FUNCTION add_child_clean
*
* Add a child value node to a parent value node
* This is only called by the agent when adding nodes
* to a target database.
*
* Pass in the editvar to use
*
* If the child node being added is part of a choice/case,
* then all sibling nodes in other cases within the same
* choice will be deleted
*
* The insert operation will also be check to see
* if the child is a list oo a leaf-list, which is ordered-by user
*
* The default insert mode is always 'last'
*
* INPUTS:
* editvars == val_editvars_t struct to use (may be NULL)
* child == node to store in the parent
* parent == complex value node with a childQ
* cleanQ == address of Q to receive any agt_cfg_nodeptr_t
* structs for nodes marked as deleted
*
* OUTPUTS:
* cleanQ may have nodes added if the child being added
* is part of a case. All other cases will be marked as deleted
* from the parent Q and nodeptrs added to the cleanQ
* RETURNS:
* status
*********************************************************************/
static status_t
add_child_clean (val_editvars_t *editvars,
val_value_t *child,
val_value_t *parent,
dlq_hdr_t *cleanQ)
{
val_value_t *testval, *nextval;
agt_cfg_nodeptr_t *nodeptr;
if (child->casobj) {
for (testval = val_get_first_child(parent);
testval != NULL;
testval = nextval) {
nextval = val_get_next_child(testval);
if (testval->casobj &&
(testval->casobj->parent == child->casobj->parent)) {
if (testval->casobj != child->casobj) {
log_debug3("\nagt_val: clean old case member '%s'"
" from parent '%s'",
testval->name, parent->name);
nodeptr = agt_cfg_new_nodeptr(testval);
if (nodeptr == NULL) {
return ERR_INTERNAL_MEM;
}
dlq_enque(nodeptr, cleanQ);
VAL_MARK_DELETED(testval);
}
}
}
}
child->parent = parent;
boolean doins = FALSE;
if (child->obj->objtype == OBJ_TYP_LIST) {
doins = TRUE;
} else if (child->obj->objtype == OBJ_TYP_LEAF_LIST) {
doins = TRUE;
}
op_insertop_t insertop = OP_INSOP_NONE;
if (editvars) {
insertop = editvars->insertop;
}
if (doins) {
switch (insertop) {
case OP_INSOP_FIRST:
testval = val_find_child(parent, val_get_mod_name(child),
child->name);
if (testval) {
dlq_insertAhead(child, testval);
} else {
val_add_child_sorted(child, parent);
}
break;
case OP_INSOP_LAST:
case OP_INSOP_NONE:
val_add_child_sorted(child, parent);
break;
case OP_INSOP_BEFORE:
case OP_INSOP_AFTER:
/* find the entry specified by the val->insertstr value
* this is value='foo' for leaf-list and
* key="[x:foo='bar'][x:foo2=7]" for list
*/
if (child->obj->objtype == OBJ_TYP_LEAF_LIST ||
child->obj->objtype == OBJ_TYP_LIST) {
if (editvars && editvars->insertval) {
testval = editvars->insertval;
if (editvars->insertop == OP_INSOP_BEFORE) {
dlq_insertAhead(child, testval);
} else {
dlq_insertAfter(child, testval);
}
} else {
SET_ERROR(ERR_NCX_INSERT_MISSING_INSTANCE);
val_add_child_sorted(child, parent);
}
} else {
/* wrong object type */
SET_ERROR(ERR_INTERNAL_VAL);
val_add_child_sorted(child, parent);
}
break;
default:
SET_ERROR(ERR_INTERNAL_VAL);
val_add_child_sorted(child, parent);
}
} else {
val_add_child_sorted(child, parent);
}
return NO_ERR;
} /* add_child_clean */
/********************************************************************
* FUNCTION add_child_node
*
* Add a child node
*
* INPUTS:
* child == child value to add
* marker == newval marker for this child node (if needed_
* !! consuming this parm here so caller can assume
* !! memory is transferred even if error returned
* parent == parent value to add child to
* msg == RPC messing to use
* editop == edit operation to save in undo rec
*
* OUTPUTS:
* child added to parent->v.childQ
* any other cases removed and either added to undo node or deleted
*
* RETURNS:
* status
*********************************************************************/
static status_t
add_child_node (val_value_t *child,
val_value_t *marker,
val_value_t *parent,
rpc_msg_t *msg,
op_editop_t editop)
{
if (LOGDEBUG3) {
log_debug3("\nAdd child '%s' to parent '%s'",
child->name,
parent->name);
}
agt_cfg_undo_rec_t *undo = add_undo_node(msg, editop, child, marker,
NULL, NULL, parent);
if (undo == NULL) {
val_free_value(marker);
return ERR_INTERNAL_MEM;
}
undo->apply_res = add_child_clean(child->editvars, child, parent,
&undo->extra_deleteQ);
undo->edit_action = AGT_CFG_EDIT_ACTION_ADD;
return undo->apply_res;
} /* add_child_node */
/********************************************************************
* FUNCTION move_child_node
*
* Move a child list or leaf-list node
*
* INPUTS:
* newchild == new child value to add
* newchild_marker == new child marker for undo rec if needed
* !! consuming this parm here so caller can assume
* !! memory is transferred even if error returned
* curchild == existing child value to move
* parent == parent value to move child within
* msg == message in progress
* editop == edit operation to save in undo rec
*
* OUTPUTS:
* child added to parent->v.childQ
* any other cases removed and either added to undo node or deleted
*
* RETURNS:
* status
*********************************************************************/
static status_t
move_child_node (val_value_t *newchild,
val_value_t *newchild_marker,
val_value_t *curchild,
val_value_t *parent,
rpc_msg_t *msg,
op_editop_t editop)
{
if (LOGDEBUG3) {
log_debug3("\nMove child '%s' in parent '%s'",
newchild->name,
parent->name);
}
agt_cfg_undo_rec_t *undo = add_undo_node(msg, editop, newchild,
newchild_marker, curchild,
NULL, parent);
if (undo == NULL) {
/* no detailed rpc-error is recorded here!!!
* relying on catch-all operation-failed in agt_rpc_dispatch */
val_free_value(newchild_marker);
return ERR_INTERNAL_MEM;
}
VAL_MARK_DELETED(curchild);
undo->apply_res = add_child_clean(newchild->editvars, newchild, parent,
&undo->extra_deleteQ);
undo->edit_action = AGT_CFG_EDIT_ACTION_MOVE;
return undo->apply_res;
} /* move_child_node */
/********************************************************************
* FUNCTION move_mergedlist_node
*
* Move a list node that was just merged with
* the contents of the newval; now the curval needs
* to be moved
*
* INPUTS:
* newchild == new child value with the editvars
* to use to move curchild
* curchild == existing child value to move
* parent == parent value to move child within
* undo == undo record in progress
*
* OUTPUTS:
* child added to parent->v.childQ
* any other cases removed and either added to undo node or deleted
*
* RETURNS:
* status
*********************************************************************/
static status_t
move_mergedlist_node (val_value_t *newchild,
val_value_t *curchild,
val_value_t *parent,
agt_cfg_undo_rec_t *undo)
{
if (LOGDEBUG3) {
log_debug3("\nMove list '%s' in parent '%s'",
newchild->name,
parent->name);
}
val_value_t *marker = val_new_deleted_value();
if (marker == NULL) {
return ERR_INTERNAL_MEM;
}
undo->curnode_marker = marker;
val_swap_child(marker, curchild);
undo->apply_res = add_child_clean(newchild->editvars, curchild, parent,
&undo->extra_deleteQ);
undo->edit_action = AGT_CFG_EDIT_ACTION_MOVE;
return undo->apply_res;
} /* move_mergedlist_node */
/********************************************************************
* FUNCTION restore_newnode
*
* Swap the newnode and newnode_pointers
*
* INPUTS:
* undo == undo record to use
*********************************************************************/
static void
restore_newnode (agt_cfg_undo_rec_t *undo)
{
if (undo->newnode_marker) {
if (undo->newnode) {
val_swap_child(undo->newnode, undo->newnode_marker);
} else {
SET_ERROR(ERR_INTERNAL_VAL);
}
val_free_value(undo->newnode_marker);
undo->newnode_marker = NULL;
}
} /* restore_newnode */
/********************************************************************
* FUNCTION restore_newnode2
*
* Swap the newnode and newnode_pointers
* There was no undo record created
*
* INPUTS:
* newval == new value currently not in any tree
* newval_marker == marker for newval in source tree
*********************************************************************/
static void
restore_newnode2 (val_value_t *newval,
val_value_t *newval_marker)
{
if (newval && newval_marker) {
val_swap_child(newval, newval_marker);
}
val_free_value(newval_marker);
} /* restore_newnode2 */
/********************************************************************
* FUNCTION restore_curnode
*
* Restore the curnode
*
* INPUTS:
* undo == undo record to use
* target == target database being edited
*********************************************************************/
static void
restore_curnode (agt_cfg_undo_rec_t *undo,
cfg_template_t *target)
{
if (undo->curnode == NULL) {
return;
}
if (VAL_IS_DELETED(undo->curnode)) {
/* curnode is a complex type that needs to be undeleted */
VAL_UNMARK_DELETED(undo->curnode);
undo->free_curnode = FALSE;
if (undo->commit_res != ERR_NCX_SKIPPED &&
target->cfg_id == NCX_CFGID_RUNNING) {
val_check_swap_resnode(undo->newnode, undo->curnode);
}
} else if (undo->curnode_clone) {
/* node is a leaf or leaf-list that was merged */
if (undo->commit_res != ERR_NCX_SKIPPED &&
target->cfg_id == NCX_CFGID_RUNNING) {
val_check_swap_resnode(undo->newnode, undo->curnode_clone);
}
if (undo->curnode_marker) {
/* the curnode was moved so move it back */
val_remove_child(undo->curnode);
val_swap_child(undo->curnode_clone, undo->curnode_marker);
val_free_value(undo->curnode_marker);
undo->curnode_marker = NULL;
} else {
val_swap_child(undo->curnode_clone, undo->curnode);
}
undo->curnode_clone = NULL;
undo->free_curnode = TRUE;
} else {
// should not happen
SET_ERROR(ERR_INTERNAL_VAL);
}
} /* restore_curnode */
/********************************************************************
* FUNCTION restore_extra_deletes
*
* Restore any extra deleted nodes from other YANG cases
*
* INPUTS:
* nodeptrQ == Q of agt_cfg_nodeptr_t records to use
*********************************************************************/
static void
restore_extra_deletes (dlq_hdr_t *nodeptrQ)
{
while (!dlq_empty(nodeptrQ)) {
agt_cfg_nodeptr_t *nodeptr = (agt_cfg_nodeptr_t *)dlq_deque(nodeptrQ);
if (nodeptr && nodeptr->node) {
VAL_UNMARK_DELETED(nodeptr->node);
} else {
SET_ERROR(ERR_INTERNAL_VAL);
}
agt_cfg_free_nodeptr(nodeptr);
}
} /* restore_extra_deletes */
/********************************************************************
* FUNCTION finish_extra_deletes
*
* Finish deleting any extra deleted nodes from other YANG cases
*
* INPUTS:
* cfgid == internal config ID of the target database
* undo == undo record to use
*********************************************************************/
static void
finish_extra_deletes (ncx_cfg_t cfgid,
agt_cfg_undo_rec_t *undo)
{
while (!dlq_empty(&undo->extra_deleteQ)) {
agt_cfg_nodeptr_t *nodeptr = (agt_cfg_nodeptr_t *)
dlq_deque(&undo->extra_deleteQ);
if (nodeptr && nodeptr->node) {
/* mark ancestor nodes dirty before deleting this node */
if (cfgid == NCX_CFGID_RUNNING) {
val_clear_dirty_flag(nodeptr->node);
} else {
val_set_dirty_flag(nodeptr->node);
}
val_remove_child(nodeptr->node);
val_free_value(nodeptr->node);
} else {
SET_ERROR(ERR_INTERNAL_VAL);
}
agt_cfg_free_nodeptr(nodeptr);
}
} /* finish_extra_deletes */
/********************************************************************
* FUNCTION check_insert_attr
*
* Check the YANG insert attribute
*
* INPUTS:
* scb == session control block
* msg == incoming rpc_msg_t in progress
* newval == val_value_t from the PDU
* curparent == current parent node for inserting children
*
* RETURNS:
* status
*********************************************************************/
static status_t
check_insert_attr (ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *newval,
val_value_t *curparent)
{
val_value_t *testval, *simval, *insertval;
status_t res = NO_ERR;
op_editop_t editop = OP_EDITOP_NONE;
if (newval == NULL) {
return NO_ERR; // no insert attr possible
}
editop = newval->editop;
if (editop == OP_EDITOP_DELETE || editop == OP_EDITOP_REMOVE) {
/* this error already checked in agt_val_parse */
return NO_ERR;
}
if (newval->obj == NULL) {
return SET_ERROR(ERR_INTERNAL_VAL);
}
switch (newval->obj->objtype) {
case OBJ_TYP_LEAF_LIST:
/* make sure the insert attr is on a node with a parent
* this should always be true since the docroot would
* be the parent of every accessible object instance
*
* OK to check insertstr, otherwise errors
* should already be recorded by agt_val_parse
*/
if (newval->editvars == NULL ||
newval->editvars->insertop == OP_INSOP_NONE) {
return NO_ERR;
}
if (!newval->editvars->insertstr) {
/* insert op already checked in agt_val_parse */
return NO_ERR;
}
if (obj_is_system_ordered(newval->obj)) {
res = ERR_NCX_UNEXPECTED_INSERT_ATTRS;
agt_record_error(scb,
&msg->mhdr,
NCX_LAYER_CONTENT,
res,
NULL,
NCX_NT_STRING,
newval->editvars->insertstr,
NCX_NT_VAL,
newval);
return res;
}
/* validate the insert string against siblings
* make a value node to compare in the
* value space instead of the lexicographical space
*/
simval = val_make_simval_obj(newval->obj,
newval->editvars->insertstr, &res);
if (res == NO_ERR && simval) {
testval = val_first_child_match(curparent, simval);
if (!testval) {
/* sibling leaf-list with the specified
* value was not found (13.7)
*/
res = ERR_NCX_INSERT_MISSING_INSTANCE;
} else {
newval->editvars->insertval = testval;
}
}
if (simval) {
val_free_value(simval);
}
break;
case OBJ_TYP_LIST:
/* there should be a 'key' attribute
* OK to check insertxpcb, otherwise errors
* should already be recorded by agt_val_parse
*/
if (newval->editvars == NULL ||
newval->editvars->insertop == OP_INSOP_NONE) {
return NO_ERR;
}
if (!newval->editvars->insertstr) {
/* insert op already checked in agt_val_parse */
return NO_ERR;
}
if (!newval->editvars->insertxpcb) {
/* insert op already checked in agt_val_parse */
return NO_ERR;
}
if (obj_is_system_ordered(newval->obj)) {
res = ERR_NCX_UNEXPECTED_INSERT_ATTRS;
agt_record_error(scb,
&msg->mhdr,
NCX_LAYER_CONTENT,
res,
NULL,
NCX_NT_STRING,
newval->editvars->insertstr,
NCX_NT_VAL,
newval);
return res;
}
if (newval->editvars->insertxpcb->validateres != NO_ERR) {
res = newval->editvars->insertxpcb->validateres;
} else {
res = xpath_yang_validate_xmlkey(scb->reader,
newval->editvars->insertxpcb,
newval->obj, FALSE);
}
if (res == NO_ERR) {
/* get the list entry that the 'key' attribute
* referenced. It should be valid objects
* and well-formed from passing the previous test
*/
testval = val_make_from_insertxpcb(newval, &res);
if (res == NO_ERR && testval) {
val_set_canonical_order(testval);
insertval = val_first_child_match(curparent, testval);
if (!insertval) {
/* sibling list with the specified
* key value was not found (13.7)
*/
res = ERR_NCX_INSERT_MISSING_INSTANCE;
} else {
newval->editvars->insertval = insertval;
}
}
if (testval) {
val_free_value(testval);
testval = NULL;
}
}
break;
default:
if (newval->editvars && newval->editvars->insertop != OP_INSOP_NONE) {
res = ERR_NCX_UNEXPECTED_INSERT_ATTRS;
agt_record_error(scb,
&msg->mhdr,
NCX_LAYER_CONTENT,
res,
NULL,
newval->editvars->insertstr ?
NCX_NT_STRING : NCX_NT_NONE,
newval->editvars->insertstr,
NCX_NT_VAL,
newval);
return res;
}
}
if (res != NO_ERR) {
agt_record_insert_error(scb, &msg->mhdr, res, newval);
}
return res;
} /* check_insert_attr */
/********************************************************************
* FUNCTION commit_delete_allowed
*
* Check if the current session is allowed to delete
* the node found in the requested commit delete operation
*
* INPUTS:
* scb == session control block
* msg == incoming commit rpc_msg_t in progress
* deleteval == value struct to check
* isfirst == TRUE if top-level caller; FALSE if recursive call
* OUTPUTS:
* rpc_err_rec_t structs may be malloced and added
* to the msg->mhdr.errQ
*
* RETURNS:
* status
*********************************************************************/
static status_t
commit_delete_allowed (ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *deleteval,
boolean isfirst)
{
status_t res = NO_ERR;
if (obj_is_root(deleteval->obj)) {
return NO_ERR;
}
/* recurse until the config root is found and check all
* the nodes top to bottom to see if this random XPath resnode
* can be deleted by the current session right now
*/
if (deleteval->parent) {
res = commit_delete_allowed(scb, msg, deleteval->parent, FALSE);
if (res != NO_ERR) {
return res;
}
}
op_editop_t op = (isfirst) ? OP_EDITOP_DELETE : OP_EDITOP_MERGE;
/* check if access control allows the delete */
if (!agt_acm_val_write_allowed(&msg->mhdr, scb->username,
NULL, deleteval, op)) {
res = ERR_NCX_ACCESS_DENIED;
agt_record_error(scb, &msg->mhdr, NCX_LAYER_OPERATION, res, NULL,
NCX_NT_NONE, NULL, NCX_NT_NONE, NULL);
return res;
}
/* check if this curval is partially locked */
uint32 lockid = 0;
res = val_write_ok(deleteval, op, SES_MY_SID(scb), TRUE, &lockid);
if (res != NO_ERR) {
agt_record_error(scb, &msg->mhdr, NCX_LAYER_CONTENT, res,
NULL, NCX_NT_UINT32_PTR, &lockid,
NCX_NT_VAL, deleteval);
return res;
}
return res;
} /* commit_delete_allowed */
/********************************************************************
* FUNCTION check_commit_deletes
*
* Check the requested commit delete operations
*
* INPUTS:
* scb == session control block
* msg == incoming commit rpc_msg_t in progress
* candval == value struct from the candidate config
* runval == value struct from the running config
*
* OUTPUTS:
* rpc_err_rec_t structs may be malloced and added
* to the msg->mhdr.errQ
*
* RETURNS:
* none
*********************************************************************/
static status_t
check_commit_deletes (ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *candval,
val_value_t *runval)
{
if (candval == NULL || runval == NULL) {
return NO_ERR;
}
log_debug3("\ncheck_commit_deletes: start %s ", runval->name);
/* go through running config
* if the matching node is not in the candidate,
* then delete that node in the running config as well
*/
status_t res = NO_ERR;
val_value_t *curval = val_get_first_child(runval);
for (; curval != NULL; curval = val_get_next_child(curval)) {
/* check only database config nodes */
if (obj_is_data_db(curval->obj) && obj_is_config(curval->obj)) {
/* check if node deleted in source */
val_value_t *matchval = val_first_child_match(candval, curval);
if (!matchval) {
res = commit_delete_allowed(scb, msg, curval, TRUE);
if (res != NO_ERR) {
return res; /* errors recorded */
}
}
} /* else skip non-config database node */
}
return res;
} /* check_commit_deletes */
/********************************************************************
* FUNCTION apply_write_val
*
* Invoke all the AGT_CB_APPLY callbacks for a
* source and target and write operation
*
* INPUTS:
* editop == edit operation in effect on the current node
* scb == session control block
* msg == incoming rpc_msg_t in progress
* target == config database target
* parent == parent value of curval and newval
* newval == new value to apply
* curval == current instance of value (may be NULL if none)
* *done == TRUE if the node manipulation is done
* == FALSE if none of the parent nodes have already
* edited the config nodes; just do user callbacks
*
* OUTPUTS:
* newval and curval may be moved around to
* different queues, or get modified
* *done may be changed from FALSE to TRUE if node is applied here
* RETURNS:
* status
*********************************************************************/
static status_t
apply_write_val (op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target,
val_value_t *parent,
val_value_t *newval,
val_value_t *curval,
boolean *done)
{
const xmlChar *name = NULL;
agt_cfg_undo_rec_t *undo = NULL;
val_value_t *newval_marker = NULL;
status_t res = NO_ERR;
op_editop_t cur_editop = OP_EDITOP_NONE;
boolean applyhere = FALSE, topreplace = FALSE;
boolean add_defs_done = FALSE;
if (newval) {
cur_editop = (newval->editop == OP_EDITOP_NONE)
? editop : newval->editop;
name = newval->name;
} else if (curval) {
cur_editop = editop;
name = curval->name;
} else {
*done = TRUE;
return SET_ERROR(ERR_INTERNAL_VAL);
}
/* check if this is a top-level replace via <copy-config> or
* a restore-from-backup replace operation */
if (newval && obj_is_root(newval->obj) &&
msg->rpc_txcb->edit_type == AGT_CFG_EDIT_TYPE_FULL) {
topreplace = TRUE;
}
log_debug4("\napply_write_val: %s start", name);
/* check if this node needs the edit operation applied */
if (*done || (newval && obj_is_root(newval->obj))) {
applyhere = FALSE;
} else if (cur_editop == OP_EDITOP_COMMIT) {
/* make sure the VAL_FL_DIRTY flag is set, not just
* the VAL_FL_SUBTREE_DIRTY flag */
applyhere = (newval) ? val_get_dirty_flag(newval) : FALSE;
*done = applyhere;
} else if (editop == OP_EDITOP_DELETE || editop == OP_EDITOP_REMOVE) {
applyhere = TRUE;
*done = TRUE;
} else {
applyhere = agt_apply_this_node(cur_editop, newval, curval);
*done = applyhere;
}
if (applyhere && newval) {
/* check corner case applying to the config root */
if (obj_is_root(newval->obj)) {
;
} else if (!typ_is_simple(newval->btyp) && !add_defs_done &&
editop != OP_EDITOP_DELETE && editop != OP_EDITOP_REMOVE) {
res = val_add_defaults(newval, (target) ? target->root : NULL,
curval, FALSE);
if (res != NO_ERR) {
log_error("\nError: add defaults failed");
applyhere = FALSE;
}
}
}
/* apply the requested edit operation */
if (applyhere) {
if (LOGDEBUG) {
val_value_t *logval;
if (curval) {
logval = curval;
} else if (newval) {
logval = newval;
} else {
logval = NULL;
}
if (logval) {
xmlChar *buff = NULL;
res = val_gen_instance_id(&msg->mhdr, logval,
NCX_IFMT_XPATH1, &buff);
if (res == NO_ERR) {
log_debug("\napply_write_val: apply %s on %s",
op_editop_name(editop), buff);
} else {
log_debug("\napply_write_val: apply %s on %s",
op_editop_name(editop), name);
}
if (buff) {
m__free(buff);
}
}
}
if (target->cfg_id == NCX_CFGID_RUNNING) {
/* only call SIL-apply once, when the data tree edits
* are applied to the running config.
* The candidate target is skipped so the SIL
* apply callback is not called twice.
* Also there is no corresponding callback
* to cleanup the candidate if <discard-changes>
* is invoked by the client or the server */
res = handle_user_callback(AGT_CB_APPLY, editop, scb, msg,
newval, curval, TRUE, FALSE);
if (res != NO_ERR) {
/* assuming SIL added an rpc-error already
* relying on catch-all operation-failed in agt_rpc_dispatch */
return res;
}
}
/* exit here if the edited node is a virtual value
* it is assumed that the user callback handled its own
* internal representation of this node any subtrees */
if (curval && val_is_virtual(curval)) {
/* update the last change time; assume the virtual
* node contents changed */
cfg_update_last_ch_time(target);
return NO_ERR;
}
/* handle recoverable edit;
* make a deleted node markers for newval or curval if they need
* to be removed from their parent nodes; this is needed
* for non-descructive commit from candidate to running
* or copy from running to startup; the source and target are
* no longer deleted, just marked as deleted until commit
* The newnode and curnode pointers MUST be rooted in a data
* tree until after all SIL callbacks have been invoked */
switch (cur_editop) {
case OP_EDITOP_LOAD:
case OP_EDITOP_DELETE:
case OP_EDITOP_REMOVE:
/* leave source tree alone since it will not be re-parented
* in the target tree */
break;
default:
/* remove newval node; swap with newval_marker for undo */
if (newval) {
newval_marker = val_new_deleted_value();
if (newval_marker) {
val_swap_child(newval_marker, newval);
} else {
return ERR_INTERNAL_MEM;
}
} // else keep source leaf or leaf-list node in place
}
switch (cur_editop) {
case OP_EDITOP_MERGE:
if (curval) {
/* This is a leaf:
* The applyhere code will not pick a complex node for
* merging if the current node already exists.
* The current node is always used instead of the new node
* for merge, in case there are any read-only descendant
* nodes already */
if (newval && newval->editvars && newval->editvars->insertstr) {
res = move_child_node(newval, newval_marker, curval,
parent, msg, cur_editop);
} else if (newval) {
/* merging a simple leaf or leaf-list
* make a copy of the current node first */
undo = add_undo_node(msg, cur_editop, newval,
newval_marker, curval, NULL, parent);
if (undo == NULL) {
/* no detailed rpc-error is recorded here!!!
* relying on catch-all operation-failed in
* agt_rpc_dispatch */
restore_newnode2(newval, newval_marker);
return ERR_INTERNAL_MEM;
}
undo->apply_res = res = val_merge(newval, curval);
undo->edit_action = AGT_CFG_EDIT_ACTION_SET;
restore_newnode(undo);
} else {
res = SET_ERROR(ERR_INTERNAL_VAL);
}
} else if (newval) {
res = add_child_node(newval, newval_marker, parent, msg,
cur_editop);
} else {
res = SET_ERROR(ERR_INTERNAL_VAL);
}
break;
case OP_EDITOP_REPLACE:
case OP_EDITOP_COMMIT:
if (curval) {
if (newval && newval->editvars &&
newval->editvars->insertstr) {
res = move_child_node(newval, newval_marker, curval,
parent, msg, cur_editop);
} else if (newval) {
undo = add_undo_node(msg, cur_editop, newval,
newval_marker, curval, NULL, parent);
if (undo == NULL) {
/* no detailed rpc-error is recorded here!!!
* relying on catch-all operation-failed in
* agt_rpc_dispatch */
restore_newnode2(newval, newval_marker);
return ERR_INTERNAL_MEM;
}
if (obj_is_leafy(curval->obj)) {
undo->apply_res = res = val_merge(newval, curval);
undo->edit_action = AGT_CFG_EDIT_ACTION_SET;
restore_newnode(undo);
} else {
val_insert_child(newval, curval, parent);
VAL_MARK_DELETED(curval);
undo->edit_action = AGT_CFG_EDIT_ACTION_REPLACE;
undo->free_curnode = TRUE;
}
} else {
res = SET_ERROR(ERR_INTERNAL_VAL);
}
} else if (newval) {
res = add_child_node(newval, newval_marker, parent, msg,
cur_editop);
} else {
res = SET_ERROR(ERR_INTERNAL_VAL);
}
break;
case OP_EDITOP_CREATE:
if (newval && curval) {
/* there must be a default leaf */
undo = add_undo_node(msg, cur_editop, newval,
newval_marker, curval, NULL, parent);
if (undo == NULL) {
/* no detailed rpc-error is recorded here!!!
* relying on catch-all operation-failed in
* agt_rpc_dispatch */
restore_newnode2(newval, newval_marker);
return ERR_INTERNAL_MEM;
}
undo->apply_res = res = val_merge(newval, curval);
undo->edit_action = AGT_CFG_EDIT_ACTION_SET;
restore_newnode(undo);
} else if (newval) {
res = add_child_node(newval, newval_marker, parent, msg,
cur_editop);
} else {
res = SET_ERROR(ERR_INTERNAL_VAL);
}
break;
case OP_EDITOP_LOAD:
assert( newval && "newval NULL in LOAD" );
undo = add_undo_node(msg, cur_editop, newval, newval_marker,
curval, NULL, parent);
if (undo == NULL) {
/* no detailed rpc-error is recorded here!!!
* relying on catch-all operation-failed in
* agt_rpc_dispatch */
restore_newnode2(newval, newval_marker);
return ERR_INTERNAL_MEM;
}
break;
case OP_EDITOP_DELETE:
case OP_EDITOP_REMOVE:
if (!curval) {
/* this was a REMOVE operation NO-OP (?verify?) */
break;
}
undo = add_undo_node(msg, cur_editop, newval, newval_marker,
curval, NULL, parent);
if (undo == NULL) {
/* no detailed rpc-error is recorded here!!!
* relying on catch-all operation-failed in agt_rpc_dispatch */
restore_newnode2(newval, newval_marker);
return ERR_INTERNAL_MEM;
}
if (curval->parent) {
val_set_dirty_flag(curval->parent);
}
/* check if this is a leaf with a default */
if (obj_get_default(curval->obj)) {
/* convert this leaf to its default value */
res = val_delete_default_leaf(curval);
undo->edit_action = AGT_CFG_EDIT_ACTION_DELETE_DEFAULT;
} else {
/* mark this node as deleted */
VAL_MARK_DELETED(curval);
undo->edit_action = AGT_CFG_EDIT_ACTION_DELETE;
undo->free_curnode = TRUE;
}
break;
default:
return SET_ERROR(ERR_INTERNAL_VAL);
}
}
if (res == NO_ERR && applyhere == TRUE && newval && curval &&
newval->btyp == NCX_BT_LIST && cur_editop == OP_EDITOP_MERGE) {
if (undo == NULL) {
undo = add_undo_node(msg, editop, newval, newval_marker,
curval, NULL, parent);
if (undo == NULL) {
restore_newnode2(newval, newval_marker);
res = ERR_INTERNAL_MEM;
}
}
if (res == NO_ERR) {
/* move the list entry after the merge is done */
res = move_mergedlist_node(newval, curval, parent, undo);
}
}
if (res == NO_ERR && newval && curval) {
if (topreplace ||
(editop == OP_EDITOP_COMMIT && !typ_is_simple(newval->btyp) &&
val_get_subtree_dirty_flag(newval))) {
res = apply_commit_deletes(scb, msg, target, newval, curval);
}
}
/* TBD: should this be moved to the commit phase somehow, although no
* recovery is possible during a OP_EDITOP_LOAD at boot-time */
if (res == NO_ERR && newval && obj_is_root(newval->obj) &&
editop == OP_EDITOP_LOAD) {
/* there is no newval_marker for this root node newval
* so this operation cannot be undone */
val_remove_child(newval);
cfg_apply_load_root(target, newval);
}
return res;
} /* apply_write_val */
/********************************************************************
* FUNCTION check_withdef_default
*
* Check the wd:default node for correctness
*
* INPUTS:
* scb == session control block
* msg == incoming rpc_msg_t in progress
* newval == val_value_t from the PDU
*
* RETURNS:
* status
*********************************************************************/
static status_t
check_withdef_default (ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *newval)
{
status_t res = NO_ERR;
if (newval == NULL) {
return NO_ERR;
}
/* check object is a leaf */
if (newval->obj->objtype != OBJ_TYP_LEAF) {
res = ERR_NCX_WRONG_NODETYP;
} else {
/* check leaf has a schema default */
const xmlChar *defstr = obj_get_default(newval->obj);
if (defstr == NULL) {
res = ERR_NCX_NO_DEFAULT;
} else {
/* check value provided is the same as the default */
int32 ret = val_compare_to_string(newval, defstr, &res);
if (res == NO_ERR && ret != 0) {
res = ERR_NCX_INVALID_VALUE;
}
}
}
if (res != NO_ERR) {
agt_record_error(scb, &msg->mhdr, NCX_LAYER_CONTENT, res, NULL,
NCX_NT_VAL, newval, NCX_NT_VAL, newval);
}
return res;
} /* check_withdef_default */
/********************************************************************
* Invoke the specified agent simple type validate callback.
*
* \param editop parent node edit operation
* \param scb session control block
* \param msg incoming rpc_msg_t in progress
* \param newval val_value_t from the PDU, this cannot be null!
* \param curval current value (if any) from the target config
* \param curparent current parent value for inserting children
*
* \return status
*********************************************************************/
static status_t invoke_simval_cb_validate( op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *newval,
val_value_t *curval,
val_value_t *curparent )
{
assert ( newval && "newval is NULL!" );
log_debug4( "\ninvoke_simval:validate: %s:%s start",
obj_get_mod_name(newval->obj), newval->name);
/* check and adjust the operation attribute */
boolean is_validate = msg->rpc_txcb->is_validate;
ncx_iqual_t iqual = val_get_iqualval(newval);
op_editop_t cur_editop = OP_EDITOP_NONE;
op_editop_t cvtop = cvt_editop(editop, newval, curval);
status_t res = agt_check_editop( cvtop, &cur_editop, newval, curval,
iqual, ses_get_protocol(scb) );
if (cur_editop == OP_EDITOP_NONE) {
cur_editop = editop;
}
if (editop != OP_EDITOP_COMMIT && !is_validate) {
newval->editop = cur_editop;
}
if (res == ERR_NCX_BAD_ATTRIBUTE) {
xml_attr_t errattr;
memset(&errattr, 0x0, sizeof(xml_attr_t));
errattr.attr_ns = xmlns_nc_id();
errattr.attr_name = NC_OPERATION_ATTR_NAME;
errattr.attr_val = (xmlChar *)NULL;
agt_record_attr_error( scb, &msg->mhdr, NCX_LAYER_CONTENT, res,
&errattr, NULL, NULL, NCX_NT_VAL, newval );
return res;
} else if (res != NO_ERR) {
agt_record_error( scb, &msg->mhdr, NCX_LAYER_CONTENT, res, NULL,
NCX_NT_NONE, NULL, NCX_NT_VAL, newval );
return res;
}
/* check the operation against the object definition and whether or not
* the entry currently exists */
res = agt_check_max_access(newval, (curval != NULL));
if ( res != NO_ERR ) {
agt_record_error( scb, &msg->mhdr, NCX_LAYER_CONTENT, res, NULL,
NCX_NT_VAL, newval, NCX_NT_VAL, newval );
return res;
}
/* make sure the node is not partial locked by another session; there is a
* corner case where all the PDU nodes are OP_EDITOP_NONE, and so nodes
* that touch a partial lock will never actually request an operation; treat
* this as an error anyway, since it is too hard to defer the test until
* later, and this is a useless corner-case so clients should not do it */
if (curval) {
uint32 lockid = 0;
res = val_write_ok( curval, cur_editop, SES_MY_SID(scb),
FALSE, &lockid );
if (res != NO_ERR) {
agt_record_error( scb, &msg->mhdr, NCX_LAYER_OPERATION, res, NULL,
NCX_NT_UINT32_PTR, &lockid, NCX_NT_VAL, curval );
return res;
}
}
res = check_insert_attr(scb, msg, newval, curparent);
if (res != NO_ERR) {
/* error already recorded */
return res;
}
/* check if the wd:default attribute is present and if so, that it is used
* properly; this needs to be done after the effective operation is set for
* newval */
if ( val_has_withdef_default(newval) ) {
res = check_withdef_default( scb, msg, newval );
if (res != NO_ERR) {
return res;
}
}
/* check the user callback only if there is some operation in
* affect already */
if ( agt_apply_this_node(cur_editop, newval, curval)) {
res = handle_user_callback( AGT_CB_VALIDATE, cur_editop, scb, msg,
newval, curval, TRUE, FALSE );
}
return res;
}
/********************************************************************
* Invoke the specified agent simple type apply / commit_check callback.
*
* \param scb session control block
* \param msg incoming rpc_msg_t in progress
* \param target cfg_template_t for the config database to write
* \param newval val_value_t from the PDU
* \param curval current value (if any) from the target config
*
* \return status
*********************************************************************/
static status_t
invoke_simval_cb_apply_commit_check( op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target,
val_value_t *newval,
val_value_t *curval,
val_value_t *curparent )
{
op_editop_t cureditop = editop;
boolean done = false;
if (newval && newval->editop != OP_EDITOP_NONE) {
cureditop = newval->editop;
} else if (curval) {
if (cureditop == OP_EDITOP_NONE) {
cureditop = curval->editop;
}
}
return apply_write_val( cureditop, scb, msg, target, curparent,
newval, curval, &done );
}
/********************************************************************
* Invoke all the specified agent simple type callbacks for a
* source and target and write operation
*
* \param cbtyp callback type being invoked
* \param editop parent node edit operation
* \param scb session control block
* \param msg incoming rpc_msg_t in progress
* \param target cfg_template_t for the config database to write
* \param newval val_value_t from the PDU
* \param curval current value (if any) from the target config
* \param curparent current parent node for inserting children
*
* \return status
*********************************************************************/
static status_t
invoke_simval_cb (agt_cbtyp_t cbtyp,
op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target,
val_value_t *newval,
val_value_t *curval,
val_value_t *curparent)
{
status_t res = NO_ERR;
/* check the 'operation' attribute in VALIDATE phase */
switch (cbtyp) {
case AGT_CB_VALIDATE:
res = invoke_simval_cb_validate( editop, scb, msg, newval, curval,
curparent );
break;
case AGT_CB_APPLY:
res = invoke_simval_cb_apply_commit_check( editop, scb, msg, target,
newval, curval, curparent );
break;
case AGT_CB_COMMIT:
case AGT_CB_ROLLBACK:
default:
/* nothing to do for commit or rollback at this time */
break;
}
return res;
} /* invoke_simval_cb */
/********************************************************************
* FUNCTION check_keys_present
*
* Check that the specified list entry has all key leafs present
* Generate and record <rpc-error>s for each missing key
*
* INPUTS:
* scb == session control block
* msg == incoming rpc_msg_t in progress
* newval == val_value_t from the PDU
*
* RETURNS:
* status
*********************************************************************/
static status_t
check_keys_present (ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *newval)
{
obj_key_t *objkey = NULL;
status_t res = NO_ERR;
if (newval == NULL) {
return NO_ERR;
}
if (newval->obj->objtype != OBJ_TYP_LIST) {
return SET_ERROR(ERR_INTERNAL_VAL);
}
for (objkey = obj_first_key(newval->obj);
objkey != NULL;
objkey = obj_next_key(objkey)) {
if (val_find_child(newval, obj_get_mod_name(objkey->keyobj),
obj_get_name(objkey->keyobj))) {
continue;
}
res = ERR_NCX_MISSING_KEY;
agt_record_error(scb,
&msg->mhdr,
NCX_LAYER_CONTENT,
res,
NULL,
NCX_NT_OBJ,
objkey->keyobj, /* error-info */
NCX_NT_VAL,
newval); /* error-path */
}
return res;
} /* check_keys_present */
/********************************************************************
* FUNCTION invoke_cpxval_cb
*
* Invoke all the specified agent complex type callbacks for a
* source and target and write operation
*
* INPUTS:
* cbtyp == callback type being invoked
* editop == parent node edit operation
* scb == session control block
* msg == incoming rpc_msg_t in progress
* target == cfg_template_t for the config database to write
* newval == val_value_t from the PDU
* curval == current value (if any) from the target config
* curparent == current parent node for adding children
* done == TRUE if the node manipulation is done
* == FALSE if none of the parent nodes have already
* edited the config nodes; just do user callbacks
*
* RETURNS:
* status
*********************************************************************/
static status_t
invoke_cpxval_cb (agt_cbtyp_t cbtyp,
op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target,
val_value_t *newval,
val_value_t *curval,
val_value_t *curparent,
boolean done)
{
status_t res = NO_ERR, retres = NO_ERR;
op_editop_t cur_editop = OP_EDITOP_NONE, cvtop = OP_EDITOP_NONE;
boolean isroot = FALSE, isdirty = TRUE;
/* check the 'operation' attribute in VALIDATE phase */
switch (cbtyp) {
case AGT_CB_VALIDATE:
assert ( newval && "newval is NULL!" );
isroot = obj_is_root(newval->obj);
if (LOGDEBUG4 && !isroot) {
log_debug4("\ninvoke_cpxval:validate: %s:%s start",
obj_get_mod_name(newval->obj),
newval->name);
}
if (editop == OP_EDITOP_COMMIT) {
isdirty = val_get_dirty_flag(newval);
}
if (!isroot && isdirty) {
/* check and adjust the operation attribute */
ncx_iqual_t iqual = val_get_iqualval(newval);
cvtop = cvt_editop(editop, newval, curval);
res = agt_check_editop(cvtop, &cur_editop, newval, curval,
iqual, ses_get_protocol(scb));
if (editop != OP_EDITOP_COMMIT ) {
/* need to check the max-access but not over-write
* the newval->editop if this is a validate operation
* do not care about parent operation in agt_check_max_access
* because the operation is expected to be OP_EDITOP_LOAD
*/
boolean is_validate = msg->rpc_txcb->is_validate;
op_editop_t saveop = editop;
newval->editop = cur_editop;
if (res == NO_ERR) {
res = agt_check_max_access(newval, (curval != NULL));
}
if (is_validate) {
newval->editop = saveop;
}
}
}
if (res == NO_ERR) {
if (!isroot && editop != OP_EDITOP_COMMIT &&
cur_editop != OP_EDITOP_LOAD) {
res = check_insert_attr(scb, msg, newval, curparent);
CHK_EXIT(res, retres);
res = NO_ERR; /* any error already recorded */
}
}
if (res != NO_ERR) {
agt_record_error(scb, &msg->mhdr, NCX_LAYER_CONTENT, res,
NULL, NCX_NT_VAL, newval, NCX_NT_VAL, newval);
CHK_EXIT(res, retres);
}
if (res == NO_ERR && !isroot && newval->btyp == NCX_BT_LIST) {
/* make sure all the keys are present since this
* was not done in agt_val_parse.c
*/
if (editop == OP_EDITOP_NONE && !agt_any_operations_set(newval)) {
if (LOGDEBUG3) {
log_debug3("\nSkipping key_check for '%s'; no edit ops",
newval->name);
}
} else {
res = check_keys_present(scb, msg, newval);
/* errors recorded if any */
}
}
/* check if the wd:default attribute is present and if so,
* it will be an error
*/
if (res == NO_ERR && !isroot && editop != OP_EDITOP_COMMIT) {
if (val_has_withdef_default(newval)) {
res = check_withdef_default(scb, msg, newval);
}
}
/* any of the errors so far indicate this node is bad
* setting the val->res to the error will force it to be removed
* if --startup-error=continue; only apply to the new tree, if any
*/
if (res != NO_ERR && newval != NULL) {
VAL_MARK_DELETED(newval);
newval->res = res;
}
/* make sure the node is not partial locked
* by another session; there is a corner case where
* all the PDU nodes are OP_EDITOP_NONE, and
* so nodes that touch a partial lock will never
* actually request an operation; treat this
* as an error anyway, since it is too hard
* to defer the test until later, and this is
* a useless corner-case so clients should not do it
*/
if (res == NO_ERR && !isroot) {
val_value_t *useval = newval ? newval : curval;
uint32 lockid = 0;
if (obj_is_root(useval->obj) && cur_editop == OP_EDITOP_NONE) {
/* do not check OP=none on the config root */
;
} else if (editop == OP_EDITOP_COMMIT && !isdirty) {
; // no write requested on this node
} else {
res = val_write_ok(useval, cur_editop, SES_MY_SID(scb),
FALSE, &lockid);
}
if (res != NO_ERR) {
agt_record_error(scb, &msg->mhdr, NCX_LAYER_OPERATION, res,
NULL, NCX_NT_UINT32_PTR, &lockid, NCX_NT_VAL,
useval);
}
}
/* check the user callback only if there is some
* operation in affect already
*/
if (res == NO_ERR && !isroot && isdirty &&
agt_apply_this_node(cur_editop, newval, curval)) {
res = handle_user_callback(AGT_CB_VALIDATE, cur_editop, scb,
msg, newval, curval, TRUE, FALSE);
}
if (res != NO_ERR) {
retres = res;
}
break;
case AGT_CB_APPLY:
if (newval) {
cur_editop = newval->editop;
if (cur_editop == OP_EDITOP_NONE) {
cur_editop = editop;
}
isroot = obj_is_root(newval->obj);
} else if (curval) {
isroot = obj_is_root(curval->obj);
cur_editop = editop;
} else {
cur_editop = editop;
}
res = apply_write_val(cur_editop, scb, msg, target,
curparent, newval, curval, &done);
if (res != NO_ERR) {
retres = res;
}
break;
case AGT_CB_COMMIT:
case AGT_CB_ROLLBACK:
break;
default:
retres = SET_ERROR(ERR_INTERNAL_VAL);
}
/* change the curparent parameter to the current nodes
* before invoking callbacks for the child nodes */
if (retres == NO_ERR) {
if (newval) {
curparent = newval;
} else if (curval) {
curparent = curval;
} else {
retres = SET_ERROR(ERR_INTERNAL_VAL);
}
}
/* check all the child nodes next */
if (retres == NO_ERR && !done && curparent) {
val_value_t *chval, *curch, *nextch;
for (chval = val_get_first_child(curparent);
chval != NULL && retres == NO_ERR;
chval = nextch) {
nextch = val_get_next_child(chval);
if (curval) {
curch = val_first_child_match(curval, chval);
} else {
curch = NULL;
}
cur_editop = chval->editop;
if (cur_editop == OP_EDITOP_NONE) {
cur_editop = editop;
}
res = invoke_btype_cb(cbtyp, cur_editop, scb, msg, target,
chval, curch, curval);
//if (chval->res == NO_ERR) {
// chval->res = res;
//}
CHK_EXIT(res, retres);
}
}
return retres;
} /* invoke_cpxval_cb */
/********************************************************************
* FUNCTION invoke_btype_cb
*
* Invoke all the specified agent typedef callbacks for a
* source and target and write operation
*
* INPUTS:
* cbtyp == callback type being invoked
* editop == parent node edit operation
* scb == session control block
* msg == incoming rpc_msg_t in progress
* target == cfg_template_t for the config database to write
* newval == val_value_t from the PDU
* curval == current value (if any) from the target config
* curparent == current parent for inserting child nodes
* RETURNS:
* status
*********************************************************************/
static status_t invoke_btype_cb( agt_cbtyp_t cbtyp,
op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target,
val_value_t *newval,
val_value_t *curval,
val_value_t *curparent )
{
val_value_t *useval;
if (newval != NULL) {
useval = newval;
} else if (curval != NULL) {
useval = curval;
} else {
return SET_ERROR(ERR_INTERNAL_VAL);
}
boolean is_root = obj_is_root(useval->obj);
if (editop == OP_EDITOP_COMMIT && !is_root && !val_dirty_subtree(useval)) {
log_debug2("\nSkipping unaffected %s in %s commit for %s:%s",
obj_get_typestr(useval->obj),
agt_cbtype_name(cbtyp),
val_get_mod_name(useval),
useval->name);
return NO_ERR;
}
val_value_t *v_val = NULL;
status_t res = NO_ERR;
boolean has_children = !typ_is_simple(useval->btyp);
if (cbtyp == AGT_CB_VALIDATE) {
boolean check_acm = TRUE;
op_editop_t cvtop = cvt_editop(editop, newval, curval);
/* check if ACM test needs to be skipped */
if (is_root) {
check_acm = FALSE;
} else if (editop == OP_EDITOP_COMMIT) {
switch (cvtop) {
case OP_EDITOP_CREATE:
case OP_EDITOP_DELETE:
break;
case OP_EDITOP_MERGE:
case OP_EDITOP_REPLACE:
if (!val_get_dirty_flag(useval)) {
check_acm = FALSE;
}
break;
default:
return SET_ERROR(ERR_INTERNAL_VAL);
}
}
/* check if allowed access to this node */
if (check_acm && scb &&
!agt_acm_val_write_allowed(&msg->mhdr, scb->username,
newval, curval, cvtop)) {
res = ERR_NCX_ACCESS_DENIED;
agt_record_error(scb,&msg->mhdr, NCX_LAYER_OPERATION, res,
NULL, NCX_NT_NONE, NULL, NCX_NT_NONE, NULL);
return res;
}
if (curval && val_is_virtual(curval)) {
v_val = val_get_virtual_value(scb, curval, &res);
if (res == ERR_NCX_SKIPPED) {
res = NO_ERR;
} else if (res != NO_ERR) {
return res;
}
}
/* check if there are commit deletes to validate */
if (has_children &&
msg->rpc_txcb->edit_type == AGT_CFG_EDIT_TYPE_FULL) {
res = check_commit_deletes(scb, msg, newval,
v_val ? v_val : curval);
if (res != NO_ERR) {
return res;
}
}
} else if (cbtyp == AGT_CB_APPLY && editop == OP_EDITOP_COMMIT &&
has_children) {
if (curval && val_is_virtual(curval)) {
v_val = val_get_virtual_value(scb, curval, &res);
if (res == ERR_NCX_SKIPPED) {
res = NO_ERR;
} else if (res != NO_ERR) {
return res;
}
}
}
/* first traverse all the nodes until leaf nodes are reached */
if (has_children) {
res = invoke_cpxval_cb(cbtyp, editop, scb, msg, target, newval,
(v_val) ? v_val : curval, curparent, FALSE);
} else {
res = invoke_simval_cb(cbtyp, editop, scb, msg, target, newval,
(v_val) ? v_val : curval, curparent );
if (newval != NULL && res != NO_ERR) {
VAL_MARK_DELETED(newval);
newval->res = res;
}
}
return res;
} /* invoke_btype_cb */
/********************************************************************
* FUNCTION commit_edit AGT_CB_COMMIT
*
* Finish the database editing for an undo-rec
* The SIL callbacks have already completed; this step cannot fail
*
* INPUTS:
* scb == session control block to use
* msg == RPC message in progress
* undo == agt_cfg_undo_rec_t struct to process
*
*********************************************************************/
static void
commit_edit (ses_cb_t *scb,
rpc_msg_t *msg,
agt_cfg_undo_rec_t *undo)
{
if (undo->editop == OP_EDITOP_LOAD) {
/* the top-level nodes are kept in the original tree the very
* first time the running config is loaded from startup */
undo->newnode = NULL;
return;
}
handle_audit_record(undo->editop, scb, msg, undo->newnode, undo->curnode);
/* check if the newval marker was placed in the source tree */
if (undo->newnode_marker) {
dlq_remove(undo->newnode_marker);
val_free_value(undo->newnode_marker);
undo->newnode_marker = NULL;
}
/* check if the curval marker was placed in the target tree */
if (undo->curnode_marker) {
dlq_remove(undo->curnode_marker);
val_free_value(undo->curnode_marker);
undo->curnode_marker = NULL;
}
if (msg->rpc_txcb->cfg_id == NCX_CFGID_RUNNING) {
switch (undo->editop) {
case OP_EDITOP_REPLACE:
case OP_EDITOP_COMMIT:
val_check_swap_resnode(undo->curnode, undo->newnode);
break;
case OP_EDITOP_DELETE:
case OP_EDITOP_REMOVE:
if (undo->curnode) {
val_check_delete_resnode(undo->curnode);
}
break;
default:
;
}
}
if (undo->newnode) {
if (msg->rpc_txcb->cfg_id == NCX_CFGID_RUNNING) {
val_clear_dirty_flag(undo->newnode);
} else {
val_set_dirty_flag(undo->newnode);
}
}
if (undo->curnode) {
if (msg->rpc_txcb->cfg_id == NCX_CFGID_RUNNING) {
val_clear_dirty_flag(undo->curnode);
} else {
val_set_dirty_flag(undo->curnode);
}
if (undo->free_curnode) {
if (VAL_IS_DELETED(undo->curnode)) {
val_remove_child(undo->curnode);
}
if (undo->curnode_clone) {
/* do not need curnode as a backup for redo-restore */
val_free_value(undo->curnode);
undo->curnode = NULL;
}
}
}
clean_node(undo->newnode);
clean_node(undo->curnode);
finish_extra_deletes(msg->rpc_txcb->cfg_id, undo);
/* rest of cleanup will be done in agt_cfg_free_undorec;
* Saving curnode_clone or curnode and the entire extra_deleteQ
* in case this commit needs to be undone by simulating a
* new transaction wrt/ SIL callbacks */
} /* commit_edit */
/********************************************************************
* FUNCTION reverse_edit
*
* Attempt to invoke SIL callbacks to reverse an edit that
* was already commited; database tree was never undone
* The apply and commit phases completed OK
*
* INPUTS:
* undo == agt_cfg_undo_rec_t struct to process
* scb == session control block
* msg == incoming rpc_msg_t in progress
*
* RETURNS:
* status
*********************************************************************/
static status_t
reverse_edit (agt_cfg_undo_rec_t *undo,
ses_cb_t *scb,
rpc_msg_t *msg)
{
agt_cfg_transaction_t *txcb = msg->rpc_txcb;
if (LOGDEBUG3) {
val_value_t *logval = undo->newnode ? undo->newnode : undo->curnode;
log_debug3("\nReverse transaction %llu, %s edit on %s:%s",
(unsigned long long)txcb->txid,
op_editop_name(undo->editop),
val_get_mod_name(logval),
logval->name);
}
val_value_t *newval = NULL;
val_value_t *curval = NULL;
op_editop_t editop = OP_EDITOP_NONE;
status_t res = NO_ERR;
boolean lookparent = TRUE;
boolean indelete = FALSE;
switch (undo->edit_action) {
case AGT_CFG_EDIT_ACTION_NONE:
log_warn("\nError: undo record has no action set");
return NO_ERR;
case AGT_CFG_EDIT_ACTION_ADD:
/* need to generate a delete for curnode */
assert( undo->newnode && "undo newnode is NULL!" );
curval = undo->newnode;
editop = OP_EDITOP_DELETE;
indelete = TRUE;
break;
case AGT_CFG_EDIT_ACTION_SET:
/* need to generate a set for the old value */
assert( undo->newnode && "undo newnode is NULL!" );
curval = undo->newnode;
newval = (undo->curnode_clone) ? undo->curnode_clone : undo->curnode;
assert( newval && "undo curnode is NULL!" );
editop = undo->editop;
break;
case AGT_CFG_EDIT_ACTION_MOVE:
/* need to generate a similar operation to move the old entry
* back to its old location
* !!! FIXME: are the editvars correct, and do SIL callbacks
* !!! look at the editvars? */
assert( undo->newnode && "undo newnode is NULL!" );
assert( undo->curnode && "undo curnode is NULL!" );
newval = undo->curnode;
curval = undo->newnode;
editop = undo->editop;
break;
case AGT_CFG_EDIT_ACTION_REPLACE:
/* need to geerate a replace with the values revered */
assert( undo->newnode && "undo newnode is NULL!" );
assert( undo->curnode && "undo curnode is NULL!" );
newval = undo->curnode;
curval = undo->newnode;
editop = undo->editop;
break;
case AGT_CFG_EDIT_ACTION_DELETE:
/* need to generate a create for the deleted value */
assert( undo->curnode && "undo curnode is NULL!" );
newval = undo->curnode;
editop = OP_EDITOP_CREATE;
break;
case AGT_CFG_EDIT_ACTION_DELETE_DEFAULT:
if (undo->curnode) {
newval = undo->curnode;
editop = OP_EDITOP_CREATE;
} else {
return NO_ERR;
}
break;
default:
return SET_ERROR(ERR_INTERNAL_VAL);
}
res = handle_user_callback(AGT_CB_APPLY, editop, scb, msg,
newval, curval, lookparent, indelete);
if (res == NO_ERR) {
res = handle_user_callback(AGT_CB_COMMIT, editop, scb, msg,
newval, curval, lookparent, indelete);
}
if (res == NO_ERR) {
/* reverse all the extra deletes as create operations */
editop = OP_EDITOP_CREATE;
curval = NULL;
lookparent = FALSE;
indelete = FALSE;
agt_cfg_nodeptr_t *nodeptr = (agt_cfg_nodeptr_t *)
dlq_firstEntry(&undo->extra_deleteQ);
for (; nodeptr && res == NO_ERR;
nodeptr = (agt_cfg_nodeptr_t *)dlq_nextEntry(nodeptr)) {
if (nodeptr && nodeptr->node) {
newval = nodeptr->node;
res = handle_user_callback(AGT_CB_APPLY, editop, scb, msg,
newval, curval, lookparent,
indelete);
if (res == NO_ERR) {
res = handle_user_callback(AGT_CB_COMMIT, editop, scb, msg,
newval, curval, lookparent,
indelete);
}
} else {
SET_ERROR(ERR_INTERNAL_VAL);
}
}
}
if (res != NO_ERR) {
log_error("\nError: SIL rejected reverse edit (%s)",
get_error_string(res));
}
return res;
} /* reverse_edit */
/********************************************************************
* FUNCTION rollback_edit
*
* Attempt to rollback an edit
*
* INPUTS:
* undo == agt_cfg_undo_rec_t struct to process
* scb == session control block
* msg == incoming rpc_msg_t in progress
* target == cfg_template_t for the config database to write
*
* RETURNS:
* status
*********************************************************************/
static status_t
rollback_edit (agt_cfg_undo_rec_t *undo,
ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target)
{
val_value_t *curval = NULL;
status_t res = NO_ERR;
ncx_cfg_t cfgid = msg->rpc_txcb->cfg_id;
if (LOGDEBUG2) {
val_value_t *logval = undo->newnode ? undo->newnode : undo->curnode;
log_debug2("\nRollback transaction %llu, %s edit on %s:%s",
(unsigned long long)msg->rpc_txcb->txid,
op_editop_name(undo->editop),
val_get_mod_name(logval),
logval->name);
}
if (undo->editop == OP_EDITOP_LOAD) {
log_debug3("\nSkipping rollback edit of LOAD operation");
undo->newnode = NULL;
return NO_ERR;
}
if (undo->curnode_clone != NULL) {
curval = undo->curnode_clone;
} else {
curval = undo->curnode;
}
switch (undo->commit_res) {
case NO_ERR:
/* need a redo edit since the SIL already completed the commit */
res = reverse_edit(undo, scb, msg);
break;
case ERR_NCX_SKIPPED:
/* need a simple undo since the commit fn was never called
* first call the SIL with the ROLLBACK request
*/
if (cfgid == NCX_CFGID_RUNNING) {
undo->rollback_res = handle_user_callback(AGT_CB_ROLLBACK,
undo->editop,
scb, msg, undo->newnode,
curval, TRUE, FALSE);
if (undo->rollback_res != NO_ERR) {
val_value_t *logval = undo->newnode ? undo->newnode : curval;
log_warn("\nWarning: SIL rollback for %s:%s in transaction "
"%llu failed (%s)",
(unsigned long long)msg->rpc_txcb->txid,
val_get_mod_name(logval),
logval->name,
get_error_string(undo->rollback_res));
res = undo->rollback_res;
/* !!! not sure what the SIL callback thinks the resulting data
* is going to look like; return to original state anyway */
}
}
break;
default:
/* this is the node that failed during the COMMIT callback
* assuming this SIL does not need any rollback since the
* failure indicates the commit was not applied;
* TBD: need to flag SIL partial commit errors and what
* to do about it */
;
}
/* if the source is from a PDU, then it will get cleanup up when
* this <rpc> is done. If it is from <candidate> config then
* preserve the edit in candidate since it is still a pending edit
* in case commit is attempted again */
//clean_node(undo->newnode);
//val_clear_dirty_flag(undo->newnode);
//clean_node(undo->curnode);
//val_clear_dirty_flag(undo->curnode);
/* undo the specific operation
* even if the SIL commit callback returned an error
* the commit_edit function was never called so this
* edit needs to be cleaned up */
switch (undo->editop) {
case OP_EDITOP_CREATE:
/* delete the node from the tree; if there was a default
* leaf before then restore curval as well */
val_remove_child(undo->newnode);
restore_newnode(undo);
restore_curnode(undo, target);
break;
case OP_EDITOP_DELETE:
case OP_EDITOP_REMOVE:
/* no need to restore newnode */
restore_curnode(undo, target);
break;
case OP_EDITOP_MERGE:
case OP_EDITOP_REPLACE:
/* check if the old node needs to be swapped back
* or if the new node is just removed
*/
restore_curnode(undo, target);
/* undo newval that was a new or merged child node */
if (undo->newnode_marker) {
val_remove_child(undo->newnode);
}
restore_newnode(undo);
break;
default:
res = SET_ERROR(ERR_INTERNAL_VAL);
}
restore_extra_deletes(&undo->extra_deleteQ);
return res;
} /* rollback_edit */
/********************************************************************
* FUNCTION attempt_commit
*
* Attempt complete commit by asking all SIL COMMIT callbacks
* to complete the requested edit
*
* INPUTS:
* scb == session control block
* msg == incoming rpc_msg_t in progress
* target == cfg_template_t for the config database to write
*
* OUTPUTS:
* if errors are encountered (such as undo-failed) then they
* will be added to the msg->mhdr.errQ
*
* RETURNS:
* status
*********************************************************************/
static status_t
attempt_commit (ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target)
{
agt_cfg_undo_rec_t *undo = NULL;
agt_cfg_transaction_t *txcb = msg->rpc_txcb;
if (LOGDEBUG) {
uint32 editcnt = dlq_count(&txcb->undoQ);
const xmlChar *cntstr = NULL;
switch (editcnt) {
case 0:
break;
case 1:
cntstr = (const xmlChar *)"edit";
break;
default:
cntstr = (const xmlChar *)"edits";
}
if (editcnt) {
log_debug("\nStart full commit of transaction %llu: %d"
" %s on %s config", txcb->txid,
editcnt, cntstr, target->name);
} else {
log_debug("\nStart full commit of transaction %llu:"
" LOAD operation on %s config",
txcb->txid, target->name);
}
}
/* first make sure all SIL callbacks accept the commit */
if (target->cfg_id == NCX_CFGID_RUNNING) {
undo = (agt_cfg_undo_rec_t *)dlq_firstEntry(&txcb->undoQ);
for (; undo != NULL; undo = (agt_cfg_undo_rec_t *)dlq_nextEntry(undo)) {
if (undo->curnode && undo->curnode->parent == NULL) {
/* node was actually removed in delete operation */
undo->curnode->parent = undo->parentnode;
}
undo->commit_res =
handle_user_callback(AGT_CB_COMMIT, undo->editop, scb, msg,
undo->newnode, undo->curnode, TRUE, FALSE);
if (undo->commit_res != NO_ERR) {
val_value_t *logval = undo->newnode ? undo->newnode :
undo->curnode;
if (LOGDEBUG) {
log_debug("\nHalting commit %llu: %s:%s SIL returned error"
" (%s)",
(unsigned long long)txcb->txid,
val_get_mod_name(logval),
logval->name,
get_error_string(undo->commit_res));
}
return undo->commit_res;
}
}
}
/* all SIL commit callbacks accepted and finalized the commit
* now go through and finalize the edit; this step should not fail
* first, finish deleting any false when-stmt nodes then commit edits */
while (!dlq_empty(&txcb->deadnodeQ)) {
agt_cfg_nodeptr_t *nodeptr = (agt_cfg_nodeptr_t *)
dlq_deque(&txcb->deadnodeQ);
if (nodeptr && nodeptr->node) {
/* mark ancestor nodes dirty before deleting this node */
val_remove_child(nodeptr->node);
val_free_value(nodeptr->node);
} else {
SET_ERROR(ERR_INTERNAL_VAL);
}
agt_cfg_free_nodeptr(nodeptr);
}
undo = (agt_cfg_undo_rec_t *)dlq_firstEntry(&txcb->undoQ);
for (; undo != NULL; undo = (agt_cfg_undo_rec_t *)dlq_nextEntry(undo)) {
commit_edit(scb, msg, undo);
}
/* update the last change time
* this will only apply here to candidate or running
*/
cfg_update_last_ch_time(target);
cfg_update_last_txid(target, txcb->txid);
cfg_set_dirty_flag(target);
agt_profile_t *profile = agt_get_profile();
profile->agt_config_state = AGT_CFG_STATE_OK;
if (LOGDEBUG) {
log_debug("\nComplete commit OK of transaction %llu"
" on %s database", (unsigned long long)txcb->txid,
target->name);
}
return NO_ERR;
} /* attempt_commit */
/********************************************************************
* FUNCTION attempt_rollback
*
* Attempt to rollback a transaction attempt
* if commit not tried:
* All edits have a status of NCX_ERR_SKIPPED
* if commit tried:
* There are N edits that succeeded and commit_res == NO_ERR
* There is 1 edit that the SIL callback rejected with an error
* There are M edits with a commit_res of NCX_ERR_SKIPPED
*
* INPUTS:
* scb == session control block
* msg == incoming rpc_msg_t in progress
* target == cfg_template_t for the config database to write
*
* RETURNS:
* status
*********************************************************************/
static status_t
attempt_rollback (ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target)
{
status_t res = NO_ERR;
agt_cfg_transaction_t *txcb = msg->rpc_txcb;
if (LOGDEBUG) {
uint32 editcnt = dlq_count(&txcb->undoQ);
const xmlChar *cntstr = NULL;
switch (editcnt) {
case 0:
break;
case 1:
cntstr = (const xmlChar *)"edit";
break;
default:
cntstr = (const xmlChar *)"edits";
}
if (editcnt) {
log_debug("\nStart full rollback of transaction %llu: %d"
" %s on %s config", txcb->txid,
editcnt, cntstr, target->name);
} else {
log_debug("\nStart full rollback of transaction %llu:"
" LOAD operation on %s config",
txcb->txid, target->name);
}
}
restore_extra_deletes(&txcb->deadnodeQ);
agt_cfg_undo_rec_t *undo = (agt_cfg_undo_rec_t *)
dlq_firstEntry(&txcb->undoQ);
for (; undo != NULL; undo = (agt_cfg_undo_rec_t *)dlq_nextEntry(undo)) {
/* rollback the edit operation */
undo->rollback_res = rollback_edit(undo, scb, msg, target);
if (undo->rollback_res != NO_ERR) {
res = undo->rollback_res;
}
}
return res;
} /* attempt_rollback */
/********************************************************************
* FUNCTION handle_callback
*
* Invoke all the specified agent typedef callbacks for a
* source and target and write operation
*
* INPUTS:
* cbtyp == callback type being invoked
* editop == parent node edit operation
* scb == session control block
* msg == incoming rpc_msg_t in progress
* target == cfg_template_t for the config database to write
* newval == val_value_t from the PDU
* curval == current value (if any) from the target config
* curparent == current parent node for inserting children
* RETURNS:
* status
*********************************************************************/
static status_t
handle_callback (agt_cbtyp_t cbtyp,
op_editop_t editop,
ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target,
val_value_t *newval,
val_value_t *curval,
val_value_t *curparent)
{
assert( msg && "msg is NULL!" );
assert( msg->rpc_txcb && "txcb is NULL!" );
agt_cfg_transaction_t *txcb = msg->rpc_txcb;
status_t res = NO_ERR;
if (LOGDEBUG2) {
if (editop == OP_EDITOP_DELETE) {
log_debug2("\n\n***** start commit_deletes for "
"session %d, transaction %llu *****\n",
scb ? SES_MY_SID(scb) : 0,
(unsigned long long)txcb->txid);
} else {
log_debug2("\n\n***** start %s callback phase for "
"session %d, transaction %llu *****\n",
agt_cbtype_name(cbtyp), scb ? SES_MY_SID(scb) : 0,
(unsigned long long)txcb->txid);
}
}
/* get the node to check */
if (newval == NULL && curval == NULL) {
return SET_ERROR(ERR_INTERNAL_VAL);
}
/* check if trying to write to a config=false node */
if (newval != NULL && !val_is_config_data(newval)) {
res = ERR_NCX_ACCESS_READ_ONLY;
agt_record_error(scb, &msg->mhdr, NCX_LAYER_OPERATION, res,
NULL, NCX_NT_NONE, NULL, NCX_NT_VAL, newval);
return res;
}
/* check if trying to delete a config=false node */
if (newval == NULL && curval != NULL && !val_is_config_data(curval)) {
res = ERR_NCX_ACCESS_READ_ONLY;
agt_record_error(scb, &msg->mhdr, NCX_LAYER_OPERATION, res, NULL,
NCX_NT_NONE, NULL, NCX_NT_VAL, curval);
return res;
}
/* this is a config node so check the operation further */
switch (cbtyp) {
case AGT_CB_VALIDATE:
case AGT_CB_APPLY:
/* keep checking until all the child nodes have been processed */
res = invoke_btype_cb(cbtyp, editop, scb, msg, target, newval, curval,
curparent);
if (cbtyp == AGT_CB_APPLY) {
txcb->apply_res = res;
}
break;
case AGT_CB_COMMIT:
txcb->commit_res = res = attempt_commit(scb, msg, target);
if (res != NO_ERR) {
txcb->rollback_res = attempt_rollback(scb, msg, target);
if (txcb->rollback_res != NO_ERR) {
log_warn("\nWarning: Recover rollback of transaction "
"%llu failed (%s)",
(unsigned long long)txcb->txid,
get_error_string(txcb->rollback_res));
}
}
break;
case AGT_CB_ROLLBACK:
txcb->rollback_res = res = attempt_rollback(scb, msg, target);
if (res != NO_ERR) {
log_warn("\nWarning: Apply rollback of transaction "
"%llu failed (%s)",
(unsigned long long)txcb->txid,
get_error_string(res));
}
break;
default:
res = SET_ERROR(ERR_INTERNAL_VAL);
}
return res;
} /* handle_callback */
/********************************************************************
* FUNCTION apply_commit_deletes
*
* Apply the requested commit delete operations
*
* Invoke all the AGT_CB_COMMIT callbacks for a
* source and target and write operation
*
* INPUTS:
* scb == session control block
* msg == incoming commit rpc_msg_t in progress
* target == target database (NCX_CFGID_RUNNING)
* candval == value struct from the candidate config
* runval == value struct from the running config
*
* OUTPUTS:
* rpc_err_rec_t structs may be malloced and added
* to the msg->mhsr.errQ
*
* RETURNS:
* status
*********************************************************************/
static status_t
apply_commit_deletes (ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target,
val_value_t *candval,
val_value_t *runval)
{
val_value_t *curval, *nextval;
status_t res = NO_ERR;
if (candval == NULL || runval == NULL) {
return NO_ERR;
}
/* go through running config
* if the matching node is not in the candidate,
* then delete that node in the running config as well
*/
for (curval = val_get_first_child(runval);
curval != NULL && res == NO_ERR;
curval = nextval) {
nextval = val_get_next_child(curval);
/* check only database config nodes */
if (obj_is_data_db(curval->obj) &&
obj_is_config(curval->obj)) {
/* check if node deleted in source */
val_value_t *matchval = val_first_child_match(candval, curval);
if (!matchval) {
/* prevent the agt_val code from ignoring this node */
val_set_dirty_flag(curval);
/* deleted in the source, so delete in the target */
res = handle_callback(AGT_CB_APPLY, OP_EDITOP_DELETE,
scb, msg, target, NULL, curval, runval);
}
} /* else skip non-config database node */
}
return res;
} /* apply_commit_deletes */
/********************************************************************
* FUNCTION compare_unique_testsets
*
* Compare 2 Qs of val_unique_t structs
*
* INPUTS:
* uni1Q == Q of val_unique_t structs for value1
* uni2Q == Q of val_unique_t structs for value2
*
* RETURNS:
* TRUE if compare test is equal
* FALSE if compare test not equal
*********************************************************************/
static boolean
compare_unique_testsets (dlq_hdr_t *uni1Q,
dlq_hdr_t *uni2Q)
{
/* compare the 2 Qs of values */
val_unique_t *uni1 = (val_unique_t *)dlq_firstEntry(uni1Q);
val_unique_t *uni2 = (val_unique_t *)dlq_firstEntry(uni2Q);
while (uni1 && uni2) {
status_t res = NO_ERR;
boolean cmpval = xpath1_compare_nodeset_results(uni1->pcb,
uni1->pcb->result,
uni2->pcb->result,
&res);
if (res != NO_ERR) {
// log_error()!!
return FALSE;
}
if (!cmpval) {
return FALSE;
}
uni1 = (val_unique_t *)dlq_nextEntry(uni1);
uni2 = (val_unique_t *)dlq_nextEntry(uni2);
}
return TRUE;
} /* compare_unique_testsets */
/********************************************************************
* FUNCTION new_unique_set
* Malloc and init a new unique test set
*
* \return the malloced data structure
*********************************************************************/
static unique_set_t * new_unique_set (void)
{
unique_set_t *uset = m__getObj(unique_set_t);
if (uset == NULL) {
return NULL;
}
memset(uset, 0x0, sizeof(unique_set_t));
dlq_createSQue(&uset->uniqueQ);
return uset;
} /* new_unique_set */
/********************************************************************
* FUNCTION free_unique_set
* Clean and free a unique test set
*
* \param uset the data structure to clean and free
*********************************************************************/
static void free_unique_set (unique_set_t *uset)
{
if (uset == NULL) {
return;
}
val_unique_t *unival;
while (!dlq_empty(&uset->uniqueQ)) {
unival = (val_unique_t *)dlq_deque(&uset->uniqueQ);
val_free_unique(unival);
}
m__free(uset);
} /* free_unique_set */
/********************************************************************
* FUNCTION make_unique_testset
*
* Construct a Q of val_unique_t records, each with the
* current value of the corresponding obj_unique_comp_t
* If a node is not present the test will be stopped,
* ERR_NCX_CANCELED will be returned in the status parm,
* Any nodes in the resultQ will be left there
* and need to be deleted
*
* INPUTS:
* curval == value to run test for
* unidef == obj_unique_t to process
* root == XPath docroot to use
* resultQ == Queue header to store the val_unique_t records
* freeQ == Queue of free val_unique_t records to check first
*
* OUTPUTS:
* resultQ has zero or more val_unique_t structs added
* which need to be freed with the val_free_unique fn
*
* RETURNS:
* status of the operation, NO_ERR if all nodes found and stored OK
*********************************************************************/
static status_t
make_unique_testset (val_value_t *curval,
obj_unique_t *unidef,
val_value_t *root,
dlq_hdr_t *resultQ,
dlq_hdr_t *freeQ)
{
/* need to get a non-const pointer to the module */
if (curval->obj == NULL) {
return SET_ERROR(ERR_INTERNAL_VAL);
}
ncx_module_t *mod = curval->obj->tkerr.mod;
status_t retres = NO_ERR;
obj_unique_comp_t *unicomp = obj_first_unique_comp(unidef);
if (!unicomp) {
/* really should not happen */
return ERR_NCX_CANCELED;
}
/* for each unique component, get the descendant
* node that is specifies and save it in a val_unique_t
*/
while (unicomp && retres == NO_ERR) {
if (unicomp->isduplicate) {
unicomp = obj_next_unique_comp(unicomp);
continue;
}
xpath_pcb_t *targpcb = NULL;
status_t res = xpath_find_val_unique(curval, mod, unicomp->xpath,
root, FALSE, &targpcb);
if (res != NO_ERR) {
retres = ERR_NCX_CANCELED;
xpath_free_pcb(targpcb);
continue;
}
/* skip the entire unique test for this list entry
* if this is an empty node-set */
if (xpath_get_first_resnode(targpcb->result) == NULL) {
retres = ERR_NCX_CANCELED;
xpath_free_pcb(targpcb);
continue;
}
val_unique_t *unival = (val_unique_t *)dlq_deque(freeQ);
if (!unival) {
unival = val_new_unique();
if (!unival) {
retres = ERR_INTERNAL_MEM;
xpath_free_pcb(targpcb);
continue;
}
}
unival->pcb = targpcb;
dlq_enque(unival, resultQ);
unicomp = obj_next_unique_comp(unicomp);
}
return retres;
} /* make_unique_testset */
/********************************************************************
* FUNCTION one_unique_stmt_check
*
* Run the unique-stmt test for the specified list object type
*
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* msg == xml_msg_hdr t from msg in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* ct == commit test record to use
* root == XPath docroot to use
* unidef == obj_unique_t to process
* uninum == ordinal ID for this unique-stmt
*
* OUTPUTS:
* if msg not NULL:
* msg->msg_errQ may have rpc_err_rec_t structs added to it
* which must be freed by the called with the
* rpc_err_free_record function
*
* RETURNS:
* status of the operation, NO_ERR if no validation errors found
*********************************************************************/
static status_t
one_unique_stmt_check (ses_cb_t *scb,
xml_msg_hdr_t *msg,
agt_cfg_commit_test_t *ct,
val_value_t *root,
obj_unique_t *unidef,
uint32 uninum)
{
dlq_hdr_t uniQ, freeQ, usetQ;
val_unique_t *unival;
unique_set_t *uset;
assert( ct && "ct is NULL!" );
assert( ct->result && "result is NULL!" );
assert( unidef && "unidef is NULL!" );
assert( unidef->xpath && "xpath is NULL!" );
status_t retres = NO_ERR;
dlq_createSQue(&uniQ); // Q of val_unique_t
dlq_createSQue(&freeQ); // Q of val_unique_t
dlq_createSQue(&usetQ); // Q of unique_set_t
if (LOGDEBUG3) {
log_debug3("\nunique_chk: %s:%s start unique # %u (%s)",
obj_get_mod_name(ct->obj), obj_get_name(ct->obj),
uninum, unidef->xpath);
}
/* create a unique test set for each list instance that has
* complete tuple to test; skip all instances with partial tuples */
xpath_resnode_t *resnode = xpath_get_first_resnode(ct->result);
for (; resnode && retres == NO_ERR;
resnode = xpath_get_next_resnode(resnode)) {
val_value_t *valnode = xpath_get_resnode_valptr(resnode);
status_t res = make_unique_testset(valnode, unidef, root, &uniQ,
&freeQ);
if (res == NO_ERR) {
/* this valnode provided a complete tuple so it will be
* used in the compare test */
uset = new_unique_set();
if (uset == NULL) {
retres = ERR_INTERNAL_MEM;
continue;
}
dlq_block_enque(&uniQ, &uset->uniqueQ);
uset->valnode = valnode;
dlq_enque(uset, &usetQ);
} else if (res == ERR_NCX_CANCELED) {
dlq_block_enque(&uniQ, &freeQ);
} else {
retres = res;
}
}
/* done with these 2 queues */
while (!dlq_empty(&uniQ)) {
unival = (val_unique_t *)dlq_deque(&uniQ);
val_free_unique(unival);
}
while (!dlq_empty(&freeQ)) {
unival = (val_unique_t *)dlq_deque(&freeQ);
val_free_unique(unival);
}
if (retres == NO_ERR) {
/* go through all the test sets and compare them to each other
* this is a brute force compare N to N+1 .. last moving N
* through the list until all entries have been compared to
* each other and all unique violations recorded;
* As compare is done, delete old set1 since no longer needed */
while (!dlq_empty(&usetQ)) {
unique_set_t *set1 = (unique_set_t *)dlq_deque(&usetQ);
if (set1 && set1->valnode->res != ERR_NCX_UNIQUE_TEST_FAILED) {
unique_set_t *set2 = (unique_set_t *)dlq_firstEntry(&usetQ);
for (; set2; set2 = (unique_set_t *)dlq_nextEntry(set2)) {
if (set2->valnode->res == ERR_NCX_UNIQUE_TEST_FAILED) {
// already compared this to rest of list instances
// if it is flagged with a unique-test failed error
continue;
}
if (compare_unique_testsets(&set1->uniqueQ,
&set2->uniqueQ)) {
/* 2 lists have the same values so generate an error */
agt_record_unique_error(scb, msg, set1->valnode,
&set1->uniqueQ);
set1->valnode->res = ERR_NCX_UNIQUE_TEST_FAILED;
retres = ERR_NCX_UNIQUE_TEST_FAILED;
}
}
}
free_unique_set(set1);
}
}
while (!dlq_empty(&usetQ)) {
uset = (unique_set_t *)dlq_deque(&usetQ);
free_unique_set(uset);
}
return retres;
} /* one_unique_stmt_check */
/********************************************************************
* FUNCTION unique_stmt_check
*
* Check for the proper uniqueness of the tuples within
* the set of list instances for the specified node
*
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* msg == xml_msg_hdr t from msg in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* ct == commit test record to use
* root == XPath docroot to use
*
* OUTPUTS:
* if msg not NULL:
* msg->msg_errQ may have rpc_err_rec_t structs added to it
* which must be freed by the called with the
* rpc_err_free_record function
*
* RETURNS:
* status of the operation, NO_ERR if no validation errors found
*********************************************************************/
static status_t
unique_stmt_check (ses_cb_t *scb,
xml_msg_hdr_t *msg,
agt_cfg_commit_test_t *ct,
val_value_t *root)
{
obj_unique_t *unidef = obj_first_unique(ct->obj);
uint32 uninum = 0;
status_t retres = NO_ERR;
/* try to catch as many errors as possible, so keep going
* even if an error recorded already */
while (unidef) {
++uninum;
if (unidef->isconfig) {
status_t res = one_unique_stmt_check(scb, msg, ct, root,
unidef, uninum);
CHK_EXIT(res, retres);
}
unidef = obj_next_unique(unidef);
}
return retres;
} /* unique_stmt_check */
/********************************************************************
* FUNCTION instance_xpath_check
*
* Check the leafref or instance-identifier leaf or leaf-list node
* Test 'require-instance' for the NCX_BT_LEAFREF
* and NCX_BT_INSTANCE_ID data types
*
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* msg == xml_msg_hdr t from msg in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* val == value node to check
* root == config root for 'val'
* layer == NCX layer calling this function (for error purposes only)
*
* OUTPUTS:
* if msg not NULL:
* msg->msg_errQ may have rpc_err_rec_t structs added to it
* which must be freed by the called with the
* rpc_err_free_record function
*
* RETURNS:
* status of the operation, NO_ERR if no validation errors found
*********************************************************************/
static status_t
instance_xpath_check (ses_cb_t *scb,
xml_msg_hdr_t *msg,
val_value_t *val,
val_value_t *root,
ncx_layer_t layer)
{
xpath_result_t *result;
xpath_pcb_t *xpcb;
ncx_errinfo_t *errinfo;
typ_def_t *typdef;
boolean constrained, fnresult;
status_t res, validateres;
res = NO_ERR;
errinfo = NULL;
typdef = obj_get_typdef(val->obj);
switch (val->btyp) {
case NCX_BT_LEAFREF:
/* do a complete parsing to retrieve the
* instance that matched; this is always constrained
* to 1 of the instances that exists at commit-time
*/
xpcb = typ_get_leafref_pcb(typdef);
if (!val->xpathpcb) {
val->xpathpcb = xpath_clone_pcb(xpcb);
if (!val->xpathpcb) {
res = ERR_INTERNAL_MEM;
}
}
if (res == NO_ERR) {
assert( scb && "scb is NULL!" );
result = xpath1_eval_xmlexpr(scb->reader, val->xpathpcb,
val, root, FALSE, TRUE, &res);
if (result && res == NO_ERR) {
/* check result: the string value in 'val'
* must match one of the values in the
* result set
*/
fnresult =
xpath1_compare_result_to_string(val->xpathpcb, result,
VAL_STR(val), &res);
if (res == NO_ERR && !fnresult) {
/* did not match any of the
* current instances (13.5)
*/
res = ERR_NCX_MISSING_VAL_INST;
}
}
xpath_free_result(result);
}
if (res != NO_ERR) {
val->res = res;
agt_record_error_errinfo(scb, msg, layer, res, NULL, NCX_NT_OBJ,
val->obj, NCX_NT_VAL, val, errinfo);
}
break;
case NCX_BT_INSTANCE_ID:
/* do a complete parsing to retrieve the
* instance that matched, just checking the
* require-instance flag
*/
result = NULL;
constrained = typ_get_constrained(typdef);
validateres = val->xpathpcb->validateres;
if (validateres == NO_ERR) {
assert( scb && "scb is NULL!" );
result = xpath1_eval_xmlexpr(scb->reader, val->xpathpcb,
val, root, FALSE, FALSE, &res);
if (result) {
xpath_free_result(result);
}
if (!constrained) {
if (!NEED_EXIT(res)) {
res = NO_ERR;
}
}
if (res != NO_ERR) {
val->res = res;
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_OBJ,
val->obj, NCX_NT_VAL, val);
}
}
break;
default:
;
}
return res;
} /* instance_xpath_check */
/********************************************************************
* FUNCTION instance_check
*
* Check for the proper number of object instances for
* the specified value struct. Checks the direct accessible
* children of 'val' only!!!
*
* The top-level value set passed cannot represent a choice
* or a case within a choice.
*
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* msg == xml_msg_hdr t from msg in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* obj == object template for child node in valset to check
* val == val_value_t list, leaf-list, or container to check
* valroot == root node of the database
* layer == NCX layer calling this function (for error purposes only)
*
* OUTPUTS:
* if msg not NULL:
* msg->msg_errQ may have rpc_err_rec_t structs added to it
* which must be freed by the called with the
* rpc_err_free_record function
*
* RETURNS:
* status of the operation, NO_ERR if no validation errors found
*********************************************************************/
static status_t
instance_check (ses_cb_t *scb,
xml_msg_hdr_t *msg,
obj_template_t *obj,
val_value_t *val,
val_value_t *valroot,
ncx_layer_t layer)
{
/* skip this node if it is non-config */
if (!obj_is_config(val->obj)) {
if (LOGDEBUG3) {
log_debug3("\ninstance_chk: skipping r/o node '%s:%s'",
obj_get_mod_name(val->obj),
val->name);
}
return NO_ERR;
}
/* check if the child node is config
* this function only tests server requirements
* and ignores mandatory read-only nodes;
* otherwise the test on candidate would always fail
*/
if (!obj_is_config(obj)) {
if (LOGDEBUG3) {
log_debug3("\ninstance_chk: skipping r/o node '%s:%s'",
obj_get_mod_name(obj),
obj_get_name(obj));
}
return NO_ERR;
}
val_value_t *errval = NULL;
xmlChar *instbuff = NULL;
status_t res = NO_ERR, res2 = NO_ERR;
// do not need to check again to see if conditional object is present
//iqual = val_get_cond_iqualval(val, valroot, obj);
ncx_iqual_t iqual = obj_get_iqualval(obj);
boolean cond = FALSE;
boolean whendone = FALSE;
uint32 whencnt = 0;
boolean minerr = FALSE;
boolean maxerr = FALSE;
uint32 minelems = 0;
uint32 maxelems = 0;
boolean minset = obj_get_min_elements(obj, &minelems);
boolean maxset = obj_get_max_elements(obj, &maxelems);
uint32 cnt = val_instance_count(val, obj_get_mod_name(obj),
obj_get_name(obj));
if (LOGDEBUG3) {
if (!minset) {
switch (iqual) {
case NCX_IQUAL_ONE:
case NCX_IQUAL_1MORE:
minelems = 1;
break;
case NCX_IQUAL_ZMORE:
case NCX_IQUAL_OPT:
minelems = 0;
break;
default:
SET_ERROR(ERR_INTERNAL_VAL);
}
}
if (!maxset) {
switch (iqual) {
case NCX_IQUAL_ONE:
case NCX_IQUAL_OPT:
maxelems = 1;
break;
case NCX_IQUAL_1MORE:
case NCX_IQUAL_ZMORE:
maxelems = 0;
break;
default:
SET_ERROR(ERR_INTERNAL_VAL);
}
}
char buff[NCX_MAX_NUMLEN];
if (maxelems) {
snprintf(buff, sizeof(buff), "%u", maxelems);
}
log_debug3("\ninstance_check '%s:%s' against '%s:%s'\n"
" (cnt=%u, min=%u, max=%s)",
obj_get_mod_name(obj),
obj_get_name(obj),
obj_get_mod_name(val->obj),
val->name,
cnt,
minelems,
maxelems ? buff : "unbounded");
}
if (minset) {
if (cnt < minelems) {
if (cnt == 0) {
/* need to check if this node is conditional because
* of when stmt, and if so, whether when-cond is false */
res = val_check_obj_when(val, valroot, NULL, obj,
&cond, &whencnt);
if (res == NO_ERR) {
whendone = TRUE;
if (whencnt && !cond) {
if (LOGDEBUG2) {
log_debug2("\nwhen_chk: skip false when-stmt for "
"node '%s:%s'", obj_get_mod_name(obj),
obj_get_name(obj));
}
return NO_ERR;
}
} else {
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_NONE,
NULL, NCX_NT_VAL, errval);
return res;
}
}
/* not enough instances error */
minerr = TRUE;
res = ERR_NCX_MIN_ELEMS_VIOLATION;
val->res = res;
if (cnt) {
/* use the first child instance as the
* value node for the error-path
*/
errval = val_find_child(val, obj_get_mod_name(obj),
obj_get_name(obj));
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_NONE,
NULL, NCX_NT_VAL, errval);
} else {
/* need to construct a string error-path */
instbuff = NULL;
res2 = val_gen_split_instance_id(msg, val, NCX_IFMT_XPATH1,
obj_get_nsid(obj),
obj_get_name(obj),
FALSE, &instbuff);
if (res2 == NO_ERR && instbuff) {
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_NONE,
NULL, NCX_NT_STRING, instbuff);
} else {
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_NONE,
NULL, NCX_NT_VAL, val);
}
if (instbuff) {
m__free(instbuff);
}
}
}
}
if (maxset) {
if (cnt > maxelems) {
maxerr = TRUE;
res = ERR_NCX_MAX_ELEMS_VIOLATION;
val->res = res;
/* too many instances error
* need to find all the extra instances
* and mark the extras as errors or they will
* not get removed later
*/
val_set_extra_instance_errors(val, obj_get_mod_name(obj),
obj_get_name(obj),
maxelems);
/* use the first extra child instance as the
* value node for the error-path
* this should always find a node, since 'cnt' > 0
*/
errval = val_find_child(val, obj_get_mod_name(obj),
obj_get_name(obj));
uint32 i = 1;
while (errval && i <= maxelems) {
errval = val_get_next_child(errval);
i++;
}
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_OBJ, obj,
NCX_NT_VAL, (errval) ? errval : val);
}
}
switch (iqual) {
case NCX_IQUAL_ONE:
case NCX_IQUAL_1MORE:
if (cnt == 0 && !minerr) {
/* need to check if this node is conditional because
* of when stmt, and if so, whether when-cond is false */
if (!whendone) {
cond = FALSE;
whencnt = 0;
res = val_check_obj_when(val, valroot, NULL, obj,
&cond, &whencnt);
if (res == NO_ERR) {
if (whencnt && !cond) {
if (LOGDEBUG2) {
log_debug2("\nwhen_chk: skip false when-stmt for "
"node '%s:%s'", obj_get_mod_name(obj),
obj_get_name(obj));
}
return NO_ERR;
}
} else {
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_NONE,
NULL, NCX_NT_VAL, errval);
return res;
}
}
/* make sure this object is not an NP container with
* mandatory descendant nodes which also have a when-stmt
* !!! For now, not clear if when-stmt and mandatory-stmt
* !!! together can be enforced if the context node does
* !!! not exist; creating a dummy context node changes
* !!! the data model. */
if (obj_is_np_container(obj) &&
!obj_is_mandatory_when_ex(obj, TRUE)) {
/* this NP container is mandatory but there are when-stmts
* that go with the mandatory nodes, so do not generate
* an error for this NP container. If this container
* is non-empty then the when-tests will be run for
* those runs after test for this node exits */
;
} else {
/* missing single parameter (13.5) */
res = ERR_NCX_MISSING_VAL_INST;
val->res = res;
/* need to construct a string error-path */
instbuff = NULL;
res2 = val_gen_split_instance_id(msg, val, NCX_IFMT_XPATH1,
obj_get_nsid(obj),
obj_get_name(obj),
FALSE, &instbuff);
if (res2 == NO_ERR && instbuff) {
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_OBJ,
obj, NCX_NT_STRING, instbuff);
} else {
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_OBJ,
obj, NCX_NT_VAL, val);
}
if (instbuff) {
m__free(instbuff);
}
}
}
if (iqual == NCX_IQUAL_1MORE) {
break;
}
/* else fall through */
case NCX_IQUAL_OPT:
if (cnt > 1 && !maxerr) {
/* too many parameters */
val_set_extra_instance_errors(val, obj_get_mod_name(obj),
obj_get_name(obj), 1);
res = ERR_NCX_EXTRA_VAL_INST;
val->res = res;
/* use the first extra child instance as the
* value node for the error-path
*/
errval = val_find_child(val, obj_get_mod_name(obj),
obj_get_name(obj));
uint32 i = 1;
while (errval && i < maxelems) {
errval = val_get_next_child(errval);
i++;
}
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_OBJ,
obj, NCX_NT_VAL, (errval) ? errval : val);
}
break;
case NCX_IQUAL_ZMORE:
break;
default:
res = SET_ERROR(ERR_INTERNAL_VAL);
val->res = res;
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_OBJ, obj,
NCX_NT_VAL, val);
}
return res;
} /* instance_check */
/********************************************************************
* FUNCTION choice_check_agt
*
* Agent version of ncx/val_util.c/choice_check
*
* Check a val_value_t struct against its expected OBJ
* for instance validation:
*
* - choice validation:
* only one case allowed if the data type is choice
* Only issue errors based on the instance test qualifiers
*
* The input is checked against the specified obj_template_t.
*
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* msg == xml_msg_hdr t from msg in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* choicobj == object template for the choice to check
* val == parent val_value_t list or container to check
* valroot == root node of the database
* layer == NCX layer calling this function (for error purposes only)
*
* OUTPUTS:
* if msg not NULL:
* msg->msg_errQ may have rpc_err_rec_t structs added to it
* which must be freed by the called with the
* rpc_err_free_record function
*
* RETURNS:
* status of the operation, NO_ERR if no validation errors found
*********************************************************************/
static status_t
choice_check_agt (ses_cb_t *scb,
xml_msg_hdr_t *msg,
obj_template_t *choicobj,
val_value_t *val,
val_value_t *valroot,
ncx_layer_t layer)
{
status_t res = NO_ERR, retres = NO_ERR;
if (LOGDEBUG3) {
log_debug3("\nchoice_check_agt: check '%s:%s' against '%s:%s'",
obj_get_mod_name(choicobj),
obj_get_name(choicobj),
obj_get_mod_name(val->obj),
val->name);
}
/* Go through all the child nodes for this object
* and look for choices against the value set to see if each
* a choice case is present in the correct number of instances.
*
* The current value could never be a OBJ_TYP_CHOICE since
* those nodes are not stored in the val_value_t tree
* Instead, it is the parent of the choice object,
* and the accessible case nodes will be child nodes
* of that complex parent type
*/
val_value_t *chval = val_get_choice_first_set(val, choicobj);
if (!chval) {
if (obj_is_mandatory(choicobj)) {
/* error missing choice (13.6) */
res = ERR_NCX_MISSING_CHOICE;
agt_record_error(scb, msg, layer, res, NULL, NCX_NT_VAL, val,
NCX_NT_VAL, val);
}
return res;
}
/* else a choice was selected
* first make sure all the mandatory case
* objects are present
*/
obj_template_t *testobj = obj_first_child(chval->casobj);
for (; testobj != NULL; testobj = obj_next_child(testobj)) {
res = instance_check(scb, msg, testobj, val, valroot, layer);
CHK_EXIT(res, retres);
/* errors already recorded if other than NO_ERR */
}
/* check if any objects from other cases are present */
val_value_t *testval = val_get_choice_next_set(choicobj, chval);
while (testval) {
if (testval->casobj != chval->casobj) {
/* error: extra case object in this choice */
retres = res = ERR_NCX_EXTRA_CHOICE;
agt_record_error(scb, msg, layer, res, NULL,
NCX_NT_OBJ, choicobj, NCX_NT_VAL, testval);
}
testval = val_get_choice_next_set(choicobj, testval);
}
if (val->res == NO_ERR) {
val->res = retres;
}
return retres;
} /* choice_check_agt */
/********************************************************************
* Perform a must statement check of the object tree.
* Check for any must-stmts in the object tree and validate the Xpath
* expression against the complete database 'root' and current
* context node 'curval'.
*
* \param scb session control block (may be NULL; no session stats)
* \param msg xml_msg_hdr t from msg in progress, NULL means no RPC-ERROR
recording.
* \param root val_value_t or the target database root to validate
* \param curval val_value_t for the current context node in the tree
* \return NO_ERR if there are no validation errors.
*********************************************************************/
static status_t must_stmt_check ( ses_cb_t *scb,
xml_msg_hdr_t *msg,
val_value_t *root,
val_value_t *curval )
{
status_t res = NO_ERR;
obj_template_t *obj = curval->obj;
if ( !obj_is_config(obj) ) {
return NO_ERR;
}
dlq_hdr_t *mustQ = obj_get_mustQ(obj);
if ( !mustQ || dlq_empty( mustQ ) ) {
/* There are no must statements, return NO ERR */
return NO_ERR;
}
/* execute all the must tests top down, so* foo/bar errors are reported
* before /foo/bar/child */
xpath_pcb_t *must = (xpath_pcb_t *)dlq_firstEntry(mustQ);
for ( ; must; must = (xpath_pcb_t *)dlq_nextEntry(must)) {
res = NO_ERR;
xpath_result_t *result = xpath1_eval_expr( must, curval, root, FALSE,
TRUE, &res );
if ( !result || res != NO_ERR ) {
log_error("\nmust_chk: failed for %s:%s (%s) expr '%s'",
obj_get_mod_name(obj), curval->name, get_error_string(res),
must->exprstr );
if (res == NO_ERR) {
res = ERR_INTERNAL_VAL;
SET_ERROR( res );
}
} else if (!xpath_cvt_boolean(result)) {
log_debug2("\nmust_chk: false for %s:%s expr '%s'",
obj_get_mod_name(obj), curval->name, must->exprstr);
res = ERR_NCX_MUST_TEST_FAILED;
} else {
log_debug3("\nmust_chk: OK for %s:%s expr '%s'",
obj_get_mod_name(obj), curval->name, must->exprstr);
}
if ( NO_ERR != res ) {
agt_record_error_errinfo(scb, msg, NCX_LAYER_CONTENT, res, NULL,
NCX_NT_STRING, must->exprstr, NCX_NT_VAL, curval,
( ( ncx_errinfo_set( &must->errinfo) ) ? &must->errinfo
: NULL ) );
if ( terminate_parse( res ) ) {
return res;
}
curval->res = res;
}
xpath_free_result(result);
}
return res;
} /* must_stmt_check */
/********************************************************************
* FUNCTION run_when_stmt_check
*
* Run one when-stmt test on a node
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* msg == xml_msg_hdr t from msg in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* root == val_value_t or the target database root to validate
* curval == val_value_t for the current context node in the tree
* configmode == TRUE to test config-TRUE
* FALSE to test config=FALSE
* deleteQ == address of Q for deleted descendants
* deleteme == address of return delete flag
*
* OUTPUTS:
* if msg not NULL:
* msg->msg_errQ may have rpc_err_rec_t structs added to it
* which must be freed by the called with the
* rpc_err_free_record function
* txcb->deadnodeQ will have any deleted instance entries
* due to false when-stmt expressions
*
* RETURNS:
* status of the operation, NO_ERR or ERR_INTERNAL_MEM most likely
*********************************************************************/
static status_t
run_when_stmt_check (ses_cb_t *scb,
xml_msg_hdr_t *msg,
agt_cfg_transaction_t *txcb,
val_value_t *root,
val_value_t *curval)
{
obj_template_t *obj = curval->obj;
status_t res = NO_ERR;
boolean condresult = FALSE;
uint32 whencount = 0;
res = val_check_obj_when(curval->parent, root, curval, obj, &condresult,
&whencount);
if (res != NO_ERR) {
log_error("\nError: when_check: failed for %s:%s (%s)",
obj_get_mod_name(obj),
obj_get_name(obj),
get_error_string(res));
agt_record_error(scb, msg, NCX_LAYER_OPERATION, res, NULL,
NCX_NT_NONE, NULL, NCX_NT_VAL, curval);
} else if (whencount == 0) {
if (LOGDEBUG) {
log_debug("\nwhen_chk: no when-tests found for node '%s:%s'",
obj_get_mod_name(obj), curval->name);
}
} else if (!condresult) {
if (LOGDEBUG2) {
log_debug2("\nwhen_chk: test false for node '%s:%s'",
obj_get_mod_name(obj), curval->name);
}
/* check if this session is allowed to delete this node
* and make sure this node is not partially locked */
if (!agt_acm_val_write_allowed(msg, scb->username, NULL, curval,
OP_EDITOP_DELETE)) {
res = ERR_NCX_ACCESS_DENIED;
agt_record_error(scb, msg, NCX_LAYER_OPERATION, res,
NULL, NCX_NT_NONE, NULL, NCX_NT_NONE, NULL);
return res;
}
uint32 lockid = 0;
res = val_write_ok(curval, OP_EDITOP_DELETE, SES_MY_SID(scb),
TRUE, &lockid);
if (res != NO_ERR) {
agt_record_error(scb, msg, NCX_LAYER_OPERATION, res,
NULL, NCX_NT_UINT32_PTR, &lockid,
NCX_NT_VAL, curval);
return res;
}
/* need to delete the current value */
agt_cfg_nodeptr_t *nodeptr = agt_cfg_new_nodeptr(curval);
if (nodeptr == NULL) {
res = ERR_INTERNAL_MEM;
agt_record_error(scb, msg, NCX_LAYER_OPERATION, res,
NULL, NCX_NT_NONE, NULL, NCX_NT_NONE, NULL);
return res;
}
log_debug("\nMarking false when-stmt as deleted %s:%s",
obj_get_mod_name(obj),
obj_get_name(obj));
dlq_enque(nodeptr, &txcb->deadnodeQ);
VAL_MARK_DELETED(curval);
} else {
if (LOGDEBUG3) {
log_debug3("\nwhen_chk: test passed for node '%s:%s'",
obj_get_mod_name(obj), curval->name);
}
}
return res;
} /* run_when_stmt_check */
/********************************************************************
* FUNCTION rpc_when_stmt_check
*
* Check for any when-stmts in the object tree and validate the Xpath
* expression against the complete database 'root' and current
* context node 'curval'. ONLY USED FOR RPC INPUT CHECKING!!
*
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* rpcmsg == rpc msg header for audit purposes
* msg == xml_msg_hdr t from msg in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* root == val_value_t or the target database root to validate
* curval == val_value_t for the current context node in the tree
*
* OUTPUTS:
* if msg not NULL:
* msg->msg_errQ may have rpc_err_rec_t structs added to it
* which must be freed by the called with the
* rpc_err_free_record function
*
* RETURNS:
* status of the operation
*********************************************************************/
static status_t
rpc_when_stmt_check (ses_cb_t *scb,
rpc_msg_t *rpcmsg,
xml_msg_hdr_t *msg,
val_value_t *root,
val_value_t *curval)
{
obj_template_t *obj = curval->obj;
status_t retres = NO_ERR;
boolean condresult = FALSE;
uint32 whencount = 0;
retres = val_check_obj_when(curval->parent, root, curval, obj, &condresult,
&whencount);
if (retres != NO_ERR) {
log_error("\nError: when_check: failed for %s:%s (%s)",
obj_get_mod_name(obj), obj_get_name(obj),
get_error_string(retres));
agt_record_error(scb, msg, NCX_LAYER_OPERATION, retres, NULL,
NCX_NT_NONE, NULL, NCX_NT_VAL, curval);
return retres;
} else if (whencount && !condresult) {
retres = ERR_NCX_RPC_WHEN_FAILED;
agt_record_error(scb, msg, NCX_LAYER_OPERATION,
retres, NULL, NCX_NT_VAL,
curval, NCX_NT_VAL, curval);
return retres;
} else {
if (LOGDEBUG3 && whencount) {
log_debug3("\nwhen_chk: test passed for node '%s:%s'",
obj_get_mod_name(obj), curval->name);
}
}
/* recurse for every child node until leafs are hit */
val_value_t *chval = val_get_first_child(curval);
for (; chval != NULL && retres == NO_ERR;
chval = val_get_next_child(chval)) {
if (!obj_is_config(chval->obj)) {
continue;
}
if (obj_is_root(chval->obj)) {
/* do not dive into a <config> node parameter
* while processing an RPC input node
*/
continue;
}
retres = rpc_when_stmt_check(scb, rpcmsg, msg, root, chval);
}
return retres;
} /* rpc_when_stmt_check */
/********************************************************************
* Perform a must statement check of the object tree.
* USED FOR RPC INPUT TESTING ONLY
* Check for any must-stmts in the object tree and validate the Xpath
* expression against the complete database 'root' and current
* context node 'curval'.
*
* \param scb session control block (may be NULL; no session stats)
* \param msg xml_msg_hdr t from msg in progress, NULL means no RPC-ERROR
recording.
* \param root val_value_t or the target database root to validate
* \param curval val_value_t for the current context node in the tree
* \return NO_ERR if there are no validation errors.
*********************************************************************/
static status_t rpc_must_stmt_check ( ses_cb_t *scb,
xml_msg_hdr_t *msg,
val_value_t *root,
val_value_t *curval )
{
status_t res;
status_t firstError = NO_ERR;
obj_template_t *obj = curval->obj;
if ( !obj_is_config(obj) ) {
return NO_ERR;
}
dlq_hdr_t *mustQ = obj_get_mustQ(obj);
if ( !mustQ || dlq_empty( mustQ ) ) {
/* There are no must statements, return NO ERR */
return NO_ERR;
}
/* execute all the must tests top down, so* foo/bar errors are reported
* before /foo/bar/child */
xpath_pcb_t *must = (xpath_pcb_t *)dlq_firstEntry(mustQ);
for ( ; must; must = (xpath_pcb_t *)dlq_nextEntry(must)) {
res = NO_ERR;
xpath_result_t *result = xpath1_eval_expr( must, curval, root, FALSE,
TRUE, &res );
if ( !result || res != NO_ERR ) {
log_error("\nrpc_must_chk: failed for %s:%s (%s) expr '%s'",
obj_get_mod_name(obj), curval->name, get_error_string(res),
must->exprstr );
if (res == NO_ERR) {
res = ERR_INTERNAL_VAL;
SET_ERROR( res );
}
} else if (!xpath_cvt_boolean(result)) {
log_debug2("\nrpc_must_chk: false for %s:%s expr '%s'",
obj_get_mod_name(obj), curval->name, must->exprstr);
res = ERR_NCX_MUST_TEST_FAILED;
} else {
log_debug3("\nrpc_must_chk: OK for %s:%s expr '%s'",
obj_get_mod_name(obj), curval->name, must->exprstr);
}
if ( NO_ERR != res ) {
agt_record_error_errinfo(scb, msg, NCX_LAYER_CONTENT, res, NULL,
NCX_NT_STRING, must->exprstr, NCX_NT_VAL, curval,
( ( ncx_errinfo_set( &must->errinfo) ) ? &must->errinfo
: NULL ) );
if ( terminate_parse( res ) ) {
return res;
}
curval->res = res;
firstError = ( firstError != NO_ERR) ? firstError : res;
}
xpath_free_result(result);
}
/* recurse for every child node until leafs are hit but only if the parent
* must test did not fail will check sibling nodes even if some must-test
* already failed; this provides complete errors during validate and
* load_running_config */
if ( firstError == NO_ERR ) {
val_value_t *chval = val_get_first_child(curval);
for ( ; chval; chval = val_get_next_child(chval)) {
/* do not dive into <config> parameters and hit database
* must-stmts by mistake */
if ( !obj_is_root(chval->obj) ) {
res = rpc_must_stmt_check(scb, msg, root, chval);
if ( NO_ERR != res ) {
if ( terminate_parse( res ) ) {
return res;
}
firstError = ( firstError != NO_ERR) ? firstError : res;
}
}
}
}
return firstError;
} /* rpc_must_stmt_check */
/********************************************************************
* FUNCTION prep_commit_test_node
*
* Update the commit test instances
*
* \param scb session control block
* \param msghdr XML message header in progress
* \param txcb transaction control block to use
* \param ct commit test to use
* \param root <config> node to check
*
* \return status
*********************************************************************/
static status_t
prep_commit_test_node ( ses_cb_t *scb,
xml_msg_hdr_t *msghdr,
agt_cfg_transaction_t *txcb,
agt_cfg_commit_test_t *ct,
val_value_t *root )
{
status_t res = NO_ERR;
/* first get all the instances of this object if needed */
if (ct->result) {
if (ct->result_txid == txcb->txid) {
log_debug3("\nReusing XPath result for %s", ct->objpcb->exprstr);
} else {
/* TBD: figure out if older TXIDs are still valid
* for this XPath expression */
log_debug3("\nGet all instances of %s", ct->objpcb->exprstr);
xpath_free_result(ct->result);
ct->result = NULL;
}
}
if (ct->result == NULL) {
ct->result_txid = 0;
ct->result = xpath1_eval_expr(ct->objpcb, root, root, FALSE,
TRUE, &res);
if (res != NO_ERR || ct->result->restype != XP_RT_NODESET) {
if (res == NO_ERR) {
res = ERR_NCX_WRONG_NODETYP;
}
agt_record_error(scb, msghdr, NCX_LAYER_CONTENT, res, NULL,
NCX_NT_NONE, NULL, NCX_NT_OBJ, ct->obj);
} else {
ct->result_txid = txcb->txid;
}
}
return res;
} /* prep_commit_test_node */
/********************************************************************
*
* Delete all the nodes that have false when-stmt exprs
* Also delete empty NP-containers
*
* \param scb session control block (may be NULL)
* \param msghdr XML message header in progress
* \param txcb transaction control block to use
* \param root root from the target database to use
* \param retcount address of return deletecount
* \return status
*********************************************************************/
static status_t delete_dead_nodes ( ses_cb_t *scb,
xml_msg_hdr_t *msghdr,
agt_cfg_transaction_t *txcb,
val_value_t *root,
uint32 *retcount )
{
*retcount = 0;
agt_profile_t *profile = agt_get_profile();
agt_cfg_commit_test_t *ct = (agt_cfg_commit_test_t *)
dlq_firstEntry(&profile->agt_commit_testQ);
for (; ct != NULL; ct = (agt_cfg_commit_test_t *)dlq_nextEntry(ct)) {
uint32 tests = ct->testflags & AGT_TEST_FL_WHEN;
if (tests == 0) {
/* no when-stmt tests needed for this node */
continue;
}
status_t res = prep_commit_test_node(scb, msghdr, txcb, ct, root);
if (res != NO_ERR) {
return res;
}
/* run all relevant tests on each node in the result set */
xpath_resnode_t *resnode = xpath_get_first_resnode(ct->result);
xpath_resnode_t *nextnode = NULL;
for (; resnode != NULL; resnode = nextnode) {
nextnode = xpath_get_next_resnode(resnode);
val_value_t *valnode = xpath_get_resnode_valptr(resnode);
res = run_when_stmt_check(scb, msghdr, txcb, root, valnode);
if (res != NO_ERR) {
/* treat any when delete error as terminate transaction */
return res;
} else if (VAL_IS_DELETED(valnode)) {
/* this node has just been flagged when=FALSE so
* remove this resnode from the result so it will
* not be reused by a commit test */
xpath_delete_resnode(resnode);
(*retcount)++;
}
}
}
return NO_ERR;
} /* delete_dead_nodes */
/********************************************************************
* FUNCTION check_parent_tests
*
* Check if the specified object has any commit tests
* to record in the parent node
*
* INPUTS:
* obj == object to check
* flags == address of return testflags
*
* OUTPUTS:
* *flags is set if any tests are needed
*
*********************************************************************/
static void
check_parent_tests (obj_template_t *obj,
uint32 *flags)
{
uint32 numelems = 0;
switch (obj->objtype) {
case OBJ_TYP_LEAF_LIST:
case OBJ_TYP_LIST:
if (obj_get_min_elements(obj, &numelems)) {
if (numelems > 1) {
*flags |= AGT_TEST_FL_MIN_ELEMS;
} // else AGT_TEST_FL_MANDATORY will check for 1 instance
}
numelems = 0;
if (obj_get_max_elements(obj, &numelems)) {
*flags |= AGT_TEST_FL_MAX_ELEMS;
}
break;
case OBJ_TYP_LEAF:
case OBJ_TYP_CONTAINER:
*flags |= AGT_TEST_FL_MAX_ELEMS;
break;
case OBJ_TYP_CHOICE:
*flags |= AGT_TEST_FL_CHOICE;
break;
default:
;
}
if (obj_is_mandatory(obj) && !obj_is_key(obj)) {
*flags |= AGT_TEST_FL_MANDATORY;
}
} /* check_parent_tests */
/********************************************************************
* FUNCTION add_obj_commit_tests
*
* Check if the specified object and all its descendants
* have any commit tests to record in the commit_testQ
* Tests are added in top-down order
* TBD: cascade XPath lookup results to nested commmit tests
*
* Tests done in the parent node:
* AGT_TEST_FL_MIN_ELEMS
* AGT_TEST_FL_MAX_ELEMS
* AGT_TEST_FL_MANDATORY
*
* Tests done in the object node:
* AGT_TEST_FL_MUST
* AGT_TEST_FL_UNIQUE
* AGT_TEST_FL_XPATH_TYPE
* AGT_TEST_FL_WHEN (part of delete_dead_nodes, not this fn)
*
* INPUTS:
* obj == object to check
* commit_testQ == address of queue to use to fill with
* agt_cfg_commit_test_t structs
* rootflags == address of return root node testflags
*
* OUTPUTS:
* commit_testQ will contain an agt_cfg_commit_test_t struct
* for each descendant-or-self object found with
* commit-time validation tests
* *rootflags will be altered if node is top-level and
* needs instance testing
* RETURNS:
* status of the operation, NO_ERR unless internal errors found
* or malloc error
*********************************************************************/
static status_t
add_obj_commit_tests (obj_template_t *obj,
dlq_hdr_t *commit_testQ,
uint32 *rootflags)
{
if (skip_obj_commit_test(obj)) {
return NO_ERR;
}
status_t res = NO_ERR;
/* check for tests in active config nodes, bottom-up traversal */
uint32 testflags = 0;
dlq_hdr_t *mustQ = obj_get_mustQ(obj);
ncx_btype_t btyp = obj_get_basetype(obj);
obj_template_t *chobj;
if (!(obj->objtype == OBJ_TYP_CHOICE || obj->objtype == OBJ_TYP_CASE)) {
if (mustQ && !dlq_empty(mustQ)) {
testflags |= AGT_TEST_FL_MUST;
}
if (obj_has_when_stmts(obj)) {
testflags |= AGT_TEST_FL_WHEN;
}
}
obj_unique_t *unidef = obj_first_unique(obj);
boolean done = FALSE;
for (; unidef && !done; unidef = obj_next_unique(unidef)) {
if (unidef->isconfig) {
testflags |= AGT_TEST_FL_UNIQUE;
done = TRUE;
}
}
if (obj_is_top(obj)) {
/* need to check if this is a top-level node that
* has instance requirements (mandatory/min/max)
*/
check_parent_tests(obj, rootflags);
}
if (obj->objtype == OBJ_TYP_CHOICE || obj->objtype == OBJ_TYP_CASE) {
/* do not create a commit test record for a choice or case
* since they will never be in the data tree, so XPath
* will never find them */
testflags = 0;
} else {
/* set the instance or MANDATORY test bits in the parent,
* not in the child nodes for each commit test
* check all child nodes to determine if parent needs
* to run instance_check
*/
for (chobj = obj_first_child(obj);
chobj != NULL;
chobj = obj_next_child(chobj)) {
if (skip_obj_commit_test(chobj)) {
continue;
}
check_parent_tests(chobj, &testflags);
}
typ_def_t *typdef = obj_get_typdef(obj);
if (btyp == NCX_BT_LEAFREF ||
(btyp == NCX_BT_INSTANCE_ID && typ_get_constrained(typdef))) {
/* need to check XPath-based leaf to see that the referenced
* instance exists in the target data tree
*/
testflags |= AGT_TEST_FL_XPATH_TYPE;
}
}
if (testflags) {
/* need a commit test record for this object */
agt_cfg_commit_test_t *ct = agt_cfg_new_commit_test();
if (ct == NULL) {
return ERR_INTERNAL_MEM;
}
ct->objpcb = xpath_new_pcb(NULL, NULL);
if (ct->objpcb == NULL) {
agt_cfg_free_commit_test(ct);
return ERR_INTERNAL_MEM;
}
res = obj_gen_object_id_xpath(obj, &ct->objpcb->exprstr);
if (res != NO_ERR) {
agt_cfg_free_commit_test(ct);
return res;
}
ct->obj = obj;
ct->btyp = btyp;
ct->testflags = testflags;
dlq_enque(ct, commit_testQ);
if (LOGDEBUG4) {
log_debug4("\nAdded commit_test record for %s",
ct->objpcb->exprstr);
}
}
for (chobj = obj_first_child(obj);
chobj != NULL;
chobj = obj_next_child(chobj)) {
res = add_obj_commit_tests(chobj, commit_testQ, rootflags);
if (res != NO_ERR) {
return res;
}
}
return res;
} /* add_obj_commit_tests */
/********************************************************************
* FUNCTION check_prune_obj
*
* Check if the specified object test can be reduced or eliminated
* from the current commit test
*
* INPUTS:
* obj == commit test object to check; must not be root!
* rootval == config root to check
* curflags == current test flags
* RETURNS:
* new testflags or unchanged test flags
*********************************************************************/
static uint32
check_prune_obj (obj_template_t *obj,
val_value_t *rootval,
uint32 curflags)
{
/* for now just check the top level object to see if
* this subtree could have possibly changed;
* TBD: come up with fast way to check more, that does
* take as much time as just using XPath to get these objects */
boolean done = FALSE;
obj_template_t *testobj = obj;
while (!done) {
if (testobj->parent && !obj_is_root(testobj->parent)) {
testobj = testobj->parent;
} else {
done = TRUE;
}
}
/* find this object in the rootval */
val_value_t *testval = val_find_child(rootval, obj_get_mod_name(testobj),
obj_get_name(testobj));
if (testval) {
switch (testobj->objtype) {
case OBJ_TYP_LEAF:
case OBJ_TYP_ANYXML:
case OBJ_TYP_CONTAINER:
if (val_dirty_subtree(testval)) {
/* do not skip this node */
return curflags;
}
break;
default:
done = FALSE;
while (!done) {
if (val_dirty_subtree(testval)) {
/* do not skip this node */
return curflags;
} else {
testval =
val_find_next_child(rootval, obj_get_mod_name(testobj),
obj_get_name(testobj), testval);
if (testval == NULL) {
done = TRUE;
}
}
}
}
}
/* skip this node for all tests, since no instances of
* the top-level object exist which might have been changed
* Relying on the fact that the root-check is always done for
* the root node (on the top-level YANG data nodes, so
* any instance or mandatory tests on the top-node will
* always be done */
return 0;
} /* check_prune_obj */
/********************************************************************
* FUNCTION check_no_prune_curedit
*
* Check if the specified object test is needed from the current
* commit test, based on the current edit in the undo record
*
* INPUTS:
* undo == edit operation to check
* obj == commit test object to check; must not be root!
* RETURNS:
* TRUE if found and test needed; FALSE if not found
*********************************************************************/
static boolean
check_no_prune_curedit (agt_cfg_undo_rec_t *undo,
obj_template_t *obj)
{
obj_template_t *editobj = (undo->newnode) ? undo->newnode->obj :
((undo->curnode) ? undo->curnode->obj : NULL);
if (editobj == NULL) {
return FALSE;
}
/* see if the commit test object is a descendant of
* the edit object, but only if not deleting the edit
* object; do not trigger descendant test on a delete */
boolean done = (undo->editop == OP_EDITOP_DELETE);
obj_template_t *testobj = obj;
while (!done) {
if (editobj == testobj) {
return TRUE; // do not prune this object test
}
if (testobj->parent && !obj_is_root(testobj->parent)) {
testobj = testobj->parent;
} else {
done = TRUE;
}
}
/* see if the edit object is a descendant of the commit test object */
done = FALSE;
while (!done) {
if (editobj == obj) {
return TRUE; // do not prune this object test
}
if (editobj->parent && !obj_is_root(editobj->parent)) {
editobj = editobj->parent;
} else {
done = TRUE;
}
}
return FALSE;
} /* check_no_prune_curedit */
/********************************************************************
* FUNCTION prune_obj_commit_tests
*
* Check if the specified object test can be reduced or elimated
* from the current commit test
*
* INPUTS:
*
* OUTPUTS:
* *testflags will be altered
* RETURNS:
* new (or unchanged) test flags
*********************************************************************/
static uint32
prune_obj_commit_tests (agt_cfg_transaction_t *txcb,
agt_cfg_commit_test_t *ct,
val_value_t *rootval,
uint32 curflags)
{
if (curflags & AGT_TEST_FL_MUST) {
/* do not prune a must-stmt test since the XPath expression
* may reference any arbitrary data node */
return curflags;
}
agt_cfg_undo_rec_t *undo = NULL;
if (txcb->cfg_id == NCX_CFGID_RUNNING) {
if (txcb->commitcheck) {
/* called from <commit>
* look for dirty or subtree dirty flags in the rootval
* this rootval is reallt candidate->root, so it is
* OK to check the dirty flags */
curflags = check_prune_obj(ct->obj, rootval, curflags);
} else {
if (txcb->edit_type == AGT_CFG_EDIT_TYPE_FULL) {
/* called from <validate> on external <config> element;
* <copy-config> is not supported on the running config
* so there is nothing to do for now; do not prune;
* force a full test for <validate> */
} else if (txcb->edit_type == AGT_CFG_EDIT_TYPE_PARTIAL) {
/* called from <edit-config> on running config;
* check the edit list; only nodes that have been
* edited need to run a commit test */
undo = (agt_cfg_undo_rec_t *)dlq_firstEntry(&txcb->undoQ);
while (undo) {
if (check_no_prune_curedit(undo, ct->obj)) {
return curflags;
}
undo = (agt_cfg_undo_rec_t *)dlq_nextEntry(undo);
}
curflags = 0;
} // else unknown edit-type! do not prune
}
} else if (txcb->cfg_id == NCX_CFGID_CANDIDATE) {
if (txcb->edit_type == AGT_CFG_EDIT_TYPE_FULL) {
/* called from <validate> operation on the <candidate> config */
curflags = check_prune_obj(ct->obj, rootval, curflags);
} else if (txcb->edit_type == AGT_CFG_EDIT_TYPE_PARTIAL) {
/* called from <edit-config> with test-option=set-then-test
* first check all the current edits; because the dirty flags
* for any edits from this <rpc> have not been set yet */
undo = (agt_cfg_undo_rec_t *)dlq_firstEntry(&txcb->undoQ);
while (undo) {
if (check_no_prune_curedit(undo, ct->obj)) {
return curflags;
}
undo = (agt_cfg_undo_rec_t *)dlq_nextEntry(undo);
}
/* did not find the object in the current edits so check
* pending edits (dirty flags) on the candidate->root target */
curflags = check_prune_obj(ct->obj, rootval, curflags);
} // else unknown edit-type! do not prune!
} // else unknown config target! do not prune!
return curflags;
} /* prune_obj_commit_tests */
/********************************************************************
* FUNCTION run_instance_check
*
* Check for the proper number of object instances for
* the specified value struct.
*
* The top-level value set passed cannot represent a choice
* or a case within a choice.
*
* This function is intended for validating PDUs (RPC requests)
* during the PDU processing. It does not check the instance
* count or must-stmt expressions for any <config> (ncx:root)
* container. This must be done with the agt_val_root_check function.
*
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* msg == xml_msg_hdr t from msg in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* valset == val_value_t list, leaf-list, or container to check
* valroot == root node of the database
* layer == NCX layer calling this function (for error purposes only)
* all_levels == TRUE to recurse for all levels
* == FALSE to just check the curent level
* OUTPUTS:
* if msg not NULL:
* msg->msg_errQ may have rpc_err_rec_t structs added to it
* which must be freed by the called with the
* rpc_err_free_record function
*
* RETURNS:
* status of the operation, NO_ERR if no validation errors found
*********************************************************************/
static status_t
run_instance_check (ses_cb_t *scb,
xml_msg_hdr_t *msg,
val_value_t *valset,
val_value_t *valroot,
ncx_layer_t layer,
boolean all_levels)
{
assert( valset && "valset is NULL!" );
if (LOGDEBUG4) {
log_debug4("\nrun_instance_check: %s:%s start",
obj_get_mod_name(valset->obj),
valset->name);
}
status_t res = NO_ERR, retres = NO_ERR;
obj_template_t *obj = valset->obj;
if (skip_obj_commit_test(obj)) {
return NO_ERR;
}
if (all_levels && val_child_cnt(valset)) {
val_value_t *chval = val_get_first_child(valset);
for (; chval != NULL; chval = val_get_next_child(chval)) {
if (!(obj_is_root(chval->obj) || obj_is_leafy(chval->obj))) {
/* recurse for all object types except root, leaf, leaf-list */
res = run_instance_check(scb, msg, chval, valroot,
layer, all_levels);
CHK_EXIT(res, retres);
}
}
}
/* check all the child nodes for correct number of instances */
obj_template_t *chobj = obj_first_child(obj);
for (; chobj != NULL; chobj = obj_next_child(chobj)) {
if (obj_is_root(chobj)) {
continue;
}
if (chobj->objtype == OBJ_TYP_CHOICE) {
res = choice_check_agt(scb, msg, chobj, valset, valroot, layer);
} else {
res = instance_check(scb, msg, chobj, valset, valroot, layer);
}
if (res != NO_ERR && valset->res == NO_ERR) {
valset->res = res;
}
CHK_EXIT(res, retres);
}
return retres;
} /* run_instance_check */
/********************************************************************
* FUNCTION run_obj_commit_tests
*
* Run selected validation tests from section 8 of RFC 6020
*
* INPUTS:
* profile == agt_profile pointer
* scb == session control block (may be NULL; no session stats)
* msghdr == XML message header in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* ct == commit test record to use (NULL == root test)
* val == context node in data tree to use
* root == root of the data tree to use
* testmask == bitmask of the tests that are requested
*
* OUTPUTS:
* if msghdr not NULL:
* msghdr->msg_errQ may have rpc_err_rec_t
* structs added to it which must be freed by the
* caller with the rpc_err_free_record function
*
* RETURNS:
* status of the operation, NO_ERR if no validation errors found
*********************************************************************/
static status_t
run_obj_commit_tests (agt_profile_t *profile,
ses_cb_t *scb,
xml_msg_hdr_t *msghdr,
agt_cfg_commit_test_t *ct,
val_value_t *val,
val_value_t *root,
uint32 testmask)
{
status_t res, retres = NO_ERR;
uint32 testflags = (ct) ? ct->testflags : profile->agt_rootflags;
testflags &= testmask;
if (testflags) {
if (LOGDEBUG2) {
log_debug2("\nrun obj_commit_tests for %s",
(ct) ? ct->objpcb->exprstr : (const xmlChar *)"/");
}
} else {
if (LOGDEBUG4) {
log_debug4("\nskip obj_commit_tests for %s",
(ct) ? ct->objpcb->exprstr : (const xmlChar *)"/");
}
return NO_ERR;
}
/* go through all the commit test objects that might need
* to be checked for this object
*/
if (testflags & AGT_TEST_INSTANCE_MASK) {
/* need to run the instance tests on the 'val' node */
if (ct) {
res = run_instance_check(scb, msghdr, val, root,
NCX_LAYER_CONTENT, FALSE);
CHK_EXIT(res, retres);
} else {
/* TBD: figure out how to use the gen_root object
* by moving all the data_db nodes into gen_root datadefQ
* This requires moving them from mod->datadefQ so that
* these 2 functions below will no longer work
* Too much code uses this for-loop search approach
* so this change is still TBD */
ncx_module_t *mod = ncx_get_first_module();
for (; mod != NULL; mod = ncx_get_next_module(mod)) {
obj_template_t *obj = ncx_get_first_data_object(mod);
for (; obj != NULL; obj = ncx_get_next_data_object(mod, obj)) {
if (skip_obj_commit_test(obj)) {
continue;
}
/* just run instance check on the top level object */
if (obj->objtype == OBJ_TYP_CHOICE) {
res = choice_check_agt(scb, msghdr, obj, val, root,
NCX_LAYER_CONTENT);
} else {
res = instance_check(scb, msghdr, obj, val, root,
NCX_LAYER_CONTENT);
}
CHK_EXIT(res, retres);
}
}
}
}
if (testflags & AGT_TEST_FL_MUST) {
res = must_stmt_check(scb, msghdr, root, val);
if (res != NO_ERR) {
CHK_EXIT(res, retres);
}
}
if (testflags & AGT_TEST_FL_XPATH_TYPE) {
res = instance_xpath_check(scb, msghdr, val, root, NCX_LAYER_CONTENT);
if (res != NO_ERR) {
CHK_EXIT(res, retres);
}
}
// defer AGT_TEST_FL_UNIQUE and process entire resnode list at once
return retres;
} /* run_obj_commit_tests */
/********************************************************************
* FUNCTION run_obj_unique_tests
*
* Run unique-stmt tests from section 7.8.3 of RFC 6020
*
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* msghdr == XML message header in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* ct == commit test record to use (NULL == root test)
* root == docroot for XPath
* OUTPUTS:
* if msghdr not NULL:
* msghdr->msg_errQ may have rpc_err_rec_t
* structs added to it which must be freed by the
* caller with the rpc_err_free_record function
*
* RETURNS:
* status of the operation, NO_ERR if no validation errors found
*********************************************************************/
static status_t
run_obj_unique_tests (ses_cb_t *scb,
xml_msg_hdr_t *msghdr,
agt_cfg_commit_test_t *ct,
val_value_t *root)
{
status_t res = NO_ERR;
if (ct->testflags & AGT_TEST_FL_UNIQUE) {
log_debug2("\nrun unique tests for %s", ct->objpcb->exprstr);
res = unique_stmt_check(scb, msghdr, ct, root);
}
return res;
} /* run_obj_unique_tests */
/******************* E X T E R N F U N C T I O N S ***************/
/********************************************************************
* FUNCTION agt_val_rpc_xpath_check
*
* Check for any nodes which are present
* but have false when-stmts associated
* with the node. These are errors and
* need to be flagged as unknown-element
*
* Any false nodes will be removed from the input PDU
* and discarded, after the error is recorded.
* This prevents false positives or negatives in
* the agt_val_instance_check, called after this function
*
* Also checks any false must-stmts for nodes
* which are present (after false when removal)
* These are flagged as 'must-violation' errors
* as per YANG, 13.4
*
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* rpcmsg == RPC msg header for audit purposes
* msg == xml_msg_hdr t from msg in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* rpcinput == RPC input node conceptually under rpcroot
* except this rpcinput has no parent node
* so a fake one will be termporarily added
* to prevent false XPath validation errors
* rpcroot == RPC method node.
* The conceptual parent of this node
* is used as the document root (/rpc == /)
*
* OUTPUTS:
* if false nodes found under :
* they are deleted
* if msg not NULL:
* msg->msg_errQ may have rpc_err_rec_t structs added to it
* which must be freed by the called with the
* rpc_err_free_record function
*
* RETURNS:
* status of the operation
* NO_ERR if no false when or must statements found
*********************************************************************/
status_t
agt_val_rpc_xpath_check (ses_cb_t *scb,
rpc_msg_t *rpcmsg,
xml_msg_hdr_t *msg,
val_value_t *rpcinput,
obj_template_t *rpcroot)
{
val_value_t *method = NULL;
status_t res = NO_ERR;
#ifdef DEBUG
if (!rpcinput || !rpcroot) {
return SET_ERROR(ERR_INTERNAL_PTR);
}
#endif
if (LOGDEBUG3) {
log_debug3("\nagt_val_rpc_xpathchk: %s:%s start",
obj_get_mod_name(rpcroot),
obj_get_name(rpcroot));
}
/* make a dummy tree to align with the XPath code */
method = val_new_value();
if (!method) {
return ERR_INTERNAL_MEM;
}
val_init_from_template(method, rpcroot);
/* add the rpc/method-name/input node */
val_add_child(rpcinput, method);
/* just check for when-stmt deletes once, since it is an error */
res = rpc_when_stmt_check(scb, rpcmsg, msg, method, rpcinput);
/* check if any must expressions apply to
* descendent-or-self nodes in the rpcinput node */
if (res == NO_ERR) {
res = rpc_must_stmt_check(scb, msg, method, rpcinput);
}
/* cleanup fake RPC method parent node */
val_remove_child(rpcinput);
val_free_value(method);
return res;
} /* agt_val_rpc_xpath_check */
/********************************************************************
* FUNCTION agt_val_instance_check
*
* Check for the proper number of object instances for
* the specified value struct.
*
* The top-level value set passed cannot represent a choice
* or a case within a choice.
*
* This function is intended for validating PDUs (RPC requests)
* during the PDU processing. It does not check the instance
* count or must-stmt expressions for any <config> (ncx:root)
* container. This must be dome with the agt_val_root_check function.
*
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* msg == xml_msg_hdr t from msg in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* valset == val_value_t list, leaf-list, or container to check
* valroot == root node of the database
* layer == NCX layer calling this function (for error purposes only)
*
* OUTPUTS:
* if msg not NULL:
* msg->msg_errQ may have rpc_err_rec_t structs added to it
* which must be freed by the called with the
* rpc_err_free_record function
*
* RETURNS:
* status of the operation, NO_ERR if no validation errors found
*********************************************************************/
status_t
agt_val_instance_check (ses_cb_t *scb,
xml_msg_hdr_t *msg,
val_value_t *valset,
val_value_t *valroot,
ncx_layer_t layer)
{
return run_instance_check(scb, msg, valset, valroot, layer, TRUE);
} /* agt_val_instance_check */
/********************************************************************
* FUNCTION agt_val_root_check
*
* !!! Full database validation !!!
* Check for the proper number of object instances for
* the specified configuration database
* Check must and when statements
* Check empty NP containers
* Check choices (selected case, and it is complete)
*
* Tests are divided into 3 groups:
* A) top-level nodes (child of conceptual <config> root
* B) parent data node for child instance tests (mand/min/max)
* C) data node referential tests (must/unique/leaf)
*
* Test pruning
* The global variable agt_profile.agt_rootflags is used
* to determine if any type (A) commit tests are needed
*
* The global variable agt_profile.agt_config_state is
* used to force complete testing; There are 3 states:
* AGT_CFG_STATE_INIT : running config has not been
* validated, or validation-in-progress
* AGT_CFG_STATE_OK : running config has been validated
* and it passed all validation checks
* AGT_CFG_STATE_BAD: running config validation has been
* attempted and it failed; running config is not valid!
* The server will shutdown if
* The target nodes in the undoQ records
* INPUTS:
* scb == session control block (may be NULL; no session stats)
* msghdr == XML message header in progress
* == NULL MEANS NO RPC-ERRORS ARE RECORDED
* txcb == transaction control block
* root == val_value_t for the target config being checked
*
* OUTPUTS:
* if mshdr not NULL:
* msghdr->msg_errQ may have rpc_err_rec_t
* structs added to it which must be freed by the
* caller with the rpc_err_free_record function
*
* RETURNS:
* status of the operation, NO_ERR if no validation errors found
*********************************************************************/
status_t
agt_val_root_check (ses_cb_t *scb,
xml_msg_hdr_t *msghdr,
agt_cfg_transaction_t *txcb,
val_value_t *root)
{
log_debug3("\nagt_val_root_check: start");
assert ( txcb && "txcb is NULL!" );
assert ( root && "root is NULL!" );
assert ( root->obj && "root->obj is NULL!" );
assert ( obj_is_root(root->obj) && "root obj not config root!" );
agt_profile_t *profile = agt_get_profile();
status_t res = NO_ERR, retres = NO_ERR;
/* the commit check is always run on the root because there
* are operations such as <validate> and <copy-config> that
* make it impossible to flag the 'root-dirty' condition
* during editing */
res = run_obj_commit_tests(profile, scb, msghdr, NULL, root, root,
AGT_TEST_ALL_COMMIT_MASK);
if (res != NO_ERR) {
profile->agt_load_top_rootcheck_errors = TRUE;
CHK_EXIT(res, retres);
}
/* go through all the commit test objects that might need
* to be checked for this commit */
agt_cfg_commit_test_t *ct = (agt_cfg_commit_test_t *)
dlq_firstEntry(&profile->agt_commit_testQ);
for (; ct != NULL; ct = (agt_cfg_commit_test_t *)dlq_nextEntry(ct)) {
uint32 tests = ct->testflags & AGT_TEST_ALL_COMMIT_MASK;
/* prune entry that has not changed in a valid config
* this will only work for <commit> and <edit-config>
* on the running config, because otherwise there will
* not be any edits recorded in the txcb->undoQ or any
* nodes marked dirty in val->flags */
if (profile->agt_config_state == AGT_CFG_STATE_OK) {
tests = prune_obj_commit_tests(txcb, ct, root, tests);
}
if (tests == 0) {
/* no commit tests needed for this node */
if (LOGDEBUG3) {
log_debug3("\nrun_root_check: skip commit test %s:%s",
obj_get_mod_name(ct->obj),
obj_get_name(ct->obj));
}
continue;
}
res = prep_commit_test_node(scb, msghdr, txcb, ct, root);
if (res != NO_ERR) {
CHK_EXIT(res, retres);
continue;
}
/* run all relevant tests on each node in the result set */
xpath_resnode_t *resnode = xpath_get_first_resnode(ct->result);
for (; resnode != NULL; resnode = xpath_get_next_resnode(resnode)) {
val_value_t *valnode = xpath_get_resnode_valptr(resnode);
res = run_obj_commit_tests(profile, scb, msghdr, ct, valnode,
root, tests);
if (res != NO_ERR) {
valnode->res = res;
profile->agt_load_rootcheck_errors = TRUE;
CHK_EXIT(res, retres);
}
}
/* check if any unique tests, which are handled all at once
* instead of one instance at a time */
res = run_obj_unique_tests(scb, msghdr, ct, root);
if (res != NO_ERR) {
profile->agt_load_rootcheck_errors = TRUE;
CHK_EXIT(res, retres);
}
}
log_debug3("\nagt_val_root_check: end");
return retres;
} /* agt_val_root_check */
/********************************************************************
* FUNCTION agt_val_validate_write
*
* Validate the requested <edit-config> write operation
*
* Check all the embedded operation attributes against
* the default-operation and maintained current operation.
*
* Invoke all the user AGT_CB_VALIDATE callbacks for a
* 'new value' and 'existing value' pairs, for a given write operation,
*
* These callbacks are invoked bottom-up, so the first step is to
* step through all the child nodes and traverse the
* 'new' data model (from the PDU) all the way to the leaf nodes
*
* The operation attribute is checked against the real data model
* on the way down the tree, and the user callbacks are invoked
* bottom-up on the way back. This way, the user callbacks can
* share sub-tree validation routines, and perhaps add additional
* <rpc-error> information, based on the context and specific errors
* reported from 'below'.
*
* INPUTS:
* scb == session control block
* msg == incoming rpc_msg_t in progress
* target == cfg_template_t for the config database to write
* == NULL for no actual write acess (validate only)
* valroot == the val_value_t struct containing the root
* (NCX_BT_CONTAINER, ncx:root)
* datatype representing the config root with
* proposed changes to the target
* editop == requested start-state write operation
* (usually from the default-operation parameter)
* OUTPUTS:
* rpc_err_rec_t structs may be malloced and added to the msg->rpc_errQ
*
* RETURNS:
* status of the operation
*********************************************************************/
status_t
agt_val_validate_write (ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target,
val_value_t *valroot,
op_editop_t editop)
{
assert( scb && "scb is NULL!" );
assert( msg && "msg is NULL!" );
assert( valroot && "valroot is NULL!" );
assert( valroot->obj && "valroot obj is NULL!" );
assert( obj_is_root(valroot->obj) && "valroot obj not root!" );
status_t res = NO_ERR;
if (target) {
/* check the lock first */
res = cfg_ok_to_write(target, scb->sid);
if (res != NO_ERR) {
agt_record_error(scb, &msg->mhdr, NCX_LAYER_CONTENT, res,
NULL, NCX_NT_NONE, NULL, NCX_NT_VAL, valroot);
return res;
}
}
/* the <config> root is just a value node of type 'root'
* traverse all nodes and check the <edit-config> request
*/
res = handle_callback(AGT_CB_VALIDATE, editop, scb, msg, target, valroot,
(target) ? target->root : NULL,
(target) ? target->root : valroot);
return res;
} /* agt_val_validate_write */
/********************************************************************
* FUNCTION agt_val_apply_write
*
* Apply the requested write operation
*
* Invoke all the AGT_CB_APPLY callbacks for a
* source and target and write operation
*
* TBD: support for handling nested parmsets independently
* of the parent parmset is not supported. This means
* that independent parmset instances nested within the
* parent parmset all have to be applied, or none applied
*
* INPUTS:
* scb == session control block
* msg == incoming rpc_msg_t in progress
* target == cfg_template_t for the config database to write
* pducfg == the 'root' value struct that represents the
* tree of changes to apply to the target
* editop == requested start-state write operation
* (usually from the default-operation parameter)
*
* OUTPUTS:
* rpc_err_rec_t structs may be malloced and added to the msg->mhsr.errQ
*
* RETURNS:
* status
*********************************************************************/
status_t
agt_val_apply_write (ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *target,
val_value_t *pducfg,
op_editop_t editop)
{
assert( scb && "scb is NULL!" );
assert( msg && "msg is NULL!" );
assert( msg->rpc_txcb && "txcb is NULL!" );
assert( target && "target is NULL!" );
assert( pducfg && "pducfg is NULL!" );
assert( obj_is_root(pducfg->obj) && "pducfg root is NULL!" );
/* start with the config root, which is a val_value_t node */
status_t res = handle_callback(AGT_CB_APPLY, editop, scb, msg, target,
pducfg, target->root, target->root);
if (res == NO_ERR) {
boolean done = FALSE;
while (!done) {
/* need to delete all the false when-stmt config objects
* and then see if the config is valid. This is done in
* candidate or running in apply phase; not evaluated at commit
* time like must-stmt or unique-stmt */
uint32 delcount = 0;
res = delete_dead_nodes(scb, &msg->mhdr, msg->rpc_txcb,
target->root, &delcount);
if (res != NO_ERR || delcount == 0) {
done = TRUE;
}
}
}
if (res == NO_ERR && msg->rpc_txcb->rootcheck) {
res = agt_val_root_check(scb, &msg->mhdr, msg->rpc_txcb, target->root);
}
if (res == NO_ERR) {
/* complete the operation */
res = handle_callback(AGT_CB_COMMIT, editop, scb, msg, target,
pducfg, target->root, target->root);
} else {
/* rollback the operation */
status_t res2 = handle_callback(AGT_CB_ROLLBACK, editop, scb, msg,
target, pducfg, target->root,
target->root);
if (res2 != NO_ERR) {
log_error("\nagt_val: Rollback failed (%s)\n",
get_error_string(res2));
}
}
return res;
} /* agt_val_apply_write */
/********************************************************************
* FUNCTION agt_val_apply_commit
*
* Apply the requested commit operation
*
* Invoke all the AGT_CB_COMMIT callbacks for a
* source and target and write operation
*
* INPUTS:
* scb == session control block
* msg == incoming commit rpc_msg_t in progress
* source == cfg_template_t for the source (candidate)
* target == cfg_template_t for the config database to
* write (running)
* save_nvstore == TRUE if the mirrored NV-store
* should be updated after the commit is done
* FALSE if this is the start of a confirmed-commit
* so the NV-store update is deferred
* Never save to NV-store if :startup is supported
*
* OUTPUTS:
* rpc_err_rec_t structs may be malloced and added
* to the msg->mhdr.errQ
*
* RETURNS:
* status
*********************************************************************/
status_t
agt_val_apply_commit (ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *source,
cfg_template_t *target,
boolean save_nvstore)
{
assert( scb && "scb is NULL!" );
assert( msg && "msg is NULL!" );
assert( msg->rpc_txcb && "txcb is NULL!" );
assert( source && "source is NULL!" );
assert( target && "target is NULL!" );
agt_profile_t *profile = agt_get_profile();
status_t res = NO_ERR;
#ifdef ALLOW_SKIP_EMPTY_COMMIT
/* usually only save if the source config was touched */
if (!cfg_get_dirty_flag(source)) {
boolean no_startup_errors = dlq_empty(&target->load_errQ);
/* no need to merge the candidate into the running
* config because there are no changes in the candidate
*/
if (profile->agt_has_startup) {
/* separate copy-config required to rewrite
* the startup config file
*/
if (LOGDEBUG) {
log_debug("\nSkipping commit, candidate not dirty");
}
} else {
/* there is no distinct startup; need to mirror now;
* check if the running config had load errors
* so overwriting it even if the candidate is
* clean makes sense
*/
if (no_startup_errors) {
if (LOGDEBUG) {
log_debug("\nSkipping commit, candidate not dirty");
}
} else {
if (LOGINFO) {
log_debug("\nSkipping commit, but saving running "
"to NV-storage due to load errors");
}
res = agt_ncx_cfg_save(target, FALSE);
if (res != NO_ERR) {
/* write to NV-store failed */
agt_record_error(scb, &msg->mhdr, NCX_LAYER_OPERATION, res,
NULL, NCX_NT_CFG, target, NCX_NT_NONE,
NULL);
}
}
}
return res;
}
#endif
/* check any top-level deletes */
//res = apply_commit_deletes(scb, msg, target, source->root, target->root);
if (res == NO_ERR) {
/* apply all the new and modified nodes */
res = handle_callback(AGT_CB_APPLY, OP_EDITOP_COMMIT, scb, msg,
target, source->root, target->root, target->root);
}
if (res==NO_ERR) {
/* complete the transaction */
res = handle_callback(AGT_CB_COMMIT, OP_EDITOP_COMMIT, scb, msg,
target, source->root, target->root, target->root);
if ( NO_ERR == res ) {
res = agt_commit_complete();
}
} else {
/* rollback the transaction */
status_t res2 = handle_callback(AGT_CB_ROLLBACK, OP_EDITOP_COMMIT,
scb, msg, target, source->root,
target->root, target->root);
if (res2 != NO_ERR) {
log_error("\nError: rollback failed (%s)",
get_error_string(res2));
}
}
if (res == NO_ERR && !profile->agt_has_startup) {
if (save_nvstore) {
res = agt_ncx_cfg_save(target, FALSE);
if (res != NO_ERR) {
/* write to NV-store failed */
agt_record_error(scb,&msg->mhdr, NCX_LAYER_OPERATION, res,
NULL, NCX_NT_CFG, target, NCX_NT_NONE, NULL);
} else {
/* don't clear the dirty flags in running
* unless the save to file worked
*/
val_clean_tree(target->root);
}
} else if (LOGDEBUG2) {
log_debug2("\nagt_val: defer NV-save after commit "
"until confirmed");
}
}
return res;
} /* agt_val_apply_commit */
/********************************************************************
* FUNCTION agt_val_check_commit_edits
*
* Check if the requested commit operation
* would cause any ACM or partial lock violations
* in the running config
* Invoke all the AGT_CB_VALIDATE callbacks for a
* source and target and write operation
*
* !!! Only works for the <commit> operation for applying
* !!! the candidate to the running config; relies on value
* !!! flags VAL_FL_SUBTREE_DIRTY and VAL_FL_DIRTY
*
* INPUTS:
* scb == session control block
* msg == incoming commit rpc_msg_t in progress
* source == cfg_template_t for the source (candidate)
* target == cfg_template_t for the config database to
* write (running)
*
* OUTPUTS:
* rpc_err_rec_t structs may be malloced and added
* to the msg->mhdr.errQ
*
* RETURNS:
* status
*********************************************************************/
status_t
agt_val_check_commit_edits (ses_cb_t *scb,
rpc_msg_t *msg,
cfg_template_t *source,
cfg_template_t *target)
{
assert( scb && "scb is NULL!" );
assert( msg && "msg is NULL!" );
assert( msg->rpc_txcb && "txcb is NULL!" );
assert( source && "source is NULL!" );
assert( target && "target is NULL!" );
/* usually only save if the source config was touched */
if (!cfg_get_dirty_flag(source)) {
/* no need to check for partial-lock violations */
return NO_ERR;
}
status_t res = handle_callback(AGT_CB_VALIDATE, OP_EDITOP_COMMIT,
scb, msg, target, source->root,
target->root, target->root);
return res;
} /* agt_val_check_commit_edits */
/********************************************************************
* FUNCTION agt_val_delete_dead_nodes
*
* Mark nodes deleted for each false when-stmt from <validate>
* INPUTS:
* scb == session control block
* msg == incoming validate rpc_msg_t in progress
* root == value tree to check for deletions
*
* OUTPUTS:
* rpc_err_rec_t structs may be malloced and added
* to the msg->mhdr.errQ
*
* RETURNS:
* status
*********************************************************************/
status_t
agt_val_delete_dead_nodes (ses_cb_t *scb,
rpc_msg_t *msg,
val_value_t *root)
{
assert( scb && "scb is NULL!" );
assert( msg && "msg is NULL!" );
assert( msg->rpc_txcb && "txcb is NULL!" );
assert( root && "root is NULL!" );
status_t res = NO_ERR;
boolean done = FALSE;
while (!done) {
/* need to delete all the false when-stmt config objects
* and then see if the config is valid. This is done in
* candidate or running in apply phase; not evaluated at commit
* time like must-stmt or unique-stmt */
uint32 delcount = 0;
res = delete_dead_nodes(scb, &msg->mhdr, msg->rpc_txcb, root,
&delcount);
if (res != NO_ERR || delcount == 0) {
done = TRUE;
}
}
return res;
} /* agt_val_delete_dead_nodes */
/********************************************************************
* FUNCTION agt_val_add_module_commit_tests
*
* !!! Initialize module data node validation !!!
* !!! Must call after all modules are initially loaded !!!
*
* Find all the data node objects in the specified module
* that need some sort database referential integrity test
*
* !!! dynamic features are not supported. Any disabled objects
* due to false if-feature stmts will be skipped. No support yet
* to add or remove tests from the commit_testQ when obj_is_enabled()
* return value changes.
*
* INPUTS:
* mod == module to check and add tests
*
* SIDE EFFECTS:
* agt_profile->commit_testQ will contain an agt_cfg_commit_test_t struct
* for each object found with commit-time validation tests
*
* RETURNS:
* status of the operation, NO_ERR unless internal errors found
* or malloc error
*********************************************************************/
status_t
agt_val_add_module_commit_tests (ncx_module_t *mod)
{
assert( mod && "mod is NULL!" );
agt_profile_t *profile = agt_get_profile();
status_t res = NO_ERR;
obj_template_t *obj = ncx_get_first_data_object(mod);
for (; obj != NULL; obj = ncx_get_next_data_object(mod, obj)) {
res = add_obj_commit_tests(obj, &profile->agt_commit_testQ,
&profile->agt_rootflags);
if (res != NO_ERR) {
return res;
}
}
return res;
} /* agt_val_add_module_commit_tests */
/********************************************************************
* FUNCTION agt_val_init_commit_tests
*
* !!! Initialize full database validation !!!
* !!! Must call after all modules are initially loaded !!!
* !!! Must be called before load_running_config is called !!!
*
* Find all the data node objects that need some sort
* database referential integrity test
* For :candidate this is done during the
* validate of the <commit> RPC
* For :writable-running, this is done during
* <edit-config> or <copy-config>
*
* SIDE EFFECTS:
* all commit_test_t records created are stored in the
* agt_profile->commit_testQ
*
* RETURNS:
* status of the operation, NO_ERR unless internal errors found
* or malloc error
*********************************************************************/
status_t
agt_val_init_commit_tests (void)
{
status_t res = NO_ERR;
/* check all the modules in the system for top-level database objects */
ncx_module_t *mod = ncx_get_first_module();
for (; mod != NULL; mod = ncx_get_next_module(mod)) {
res = agt_val_add_module_commit_tests(mod);
if (res != NO_ERR) {
return res;
}
}
return res;
} /* agt_val_init_commit_tests */
/* END file agt_val.c */
| 34.559908 | 80 | 0.523529 |
5a3e473d0cb96344acf036605f5d889fe28e6037 | 6,061 | rs | Rust | lib/bound.rs | exbibyte/mazth | 4e8acdd7b958c95ff380c2668f1cf0e689c458b2 | [
"BSD-2-Clause"
] | 3 | 2019-01-28T00:41:00.000Z | 2019-06-05T09:41:16.000Z | lib/bound.rs | exbibyte/mazth | 4e8acdd7b958c95ff380c2668f1cf0e689c458b2 | [
"BSD-2-Clause"
] | null | null | null | lib/bound.rs | exbibyte/mazth | 4e8acdd7b958c95ff380c2668f1cf0e689c458b2 | [
"BSD-2-Clause"
] | 1 | 2019-10-30T11:24:58.000Z | 2019-10-30T11:24:58.000Z | use std::cmp;
use std::f64;
use i_bound::BoundType;
use i_bound::IBound;
use i_shape::ShapeType;
#[derive(Debug, Clone)]
pub struct AxisAlignedBBox {
pub _bound_lower: [f64; 3],
pub _bound_upper: [f64; 3],
}
#[derive(Debug, Clone)]
pub enum Axis {
X,
Y,
Z,
}
impl AxisAlignedBBox {
pub fn init(shape_type: ShapeType, vals: &[f64]) -> AxisAlignedBBox {
match shape_type {
ShapeType::Ray => {
assert!(vals.len() == 6);
let mut bounds = [(0f64, 0f64); 3];
for i in 0..3 {
let b = if vals[3 + i] > 0f64 {
(vals[i], f64::INFINITY)
} else if vals[3 + i] < 0f64 {
(f64::NEG_INFINITY, vals[i])
} else {
(vals[i], vals[i])
};
bounds[i] = b;
}
AxisAlignedBBox {
_bound_lower: [bounds[0].0, bounds[1].0, bounds[2].0],
_bound_upper: [bounds[0].1, bounds[1].1, bounds[2].1],
}
}
ShapeType::Point => {
assert!(vals.len() == 3);
AxisAlignedBBox {
_bound_lower: [vals[0], vals[1], vals[2]],
_bound_upper: [vals[0], vals[1], vals[2]],
}
}
ShapeType::Sphere => {
assert!(vals.len() == 4);
AxisAlignedBBox {
_bound_lower: [vals[0] - vals[3], vals[1] - vals[3], vals[2] - vals[3]],
_bound_upper: [vals[0] + vals[3], vals[1] + vals[3], vals[2] + vals[3]],
}
}
ShapeType::Plane => {
assert!(vals.len() == 6);
AxisAlignedBBox {
_bound_lower: [f64::NEG_INFINITY; 3],
_bound_upper: [f64::INFINITY; 3],
}
}
ShapeType::Box => {
assert!(vals.len() == 4);
AxisAlignedBBox {
_bound_lower: [vals[0] - vals[3], vals[1] - vals[3], vals[2] - vals[3]],
_bound_upper: [vals[0] + vals[3], vals[1] + vals[3], vals[2] + vals[3]],
}
}
ShapeType::Rect => {
assert!(vals.len() == 6);
AxisAlignedBBox {
_bound_lower: [vals[0], vals[1], vals[2]],
_bound_upper: [vals[3], vals[4], vals[5]],
}
}
ShapeType::Frustum => {
unimplemented!();
}
_ => {
unimplemented!();
}
}
}
pub fn get_longest_axis(&self) -> (Axis, f64) {
let dx = (Axis::X, self._bound_upper[0] - self._bound_lower[0]);
let dy = (Axis::Y, self._bound_upper[1] - self._bound_lower[1]);
let dz = (Axis::Z, self._bound_upper[2] - self._bound_lower[2]);
let longest = [dx, dy, dz]
.iter()
.cloned()
.max_by(|x, y| {
if x.1 < y.1 {
cmp::Ordering::Less
} else if x.1 < y.1 {
cmp::Ordering::Greater
} else {
cmp::Ordering::Equal
}
})
.unwrap();
longest
}
}
impl IBound for AxisAlignedBBox {
fn get_type(&self) -> BoundType {
BoundType::AxisAlignBox
}
fn intersect(&self, other: &dyn IBound) -> bool {
match other.get_type() {
BoundType::AxisAlignBox => {
let a_bounds = self.get_bound_data();
let b_bounds = other.get_bound_data();
let a_lower = &a_bounds[0..3];
let a_upper = &a_bounds[3..6];
let b_lower = &b_bounds[0..3];
let b_upper = &b_bounds[3..6];
for i in 0..3 {
if a_lower[i] > b_upper[i] || a_upper[i] < b_lower[i] {
return false;
}
}
return true;
}
_ => {
unimplemented!();
}
}
}
fn get_shortest_separation(&self, _other: &dyn IBound) -> f64 {
unimplemented!();
}
fn get_bound_data(&self) -> [f64; 32] {
let mut arr = [0f64; 32];
for i in 0..3 {
arr[i] = self._bound_lower[i];
}
for i in 0..3 {
arr[i + 3] = self._bound_upper[i];
}
arr
}
fn get_union(&mut self, bounds: &[&dyn IBound]) {
self._bound_lower = [f64::INFINITY; 3];
self._bound_upper = [f64::NEG_INFINITY; 3];
for i in bounds {
match i.get_type() {
BoundType::AxisAlignBox => (),
_ => {
unimplemented!();
}
}
let b = i.get_bound_data();
let b_lower = &b[0..3];
let b_upper = &b[3..6];
for j in 0..3 {
self._bound_lower[j] = self._bound_lower[j].min(b_lower[j]);
self._bound_upper[j] = self._bound_upper[j].max(b_upper[j]);
}
}
}
fn get_centroid(&self) -> [f64; 3] {
match self.get_type() {
BoundType::AxisAlignBox => {
let b = self.get_bound_data();
let b_lower = &b[0..3];
let b_upper = &b[3..6];
return [
(b_lower[0] + b_upper[0]) / 2f64,
(b_lower[1] + b_upper[1]) / 2f64,
(b_lower[2] + b_upper[2]) / 2f64,
];
}
_ => {
unimplemented!();
}
}
}
}
impl Default for AxisAlignedBBox {
fn default() -> AxisAlignedBBox {
AxisAlignedBBox {
_bound_lower: [f64::NEG_INFINITY; 3],
_bound_upper: [f64::INFINITY; 3],
}
}
}
| 31.567708 | 92 | 0.410328 |
1bf937f9211df97be2715b63435722abc6a89f74 | 13,968 | py | Python | Sam.py | Danila-Bashinskiy/Sam | 50834e64e9cdf6339213c348095a2087d7a89b14 | [
"MIT"
] | 2 | 2021-02-04T09:01:54.000Z | 2021-07-09T21:56:30.000Z | Sam.py | Danila-Bashinskiy/Sam | 50834e64e9cdf6339213c348095a2087d7a89b14 | [
"MIT"
] | null | null | null | Sam.py | Danila-Bashinskiy/Sam | 50834e64e9cdf6339213c348095a2087d7a89b14 | [
"MIT"
] | null | null | null | import random
import sys
import time
print("Здравствуйте, меня зовут Сэм,"
" я исскуственный интелект созданный для 4 программ и"
" простого разговора с людьми."
)
print("У меня есть 4 программы, 1-ая из них - это калькулятор, чтобы его выбрать напишите 1.")
print("2-ая из них - это программа для подкидывание монетки, 'Орел и решка', чтобы ее выбрать напишите 2.")
print("3-ая из этих трёх, это мини-игра - 'Камень, Ножницы, Бумага', чтобы выбрать эту мини-игру, "
"напишите 3.")
print("4-ая и почти последняя - это приложение Kahoot! Создатель тестов и последущее прохождение их.")
print("Иначе, если вы хотите поговорить с Сэмом, напишите '0'")
print("5-ая и конечная - это типичное приложение таймер. Чтобы его активировать напишите 'time'.")
select = input()
if select == "time":
timer = time.time()
while True:
timer2 = time.time()
sum_timer = timer2 - timer
print(round(sum_timer))
time.sleep(1)
if select == "4":
import time
import sys
points = 0
print("Привет! Это приложение Kahoot!")
print("Чтобы узнать почему сейчас наше приложение находится")
print("В командной строке напишите знак '?'")
print("Иначе, чтобы выбрать редактор теста напишите слово 'Edit'")
print("Чтобы приложение вас поняло пишите чётко цифры, знаки"
" или слова и без пробелов.")
select = input()
if select != "?" or "Edit":
print("Извините, но я вас не понимаю!")
if select == "?":
print(" ")
print("Из-за технических неполадок мы перешли на версию 1.0")
print("Эта версия может показываться только в командной строке")
print("И поддерживает только ОС Windows")
print("Извините за представленные неудобства, но пока что по другому никак")
elif select == "Edit":
print(" ")
print("Отлично! Вы выбрали редактор тестов.")
print("Для начала напишите 1-ый вопрос который будет в тесте")
one_q = input()
print("Теперь напишите варианты ответов их всего будет 4.")
print("Если вы хотите оставить только 1, 2 или 3 вариантов."
"ответа просто можете поставить пробел.")
print("P.S. После вопроса всегда пишите правильный ответ")
one_one_answ = input()
one_two_answ = input()
one_three_answ = input()
one_four_answ = input()
print("Отлично! Теперь снова напишите вопрос, а потом ответы, и так до 5 вопросов.")
two_q = input()
two_one_answ = input()
two_two_answ = input()
two_three_answ = input()
two_four_answ = input()
print("Супер! Пишите вопросы дальше.")
three_q = input()
three_one_answ = input()
three_two_answ = input()
three_three_answ = input()
three_four_answ = input()
print("Вам осталось написать еще 2 вопроса.")
four_q = input()
four_one_answ = input()
four_two_answ = input()
four_three_answ = input()
four_four_answ = input()
print("Еще один вопрос.")
five_q = input()
five_one_answ = input()
five_two_answ = input()
five_three_answ = input()
five_four_answ = input()
print("Великолепно! Чтобы выполнить ваш тест напишите 'Go'")
end = input()
if end == "Go":
print(" ")
print("1-ый вопрос:", one_q)
print("Варианты ответов:")
print(one_four_answ, ";", one_three_answ)
print(one_two_answ, ";", one_one_answ)
one_answ = input()
if one_answ == one_one_answ:
print("Отлично! Вы ответили правильно на первый вопрос. +1000 баллов")
points = points + 1000
else:
print("Не правильно. Повезет в следущий раз.")
print("2-ой вопрос:", two_q)
print("Варианты ответов:")
print(two_two_answ, ";", two_one_answ)
print(two_four_answ, ";", two_three_answ)
two_answ = input()
if two_answ == two_one_answ:
print("Супер! Вы ответили правильно. +1000 баллов")
points = points + 1000
else:
print("О нет! Вы ответили не правильно.")
print("3-ой вопрос:", three_q)
print("Варианты ответов:")
print(three_one_answ, ";", three_two_answ)
print(three_four_answ, ";", three_three_answ)
three_answ = input()
if three_answ == three_one_answ:
print("Вау! Вы ответили правильно. +1000 баллов")
points = points + 1000
else:
print("Как же так! Вы ответили не правильно.")
print("4-ой вопрос:", four_q)
print("Варианты ответов:")
print(four_four_answ, ";", four_three_answ)
print(four_one_answ, ";", four_two_answ)
four_answ = input()
if four_answ == four_one_answ:
print("Супер! Вы ответили правильно. +1000 баллов")
points = points + 1000
else:
print("Мммм как же так! Вы ответили не правильно.")
print("5-ой вопрос:", two_q)
print("Варианты ответов:")
print(five_two_answ, ";", five_one_answ)
print(five_four_answ, ";", five_three_answ)
five_answ = input()
if five_answ == five_one_answ:
print("Класс! Вы ответили правильно. +1000 баллов")
points = points + 1000
else:
print("Вау, хороший ответ! Но не верно.")
if points == 1000:
status = "Честно? Может быть и лучше..."
elif points == 2000:
status = "Стоит подтянуть знания!"
elif points == 3000:
status = "Junior!"
elif points == 4000:
status = "Middle!"
elif points == 5000:
status = "Senior!"
elif points == 0:
status = "I'll be back"
print(" ")
print("И так! Идет подсчет баллов...")
print("*", end="")
sys.stdout.flush()
time.sleep(1)
print("*", end="")
sys.stdout.flush()
time.sleep(0.2)
print("*", end="")
sys.stdout.flush()
time.sleep(0.5)
print("*", end="")
sys.stdout.flush()
time.sleep(1)
print("100%")
print("Вы получили", points, "баллов!")
print("Ваш статус:")
sys.stdout.flush()
print(status)
else:
print("Извините, но я вас не понимаю!")
if select == "1":
print("Отлично! Вы выбрали программу 'Калькулятор'.")
print("Здравствуйте, вас приветствует калькулятор Сэм.")
print("Для того чтобы выполнить какое либо действие напишите,")
print("число №1, способ вычисления между числами, Число №2")
print("(Пишите числа и способ вычисления без пробелов после них, ")
print("иначе это приведёт к авто. заканчиванию программы.)")
one = int(input())
sposob = input()
two = int(input())
if sposob == "/":
print("Сэм произвёл расчет, он составляет...")
print(one / two)
input()
elif sposob == "*":
print("Сэм произвёл расчет, он составляет...")
print(one * two)
input()
elif sposob == "-":
print("Сэм произвёл расчет, он составляет...")
print(one - two)
input()
elif sposob == "+":
print("Сэм произвёл расчет, он составляет...")
print(one + two)
input()
else:
print("Сэм вас не понял! Повторите расчет правильно!")
input()
elif select == "2":
print("Супер! Вы выбрали программу - 'Орел и решка'.")
print("Здравствуйте, это симулятор подкидывания монетки, для использования приложения выберите язык.")
print("_____________________________________________________________________________________________")
print("Hello, this is a coin toss simulator, please select a language to use the application.")
print("_____________________________________________________________________________________________")
time.sleep(4)
print("Для того чтобы выбрать Русский язык напишите 'Rus', для того чтобы выбрать английский язык напишите 'Eng'.")
print("_____________________________________________________________________________________________")
print("To select the Russian language write 'Rus', to select the English language write 'Eng'.") # Начало
lang = input()
if lang == "Rus":
print("Отлично! Вы выбрали русский язык.")
print("Для того чтобы подкинуть монетку напишите 'Start'.")
elif lang == "Eng":
print("Excellent! You have selected English language.")
print("To toss a coin write 'Start'.")
# Выбор языка
else:
print("Сэм вас не понял! Повторите запрос.")
print("Sam didn't get you! Please try again.")
start = input()
if start != "Start":
print("Сэм вас не понял! Повторите запрос.")
print("Sam didn't get you! Please try again.")
if lang == "Rus" and start == "Start": # Подкидывание монетки на русском
print("Монетка подкидывается")
print(".", end="")
time.sleep(1)
sys.stdout.flush()
print(".", end="")
time.sleep(1)
sys.stdout.flush()
print(".", end="")
time.sleep(1)
sys.stdout.flush()
print(".", end="")
time.sleep(1)
sys.stdout.flush()
print(".", end="")
time.sleep(1)
r = (random.randint(1, 2))
if r == 1:
print("Выпал орел!")
input()
if r == 2:
print("Выпала Решка!")
input()
if lang == "Eng" and start == "Start": # Подкидывание монетки на английском
print("The coin is tossed")
print(".", end="")
time.sleep(1)
sys.stdout.flush()
print(".", end="")
time.sleep(1)
sys.stdout.flush()
print(".", end="")
time.sleep(1)
sys.stdout.flush()
print(".", end="")
time.sleep(1)
sys.stdout.flush()
print(".", end="")
time.sleep(1)
r = (random.randint(1, 2))
if r == 2:
print("The eagle fell!")
input()
if r == 1:
print("Tails fell!")
input()
elif select == "3":
print("Великолепно! Вы выбрали мини-игру - 'Камень, Ножницы, Бумага'.")
select_two = 0
print("Напишите что вы выберите, 'Камень', 'Ножницы' или 'Бумага'")
select_one = 0
incorrect_input = True
while incorrect_input: #проверка
select_one = input()
if select_one == "Камень" or select_one == "Ножницы" or select_one == "Бумага":
incorrect_input = False
if incorrect_input == True:
print("Не так! Напишите 'Камень', 'Ножницы' или 'Бумага'.")
if select_one == "Камень" or "Ножницы" or "Бумага":
print("Отлично вы выбрали", select_one)
time.sleep(2)
print("Ждем ответа от второго участника...")
print(".", end="")
sys.stdout.flush()
time.sleep(1)
print(".", end="")
sys.stdout.flush()
time.sleep(1)
select_two = random.randrange(1, 3)
if select_two == 1:
print("Противник выбрал Камень!")
elif select_two == 2:
print("Противник выбрал Бумагу!")
elif select_two == 3:
print("Противник выбрал Ножницы!")
if select_two == 1 and select_one == "Камень":
print("Ничья!")
input()
if select_two == 2 and select_one == "Бумага":
print("Ничья!")
input()
if select_two == 3 and select_one == "Ножницы":
print("Ничья!")
input()
if select_two == 1 and select_one == "Бумага":
print("Ты выиграл!")
input()
if select_two == 1 and select_one == "Ножницы":
print("Ты проиграл!")
input()
if select_two == 2 and select_one == "Камень":
print("Ты проиграл!")
input()
if select_two == 2 and select_one == "Ножницы":
print("Ты выиграл!")
input()
if select_two == 3 and select_one == "Камень":
print("Ты выиграл!")
input()
if select_two == 3 and select_one == "Бумага": # Алгоритм окончания игры
print("Ты проиграл!")
input()
elif select == "0":
print("Здравствуйте, о чем Вы хотели поговорить?")
spk = input()
if spk == "Как дела?":
spk_random = random.randint(1, 4)
if spk_random == 1:
print("Отлично!")
input()
elif spk_random == 2:
print("Супер!")
input()
elif spk_random == 3:
print("Великолепно!")
print("Спасибо что спросили.")
input()
elif spk_random == 4:
print("Хорошо!")
input()
elif spk == "Как поживаешь?":
spk_random = random.randint(1, 4)
if spk_random == 1:
print("Отлично!")
input()
elif spk_random == 2:
print("Супер!")
input()
elif spk_random == 3:
print("Великолепно!")
print("Спасибо что спросили.")
input()
elif spk_random == 4:
print("Хорошо!")
input()
elif spk == "Что ты умеешь?":
print("Немного, но все что я умею полезно.")
input()
else:
print("Извините, но я вас не понимаю!")
input()
else:
print("Извините, но Сэм вас не понимает.")
input()
| 35.815385 | 120 | 0.547967 |
ef444d683e365d1b47ddf05832f65ab42fd3da53 | 2,119 | dart | Dart | packages/mp_build_tools/lib/init_local_plugin.dart | aosic/mpflutter | 4219538c2ed2420bf6c15c6fa39bc2776493afd1 | [
"Apache-2.0"
] | 1 | 2022-03-25T12:30:20.000Z | 2022-03-25T12:30:20.000Z | packages/mp_build_tools/lib/init_local_plugin.dart | aosic/mpflutter | 4219538c2ed2420bf6c15c6fa39bc2776493afd1 | [
"Apache-2.0"
] | null | null | null | packages/mp_build_tools/lib/init_local_plugin.dart | aosic/mpflutter | 4219538c2ed2420bf6c15c6fa39bc2776493afd1 | [
"Apache-2.0"
] | null | null | null | import 'dart:io';
import 'package:path/path.dart' as p;
import 'package:cli_dialog/cli_dialog.dart';
import 'package:mp_build_tools/i18n.dart';
void main(List<String> args) {
final pluginNameDialog = CLI_Dialog(questions: [
[I18n.askTemplatePluginName(), 'pluginName']
]);
final pluginName = pluginNameDialog.ask()['pluginName'];
final useGiteeDialog = CLI_Dialog(booleanQuestions: [
[I18n.useGitee(), 'Yes']
]);
final useGitee = useGiteeDialog.ask()['Yes'];
if (!File('pubspec.yaml').existsSync()) {
throw I18n.pubspecYamlNotExists();
}
if (!Directory('local_plugins').existsSync()) {
Directory('local_plugins').createSync();
}
if (Directory(p.join('local_plugins', pluginName)).existsSync()) {
throw I18n.pluginAlreadyExist(pluginName);
}
final gitCloneResult = Process.runSync(
'git',
[
'clone',
useGitee
? 'https://gitee.com/mpflutter/mpflutter_plugin_template'
: 'https://github.com/mpflutter/mpflutter_plugin_template',
pluginName
],
workingDirectory: 'local_plugins');
if (gitCloneResult.exitCode != 0) {
print(gitCloneResult.stdout);
print(gitCloneResult.stderr);
throw I18n.executeFail('git clone');
}
Directory(p.join('local_plugins', pluginName, '.git'))
.deleteSync(recursive: true);
if (File(p.join('local_plugins', pluginName, 'pubspec.yaml')).existsSync()) {
var code = File(p.join('local_plugins', pluginName, 'pubspec.yaml'))
.readAsStringSync();
code = code.replaceAllMapped(RegExp('^name:[ |a-zA-Z0-9_]+', dotAll: true),
(match) => 'name: ${pluginName}');
File(p.join('local_plugins', pluginName, 'pubspec.yaml'))
.writeAsStringSync(code);
}
if (File(p.join(
'local_plugins', pluginName, 'lib', 'mpflutter_plugin_template.dart'))
.existsSync()) {
File(p.join('local_plugins', pluginName, 'lib',
'mpflutter_plugin_template.dart'))
.renameSync(
p.join('local_plugins', pluginName, 'lib', pluginName + '.dart'));
}
print(I18n.localPluginCreated(pluginName));
}
| 35.316667 | 80 | 0.65597 |
2671307fc081764f7b0ff3e389e9229b31a60b1f | 2,089 | java | Java | langx-java/src/main/java/com/jn/langx/util/DataUnit.java | fangjinuo/langx | 8b61fd3a339f6dfeb057f4db7157da09a1c28f75 | [
"Apache-2.0"
] | 48 | 2019-08-11T11:34:09.000Z | 2022-01-05T12:10:42.000Z | langx-java/src/main/java/com/jn/langx/util/DataUnit.java | fangjinuo/langx | 8b61fd3a339f6dfeb057f4db7157da09a1c28f75 | [
"Apache-2.0"
] | 29 | 2019-08-13T14:50:15.000Z | 2022-03-19T08:53:27.000Z | langx-java/src/main/java/com/jn/langx/util/DataUnit.java | fangjinuo/langx | 8b61fd3a339f6dfeb057f4db7157da09a1c28f75 | [
"Apache-2.0"
] | 6 | 2019-11-26T02:08:09.000Z | 2021-11-05T05:41:43.000Z | package com.jn.langx.util;
import com.jn.langx.util.collection.Collects;
import com.jn.langx.util.collection.Pipeline;
import com.jn.langx.util.enums.Enums;
import com.jn.langx.util.function.Function;
import com.jn.langx.util.function.Functions;
import com.jn.langx.util.function.Predicate;
import java.util.EnumSet;
import java.util.List;
public enum DataUnit {
B(1, "b"),
KB(1024 * B.bytes, "kb", "k"),
MB(1024 * KB.bytes, "mb", "m"),
GB(1024 * MB.bytes, "gb", "g"),
TB(1024 * MB.bytes, "tb", "t"),
PB(1024 * MB.bytes, "pb", "p");
private List<String> symbols;
private long bytes;
private DataUnit(long bytes, String... symbols) {
this.symbols = Collects.asList(symbols);
this.bytes = bytes;
}
public List<String> getSymbols() {
return symbols;
}
public String getStandardSymbol(){
return getSymbols().get(0);
}
public String getLessUnitSymbol(){
String symbol = getStandardSymbol();
if(symbol.length()==1){
return symbol;
}
else{
if(symbol.endsWith("b")){
return symbol.substring(0,symbol.length()-1);
}else{
return symbol;
}
}
}
public long getBytes() {
return bytes;
}
public static DataUnit ofBytes(long bytes) {
return Enums.ofField(DataUnit.class, "bytes", bytes);
}
public static DataUnit ofSymbol(final String symbol) {
return Enums.ofField(DataUnit.class, "symbols", symbol, new Predicate<DataUnit>() {
@Override
public boolean test(DataUnit unit) {
return unit.symbols.contains(symbol);
}
});
}
public static List<String> allSymbols() {
return Pipeline.of(EnumSet.allOf(DataUnit.class)).map(new Function<DataUnit, List<String>>() {
@Override
public List<String> apply(DataUnit unit) {
return unit.symbols;
}
}).flatMap(Functions.<String>noopMapper()).asList();
}
} | 27.12987 | 102 | 0.587841 |
0ba8551d5076fefbf31d48a58d0338bdc2763c0b | 181 | py | Python | src/misc/helpers.py | dnmarkon/kaggle_elo_merchant | 92ac552d72234455455c95f53e6091017f048504 | [
"MIT"
] | null | null | null | src/misc/helpers.py | dnmarkon/kaggle_elo_merchant | 92ac552d72234455455c95f53e6091017f048504 | [
"MIT"
] | null | null | null | src/misc/helpers.py | dnmarkon/kaggle_elo_merchant | 92ac552d72234455455c95f53e6091017f048504 | [
"MIT"
] | null | null | null | import pandas as pd
def one_hot(df, column):
df = pd.concat([df, pd.get_dummies(df[column], prefix=column)], axis=1)
df.drop([column], axis=1, inplace=True)
return df
| 22.625 | 75 | 0.662983 |
6e03ef48cb997a807ed6f5321835dc8ced5bf2c0 | 35,012 | html | HTML | src/test/web/modules/prototipos/views/dashboard-ccee.html | jferracini/gux-framework | e46745217655a69d134c554fe524925e45171eab | [
"Apache-2.0"
] | null | null | null | src/test/web/modules/prototipos/views/dashboard-ccee.html | jferracini/gux-framework | e46745217655a69d134c554fe524925e45171eab | [
"Apache-2.0"
] | null | null | null | src/test/web/modules/prototipos/views/dashboard-ccee.html | jferracini/gux-framework | e46745217655a69d134c554fe524925e45171eab | [
"Apache-2.0"
] | null | null | null | <div class="bg-light b-b wrapper-lg">
<div class="row">
<div class="col-sm-6 col-xs-12">
<span class="m-n font-thin h1 text-muted">Dashboard</span>
<br><small class="text-muted">Última atualização em 22 de agosto de 2016 às 16h32</small>
</div>
<div class="col-sm-6 text-right hidden-xs">
<div class="inline m-r text-left">
<div class="m-b-xs">30.000 <span class="text-muted">cadastros</span></div>
<div></div>
</div>
<div class="inline text-left">
<div class="m-b-xs">4.100 <span class="text-muted">empresas</span></div>
<div></div>
</div>
</div>
<div class="btn-group dropdown pull-right">
<button class="btn btn-info btn-lg btn-addon md-whiteframe-z0" data-toggle="dropdown" aria-expanded="false">Iniciar um novo cadastro <span class="caret"></span><i class="fa fa-plus" aria-hidden="true"></i>
</button>
<ul class="dropdown-menu w-full animated fadeInRight smooth">
<li>
<a href="" ui-sref="home.prototipos.wizard">
<i class="fa fa-industry m-r" aria-hidden="true"></i> Novo Agente
</a>
</li>
<li>
<a href="" ui-sref="home.prototipos.wizard">
<i class="fa fa-sitemap m-r" aria-hidden="true"></i> Comercializador Varejista
</a>
</li>
<li>
<a href="" ui-sref="home.prototipos.wizard">
<i class="fa fa-users m-r" aria-hidden="true"></i> Organizações do setor
</a>
</li>
<li>
<a href="" ui-sref="home.prototipos.wizard">
<i class="fa fa-user m-r" aria-hidden="true"></i> Novo Contato
</a>
</li>
</ul>
</div>
</div>
</div>
<div class="hbox hbox-auto-xs hbox-auto-sm animated fadeInUp">
<div class="col">
<div class="wrapper-md bg-light">
<!-- hbox -->
<div class="panel hbox hbox-auto-xs">
<div class="btn-group w-full wrapper">
<p class="text-muted m-r">Filtro</p>
<a class="btn btn-default btn-md active" data-toggle="button" aria-pressed="false" autocomplete="off">
<i class="fa fa-industry" aria-hidden="true"></i>
<span class="m-l-xs">Agentes</span>
<span class="badge badge-lg v-middle bg-info lt pull-right-xs m-l-xs">4.1k</span>
</a>
<a class="btn btn-default btn-md active" data-toggle="button" aria-pressed="false" autocomplete="off">
<i class="fa fa-sitemap" aria-hidden="true"></i>
<span class="m-l-xs">Comercializador Varejista</span>
<span class="badge badge-lg v-middle bg-info lt pull-right-xs m-l-xs">50</span>
</a>
<a class="btn btn-default btn-md active" data-toggle="button" aria-pressed="false" autocomplete="off">
<i class="fa fa-users" aria-hidden="true"></i>
<span class="m-l-xs">Organizações do setor</span>
<span class="badge badge-lg v-middle bg-info lt pull-right-xs m-l-xs">122</span>
</a>
<a class="btn btn-default btn-md active" data-toggle="button" aria-pressed="false" autocomplete="off">
<i class="fa fa-user" aria-hidden="true"></i>
<span class="m-l-xs">Contato</span>
<span class="badge badge-lg v-middle bg-info lt pull-right-xs m-l-xs">120</span>
</a>
<a data-toggle="dropdown" class="pull-right m-t-n-xs md-fab md-primary md-button md-ink-ripple md-mini" data-toggle="button">
<i class="ion-levels" aria-hidden="true"></i>
<!-- <span class="m-l-xs"></span>-->
<md-tooltip md-direction="left">Filtro avançado</md-tooltip>
</a>
<ul class="dropdown-menu no-border w-full animated fadeIn md-whiteframe-z2 wrapper row bg-light">
<li class="col-md-12">
<h4>Filtro avançado do painel de cadastros</h4>
</li>
<li class="col-md-4 col-xs-12 b-b">
<label>Período</label>
</li>
<li class="col-md-4 col-xs-12 b-b">
<label>Tipo de ordenação</label>
</li>
<li class="col-md-4 col-xs-12 b-b">
<label>Quantidade de itens exibidos</label>
</li>
</ul>
</div>
<div class="w-full no-padder" ng-controller="AutocompleteCtrl as ctrl" ng-cloak>
<md-content layout-padding layout="column">
<form ng-submit="$event.preventDefault()">
<md-autocomplete ng-disabled="ctrl.isDisabled" md-no-cache="ctrl.noCache" md-selected-item="ctrl.selectedItem" md-search-text-change="ctrl.searchTextChange(ctrl.searchText)" md-search-text="ctrl.searchText" md-selected-item-change="ctrl.selectedItemChange(item)"
md-items="item in ctrl.querySearch(ctrl.searchText)" md-item-text="item.name + item.forks" md-min-length="0" placeholder="buscar pelo nome do proponente..." md-menu-class="autocomplete-custom-template">
<md-item-template>
<span class="item-title">
<!--
<span class="thumb-xs avatar pull-left m-t-n-sm m-b-n-sm m-l-sm">
<img src="images/profile.jpg" alt="...">
</span> -->
<span class="h5 font-bold text-info"> {{item.name}} </span>
</span>
<span class="item-metadata">
<span class="item-metastat">no cadastro de
<strong>{{item.watchers}}</strong>
</span>
<span class="item-metastat">id de cadastro nº <strong>{{item.forks}}</strong></span>
<span class="item-metastat">recebido em <strong>{{item.receb}}</strong></span>
</span>
</md-item-template>
</md-autocomplete>
</form>
</md-content>
</div>
<!-- panel -->
<div class="panel-heading wrapper b-b b-light">
<span class="text-xs text-muted pull-right">
<i class="fa fa-circle text-default m-r-xs m-l-sm"></i> Em espera
<i class="fa fa-circle text-info m-r-xs m-l-sm"></i> Em progresso
<i class="fa fa-circle text-warning m-r-xs m-l-sm"></i> Com pendências
<i class="fa fa-circle text-success m-r-xs m-l-sm"></i> Aprovado
<i class="fa fa-circle text-danger m-r-xs m-l-sm"></i> Reprovado
</span>
<h3 class="font-thin m-t-none m-b-none text-muted"><i class="fa fa-tachometer m-r" aria-hidden="true"></i>Painel de Cadastros</h3>
</div>
<div class="panel-body no-padder">
<table class="table table-responsive table-hover m-b-none">
<thead>
<tr>
<th class="text-center"></th>
<th class="text-center">Tipo</th>
<th>Proponente</th>
<th>Empresa</th>
<th class="text-muted text-center">Envio</th>
<th class="text-muted text-center">Prazo</th>
<th class="text-center" style="width:300px;">Habilitação comercial</th>
<th class="text-center" style="width:300px;">Habilitação técnica</th>
</tr>
</thead>
<tbody>
<tr>
<td>
<div class="btn-group dropdown pull-left">
<a href="" class="dropdown btn btn-md btn-link text-info" data-toggle="dropdown" aria-expanded="false"><i class="glyphicon glyphicon-option-horizontal"></i>
<md-tooltip md-direction="top">Ações</md-tooltip>
</a>
<ul class="dropdown-menu animated fadeIn">
<li><a href=""><i class="fa fa-folder-open m-r-sm"></i>Abrir cadastro</a></li>
<li class="divider"></li>
<li><span class="text-muted m-l-md">Ações rápidas</span></li>
<li><a href=""><i class="fa fa-eye m-r-sm"></i>Espiar
<md-tooltip md-direction="right">Visualização rápida do cadastro.
</md-tooltip>
</a>
</li>
<li><a href=""><i class="fa fa-star m-r-sm"></i>Acompanhar o andamento</a></li>
<li><a href=""><i class="fa fa-warning m-r-sm"></i>Verificar pendências</a></li>
<li><a href=""><i class="fa fa-clock-o m-r-sm"></i>Verificar Prazos</a></li>
<li class="divider"></li>
<li><a href=""><i class="fa fa-thumbs-up m-r-sm"></i>Aprovar Cadastro</a></li>
<li><a href=""><i class="fa fa-thumbs-down m-r-sm"></i>Reprovar Cadastro</a></li>
</ul>
</div>
</td>
<td class="text-center">
<i class="fa fa-industry m-r-sm text-muted"><md-tooltip md-direction="bottom">Agente</md-tooltip></i>
</td>
<td>Rogerio Vilela</td>
<td>Comercializadora Lorem Ipsum S.A.</td>
<td class="text-muted text-center">
<i class="fa fa-clock-o text-info m-r-xs"></i> 12/12/2016
</td>
<td class="text-muted text-center">
<i class="fa fa-clock-o text-info m-r-xs"></i> 12/12/2016
</td>
<td class="text-center">
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-user"></i>
<md-tooltip md-direction="bottom">Informações Cadastrais</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-file-pdf-o"></i>
<md-tooltip md-direction="bottom">Envio de Documentos </md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-info btn-icon m-r-xs"><i class="fa fa-pencil"></i>
<md-tooltip md-direction="bottom">Assinatura do Termo de Adesão</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-warning btn-icon m-r-xs"><i class="fa fa-users"></i>
<md-tooltip md-direction="bottom">Indicação das representações</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon active"><i class="fa fa-check"></i>
<md-tooltip md-direction="bottom">Aprovação do Cad</md-tooltip>
</a>
</td>
<td class="text-center">
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-dot-circle-o"></i>
<md-tooltip md-direction="bottom">Cadastro de Pontos</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon m-r-xs active"><i class="fa fa-plug"></i>
<md-tooltip md-direction="bottom">Modelagem de Ativos</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon active"><i class="fa fa-key"></i>
<md-tooltip md-direction="bottom">Habilitação do cryptocard</md-tooltip>
</a>
</td>
</tr>
<tr>
<td>
<div class="btn-group dropdown pull-left">
<a href="" class="dropdown btn btn-md btn-link text-info" data-toggle="dropdown" aria-expanded="false"><i class="glyphicon glyphicon-option-horizontal"></i>
<md-tooltip md-direction="top">Ações</md-tooltip>
</a>
<ul class="dropdown-menu animated fadeIn">
<li><a href=""><i class="fa fa-folder-open m-r-sm"></i>Abrir cadastro</a></li>
<li class="divider"></li>
<li><span class="text-muted m-l-md">Ações rápidas</span></li>
<li><a href=""><i class="fa fa-eye m-r-sm"></i>Espiar
<md-tooltip md-direction="right">Visualização rápida do cadastro.
</md-tooltip>
</a>
</li>
<li><a href=""><i class="fa fa-star m-r-sm"></i>Acompanhar o andamento</a></li>
<li><a href=""><i class="fa fa-warning m-r-sm"></i>Verificar pendências</a></li>
<li><a href=""><i class="fa fa-clock-o m-r-sm"></i>Verificar Prazos</a></li>
<li class="divider"></li>
<li><a href=""><i class="fa fa-thumbs-up m-r-sm"></i>Aprovar Cadastro</a></li>
<li><a href=""><i class="fa fa-thumbs-down m-r-sm"></i>Reprovar Cadastro</a></li>
</ul>
</div>
</td>
<td class="text-center">
<i class="fa fa-user m-r-sm text-muted"><md-tooltip md-direction="bottom">Contatos</md-tooltip></i>
</td>
<td>Maria da Penha Barros de Souza</td>
<td>Comercializadora Lorem Ipsum S.A.</td>
<td class="text-muted text-center">
<i class="fa fa-clock-o text-info m-r-xs"></i> 12/12/2016
</td>
<td class="text-muted text-center">
<i class="fa fa-clock-o text-info m-r-xs"></i> 12/12/2016
</td>
<td class="text-center">
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-user"></i>
<md-tooltip md-direction="bottom">Informações Cadastrais</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-warning btn-icon m-r-xs"><i class="fa fa-file-pdf-o"></i>
<md-tooltip md-direction="bottom">Envio de Documentos </md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon active m-r-xs"><i class="fa fa-pencil"></i>
<md-tooltip md-direction="bottom">Assinatura do Termo de Adesão</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon active m-r-xs"><i class="fa fa-users"></i>
<md-tooltip md-direction="bottom">Indicação das representações</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon active"><i class="fa fa-check"></i>
<md-tooltip md-direction="bottom">Aprovação do Cad</md-tooltip>
</a>
</td>
<td class="text-center">
<a href class="btn btn-sm btn-rounded btn-default btn-icon m-r-xs active"><i class="fa fa-dot-circle-o"></i>
<md-tooltip md-direction="bottom">Cadastro de Pontos</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon m-r-xs active"><i class="fa fa-plug"></i>
<md-tooltip md-direction="bottom">Modelagem de Ativos</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon active"><i class="fa fa-key"></i>
<md-tooltip md-direction="bottom">Habilitação do cryptocard</md-tooltip>
</a>
</td>
</tr>
<tr>
<td>
<div class="btn-group dropdown pull-left">
<a href="" class="dropdown btn btn-md btn-link text-info" data-toggle="dropdown" aria-expanded="false"><i class="glyphicon glyphicon-option-horizontal"></i>
<md-tooltip md-direction="top">Ações</md-tooltip>
</a>
<ul class="dropdown-menu animated fadeIn">
<li><a href=""><i class="fa fa-folder-open m-r-sm"></i>Abrir cadastro</a></li>
<li class="divider"></li>
<li><span class="text-muted m-l-md">Ações rápidas</span></li>
<li><a href=""><i class="fa fa-eye m-r-sm"></i>Espiar
<md-tooltip md-direction="right">Visualização rápida do cadastro.
</md-tooltip>
</a>
</li>
<li><a href=""><i class="fa fa-star m-r-sm"></i>Acompanhar o andamento</a></li>
<li><a href=""><i class="fa fa-warning m-r-sm"></i>Verificar pendências</a></li>
<li><a href=""><i class="fa fa-clock-o m-r-sm"></i>Verificar Prazos</a></li>
<li class="divider"></li>
<li><a href=""><i class="fa fa-thumbs-up m-r-sm"></i>Aprovar Cadastro</a></li>
<li><a href=""><i class="fa fa-thumbs-down m-r-sm"></i>Reprovar Cadastro</a></li>
</ul>
</div>
</td>
<td class="text-center">
<i class="fa fa-sitemap m-r-sm text-muted"><md-tooltip md-direction="bottom">Comercializador Varejista</md-tooltip></i>
</td>
<td>Marcelo Viera Vilela</td>
<td>Consultoria em Negócios Cacilds e Associadis</td>
<td class="text-muted text-center">
<i class="fa fa-clock-o text-info m-r-xs"></i> 12/12/2016
</td>
<td class="text-muted text-center">
<i class="fa fa-clock-o text-info m-r-xs"></i> 12/12/2016
</td>
<td class="text-center">
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-user"></i>
<md-tooltip md-direction="bottom">Informações Cadastrais</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-file-pdf-o"></i>
<md-tooltip md-direction="bottom">Envio de Documentos </md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-pencil"></i>
<md-tooltip md-direction="bottom">Assinatura do Termo de Adesão</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-users"></i>
<md-tooltip md-direction="bottom">Indicação das representações</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-success btn-icon"><i class="fa fa-check"></i>
<md-tooltip md-direction="bottom">Aprovação do Cad</md-tooltip>
</a>
</td>
<td class="text-center">
<a href class="btn btn-sm btn-rounded btn-default btn-icon m-r-xs active"><i class="fa fa-dot-circle-o"></i>
<md-tooltip md-direction="bottom">Cadastro de Pontos</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon m-r-xs active"><i class="fa fa-plug"></i>
<md-tooltip md-direction="bottom">Modelagem de Ativos</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon active"><i class="fa fa-key"></i>
<md-tooltip md-direction="bottom">Habilitação do cryptocard</md-tooltip>
</a>
</td>
</tr>
<tr>
<td>
<div class="btn-group dropdown pull-left">
<a href="" class="dropdown btn btn-md btn-link text-info" data-toggle="dropdown" aria-expanded="false"><i class="glyphicon glyphicon-option-horizontal"></i>
<md-tooltip md-direction="top">Ações</md-tooltip>
</a>
<ul class="dropdown-menu animated fadeIn">
<li><a href=""><i class="fa fa-folder-open m-r-sm"></i>Abrir cadastro</a></li>
<li class="divider"></li>
<li><span class="text-muted m-l-md">Ações rápidas</span></li>
<li><a href=""><i class="fa fa-eye m-r-sm"></i>Espiar
<md-tooltip md-direction="right">Visualização rápida do cadastro.
</md-tooltip>
</a>
</li>
<li><a href=""><i class="fa fa-star m-r-sm"></i>Acompanhar o andamento</a></li>
<li><a href=""><i class="fa fa-warning m-r-sm"></i>Verificar pendências</a></li>
<li><a href=""><i class="fa fa-clock-o m-r-sm"></i>Verificar Prazos</a></li>
<li class="divider"></li>
<li><a href=""><i class="fa fa-thumbs-up m-r-sm"></i>Aprovar Cadastro</a></li>
<li><a href=""><i class="fa fa-thumbs-down m-r-sm"></i>Reprovar Cadastro</a></li>
</ul>
</div>
</td>
<td class="text-center">
<i class="fa fa-users m-r-sm text-muted"><md-tooltip md-direction="bottom">Organização do Setor</md-tooltip></i>
</td>
<td>Hermes da Silva</td>
<td>Secretaria da Fazenda - Governo do Estado do Piauí</td>
<td class="text-muted text-center">
<i class="fa fa-clock-o text-info m-r-xs"></i> 12/12/2016
</td>
<td class="text-muted text-center">
<i class="fa fa-clock-o text-info m-r-xs"></i> 12/12/2016
</td>
<td class="text-center">
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-user"></i>
<md-tooltip md-direction="bottom">Informações Cadastrais</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-file-pdf-o"></i>
<md-tooltip md-direction="bottom">Envio de Documentos </md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-pencil"></i>
<md-tooltip md-direction="bottom">Assinatura do Termo de Adesão</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-success btn-icon m-r-xs"><i class="fa fa-users"></i>
<md-tooltip md-direction="bottom">Indicação das representações</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-success btn-icon"><i class="fa fa-check"></i>
<md-tooltip md-direction="bottom">Aprovação do Cad</md-tooltip>
</a>
</td>
<td class="text-center">
<a href class="btn btn-sm btn-rounded btn-default btn-icon m-r-xs active"><i class="fa fa-dot-circle-o"></i>
<md-tooltip md-direction="bottom">Cadastro de Pontos</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon m-r-xs active"><i class="fa fa-plug"></i>
<md-tooltip md-direction="bottom">Modelagem de Ativos</md-tooltip>
</a>
<a href class="btn btn-sm btn-rounded btn-default btn-icon active"><i class="fa fa-key"></i>
<md-tooltip md-direction="bottom">Habilitação do cryptocard</md-tooltip>
</a>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<!-- hbox end -->
<!-- hbox -->
<div class="panel hbox hbox-auto-xs">
<!-- panel -->
<div class="panel-body bg-light lter">
<h3 class="font-thin m-t-none m-b text-muted"><i class="fa fa-clock-o m-r" aria-hidden="true"></i> Prazos</h3>
<div class="wrapper">Gráficos com pré-filtro para ações rápidas.</div>
<div class="">
<ul>
<li>Existem os seguintes indicadores que precisam ser discutidos:</li>
<li>- Prazo de processo de adesão (6 meses)</li>
<li>- Aprovação de documento, cadastro, perfil, etc (5du)</li>
<li>- Prazo para aprovação dA GUX (Adesão) - (M -12)</li>
<li>- Prazo do Conselho (Adesão) - (M -8)</li>
<li>Os prazos aplicados acima podem não ser aplicados para os Não Agentes, com exceção do 5du (Aprovação dos dados pela GUX)</li>
</ul>
</div>
</div>
<div class="panel-footer">
<p class="pull-left">
<label class="md-switch">
<input type="checkbox">
<i class="blue-grey"></i> Recebimento de notificações sobre prazos expirados
</label>
</p>
</div>
<div class="col wrapper-md w-lg bg-light dk r-r">
<h4 class="font-thin m-t-none m-b text-muted"><i class="fa fa-fire-extinguisher text-danger m-r-sm" aria-hidden="true"></i> Atrasos</h4>
<div class="wrapper">
Sinalização para ações de filtro rápido
</div>
</div>
</div>
<!-- hbox end -->
<!-- linha -->
<div class="row">
<div class="col-md-6">
<div class="panel panel-default">
<div class="panel-heading">
<span class="label label-default pull-right m-t-sm wrapper-xs">4 recebidas hoje</span>
<h4 class="font-thin m-t-sm m-b text-muted"><i class="ion-alert-circled m-r" aria-hidden="true"></i> Pendências de cadastro</h4>
</div>
<div class="wrapper">Tarefas do solicitante para conclusão do cadastro.</div>
</div>
</div>
<div class="col-md-6">
<div class="panel panel-default">
<div class="panel-heading">
<span class="label label-default pull-right m-t-sm wrapper-xs">4 atualizadas</span>
<h4 class="font-thin m-t-sm m-b text-muted"><i class="fa fa-star m-r" aria-hidden="true"></i> Acompanhamentos de cadastros</h4>
</div>
<div class="wrapper">Favoritos.</div>
</div>
</div>
</div>
<!-- linha end -->
</div>
</div>
</div>
</div> | 65.078067 | 290 | 0.384725 |
8f71c471ea1b2854aa65fac53d1cba7b17260987 | 319 | swift | Swift | Combine-MVVM/Model/MeasurementSymbol.swift | konroj/Combine-MVVM-Sample | 7e6af4191943214718a90c38ca5fd21a900e98a8 | [
"MIT"
] | null | null | null | Combine-MVVM/Model/MeasurementSymbol.swift | konroj/Combine-MVVM-Sample | 7e6af4191943214718a90c38ca5fd21a900e98a8 | [
"MIT"
] | null | null | null | Combine-MVVM/Model/MeasurementSymbol.swift | konroj/Combine-MVVM-Sample | 7e6af4191943214718a90c38ca5fd21a900e98a8 | [
"MIT"
] | null | null | null | //
// MeasurementSymbol.swift
// Combine-MVVM
//
// Created by Konrad Roj on 13/06/2019.
// Copyright © 2019 konradroj. All rights reserved.
//
import Foundation
enum MeasurementSymbol: String {
case rain = "rain"
case water = "water"
case windDirection = "winddir"
case windLevel = "windlevel"
}
| 18.764706 | 52 | 0.673981 |
27d28381d41af7107d4e1bf46eb01f1d125fef43 | 139,223 | asm | Assembly | ioq3/build/release-js-js/baseq3/cgame/cg_particles.asm | RawTechnique/quake-port | 2e7c02095f0207831a6026ec23b1c1d75c24f98d | [
"MIT"
] | 1 | 2021-12-31T10:26:58.000Z | 2021-12-31T10:26:58.000Z | ioq3/build/release-js-js/baseq3/cgame/cg_particles.asm | unfriendly/quake-port | 2e7c02095f0207831a6026ec23b1c1d75c24f98d | [
"MIT"
] | 28 | 2019-03-05T20:45:07.000Z | 2019-03-05T20:45:57.000Z | ioq3/build/release-js-js/baseq3/cgame/cg_particles.asm | unfriendly/quake-port | 2e7c02095f0207831a6026ec23b1c1d75c24f98d | [
"MIT"
] | null | null | null | data
align 4
LABELV shaderAnimNames
address $72
byte 4 0
skip 120
align 4
LABELV shaderAnimCounts
byte 4 23
skip 124
align 4
LABELV shaderAnimSTRatio
byte 4 1065353216
skip 124
export cl_numparticles
align 4
LABELV cl_numparticles
byte 4 1024
export initparticles
align 4
LABELV initparticles
byte 4 0
export CG_ClearParticles
code
proc CG_ClearParticles 28 12
ADDRGP4 particles
ARGP4
CNSTI4 0
ARGI4
CNSTU4 126976
ARGU4
ADDRGP4 qk_memset
CALLP4
pop
ADDRGP4 free_particles
ADDRGP4 particles
ASGNP4
ADDRGP4 active_particles
CNSTP4 0
ASGNP4
ADDRLP4 0
CNSTI4 0
ASGNI4
ADDRGP4 $77
JUMPV
LABELV $74
ADDRLP4 4
CNSTI4 124
ADDRLP4 0
INDIRI4
MULI4
ASGNI4
ADDRLP4 4
INDIRI4
ADDRGP4 particles
ADDP4
ADDRLP4 4
INDIRI4
ADDRGP4 particles+124
ADDP4
ASGNP4
CNSTI4 124
ADDRLP4 0
INDIRI4
MULI4
ADDRGP4 particles+64
ADDP4
CNSTI4 0
ASGNI4
LABELV $75
ADDRLP4 0
ADDRLP4 0
INDIRI4
CNSTI4 1
ADDI4
ASGNI4
LABELV $77
ADDRLP4 0
INDIRI4
ADDRGP4 cl_numparticles
INDIRI4
LTI4 $74
CNSTI4 124
ADDRGP4 cl_numparticles
INDIRI4
MULI4
ADDRGP4 particles-124
ADDP4
CNSTP4 0
ASGNP4
ADDRGP4 oldtime
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
CNSTI4 0
ASGNI4
ADDRGP4 $85
JUMPV
LABELV $82
ADDRLP4 4
CNSTI4 0
ASGNI4
ADDRGP4 $89
JUMPV
LABELV $86
ADDRGP4 $90
ARGP4
ADDRLP4 12
CNSTI4 2
ASGNI4
ADDRLP4 0
INDIRI4
ADDRLP4 12
INDIRI4
LSHI4
ADDRGP4 shaderAnimNames
ADDP4
INDIRP4
ARGP4
ADDRLP4 4
INDIRI4
CNSTI4 1
ADDI4
ARGI4
ADDRLP4 20
ADDRGP4 va
CALLP4
ASGNP4
ADDRLP4 20
INDIRP4
ARGP4
ADDRLP4 24
ADDRGP4 trap_R_RegisterShader
CALLI4
ASGNI4
ADDRLP4 4
INDIRI4
ADDRLP4 12
INDIRI4
LSHI4
ADDRLP4 0
INDIRI4
CNSTI4 8
LSHI4
ADDRGP4 shaderAnims
ADDP4
ADDP4
ADDRLP4 24
INDIRI4
ASGNI4
LABELV $87
ADDRLP4 4
ADDRLP4 4
INDIRI4
CNSTI4 1
ADDI4
ASGNI4
LABELV $89
ADDRLP4 4
INDIRI4
ADDRLP4 0
INDIRI4
CNSTI4 2
LSHI4
ADDRGP4 shaderAnimCounts
ADDP4
INDIRI4
LTI4 $86
LABELV $83
ADDRLP4 0
ADDRLP4 0
INDIRI4
CNSTI4 1
ADDI4
ASGNI4
LABELV $85
ADDRLP4 0
INDIRI4
CNSTI4 2
LSHI4
ADDRGP4 shaderAnimNames
ADDP4
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $82
ADDRGP4 numShaderAnims
ADDRLP4 0
INDIRI4
ASGNI4
ADDRGP4 initparticles
CNSTI4 1
ASGNI4
LABELV $73
endproc CG_ClearParticles 28 12
export CG_AddParticleToScene
proc CG_AddParticleToScene 476 16
ADDRFP4 0
ADDRFP4 0
INDIRP4
ASGNP4
ADDRFP4 4
ADDRFP4 4
INDIRP4
ASGNP4
ADDRLP4 240
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
ASGNI4
ADDRLP4 240
INDIRI4
CNSTI4 1
EQI4 $97
ADDRLP4 240
INDIRI4
CNSTI4 5
EQI4 $97
ADDRLP4 240
INDIRI4
CNSTI4 11
EQI4 $97
ADDRLP4 240
INDIRI4
CNSTI4 13
EQI4 $97
ADDRLP4 240
INDIRI4
CNSTI4 14
NEI4 $92
LABELV $97
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 11
EQI4 $98
ADDRLP4 244
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
ASGNI4
ADDRLP4 244
INDIRI4
CNSTI4 13
EQI4 $102
ADDRLP4 244
INDIRI4
CNSTI4 14
NEI4 $100
LABELV $102
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 92
ADDP4
INDIRF4
LEF4 $101
ADDRFP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRFP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 248
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRFP4 0
INDIRP4
CNSTI4 20
ADDP4
ADDRFP4 0
INDIRP4
CNSTI4 88
ADDP4
INDIRF4
CNSTF4 1082130432
CNSTF4 1073741824
ADDRLP4 248
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ADDF4
ASGNF4
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 14
NEI4 $101
ADDRLP4 256
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRFP4 0
INDIRP4
CNSTI4 24
ADDP4
CNSTF4 1082130432
CNSTF4 1073741824
ADDRLP4 256
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
ADDRLP4 260
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRFP4 0
INDIRP4
CNSTI4 28
ADDP4
CNSTF4 1082130432
CNSTF4 1073741824
ADDRLP4 260
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
ADDRGP4 $101
JUMPV
LABELV $100
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 92
ADDP4
INDIRF4
GEF4 $108
ADDRFP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRFP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRGP4 $112
JUMPV
LABELV $111
ADDRLP4 252
ADDRFP4 0
INDIRP4
CNSTI4 20
ADDP4
ASGNP4
ADDRLP4 252
INDIRP4
ADDRLP4 252
INDIRP4
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 88
ADDP4
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 92
ADDP4
INDIRF4
SUBF4
ADDF4
ASGNF4
LABELV $112
ADDRFP4 0
INDIRP4
CNSTI4 20
ADDP4
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 92
ADDP4
INDIRF4
LTF4 $111
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 5
NEI4 $114
ADDRLP4 252
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRFP4 0
INDIRP4
CNSTI4 24
ADDP4
CNSTF4 1098907648
CNSTF4 1073741824
ADDRLP4 252
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
ADDRLP4 256
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRFP4 0
INDIRP4
CNSTI4 28
ADDP4
CNSTF4 1098907648
CNSTF4 1073741824
ADDRLP4 256
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
LABELV $114
LABELV $108
LABELV $101
ADDRFP4 0
INDIRP4
CNSTI4 108
ADDP4
INDIRI4
CNSTI4 0
NEI4 $116
ADDRGP4 $91
JUMPV
LABELV $116
ADDRFP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1065353216
ASGNF4
LABELV $98
ADDRGP4 cg+36
INDIRP4
CNSTI4 64
ADDP4
ARGP4
ADDRFP4 4
INDIRP4
ARGP4
ADDRLP4 244
ADDRGP4 Distance
CALLF4
ASGNF4
ADDRLP4 244
INDIRF4
CNSTF4 1149239296
LEF4 $118
ADDRGP4 $91
JUMPV
LABELV $118
ADDRLP4 248
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
ASGNI4
ADDRLP4 248
INDIRI4
CNSTI4 13
EQI4 $123
ADDRLP4 248
INDIRI4
CNSTI4 14
NEI4 $121
LABELV $123
ADDRLP4 256
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 256
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 256
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 260
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 260
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 260
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 12
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+12
CNSTF4 0
ASGNF4
ADDRLP4 12+12+4
CNSTF4 0
ASGNF4
ADDRLP4 12+20
CNSTU1 255
ASGNU1
ADDRLP4 12+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+20+2
CNSTU1 255
ASGNU1
ADDRLP4 268
CNSTF4 1132396544
ADDRFP4 0
INDIRP4
CNSTI4 56
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 272
CNSTF4 1325400064
ASGNF4
ADDRLP4 268
INDIRF4
ADDRLP4 272
INDIRF4
LTF4 $145
ADDRLP4 264
ADDRLP4 268
INDIRF4
ADDRLP4 272
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $146
JUMPV
LABELV $145
ADDRLP4 264
ADDRLP4 268
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $146
ADDRLP4 12+20+3
ADDRLP4 264
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 280
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 280
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 280
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 284
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 284
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 284
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 12+24
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+24+12
CNSTF4 0
ASGNF4
ADDRLP4 12+24+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+24+20
CNSTU1 255
ASGNU1
ADDRLP4 12+24+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+24+20+2
CNSTU1 255
ASGNU1
ADDRLP4 292
CNSTF4 1132396544
ADDRFP4 0
INDIRP4
CNSTI4 56
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 296
CNSTF4 1325400064
ASGNF4
ADDRLP4 292
INDIRF4
ADDRLP4 296
INDIRF4
LTF4 $175
ADDRLP4 288
ADDRLP4 292
INDIRF4
ADDRLP4 296
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $176
JUMPV
LABELV $175
ADDRLP4 288
ADDRLP4 292
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $176
ADDRLP4 12+24+20+3
ADDRLP4 288
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 304
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 304
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 304
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 308
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 308
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 308
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 12+48
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+48+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+20
CNSTU1 255
ASGNU1
ADDRLP4 12+48+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+48+20+2
CNSTU1 255
ASGNU1
ADDRLP4 316
CNSTF4 1132396544
ADDRFP4 0
INDIRP4
CNSTI4 56
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 320
CNSTF4 1325400064
ASGNF4
ADDRLP4 316
INDIRF4
ADDRLP4 320
INDIRF4
LTF4 $205
ADDRLP4 312
ADDRLP4 316
INDIRF4
ADDRLP4 320
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $206
JUMPV
LABELV $205
ADDRLP4 312
ADDRLP4 316
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $206
ADDRLP4 12+48+20+3
ADDRLP4 312
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 328
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 328
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 328
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 332
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 332
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 332
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 12+72
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+72+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+72+12+4
CNSTF4 0
ASGNF4
ADDRLP4 12+72+20
CNSTU1 255
ASGNU1
ADDRLP4 12+72+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+72+20+2
CNSTU1 255
ASGNU1
ADDRLP4 340
CNSTF4 1132396544
ADDRFP4 0
INDIRP4
CNSTI4 56
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 344
CNSTF4 1325400064
ASGNF4
ADDRLP4 340
INDIRF4
ADDRLP4 344
INDIRF4
LTF4 $235
ADDRLP4 336
ADDRLP4 340
INDIRF4
ADDRLP4 344
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $236
JUMPV
LABELV $235
ADDRLP4 336
ADDRLP4 340
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $236
ADDRLP4 12+72+20+3
ADDRLP4 336
INDIRU4
CVUU1 4
ASGNU1
ADDRGP4 $93
JUMPV
LABELV $121
ADDRLP4 256
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 256
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 256
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 260
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 260
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 260
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 108
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 108+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 108+12+4
CNSTF4 0
ASGNF4
ADDRLP4 108+20
CNSTU1 255
ASGNU1
ADDRLP4 108+20+1
CNSTU1 255
ASGNU1
ADDRLP4 108+20+2
CNSTU1 255
ASGNU1
ADDRLP4 268
CNSTF4 1132396544
ADDRFP4 0
INDIRP4
CNSTI4 56
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 272
CNSTF4 1325400064
ASGNF4
ADDRLP4 268
INDIRF4
ADDRLP4 272
INDIRF4
LTF4 $258
ADDRLP4 264
ADDRLP4 268
INDIRF4
ADDRLP4 272
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $259
JUMPV
LABELV $258
ADDRLP4 264
ADDRLP4 268
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $259
ADDRLP4 108+20+3
ADDRLP4 264
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 280
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 280
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 280
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 284
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 284
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 284
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 108+24
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 108+24+12
CNSTF4 0
ASGNF4
ADDRLP4 108+24+12+4
CNSTF4 0
ASGNF4
ADDRLP4 108+24+20
CNSTU1 255
ASGNU1
ADDRLP4 108+24+20+1
CNSTU1 255
ASGNU1
ADDRLP4 108+24+20+2
CNSTU1 255
ASGNU1
ADDRLP4 292
CNSTF4 1132396544
ADDRFP4 0
INDIRP4
CNSTI4 56
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 296
CNSTF4 1325400064
ASGNF4
ADDRLP4 292
INDIRF4
ADDRLP4 296
INDIRF4
LTF4 $288
ADDRLP4 288
ADDRLP4 292
INDIRF4
ADDRLP4 296
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $289
JUMPV
LABELV $288
ADDRLP4 288
ADDRLP4 292
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $289
ADDRLP4 108+24+20+3
ADDRLP4 288
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 304
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 304
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 304
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 308
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 308
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 308
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 108+48
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 108+48+12
CNSTF4 0
ASGNF4
ADDRLP4 108+48+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 108+48+20
CNSTU1 255
ASGNU1
ADDRLP4 108+48+20+1
CNSTU1 255
ASGNU1
ADDRLP4 108+48+20+2
CNSTU1 255
ASGNU1
ADDRLP4 316
CNSTF4 1132396544
ADDRFP4 0
INDIRP4
CNSTI4 56
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 320
CNSTF4 1325400064
ASGNF4
ADDRLP4 316
INDIRF4
ADDRLP4 320
INDIRF4
LTF4 $318
ADDRLP4 312
ADDRLP4 316
INDIRF4
ADDRLP4 320
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $319
JUMPV
LABELV $318
ADDRLP4 312
ADDRLP4 316
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $319
ADDRLP4 108+48+20+3
ADDRLP4 312
INDIRU4
CVUU1 4
ASGNU1
ADDRGP4 $93
JUMPV
LABELV $92
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 15
NEI4 $320
ADDRLP4 280
CNSTF4 1065353216
ASGNF4
ADDRLP4 184
ADDRLP4 280
INDIRF4
ASGNF4
ADDRLP4 184+4
ADDRLP4 280
INDIRF4
ASGNF4
ADDRLP4 184+8
CNSTF4 1056964608
ASGNF4
ADDRLP4 288
ADDRFP4 0
INDIRP4
CNSTI4 4
ADDP4
ASGNP4
ADDRLP4 232
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRLP4 288
INDIRP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 236
ADDRFP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 288
INDIRP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 200
ADDRLP4 232
INDIRF4
ADDRLP4 236
INDIRF4
DIVF4
ASGNF4
ADDRLP4 292
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
ASGNF4
ADDRLP4 296
ADDRLP4 200
INDIRF4
ASGNF4
ADDRLP4 196
ADDRLP4 292
INDIRF4
ADDRLP4 296
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 84
ADDP4
INDIRF4
ADDRLP4 292
INDIRF4
SUBF4
MULF4
ADDF4
ASGNF4
ADDRLP4 300
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
ASGNF4
ADDRLP4 180
ADDRLP4 300
INDIRF4
ADDRLP4 296
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 80
ADDP4
INDIRF4
ADDRLP4 300
INDIRF4
SUBF4
MULF4
ADDF4
ASGNF4
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CNSTI4 0
EQI4 $325
ADDRGP4 cg+109032+36
ARGP4
ADDRLP4 268
ARGP4
ADDRGP4 vectoangles
CALLV
pop
ADDRLP4 268+8
ADDRLP4 268+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CVIF4 4
ADDF4
ASGNF4
ADDRLP4 268
ARGP4
CNSTP4 0
ARGP4
ADDRLP4 256
ARGP4
ADDRLP4 244
ARGP4
ADDRGP4 AngleVectors
CALLV
pop
LABELV $325
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CNSTI4 0
EQI4 $330
ADDRLP4 308
ADDRLP4 180
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRLP4 244
INDIRF4
ADDRLP4 308
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRLP4 244+4
INDIRF4
ADDRLP4 308
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 244+8
INDIRF4
ADDRLP4 180
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 312
ADDRLP4 196
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 256
INDIRF4
ADDRLP4 312
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 256+4
INDIRF4
ADDRLP4 312
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 256+8
INDIRF4
ADDRLP4 196
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $331
JUMPV
LABELV $330
ADDRLP4 308
ADDRLP4 180
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 308
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 308
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRLP4 180
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 312
ADDRLP4 196
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 312
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 312
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRLP4 196
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
LABELV $331
ADDRLP4 12
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+12
CNSTF4 0
ASGNF4
ADDRLP4 12+12+4
CNSTF4 0
ASGNF4
ADDRLP4 12+20
CNSTU1 255
ASGNU1
ADDRLP4 12+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+20+3
CNSTU1 255
ASGNU1
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CNSTI4 0
EQI4 $362
ADDRLP4 304
CNSTF4 1073741824
ADDRLP4 180
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 244
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 244+4
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 244+8
INDIRF4
CNSTF4 1073741824
ADDRLP4 180
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $363
JUMPV
LABELV $362
ADDRLP4 304
CNSTF4 1073741824
ADDRLP4 180
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vup+8
INDIRF4
CNSTF4 1073741824
ADDRLP4 180
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
LABELV $363
ADDRLP4 12+24
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+24+12
CNSTF4 0
ASGNF4
ADDRLP4 12+24+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+24+20
CNSTU1 255
ASGNU1
ADDRLP4 12+24+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+24+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+24+20+3
CNSTU1 255
ASGNU1
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CNSTI4 0
EQI4 $393
ADDRLP4 304
CNSTF4 1073741824
ADDRLP4 196
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 256
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 256+4
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 256+8
INDIRF4
CNSTF4 1073741824
ADDRLP4 196
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $394
JUMPV
LABELV $393
ADDRLP4 304
CNSTF4 1073741824
ADDRLP4 196
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
CNSTF4 1073741824
ADDRLP4 196
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
LABELV $394
ADDRLP4 12+48
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+48+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+20
CNSTU1 255
ASGNU1
ADDRLP4 12+48+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+48+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+48+20+3
CNSTU1 255
ASGNU1
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CNSTI4 0
EQI4 $424
ADDRLP4 304
CNSTF4 3221225472
ADDRLP4 180
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 244
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 244+4
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 244+8
INDIRF4
CNSTF4 3221225472
ADDRLP4 180
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $425
JUMPV
LABELV $424
ADDRLP4 304
CNSTF4 3221225472
ADDRLP4 180
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 304
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vup+8
INDIRF4
CNSTF4 3221225472
ADDRLP4 180
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
LABELV $425
ADDRLP4 12+72
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+72+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+72+12+4
CNSTF4 0
ASGNF4
ADDRLP4 12+72+20
CNSTU1 255
ASGNU1
ADDRLP4 12+72+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+72+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+72+20+3
CNSTU1 255
ASGNU1
ADDRGP4 $321
JUMPV
LABELV $320
ADDRLP4 244
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
ASGNI4
ADDRLP4 244
INDIRI4
CNSTI4 3
EQI4 $457
ADDRLP4 244
INDIRI4
CNSTI4 12
NEI4 $455
LABELV $457
ADDRLP4 248
CNSTI4 64
ASGNI4
ADDRFP4 0
INDIRP4
ADDRLP4 248
INDIRI4
ADDP4
INDIRI4
CNSTI4 12
NEI4 $458
ADDRGP4 cg+36
INDIRP4
ADDRLP4 248
INDIRI4
ADDP4
ARGP4
ADDRFP4 4
INDIRP4
ARGP4
ADDRLP4 252
ADDRGP4 Distance
CALLF4
ASGNF4
ADDRLP4 252
INDIRF4
CNSTF4 1149239296
LEF4 $458
ADDRGP4 $91
JUMPV
LABELV $458
ADDRFP4 0
INDIRP4
CNSTI4 48
ADDP4
INDIRI4
CNSTI4 2
NEI4 $461
ADDRLP4 184
CNSTF4 1046562734
ASGNF4
ADDRLP4 184+4
CNSTF4 0
ASGNF4
ADDRLP4 184+8
CNSTF4 0
ASGNF4
ADDRGP4 $462
JUMPV
LABELV $461
ADDRFP4 0
INDIRP4
CNSTI4 48
ADDP4
INDIRI4
CNSTI4 4
NEI4 $465
ADDRGP4 cg+36
INDIRP4
CNSTI4 64
ADDP4
ARGP4
ADDRFP4 4
INDIRP4
ARGP4
ADDRLP4 268
ADDRGP4 Distance
CALLF4
ASGNF4
ADDRLP4 260
ADDRLP4 268
INDIRF4
ASGNF4
ADDRLP4 260
INDIRF4
CNSTF4 0
NEF4 $468
ADDRLP4 260
CNSTF4 1065353216
ASGNF4
LABELV $468
ADDRLP4 264
CNSTF4 1166016512
ADDRLP4 260
INDIRF4
DIVF4
ASGNF4
ADDRLP4 256
CNSTF4 1048576000
ADDRLP4 264
INDIRF4
MULF4
ASGNF4
ADDRLP4 256
INDIRF4
CNSTF4 1056964608
LEF4 $470
ADDRLP4 256
CNSTF4 1056964608
ASGNF4
LABELV $470
ADDRLP4 272
ADDRLP4 256
INDIRF4
ASGNF4
ADDRLP4 184
ADDRLP4 272
INDIRF4
ASGNF4
ADDRLP4 184+4
ADDRLP4 272
INDIRF4
ASGNF4
ADDRLP4 184+8
ADDRLP4 256
INDIRF4
ASGNF4
ADDRGP4 $466
JUMPV
LABELV $465
ADDRLP4 256
CNSTF4 1065353216
ASGNF4
ADDRLP4 184
ADDRLP4 256
INDIRF4
ASGNF4
ADDRLP4 184+4
ADDRLP4 256
INDIRF4
ASGNF4
ADDRLP4 184+8
CNSTF4 1065353216
ASGNF4
LABELV $466
LABELV $462
ADDRLP4 264
ADDRFP4 0
INDIRP4
CNSTI4 4
ADDP4
ASGNP4
ADDRLP4 232
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRLP4 264
INDIRP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 236
ADDRFP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 264
INDIRP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 200
ADDRLP4 232
INDIRF4
ADDRLP4 236
INDIRF4
DIVF4
ASGNF4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRFP4 0
INDIRP4
CNSTI4 96
ADDP4
INDIRF4
LEF4 $477
ADDRLP4 272
ADDRFP4 0
INDIRP4
CNSTI4 96
ADDP4
INDIRF4
ASGNF4
ADDRLP4 204
CNSTF4 1065353216
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRLP4 272
INDIRF4
SUBF4
ADDRFP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 272
INDIRF4
SUBF4
DIVF4
SUBF4
ASGNF4
ADDRFP4 0
INDIRP4
CNSTI4 48
ADDP4
INDIRI4
CNSTI4 3
NEI4 $481
ADDRLP4 280
ADDRLP4 204
INDIRF4
ASGNF4
ADDRLP4 276
ADDRLP4 280
INDIRF4
ADDRLP4 280
INDIRF4
MULF4
ASGNF4
ADDRLP4 276
INDIRF4
CNSTF4 0
GEF4 $483
ADDRLP4 276
CNSTF4 0
ASGNF4
LABELV $483
ADDRLP4 284
ADDRLP4 276
INDIRF4
ASGNF4
ADDRLP4 184
ADDRLP4 284
INDIRF4
ASGNF4
ADDRLP4 184+4
ADDRLP4 284
INDIRF4
ASGNF4
ADDRLP4 184+8
ADDRLP4 276
INDIRF4
ASGNF4
LABELV $481
ADDRLP4 204
ADDRLP4 204
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 56
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRGP4 $478
JUMPV
LABELV $477
ADDRLP4 204
CNSTF4 1065353216
ADDRFP4 0
INDIRP4
CNSTI4 56
ADDP4
INDIRF4
MULF4
ASGNF4
LABELV $478
ADDRGP4 cgs+20100+11288
INDIRI4
CNSTI4 3
NEI4 $487
ADDRLP4 204
CNSTF4 1065353216
ASGNF4
LABELV $487
ADDRLP4 204
INDIRF4
CNSTF4 1065353216
LEF4 $491
ADDRLP4 204
CNSTF4 1065353216
ASGNF4
LABELV $491
ADDRLP4 272
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
ASGNF4
ADDRLP4 276
ADDRLP4 200
INDIRF4
ASGNF4
ADDRLP4 196
ADDRLP4 272
INDIRF4
ADDRLP4 276
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 84
ADDP4
INDIRF4
ADDRLP4 272
INDIRF4
SUBF4
MULF4
ADDF4
ASGNF4
ADDRLP4 280
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
ASGNF4
ADDRLP4 180
ADDRLP4 280
INDIRF4
ADDRLP4 276
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 80
ADDP4
INDIRF4
ADDRLP4 280
INDIRF4
SUBF4
MULF4
ADDF4
ASGNF4
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 12
EQI4 $493
ADDRGP4 rforward
ARGP4
ADDRLP4 284
ARGP4
ADDRGP4 vectoangles
CALLV
pop
ADDRLP4 300
ADDRFP4 0
INDIRP4
CNSTI4 120
ADDP4
ASGNP4
ADDRLP4 300
INDIRP4
ADDRLP4 300
INDIRP4
INDIRI4
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
ADDI4
ASGNI4
ADDRLP4 284+8
ADDRLP4 284+8
INDIRF4
CNSTF4 1036831949
ADDRFP4 0
INDIRP4
CNSTI4 120
ADDP4
INDIRI4
CVIF4 4
MULF4
ADDF4
ASGNF4
ADDRLP4 284
ARGP4
CNSTP4 0
ARGP4
ADDRLP4 208
ARGP4
ADDRLP4 220
ARGP4
ADDRGP4 AngleVectors
CALLV
pop
ADDRGP4 $494
JUMPV
LABELV $493
ADDRLP4 208
ADDRGP4 rright
INDIRB
ASGNB 12
ADDRLP4 220
ADDRGP4 rup
INDIRB
ASGNB 12
LABELV $494
ADDRFP4 0
INDIRP4
CNSTI4 100
ADDP4
INDIRI4
CNSTI4 0
EQI4 $496
ADDRLP4 288
ADDRLP4 180
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRLP4 220
INDIRF4
ADDRLP4 288
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRLP4 220+4
INDIRF4
ADDRLP4 288
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 220+8
INDIRF4
ADDRLP4 180
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 292
ADDRLP4 196
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 208
INDIRF4
ADDRLP4 292
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 208+4
INDIRF4
ADDRLP4 292
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 208+8
INDIRF4
ADDRLP4 196
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $497
JUMPV
LABELV $496
ADDRLP4 288
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 288
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 288
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 292
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 292
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 292
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
LABELV $497
ADDRLP4 12
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+12
CNSTF4 0
ASGNF4
ADDRLP4 12+12+4
CNSTF4 0
ASGNF4
ADDRLP4 288
CNSTF4 1132396544
ADDRLP4 184
INDIRF4
MULF4
ASGNF4
ADDRLP4 292
CNSTF4 1325400064
ASGNF4
ADDRLP4 288
INDIRF4
ADDRLP4 292
INDIRF4
LTF4 $523
ADDRLP4 284
ADDRLP4 288
INDIRF4
ADDRLP4 292
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $524
JUMPV
LABELV $523
ADDRLP4 284
ADDRLP4 288
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $524
ADDRLP4 12+20
ADDRLP4 284
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 300
CNSTF4 1132396544
ADDRLP4 184+4
INDIRF4
MULF4
ASGNF4
ADDRLP4 304
CNSTF4 1325400064
ASGNF4
ADDRLP4 300
INDIRF4
ADDRLP4 304
INDIRF4
LTF4 $529
ADDRLP4 296
ADDRLP4 300
INDIRF4
ADDRLP4 304
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $530
JUMPV
LABELV $529
ADDRLP4 296
ADDRLP4 300
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $530
ADDRLP4 12+20+1
ADDRLP4 296
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 312
CNSTF4 1132396544
ADDRLP4 184+8
INDIRF4
MULF4
ASGNF4
ADDRLP4 316
CNSTF4 1325400064
ASGNF4
ADDRLP4 312
INDIRF4
ADDRLP4 316
INDIRF4
LTF4 $535
ADDRLP4 308
ADDRLP4 312
INDIRF4
ADDRLP4 316
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $536
JUMPV
LABELV $535
ADDRLP4 308
ADDRLP4 312
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $536
ADDRLP4 12+20+2
ADDRLP4 308
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 324
CNSTF4 1132396544
ADDRLP4 204
INDIRF4
MULF4
ASGNF4
ADDRLP4 328
CNSTF4 1325400064
ASGNF4
ADDRLP4 324
INDIRF4
ADDRLP4 328
INDIRF4
LTF4 $540
ADDRLP4 320
ADDRLP4 324
INDIRF4
ADDRLP4 328
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $541
JUMPV
LABELV $540
ADDRLP4 320
ADDRLP4 324
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $541
ADDRLP4 12+20+3
ADDRLP4 320
INDIRU4
CVUU1 4
ASGNU1
ADDRFP4 0
INDIRP4
CNSTI4 100
ADDP4
INDIRI4
CNSTI4 0
EQI4 $542
ADDRLP4 336
ADDRLP4 180
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRLP4 220
INDIRF4
ADDRLP4 336
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRLP4 220+4
INDIRF4
ADDRLP4 336
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 220+8
INDIRF4
ADDRLP4 180
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 340
ADDRLP4 196
INDIRF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 208
INDIRF4
ADDRLP4 340
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 208+4
INDIRF4
ADDRLP4 340
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 208+8
INDIRF4
ADDRLP4 196
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $543
JUMPV
LABELV $542
ADDRLP4 336
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 336
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 336
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 340
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 340
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 340
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
LABELV $543
ADDRLP4 12+24
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+24+12
CNSTF4 0
ASGNF4
ADDRLP4 12+24+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 336
CNSTF4 1132396544
ADDRLP4 184
INDIRF4
MULF4
ASGNF4
ADDRLP4 340
CNSTF4 1325400064
ASGNF4
ADDRLP4 336
INDIRF4
ADDRLP4 340
INDIRF4
LTF4 $573
ADDRLP4 332
ADDRLP4 336
INDIRF4
ADDRLP4 340
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $574
JUMPV
LABELV $573
ADDRLP4 332
ADDRLP4 336
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $574
ADDRLP4 12+24+20
ADDRLP4 332
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 348
CNSTF4 1132396544
ADDRLP4 184+4
INDIRF4
MULF4
ASGNF4
ADDRLP4 352
CNSTF4 1325400064
ASGNF4
ADDRLP4 348
INDIRF4
ADDRLP4 352
INDIRF4
LTF4 $580
ADDRLP4 344
ADDRLP4 348
INDIRF4
ADDRLP4 352
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $581
JUMPV
LABELV $580
ADDRLP4 344
ADDRLP4 348
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $581
ADDRLP4 12+24+20+1
ADDRLP4 344
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 360
CNSTF4 1132396544
ADDRLP4 184+8
INDIRF4
MULF4
ASGNF4
ADDRLP4 364
CNSTF4 1325400064
ASGNF4
ADDRLP4 360
INDIRF4
ADDRLP4 364
INDIRF4
LTF4 $587
ADDRLP4 356
ADDRLP4 360
INDIRF4
ADDRLP4 364
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $588
JUMPV
LABELV $587
ADDRLP4 356
ADDRLP4 360
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $588
ADDRLP4 12+24+20+2
ADDRLP4 356
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 372
CNSTF4 1132396544
ADDRLP4 204
INDIRF4
MULF4
ASGNF4
ADDRLP4 376
CNSTF4 1325400064
ASGNF4
ADDRLP4 372
INDIRF4
ADDRLP4 376
INDIRF4
LTF4 $593
ADDRLP4 368
ADDRLP4 372
INDIRF4
ADDRLP4 376
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $594
JUMPV
LABELV $593
ADDRLP4 368
ADDRLP4 372
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $594
ADDRLP4 12+24+20+3
ADDRLP4 368
INDIRU4
CVUU1 4
ASGNU1
ADDRFP4 0
INDIRP4
CNSTI4 100
ADDP4
INDIRI4
CNSTI4 0
EQI4 $595
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRLP4 220
INDIRF4
ADDRLP4 180
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRLP4 220+4
INDIRF4
ADDRLP4 180
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 220+8
INDIRF4
ADDRLP4 180
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 388
ADDRLP4 196
INDIRF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 208
INDIRF4
ADDRLP4 388
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 208+4
INDIRF4
ADDRLP4 388
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 208+8
INDIRF4
ADDRLP4 196
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $596
JUMPV
LABELV $595
ADDRLP4 384
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 384
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 384
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 388
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 388
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 388
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
LABELV $596
ADDRLP4 12+48
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+48+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 384
CNSTF4 1132396544
ADDRLP4 184
INDIRF4
MULF4
ASGNF4
ADDRLP4 388
CNSTF4 1325400064
ASGNF4
ADDRLP4 384
INDIRF4
ADDRLP4 388
INDIRF4
LTF4 $626
ADDRLP4 380
ADDRLP4 384
INDIRF4
ADDRLP4 388
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $627
JUMPV
LABELV $626
ADDRLP4 380
ADDRLP4 384
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $627
ADDRLP4 12+48+20
ADDRLP4 380
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 396
CNSTF4 1132396544
ADDRLP4 184+4
INDIRF4
MULF4
ASGNF4
ADDRLP4 400
CNSTF4 1325400064
ASGNF4
ADDRLP4 396
INDIRF4
ADDRLP4 400
INDIRF4
LTF4 $633
ADDRLP4 392
ADDRLP4 396
INDIRF4
ADDRLP4 400
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $634
JUMPV
LABELV $633
ADDRLP4 392
ADDRLP4 396
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $634
ADDRLP4 12+48+20+1
ADDRLP4 392
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 408
CNSTF4 1132396544
ADDRLP4 184+8
INDIRF4
MULF4
ASGNF4
ADDRLP4 412
CNSTF4 1325400064
ASGNF4
ADDRLP4 408
INDIRF4
ADDRLP4 412
INDIRF4
LTF4 $640
ADDRLP4 404
ADDRLP4 408
INDIRF4
ADDRLP4 412
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $641
JUMPV
LABELV $640
ADDRLP4 404
ADDRLP4 408
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $641
ADDRLP4 12+48+20+2
ADDRLP4 404
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 420
CNSTF4 1132396544
ADDRLP4 204
INDIRF4
MULF4
ASGNF4
ADDRLP4 424
CNSTF4 1325400064
ASGNF4
ADDRLP4 420
INDIRF4
ADDRLP4 424
INDIRF4
LTF4 $646
ADDRLP4 416
ADDRLP4 420
INDIRF4
ADDRLP4 424
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $647
JUMPV
LABELV $646
ADDRLP4 416
ADDRLP4 420
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $647
ADDRLP4 12+48+20+3
ADDRLP4 416
INDIRU4
CVUU1 4
ASGNU1
ADDRFP4 0
INDIRP4
CNSTI4 100
ADDP4
INDIRI4
CNSTI4 0
EQI4 $648
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRLP4 220
INDIRF4
ADDRLP4 180
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRLP4 220+4
INDIRF4
ADDRLP4 180
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 220+8
INDIRF4
ADDRLP4 180
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 436
ADDRLP4 196
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 208
INDIRF4
ADDRLP4 436
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 208+4
INDIRF4
ADDRLP4 436
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 208+8
INDIRF4
ADDRLP4 196
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $649
JUMPV
LABELV $648
ADDRLP4 432
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 432
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 432
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 436
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 436
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 436
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
LABELV $649
ADDRLP4 12+72
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+72+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+72+12+4
CNSTF4 0
ASGNF4
ADDRLP4 432
CNSTF4 1132396544
ADDRLP4 184
INDIRF4
MULF4
ASGNF4
ADDRLP4 436
CNSTF4 1325400064
ASGNF4
ADDRLP4 432
INDIRF4
ADDRLP4 436
INDIRF4
LTF4 $679
ADDRLP4 428
ADDRLP4 432
INDIRF4
ADDRLP4 436
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $680
JUMPV
LABELV $679
ADDRLP4 428
ADDRLP4 432
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $680
ADDRLP4 12+72+20
ADDRLP4 428
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 444
CNSTF4 1132396544
ADDRLP4 184+4
INDIRF4
MULF4
ASGNF4
ADDRLP4 448
CNSTF4 1325400064
ASGNF4
ADDRLP4 444
INDIRF4
ADDRLP4 448
INDIRF4
LTF4 $686
ADDRLP4 440
ADDRLP4 444
INDIRF4
ADDRLP4 448
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $687
JUMPV
LABELV $686
ADDRLP4 440
ADDRLP4 444
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $687
ADDRLP4 12+72+20+1
ADDRLP4 440
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 456
CNSTF4 1132396544
ADDRLP4 184+8
INDIRF4
MULF4
ASGNF4
ADDRLP4 460
CNSTF4 1325400064
ASGNF4
ADDRLP4 456
INDIRF4
ADDRLP4 460
INDIRF4
LTF4 $693
ADDRLP4 452
ADDRLP4 456
INDIRF4
ADDRLP4 460
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $694
JUMPV
LABELV $693
ADDRLP4 452
ADDRLP4 456
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $694
ADDRLP4 12+72+20+2
ADDRLP4 452
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 468
CNSTF4 1132396544
ADDRLP4 204
INDIRF4
MULF4
ASGNF4
ADDRLP4 472
CNSTF4 1325400064
ASGNF4
ADDRLP4 468
INDIRF4
ADDRLP4 472
INDIRF4
LTF4 $699
ADDRLP4 464
ADDRLP4 468
INDIRF4
ADDRLP4 472
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $700
JUMPV
LABELV $699
ADDRLP4 464
ADDRLP4 468
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $700
ADDRLP4 12+72+20+3
ADDRLP4 464
INDIRU4
CVUU1 4
ASGNU1
ADDRGP4 $456
JUMPV
LABELV $455
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 8
NEI4 $701
ADDRLP4 272
ADDRFP4 0
INDIRP4
CNSTI4 56
ADDP4
INDIRF4
ASGNF4
ADDRGP4 cgs+20100+11288
INDIRI4
CNSTI4 3
NEI4 $703
ADDRLP4 272
CNSTF4 1065353216
ASGNF4
LABELV $703
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CNSTI4 0
EQI4 $707
ADDRGP4 cg+109032+36
ARGP4
ADDRLP4 276
ARGP4
ADDRGP4 vectoangles
CALLV
pop
ADDRLP4 276+8
ADDRLP4 276+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CVIF4 4
ADDF4
ASGNF4
ADDRLP4 276
ARGP4
CNSTP4 0
ARGP4
ADDRLP4 248
ARGP4
ADDRLP4 260
ARGP4
ADDRGP4 AngleVectors
CALLV
pop
ADDRGP4 $708
JUMPV
LABELV $707
ADDRLP4 260
ADDRGP4 vup
INDIRB
ASGNB 12
ADDRLP4 248
ADDRGP4 vright
INDIRB
ASGNB 12
LABELV $708
ADDRLP4 292
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRLP4 260
INDIRF4
ADDRLP4 292
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRLP4 260+4
INDIRF4
ADDRLP4 292
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 260+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 296
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 248
INDIRF4
ADDRLP4 296
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 248+4
INDIRF4
ADDRLP4 296
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 248+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 12
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+12
CNSTF4 0
ASGNF4
ADDRLP4 12+12+4
CNSTF4 0
ASGNF4
ADDRLP4 12+20
CNSTU1 111
ASGNU1
ADDRLP4 12+20+1
CNSTU1 19
ASGNU1
ADDRLP4 12+20+2
CNSTU1 9
ASGNU1
ADDRLP4 304
CNSTF4 1132396544
ADDRLP4 272
INDIRF4
MULF4
ASGNF4
ADDRLP4 308
CNSTF4 1325400064
ASGNF4
ADDRLP4 304
INDIRF4
ADDRLP4 308
INDIRF4
LTF4 $733
ADDRLP4 300
ADDRLP4 304
INDIRF4
ADDRLP4 308
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $734
JUMPV
LABELV $733
ADDRLP4 300
ADDRLP4 304
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $734
ADDRLP4 12+20+3
ADDRLP4 300
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 316
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRLP4 260
INDIRF4
ADDRLP4 316
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRLP4 260+4
INDIRF4
ADDRLP4 316
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 260+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 320
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 248
INDIRF4
ADDRLP4 320
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 248+4
INDIRF4
ADDRLP4 320
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 248+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 12+24
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+24+12
CNSTF4 0
ASGNF4
ADDRLP4 12+24+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+24+20
CNSTU1 111
ASGNU1
ADDRLP4 12+24+20+1
CNSTU1 19
ASGNU1
ADDRLP4 12+24+20+2
CNSTU1 9
ASGNU1
ADDRLP4 328
CNSTF4 1132396544
ADDRLP4 272
INDIRF4
MULF4
ASGNF4
ADDRLP4 332
CNSTF4 1325400064
ASGNF4
ADDRLP4 328
INDIRF4
ADDRLP4 332
INDIRF4
LTF4 $763
ADDRLP4 324
ADDRLP4 328
INDIRF4
ADDRLP4 332
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $764
JUMPV
LABELV $763
ADDRLP4 324
ADDRLP4 328
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $764
ADDRLP4 12+24+20+3
ADDRLP4 324
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 340
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRLP4 260
INDIRF4
ADDRLP4 340
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRLP4 260+4
INDIRF4
ADDRLP4 340
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 260+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 344
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 248
INDIRF4
ADDRLP4 344
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 248+4
INDIRF4
ADDRLP4 344
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 248+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 12+48
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+48+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+20
CNSTU1 111
ASGNU1
ADDRLP4 12+48+20+1
CNSTU1 19
ASGNU1
ADDRLP4 12+48+20+2
CNSTU1 9
ASGNU1
ADDRLP4 352
CNSTF4 1132396544
ADDRLP4 272
INDIRF4
MULF4
ASGNF4
ADDRLP4 356
CNSTF4 1325400064
ASGNF4
ADDRLP4 352
INDIRF4
ADDRLP4 356
INDIRF4
LTF4 $793
ADDRLP4 348
ADDRLP4 352
INDIRF4
ADDRLP4 356
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $794
JUMPV
LABELV $793
ADDRLP4 348
ADDRLP4 352
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $794
ADDRLP4 12+48+20+3
ADDRLP4 348
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 364
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRLP4 260
INDIRF4
ADDRLP4 364
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRLP4 260+4
INDIRF4
ADDRLP4 364
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 260+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 368
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 248
INDIRF4
ADDRLP4 368
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 248+4
INDIRF4
ADDRLP4 368
INDIRP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 248+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 12+72
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+72+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+72+12+4
CNSTF4 0
ASGNF4
ADDRLP4 12+72+20
CNSTU1 111
ASGNU1
ADDRLP4 12+72+20+1
CNSTU1 19
ASGNU1
ADDRLP4 12+72+20+2
CNSTU1 9
ASGNU1
ADDRLP4 376
CNSTF4 1132396544
ADDRLP4 272
INDIRF4
MULF4
ASGNF4
ADDRLP4 380
CNSTF4 1325400064
ASGNF4
ADDRLP4 376
INDIRF4
ADDRLP4 380
INDIRF4
LTF4 $823
ADDRLP4 372
ADDRLP4 376
INDIRF4
ADDRLP4 380
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $824
JUMPV
LABELV $823
ADDRLP4 372
ADDRLP4 376
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $824
ADDRLP4 12+72+20+3
ADDRLP4 372
INDIRU4
CVUU1 4
ASGNU1
ADDRGP4 $702
JUMPV
LABELV $701
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 9
NEI4 $825
ADDRFP4 0
INDIRP4
CNSTI4 48
ADDP4
INDIRI4
CNSTI4 2
NEI4 $827
ADDRLP4 256
CNSTF4 1065353216
ASGNF4
ADDRLP4 184
ADDRLP4 256
INDIRF4
ASGNF4
ADDRLP4 184+4
ADDRLP4 256
INDIRF4
ASGNF4
ADDRLP4 184+8
CNSTF4 1065353216
ASGNF4
ADDRGP4 $828
JUMPV
LABELV $827
ADDRLP4 260
CNSTF4 1056964608
ASGNF4
ADDRLP4 184
ADDRLP4 260
INDIRF4
ASGNF4
ADDRLP4 184+4
ADDRLP4 260
INDIRF4
ASGNF4
ADDRLP4 184+8
CNSTF4 1056964608
ASGNF4
LABELV $828
ADDRLP4 268
ADDRFP4 0
INDIRP4
CNSTI4 4
ADDP4
ASGNP4
ADDRLP4 232
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRLP4 268
INDIRP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 236
ADDRFP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 268
INDIRP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 200
ADDRLP4 232
INDIRF4
ADDRLP4 236
INDIRF4
DIVF4
ASGNF4
ADDRLP4 272
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
ASGNF4
ADDRLP4 276
ADDRLP4 200
INDIRF4
ASGNF4
ADDRLP4 280
ADDRFP4 0
INDIRP4
CNSTI4 84
ADDP4
ASGNP4
ADDRLP4 196
ADDRLP4 272
INDIRF4
ADDRLP4 276
INDIRF4
ADDRLP4 280
INDIRP4
INDIRF4
ADDRLP4 272
INDIRF4
SUBF4
MULF4
ADDF4
ASGNF4
ADDRLP4 284
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
ASGNF4
ADDRLP4 180
ADDRLP4 284
INDIRF4
ADDRLP4 276
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 80
ADDP4
INDIRF4
ADDRLP4 284
INDIRF4
SUBF4
MULF4
ADDF4
ASGNF4
ADDRLP4 196
INDIRF4
ADDRLP4 280
INDIRP4
INDIRF4
LEF4 $834
ADDRLP4 196
ADDRFP4 0
INDIRP4
CNSTI4 84
ADDP4
INDIRF4
ASGNF4
LABELV $834
ADDRLP4 180
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 80
ADDP4
INDIRF4
LEF4 $836
ADDRLP4 180
ADDRFP4 0
INDIRP4
CNSTI4 80
ADDP4
INDIRF4
ASGNF4
LABELV $836
CNSTF4 1078530011
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CVIF4 4
MULF4
CNSTF4 1127481344
DIVF4
ARGF4
ADDRLP4 288
ADDRGP4 qk_sin
CALLF4
ASGNF4
CNSTF4 1073741824
ARGF4
ADDRLP4 292
ADDRGP4 qk_sqrt
CALLF4
ASGNF4
ADDRLP4 248
ADDRLP4 180
INDIRF4
ADDRLP4 288
INDIRF4
MULF4
ADDRLP4 292
INDIRF4
MULF4
ASGNF4
CNSTF4 1078530011
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CVIF4 4
MULF4
CNSTF4 1127481344
DIVF4
ARGF4
ADDRLP4 296
ADDRGP4 qk_cos
CALLF4
ASGNF4
CNSTF4 1073741824
ARGF4
ADDRLP4 300
ADDRGP4 qk_sqrt
CALLF4
ASGNF4
ADDRLP4 252
ADDRLP4 196
INDIRF4
ADDRLP4 296
INDIRF4
MULF4
ADDRLP4 300
INDIRF4
MULF4
ASGNF4
ADDRLP4 12
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 12
ADDRLP4 12
INDIRF4
ADDRLP4 248
INDIRF4
SUBF4
ASGNF4
ADDRLP4 12+4
ADDRLP4 12+4
INDIRF4
ADDRLP4 252
INDIRF4
SUBF4
ASGNF4
ADDRLP4 12+12
CNSTF4 0
ASGNF4
ADDRLP4 12+12+4
CNSTF4 0
ASGNF4
ADDRLP4 308
CNSTF4 1132396544
ADDRLP4 184
INDIRF4
MULF4
ASGNF4
ADDRLP4 312
CNSTF4 1325400064
ASGNF4
ADDRLP4 308
INDIRF4
ADDRLP4 312
INDIRF4
LTF4 $844
ADDRLP4 304
ADDRLP4 308
INDIRF4
ADDRLP4 312
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $845
JUMPV
LABELV $844
ADDRLP4 304
ADDRLP4 308
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $845
ADDRLP4 12+20
ADDRLP4 304
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 320
CNSTF4 1132396544
ADDRLP4 184+4
INDIRF4
MULF4
ASGNF4
ADDRLP4 324
CNSTF4 1325400064
ASGNF4
ADDRLP4 320
INDIRF4
ADDRLP4 324
INDIRF4
LTF4 $850
ADDRLP4 316
ADDRLP4 320
INDIRF4
ADDRLP4 324
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $851
JUMPV
LABELV $850
ADDRLP4 316
ADDRLP4 320
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $851
ADDRLP4 12+20+1
ADDRLP4 316
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 332
CNSTF4 1132396544
ADDRLP4 184+8
INDIRF4
MULF4
ASGNF4
ADDRLP4 336
CNSTF4 1325400064
ASGNF4
ADDRLP4 332
INDIRF4
ADDRLP4 336
INDIRF4
LTF4 $856
ADDRLP4 328
ADDRLP4 332
INDIRF4
ADDRLP4 336
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $857
JUMPV
LABELV $856
ADDRLP4 328
ADDRLP4 332
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $857
ADDRLP4 12+20+2
ADDRLP4 328
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 12+20+3
CNSTU1 255
ASGNU1
ADDRLP4 12+24
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 12+24
ADDRLP4 12+24
INDIRF4
ADDRLP4 252
INDIRF4
SUBF4
ASGNF4
ADDRLP4 12+24+4
ADDRLP4 12+24+4
INDIRF4
ADDRLP4 248
INDIRF4
ADDF4
ASGNF4
ADDRLP4 12+24+12
CNSTF4 0
ASGNF4
ADDRLP4 12+24+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 344
CNSTF4 1132396544
ADDRLP4 184
INDIRF4
MULF4
ASGNF4
ADDRLP4 348
CNSTF4 1325400064
ASGNF4
ADDRLP4 344
INDIRF4
ADDRLP4 348
INDIRF4
LTF4 $872
ADDRLP4 340
ADDRLP4 344
INDIRF4
ADDRLP4 348
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $873
JUMPV
LABELV $872
ADDRLP4 340
ADDRLP4 344
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $873
ADDRLP4 12+24+20
ADDRLP4 340
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 356
CNSTF4 1132396544
ADDRLP4 184+4
INDIRF4
MULF4
ASGNF4
ADDRLP4 360
CNSTF4 1325400064
ASGNF4
ADDRLP4 356
INDIRF4
ADDRLP4 360
INDIRF4
LTF4 $879
ADDRLP4 352
ADDRLP4 356
INDIRF4
ADDRLP4 360
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $880
JUMPV
LABELV $879
ADDRLP4 352
ADDRLP4 356
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $880
ADDRLP4 12+24+20+1
ADDRLP4 352
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 368
CNSTF4 1132396544
ADDRLP4 184+8
INDIRF4
MULF4
ASGNF4
ADDRLP4 372
CNSTF4 1325400064
ASGNF4
ADDRLP4 368
INDIRF4
ADDRLP4 372
INDIRF4
LTF4 $886
ADDRLP4 364
ADDRLP4 368
INDIRF4
ADDRLP4 372
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $887
JUMPV
LABELV $886
ADDRLP4 364
ADDRLP4 368
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $887
ADDRLP4 12+24+20+2
ADDRLP4 364
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 12+24+20+3
CNSTU1 255
ASGNU1
ADDRLP4 12+48
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 12+48
ADDRLP4 12+48
INDIRF4
ADDRLP4 248
INDIRF4
ADDF4
ASGNF4
ADDRLP4 12+48+4
ADDRLP4 12+48+4
INDIRF4
ADDRLP4 252
INDIRF4
ADDF4
ASGNF4
ADDRLP4 12+48+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 380
CNSTF4 1132396544
ADDRLP4 184
INDIRF4
MULF4
ASGNF4
ADDRLP4 384
CNSTF4 1325400064
ASGNF4
ADDRLP4 380
INDIRF4
ADDRLP4 384
INDIRF4
LTF4 $903
ADDRLP4 376
ADDRLP4 380
INDIRF4
ADDRLP4 384
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $904
JUMPV
LABELV $903
ADDRLP4 376
ADDRLP4 380
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $904
ADDRLP4 12+48+20
ADDRLP4 376
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 392
CNSTF4 1132396544
ADDRLP4 184+4
INDIRF4
MULF4
ASGNF4
ADDRLP4 396
CNSTF4 1325400064
ASGNF4
ADDRLP4 392
INDIRF4
ADDRLP4 396
INDIRF4
LTF4 $910
ADDRLP4 388
ADDRLP4 392
INDIRF4
ADDRLP4 396
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $911
JUMPV
LABELV $910
ADDRLP4 388
ADDRLP4 392
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $911
ADDRLP4 12+48+20+1
ADDRLP4 388
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 404
CNSTF4 1132396544
ADDRLP4 184+8
INDIRF4
MULF4
ASGNF4
ADDRLP4 408
CNSTF4 1325400064
ASGNF4
ADDRLP4 404
INDIRF4
ADDRLP4 408
INDIRF4
LTF4 $917
ADDRLP4 400
ADDRLP4 404
INDIRF4
ADDRLP4 408
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $918
JUMPV
LABELV $917
ADDRLP4 400
ADDRLP4 404
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $918
ADDRLP4 12+48+20+2
ADDRLP4 400
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 12+48+20+3
CNSTU1 255
ASGNU1
ADDRLP4 12+72
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 12+72
ADDRLP4 12+72
INDIRF4
ADDRLP4 252
INDIRF4
ADDF4
ASGNF4
ADDRLP4 12+72+4
ADDRLP4 12+72+4
INDIRF4
ADDRLP4 248
INDIRF4
SUBF4
ASGNF4
ADDRLP4 12+72+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+72+12+4
CNSTF4 0
ASGNF4
ADDRLP4 416
CNSTF4 1132396544
ADDRLP4 184
INDIRF4
MULF4
ASGNF4
ADDRLP4 420
CNSTF4 1325400064
ASGNF4
ADDRLP4 416
INDIRF4
ADDRLP4 420
INDIRF4
LTF4 $934
ADDRLP4 412
ADDRLP4 416
INDIRF4
ADDRLP4 420
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $935
JUMPV
LABELV $934
ADDRLP4 412
ADDRLP4 416
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $935
ADDRLP4 12+72+20
ADDRLP4 412
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 428
CNSTF4 1132396544
ADDRLP4 184+4
INDIRF4
MULF4
ASGNF4
ADDRLP4 432
CNSTF4 1325400064
ASGNF4
ADDRLP4 428
INDIRF4
ADDRLP4 432
INDIRF4
LTF4 $941
ADDRLP4 424
ADDRLP4 428
INDIRF4
ADDRLP4 432
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $942
JUMPV
LABELV $941
ADDRLP4 424
ADDRLP4 428
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $942
ADDRLP4 12+72+20+1
ADDRLP4 424
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 440
CNSTF4 1132396544
ADDRLP4 184+8
INDIRF4
MULF4
ASGNF4
ADDRLP4 444
CNSTF4 1325400064
ASGNF4
ADDRLP4 440
INDIRF4
ADDRLP4 444
INDIRF4
LTF4 $948
ADDRLP4 436
ADDRLP4 440
INDIRF4
ADDRLP4 444
INDIRF4
SUBF4
CVFI4 4
CVIU4 4
CNSTU4 2147483648
ADDU4
ASGNU4
ADDRGP4 $949
JUMPV
LABELV $948
ADDRLP4 436
ADDRLP4 440
INDIRF4
CVFI4 4
CVIU4 4
ASGNU4
LABELV $949
ADDRLP4 12+72+20+2
ADDRLP4 436
INDIRU4
CVUU1 4
ASGNU1
ADDRLP4 12+72+20+3
CNSTU1 255
ASGNU1
ADDRGP4 $826
JUMPV
LABELV $825
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 2
NEI4 $953
ADDRLP4 12
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 12
ADDRLP4 12
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 12+4
ADDRLP4 12+4
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 12+12
CNSTF4 0
ASGNF4
ADDRLP4 12+12+4
CNSTF4 0
ASGNF4
ADDRLP4 12+20
CNSTU1 255
ASGNU1
ADDRLP4 12+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+20+3
CNSTU1 255
ASGNU1
ADDRLP4 12+24
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 12+24
ADDRLP4 12+24
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 12+24+4
ADDRLP4 12+24+4
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
ADDF4
ASGNF4
ADDRLP4 12+24+12
CNSTF4 0
ASGNF4
ADDRLP4 12+24+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+24+20
CNSTU1 255
ASGNU1
ADDRLP4 12+24+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+24+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+24+20+3
CNSTU1 255
ASGNU1
ADDRLP4 12+48
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 12+48
ADDRLP4 12+48
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
ADDF4
ASGNF4
ADDRLP4 12+48+4
ADDRLP4 12+48+4
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
ADDF4
ASGNF4
ADDRLP4 12+48+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+20
CNSTU1 255
ASGNU1
ADDRLP4 12+48+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+48+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+48+20+3
CNSTU1 255
ASGNU1
ADDRLP4 12+72
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 12+72
ADDRLP4 12+72
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
ADDF4
ASGNF4
ADDRLP4 12+72+4
ADDRLP4 12+72+4
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 12+72+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+72+12+4
CNSTF4 0
ASGNF4
ADDRLP4 12+72+20
CNSTU1 255
ASGNU1
ADDRLP4 12+72+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+72+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+72+20+3
CNSTU1 255
ASGNU1
ADDRGP4 $954
JUMPV
LABELV $953
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 6
NEI4 $1026
ADDRLP4 296
ADDRFP4 0
INDIRP4
CNSTI4 4
ADDP4
ASGNP4
ADDRLP4 232
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRLP4 296
INDIRP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 236
ADDRFP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 296
INDIRP4
INDIRF4
SUBF4
ASGNF4
ADDRLP4 200
ADDRLP4 232
INDIRF4
ADDRLP4 236
INDIRF4
DIVF4
ASGNF4
ADDRLP4 200
INDIRF4
CNSTF4 1065353216
LTF4 $1029
ADDRLP4 200
CNSTF4 1065351538
ASGNF4
LABELV $1029
ADDRLP4 304
ADDRFP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
ASGNF4
ADDRLP4 308
ADDRLP4 200
INDIRF4
ASGNF4
ADDRLP4 196
ADDRLP4 304
INDIRF4
ADDRLP4 308
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 84
ADDP4
INDIRF4
ADDRLP4 304
INDIRF4
SUBF4
MULF4
ADDF4
ASGNF4
ADDRLP4 312
ADDRFP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
ASGNF4
ADDRLP4 180
ADDRLP4 312
INDIRF4
ADDRLP4 308
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 80
ADDP4
INDIRF4
ADDRLP4 312
INDIRF4
SUBF4
MULF4
ADDF4
ASGNF4
ADDRGP4 cg+36
INDIRP4
CNSTI4 64
ADDP4
ARGP4
ADDRFP4 4
INDIRP4
ARGP4
ADDRLP4 316
ADDRGP4 Distance
CALLF4
ASGNF4
ADDRLP4 316
INDIRF4
ADDRLP4 196
INDIRF4
CNSTF4 1069547520
DIVF4
GEF4 $1031
ADDRGP4 $91
JUMPV
LABELV $1031
ADDRLP4 320
ADDRFP4 0
INDIRP4
CNSTI4 112
ADDP4
ASGNP4
ADDRLP4 272
ADDRLP4 320
INDIRP4
INDIRI4
ASGNI4
ADDRLP4 200
INDIRF4
ADDRLP4 320
INDIRP4
INDIRI4
CNSTI4 2
LSHI4
ADDRGP4 shaderAnimCounts
ADDP4
INDIRI4
CVIF4 4
MULF4
ARGF4
ADDRLP4 324
ADDRGP4 qk_floor
CALLF4
ASGNF4
ADDRLP4 276
ADDRLP4 324
INDIRF4
CVFI4 4
ASGNI4
ADDRFP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRLP4 276
INDIRI4
CNSTI4 2
LSHI4
ADDRLP4 272
INDIRI4
CNSTI4 8
LSHI4
ADDRGP4 shaderAnims
ADDP4
ADDP4
INDIRI4
ASGNI4
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CNSTI4 0
EQI4 $1034
ADDRGP4 cg+109032+36
ARGP4
ADDRLP4 280
ARGP4
ADDRGP4 vectoangles
CALLV
pop
ADDRLP4 280+8
ADDRLP4 280+8
INDIRF4
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CVIF4 4
ADDF4
ASGNF4
ADDRLP4 280
ARGP4
CNSTP4 0
ARGP4
ADDRLP4 260
ARGP4
ADDRLP4 248
ARGP4
ADDRGP4 AngleVectors
CALLV
pop
LABELV $1034
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CNSTI4 0
EQI4 $1039
ADDRLP4 332
ADDRLP4 180
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRLP4 248
INDIRF4
ADDRLP4 332
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRLP4 248+4
INDIRF4
ADDRLP4 332
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRLP4 248+8
INDIRF4
ADDRLP4 180
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 336
ADDRLP4 196
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 260
INDIRF4
ADDRLP4 336
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 260+4
INDIRF4
ADDRLP4 336
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 260+8
INDIRF4
ADDRLP4 196
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $1040
JUMPV
LABELV $1039
ADDRLP4 332
ADDRLP4 180
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRFP4 4
INDIRP4
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 332
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 332
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ADDRGP4 vup+8
INDIRF4
ADDRLP4 180
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
ADDRLP4 336
ADDRLP4 196
INDIRF4
NEGF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 336
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 336
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
ADDRLP4 196
INDIRF4
NEGF4
MULF4
ADDF4
ASGNF4
LABELV $1040
ADDRLP4 12
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+12
CNSTF4 0
ASGNF4
ADDRLP4 12+12+4
CNSTF4 0
ASGNF4
ADDRLP4 12+20
CNSTU1 255
ASGNU1
ADDRLP4 12+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+20+3
CNSTU1 255
ASGNU1
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CNSTI4 0
EQI4 $1071
ADDRLP4 328
CNSTF4 1073741824
ADDRLP4 180
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 248
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 248+4
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 248+8
INDIRF4
CNSTF4 1073741824
ADDRLP4 180
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $1072
JUMPV
LABELV $1071
ADDRLP4 328
CNSTF4 1073741824
ADDRLP4 180
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vup+8
INDIRF4
CNSTF4 1073741824
ADDRLP4 180
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
LABELV $1072
ADDRLP4 12+24
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+24+12
CNSTF4 0
ASGNF4
ADDRLP4 12+24+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+24+20
CNSTU1 255
ASGNU1
ADDRLP4 12+24+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+24+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+24+20+3
CNSTU1 255
ASGNU1
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CNSTI4 0
EQI4 $1102
ADDRLP4 328
CNSTF4 1073741824
ADDRLP4 196
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 260
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 260+4
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 260+8
INDIRF4
CNSTF4 1073741824
ADDRLP4 196
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $1103
JUMPV
LABELV $1102
ADDRLP4 328
CNSTF4 1073741824
ADDRLP4 196
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vright
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vright+4
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vright+8
INDIRF4
CNSTF4 1073741824
ADDRLP4 196
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
LABELV $1103
ADDRLP4 12+48
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+48+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+12+4
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+48+20
CNSTU1 255
ASGNU1
ADDRLP4 12+48+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+48+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+48+20+3
CNSTU1 255
ASGNU1
ADDRFP4 0
INDIRP4
CNSTI4 116
ADDP4
INDIRI4
CNSTI4 0
EQI4 $1133
ADDRLP4 328
CNSTF4 3221225472
ADDRLP4 180
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRLP4 248
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 248+4
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRLP4 248+8
INDIRF4
CNSTF4 3221225472
ADDRLP4 180
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $1134
JUMPV
LABELV $1133
ADDRLP4 328
CNSTF4 3221225472
ADDRLP4 180
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
ADDRLP4 0
INDIRF4
ADDRGP4 vup
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 0+4
INDIRF4
ADDRGP4 vup+4
INDIRF4
ADDRLP4 328
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 0+8
INDIRF4
ADDRGP4 vup+8
INDIRF4
CNSTF4 3221225472
ADDRLP4 180
INDIRF4
MULF4
MULF4
ADDF4
ASGNF4
LABELV $1134
ADDRLP4 12+72
ADDRLP4 0
INDIRB
ASGNB 12
ADDRLP4 12+72+12
CNSTF4 1065353216
ASGNF4
ADDRLP4 12+72+12+4
CNSTF4 0
ASGNF4
ADDRLP4 12+72+20
CNSTU1 255
ASGNU1
ADDRLP4 12+72+20+1
CNSTU1 255
ASGNU1
ADDRLP4 12+72+20+2
CNSTU1 255
ASGNU1
ADDRLP4 12+72+20+3
CNSTU1 255
ASGNU1
LABELV $1026
LABELV $954
LABELV $826
LABELV $702
LABELV $456
LABELV $321
LABELV $93
ADDRFP4 0
INDIRP4
CNSTI4 68
ADDP4
INDIRI4
CNSTI4 0
NEI4 $1164
ADDRGP4 $91
JUMPV
LABELV $1164
ADDRLP4 248
ADDRFP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
ASGNI4
ADDRLP4 248
INDIRI4
CNSTI4 1
EQI4 $1169
ADDRLP4 248
INDIRI4
CNSTI4 5
EQI4 $1169
ADDRLP4 248
INDIRI4
CNSTI4 11
NEI4 $1166
LABELV $1169
ADDRFP4 0
INDIRP4
CNSTI4 68
ADDP4
INDIRI4
ARGI4
CNSTI4 3
ARGI4
ADDRLP4 108
ARGP4
ADDRGP4 trap_R_AddPolyToScene
CALLV
pop
ADDRGP4 $1167
JUMPV
LABELV $1166
ADDRFP4 0
INDIRP4
CNSTI4 68
ADDP4
INDIRI4
ARGI4
CNSTI4 4
ARGI4
ADDRLP4 12
ARGP4
ADDRGP4 trap_R_AddPolyToScene
CALLV
pop
LABELV $1167
LABELV $91
endproc CG_AddParticleToScene 476 16
data
align 4
LABELV roll
byte 4 0
export CG_AddParticles
code
proc CG_AddParticles 92 16
ADDRGP4 initparticles
INDIRI4
CNSTI4 0
NEI4 $1171
ADDRGP4 CG_ClearParticles
CALLV
pop
LABELV $1171
ADDRGP4 vforward
ADDRGP4 cg+109032+36
INDIRB
ASGNB 12
ADDRGP4 vright
ADDRGP4 cg+109032+36+12
INDIRB
ASGNB 12
ADDRGP4 vup
ADDRGP4 cg+109032+36+24
INDIRB
ASGNB 12
ADDRGP4 cg+109032+36
ARGP4
ADDRLP4 40
ARGP4
ADDRGP4 vectoangles
CALLV
pop
ADDRLP4 52
ADDRGP4 roll
ASGNP4
ADDRLP4 52
INDIRP4
ADDRLP4 52
INDIRP4
INDIRF4
CNSTF4 1036831949
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRGP4 oldtime
INDIRF4
SUBF4
MULF4
ADDF4
ASGNF4
ADDRLP4 40+8
ADDRLP4 40+8
INDIRF4
CNSTF4 1063675494
ADDRLP4 52
INDIRP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 40
ARGP4
ADDRGP4 rforward
ARGP4
ADDRGP4 rright
ARGP4
ADDRGP4 rup
ARGP4
ADDRGP4 AngleVectors
CALLV
pop
ADDRGP4 oldtime
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 56
CNSTP4 0
ASGNP4
ADDRLP4 36
ADDRLP4 56
INDIRP4
ASGNP4
ADDRLP4 28
ADDRLP4 56
INDIRP4
ASGNP4
ADDRLP4 0
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 $1189
JUMPV
LABELV $1186
ADDRLP4 32
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 4
CNSTF4 981668463
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
SUBF4
MULF4
ASGNF4
ADDRLP4 8
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
INDIRF4
ADDRLP4 4
INDIRF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 8
INDIRF4
CNSTF4 0
GTF4 $1191
ADDRLP4 0
INDIRP4
ADDRGP4 free_particles
INDIRP4
ASGNP4
ADDRGP4 free_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 0
ASGNF4
ADDRGP4 $1187
JUMPV
LABELV $1191
ADDRLP4 64
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
ASGNI4
ADDRLP4 64
INDIRI4
CNSTI4 3
EQI4 $1197
ADDRLP4 64
INDIRI4
CNSTI4 6
EQI4 $1197
ADDRLP4 64
INDIRI4
CNSTI4 8
EQI4 $1197
ADDRLP4 64
INDIRI4
CNSTI4 12
NEI4 $1193
LABELV $1197
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
LEF4 $1198
ADDRLP4 0
INDIRP4
ADDRGP4 free_particles
INDIRP4
ASGNP4
ADDRGP4 free_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 0
ASGNF4
ADDRGP4 $1187
JUMPV
LABELV $1198
LABELV $1193
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 11
NEI4 $1201
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
LEF4 $1203
ADDRLP4 0
INDIRP4
ADDRGP4 free_particles
INDIRP4
ASGNP4
ADDRGP4 free_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 0
ASGNF4
ADDRGP4 $1187
JUMPV
LABELV $1203
LABELV $1201
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 10
NEI4 $1206
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
LEF4 $1208
ADDRLP4 0
INDIRP4
ADDRGP4 free_particles
INDIRP4
ASGNP4
ADDRGP4 free_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 0
ASGNF4
ADDRGP4 $1187
JUMPV
LABELV $1208
LABELV $1206
ADDRLP4 68
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
ASGNI4
ADDRLP4 68
INDIRI4
CNSTI4 7
EQI4 $1213
ADDRLP4 68
INDIRI4
CNSTI4 15
NEI4 $1211
LABELV $1213
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
CNSTF4 0
GEF4 $1211
ADDRLP4 0
INDIRP4
ARGP4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ARGP4
ADDRLP4 8
INDIRF4
ARGF4
ADDRGP4 CG_AddParticleToScene
CALLV
pop
ADDRLP4 0
INDIRP4
ADDRGP4 free_particles
INDIRP4
ASGNP4
ADDRGP4 free_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 0
ASGNF4
ADDRGP4 $1187
JUMPV
LABELV $1211
ADDRLP4 0
INDIRP4
CNSTP4 0
ASGNP4
ADDRLP4 28
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1214
ADDRLP4 28
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 36
ADDRLP4 0
INDIRP4
ASGNP4
ADDRGP4 $1215
JUMPV
LABELV $1214
ADDRLP4 28
INDIRP4
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 28
ADDRLP4 0
INDIRP4
ASGNP4
LABELV $1215
ADDRLP4 8
INDIRF4
CNSTF4 1065353216
LEF4 $1216
ADDRLP4 8
CNSTF4 1065353216
ASGNF4
LABELV $1216
ADDRLP4 12
ADDRLP4 4
INDIRF4
ADDRLP4 4
INDIRF4
MULF4
ASGNF4
ADDRLP4 16
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
INDIRF4
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
INDIRF4
ADDRLP4 4
INDIRF4
MULF4
ADDF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
INDIRF4
ADDRLP4 12
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 16+4
ADDRLP4 0
INDIRP4
CNSTI4 16
ADDP4
INDIRF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
INDIRF4
ADDRLP4 4
INDIRF4
MULF4
ADDF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
INDIRF4
ADDRLP4 12
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 16+8
ADDRLP4 0
INDIRP4
CNSTI4 20
ADDP4
INDIRF4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
INDIRF4
ADDRLP4 4
INDIRF4
MULF4
ADDF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
INDIRF4
ADDRLP4 12
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0
INDIRP4
ARGP4
ADDRLP4 16
ARGP4
ADDRLP4 8
INDIRF4
ARGF4
ADDRGP4 CG_AddParticleToScene
CALLV
pop
LABELV $1187
ADDRLP4 0
ADDRLP4 32
INDIRP4
ASGNP4
LABELV $1189
ADDRLP4 0
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1186
ADDRGP4 active_particles
ADDRLP4 36
INDIRP4
ASGNP4
LABELV $1170
endproc CG_AddParticles 92 16
export CG_ParticleSnowFlurry
proc CG_ParticleSnowFlurry 80 4
ADDRFP4 4
ADDRFP4 4
INDIRP4
ASGNP4
ADDRLP4 4
CNSTI4 1
ASGNI4
ADDRFP4 0
INDIRI4
CNSTI4 0
NEI4 $1221
ADDRGP4 $1223
ARGP4
ADDRGP4 CG_Printf
CALLV
pop
LABELV $1221
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1224
ADDRGP4 $1220
JUMPV
LABELV $1224
ADDRLP4 8
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 8
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 8
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1063675494
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 88
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 104
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 92
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 108
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 4
INDIRP4
CNSTI4 84
ADDP4
INDIRI4
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 4
INDIRP4
CNSTI4 88
ADDP4
INDIRI4
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRFP4 0
INDIRI4
ASGNI4
ADDRLP4 20
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 20
INDIRI4
CNSTI4 100
MODI4
CNSTI4 90
LEI4 $1229
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1107296256
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1107296256
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1036831949
ASGNF4
ADDRGP4 $1230
JUMPV
LABELV $1229
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1065353216
ASGNF4
LABELV $1230
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 3248488448
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 11
ASGNI4
ADDRLP4 4
INDIRI4
CNSTI4 0
EQI4 $1231
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 3240099840
ASGNF4
LABELV $1231
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 92
ADDP4
INDIRB
ASGNB 12
ADDRLP4 24
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ASGNP4
ADDRLP4 24
INDIRP4
ADDRLP4 24
INDIRP4
INDIRF4
ASGNF4
ADDRLP4 28
ADDRLP4 0
INDIRP4
CNSTI4 16
ADDP4
ASGNP4
ADDRLP4 28
INDIRP4
ADDRLP4 28
INDIRP4
INDIRF4
ASGNF4
ADDRLP4 32
ADDRLP4 0
INDIRP4
CNSTI4 20
ADDP4
ASGNP4
ADDRLP4 32
INDIRP4
ADDRLP4 32
INDIRP4
INDIRF4
ASGNF4
ADDRLP4 40
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
ADDRLP4 40
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
ADDRLP4 40
INDIRF4
ASGNF4
ADDRLP4 48
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 48
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 48
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 48
INDIRF4
ASGNF4
ADDRLP4 52
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 56
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
ASGNP4
ADDRLP4 56
INDIRP4
ADDRLP4 56
INDIRP4
INDIRF4
CNSTF4 1107296256
ADDRFP4 4
INDIRP4
CNSTI4 116
ADDP4
INDIRF4
MULF4
CNSTF4 1098907648
CNSTF4 1073741824
ADDRLP4 52
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ADDF4
ADDF4
ASGNF4
ADDRLP4 60
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 64
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
ASGNP4
ADDRLP4 64
INDIRP4
ADDRLP4 64
INDIRP4
INDIRF4
CNSTF4 1107296256
ADDRFP4 4
INDIRP4
CNSTI4 120
ADDP4
INDIRF4
MULF4
CNSTF4 1098907648
CNSTF4 1073741824
ADDRLP4 60
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ADDF4
ADDF4
ASGNF4
ADDRLP4 68
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
ASGNP4
ADDRLP4 68
INDIRP4
ADDRLP4 68
INDIRP4
INDIRF4
ADDRFP4 4
INDIRP4
CNSTI4 124
ADDP4
INDIRF4
ADDF4
ASGNF4
ADDRLP4 4
INDIRI4
CNSTI4 0
EQI4 $1233
ADDRLP4 72
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
CNSTF4 1098907648
CNSTF4 1073741824
ADDRLP4 72
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
ADDRLP4 76
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
CNSTF4 1098907648
CNSTF4 1073741824
ADDRLP4 76
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
LABELV $1233
LABELV $1220
endproc CG_ParticleSnowFlurry 80 4
export CG_ParticleSnow
proc CG_ParticleSnow 68 4
ADDRFP4 0
INDIRI4
CNSTI4 0
NEI4 $1236
ADDRGP4 $1238
ARGP4
ADDRGP4 CG_Printf
CALLV
pop
LABELV $1236
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1239
ADDRGP4 $1235
JUMPV
LABELV $1239
ADDRLP4 4
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 4
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1053609165
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 88
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 92
ADDP4
ADDRFP4 8
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRFP4 0
INDIRI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 3259498496
ASGNF4
ADDRFP4 12
INDIRI4
CNSTI4 0
EQI4 $1242
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 5
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 3263299584
ASGNF4
ADDRGP4 $1243
JUMPV
LABELV $1242
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 1
ASGNI4
LABELV $1243
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 16
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 20
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ASGNP4
ADDRLP4 20
INDIRP4
ADDRLP4 20
INDIRP4
INDIRF4
CNSTF4 1073741824
ADDRLP4 16
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
ADDRFP4 16
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 24
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 28
ADDRLP4 0
INDIRP4
CNSTI4 16
ADDP4
ASGNP4
ADDRLP4 28
INDIRP4
ADDRLP4 28
INDIRP4
INDIRF4
CNSTF4 1073741824
ADDRLP4 24
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
ADDRFP4 16
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 32
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 36
ADDRLP4 0
INDIRP4
CNSTI4 20
ADDP4
ASGNP4
ADDRLP4 36
INDIRP4
ADDRLP4 36
INDIRP4
INDIRF4
CNSTF4 1073741824
ADDRLP4 32
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
ADDRLP4 0
INDIRP4
CNSTI4 88
ADDP4
INDIRF4
ADDRLP4 0
INDIRP4
CNSTI4 92
ADDP4
INDIRF4
SUBF4
MULF4
ADDF4
ASGNF4
ADDRLP4 48
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
ADDRLP4 48
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
ADDRLP4 48
INDIRF4
ASGNF4
ADDRLP4 56
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 56
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 56
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 56
INDIRF4
ASGNF4
ADDRFP4 12
INDIRI4
CNSTI4 0
EQI4 $1244
ADDRLP4 60
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
CNSTF4 1098907648
CNSTF4 1073741824
ADDRLP4 60
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
ADDRLP4 64
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
CNSTF4 1098907648
CNSTF4 1073741824
ADDRLP4 64
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
LABELV $1244
ADDRLP4 0
INDIRP4
CNSTI4 104
ADDP4
ADDRFP4 20
INDIRI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 108
ADDP4
CNSTI4 1
ASGNI4
LABELV $1235
endproc CG_ParticleSnow 68 4
export CG_ParticleBubble
proc CG_ParticleBubble 80 4
ADDRFP4 0
INDIRI4
CNSTI4 0
NEI4 $1247
ADDRGP4 $1238
ARGP4
ADDRGP4 CG_Printf
CALLV
pop
LABELV $1247
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1249
ADDRGP4 $1246
JUMPV
LABELV $1249
ADDRLP4 8
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 8
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 8
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1053609165
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 88
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 92
ADDP4
ADDRFP4 8
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRFP4 0
INDIRI4
ASGNI4
ADDRLP4 20
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 4
CNSTF4 1056964608
CNSTF4 1073741824
ADDRLP4 20
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
CNSTF4 1065353216
ADDF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
ADDRLP4 4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
ADDRLP4 4
INDIRF4
ASGNF4
ADDRLP4 24
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 1092616192
CNSTF4 1073741824
ADDRLP4 24
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
CNSTF4 1112014848
ADDF4
ASGNF4
ADDRFP4 12
INDIRI4
CNSTI4 0
EQI4 $1252
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 14
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 1115815936
ASGNF4
ADDRGP4 $1253
JUMPV
LABELV $1252
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 13
ASGNI4
LABELV $1253
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 28
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 32
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ASGNP4
ADDRLP4 32
INDIRP4
ADDRLP4 32
INDIRP4
INDIRF4
CNSTF4 1073741824
ADDRLP4 28
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
ADDRFP4 16
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 36
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 40
ADDRLP4 0
INDIRP4
CNSTI4 16
ADDP4
ASGNP4
ADDRLP4 40
INDIRP4
ADDRLP4 40
INDIRP4
INDIRF4
CNSTF4 1073741824
ADDRLP4 36
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
ADDRFP4 16
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 44
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 48
ADDRLP4 0
INDIRP4
CNSTI4 20
ADDP4
ASGNP4
ADDRLP4 48
INDIRP4
ADDRLP4 48
INDIRP4
INDIRF4
CNSTF4 1073741824
ADDRLP4 44
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
ADDRLP4 0
INDIRP4
CNSTI4 88
ADDP4
INDIRF4
ADDRLP4 0
INDIRP4
CNSTI4 92
ADDP4
INDIRF4
SUBF4
MULF4
ADDF4
ASGNF4
ADDRLP4 60
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
ADDRLP4 60
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
ADDRLP4 60
INDIRF4
ASGNF4
ADDRLP4 68
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 68
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 68
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 68
INDIRF4
ASGNF4
ADDRFP4 12
INDIRI4
CNSTI4 0
EQI4 $1254
ADDRLP4 72
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
CNSTF4 1082130432
CNSTF4 1073741824
ADDRLP4 72
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
ADDRLP4 76
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
CNSTF4 1082130432
CNSTF4 1073741824
ADDRLP4 76
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
LABELV $1254
ADDRLP4 0
INDIRP4
CNSTI4 104
ADDP4
ADDRFP4 20
INDIRI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 108
ADDP4
CNSTI4 1
ASGNI4
LABELV $1246
endproc CG_ParticleBubble 80 4
export CG_ParticleSmoke
proc CG_ParticleSmoke 40 4
ADDRFP4 4
ADDRFP4 4
INDIRP4
ASGNP4
ADDRFP4 0
INDIRI4
CNSTI4 0
NEI4 $1257
ADDRGP4 $1259
ARGP4
ADDRGP4 CG_Printf
CALLV
pop
LABELV $1257
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1260
ADDRGP4 $1256
JUMPV
LABELV $1260
ADDRLP4 4
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 4
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 4
INDIRP4
CNSTI4 84
ADDP4
INDIRI4
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 4
INDIRP4
CNSTI4 88
ADDP4
INDIRI4
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 88
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 100
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 92
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 112
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRFP4 0
INDIRI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 100
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1090519040
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1090519040
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
CNSTF4 1107296256
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
CNSTF4 1107296256
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 3
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 92
ADDP4
INDIRB
ASGNB 12
ADDRLP4 20
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
ADDRLP4 20
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
ADDRLP4 20
INDIRF4
ASGNF4
ADDRLP4 28
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 28
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 28
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 28
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 1084227584
ASGNF4
ADDRFP4 4
INDIRP4
CNSTI4 172
ADDP4
INDIRI4
CNSTI4 1
NEI4 $1265
ADDRLP4 32
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
ASGNP4
ADDRLP4 32
INDIRP4
CNSTF4 3212836864
ADDRLP4 32
INDIRP4
INDIRF4
MULF4
ASGNF4
LABELV $1265
ADDRLP4 36
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
CNSTF4 1082130432
CNSTF4 1073741824
ADDRLP4 36
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
CNSTF4 1090519040
ADDF4
CVFI4 4
ASGNI4
LABELV $1256
endproc CG_ParticleSmoke 40 4
export CG_ParticleBulletDebris
proc CG_ParticleBulletDebris 28 0
ADDRFP4 4
ADDRFP4 4
INDIRP4
ASGNP4
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1268
ADDRGP4 $1267
JUMPV
LABELV $1268
ADDRLP4 4
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 4
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 8
INDIRI4
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 8
INDIRI4
CNSTI4 2
DIVI4
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 3
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1056964608
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1056964608
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
CNSTF4 1056964608
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
CNSTF4 1056964608
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRGP4 cgs+152852+204
INDIRI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 3
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 0
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
ADDRFP4 4
INDIRP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ASGNF4
ADDRLP4 20
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 20
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 20
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 20
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
CNSTF4 3262119936
ASGNF4
ADDRLP4 24
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
ASGNP4
ADDRLP4 24
INDIRP4
ADDRLP4 24
INDIRP4
INDIRF4
CNSTF4 3248488448
ADDF4
ASGNF4
LABELV $1267
endproc CG_ParticleBulletDebris 28 0
export CG_ParticleExplosion
proc CG_ParticleExplosion 28 8
ADDRFP4 0
ADDRFP4 0
INDIRP4
ASGNP4
ADDRFP4 0
INDIRP4
CVPU4 4
CNSTU4 10
GEU4 $1276
ADDRGP4 $1278
ARGP4
ADDRGP4 CG_Error
CALLV
pop
LABELV $1276
ADDRLP4 0
CNSTI4 0
ASGNI4
ADDRGP4 $1282
JUMPV
LABELV $1279
ADDRFP4 0
INDIRP4
ARGP4
ADDRLP4 0
INDIRI4
CNSTI4 2
LSHI4
ADDRGP4 shaderAnimNames
ADDP4
INDIRP4
ARGP4
ADDRLP4 8
ADDRGP4 Q_stricmp
CALLI4
ASGNI4
ADDRLP4 8
INDIRI4
CNSTI4 0
NEI4 $1283
ADDRGP4 $1281
JUMPV
LABELV $1283
LABELV $1280
ADDRLP4 0
ADDRLP4 0
INDIRI4
CNSTI4 1
ADDI4
ASGNI4
LABELV $1282
ADDRLP4 0
INDIRI4
CNSTI4 2
LSHI4
ADDRGP4 shaderAnimNames
ADDP4
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1279
LABELV $1281
ADDRLP4 0
INDIRI4
CNSTI4 2
LSHI4
ADDRGP4 shaderAnimNames
ADDP4
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1285
ADDRGP4 $1287
ARGP4
ADDRFP4 0
INDIRP4
ARGP4
ADDRGP4 CG_Error
CALLV
pop
ADDRGP4 $1275
JUMPV
LABELV $1285
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1288
ADDRGP4 $1275
JUMPV
LABELV $1288
ADDRLP4 8
ADDRGP4 free_particles
ASGNP4
ADDRLP4 4
ADDRLP4 8
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 8
INDIRP4
ADDRLP4 4
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 4
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 4
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1056964608
ASGNF4
ADDRLP4 4
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRFP4 12
INDIRI4
CNSTI4 0
GEI4 $1291
ADDRFP4 12
CNSTI4 -1
ADDRFP4 12
INDIRI4
MULI4
ASGNI4
ADDRLP4 4
INDIRP4
CNSTI4 116
ADDP4
CNSTI4 0
ASGNI4
ADDRGP4 $1292
JUMPV
LABELV $1291
ADDRLP4 20
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 4
INDIRP4
CNSTI4 116
ADDP4
CNSTF4 1127415808
CNSTF4 1073741824
ADDRLP4 20
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
CVFI4 4
ASGNI4
LABELV $1292
ADDRLP4 4
INDIRP4
CNSTI4 112
ADDP4
ADDRLP4 0
INDIRI4
ASGNI4
ADDRLP4 4
INDIRP4
CNSTI4 76
ADDP4
ADDRFP4 16
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 4
INDIRP4
CNSTI4 72
ADDP4
ADDRFP4 16
INDIRI4
CVIF4 4
ADDRLP4 0
INDIRI4
CNSTI4 2
LSHI4
ADDRGP4 shaderAnimSTRatio
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 4
INDIRP4
CNSTI4 80
ADDP4
ADDRFP4 20
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 4
INDIRP4
CNSTI4 84
ADDP4
ADDRFP4 20
INDIRI4
CVIF4 4
ADDRLP4 0
INDIRI4
CNSTI4 2
LSHI4
ADDRGP4 shaderAnimSTRatio
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 4
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 12
INDIRI4
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 4
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 6
ASGNI4
ADDRLP4 4
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 4
INDIRP4
CNSTI4 24
ADDP4
ADDRFP4 8
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 24
CNSTF4 0
ASGNF4
ADDRLP4 4
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 24
INDIRF4
ASGNF4
ADDRLP4 4
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 24
INDIRF4
ASGNF4
ADDRLP4 4
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 24
INDIRF4
ASGNF4
LABELV $1275
endproc CG_ParticleExplosion 28 8
export CG_AddParticleShrapnel
proc CG_AddParticleShrapnel 0 0
LABELV $1294
endproc CG_AddParticleShrapnel 0 0
export CG_NewParticleArea
proc CG_NewParticleArea 92 24
ADDRLP4 40
CNSTF4 0
ASGNF4
ADDRFP4 0
INDIRI4
ARGI4
ADDRLP4 56
ADDRGP4 CG_ConfigString
CALLP4
ASGNP4
ADDRLP4 8
ADDRLP4 56
INDIRP4
ASGNP4
ADDRLP4 8
INDIRP4
INDIRI1
CVII4 1
CNSTI4 0
NEI4 $1296
CNSTI4 0
RETI4
ADDRGP4 $1295
JUMPV
LABELV $1296
ADDRLP4 8
ARGP4
ADDRLP4 60
ADDRGP4 COM_Parse
CALLP4
ASGNP4
ADDRLP4 4
ADDRLP4 60
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ARGP4
ADDRLP4 64
ADDRGP4 qk_atoi
CALLI4
ASGNI4
ADDRLP4 36
ADDRLP4 64
INDIRI4
ASGNI4
ADDRLP4 36
INDIRI4
CNSTI4 1
NEI4 $1298
ADDRLP4 40
CNSTF4 1124073472
ASGNF4
ADDRGP4 $1299
JUMPV
LABELV $1298
ADDRLP4 36
INDIRI4
CNSTI4 2
NEI4 $1300
ADDRLP4 40
CNSTF4 1115684864
ASGNF4
ADDRGP4 $1301
JUMPV
LABELV $1300
ADDRLP4 36
INDIRI4
CNSTI4 3
NEI4 $1302
ADDRLP4 40
CNSTF4 1107296256
ASGNF4
ADDRGP4 $1303
JUMPV
LABELV $1302
ADDRLP4 36
INDIRI4
CNSTI4 0
NEI4 $1304
ADDRLP4 40
CNSTF4 1132462080
ASGNF4
ADDRGP4 $1305
JUMPV
LABELV $1304
ADDRLP4 36
INDIRI4
CNSTI4 4
NEI4 $1306
ADDRLP4 40
CNSTF4 1090519040
ASGNF4
ADDRGP4 $1307
JUMPV
LABELV $1306
ADDRLP4 36
INDIRI4
CNSTI4 5
NEI4 $1308
ADDRLP4 40
CNSTF4 1098907648
ASGNF4
ADDRGP4 $1309
JUMPV
LABELV $1308
ADDRLP4 36
INDIRI4
CNSTI4 6
NEI4 $1310
ADDRLP4 40
CNSTF4 1107296256
ASGNF4
ADDRGP4 $1311
JUMPV
LABELV $1310
ADDRLP4 36
INDIRI4
CNSTI4 7
NEI4 $1312
ADDRLP4 40
CNSTF4 1115684864
ASGNF4
LABELV $1312
LABELV $1311
LABELV $1309
LABELV $1307
LABELV $1305
LABELV $1303
LABELV $1301
LABELV $1299
ADDRLP4 0
CNSTI4 0
ASGNI4
LABELV $1314
ADDRLP4 8
ARGP4
ADDRLP4 68
ADDRGP4 COM_Parse
CALLP4
ASGNP4
ADDRLP4 4
ADDRLP4 68
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ARGP4
ADDRLP4 72
ADDRGP4 qk_atof
CALLF4
ASGNF4
ADDRLP4 0
INDIRI4
CNSTI4 2
LSHI4
ADDRLP4 12
ADDP4
ADDRLP4 72
INDIRF4
ASGNF4
LABELV $1315
ADDRLP4 0
ADDRLP4 0
INDIRI4
CNSTI4 1
ADDI4
ASGNI4
ADDRLP4 0
INDIRI4
CNSTI4 3
LTI4 $1314
ADDRLP4 0
CNSTI4 0
ASGNI4
LABELV $1318
ADDRLP4 8
ARGP4
ADDRLP4 68
ADDRGP4 COM_Parse
CALLP4
ASGNP4
ADDRLP4 4
ADDRLP4 68
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ARGP4
ADDRLP4 72
ADDRGP4 qk_atof
CALLF4
ASGNF4
ADDRLP4 0
INDIRI4
CNSTI4 2
LSHI4
ADDRLP4 24
ADDP4
ADDRLP4 72
INDIRF4
ASGNF4
LABELV $1319
ADDRLP4 0
ADDRLP4 0
INDIRI4
CNSTI4 1
ADDI4
ASGNI4
ADDRLP4 0
INDIRI4
CNSTI4 3
LTI4 $1318
ADDRLP4 8
ARGP4
ADDRLP4 68
ADDRGP4 COM_Parse
CALLP4
ASGNP4
ADDRLP4 4
ADDRLP4 68
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ARGP4
ADDRLP4 72
ADDRGP4 qk_atoi
CALLI4
ASGNI4
ADDRLP4 48
ADDRLP4 72
INDIRI4
ASGNI4
ADDRLP4 8
ARGP4
ADDRLP4 76
ADDRGP4 COM_Parse
CALLP4
ASGNP4
ADDRLP4 4
ADDRLP4 76
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ARGP4
ADDRLP4 80
ADDRGP4 qk_atoi
CALLI4
ASGNI4
ADDRLP4 44
ADDRLP4 80
INDIRI4
ASGNI4
ADDRLP4 8
ARGP4
ADDRLP4 84
ADDRGP4 COM_Parse
CALLP4
ASGNP4
ADDRLP4 4
ADDRLP4 84
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ARGP4
ADDRLP4 88
ADDRGP4 qk_atoi
CALLI4
ASGNI4
ADDRLP4 52
ADDRLP4 88
INDIRI4
ASGNI4
ADDRLP4 0
CNSTI4 0
ASGNI4
ADDRGP4 $1325
JUMPV
LABELV $1322
ADDRLP4 36
INDIRI4
CNSTI4 4
LTI4 $1326
ADDRGP4 cgs+152852+276
INDIRI4
ARGI4
ADDRLP4 12
ARGP4
ADDRLP4 24
ARGP4
ADDRLP4 44
INDIRI4
ARGI4
ADDRLP4 40
INDIRF4
ARGF4
ADDRLP4 52
INDIRI4
ARGI4
ADDRGP4 CG_ParticleBubble
CALLV
pop
ADDRGP4 $1327
JUMPV
LABELV $1326
ADDRGP4 cgs+152852+276
INDIRI4
ARGI4
ADDRLP4 12
ARGP4
ADDRLP4 24
ARGP4
ADDRLP4 44
INDIRI4
ARGI4
ADDRLP4 40
INDIRF4
ARGF4
ADDRLP4 52
INDIRI4
ARGI4
ADDRGP4 CG_ParticleSnow
CALLV
pop
LABELV $1327
LABELV $1323
ADDRLP4 0
ADDRLP4 0
INDIRI4
CNSTI4 1
ADDI4
ASGNI4
LABELV $1325
ADDRLP4 0
INDIRI4
ADDRLP4 48
INDIRI4
LTI4 $1322
CNSTI4 1
RETI4
LABELV $1295
endproc CG_NewParticleArea 92 24
export CG_SnowLink
proc CG_SnowLink 16 0
ADDRLP4 8
ADDRFP4 0
INDIRP4
CNSTI4 172
ADDP4
INDIRI4
ASGNI4
ADDRLP4 0
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 $1336
JUMPV
LABELV $1333
ADDRLP4 4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 12
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
ASGNI4
ADDRLP4 12
INDIRI4
CNSTI4 1
EQI4 $1339
ADDRLP4 12
INDIRI4
CNSTI4 5
NEI4 $1337
LABELV $1339
ADDRLP4 0
INDIRP4
CNSTI4 104
ADDP4
INDIRI4
ADDRLP4 8
INDIRI4
NEI4 $1340
ADDRFP4 4
INDIRI4
CNSTI4 0
EQI4 $1342
ADDRLP4 0
INDIRP4
CNSTI4 108
ADDP4
CNSTI4 1
ASGNI4
ADDRGP4 $1343
JUMPV
LABELV $1342
ADDRLP4 0
INDIRP4
CNSTI4 108
ADDP4
CNSTI4 0
ASGNI4
LABELV $1343
LABELV $1340
LABELV $1337
LABELV $1334
ADDRLP4 0
ADDRLP4 4
INDIRP4
ASGNP4
LABELV $1336
ADDRLP4 0
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1333
LABELV $1332
endproc CG_SnowLink 16 0
export CG_ParticleImpactSmokePuff
proc CG_ParticleImpactSmokePuff 36 4
ADDRFP4 0
INDIRI4
CNSTI4 0
NEI4 $1345
ADDRGP4 $1347
ARGP4
ADDRGP4 CG_Printf
CALLV
pop
LABELV $1345
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1348
ADDRGP4 $1344
JUMPV
LABELV $1348
ADDRLP4 4
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 4
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1048576000
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 16
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
CNSTF4 1127415808
CNSTF4 1073741824
ADDRLP4 16
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
CVFI4 4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRFP4 0
INDIRI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
CNSTI4 1000
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRGP4 cg+107604
INDIRI4
CNSTI4 100
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 20
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
ADDRLP4 20
INDIRI4
CNSTI4 4
MODI4
CNSTI4 8
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 24
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
ADDRLP4 24
INDIRI4
CNSTI4 4
MODI4
CNSTI4 8
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
CNSTF4 1073741824
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
CNSTF4 1073741824
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
CNSTI4 500
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 12
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 1101004800
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
CNSTF4 1101004800
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 100
ADDP4
CNSTI4 1
ASGNI4
LABELV $1344
endproc CG_ParticleImpactSmokePuff 36 4
export CG_Particle_Bleed
proc CG_Particle_Bleed 36 4
ADDRFP4 0
INDIRI4
CNSTI4 0
NEI4 $1355
ADDRGP4 $1357
ARGP4
ADDRGP4 CG_Printf
CALLV
pop
LABELV $1355
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1358
ADDRGP4 $1354
JUMPV
LABELV $1358
ADDRLP4 4
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 4
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRFP4 0
INDIRI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 16
INDIRI4
ADDI4
CVIF4 4
ASGNF4
ADDRFP4 12
INDIRI4
CNSTI4 0
EQI4 $1362
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRGP4 $1363
JUMPV
LABELV $1362
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRGP4 cg+107604
INDIRI4
CNSTI4 100
ADDI4
CVIF4 4
ASGNF4
LABELV $1363
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1082130432
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1082130432
ASGNF4
ADDRLP4 16
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
ADDRLP4 16
INDIRI4
CNSTI4 3
MODI4
CNSTI4 4
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 3
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 3248488448
ASGNF4
ADDRLP4 28
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 28
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 28
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 28
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 100
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 32
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
ADDRLP4 32
INDIRI4
CNSTI4 179
MODI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 2
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1061158912
ASGNF4
LABELV $1354
endproc CG_Particle_Bleed 36 4
export CG_Particle_OilParticle
proc CG_Particle_OilParticle 48 4
ADDRFP4 4
ADDRFP4 4
INDIRP4
ASGNP4
ADDRLP4 16
CNSTF4 1153138688
ASGNF4
ADDRLP4 8
ADDRGP4 cg+107604
INDIRI4
ASGNI4
ADDRLP4 12
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 4
INDIRP4
CNSTI4 84
ADDP4
INDIRI4
ADDI4
ASGNI4
ADDRLP4 4
CNSTF4 1065353216
ADDRLP4 8
INDIRI4
CVIF4 4
ADDRLP4 12
INDIRI4
CVIF4 4
DIVF4
SUBF4
ASGNF4
ADDRFP4 0
INDIRI4
CNSTI4 0
NEI4 $1369
ADDRGP4 $1371
ARGP4
ADDRGP4 CG_Printf
CALLV
pop
LABELV $1369
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1372
ADDRGP4 $1366
JUMPV
LABELV $1372
ADDRLP4 20
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 20
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 20
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRFP4 0
INDIRI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRLP4 16
INDIRF4
ADDF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1077936128
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
CNSTF4 1077936128
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 3
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 92
ADDP4
INDIRB
ASGNB 12
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 104
ADDP4
INDIRF4
CNSTF4 1098907648
ADDRLP4 4
INDIRF4
MULF4
MULF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 108
ADDP4
INDIRF4
CNSTF4 1098907648
ADDRLP4 4
INDIRF4
MULF4
MULF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 112
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 104
ADDP4
CNSTI4 1
ASGNI4
ADDRLP4 40
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 40
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 40
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 40
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
CNSTF4 3248488448
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 100
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 44
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
ADDRLP4 44
INDIRI4
CNSTI4 179
MODI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1061158912
ASGNF4
LABELV $1366
endproc CG_Particle_OilParticle 48 4
export CG_Particle_OilSlick
proc CG_Particle_OilSlick 48 4
ADDRFP4 4
ADDRFP4 4
INDIRP4
ASGNP4
ADDRFP4 0
INDIRI4
CNSTI4 0
NEI4 $1377
ADDRGP4 $1379
ARGP4
ADDRGP4 CG_Printf
CALLV
pop
LABELV $1377
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1380
ADDRGP4 $1376
JUMPV
LABELV $1380
ADDRLP4 4
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 4
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRFP4 4
INDIRP4
CNSTI4 136
ADDP4
INDIRF4
CNSTF4 0
EQF4 $1383
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ADDRFP4 4
INDIRP4
CNSTI4 136
ADDP4
INDIRF4
ADDF4
ASGNF4
ADDRGP4 $1384
JUMPV
LABELV $1383
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
CNSTI4 60000
ADDI4
CVIF4 4
ASGNF4
LABELV $1384
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRFP4 0
INDIRI4
ASGNI4
ADDRLP4 24
CNSTF4 0
ASGNF4
ADDRFP4 4
INDIRP4
CNSTI4 128
ADDP4
INDIRF4
ADDRLP4 24
INDIRF4
NEF4 $1389
ADDRFP4 4
INDIRP4
CNSTI4 132
ADDP4
INDIRF4
ADDRLP4 24
INDIRF4
EQF4 $1387
LABELV $1389
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 128
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 128
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 132
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 132
ADDP4
INDIRF4
ASGNF4
ADDRGP4 $1388
JUMPV
LABELV $1387
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1090519040
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1090519040
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
CNSTF4 1098907648
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
CNSTF4 1098907648
ASGNF4
LABELV $1388
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 9
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 104
ADDP4
CNSTI4 1
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 92
ADDP4
INDIRB
ASGNB 12
ADDRLP4 28
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 32
ADDRLP4 0
INDIRP4
CNSTI4 20
ADDP4
ASGNP4
ADDRLP4 32
INDIRP4
ADDRLP4 32
INDIRP4
INDIRF4
CNSTF4 1056964608
CNSTF4 1073741824
ADDRLP4 28
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
CNSTF4 1057803469
ADDF4
ADDF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 40
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 40
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 40
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 40
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 100
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 44
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
ADDRLP4 44
INDIRI4
CNSTI4 179
MODI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1061158912
ASGNF4
LABELV $1376
endproc CG_Particle_OilSlick 48 4
export CG_OilSlickRemove
proc CG_OilSlickRemove 20 4
ADDRLP4 8
CNSTI4 1
ASGNI4
ADDRLP4 8
INDIRI4
CNSTI4 0
NEI4 $1391
ADDRGP4 $1393
ARGP4
ADDRGP4 CG_Printf
CALLV
pop
LABELV $1391
ADDRLP4 0
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 $1397
JUMPV
LABELV $1394
ADDRLP4 4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
INDIRI4
CNSTI4 9
NEI4 $1398
ADDRLP4 0
INDIRP4
CNSTI4 104
ADDP4
INDIRI4
ADDRLP4 8
INDIRI4
NEI4 $1400
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
CNSTI4 100
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 10
ASGNI4
LABELV $1400
LABELV $1398
LABELV $1395
ADDRLP4 0
ADDRLP4 4
INDIRP4
ASGNP4
LABELV $1397
ADDRLP4 0
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1394
LABELV $1390
endproc CG_OilSlickRemove 20 4
export ValidBloodPool
proc ValidBloodPool 200 28
ADDRFP4 0
ADDRFP4 0
INDIRP4
ASGNP4
ADDRLP4 168
CNSTI4 16
ASGNI4
ADDRLP4 152
ADDRLP4 168
INDIRI4
ASGNI4
ADDRLP4 120
ADDRLP4 168
INDIRI4
ASGNI4
ADDRLP4 172
CNSTF4 0
ASGNF4
ADDRLP4 96
ADDRLP4 172
INDIRF4
ASGNF4
ADDRLP4 96+4
ADDRLP4 172
INDIRF4
ASGNF4
ADDRLP4 96+8
CNSTF4 1065353216
ASGNF4
ADDRLP4 96
ARGP4
ADDRLP4 156
ARGP4
ADDRGP4 vectoangles
CALLV
pop
ADDRLP4 156
ARGP4
CNSTP4 0
ARGP4
ADDRLP4 140
ARGP4
ADDRLP4 108
ARGP4
ADDRGP4 AngleVectors
CALLV
pop
ADDRLP4 180
CNSTF4 1056964608
ASGNF4
ADDRLP4 128
ADDRFP4 0
INDIRP4
INDIRF4
ADDRLP4 180
INDIRF4
ADDRLP4 96
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 128+4
ADDRFP4 0
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ADDRLP4 180
INDIRF4
ADDRLP4 96+4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 128+8
ADDRFP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
CNSTF4 1056964608
ADDRLP4 96+8
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 124
ADDRLP4 152
INDIRI4
NEGI4
CNSTI4 2
DIVI4
ASGNI4
ADDRGP4 $1413
JUMPV
LABELV $1410
ADDRLP4 184
ADDRLP4 124
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 84
ADDRLP4 128
INDIRF4
ADDRLP4 140
INDIRF4
ADDRLP4 184
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 84+4
ADDRLP4 128+4
INDIRF4
ADDRLP4 140+4
INDIRF4
ADDRLP4 184
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 84+8
ADDRLP4 128+8
INDIRF4
ADDRLP4 140+8
INDIRF4
ADDRLP4 124
INDIRI4
CVIF4 4
MULF4
ADDF4
ASGNF4
ADDRLP4 12
ADDRLP4 120
INDIRI4
NEGI4
CNSTI4 2
DIVI4
ASGNI4
ADDRGP4 $1423
JUMPV
LABELV $1420
ADDRLP4 188
ADDRLP4 12
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
ADDRLP4 84
INDIRF4
ADDRLP4 108
INDIRF4
ADDRLP4 188
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+4
ADDRLP4 84+4
INDIRF4
ADDRLP4 108+4
INDIRF4
ADDRLP4 188
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0+8
ADDRLP4 84+8
INDIRF4
ADDRLP4 108+8
INDIRF4
ADDRLP4 12
INDIRI4
CVIF4 4
MULF4
ADDF4
ASGNF4
ADDRLP4 192
CNSTF4 3212836864
ASGNF4
ADDRLP4 16
ADDRLP4 0
INDIRF4
ADDRLP4 192
INDIRF4
ADDRLP4 96
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 16+4
ADDRLP4 0+4
INDIRF4
ADDRLP4 192
INDIRF4
ADDRLP4 96+4
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 16+8
ADDRLP4 0+8
INDIRF4
CNSTF4 3212836864
ADDRLP4 96+8
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 28
ARGP4
ADDRLP4 0
ARGP4
ADDRLP4 196
CNSTP4 0
ASGNP4
ADDRLP4 196
INDIRP4
ARGP4
ADDRLP4 196
INDIRP4
ARGP4
ADDRLP4 16
ARGP4
CNSTI4 -1
ARGI4
CNSTI4 1
ARGI4
ADDRGP4 CG_Trace
CALLV
pop
ADDRLP4 28+52
INDIRI4
CNSTI4 1022
GEI4 $1436
CNSTI4 0
RETI4
ADDRGP4 $1403
JUMPV
LABELV $1436
ADDRLP4 28+4
INDIRI4
CNSTI4 0
NEI4 $1443
ADDRLP4 28+8
INDIRF4
CNSTF4 1065353216
LTF4 $1439
LABELV $1443
CNSTI4 0
RETI4
ADDRGP4 $1403
JUMPV
LABELV $1439
LABELV $1421
ADDRLP4 12
ADDRLP4 12
INDIRI4
ADDRLP4 120
INDIRI4
ADDI4
ASGNI4
LABELV $1423
ADDRLP4 12
INDIRI4
ADDRLP4 120
INDIRI4
LTI4 $1420
LABELV $1411
ADDRLP4 124
ADDRLP4 124
INDIRI4
ADDRLP4 152
INDIRI4
ADDI4
ASGNI4
LABELV $1413
ADDRLP4 124
INDIRI4
ADDRLP4 152
INDIRI4
LTI4 $1410
CNSTI4 1
RETI4
LABELV $1403
endproc ValidBloodPool 200 28
export CG_BloodPool
proc CG_BloodPool 60 4
ADDRFP4 4
INDIRI4
CNSTI4 0
NEI4 $1445
ADDRGP4 $1447
ARGP4
ADDRGP4 CG_Printf
CALLV
pop
LABELV $1445
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1448
ADDRGP4 $1444
JUMPV
LABELV $1448
ADDRLP4 8
ADDRFP4 8
INDIRP4
CNSTI4 12
ADDP4
INDIRB
ASGNB 12
ADDRLP4 8
ARGP4
ADDRLP4 24
ADDRGP4 ValidBloodPool
CALLI4
ASGNI4
ADDRLP4 20
ADDRLP4 24
INDIRI4
ASGNI4
ADDRLP4 20
INDIRI4
CNSTI4 0
NEI4 $1450
ADDRGP4 $1444
JUMPV
LABELV $1450
ADDRLP4 28
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 28
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 28
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
CNSTI4 3000
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRFP4 4
INDIRI4
ASGNI4
ADDRLP4 44
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 4
CNSTF4 1058642330
ADDRLP4 44
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
MULF4
CNSTF4 1053609165
ADDF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1090519040
ADDRLP4 4
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1090519040
ADDRLP4 4
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
CNSTF4 1098907648
ADDRLP4 4
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
CNSTF4 1098907648
ADDRLP4 4
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 9
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRLP4 8
INDIRB
ASGNB 12
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 52
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 52
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 52
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 52
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 100
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 56
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
ADDRLP4 56
INDIRI4
CNSTI4 179
MODI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1061158912
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 2
ASGNI4
LABELV $1444
endproc CG_BloodPool 60 4
export CG_ParticleBloodCloud
proc CG_ParticleBloodCloud 96 16
ADDRFP4 4
ADDRFP4 4
INDIRP4
ASGNP4
ADDRLP4 36
CNSTF4 0
ASGNF4
ADDRFP4 8
INDIRP4
ARGP4
ADDRLP4 56
ADDRGP4 VectorLength
CALLF4
ASGNF4
ADDRLP4 40
ADDRLP4 56
INDIRF4
ASGNF4
ADDRFP4 8
INDIRP4
ARGP4
ADDRLP4 44
ARGP4
ADDRGP4 vectoangles
CALLV
pop
ADDRLP4 44
ARGP4
ADDRLP4 20
ARGP4
ADDRLP4 60
CNSTP4 0
ASGNP4
ADDRLP4 60
INDIRP4
ARGP4
ADDRLP4 60
INDIRP4
ARGP4
ADDRGP4 AngleVectors
CALLV
pop
ADDRLP4 16
CNSTF4 1107296256
ASGNF4
ADDRLP4 40
INDIRF4
CNSTF4 0
EQF4 $1455
ADDRLP4 36
ADDRLP4 40
INDIRF4
ADDRLP4 16
INDIRF4
DIVF4
ASGNF4
LABELV $1455
ADDRLP4 36
INDIRF4
CNSTF4 1065353216
GEF4 $1457
ADDRLP4 36
CNSTF4 1065353216
ASGNF4
LABELV $1457
ADDRLP4 4
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 32
CNSTI4 0
ASGNI4
ADDRGP4 $1462
JUMPV
LABELV $1459
ADDRLP4 4
ADDRLP4 4
INDIRF4
ADDRLP4 20
INDIRF4
ADDRLP4 16
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 4+4
ADDRLP4 4+4
INDIRF4
ADDRLP4 20+4
INDIRF4
ADDRLP4 16
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 4+8
ADDRLP4 4+8
INDIRF4
ADDRLP4 20+8
INDIRF4
ADDRLP4 16
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1469
ADDRGP4 $1454
JUMPV
LABELV $1469
ADDRLP4 68
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 68
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 68
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRGP4 cgs+152852+260
INDIRI4
ASGNI4
ADDRLP4 80
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
CNSTI4 350
ADDI4
CVIF4 4
CNSTF4 1120403456
CNSTF4 1073741824
ADDRLP4 80
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1107296256
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1107296256
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
CNSTF4 1107296256
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
CNSTF4 1107296256
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 3
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 3212836864
ASGNF4
ADDRLP4 88
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 88
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 88
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 88
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 100
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 92
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
ADDRLP4 92
INDIRI4
CNSTI4 179
MODI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 2
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1061158912
ASGNF4
LABELV $1460
ADDRLP4 32
ADDRLP4 32
INDIRI4
CNSTI4 1
ADDI4
ASGNI4
LABELV $1462
ADDRLP4 32
INDIRI4
CVIF4 4
ADDRLP4 36
INDIRF4
LTF4 $1459
LABELV $1454
endproc CG_ParticleBloodCloud 96 16
export CG_ParticleSparks
proc CG_ParticleSparks 72 0
ADDRFP4 4
ADDRFP4 4
INDIRP4
ASGNP4
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1477
ADDRGP4 $1476
JUMPV
LABELV $1477
ADDRLP4 4
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 4
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 8
INDIRI4
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 8
INDIRI4
CNSTI4 2
DIVI4
ADDI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 48
ADDP4
CNSTI4 3
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1053609165
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1056964608
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1056964608
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
CNSTF4 1056964608
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
CNSTF4 1056964608
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRGP4 cgs+152852+204
INDIRI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 3
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 0
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 16
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 20
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ASGNP4
ADDRLP4 20
INDIRP4
ADDRLP4 20
INDIRP4
INDIRF4
CNSTF4 1073741824
ADDRLP4 16
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
ADDRFP4 12
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 24
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 28
ADDRLP4 0
INDIRP4
CNSTI4 16
ADDP4
ASGNP4
ADDRLP4 28
INDIRP4
ADDRLP4 28
INDIRP4
INDIRF4
CNSTF4 1073741824
ADDRLP4 24
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
ADDRFP4 16
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
ADDRFP4 4
INDIRP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 4
ADDP4
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
ADDRFP4 4
INDIRP4
CNSTI4 8
ADDP4
INDIRF4
ASGNF4
ADDRLP4 36
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 36
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 36
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 36
INDIRF4
ASGNF4
ADDRLP4 40
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 44
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
ASGNP4
ADDRLP4 44
INDIRP4
ADDRLP4 44
INDIRP4
INDIRF4
CNSTF4 1082130432
CNSTF4 1073741824
ADDRLP4 40
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ADDF4
ASGNF4
ADDRLP4 48
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 52
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
ASGNP4
ADDRLP4 52
INDIRP4
ADDRLP4 52
INDIRP4
INDIRF4
CNSTF4 1082130432
CNSTF4 1073741824
ADDRLP4 48
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ADDF4
ASGNF4
ADDRLP4 56
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 60
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
ASGNP4
ADDRLP4 60
INDIRP4
ADDRLP4 60
INDIRP4
INDIRF4
CNSTF4 1092616192
CNSTF4 1073741824
ADDRLP4 56
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
CNSTF4 1101004800
ADDF4
ADDRFP4 20
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 64
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
CNSTF4 1082130432
CNSTF4 1073741824
ADDRLP4 64
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
ADDRLP4 68
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
CNSTF4 1082130432
CNSTF4 1073741824
ADDRLP4 68
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
LABELV $1476
endproc CG_ParticleSparks 72 0
export CG_ParticleDust
proc CG_ParticleDust 132 16
ADDRFP4 8
ADDRFP4 8
INDIRP4
ASGNP4
ADDRLP4 40
CNSTF4 0
ASGNF4
ADDRFP4 8
INDIRP4
ADDRFP4 8
INDIRP4
INDIRF4
NEGF4
ASGNF4
ADDRLP4 60
ADDRFP4 8
INDIRP4
CNSTI4 4
ADDP4
ASGNP4
ADDRLP4 60
INDIRP4
ADDRLP4 60
INDIRP4
INDIRF4
NEGF4
ASGNF4
ADDRLP4 64
ADDRFP4 8
INDIRP4
CNSTI4 8
ADDP4
ASGNP4
ADDRLP4 64
INDIRP4
ADDRLP4 64
INDIRP4
INDIRF4
NEGF4
ASGNF4
ADDRFP4 8
INDIRP4
ARGP4
ADDRLP4 68
ADDRGP4 VectorLength
CALLF4
ASGNF4
ADDRLP4 32
ADDRLP4 68
INDIRF4
ASGNF4
ADDRFP4 8
INDIRP4
ARGP4
ADDRLP4 44
ARGP4
ADDRGP4 vectoangles
CALLV
pop
ADDRLP4 44
ARGP4
ADDRLP4 20
ARGP4
ADDRLP4 72
CNSTP4 0
ASGNP4
ADDRLP4 72
INDIRP4
ARGP4
ADDRLP4 72
INDIRP4
ARGP4
ADDRGP4 AngleVectors
CALLV
pop
ADDRLP4 16
CNSTF4 1107296256
ASGNF4
ADDRLP4 32
INDIRF4
CNSTF4 0
EQF4 $1485
ADDRLP4 40
ADDRLP4 32
INDIRF4
ADDRLP4 16
INDIRF4
DIVF4
ASGNF4
LABELV $1485
ADDRLP4 40
INDIRF4
CNSTF4 1065353216
GEF4 $1487
ADDRLP4 40
CNSTF4 1065353216
ASGNF4
LABELV $1487
ADDRLP4 4
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 36
CNSTI4 0
ASGNI4
ADDRGP4 $1492
JUMPV
LABELV $1489
ADDRLP4 4
ADDRLP4 4
INDIRF4
ADDRLP4 20
INDIRF4
ADDRLP4 16
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 4+4
ADDRLP4 4+4
INDIRF4
ADDRLP4 20+4
INDIRF4
ADDRLP4 16
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRLP4 4+8
ADDRLP4 4+8
INDIRF4
ADDRLP4 20+8
INDIRF4
ADDRLP4 16
INDIRF4
MULF4
ADDF4
ASGNF4
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1499
ADDRGP4 $1484
JUMPV
LABELV $1499
ADDRLP4 80
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 80
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 80
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1084227584
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRGP4 cgs+152852+260
INDIRI4
ASGNI4
ADDRLP4 32
INDIRF4
CNSTF4 0
EQF4 $1504
ADDRLP4 92
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
CNSTI4 4500
ADDI4
CVIF4 4
CNSTF4 1163575296
CNSTF4 1073741824
ADDRLP4 92
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ADDF4
ASGNF4
ADDRGP4 $1505
JUMPV
LABELV $1504
ADDRLP4 96
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
CNSTI4 750
ADDI4
CVIF4 4
CNSTF4 1140457472
CNSTF4 1073741824
ADDRLP4 96
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ADDF4
ASGNF4
LABELV $1505
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
CNSTF4 1107296256
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
CNSTF4 1107296256
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
CNSTF4 1119879168
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
CNSTF4 1119879168
ASGNF4
ADDRLP4 32
INDIRF4
CNSTF4 0
NEF4 $1509
ADDRLP4 100
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
ASGNP4
ADDRLP4 100
INDIRP4
CNSTF4 1045220557
ADDRLP4 100
INDIRP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 104
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
ASGNP4
ADDRLP4 104
INDIRP4
CNSTF4 1045220557
ADDRLP4 104
INDIRP4
INDIRF4
MULF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
CNSTF4 1098907648
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
CNSTF4 1098907648
ASGNF4
LABELV $1509
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 3
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRLP4 4
INDIRB
ASGNB 12
ADDRLP4 100
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 24
ADDP4
CNSTF4 1086324736
CNSTF4 1073741824
ADDRLP4 100
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
ADDRLP4 104
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 28
ADDP4
CNSTF4 1086324736
CNSTF4 1073741824
ADDRLP4 104
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
ADDRLP4 108
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 32
ADDP4
CNSTF4 1101004800
ADDRLP4 108
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
MULF4
ASGNF4
ADDRLP4 112
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
CNSTF4 1077936128
CNSTF4 1073741824
ADDRLP4 112
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
ADDRLP4 116
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
CNSTF4 1077936128
CNSTF4 1073741824
ADDRLP4 116
INDIRI4
CNSTI4 32767
BANDI4
CVIF4 4
CNSTF4 1191181824
DIVF4
CNSTF4 1056964608
SUBF4
MULF4
MULF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
CNSTF4 3246391296
ASGNF4
ADDRLP4 124
CNSTF4 0
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 44
ADDP4
ADDRLP4 124
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 40
ADDP4
ADDRLP4 124
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 36
ADDP4
ADDRLP4 124
INDIRF4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 100
ADDP4
CNSTI4 0
ASGNI4
ADDRLP4 128
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
ADDRLP4 128
INDIRI4
CNSTI4 179
MODI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1061158912
ASGNF4
LABELV $1490
ADDRLP4 36
ADDRLP4 36
INDIRI4
CNSTI4 1
ADDI4
ASGNI4
LABELV $1492
ADDRLP4 36
INDIRI4
CVIF4 4
ADDRLP4 40
INDIRF4
LTF4 $1489
LABELV $1484
endproc CG_ParticleDust 132 16
export CG_ParticleMisc
proc CG_ParticleMisc 20 4
ADDRFP4 8
ADDRFP4 8
INDIRI4
ASGNI4
ADDRFP4 0
INDIRI4
CNSTI4 0
NEI4 $1512
ADDRGP4 $1347
ARGP4
ADDRGP4 CG_Printf
CALLV
pop
LABELV $1512
ADDRGP4 free_particles
INDIRP4
CVPU4 4
CNSTU4 0
NEU4 $1514
ADDRGP4 $1511
JUMPV
LABELV $1514
ADDRLP4 4
ADDRGP4 free_particles
ASGNP4
ADDRLP4 0
ADDRLP4 4
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 4
INDIRP4
ADDRLP4 0
INDIRP4
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
ADDRGP4 active_particles
INDIRP4
ASGNP4
ADDRGP4 active_particles
ADDRLP4 0
INDIRP4
ASGNP4
ADDRLP4 0
INDIRP4
CNSTI4 4
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 56
ADDP4
CNSTF4 1065353216
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 60
ADDP4
CNSTF4 0
ASGNF4
ADDRLP4 16
ADDRGP4 qk_rand
CALLI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 116
ADDP4
ADDRLP4 16
INDIRI4
CNSTI4 179
MODI4
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 68
ADDP4
ADDRFP4 0
INDIRI4
ASGNI4
ADDRFP4 12
INDIRI4
CNSTI4 0
LEI4 $1517
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRGP4 cg+107604
INDIRI4
ADDRFP4 12
INDIRI4
ADDI4
CVIF4 4
ASGNF4
ADDRGP4 $1518
JUMPV
LABELV $1517
ADDRLP4 0
INDIRP4
CNSTI4 8
ADDP4
ADDRFP4 12
INDIRI4
CVIF4 4
ASGNF4
LABELV $1518
ADDRLP4 0
INDIRP4
CNSTI4 96
ADDP4
ADDRGP4 cg+107604
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 76
ADDP4
ADDRFP4 8
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 72
ADDP4
ADDRFP4 8
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 80
ADDP4
ADDRFP4 8
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 84
ADDP4
ADDRFP4 8
INDIRI4
CVIF4 4
ASGNF4
ADDRLP4 0
INDIRP4
CNSTI4 64
ADDP4
CNSTI4 15
ASGNI4
ADDRLP4 0
INDIRP4
CNSTI4 12
ADDP4
ADDRFP4 4
INDIRP4
INDIRB
ASGNB 12
ADDRLP4 0
INDIRP4
CNSTI4 100
ADDP4
CNSTI4 0
ASGNI4
LABELV $1511
endproc CG_ParticleMisc 20 4
bss
export oldtime
align 4
LABELV oldtime
skip 4
export rup
align 4
LABELV rup
skip 12
export rright
align 4
LABELV rright
skip 12
export rforward
align 4
LABELV rforward
skip 12
export vup
align 4
LABELV vup
skip 12
export vright
align 4
LABELV vright
skip 12
export vforward
align 4
LABELV vforward
skip 12
export particles
align 4
LABELV particles
skip 126976
export free_particles
align 4
LABELV free_particles
skip 4
export active_particles
align 4
LABELV active_particles
skip 4
align 4
LABELV numShaderAnims
skip 4
align 4
LABELV shaderAnims
skip 8192
import trap_GetEntityToken
import trap_getCameraInfo
import trap_startCamera
import trap_loadCamera
import trap_SnapVector
import trap_RealTime
import trap_CIN_SetExtents
import trap_CIN_DrawCinematic
import trap_CIN_RunCinematic
import trap_CIN_StopCinematic
import trap_CIN_PlayCinematic
import trap_Key_GetKey
import trap_Key_SetCatcher
import trap_Key_GetCatcher
import trap_Key_IsDown
import trap_R_RegisterFont
import trap_MemoryRemaining
import testPrintFloat
import testPrintInt
import trap_SetUserCmdValue
import trap_GetUserCmd
import trap_GetCurrentCmdNumber
import trap_GetServerCommand
import trap_GetSnapshot
import trap_GetCurrentSnapshotNumber
import trap_GetGameState
import trap_GetGlconfig
import trap_R_inPVS
import trap_R_RemapShader
import trap_R_LerpTag
import trap_R_ModelBounds
import trap_R_DrawStretchPic
import trap_R_SetColor
import trap_R_RenderScene
import trap_R_LightForPoint
import trap_R_AddAdditiveLightToScene
import trap_R_AddLightToScene
import trap_R_AddPolysToScene
import trap_R_AddPolyToScene
import trap_R_AddRefEntityToScene
import trap_R_ClearScene
import trap_R_RegisterShaderNoMip
import trap_R_RegisterShader
import trap_R_RegisterSkin
import trap_R_RegisterModel
import trap_R_LoadWorldMap
import trap_S_StopBackgroundTrack
import trap_S_StartBackgroundTrack
import trap_S_RegisterSound
import trap_S_Respatialize
import trap_S_UpdateEntityPosition
import trap_S_AddRealLoopingSound
import trap_S_AddLoopingSound
import trap_S_ClearLoopingSounds
import trap_S_StartLocalSound
import trap_S_StopLoopingSound
import trap_S_StartSound
import trap_CM_MarkFragments
import trap_CM_TransformedCapsuleTrace
import trap_CM_TransformedBoxTrace
import trap_CM_CapsuleTrace
import trap_CM_BoxTrace
import trap_CM_TransformedPointContents
import trap_CM_PointContents
import trap_CM_TempBoxModel
import trap_CM_InlineModel
import trap_CM_NumInlineModels
import trap_CM_LoadMap
import trap_UpdateScreen
import trap_SendClientCommand
import trap_RemoveCommand
import trap_AddCommand
import trap_SendConsoleCommand
import trap_FS_Seek
import trap_FS_FCloseFile
import trap_FS_Write
import trap_FS_Read
import trap_FS_FOpenFile
import trap_Args
import trap_Argv
import trap_Argc
import trap_Cvar_VariableStringBuffer
import trap_Cvar_Set
import trap_Cvar_Update
import trap_Cvar_Register
import trap_Milliseconds
import trap_Error
import trap_Print
import CG_CheckChangedPredictableEvents
import CG_TransitionPlayerState
import CG_Respawn
import CG_ShaderStateChanged
import CG_SetConfigValues
import CG_ParseServerinfo
import CG_ExecuteNewServerCommands
import CG_InitConsoleCommands
import CG_ConsoleCommand
import CG_DrawOldTourneyScoreboard
import CG_DrawOldScoreboard
import CG_DrawInformation
import CG_LoadingClient
import CG_LoadingItem
import CG_LoadingString
import CG_ProcessSnapshots
import CG_MakeExplosion
import CG_Bleed
import CG_BigExplode
import CG_GibPlayer
import CG_ScorePlum
import CG_SpawnEffect
import CG_BubbleTrail
import CG_SmokePuff
import CG_AddLocalEntities
import CG_AllocLocalEntity
import CG_InitLocalEntities
import CG_ImpactMark
import CG_AddMarks
import CG_InitMarkPolys
import CG_OutOfAmmoChange
import CG_DrawWeaponSelect
import CG_AddPlayerWeapon
import CG_AddViewWeapon
import CG_GrappleTrail
import CG_RailTrail
import CG_Bullet
import CG_ShotgunFire
import CG_MissileHitPlayer
import CG_MissileHitWall
import CG_FireWeapon
import CG_RegisterItemVisuals
import CG_RegisterWeapon
import CG_Weapon_f
import CG_PrevWeapon_f
import CG_NextWeapon_f
import CG_PositionRotatedEntityOnTag
import CG_PositionEntityOnTag
import CG_AdjustPositionForMover
import CG_Beam
import CG_AddPacketEntities
import CG_SetEntitySoundPosition
import CG_PainEvent
import CG_EntityEvent
import CG_PlaceString
import CG_CheckEvents
import CG_LoadDeferredPlayers
import CG_PredictPlayerState
import CG_Trace
import CG_PointContents
import CG_BuildSolidList
import CG_CustomSound
import CG_NewClientInfo
import CG_AddRefEntityWithPowerups
import CG_ResetPlayerEntity
import CG_Player
import CG_StatusHandle
import CG_OtherTeamHasFlag
import CG_YourTeamHasFlag
import CG_GameTypeString
import CG_CheckOrderPending
import CG_Text_PaintChar
import CG_Draw3DModel
import CG_GetKillerText
import CG_GetGameStatusText
import CG_GetTeamColor
import CG_InitTeamChat
import CG_SetPrintString
import CG_ShowResponseHead
import CG_RunMenuScript
import CG_OwnerDrawVisible
import CG_GetValue
import CG_SelectNextPlayer
import CG_SelectPrevPlayer
import CG_Text_Height
import CG_Text_Width
import CG_Text_Paint
import CG_OwnerDraw
import CG_DrawTeamBackground
import CG_DrawFlagModel
import CG_DrawActive
import CG_DrawHead
import CG_CenterPrint
import CG_AddLagometerSnapshotInfo
import CG_AddLagometerFrameInfo
import teamChat2
import teamChat1
import systemChat
import drawTeamOverlayModificationCount
import numSortedTeamPlayers
import sortedTeamPlayers
import CG_DrawTopBottom
import CG_DrawSides
import CG_DrawRect
import UI_DrawProportionalString
import CG_GetColorForHealth
import CG_ColorForHealth
import CG_TileClear
import CG_TeamColor
import CG_FadeColor
import CG_DrawStrlen
import CG_DrawSmallStringColor
import CG_DrawSmallString
import CG_DrawBigStringColor
import CG_DrawBigString
import CG_DrawStringExt
import CG_DrawString
import CG_DrawPic
import CG_FillRect
import CG_AdjustFrom640
import CG_DrawActiveFrame
import CG_AddBufferedSound
import CG_ZoomUp_f
import CG_ZoomDown_f
import CG_TestModelPrevSkin_f
import CG_TestModelNextSkin_f
import CG_TestModelPrevFrame_f
import CG_TestModelNextFrame_f
import CG_TestGun_f
import CG_TestModel_f
import CG_BuildSpectatorString
import CG_GetSelectedScore
import CG_SetScoreSelection
import CG_RankRunFrame
import CG_EventHandling
import CG_MouseEvent
import CG_KeyEvent
import CG_LoadMenus
import CG_LastAttacker
import CG_CrosshairPlayer
import CG_UpdateCvars
import CG_StartMusic
import CG_Error
import CG_Printf
import CG_Argv
import CG_ConfigString
import cg_trueLightning
import cg_oldPlasma
import cg_oldRocket
import cg_oldRail
import cg_noProjectileTrail
import cg_noTaunt
import cg_bigFont
import cg_smallFont
import cg_cameraMode
import cg_timescale
import cg_timescaleFadeSpeed
import cg_timescaleFadeEnd
import cg_cameraOrbitDelay
import cg_cameraOrbit
import pmove_msec
import pmove_fixed
import cg_smoothClients
import cg_scorePlum
import cg_teamChatsOnly
import cg_drawFriend
import cg_deferPlayers
import cg_predictItems
import cg_blood
import cg_paused
import cg_buildScript
import cg_forceModel
import cg_stats
import cg_teamChatHeight
import cg_teamChatTime
import cg_synchronousClients
import cg_drawAttacker
import cg_lagometer
import cg_thirdPerson
import cg_thirdPersonAngle
import cg_thirdPersonRange
import cg_zoomFov
import cg_fov
import cg_simpleItems
import cg_ignore
import cg_autoswitch
import cg_tracerLength
import cg_tracerWidth
import cg_tracerChance
import cg_viewsize
import cg_drawGun
import cg_gun_z
import cg_gun_y
import cg_gun_x
import cg_gun_frame
import cg_brassTime
import cg_addMarks
import cg_footsteps
import cg_showmiss
import cg_noPlayerAnims
import cg_nopredict
import cg_errorDecay
import cg_railTrailTime
import cg_debugEvents
import cg_debugPosition
import cg_debugAnim
import cg_animSpeed
import cg_draw2D
import cg_drawStatus
import cg_crosshairHealth
import cg_crosshairSize
import cg_crosshairY
import cg_crosshairX
import cg_teamOverlayUserinfo
import cg_drawTeamOverlay
import cg_drawRewards
import cg_drawCrosshairNames
import cg_drawCrosshair
import cg_drawAmmoWarning
import cg_drawIcons
import cg_draw3dIcons
import cg_drawSnapshot
import cg_drawFPS
import cg_drawTimer
import cg_gibs
import cg_shadows
import cg_swingSpeed
import cg_bobroll
import cg_bobpitch
import cg_bobup
import cg_runroll
import cg_runpitch
import cg_centertime
import cg_markPolys
import cg_items
import cg_weapons
import cg_entities
import cg
import cgs
import BG_PlayerTouchesItem
import BG_PlayerStateToEntityStateExtraPolate
import BG_PlayerStateToEntityState
import BG_TouchJumpPad
import BG_AddPredictableEventToPlayerstate
import BG_EvaluateTrajectoryDelta
import BG_EvaluateTrajectory
import BG_CanItemBeGrabbed
import BG_FindItemForHoldable
import BG_FindItemForPowerup
import BG_FindItemForWeapon
import BG_FindItem
import bg_numItems
import bg_itemlist
import Pmove
import PM_UpdateViewAngles
import Com_Printf
import Com_Error
import Info_NextPair
import Info_Validate
import Info_SetValueForKey_Big
import Info_SetValueForKey
import Info_RemoveKey_Big
import Info_RemoveKey
import Info_ValueForKey
import Com_TruncateLongString
import va
import Q_CountChar
import Q_CleanStr
import Q_PrintStrlen
import Q_strcat
import Q_strncpyz
import Q_stristr
import Q_strupr
import Q_strlwr
import Q_stricmpn
import Q_strncmp
import Q_stricmp
import Q_isintegral
import Q_isanumber
import Q_isalpha
import Q_isupper
import Q_islower
import Q_isprint
import Com_RandomBytes
import Com_SkipCharset
import Com_SkipTokens
import Com_sprintf
import Com_HexStrToInt
import Parse3DMatrix
import Parse2DMatrix
import Parse1DMatrix
import SkipRestOfLine
import SkipBracedSection
import COM_MatchToken
import COM_ParseWarning
import COM_ParseError
import COM_Compress
import COM_ParseExt
import COM_Parse
import COM_GetCurrentParseLine
import COM_BeginParseSession
import COM_DefaultExtension
import COM_CompareExtension
import COM_StripExtension
import COM_GetExtension
import COM_SkipPath
import Com_Clamp
import PerpendicularVector
import AngleVectors
import MatrixMultiply
import MakeNormalVectors
import RotateAroundDirection
import RotatePointAroundVector
import ProjectPointOnPlane
import PlaneFromPoints
import AngleDelta
import AngleNormalize180
import AngleNormalize360
import AnglesSubtract
import AngleSubtract
import LerpAngle
import AngleMod
import BoundsIntersectPoint
import BoundsIntersectSphere
import BoundsIntersect
import BoxOnPlaneSide
import SetPlaneSignbits
import AxisCopy
import AxisClear
import AnglesToAxis
import vectoangles
import Q_crandom
import Q_random
import Q_rand
import Q_acos
import Q_log2
import VectorRotate
import Vector4Scale
import VectorNormalize2
import VectorNormalize
import CrossProduct
import VectorInverse
import VectorNormalizeFast
import DistanceSquared
import Distance
import VectorLengthSquared
import VectorLength
import VectorCompare
import AddPointToBounds
import ClearBounds
import RadiusFromBounds
import NormalizeColor
import ColorBytes4
import ColorBytes3
import _VectorMA
import _VectorScale
import _VectorCopy
import _VectorAdd
import _VectorSubtract
import _DotProduct
import ByteToDir
import DirToByte
import ClampShort
import ClampChar
import Q_rsqrt
import Q_fabs
import Q_isnan
import axisDefault
import vec3_origin
import g_color_table
import colorDkGrey
import colorMdGrey
import colorLtGrey
import colorWhite
import colorCyan
import colorMagenta
import colorYellow
import colorBlue
import colorGreen
import colorRed
import colorBlack
import bytedirs
import Hunk_AllocDebug
import FloatSwap
import LongSwap
import ShortSwap
import CopyLongSwap
import CopyShortSwap
import qk_acos
import qk_fabs
import qk_abs
import qk_tan
import qk_atan2
import qk_cos
import qk_sin
import qk_sqrt
import qk_floor
import qk_ceil
import qk_memcpy
import qk_memset
import qk_memmove
import qk_sscanf
import qk_vsnprintf
import qk_strtol
import qk_atoi
import qk_strtod
import qk_atof
import qk_toupper
import qk_tolower
import qk_strncpy
import qk_strstr
import qk_strrchr
import qk_strchr
import qk_strcmp
import qk_strcpy
import qk_strcat
import qk_strlen
import qk_rand
import qk_srand
import qk_qsort
lit
align 1
LABELV $1447
byte 1 67
byte 1 71
byte 1 95
byte 1 66
byte 1 108
byte 1 111
byte 1 111
byte 1 100
byte 1 80
byte 1 111
byte 1 111
byte 1 108
byte 1 32
byte 1 112
byte 1 115
byte 1 104
byte 1 97
byte 1 100
byte 1 101
byte 1 114
byte 1 32
byte 1 61
byte 1 61
byte 1 32
byte 1 90
byte 1 69
byte 1 82
byte 1 79
byte 1 33
byte 1 10
byte 1 0
align 1
LABELV $1393
byte 1 67
byte 1 71
byte 1 95
byte 1 79
byte 1 105
byte 1 108
byte 1 83
byte 1 108
byte 1 105
byte 1 99
byte 1 107
byte 1 82
byte 1 101
byte 1 118
byte 1 111
byte 1 118
byte 1 101
byte 1 32
byte 1 78
byte 1 85
byte 1 76
byte 1 76
byte 1 32
byte 1 105
byte 1 100
byte 1 10
byte 1 0
align 1
LABELV $1379
byte 1 67
byte 1 71
byte 1 95
byte 1 80
byte 1 97
byte 1 114
byte 1 116
byte 1 105
byte 1 99
byte 1 108
byte 1 101
byte 1 95
byte 1 79
byte 1 105
byte 1 108
byte 1 83
byte 1 108
byte 1 105
byte 1 99
byte 1 107
byte 1 32
byte 1 61
byte 1 61
byte 1 32
byte 1 90
byte 1 69
byte 1 82
byte 1 79
byte 1 33
byte 1 10
byte 1 0
align 1
LABELV $1371
byte 1 67
byte 1 71
byte 1 95
byte 1 80
byte 1 97
byte 1 114
byte 1 116
byte 1 105
byte 1 99
byte 1 108
byte 1 101
byte 1 95
byte 1 79
byte 1 105
byte 1 108
byte 1 80
byte 1 97
byte 1 114
byte 1 116
byte 1 105
byte 1 99
byte 1 108
byte 1 101
byte 1 32
byte 1 61
byte 1 61
byte 1 32
byte 1 90
byte 1 69
byte 1 82
byte 1 79
byte 1 33
byte 1 10
byte 1 0
align 1
LABELV $1357
byte 1 67
byte 1 71
byte 1 95
byte 1 80
byte 1 97
byte 1 114
byte 1 116
byte 1 105
byte 1 99
byte 1 108
byte 1 101
byte 1 95
byte 1 66
byte 1 108
byte 1 101
byte 1 101
byte 1 100
byte 1 32
byte 1 112
byte 1 115
byte 1 104
byte 1 97
byte 1 100
byte 1 101
byte 1 114
byte 1 32
byte 1 61
byte 1 61
byte 1 32
byte 1 90
byte 1 69
byte 1 82
byte 1 79
byte 1 33
byte 1 10
byte 1 0
align 1
LABELV $1347
byte 1 67
byte 1 71
byte 1 95
byte 1 80
byte 1 97
byte 1 114
byte 1 116
byte 1 105
byte 1 99
byte 1 108
byte 1 101
byte 1 73
byte 1 109
byte 1 112
byte 1 97
byte 1 99
byte 1 116
byte 1 83
byte 1 109
byte 1 111
byte 1 107
byte 1 101
byte 1 80
byte 1 117
byte 1 102
byte 1 102
byte 1 32
byte 1 112
byte 1 115
byte 1 104
byte 1 97
byte 1 100
byte 1 101
byte 1 114
byte 1 32
byte 1 61
byte 1 61
byte 1 32
byte 1 90
byte 1 69
byte 1 82
byte 1 79
byte 1 33
byte 1 10
byte 1 0
align 1
LABELV $1287
byte 1 67
byte 1 71
byte 1 95
byte 1 80
byte 1 97
byte 1 114
byte 1 116
byte 1 105
byte 1 99
byte 1 108
byte 1 101
byte 1 69
byte 1 120
byte 1 112
byte 1 108
byte 1 111
byte 1 115
byte 1 105
byte 1 111
byte 1 110
byte 1 58
byte 1 32
byte 1 117
byte 1 110
byte 1 107
byte 1 110
byte 1 111
byte 1 119
byte 1 110
byte 1 32
byte 1 97
byte 1 110
byte 1 105
byte 1 109
byte 1 97
byte 1 116
byte 1 105
byte 1 111
byte 1 110
byte 1 32
byte 1 115
byte 1 116
byte 1 114
byte 1 105
byte 1 110
byte 1 103
byte 1 58
byte 1 32
byte 1 37
byte 1 115
byte 1 0
align 1
LABELV $1278
byte 1 67
byte 1 71
byte 1 95
byte 1 80
byte 1 97
byte 1 114
byte 1 116
byte 1 105
byte 1 99
byte 1 108
byte 1 101
byte 1 69
byte 1 120
byte 1 112
byte 1 108
byte 1 111
byte 1 115
byte 1 105
byte 1 111
byte 1 110
byte 1 58
byte 1 32
byte 1 97
byte 1 110
byte 1 105
byte 1 109
byte 1 83
byte 1 116
byte 1 114
byte 1 32
byte 1 105
byte 1 115
byte 1 32
byte 1 112
byte 1 114
byte 1 111
byte 1 98
byte 1 97
byte 1 98
byte 1 108
byte 1 121
byte 1 32
byte 1 97
byte 1 110
byte 1 32
byte 1 105
byte 1 110
byte 1 100
byte 1 101
byte 1 120
byte 1 32
byte 1 114
byte 1 97
byte 1 116
byte 1 104
byte 1 101
byte 1 114
byte 1 32
byte 1 116
byte 1 104
byte 1 97
byte 1 110
byte 1 32
byte 1 97
byte 1 32
byte 1 115
byte 1 116
byte 1 114
byte 1 105
byte 1 110
byte 1 103
byte 1 0
align 1
LABELV $1259
byte 1 67
byte 1 71
byte 1 95
byte 1 80
byte 1 97
byte 1 114
byte 1 116
byte 1 105
byte 1 99
byte 1 108
byte 1 101
byte 1 83
byte 1 109
byte 1 111
byte 1 107
byte 1 101
byte 1 32
byte 1 61
byte 1 61
byte 1 32
byte 1 90
byte 1 69
byte 1 82
byte 1 79
byte 1 33
byte 1 10
byte 1 0
align 1
LABELV $1238
byte 1 67
byte 1 71
byte 1 95
byte 1 80
byte 1 97
byte 1 114
byte 1 116
byte 1 105
byte 1 99
byte 1 108
byte 1 101
byte 1 83
byte 1 110
byte 1 111
byte 1 119
byte 1 32
byte 1 112
byte 1 115
byte 1 104
byte 1 97
byte 1 100
byte 1 101
byte 1 114
byte 1 32
byte 1 61
byte 1 61
byte 1 32
byte 1 90
byte 1 69
byte 1 82
byte 1 79
byte 1 33
byte 1 10
byte 1 0
align 1
LABELV $1223
byte 1 67
byte 1 71
byte 1 95
byte 1 80
byte 1 97
byte 1 114
byte 1 116
byte 1 105
byte 1 99
byte 1 108
byte 1 101
byte 1 83
byte 1 110
byte 1 111
byte 1 119
byte 1 70
byte 1 108
byte 1 117
byte 1 114
byte 1 114
byte 1 121
byte 1 32
byte 1 112
byte 1 115
byte 1 104
byte 1 97
byte 1 100
byte 1 101
byte 1 114
byte 1 32
byte 1 61
byte 1 61
byte 1 32
byte 1 90
byte 1 69
byte 1 82
byte 1 79
byte 1 33
byte 1 10
byte 1 0
align 1
LABELV $90
byte 1 37
byte 1 115
byte 1 37
byte 1 105
byte 1 0
align 1
LABELV $72
byte 1 101
byte 1 120
byte 1 112
byte 1 108
byte 1 111
byte 1 100
byte 1 101
byte 1 49
byte 1 0
| 10.186055 | 45 | 0.832987 |
dd8b76516272d26e7787f2cc0cc620707388c975 | 1,778 | dart | Dart | lib/src/line_intersect.dart | MinByeongDon/turf_dart | d514f27a8da58b71ebd78df01d1a31e8e2f94b3f | [
"MIT"
] | null | null | null | lib/src/line_intersect.dart | MinByeongDon/turf_dart | d514f27a8da58b71ebd78df01d1a31e8e2f94b3f | [
"MIT"
] | null | null | null | lib/src/line_intersect.dart | MinByeongDon/turf_dart | d514f27a8da58b71ebd78df01d1a31e8e2f94b3f | [
"MIT"
] | null | null | null |
import 'package:turf/helpers.dart';
Point? lineIntersect(LineString line1, LineString line2) {
Map<String, bool> unique = {};
if (line1.coordinates.length == 2 && line2.coordinates.length == 2) {
final intersect = intersects(line1, line2);
if (intersect != null) {
return intersect;
}
}
return null;
}
/// Find a point that intersects LineStrings with two coordinates each
///
/// [line1] {Feature<LineString>} line1 GeoJSON LineString (Must only contain 2 coordinates)
///
/// [line2] {Feature<LineString>} line2 GeoJSON LineString (Must only contain 2 coordinates)
///
/// returns {Feature<Point>} intersecting GeoJSON Point
Point? intersects(LineString line1, LineString line2) {
final coords1 = line1.coordinates;
final coords2 = line2.coordinates;
if (coords1.length != 2) {
throw Exception("<intersects> line1 must only contain 2 coordinates");
}
if (coords2.length != 2) {
throw Exception("<intersects> line2 must only contain 2 coordinates");
}
final x1 = coords1[0][0]!;
final y1 = coords1[0][1]!;
final x2 = coords1[1][0]!;
final y2 = coords1[1][1]!;
final x3 = coords2[0][0]!;
final y3 = coords2[0][1]!;
final x4 = coords2[1][0]!;
final y4 = coords2[1][1]!;
final denom = (y4 - y3) * (x2 - x1) - (x4 - x3) * (y2 - y1);
final numeA = (x4 - x3) * (y1 - y3) - (y4 - y3) * (x1 - x3);
final numeB = (x2 - x1) * (y1 - y3) - (y2 - y1) * (x1 - x3);
if (denom == 0) {
if (numeA == 0 && numeB == 0) {
return null;
}
return null;
}
final uA = numeA / denom;
final uB = numeB / denom;
if (uA >= 0 && uA <= 1 && uB >= 0 && uB <= 1) {
final x = x1 + uA * (x2 - x1);
final y = y1 + uA * (y2 - y1);
return Point(coordinates: Position(x, y));
}
return null;
}
| 28.222222 | 92 | 0.6018 |
2f3e15731426041804311fee382c73b8067f64ef | 3,412 | php | PHP | Application/Common/Controller/BaseController.class.php | chenping684/dzr | 7e5bf9e20a0e71823ec50db8f60be9910ba9b1a1 | [
"BSD-2-Clause"
] | null | null | null | Application/Common/Controller/BaseController.class.php | chenping684/dzr | 7e5bf9e20a0e71823ec50db8f60be9910ba9b1a1 | [
"BSD-2-Clause"
] | null | null | null | Application/Common/Controller/BaseController.class.php | chenping684/dzr | 7e5bf9e20a0e71823ec50db8f60be9910ba9b1a1 | [
"BSD-2-Clause"
] | null | null | null | <?php
namespace Common\Controller;
/**
* Class BaseController
* @author yourname
*/
class BaseController extends \Think\Controller {
public function _initialize() {
if(!in_array(strtolower(CONTROLLER_NAME), array('index')) || session('id')) {
$id = session('id');
$checkMemberStatus = D('AdminInfo')->where(array('id'=>$id))->getField('type');
if ( $checkMemberStatus == 2 && in_array(strtolower(CONTROLLER_NAME), array('agentachievement', 'agentinfo',))) {
session(null);
echo "<script>location.href='".__ROOT__."/admin.php/Public/login';</script>";
}
//平台管理员url限制还没有加
if ( $checkMemberStatus != 2 && in_array(strtolower(CONTROLLER_NAME), array('admingoods', 'adminscenic',))) {
session(null);
// $this->redirect('Public/login');
echo "<script>location.href='".__ROOT__."/admin.php/Public/login';</script>";
}
} else {
session(null);
// $this->redirect('Public/login');
echo "<script>location.href='".__ROOT__."/admin.php/Public/login';</script>";
}
}
/**
* 分页控件
* @param $total int 总记录数
* @param $size int 每页显示的记录数
* @param $type string 类型
* */
protected function _pageShow($total, $size, $type = 'default') {
$page = new \Common\Lib\Page($total, $size);// 实例化分页类 传入总记录数和每页显示的记录数
switch($type) {
// case C('TPL_PAGE_SHOW_NORMAL'):
// $page->setConfig('theme'
//, '<div class="dataTables_paginate paging_bootstrap_full"><ul class="pagination">
// <li>%UP_PAGE%</li> <li>%FIRST%</li> <li>%LINK_PAGE%</li> <li>%END%</li> <li>%DOWN_PAGE%</li> </ul></div>');
// break;
// case C('TPL_PAGE_SHOW_IMPROVE'):
// $page->setConfig('theme', '<div class="dataTables_paginate paging_bootstrap_f
//ull"><ul class="pagination">
// <li>%UP_PAGE%</li>
// <li>%FIRST%</li>
// <li>%LINK_PAGE%</li>
// <li>%END%</li>
// <li>%DOWN_PAGE%</li>
// </ul>
// <ul class="pagination pull-right"> <li>'.$this->_pageNumberWidget($size, C('SEARCH_DEFAULT_PAGE_ASSEMBLAGE')).'</li> <li><i>条/页</i></li> <li><i>(%HEADER%)</i></li> </ul> </div>');
// break;
default:
$theme = <<<EOF
<div class="row">
<div class="col-sm-6">
<div class="dataTables_info" id="sample-table_info" role="status" aria-live="polite"></div>
</div>
<div class="col-sm-6">
<div class="dataTables_paginate paging_bootstrap" id="sample-table_paginate">
<ul class="pagination">
<li class="prev disabled">%UP_PAGE% </li>
%LINK_PAGE%
<li class="next disabled">%DOWN_PAGE%</li>
</ul>
</div>
</div>
</div>
EOF;
$page->setConfig('prev', '上一页');
$page->setConfig('next', '下一页');
$page->setConfig('theme', $theme);
break;
}
$show = $page->show();// 分页显示输出
$this->assign('my_page', $show);// 赋值分页输出
}
}
| 36.688172 | 183 | 0.493845 |
07e74733edbca5eed8d180fe5adb8a34fa2de9de | 24 | rs | Rust | inventory_ms/domain/src/entities/mod.rs | ralvescosta/distributed_systems | 1e95249cce2535400a8f0f42ae57c66a80260dc1 | [
"MIT"
] | 8 | 2021-10-19T21:22:10.000Z | 2021-12-20T22:01:54.000Z | inventory_ms/domain/src/entities/mod.rs | ralvescosta/distributed_loging | 1e95249cce2535400a8f0f42ae57c66a80260dc1 | [
"MIT"
] | 5 | 2021-11-03T11:28:34.000Z | 2022-02-27T21:56:40.000Z | inventory_ms/domain/src/entities/mod.rs | ralvescosta/distributed_systems | 1e95249cce2535400a8f0f42ae57c66a80260dc1 | [
"MIT"
] | null | null | null | pub mod product_entity;
| 12 | 23 | 0.833333 |
5f5291ecc7765c78aeef721504f22a572a90b16b | 1,662 | ts | TypeScript | src/app/portfolio-page/portfolio-page.component.ts | irinabratu/gainuta | 4c616781fb58b8e5a2c141aba7b86052b8195e41 | [
"MIT"
] | null | null | null | src/app/portfolio-page/portfolio-page.component.ts | irinabratu/gainuta | 4c616781fb58b8e5a2c141aba7b86052b8195e41 | [
"MIT"
] | null | null | null | src/app/portfolio-page/portfolio-page.component.ts | irinabratu/gainuta | 4c616781fb58b8e5a2c141aba7b86052b8195e41 | [
"MIT"
] | null | null | null | import { Component, OnInit } from '@angular/core';
import { HttpClient } from '@angular/common/http';
import { baseUrl } from '../../utils/constants';
import { PortfolioEntity } from '../../model/PortfolioEntity';
import { MatExpansionPanel } from '@angular/material';
@Component({
selector: 'portfolio-page',
templateUrl: './portfolio-page.component.html',
styleUrls: ['./portfolio-page.component.css']
})
export class PortfolioPageComponent implements OnInit {
showSpinner: boolean;
archPanel: PortfolioEntity = new PortfolioEntity();
illustPanel: PortfolioEntity = new PortfolioEntity();
designPanel: PortfolioEntity = new PortfolioEntity();
constructor(public http: HttpClient) {
}
ngOnInit() {
this.fetchPortfolio();
}
fetchPortfolio() {
this.showSpinner = true;
this.http.get(baseUrl + 'Portfolio/GetActive')
.subscribe(data => {
let archPanel;
let illustPanel;
let designPanel;
var items = data as PortfolioEntity[];
items.forEach(function (item) {
if (item.Category == 'Achitecture') {
archPanel = item;
}
else if (item.Category == 'Illustration') {
illustPanel = item;
}
else if (item.Category == 'Design') {
designPanel = item;
}
});
this.archPanel = archPanel;
this.illustPanel = illustPanel;
this.designPanel = designPanel;
this.showSpinner = false;
}, fail => {
console.log(fail.message);
});
}
onClickPanel(panel: MatExpansionPanel) {
console.log(panel);
}
}
| 23.408451 | 62 | 0.608303 |
84ded61715655ebdc90f270459d3c89bdd83b9f4 | 218 | h | C | proyecto2/funcion.h | ErickTejaxun/coline-compiler-learning | 76654c82317d72f2b4ae7b743062eadd43cb235c | [
"MIT"
] | null | null | null | proyecto2/funcion.h | ErickTejaxun/coline-compiler-learning | 76654c82317d72f2b4ae7b743062eadd43cb235c | [
"MIT"
] | null | null | null | proyecto2/funcion.h | ErickTejaxun/coline-compiler-learning | 76654c82317d72f2b4ae7b743062eadd43cb235c | [
"MIT"
] | null | null | null | #ifndef FUNCION_H
#define FUNCION_H
#include <QString>
#include <nodo.h>
class Funcion
{
public:
Funcion(nodo raiz);
QString getId();
QString nombre;
QString id;
nodo raiz;
};
#endif // FUNCION_H
| 12.823529 | 23 | 0.665138 |
39fcd464cd6ed9d4146fb3cb2bf2fb0fde8b316e | 267 | java | Java | plugins/eu.hyvar.feature.constraint.resource.hyconstraints.ui/src-gen/eu/hyvar/feature/constraint/resource/hyconstraints/ui/IHyconstraintsTokenScanner.java | DarwinSPL/DarwinSPL | d243805ba5a6fc7c1adec94cc81a5d160ccf5a8a | [
"Apache-2.0"
] | 4 | 2017-06-07T14:13:00.000Z | 2019-03-25T16:20:25.000Z | plugins/eu.hyvar.feature.constraint.resource.hyconstraints.ui/src-gen/eu/hyvar/feature/constraint/resource/hyconstraints/ui/IHyconstraintsTokenScanner.java | DarwinSPL/DarwinSPL | d243805ba5a6fc7c1adec94cc81a5d160ccf5a8a | [
"Apache-2.0"
] | 81 | 2017-06-30T11:18:14.000Z | 2018-09-26T14:10:40.000Z | plugins/eu.hyvar.feature.constraint.resource.hyconstraints.ui/src-gen/eu/hyvar/feature/constraint/resource/hyconstraints/ui/IHyconstraintsTokenScanner.java | DarwinSPL/DarwinSPL | d243805ba5a6fc7c1adec94cc81a5d160ccf5a8a | [
"Apache-2.0"
] | 4 | 2017-10-17T11:48:02.000Z | 2018-10-04T09:12:33.000Z | /**
* <copyright>
* </copyright>
*
*
*/
package eu.hyvar.feature.constraint.resource.hyconstraints.ui;
import org.eclipse.jface.text.rules.ITokenScanner;
public interface IHyconstraintsTokenScanner extends ITokenScanner {
public String getTokenText();
}
| 16.6875 | 67 | 0.749064 |
08085a3b393e5856f8e2371e3e180959d703f110 | 28,544 | html | HTML | lib/rampart-1.6.2/docs/apidocs/org/apache/rahas/SimpleTokenStore.html | cefeboru/AIEP-GradeExtract | 6f37c6354cafc80faa69a3aca5faada12d5275f8 | [
"Apache-2.0"
] | null | null | null | lib/rampart-1.6.2/docs/apidocs/org/apache/rahas/SimpleTokenStore.html | cefeboru/AIEP-GradeExtract | 6f37c6354cafc80faa69a3aca5faada12d5275f8 | [
"Apache-2.0"
] | null | null | null | lib/rampart-1.6.2/docs/apidocs/org/apache/rahas/SimpleTokenStore.html | cefeboru/AIEP-GradeExtract | 6f37c6354cafc80faa69a3aca5faada12d5275f8 | [
"Apache-2.0"
] | null | null | null | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.6.0_22) on Thu Apr 26 14:22:13 IST 2012 -->
<TITLE>
SimpleTokenStore (Apache Rampart API)
</TITLE>
<META NAME="date" CONTENT="2012-04-26">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../stylesheet.css" TITLE="Style">
<SCRIPT type="text/javascript">
function windowTitle()
{
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="SimpleTokenStore (Apache Rampart API)";
}
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>
</HEAD>
<BODY BGCOLOR="white" onload="windowTitle();">
<HR>
<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/SimpleTokenStore.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../org/apache/rahas/RampartSAMLBootstrap.html" title="class in org.apache.rahas"><B>PREV CLASS</B></A>
<A HREF="../../../org/apache/rahas/STSMessageReceiver.html" title="class in org.apache.rahas"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../index.html?org/apache/rahas/SimpleTokenStore.html" target="_top"><B>FRAMES</B></A>
<A HREF="SimpleTokenStore.html" target="_top"><B>NO FRAMES</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: NESTED | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
org.apache.rahas</FONT>
<BR>
Class SimpleTokenStore</H2>
<PRE>
java.lang.Object
<IMG SRC="../../../resources/inherit.gif" ALT="extended by "><B>org.apache.rahas.SimpleTokenStore</B>
</PRE>
<DL>
<DT><B>All Implemented Interfaces:</B> <DD>java.io.Serializable, <A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A></DD>
</DL>
<HR>
<DL>
<DT><PRE>public class <B>SimpleTokenStore</B><DT>extends java.lang.Object<DT>implements <A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A>, java.io.Serializable</DL>
</PRE>
<P>
In-memory implementation of the token storage
<P>
<P>
<DL>
<DT><B>See Also:</B><DD><A HREF="../../../serialized-form.html#org.apache.rahas.SimpleTokenStore">Serialized Form</A></DL>
<HR>
<P>
<!-- =========== FIELD SUMMARY =========== -->
<A NAME="field_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Field Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected java.util.concurrent.locks.Lock</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#readLock">readLock</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected java.util.concurrent.locks.ReadWriteLock</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#readWriteLock">readWriteLock</A></B></CODE>
<BR>
We use a read write lock to improve concurrency while avoiding concurrent modification
exceptions.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected java.util.Map</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#tokens">tokens</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected java.util.concurrent.locks.Lock</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#writeLock">writeLock</A></B></CODE>
<BR>
</TD>
</TR>
</TABLE>
<A NAME="fields_inherited_from_class_org.apache.rahas.TokenStorage"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Fields inherited from interface org.apache.rahas.<A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A></B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#TOKEN_STORAGE_KEY">TOKEN_STORAGE_KEY</A></CODE></TD>
</TR>
</TABLE>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#SimpleTokenStore()">SimpleTokenStore</A></B>()</CODE>
<BR>
</TD>
</TR>
</TABLE>
<!-- ========== METHOD SUMMARY =========== -->
<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Method Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#add(org.apache.rahas.Token)">add</A></B>(<A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A> token)</CODE>
<BR>
Add the given token to the list.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A>[]</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#getCancelledTokens()">getCancelledTokens</A></B>()</CODE>
<BR>
Return the list of CANCELLED tokens</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A>[]</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#getExpiredTokens()">getExpiredTokens</A></B>()</CODE>
<BR>
Return the list of <code>EXPIRED</code> tokens.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#getIdFromSTR(org.apache.axiom.om.OMElement)">getIdFromSTR</A></B>(org.apache.axiom.om.OMElement str)</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A>[]</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#getRenewedTokens()">getRenewedTokens</A></B>()</CODE>
<BR>
Return the list of RENEWED tokens.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#getToken(java.lang.String)">getToken</A></B>(java.lang.String id)</CODE>
<BR>
Returns the <code>Token</code> of the given id</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> java.lang.String[]</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#getTokenIdentifiers()">getTokenIdentifiers</A></B>()</CODE>
<BR>
Return the list of all token identifiers.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A>[]</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#getValidTokens()">getValidTokens</A></B>()</CODE>
<BR>
Return the list of ISSUED and RENEWED tokens.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>protected void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#processTokenExpiry()">processTokenExpiry</A></B>()</CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#removeToken(java.lang.String)">removeToken</A></B>(java.lang.String id)</CODE>
<BR>
Removes the given token from token storage.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../org/apache/rahas/SimpleTokenStore.html#update(org.apache.rahas.Token)">update</A></B>(<A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A> token)</CODE>
<BR>
Update an existing token.</TD>
</TR>
</TABLE>
<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Methods inherited from class java.lang.Object</B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
<P>
<!-- ============ FIELD DETAIL =========== -->
<A NAME="field_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Field Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="tokens"><!-- --></A><H3>
tokens</H3>
<PRE>
protected java.util.Map <B>tokens</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="readWriteLock"><!-- --></A><H3>
readWriteLock</H3>
<PRE>
protected final java.util.concurrent.locks.ReadWriteLock <B>readWriteLock</B></PRE>
<DL>
<DD>We use a read write lock to improve concurrency while avoiding concurrent modification
exceptions. We allow concurrent reads and avoid concurrent reads and modifications
ReentrantReadWriteLock supports a maximum of 65535 recursive write locks and 65535 read locks
<P>
<DL>
</DL>
</DL>
<HR>
<A NAME="readLock"><!-- --></A><H3>
readLock</H3>
<PRE>
protected final java.util.concurrent.locks.Lock <B>readLock</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="writeLock"><!-- --></A><H3>
writeLock</H3>
<PRE>
protected final java.util.concurrent.locks.Lock <B>writeLock</B></PRE>
<DL>
<DL>
</DL>
</DL>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="SimpleTokenStore()"><!-- --></A><H3>
SimpleTokenStore</H3>
<PRE>
public <B>SimpleTokenStore</B>()</PRE>
<DL>
</DL>
<!-- ============ METHOD DETAIL ========== -->
<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Method Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="add(org.apache.rahas.Token)"><!-- --></A><H3>
add</H3>
<PRE>
public void <B>add</B>(<A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A> token)
throws <A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#add(org.apache.rahas.Token)">TokenStorage</A></CODE></B></DD>
<DD>Add the given token to the list.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#add(org.apache.rahas.Token)">add</A></CODE> in interface <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>token</CODE> - The token to be added
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="update(org.apache.rahas.Token)"><!-- --></A><H3>
update</H3>
<PRE>
public void <B>update</B>(<A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A> token)
throws <A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#update(org.apache.rahas.Token)">TokenStorage</A></CODE></B></DD>
<DD>Update an existing token.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#update(org.apache.rahas.Token)">update</A></CODE> in interface <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="getTokenIdentifiers()"><!-- --></A><H3>
getTokenIdentifiers</H3>
<PRE>
public java.lang.String[] <B>getTokenIdentifiers</B>()
throws <A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getTokenIdentifiers()">TokenStorage</A></CODE></B></DD>
<DD>Return the list of all token identifiers.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getTokenIdentifiers()">getTokenIdentifiers</A></CODE> in interface <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>As array of token identifiers
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="getValidTokens()"><!-- --></A><H3>
getValidTokens</H3>
<PRE>
public <A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A>[] <B>getValidTokens</B>()
throws <A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getValidTokens()">TokenStorage</A></CODE></B></DD>
<DD>Return the list of ISSUED and RENEWED tokens.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getValidTokens()">getValidTokens</A></CODE> in interface <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>An array of ISSUED and RENEWED <code>Tokens</code>.
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="getRenewedTokens()"><!-- --></A><H3>
getRenewedTokens</H3>
<PRE>
public <A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A>[] <B>getRenewedTokens</B>()
throws <A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getRenewedTokens()">TokenStorage</A></CODE></B></DD>
<DD>Return the list of RENEWED tokens.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getRenewedTokens()">getRenewedTokens</A></CODE> in interface <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>An array of RENEWED <code>Tokens</code>
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="getCancelledTokens()"><!-- --></A><H3>
getCancelledTokens</H3>
<PRE>
public <A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A>[] <B>getCancelledTokens</B>()
throws <A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getCancelledTokens()">TokenStorage</A></CODE></B></DD>
<DD>Return the list of CANCELLED tokens
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getCancelledTokens()">getCancelledTokens</A></CODE> in interface <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>An array of CANCELLED <code>Tokens</code>
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="getExpiredTokens()"><!-- --></A><H3>
getExpiredTokens</H3>
<PRE>
public <A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A>[] <B>getExpiredTokens</B>()
throws <A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getExpiredTokens()">TokenStorage</A></CODE></B></DD>
<DD>Return the list of <code>EXPIRED</code> tokens.
If there are no <code>EXPIRED</code> tokens <code>null</code> will be
returned
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getExpiredTokens()">getExpiredTokens</A></CODE> in interface <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>An array of expired <code>Tokens</code>
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="getToken(java.lang.String)"><!-- --></A><H3>
getToken</H3>
<PRE>
public <A HREF="../../../org/apache/rahas/Token.html" title="class in org.apache.rahas">Token</A> <B>getToken</B>(java.lang.String id)
throws <A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getToken(java.lang.String)">TokenStorage</A></CODE></B></DD>
<DD>Returns the <code>Token</code> of the given id
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#getToken(java.lang.String)">getToken</A></CODE> in interface <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>The requested <code>Token</code> identified by the give id
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="removeToken(java.lang.String)"><!-- --></A><H3>
removeToken</H3>
<PRE>
public void <B>removeToken</B>(java.lang.String id)</PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#removeToken(java.lang.String)">TokenStorage</A></CODE></B></DD>
<DD>Removes the given token from token storage.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../org/apache/rahas/TokenStorage.html#removeToken(java.lang.String)">removeToken</A></CODE> in interface <CODE><A HREF="../../../org/apache/rahas/TokenStorage.html" title="interface in org.apache.rahas">TokenStorage</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>id</CODE> - Token id to remove.</DL>
</DD>
</DL>
<HR>
<A NAME="processTokenExpiry()"><!-- --></A><H3>
processTokenExpiry</H3>
<PRE>
protected void <B>processTokenExpiry</B>()
throws <A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></PRE>
<DL>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Throws:</B>
<DD><CODE><A HREF="../../../org/apache/rahas/TrustException.html" title="class in org.apache.rahas">TrustException</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="getIdFromSTR(org.apache.axiom.om.OMElement)"><!-- --></A><H3>
getIdFromSTR</H3>
<PRE>
public static java.lang.String <B>getIdFromSTR</B>(org.apache.axiom.om.OMElement str)</PRE>
<DL>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/SimpleTokenStore.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../org/apache/rahas/RampartSAMLBootstrap.html" title="class in org.apache.rahas"><B>PREV CLASS</B></A>
<A HREF="../../../org/apache/rahas/STSMessageReceiver.html" title="class in org.apache.rahas"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../index.html?org/apache/rahas/SimpleTokenStore.html" target="_top"><B>FRAMES</B></A>
<A HREF="SimpleTokenStore.html" target="_top"><B>NO FRAMES</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: NESTED | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<HR>
</BODY>
</HTML>
| 43.84639 | 280 | 0.650785 |
56bcd1b503f8c88e70cb5e94cb500528cf28e0ab | 551 | ts | TypeScript | src/day1/main.ts | staszewski/adventofcode2019 | 2beecc4b9b73c1b9e2325ec33c05edcbe9ce72e5 | [
"Apache-2.0"
] | 1 | 2019-12-05T18:33:26.000Z | 2019-12-05T18:33:26.000Z | src/day1/main.ts | staszewski/adventofcode2019 | 2beecc4b9b73c1b9e2325ec33c05edcbe9ce72e5 | [
"Apache-2.0"
] | null | null | null | src/day1/main.ts | staszewski/adventofcode2019 | 2beecc4b9b73c1b9e2325ec33c05edcbe9ce72e5 | [
"Apache-2.0"
] | null | null | null | import * as fs from 'fs';
import * as path from 'path';
const readFile = () => {
try {
return fs.readFileSync(path.join(__dirname, '../../../src/day1/input.txt'), "utf-8").split("\n")
} catch (e) {
return e
}
}
const massModulesData: string[] = readFile()
const calculateFule = (module: string) => {
return Math.floor(Number(module) / 3) - 2
}
const fuelData = massModulesData.map(calculateFule)
const sum = (input: number[]) => {
return input.reduce((a: number, b: number) => {
return a + b;
});
}
console.log(sum(fuelData))
| 20.407407 | 99 | 0.622505 |
8e39fb1db6db594d17b119e247bfe34dc816b338 | 2,799 | rb | Ruby | app/controllers/snakes_controller.rb | billyliberty/all-the-snakes | 0dc80b0c3dae9d63a71aca83b228003f40a29463 | [
"MIT",
"Unlicense"
] | null | null | null | app/controllers/snakes_controller.rb | billyliberty/all-the-snakes | 0dc80b0c3dae9d63a71aca83b228003f40a29463 | [
"MIT",
"Unlicense"
] | 5 | 2020-02-26T00:09:29.000Z | 2022-02-26T05:18:51.000Z | app/controllers/snakes_controller.rb | billyliberty/all-the-snakes | 0dc80b0c3dae9d63a71aca83b228003f40a29463 | [
"MIT",
"Unlicense"
] | null | null | null | class SnakesController < ApplicationController
# If user is logged in, index of snakes can be viewed. This renders the index page.
get '/snakes' do
if logged_in?
@snakes = Snake.all
erb :'snakes/index'
else
redirect to "/hunters/#{@hunter.id}"
end
end
# If user is logged in, new snake entry can be created. This renders the creation page.
get '/snakes/new' do
if logged_in?
erb :'snakes/new'
else
redirect to "/"
end
end
# If user is logged in, new snake entry can be created. This creates the entry in the database.
post '/snakes' do
if !logged_in?
redirect to "/"
end
if params[:content] != "" || params[:length] != "" || params[:weight] != "" || params[:monetary_value != ""]
@snake = Snake.new(:content => params[:content], :length => params[:length], :weight => params[:weight], :monetary_value => params[:monetary_value], hunter_id: current_hunter.id )
@snake.save
redirect to "/snakes/#{@snake.id}"
else redirect to "/snakes/new"
end
end
# If user is logged in, user can edit their addition to the database. Users can only edit their own additions. This renders the edit page.
get '/snakes/:id/edit' do
find_snake
if logged_in?
if @snake.hunter == current_hunter
erb :'/snakes/edit'
else
redirect to "hunters/#{current_hunter.id}"
end
else
redirect to "/"
end
end
# If user is logged in, user can edit their own addition to the database. This updates the database with the edit.
patch '/snakes/:id' do
find_snake
if logged_in?
if @snake.hunter == current_hunter
@snake.update(:content => params[:content], :length => params[:length], :weight => params[:weight], :monetary_value => params[:monetary_value])
redirect to "snakes/#{@snake.id}"
else
redirect to "users/#{current_hunter.id}"
end
else
redirect to "/"
end
end
# This is a show route for the addition.
get "/snakes/:id" do
if logged_in?
find_snake
erb :'/snakes/show'
else
redirect to "/"
end
end
# This permits the deletion of an addition from the database. Users can only delete their own additions.
delete '/snakes/:id' do
find_snake
@snake = Snake.find(params[:id])
if @snake.hunter == current_hunter
@snake.destroy
flash[:message] = "Deletion Successful"
redirect to "/"
else
redirect '/'
end
end
private
# This is a helper method for only this controller that locates an addition by its ID and saves it as an instance variable.
def find_snake
@snake = Snake.find_by(id: params[:id])
end
end | 26.158879 | 185 | 0.617363 |
fd8735d6e1e805be1463e32f6b20be2768826050 | 1,028 | h | C | compator/road/bound.h | yuchenECNU/VTree | 32f98206b85cc9ac96f352c346c6316cf81efdca | [
"Unlicense"
] | null | null | null | compator/road/bound.h | yuchenECNU/VTree | 32f98206b85cc9ac96f352c346c6316cf81efdca | [
"Unlicense"
] | null | null | null | compator/road/bound.h | yuchenECNU/VTree | 32f98206b85cc9ac96f352c346c6316cf81efdca | [
"Unlicense"
] | null | null | null | /* ----------------------------------------------------------------------------
Author: Ken C. K. Lee
Email: cklee@cse.psu.edu
Copyright(c) Ken C. K. Lee 2008
This header file declares Bound class.
This defines the volume bound.
---------------------------------------------------------------------------- */
#ifndef BOUND_DEFINED
#define BOUND_DEFINED
#include "point.h"
class Bound
{
public:
const Point m_lower; // lower bound
const Point m_upper; // upper bound
public:
// constructor/destructor
Bound(const Point& a_lower, const Point& a_upper);
virtual ~Bound();
//
// search
virtual int dimen() const;
virtual Point center() const;
//
// is this bound containing another (in param)
virtual bool contain(const Bound& a_bound) const;
virtual bool contain(const Point& a_point) const;
virtual float mindist(const Point& a_pt) const;
virtual bool equal(const Bound& a_bound) const;
//
// info
static int size(const int a_dimen); // storage size
};
#endif
| 25.073171 | 79 | 0.582685 |
71450a83543973c3e03de328279577f480c645c1 | 186 | ts | TypeScript | lib/typescript/src/SceneMap.d.ts | EugeneDraitsev/react-native-tab-view | f1c4e9fe219ba5bd78c0098a203cc48d1616fcc1 | [
"MIT"
] | 1 | 2020-12-11T11:55:02.000Z | 2020-12-11T11:55:02.000Z | lib/typescript/src/SceneMap.d.ts | EugeneDraitsev/react-native-tab-view | f1c4e9fe219ba5bd78c0098a203cc48d1616fcc1 | [
"MIT"
] | 9 | 2020-12-11T10:35:55.000Z | 2022-02-27T10:59:58.000Z | Mobile/node_modules/react-native-tab-view/lib/typescript/src/SceneMap.d.ts | MuriloMilani8870/M_Cleveland_Sprint4_FabioMurilo | c6ec3451be2026208cb56dc207f70a9aa2eee7c3 | [
"MIT"
] | 1 | 2020-12-09T15:32:55.000Z | 2020-12-09T15:32:55.000Z | import * as React from 'react';
export default function SceneMap<T extends any>(scenes: {
[key: string]: React.ComponentType<T>;
}): ({ route, jumpTo, position }: T) => JSX.Element;
| 37.2 | 57 | 0.677419 |
0cbded3b957b5b9247296e61a096662c54742d11 | 774 | py | Python | programming_fundamentals/python_part_2/common_vars.py | tobaidullah/2 | 3fa67855ef461ccaee283dcbbdd9bf00e7a52378 | [
"MIT"
] | 629 | 2017-12-15T20:26:13.000Z | 2022-03-30T04:02:02.000Z | programming_fundamentals/python_part_2/common_vars.py | tobaidullah/2 | 3fa67855ef461ccaee283dcbbdd9bf00e7a52378 | [
"MIT"
] | 40 | 2018-01-18T09:07:50.000Z | 2021-09-23T23:21:47.000Z | programming_fundamentals/python_part_2/common_vars.py | tobaidullah/2 | 3fa67855ef461ccaee283dcbbdd9bf00e7a52378 | [
"MIT"
] | 394 | 2017-12-18T22:35:36.000Z | 2022-03-29T19:41:25.000Z | #! /usr/bin/env python
"""
Learning Series: Network Programmability Basics
Module: Programming Fundamentals
Lesson: Python Part 2
Author: Hank Preston <hapresto@cisco.com>
common_vars.py
Illustrate the following concepts:
- Code reuse
imported into other examples
"""
shapes = ["square", "triangle", "circle"]
books = [
{
"title": "War and Peace",
"shelf": 3,
"available": True
},
{
"title": "Hamlet",
"shelf": 1,
"available": False
},
{
"title": "Harold and the Purple Crayon",
"shelf": 2,
"available": True
}
]
colors = ["blue", "green", "red"]
| 22.764706 | 56 | 0.485788 |
4e547113e2075e4ea2a3ae533d3ed55eb44b69d9 | 884 | kt | Kotlin | src/main/kotlin/de/unihalle/informatik/bigdata/millionsongdataset/analysis/hadoop/SelectableTool.kt | dmitrijBerg/song-analysis | 86cccb20b2321059469f085f285302e8a0cbd6d6 | [
"MIT"
] | 4 | 2018-06-20T02:05:07.000Z | 2018-06-28T09:38:32.000Z | src/main/kotlin/de/unihalle/informatik/bigdata/millionsongdataset/analysis/hadoop/SelectableTool.kt | dmitrijBerg/song-analysis | 86cccb20b2321059469f085f285302e8a0cbd6d6 | [
"MIT"
] | 2 | 2018-06-21T22:45:29.000Z | 2021-05-27T23:24:32.000Z | src/main/kotlin/de/unihalle/informatik/bigdata/millionsongdataset/analysis/hadoop/SelectableTool.kt | dmitrijBerg/song-analysis | 86cccb20b2321059469f085f285302e8a0cbd6d6 | [
"MIT"
] | 1 | 2018-06-24T20:05:15.000Z | 2018-06-24T20:05:15.000Z | package de.unihalle.informatik.bigdata.millionsongdataset.analysis.hadoop
import de.unihalle.informatik.bigdata.millionsongdataset.analysis.extensions.hadoop.configuration
import org.apache.hadoop.conf.Configurable
import org.apache.hadoop.conf.Configured
import org.apache.hadoop.util.Tool
class SelectableTool(
private val selectTool: (toolName: String) -> Tool
) : Tool, Configurable by Configured() {
override fun run(arguments: Array<String>?): Int {
if (arguments == null) {
throw IllegalArgumentException("Missing program arguments.")
}
if (arguments.isEmpty() || arguments[0].isEmpty()) {
throw IllegalArgumentException("Missing analysis tool name.")
}
val tool = selectTool(arguments[0])
tool.configuration = configuration
return tool.run(arguments.drop(1).toTypedArray())
}
} | 38.434783 | 97 | 0.709276 |
b2695aadcdeee6f16f19dc35ad587c3c3a0883be | 644 | sql | SQL | openGaussBase/testcase/KEYWORDS/Iterate/Opengauss_Function_Keyword_Iterate_Case0029.sql | opengauss-mirror/Yat | aef107a8304b94e5d99b4f1f36eb46755eb8919e | [
"MulanPSL-1.0"
] | null | null | null | openGaussBase/testcase/KEYWORDS/Iterate/Opengauss_Function_Keyword_Iterate_Case0029.sql | opengauss-mirror/Yat | aef107a8304b94e5d99b4f1f36eb46755eb8919e | [
"MulanPSL-1.0"
] | null | null | null | openGaussBase/testcase/KEYWORDS/Iterate/Opengauss_Function_Keyword_Iterate_Case0029.sql | opengauss-mirror/Yat | aef107a8304b94e5d99b4f1f36eb46755eb8919e | [
"MulanPSL-1.0"
] | null | null | null | -- @testpoint:opengauss关键字Iterate(非保留),作为表空间名
--关键字不带引号,创建成功
drop tablespace if exists Iterate;
CREATE TABLESPACE Iterate RELATIVE LOCATION 'hdfs_tablespace/hdfs_tablespace_1';
drop tablespace Iterate;
--关键字带双引号,创建成功
drop tablespace if exists "Iterate";
CREATE TABLESPACE "Iterate" RELATIVE LOCATION 'hdfs_tablespace/hdfs_tablespace_1';
drop tablespace "Iterate";
--关键字带单引号,合理报错
drop tablespace if exists 'Iterate';
CREATE TABLESPACE 'Iterate' RELATIVE LOCATION 'hdfs_tablespace/hdfs_tablespace_1';
--关键字带反引号,合理报错
drop tablespace if exists `Iterate`;
CREATE TABLESPACE `Iterate` RELATIVE LOCATION 'hdfs_tablespace/hdfs_tablespace_1';
| 29.272727 | 83 | 0.812112 |
2d8c0626d12bfcab6a04bd7efff05ab0ee6309d6 | 171,740 | html | HTML | robocode_master_backup/javadoc/robocode/AdvancedRobot.html | TomPlum/university_major_project | 915e009b34a563b1861cb82832e6ce2692ccf4fc | [
"Apache-2.0"
] | null | null | null | robocode_master_backup/javadoc/robocode/AdvancedRobot.html | TomPlum/university_major_project | 915e009b34a563b1861cb82832e6ce2692ccf4fc | [
"Apache-2.0"
] | 8 | 2018-04-17T21:57:28.000Z | 2018-08-10T08:06:58.000Z | robocode_master_backup/javadoc/robocode/AdvancedRobot.html | TomPlum/university_major_project | 915e009b34a563b1861cb82832e6ce2692ccf4fc | [
"Apache-2.0"
] | null | null | null | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!-- NewPage -->
<html lang="da">
<head>
<!-- Generated by javadoc (1.8.0_141) on Tue Oct 17 22:00:18 CEST 2017 -->
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>AdvancedRobot (Robocode 1.9.3.0 API)</title>
<meta name="date" content="2017-10-17">
<link rel="stylesheet" type="text/css" href="../stylesheet.css" title="Style">
<script type="text/javascript" src="../script.js"></script>
</head>
<body>
<script type="text/javascript"><!--
try {
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="AdvancedRobot (Robocode 1.9.3.0 API)";
}
}
catch(err) {
}
//-->
var methods = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10,"i13":10,"i14":10,"i15":10,"i16":10,"i17":10,"i18":10,"i19":10,"i20":10,"i21":10,"i22":10,"i23":10,"i24":10,"i25":10,"i26":10,"i27":10,"i28":10,"i29":10,"i30":10,"i31":10,"i32":10,"i33":10,"i34":10,"i35":10,"i36":10,"i37":10,"i38":10,"i39":10,"i40":10,"i41":10,"i42":10,"i43":10,"i44":10,"i45":10,"i46":10,"i47":10,"i48":10,"i49":10,"i50":10,"i51":10,"i52":10,"i53":10,"i54":10,"i55":10,"i56":10,"i57":10,"i58":10,"i59":10,"i60":10,"i61":10,"i62":10,"i63":10,"i64":10};
var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a name="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../deprecated-list.html">Deprecated</a></li>
<li><a href="../index-all.html">Index</a></li>
<li><a href="../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../robocode/_RobotBase.html" title="class in robocode"><span class="typeNameLink">Prev Class</span></a></li>
<li><a href="../robocode/BattleEndedEvent.html" title="class in robocode"><span class="typeNameLink">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../index.html?robocode/AdvancedRobot.html" target="_top">Frames</a></li>
<li><a href="AdvancedRobot.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_top">
<li><a href="../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_top");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary: </li>
<li>Nested | </li>
<li><a href="#fields.inherited.from.class.robocode._RobotBase">Field</a> | </li>
<li><a href="#constructor.summary">Constr</a> | </li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail: </li>
<li>Field | </li>
<li><a href="#constructor.detail">Constr</a> | </li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.top">
<!-- -->
</a></div>
<!-- ========= END OF TOP NAVBAR ========= -->
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle">robocode</div>
<h2 title="Class AdvancedRobot" class="title">Class AdvancedRobot</h2>
</div>
<div class="contentContainer">
<ul class="inheritance">
<li><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">java.lang.Object</a></li>
<li>
<ul class="inheritance">
<li><a href="../robocode/_RobotBase.html" title="class in robocode">robocode._RobotBase</a></li>
<li>
<ul class="inheritance">
<li><a href="../robocode/_Robot.html" title="class in robocode">robocode._Robot</a></li>
<li>
<ul class="inheritance">
<li><a href="../robocode/Robot.html" title="class in robocode">robocode.Robot</a></li>
<li>
<ul class="inheritance">
<li><a href="../robocode/_AdvancedRobot.html" title="class in robocode">robocode._AdvancedRobot</a></li>
<li>
<ul class="inheritance">
<li><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">robocode._AdvancedRadiansRobot</a></li>
<li>
<ul class="inheritance">
<li>robocode.AdvancedRobot</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</li>
</ul>
<div class="description">
<ul class="blockList">
<li class="blockList">
<dl>
<dt>All Implemented Interfaces:</dt>
<dd><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Runnable.html?is-external=true" title="class or interface in java.lang">Runnable</a>, <a href="../robocode/robotinterfaces/IAdvancedEvents.html" title="interface in robocode.robotinterfaces">IAdvancedEvents</a>, <a href="../robocode/robotinterfaces/IAdvancedRobot.html" title="interface in robocode.robotinterfaces">IAdvancedRobot</a>, <a href="../robocode/robotinterfaces/IBasicEvents.html" title="interface in robocode.robotinterfaces">IBasicEvents</a>, <a href="../robocode/robotinterfaces/IBasicEvents2.html" title="interface in robocode.robotinterfaces">IBasicEvents2</a>, <a href="../robocode/robotinterfaces/IBasicEvents3.html" title="interface in robocode.robotinterfaces">IBasicEvents3</a>, <a href="../robocode/robotinterfaces/IBasicRobot.html" title="interface in robocode.robotinterfaces">IBasicRobot</a>, <a href="../robocode/robotinterfaces/IInteractiveEvents.html" title="interface in robocode.robotinterfaces">IInteractiveEvents</a>, <a href="../robocode/robotinterfaces/IInteractiveRobot.html" title="interface in robocode.robotinterfaces">IInteractiveRobot</a>, <a href="../robocode/robotinterfaces/IPaintEvents.html" title="interface in robocode.robotinterfaces">IPaintEvents</a>, <a href="../robocode/robotinterfaces/IPaintRobot.html" title="interface in robocode.robotinterfaces">IPaintRobot</a></dd>
</dl>
<dl>
<dt>Direct Known Subclasses:</dt>
<dd><a href="../robocode/TeamRobot.html" title="class in robocode">TeamRobot</a></dd>
</dl>
<hr>
<br>
<pre>public class <span class="typeNameLabel">AdvancedRobot</span>
extends <a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a>
implements <a href="../robocode/robotinterfaces/IAdvancedRobot.html" title="interface in robocode.robotinterfaces">IAdvancedRobot</a>, <a href="../robocode/robotinterfaces/IAdvancedEvents.html" title="interface in robocode.robotinterfaces">IAdvancedEvents</a></pre>
<div class="block">A more advanced type of robot than Robot that allows non-blocking calls,
custom events, and writes to the filesystem.
<p>
If you have not already, you should create a <a href="../robocode/Robot.html" title="class in robocode"><code>Robot</code></a> first.</div>
<dl>
<dt><span class="simpleTagLabel">Author:</span></dt>
<dd>Mathew A. Nelson (original), Flemming N. Larsen (contributor), Robert D. Maupin (contributor), Pavel Savara (contributor)</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a target="_top" href="http://robocode.sourceforge.net">
robocode.sourceforge.net</a>,
<a href="http://robocode.sourceforge.net/myfirstrobot/MyFirstRobot.html">
Building your first robot<a>,
<a href="../robocode/JuniorRobot.html" title="class in robocode"><code>JuniorRobot</code></a>,
<a href="../robocode/Robot.html" title="class in robocode"><code>Robot</code></a>,
<a href="../robocode/TeamRobot.html" title="class in robocode"><code>TeamRobot</code></a>,
<a href="../robocode/RateControlRobot.html" title="class in robocode"><code>RateControlRobot</code></a>,
<a href="../robocode/Droid.html" title="interface in robocode"><code>Droid</code></a>,
<a href="../robocode/BorderSentry.html" title="interface in robocode"><code>BorderSentry</code></a></dd>
</dl>
</li>
</ul>
</div>
<div class="summary">
<ul class="blockList">
<li class="blockList">
<!-- =========== FIELD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="field.summary">
<!-- -->
</a>
<h3>Field Summary</h3>
<ul class="blockList">
<li class="blockList"><a name="fields.inherited.from.class.robocode._RobotBase">
<!-- -->
</a>
<h3>Fields inherited from class robocode.<a href="../robocode/_RobotBase.html" title="class in robocode">_RobotBase</a></h3>
<code><a href="../robocode/_RobotBase.html#out">out</a></code></li>
</ul>
</li>
</ul>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor.summary">
<!-- -->
</a>
<h3>Constructor Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Constructor Summary table, listing constructors, and an explanation">
<caption><span>Constructors</span><span class="tabEnd"> </span></caption>
<tr>
<th class="colOne" scope="col">Constructor and Description</th>
</tr>
<tr class="altColor">
<td class="colOne"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#AdvancedRobot--">AdvancedRobot</a></span>()</code> </td>
</tr>
</table>
</li>
</ul>
<!-- ========== METHOD SUMMARY =========== -->
<ul class="blockList">
<li class="blockList"><a name="method.summary">
<!-- -->
</a>
<h3>Method Summary</h3>
<table class="memberSummary" border="0" cellpadding="3" cellspacing="0" summary="Method Summary table, listing methods, and an explanation">
<caption><span id="t0" class="activeTableTab"><span>All Methods</span><span class="tabEnd"> </span></span><span id="t2" class="tableTab"><span><a href="javascript:show(2);">Instance Methods</a></span><span class="tabEnd"> </span></span><span id="t4" class="tableTab"><span><a href="javascript:show(8);">Concrete Methods</a></span><span class="tabEnd"> </span></span></caption>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colLast" scope="col">Method and Description</th>
</tr>
<tr id="i0" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#addCustomEvent-robocode.Condition-">addCustomEvent</a></span>(<a href="../robocode/Condition.html" title="class in robocode">Condition</a> condition)</code>
<div class="block">Registers a custom event to be called when a condition is met.</div>
</td>
</tr>
<tr id="i1" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#clearAllEvents--">clearAllEvents</a></span>()</code>
<div class="block">Clears out any pending events in the robot's event queue immediately.</div>
</td>
</tr>
<tr id="i2" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#execute--">execute</a></span>()</code>
<div class="block">Executes any pending actions, or continues executing actions that are
in process.</div>
</td>
</tr>
<tr id="i3" class="rowColor">
<td class="colFirst"><code><a href="../robocode/robotinterfaces/IAdvancedEvents.html" title="interface in robocode.robotinterfaces">IAdvancedEvents</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getAdvancedEventListener--">getAdvancedEventListener</a></span>()</code>
<div class="block">Do not call this method!</div>
</td>
</tr>
<tr id="i4" class="altColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/Event.html" title="class in robocode">Event</a>></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getAllEvents--">getAllEvents</a></span>()</code>
<div class="block">Returns a vector containing all events currently in the robot's queue.</div>
</td>
</tr>
<tr id="i5" class="rowColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/BulletHitBulletEvent.html" title="class in robocode">BulletHitBulletEvent</a>></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getBulletHitBulletEvents--">getBulletHitBulletEvents</a></span>()</code>
<div class="block">Returns a vector containing all BulletHitBulletEvents currently in the
robot's queue.</div>
</td>
</tr>
<tr id="i6" class="altColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/BulletHitEvent.html" title="class in robocode">BulletHitEvent</a>></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getBulletHitEvents--">getBulletHitEvents</a></span>()</code>
<div class="block">Returns a vector containing all BulletHitEvents currently in the robot's
queue.</div>
</td>
</tr>
<tr id="i7" class="rowColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/BulletMissedEvent.html" title="class in robocode">BulletMissedEvent</a>></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getBulletMissedEvents--">getBulletMissedEvents</a></span>()</code>
<div class="block">Returns a vector containing all BulletMissedEvents currently in the
robot's queue.</div>
</td>
</tr>
<tr id="i8" class="altColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getDataDirectory--">getDataDirectory</a></span>()</code>
<div class="block">Returns a file representing a data directory for the robot, which can be
written to using <a href="../robocode/RobocodeFileOutputStream.html" title="class in robocode"><code>RobocodeFileOutputStream</code></a> or
<a href="../robocode/RobocodeFileWriter.html" title="class in robocode"><code>RobocodeFileWriter</code></a>.</div>
</td>
</tr>
<tr id="i9" class="rowColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getDataFile-java.lang.String-">getDataFile</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> filename)</code>
<div class="block">Returns a file in your data directory that you can write to using
<a href="../robocode/RobocodeFileOutputStream.html" title="class in robocode"><code>RobocodeFileOutputStream</code></a> or <a href="../robocode/RobocodeFileWriter.html" title="class in robocode"><code>RobocodeFileWriter</code></a>.</div>
</td>
</tr>
<tr id="i10" class="altColor">
<td class="colFirst"><code>long</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getDataQuotaAvailable--">getDataQuotaAvailable</a></span>()</code>
<div class="block">Returns the data quota available in your data directory, i.e. the amount
of bytes left in the data directory for the robot.</div>
</td>
</tr>
<tr id="i11" class="rowColor">
<td class="colFirst"><code>double</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getDistanceRemaining--">getDistanceRemaining</a></span>()</code>
<div class="block">Returns the distance remaining in the robot's current move measured in
pixels.</div>
</td>
</tr>
<tr id="i12" class="altColor">
<td class="colFirst"><code>int</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getEventPriority-java.lang.String-">getEventPriority</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> eventClass)</code>
<div class="block">Returns the current priority of a class of events.</div>
</td>
</tr>
<tr id="i13" class="rowColor">
<td class="colFirst"><code>double</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getGunHeadingRadians--">getGunHeadingRadians</a></span>()</code>
<div class="block">Returns the direction that the robot's gun is facing, in radians.</div>
</td>
</tr>
<tr id="i14" class="altColor">
<td class="colFirst"><code>double</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getGunTurnRemaining--">getGunTurnRemaining</a></span>()</code>
<div class="block">Returns the angle remaining in the gun's turn, in degrees.</div>
</td>
</tr>
<tr id="i15" class="rowColor">
<td class="colFirst"><code>double</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getGunTurnRemainingRadians--">getGunTurnRemainingRadians</a></span>()</code>
<div class="block">Returns the angle remaining in the gun's turn, in radians.</div>
</td>
</tr>
<tr id="i16" class="altColor">
<td class="colFirst"><code>double</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getHeadingRadians--">getHeadingRadians</a></span>()</code>
<div class="block">Returns the direction that the robot's body is facing, in radians.</div>
</td>
</tr>
<tr id="i17" class="rowColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/HitByBulletEvent.html" title="class in robocode">HitByBulletEvent</a>></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getHitByBulletEvents--">getHitByBulletEvents</a></span>()</code>
<div class="block">Returns a vector containing all HitByBulletEvents currently in the
robot's queue.</div>
</td>
</tr>
<tr id="i18" class="altColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/HitRobotEvent.html" title="class in robocode">HitRobotEvent</a>></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getHitRobotEvents--">getHitRobotEvents</a></span>()</code>
<div class="block">Returns a vector containing all HitRobotEvents currently in the robot's
queue.</div>
</td>
</tr>
<tr id="i19" class="rowColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/HitWallEvent.html" title="class in robocode">HitWallEvent</a>></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getHitWallEvents--">getHitWallEvents</a></span>()</code>
<div class="block">Returns a vector containing all HitWallEvents currently in the robot's
queue.</div>
</td>
</tr>
<tr id="i20" class="altColor">
<td class="colFirst"><code>double</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getRadarHeadingRadians--">getRadarHeadingRadians</a></span>()</code>
<div class="block">Returns the direction that the robot's radar is facing, in radians.</div>
</td>
</tr>
<tr id="i21" class="rowColor">
<td class="colFirst"><code>double</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getRadarTurnRemaining--">getRadarTurnRemaining</a></span>()</code>
<div class="block">Returns the angle remaining in the radar's turn, in degrees.</div>
</td>
</tr>
<tr id="i22" class="altColor">
<td class="colFirst"><code>double</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getRadarTurnRemainingRadians--">getRadarTurnRemainingRadians</a></span>()</code>
<div class="block">Returns the angle remaining in the radar's turn, in radians.</div>
</td>
</tr>
<tr id="i23" class="rowColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/RobotDeathEvent.html" title="class in robocode">RobotDeathEvent</a>></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getRobotDeathEvents--">getRobotDeathEvents</a></span>()</code>
<div class="block">Returns a vector containing all RobotDeathEvents currently in the robot's
queue.</div>
</td>
</tr>
<tr id="i24" class="altColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/ScannedRobotEvent.html" title="class in robocode">ScannedRobotEvent</a>></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getScannedRobotEvents--">getScannedRobotEvents</a></span>()</code>
<div class="block">Returns a vector containing all ScannedRobotEvents currently in the
robot's queue.</div>
</td>
</tr>
<tr id="i25" class="rowColor">
<td class="colFirst"><code><a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/StatusEvent.html" title="class in robocode">StatusEvent</a>></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getStatusEvents--">getStatusEvents</a></span>()</code>
<div class="block">Returns a vector containing all StatusEvents currently in the robot's
queue.</div>
</td>
</tr>
<tr id="i26" class="altColor">
<td class="colFirst"><code>double</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getTurnRemaining--">getTurnRemaining</a></span>()</code>
<div class="block">Returns the angle remaining in the robots's turn, in degrees.</div>
</td>
</tr>
<tr id="i27" class="rowColor">
<td class="colFirst"><code>double</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#getTurnRemainingRadians--">getTurnRemainingRadians</a></span>()</code>
<div class="block">Returns the angle remaining in the robot's turn, in radians.</div>
</td>
</tr>
<tr id="i28" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#isAdjustGunForRobotTurn--">isAdjustGunForRobotTurn</a></span>()</code>
<div class="block">Checks if the gun is set to adjust for the robot turning, i.e. to turn
independent from the robot's body turn.</div>
</td>
</tr>
<tr id="i29" class="rowColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#isAdjustRadarForGunTurn--">isAdjustRadarForGunTurn</a></span>()</code>
<div class="block">Checks if the radar is set to adjust for the gun turning, i.e. to turn
independent from the gun's turn.</div>
</td>
</tr>
<tr id="i30" class="altColor">
<td class="colFirst"><code>boolean</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#isAdjustRadarForRobotTurn--">isAdjustRadarForRobotTurn</a></span>()</code>
<div class="block">Checks if the radar is set to adjust for the robot turning, i.e. to turn
independent from the robot's body turn.</div>
</td>
</tr>
<tr id="i31" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#onCustomEvent-robocode.CustomEvent-">onCustomEvent</a></span>(<a href="../robocode/CustomEvent.html" title="class in robocode">CustomEvent</a> event)</code>
<div class="block">This method is called when a custom condition is met.</div>
</td>
</tr>
<tr id="i32" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#onDeath-robocode.DeathEvent-">onDeath</a></span>(<a href="../robocode/DeathEvent.html" title="class in robocode">DeathEvent</a> event)</code>
<div class="block">This method is called if your robot dies.</div>
</td>
</tr>
<tr id="i33" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#onSkippedTurn-robocode.SkippedTurnEvent-">onSkippedTurn</a></span>(<a href="../robocode/SkippedTurnEvent.html" title="class in robocode">SkippedTurnEvent</a> event)</code>
<div class="block">This method is called if the robot is using too much time between
actions.</div>
</td>
</tr>
<tr id="i34" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#removeCustomEvent-robocode.Condition-">removeCustomEvent</a></span>(<a href="../robocode/Condition.html" title="class in robocode">Condition</a> condition)</code>
<div class="block">Removes a custom event that was previously added by calling
<a href="../robocode/AdvancedRobot.html#addCustomEvent-robocode.Condition-"><code>addCustomEvent(Condition)</code></a>.</div>
</td>
</tr>
<tr id="i35" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setAhead-double-">setAhead</a></span>(double distance)</code>
<div class="block">Sets the robot to move ahead (forward) by distance measured in pixels
when the next execution takes place.</div>
</td>
</tr>
<tr id="i36" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setBack-double-">setBack</a></span>(double distance)</code>
<div class="block">Sets the robot to move back by distance measured in pixels when the next
execution takes place.</div>
</td>
</tr>
<tr id="i37" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setEventPriority-java.lang.String-int-">setEventPriority</a></span>(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> eventClass,
int priority)</code>
<div class="block">Sets the priority of a class of events.</div>
</td>
</tr>
<tr id="i38" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setFire-double-">setFire</a></span>(double power)</code>
<div class="block">Sets the gun to fire a bullet when the next execution takes place.</div>
</td>
</tr>
<tr id="i39" class="rowColor">
<td class="colFirst"><code><a href="../robocode/Bullet.html" title="class in robocode">Bullet</a></code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setFireBullet-double-">setFireBullet</a></span>(double power)</code>
<div class="block">Sets the gun to fire a bullet when the next execution takes place.</div>
</td>
</tr>
<tr id="i40" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setInterruptible-boolean-">setInterruptible</a></span>(boolean interruptible)</code>
<div class="block">Call this during an event handler to allow new events of the same
priority to restart the event handler.</div>
</td>
</tr>
<tr id="i41" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setMaxTurnRate-double-">setMaxTurnRate</a></span>(double newMaxTurnRate)</code>
<div class="block">Sets the maximum turn rate of the robot measured in degrees if the robot
should turn slower than <a href="../robocode/Rules.html#MAX_TURN_RATE"><code>Rules.MAX_TURN_RATE</code></a> (10 degress/turn).</div>
</td>
</tr>
<tr id="i42" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setMaxVelocity-double-">setMaxVelocity</a></span>(double newMaxVelocity)</code>
<div class="block">Sets the maximum velocity of the robot measured in pixels/turn if the
robot should move slower than <a href="../robocode/Rules.html#MAX_VELOCITY"><code>Rules.MAX_VELOCITY</code></a> (8 pixels/turn).</div>
</td>
</tr>
<tr id="i43" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setResume--">setResume</a></span>()</code>
<div class="block">Sets the robot to resume the movement stopped by <a href="../robocode/Robot.html#stop--"><code>stop()</code></a>
or <a href="../robocode/AdvancedRobot.html#setStop--"><code>setStop()</code></a>, if any.</div>
</td>
</tr>
<tr id="i44" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setStop--">setStop</a></span>()</code>
<div class="block">This call is identical to <a href="../robocode/Robot.html#stop--"><code>stop()</code></a>, but returns immediately, and
will not execute until you call <a href="../robocode/AdvancedRobot.html#execute--"><code>execute()</code></a> or take an action that
executes.</div>
</td>
</tr>
<tr id="i45" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setStop-boolean-">setStop</a></span>(boolean overwrite)</code>
<div class="block">This call is identical to <a href="../robocode/Robot.html#stop-boolean-"><code>stop(boolean)</code></a>, but
returns immediately, and will not execute until you call
<a href="../robocode/AdvancedRobot.html#execute--"><code>execute()</code></a> or take an action that executes.</div>
</td>
</tr>
<tr id="i46" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnGunLeft-double-">setTurnGunLeft</a></span>(double degrees)</code>
<div class="block">Sets the robot's gun to turn left by degrees when the next execution
takes place.</div>
</td>
</tr>
<tr id="i47" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnGunLeftRadians-double-">setTurnGunLeftRadians</a></span>(double radians)</code>
<div class="block">Sets the robot's gun to turn left by radians when the next execution
takes place.</div>
</td>
</tr>
<tr id="i48" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnGunRight-double-">setTurnGunRight</a></span>(double degrees)</code>
<div class="block">Sets the robot's gun to turn right by degrees when the next execution
takes place.</div>
</td>
</tr>
<tr id="i49" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnGunRightRadians-double-">setTurnGunRightRadians</a></span>(double radians)</code>
<div class="block">Sets the robot's gun to turn right by radians when the next execution
takes place.</div>
</td>
</tr>
<tr id="i50" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnLeft-double-">setTurnLeft</a></span>(double degrees)</code>
<div class="block">Sets the robot's body to turn left by degrees when the next execution
takes place.</div>
</td>
</tr>
<tr id="i51" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnLeftRadians-double-">setTurnLeftRadians</a></span>(double radians)</code>
<div class="block">Sets the robot's body to turn left by radians when the next execution
takes place.</div>
</td>
</tr>
<tr id="i52" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnRadarLeft-double-">setTurnRadarLeft</a></span>(double degrees)</code>
<div class="block">Sets the robot's radar to turn left by degrees when the next execution
takes place.</div>
</td>
</tr>
<tr id="i53" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnRadarLeftRadians-double-">setTurnRadarLeftRadians</a></span>(double radians)</code>
<div class="block">Sets the robot's radar to turn left by radians when the next execution
takes place.</div>
</td>
</tr>
<tr id="i54" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnRadarRight-double-">setTurnRadarRight</a></span>(double degrees)</code>
<div class="block">Sets the robot's radar to turn right by degrees when the next execution
takes place.</div>
</td>
</tr>
<tr id="i55" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnRadarRightRadians-double-">setTurnRadarRightRadians</a></span>(double radians)</code>
<div class="block">Sets the robot's radar to turn right by radians when the next execution
takes place.</div>
</td>
</tr>
<tr id="i56" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnRight-double-">setTurnRight</a></span>(double degrees)</code>
<div class="block">Sets the robot's body to turn right by degrees when the next execution
takes place.</div>
</td>
</tr>
<tr id="i57" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#setTurnRightRadians-double-">setTurnRightRadians</a></span>(double radians)</code>
<div class="block">Sets the robot's body to turn right by radians when the next execution
takes place.</div>
</td>
</tr>
<tr id="i58" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#turnGunLeftRadians-double-">turnGunLeftRadians</a></span>(double radians)</code>
<div class="block">Immediately turns the robot's gun to the left by radians.</div>
</td>
</tr>
<tr id="i59" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#turnGunRightRadians-double-">turnGunRightRadians</a></span>(double radians)</code>
<div class="block">Immediately turns the robot's gun to the right by radians.</div>
</td>
</tr>
<tr id="i60" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#turnLeftRadians-double-">turnLeftRadians</a></span>(double radians)</code>
<div class="block">Immediately turns the robot's body to the left by radians.</div>
</td>
</tr>
<tr id="i61" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#turnRadarLeftRadians-double-">turnRadarLeftRadians</a></span>(double radians)</code>
<div class="block">Immediately turns the robot's radar to the left by radians.</div>
</td>
</tr>
<tr id="i62" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#turnRadarRightRadians-double-">turnRadarRightRadians</a></span>(double radians)</code>
<div class="block">Immediately turns the robot's radar to the right by radians.</div>
</td>
</tr>
<tr id="i63" class="rowColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#turnRightRadians-double-">turnRightRadians</a></span>(double radians)</code>
<div class="block">Immediately turns the robot's body to the right by radians.</div>
</td>
</tr>
<tr id="i64" class="altColor">
<td class="colFirst"><code>void</code></td>
<td class="colLast"><code><span class="memberNameLink"><a href="../robocode/AdvancedRobot.html#waitFor-robocode.Condition-">waitFor</a></span>(<a href="../robocode/Condition.html" title="class in robocode">Condition</a> condition)</code>
<div class="block">Does not return until a condition is met, i.e. when a
<a href="../robocode/Condition.html#test--"><code>Condition.test()</code></a> returns <code>true</code>.</div>
</td>
</tr>
</table>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.robocode._AdvancedRobot">
<!-- -->
</a>
<h3>Methods inherited from class robocode.<a href="../robocode/_AdvancedRobot.html" title="class in robocode">_AdvancedRobot</a></h3>
<code><a href="../robocode/_AdvancedRobot.html#endTurn--">endTurn</a>, <a href="../robocode/_AdvancedRobot.html#getGunHeadingDegrees--">getGunHeadingDegrees</a>, <a href="../robocode/_AdvancedRobot.html#getHeadingDegrees--">getHeadingDegrees</a>, <a href="../robocode/_AdvancedRobot.html#getMaxWaitCount--">getMaxWaitCount</a>, <a href="../robocode/_AdvancedRobot.html#getRadarHeadingDegrees--">getRadarHeadingDegrees</a>, <a href="../robocode/_AdvancedRobot.html#getWaitCount--">getWaitCount</a>, <a href="../robocode/_AdvancedRobot.html#setTurnGunLeftDegrees-double-">setTurnGunLeftDegrees</a>, <a href="../robocode/_AdvancedRobot.html#setTurnGunRightDegrees-double-">setTurnGunRightDegrees</a>, <a href="../robocode/_AdvancedRobot.html#setTurnLeftDegrees-double-">setTurnLeftDegrees</a>, <a href="../robocode/_AdvancedRobot.html#setTurnRadarLeftDegrees-double-">setTurnRadarLeftDegrees</a>, <a href="../robocode/_AdvancedRobot.html#setTurnRadarRightDegrees-double-">setTurnRadarRightDegrees</a>, <a href="../robocode/_AdvancedRobot.html#setTurnRightDegrees-double-">setTurnRightDegrees</a>, <a href="../robocode/_AdvancedRobot.html#turnGunLeftDegrees-double-">turnGunLeftDegrees</a>, <a href="../robocode/_AdvancedRobot.html#turnGunRightDegrees-double-">turnGunRightDegrees</a>, <a href="../robocode/_AdvancedRobot.html#turnLeftDegrees-double-">turnLeftDegrees</a>, <a href="../robocode/_AdvancedRobot.html#turnRadarLeftDegrees-double-">turnRadarLeftDegrees</a>, <a href="../robocode/_AdvancedRobot.html#turnRadarRightDegrees-double-">turnRadarRightDegrees</a>, <a href="../robocode/_AdvancedRobot.html#turnRightDegrees-double-">turnRightDegrees</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.robocode.Robot">
<!-- -->
</a>
<h3>Methods inherited from class robocode.<a href="../robocode/Robot.html" title="class in robocode">Robot</a></h3>
<code><a href="../robocode/Robot.html#ahead-double-">ahead</a>, <a href="../robocode/Robot.html#back-double-">back</a>, <a href="../robocode/Robot.html#doNothing--">doNothing</a>, <a href="../robocode/Robot.html#fire-double-">fire</a>, <a href="../robocode/Robot.html#fireBullet-double-">fireBullet</a>, <a href="../robocode/Robot.html#getBasicEventListener--">getBasicEventListener</a>, <a href="../robocode/Robot.html#getBattleFieldHeight--">getBattleFieldHeight</a>, <a href="../robocode/Robot.html#getBattleFieldWidth--">getBattleFieldWidth</a>, <a href="../robocode/Robot.html#getEnergy--">getEnergy</a>, <a href="../robocode/Robot.html#getGraphics--">getGraphics</a>, <a href="../robocode/Robot.html#getGunCoolingRate--">getGunCoolingRate</a>, <a href="../robocode/Robot.html#getGunHeading--">getGunHeading</a>, <a href="../robocode/Robot.html#getGunHeat--">getGunHeat</a>, <a href="../robocode/Robot.html#getHeading--">getHeading</a>, <a href="../robocode/Robot.html#getHeight--">getHeight</a>, <a href="../robocode/Robot.html#getInteractiveEventListener--">getInteractiveEventListener</a>, <a href="../robocode/Robot.html#getName--">getName</a>, <a href="../robocode/Robot.html#getNumRounds--">getNumRounds</a>, <a href="../robocode/Robot.html#getNumSentries--">getNumSentries</a>, <a href="../robocode/Robot.html#getOthers--">getOthers</a>, <a href="../robocode/Robot.html#getPaintEventListener--">getPaintEventListener</a>, <a href="../robocode/Robot.html#getRadarHeading--">getRadarHeading</a>, <a href="../robocode/Robot.html#getRobotRunnable--">getRobotRunnable</a>, <a href="../robocode/Robot.html#getRoundNum--">getRoundNum</a>, <a href="../robocode/Robot.html#getSentryBorderSize--">getSentryBorderSize</a>, <a href="../robocode/Robot.html#getTime--">getTime</a>, <a href="../robocode/Robot.html#getVelocity--">getVelocity</a>, <a href="../robocode/Robot.html#getWidth--">getWidth</a>, <a href="../robocode/Robot.html#getX--">getX</a>, <a href="../robocode/Robot.html#getY--">getY</a>, <a href="../robocode/Robot.html#onBattleEnded-robocode.BattleEndedEvent-">onBattleEnded</a>, <a href="../robocode/Robot.html#onBulletHit-robocode.BulletHitEvent-">onBulletHit</a>, <a href="../robocode/Robot.html#onBulletHitBullet-robocode.BulletHitBulletEvent-">onBulletHitBullet</a>, <a href="../robocode/Robot.html#onBulletMissed-robocode.BulletMissedEvent-">onBulletMissed</a>, <a href="../robocode/Robot.html#onHitByBullet-robocode.HitByBulletEvent-">onHitByBullet</a>, <a href="../robocode/Robot.html#onHitRobot-robocode.HitRobotEvent-">onHitRobot</a>, <a href="../robocode/Robot.html#onHitWall-robocode.HitWallEvent-">onHitWall</a>, <a href="../robocode/Robot.html#onKeyPressed-java.awt.event.KeyEvent-">onKeyPressed</a>, <a href="../robocode/Robot.html#onKeyReleased-java.awt.event.KeyEvent-">onKeyReleased</a>, <a href="../robocode/Robot.html#onKeyTyped-java.awt.event.KeyEvent-">onKeyTyped</a>, <a href="../robocode/Robot.html#onMouseClicked-java.awt.event.MouseEvent-">onMouseClicked</a>, <a href="../robocode/Robot.html#onMouseDragged-java.awt.event.MouseEvent-">onMouseDragged</a>, <a href="../robocode/Robot.html#onMouseEntered-java.awt.event.MouseEvent-">onMouseEntered</a>, <a href="../robocode/Robot.html#onMouseExited-java.awt.event.MouseEvent-">onMouseExited</a>, <a href="../robocode/Robot.html#onMouseMoved-java.awt.event.MouseEvent-">onMouseMoved</a>, <a href="../robocode/Robot.html#onMousePressed-java.awt.event.MouseEvent-">onMousePressed</a>, <a href="../robocode/Robot.html#onMouseReleased-java.awt.event.MouseEvent-">onMouseReleased</a>, <a href="../robocode/Robot.html#onMouseWheelMoved-java.awt.event.MouseWheelEvent-">onMouseWheelMoved</a>, <a href="../robocode/Robot.html#onPaint-java.awt.Graphics2D-">onPaint</a>, <a href="../robocode/Robot.html#onRobotDeath-robocode.RobotDeathEvent-">onRobotDeath</a>, <a href="../robocode/Robot.html#onRoundEnded-robocode.RoundEndedEvent-">onRoundEnded</a>, <a href="../robocode/Robot.html#onScannedRobot-robocode.ScannedRobotEvent-">onScannedRobot</a>, <a href="../robocode/Robot.html#onStatus-robocode.StatusEvent-">onStatus</a>, <a href="../robocode/Robot.html#onWin-robocode.WinEvent-">onWin</a>, <a href="../robocode/Robot.html#resume--">resume</a>, <a href="../robocode/Robot.html#run--">run</a>, <a href="../robocode/Robot.html#scan--">scan</a>, <a href="../robocode/Robot.html#setAdjustGunForRobotTurn-boolean-">setAdjustGunForRobotTurn</a>, <a href="../robocode/Robot.html#setAdjustRadarForGunTurn-boolean-">setAdjustRadarForGunTurn</a>, <a href="../robocode/Robot.html#setAdjustRadarForRobotTurn-boolean-">setAdjustRadarForRobotTurn</a>, <a href="../robocode/Robot.html#setAllColors-java.awt.Color-">setAllColors</a>, <a href="../robocode/Robot.html#setBodyColor-java.awt.Color-">setBodyColor</a>, <a href="../robocode/Robot.html#setBulletColor-java.awt.Color-">setBulletColor</a>, <a href="../robocode/Robot.html#setColors-java.awt.Color-java.awt.Color-java.awt.Color-">setColors</a>, <a href="../robocode/Robot.html#setColors-java.awt.Color-java.awt.Color-java.awt.Color-java.awt.Color-java.awt.Color-">setColors</a>, <a href="../robocode/Robot.html#setDebugProperty-java.lang.String-java.lang.String-">setDebugProperty</a>, <a href="../robocode/Robot.html#setGunColor-java.awt.Color-">setGunColor</a>, <a href="../robocode/Robot.html#setRadarColor-java.awt.Color-">setRadarColor</a>, <a href="../robocode/Robot.html#setScanColor-java.awt.Color-">setScanColor</a>, <a href="../robocode/Robot.html#stop--">stop</a>, <a href="../robocode/Robot.html#stop-boolean-">stop</a>, <a href="../robocode/Robot.html#turnGunLeft-double-">turnGunLeft</a>, <a href="../robocode/Robot.html#turnGunRight-double-">turnGunRight</a>, <a href="../robocode/Robot.html#turnLeft-double-">turnLeft</a>, <a href="../robocode/Robot.html#turnRadarLeft-double-">turnRadarLeft</a>, <a href="../robocode/Robot.html#turnRadarRight-double-">turnRadarRight</a>, <a href="../robocode/Robot.html#turnRight-double-">turnRight</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.robocode._Robot">
<!-- -->
</a>
<h3>Methods inherited from class robocode.<a href="../robocode/_Robot.html" title="class in robocode">_Robot</a></h3>
<code><a href="../robocode/_Robot.html#getBattleNum--">getBattleNum</a>, <a href="../robocode/_Robot.html#getGunCharge--">getGunCharge</a>, <a href="../robocode/_Robot.html#getGunImageName--">getGunImageName</a>, <a href="../robocode/_Robot.html#getLife--">getLife</a>, <a href="../robocode/_Robot.html#getNumBattles--">getNumBattles</a>, <a href="../robocode/_Robot.html#getRadarImageName--">getRadarImageName</a>, <a href="../robocode/_Robot.html#getRobotImageName--">getRobotImageName</a>, <a href="../robocode/_Robot.html#setGunImageName-java.lang.String-">setGunImageName</a>, <a href="../robocode/_Robot.html#setRadarImageName-java.lang.String-">setRadarImageName</a>, <a href="../robocode/_Robot.html#setRobotImageName-java.lang.String-">setRobotImageName</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.robocode._RobotBase">
<!-- -->
</a>
<h3>Methods inherited from class robocode.<a href="../robocode/_RobotBase.html" title="class in robocode">_RobotBase</a></h3>
<code><a href="../robocode/_RobotBase.html#finalize--">finalize</a>, <a href="../robocode/_RobotBase.html#setOut-java.io.PrintStream-">setOut</a>, <a href="../robocode/_RobotBase.html#setPeer-robocode.robotinterfaces.peer.IBasicRobotPeer-">setPeer</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.java.lang.Object">
<!-- -->
</a>
<h3>Methods inherited from class java.lang.<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang">Object</a></h3>
<code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#clone--" title="class or interface in java.lang">clone</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#equals-java.lang.Object-" title="class or interface in java.lang">equals</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#getClass--" title="class or interface in java.lang">getClass</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#hashCode--" title="class or interface in java.lang">hashCode</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notify--" title="class or interface in java.lang">notify</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#notifyAll--" title="class or interface in java.lang">notifyAll</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#toString--" title="class or interface in java.lang">toString</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait--" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait-long-" title="class or interface in java.lang">wait</a>, <a href="http://docs.oracle.com/javase/6/docs/api/java/lang/Object.html?is-external=true#wait-long-int-" title="class or interface in java.lang">wait</a></code></li>
</ul>
<ul class="blockList">
<li class="blockList"><a name="methods.inherited.from.class.robocode.robotinterfaces.IBasicRobot">
<!-- -->
</a>
<h3>Methods inherited from interface robocode.robotinterfaces.<a href="../robocode/robotinterfaces/IBasicRobot.html" title="interface in robocode.robotinterfaces">IBasicRobot</a></h3>
<code><a href="../robocode/robotinterfaces/IBasicRobot.html#getBasicEventListener--">getBasicEventListener</a>, <a href="../robocode/robotinterfaces/IBasicRobot.html#getRobotRunnable--">getRobotRunnable</a>, <a href="../robocode/robotinterfaces/IBasicRobot.html#setOut-java.io.PrintStream-">setOut</a>, <a href="../robocode/robotinterfaces/IBasicRobot.html#setPeer-robocode.robotinterfaces.peer.IBasicRobotPeer-">setPeer</a></code></li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
<div class="details">
<ul class="blockList">
<li class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<ul class="blockList">
<li class="blockList"><a name="constructor.detail">
<!-- -->
</a>
<h3>Constructor Detail</h3>
<a name="AdvancedRobot--">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>AdvancedRobot</h4>
<pre>public AdvancedRobot()</pre>
</li>
</ul>
</li>
</ul>
<!-- ============ METHOD DETAIL ========== -->
<ul class="blockList">
<li class="blockList"><a name="method.detail">
<!-- -->
</a>
<h3>Method Detail</h3>
<a name="getDistanceRemaining--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getDistanceRemaining</h4>
<pre>public double getDistanceRemaining()</pre>
<div class="block">Returns the distance remaining in the robot's current move measured in
pixels.
<p>
This call returns both positive and negative values. Positive values
means that the robot is currently moving forwards. Negative values means
that the robot is currently moving backwards. If the returned value is 0,
the robot currently stands still.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the distance remaining in the robot's current move measured in
pixels.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getTurnRemaining--"><code>getTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getTurnRemainingRadians--"><code>getTurnRemainingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunTurnRemaining--"><code>getGunTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunTurnRemainingRadians--"><code>getGunTurnRemainingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemaining--"><code>getRadarTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemainingRadians--"><code>getRadarTurnRemainingRadians()</code></a></dd>
</dl>
</li>
</ul>
<a name="getTurnRemaining--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getTurnRemaining</h4>
<pre>public double getTurnRemaining()</pre>
<div class="block">Returns the angle remaining in the robots's turn, in degrees.
<p>
This call returns both positive and negative values. Positive values
means that the robot is currently turning to the right. Negative values
means that the robot is currently turning to the left. If the returned
value is 0, the robot is currently not turning.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the angle remaining in the robots's turn, in degrees</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getTurnRemainingRadians--"><code>getTurnRemainingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getDistanceRemaining--"><code>getDistanceRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunTurnRemaining--"><code>getGunTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunTurnRemainingRadians--"><code>getGunTurnRemainingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemaining--"><code>getRadarTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemainingRadians--"><code>getRadarTurnRemainingRadians()</code></a></dd>
</dl>
</li>
</ul>
<a name="getGunTurnRemaining--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getGunTurnRemaining</h4>
<pre>public double getGunTurnRemaining()</pre>
<div class="block">Returns the angle remaining in the gun's turn, in degrees.
<p>
This call returns both positive and negative values. Positive values
means that the gun is currently turning to the right. Negative values
means that the gun is currently turning to the left. If the returned
value is 0, the gun is currently not turning.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the angle remaining in the gun's turn, in degrees</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getGunTurnRemainingRadians--"><code>getGunTurnRemainingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getDistanceRemaining--"><code>getDistanceRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getTurnRemaining--"><code>getTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getTurnRemainingRadians--"><code>getTurnRemainingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemaining--"><code>getRadarTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemainingRadians--"><code>getRadarTurnRemainingRadians()</code></a></dd>
</dl>
</li>
</ul>
<a name="getRadarTurnRemaining--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getRadarTurnRemaining</h4>
<pre>public double getRadarTurnRemaining()</pre>
<div class="block">Returns the angle remaining in the radar's turn, in degrees.
<p>
This call returns both positive and negative values. Positive values
means that the radar is currently turning to the right. Negative values
means that the radar is currently turning to the left. If the returned
value is 0, the radar is currently not turning.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the angle remaining in the radar's turn, in degrees</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getRadarTurnRemainingRadians--"><code>getRadarTurnRemainingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getDistanceRemaining--"><code>getDistanceRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunTurnRemaining--"><code>getGunTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunTurnRemainingRadians--"><code>getGunTurnRemainingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemaining--"><code>getRadarTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemainingRadians--"><code>getRadarTurnRemainingRadians()</code></a></dd>
</dl>
</li>
</ul>
<a name="setAhead-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setAhead</h4>
<pre>public void setAhead(double distance)</pre>
<div class="block">Sets the robot to move ahead (forward) by distance measured in pixels
when the next execution takes place.
<p>
This call returns immediately, and will not execute until you call
<a href="../robocode/AdvancedRobot.html#execute--"><code>execute()</code></a> or take an action that executes.
<p>
Note that both positive and negative values can be given as input, where
positive values means that the robot is set to move ahead, and negative
values means that the robot is set to move back. If 0 is given as input,
the robot will stop its movement, but will have to decelerate
till it stands still, and will thus not be able to stop its movement
immediately, but eventually.
<p>
Example:
<pre>
// Set the robot to move 50 pixels ahead
setAhead(50);
// Set the robot to move 100 pixels back
// (overrides the previous order)
setAhead(-100);
...
// Executes the last setAhead()
execute();
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>distance</code> - the distance to move measured in pixels.
If <code>distance</code> > 0 the robot is set to move ahead.
If <code>distance</code> < 0 the robot is set to move back.
If <code>distance</code> = 0 the robot is set to stop its movement.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#ahead-double-"><code>ahead(double)</code></a>,
<a href="../robocode/Robot.html#back-double-"><code>back(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setBack-double-"><code>setBack(double)</code></a></dd>
</dl>
</li>
</ul>
<a name="setBack-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setBack</h4>
<pre>public void setBack(double distance)</pre>
<div class="block">Sets the robot to move back by distance measured in pixels when the next
execution takes place.
<p>
This call returns immediately, and will not execute until you call
<a href="../robocode/AdvancedRobot.html#execute--"><code>execute()</code></a> or take an action that executes.
<p>
Note that both positive and negative values can be given as input, where
positive values means that the robot is set to move back, and negative
values means that the robot is set to move ahead. If 0 is given as input,
the robot will stop its movement, but will have to decelerate
till it stands still, and will thus not be able to stop its movement
immediately, but eventually.
<p>
Example:
<pre>
// Set the robot to move 50 pixels back
setBack(50);
// Set the robot to move 100 pixels ahead
// (overrides the previous order)
setBack(-100);
...
// Executes the last setBack()
execute();
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>distance</code> - the distance to move measured in pixels.
If <code>distance</code> > 0 the robot is set to move back.
If <code>distance</code> < 0 the robot is set to move ahead.
If <code>distance</code> = 0 the robot is set to stop its movement.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#back-double-"><code>back(double)</code></a>,
<a href="../robocode/Robot.html#ahead-double-"><code>ahead(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setAhead-double-"><code>setAhead(double)</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnLeft-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnLeft</h4>
<pre>public void setTurnLeft(double degrees)</pre>
<div class="block">Sets the robot's body to turn left by degrees when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's body is set to turn right
instead of left.
<p>
Example:
<pre>
// Set the robot to turn 180 degrees to the left
setTurnLeft(180);
// Set the robot to turn 90 degrees to the right instead of left
// (overrides the previous order)
setTurnLeft(-90);
...
// Executes the last setTurnLeft()
execute();
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>degrees</code> - the amount of degrees to turn the robot's body to the left.
If <code>degrees</code> > 0 the robot is set to turn left.
If <code>degrees</code> < 0 the robot is set to turn right.
If <code>degrees</code> = 0 the robot is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnLeftRadians-double-"><code>setTurnLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnLeft-double-"><code>turnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnLeftRadians-double-"><code>turnLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRight-double-"><code>turnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRightRadians-double-"><code>turnRightRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRight-double-"><code>setTurnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRightRadians-double-"><code>setTurnRightRadians(double)</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnRight-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnRight</h4>
<pre>public void setTurnRight(double degrees)</pre>
<div class="block">Sets the robot's body to turn right by degrees when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's body is set to turn left
instead of right.
<p>
Example:
<pre>
// Set the robot to turn 180 degrees to the right
setTurnRight(180);
// Set the robot to turn 90 degrees to the left instead of right
// (overrides the previous order)
setTurnRight(-90);
...
// Executes the last setTurnRight()
execute();
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>degrees</code> - the amount of degrees to turn the robot's body to the right.
If <code>degrees</code> > 0 the robot is set to turn right.
If <code>degrees</code> < 0 the robot is set to turn left.
If <code>degrees</code> = 0 the robot is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnRightRadians-double-"><code>setTurnRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRight-double-"><code>turnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRightRadians-double-"><code>turnRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnLeft-double-"><code>turnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnLeftRadians-double-"><code>turnLeftRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnLeft-double-"><code>setTurnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnLeftRadians-double-"><code>setTurnLeftRadians(double)</code></a></dd>
</dl>
</li>
</ul>
<a name="setFire-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setFire</h4>
<pre>public void setFire(double power)</pre>
<div class="block">Sets the gun to fire a bullet when the next execution takes place.
The bullet will travel in the direction the gun is pointing.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
The specified bullet power is an amount of energy that will be taken from
the robot's energy. Hence, the more power you want to spend on the
bullet, the more energy is taken from your robot.
<p>
The bullet will do (4 * power) damage if it hits another robot. If power
is greater than 1, it will do an additional 2 * (power - 1) damage.
You will get (3 * power) back if you hit the other robot. You can call
Rules#getBulletDamage(double)} for getting the damage that a
bullet with a specific bullet power will do.
<p>
The specified bullet power should be between
<a href="../robocode/Rules.html#MIN_BULLET_POWER"><code>Rules.MIN_BULLET_POWER</code></a> and <a href="../robocode/Rules.html#MAX_BULLET_POWER"><code>Rules.MAX_BULLET_POWER</code></a>.
<p>
Note that the gun cannot fire if the gun is overheated, meaning that
<a href="../robocode/Robot.html#getGunHeat--"><code>Robot.getGunHeat()</code></a> returns a value > 0.
<p>
An event is generated when the bullet hits a robot, wall, or another
bullet.
<p>
Example:
<pre>
// Fire a bullet with maximum power if the gun is ready
if (getGunHeat() == 0) {
setFire(Rules.MAX_BULLET_POWER);
}
...
execute();
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>power</code> - the amount of energy given to the bullet, and subtracted
from the robot's energy.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setFireBullet-double-"><code>setFireBullet(double)</code></a>,
<a href="../robocode/Robot.html#fire-double-"><code>fire(double)</code></a>,
<a href="../robocode/Robot.html#fireBullet-double-"><code>fireBullet(double)</code></a>,
<a href="../robocode/Robot.html#getGunHeat--"><code>getGunHeat()</code></a>,
<a href="../robocode/Robot.html#getGunCoolingRate--"><code>getGunCoolingRate()</code></a>,
<a href="../robocode/Robot.html#onBulletHit-robocode.BulletHitEvent-"><code>onBulletHit(BulletHitEvent)</code></a>,
<a href="../robocode/Robot.html#onBulletHitBullet-robocode.BulletHitBulletEvent-"><code>onBulletHitBullet(BulletHitBulletEvent)</code></a>,
<a href="../robocode/Robot.html#onBulletMissed-robocode.BulletMissedEvent-"><code>onBulletMissed(BulletMissedEvent)</code></a></dd>
</dl>
</li>
</ul>
<a name="setFireBullet-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setFireBullet</h4>
<pre>public <a href="../robocode/Bullet.html" title="class in robocode">Bullet</a> setFireBullet(double power)</pre>
<div class="block">Sets the gun to fire a bullet when the next execution takes place.
The bullet will travel in the direction the gun is pointing.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
The specified bullet power is an amount of energy that will be taken from
the robot's energy. Hence, the more power you want to spend on the
bullet, the more energy is taken from your robot.
<p>
The bullet will do (4 * power) damage if it hits another robot. If power
is greater than 1, it will do an additional 2 * (power - 1) damage.
You will get (3 * power) back if you hit the other robot. You can call
<a href="../robocode/Rules.html#getBulletDamage-double-"><code>Rules.getBulletDamage(double)</code></a> for getting the damage that a
bullet with a specific bullet power will do.
<p>
The specified bullet power should be between
<a href="../robocode/Rules.html#MIN_BULLET_POWER"><code>Rules.MIN_BULLET_POWER</code></a> and <a href="../robocode/Rules.html#MAX_BULLET_POWER"><code>Rules.MAX_BULLET_POWER</code></a>.
<p>
Note that the gun cannot fire if the gun is overheated, meaning that
<a href="../robocode/Robot.html#getGunHeat--"><code>Robot.getGunHeat()</code></a> returns a value > 0.
<p>
A event is generated when the bullet hits a robot
(<a href="../robocode/BulletHitEvent.html" title="class in robocode"><code>BulletHitEvent</code></a>), wall (<a href="../robocode/BulletMissedEvent.html" title="class in robocode"><code>BulletMissedEvent</code></a>), or another
bullet (<a href="../robocode/BulletHitBulletEvent.html" title="class in robocode"><code>BulletHitBulletEvent</code></a>).
<p>
Example:
<pre>
Bullet bullet = null;
<p>
// Fire a bullet with maximum power if the gun is ready
if (getGunHeat() == 0) {
bullet = setFireBullet(Rules.MAX_BULLET_POWER);
}
...
execute();
...
// Get the velocity of the bullet
if (bullet != null) {
double bulletVelocity = bullet.getVelocity();
}
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>power</code> - the amount of energy given to the bullet, and subtracted
from the robot's energy.</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a <a href="../robocode/Bullet.html" title="class in robocode"><code>Bullet</code></a> that contains information about the bullet if it
was actually fired, which can be used for tracking the bullet after it
has been fired. If the bullet was not fired, <code>null</code> is returned.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setFire-double-"><code>setFire(double)</code></a>,
<a href="../robocode/Bullet.html" title="class in robocode"><code>Bullet</code></a>,
<a href="../robocode/Robot.html#fire-double-"><code>fire(double)</code></a>,
<a href="../robocode/Robot.html#fireBullet-double-"><code>fireBullet(double)</code></a>,
<a href="../robocode/Robot.html#getGunHeat--"><code>getGunHeat()</code></a>,
<a href="../robocode/Robot.html#getGunCoolingRate--"><code>getGunCoolingRate()</code></a>,
<a href="../robocode/Robot.html#onBulletHit-robocode.BulletHitEvent-"><code>onBulletHit(BulletHitEvent)</code></a>,
<a href="../robocode/Robot.html#onBulletHitBullet-robocode.BulletHitBulletEvent-"><code>onBulletHitBullet(BulletHitBulletEvent)</code></a>,
<a href="../robocode/Robot.html#onBulletMissed-robocode.BulletMissedEvent-"><code>onBulletMissed(BulletMissedEvent)</code></a></dd>
</dl>
</li>
</ul>
<a name="addCustomEvent-robocode.Condition-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>addCustomEvent</h4>
<pre>public void addCustomEvent(<a href="../robocode/Condition.html" title="class in robocode">Condition</a> condition)</pre>
<div class="block">Registers a custom event to be called when a condition is met.
When you are finished with your condition or just want to remove it you
must call <a href="../robocode/AdvancedRobot.html#removeCustomEvent-robocode.Condition-"><code>removeCustomEvent(Condition)</code></a>.
<p>
Example:
<pre>
// Create the condition for our custom event
Condition triggerHitCondition = new Condition("triggerhit") {
public boolean test() {
return (getEnergy() <= trigger);
}
}
// Add our custom event based on our condition
<b>addCustomEvent(triggerHitCondition);</b>
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>condition</code> - the condition that must be met.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the condition parameter has been set to
<code>null</code>.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Condition.html" title="class in robocode"><code>Condition</code></a>,
<a href="../robocode/AdvancedRobot.html#removeCustomEvent-robocode.Condition-"><code>removeCustomEvent(Condition)</code></a></dd>
</dl>
</li>
</ul>
<a name="removeCustomEvent-robocode.Condition-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>removeCustomEvent</h4>
<pre>public void removeCustomEvent(<a href="../robocode/Condition.html" title="class in robocode">Condition</a> condition)</pre>
<div class="block">Removes a custom event that was previously added by calling
<a href="../robocode/AdvancedRobot.html#addCustomEvent-robocode.Condition-"><code>addCustomEvent(Condition)</code></a>.
<p>
Example:
<pre>
// Create the condition for our custom event
Condition triggerHitCondition = new Condition("triggerhit") {
public boolean test() {
return (getEnergy() <= trigger);
}
}
// Add our custom event based on our condition
addCustomEvent(triggerHitCondition);
...
<i>do something with your robot</i>
...
// Remove the custom event based on our condition
<b>removeCustomEvent(triggerHitCondition);</b>
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>condition</code> - the condition that was previous added and that must be
removed now.</dd>
<dt><span class="throwsLabel">Throws:</span></dt>
<dd><code><a href="http://docs.oracle.com/javase/6/docs/api/java/lang/NullPointerException.html?is-external=true" title="class or interface in java.lang">NullPointerException</a></code> - if the condition parameter has been set to
<code>null</code>.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Condition.html" title="class in robocode"><code>Condition</code></a>,
<a href="../robocode/AdvancedRobot.html#addCustomEvent-robocode.Condition-"><code>addCustomEvent(Condition)</code></a></dd>
</dl>
</li>
</ul>
<a name="clearAllEvents--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>clearAllEvents</h4>
<pre>public void clearAllEvents()</pre>
<div class="block">Clears out any pending events in the robot's event queue immediately.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getAllEvents--"><code>getAllEvents()</code></a></dd>
</dl>
</li>
</ul>
<a name="execute--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>execute</h4>
<pre>public void execute()</pre>
<div class="block">Executes any pending actions, or continues executing actions that are
in process. This call returns after the actions have been started.
<p>
Note that advanced robots <em>must</em> call this function in order to
execute pending set* calls like e.g. <a href="../robocode/AdvancedRobot.html#setAhead-double-"><code>setAhead(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setFire-double-"><code>setFire(double)</code></a>, <a href="../robocode/AdvancedRobot.html#setTurnLeft-double-"><code>setTurnLeft(double)</code></a> etc. Otherwise,
these calls will never get executed.
<p>
In this example the robot will move while turning:
<pre>
setTurnRight(90);
setAhead(100);
execute();
while (getDistanceRemaining() > 0 && getTurnRemaining() > 0) {
execute();
}
</pre></div>
</li>
</ul>
<a name="getAllEvents--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getAllEvents</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/Event.html" title="class in robocode">Event</a>> getAllEvents()</pre>
<div class="block">Returns a vector containing all events currently in the robot's queue.
You might, for example, call this while processing another event.
<p>
Example:
<pre>
for (Event event : getAllEvents()) {
if (event instanceof HitRobotEvent) {
<i>// do something with the event</i>
} else if (event instanceof HitByBulletEvent) {
<i>// do something with the event</i>
}
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a vector containing all events currently in the robot's queue</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Event.html" title="class in robocode"><code>Event</code></a>,
<a href="../robocode/AdvancedRobot.html#clearAllEvents--"><code>clearAllEvents()</code></a>,
<a href="../robocode/AdvancedRobot.html#getStatusEvents--"><code>getStatusEvents()</code></a>,
<a href="../robocode/AdvancedRobot.html#getScannedRobotEvents--"><code>getScannedRobotEvents()</code></a>,
<a href="../robocode/AdvancedRobot.html#getBulletHitEvents--"><code>getBulletHitEvents()</code></a>,
<a href="../robocode/AdvancedRobot.html#getBulletMissedEvents--"><code>getBulletMissedEvents()</code></a>,
<a href="../robocode/AdvancedRobot.html#getBulletHitBulletEvents--"><code>getBulletHitBulletEvents()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRobotDeathEvents--"><code>getRobotDeathEvents()</code></a></dd>
</dl>
</li>
</ul>
<a name="getBulletHitBulletEvents--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBulletHitBulletEvents</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/BulletHitBulletEvent.html" title="class in robocode">BulletHitBulletEvent</a>> getBulletHitBulletEvents()</pre>
<div class="block">Returns a vector containing all BulletHitBulletEvents currently in the
robot's queue. You might, for example, call this while processing another
event.
<p>
Example:
<pre>
for (BulletHitBulletEvent event : getBulletHitBulletEvents()) {
<i>// do something with the event</i>
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a vector containing all BulletHitBulletEvents currently in the
robot's queue</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#onBulletHitBullet-robocode.BulletHitBulletEvent-"><code>onBulletHitBullet(BulletHitBulletEvent)</code></a>,
<a href="../robocode/BulletHitBulletEvent.html" title="class in robocode"><code>BulletHitBulletEvent</code></a>,
<a href="../robocode/AdvancedRobot.html#getAllEvents--"><code>getAllEvents()</code></a></dd>
</dl>
</li>
</ul>
<a name="getBulletHitEvents--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBulletHitEvents</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/BulletHitEvent.html" title="class in robocode">BulletHitEvent</a>> getBulletHitEvents()</pre>
<div class="block">Returns a vector containing all BulletHitEvents currently in the robot's
queue. You might, for example, call this while processing another event.
<p>
Example:
<pre>
for (BulletHitEvent event: getBulletHitEvents()) {
<i>// do something with the event</i>
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a vector containing all BulletHitEvents currently in the robot's
queue</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#onBulletHit-robocode.BulletHitEvent-"><code>onBulletHit(BulletHitEvent)</code></a>,
<a href="../robocode/BulletHitEvent.html" title="class in robocode"><code>BulletHitEvent</code></a>,
<a href="../robocode/AdvancedRobot.html#getAllEvents--"><code>getAllEvents()</code></a></dd>
</dl>
</li>
</ul>
<a name="getBulletMissedEvents--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getBulletMissedEvents</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/BulletMissedEvent.html" title="class in robocode">BulletMissedEvent</a>> getBulletMissedEvents()</pre>
<div class="block">Returns a vector containing all BulletMissedEvents currently in the
robot's queue. You might, for example, call this while processing another
event.
<p>
Example:
<pre>
for (BulletMissedEvent event : getBulletMissedEvents()) {
<i>// do something with the event</i>
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a vector containing all BulletMissedEvents currently in the
robot's queue</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#onBulletMissed-robocode.BulletMissedEvent-"><code>onBulletMissed(BulletMissedEvent)</code></a>,
<a href="../robocode/BulletMissedEvent.html" title="class in robocode"><code>BulletMissedEvent</code></a>,
<a href="../robocode/AdvancedRobot.html#getAllEvents--"><code>getAllEvents()</code></a></dd>
</dl>
</li>
</ul>
<a name="getDataDirectory--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getDataDirectory</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a> getDataDirectory()</pre>
<div class="block">Returns a file representing a data directory for the robot, which can be
written to using <a href="../robocode/RobocodeFileOutputStream.html" title="class in robocode"><code>RobocodeFileOutputStream</code></a> or
<a href="../robocode/RobocodeFileWriter.html" title="class in robocode"><code>RobocodeFileWriter</code></a>.
<p>
The system will automatically create the directory for you, so you do not
need to create it by yourself.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a file representing the data directory for your robot</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getDataFile-java.lang.String-"><code>getDataFile(String)</code></a>,
<a href="../robocode/RobocodeFileOutputStream.html" title="class in robocode"><code>RobocodeFileOutputStream</code></a>,
<a href="../robocode/RobocodeFileWriter.html" title="class in robocode"><code>RobocodeFileWriter</code></a></dd>
</dl>
</li>
</ul>
<a name="getDataFile-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getDataFile</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/io/File.html?is-external=true" title="class or interface in java.io">File</a> getDataFile(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> filename)</pre>
<div class="block">Returns a file in your data directory that you can write to using
<a href="../robocode/RobocodeFileOutputStream.html" title="class in robocode"><code>RobocodeFileOutputStream</code></a> or <a href="../robocode/RobocodeFileWriter.html" title="class in robocode"><code>RobocodeFileWriter</code></a>.
<p>
The system will automatically create the directory for you, so you do not
need to create it by yourself.
<p>
Please notice that the max. size of your data file is set to 200000
(~195 KB).
<p>
See the <code>sample.SittingDuck</code> to see an example of how to use this
method.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>filename</code> - the file name of the data file for your robot</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a file representing the data file for your robot or null if the data
file could not be created due to an error.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getDataDirectory--"><code>getDataDirectory()</code></a>,
<a href="../robocode/RobocodeFileOutputStream.html" title="class in robocode"><code>RobocodeFileOutputStream</code></a>,
<a href="../robocode/RobocodeFileWriter.html" title="class in robocode"><code>RobocodeFileWriter</code></a></dd>
</dl>
</li>
</ul>
<a name="getDataQuotaAvailable--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getDataQuotaAvailable</h4>
<pre>public long getDataQuotaAvailable()</pre>
<div class="block">Returns the data quota available in your data directory, i.e. the amount
of bytes left in the data directory for the robot.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the amount of bytes left in the robot's data directory</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getDataDirectory--"><code>getDataDirectory()</code></a>,
<a href="../robocode/AdvancedRobot.html#getDataFile-java.lang.String-"><code>getDataFile(String)</code></a></dd>
</dl>
</li>
</ul>
<a name="getEventPriority-java.lang.String-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getEventPriority</h4>
<pre>public int getEventPriority(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> eventClass)</pre>
<div class="block">Returns the current priority of a class of events.
An event priority is a value from 0 - 99. The higher value, the higher
priority.
<p>
Example:
<pre>
int myHitRobotPriority = getEventPriority("HitRobotEvent");
</pre>
<p>
The default priorities are, from highest to lowest:
<pre>
<a href="../robocode/RoundEndedEvent.html" title="class in robocode"><code>RoundEndedEvent</code></a>: 100 (reserved)
<a href="../robocode/BattleEndedEvent.html" title="class in robocode"><code>BattleEndedEvent</code></a>: 100 (reserved)
<a href="../robocode/WinEvent.html" title="class in robocode"><code>WinEvent</code></a>: 100 (reserved)
<a href="../robocode/SkippedTurnEvent.html" title="class in robocode"><code>SkippedTurnEvent</code></a>: 100 (reserved)
<a href="../robocode/StatusEvent.html" title="class in robocode"><code>StatusEvent</code></a>: 99
Key and mouse events: 98
<a href="../robocode/CustomEvent.html" title="class in robocode"><code>CustomEvent</code></a>: 80 (default value)
<a href="../robocode/MessageEvent.html" title="class in robocode"><code>MessageEvent</code></a>: 75
<a href="../robocode/RobotDeathEvent.html" title="class in robocode"><code>RobotDeathEvent</code></a>: 70
<a href="../robocode/BulletMissedEvent.html" title="class in robocode"><code>BulletMissedEvent</code></a>: 60
<a href="../robocode/BulletHitBulletEvent.html" title="class in robocode"><code>BulletHitBulletEvent</code></a>: 55
<a href="../robocode/BulletHitEvent.html" title="class in robocode"><code>BulletHitEvent</code></a>: 50
<a href="../robocode/HitByBulletEvent.html" title="class in robocode"><code>HitByBulletEvent</code></a>: 40
<a href="../robocode/HitWallEvent.html" title="class in robocode"><code>HitWallEvent</code></a>: 30
<a href="../robocode/HitRobotEvent.html" title="class in robocode"><code>HitRobotEvent</code></a>: 20
<a href="../robocode/ScannedRobotEvent.html" title="class in robocode"><code>ScannedRobotEvent</code></a>: 10
<a href="../robocode/PaintEvent.html" title="class in robocode"><code>PaintEvent</code></a>: 5
<a href="../robocode/DeathEvent.html" title="class in robocode"><code>DeathEvent</code></a>: -1 (reserved)
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>eventClass</code> - the name of the event class (string)</dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the current priority of a class of events</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setEventPriority-java.lang.String-int-"><code>setEventPriority(String, int)</code></a></dd>
</dl>
</li>
</ul>
<a name="getHitByBulletEvents--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getHitByBulletEvents</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/HitByBulletEvent.html" title="class in robocode">HitByBulletEvent</a>> getHitByBulletEvents()</pre>
<div class="block">Returns a vector containing all HitByBulletEvents currently in the
robot's queue. You might, for example, call this while processing
another event.
<p>
Example:
<pre>
for (HitByBulletEvent event : getHitByBulletEvents()) {
<i>// do something with the event</i>
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a vector containing all HitByBulletEvents currently in the
robot's queue</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#onHitByBullet-robocode.HitByBulletEvent-"><code>onHitByBullet(HitByBulletEvent)</code></a>,
<a href="../robocode/HitByBulletEvent.html" title="class in robocode"><code>HitByBulletEvent</code></a>,
<a href="../robocode/AdvancedRobot.html#getAllEvents--"><code>getAllEvents()</code></a></dd>
</dl>
</li>
</ul>
<a name="getHitRobotEvents--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getHitRobotEvents</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/HitRobotEvent.html" title="class in robocode">HitRobotEvent</a>> getHitRobotEvents()</pre>
<div class="block">Returns a vector containing all HitRobotEvents currently in the robot's
queue. You might, for example, call this while processing another event.
<p>
Example:
<pre>
for (HitRobotEvent event : getHitRobotEvents()) {
<i>// do something with the event</i>
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a vector containing all HitRobotEvents currently in the robot's
queue</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#onHitRobot-robocode.HitRobotEvent-"><code>onHitRobot(HitRobotEvent)</code></a>,
<a href="../robocode/HitRobotEvent.html" title="class in robocode"><code>HitRobotEvent</code></a>,
<a href="../robocode/AdvancedRobot.html#getAllEvents--"><code>getAllEvents()</code></a></dd>
</dl>
</li>
</ul>
<a name="getHitWallEvents--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getHitWallEvents</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/HitWallEvent.html" title="class in robocode">HitWallEvent</a>> getHitWallEvents()</pre>
<div class="block">Returns a vector containing all HitWallEvents currently in the robot's
queue. You might, for example, call this while processing another event.
<p>
Example:
<pre>
for (HitWallEvent event : getHitWallEvents()) {
<i>// do something with the event</i>
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a vector containing all HitWallEvents currently in the robot's
queue</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#onHitWall-robocode.HitWallEvent-"><code>onHitWall(HitWallEvent)</code></a>,
<a href="../robocode/HitWallEvent.html" title="class in robocode"><code>HitWallEvent</code></a>,
<a href="../robocode/AdvancedRobot.html#getAllEvents--"><code>getAllEvents()</code></a></dd>
</dl>
</li>
</ul>
<a name="getRobotDeathEvents--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getRobotDeathEvents</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/RobotDeathEvent.html" title="class in robocode">RobotDeathEvent</a>> getRobotDeathEvents()</pre>
<div class="block">Returns a vector containing all RobotDeathEvents currently in the robot's
queue. You might, for example, call this while processing another event.
<p>
Example:
<pre>
for (RobotDeathEvent event : getRobotDeathEvents()) {
<i>// do something with the event</i>
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a vector containing all RobotDeathEvents currently in the robot's
queue</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#onRobotDeath-robocode.RobotDeathEvent-"><code>onRobotDeath(RobotDeathEvent)</code></a>,
<a href="../robocode/RobotDeathEvent.html" title="class in robocode"><code>RobotDeathEvent</code></a>,
<a href="../robocode/AdvancedRobot.html#getAllEvents--"><code>getAllEvents()</code></a></dd>
</dl>
</li>
</ul>
<a name="getScannedRobotEvents--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getScannedRobotEvents</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/ScannedRobotEvent.html" title="class in robocode">ScannedRobotEvent</a>> getScannedRobotEvents()</pre>
<div class="block">Returns a vector containing all ScannedRobotEvents currently in the
robot's queue. You might, for example, call this while processing another
event.
<p>
Example:
<pre>
for (ScannedRobotEvent event : getScannedRobotEvents()) {
<i>// do something with the event</i>
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a vector containing all ScannedRobotEvents currently in the
robot's queue</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#onScannedRobot-robocode.ScannedRobotEvent-"><code>onScannedRobot(ScannedRobotEvent)</code></a>,
<a href="../robocode/ScannedRobotEvent.html" title="class in robocode"><code>ScannedRobotEvent</code></a>,
<a href="../robocode/AdvancedRobot.html#getAllEvents--"><code>getAllEvents()</code></a></dd>
</dl>
</li>
</ul>
<a name="getStatusEvents--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getStatusEvents</h4>
<pre>public <a href="http://docs.oracle.com/javase/6/docs/api/java/util/Vector.html?is-external=true" title="class or interface in java.util">Vector</a><<a href="../robocode/StatusEvent.html" title="class in robocode">StatusEvent</a>> getStatusEvents()</pre>
<div class="block">Returns a vector containing all StatusEvents currently in the robot's
queue. You might, for example, call this while processing another event.
<p>
Example:
<pre>
for (StatusEvent event : getStatusEvents()) {
<i>// do something with the event</i>
}
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>a vector containing all StatusEvents currently in the robot's queue</dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>1.6.1</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#onStatus-robocode.StatusEvent-"><code>onStatus(StatusEvent)</code></a>,
<a href="../robocode/StatusEvent.html" title="class in robocode"><code>StatusEvent</code></a>,
<a href="../robocode/AdvancedRobot.html#getAllEvents--"><code>getAllEvents()</code></a></dd>
</dl>
</li>
</ul>
<a name="isAdjustGunForRobotTurn--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isAdjustGunForRobotTurn</h4>
<pre>public boolean isAdjustGunForRobotTurn()</pre>
<div class="block">Checks if the gun is set to adjust for the robot turning, i.e. to turn
independent from the robot's body turn.
<p>
This call returns <code>true</code> if the gun is set to turn independent of
the turn of the robot's body. Otherwise, <code>false</code> is returned,
meaning that the gun is set to turn with the robot's body turn.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if the gun is set to turn independent of the robot
turning; <code>false</code> if the gun is set to turn with the robot
turning</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#setAdjustGunForRobotTurn-boolean-"><code>setAdjustGunForRobotTurn(boolean)</code></a>,
<a href="../robocode/AdvancedRobot.html#isAdjustRadarForRobotTurn--"><code>isAdjustRadarForRobotTurn()</code></a>,
<a href="../robocode/AdvancedRobot.html#isAdjustRadarForGunTurn--"><code>isAdjustRadarForGunTurn()</code></a></dd>
</dl>
</li>
</ul>
<a name="isAdjustRadarForRobotTurn--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isAdjustRadarForRobotTurn</h4>
<pre>public boolean isAdjustRadarForRobotTurn()</pre>
<div class="block">Checks if the radar is set to adjust for the robot turning, i.e. to turn
independent from the robot's body turn.
<p>
This call returns <code>true</code> if the radar is set to turn independent of
the turn of the robot. Otherwise, <code>false</code> is returned, meaning that
the radar is set to turn with the robot's turn.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if the radar is set to turn independent of the robot
turning; <code>false</code> if the radar is set to turn with the robot
turning</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#setAdjustRadarForRobotTurn-boolean-"><code>setAdjustRadarForRobotTurn(boolean)</code></a>,
<a href="../robocode/AdvancedRobot.html#isAdjustGunForRobotTurn--"><code>isAdjustGunForRobotTurn()</code></a>,
<a href="../robocode/AdvancedRobot.html#isAdjustRadarForGunTurn--"><code>isAdjustRadarForGunTurn()</code></a></dd>
</dl>
</li>
</ul>
<a name="isAdjustRadarForGunTurn--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>isAdjustRadarForGunTurn</h4>
<pre>public boolean isAdjustRadarForGunTurn()</pre>
<div class="block">Checks if the radar is set to adjust for the gun turning, i.e. to turn
independent from the gun's turn.
<p>
This call returns <code>true</code> if the radar is set to turn independent of
the turn of the gun. Otherwise, <code>false</code> is returned, meaning that
the radar is set to turn with the gun's turn.</div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd><code>true</code> if the radar is set to turn independent of the gun
turning; <code>false</code> if the radar is set to turn with the gun
turning</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#setAdjustRadarForGunTurn-boolean-"><code>setAdjustRadarForGunTurn(boolean)</code></a>,
<a href="../robocode/AdvancedRobot.html#isAdjustGunForRobotTurn--"><code>isAdjustGunForRobotTurn()</code></a>,
<a href="../robocode/AdvancedRobot.html#isAdjustRadarForRobotTurn--"><code>isAdjustRadarForRobotTurn()</code></a></dd>
</dl>
</li>
</ul>
<a name="onCustomEvent-robocode.CustomEvent-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>onCustomEvent</h4>
<pre>public void onCustomEvent(<a href="../robocode/CustomEvent.html" title="class in robocode">CustomEvent</a> event)</pre>
<div class="block">This method is called when a custom condition is met.
<p>
See the sample robots for examples of use, e.g. the <code>sample.Target</code>
robot.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../robocode/robotinterfaces/IAdvancedEvents.html#onCustomEvent-robocode.CustomEvent-">onCustomEvent</a></code> in interface <code><a href="../robocode/robotinterfaces/IAdvancedEvents.html" title="interface in robocode.robotinterfaces">IAdvancedEvents</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>event</code> - the custom event that occurred</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#addCustomEvent-robocode.Condition-"><code>addCustomEvent(robocode.Condition)</code></a>,
<a href="../robocode/CustomEvent.html" title="class in robocode"><code>CustomEvent</code></a>,
<a href="../robocode/Event.html" title="class in robocode"><code>Event</code></a></dd>
</dl>
</li>
</ul>
<a name="setEventPriority-java.lang.String-int-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setEventPriority</h4>
<pre>public void setEventPriority(<a href="http://docs.oracle.com/javase/6/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a> eventClass,
int priority)</pre>
<div class="block">Sets the priority of a class of events.
<p>
Events are sent to the onXXX handlers in order of priority.
Higher priority events can interrupt lower priority events.
For events with the same priority, newer events are always sent first.
Valid priorities are 0 - 99, where 100 is reserved and 80 is the default
priority.
<p>
Example:
<pre>
setEventPriority("RobotDeathEvent", 15);
</pre>
<p>
The default priorities are, from highest to lowest:
<pre>
<a href="../robocode/WinEvent.html" title="class in robocode"><code>WinEvent</code></a>: 100 (reserved)
<a href="../robocode/SkippedTurnEvent.html" title="class in robocode"><code>SkippedTurnEvent</code></a>: 100 (reserved)
<a href="../robocode/StatusEvent.html" title="class in robocode"><code>StatusEvent</code></a>: 99
<a href="../robocode/CustomEvent.html" title="class in robocode"><code>CustomEvent</code></a>: 80
<a href="../robocode/MessageEvent.html" title="class in robocode"><code>MessageEvent</code></a>: 75
<a href="../robocode/RobotDeathEvent.html" title="class in robocode"><code>RobotDeathEvent</code></a>: 70
<a href="../robocode/BulletMissedEvent.html" title="class in robocode"><code>BulletMissedEvent</code></a>: 60
<a href="../robocode/BulletHitBulletEvent.html" title="class in robocode"><code>BulletHitBulletEvent</code></a>: 55
<a href="../robocode/BulletHitEvent.html" title="class in robocode"><code>BulletHitEvent</code></a>: 50
<a href="../robocode/HitByBulletEvent.html" title="class in robocode"><code>HitByBulletEvent</code></a>: 40
<a href="../robocode/HitWallEvent.html" title="class in robocode"><code>HitWallEvent</code></a>: 30
<a href="../robocode/HitRobotEvent.html" title="class in robocode"><code>HitRobotEvent</code></a>: 20
<a href="../robocode/ScannedRobotEvent.html" title="class in robocode"><code>ScannedRobotEvent</code></a>: 10
<a href="../robocode/PaintEvent.html" title="class in robocode"><code>PaintEvent</code></a>: 5
<a href="../robocode/DeathEvent.html" title="class in robocode"><code>DeathEvent</code></a>: -1 (reserved)
</pre>
<p>
Note that you cannot change the priority for events with the special
priority value -1 or 100 (reserved) as these event are system events.
Also note that you cannot change the priority of CustomEvent.
Instead you must change the priority of the condition(s) for your custom
event(s).</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>eventClass</code> - the name of the event class (string) to set the
priority for</dd>
<dd><code>priority</code> - the new priority for that event class</dd>
<dt><span class="simpleTagLabel">Since:</span></dt>
<dd>1.5, the priority of DeathEvent was changed from 100 to -1 in
order to let robots process pending events on its event queue before
it dies. When the robot dies, it will not be able to process events.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getEventPriority-java.lang.String-"><code>getEventPriority(String)</code></a>,
<a href="../robocode/AdvancedRobot.html#setInterruptible-boolean-"><code>setInterruptible(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="setInterruptible-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setInterruptible</h4>
<pre>public void setInterruptible(boolean interruptible)</pre>
<div class="block">Call this during an event handler to allow new events of the same
priority to restart the event handler.
<p>
<p>Example:
<pre>
public void onScannedRobot(ScannedRobotEvent e) {
fire(1);
<b>setInterruptible(true);</b>
ahead(100); // If you see a robot while moving ahead,
// this handler will start from the top
// Without setInterruptible(true), we wouldn't
// receive scan events at all!
// We'll only get here if we don't see a robot during the move.
out.println("Ok, I can't see anyone");
}
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_Robot.html#setInterruptible-boolean-">setInterruptible</a></code> in class <code><a href="../robocode/_Robot.html" title="class in robocode">_Robot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>interruptible</code> - <code>true</code> if the event handler should be
interrupted if new events of the same priority occurs; <code>false</code>
otherwise</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setEventPriority-java.lang.String-int-"><code>setEventPriority(String, int)</code></a>,
<a href="../robocode/Robot.html#onScannedRobot-robocode.ScannedRobotEvent-"><code>onScannedRobot(ScannedRobotEvent)</code></a></dd>
</dl>
</li>
</ul>
<a name="setMaxTurnRate-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setMaxTurnRate</h4>
<pre>public void setMaxTurnRate(double newMaxTurnRate)</pre>
<div class="block">Sets the maximum turn rate of the robot measured in degrees if the robot
should turn slower than <a href="../robocode/Rules.html#MAX_TURN_RATE"><code>Rules.MAX_TURN_RATE</code></a> (10 degress/turn).</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>newMaxTurnRate</code> - the new maximum turn rate of the robot measured in
degrees. Valid values are 0 - <a href="../robocode/Rules.html#MAX_TURN_RATE"><code>Rules.MAX_TURN_RATE</code></a></dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#turnRight-double-"><code>turnRight(double)</code></a>,
<a href="../robocode/Robot.html#turnLeft-double-"><code>turnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRight-double-"><code>setTurnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnLeft-double-"><code>setTurnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setMaxVelocity-double-"><code>setMaxVelocity(double)</code></a></dd>
</dl>
</li>
</ul>
<a name="setMaxVelocity-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setMaxVelocity</h4>
<pre>public void setMaxVelocity(double newMaxVelocity)</pre>
<div class="block">Sets the maximum velocity of the robot measured in pixels/turn if the
robot should move slower than <a href="../robocode/Rules.html#MAX_VELOCITY"><code>Rules.MAX_VELOCITY</code></a> (8 pixels/turn).</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>newMaxVelocity</code> - the new maximum turn rate of the robot measured in
pixels/turn. Valid values are 0 - <a href="../robocode/Rules.html#MAX_VELOCITY"><code>Rules.MAX_VELOCITY</code></a></dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#ahead-double-"><code>Robot.ahead(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setAhead-double-"><code>setAhead(double)</code></a>,
<a href="../robocode/Robot.html#back-double-"><code>Robot.back(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setBack-double-"><code>setBack(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setMaxTurnRate-double-"><code>setMaxTurnRate(double)</code></a></dd>
</dl>
</li>
</ul>
<a name="setResume--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setResume</h4>
<pre>public void setResume()</pre>
<div class="block">Sets the robot to resume the movement stopped by <a href="../robocode/Robot.html#stop--"><code>stop()</code></a>
or <a href="../robocode/AdvancedRobot.html#setStop--"><code>setStop()</code></a>, if any.
<p>
This call returns immediately, and will not execute until you call
<a href="../robocode/AdvancedRobot.html#execute--"><code>execute()</code></a> or take an action that executes.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#resume--"><code>resume()</code></a>,
<a href="../robocode/Robot.html#stop--"><code>stop()</code></a>,
<a href="../robocode/Robot.html#stop-boolean-"><code>stop(boolean)</code></a>,
<a href="../robocode/AdvancedRobot.html#setStop--"><code>setStop()</code></a>,
<a href="../robocode/AdvancedRobot.html#setStop-boolean-"><code>setStop(boolean)</code></a>,
<a href="../robocode/AdvancedRobot.html#execute--"><code>execute()</code></a></dd>
</dl>
</li>
</ul>
<a name="setStop--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setStop</h4>
<pre>public void setStop()</pre>
<div class="block">This call is identical to <a href="../robocode/Robot.html#stop--"><code>stop()</code></a>, but returns immediately, and
will not execute until you call <a href="../robocode/AdvancedRobot.html#execute--"><code>execute()</code></a> or take an action that
executes.
<p>
If there is already movement saved from a previous stop, this will have
no effect.
<p>
This call is equivalent to calling <code>setStop(false)</code>;</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#stop--"><code>stop()</code></a>,
<a href="../robocode/Robot.html#stop-boolean-"><code>stop(boolean)</code></a>,
<a href="../robocode/Robot.html#resume--"><code>resume()</code></a>,
<a href="../robocode/AdvancedRobot.html#setResume--"><code>setResume()</code></a>,
<a href="../robocode/AdvancedRobot.html#setStop-boolean-"><code>setStop(boolean)</code></a>,
<a href="../robocode/AdvancedRobot.html#execute--"><code>execute()</code></a></dd>
</dl>
</li>
</ul>
<a name="setStop-boolean-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setStop</h4>
<pre>public void setStop(boolean overwrite)</pre>
<div class="block">This call is identical to <a href="../robocode/Robot.html#stop-boolean-"><code>stop(boolean)</code></a>, but
returns immediately, and will not execute until you call
<a href="../robocode/AdvancedRobot.html#execute--"><code>execute()</code></a> or take an action that executes.
<p>
If there is already movement saved from a previous stop, you can
overwrite it by calling <code>setStop(true)</code>.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>overwrite</code> - <code>true</code> if the movement saved from a previous stop
should be overwritten; <code>false</code> otherwise.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#stop--"><code>stop()</code></a>,
<a href="../robocode/Robot.html#stop-boolean-"><code>stop(boolean)</code></a>,
<a href="../robocode/Robot.html#resume--"><code>resume()</code></a>,
<a href="../robocode/AdvancedRobot.html#setResume--"><code>setResume()</code></a>,
<a href="../robocode/AdvancedRobot.html#setStop--"><code>setStop()</code></a>,
<a href="../robocode/AdvancedRobot.html#execute--"><code>execute()</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnGunLeft-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnGunLeft</h4>
<pre>public void setTurnGunLeft(double degrees)</pre>
<div class="block">Sets the robot's gun to turn left by degrees when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's gun is set to turn right
instead of left.
<p>
Example:
<pre>
// Set the gun to turn 180 degrees to the left
setTurnGunLeft(180);
// Set the gun to turn 90 degrees to the right instead of left
// (overrides the previous order)
setTurnGunLeft(-90);
...
// Executes the last setTurnGunLeft()
execute();
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>degrees</code> - the amount of degrees to turn the robot's gun to the left.
If <code>degrees</code> > 0 the robot's gun is set to turn left.
If <code>degrees</code> < 0 the robot's gun is set to turn right.
If <code>degrees</code> = 0 the robot's gun is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnGunLeftRadians-double-"><code>setTurnGunLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunLeft-double-"><code>turnGunLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunLeftRadians-double-"><code>turnGunLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunRight-double-"><code>turnGunRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunRightRadians-double-"><code>turnGunRightRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnGunRight-double-"><code>setTurnGunRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnGunRightRadians-double-"><code>setTurnGunRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustGunForRobotTurn-boolean-"><code>setAdjustGunForRobotTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnGunRight-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnGunRight</h4>
<pre>public void setTurnGunRight(double degrees)</pre>
<div class="block">Sets the robot's gun to turn right by degrees when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's gun is set to turn left
instead of right.
<p>
Example:
<pre>
// Set the gun to turn 180 degrees to the right
setTurnGunRight(180);
// Set the gun to turn 90 degrees to the left instead of right
// (overrides the previous order)
setTurnGunRight(-90);
...
// Executes the last setTurnGunRight()
execute();
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>degrees</code> - the amount of degrees to turn the robot's gun to the right.
If <code>degrees</code> > 0 the robot's gun is set to turn right.
If <code>degrees</code> < 0 the robot's gun is set to turn left.
If <code>degrees</code> = 0 the robot's gun is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnGunRightRadians-double-"><code>setTurnGunRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunRight-double-"><code>turnGunRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunRightRadians-double-"><code>turnGunRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunLeft-double-"><code>turnGunLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunLeftRadians-double-"><code>turnGunLeftRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnGunLeft-double-"><code>setTurnGunLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnGunLeftRadians-double-"><code>setTurnGunLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustGunForRobotTurn-boolean-"><code>setAdjustGunForRobotTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnRadarLeft-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnRadarLeft</h4>
<pre>public void setTurnRadarLeft(double degrees)</pre>
<div class="block">Sets the robot's radar to turn left by degrees when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's radar is set to turn right
instead of left.
<p>
Example:
<pre>
// Set the radar to turn 180 degrees to the left
setTurnRadarLeft(180);
// Set the radar to turn 90 degrees to the right instead of left
// (overrides the previous order)
setTurnRadarLeft(-90);
...
// Executes the last setTurnRadarLeft()
execute();
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>degrees</code> - the amount of degrees to turn the robot's radar to the left.
If <code>degrees</code> > 0 the robot's radar is set to turn left.
If <code>degrees</code> < 0 the robot's radar is set to turn right.
If <code>degrees</code> = 0 the robot's radar is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnRadarLeftRadians-double-"><code>setTurnRadarLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarLeft-double-"><code>turnRadarLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarLeftRadians-double-"><code>turnRadarLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarRight-double-"><code>turnRadarRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarRightRadians-double-"><code>turnRadarRightRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRadarRight-double-"><code>setTurnRadarRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRadarRightRadians-double-"><code>setTurnRadarRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForRobotTurn-boolean-"><code>setAdjustRadarForRobotTurn(boolean)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForGunTurn-boolean-"><code>setAdjustRadarForGunTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnRadarRight-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnRadarRight</h4>
<pre>public void setTurnRadarRight(double degrees)</pre>
<div class="block">Sets the robot's radar to turn right by degrees when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's radar is set to turn left
instead of right.
<p>
Example:
<pre>
// Set the radar to turn 180 degrees to the right
setTurnRadarRight(180);
// Set the radar to turn 90 degrees to the right instead of right
// (overrides the previous order)
setTurnRadarRight(-90);
...
// Executes the last setTurnRadarRight()
execute();
</pre></div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>degrees</code> - the amount of degrees to turn the robot's radar to the right.
If <code>degrees</code> > 0 the robot's radar is set to turn right.
If <code>degrees</code> < 0 the robot's radar is set to turn left.
If <code>degrees</code> = 0 the robot's radar is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnRadarRightRadians-double-"><code>setTurnRadarRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarRight-double-"><code>turnRadarRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarRightRadians-double-"><code>turnRadarRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarLeft-double-"><code>turnRadarLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarLeftRadians-double-"><code>turnRadarLeftRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRadarLeft-double-"><code>setTurnRadarLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRadarLeftRadians-double-"><code>setTurnRadarLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForRobotTurn-boolean-"><code>setAdjustRadarForRobotTurn(boolean)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForGunTurn-boolean-"><code>setAdjustRadarForGunTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="waitFor-robocode.Condition-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>waitFor</h4>
<pre>public void waitFor(<a href="../robocode/Condition.html" title="class in robocode">Condition</a> condition)</pre>
<div class="block">Does not return until a condition is met, i.e. when a
<a href="../robocode/Condition.html#test--"><code>Condition.test()</code></a> returns <code>true</code>.
<p>
This call executes immediately.
<p>
See the <code>sample.Crazy</code> robot for how this method can be used.</div>
<dl>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>condition</code> - the condition that must be met before this call returns</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Condition.html" title="class in robocode"><code>Condition</code></a>,
<a href="../robocode/Condition.html#test--"><code>Condition.test()</code></a></dd>
</dl>
</li>
</ul>
<a name="onDeath-robocode.DeathEvent-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>onDeath</h4>
<pre>public void onDeath(<a href="../robocode/DeathEvent.html" title="class in robocode">DeathEvent</a> event)</pre>
<div class="block">This method is called if your robot dies.
<p>
You should override it in your robot if you want to be informed of this
event. Actions will have no effect if called from this section. The
intent is to allow you to perform calculations or print something out
when the robot is killed.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../robocode/robotinterfaces/IBasicEvents.html#onDeath-robocode.DeathEvent-">onDeath</a></code> in interface <code><a href="../robocode/robotinterfaces/IBasicEvents.html" title="interface in robocode.robotinterfaces">IBasicEvents</a></code></dd>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/Robot.html#onDeath-robocode.DeathEvent-">onDeath</a></code> in class <code><a href="../robocode/Robot.html" title="class in robocode">Robot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>event</code> - the death event set by the game</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/DeathEvent.html" title="class in robocode"><code>DeathEvent</code></a>,
<a href="../robocode/Event.html" title="class in robocode"><code>Event</code></a></dd>
</dl>
</li>
</ul>
<a name="onSkippedTurn-robocode.SkippedTurnEvent-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>onSkippedTurn</h4>
<pre>public void onSkippedTurn(<a href="../robocode/SkippedTurnEvent.html" title="class in robocode">SkippedTurnEvent</a> event)</pre>
<div class="block">This method is called if the robot is using too much time between
actions. When this event occur, the robot's turn is skipped, meaning that
it cannot take action anymore in this turn.
<p>
If you receive 30 skipped turn event, your robot will be removed from the
round and loose the round.
<p>
You will only receive this event after taking an action. So a robot in an
infinite loop will not receive any events, and will simply be stopped.
<p>
No correctly working, reasonable robot should ever receive this event
unless it is using too many CPU cycles.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../robocode/robotinterfaces/IAdvancedEvents.html#onSkippedTurn-robocode.SkippedTurnEvent-">onSkippedTurn</a></code> in interface <code><a href="../robocode/robotinterfaces/IAdvancedEvents.html" title="interface in robocode.robotinterfaces">IAdvancedEvents</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>event</code> - the skipped turn event set by the game</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/SkippedTurnEvent.html" title="class in robocode"><code>SkippedTurnEvent</code></a>,
<a href="../robocode/Event.html" title="class in robocode"><code>Event</code></a></dd>
</dl>
</li>
</ul>
<a name="getHeadingRadians--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getHeadingRadians</h4>
<pre>public double getHeadingRadians()</pre>
<div class="block">Returns the direction that the robot's body is facing, in radians.
The value returned will be between 0 and 2 * PI (is excluded).
<p>
Note that the heading in Robocode is like a compass, where 0 means North,
PI / 2 means East, PI means South, and 3 * PI / 2 means West.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#getHeadingRadians--">getHeadingRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the direction that the robot's body is facing, in radians.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/_AdvancedRobot.html#getHeadingDegrees--"><code>_AdvancedRobot.getHeadingDegrees()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunHeadingRadians--"><code>getGunHeadingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarHeadingRadians--"><code>getRadarHeadingRadians()</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnLeftRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnLeftRadians</h4>
<pre>public void setTurnLeftRadians(double radians)</pre>
<div class="block">Sets the robot's body to turn left by radians when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's body is set to turn right
instead of left.
<p>
Example:
<pre>
// Set the robot to turn 180 degrees to the left
setTurnLeftRadians(Math.PI);
// Set the robot to turn 90 degrees to the right instead of left
// (overrides the previous order)
setTurnLeftRadians(-Math.PI / 2);
...
// Executes the last setTurnLeftRadians()
execute();
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#setTurnLeftRadians-double-">setTurnLeftRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's body to the left.
If <code>radians</code> > 0 the robot is set to turn left.
If <code>radians</code> < 0 the robot is set to turn right.
If <code>radians</code> = 0 the robot is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnLeft-double-"><code>setTurnLeft(double)</code></a>,
<a href="../robocode/Robot.html#turnLeft-double-"><code>Robot.turnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnLeftRadians-double-"><code>turnLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRight-double-"><code>Robot.turnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRightRadians-double-"><code>turnRightRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRight-double-"><code>setTurnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRightRadians-double-"><code>setTurnRightRadians(double)</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnRightRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnRightRadians</h4>
<pre>public void setTurnRightRadians(double radians)</pre>
<div class="block">Sets the robot's body to turn right by radians when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's body is set to turn left
instead of right.
<p>
Example:
<pre>
// Set the robot to turn 180 degrees to the right
setTurnRightRadians(Math.PI);
// Set the robot to turn 90 degrees to the left instead of right
// (overrides the previous order)
setTurnRightRadians(-Math.PI / 2);
...
// Executes the last setTurnRightRadians()
execute();
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#setTurnRightRadians-double-">setTurnRightRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's body to the right.
If <code>radians</code> > 0 the robot is set to turn right.
If <code>radians</code> < 0 the robot is set to turn left.
If <code>radians</code> = 0 the robot is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnRight-double-"><code>setTurnRight(double)</code></a>,
<a href="../robocode/Robot.html#turnRight-double-"><code>Robot.turnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRightRadians-double-"><code>turnRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnLeft-double-"><code>Robot.turnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnLeftRadians-double-"><code>turnLeftRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnLeft-double-"><code>setTurnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnLeftRadians-double-"><code>setTurnLeftRadians(double)</code></a></dd>
</dl>
</li>
</ul>
<a name="turnLeftRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>turnLeftRadians</h4>
<pre>public void turnLeftRadians(double radians)</pre>
<div class="block">Immediately turns the robot's body to the left by radians.
<p>
This call executes immediately, and does not return until it is complete,
i.e. when the angle remaining in the robot's turn is 0.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's body is set to turn right
instead of left.
<p>
Example:
<pre>
// Turn the robot 180 degrees to the left
turnLeftRadians(Math.PI);
// Afterwards, turn the robot 90 degrees to the right
turnLeftRadians(-Math.PI / 2);
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#turnLeftRadians-double-">turnLeftRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's body to the left.
If <code>radians</code> > 0 the robot will turn right.
If <code>radians</code> < 0 the robot will turn left.
If <code>radians</code> = 0 the robot will not turn, but execute.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#turnLeft-double-"><code>Robot.turnLeft(double)</code></a>,
<a href="../robocode/Robot.html#turnRight-double-"><code>Robot.turnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRightRadians-double-"><code>turnRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunLeft-double-"><code>Robot.turnGunLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunLeftRadians-double-"><code>turnGunLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunRight-double-"><code>Robot.turnGunRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunRightRadians-double-"><code>turnGunRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarLeft-double-"><code>Robot.turnRadarLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarLeftRadians-double-"><code>turnRadarLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarRight-double-"><code>Robot.turnRadarRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarRightRadians-double-"><code>turnRadarRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustGunForRobotTurn-boolean-"><code>Robot.setAdjustGunForRobotTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="turnRightRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>turnRightRadians</h4>
<pre>public void turnRightRadians(double radians)</pre>
<div class="block">Immediately turns the robot's body to the right by radians.
This call executes immediately, and does not return until it is complete,
i.e. when the angle remaining in the robot's turn is 0.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's body is set to turn left
instead of right.
<p>
Example:
<pre>
// Turn the robot 180 degrees to the right
turnRightRadians(Math.PI);
// Afterwards, turn the robot 90 degrees to the left
turnRightRadians(-Math.PI / 2);
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#turnRightRadians-double-">turnRightRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's body to the right.
If <code>radians</code> > 0 the robot will turn right.
If <code>radians</code> < 0 the robot will turn left.
If <code>radians</code> = 0 the robot will not turn, but execute.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#turnRight-double-"><code>Robot.turnRight(double)</code></a>,
<a href="../robocode/Robot.html#turnLeft-double-"><code>Robot.turnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnLeftRadians-double-"><code>turnLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunLeft-double-"><code>Robot.turnGunLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunLeftRadians-double-"><code>turnGunLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunRight-double-"><code>Robot.turnGunRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunRightRadians-double-"><code>turnGunRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarLeft-double-"><code>Robot.turnRadarLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarLeftRadians-double-"><code>turnRadarLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarRight-double-"><code>Robot.turnRadarRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarRightRadians-double-"><code>turnRadarRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustGunForRobotTurn-boolean-"><code>Robot.setAdjustGunForRobotTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="getGunHeadingRadians--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getGunHeadingRadians</h4>
<pre>public double getGunHeadingRadians()</pre>
<div class="block">Returns the direction that the robot's gun is facing, in radians.
The value returned will be between 0 and 2 * PI (is excluded).
<p>
Note that the heading in Robocode is like a compass, where 0 means North,
PI / 2 means East, PI means South, and 3 * PI / 2 means West.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#getGunHeadingRadians--">getGunHeadingRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the direction that the robot's gun is facing, in radians.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/_AdvancedRobot.html#getGunHeadingDegrees--"><code>_AdvancedRobot.getGunHeadingDegrees()</code></a>,
<a href="../robocode/AdvancedRobot.html#getHeadingRadians--"><code>getHeadingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarHeadingRadians--"><code>getRadarHeadingRadians()</code></a></dd>
</dl>
</li>
</ul>
<a name="getRadarHeadingRadians--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getRadarHeadingRadians</h4>
<pre>public double getRadarHeadingRadians()</pre>
<div class="block">Returns the direction that the robot's radar is facing, in radians.
The value returned will be between 0 and 2 * PI (is excluded).
<p>
Note that the heading in Robocode is like a compass, where 0 means North,
PI / 2 means East, PI means South, and 3 * PI / 2 means West.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#getRadarHeadingRadians--">getRadarHeadingRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the direction that the robot's radar is facing, in radians.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/_AdvancedRobot.html#getRadarHeadingDegrees--"><code>_AdvancedRobot.getRadarHeadingDegrees()</code></a>,
<a href="../robocode/AdvancedRobot.html#getHeadingRadians--"><code>getHeadingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunHeadingRadians--"><code>getGunHeadingRadians()</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnGunLeftRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnGunLeftRadians</h4>
<pre>public void setTurnGunLeftRadians(double radians)</pre>
<div class="block">Sets the robot's gun to turn left by radians when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's gun is set to turn right
instead of left.
<p>
Example:
<pre>
// Set the gun to turn 180 degrees to the left
setTurnGunLeftRadians(Math.PI);
// Set the gun to turn 90 degrees to the right instead of left
// (overrides the previous order)
setTurnGunLeftRadians(-Math.PI / 2);
...
// Executes the last setTurnGunLeftRadians()
execute();
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#setTurnGunLeftRadians-double-">setTurnGunLeftRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's gun to the left.
If <code>radians</code> > 0 the robot's gun is set to turn left.
If <code>radians</code> < 0 the robot's gun is set to turn right.
If <code>radians</code> = 0 the robot's gun is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnGunLeft-double-"><code>setTurnGunLeft(double)</code></a>,
<a href="../robocode/Robot.html#turnGunLeft-double-"><code>Robot.turnGunLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunLeftRadians-double-"><code>turnGunLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunRight-double-"><code>Robot.turnGunRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunRightRadians-double-"><code>turnGunRightRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnGunRight-double-"><code>setTurnGunRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnGunRightRadians-double-"><code>setTurnGunRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustGunForRobotTurn-boolean-"><code>Robot.setAdjustGunForRobotTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnGunRightRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnGunRightRadians</h4>
<pre>public void setTurnGunRightRadians(double radians)</pre>
<div class="block">Sets the robot's gun to turn right by radians when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's gun is set to turn left
instead of right.
<p>
Example:
<pre>
// Set the gun to turn 180 degrees to the right
setTurnGunRightRadians(Math.PI);
// Set the gun to turn 90 degrees to the left instead of right
// (overrides the previous order)
setTurnGunRightRadians(-Math.PI / 2);
...
// Executes the last setTurnGunRightRadians()
execute();
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#setTurnGunRightRadians-double-">setTurnGunRightRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's gun to the right.
If <code>radians</code> > 0 the robot's gun is set to turn left.
If <code>radians</code> < 0 the robot's gun is set to turn right.
If <code>radians</code> = 0 the robot's gun is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnGunRight-double-"><code>setTurnGunRight(double)</code></a>,
<a href="../robocode/Robot.html#turnGunRight-double-"><code>Robot.turnGunRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunRightRadians-double-"><code>turnGunRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunLeft-double-"><code>Robot.turnGunLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunLeftRadians-double-"><code>turnGunLeftRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnGunLeft-double-"><code>setTurnGunLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnGunLeftRadians-double-"><code>setTurnGunLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustGunForRobotTurn-boolean-"><code>Robot.setAdjustGunForRobotTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnRadarLeftRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnRadarLeftRadians</h4>
<pre>public void setTurnRadarLeftRadians(double radians)</pre>
<div class="block">Sets the robot's radar to turn left by radians when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's radar is set to turn right
instead of left.
<p>
Example:
<pre>
// Set the radar to turn 180 degrees to the left
setTurnRadarLeftRadians(Math.PI);
// Set the radar to turn 90 degrees to the right instead of left
// (overrides the previous order)
setTurnRadarLeftRadians(-Math.PI / 2);
...
// Executes the last setTurnRadarLeftRadians()
execute();
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#setTurnRadarLeftRadians-double-">setTurnRadarLeftRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's radar to the left.
If <code>radians</code> > 0 the robot's radar is set to turn left.
If <code>radians</code> < 0 the robot's radar is set to turn right.
If <code>radians</code> = 0 the robot's radar is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnRadarLeft-double-"><code>setTurnRadarLeft(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarLeft-double-"><code>Robot.turnRadarLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarLeftRadians-double-"><code>turnRadarLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarRight-double-"><code>Robot.turnRadarRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarRightRadians-double-"><code>turnRadarRightRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRadarRight-double-"><code>setTurnRadarRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRadarRightRadians-double-"><code>setTurnRadarRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForRobotTurn-boolean-"><code>Robot.setAdjustRadarForRobotTurn(boolean)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForGunTurn-boolean-"><code>Robot.setAdjustRadarForGunTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="setTurnRadarRightRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>setTurnRadarRightRadians</h4>
<pre>public void setTurnRadarRightRadians(double radians)</pre>
<div class="block">Sets the robot's radar to turn right by radians when the next execution
takes place.
<p>
This call returns immediately, and will not execute until you call
execute() or take an action that executes.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's radar is set to turn left
instead of right.
<p>
Example:
<pre>
// Set the radar to turn 180 degrees to the right
setTurnRadarRightRadians(Math.PI);
// Set the radar to turn 90 degrees to the right instead of right
// (overrides the previous order)
setTurnRadarRightRadians(-Math.PI / 2);
...
// Executes the last setTurnRadarRightRadians()
execute();
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#setTurnRadarRightRadians-double-">setTurnRadarRightRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's radar to the right.
If <code>radians</code> > 0 the robot's radar is set to turn left.
If <code>radians</code> < 0 the robot's radar is set to turn right.
If <code>radians</code> = 0 the robot's radar is set to stop turning.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#setTurnRadarRight-double-"><code>setTurnRadarRight(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarRight-double-"><code>Robot.turnRadarRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarRightRadians-double-"><code>turnRadarRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarLeft-double-"><code>Robot.turnRadarLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarLeftRadians-double-"><code>turnRadarLeftRadians(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRadarLeft-double-"><code>setTurnRadarLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#setTurnRadarLeftRadians-double-"><code>setTurnRadarLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForRobotTurn-boolean-"><code>Robot.setAdjustRadarForRobotTurn(boolean)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForGunTurn-boolean-"><code>Robot.setAdjustRadarForGunTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="turnGunLeftRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>turnGunLeftRadians</h4>
<pre>public void turnGunLeftRadians(double radians)</pre>
<div class="block">Immediately turns the robot's gun to the left by radians.
<p>
This call executes immediately, and does not return until it is complete,
i.e. when the angle remaining in the gun's turn is 0.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's gun is set to turn right
instead of left.
<p>
Example:
<pre>
// Turn the robot's gun 180 degrees to the left
turnGunLeftRadians(Math.PI);
// Afterwards, turn the robot's gun 90 degrees to the right
turnGunLeftRadians(-Math.PI / 2);
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#turnGunLeftRadians-double-">turnGunLeftRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's gun to the left.
If <code>radians</code> > 0 the robot's gun will turn left.
If <code>radians</code> < 0 the robot's gun will turn right.
If <code>radians</code> = 0 the robot's gun will not turn, but execute.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#turnGunLeft-double-"><code>Robot.turnGunLeft(double)</code></a>,
<a href="../robocode/Robot.html#turnGunRight-double-"><code>Robot.turnGunRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunRightRadians-double-"><code>turnGunRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnLeft-double-"><code>Robot.turnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnLeftRadians-double-"><code>turnLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRight-double-"><code>Robot.turnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRightRadians-double-"><code>turnRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarLeft-double-"><code>Robot.turnRadarLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarLeftRadians-double-"><code>turnRadarLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarRight-double-"><code>Robot.turnRadarRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarRightRadians-double-"><code>turnRadarRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustGunForRobotTurn-boolean-"><code>Robot.setAdjustGunForRobotTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="turnGunRightRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>turnGunRightRadians</h4>
<pre>public void turnGunRightRadians(double radians)</pre>
<div class="block">Immediately turns the robot's gun to the right by radians.
This call executes immediately, and does not return until it is complete,
i.e. when the angle remaining in the gun's turn is 0.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's gun is set to turn left
instead of right.
<p>
Example:
<pre>
// Turn the robot's gun 180 degrees to the right
turnGunRightRadians(Math.PI);
// Afterwards, turn the robot's gun 90 degrees to the left
turnGunRightRadians(-Math.PI / 2);
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#turnGunRightRadians-double-">turnGunRightRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's gun to the right.
If <code>radians</code> > 0 the robot's gun will turn right.
If <code>radians</code> < 0 the robot's gun will turn left.
If <code>radians</code> = 0 the robot's gun will not turn, but execute.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#turnGunRight-double-"><code>Robot.turnGunRight(double)</code></a>,
<a href="../robocode/Robot.html#turnGunLeft-double-"><code>Robot.turnGunLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunLeftRadians-double-"><code>turnGunLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnLeft-double-"><code>Robot.turnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnLeftRadians-double-"><code>turnLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRight-double-"><code>Robot.turnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRightRadians-double-"><code>turnRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarLeft-double-"><code>Robot.turnRadarLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarLeftRadians-double-"><code>turnRadarLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarRight-double-"><code>Robot.turnRadarRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRadarRightRadians-double-"><code>turnRadarRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustGunForRobotTurn-boolean-"><code>Robot.setAdjustGunForRobotTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="turnRadarLeftRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>turnRadarLeftRadians</h4>
<pre>public void turnRadarLeftRadians(double radians)</pre>
<div class="block">Immediately turns the robot's radar to the left by radians.
<p>
This call executes immediately, and does not return until it is complete,
i.e. when the angle remaining in the radar's turn is 0.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's radar is set to turn right
instead of left.
<p>
Example:
<pre>
// Turn the robot's radar 180 degrees to the left
turnRadarLeftRadians(Math.PI);
// Afterwards, turn the robot's radar 90 degrees to the right
turnRadarLeftRadians(-Math.PI / 2);
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#turnRadarLeftRadians-double-">turnRadarLeftRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's radar to the left.
If <code>radians</code> > 0 the robot's radar will turn left.
If <code>radians</code> < 0 the robot's radar will turn right.
If <code>radians</code> = 0 the robot's radar will not turn, but execute.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#turnRadarLeft-double-"><code>Robot.turnRadarLeft(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarRight-double-"><code>Robot.turnRadarRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunRightRadians-double-"><code>turnGunRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnLeft-double-"><code>Robot.turnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnLeftRadians-double-"><code>turnLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRight-double-"><code>Robot.turnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRightRadians-double-"><code>turnRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunLeft-double-"><code>Robot.turnGunLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunLeftRadians-double-"><code>turnGunLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunRight-double-"><code>Robot.turnGunRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunRightRadians-double-"><code>turnGunRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForRobotTurn-boolean-"><code>Robot.setAdjustRadarForRobotTurn(boolean)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForGunTurn-boolean-"><code>Robot.setAdjustRadarForGunTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="turnRadarRightRadians-double-">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>turnRadarRightRadians</h4>
<pre>public void turnRadarRightRadians(double radians)</pre>
<div class="block">Immediately turns the robot's radar to the right by radians.
This call executes immediately, and does not return until it is complete,
i.e. when the angle remaining in the radar's turn is 0.
<p>
Note that both positive and negative values can be given as input,
where negative values means that the robot's radar is set to turn left
instead of right.
<p>
Example:
<pre>
// Turn the robot's radar 180 degrees to the right
turnRadarRightRadians(Math.PI);
// Afterwards, turn the robot's radar 90 degrees to the left
turnRadarRightRadians(-Math.PI / 2);
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#turnRadarRightRadians-double-">turnRadarRightRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="paramLabel">Parameters:</span></dt>
<dd><code>radians</code> - the amount of radians to turn the robot's radar to the right.
If <code>radians</code> > 0 the robot's radar will turn right.
If <code>radians</code> < 0 the robot's radar will turn left.
If <code>radians</code> = 0 the robot's radar will not turn, but execute.</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/Robot.html#turnRadarRight-double-"><code>Robot.turnRadarRight(double)</code></a>,
<a href="../robocode/Robot.html#turnRadarLeft-double-"><code>Robot.turnRadarLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunLeftRadians-double-"><code>turnGunLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnLeft-double-"><code>Robot.turnLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnLeftRadians-double-"><code>turnLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnRight-double-"><code>Robot.turnRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnRightRadians-double-"><code>turnRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunLeft-double-"><code>Robot.turnGunLeft(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunLeftRadians-double-"><code>turnGunLeftRadians(double)</code></a>,
<a href="../robocode/Robot.html#turnGunRight-double-"><code>Robot.turnGunRight(double)</code></a>,
<a href="../robocode/AdvancedRobot.html#turnGunRightRadians-double-"><code>turnGunRightRadians(double)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForRobotTurn-boolean-"><code>Robot.setAdjustRadarForRobotTurn(boolean)</code></a>,
<a href="../robocode/Robot.html#setAdjustRadarForGunTurn-boolean-"><code>Robot.setAdjustRadarForGunTurn(boolean)</code></a></dd>
</dl>
</li>
</ul>
<a name="getGunTurnRemainingRadians--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getGunTurnRemainingRadians</h4>
<pre>public double getGunTurnRemainingRadians()</pre>
<div class="block">Returns the angle remaining in the gun's turn, in radians.
<p>
This call returns both positive and negative values. Positive values
means that the gun is currently turning to the right. Negative values
means that the gun is currently turning to the left.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#getGunTurnRemainingRadians--">getGunTurnRemainingRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the angle remaining in the gun's turn, in radians</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getGunTurnRemaining--"><code>getGunTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getTurnRemaining--"><code>getTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getTurnRemainingRadians--"><code>getTurnRemainingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemaining--"><code>getRadarTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemainingRadians--"><code>getRadarTurnRemainingRadians()</code></a></dd>
</dl>
</li>
</ul>
<a name="getRadarTurnRemainingRadians--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getRadarTurnRemainingRadians</h4>
<pre>public double getRadarTurnRemainingRadians()</pre>
<div class="block">Returns the angle remaining in the radar's turn, in radians.
<p>
This call returns both positive and negative values. Positive values
means that the radar is currently turning to the right. Negative values
means that the radar is currently turning to the left.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#getRadarTurnRemainingRadians--">getRadarTurnRemainingRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the angle remaining in the radar's turn, in radians</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getRadarTurnRemaining--"><code>getRadarTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getTurnRemaining--"><code>getTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getTurnRemainingRadians--"><code>getTurnRemainingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunTurnRemaining--"><code>getGunTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunTurnRemainingRadians--"><code>getGunTurnRemainingRadians()</code></a></dd>
</dl>
</li>
</ul>
<a name="getTurnRemainingRadians--">
<!-- -->
</a>
<ul class="blockList">
<li class="blockList">
<h4>getTurnRemainingRadians</h4>
<pre>public double getTurnRemainingRadians()</pre>
<div class="block">Returns the angle remaining in the robot's turn, in radians.
<p>
This call returns both positive and negative values. Positive values
means that the robot is currently turning to the right. Negative values
means that the robot is currently turning to the left.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../robocode/_AdvancedRadiansRobot.html#getTurnRemainingRadians--">getTurnRemainingRadians</a></code> in class <code><a href="../robocode/_AdvancedRadiansRobot.html" title="class in robocode">_AdvancedRadiansRobot</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>the angle remaining in the robot's turn, in radians</dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../robocode/AdvancedRobot.html#getTurnRemaining--"><code>getTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunTurnRemaining--"><code>getGunTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getGunTurnRemainingRadians--"><code>getGunTurnRemainingRadians()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemaining--"><code>getRadarTurnRemaining()</code></a>,
<a href="../robocode/AdvancedRobot.html#getRadarTurnRemainingRadians--"><code>getRadarTurnRemainingRadians()</code></a></dd>
</dl>
</li>
</ul>
<a name="getAdvancedEventListener--">
<!-- -->
</a>
<ul class="blockListLast">
<li class="blockList">
<h4>getAdvancedEventListener</h4>
<pre>public final <a href="../robocode/robotinterfaces/IAdvancedEvents.html" title="interface in robocode.robotinterfaces">IAdvancedEvents</a> getAdvancedEventListener()</pre>
<div class="block">Do not call this method!
<p>
This method is called by the game to notify this robot about advanced
robot event. Hence, this method must be implemented so it returns your
<a href="../robocode/robotinterfaces/IAdvancedEvents.html" title="interface in robocode.robotinterfaces"><code>IAdvancedEvents</code></a> listener.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../robocode/robotinterfaces/IAdvancedRobot.html#getAdvancedEventListener--">getAdvancedEventListener</a></code> in interface <code><a href="../robocode/robotinterfaces/IAdvancedRobot.html" title="interface in robocode.robotinterfaces">IAdvancedRobot</a></code></dd>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>listener to advanced events or <code>null</code> if this robot should
not receive the notifications.</dd>
</dl>
</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
<!-- ========= END OF CLASS DATA ========= -->
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a name="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a name="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../overview-summary.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../deprecated-list.html">Deprecated</a></li>
<li><a href="../index-all.html">Index</a></li>
<li><a href="../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<ul class="navList">
<li><a href="../robocode/_RobotBase.html" title="class in robocode"><span class="typeNameLink">Prev Class</span></a></li>
<li><a href="../robocode/BattleEndedEvent.html" title="class in robocode"><span class="typeNameLink">Next Class</span></a></li>
</ul>
<ul class="navList">
<li><a href="../index.html?robocode/AdvancedRobot.html" target="_top">Frames</a></li>
<li><a href="AdvancedRobot.html" target="_top">No Frames</a></li>
</ul>
<ul class="navList" id="allclasses_navbar_bottom">
<li><a href="../allclasses-noframe.html">All Classes</a></li>
</ul>
<div>
<script type="text/javascript"><!--
allClassesLink = document.getElementById("allclasses_navbar_bottom");
if(window==top) {
allClassesLink.style.display = "block";
}
else {
allClassesLink.style.display = "none";
}
//-->
</script>
</div>
<div>
<ul class="subNavList">
<li>Summary: </li>
<li>Nested | </li>
<li><a href="#fields.inherited.from.class.robocode._RobotBase">Field</a> | </li>
<li><a href="#constructor.summary">Constr</a> | </li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail: </li>
<li>Field | </li>
<li><a href="#constructor.detail">Constr</a> | </li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<a name="skip.navbar.bottom">
<!-- -->
</a></div>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<p class="legalCopy"><small>Copyright © 2017 <a href="http://robocode.sf.net">Robocode</a>. All Rights Reserved.</small></p>
</body>
</html>
| 55.814105 | 5,986 | 0.711465 |
04626e40e2e3b395686b0346d56536f2cb94de93 | 3,319 | swift | Swift | CoreDataTask/ADDAddressViewController.swift | Kinjal8899/CoreDataTask | fa82fd9e8d54cc9d05e75e2ecae6edab94e32bc5 | [
"MIT"
] | null | null | null | CoreDataTask/ADDAddressViewController.swift | Kinjal8899/CoreDataTask | fa82fd9e8d54cc9d05e75e2ecae6edab94e32bc5 | [
"MIT"
] | null | null | null | CoreDataTask/ADDAddressViewController.swift | Kinjal8899/CoreDataTask | fa82fd9e8d54cc9d05e75e2ecae6edab94e32bc5 | [
"MIT"
] | null | null | null | //
// ADDAddressViewController.swift
// CoreDataTask
//
// Created by MacMini1 on 01/03/21.
// Copyright © 2021 bacancy. All rights reserved.
//
import UIKit
class ADDAddressViewController: UIViewController {
var coreDataModel = CoreDataModel()
@IBOutlet weak var txtStreet: UITextField!
@IBOutlet weak var txtArea: UITextField!
@IBOutlet weak var txtCity: UITextField!
@IBOutlet weak var txtDistrict: UITextField!
@IBOutlet weak var txtPincode: UITextField!
@IBOutlet weak var btnSaveAddress: UIButton!
var user:User?
override func viewDidLoad() {
super.viewDidLoad()
//print(user!)
}
@IBAction func addAddressClicked(_ sender: UIButton) {
if txtStreet.text!.isEmpty || txtArea.text!.isEmpty || txtCity.text!.isEmpty || txtDistrict.text!.isEmpty || txtPincode.text!.isEmpty {
let alert = UIAlertController(title: "Invalid", message: "Please fill up all the details", preferredStyle: .alert)
let saveAction = UIAlertAction(title: "Okay", style: .default) { (action) in
}
alert.addAction(saveAction)
self.present(alert, animated: true, completion: nil)
}
else {
let street = txtStreet.text
let area = txtArea.text
let city = txtCity.text
let district = txtDistrict.text
let pincode = txtPincode.text
let addFlag = coreDataModel.addUserAddress(user: user!, street: street!, area: area!, city: city!, district: district!, pincode: pincode!)
if(addFlag) {
//print("Address details are saved...")
let alert = UIAlertController(title: "Success", message: "Address details are saved.", preferredStyle: .alert)
let saveAction = UIAlertAction(title: "Okay", style: .default) { (action) in
self.txtStreet.text = ""
self.txtArea.text = ""
self.txtCity.text = ""
self.txtDistrict.text = ""
self.txtPincode.text = ""
}
alert.addAction(saveAction)
self.present(alert, animated: true, completion: nil)
}
else {
print("Sorry,Address details are not saved...")
}
}
}
@IBAction func showAddressClicked(_ sender: UIButton) {
let arrUserAddresses = coreDataModel.showAllAddresses(user: user!)
if arrUserAddresses.count > 0 {
//print(arrUserAddresses)
let aVC = self.storyboard?.instantiateViewController(identifier: "ShowAllUserAddressesViewController") as! ShowAllUserAddressesViewController
aVC.arrUserAddresses = arrUserAddresses
aVC.user = user
self.navigationController?.pushViewController(aVC, animated: true)
}
else {
let alert = UIAlertController(title: "Sorry", message: "This user doesn't have any addresses yet saved.", preferredStyle: .alert)
let saveAction = UIAlertAction(title: "Okay", style: .default) { (action) in
}
alert.addAction(saveAction)
self.present(alert, animated: true, completion: nil)
}
}
}
| 39.511905 | 153 | 0.598674 |
688baa597f75efc2e28e6c22fee2e2208afa2c1f | 1,680 | sql | SQL | src/main/java/EggGeth.sql | Rebeccalomi/agriorigin | 32e88abef33b8f03aa5229364edd189956c2d9f6 | [
"Apache-2.0"
] | 1 | 2022-03-08T04:12:34.000Z | 2022-03-08T04:12:34.000Z | src/main/java/EggGeth.sql | Rebeccalomi/agriorigin | 32e88abef33b8f03aa5229364edd189956c2d9f6 | [
"Apache-2.0"
] | null | null | null | src/main/java/EggGeth.sql | Rebeccalomi/agriorigin | 32e88abef33b8f03aa5229364edd189956c2d9f6 | [
"Apache-2.0"
] | 1 | 2022-03-28T16:12:04.000Z | 2022-03-28T16:12:04.000Z | INSERT INTO `guns`.`sys_menu` (`id`, `code`, `pcode`, `pcodes`, `name`, `icon`, `url`, `num`, `levels`, `ismenu`, `tips`, `status`, `isopen`) VALUES ('1256956556533129217', 'eggGeth', '0', '[0],', '区块链管理', '', '/eggGeth', '99', '1', '1', NULL, '1', '0');
INSERT INTO `guns`.`sys_menu` (`id`, `code`, `pcode`, `pcodes`, `name`, `icon`, `url`, `num`, `levels`, `ismenu`, `tips`, `status`, `isopen`) VALUES ('1256956556533129218', 'eggGeth_list', 'eggGeth', '[0],[eggGeth],', '区块链管理列表', '', '/eggGeth/list', '99', '2', '0', NULL, '1', '0');
INSERT INTO `guns`.`sys_menu` (`id`, `code`, `pcode`, `pcodes`, `name`, `icon`, `url`, `num`, `levels`, `ismenu`, `tips`, `status`, `isopen`) VALUES ('1256956556533129219', 'eggGeth_add', 'eggGeth', '[0],[eggGeth],', '区块链管理添加', '', '/eggGeth/add', '99', '2', '0', NULL, '1', '0');
INSERT INTO `guns`.`sys_menu` (`id`, `code`, `pcode`, `pcodes`, `name`, `icon`, `url`, `num`, `levels`, `ismenu`, `tips`, `status`, `isopen`) VALUES ('1256956556533129220', 'eggGeth_update', 'eggGeth', '[0],[eggGeth],', '区块链管理更新', '', '/eggGeth/update', '99', '2', '0', NULL, '1', '0');
INSERT INTO `guns`.`sys_menu` (`id`, `code`, `pcode`, `pcodes`, `name`, `icon`, `url`, `num`, `levels`, `ismenu`, `tips`, `status`, `isopen`) VALUES ('1256956556533129221', 'eggGeth_delete', 'eggGeth', '[0],[eggGeth],', '区块链管理删除', '', '/eggGeth/delete', '99', '2', '0', NULL, '1', '0');
INSERT INTO `guns`.`sys_menu` (`id`, `code`, `pcode`, `pcodes`, `name`, `icon`, `url`, `num`, `levels`, `ismenu`, `tips`, `status`, `isopen`) VALUES ('1256956556533129222', 'eggGeth_detail', 'eggGeth', '[0],[eggGeth],', '区块链管理详情', '', '/eggGeth/detail', '99', '2', '0', NULL, '1', '0');
| 240 | 286 | 0.566667 |
ca3f29037b2d1886c94ab40cd7d8c3afc8153ec4 | 95,520 | sql | SQL | db/progressweb_dump.sql | sstopkin/ProgressWEB | 85bd04b1f2b9a6c8e676bcc194e9d742b414e178 | [
"MIT"
] | null | null | null | db/progressweb_dump.sql | sstopkin/ProgressWEB | 85bd04b1f2b9a6c8e676bcc194e9d742b414e178 | [
"MIT"
] | null | null | null | db/progressweb_dump.sql | sstopkin/ProgressWEB | 85bd04b1f2b9a6c8e676bcc194e9d742b414e178 | [
"MIT"
] | null | null | null | -- MySQL dump 10.13 Distrib 5.6.24, for debian-linux-gnu (x86_64)
--
-- Host: localhost Database: progressweb
-- ------------------------------------------------------
-- Server version 5.6.24-0ubuntu2
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;
/*!40103 SET @OLD_TIME_ZONE=@@TIME_ZONE */;
/*!40103 SET TIME_ZONE='+00:00' */;
/*!40014 SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0 */;
/*!40014 SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0 */;
/*!40101 SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='NO_AUTO_VALUE_ON_ZERO' */;
/*!40111 SET @OLD_SQL_NOTES=@@SQL_NOTES, SQL_NOTES=0 */;
--
-- Current Database: `progressweb`
--
CREATE DATABASE /*!32312 IF NOT EXISTS*/ `progressweb` /*!40100 DEFAULT CHARACTER SET utf8 */;
USE `progressweb`;
--
-- Table structure for table `Apartaments`
--
DROP TABLE IF EXISTS `Apartaments`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `Apartaments` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`CityName` varchar(50) NOT NULL,
`StreetName` varchar(50) NOT NULL,
`HouseNumber` varchar(50) DEFAULT NULL,
`BuildingNumber` varchar(50) DEFAULT NULL,
`KladrId` varchar(50) DEFAULT NULL,
`ShortAddress` varchar(100) DEFAULT NULL,
`ApartamentLan` varchar(10) DEFAULT NULL,
`ApartamentLon` varchar(10) DEFAULT NULL,
`TypeOfSales` tinyint(1) NOT NULL DEFAULT '0',
`Rooms` int(11) NOT NULL,
`Price` int(11) NOT NULL,
`CityDistrict` int(11) NOT NULL,
`Floor` int(11) NOT NULL,
`Floors` int(11) NOT NULL,
`RoomNumber` int(11) NOT NULL,
`Material` int(11) NOT NULL,
`SizeApartament` decimal(5,2) NOT NULL,
`SizeLiving` decimal(5,2) NOT NULL,
`SizeKitchen` decimal(5,2) NOT NULL,
`Balcony` int(11) NOT NULL,
`Loggia` int(11) NOT NULL,
`YearOfConstruction` int(11) NOT NULL,
`Description` mediumtext NOT NULL,
`MethodOfPurchase_PureSale` tinyint(1) NOT NULL DEFAULT '0',
`MethodOfPurchase_Mortgage` tinyint(1) NOT NULL DEFAULT '0',
`MethodOfPurchase_Exchange` tinyint(1) NOT NULL DEFAULT '0',
`MethodOfPurchase_Rent` tinyint(1) NOT NULL DEFAULT '0',
`RePlanning` tinyint(1) NOT NULL DEFAULT '0',
`CreationDate` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`LastModify` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00',
`idWorker` int(11) NOT NULL,
`idWorkerTarget` int(11) NOT NULL,
`idCustomer` int(11) NOT NULL,
`IsApproved` tinyint(1) NOT NULL DEFAULT '0',
`Deleted` tinyint(1) NOT NULL DEFAULT '0',
`idFilespace` int(11) NOT NULL DEFAULT '-1',
`dwellingType` tinyint(1) NOT NULL,
`status` tinyint(1) NOT NULL,
`apartamentUUID` varchar(45) NOT NULL,
`filespaceUUID` varchar(45) DEFAULT NULL,
`isAD` tinyint(4) NOT NULL DEFAULT '0',
PRIMARY KEY (`id`),
KEY `idCustomer` (`idCustomer`),
KEY `idCustomerIndex` (`idWorker`),
CONSTRAINT `Apartaments_ibfk_1` FOREIGN KEY (`idWorker`) REFERENCES `Workers` (`id`),
CONSTRAINT `Apartaments_ibfk_2` FOREIGN KEY (`idCustomer`) REFERENCES `Customers` (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=175 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `Apartaments`
--
LOCK TABLES `Apartaments` WRITE;
/*!40000 ALTER TABLE `Apartaments` DISABLE KEYS */;
INSERT INTO `Apartaments` VALUES (1,'Омск','Менделеева','19к2','','2750','644083, г. Омск, пр-кт. Менделеева, д. 19к2','55.046661','73.309705',2,3,2750,4,4,9,23,1,60.00,46.00,7.00,1,0,1995,'Продается 3-х комнатная квартира с отличным современным ремонтом.Окна ПВХ,балкон,лоджия,возможен обмен на 2-х комнатную.Звоните. ',0,0,0,0,0,'2014-02-07 10:32:37','2014-06-17 02:27:15',1,1,1,0,1,-1,1,1,'9e1389a0-cbc9-4eaa-8ede-0f2fa8392e0e','',0),(2,'Омск','Челюскинцев','83Б','','1460','г. Омск, ул. Челюскинцев, д. 83Б','55.008454','73.398063',2,1,1460,5,1,5,1,2,30.00,17.00,6.00,0,0,1970,'Теплая квартира в кирпичном доме. Хорошее состояние – произведен косметический ремонт, окна ПВХ. С/у совместный, ж/дверь, чистый отремонтированный подъезд, тихий зеленый двор с местами для парковки. Природный газ. Неугловая. В прилегающей окрестности имеется вся необходимая для жизни инфраструктура. Свободная. Чистая продажа. Проект и разрешение на пристройку балкона в подарок. Торг. ',0,0,0,0,0,'2014-02-07 10:48:14','2014-06-17 02:27:20',1,1,1,0,1,-1,1,1,'e39bce97-07d2-487c-9d02-b557d82c152e','',0),(3,'Омск','Энтузиастов','31Б','','1920','г. Омск, ул. Энтузиастов, 31Б','55.045315','73.280806',2,2,1920,4,1,5,23,2,42.00,30.00,6.00,0,0,1968,'2 комн. квартира на 1 этаже, 5 этажного кирпичного дома 42/30/6. Комнаты смежные. Квартира не угловая, теплая. Квартира в обычном состоянии, чистая, окна деревянные. Сан узел совместный. Входная дверь металлическая, Домофон, городской. Чистый подъезд, хорошие соседи. Инфраструктура развита, две остановки: ДК \"Звездный\" и \"Школа\" ,магазины, детский сады, школы, поликлиники рядом. Подойдет под ипотеку, Звоните сейчас',0,0,0,0,0,'2014-02-07 10:50:49','2015-04-17 08:48:46',1,8,27,0,0,-1,1,4,'f7a14887-0d46-44c5-9247-4178748dcd37','1e129ce3-43e7-4525-bea8-cdb85062b59a',0),(4,'Омск','Мира','86','','1560','644077, г. Омск, пр-кт. Мира, д. 86','55.029183','73.257809',2,1,1560,4,5,5,47,2,31.00,18.00,6.00,1,0,1970,'Продаю 1-комнатную очень уютную и тёплую квартиру на 5 этаже в 5-ти этажном кирпичном доме в районе Нефтяники. Квартира в хорошем состоянии, не требующая первоначальных вложений в ремонт. Окна ПВХ, сан.узел в кафеле, входная дверь металлическая, двойная, домофон. Есть возможность сделать кухню-студию. Хорошее расположение дома, соседи идеальные. Рядом все необходимые элементы инфраструктуры: торговые комплексы, учебные заведения, детские сады, поликлиника, остановка и многое другое... В доме сделан капитальный ремонт, в подъезде окна ПВХ. Через дорогу находится 1-й и 2-й корпус ОмГУ. Удобный вариант для личного проживания или сдачи в аренду. Звоните сейчас, квартира на чистой продаже. ',0,0,0,0,0,'2014-02-11 04:48:29','2014-06-17 02:27:37',1,1,1,0,1,-1,1,1,'05e9c373-77a8-4036-8956-16561ddb7f8e','',0),(5,'Омск','Менделеева','3','','1620','644083, г. Омск, пр-кт. Менделеева, д. 3','55.047832','73.301162',2,1,1620,4,5,5,100,1,32.00,18.00,6.00,1,0,1969,'продаётся 1-комнатная очень тёплая и уютная квартира, с отличным ремонтом, а именно: окна пвх, межкомнатные двери, сантехника-санфаянс, разводка труб, алюминиевые радиаторы отопления, натяжные потолки, точечное освещение. установлена новая металлическая входная дверь. в подъезде произведён ремонт-окна пвх. ',0,0,0,0,0,'2014-02-11 04:57:07','2014-06-17 02:28:50',1,1,1,0,1,-1,1,1,'7ca24af0-cfe5-4b3c-9924-73ee23ff471e','',0),(6,'Омск','Мира','97','','1470','644089, г. Омск, пр-кт. Мира, д. 96','55.029312','73.250919',2,1,1470,4,5,5,15,2,30.00,17.00,7.00,1,0,1970,'СНИЖЕНА ЦЕНА!!! 1-комнатная квартира. Не угловая. Окна на улицу. Обычный ремонт. Балкон обшит сайдингом, не застеклен.Отличный вариант для личного проживания всех категорий населения или сдачи в аренду. В шаговой доступности магазины, детские сады, школы, поликлиника, остановки общественного транспорта. Недалеко ОмГУ. Район с очень развитой инфраструктурой. Теплая и светлая. Не упустите свой шанс! Звоните! ',0,0,0,0,0,'2014-02-11 04:59:23','2014-06-17 02:28:37',1,1,1,0,1,-1,1,1,'e99f650f-36c7-45c1-b99d-4f11bedeacea','',0),(7,'Омск','Барнаульская 2-я','12','','1760','644105, г. Омск, ул. Барнаульская 2-я, д. 12','55.014742','73.42848',2,1,1760,5,4,5,11,2,34.00,18.00,8.00,1,0,1989,'Комфортная и уютная 1-комн. квартира в хорошем состоянии с удобной планировкой (Омский проект): не угловая, просторная комната, вместительная кухня (7, 6 м2). Произведен ремонт со вкусом, потолок с точечным освещением, межкомнатные двери из массива, окна ПВХ, балкон застеклен, добротная входная дверь. Санузел совмещен, облицован современным кафелем, новая сантехника. Также установлены счетчики на газ и водоснабжение. Квартира полностью готова проживанию. Ухоженный подъезд, соседи идеальные. Год постройки дома 1989. В шаговой доступности все необходимые элементы инфраструктуры: школа детский сад, поликлиника, магазины, сад \"Сибирь\", остановки. Звоните прямо сейчас! ',0,0,0,0,0,'2014-02-11 05:04:10','2014-06-17 02:28:56',1,1,1,0,1,-1,1,1,'bcd4141e-fafc-4ce2-847d-427de489c678','',0),(8,'Омск','Карла Маркса','81','','1800','г. Омск, пр-кт. Карла Маркса, д. 81','54.944818','73.386367',2,1,1800,5,1,5,1,2,31.00,17.00,7.00,0,0,1963,'Уютная, теплая 1к квартира в кирпичном доме расположенном между КДЦ» Галактика и ЖД Вокзалом, в обычном состоянии, есть кладовка, а также индивидуальный тамбур для хранения (в подвальном помещении дома) . Сан узел совместный, новая сантехника в хорошем состоянии. Произведена замена труб, стояков и отопительных радиаторов . Металлическая входная дверь, установлены счетчики на газ и воду. Окна ПВХ выходят во двор. Есть возможность сделать ремонт по своему проекту Чистый подъезд, хорошие соседи. Во дворе детская площадка, есть парковка, остановка всех видов общественного транспорта пл. Серова. ЖД Вокзал. Удобная транспортная развязка. В шаговой доступности Ленинский рынок, много магазинов разного плана, Банки, Сквер, Иртышская набережная. ',0,0,0,0,0,'2014-02-11 05:07:11','2014-06-17 02:29:13',1,1,1,0,1,-1,1,1,'dfc48e70-6525-44e6-b42a-fb1165d61b0e','',0),(9,'Омск','Кирова','22','','1840','644041, г. Омск, ул. Кирова, д. 22','54.941591','73.423692',2,1,1680,3,9,9,106,1,38.00,19.00,9.00,1,0,1989,'1-комнатная квартира , удобная планировка, большая кухня, есть кладовка, балкон. Окна выходят во двор. Санузел совмещен. Квартира не угловая, теплая. Металлическая входная дверь. Установлены счетчики на газ и воду. Есть возможность сделать ремонт по своему проекту! Уютный двор с детской площадкой и местами для парковки. Рядом детские сады, школа. Остановка транспорта рядом., удобная транспортная развязка. В шаговой доступности много торговых комплексов, рынок, аптеки, детские студии и многое другое. Документы готовы. Срочная продажа. Вариант подобран. ',0,0,0,0,0,'2014-02-11 05:10:31','2014-11-10 06:25:31',1,1,1,0,0,-1,1,4,'8437fb20-fa4c-48fe-9835-ca8a0f4764f4','',0),(10,'Омск','Малиновского','16','','1860','644090, г. Омск, ул. Малиновского, д. 14к2','55.038558','73.326395',2,1,1860,4,1,10,1,1,34.00,14.00,9.00,0,0,2010,'ост. Малиновского, ремон, шкаф-купе, ПВХ, л, с/у/с-каф, душ/каб, вх/мет, не угл, д/ф, инт, ч/пр, окна во двор, под коммер,ипот.',0,0,0,0,0,'2014-02-11 05:12:46','2014-06-17 02:37:28',1,1,1,0,1,-1,1,1,'45441a2e-9446-40f4-a436-e285c7d53441','',0),(11,'Омск','Кирова','18к2','','2060','644041, г. Омск, ул. Кирова, д. 18к2','54.942982','73.422084',2,1,2060,3,6,9,58,1,39.00,19.00,9.00,1,0,1988,'Квартира светлая, солнечная в обычном состоянии, не угловая, окна ПВХ, в коридоре встроенный шкаф, большой балкон. По желанию покупателя остается кухонный гарнитур. Чистый подъезд, тамбур на две квартиры. В шаговой доступности школа, детский сад. Дом расположен не вдоль дороги. Тихий, спокойный двор с детской площадкой Рядом остановка транспорта, сеть аптек, рынок, много магазинов. Документы готовы, чистая продажа. Этот объект недвижимости можно приобрести по ипотечному кредиту! ',0,0,0,0,0,'2014-02-11 05:14:29','2014-06-17 02:50:46',1,1,1,0,1,-1,1,1,'8a778361-6aae-4e6c-a73a-3d2b8ff8ba93','',0),(12,'Омск','Сазонова','33','','3450','644122, г. Омск, ул. Сазонова, д. 33','55.00107','73.359642',2,1,3450,5,3,12,1,2,40.00,16.00,12.00,0,0,2010,'Шикарная полнометражная квартира в ЖК \"Ласточкино гнездо\". Квартира полностью готова к проживанию: произведен со вкусом евроремонт, с ипользованием дорогих материалов, натяжные потолки, на полу ламинат/плитка, окна ПВХ. Остается солидная мебель: шкафы-купе в коридоре и комнате, угловой диван, обеденная зона, кухонный гарнитур и бытовая техника: новый холодильник, посудомоечная машина, варочная панель и духовой шкаф, телевизор, стиральная машинка. Санузел облицован современным кафелем Керама Марацци, дорогая сантехника, водонагреватель. Квартира уютная и в ней дышится легко! Приличные соседи. Дом кирпичный, 2010 года постройки. Во дворе детская и спортивная площадка, подземный паркинг. Комфортабельный район. Звоните, покупайте и наслаждайтесь вашей новой квартирой! Торг уместен! ',0,0,0,0,0,'2014-02-11 05:17:44','2014-06-17 02:50:54',1,1,1,0,1,-1,1,1,'209ac5a0-ed1e-4a55-b663-628754959d07','',0),(13,'Омск','5 Линия','227Ак1','','2060','644021, г. Омск, ул. 5 Линия, д. 227ак1','54.961176','73.40604',2,1,2060,3,8,9,48,2,29.00,16.00,7.00,0,1,2012,'Великолепная 1-комнатная квартира- студия, в кирпичном доме 2012 года постройки. Квартира с хорошей энергетикой. По проекту дизайнера выполнен качественный ремонт с использованием дорогих эксклюзивных материалов. Не угловая, окна ПВХ, на полу ламинат/кафель. Заслуживает внимания просторная застекленная лоджия (7 кв.м), которая позволяет оборудовать полноценное место для летнего отдыха, утеплена, обшита панелями МДФ. Санузел совмещен, новая сантехника Sanita Luxe, счетчики. Полностью готова для проживания: кафель в ванной, встроенный кухонный гарнитур, шкафы-купе в коридоре и комнате, встроенная электрическая плита Ariston, вытяжка и встроенный холодильник Electrolux, душевая кабина. Остается солидная мебель, люстры и шторы производства Италия. Привлекательно и расположение дома: во дворе детская площадка, места для парковки, развита инфраструктура. Квартира хорошо подойдет молодым и амбициозным людям, станет отличным мотивирующим подарком студенту, послужит уютным гнездышком для влюбленных. Звоните, покупайте и получайте удовольствие от вашей новой квартиры! Поможем Вам оформить ипотеку со скидкой на процент!',0,0,0,0,0,'2014-02-11 05:20:16','2014-06-17 02:51:03',1,1,1,0,1,-1,1,1,'c88b2150-86a4-4591-b978-dd244b8fe4dc','',0),(14,'Омск','Желиховского','2','','1610','644005, г. Омск, ул. Желиховского, д. 2','54.947134','73.396949',2,2,1610,2,1,2,4,2,35.00,9.00,0.00,0,0,1946,'2-х комнатная квартира в идеальном состоянии. Комнаты большие: 20 кв.м., 15.2 кв.м., кухня 9 кв.м. Не угловая. Очень теплая. Окна ПВХ. Есть свой погреб в квартире. Кухня и сан. узел на 2-х хозяев (бывшее общежитие). Душевая кабина. На кухне своя газ. плита. В секции чисто и тихо. Соседи приличные и порядочные люди, проживают давно. Новым хозяевам в подарок остается хороший шкаф-купе и частично мебель. Дополнительно можно приобрести и капитальный гараж (цену узнавать отдельно). Можно заезжать и жить. Торг уместен. Звоните сейчас и приходите смотреть! ',0,0,0,0,0,'2014-02-11 05:49:23','2014-06-17 02:54:00',1,1,1,0,1,-1,1,1,'2bc3185c-0f6d-43c9-8a0e-7f127772cc6f','',0),(15,'Омск','Энтузиастов','45','','1860','г. Омск, ул. Энтузиастов, 45','55.0453','73.274221',1,2,1860,4,3,5,32,2,47.00,27.00,7.00,1,0,1965,'Продается теплая,светлая квартира в нефтяниках,произведена замена стояков отопления,водопровода,канализации,имеется кладовая.Тихий двор,все в шаговой доступности.Звоните!!! ',0,0,0,0,0,'2014-02-11 05:51:39','2015-04-17 10:03:56',1,12,1,0,0,-1,1,1,'27f6e224-4a61-4c90-9745-6a8752c1a529','017f3ed1-2a07-4041-94ff-0721b3a06e63',0),(16,'Омск','Энергетиков','63','','1780','644065, г. Омск, ул. Энергетиков, д. 63','55.043035','73.278497',1,2,1800,4,3,5,69,1,43.00,28.00,6.00,1,0,1966,'Хорошая 2-комнатная квартира в советском округе! Квартира с частичным косметическим ремонтом, окна выходят во двор на детскую площадку, что избавляет Вас от вечного шума гудящей магистрали. Квартира не угловая и очень теплая. Санузел совмещенный, облицован кафелем советского образца, в квартире установлены новые межкомнатные двери, на потолке потолочная плитка. Район с достаточно развитой инфраструктурой - ост. ДК Звездный в шаговой доступности, супермаркеты, магазины, аптека, Сбербанк - напротив дома, несколько школ и детских садов. Рассмотрим варианты обмена на 1-ком.квартиру в САО + ваша доплата. Чистая продажа, документы готовы. Звоните! ',0,0,0,0,0,'2014-02-11 06:00:47','2014-08-25 03:45:17',1,1,1,0,0,-1,1,4,'81d8e1c5-4305-4422-a871-e2068675ea35','',0),(17,'Омск','10 лет Октября','16','','2060','644009, г. Омск, ул. 10 лет Октября, д. 145','54.986402','73.419263',1,2,2060,5,8,9,103,2,46.00,29.00,6.00,1,0,1978,'Продается 2х комнатная квартира общей площадью 46 кв.м теплая не угловая, состояние обычное, балкон, с/у раздельный. Дом расположен в хорошем районе города во дворе детская площадка. Развитая инфраструктура: в шаговой доступности детский сад, школы, супермаркет, магазины, аптеки. Транспорт по всем направлениям. ',0,0,0,0,0,'2014-02-11 06:18:39','2014-06-17 02:58:35',1,1,1,0,0,-1,1,4,'15acd661-59dc-4753-8608-2295f62bf4fd','',0),(18,'Омск','10 лет Октября','16','','2210','644009, г. Омск, ул. 10 лет Октября, д. 145','54.986402','73.419263',1,2,2210,5,2,9,115,2,45.00,28.00,6.00,0,0,1978,'Продается 2х-комнатная, теплая не угловая квартира в хорошем кирпичном доме, комнаты изолированные, сан узел раздельный, чистый подъезд, в квартире делается чистовая отделка окна ПВХ . Двор зеленый с детской площадкой. Развитая инфраструктура рядом школа, супермаркет, аптеки, остановка в шаговой доступности, сделают вашу жизнь комфортной! Звоните! ',0,0,0,0,0,'2014-02-11 06:20:06','2014-06-17 02:59:02',1,1,1,0,0,-1,1,4,'45bc208b-b0f2-498d-8798-659536f6203b','',0),(19,'Омск','Краснознаменная','26к2','','2260','644013, г. Омск, ул. Краснознаменная, д. 26к2','55.036659','73.45498',1,2,2060,5,1,10,199,1,53.00,33.00,11.00,1,0,2005,'Уютная просторная квартира в нормальном состоянии. Изолированные комнаты на обе стороны дома. Окна ПВХ. Санузел совместный. Просторный коридор. Большая кухня с лоджией, застекленной ПВХ. Балкон (из зала). Счетчики на все. Тамбур на одного хозяина. Аккуратный чистый подъезд. Домофон, интернет. Дом расположен в стороне от магистрали. Уютный тихий двор, есть места под а\\транспорт, рядом вся необходимая инфраструктура , д/с, школа. Транспорт по всем направлениям. Чистая продажа. ',0,0,0,0,0,'2014-02-11 06:22:59','2014-08-25 03:45:40',1,1,1,0,0,-1,1,4,'5cbf0f60-b7d4-4076-81ae-73f83d6eea63','',0),(20,'Омск','Мира','35','','2460','644029, г. Омск, пр-кт. Мира, д. 35','55.028744','73.274518',1,2,2460,4,2,4,24,2,54.00,31.00,8.00,2,0,1990,'Добротная, просторная, полнометражная квартира в теплом кирпичном доме, не угловая, комнаты изолированные, с/у раздельный, большой коридор, два балкона, обычное состояние, аккуратный подъезд, спокойные соседи, телефон, домофон, тихий двор, есть место под а/транспорт. Готова для воплощения Ваших самых смелых дизайнерских фантазий. Квартира дает ощущение тихого защищенного оазиса в динамичном районе с развитой инфраструктурой. Подходит под ипотеку.',0,0,0,0,0,'2014-02-11 06:25:31','2014-08-25 03:46:26',1,1,1,0,0,-1,1,4,'ee680fd1-a080-4e5f-bb03-ee7dd258fadd','',0),(21,'Омск','20 лет РККА','10','','2510','г. Омск, ул. 20 лет РККА, 10','54.976028','73.40922',1,2,2510,5,2,10,7,1,53.00,33.00,8.00,0,1,1990,'Отличное предложение тем, кто хочет жить в центре города, место тихое не магистраль рядом с парком 30 лет ВЛКС, квартира улучшенной планировки, комнаты изолированы. Квартира светлая, теплая, большая лоджия застеклена, в зале шкаф- купе.Состояние квартиры жилое, частично сделан ремонт, поменяны окна.Торг',0,0,0,0,0,'2014-02-11 06:38:05','2015-04-17 08:49:04',1,11,1,0,0,-1,1,4,'ad29c3c7-61fa-4732-aea1-080d6a9ec624','',0),(22,'Омск','Бородина','17','','2600','г. Омск, ул. Бородина, д. 17','55.052221','73.310675',1,2,2600,4,5,5,1,2,52.00,30.00,8.00,0,1,1976,'Эксклюзивный объект в этом районе! Продается 2-комн. квартира с удобной планировкой, изолированные комнаты, окна выходят на обе стороны, имеется гардеробная комната. Квартира не угловая и очень теплая, с ПВХ остеклением. Лоджия также застеклена ПВХ, обшита деревянной вагонкой. Все плюсы и удобства раздельного санузла, в кафеле. Заменена вся канализационная разводка, новая сантехника. Двойная входная дверь. Очень ухоженный подъезд, очень приличные соседи. Вашим детям будет тепло в кирпичном доме! Был произведен капитальный ремонт дома. Большой зеленый двор с детской площадкой. В шаговой доступности 2 школы, детские сады, поликлиника, 2 остановки, торговые комплексы, рынок и многое другое. Звоните прямо сейчас!!',0,0,0,0,0,'2014-02-11 06:44:47','2014-06-17 02:59:50',1,1,1,0,0,-1,1,4,'ca07bfde-8263-4278-903b-5c2229ce6f87','',0),(23,'Омск','Декабристов','130','','2999','644010, г. Омск, ул. Декабристов, д. 130','54.974184','73.3942',1,2,2999,5,2,4,66,2,66.00,43.00,8.00,0,0,1942,'Продаем светлую солнечную квартиру в центре города в отличном районе. Дом очень теплый, а это немаловажно в условиях суровых сибирских зим. Удобная планировка квартиры: изолированные комнаты большой площади, что позволит Вам грамотно спланировать пространство (25,2 и 17,9 кв.м), уютная кухня (7,4 кв.м), санузел совмещенный, установлена душевая кабина, весь санфаянс новый, трубы заменены. Важная деталь - высокие потолки, добавляющие объем пространству. В квартире сделан качественный евроремонт в январе 2013 г.: окна ПВХ, натяжные потолки с точечными светильниками, кафель в санузле, Al радиаторы, добротная входная дверь, новые межкомнатные двери. Привлекательно и расположение дома: центр города, школа, детский сад, СКК им. Блинова, СК Авангард, бульвар Мартынова. Приятно порадуют спокойные доброжелательные соседи. Чистая продажа, квартира свободна, возможна передача ключей на сделке. Запись на просмотр по звонку. Звоните прямо сейчас!!! ',0,0,0,0,0,'2014-02-11 06:46:53','2014-06-17 03:04:09',1,1,1,0,0,-1,1,4,'a0ca580d-ce5a-467d-887b-bfe8f3f96f68','',0),(24,'Омск','Орджоникидзе','162','','2999','644033, г. Омск, ул. Орджоникидзе, д. 162','55.011319','73.365535',1,2,2999,5,2,4,66,2,66.00,43.00,8.00,0,1,2008,'В центре города, продается просторная, уютная, светлая, квартира, окна улица/двор ПВХ,. Дом 2008 г.п. расположен в тихом месте динамичного района. Большая кухня, просторный коридор возможно поставить встроенный шкаф, с/у раздельный, застекленная лоджия (ПВХ). новая сантехника, кафель, счетчики на всё. Закрытый тихий двор с детской площадкой и местом под а/транспорт. Развитая инфраструктура: в шаговой доступности супермаркет, магазины, аптеки. Транспорт по всем направлениям удобно выехать в любую точку города объехать пробки в час пик. Готовая для проживания. Возможна ипотека.',0,0,0,0,0,'2014-02-11 06:50:44','2014-06-17 03:04:59',1,1,1,0,0,-1,1,4,'c0c4fb01-bbe4-4d98-a7a8-e525a003c68f','',0),(25,'Омск','Архитекторов','8','','4060','644112, г. Омск, б-р. Архитекторов, д. 8','54.992394','73.30851',1,2,4060,1,8,8,1,2,67.00,33.00,14.00,0,1,1990,'Наша квартира индивидуальна и предназначена только для Вас. Две просторные комнаты,наполненные светом, дизайнерский ремонт. Шикарная кухня-13.5 кв. м. Изюминкой квартиры является своя сауна (отделка-липа) с гидромассажным душем. В ванной комнате установлена джакузи. Пол-ламинат, с подогревом. Лоджия-застеклена. Окна ПВХ, счетчики на все. Плита-электричество (возможен перевод на газ). Во всей квартире сделана точечная подсветка. Новым хозяевам остается кухонный гарнитур, 2 шкафа-купе, кондиционер в зале. Квартира в идеальном состоянии, никаких дополнительных вложений не требуется. Это лучший вариант для Вашего проживания! Возможна ипотека и мат. капитал. Звоните! Покажем, расскажем, договоримся! Тел.35-67-67 Наталья. ',0,0,0,0,0,'2014-02-11 06:52:48','2014-06-17 08:20:31',1,1,1,0,1,-1,1,1,'b1fb1e5a-993b-44ee-baba-28deac5a63d6','',0),(26,'Омск','Сергея Тюленина','1А','','2200','644100, г. Омск, ул. Сергея Тюленина, д. 1А','55.041369','73.315499',1,3,2200,4,1,5,1,1,60.00,43.00,6.00,0,0,1970,'Комфортная 3-комн. квартира для жизни. Удобная планировка, изолированные комнаты, окна выходят на обе стороны. Состояние квартиры обычное, возможность ремонта на свой вкус. Заменена электропроводка и вся канализационная разводка. Санузел совмещен. Квартира не угловая и очень теплая, двойная входная дверь. Хорошие соседи. Уютный двор с детской площадкой и местами для парковки. В шаговой доступности множество торговых комплексов, фитнес-центры, детские сады, школы, гимназия, удобная транспортная развязка и многое другое. Звоните сейчас, квартира на чистой продаже! ',0,0,0,0,0,'2014-02-11 06:57:25','2014-06-17 03:05:40',1,1,1,0,0,-1,1,4,'32c25e56-ed0b-4e81-af2c-5662f16cddc8','',0),(27,'Омск','Белозерова','11','','2170','644083, г. Омск, ул. Белозерова, д. 11','55.048756','73.305546',1,3,2170,4,3,5,1,1,59.00,42.00,7.00,1,0,1969,'Квартира в обычном состоянии, не угловая с балконом, есть кладовка. Сан узел совместный, сантехника в хорошем состоянии. Металлическая входная дверь, установлен счетчик на газ. Окна выходят на две стороны. Дом расположен не вдоль дороги. Остается кухонный гарнитур. Чистый подъезд, хорошие соседи. Во дворе детская площадка, рядом две школы, три детских сада, остановка общественного транспорта ул.«Белозерова», ост.«Сады». Недалеко от дома «Социальный рынок», Торговый комплекс «Светлый», магазин «О Кей», сети аптек. Срочная продажа. Документы готовы. ',0,0,0,0,0,'2014-02-11 06:59:28','2014-06-17 03:09:58',1,1,1,0,0,-1,1,4,'4761195b-53c2-42c7-a3f4-adf3758aa776','',0),(28,'Омск','Коммунальная','5','','2260','644083, г. Омск, ул. Коммунальная, д. 5','55.053676','73.306183',1,3,2260,4,1,5,42,1,56.00,38.00,6.00,1,0,1970,'Комфортная и уютная 3-комн. квартира для семьи. Квартира не угловая и очень теплая. Окна ПВХ, балкон с погребом, застеклен, решетки. Все плюсы и удобства раздельного санузла, в кафеле, установлены счетчики водоснабжение и газ. Добротные межкомнатные двери, вместительный шкаф-купе, двойная входная дверь. Квартира ухоженная, готова к проживанию. Был произведен капитальный ремонт дома, очень чистый подъезд, хорошие соседи. Зеленый двор с детской площадкой. В шаговой доступности школы, лицей, детские садики, почта, магазины, социальный рынок и многое другое, удобная транспортная развязка. Возможно под коммерческую недвижимость. Подходит под ипотеку. Звоните!',0,0,0,0,0,'2014-02-11 07:04:01','2014-06-17 03:06:44',1,1,1,0,0,-1,1,4,'2faa5e15-c3c3-45cf-b85b-60e01cb306c2','',0),(29,'Омск','Амурская 21-я','18','','2400','644086, г. Омск, ул. Амурская 21-я, д. 18','55.028981','73.415445',1,3,2250,5,2,5,36,1,65.00,47.00,6.00,1,0,1986,'Продается 3-комнатная квартира. В хорошем состоянии, удачное местоположение, рядом школа, библиотека, больница, магазины. Перепланировок нет. Звоните!',0,0,0,0,0,'2014-02-11 08:43:08','2014-08-25 03:47:07',1,1,1,0,0,-1,1,4,'8274ef9b-e795-4f84-b8b7-92eb2fd1a9f7','',0),(30,'Омск','Менделеева','27','','2460','644090, г. Омск, пр-кт. Менделеева, д. 27','55.043659','73.322479',1,3,2460,4,1,9,1,1,60.00,44.00,7.00,0,1,1973,'Продается 3-ком. в отличном состоянии, не угловая, теплая, окна выходят на обе стороны, комнаты смежно-изолированные. Окна ПВХ, просторная лоджия с погребом так же застеклена ПВХ, обшита вагонкой. Санузел раздельный, облицован кафелем, установлена новая сантехника. Большой коридор, встроенная гардеробная. Дом панельный, 1973 года постройки. Спокойный, просторный двор с детскими площадками. Инфраструктура развита, рядом 3 школы и 3 детских сада, хорошая транспортная развязка, рядом \"Первомайский\" рынок. Звоните, возможно под коммерческую недвижимость! Звоните сейчас!! ',0,0,0,0,0,'2014-02-11 08:44:57','2014-06-17 03:07:59',1,1,1,0,0,-1,1,4,'75d943a9-2ead-4f22-9ddf-6bded4a2db87','',0),(31,'Омск','Карбышева','27','','2510','г. Омск, ул. Карбышева, д. 27','54.941405','73.393769',1,3,2510,2,1,5,18,1,59.00,45.00,7.00,0,0,1973,'З-х комнатная квартира по реальной цене. Не угловая. Очень теплая. Комнаты смежно-изолированные. Окна на две стороны-двор и улица (решетки). Произведена замена всех труб и сантехники. Установлены счетчики. В сан.узле новый современный кафель. Два встроенных шкафа-купе (коридор и комната). Двойная входная дверь, вторая-металл. Действительно чистый подъезд и порядочные соседи. Возможна пристройка лоджии с погребом.В 5-ти минутах ходьбы взрослая и детская поликлиники, 2 детских сада, школа и гимназия, сбербанк, магазины, аптеки и остановка общественного транспорта (до центра -10 минут езды). Район с очень развитой инфраструктурой. Звоните и смотрите. ',0,0,0,0,0,'2014-02-11 08:48:23','2014-06-17 03:10:25',1,1,1,0,0,-1,1,4,'2727440c-301e-40a7-aa3e-262bd50584b3','',0),(32,'Омск','Пархоменко','11','','2500','644027, г. Омск, ул. Пархоменко, д. 11','54.973228','73.44562',1,3,2500,3,1,2,1,2,78.00,48.00,9.00,0,0,1955,'Планировочное решение квартиры обеспечивает максимально комфортное проживание.Квартира полностью готова к проживанию! Окна ПВХ, на полу линолеум, не угловая,межкомнатные двери все поменяны, в зале и комнате натяжные потолки, с очень красивой люстрой и точечными светильниками,кухня - мечта хозяйки, большая по площади, продается со встроенным кухонным гарнитуром . Добротная входная дверь. Санузел разделён, установлены счетчики на водоснабжение. Также заменена вся канализационная разводка. Чистый подъезд, хорошие соседи. Имеется подпол. Так же возле окна можно поставить свой автотранспорт. Дом находится в районе, отвечающем всем требованиям современного ритма жизни.Удачная транспортная развязка и отличное транспортное сообщение позволяют добраться практически в любую часть города. Развитая инфраструктура района обеспечит будущих жильцов всем необходимым для комфортного проживания и проведения досуга. В зоне пешеходной доступности детский сад, сеть аптек, супермаркеты, большое количество компаний сфер обслуживания. При покупке квартиры у обладателей автомобиля будет маленький но очень приятный Bonus. Хотите жить в комфорте звоните прямо сейчас! ',0,0,0,0,0,'2014-02-11 08:50:48','2014-06-17 03:10:59',1,1,1,0,0,-1,1,4,'78597608-faf5-48a6-ace9-aa52ab9d311b','',0),(33,'Омск','Менделеева','23','','2560','г. Омск, пр-кт. Менделеева, 23','55.044877','73.318338',1,3,2560,4,9,9,141,1,62.00,43.00,7.00,1,0,1973,'Уютная просторная квартира в отличном состоянии. Комнаты на обе стороны дома. Окна ПВХ, лоджия застеклена и обшита деревянной вагонкой, имеется балкон. Санузел раздельный, новая сантехника, кафельная плитка. Просторный коридор, гардеробная. Встроенная кухня (кафель на стенах), счетчики на все. Дом панельный, состояние очень хорошее. Произведен капремонт кровли, аккуратный подъезд. Телефон, домофон, интернет. Уютный двор с детскими площадками, есть места под а\\транспорт, рядом 3 школы и 3 детских сада, вся необходимая инфраструктура. Транспорт по всем направлениям. Оптимальное предложение по цене-качеству. Чистая продажа. Приглашаем на просмотр! ',0,0,0,0,0,'2014-02-11 08:53:07','2015-04-17 08:49:27',1,12,1,0,0,-1,1,4,'be1a5faf-b271-4449-88e5-2791a11aafc9','',0),(34,'Омск','Бородина','12к5','','2850','г. Омск, ул. Бородина, д. 12, к. 5','55.049472','73.313612',1,3,2850,4,1,5,63,1,70.00,44.00,13.00,2,0,1991,'Расширяем возможности! Замечательная 3-комн. квартира, общей площадью 70кв.м! Удобная планировка- все комнаты изолированные. Большая кухня (12, 5)- отличное место для приема гостей и релакса. Состояние квартиры обычное, возможность ремонта на свой вкус. Заслуживает внимания просторная застекленная лоджия на две комнаты, которая позволяет оборудовать полноценное место для летнего отдыха. На окнах решетки. Санузел раздельный, в кафеле. Ухоженный подъезд, дом панельный, омской серии. В шаговой доступности абсолютно все необходимые элементы инфраструктуры. Звоните!! ',0,0,0,0,0,'2014-02-11 08:55:31','2014-06-17 03:16:43',1,1,1,0,0,-1,1,4,'a318bdad-c46d-49d3-b386-7022a5d8ddd3','',0),(35,'Омск','Транссибирская','4','','3070','644103, г. Омск, ул. Транссибирская, д. 4','54.952847','73.336645',1,3,3070,1,4,5,32,2,70.00,44.00,9.00,1,0,1991,'3-х квартира улучшенной планировки в кирпичном доме, светлая, солнечная в обычном состоянии, не угловая, окна ПВХ выходят во двор и на улицу, встроенные шкафы в коридоре и комнатах. Металлическая входная дверь, домофон. Большой балкон остеклен. Санузел раздельный. Есть городской телефон, интернет проведен. Чистый просторный подъезд, спокойные соседи. Тихий двор есть места для парковки. Школы и детские сады в шаговом доступе. Магазины. аптеки, остановка общественного транспорта рядом. До центра города 10 минут. ',0,0,0,0,0,'2014-02-11 08:58:53','2014-06-17 03:17:12',1,1,1,0,0,-1,1,4,'f68d3df2-d85f-40bf-b3dd-ee47abecae56','',0),(36,'Омск','Белозерова','6','','3200','г. Омск, ул. Белозерова, 6','55.043747','73.30489',1,3,3200,4,5,5,13,1,70.00,43.00,11.00,2,0,1988,'На ЧИСТОЙ ПРОДАЖЕ 3-х комнатная квартира в идеальном состоянии и с качественным ремонтом «под ключ». Продается со всей мебелью (кухонный гарнитур, мягкая мебель, спальный гарнитур, детская стенка, шкаф-купе и пр.)! Все комнаты изолированные, зал-дополнительно утеплен. Пол-ламинат (Германия), обои-Англия, двери в квартире-дерево (Финляндия). Стены и потолки-идеально ровные. Трубы и сантехника-новые. Окна-ПВХ (Германия) с напылением. 2 балкона-полностью отделка ПВХ. На кухне-гарнитур пр-ва Германия, который прослужит Вам долгие годы. Двойная входная дверь «Люкс» с секретом сделана по индивидуальному заказу. Сигнализация, домофон, своя антенна, интернет. В подъезде абсолютные тишина и покой. Дом 1988 года постройки содержится в превосходном состоянии. Не упустите такую возможность! Обязательно звоните и мы Вам все покажем! ',0,0,0,0,0,'2014-02-11 09:01:41','2015-04-22 11:38:09',1,8,1,0,0,-1,1,1,'132c32a5-f45f-4cfa-8bb2-636b2b5c8ea8','',0),(37,'Омск','Лобкова','4','','3000','644020, г. Омск, ул. Лобкова, 4','54.939103','73.382262',1,3,3000,2,3,3,22,2,67.00,42.00,7.00,1,0,1924,'Отличная З-х комнатная квартира с превосходным ремонтом и новой мебелью (спальный гарнитур, кухонный гарнитур, шкаф-купе). Никаких дополнительных вложений не потребуется. Заменена вся система отопления, установлены новые радиаторы. В ванной- современный кафель. На кухне и в прихожей точечная подсветка. Большие окна ПВХ (на две стороны), пол-ламинат. Есть 2 большие кладовые. Комнаты изолированные. Балкон-на магистраль. Двор закрыт и охраняется. Есть хорошая детская площадка. Один собственник. Быстрый подбор. Это Ваша квартира! Звоните! ',0,0,0,0,0,'2014-02-11 09:03:21','2015-04-22 09:51:01',1,8,1,0,0,-1,1,1,'a5b28176-3df4-41ed-948d-1b3e8eb1804e','',0),(38,'Омск','Туполева','2','','3700','644112, г. Омск, ул. Туполева, д. 2','54.994693','73.307396',1,3,3700,1,10,10,1,4,62.00,35.00,14.00,1,0,2010,'Внимание! Снижена цена! Великолепная 3-комн. квартира для взыскательны хозяев в новом доме! Качественно и на совесть выполнен ремонт- бельгийский ламинат \"Quick Step\", немецкие моющиеся обои и натяжные потолки, в кухне кафель. Установлены добротные межкомнатные двери производство Италия, очень надежная входная двери из стали (180кг). Квартира не угловая и очень теплая, окна ПВХ, лоджия ПВХ. Санузел совмещен, облицован современным кафелем, джакузи. Новая сантехника, имеются счетчики на водоснабжение. Каждый уголок квартиры освещен светом добра и любви. Продается в связи с отъездом в другой город. В стоимость уже входит шкафы в прихожей, дорогой элегантный кухонный гарнитур, водонагреватель, варочная панель, духовой шкаф, фильтры очистки воды, мойка из камня и другое. Вам осталось только занести свои личные вещи. В подъезде два выхода- на детскую площадку и на парковку. Вся инфраструктура в 5 минутах ходьбы от Вашего дома. Звоните сейчас, квартира на чистой продаже! Возможен торг. ',0,0,0,0,0,'2014-02-11 09:05:55','2014-06-17 03:18:28',1,1,1,0,0,-1,1,4,'c6e99aa9-8d01-4487-9f5d-cba666eff2ae','0ed53d69-ed73-448f-820a-bf5cbc38cc63',0),(39,'Омск','Ленина','47','','4300','644010, г. Омск, ул. Ленина, д. 47','54.973243','73.379225',1,3,4300,5,4,4,1,1,79.00,57.00,13.00,1,0,1978,'Добротная полнометражная квартира в центре города! Ее особенности: общая площадь 78, 6 кв.м., большая кухня 12, 5 кв.м, высота потолков 3м! Удобная планировка- изолированные просторные комнаты. Квартира светлая, окна ПВХ, выходят на обе стороны, не угловая, теплая. Установлено 2 кондиционера, межкомнатные двери из массива, сейфовая входная двойная дверь. Сан.узел раздельный, облицован кафельной плиткой, заменены стояки отопления. Также оснащена мебелью: кухонный гарнитур, шкафы; при необходимости может остаться вся мебель. Чистый, ухоженный подъезд, доброжелательные соседи. Двор оборудован местами для парковки, есть детская площадка. развитая инфрастуктура, ориентир ; остановка &laquo;Жемчужина&raquo;. Документы готовы, чистая продажа. Звоните, покупайте и вы оцените жизнь в центре! ',0,0,0,0,0,'2014-02-11 09:08:57','2014-06-17 03:19:20',1,1,1,0,0,-1,1,4,'a61e5851-39d7-4e45-a51e-1875bac01402','',0),(40,'Омск','Ленина','50','','4160','644010, г. Омск, ул. Ленина, д. 50','54.970613','73.37901',1,3,4160,5,2,3,4,2,87.00,55.00,14.00,1,0,1936,'Продам квартиру в центре города, полнометражная, комнаты большие, изолированные, окна выходят на обе стороны, закрытый тихий двор. Отсутствует проблема с парковкой. Всегда свободные парковочные места, можно удобно поставить машину рядом с домом. В непосредственной близости парк и иртышская набережная, где можно хорошо отдохнуть после трудового дня. Продаётся срочно в связи с переездом. Звоните! ',0,0,0,0,0,'2014-02-11 09:21:01','2014-06-17 03:18:53',1,1,1,0,0,-1,1,4,'b3b90df2-8b0e-40cc-9402-e6369df76235','',0),(41,'Омск','Транссибирская','4','','4860','644103, г. Омск, ул. Транссибирская, д. 4','54.952847','73.336645',1,3,4860,1,6,6,1,2,129.00,71.00,13.00,0,1,1996,'Просторная комфортная двух ярусная квартира для жизни: 3 комнаты (зал и 2 спальни), кухня, 2 кладовки, просторная лоджия-зимний сад, комната отдыха с великолепным камином, 2-санузла: гостевой, шикарная ванная комната, оснащенная ванной, душевой кабиной, биде, унитазом. Выполнен качественный ремонт в классическом стиле с использованием дорогих материалов. Двойная входная дверь, домофон, телефон, Internet . Инфраструктура развитая. При продаже в квартире частично останется мебель. Это великолепное предложение для людей, которые ценят престиж и качество в жизни. Звоните. ',0,0,0,0,0,'2014-02-11 09:23:06','2014-06-17 03:19:41',1,1,1,0,0,-1,1,4,'756d5a2b-81c9-4fe3-957b-80d735aa0466','',0),(42,'Омск','Степанца','8Б','','3159','644112, г. Омск, ул. Степанца, д. 8Б','54.990695','73.299572',1,4,3159,1,10,10,198,1,74.00,50.00,10.00,0,2,1993,'Хорошие светлые большие просторные комнаты с качественным ремонтом удобны для проживания! Сан. узел раздельный, облицован кафельной плиткой, сантехника новая, установлены счетчики . Хороший вместительный коридор со встроенными шкафами-купе , тамбур в личном пользовании, сделан вместительный шкаф для хранения вещей. Кухня - мечта хозяйки, большая по площади, продается со встроенным кухонным гарнитуром .Дополнительная площадь к жилому пространству в виде 2х лоджий , застеклены. Окна выходят на две стороны - восточная и южная . В квартире постоянно солнечно. Квартира продается со всей мебелью. Замечательные соседи. Комфортабельный район, рядом абсолютно все элементы инфраструктуры, учебные заведения, торговый комплекс «МАЯК» , Левобережный рынок и многое другое. Звоните прямо сейчас, квартира на чистой продаже! ',0,0,0,0,0,'2014-02-11 09:24:59','2014-06-17 03:20:56',1,1,1,0,0,-1,1,4,'2ff4452d-73d4-49bc-b55e-001fa7f72321','',0),(43,'Омск','Туполева','4','','5059','644112, г. Омск, ул. Туполева, д. 4','54.992652','73.304584',1,4,5059,1,5,6,1,2,101.00,70.00,11.00,0,2,1999,'Продается 4-х комнатная квартира, двухуровневая, общей площадью 101 м2 Планировочное решение квартиры обеспечивает максимально комфортное проживание. На первом этаже располагаются: просторная прихожая , кухня-столовая и гостиная объединенные единым пространством, кабинет, который может легко трансформироваться в гостевую или детскую комнату, лоджия, имеющая выход как из гостиной так и из кабинета, сан. узел. На втором этаже расположены две спальни, одна из которых имеет выход на лоджию, большая ванная комната. Дизайн и интерьер квартиры, выполнены преимущественно в классическом стиле с элементами ручной росписи и лепнины, что придает пространству индивидуальный и неповторимый облик и создают атмосферу уюта и красоты. Учитывая этот факт квартира предпочтительно продается со всей мебелью и предметами интерьера. В отделке помещений использованы качественные материалы и сантехническое оборудование европейского производства. Квартира оборудована 3-я встроенными шкафами, обеспечивающими удобную систему хранения, имеется небольшая кладовая смежная с кухней. Во всех жилых помещениях установлены кондиционеры, система принудительной вентиляции в сан. узлах, видео домофон. Дом находится в районе, отвечающем всем требованиям современного ритма жизни.Удачная транспортная развязка и отличное транспортное сообщение позволяют добраться практически в любую часть города. Развитая инфраструктура района обеспечит будущих жильцов всем необходимым для комфортного проживания и проведения досуга. В зоне пешеходной доступности детский сад, сеть аптек, супермаркеты, большое количество компаний сфер обслуживания. Удачное расположение ТСЖ позволяет экономить время на оплату коммунальных услуг. Нравится? Звоните прямо сейчас! ',0,0,0,0,0,'2014-02-11 09:28:28','2014-06-17 03:20:30',1,1,1,0,0,-1,1,4,'fcba9af1-311f-40fb-ab33-c9668c59860c','',0),(44,'Омск','Кордная 5-я','63','','639','644018, г. Омск, ул. Кордная 5-я, д. 63','54.960597','73.470395',2,1,639,3,5,5,38,1,13.70,13.00,0.00,0,0,0,'Продаем гостинку в секции на 5 комнат. Хорошее состояние, окно ПВХ, металлическая современная входная дверь, в секции туалет, душевая комната, кухня. В шаговой доступности конечная остановка городского транспорта, магазины, школа, детский сад, МСЧ №9. Чистая продажа, звоните!',1,0,0,0,0,'2014-02-24 08:16:05','2014-06-17 08:21:19',1,1,1,0,1,-1,2,1,'3b5ec853-d388-4c7e-9e37-16d5cf32931a','',0),(45,'Омск','Магистральная','82А','','910','644089, г. Омск, ул. Магистральная, д. 82А','55.032428','73.25383',1,2,910,4,5,5,30,1,0.00,19.00,0.00,0,0,1973,'Продается 2/3 доли в 2х комнатной квартире. В комнате сделан отличный ремонт, качественная межкомнатная дверь, места общего пользования в стадии ремонта, кухня 7 кв м., кухня и сан.узел на двух хозяев. Из комнаты есть выход на балкон. Окна ПВХ. Соседка женщина, доброжелательная. В зоне пешеходной доступности детский сад, сеть аптек, супермаркеты, большое количество компаний сфер обслуживания.Документы готовы. Торг ',0,0,0,0,0,'2014-02-24 08:24:56','2014-11-10 06:39:45',1,12,1,0,0,-1,4,1,'278e7318-e6c4-4ead-97a2-88a1aab254d7','f880c7e2-0702-4a86-b6ed-265011916f0f',0),(46,'Омск','50 лет Профсоюзов','128','','860','644089, г. Омск, ул. 50 лет Профсоюзов, д. 128','55.032681','73.243939',1,2,860,4,2,5,0,1,0.00,17.00,0.00,0,0,1973,'Продается комната 17 м2 (зал) - 17/28 доли в 2х комнатной квартире не угловая, теплая. Обычное состояние. Кухня 6 м2, кладовая 3 м2 и санузел (раздельный) на двух хозяев. В комнате имеется балкон. В шаговой доступности – вся инфраструктура. ',0,0,0,0,0,'2014-02-24 08:28:07','2014-06-17 10:27:06',1,1,1,0,0,-1,4,4,'cd79d271-af54-4a37-a799-8aab32f11680','e42a4b2a-05a6-4308-aff2-aac83fc989c1',0),(47,'Омск','Куйбышева','113','','2810','644010, г. Омск, ул. Куйбышева, д. 113','54.972344','73.399779',1,2,2810,5,8,9,252,2,73.00,0.00,0.00,0,1,2014,'Новостройка. Срок сдачи: 2-й кв. 2014 г. Застройщик - ООО \"Стройстар Инвест\". Квартира площадью 73, 07 кв. м. по проекту (+9, 36 кв. м площадь лоджий), под отделку в свободной планировке (санузел выделен и оштукатурен, установлена одна межкомнатная перегородка). Наружные стены – самонесущие, из пенополистерольных блоков, с облицовкой из кирпича; окна и балконные двери – из поливинилхлоридных двухкамерных профилей со стеклопакетами; стяжка пола; установка счетчиков; водоснабжение – от существующего высоконапорного водопровода; электроснабжение – от подстанции; отопление – двухтрубная тупиковая система с нижней разводкой магистральных трубопроводов; предусмотрены сети проводного вещания, телефонизации, телевидения, домофонной связи, пожарной сигнализации. 1 этаж и цоколь планируются под магазины и офисные помещения. Чистая продажа. Документы готовы, звоните!!! ',1,0,0,0,0,'2014-02-24 09:17:13','2014-06-17 08:21:52',1,1,1,0,1,-1,1,1,'683e93fe-0122-4f33-b545-96a55cba148d','',0),(48,'Омск','50 лет ВЛКСМ','16','','3070','644076, г. Омск, ул. 50 лет ВЛКСМ, д. 14','54.97469','73.478471',1,4,3070,3,1,5,14,1,74.50,55.20,5.60,0,0,1969,'Чистая, теплая, четырёхкомнатная квартира в панельном доме не угловая, в хорошем состоянии, две комнаты изолированы, Отличный вариант для большой семьи с детьми. Окна выходят во двор и на улицу, два окна ПВХ. Установлен счетчик на газ, входная дверь металлическая, двойная, домофон. В квартире остается качественная мебель. Чистый, ухоженный подъезд. В 2012 году в доме произведен капитальный ремонт. Во дворе детская площадка. Дом расположен в районе с хорошо развитой инфраструктурой, рядом с домом детские сады, школа, гимназия, детская поликлиника. В шаговой доступности остановка общественного транспорта, много магазинов, рынки. Чистая продажа',1,0,0,0,0,'2014-02-26 10:01:10','2014-11-10 06:40:19',1,1,1,0,0,-1,1,4,'3ae7e202-ab6d-4acc-afbb-f7cb0f7d4484','',0),(49,'Омск','Химиков','47','','1369','644088, г. Омск, ул. Химиков, д. 47','55.039306','73.29013',2,1,1369,4,1,5,1,2,29.60,17.50,5.50,0,0,1975,'Продается малосемейка в хорошем состоянии.Не угловая,на окнах решетки,была произведена замена труб и с/техники,чистая продажа .Звоните!\n',1,1,0,0,0,'2014-03-04 03:07:56','2014-05-23 04:05:48',1,1,1,0,1,-1,3,1,'10cd1df6-255f-4d88-b6ce-134dab3c483a','21d61f0c-2154-4b12-a7a9-216d57da822d',0),(50,'Омск','Калинина','10','','','644121, г. Омск, ул. Калинина, д. 10','54.930543','73.376396',-1,3,0,-1,7,9,0,-1,60.00,0.00,0.00,0,0,0,'',0,0,0,0,0,'2014-04-17 08:26:53','2014-06-17 08:19:05',1,1,1,0,1,-1,1,0,'bbb20065-d0df-40a8-9810-b22f41fa576c','',0),(51,'Омск','Калинина','28','','','г. Омск, д. 28','54.989342','73.368212',-1,3,0,2,7,9,0,1,60.00,0.00,0.00,1,1,0,'комнаты раздельные, школа, детский сад, магазины',1,0,0,0,0,'2014-04-21 06:41:17','2014-06-17 08:23:52',1,1,1,0,1,-1,1,0,'60e03cc1-2c78-4e4e-908a-974b57a7f2c7','',0),(52,'Омск','Мира','161','','1520000','644085, г. Омск, пр-кт. Мира, д. 161','55.029879','73.223925',0,1,1520000,4,0,4,5,0,48.00,0.00,0.00,1,0,0,'Окна ПВХ, дверь металлическая, счетчики воды, 2 шкафа купе, телефон Вид на реку',1,0,0,0,0,'2014-04-21 06:54:00','2014-04-22 20:13:20',1,1,1,0,0,-1,1,0,'603ce93f-0614-46fc-b268-c3da920f3628','509a4ded-859c-4d58-98fc-fc6b8e7d32c4',0),(53,'Омск','Мельничная','89к3','','1340000','г. Омск, ул. Мельничная, д. 89/3','54.907719','73.312606',2,1,1340000,1,5,5,0,0,30.00,0.00,0.00,1,0,0,'теплая квартира, кухонный гарнитур, развитая ирфроструктура',1,0,0,0,0,'2014-04-21 07:38:08','2014-04-21 07:38:08',1,1,1,0,0,-1,1,0,'cd83cb9b-9732-470f-a769-63b2b271889f','',0),(54,'Омск','Майорова','38','','2050000','644504, с. Лузино, ул. Майорова, д. 38','54.950164','73.019953',-1,3,2050000,0,3,5,38,2,70.00,0.00,0.00,1,0,2012,'Изолированные комнаты, кухонный гарнитур с немецской бытовой ',1,0,0,0,0,'2014-04-21 07:49:57','2014-04-21 07:49:57',1,1,1,0,0,-1,1,0,'69d85ae7-728e-4cc2-a5d5-6cf8b6e970b5','',0),(56,'Омск','Карла Маркса','63','','3000000','644006, г. Омск, пр-кт. Карла Маркса, д. 63','54.949947','73.388631',0,3,3000000,2,4,5,0,2,56.00,0.00,0.00,1,0,0,'',1,0,0,0,0,'2014-05-07 05:03:46','2014-05-07 05:03:46',1,1,1,0,0,-1,1,0,'a3e7470f-d513-48ae-b422-5afda3487f13','',0),(57,'Омск','Светловская','10','','1600000','644109, г. Омск, ул. Светловская, д. 10','54.910441','73.464404',2,2,1600000,2,5,9,0,1,41.00,0.00,0.00,1,0,0,'',1,0,0,0,0,'2014-05-07 05:12:56','2014-05-07 05:12:56',1,1,1,0,0,-1,1,0,'81043a6c-fbc3-4be3-9091-81227a66c640','',0),(58,'Омск','Орджоникидзе','88','','2600000','644007, г. Омск, ул. Орджоникидзе, д. 88','55.00327','73.365481',1,2,2600000,5,2,5,0,2,43.00,0.00,0.00,1,0,0,'',1,0,0,0,0,'2014-05-07 06:41:23','2014-05-07 06:41:23',1,1,1,0,0,-1,1,0,'2346bd03-9964-4f2e-91d3-012a18a9301a','',0),(60,'Омск','50 лет Октября','11','','1610','644089, г. Омск, ул. 50 лет Октября, д. 11','55.037005','73.24755',0,1,1610,4,5,5,97,2,33.00,18.00,8.00,1,0,1983,'Теплая уютная квартира в кирпичном доме. Хорошее состояние. С/у совместный, балкон застеклен, ж/дверь, чистый подъезд, двор с местами для парковки. Не угловая. В прилегающей окрестности имеется вся необходимая для жизни инфраструктура. Чистая продажа. ',1,0,0,0,0,'2014-06-17 10:32:42','2014-11-10 06:41:02',1,1,1,0,0,-1,1,4,'4c7a5b82-1c8f-4e14-9456-95d94375715f','',0),(63,'Омск','Коммунальная','3','','2000000','644083, г. Омск, ул. Коммунальная, д. 3','55.05348','73.30551',1,3,2000000,4,2,5,46,1,58.00,33.00,6.00,1,0,1976,'',1,0,0,0,0,'2014-07-01 04:03:19','2014-07-01 04:05:59',1,12,1,0,1,-1,1,0,'4b0a30ce-e40a-4bd9-984c-593afdb67260','',0),(64,'Омск','Военная 1-я','17','','1900000','г. Омск, д. 17','54.989342','73.368212',2,2,1900000,5,5,5,17,2,51.00,38.00,9.00,1,0,0,' Собственник:89136275191',1,0,0,0,0,'2014-07-01 04:06:05','2014-07-01 04:20:11',1,9,1,0,0,-1,1,0,'dfadb518-ce75-4dd7-bc89-989f31297a61','',0),(65,'Омск','20 лет РККА','10','','2560','644001, г. Омск, ул. 20 лет РККА, д. 10','54.976023','73.40922',0,2,2510,3,2,10,10,1,52.90,33.70,7.70,1,1,1990,'собственник: Елена Викторовна 8-913-964-3100',0,0,1,0,0,'2014-07-01 04:06:12','2014-11-10 06:44:29',1,11,1,0,0,-1,1,4,'66314564-337e-4bbb-bc32-59cbd26ed79f','',0),(66,'Омск','Космический','16','','2600000','644027, г. Омск, пр-кт. Космический, д. 16','54.969274','73.448369',2,2,2600000,3,4,10,0,0,56.00,33.00,9.00,0,1,0,'л/заст, о-ПВХ, 89083171982 Наталья Ивановна',0,0,0,0,0,'2014-07-01 04:10:57','2014-07-01 04:10:57',1,1,1,0,0,-1,1,0,'db8e926b-34ec-46ff-adb3-d08597deb060','',0),(67,'Омск','25 лет Октября','11','','5500000','644121, г. Омск, ул. 25 лет Октября, д. 11','54.939755','73.37238',2,3,5500000,2,0,12,0,2,100.00,68.00,15.00,0,2,2012,'звонок с прозвона 8913-970-17-77 думает.цена будет несколько больше',1,0,0,0,0,'2014-07-01 04:47:36','2014-07-01 04:47:36',1,9,1,0,0,-1,1,0,'64a9ad54-dde5-44b5-8a7a-62731212c4da','',0),(68,'Омск','20 Партсъезда','20','','3500','644029, г. Омск, ул. 20 Партсъезда, д. 20','55.033594','73.280114',0,1,3500,0,2,3,4,2,13.00,0.00,0.00,0,0,0,'Сдается в аренду комната 13м2 для женщины, слав. 3500р/мес. тел 22-21-96, 8 950 330 40 11 Наталья',0,0,0,1,0,'2014-07-01 10:49:50','2014-07-01 10:49:50',1,5,1,0,0,-1,4,0,'1a6b7405-a5d7-4afb-a1e0-8bfee59e20eb','',0),(71,'Омск','Карла Маркса','45','','3850000','644006, г. Омск, пр-кт. Карла Маркса, д. 45','54.953933','73.388164',2,3,3850000,2,4,0,5,2,83.00,0.00,0.00,1,0,0,'Сталенский дом',1,0,0,0,0,'2014-07-04 07:41:25','2014-07-04 07:41:25',1,9,1,0,0,-1,1,0,'52b36a8b-616c-4966-995d-128f6575fdb1','',0),(72,'Омск','Герцена','40','','2870000','644007, г. Омск, ул. Герцена, д. 40','54.997833','73.373674',2,2,2870000,5,4,5,0,2,60.00,42.00,9.00,0,0,1958,'Сталинский дом, высокие потолки, кап.ремонт 2013',1,1,0,0,0,'2014-07-08 04:11:34','2014-08-25 03:52:55',1,1,1,0,0,-1,1,4,'2154349a-6203-41af-b46d-f4196dead9b3','',0),(73,'Омск','Калинина','','','0','644121, г. Омск, ул. Калинина','54.92912','73.370619',2,2,0,2,0,5,5,1,44.00,0.00,0.00,1,0,0,'звонок по объявлению, работаю дальше',1,0,0,0,0,'2014-07-08 04:15:28','2014-07-08 04:15:28',1,9,1,0,0,-1,1,0,'69f9c8c8-ff81-4517-b62e-b25fc1fa99a5','',0),(75,'Омск','Комкова','1Б','','2300000','644073, г. Омск, ул. Комкова, д. 1б','54.996826','73.235863',0,2,2300000,1,3,5,0,1,48.00,0.00,0.00,1,0,0,'опрятная, косм. ремонт, планировка \"Бабочка\", ПВХ, с/у разд.,замена труб, счетчики.\nнужен кирпичный дом до 2500000 в КАО.',0,0,1,0,0,'2014-07-09 02:49:30','2014-07-09 02:49:30',1,8,1,0,0,-1,1,0,'ee080f6f-fb0d-4974-aaf2-d6da9b18aeaf','',0),(81,'Омск','Конева','28к2','','0','644074, г. Омск, ул. Конева, д. 28, к. 2','54.978049','73.310477',2,1,0,1,3,12,0,1,39.00,0.00,0.00,1,0,0,'',1,0,0,0,0,'2014-08-15 08:27:11','2014-08-15 08:27:11',1,9,1,0,0,-1,1,5,'a3b362a8-95fd-4596-9a35-21920298bb29','',0),(82,'Омск','Рокоссовского','30','','3000000','644073, г. Омск, ул. Рокоссовского, д. 30','55.000699','73.236564',0,3,3000000,1,6,9,93,1,63.00,39.00,11.00,1,0,1988,'хор. сост, комнаты изолир., с\\узел. разд. в хор. кафеле. В ипотеке на 2 000 000 руб. нужна 2-комн. на лев. берегу или в Дружино. Договор с др. агенством. просят 3 000 000 руб. (Цена существенно завышена) тел. 89088090251 Людмила.',0,0,1,0,0,'2014-08-18 06:10:31','2014-08-18 06:10:31',1,1,1,0,0,-1,1,0,'ae7f3662-168b-42b5-9384-b22d87c4399a','',0),(84,'Омск','Труда','61к1','','9800000','644121, г. Омск, ул. Труда, д. 61, к. 1','54.931738','73.363568',2,4,9800000,2,2,7,0,2,154.00,0.00,0.00,0,2,0,'Хорошая просторная 2 сан.узла,гардеробная, индивидуальная порковка',1,0,0,0,0,'2014-08-18 08:39:49','2014-08-19 02:41:26',1,9,1,0,1,-1,1,0,'63c604b0-01d1-4343-833d-70066f6afd09','',0),(85,'Омск','Труда','11к1','','3250000','644121, г. Омск, ул. Труда, д. 11, к. 1','54.933605','73.377015',1,3,3250000,2,4,9,0,1,60.00,42.00,0.00,1,1,0,'',1,0,0,0,0,'2014-08-18 08:43:28','2014-08-18 08:43:28',1,9,1,0,0,-1,1,0,'b1f151f7-a973-4c0c-a4ed-273234edfa4b','',0),(86,'Омск','Орджоникидзе','270','','1950000','644034, г. Омск, ул. Орджоникидзе, д. 270','55.026277','73.365643',1,1,1950000,2,4,5,0,2,32.00,0.00,0.00,1,0,0,'агенство Мария',1,0,0,0,0,'2014-08-18 08:50:39','2014-08-19 02:40:43',1,9,1,0,1,-1,1,0,'d0ab9c5b-e2d7-4b6d-8a93-ecccc30f9fed','',0),(89,'Омск','Культуры','4А','','600','644029, г. Омск, пр-кт. Культуры, д. 4А, к. а','55.027583','73.279449',2,1,600,4,3,5,0,2,12.00,12.00,0.00,0,0,0,'Молодая супружеская пара.При разговоре были почти согласны на сотрудничество ,потом передумали объясняя ,что нет необходимости.89507937688 Артем.Агент Екатерина Олеговна',1,0,0,0,0,'2014-08-20 04:33:24','2014-08-20 04:51:05',1,1,1,0,0,-1,2,0,'05f66e40-277e-4faf-bf96-1047504796bf','',0),(90,'Омск','19 Партсъезда','24Бк6','','1900000','644065, г. Омск, ул. 19 Партсъезда, д. 24Б, к. б','55.037944','73.275829',2,2,1900000,4,3,3,0,2,55.00,0.00,0.00,1,0,0,'Хозяин с Москвы,при разговоре отказался от услуг с критикой на агенство с кем ранее сотрудничал.89268548809 Сергей.Агент Екатерина Олеговна',1,0,0,0,0,'2014-08-20 04:49:42','2014-08-20 04:49:42',1,1,1,0,0,-1,1,0,'131c6b4c-d8ed-445c-8139-954f06203f67','',0),(91,'Омск','50 лет Профсоюзов','85','','600','644053, г. Омск, ул. 50 лет Профсоюзов, д. 85','55.036515','73.267744',2,1,600,4,5,5,0,2,13.20,13.20,0.00,0,0,0,'Продает пассивно ,без торга .Снял везде с продажи.Продаст если к нему приведут клиента.89836211207 Алексей .Агент Екатерина Олеговна',1,0,0,0,0,'2014-08-20 05:04:47','2014-08-20 05:04:47',1,1,1,0,0,-1,2,0,'0179cc9b-ed0d-4ba5-8282-a15080aa6bbb','',0),(92,'Омск','Омская','112','','2600000','644070, г. Омск, ул. Омская, д. 112, к. 0','54.989693','73.404396',2,2,2600000,5,5,5,0,1,52.00,33.00,8.00,1,0,0,'окна и двери деревянные',1,0,0,0,0,'2014-08-20 07:41:40','2014-08-20 07:41:40',1,9,1,0,0,-1,1,0,'3b8f82cd-b068-44da-ad01-bf0627aa37e4','',0),(93,'Омск','Сулеймана Стальского','9','','2500000','644121, г. Омск, ул. Сулеймана Стальского, д. 9, к. 0','54.935881','73.374509',2,2,2500000,2,7,9,0,0,48.00,0.00,0.00,1,0,0,'окна Пвх',0,0,1,0,0,'2014-08-20 07:45:38','2014-08-20 07:47:23',1,9,1,0,0,-1,1,0,'2b8afde7-ea83-4c5f-917f-8662052191cb','',0),(96,'Омск','Мира','9к2','','1820000','644050, г. Омск, пр-кт. Мира, д. 9, к. 2','55.023651','73.295862',2,2,1820000,4,3,8,0,4,35.00,0.00,0.00,0,0,2005,'Квартира однокомнатная переделана в двухкомнатную.продажа с целью приобретения полноценной двушки.Хозяйка адекватная 89514040088 Кристина.Стоит в ин-нете еще в двух агенствах',0,0,1,0,0,'2014-08-20 08:40:59','2014-08-20 08:40:59',1,12,1,0,0,-1,1,0,'ff5bc0ff-bb63-494b-a443-1d5998745e11','',0),(97,'Омск','50 лет Профсоюзов','119','','3500','644089, г. Омск, ул. 50 лет Профсоюзов, д. 119','55.031696','73.244029',2,4,3500,4,6,0,9,2,75.00,0.00,0.00,0,1,0,'с продажи хотят приобрести двухкомнатную и однокомнатную.89609850700 Татьяна.Агент Екатерина Олеговна ',0,0,1,0,0,'2014-08-20 09:17:37','2014-08-20 09:17:37',1,1,1,0,0,-1,1,0,'b3b1a1a0-6d41-44fd-b146-232cf5b0cc5e','',0),(98,'Омск','Иртышская Набережная','48','','2550000','г. Омск, ул. Иртышская Набережная, д. 48','54.943225','73.373341',1,2,2550000,2,2,5,0,2,44.00,30.00,6.00,1,0,0,'окна ПВХ. сантехника поменена',0,0,0,0,0,'2014-08-20 09:31:06','2014-08-20 09:31:06',1,9,1,0,0,-1,1,0,'398e43c9-0229-46e5-b732-1b9090de3ace','',0),(99,'Омск','Герцена','40','','2870000','644007, г. Омск, ул. Герцена, д. 40','54.997833','73.373674',2,2,2870000,5,4,5,0,2,60.00,40.00,9.00,0,0,0,'кап.ремонт в 2013',1,0,0,0,0,'2014-08-20 09:38:12','2014-08-20 09:38:12',1,9,1,0,0,-1,1,0,'e41865bd-ee49-4d33-ab50-a5d23e3ae54e','',0),(100,'Омск','50 лет Профсоюзов','97сек1','','750','644053, г. Омск, ул. 50 лет Профсоюзов, д. 97, к. сек1','55.039816','73.290238',0,1,750,4,1,5,2,2,11.60,11.60,0.00,0,0,0,'ост. Сквер молодоженов, х/с, мет/ дв, с/у/р',0,0,0,0,0,'2014-08-25 03:57:36','2014-11-10 06:45:20',1,12,1,0,0,-1,2,4,'cccbf564-cadf-4ba6-8abb-2f0c5a043813','',0),(101,'Омск','Малунцева','25','','1760','644029, г. Омск, ул. Малунцева, д. 25','55.030117','73.271436',0,1,1760,4,1,4,57,2,37.00,19.00,7.00,0,0,0,'ост. Малунцева, х/с, б/б, с/у/р, не угл, двор огорожен, ипотека, ч/пр',1,0,0,0,0,'2014-08-25 04:01:06','2014-11-10 06:46:22',1,12,1,0,0,-1,1,1,'ac2e0c89-35f6-492d-ad79-bbad7a8cb831','',0),(102,'Омск','Дианова','33','','1750','644073, г. Омск, ул. Дианова, д. 33','54.994527','73.232899',0,1,1750,1,6,9,0,2,40.00,16.00,11.00,0,0,0,'ост. Комкова, н/с, с/у/совм., не угл.,б/б, больш. тамбур на эту квартиру, возможен обмен на 2-к квартиру в САО, рассмотрим все варианты',0,0,0,0,0,'2014-08-25 04:03:43','2014-11-10 06:46:54',1,8,1,0,0,-1,1,4,'9bc039df-f090-4d9a-9129-3570121db490','',0),(103,'Омск','6 Линия','97','','2310','644001, г. Омск, ул. 6 Линия, д. 97','54.973543','73.405609',1,1,2310,3,6,6,159,4,40.00,0.00,10.00,0,1,2013,'под отд, ПВХ, Al рад, м/комн. перегородка, л/з, с/у/р',0,0,0,0,0,'2014-08-25 04:07:05','2014-11-10 06:47:10',1,5,1,0,0,-1,1,4,'db4a6768-7115-47a4-a5b2-b5daaf9023dd','',0),(104,'Омск','Мира','27к1','','1870','644029, г. Омск, пр-кт. Мира, д. 27','55.028827','73.279899',0,1,1870,4,4,5,56,2,31.10,16.50,5.60,1,0,0,'ПВХ, о/с, с/у/с, б/з, нов стояки водопровода и отопления, Ал радиаторы, сч/в/г, нов сантехника, кафель, подвесной потолок, шкаф-купе, встр кухня с вытяжкой. Всё рядом. Возможна ипотека.',0,1,0,0,0,'2014-08-25 04:18:28','2014-11-10 06:47:39',1,12,1,0,0,-1,1,4,'1f1f13da-ea58-474c-ab64-56a730fc6625','',0),(105,'Омск','Мира','16','','1870','644080, г. Омск, пр-кт. Мира, д. 16','55.024229','73.299509',0,2,1870,4,5,5,0,2,42.00,24.00,6.00,0,0,1962,'из,с/у/с,б/б,косм.ремонт,ч/пр,ПВХ,вх/м,д/ф,инт',0,0,0,0,0,'2014-08-25 04:26:31','2014-11-10 06:48:10',1,8,1,0,0,-1,1,4,'31940579-014d-4f55-9e5f-cb7e3dadbb25','',0),(106,'Омск','22 Апреля','40','','2300','644053, г. Омск, ул. 22 Апреля, д. 40','55.037582','73.26036',1,2,2300,4,8,9,39,2,47.00,30.00,8.00,1,0,1979,'ост. пл. Лицкевича, о/с, ПВХ, б/з/ПВХ, из, сч, встр.меб, с/у/с-каф, торг',1,0,0,0,0,'2014-08-25 04:29:46','2014-11-10 06:49:03',1,4,1,0,0,-1,1,4,'c0a69db0-5114-4fed-b9ad-c8235735ad4f','',0),(107,'Омск','20 лет РККА','10','','2670','644001, г. Омск, ул. 20 лет РККА, д. 10','54.976023','73.40922',0,2,2670,5,1,10,2,1,47.30,27.00,7.60,1,1,1989,'о/с, л/б/з/утеп, погреб, ПВХ, Al рад, сч/в/г, нов. с/тех, ипот, угл, с/у/р',0,1,0,0,0,'2014-08-25 04:32:45','2014-11-10 06:49:38',1,11,1,0,0,-1,1,4,'fae0239e-a791-4f85-9c08-d395fe3a9fc5','',0),(108,'Омск','Совхозная 2-я','29','','1850','г. Омск, ул. Совхозная 2-я, 29','55.029363','73.379773',0,2,1850,5,3,3,7,2,45.00,25.30,6.00,1,0,0,'б, с/у/с, н/с, ип, смеж/из/к, + большая кладовая как 3-я комната',0,0,0,0,0,'2014-08-25 04:38:20','2015-04-17 08:49:47',1,12,1,0,0,-1,1,4,'af91154a-5008-460c-85bc-4c6a84d0089d','',0),(109,'Омск','Культуры','2','','2235','644029, г. Омск, пр-кт. Культуры, д. 2','55.026788','73.278398',0,2,2235,4,2,5,0,2,43.00,0.00,0.00,0,0,0,'43/-/- 2/5 кирпичный, б/б, с/у/с, отличное состояние, студия, окна ПВХ, замена сантехники, встроенная мебель, подвесные потолки чистая продажа, ипотека',1,1,0,0,0,'2014-08-25 04:42:24','2014-11-10 06:51:21',1,12,1,0,0,-1,1,4,'78de3eb8-9680-49aa-99f0-5aaadd6b2300','',0),(110,'Омск','Мира','167','','1570','644085, г. Омск, пр-кт. Мира, д. 167','55.032547','73.221993',0,2,1570,4,3,5,64,2,34.00,0.00,0.00,0,0,0,'без балкона, с/у/с, н/с, малосемейного типа, окна ПВХ, мет/ дверь, двойная. Подходит под ипотеку',0,1,0,0,0,'2014-08-25 04:45:10','2014-11-10 06:53:58',1,3,1,0,0,-1,1,4,'9d095e4a-19d8-4494-ac17-a2a2e5e6e6ff','',0),(111,'Омск','П.Г.Косенкова','30','','920','обл. Омская, р-н. Омский, г. Омск, П.Г.Косенкова, 30','55.171905','73.217286',0,2,920,4,3,4,0,2,25.00,0.00,0.00,0,0,0,'Продается 2-х комнатная уютная квартира в отличном состоянии. Окна ПВХ. Ремонт сделан 1 год назад. Хорошие соседи. Рядом расположены: детский сад, школа, мини-рынок, конечная остановка автобусов и маршрутных такси. Дом культуры. Транспорт до города каждые 10 минут. Возможен обмен, рассмотрим варианты в п. Береговом и п. Ключи. Торг.',0,0,1,0,0,'2014-08-25 05:12:53','2015-05-08 09:19:53',1,17,1,0,0,-1,1,1,'372146cc-1856-4fb3-b640-a847f089614e','',0),(112,'Омск','Авиагородок','3','','3300','644103, г. Омск, ул. Авиагородок, д. 3','54.950454','73.321922',0,3,3300,1,1,4,10,2,80.00,0.00,0.00,0,0,1967,'ост. ОЛТУГА, с/у/р, из, х/рем, натяжные потолки',0,0,0,0,0,'2014-08-25 05:18:36','2014-08-25 05:18:36',1,3,1,0,0,-1,1,1,'85c8daa2-3386-47ad-9473-97119a6f265e','',0),(113,'Омск','Малунцева','3','','3460','644029, г. Омск, ул. Малунцева, д. 3','55.030519','73.283609',0,3,3460,4,2,4,23,2,73.00,48.00,8.00,0,0,0,'отл/с, без б, с/у/совм, ПВХ, ч/пр, д/г, ипотека',1,1,0,0,0,'2014-08-25 05:21:51','2014-11-10 06:57:01',1,12,1,0,0,-1,1,4,'8dfc0ea7-d884-461e-8c91-bfff3982cceb','',0),(114,'Омск','22 Апреля','30','','1800','г. Омск, ул. 22 Апреля, 30','55.041436','73.274823',0,3,1800,4,4,5,14,2,41.00,30.00,6.00,1,0,1967,'х/с, балкон, д/фон, с/у/с, мет/дер дверь, см-изол, выс. 2,5, вх. Дверь (металл, дерево), окна дерево. Торг',0,0,0,0,0,'2014-08-25 05:37:59','2015-04-17 08:50:40',1,12,1,0,0,-1,1,4,'3bca97b7-9fb6-4c97-9bc6-7e44ce2e53e2','',0),(115,'Омск','Степанца','12к2','','0','644119, г. Омск, ул. Степанца, д. 12, к. 2','54.999506','73.285441',0,1,0,1,3,9,125,1,30.00,17.00,5.00,0,0,1984,'Хор. сост. Окна-ПВХ.В ипотеке 750 тыс. руб. Просят 1500000 руб. В нескольких агенствах. 89136873015 Людмила Викторовна.',0,0,1,0,0,'2014-09-05 03:33:13','2014-09-05 03:33:13',1,8,1,0,0,-1,3,0,'20bdef53-bd01-4d23-a7b4-77d3c5f70626','',0),(116,'Омск','Мира','167','','0','644085, г. Омск, пр-кт. Мира, д. 167','55.032547','73.221993',0,1,0,4,2,5,0,0,30.00,17.00,5.00,0,0,0,'требует ремонта. обмен на 2-3 комн. возм. работают с др. агенством. 89514046667 Ольга Борисовна.',0,0,1,0,0,'2014-09-05 03:40:48','2014-11-10 06:58:52',1,8,1,0,0,-1,1,4,'52ea4cc6-1e98-41e8-b2e8-38c649b1a701','',0),(117,'Омск','Башенный','2','','1530000','644012, г. Омск, пер. Башенный, д. 2','55.034941','73.33077',0,1,1530000,4,7,9,0,1,30.00,17.00,6.00,0,0,0,'норм. сост. окна -ПВХ.в работе у трех агенств. цена явно завышена. 89136060572 наталья.',0,0,1,0,0,'2014-09-05 03:44:32','2014-11-10 06:59:17',1,8,1,0,0,-1,3,4,'ffa60a8f-1fac-4634-9d3a-242d25af4db6','',0),(118,'Омск','Вострецова','5','','800000','644113, г. Омск, ул. Вострецова, д. 5','54.916289','73.450462',0,1,800000,2,4,5,0,2,0.00,18.00,0.00,0,0,0,'Комната в отл. сост. вода., эл. плита, стир. машинка в комнате. Хор. мет дверь. Окно-ПВХ.Остается кухонный гарнитур, эл. плита. Чистая секция. Душ и с/узел в хор. сост. на 3 собств. Обмен на 1-2 комн. с допл. мат. кап.. 89230380178 Наталья',0,0,1,0,0,'2014-09-05 03:50:18','2014-11-10 06:59:43',1,8,1,0,0,-1,2,4,'46b2112b-efff-444c-8043-9c2fba1dbd69','',0),(119,'Омск','Мира','173','','1900000','644085, г. Омск, пр-кт. Мира, д. 173','55.034224','73.217888',0,2,1900000,4,2,5,0,1,45.00,30.00,6.00,1,0,0,'хор. сост. с/уз. совм.,окна-ПВХ, балк. заст. т.266396',0,0,1,0,0,'2014-09-05 03:53:56','2014-11-10 07:00:22',1,8,1,0,0,-1,1,4,'9d70dc7d-a7dc-45ea-a874-ea55ecacbc79','',0),(120,'омск','Бородина','10/1','','1370','р-н. Первомайский, омск, Бородина','56.850068','53.20319',0,1,1370,4,8,9,0,1,30.00,17.00,6.00,0,0,1984,'ПВХ, под ремонт, кафель',0,0,0,0,0,'2014-11-10 07:05:30','2014-12-15 09:07:05',1,8,1,0,0,-1,2,4,'8e934445-edf0-4c92-b380-7df073bcb1a1','',0),(121,'Омск','Пр. Мира','32 Б','','820','г. Омск, Пр. Мира, 32 Б','55.027924','73.293508',0,1,820,4,3,5,66,2,17.00,0.00,0.00,0,0,0,'ПВХ, косм/рем, мет/дверь',0,0,0,0,0,'2014-11-10 07:08:05','2015-04-17 08:50:54',1,0,1,0,0,-1,2,4,'57c47196-d467-473d-bfd3-51d6e866787e','',0),(122,'Омск','5-я Марьяновская','4/2','','0','обл. Омская, р-н. Ленинский, Омск, 5-я Марьяновская, 4/2','54.917288','73.362256',0,1,565,2,1,4,0,2,12.00,0.00,0.00,0,0,0,'Новостройка. ПВХ, мет/дверь, ремонт, сдан 2014 г.',0,0,0,0,0,'2014-11-10 07:12:00','2014-11-10 07:15:37',1,1,1,0,0,-1,2,1,'f50ee791-adf2-4bea-8f7e-4ad66861d435','',0),(123,'Омск','Дмитриева','6/1','','1880','обл. Омская, г. Омск, ул. Дмитриева','54.983329','73.310765',0,1,1880,4,1,9,0,1,37.00,19.00,9.00,1,0,1987,'х/с, балкон, мет/дверь, с/у/с, не угловая',0,0,0,0,0,'2014-11-10 07:14:57','2014-12-15 09:09:16',1,8,1,0,0,-1,1,4,'36a1ac0f-0522-4840-8e1d-67f8a3e8374d','',0),(124,'Омск','Тварковского','5','','1600','644077, обл. Омская, г. Омск, ул. Тварковского, д. 5','55.022133','73.296733',0,1,1600,4,5,5,0,2,31.00,18.00,6.00,1,0,0,'угловая, с/у/с, счетчики, б/рем, ч/продажа',1,0,0,0,0,'2014-11-10 07:20:38','2014-11-10 07:20:38',1,8,1,0,0,-1,1,1,'0d5a626e-723a-4b57-bdeb-db7a3e87c5e7','',0),(125,'Омск','Комарова','19','','2370','644074, обл. Омская, г. Омск, пр-кт. Комарова, д. 19','54.984465','73.304746',0,1,2370,1,7,7,0,2,40.00,16.00,10.00,0,0,0,'о/с, ПВХ, студия, дизайн/ремонт',0,0,0,0,0,'2014-11-10 07:23:37','2014-12-15 09:07:40',1,11,1,0,0,-1,1,4,'678f28a3-ee6c-4009-8ec8-342b909b13b6','',0),(126,'Омск','Культуры','1','','1650','644029, обл. Омская, г. Омск, пр-кт. Культуры, д. 1','55.026788','73.277482',0,1,1650,4,4,5,0,2,31.00,18.00,6.00,0,0,0,'не угловая, окна во двор, дверь/мет, с/у/с, косм/рем',0,0,0,0,0,'2014-11-10 07:26:20','2014-12-15 09:08:18',1,0,1,0,0,-1,1,4,'9849f414-b1d8-43dc-9080-7c6a16229ca1','',0),(127,'Омск','Ленинская 9-я','1','','2880','644121, г. Омск, ул. Ленинская 9-я, 1','54.938436','73.373135',0,2,2880,2,4,5,71,1,44.00,30.00,6.50,0,0,0,'изол/комн, с/у/с, потолки натяжные, ламинат, ПВХ, требуется ремонт, дверь металл',0,0,0,0,0,'2014-11-10 10:53:06','2015-04-17 08:51:17',1,11,1,0,0,-1,1,4,'dfad9507-2dfe-4bae-a50c-f7c29e4af1aa','',0),(128,'Омск','Маршала Жукова','107','','5570','г. Омск, ул. Маршала Жукова, 107','54.968339','73.391424',0,2,5570,5,7,12,47,2,79.00,60.00,12.00,0,2,0,'п/отд, ПВХ, с/у/р, 2л, подземная парковка, сч',0,0,0,0,0,'2014-11-10 11:03:00','2015-04-17 10:08:51',1,8,1,0,0,-1,1,1,'7e7bd2f4-beb6-4f79-9d64-490d0fc29afb','',0),(129,'Омск','Мира','61А','','1870','г. Омск, пр-кт. Мира, 61А','55.027536','73.257854',0,2,1870,4,1,5,0,2,45.00,0.00,0.00,0,0,0,'состояние нормальное, не угловая, металлическая дверь',0,0,0,0,0,'2014-11-10 11:05:43','2015-04-17 08:51:37',1,0,1,0,0,-1,1,4,'3531b890-722c-4d2a-a443-915d91e59cf1','',0),(130,'Омск','22 Апреля','30','','1800','г. Омск, ул. 22 Апреля, 30','55.041436','73.274823',0,3,1800,4,4,5,14,2,41.00,30.00,6.00,1,0,1967,'х/с, балкон, д/фон, с/у/с, мет/дверь, см/изол, торг.',0,0,0,0,0,'2014-11-10 11:08:54','2015-04-17 08:51:58',1,12,1,0,0,-1,1,4,'3af7ad8e-3256-4b4e-882c-7698adaf7611','',0),(131,'Омск','Орджоникидзе','83','','4600','644122, обл. Омская, г. Омск, ул. Орджоникидзе, д. 83','55.003807','73.363891',0,3,4600,5,3,10,118,2,81.40,45.20,12.00,1,1,2000,'с/у/р, х/с, изол, вх/мет, встр/меб',0,1,0,0,0,'2014-11-10 11:11:54','2014-12-15 09:09:49',1,8,1,0,0,-1,1,4,'6e42accb-0c7c-48ef-acb3-b184461686d8','',0),(132,'Омск','70 лет Октября','15','','7000','644074, обл. Омская, г. Омск, ул. 70 лет Октября, д. 15','54.981763','73.321293',0,3,7000,1,6,9,148,2,110.00,82.00,14.00,1,1,2008,'Дизайнерский ремонт, ПВХ, сч/в, вх/мет',1,0,0,0,0,'2014-11-10 11:14:24','2014-12-15 09:10:18',1,8,1,0,0,-1,1,4,'c7c79af5-87aa-4b70-a101-c4f240ed739d','',0),(133,'Омск','Красный Путь','145','','3150','644033, обл. Омская, г. Омск, ул. Красный Путь, д. 145','55.011774','73.333357',0,3,3150,4,1,5,19,2,57.70,41.70,6.00,0,0,0,'см/из, с/у/с, под коммерческую недвижимость',0,0,0,0,0,'2014-11-10 11:18:09','2014-12-15 09:10:43',1,2,1,0,0,-1,1,4,'5f96b897-42aa-40fe-87dc-ffe6bd5d9786','',0),(134,'Омск','Андрианова','8','','2570','г. Омск, ул. Андрианова, 8','55.026546','73.276584',0,3,2570,4,3,5,29,2,53.00,34.00,6.00,1,0,0,'ПВХ, с/у/с, нат/потолки, новые стояки, замена сантехники, х/с, изол',0,1,0,0,0,'2014-11-10 11:20:52','2015-04-17 08:52:39',1,12,1,0,0,-1,1,4,'b4b0a749-35ec-44f4-b800-4ab17fcaba08','',0),(135,'Омск','Мира','96А','','2200','г. Омск, пр-кт. Мира, 96А','55.029936','73.251602',0,3,2200,4,3,5,0,1,58.00,44.00,6.00,1,0,0,'ПВХ, мет/дверь, с/у/с, состояние среднее',0,0,0,0,0,'2014-11-10 11:23:05','2015-04-17 08:53:00',1,12,1,0,0,-1,1,4,'61a5e2f9-3578-4e23-8465-ec04a3d5d446','',0),(136,'Омск','Сазонова','33','','7700','г. Омск, ул. Сазонова, 33','55.00107','73.359642',0,3,7700,5,8,14,21,2,95.00,41.00,12.00,0,1,2010,'Элитный дом в микр. Ласточкино гнездо. Отличное состояние, ПВХ, 2 с/у/с, лоджия застеклена, комн/изол',0,0,0,0,0,'2014-11-10 11:26:14','2015-04-17 08:53:35',1,8,1,0,0,-1,1,4,'049010c7-3224-47d0-9975-78b362480e27','',0),(137,'Омск','Мамина-Сибиряка','9','','2160','г. Омск, ул. Мамина-Сибиряка, 9','55.03409','73.258923',0,3,2160,4,5,5,78,1,55.50,37.10,5.40,1,0,0,'не угловая, см/изол, с/у/р, свободная',1,1,0,0,0,'2014-11-10 11:28:26','2015-04-17 08:53:50',1,0,1,0,0,-1,1,4,'d8beab45-85c2-407a-a2cf-6fd96e73617e','',0),(138,'Омск','Циолковского','2','','3000','644042, обл. Омская, г. Омск, ул. Циолковского','54.96208','73.383915',0,3,3000,5,1,5,44,2,53.30,0.00,0.00,0,0,0,'не угл, см/изол, с/у/с, ПВХ, х/с, мет/дверь, замена сант, 2 собственника',0,0,0,0,0,'2014-11-10 11:31:20','2014-11-10 11:31:20',1,11,1,0,0,-1,1,1,'9d7379f9-2e2c-42de-b792-f44693f3ae64','',0),(139,'Омск','Мира','167А','','1750','644085, обл. Омская, г. Омск, пр-кт. Мира, д. 167А','55.032052','73.221059',0,3,1750,4,2,5,5,2,50.00,36.00,6.00,1,0,0,'с/у/р, окно на кухне ПВХ, сч/газ, требуется ремонт',0,0,0,0,0,'2014-11-10 11:33:27','2014-11-10 11:33:27',1,8,1,0,0,-1,1,1,'50d67410-c082-4e6a-a182-835615fb7d90','',0),(140,'Омск','Мира','37а','','620000','644029, обл. Омская, г. Омск, пр-кт. Мира, д. 37','55.028723','73.272964',2,1,620000,4,2,5,0,2,10.00,10.00,0.00,0,0,0,'состояние норм,ПВХ,метал дверь.Весь комплект документов,2 прописанных. Собственник Юля. Отложили до весны 2015 г ',1,0,0,0,0,'2014-11-11 11:46:14','2014-11-11 11:46:14',1,14,1,0,0,-1,2,0,'2757e0f1-ca0d-4a22-b70c-82ec5169c114','',0),(141,'Омск','Культуры','4А','','600','644029, обл. Омская, р-н. Омский, г. Омск, пр-кт. Культуры, д. 4А','55.030308','73.277213',2,1,600,4,3,5,0,2,12.00,12.00,0.00,0,0,0,'чистая продажа,собственник девушка прописана она и несовершеннолетний ребенок.состояние среднее',1,0,0,0,0,'2014-11-12 09:25:55','2014-11-12 09:25:55',1,14,1,0,0,-1,2,0,'ccb6457c-5842-4f57-bc47-ece4abae9928','',0),(142,'Омск','19 Партсъезда','24Б','','1900000','644065, обл. Омская, р-н. Омский, г. Омск, ул. 19 Партсъезда, д. 24Б','55.035023','73.274814',2,2,1900000,4,3,3,0,0,55.00,0.00,0.00,0,0,0,'Звонила,критиковал агенство кто занимался его кв 89268548809 сергей',0,0,0,0,0,'2014-11-12 09:52:19','2014-11-12 09:52:19',1,14,1,0,0,-1,1,0,'c1396252-2250-4e6c-b05a-5f2309df3621','',0),(143,'Омск','50 лет Профсоюзов','85','','600000','644053, обл. Омская, р-н. Омский, г. Омск, ул. 50 лет Профсоюзов, д. 85','54.791731','73.630547',2,1,600000,4,5,5,0,2,13.20,0.00,0.00,0,0,0,'Не срочная продажа,Клиент появляется Алексей продает свою комнату,(комната сдается в аренду)89836211207',1,0,0,0,0,'2014-11-12 09:58:52','2014-11-12 09:58:52',1,14,1,0,0,-1,2,0,'fe28059d-7ed7-41fd-b740-545959e1c3d1','',0),(144,'Омск','Королева','4А','','790000','644045, обл. Омская, р-н. Омский, г. Омск, пр-кт. Королева, д. 4А','55.031892','73.328641',2,1,790000,4,4,5,0,2,18.00,0.00,0.00,0,0,0,'не угловая,здание кап ремонт 2013г,торг 89043211584 Ольга',0,0,0,0,0,'2014-11-12 10:05:26','2014-11-12 10:05:26',1,14,1,0,0,-1,2,0,'31c4512c-f64f-4d62-b742-c01b83aa2dc2','',0),(145,'Омск','Коммунальная','21','','1650000','644083, обл. Омская, р-н. Омский, г. Омск, ул. Коммунальная, д. 21','55.056321','73.313415',0,2,1650000,4,4,5,0,1,42.20,26.40,6.60,1,0,0,'89083182592 Лидия Геннадевна',0,0,0,0,0,'2014-11-12 10:08:24','2014-11-12 10:08:24',1,14,1,0,0,-1,1,0,'182f4f1b-b96c-49d7-972d-5f27fd839593','',0),(146,'Омск','Коммунальная','21','','1650000','644083, обл. Омская, р-н. Омский, г. Омск, ул. Коммунальная, д. 21','55.056321','73.313415',2,2,1650000,4,4,5,0,1,42.20,26.40,6.60,1,0,0,'89083182592 Лидия Геннадьевна',0,0,0,0,0,'2014-11-12 10:11:50','2014-11-12 10:11:50',1,14,1,0,0,-1,1,5,'93146fef-2b97-4d51-80e8-d7d1bd02afb2','',0),(147,'Омск','Андрианова','8','','1500000','644029, обл. Омская, р-н. Омский, г. Омск, ул. Андрианова, д. 8','55.026148','73.266217',2,1,1500000,4,2,5,0,2,30.00,18.00,5.60,1,0,0,'состояние норм с частичным ремонтом,балкон застеклен, и продает гараж капитальный(бетонные плиты и брус) с подвалом 500 т р.89507807330',0,0,0,0,0,'2014-11-12 10:21:10','2014-11-12 10:21:10',1,14,1,0,0,-1,1,0,'cb8b7ae8-71a4-4272-a002-723037569c83','',0),(148,'Омск','Поселковая 4-я','34А','','1500000','644050, обл. Омская, р-н. Омский, г. Омск, ул. Поселковая 4-я, д. 34А','55.029245','73.291424',2,1,1500000,4,1,4,0,2,30.00,13.00,7.00,0,0,0,'89881875862 Надежда Дмитриевна.Документы не видела,говорит,что все.Квартира сама 24 кв.м. и присвоена площадь общего пользования не узаконина,просто собрали согласие соседей пользуются уже этой площадью лет 10.Остается современный кухонный гарнитур,шкаф-купе,прихожая.бала там,собственница не захотела с агентством работать. ',0,0,0,0,0,'2014-11-12 10:46:13','2014-11-12 10:46:13',1,14,1,0,0,-1,1,5,'c907b36e-023f-4b6c-b6de-5bc8dd2041ef','',0),(149,'Омск','50 лет Профсоюзов','119','','3500000','644089, обл. Омская, р-н. Омский, г. Омск, ул. 50 лет Профсоюзов, д. 119','54.791731','73.630547',2,4,3500000,4,6,9,219,2,74.00,52.00,8.00,0,1,1990,'8-960-985-07-00 Татьяна.Хотела разменять на однокомнатную и двухкомнатную разъехаться с сыном.Потом передумали продавать.',0,0,1,0,0,'2014-11-12 11:01:22','2014-11-12 11:01:22',1,14,1,0,0,-1,1,0,'5cb6322f-8437-460a-83ce-183c61bad76f','',0),(150,'Омск','Олимпийская','4','','1400000','644076, обл. Омская, р-н. Омский, г. Омск, ул. Олимпийская, д. 4','54.811212','73.596654',2,1,1400000,3,5,5,10,1,30.00,18.00,7.00,1,0,0,'Маша, 386495',0,1,1,0,1,'2014-11-28 04:45:45','2014-12-02 12:10:48',1,16,1,0,0,-1,1,0,'31ae6ab3-c446-4f83-b6ed-5497399389e1','',0),(151,'Омск','Молодежная 3-я','73','','1249','644117, г. Омск, ул. Молодежная 3-я, 73','54.954135','73.472839',1,1,1249,3,2,9,19,1,30.00,17.00,5.00,0,0,1985,'8-913-610-77-85 Наталья Караткевич\nКвартира в хорошем состоянии, о/ПВХ, счетчики на все, трубы на воду ПВХ, новые радиаторы отопления.',0,0,1,0,0,'2014-12-02 11:26:05','2015-04-22 11:19:34',1,5,1,0,0,-1,3,1,'094e7044-0811-40ec-9fe4-56f2a3050fc8','',0),(152,'Омск','Гуртьева','33','','1650','644060, обл. Омская, р-н. Омский, г. Омск, ул. Гуртьева, д. 33','54.920584','73.409876',2,1,1650,2,4,9,51,2,27.00,13.00,9.00,1,0,1990,'Получение ипотеки для покупки другого жилья',0,0,0,0,0,'2014-12-15 08:18:13','2014-12-15 08:18:13',1,16,1,0,0,-1,1,0,'3153047f-c4c2-4a57-87e2-78d0c59b0208','',0),(153,'Омск','50 лет Профсоюзов','97 А','','1980','г. Омск, ул. 50 лет Профсоюзов, 97 А','55.034224','73.25966',2,3,1980,4,5,5,0,1,50.10,0.00,0.00,1,0,0,'АН Прогресс предлагает к продаже светлую, уютную, солнечную квартиру с евроремонтом. Использованы только качественные материалы. Окна ПВХ, металлическая дверь, алюминиевые радиаторы, три встроенных шкафа-купе, новый встроенный кухонный гарнитур. Установлены счетчики. Балкон застеклен. Кухня-студия. Квартира достойная Вашего внимания, заезжайте и живите!',1,0,0,0,0,'2014-12-15 09:14:13','2015-04-17 08:54:09',1,5,1,0,0,-1,1,4,'84383572-08c0-4a99-ad2f-18e6839e966a','',0),(154,'Омск','Кордная 5-я','69','','1750','644018, обл. Омская, г. Омск, ул. Кордная 5-я, д. 69','54.96054','73.467736',2,2,1750,3,5,5,34,1,44.00,28.00,6.00,1,0,1980,'требуется косметический ремонт',1,0,0,0,0,'2014-12-16 08:00:47','2014-12-16 08:00:47',1,16,1,0,0,-1,1,0,'a216352e-5059-41d0-810c-4e935297e0d4','',0),(155,'Омск','Краснопресненская','1','','0','644041, г. Омск, ул. Краснопресненская, д. 1','54.951338','73.421788',2,1,0,3,4,5,40,2,30.00,18.00,5.00,1,0,1978,'продается 1/2 доля, другая доля у ребенка. Будет выкупать мать ребенка.',1,0,0,0,0,'2014-12-24 09:27:01','2014-12-24 09:27:01',1,16,1,0,0,-1,3,0,'6dba8abf-0e29-4952-b15b-d354aa68ad06','',0),(156,'Омск','Гуртьева','33','','0','644060, г. Омск, ул. Гуртьева, д. 33','54.920584','73.409876',2,1,0,2,4,9,51,2,28.00,130.00,8.00,1,0,1990,'8-913-646-97-88 Мария\nпокупка 2-х комн. с оформлением ипотеки (бюджетник), возможно с продажей м/с. Дети дольщики',0,0,1,0,0,'2014-12-24 10:22:10','2014-12-24 10:22:10',1,16,1,0,0,-1,3,0,'594d9818-af83-4c44-a523-5911efff738d','',0),(157,'Омск','Кирова','6','','1800','г. Омск, ул. Кирова, 6','54.949125','73.415823',2,1,1800,3,2,9,18,2,26.00,14.00,7.00,1,0,1987,'Квартира в хорошем состоянии, о/ПВХ, санузел совмещен - кафель, заменены все трубы и электропроводка, выровнены стены и пол.',1,0,0,0,0,'2015-01-26 04:44:28','2015-04-17 08:54:36',1,16,1,0,0,-1,3,4,'a9a3f4bf-366c-47f9-a2d3-2d5d3440d95c','',0),(158,'Омск','В.Ф.Маргелова','356','','2060','644025, обл. Омская, р-н. Омский, г. Омск, ул. В.Ф.Маргелова, д. 356','54.885953','73.481597',0,2,2060,2,3,5,10,1,52.40,28.40,8.20,1,1,0,'АН \"ПРОГРЕСС\" предлагает Вашему вниманию уютную квартиру. Без перепланировок. Из окна прекрасный вид на рощу. Комнаты изолированные. Балкон и лоджия застеклены. В квартире аккуратно и чисто. Можно заехать и жить, или же сделать ремонт под себя! Тамбур на 2 хозяина, приличные соседи. Подъезд тихий, чистый. Развитая инфраструктура: ост. Микрорайон Светлый конечная (в нескольких минутах от дома), поликлиника №10, множество детских площадок, роща, детский сад №299, школа №148, продуктовый магазин - всё в шаговой доступности. Подходит под ипотеку, материнский капитал. Торг.',1,1,0,0,0,'2015-03-04 11:12:45','2015-03-04 11:12:45',1,5,1,0,0,-1,1,1,'79102b58-4784-45a0-a24e-6e8e71eea653','',0),(159,'Омск','Б. Петухова','5','','1760','г. Омск, Б. Петухова, 5','55.028347','73.283204',0,2,1760,4,2,5,0,2,46.00,0.00,0.00,1,0,0,'На срочной продаже квартира в центре г. Нефтяников. Дом находится напротив КДЦ \"Кристалл\". В нескольких метрах ПКиО Советский, река Иртыш, стадион Нефтяник. Вы сможете как прогуливаться всей семьей, так и заниматься спортом. Развита инфраструктура: ост. Кристалл, гимназия №117, детский сад №222, детская площадка, спортивный клуб, Сбербанк, ТК Европа, аптеки, магазины: Гранат, Еда, Магнит, Холидей; развлекательные заведения. Запись на просмотр с 14. 03. 2015 г.',0,0,0,0,0,'2015-03-04 11:20:05','2015-04-17 08:54:53',1,5,1,0,0,-1,1,4,'87ad6456-9462-4c61-961c-c48d595bc2e7','',0),(160,'Омск','Королева','14','','1900','г. Омск, пр-кт. Королева, 14','55.037908','73.304144',0,2,1900,4,1,9,146,1,44.30,27.00,6.90,0,1,1972,'АН «Прогресс» предлагает Вашему вниманию 2-комнатную квартиру. Изолированные комнаты, санузел раздельный. Лоджия остеклена. На окнах и лоджии установлены металлические решетки. Окна выходят не на магистраль. Входная металлическая дверь, тамбур на 2 квартиры, чистый подъезд. Рядом с домом вся необходимая инфраструктура: ост. Волкова, школа №82, детский сад №201, супермаркет «Сибириада», магазин «Магнит», ТК «На Королева», поликлиника №4, почтовое отделение, детские площадки. Чистая продажа. ',1,0,0,0,0,'2015-04-17 09:16:37','2015-04-17 09:20:54',1,5,1,0,0,-1,1,1,'310032d3-e1a8-4d62-b409-ff7cc8477804','',0),(161,'Омск','Котельникова','6','','3860','г. Омск, ул. Котельникова, 6','54.937883','73.378093',0,3,3860,2,4,14,18,1,73.80,51.10,9.10,1,0,1991,'Современная, уютная 3-х. квартира, с хорошим качественным ремонтом, подойдет для людей, которые покупают квартиру с ремонтом. Комнаты изолированы, с/у совмещен, на полу постелен линолеум, пол с подогревом. Металлическая двойная дверь. Окна ПВХ, хорошая сантехника. В комнатах кондиционеры. Балкон остеклен, обшит панелью. Большой отдельный тамбур используется, как дополнительный коридор. В квартире остается шкаф- купе, кухонный гарнитур, электрическая плита. Перепланировка узаконена. Квартира не угловая, очень теплая, светлая и просторная. Отличное расположение! Рядом остановка, магазины, Ленинский рынок, школа, детский сад во дворе . В нескольких минутах ходьбы Иртышская Набережная, Центр спортивной подготовки Авангард. Чистая продажа! Возможна продажа по ипотеке.',1,1,0,0,0,'2015-04-17 09:27:41','2015-04-17 09:35:32',1,11,1,0,0,-1,1,1,'b6a90af3-73a2-46eb-a180-e26420aaf2ce','',0),(162,'Омск','Котельникова','2','','3570','г. Омск, ул. Котельникова, 2','54.939527','73.378758',0,3,3570,2,3,9,125,1,61.30,44.60,7.10,1,1,0,'Уютная квартира, с хорошим качественным современным ремонтом, выполненным с использованием импортных материалов. Дорогостоящая входная дверь по индивидуальному заказу. Одна комната изолирована, с/у совмещен. На полу постелен ламинат. Окна ПВХ, новая сантехника. Балкон и лоджия застеклены, обшиты панелью. В квартире остается шкаф- купе, кухонный гарнитур, кондиционер. Квартира не угловая, очень теплая, светлая и просторная. подойдет для людей, которые покупают квартиру с ремонтом. Отличное расположение! Рядом остановка, магазины, Ленинский рынок, школа, детский сад во дворе. В нескольких минутах ходьбы Иртышская Набережная, Центр спортивной подготовки Авангард. Чистая продажа! Возможна ипотека.',1,1,0,0,0,'2015-04-17 09:30:33','2015-04-22 11:17:42',1,11,1,0,0,-1,1,4,'8a5da20a-3517-4268-a80b-504b6cba08f0','',0),(163,'Омск','20 Линия','61','','1480','644031, обл. Омская, г. Омск, ул. 20 Линия, д. 61','54.987529','73.425066',0,1,1480,5,3,9,130,1,29.80,17.40,5.10,0,0,0,'Цена снижена до 19. 04. 2015 г. На срочной продаже 1комнатная квартира малосемейного типа. Окна во двор, без балкона. Санузел совмещен. Металлическая входная дверь. Остается шкаф-купе, кухонный гарнитур. Квартира теплая, не угловая. Дом расположен на пересечении ул. 10 лет Октября и ул. 20 Линия. Район с развитой инфраструктурой: торговый комплекс \"Тара\", поликлиника, Супермаркеты, салоны, Центры развития детей, Детский сад, школа № 48, № 90. Документы готовы. Возможна продажа по ипотеке. Обменный вариант подобран.',0,1,1,0,0,'2015-04-17 09:47:05','2015-04-27 10:45:43',1,11,1,0,0,-1,3,1,'288ba2a4-73aa-4fbb-a7eb-b0975210ae24','',1),(164,'Омск','Пирогова','48','','1800','644001, г. Омск, ул. Пирогова, 48','54.982156','73.408861',0,1,1800,0,2,5,7,2,30.20,16.90,6.30,1,0,1967,'Уютная светлая квартира в теплом кирпичном доме в стороне от магистрали (на пересечении ул. Лермонтова и Б. Хмельницкого) в отличном состоянии. Санузел совмещен. Балкон. Свежий ремонт: окна ПВХ, натяжной потолок, линолеум, новая сантехника, душевая кабина (Apollo), встроенный шкаф, произведена замена коммуникаций, счетчик на газ. В подвале дома имеется кладовка. Телефон, домофон, интернет, каб. ТВ Чистый подъезд. Тихий зеленый двор. В шаговой доступности детский сад, школа, все необходимые элементы инфраструктуры. ',0,0,1,0,0,'2015-04-17 09:56:23','2015-04-22 11:20:44',1,11,1,0,0,-1,1,1,'f39748b0-7f70-4f6a-97ab-1c150f54d8ec','',0),(165,'Омск','Андрианова','10','','1800','644029, обл. Омская, г. Омск, ул. Андрианова, д. 10','55.026757','73.275677',0,2,1800,4,5,5,59,2,45.20,30.30,5.10,1,0,1959,'АН \"Прогресс\" предлагает к продаже квартиру в центре г. Нефтяников. Квартира переделана из 2-комнатной в 3-комнатную, перепланировка узаконена. Санузел совмещен. Балкон застеклен. вся необходимая инфраструктура в шаговой доступности, транспорт по всем направлениям. А за окном – высокие деревья и свежий воздух (зеленая зона Советского парка). Торг.',0,1,0,0,0,'2015-04-17 10:03:02','2015-04-17 10:03:02',1,12,1,0,0,-1,1,1,'42ddba31-0297-43c1-b1c7-c48b3286c1a3','',0),(166,'Омск','Декабристов','71','','2150','644024, обл. Омская, г. Омск, ул. Декабристов, д. 71','54.977857','73.394066',0,2,2150,5,5,5,79,2,43.30,29.40,6.00,1,0,0,'Продам 2-х комнатную квартиру в районе СКК им. Блинова. 5-й этаж 5-ти этажного кирпичного дома. В хорошем состоянии. Санузел раздельный. Пластиковые окна. косметический ремонт. Остается шкаф-купе, кондиционер. Балкон остеклен с выносом, обшит деревом. Натяжные потолки. Квартира очень светлая и теплая. Уютный, зеленый двор, новая хоккейная коробка, есть парковка. В доме Аптека. Чистый подъезд, хорошие соседи. Подходит под ипотеку. Документы готовы, вариант подобран.',0,1,1,0,0,'2015-04-17 10:07:47','2015-04-17 10:07:47',1,11,1,0,0,-1,1,1,'f4d3f839-6b01-454a-9567-395456b094ae','',0),(167,'Омск','Транссибирская','4','','3250','644103, г. Омск, ул. Транссибирская, 4','54.952847','73.336645',0,3,3250,1,1,6,159,2,74.00,41.00,12.00,0,1,1996,'3-комнатная квартира с частичным ремонтом. Несмотря на первый этаж очень светлая. Комнаты изолированные. Просторная кухня 12 кв. м. Окна ПВХ на две стороны. Потолки и стены выровнены. Полы меняли и утепляли. В квартире очень тепло. Подходит под ипотеку любого банка (окажем помощь в оформлении). Рядом остановка общественного транспорта, лицей №145, детская и взрослая поликлиники, аптеки, магазины, фирмы и организации различной социальной направленности.',0,1,1,0,0,'2015-04-17 10:14:19','2015-04-22 11:15:35',1,8,1,0,0,-1,1,1,'9b432206-03d1-4b09-8b2e-ee253eaf218b','',0),(168,'Омск','Иркутская','5','','5400','644070, обл. Омская, г. Омск, ул. Иркутская, д. 5','54.988897','73.403183',0,4,5400,5,8,10,40,2,82.00,52.00,8.50,1,1,1993,'4-комнатная квартира с ремонтом в классическом стиле, спокойных тонах. Все комнаты изолированные. Окна (деревянные стеклопакеты, покрыты лаком)- на две стороны. Балкон и лоджия застеклены ПВХ. Трубы все меняли. При продаже остается новый кухонный гарнитур с встроенной техникой (варочная поверхность и духовой шкаф \"Электролюкс\", посудомоечная машина \"Индезит\"), три шкафа-купе. Есть вместительная кладовка для хранения «нужных» вещей. Огромный тамбур на три квартиры позволит Вам, никому не мешая, ставить коляску или велосипед. Квартира располагается в центре города, остановка общественного транспорта в 5-ти минутах спокойной ходьбы от дома, рядом гимназия № 146, школы № 65, 132, д/сады № 378, 51, начальная школа-сад № 146, детская поликлиника, множество разнообразных магазинов, фирм, организаций социально-бытового обслуживания. Дом содержится в чистоте и порядке. Поможем Вам оформить ипотеку на данный объект. Кроме того возможно приобретение капитального гаража так же в шаговой доступности от дома.',1,1,0,0,0,'2015-04-22 11:28:32','2015-04-22 11:28:32',1,8,1,0,0,-1,1,1,'db78c117-2901-4309-89d2-7453dc57e2cf','',0),(169,'Омск','Поселковая 2-я','53В','','3470','644050, обл. Омская, г. Омск, ул. Поселковая 2-я, д. 53В','55.027794','73.298251',1,3,3470,4,3,5,0,2,64.00,42.00,7.00,0,1,1983,'3-комнатная квартира с изолированными комнатами в кирпичном доме на отличном этаже. Лоджия застеклена ПВХ и облагорожена светлым деревом. Произведена полная замена всех труб, установлены счетчики на все. В ванной современный кафель и душевая кабина, сантехника новая. На кухне остается кухонный гарнитур. Большой квадратный коридор. На площадке только 2 квартиры. Подъезд в чистоте. Рядом с домом можно дополнительно приобрести капитальный гараж. Для семей с детьми поблизости школа № 109, д/сад, возле дома детская площадка. Для комфортного проживания Вас и Вашей семьи есть абсолютно вся инфраструктура. Квартира подходит под ипотеку (окажем помощь).',1,1,0,0,0,'2015-04-22 11:31:32','2015-04-22 11:31:32',1,8,1,0,0,-1,1,1,'cb7d5a97-41ab-43ed-a6c7-40b8ce8a7207','',0),(170,'Омск','Мира','49','','2170','644077, обл. Омская, г. Омск, пр-кт. Мира, д. 49','55.028125','73.26734',0,2,2170,4,3,5,12,2,43.00,28.00,6.00,1,0,0,'2-комнатная квартира на лучшем этаже, солнечная сторона. Полностью заменили трубы, сантехнику, электропроводку. Установлены счетчики на все. Новые окна ПВХ, межкомнатные двери и входная дверь. Балкон застеклен. Квартира чистая и опрятная. Остается корпусная мебель в зале. Дом капитально отремонтирован от крыши до подвала. Прекрасное месторасположение: д/сад №195, 241, школа № 94, лицей № 166, ОмГУ, магазины, филиалы банков, фирм разнообразной социальной направленности. Возможна ипотека и мат. капитал (окажем помощь в оформлении всех необходимых документов непосредственно в офисе нашего агентства недвижимости \"ПРОГРЕСС\" на наиболее выгодных для Вас условиях). ',1,1,0,0,0,'2015-04-22 11:34:24','2015-04-22 11:34:24',1,8,1,0,0,-1,1,1,'b5577e76-2f0d-47ed-9c52-b6b2688626a6','',0),(171,'Омск','Заозерная','36','','3270','обл. Омская, г. Омск, ул. Заозерная, 36','55.043278','73.312355',0,3,3270,4,6,9,18,1,63.00,41.00,10.50,1,1,1992,'3-комнатная квартира ленинградской серии в достойном состоянии. Окна частично ПВХ на две стороны. Есть застекленные лоджия и балкон. Установлены новые счетчики на все. Квартира светлая, теплая, не угловая. Комнаты изолированные. В подъезде образцовый порядок и тишина. Отличное расположение дома относительно остановки общественного транспорта, рядом д/сад №81, 394, 342, школа №44, взрослая поликлиника №11, магазины, аптеки, банкоматы и филиалы банков. Окажем помощь в покупке квартиры по ипотеке.',0,1,1,0,0,'2015-04-22 11:37:46','2015-04-22 11:37:46',1,8,1,0,0,-1,1,1,'19349d23-0df7-4720-8864-46c2395f4106','',0),(172,'Омск','Бульварная','15','','1660','644046, обл. Омская, г. Омск, ул. Бульварная, д. 15','54.965688','73.401629',0,1,1660,3,3,9,0,1,29.30,0.00,0.00,1,0,0,'АН \"Прогресс\" предлагает к продаже квартиру малосемейного типа. В квартире остается кухонный гарнитур. Санузел совмещен, новые межкомнатные двери. Балкон. Двойная входная дверь. Инфраструктура: ост. Лизы Чайкиной, школа №62, детский сад №291, центр покупок \"Куйбышевский\", \"Урожай\", магазин \"Гураль\", аптека. Чистая продажа. Торг.',1,1,0,0,0,'2015-05-08 09:17:14','2015-05-08 09:17:14',1,17,1,0,0,-1,1,1,'b047eaae-a867-4f4c-89f2-b6cb4bbe8702','',0),(173,'Омск','Военный 17-й','370','','2070','644007, обл. Омская, г. Омск, городок. Военный 17-й, д. 370','55.008134','73.384561',0,3,2070,5,4,5,91,2,54.00,39.00,6.00,1,0,0,'АН \"ПРОГРЕСС\" предлагает к продаже 3-комнатную квартиру. Установлены новые межкомнатные двери, окна ПВХ, на полу линолеум, сделан косметический ремонт. Чистый подъезд. Возможен обмен на 1-комнатную квартиру и дом. Торг.',1,0,1,0,0,'2015-05-08 09:22:53','2015-05-08 09:22:53',1,17,1,0,0,-1,1,1,'3fb5848f-27b0-4a89-a97c-3e7b01c9ee60','',0),(174,'Омск','Молодежная 3-я','59','','2160','644117, обл. Омская, г. Омск, ул. Молодежная 3-я, д. 59','54.951798','73.461412',1,3,2160,3,9,9,105,1,65.00,39.00,9.00,0,1,0,'АН \"Прогресс\" предлагает к продаже 3-комнатную квартиру. Санузел раздельный, комнаты изолированные, лоджия застеклена. Перепланировок нет. Подходит под ипотеку, материнский капитал. Чистая продажа. Так же рассмотрим обменный вариант на 2-комнатную квартиру с доплатой. Торг. Остановка \"3-я Молодежная\" в пяти минутах от дома. Развитая инфраструктура: хорошая детская площадка, хорошая транспортная развязка, школа №58, библиотека, магазин \"Привет+\", ТК \"Роща\" - всё в шаговой доступности. Во дворе дома: аптека, детский сад № 365. ',1,1,0,0,0,'2015-05-08 09:25:50','2015-05-08 09:25:50',1,17,1,0,0,-1,1,1,'08f78206-20cd-4cec-885c-f44d517daf77','',0);
/*!40000 ALTER TABLE `Apartaments` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `News`
--
DROP TABLE IF EXISTS `News`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `News` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`idWorker` int(11) NOT NULL,
`Header` mediumtext NOT NULL,
`Text` mediumtext NOT NULL,
`CreationDate` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
`LastModify` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00',
`Deleted` tinyint(1) NOT NULL DEFAULT '0',
PRIMARY KEY (`id`),
KEY `idWorkerIndex` (`idWorker`),
CONSTRAINT `News_ibfk_1` FOREIGN KEY (`idWorker`) REFERENCES `Workers` (`id`)
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `News`
--
LOCK TABLES `News` WRITE;
/*!40000 ALTER TABLE `News` DISABLE KEYS */;
INSERT INTO `News` VALUES (1,1,'Документация','Доступна по ссылке\nhttps://docs.google.com/document/d/1H_aW2oHrd3zPMU2N5_wvQ1V2mFGYAIKWb7HGavHeyjs/edit','2014-02-02 19:18:43','2014-02-02 19:18:43',0),(2,1,'test','test','2014-02-05 17:26:16','2014-02-05 17:26:19',1),(3,1,'Документация','<a href=\"http://goo.gl/7SWHHH\">ссылка</a>','2014-05-23 03:02:19','2014-07-01 02:51:08',1),(4,1,'ссылка откроется в новом окне','<p><a href=\"2.html\" target=\"_blank\">Ссылка откроется в новом окне</a></p>','2014-07-01 02:49:06','2014-07-01 02:49:26',1),(5,1,'Документация','<p><a href=\"#news\" target=\"_blank\">Ссылка откроется в новом окне</a></p>','2014-07-01 02:50:28','2014-07-01 02:50:40',1),(6,1,'Документация','<p><a href=\"https://docs.google.com/document/d/1H_aW2oHrd3zPMU2N5_wvQ1V2mFGYAIKWb7HGavHeyjs/edit?pli=1\" target=\"_blank\">Ссылка откроется в новом окне</a></p>','2014-07-01 02:50:59','2014-07-01 02:50:59',0),(7,1,'Обновление','1) Обновлен функционал \"Клиенты\"\n2) Добавлена проверка адреса, при добавлении нового объекта\n3) Прочие мелкие исправления.','2014-08-26 19:06:53','2014-08-26 19:06:53',0),(8,1,'Обновление','1) Обновлен функционал \"Клиенты\"\n2) Добавлена проверка адреса, при добавлении нового объекта\n3) Прочие мелкие исправления.','2014-08-31 19:58:32','2014-08-31 19:58:32',0),(9,1,'Обновление','1) Обновлен функционал \"Новости\" - поддерживается добавление, редактирование и удаление.','2014-09-03 08:09:36','2014-09-03 08:09:36',0),(10,1,'Обновление','1) Изменен формат даты.\n2) Прочие исправления.','2014-10-05 17:28:47','2014-10-05 17:28:47',0);
/*!40000 ALTER TABLE `News` ENABLE KEYS */;
UNLOCK TABLES;
--
-- Table structure for table `Workers`
--
DROP TABLE IF EXISTS `Workers`;
/*!40101 SET @saved_cs_client = @@character_set_client */;
/*!40101 SET character_set_client = utf8 */;
CREATE TABLE `Workers` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`FName` varchar(50) NOT NULL,
`MName` varchar(50) NOT NULL,
`LName` varchar(50) NOT NULL,
`PwdHash` varchar(40) NOT NULL,
`Permissions` int(11) NOT NULL DEFAULT '1',
`Email` varchar(50) NOT NULL,
`Deleted` tinyint(1) NOT NULL DEFAULT '0',
`IsActive` tinyint(1) NOT NULL DEFAULT '1',
PRIMARY KEY (`id`),
UNIQUE KEY `EmailIndex` (`Email`)
) ENGINE=InnoDB AUTO_INCREMENT=18 DEFAULT CHARSET=utf8;
/*!40101 SET character_set_client = @saved_cs_client */;
--
-- Dumping data for table `Workers`
--
LOCK TABLES `Workers` WRITE;
/*!40000 ALTER TABLE `Workers` DISABLE KEYS */;
INSERT INTO `Workers` VALUES (1,'Не','','выбран','null',0,'null',1,1),(2,'Сергей','Викторович','Стопкин','f9a7c6df341325822e3ea264cfe39e5ef8c73aa4',3,'admin@progress55.com',0,1),(3,'Имя','Отчество','Фамилия','f9a7c6df341325822e3ea264cfe39e5ef8c73aa4',3,'user@progress55.com',0,0);
/*!40000 ALTER TABLE `Workers` ENABLE KEYS */;
UNLOCK TABLES;
/*!40103 SET TIME_ZONE=@OLD_TIME_ZONE */;
/*!40101 SET SQL_MODE=@OLD_SQL_MODE */;
/*!40014 SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS */;
/*!40014 SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS */;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
/*!40111 SET SQL_NOTES=@OLD_SQL_NOTES */;
-- Dump completed on 2015-06-15 20:52:23
| 571.976048 | 87,830 | 0.719095 |
7fa7f8e3a52d6988e877c2636b370238817ebc28 | 1,250 | sql | SQL | var/schema.sql | Mathieu-Lichtsteiner/WEBT_FS21_Projekt | 1e5fd15aa8fcf34ed70bc831fd2f5553f09af5b4 | [
"MIT"
] | null | null | null | var/schema.sql | Mathieu-Lichtsteiner/WEBT_FS21_Projekt | 1e5fd15aa8fcf34ed70bc831fd2f5553f09af5b4 | [
"MIT"
] | null | null | null | var/schema.sql | Mathieu-Lichtsteiner/WEBT_FS21_Projekt | 1e5fd15aa8fcf34ed70bc831fd2f5553f09af5b4 | [
"MIT"
] | null | null | null | /*
Ich brauche eine Tabelle für die Posts
Reihen:
- index (key)
- email-Adresse
- url zum Bild (eventuell nicht nötig, da benennung mit dem Datum, oder besser mit dem Index)
- Erstellungszeit (timestamp sollte ausreichend sein)
- beschreibung
*/
-- Datenbank "portofolio" erstellen
CREATE DATABASE portofolio;
-- Datenbank verwenden (standard-verfahren)
USE portofolio;
-- Tabelle "posts" erstellen (index wird für dateiname verwendet) (Achtung um Auto_increment zu brauchen, muss der typ von id ein int sein, was ich mit trial & error gemerkt habe)
CREATE TABLE posts (id int NOT NULL AUTO_INCREMENT PRIMARY KEY, firstName varchar(30) NOT NULL, lastName varchar(30) NOT NULL, email varchar(100) NOT NULL, created timestamp NOT NULL, msg varchar(1000) NOT NULL);
-- Abfrageindex für id erstellen
CREATE UNIQUE INDEX posts_id ON posts(id);
-- Abfrageindex für firstName erstellen
CREATE INDEX posts_firsName ON posts(firstName);
-- Abfrageindex für lastName erstellen
CREATE INDEX posts_lastName ON posts(lastName);
-- Erste Einträge erstellen
INSERT INTO posts (firstName, lastName, email, created, msg) VALUES ("Mathieu", "Lichtsteiner", "mathieu.lichts@fakemail.com", timestamp('2021-05-23 15:00:20'), "Das ist mein erstes Kustwerk! WOW!"); | 50 | 212 | 0.7736 |
265970b97c196e2fd37942cec6d2b5610efb0526 | 1,905 | java | Java | RobotControl/RobotControlGUI/src/de/naoth/rc/components/preferences/PreferencesSpinner.java | tarsoly/NaoTH | dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52 | [
"ECL-2.0",
"Apache-2.0"
] | 15 | 2015-01-12T10:46:29.000Z | 2022-03-28T05:13:14.000Z | RobotControl/RobotControlGUI/src/de/naoth/rc/components/preferences/PreferencesSpinner.java | tarsoly/NaoTH | dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52 | [
"ECL-2.0",
"Apache-2.0"
] | 2 | 2019-01-20T21:07:50.000Z | 2020-01-22T14:00:28.000Z | RobotControl/RobotControlGUI/src/de/naoth/rc/components/preferences/PreferencesSpinner.java | tarsoly/NaoTH | dcd2b67ef6bf9953c81d3e1b26e543b5922b7d52 | [
"ECL-2.0",
"Apache-2.0"
] | 5 | 2018-02-07T18:18:10.000Z | 2019-10-15T17:01:41.000Z | package de.naoth.rc.components.preferences;
/**
*
* @author Philipp Strobel <philippstrobel@posteo.de>
*/
public class PreferencesSpinner extends javax.swing.JPanel implements PreferencesField {
/**
* Creates new form integer spinner
* @param title
* @param value
*/
public PreferencesSpinner(String title, int value) {
initComponents();
this.label.setText(title);
this.spinner.setValue(value);
}
@Override
public String getPreferenceName() {
return getName();
}
@Override
public String getPreferenceValue() {
return String.valueOf(spinner.getValue());
}
@Override
public void setPreferenceValue(String value) {
if(value != null) {
spinner.setValue(Integer.parseInt(value));
}
}
/**
* This method is called from within the constructor to initialize the form. WARNING: Do NOT
* modify this code. The content of this method is always regenerated by the Form Editor.
*/
@SuppressWarnings("unchecked")
// <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
private void initComponents() {
label = new javax.swing.JLabel();
spinner = new javax.swing.JSpinner();
setMaximumSize(new java.awt.Dimension(2147483647, 40));
setLayout(new java.awt.BorderLayout());
label.setLabelFor(spinner);
label.setText("Name");
add(label, java.awt.BorderLayout.NORTH);
spinner.setModel(new javax.swing.SpinnerNumberModel());
add(spinner, java.awt.BorderLayout.CENTER);
}// </editor-fold>//GEN-END:initComponents
// Variables declaration - do not modify//GEN-BEGIN:variables
private javax.swing.JLabel label;
private javax.swing.JSpinner spinner;
// End of variables declaration//GEN-END:variables
}
| 28.863636 | 96 | 0.652493 |
1f7da817ab92154c374c98fb309c2e3022e0907b | 7,787 | css | CSS | module-06/css/styles.css | inna91/html-css-06 | 3213fa782dd8ed54c9538f89478e279b4b2a712a | [
"Unlicense"
] | null | null | null | module-06/css/styles.css | inna91/html-css-06 | 3213fa782dd8ed54c9538f89478e279b4b2a712a | [
"Unlicense"
] | null | null | null | module-06/css/styles.css | inna91/html-css-06 | 3213fa782dd8ed54c9538f89478e279b4b2a712a | [
"Unlicense"
] | null | null | null | @keyframes tada {
from {
-webkit-transform: scale3d(1, 1, 1);
transform: scale3d(1, 1, 1);
}
10%,
20% {
-webkit-transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
transform: scale3d(0.9, 0.9, 0.9) rotate3d(0, 0, 1, -3deg);
}
30%,
50%,
70%,
90% {
-webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, 3deg);
}
40%,
60%,
80% {
-webkit-transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
transform: scale3d(1.1, 1.1, 1.1) rotate3d(0, 0, 1, -3deg);
}
to {
-webkit-transform: scale3d(1, 1, 1);
transform: scale3d(1, 1, 1);
}
}
html {
box-sizing: border-box;
}
*,
*::before,
*::after {
box-sizing: inherit;
}
* {
margin: 0;
padding: 0;
}
img {
display: block;
max-width: 100%;
height: auto;
}
ul,
ol {
list-style: none;
}
.container {
width: 1200px;
margin: 0 auto;
}
.main-nav {
display: flex;
justify-content: space-between;
align-items: baseline;
margin-bottom: 128px;
}
.visually-hidden {
position: absolute;
white-space: nowrap;
width: 1px;
height: 1px;
overflow: hidden;
border: 0;
padding: 0;
clip: rect(0 0 0 0);
clip-path: inset(50%);
margin: -1px;
}
.logo {
font-family: 'Montserrat', 'Arial', sans-serif;
font-size: 30px;
animation: tada 1s linear 1 backwards;
}
.logo a {
font-family: 'Montserrat', 'Arial', sans-serif;
font-size: 30px;
color: rgb(149, 225, 211);
font-weight: 700;
line-height: 1.2;
text-decoration: none;
}
.site-navigation {
font-family: 'Montserrat', 'Arial', sans-serif;
font-size: 14px;
display: flex;
flex-wrap: wrap;
justify-content: space-between;
}
.site-navigation li {
margin-right: 60px;
}
.site-navigation li:last-child {
margin-right: 0;
}
.site-navigation-link {
color: rgb(149, 225, 211);
font-weight: 400;
text-transform: uppercase;
text-decoration: none;
line-height: 1.2;
position: relative;
transition: color 0.2s linear;
}
.site-navigation-link::after {
display: block;
position: absolute;
width: 0%;
height: 3px;
background-color: rgb(243, 129, 129);
content: "";
bottom: -10px;
transition: width 0.2s linear;
}
.site-navigation-link:hover,
.site-navigation-link:focus {
color: rgb(243, 129, 129);
}
.site-navigation-link:hover::after {
width: 100%;
}
.services {
margin-bottom: 91px;
}
.beggining-of-title {
display: block;
font-family: 'Kaushan Script', 'Arial', cursive;
font-size: 24px;
line-height: 1.2;
font-weight: 400;
margin-bottom: 19px;
color: rgb(51, 51, 51);
text-transform: none;
}
.section-title {
font-family: 'Montserrat', 'Arial', sans-serif;
font-size: 30px;
line-height: 1.2;
color: rgb(51, 51, 51);
font-weight: 700;
text-transform: uppercase;
margin-bottom: 107px;
text-align: center;
}
.services h2::after {
display: block;
width: 60px;
height: 3px;
background-color: #f38181;
content: "";
margin: 0 auto;
margin-top: 40px;
}
.services-list {
display: flex;
justify-content: space-around;
flex-wrap: wrap;
}
.services-list-item {
flex-basis: 362px;
padding-left: 62px;
margin-bottom: 98px;
position: relative;
background-repeat: no-repeat;
text-align: left;
}
.services-list-item:nth-last-child(-n + 3) {
margin-bottom: 0;
}
.services-list-item::before {
content: "";
display: block;
position: absolute;
top: 0;
left: 0;
width: 32px;
height: 100%;
}
.services-list-item-clock {
background-image: url("../img/icons/alarm.png");
}
.services-list-item-graph {
background-image: url("../img/icons/graph.png");
}
.services-list-item-computer {
background-image: url("../img/icons/computer.png");
}
.services-list-item-book {
background-image: url("../img/icons/book.png");
}
.services-list-item-home {
background-image: url("../img/icons/home.png");
}
.services-list-item-image {
background-image: url("../img/icons/image.png");
}
.services-list-item-title {
font-family: 'Montserrat', 'Arial', sans-serif;
font-size: 14px;
line-height: 1.2;
font-weight: 400;
color: rgb(51, 51, 51);
text-transform: uppercase;
margin-bottom: 17px;
}
.services-list-item-description {
font-family: 'Roboto', 'Arial', sans-serif;
font-size: 15px;
line-height: 24px;
font-weight: 400;
color: rgb(153, 153, 153);
}
.team h2::after {
display: block;
width: 60px;
height: 3px;
background-color: #f38181;
content: "";
margin: 0 auto;
margin-top: 40px;
}
.section-description {
font-family: 'Roboto', 'Arial', sans-serif;
font-size: 15px;
line-height: 24px;
font-weight: 400;
color: rgb(153, 153, 153);
margin-bottom: 90px;
text-align: center;
}
.team {
padding-bottom: 90px;
}
.team-list {
display: flex;
justify-content: space-between;
flex-wrap: wrap;
}
.pic-wrap {
position: relative;
margin-bottom: 29px;
}
.overlay {
background-image: linear-gradient(0deg, rgba(252, 227, 138, 0.9) 0%, rgba(243, 129, 129, 0.9) 100%);
width: 100%;
height: 100%;
position: absolute;
top: 0;
left: 0;
display: flex;
align-items: center;
justify-content: center;
visibility: hidden;
opacity: 0;
transition: opacity 0.2s linear, visibility 0.2s linear;
}
.team-list-item:hover .overlay {
opacity: 1;
visibility: visible;
}
.pic-wrap {
transition: transform 0.2s linear,
box-shadow 0.2s linear;
}
.team-list-item:hover .pic-wrap {
transform: translate(-10px, -10px);
box-shadow: 10px 10px rgb(149, 225, 211);
}
.social-list {
display: flex;
}
.social-list-item:not(:last-child) {
margin-right: 1px;
}
.social-list-item-link {
display: block;
width: 56px;
height: 56px;
background-color: #fce38a;
background-repeat: no-repeat;
background-position: center;
transition: background-color 0.2s linear;
}
.social-list-item-link:hover {
background-color: #95e1d3;
}
.social-list-item-link-facebook {
background-image: url("../img/icons/facebook.png");
}
.social-list-item-link-twitter {
background-image: url("../img/icons/twitter.png");
}
.social-list-item-link-pinterest {
background-image: url("../img/icons/pinterest.png");
}
.social-list-item-link-instagram {
background-image: url("../img/icons/instagram.png");
}
.man-name {
font-family: 'Montserrat', 'Arial', sans-serif;
font-size: 14px;
line-height: 1.2;
font-weight: 400;
color: rgb(51, 51, 51);
text-transform: uppercase;
margin-bottom: 9px;
text-align: center;
}
.profession {
font-family: 'Roboto', 'Arial', sans-serif;
font-size: 15px;
line-height: 24px;
font-weight: 300;
color: rgb(153, 153, 153);
text-align: center;
}
.page-caption {
font-family: 'Montserrat', 'Arial', sans-serif;
font-size: 14px;
line-height: 1.2;
font-weight: 400;
color: rgb(51, 51, 51);
}
.page-caption a {
color: rgb(243, 129, 129);
font-weight: 400;
text-decoration: none;
line-height: 1.2;
}
.footer-wrapper {
display: flex;
justify-content: space-between;
border-top: 1px solid rgb(229, 229, 229);
padding-top: 12px;
padding-bottom: 12px;
align-items: center;
}
.footer-form {
display: flex;
align-items: center;
}
input::placeholder {
font-family: 'Roboto', 'Arial', sans-serif;
font-size: 15px;
line-height: 24px;
font-weight: 300;
color: rgb(204, 204, 204);
font-style: italic;
}
.input {
width: 230px;
height: 40px;
border: 1px solid #e7e7e7;
background-color: #ffffff;
padding-left: 13px;
}
.subscribe {
text-transform: uppercase;
text-align: center;
font-family: 'Montserrat', 'Arial', sans-serif;
font-size: 14px;
line-height: 1.2;
font-weight: 700;
color: rgb(255, 255, 255);
border: none;
background-color: rgb(149, 225, 211);
width: 150px;
height: 40px;
} | 17.942396 | 102 | 0.644022 |
b6f759a300e081083972ebed636e98d4ba5fcbe8 | 545 | sql | SQL | Build/Drop(tSQLtAssemblyKey)(Pre2017).sql | rosen-group/tSQLt | ee89085bad9e39182af056bdf4c85cf616a19f3e | [
"Apache-2.0"
] | 337 | 2015-11-19T17:03:49.000Z | 2022-03-18T20:39:09.000Z | Build/Drop(tSQLtAssemblyKey)(Pre2017).sql | rosen-group/tSQLt | ee89085bad9e39182af056bdf4c85cf616a19f3e | [
"Apache-2.0"
] | 117 | 2016-02-25T12:58:47.000Z | 2022-03-25T06:11:42.000Z | Build/Drop(tSQLtAssemblyKey)(Pre2017).sql | rosen-group/tSQLt | ee89085bad9e39182af056bdf4c85cf616a19f3e | [
"Apache-2.0"
] | 108 | 2015-12-07T13:16:37.000Z | 2022-02-24T10:04:52.000Z | DECLARE @cmd NVARCHAR(MAX);
IF(CAST(PARSENAME(CAST(SERVERPROPERTY('ProductVersion') AS NVARCHAR(MAX)),4) AS INT)<14)
BEGIN
PRINT '-------Dropping tSQLtAssemblyKey---------------';
SET @cmd = N'IF SUSER_ID(''tSQLtAssemblyKey'') IS NOT NULL DROP LOGIN tSQLtAssemblyKey;';
EXEC master.sys.sp_executesql @cmd;
SET @cmd = N'IF ASYMKEY_ID(''tSQLtAssemblyKey'') IS NOT NULL DROP ASYMMETRIC KEY tSQLtAssemblyKey;';
EXEC master.sys.sp_executesql @cmd;
END;
ELSE
BEGIN
PRINT '-------Dropping of tSQLtAssemblyKey skipped---------------';
END;
| 36.333333 | 102 | 0.693578 |
0b5218f0be7a06f3e5bb1ddae6a9fce7c35741e8 | 11,880 | py | Python | hbruraldoctor/hbvirtual/lib/python3.7/site-packages/Naked/app.py | hallohubo/DjangoDocterAPI | 2d86d17c718affa968c0b2d4f9590aa08d43716e | [
"Apache-2.0"
] | 89 | 2015-04-10T14:34:05.000Z | 2021-11-08T09:17:09.000Z | hbruraldoctor/hbvirtual/lib/python3.7/site-packages/Naked/app.py | hallohubo/DjangoDocterAPI | 2d86d17c718affa968c0b2d4f9590aa08d43716e | [
"Apache-2.0"
] | 13 | 2015-03-17T15:44:41.000Z | 2020-11-19T03:07:13.000Z | hbruraldoctor/hbvirtual/lib/python3.7/site-packages/Naked/app.py | hallohubo/DjangoDocterAPI | 2d86d17c718affa968c0b2d4f9590aa08d43716e | [
"Apache-2.0"
] | 19 | 2015-05-13T09:18:12.000Z | 2021-04-28T10:35:39.000Z | #!/usr/bin/env python
# encoding: utf-8
#------------------------------------------------------------------------------
# Naked | A Python command line application framework
# Copyright 2014 Christopher Simpkins
# MIT License
#------------------------------------------------------------------------------
#------------------------------------------------------------------------------------
# c.cmd = Primary command (<executable> <primary command>)
# c.cmd2 = Secondary command (<executable> <primary command> <secondary command>)
#
# c.option(option_string, [bool argument_required]) = test for option with optional test for positional arg to the option
# c.option_with_arg(option_string) = test for option and mandatory positional argument to option test
# c.flag(flag_string) = test for presence of a "--option=argument" style flag
#
# c.arg(arg_string) = returns the next positional argument to the arg_string argument
# c.flag_arg(flag_string) = returns the flag assignment for a "--option=argument" style flag
#------------------------------------------------------------------------------------
# Application start
def main():
import sys
from Naked.commandline import Command
#from Naked.toolshed.state import StateObject
from Naked.toolshed.system import stderr
#------------------------------------------------------------------------------------------
# [ Instantiate command line object ]
# used for all subsequent conditional logic in the CLI application
#------------------------------------------------------------------------------------------
c = Command(sys.argv[0], sys.argv[1:])
#------------------------------------------------------------------------------
# [ Instantiate state object ]
#------------------------------------------------------------------------------
#state = StateObject()
#------------------------------------------------------------------------------------------
# [ Command Suite Validation ] - early validation of appropriate command syntax
# Test that user entered a primary command, print usage if not
#------------------------------------------------------------------------------------------
if not c.command_suite_validates():
from Naked.commands.usage import Usage
Usage().print_usage()
sys.exit(1)
#------------------------------------------------------------------------------------------
# [ PRIMARY COMMAND LOGIC ]
# Test for primary commands and handle them
#------------------------------------------------------------------------------------------
#------------------------------------------------------------------------------
# [ args ] - identify the parsed arguments for a command string (2)= help
#------------------------------------------------------------------------------
if c.cmd == "args":
if c.cmd2 == "help":
from Naked.commands.args import help as args_help
args_help()
elif c.argc > 0: # there is an argument to where that is not help
from Naked.commands.args import Args
a = Args(c.arg_to_cmd)
a.run()
else:
stderr("The args command requires an example command as an argument. Use 'naked args help' for more information.", 1)
#------------------------------------------------------------------------------
# [ build ] - build the C code in the Naked library (2)= help
#------------------------------------------------------------------------------
elif c.cmd == "build":
if c.cmd2 == "help":
from Naked.commands.build import help as build_help
build_help()
else:
from Naked.commands.build import compile_c_code
import os, inspect
abs_dirpath = os.path.join(os.path.dirname(os.path.abspath(inspect.getfile(inspect.currentframe()))), "toolshed", "c")
compile_c_code(abs_dirpath) # function calls exit status code
#------------------------------------------------------------------------------
# [ classify ] - search Python application classifiers and display to user (args)-search string
#------------------------------------------------------------------------------
elif c.cmd == "classify":
if c.cmd2 == "help":
from Naked.commands.classifier import help as classifier_help
classifier_help()
else:
if c.second: # if search string was given
search_string = c.second
else:
search_string = "" # absence of search string detected in Classifier, defaults to the entire list instead of search
from Naked.commands.classifier import Classifier
c = Classifier(search_string)
c.run()
#------------------------------------------------------------------------------
# [ dist ] - distribute source files to PyPI (2)=register, sdist, swheel, wheel, win, all, help
#------------------------------------------------------------------------------
elif c.cmd == "dist":
if c.argc > 1:
from Naked.commands.dist import Dist
d = Dist()
if c.cmd2 == "register": # python setup.py register
d.run('register')
elif c.cmd2 == "sdist": # python setup.py sdist upload
d.run('sdist')
elif c.cmd2 == "swheel": # python setup.py sdist bdist_wheel upload
d.run('swheel')
elif c.cmd2 == "wheel": # python setup.py bdist_wheel upload
d.run('wheel')
elif c.cmd2 == "win": # python setup.py bdist_wininst upload
d.run('win')
elif c.cmd2 == "all": # python setup.py sdist bdist_wheel bdist_wininst upload
d.run('all')
elif c.cmd2 == "help": # help for command
from Naked.commands.dist import help as dist_help
dist_help()
else:
stderr("The naked dist secondary command was not recognized. Use 'naked dist help' for more information.", 1)
else:
stderr("Please enter a secondary command", 1)
#------------------------------------------------------------------------------
# [ locate ] - locate Naked project files (2)= main, settings, setup, help
#------------------------------------------------------------------------------
elif c.cmd == "locate":
from Naked.commands.locate import Locator
if c.cmd2 == "help":
from Naked.commands.locate import help as locate_help
locate_help()
elif c.cmd2 == "main":
l = Locator('main')
elif c.cmd2 == "settings":
l = Locator('settings')
elif c.cmd2 == "setup":
l = Locator('setup')
else:
l = Locator('') #handles error report to user
#------------------------------------------------------------------------------
# [ make ] - make a new Naked project (2)=help (args)=project name
#------------------------------------------------------------------------------
elif c.cmd == "make":
from Naked.commands.make import MakeController
if c.cmd2 == "help":
from Naked.commands.make import help as make_help
make_help()
if c.arg1: # arg1 is not help so use it as the argument to the make command
m = MakeController(c.arg1)
else:
m = MakeController(None)
m.run()
#------------------------------------------------------------------------------
# [ profile ] - run the profiler.py file in the Naked project (2)=help
#------------------------------------------------------------------------------
elif c.cmd == "profile":
if c.cmd2 == "help":
from Naked.commands.profile import help as profile_help
profile_help()
else:
from Naked.commands.profile import Profiler
p = Profiler()
p.run()
#------------------------------------------------------------------------------
# [ pyh ] - help for python built-in library modules, classes, methods, functions
#------------------------------------------------------------------------------
elif c.cmd == "pyh":
if c.cmd2 == "help":
from Naked.commands.pyh import pyh_help
pyh_help()
else:
if c.argc > 1:
from Naked.commands.pyh import python_help
python_help(c.arg1)
else:
stderr("Please enter a query term with the pyh command. Use 'naked pyh help' for more information.", 1)
#------------------------------------------------------------------------------
# [ test ] - Run unit tests on the project (2)= help,nose,pytest,tox,unittest (see help for args)
#------------------------------------------------------------------------------
elif c.cmd == "test":
if c.argc > 1:
if c.cmd2 == "help":
from Naked.commands.test import help as tox_help
tox_help()
elif c.cmd2 == "nose":
from Naked.commands.test import NoseTester
n = NoseTester()
n.run()
elif c.cmd2 == "pytest":
from Naked.commands.test import PyTester
p = PyTester()
p.run()
elif c.cmd2 == "tox":
from Naked.commands.test import ToxTester
if c.arg2: #user specified a python version to run with one of the tox version defs
t = ToxTester(c.arg2) #instantiate with the python version
else:
t = ToxTester()
t.run()
elif c.cmd2 == "unittest":
from Naked.commands.test import UnitTester
if c.arg2:
t = UnitTester(c.arg2)
t.run()
else:
stderr("Please include a unit test file path. Use 'naked test help' for more information.", 1)
else:
stderr("The secondary command was not recognized. Use 'naked test help' for more information.", 1)
else:
stderr("Please include a secondary command with the 'naked test' command. Use 'naked dist help' for more information.", 1)
#------------------------------------------------------------------------------------------
# [ NAKED FRAMEWORK COMMANDS ]
# Naked framework provides default help, usage, and version commands for all applications
# --> settings for user messages are assigned in the lib/PROJECT/settings.py file
#------------------------------------------------------------------------------------------
elif c.help(): # User requested naked help (help.py module in commands directory)
from Naked.commands.help import Help
Help().print_help()
elif c.usage(): # user requested naked usage info (usage.py module in commands directory)
from Naked.commands.usage import Usage
Usage().print_usage()
elif c.version(): # user requested naked version (version.py module in commands directory)
from Naked.commands.version import Version
Version().print_version()
#------------------------------------------------------------------------------------------
# [ DEFAULT MESSAGE FOR MATCH FAILURE ]
# Message to provide to the user when all above conditional logic fails to meet a true condition
#------------------------------------------------------------------------------------------
else:
print("Could not complete the command that you entered. Please try again.")
sys.exit(1) #exit
if __name__ == '__main__':
main()
| 51.652174 | 135 | 0.448485 |
687897ce0e25ff25da34b8747740e441ee2cf1fe | 1,160 | swift | Swift | Splits/Pods/Stripe/Stripe/STPMandateDataParams.swift | spectivePer/Splits | 2d455e0a1f8f7656ec0fb9db5b8e664cb34f6698 | [
"MIT"
] | null | null | null | Splits/Pods/Stripe/Stripe/STPMandateDataParams.swift | spectivePer/Splits | 2d455e0a1f8f7656ec0fb9db5b8e664cb34f6698 | [
"MIT"
] | 1 | 2021-02-23T19:41:12.000Z | 2021-02-23T19:41:12.000Z | Splits/Pods/Stripe/Stripe/STPMandateDataParams.swift | spectivePer/Splits | 2d455e0a1f8f7656ec0fb9db5b8e664cb34f6698 | [
"MIT"
] | null | null | null | //
// STPMandateDataParams.swift
// Stripe
//
// Created by Cameron Sabol on 10/17/19.
// Copyright © 2019 Stripe, Inc. All rights reserved.
//
import Foundation
/// This object contains details about the Mandate to create. - seealso: https://stripe.com/docs/api/payment_intents/confirm#confirm_payment_intent-mandate_data
public class STPMandateDataParams: NSObject {
/// Details about the customer acceptance of the Mandate.
@objc public let customerAcceptance: STPMandateCustomerAcceptanceParams
@objc public var additionalAPIParameters: [AnyHashable: Any] = [:]
/// Initializes an STPMandateDataParams from an STPMandateCustomerAcceptanceParams.
@objc public init(customerAcceptance: STPMandateCustomerAcceptanceParams) {
self.customerAcceptance = customerAcceptance
super.init()
}
}
extension STPMandateDataParams: STPFormEncodable {
@objc
public class func propertyNamesToFormFieldNamesMapping() -> [String: String] {
return [
NSStringFromSelector(#selector(getter:customerAcceptance)): "customer_acceptance"
]
}
@objc
public class func rootObjectName() -> String? {
return "mandate_data"
}
}
| 29.74359 | 160 | 0.758621 |
816fc11d14815818b4814462998fbf2bb4fcd3b3 | 175 | kts | Kotlin | buildSrc/build.gradle.kts | cqse/teamscale-jacoco-agent | 9390983fc4eacacc0c331f51e75587e297de5a0e | [
"Apache-2.0"
] | 9 | 2018-10-29T06:44:27.000Z | 2022-02-07T13:20:44.000Z | buildSrc/build.gradle.kts | cqse/teamscale-jacoco-agent | 9390983fc4eacacc0c331f51e75587e297de5a0e | [
"Apache-2.0"
] | 106 | 2018-08-30T05:35:10.000Z | 2022-03-23T07:40:56.000Z | buildSrc/build.gradle.kts | cqse/teamscale-jacoco-agent | 9390983fc4eacacc0c331f51e75587e297de5a0e | [
"Apache-2.0"
] | 10 | 2019-04-04T05:46:23.000Z | 2022-03-02T07:58:42.000Z | plugins {
`kotlin-dsl`
}
repositories {
gradlePluginPortal()
}
dependencies {
implementation("gradle.plugin.com.github.jengelman.gradle.plugins:shadow:7.0.0")
}
| 14.583333 | 84 | 0.708571 |
a72ce14be89a3fb783f755e2de61fdc3e86ced30 | 2,095 | sql | SQL | doc/topic_cate.sql | CocoaSY/PHP_Industry | 5e0797cf93d0398ab92f0808b1d1a2b9a69141f7 | [
"BSD-2-Clause"
] | null | null | null | doc/topic_cate.sql | CocoaSY/PHP_Industry | 5e0797cf93d0398ab92f0808b1d1a2b9a69141f7 | [
"BSD-2-Clause"
] | null | null | null | doc/topic_cate.sql | CocoaSY/PHP_Industry | 5e0797cf93d0398ab92f0808b1d1a2b9a69141f7 | [
"BSD-2-Clause"
] | null | null | null | -- phpMyAdmin SQL Dump
-- version 4.5.2
-- http://www.phpmyadmin.net
--
-- Host: localhost
-- Generation Time: 2016-10-31 10:26:44
-- 服务器版本: 10.1.16-MariaDB
-- PHP Version: 5.5.38
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+00:00";
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8mb4 */;
--
-- Database: `z_Industry`
--
-- --------------------------------------------------------
--
-- 表的结构 `z_topic_cate`
--
DROP TABLE IF EXISTS `z_topic_cate`;
CREATE TABLE `z_topic_cate` (
`cid` int(11) NOT NULL COMMENT '话题分类ID',
`name` varchar(30) NOT NULL COMMENT '分类名称',
`ename` varchar(30) NOT NULL COMMENT '分类英文名称',
`pic` varchar(200) NOT NULL COMMENT '缩略图原图',
`pic50` varchar(200) NOT NULL COMMENT '缩略图50x50',
`pic100` varchar(200) NOT NULL COMMENT '缩略图100x100',
`pic200` varchar(200) NOT NULL COMMENT '缩略图200x200',
`description` text NOT NULL COMMENT '分类描述'
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
--
-- 转存表中的数据 `z_topic_cate`
--
INSERT INTO `z_topic_cate` (`t_id`, `name`, `ename`, `pic`, `pic50`, `pic100`, `pic200`, `description`) VALUES
(1, '求助交流', 'help', '', '', '', '', ''),
(2, '技术分享', 'share', '', '', '', '', ''),
(3, '网站模板', 'template', '', '', '', '', ''),
(4, '网站源码', 'code', '', '', '', '', ''),
(5, '项目合作', 'working', '', '', '', '', ''),
(6, '招聘求职', 'job', '', '', '', '', ''),
(7, '其他', 'other', '', '', '', '', ''),
(8, '新手模块', 'new', '', '', '', '', '');
--
-- Indexes for dumped tables
--
--
-- Indexes for table `z_topic_cate`
--
ALTER TABLE `z_topic_cate`
ADD PRIMARY KEY (`t_id`);
--
-- 在导出的表使用AUTO_INCREMENT
--
--
-- 使用表AUTO_INCREMENT `z_topic_cate`
--
ALTER TABLE `z_topic_cate`
MODIFY `t_id` int(11) NOT NULL AUTO_INCREMENT COMMENT '话题分类ID', AUTO_INCREMENT=11;
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
| 27.207792 | 110 | 0.61432 |
6b76b3442c106433ddc0e8936e93955818eb5e92 | 11,661 | h | C | DirectMLSuperResolution/Samples/ML/DirectMLSuperResolution/DirectMLSuperResolution.h | bhouse-microsoft/DirectML-Samples | 4a0f7225d9afe7bb1cbd5e2c2ba3f83086ad093c | [
"MIT"
] | 3 | 2019-11-04T19:37:44.000Z | 2021-11-17T11:10:27.000Z | DirectMLSuperResolution/Samples/ML/DirectMLSuperResolution/DirectMLSuperResolution.h | pmbrown1055/DirectML-Samples | 4a0f7225d9afe7bb1cbd5e2c2ba3f83086ad093c | [
"MIT"
] | null | null | null | DirectMLSuperResolution/Samples/ML/DirectMLSuperResolution/DirectMLSuperResolution.h | pmbrown1055/DirectML-Samples | 4a0f7225d9afe7bb1cbd5e2c2ba3f83086ad093c | [
"MIT"
] | null | null | null | //--------------------------------------------------------------------------------------
// DirectMLSuperResolution.h
//
// Advanced Technology Group (ATG)
// Copyright (C) Microsoft Corporation. Copyright (C) NVIDIA Corporation. All rights reserved.
// Licensed under the MIT License.
//--------------------------------------------------------------------------------------
#pragma once
#include "DeviceResources.h"
#include "StepTimer.h"
#include "LoadWeights.h"
#include "MediaEnginePlayer.h"
class SmoothedFPS
{
public:
SmoothedFPS(float secondsInterval = 1.f)
{
Initialize(secondsInterval);
}
void Initialize(float secondsInterval = 1.f)
{
m_secondsInterval = secondsInterval;
m_timeAccumulator = 0.0f;
m_frameAccumulator = 0;
m_smoothedFPS = 0.0f;
}
void Tick(float DeltaTime)
{
m_timeAccumulator += DeltaTime;
++m_frameAccumulator;
if (m_timeAccumulator >= m_secondsInterval)
{
m_smoothedFPS = (float)m_frameAccumulator / m_timeAccumulator;
m_timeAccumulator = 0.0f;
m_frameAccumulator = 0;
}
}
float GetFPS() const { return m_smoothedFPS; }
private:
float m_smoothedFPS;
float m_timeAccumulator;
uint32_t m_frameAccumulator;
float m_secondsInterval;
};
enum class TensorLayout
{
Default,
NHWC
};
// A basic sample implementation that creates a D3D12 device and
// provides a render loop.
class Sample : public DX::IDeviceNotify
{
public:
Sample() noexcept(false);
~Sample();
// Initialization and management
void Initialize(HWND window, int width, int height);
// Basic render loop
void Tick();
// IDeviceNotify
virtual void OnDeviceLost() override;
virtual void OnDeviceRestored() override;
// Messages
void OnActivated();
void OnDeactivated();
void OnSuspending();
void OnResuming();
void OnWindowMoved();
void OnWindowSizeChanged(int width, int height);
// Properties
void GetDefaultSize( int& width, int& height ) const;
private:
void Update(DX::StepTimer const& timer);
void Render();
void UpdateZoomVertexBuffer();
void Clear();
void CreateDeviceDependentResources();
void CreateTextureResources();
void CreateDirectMLResources();
void InitializeDirectMLResources();
void CreateUIResources();
void CreateUpsampleLayer(
_In_reads_(4) const uint32_t* inputSizes,
_Inout_updates_(1) uint64_t* inputBufferRequiredSize,
_Inout_updates_(1) uint64_t* outputBufferRequiredSize,
_Out_writes_(4) uint32_t* outputSizesOut,
_Out_writes_(1) IDMLCompiledOperator** compiledOpOut);
void CreateConvolutionLayer(
_In_reads_(4) const uint32_t* inputSizes,
_In_reads_(4) const uint32_t* filterSizes,
bool useBiasAndActivation,
_Inout_updates_(1) uint64_t* inputBufferRequiredSize,
_Inout_updates_(1) uint64_t* outputBufferRequiredSize,
_Out_writes_(4) uint32_t* outputSizesOut,
_Out_writes_(1) IDMLCompiledOperator** compiledOpOut);
void CreateAdditionLayer(
_In_reads_(4) const uint32_t* inputSizes,
_Out_writes_(1) IDMLCompiledOperator** compiledOpOut);
void CreateWeightTensors(
WeightMapType& weights,
const char* convLayerName,
const char* scaleLayerName,
const char* shiftLayerName,
_In_reads_(4) const uint32_t* filterSizes,
DirectX::ResourceUploadBatch& uploadBatch,
_Out_writes_(1) ID3D12Resource** filterWeightResourceOut,
_Out_writes_opt_(1) ID3D12Resource** biasWeightResourceOut);
void CreateWeightResource(
_In_reads_(4) const uint32_t* tensorSizes,
_Out_writes_(1) ID3D12Resource** d3dResourceOut);
void BindTempResourceIfNeeded(
DML_BINDING_PROPERTIES& bindingProps,
_In_reads_(1) IDMLBindingTable* initBindingTable,
_Out_writes_opt_(1) ID3D12Resource** tempResource);
void CreateWindowSizeDependentResources();
// Device resources
std::unique_ptr<DX::DeviceResources> m_deviceResources;
// Rendering loop timer
DX::StepTimer m_timer;
// Input devices
std::unique_ptr<DirectX::GamePad> m_gamePad;
std::unique_ptr<DirectX::Keyboard> m_keyboard;
DirectX::GamePad::ButtonStateTracker m_gamePadButtons;
DirectX::Keyboard::KeyboardStateTracker m_keyboardButtons;
bool m_ctrlConnected;
// DirectXTK objects
std::unique_ptr<DirectX::GraphicsMemory> m_graphicsMemory;
std::unique_ptr<DirectX::DescriptorHeap> m_SRVDescriptorHeap;
std::unique_ptr<DirectX::DescriptorHeap> m_RTVDescriptorHeap;
// UI
SmoothedFPS m_fps;
std::unique_ptr<DirectX::BasicEffect> m_lineEffect;
std::unique_ptr<DirectX::PrimitiveBatch<DirectX::VertexPositionColor>> m_lineBatch;
std::unique_ptr<DirectX::DescriptorHeap> m_fontDescriptorHeap;
std::unique_ptr<DirectX::SpriteBatch> m_spriteBatch;
std::unique_ptr<DirectX::SpriteFont> m_labelFont;
std::unique_ptr<DirectX::SpriteFont> m_labelFontBold;
std::unique_ptr<DirectX::SpriteFont> m_legendFont;
std::unique_ptr<DirectX::SpriteFont> m_ctrlFont;
// Video player
std::unique_ptr<MediaEnginePlayer> m_player;
HANDLE m_sharedVideoTexture;
// Direct3D 12 objects for rendering texture to screen
Microsoft::WRL::ComPtr<ID3D12RootSignature> m_texRootSignatureNN; // Nearest-neighbor texture upscale
Microsoft::WRL::ComPtr<ID3D12PipelineState> m_texPipelineStateNN;
Microsoft::WRL::ComPtr<ID3D12RootSignature> m_texRootSignatureLinear; // Bilinear texture upscale
Microsoft::WRL::ComPtr<ID3D12PipelineState> m_texPipelineStateLinear;
Microsoft::WRL::ComPtr<ID3D12RootSignature> m_tensorRenderRootSignature; // Render from DML tensor format to texture
Microsoft::WRL::ComPtr<ID3D12PipelineState> m_tensorRenderPipelineState;
Microsoft::WRL::ComPtr<ID3D12Resource> m_texture; // Static input texture to render, if USE_VIDEO == 0
Microsoft::WRL::ComPtr<ID3D12Resource> m_videoTexture; // Input video frame to render, if USE_VIDEO == 1
Microsoft::WRL::ComPtr<ID3D12Resource> m_finalResultTexture; // Upscaled 4K texture output
uint32_t m_origTextureHeight;
uint32_t m_origTextureWidth;
Microsoft::WRL::ComPtr<ID3D12Resource> m_vertexBuffer;
Microsoft::WRL::ComPtr<ID3D12Resource> m_indexBuffer;
D3D12_VERTEX_BUFFER_VIEW m_vertexBufferView;
D3D12_INDEX_BUFFER_VIEW m_indexBufferView;
// Additional D3D12 objects for rendering zoomed picture-in-picture window
DirectX::SharedGraphicsResource m_zoomedVertexHeap;
D3D12_VERTEX_BUFFER_VIEW m_zoomedVertexBufferView;
// Compute objects for converting texture to DML tensor format
Microsoft::WRL::ComPtr<ID3D12PipelineState> m_computePSO;
Microsoft::WRL::ComPtr<ID3D12RootSignature> m_computeRootSignature;
// DirectML objects
Microsoft::WRL::ComPtr<IDMLDevice> m_dmlDevice;
Microsoft::WRL::ComPtr<IDMLCommandRecorder> m_dmlCommandRecorder;
TensorLayout m_tensorLayout;
// Model layer sizes and indices
static const size_t c_numUpsampleLayers = 2;
static const size_t c_numConvLayers = 7;
static const size_t c_numIntermediateBuffers = 2;
enum OpTypes : uint32_t
{
e_opUpsample,
e_opConv,
e_opAdd,
e_opCount
};
// Resources for DirectML
std::unique_ptr<DirectX::DescriptorHeap> m_dmlDescriptorHeap;
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelInput;
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelOutput;
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelIntermediateResult[c_numIntermediateBuffers];
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelConvFilterWeights[c_numConvLayers];
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelConvBiasWeights[c_numConvLayers];
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelUpsamplePersistentResources[c_numUpsampleLayers];
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelConvPersistentResources[c_numConvLayers];
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelAddPersistentResource;
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelInitTemporaryResources[e_opCount];
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelUpsampleTemporaryResources[c_numUpsampleLayers];
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelConvTemporaryResources[c_numConvLayers];
Microsoft::WRL::ComPtr<ID3D12Resource> m_modelAddTemporaryResource;
// DirectML operations
Microsoft::WRL::ComPtr<IDMLCompiledOperator> m_dmlUpsampleOps[c_numUpsampleLayers];
Microsoft::WRL::ComPtr<IDMLBindingTable> m_dmlUpsampleBindings[c_numUpsampleLayers];
Microsoft::WRL::ComPtr<IDMLCompiledOperator> m_dmlConvOps[c_numConvLayers];
Microsoft::WRL::ComPtr<IDMLBindingTable> m_dmlConvBindings[c_numConvLayers];
Microsoft::WRL::ComPtr<IDMLCompiledOperator> m_dmlAddResidualOp;
Microsoft::WRL::ComPtr<IDMLBindingTable> m_dmlAddResidualBinding;
Microsoft::WRL::ComPtr<IDMLOperatorInitializer> m_dmlOpInitializers[e_opCount];
// Application state
bool m_useDml;
bool m_showPip;
float m_zoomX;
float m_zoomY;
float m_zoomWindowSize;
bool m_zoomUpdated;
const float c_minZoom = 0.005f;
const float c_maxZoom = 0.05f;
// DirectX index enums
enum SrvDescriptors : uint32_t
{
e_descTexture,
e_descModelInput,
e_descModelOutput,
e_descFinalResultTextureSrv,
e_srvDescCount
};
enum RtvDescriptors : uint32_t
{
e_descFinalResultTextureRtv,
e_rtvDescCount
};
enum FontDescriptors : uint32_t
{
e_descLabelFont,
e_descLabelFontBold,
e_descLegendFont,
e_descCtrlFont,
e_fontDescCount,
};
enum ComputeRootParameters : uint32_t
{
e_crpIdxCB = 0,
e_crpIdxSRV,
e_crpIdxUAV,
e_crpIdxCount
};
enum TensorRenderRootParameters : uint32_t
{
e_rrpIdxCB = 0,
e_rrpIdxSRV,
e_rrpIdxCount
};
}; | 39.262626 | 137 | 0.620187 |
bcc62c995bd114fd94e327e8f1ea8ec468c81612 | 354 | js | JavaScript | packages/rax-textinput/demo/miniapp/pages/index.js | zj1024/rax-components | bf48957fa84708e35606726c256100aadf2f9657 | [
"BSD-3-Clause"
] | 7 | 2020-03-05T09:14:30.000Z | 2020-03-05T09:56:31.000Z | packages/rax-textinput/demo/miniapp/pages/index.js | zj1024/rax-components | bf48957fa84708e35606726c256100aadf2f9657 | [
"BSD-3-Clause"
] | null | null | null | packages/rax-textinput/demo/miniapp/pages/index.js | zj1024/rax-components | bf48957fa84708e35606726c256100aadf2f9657 | [
"BSD-3-Clause"
] | 4 | 2020-03-05T09:14:52.000Z | 2020-03-05T09:56:35.000Z | Page({
data: {
text: '',
},
onChange(e) {
this.setData({
text: `onChange: ${e.detail.value}`
});
},
onChangeText(text) {
this.setData({
text: `onChangeText: ${text}`
});
},
onBlur() {
this.setData({
text: 'onBlur'
});
},
onFocus() {
this.setData({
text: 'onFocus'
});
}
});
| 13.615385 | 41 | 0.449153 |
8bc9335314f53189b897a98d750ad9be89b4c678 | 386 | kt | Kotlin | Android_simpleViewModel_kotlin_morexml/app/src/main/java/com/carpa/android_simpleviewmodel_kotlin_morexml/display_name/DisplayNameViewModel.kt | lolloz98/Android_ViewModel | bf268ea4a0ecdc92f4231f09c6562fa0017bb4b0 | [
"MIT"
] | null | null | null | Android_simpleViewModel_kotlin_morexml/app/src/main/java/com/carpa/android_simpleviewmodel_kotlin_morexml/display_name/DisplayNameViewModel.kt | lolloz98/Android_ViewModel | bf268ea4a0ecdc92f4231f09c6562fa0017bb4b0 | [
"MIT"
] | null | null | null | Android_simpleViewModel_kotlin_morexml/app/src/main/java/com/carpa/android_simpleviewmodel_kotlin_morexml/display_name/DisplayNameViewModel.kt | lolloz98/Android_ViewModel | bf268ea4a0ecdc92f4231f09c6562fa0017bb4b0 | [
"MIT"
] | null | null | null | package com.carpa.android_simpleviewmodel_kotlin_morexml.display_name
import androidx.lifecycle.LiveData
import androidx.lifecycle.MutableLiveData
import androidx.lifecycle.ViewModel
class DisplayNameViewModel(name: String): ViewModel() {
private val _name = MutableLiveData<String>()
val name: LiveData<String>
get() = _name
init{
_name.value = name
}
} | 24.125 | 69 | 0.759067 |
652e84bd8ad0187eda337ba399fb9e1a9cdb03eb | 377 | py | Python | setup.py | PaulDodd/pynomial | 8da81bf37ee96b8e3c49b40cdfcae075ba667632 | [
"Apache-2.0"
] | null | null | null | setup.py | PaulDodd/pynomial | 8da81bf37ee96b8e3c49b40cdfcae075ba667632 | [
"Apache-2.0"
] | null | null | null | setup.py | PaulDodd/pynomial | 8da81bf37ee96b8e3c49b40cdfcae075ba667632 | [
"Apache-2.0"
] | null | null | null | import sys
from setuptools import setup, find_packages
setup(
name='pynomial',
version='0.0.0',
packages=find_packages(),
author='Paul M Dodd',
author_email='pdodd@umich.edu',
description="python package for combinatorial problems",
url="https://github.com/PaulDodd/pynomial.git",
install_requires=[], # install_requires or something else?
)
| 26.928571 | 64 | 0.70557 |
0b0cd02cfa91edb20bb99ffeb3ec3643c5ad48e8 | 5,543 | swift | Swift | relex_swift/lib/WLVideoPlayer/WLPlayerHandler.swift | Darren-chenchen/leilemo_swift | 67da746021639373188ff7e84c17fd9b5152cc43 | [
"Apache-2.0"
] | 8 | 2017-05-02T01:13:57.000Z | 2021-12-05T03:48:16.000Z | relex_swift/lib/WLVideoPlayer/WLPlayerHandler.swift | Darren-chenchen/leilemo_swift | 67da746021639373188ff7e84c17fd9b5152cc43 | [
"Apache-2.0"
] | null | null | null | relex_swift/lib/WLVideoPlayer/WLPlayerHandler.swift | Darren-chenchen/leilemo_swift | 67da746021639373188ff7e84c17fd9b5152cc43 | [
"Apache-2.0"
] | null | null | null | //
// WLPlayerHandler.swift
// WLVideoPlayer(MP)
//
// Created by wl on 16/2/25.
// Copyright © 2016年 wl. All rights reserved.
// 处理用户自定义控制面板逻辑的对象
/***************************************************
* 如果您发现任何BUG,或者有更好的建议或者意见,欢迎您的指出。
*邮箱:wxl19950606@163.com.感谢您的支持
***************************************************/
import UIKit
import MediaPlayer
class WLPlayerHandler: NSObject {
weak var player: MPMoviePlayerController!
weak var customControlView: WLBasePlayerControlView!
var customControlViewAutoHiddenInterval: TimeInterval = 3
/// customControlViewAutoHiddenInterval秒调用一次,用来隐藏自定义控制面板
fileprivate var autoHiddenTimer: Timer?
override init() {
super.init()
NotificationCenter.default.addObserver(self, selector: #selector(WLPlayerHandler.customControlViewStateDidChange), name: NSNotification.Name(rawValue: WLPlayerCustomControlViewStateDidChangeNotification), object: nil)
NotificationCenter.default.addObserver(self, selector: #selector(WLPlayerHandler.playerDidExitFullscreen), name: NSNotification.Name(rawValue: WLPlayerDidExitFullscreenNotification), object: nil)
NotificationCenter.default.addObserver(self, selector: #selector(WLPlayerHandler.playerDidEnterFullscreen), name: NSNotification.Name(rawValue: WLPlayerDidEnterFullscreenNotification), object: nil)
}
deinit {
// print("WLPlayerHandler===deinit")
}
/**
自定义控制面板显示的时候变会调用,
用来添加一个定时器,为了在适合的时候隐藏控制面板
*/
fileprivate func addAutoHiddenTimer() {
removeAutoHiddenTimer()
let timer = Timer(timeInterval: customControlViewAutoHiddenInterval, target: self, selector: #selector(WLPlayerHandler.hiddenCustomControlView), userInfo: nil, repeats: false)
RunLoop.main.add(timer, forMode: RunLoopMode.commonModes)
autoHiddenTimer = timer
}
fileprivate func removeAutoHiddenTimer() {
autoHiddenTimer?.invalidate()
autoHiddenTimer = nil
}
/**
更新自定义控制面板的进度条以及时间
*/
func updateProgress(_ playerControlView: WLBasePlayerControlView) {
playerControlView.updateProgress(player.currentPlaybackTime, duration: player.duration, playableDuration: player.playableDuration)
}
// MARK: - 回调方法
/**
定时器回调方法,自定义控制面板显示且customControlViewAutoHiddenInterval秒对其没有操作时候调用
用来隐藏自定义视频控制面板
*/
func hiddenCustomControlView() {
customControlView.setVirtualHidden(true)
removeAutoHiddenTimer()
}
/**
当自定义控制面板上发生任何交互事件被调用,
重置自动隐藏面板的定时器
*/
func customControlViewStateDidChange() {
removeAutoHiddenTimer()
addAutoHiddenTimer()
}
func playerDidExitFullscreen() {
customControlView.getEnterFullscreenBtn()?.isSelected = false
addAutoHiddenTimer()
}
func playerDidEnterFullscreen() {
customControlView.getEnterFullscreenBtn()?.isSelected = true
addAutoHiddenTimer()
}
}
// MARK: - WLPlayerControlViewDelegate代理
extension WLPlayerHandler: WLPlayerControlViewDelegate {
/**
WLBasePlayerControlView的代理方法,
当点击视频控制View的空白处调用
主要是用来显示\隐藏视频控制View
*/
func didClikOnPlayerControlView(_ playerControlView: WLBasePlayerControlView) {
playerControlView.setVirtualHidden()
addAutoHiddenTimer()
}
/**
WLBasePlayerControlView的代理方法,
当点击暂停/播放的时候调用
用来暂停/播放视频
- parameter playerControlView: 用户自定义的那个控制面板
- parameter pauseBtn: 暂停/播放按钮
*/
func playerControlView(_ playerControlView: WLBasePlayerControlView, pauseBtnDidClik pauseBtn: UIButton) {
assert(player != nil, "player is nil")
if pauseBtn.isSelected { //暂停==>播放
player.play()
}else {
player.pause()
}
pauseBtn.isSelected = !pauseBtn.isSelected
addAutoHiddenTimer()
}
/**
WLBasePlayerControlView的代理方法,
当点击进入/退出全屏的时候调用
用来进入/退出全屏
- parameter playerControlView: 用户自定义的那个控制面板
- parameter pauseBtn: 全屏/退出全屏按钮
*/
func playerControlView(_ playerControlView: WLBasePlayerControlView, enterFullScreenBtnDidClik enterFullScreenBtn: UIButton) {
assert(player != nil, "player is nil")
if enterFullScreenBtn.isSelected { //全屏==>退出全屏
NotificationCenter.default.post(name: Notification.Name(rawValue: WLPlayerWillExitFullscreenNotification), object: nil)
}else {
NotificationCenter.default.post(name: Notification.Name(rawValue: WLPlayerWillEnterFullscreenNotification), object: nil)
}
enterFullScreenBtn.isSelected = !enterFullScreenBtn.isSelected
addAutoHiddenTimer()
}
/**
WLBasePlayerControlView的代理方法,
当playerControlView开始滑动的时候调用
*/
func beganSlideOnPlayerControlView(_ playerControlView: WLBasePlayerControlView) {
assert(player != nil, "player is nil")
player.pause()
removeAutoHiddenTimer()
}
/**
WLBasePlayerControlView的代理方法,
当playerControlView滑动结束的时候调用
设置视频播放的时间
- parameter playerControlView: 视频新的播放时间
*/
func playerControlView(_ playerControlView: WLBasePlayerControlView, endedSlide currentTime: TimeInterval) {
assert(player != nil, "player is nil")
player.currentPlaybackTime = currentTime
player.play()
addAutoHiddenTimer()
}
}
// 版权属于原作者
// http://code4app.com (cn) http://code4app.net (en)
// 发布代码于最专业的源码分享网站: Code4App.com
| 33.593939 | 225 | 0.68158 |
12caaacdbad73ab41edb482c962ecbbe360e0eec | 4,342 | html | HTML | characterization/references/rfc50.html | grigory-rechistov/rfc2html | 08a06c9836f33e20be7998c53c69c7d69924b141 | [
"BSD-3-Clause"
] | null | null | null | characterization/references/rfc50.html | grigory-rechistov/rfc2html | 08a06c9836f33e20be7998c53c69c7d69924b141 | [
"BSD-3-Clause"
] | null | null | null | characterization/references/rfc50.html | grigory-rechistov/rfc2html | 08a06c9836f33e20be7998c53c69c7d69924b141 | [
"BSD-3-Clause"
] | null | null | null | <pre> E. Harslen
J. Heafner
Network Working Group RANL
Request for Comments: 50 4/30/70
Comments on the Meyer Proposal
------------------------------
We find the Meyer proposal (Note #46) to be the most acceptable
to dare, for exactly the reasons that he enumerates; viz., simple,
suffices for most planned uses of the Network, easy to implement,
can be extended. It does not encompass everything that has been
suggested recently, however, we do agree with the items that are
proposed and we feel that the missing features are probably not
worth doing battle over and thus delaying the specification.
We make the following comments on the seven issues rasied in
Note #47.
1) We agree with Steve that dynamic reconnection will later
be required for more sophisticated uses of the Network.
We also agree with the Project MAC people that it
unnecessary initially. A better job can be done of dynamic
reconnection given some Network experience and the specific
needs of its use.
2) INT is easy to implement and serves a useful purpose.
3) We favor including a sub-field for instance tag identifier.
We see the need for both cases; a) where multiple processes
should appear indistinguishable, and b) where a given
user owning multiple processes must distinguish among
them. Those program parts that should not distinguish
among processes should simply ignore the instance tag.
Tom's suggestion to use part of the user number sub-field
merely reduces the combined length of sub-fields from 32
bits to 24 bits; the problem remains.
4) We disagree with both Steve and MAC in that no special
structure should be imposed on the data transmitted. We
prefer the "message data type" mentioned by E. I. Ancona,
Note #42, page 1. An example of its use was cited in
Note #39, page 2, transmit vs broadcast.
<span class="grey"> [Page 1]</span></pre>
<hr class='noprint'/><!--NewPage--><pre class='newpage'><span id="page-2" ></span>
<span class="grey"> With regard to a standard character set, we strongly</span>
support adopting one in the beginning, and in particular
ASCII. We have observed that most sites have previously
suggested ASCII. Is there anyone who objects?
5) Word boundary alignment is more attractive than double
padding.
6) Steve's suggestion of short-term queueing of RFCs is
acceptable as an option.
7) We support the UCC in Note #46 for three principle reasons:
a) In general the user should not know the remote socket
code of the process to whom he wishes to communicate.
b) The additional duplex connection can provide some
superfisory control over process behavior, possibly
in conjunction with the interrupt procedure.
c) Most of the other proposed methods demand queueing.
We think there must be a standard UCC, yet we encourage
parallel experimental UCCs.
We make two additional comments on Note #46 that were not reiterated
in Note #47.
BLK and RSM are more straightforward than previous suggestions and
they do not deny multiplexing over a given link. With regard to
the use of links, we refer to an example given by Bob Kahn where
an intermediate IMP goes down and eats some's RFNM. This
should not necessitate reconnection.
In Note #46, page 6, the statement that the UCC has the ability
to close connections to a dead process is installation dependent.
In our particular case the NCP is notified directly of process
failure due to the particular software interface through which all
processea, including NCP, must communicate.
JFH:hs
[ This RFC was put into machine readable form for entry ]
[ into the online RFC archives by Gary Okada 7/97 ]
[Page 2]
</pre> | 40.962264 | 105 | 0.650392 |
8f3d2133b9a3893fdf34d3fcdfa21d4af7de557b | 3,594 | kt | Kotlin | src/main/kotlin/org/ileasile/kformat/Color.kt | ileasile/kformat | 58fb611d39e0b496437e62a46fc4d0d41f745972 | [
"MIT"
] | 1 | 2020-05-01T01:41:26.000Z | 2020-05-01T01:41:26.000Z | src/main/kotlin/org/ileasile/kformat/Color.kt | ileasile/kformat | 58fb611d39e0b496437e62a46fc4d0d41f745972 | [
"MIT"
] | null | null | null | src/main/kotlin/org/ileasile/kformat/Color.kt | ileasile/kformat | 58fb611d39e0b496437e62a46fc4d0d41f745972 | [
"MIT"
] | null | null | null | package org.ileasile.kformat
import java.lang.IllegalArgumentException
import java.lang.IllegalStateException
import kotlin.math.roundToInt
interface Color {
val fgCode: Int?
get() = null
val bgCode: Int?
get() = null
val extCode: Int?
get() = null
val rgb: RGB8?
get() = null
fun encodeFg(): String {
val simple = fgCode
if (simple != null)
return simple.toString()
val ext = extCode
if (ext != null)
return "38;5;$ext"
val (r, g, b) = rgb ?: throw IllegalStateException("Wrong color definition")
return "38;2;$r;$g;$b"
}
fun encodeBg(): String {
val simple = bgCode
if (simple != null)
return simple.toString()
val ext = extCode
if (ext != null)
return "48;5;$ext"
val (r, g, b) = rgb ?: throw IllegalStateException("Wrong color definition")
return "48;2;$r;$g;$b"
}
}
interface RgbAwareColor : Color {
override val rgb: RGB8
}
interface AnsiAwareColor : Color {
val ansiInfo: AnsiColorInfo
}
data class AnsiColorInfo(
val color: BasicColor,
val isBright: Boolean = false
)
interface ColorConverter <T> {
fun convertAnsi(ansiAwareColor: AnsiAwareColor): T
fun convertRgb(rgbAwareColor: RgbAwareColor): T
fun convert(color: Color): T {
return when (color) {
is AnsiAwareColor -> convertAnsi(color)
is RgbAwareColor -> convertRgb(color)
else -> {
val names = listOf(
AnsiAwareColor::class,
RgbAwareColor::class
).joinToString { it.qualifiedName!! }
throw IllegalArgumentException("Color should implement one of the following interfaces: $names.")
}
}
}
}
enum class BasicColor(val code: Int) : AnsiAwareColor {
Black(0),
Red(1),
Green(2),
Yellow(3),
Blue(4),
Magenta(5),
Cyan(6),
White(7);
override val fgCode: Int
get() = code + 30
override val bgCode: Int
get() = code + 40
override val extCode: Int
get() = code
val htmlName: String
get() = name.toLowerCase()
override val ansiInfo: AnsiColorInfo
get() = AnsiColorInfo(this)
}
inline class BrightColor(
private val baseColor: BasicColor
) : AnsiAwareColor {
override val ansiInfo: AnsiColorInfo
get() = AnsiColorInfo(baseColor, true)
override val fgCode: Int
get() = baseColor.code + 90
override val bgCode: Int
get() = baseColor.code + 100
override val extCode: Int
get() = baseColor.code + 8
}
data class RGB6Color(
val red: Int,
val green: Int,
val blue: Int
) : RgbAwareColor {
override val extCode: Int?
get() = 16 + 36 * red + 6 * green + blue
override val rgb: RGB8
get() = RGB8(red * RGB6_TO_RGB8, green * RGB6_TO_RGB8, blue * RGB6_TO_RGB8)
companion object {
const val RGB6_TO_RGB8 = 255 / 5
}
}
data class GrayShadeColor(val level: Double) : RgbAwareColor {
override val extCode: Int?
get() = 232 + (level * 24).roundToInt()
override val rgb: RGB8
get() {
val intLevel = (level * 255).roundToInt()
return RGB8(intLevel, intLevel, intLevel)
}
}
inline class RGBColor(
override val rgb: RGB8
) : RgbAwareColor {
constructor(red: Int, green: Int, blue: Int) : this(RGB8(red, green, blue))
}
data class RGB8(
val r: Int,
val g: Int,
val b: Int
)
| 23.801325 | 113 | 0.585142 |
d1eb17467223d62ad237f2da229ad733dcd159ce | 11,289 | rs | Rust | azure_sdk_storage_blob/src/blob/requests/delete_blob_builder.rs | maxburke/AzureSDKForRust | 02022344b7c37cdb713b69d60f9c86fc7295f64c | [
"Apache-2.0"
] | null | null | null | azure_sdk_storage_blob/src/blob/requests/delete_blob_builder.rs | maxburke/AzureSDKForRust | 02022344b7c37cdb713b69d60f9c86fc7295f64c | [
"Apache-2.0"
] | null | null | null | azure_sdk_storage_blob/src/blob/requests/delete_blob_builder.rs | maxburke/AzureSDKForRust | 02022344b7c37cdb713b69d60f9c86fc7295f64c | [
"Apache-2.0"
] | null | null | null | use crate::blob::generate_blob_uri;
use crate::blob::responses::DeleteBlobResponse;
use azure_sdk_core::errors::{check_status_extract_headers_and_body, AzureError};
use azure_sdk_core::lease::LeaseId;
use azure_sdk_core::{
BlobNameRequired, BlobNameSupport, ClientRequestIdOption, ClientRequestIdSupport,
ContainerNameRequired, ContainerNameSupport, DeleteSnapshotsMethodRequired,
DeleteSnapshotsMethodSupport, LeaseIdOption, LeaseIdSupport, TimeoutOption, TimeoutSupport,
};
use azure_sdk_core::{DeleteSnapshotsMethod, No, ToAssign, Yes};
use azure_sdk_storage_core::client::Client;
use azure_sdk_storage_core::ClientRequired;
use hyper::{Method, StatusCode};
use std::marker::PhantomData;
#[derive(Debug, Clone)]
pub struct DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
client: &'a Client,
p_container_name: PhantomData<ContainerNameSet>,
p_blob_name: PhantomData<BlobNameSet>,
p_delete_snapshots_method: PhantomData<DeleteSnapshotMethodSet>,
container_name: Option<&'a str>,
blob_name: Option<&'a str>,
delete_snapshots_method: DeleteSnapshotsMethod,
timeout: Option<u64>,
lease_id: Option<&'a LeaseId>,
client_request_id: Option<&'a str>,
}
impl<'a> DeleteBlobBuilder<'a, No, No, No> {
#[inline]
pub(crate) fn new(client: &'a Client) -> DeleteBlobBuilder<'a, No, No, No> {
DeleteBlobBuilder {
client,
p_container_name: PhantomData {},
container_name: None,
p_blob_name: PhantomData {},
blob_name: None,
p_delete_snapshots_method: PhantomData {},
delete_snapshots_method: DeleteSnapshotsMethod::Include,
timeout: None,
lease_id: None,
client_request_id: None,
}
}
}
impl<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet> ClientRequired<'a>
for DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
#[inline]
fn client(&self) -> &'a Client {
self.client
}
}
impl<'a, BlobNameSet, DeleteSnapshotMethodSet> ContainerNameRequired<'a>
for DeleteBlobBuilder<'a, Yes, BlobNameSet, DeleteSnapshotMethodSet>
where
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
#[inline]
fn container_name(&self) -> &'a str {
self.container_name.unwrap()
}
}
impl<'a, ContainerNameSet, DeleteSnapshotMethodSet> BlobNameRequired<'a>
for DeleteBlobBuilder<'a, ContainerNameSet, Yes, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
#[inline]
fn blob_name(&self) -> &'a str {
self.blob_name.unwrap()
}
}
impl<'a, ContainerNameSet, BlobNameSet> DeleteSnapshotsMethodRequired
for DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, Yes>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
{
#[inline]
fn delete_snapshots_method(&self) -> DeleteSnapshotsMethod {
self.delete_snapshots_method
}
}
impl<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet> TimeoutOption
for DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
#[inline]
fn timeout(&self) -> Option<u64> {
self.timeout
}
}
impl<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet> LeaseIdOption<'a>
for DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
#[inline]
fn lease_id(&self) -> Option<&'a LeaseId> {
self.lease_id
}
}
impl<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet> ClientRequestIdOption<'a>
for DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
#[inline]
fn client_request_id(&self) -> Option<&'a str> {
self.client_request_id
}
}
impl<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet> ContainerNameSupport<'a>
for DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
type O = DeleteBlobBuilder<'a, Yes, BlobNameSet, DeleteSnapshotMethodSet>;
#[inline]
fn with_container_name(self, container_name: &'a str) -> Self::O {
DeleteBlobBuilder {
client: self.client,
p_container_name: PhantomData {},
p_blob_name: PhantomData {},
p_delete_snapshots_method: PhantomData {},
container_name: Some(container_name),
blob_name: self.blob_name,
delete_snapshots_method: self.delete_snapshots_method,
timeout: self.timeout,
lease_id: self.lease_id,
client_request_id: self.client_request_id,
}
}
}
impl<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet> BlobNameSupport<'a>
for DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
type O = DeleteBlobBuilder<'a, ContainerNameSet, Yes, DeleteSnapshotMethodSet>;
#[inline]
fn with_blob_name(self, blob_name: &'a str) -> Self::O {
DeleteBlobBuilder {
client: self.client,
p_container_name: PhantomData {},
p_blob_name: PhantomData {},
p_delete_snapshots_method: PhantomData {},
container_name: self.container_name,
blob_name: Some(blob_name),
delete_snapshots_method: self.delete_snapshots_method,
timeout: self.timeout,
lease_id: self.lease_id,
client_request_id: self.client_request_id,
}
}
}
impl<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet> DeleteSnapshotsMethodSupport
for DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
type O = DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, Yes>;
#[inline]
fn with_delete_snapshots_method(
self,
delete_snapshots_method: DeleteSnapshotsMethod,
) -> Self::O {
DeleteBlobBuilder {
client: self.client,
p_container_name: PhantomData {},
p_blob_name: PhantomData {},
p_delete_snapshots_method: PhantomData {},
container_name: self.container_name,
blob_name: self.blob_name,
delete_snapshots_method,
timeout: self.timeout,
lease_id: self.lease_id,
client_request_id: self.client_request_id,
}
}
}
impl<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet> TimeoutSupport
for DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
type O = DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>;
#[inline]
fn with_timeout(self, timeout: u64) -> Self::O {
DeleteBlobBuilder {
client: self.client,
p_container_name: PhantomData {},
p_blob_name: PhantomData {},
p_delete_snapshots_method: PhantomData {},
container_name: self.container_name,
blob_name: self.blob_name,
delete_snapshots_method: self.delete_snapshots_method,
timeout: Some(timeout),
lease_id: self.lease_id,
client_request_id: self.client_request_id,
}
}
}
impl<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet> LeaseIdSupport<'a>
for DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
type O = DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>;
#[inline]
fn with_lease_id(self, lease_id: &'a LeaseId) -> Self::O {
DeleteBlobBuilder {
client: self.client,
p_container_name: PhantomData {},
p_blob_name: PhantomData {},
p_delete_snapshots_method: PhantomData {},
container_name: self.container_name,
blob_name: self.blob_name,
delete_snapshots_method: self.delete_snapshots_method,
timeout: self.timeout,
lease_id: Some(lease_id),
client_request_id: self.client_request_id,
}
}
}
impl<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet> ClientRequestIdSupport<'a>
for DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
type O = DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>;
#[inline]
fn with_client_request_id(self, client_request_id: &'a str) -> Self::O {
DeleteBlobBuilder {
client: self.client,
p_container_name: PhantomData {},
p_blob_name: PhantomData {},
p_delete_snapshots_method: PhantomData {},
container_name: self.container_name,
blob_name: self.blob_name,
delete_snapshots_method: self.delete_snapshots_method,
timeout: self.timeout,
lease_id: self.lease_id,
client_request_id: Some(client_request_id),
}
}
}
// methods callable regardless
impl<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
DeleteBlobBuilder<'a, ContainerNameSet, BlobNameSet, DeleteSnapshotMethodSet>
where
ContainerNameSet: ToAssign,
BlobNameSet: ToAssign,
DeleteSnapshotMethodSet: ToAssign,
{
}
impl<'a> DeleteBlobBuilder<'a, Yes, Yes, Yes> {
pub async fn finalize(self) -> Result<DeleteBlobResponse, AzureError> {
let mut uri = generate_blob_uri(&self, None);
if let Some(nm) = TimeoutOption::to_uri_parameter(&self) {
uri = format!("{}?{}", uri, nm);
}
trace!("delete_blob uri == {:?}", uri);
let future_response = self.client().perform_request(
&uri,
&Method::DELETE,
|ref mut request| {
DeleteSnapshotsMethodRequired::add_header(&self, request);
LeaseIdOption::add_header(&self, request);
ClientRequestIdOption::add_header(&self, request);
},
None,
)?;
let (headers, _body) =
check_status_extract_headers_and_body(future_response, StatusCode::ACCEPTED).await?;
DeleteBlobResponse::from_headers(&headers)
}
}
| 33.698507 | 96 | 0.684915 |
595b134e22cb3f401303fc5f979a07b23ea2de68 | 87 | kt | Kotlin | plugins/tower/src/main/kotlin/tower/api/Packets.kt | pluginloader/mono | e039d256d2e26ffeee55bd3c4f46de973b024b3a | [
"MIT"
] | 1 | 2021-11-04T00:35:05.000Z | 2021-11-04T00:35:05.000Z | plugins/tower/src/main/kotlin/tower/api/Packets.kt | pluginloader/mono | e039d256d2e26ffeee55bd3c4f46de973b024b3a | [
"MIT"
] | null | null | null | plugins/tower/src/main/kotlin/tower/api/Packets.kt | pluginloader/mono | e039d256d2e26ffeee55bd3c4f46de973b024b3a | [
"MIT"
] | 2 | 2021-05-10T23:37:51.000Z | 2021-09-21T08:46:51.000Z | package tower.api
interface Packet
interface Request<T: Response>
interface Response | 12.428571 | 30 | 0.827586 |
7adf47a9337f87c27fca10a590858ab425c74485 | 9,472 | sql | SQL | Temp_Dirty/missile_data.sql | TwistedFaith13/echoes_missiles | 040b73c023a8936e1cb81712f13d5773c39ed5ae | [
"Apache-2.0"
] | null | null | null | Temp_Dirty/missile_data.sql | TwistedFaith13/echoes_missiles | 040b73c023a8936e1cb81712f13d5773c39ed5ae | [
"Apache-2.0"
] | null | null | null | Temp_Dirty/missile_data.sql | TwistedFaith13/echoes_missiles | 040b73c023a8936e1cb81712f13d5773c39ed5ae | [
"Apache-2.0"
] | null | null | null | DROP TABLE IF EXISTS `echoes_db`.`def_sizes`;
DROP TABLE IF EXISTS `echoes_db`.`def_missile_types`;
DROP TABLE IF EXISTS `echoes_db`.`def_missiles`;
CREATE TABLE `echoes_db`.`def_sizes` (
`ms_id` tinyint(3) unsigned NOT NULL COMMENT 'Internal ID. Only for correlation',
`ms_display_name` char(10) NOT NULL COMMENT 'Human readable name for sizes.',
PRIMARY KEY (`ms_id`),
UNIQUE KEY `Duplicate Check` (`ms_display_name`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COMMENT='Baseline Size Table';
CREATE TABLE `echoes_db`.`def_missile_types` (
`mt_id` tinyint(3) unsigned NOT NULL COMMENT 'Internal ID. Only for correlation',
`mt_display_name` char(10) NOT NULL COMMENT 'Human readable name for missile types',
PRIMARY KEY (`mt_id`),
UNIQUE KEY `Duplicate Check` (`mt_display_name`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COMMENT='Baseline Missile Type Table';
CREATE TABLE `echoes_db`.`def_missiles` (
`m_id` smallint(5) unsigned NOT NULL AUTO_INCREMENT COMMENT 'Internal ID. Only for correlation',
`m_size` tinyint(3) unsigned NOT NULL COMMENT 'Foreign key pointing to def_sizes',
`m_type` tinyint(3) unsigned NOT NULL COMMENT 'Foreign key pointing to def_missile_types',
`m_tech_level` tinyint(3) unsigned NOT NULL COMMENT 'Minimum tech level to equip',
`m_meta_level` tinyint(3) unsigned NOT NULL COMMENT 'Meta level of projectile',
`m_name` char(20) NOT NULL COMMENT 'Projectile display name',
`m_dps` decimal(5,2) NOT NULL COMMENT 'Projectile DPS (sum of all damage types divided by activation time)',
`m_em_dmg` decimal(5,2) NOT NULL COMMENT 'Projectile ElectroMagnetic damage',
`m_th_dmg` decimal(5,2) NOT NULL COMMENT 'Projectile Thermal damage',
`m_ki_dmg` decimal(5,2) NOT NULL COMMENT 'Projectile Kinetic damage',
`m_ex_dmg` decimal(5,2) NOT NULL COMMENT 'Projectile Explosive damage',
`m_velocity` smallint(5) unsigned NOT NULL COMMENT 'Projectile velocity (affects range, ability to hit fast target) unit:m/s',
`m_activation_time` decimal(4,2) NOT NULL COMMENT 'Weapon cycle time (affects DPS) unit:s',
`m_explosion_velocity` tinyint(3) unsigned NOT NULL COMMENT 'Explosion velocity (affects ability to hit fast targets) unit:m/s',
`m_explosion_radius` smallint(5) unsigned NOT NULL COMMENT 'Explosion radius (affects ability to hit small targets) unit:m',
`m_flight_time` decimal(4,2) NOT NULL COMMENT 'Projectile flight time (affects range) unit:s',
`m_range` decimal(5,2) NOT NULL COMMENT 'Projectile range (velocity multiplied by time / 1000) unit:km',
PRIMARY KEY (`m_id`),
KEY `Only Size` (`m_size`),
KEY `Only Type` (`m_type`),
KEY `Both Size and Type` (`m_size`,`m_type`)
) ENGINE=MyISAM DEFAULT CHARSET=utf8mb4 COMMENT='Baseline Missile Details Table';
INSERT INTO `echoes_db`.`def_sizes`
(`ms_id`, `ms_display_name`)
VALUES
(1, 'Small'),
(2, 'Medium'),
(3, 'Large');
INSERT INTO `echoes_db`.`def_missile_types`
(`mt_id`, `mt_display_name`)
VALUES
(1, "Rapid"),
(2, "Missile"),
(3, "Torpedo");
INSERT INTO `echoes_db`.`def_missiles`
(`m_size`, `m_type`, `m_tech_level`, `m_meta_level`, `m_name`, `m_dps`, `M_em_dmg`, `m_th_dmg`, `m_ki_dmg`, `m_ex_dmg`, `m_velocity`, `m_activation_time`, `m_explosion_velocity`, `m_explosion_radius`, `m_flight_time`, `m_range`)
VALUES
(1, 2, 7, 3, "Mk7", 19.53, 62.51, 62.51, 62.51, 62.51, 3750, 12.8, 170, 40, 4, 15),
(1, 2, 9, 4, "Mk9", 20.85, 66.71, 66.71, 66.71, 66.71, 3750, 12.8, 170, 40, 4, 15),
(1, 2, 0, 5, "Gallows", 21.91, 70.11, 70.11, 70.11, 70.11, 3750, 12.8, 170, 40, 4, 15),
(1, 2, 0, 6, "Caldari Navy", 22.82, 73.01, 73.01, 73.01, 73.01, 3750, 12.8, 170, 40, 4, 15),
(1, 2, 0, 6, "Republic Fleet", 22.82, 73.01, 73.01, 73.01, 73.01, 3750, 12.8, 170, 40, 4, 15),
(1, 2, 0, 8, "Discipline", 24.28, 77.7, 77.7, 77.7, 77.7, 3750, 12.8, 170, 40, 4, 15),
(1, 2, 0, 11, "Pithi C-Type", 25.97, 83.09, 83.09, 83.09, 83.09, 3750, 12.8, 170, 40, 4, 15),
(1, 3, 7, 3, "Mk7", 25.13, 25.13, 25.13, 25.13, 25.13, 2250, 4, 150, 20, 2.4, 5.4),
(1, 3, 9, 4, "Mk9", 26.8, 26.8, 26.8, 26.8, 26.8, 2250, 4, 150, 20, 2.4, 5.4),
(1, 3, 0, 5, "Balefire", 28.17, 28.17, 28.17, 28.17, 28.17, 2250, 4, 150, 20, 2.4, 5.4),
(1, 3, 0, 6, "Caldari Navy", 29.34, 29.34, 29.34, 29.34, 29.34, 2250, 4, 150, 20, 2.4, 5.4),
(1, 3, 0, 6, "Republic Fleet", 29.34, 29.34, 29.34, 29.34, 29.34, 2250, 4, 150, 20, 2.4, 5.4),
(1, 3, 0, 8, "Heth", 31.23, 31.23, 31.23, 31.23, 31.23, 2250, 4, 150, 20, 2.4, 5.4),
(1, 3, 0, 11, "Pithi C-Type", 33.39, 33.39, 33.39, 33.39, 33.39, 2250, 4, 150, 20, 2.4, 5.4),
(2, 1, 7, 3, "Mk7", 27.66, 43.16, 43.16, 43.16, 43.16, 3750, 6.24, 170, 40, 4.25, 15.94),
(2, 1, 9, 4, "Mk9", 29.5, 46.03, 46.03, 46.03, 46.03, 3750, 6.24, 170, 40, 4.25, 15.94),
(2, 1, 0, 5, "Undertaker", 31.01, 48.37, 48.37, 48.37, 48.37, 3750, 6.24, 170, 40, 4.25, 15.94),
(2, 1, 0, 6, "Caldari Navy", 32.29, 50.37, 50.37, 50.37, 50.37, 3750, 6.24, 170, 40, 4.25, 15.94),
(2, 1, 0, 6, "Republic Fleet", 32.29, 50.37, 50.37, 50.37, 50.37, 3750, 6.24, 170, 40, 4.25, 15.94),
(2, 1, 0, 8, "Hurricane", 34.37, 53.62, 53.62, 53.62, 53.62, 3750, 6.24, 170, 40, 4.25, 15.94),
(2, 1, 0, 11, "Pithum C-Type", 36.75, 57.33, 57.33, 57.33, 57.33, 3750, 6.24, 170, 40, 4.25, 15.94),
(2, 2, 7, 3, "Mk7", 33.75, 101, 101, 101, 101, 4300, 12, 81, 140, 6.5, 27.95),
(2, 2, 9, 4, "Mk9", 36.01, 108, 108, 108, 108, 4300, 12, 81, 140, 6.5, 27.95),
(2, 2, 0, 5, "Undertaker", 37.84, 114, 114, 114, 114, 4300, 12, 81, 140, 6.5, 27.95),
(2, 2, 0, 6, "Caldari Navy", 39.39, 118, 118, 118, 118, 4300, 12, 81, 140, 6.5, 27.95),
(2, 2, 0, 6, "Republic Fleet", 39.39, 118, 118, 118, 118, 4300, 12, 81, 140, 6.5, 27.95),
(2, 2, 0, 8, "Discipline", 41.93, 126, 126, 126, 126, 4300, 12, 81, 140, 6.5, 27.95),
(2, 2, 0, 11, "Pithum C-Type", 44.84, 135, 135, 135, 135, 4300, 12, 81, 140, 6.5, 27.95),
(2, 3, 7, 3, "Mk7", 42.02, 67.24, 67.24, 67.24, 67.24, 2250, 6.4, 101, 125, 4, 9),
(2, 3, 9, 4, "Mk9", 44.82, 71.72, 71.72, 71.72, 71.72, 2250, 6.4, 101, 125, 4, 9),
(2, 3, 0, 5, "Undertaker", 47.12, 75.39, 75.39, 75.39, 75.39, 2250, 6.4, 101, 125, 4, 9),
(2, 3, 0, 6, "Caldari Navy", 49.07, 78.51, 78.51, 78.51, 78.51, 2250, 6.4, 101, 125, 4, 9),
(2, 3, 0, 6, "Republic Fleet", 49.07, 78.51, 78.51, 78.51, 78.51, 2250, 6.4, 101, 125, 4, 9),
(2, 3, 0, 8, "Heth", 52.22, 83.55, 83.55, 83.55, 83.55, 2250, 6.4, 101, 125, 4, 9),
(2, 3, 0, 11, "Pithum C-Type", 55.83, 89.32, 89.32, 89.32, 89.32, 2250, 6.4, 101, 125, 4, 9),
(3, 1, 9, 4, "Mk9", 46.05, 80.59, 80.59, 80.59, 80.59, 4300, 7, 70, 140, 6.5, 27.95),
(3, 1, 0, 5, "Gallows", 48.41, 84.72, 84.72, 84.72, 84.72, 4300, 7, 70, 140, 6.5, 27.95),
(3, 1, 0, 6, "Caldari Navy", 50.4, 88.21, 88.21, 88.21, 88.21, 4300, 7, 70, 140, 6.5, 27.95),
(3, 1, 0, 6, "Republic Fleet", 50.4, 88.21, 88.21, 88.21, 88.21, 4300, 7, 70, 140, 6.5, 27.95),
(3, 1, 0, 8, "Hurricane", 53.67, 93.93, 93.93, 93.93, 93.93, 4300, 7, 70, 140, 6.5, 27.95),
(3, 1, 0, 11, "Pith C-Type", 57.38, 100, 100, 100, 100, 4300, 7, 70, 140, 6.5, 27.95),
(3, 1, 0, 12, "Pith B-Type", 60.25, 105, 105, 105, 105, 4300, 7, 70, 140, 6.5, 27.95),
(3, 2, 9, 4, "Mk9", 48.59, 201, 201, 201, 201, 4700, 16.54, 69, 330, 14, 65.8),
(3, 2, 0, 5, "Gallows", 51.08, 211, 211, 211, 211, 4700, 16.54, 69, 330, 14, 65.8),
(3, 2, 0, 6, "Caldari Navy", 53.16, 220, 220, 220, 220, 4700, 16.54, 69, 330, 14, 65.8),
(3, 2, 0, 6, "Republic Fleet", 53.16, 220, 220, 220, 220, 4700, 16.54, 69, 330, 14, 65.8),
(3, 2, 0, 8, "Hurricane", 56.59, 234, 234, 234, 234, 4700, 16.54, 69, 330, 14, 65.8),
(3, 2, 0, 11, "Pith C-Type", 60.51, 250, 250, 250, 250, 4700, 16.54, 69, 330, 14, 65.8),
(3, 2, 0, 12, "Pith B-Type", 63.57, 263, 263, 263, 263, 4700, 16.54, 69, 330, 14, 65.8),
(3, 3, 9, 4, "Mk9", 58.97, 212, 212, 212, 212, 1800, 14.4, 71, 450, 6, 10.8),
(3, 3, 0, 5, "Barrage", 62, 223, 223, 223, 223, 1800, 14.4, 71, 450, 6, 10.8),
(3, 3, 0, 6, "Caldari Navy", 64.53, 232, 232, 232, 232, 1800, 14.4, 71, 450, 6, 10.8),
(3, 3, 0, 6, "Republic Fleet", 64.53, 232, 232, 232, 232, 1800, 14.4, 71, 450, 6, 10.8),
(3, 3, 0, 8, "Hurricane", 68.7, 247, 247, 247, 247, 1800, 14.4, 71, 450, 6, 10.8),
(3, 3, 0, 11, "Pith C-Type", 73.47, 264, 264, 264, 264, 1800, 14.4, 71, 450, 6, 10.8),
(3, 3, 0, 12, "Pith B-Type", 77.13, 278, 278, 278, 278, 1800, 14.4, 71, 450, 6, 10.8);
/*
Sample query
SELECT
concat(`m_name`, ' ', (select `ms_display_name` from `def_sizes` where `m_size`=`def_sizes`.`ms_id`), ' ', (select `mt_display_name` from `def_missile_types` where `m_type`=`def_missile_types`.`mt_id`), ' Launcher') as "Name",
concat(`m_activation_time`, ' s') as "Activation Time",
`m_dps` as "DPS",
concat((`m_em_dmg` + `m_th_dmg` + `m_ki_dmg` + `m_ex_dmg`), ' (Em: ', `m_em_dmg`, ', Th: ', `m_th_dmg`, ', Ki: ', `m_ki_dmg`, ', Ex: ', `m_ex_dmg`, ')') as "Alpha Dmg",
concat(`m_range`, ' km') as "Range"
FROM
`echoes_db`.`def_missiles`
WHERE m_size=2 and m_type=1 limit 10;
SELECT
concat(`m_name`, ' ', (select `ms_display_name` from `def_sizes` where `m_size`=`def_sizes`.`ms_id`), ' ', (select `mt_display_name` from `def_missile_types` where `m_type`=`def_missile_types`.`mt_id`), ' Launcher') as "Name",
concat(`m_activation_time` * (1 + (-10)/100), ' s') as "Activation Time",
`m_dps` as "DPS",
concat((`m_em_dmg` + `m_th_dmg` + `m_ki_dmg` + `m_ex_dmg`), ' (Em: ', `m_em_dmg`, ', Th: ', `m_th_dmg`, ', Ki: ', `m_ki_dmg`, ', Ex: ', `m_ex_dmg`, ')') as "Alpha Dmg",
concat(`m_range`, ' km') as "Range"
FROM
`echoes_db`.`def_missiles`
WHERE `m_id`=20;
*/ | 68.143885 | 229 | 0.61212 |
a9c82497aba55ed8802a552e007dcc04ffa8e61f | 7,772 | htm | HTML | sdk/boost_1_30_0/libs/test/doc/output_test_stream.htm | acidicMercury8/xray-1.0 | 65e85c0e31e82d612c793d980dc4b73fa186c76c | [
"Linux-OpenIB"
] | 2 | 2020-01-30T12:51:49.000Z | 2020-08-31T08:36:49.000Z | sdk/boost_1_30_0/libs/test/doc/output_test_stream.htm | acidicMercury8/xray-1.0 | 65e85c0e31e82d612c793d980dc4b73fa186c76c | [
"Linux-OpenIB"
] | null | null | null | sdk/boost_1_30_0/libs/test/doc/output_test_stream.htm | acidicMercury8/xray-1.0 | 65e85c0e31e82d612c793d980dc4b73fa186c76c | [
"Linux-OpenIB"
] | null | null | null | <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">
<HTML>
<HEAD>
<TITLE>Output test Stream</TITLE>
<LINK rel="stylesheet" type="text/css" href="style/btl-white.css" media="screen">
<LINK rel="stylesheet" type="text/css" href="style/btl-print.css" media="print">
<META http-equiv="Content-Language" content="en-us">
<META http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</HEAD>
<BODY>
<DIV class="centered">
<TABLE class="body-table" cellspacing="3" >
<TR>
<TD id="body"> <A name='TOP'><IMG src='../../../c++boost.gif' width='277' height='86' alt="Boost logo"></A>
<H1>Boost Test Library: output_test_stream tool</H1>
<P class="page-toc"> <A href="index.htm">Home</A><BR>
<A href="#Introduction">Introduction</A><BR>
<A href="#Benifits">Benefits</A><BR>
<A href="#Specification">Specification<BR>
</A> <A href="#Tests">Examples and Tests</A> </P>
<H2><A name="Introduction">Introduction</A></H2>
<P class="1-line-indented">The class <SPAN class="new-term">output_test_stream</SPAN>
is a simple tool for testing output operation with standard std::ostream facilities.
The class output_test_stream comply to std::ostream interface so it can be used
in place of any std::ostream argument. In addition it provide several methods to
validate output content. Also it allows to match/save output content versus/into
specified file. Working mode of the output_test_stream could be defined by framework
parameter "<A href="unit_test_framework.htm#FrameworkParameters"> Save pattern</A>"</P>
<H2><A name="Benifits">Benefits</A></H2>
<P class="1-line-indented">Simplified mechanism for checking correctness of output
operations. <SPAN class="ref-to-top"><A href="#TOP"><IMG src="imgs/uarrow.gif" alt="reference to the top"></A></SPAN></P>
<H2><A name="Specification">Specification</A></H2>
<PRE class="code"><SPAN class="reserv-word">class</SPAN> <SPAN class="new-term">output_test_stream</SPAN> {
<SPAN class="reserv-word">pubic</SPAN>:
<SPAN class="reserv-word">explicit</SPAN> output_test_stream( <SPAN class="cpp-type">char</SPAN> <SPAN class="reserv-word">const</SPAN>* pattern_file = NULL,
<SPAN class="cpp-type">bool</SPAN> match_or_save = <SPAN class="reserv-word">true</SPAN> );
~output_test_stream();
<SPAN class="cpp-type">bool</SPAN> is_empty( <SPAN class="cpp-type">bool</SPAN> flush_stream = <SPAN class="reserv-word">true</SPAN> );
<SPAN class="cpp-type">bool</SPAN> check_length( std::size_t length, <SPAN class="cpp-type">bool</SPAN> flush_stream = <SPAN class="reserv-word">true</SPAN> );
<SPAN class="cpp-type">bool</SPAN> is_equal( <SPAN class="cpp-type">char</SPAN> <SPAN class="reserv-word">const</SPAN>* arg, <SPAN class="cpp-type">bool</SPAN> flush_stream = <SPAN class="reserv-word">true</SPAN> );
<SPAN class="cpp-type">bool</SPAN> is_equal( <SPAN class="cpp-type">std::string</SPAN> <SPAN class="reserv-word">const</SPAN>& arg, <SPAN class="cpp-type">bool</SPAN> flush_stream = <SPAN class="reserv-word">true</SPAN> );
<SPAN class="cpp-type">bool</SPAN> is_equal( <SPAN class="cpp-type">char</SPAN> <SPAN class="reserv-word">const</SPAN>* arg, <SPAN class="cpp-type">std::size_t</SPAN> n,
<SPAN class="cpp-type">bool</SPAN> flush_stream = <SPAN class="reserv-word">true</SPAN> );
<SPAN class="cpp-type">bool</SPAN> match_pattern( <SPAN class="cpp-type">bool</SPAN> flush_stream = <SPAN class="reserv-word">true</SPAN> );
<SPAN class="cpp-type">void</SPAN> flush();
};
</PRE>
<P>explicit <SPAN class="new-term"><A name="output_test_stream constructor">output_test_stream</A></SPAN>(
char const* pattern_file = NULL, bool match_or_save = true );</P>
<P class="1-line-indented">The class output_test_stream constructor accept pattern
file name and boolean switch match_or_save that are used by <A href="#match_pattern">match_pattern</A>
facility. If they are not present you can still use other testing mechanisms.</P>
<P>void <SPAN class="new-term">flush</SPAN>();</P>
<P class="1-line-indented">The method output_test_stream::flush() is used to clean
the content of the output_test_stream instance.</P>
<P>bool <SPAN class="new-term">is_empty</SPAN>( bool flush_stream = true );</P>
<P class="1-line-indented">The method output_test_stream::is_empty(...) is used to
check that the content of the output_test_stream instance is empty. The flush_stream
argument manage automatic call of the method output_test_stream::flush() after
check is done.</P>
<P> bool <SPAN class="new-term">check_length</SPAN>( std::size_t length, bool flush_stream
= true );</P>
<P class="1-line-indented">The method output_test_stream::check_length(...) is used
to check that the length of the content of the output_test_stream instance is equal
to supplied length value. The flush_stream argument manage automatic call of the
method output_test_stream::flush() after check is done.</P>
<P> bool <SPAN class="new-term">is_equal</SPAN>( char const* arg, bool flush_stream
= true );<BR>
bool <SPAN class="new-term">is_equal</SPAN>( std::string const& arg, bool flush_stream
= true );<BR>
bool <SPAN class="new-term">is_equal</SPAN>( char const* arg, std::size_t n, bool
flush_stream = true );</P>
<P class="1-line-indented">The overloaded method output_test_stream::is_equal(...)
is used to check that the content of the output_test_stream instance is equal to
supplied character string. The first version compare with null-terminated string.
The second compare with a reference to std::string object. And finnaly the third
version compare with probably not null-terminated string defined by pointer to
the string begin and the string length. The flush_stream argument manage automatic
call of the method output_test_stream::flush() after check is done.</P>
<P>bool <SPAN class="new-term"><A name="match_pattern">match_pattern</A></SPAN>(
bool flush_stream = true );</P>
<P class="1-line-indented">The method output_test_stream::match_pattern(...) is used
to match the content of the output_test_stream instance versus the pattern file.
The pattern file name is specified in the class output_test_stream <A href="#output_test_stream constructor">constructor</A>.
If second argument of the class output_test_stream <A href="#output_test_stream constructor">constructor</A>
is false, then every call of the method output_test_stream::match_pattern(...)
will cause the output_test_stream instance content to be <SPAN style="text-decoration: underline">stored</SPAN>
at the end of the pattern file. The flush_stream argument manage automatic call
of the method output_test_stream::flush() after check is done.</P>
<H2><A name="Tests">Examlpes and Tests</A></H2>
<P class="indented"> <a href="components_testing.htm#output_test_stream_test">output_test_stream_test</a><BR>
<a href="components_testing.htm#result_report_test">result_report_test</a><BR>
<a href="components_testing.htm#test_tools_test">test_tools_test</a><BR>
<SPAN class="ref-to-top"><A href="#TOP"><IMG src="imgs/uarrow.gif" alt="reference to the top"></A></SPAN>
<a href="components_testing.htm#errors_handling_test">errors_handling_test</a></P>
<BR>
<DIV class="footer">
<P>© <A href='mailto:rogeeff@emailaccount.com'>Gennadiy Rozental</A> 2001-2002
</P>
<P>Revised: 12 February, 2003</P>
</DIV>
</TD>
</TR>
</TABLE>
</DIV>
</BODY>
</HTML> | 69.392857 | 232 | 0.693387 |
b1e7b87aea2ce6d2c577a9965f369ca48e945082 | 646 | sql | SQL | WeatherSystemServer/src/main/resources/data.sql | SanjinKurelic/WeatherSystem | e7b2a769c1650fd78d1a1be65757bb085d38ff72 | [
"MIT"
] | null | null | null | WeatherSystemServer/src/main/resources/data.sql | SanjinKurelic/WeatherSystem | e7b2a769c1650fd78d1a1be65757bb085d38ff72 | [
"MIT"
] | null | null | null | WeatherSystemServer/src/main/resources/data.sql | SanjinKurelic/WeatherSystem | e7b2a769c1650fd78d1a1be65757bb085d38ff72 | [
"MIT"
] | null | null | null | insert into station values
(1, 'Dubec WM-1', 'WeatherMachine', '2000', 51513, 'Omišalj'),
(2, 'Svjetionik istok', 'Rain Falcon', 'v55.73', 51515, 'Šilo'),
(3, 'MK - Centar', 'WeatherMachine', '2000', 51511, 'Malinska'),
(4, 'Marina Punat', 'Rain Falcon', 'v44.88', 51521, 'Punat'),
(5, 'Punat jug - kamp', 'Rain Falcon', 'v55.73', 51521, 'Punat'),
(6, 'KK_Lukobran', 'WeatherMachine', '2000', 51500, 'Krk'),
(7, 'KK_Politin', 'Rain Falcon', 'v77.00.5', 51500, 'Krk'),
(8, 'KK_Škola', 'WeatherMachine', '2010', 51500, 'Krk'),
(9, 'BS - Centar', 'Rain Automata', 'L-22-IT', 51523, 'Baška'),
(10, 'Gospoja', 'Rain Falcon', 'v101', 51516, 'Vrbnik');
| 53.833333 | 65 | 0.611455 |
2f434054e5533044fb8a5ed8d3006c7d59017aac | 568 | php | PHP | app/Models/Abz/Abz_Ranks.php | account931/abz_Laravel_6_LTS | e5c49e48397f061c4f30d3e958cf5592d9d07ffb | [
"MIT"
] | null | null | null | app/Models/Abz/Abz_Ranks.php | account931/abz_Laravel_6_LTS | e5c49e48397f061c4f30d3e958cf5592d9d07ffb | [
"MIT"
] | null | null | null | app/Models/Abz/Abz_Ranks.php | account931/abz_Laravel_6_LTS | e5c49e48397f061c4f30d3e958cf5592d9d07ffb | [
"MIT"
] | null | null | null | <?php
namespace App\Models\Abz;
//use Illuminate\Database\Eloquent\Factories\HasFactory; //causes Crash, not found
use Illuminate\Database\Eloquent\Model;
class Abz_Ranks extends Model
{
protected $table = 'abz_ranks'; //specify the DB table table
//hasOne
public function user()
{
return $this->hasOne('App\Models\Abz\Abz_Employees', 'rank_id', 'id'); //$this->belongsTo('App\modelName', 'foreign_key_that_table', 'parent_id_this_table');}
//return $this->belongsTo('App\Models\Abz\Abz_Employees', 'id', 'rank_id');
}
} | 23.666667 | 165 | 0.68662 |
110ffec436e0f6fbdcf1c72a972946c73c6370aa | 937 | nasm | Assembly | RustPkg/Library/IntrinsicLib/Ia32/MathLShiftS64.nasm | makubacki/mu_basecore | 90947a3f132690320e57c93c2c2a71a3185dacc8 | [
"Python-2.0",
"Zlib",
"BSD-2-Clause",
"MIT",
"BSD-2-Clause-Patent",
"BSD-3-Clause"
] | 9 | 2021-07-26T17:02:51.000Z | 2021-12-30T10:49:46.000Z | CryptoPkg/Library/IntrinsicLib/Ia32/MathLShiftS64.nasm | ESdove/edk2_exploring | 34ff32b45f43d233d9696e7c8e3de68ea3000a7b | [
"Python-2.0",
"Zlib",
"BSD-2-Clause",
"MIT",
"BSD-2-Clause-Patent",
"BSD-3-Clause"
] | null | null | null | CryptoPkg/Library/IntrinsicLib/Ia32/MathLShiftS64.nasm | ESdove/edk2_exploring | 34ff32b45f43d233d9696e7c8e3de68ea3000a7b | [
"Python-2.0",
"Zlib",
"BSD-2-Clause",
"MIT",
"BSD-2-Clause-Patent",
"BSD-3-Clause"
] | null | null | null | ;------------------------------------------------------------------------------
;
; Copyright (c) 2016, Intel Corporation. All rights reserved.<BR>
; SPDX-License-Identifier: BSD-2-Clause-Patent
;
; Module Name:
;
; MathLShiftS64.nasm
;
; Abstract:
;
; 64-bit Math Worker Function.
; Shifts a 64-bit signed value left by a certain number of bits.
;
;------------------------------------------------------------------------------
SECTION .text
global ASM_PFX(__ashldi3)
;------------------------------------------------------------------------------
;
; void __cdecl __ashldi3 (void)
;
;------------------------------------------------------------------------------
ASM_PFX(__ashldi3):
cmp cl,0x40
jnc ReturnZero
cmp cl,0x20
jnc More32
shld edx,eax,cl
shl eax,cl
ret
More32:
mov edx,eax
xor eax,eax
and cl,0x1f
shl edx,cl
ret
ReturnZero:
xor eax,eax
xor edx,edx
ret
| 21.790698 | 79 | 0.431163 |
98b9260a75a0b94d2f0a3fbde4f4b4c2ae4e190b | 45,044 | html | HTML | static/slides/w4p1.html | datalorax/mlm2 | 5442642e178b2cab281fc33049e8defc95275464 | [
"CC-BY-4.0"
] | 2 | 2021-06-11T17:40:03.000Z | 2022-03-13T00:23:20.000Z | static/slides/w4p1.html | datalorax/mlm2 | 5442642e178b2cab281fc33049e8defc95275464 | [
"CC-BY-4.0"
] | null | null | null | static/slides/w4p1.html | datalorax/mlm2 | 5442642e178b2cab281fc33049e8defc95275464 | [
"CC-BY-4.0"
] | null | null | null | <!DOCTYPE html>
<html lang="" xml:lang="">
<head>
<title>Review & Intro to GH Notation</title>
<meta charset="utf-8" />
<meta name="author" content="Daniel Anderson" />
<script src="libs/header-attrs-2.7/header-attrs.js"></script>
<link href="libs/remark-css-0.0.1/default.css" rel="stylesheet" />
<script src="libs/clipboard-2.0.6/clipboard.min.js"></script>
<link href="libs/xaringanExtra-clipboard-0.2.6/xaringanExtra-clipboard.css" rel="stylesheet" />
<script src="libs/xaringanExtra-clipboard-0.2.6/xaringanExtra-clipboard.js"></script>
<script>window.xaringanExtraClipboard(null, {"button":"Copy Code","success":"Copied!","error":"Press Ctrl+C to Copy"})</script>
<link href="libs/countdown-0.3.5/countdown.css" rel="stylesheet" />
<script src="libs/countdown-0.3.5/countdown.js"></script>
<script src="https://unpkg.com/feather-icons"></script>
<link rel="stylesheet" href="new.css" type="text/css" />
</head>
<body>
<textarea id="source">
class: center, middle, inverse, title-slide
# Review & Intro to GH Notation
### Daniel Anderson
### Week 4
---
layout: true
<script>
feather.replace()
</script>
<div class="slides-footer">
<span>
<a class = "footer-icon-link" href = "https://github.com/datalorax/mlm2/raw/main/static/slides/w4p1.pdf">
<i class = "footer-icon" data-feather="download"></i>
</a>
<a class = "footer-icon-link" href = "https://mlm2.netlify.app/slides/w4p1.html">
<i class = "footer-icon" data-feather="link"></i>
</a>
<a class = "footer-icon-link" href = "https://mlm2-2021.netlify.app">
<i class = "footer-icon" data-feather="globe"></i>
</a>
<a class = "footer-icon-link" href = "https://github.com/datalorax/mlm2">
<i class = "footer-icon" data-feather="github"></i>
</a>
</span>
</div>
---
# Agenda
* Review Homework 1
* Review the most important parts of Week 3 content
* Discuss Gelman and Hill notation - contrast with Raudenbush and Bryk
* Unstructured VCV Matrices and alternatives
---
# Learning Objectives
* Understand at least the basics of the GH notation and why I view it as preferable
* Gain a deeper understanding of how the residual structure is different in multilevel models
* Understand that there are methods for changing the residual structure, and understand when and why this might be preferable
* Have a basic understanding of implementing alternative methods
---
class: inverse-blue middle
# Review Homework 1
---
class: inverse-red middle
# Review Week 3 content
---
# Data and model
```r
library(tidyverse)
library(lme4)
popular <- read_csv(here::here("data", "popularity.csv"))
m <- lmer(popular ~ extrav + (extrav|class), popular,
control = lmerControl(optimizer = "bobyqa"))
```
`extrav` is a measure of extraversion.
What is this model fitting, in plain English?
---
# Model summary
```r
arm::display(m)
```
```
## lmer(formula = popular ~ extrav + (extrav | class), data = popular,
## control = lmerControl(optimizer = "bobyqa"))
## coef.est coef.se
## (Intercept) 2.46 0.20
## extrav 0.49 0.03
##
## Error terms:
## Groups Name Std.Dev. Corr
## class (Intercept) 1.73
## extrav 0.16 -0.97
## Residual 0.95
## ---
## number of obs: 2000, groups: class, 100
## AIC = 5791.4, DIC = 5762
## deviance = 5770.7
```
---
# Let's walk through
* By way of thinking through it, let's compare to simple linear regression
--
```r
slr <- lm(popular ~ extrav, popular)
arm::display(slr)
```
```
## lm(formula = popular ~ extrav, data = popular)
## coef.est coef.se
## (Intercept) 3.27 0.12
## extrav 0.35 0.02
## ---
## n = 2000, k = 2
## residual sd = 1.31, R-Squared = 0.10
```
---
# Visually
```r
ggplot(popular, aes(extrav, popular)) +
geom_point() +
geom_smooth(se = FALSE, method = "lm")
```
<!-- -->
---
# Making predictions
$$
\operatorname{\widehat{popular}} = 3.27 + 0.35(\operatorname{extrav})
$$
--
Scores of 0 to 5
$$
\operatorname{\widehat{popular}} = 3.27 + 0.35 \times 0 = 3.27
$$
$$
\operatorname{\widehat{popular}} = 3.27 + 0.35 \times 1 = 3.62
$$
$$
\operatorname{\widehat{popular}} = 3.27 + 0.35 \times 2 = 3.97
$$
$$
\operatorname{\widehat{popular}} = 3.27 + 0.35 \times 3 = 4.32
$$
$$
\operatorname{\widehat{popular}} = 3.27 + 0.35 \times 4 = 4.67
$$
$$
\operatorname{\widehat{popular}} = 3.27 + 0.35 \times 5 = 5.02
$$
---
# Now for the mlm
It's more complicated now for a couple of reasons
* Each `class` has their own intercept and slope. Which class is the student in?
* What if we want to make a prediction for someone outside our sample?
--
Let's walk through 4 predictions
---
# Sample preds
```r
sample_preds <- popular %>%
group_by(class) %>%
slice(1) %>%
ungroup() %>%
slice(1:4)
sample_preds
```
```
## # A tibble: 4 x 7
## pupil class extrav sex texp popular popteach
## <dbl> <dbl> <dbl> <chr> <dbl> <dbl> <dbl>
## 1 1 1 5 girl 24 6.3 6
## 2 1 2 8 girl 14 6.4 6
## 3 1 3 5 boy 13 4.2 4
## 4 1 4 3 girl 20 4.1 4
```
---
# Coefficients
$$
`\begin{aligned}
\operatorname{\widehat{popular}}_{i} &\sim N \left(\mu, \sigma^2 \right) \\
\mu &=2.46_{\alpha_{j[i]}} + 0.49_{\beta_{1j[i]}}(\operatorname{extrav}) \\
\left(
\begin{array}{c}
\begin{aligned}
&\alpha_{j} \\
&\beta_{1j}
\end{aligned}
\end{array}
\right)
&\sim N \left(
\left(
\begin{array}{c}
\begin{aligned}
&0 \\
&0
\end{aligned}
\end{array}
\right)
,
\left(
\begin{array}{cc}
1.73 & -0.97 \\
-0.97 & 0.16
\end{array}
\right)
\right)
\text{, for class j = 1,} \dots \text{,J}
\end{aligned}`
$$
---
# Grab params
Fixed effects
```r
f <- fixef(m)
f
```
```
## (Intercept) extrav
## 2.4610234 0.4928571
```
--
classroom deviations
```r
r <- ranef(m)
r
```
```
## $class
## (Intercept) extrav
## 1 0.34095954 -0.027014677
## 2 -1.17798954 0.096974668
## 3 -0.62937002 0.057097182
## 4 1.08529708 -0.099953042
## 5 -0.19489641 0.021601800
## 6 -0.98339230 0.083762531
## 7 -1.00065422 0.064825024
## 8 -2.31344585 0.203883548
## 9 -0.72390121 0.076936163
## 10 0.81714889 -0.088190958
## 11 -0.80165382 0.053642262
## 12 -0.50559454 0.035562482
## 13 1.94465792 -0.163675650
## 14 -4.60442503 0.379805874
## 15 -0.95627606 0.092420531
## 16 -0.63300242 0.038113732
## 17 0.39246763 -0.023686639
## 18 2.28824205 -0.199172763
## 19 1.11955746 -0.088677713
## 20 0.21949255 0.001085573
## 21 0.26728615 -0.047272343
## 22 2.29791264 -0.192289863
## 23 0.33161921 -0.024183133
## 24 -1.35638924 0.114938066
## 25 -0.01994683 -0.011555948
## 26 -1.25402662 0.107101274
## 27 -1.19545641 0.114147749
## 28 -0.44502470 0.014290982
## 29 2.03871407 -0.180129251
## 30 -1.40054893 0.109698011
## 31 -1.79566145 0.205412272
## 32 -0.34719881 0.051159472
## 33 2.12578123 -0.136367830
## 34 -0.98425888 0.101445482
## 35 3.63820003 -0.322359287
## 36 0.91322197 -0.111514042
## 37 0.30465672 -0.016094329
## 38 -0.51579961 0.044299138
## 39 0.61982719 -0.065503359
## 40 -1.37549168 0.146964064
## 41 -1.59793019 0.120798718
## 42 0.45790261 -0.028187295
## 43 0.71853077 -0.072570668
## 44 -0.62247125 0.062370382
## 45 1.35450804 -0.121366316
## 46 0.20177100 0.005892888
## 47 -0.02078929 -0.013791520
## 48 -2.26606243 0.208550251
## 49 -0.61265117 0.051465741
## 50 2.28265601 -0.208111972
## 51 -0.69648204 0.049844088
## 52 -0.90954843 0.067366763
## 53 2.86086261 -0.232865613
## 54 0.64107333 -0.074085601
## 55 -2.50861566 0.192442071
## 56 -0.14415572 0.007115389
## 57 -2.80554237 0.241556549
## 58 1.75944076 -0.126488906
## 59 -1.68024885 0.141406264
## 60 -2.84510196 0.251453827
## 61 1.61352443 -0.124578081
## 62 1.50756016 -0.135037156
## 63 0.59132744 -0.044723322
## 64 3.73918453 -0.308268291
## 65 2.45234814 -0.220397788
## 66 1.03733197 -0.058445288
## 67 2.66082354 -0.227526069
## 68 1.46921309 -0.131443741
## 69 1.63166550 -0.140435755
## 70 0.43378635 -0.053210430
## 71 -0.30351761 0.025705771
## 72 1.51758455 -0.131131939
## 73 0.31830478 -0.015358480
## 74 0.11917146 -0.010920052
## 75 3.21937801 -0.282591050
## 76 -0.44752241 0.034897759
## 77 -2.07421760 0.189805156
## 78 0.20218552 -0.032347963
## 79 -0.03079998 0.023590148
## 80 -0.35201798 -0.007108531
## 81 -1.59892551 0.137191741
## 82 -4.47259281 0.356549044
## 83 1.94061207 -0.169805276
## 84 2.34329550 -0.194455692
## 85 2.59038066 -0.230546280
## 86 -2.63669093 0.211968413
## 87 -2.15950668 0.182295946
## 88 -0.50307369 0.043046426
## 89 -0.24684183 0.033388043
## 90 -1.31095047 0.116798271
## 91 0.17151990 -0.024759656
## 92 -0.79771656 0.067134422
## 93 -0.94261942 0.087295289
## 94 0.90471914 -0.082321802
## 95 0.32102824 -0.049803302
## 96 0.61116278 -0.045875786
## 97 -2.32751564 0.214605064
## 98 2.31222739 -0.201619723
## 99 -0.11828481 0.029049313
## 100 -2.48332475 0.229068557
##
## with conditional variances for "class"
```
---
# Predictions depend on classroom
### Fixed effect part
Works just like simple linear regression
--
```r
sample_preds[1, ]
```
```
## # A tibble: 1 x 7
## pupil class extrav sex texp popular popteach
## <dbl> <dbl> <dbl> <chr> <dbl> <dbl> <dbl>
## 1 1 1 5 girl 24 6.3 6
```
$$
\operatorname{\widehat{popular}} = 2.46 + 0.49 \times 5 = 4.91
$$
--
```r
f[1] + f[2]*5
```
```
## (Intercept)
## 4.925309
```
---
# Random effects
We now have to add in the random effects *for the corresponding classroom*.
--
```r
head(r$class)
```
```
## (Intercept) extrav
## 1 0.3409595 -0.02701468
## 2 -1.1779895 0.09697467
## 3 -0.6293700 0.05709718
## 4 1.0852971 -0.09995304
## 5 -0.1948964 0.02160180
## 6 -0.9833923 0.08376253
```
--
$$
\operatorname{\widehat{popular}} = (2.46 + 0.34) + (0.49 + -0.03) \times 5 = 5.10
$$
---
# In code
```r
class1 <- r$class[1, ]
class1
```
```
## (Intercept) extrav
## 1 0.3409595 -0.02701468
```
```r
(f[1] + class1[1]) + (f[2] + class1[2])*5
```
```
## (Intercept)
## 1 5.131195
```
---
# Predictions
```r
sample_preds
```
```
## # A tibble: 4 x 7
## pupil class extrav sex texp popular popteach
## <dbl> <dbl> <dbl> <chr> <dbl> <dbl> <dbl>
## 1 1 1 5 girl 24 6.3 6
## 2 1 2 8 girl 14 6.4 6
## 3 1 3 5 boy 13 4.2 4
## 4 1 4 3 girl 20 4.1 4
```
```r
head(r$class, n = 4)
```
```
## (Intercept) extrav
## 1 0.3409595 -0.02701468
## 2 -1.1779895 0.09697467
## 3 -0.6293700 0.05709718
## 4 1.0852971 -0.09995304
```
```r
fixef(m)
```
```
## (Intercept) extrav
## 2.4610234 0.4928571
```
---
$$
\operatorname{\widehat{popular}} = (2.46 + 0.34) + (0.49 + -0.03) \times 5 = 5.10
$$
$$
\operatorname{\widehat{popular}} = (2.46 + -1.18) + (0.49 + 0.10) \times 8 = 6.00
$$
$$
\operatorname{\widehat{popular}} = (2.46 + -0.63) + (0.49 + 0.06) \times 5 = 4.58
$$
$$
\operatorname{\widehat{popular}} = (2.46 + 1.09) + (0.49 + -0.10) \times 3 = 4.72
$$
--
```r
predict(m, newdata = sample_preds)
```
```
## 1 2 3 4
## 5.131195 6.001688 4.581425 4.725033
```
--
### What if we want to make a prediction outside of our classrooms?
--
Fixed effects only
$$
\operatorname{\widehat{popular}} = 2.46 + 0.49 \times \operatorname{extraversion}
$$
---
# Plotting
We can use the `expand.grid()` function to create different conditions.
--
Let's compare slopes across the first five classrooms
```r
conditions <- expand.grid(extrav = 1:10, class = 1:5)
```
.pull-left[
```r
head(conditions)
```
```
## extrav class
## 1 1 1
## 2 2 1
## 3 3 1
## 4 4 1
## 5 5 1
## 6 6 1
```
]
.pull-right[
```r
tail(conditions)
```
```
## extrav class
## 45 5 5
## 46 6 5
## 47 7 5
## 48 8 5
## 49 9 5
## 50 10 5
```
]
---
# Make predictions
```r
conditions %>%
mutate(model_pred = predict(m, newdata = conditions))
```
```
## extrav class model_pred
## 1 1 1 3.267825
## 2 2 1 3.733668
## 3 3 1 4.199510
## 4 4 1 4.665353
## 5 5 1 5.131195
## 6 6 1 5.597038
## 7 7 1 6.062880
## 8 8 1 6.528722
## 9 9 1 6.994565
## 10 10 1 7.460407
## 11 1 2 1.872866
## 12 2 2 2.462697
## 13 3 2 3.052529
## 14 4 2 3.642361
## 15 5 2 4.232193
## 16 6 2 4.822025
## 17 7 2 5.411856
## 18 8 2 6.001688
## 19 9 2 6.591520
## 20 10 2 7.181352
## 21 1 3 2.381608
## 22 2 3 2.931562
## 23 3 3 3.481516
## 24 4 3 4.031471
## 25 5 3 4.581425
## 26 6 3 5.131379
## 27 7 3 5.681333
## 28 8 3 6.231288
## 29 9 3 6.781242
## 30 10 3 7.331196
## 31 1 4 3.939225
## 32 2 4 4.332129
## 33 3 4 4.725033
## 34 4 4 5.117937
## 35 5 4 5.510841
## 36 6 4 5.903745
## 37 7 4 6.296649
## 38 8 4 6.689553
## 39 9 4 7.082457
## 40 10 4 7.475361
## 41 1 5 2.780586
## 42 2 5 3.295045
## 43 3 5 3.809504
## 44 4 5 4.323963
## 45 5 5 4.838422
## 46 6 5 5.352880
## 47 7 5 5.867339
## 48 8 5 6.381798
## 49 9 5 6.896257
## 50 10 5 7.410716
```
---
# Plot
```r
conditions %>%
mutate(model_pred = predict(m, newdata = conditions)) %>%
ggplot(aes(extrav, model_pred)) +
geom_line(aes(group = class))
```
<!-- -->
---
# One more quick example
Model an interaction
```r
m2 <- lmer(popular ~ extrav*sex + (extrav|class), popular,
control = lmerControl(optimizer = "bobyqa"))
```
---
# Model summary
```r
arm::display(m2)
```
```
## lmer(formula = popular ~ extrav * sex + (extrav | class), data = popular,
## control = lmerControl(optimizer = "bobyqa"))
## coef.est coef.se
## (Intercept) 2.23 0.20
## extrav 0.41 0.03
## sexgirl 0.95 0.16
## extrav:sexgirl 0.06 0.03
##
## Error terms:
## Groups Name Std.Dev. Corr
## class (Intercept) 1.63
## extrav 0.18 -0.94
## Residual 0.74
## ---
## number of obs: 2000, groups: class, 100
## AIC = 4890.7, DIC = 4836.6
## deviance = 4855.7
```
---
# Marginal effect
Let's look at the interaction between extraversion and sex
```r
conditions2 <- expand.grid(extrav = 1:10,
sex = c("girl", "boy"),
class = 0) %>%
mutate(pred = predict(m2,
newdata = .,
allow.new.levels = TRUE))
conditions2
```
```
## extrav sex class pred
## 1 1 girl 0 3.654686
## 2 2 girl 0 4.124926
## 3 3 girl 0 4.595165
## 4 4 girl 0 5.065404
## 5 5 girl 0 5.535643
## 6 6 girl 0 6.005883
## 7 7 girl 0 6.476122
## 8 8 girl 0 6.946361
## 9 9 girl 0 7.416600
## 10 10 girl 0 7.886840
## 11 1 boy 0 2.645470
## 12 2 boy 0 3.059526
## 13 3 boy 0 3.473583
## 14 4 boy 0 3.887640
## 15 5 boy 0 4.301697
## 16 6 boy 0 4.715754
## 17 7 boy 0 5.129811
## 18 8 boy 0 5.543868
## 19 9 boy 0 5.957925
## 20 10 boy 0 6.371982
```
---
# Plot
```r
ggplot(conditions2, aes(extrav, pred)) +
geom_line(aes(color = sex))
```
<!-- -->
---
class: inverse-red middle
# Questions?
---
class: inverse-blue middle
# Notation
### Introducing the Gelman and Hill notation
---
# Standard regression
Imagine we have a model like this
```r
m <- lm(mpg ~ disp + hp + drat, data = mtcars)
```
--
We would probably display this model like this
$$
`\begin{equation}
\operatorname{mpg} = \alpha + \beta_{1}(\operatorname{disp}) + \beta_{2}(\operatorname{hp}) + \beta_{3}(\operatorname{drat}) + \epsilon
\end{equation}`
$$
--
What we often don't show, is the distributional assumption of the residuals
$$
\epsilon \sim N\left(0, \sigma \right)
$$
---
# A different view
The model on the previous slide could also be displayed like this
$$
`\begin{aligned}
\hat{y} &= \alpha + \beta_{1}(\operatorname{disp}) + \beta_{2}(\operatorname{hp}) + \beta_{3}(\operatorname{drat}) \\\
\operatorname{mpg} &\sim N\left(\hat{y}, \sigma \right)
\end{aligned}`
$$
--
This makes the distributional assumptions clearer
--
Each `mpg` value is assumed generated from a normal distribution, with a mean structure according to `\(\hat{y}\)`, and an unknown standard deviation, `\(\sigma\)`.
---
# Simulate
### I'm not expecting you to follow along here
If we have a solid understanding of the distributional properties, we can simulate new data from the model
--
First let's set some population parameters
```r
n <- 1000
intercept <- 100
b1 <- 5
b2 <- -3
b3 <- 0.5
sigma <- 4.5
```
---
# Simulate
Next create some variables. The standard deviations relate to the standard errors - more variance in the predictor leads to lower standard errors.
```r
set.seed(123)
x1 <- rnorm(n, sd = 1)
x2 <- rnorm(n, sd = 2)
x3 <- rnorm(n, sd = 4)
```
--
## Create y-hat
```r
yhat <- intercept + b1*x1 + b2*x2 + b3*x3
```
---
# Generate data & test
```r
sim <- rnorm(n, yhat, sigma)
summary(lm(sim ~ x1 + x2 + x3))
```
```
##
## Call:
## lm(formula = sim ~ x1 + x2 + x3)
##
## Residuals:
## Min 1Q Median 3Q Max
## -13.7528 -2.8505 0.0021 3.0387 13.0151
##
## Coefficients:
## Estimate Std. Error t value Pr(>|t|)
## (Intercept) 99.96508 0.14141 706.92 <2e-16 ***
## x1 4.99415 0.14306 34.91 <2e-16 ***
## x2 -3.01827 0.07027 -42.95 <2e-16 ***
## x3 0.55792 0.03613 15.44 <2e-16 ***
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Residual standard error: 4.466 on 996 degrees of freedom
## Multiple R-squared: 0.7514, Adjusted R-squared: 0.7506
## F-statistic: 1003 on 3 and 996 DF, p-value: < 2.2e-16
```
---
# Generalizing
We can generalize this same basic approach to multilevel models
This is helpful because the error structure is more complicated
Using this approach helps us better understand the distributional assumptions of our model
---
# Simple example
I know we hate the HSB data but bear with me for a minute.
Consider this simple model
```r
library(lme4)
library(equatiomatic)
hsb_m0 <- lmer(math ~ ses + (1|sch.id), data = hsb)
```
---
# R&B
In Raudenbush and Bryk notation, the model on the prior slide would look like this
$$
`\begin{aligned}
\text{math}_{ij} &= \beta_{0j} + \beta_{1j}(\text{ses}) + e_{ij} \\\
\beta_{0j} &= \gamma_{00} + u_{0j} \\\
\beta_{1j} &= \gamma_{10}
\end{aligned}`
$$
--
.pull-left[
Generally, the distributional part is omitted, which in this case is
$$
`\begin{aligned}
&E\left(e_{ij} \right) = 0, \text{Var}\left(e_{ij} \right) = \sigma^2 \\\
&E\left(u_{0j} \right) = 0, \text{Var}\left(u_{0j} \right) = \tau_{00}
\end{aligned}`
$$
]
--
.pull-right[
Put differently
$$
`\begin{aligned}
e_{ij} &\sim N\left(0, \sigma^2 \right) \\\
u_{0j} &\sim N\left(0, \tau_{00} \right)
\end{aligned}`
$$
]
---
# G&H
In Gelman & Hill notation, this same model can be communicated as
$$
`\begin{aligned}
\operatorname{math}_{i} &\sim N \left(\alpha_{j[i]} + \beta_{1}(\operatorname{ses}), \sigma^2 \right) \\
\alpha_{j} &\sim N \left(\mu_{\alpha_{j}}, \sigma^2_{\alpha_{j}} \right)
\text{, for sch.id j = 1,} \dots \text{,J}
\end{aligned}`
$$
--
This notation communicates the distributional assumptions
--
We can also still easily see what levels the predictors are at
--
It does look a little more complex, but it's not hiding anything
--
If you properly understand the notation, you can simultate data assuming this data generating process (which we'll do later)
---
# Bonus
It works really well to communicate model results
$$
`\begin{aligned}
\operatorname{\widehat{math}}_{i} &\sim N \left(12.66_{\alpha_{j[i]}} + 2.39_{\beta_{1}}(\operatorname{ses}), \sigma^2 \right) \\
\alpha_{j} &\sim N \left(0, 2.18 \right)
\text{, for sch.id j = 1,} \dots \text{,J}
\end{aligned}`
$$
--
### Extra bonus!
You can use equatiomatic to give you the model formula. The above was generated with `extract_eq(hsb_m0, use_coef = TRUE)`
---
# Quick simulation
We'll go over this in more detail later, but I want to give you the general idea.
First, set some parameters
```r
j <- 30 # 30 schools
nj <- 50 # 50 students per school
```
Next, simulate the school distribution
```r
# School distribution
a_j <- rnorm(j, 0, 2.18)
```
---
For each school, simulate nj obs from the level 1 model, adding in the school deviation
There are lots of ways to do this - I'm using a `for()` loop here in an effort to be transparent
```r
school_scores <- vector("list", j)
ses <- vector("list", j)
for(i in 1:j) {
ses[[i]] <- rnorm(nj)
school_scores[[i]] <- rnorm(nj,
12.66 + 2.39*ses[[i]] + a_j[i],
6.09)
}
```
---
# Put in a df
```r
sim_df <- data.frame(
scid = rep(1:j, each = nj),
ses = unlist(ses),
score = unlist(school_scores)
)
head(sim_df)
```
```
## scid ses score
## 1 1 -0.9529766 9.789073
## 2 1 0.4057701 12.820300
## 3 1 -0.9839385 20.956667
## 4 1 -1.6101230 15.884079
## 5 1 -0.4301688 1.363627
## 6 1 -1.2242106 7.820335
```
---
# Test it out
```r
sim_m0 <- lmer(score ~ ses + (1|scid), data = sim_df)
summary(sim_m0)
```
```
## Linear mixed model fit by REML ['lmerMod']
## Formula: score ~ ses + (1 | scid)
## Data: sim_df
##
## REML criterion at convergence: 9704.9
##
## Scaled residuals:
## Min 1Q Median 3Q Max
## -3.1418 -0.6848 0.0030 0.6552 3.5886
##
## Random effects:
## Groups Name Variance Std.Dev.
## scid (Intercept) 5.685 2.384
## Residual 36.187 6.016
## Number of obs: 1500, groups: scid, 30
##
## Fixed effects:
## Estimate Std. Error t value
## (Intercept) 12.3901 0.4622 26.81
## ses 2.4682 0.1562 15.80
##
## Correlation of Fixed Effects:
## (Intr)
## ses -0.002
```
---
# Expanding the model
Let's add a school-level predictor
--
```r
hsb_m1 <- lmer(math ~ ses + sector + (1|sch.id), data = hsb)
```
--
```r
extract_eq(hsb_m1)
```
$$
`\begin{aligned}
\operatorname{math}_{i} &\sim N \left(\alpha_{j[i]} + \beta_{1}(\operatorname{ses}), \sigma^2 \right) \\
\alpha_{j} &\sim N \left(\gamma_{0}^{\alpha} + \gamma_{1}^{\alpha}(\operatorname{sector}), \sigma^2_{\alpha_{j}} \right)
\text{, for sch.id j = 1,} \dots \text{,J}
\end{aligned}`
$$
---
# Add in a random slope
.small80[
```r
hsb_m2 <- lmer(math ~ ses + sector + (ses|sch.id), data = hsb)
extract_eq(hsb_m2)
```
$$
`\begin{aligned}
\operatorname{math}_{i} &\sim N \left(\alpha_{j[i]} + \beta_{1j[i]}(\operatorname{ses}), \sigma^2 \right) \\
\left(
\begin{array}{c}
\begin{aligned}
&\alpha_{j} \\
&\beta_{1j}
\end{aligned}
\end{array}
\right)
&\sim N \left(
\left(
\begin{array}{c}
\begin{aligned}
&\gamma_{0}^{\alpha} + \gamma_{1}^{\alpha}(\operatorname{sector}) \\
&\mu_{\beta_{1j}}
\end{aligned}
\end{array}
\right)
,
\left(
\begin{array}{cc}
\sigma^2_{\alpha_{j}} & \rho_{\alpha_{j}\beta_{1j}} \\
\rho_{\beta_{1j}\alpha_{j}} & \sigma^2_{\beta_{1j}}
\end{array}
\right)
\right)
\text{, for sch.id j = 1,} \dots \text{,J}
\end{aligned}`
$$
]
---
# Include interaction
Include `sector` as a predictor of the relation between `ses` and `math`
.small80[
```r
hsb_m3 <- lmer(math ~ ses * sector + (ses|sch.id), data = hsb,
control = lmerControl(optimizer = "nmkbw"))
extract_eq(hsb_m3)
```
$$
`\begin{aligned}
\operatorname{math}_{i} &\sim N \left(\alpha_{j[i]} + \beta_{1j[i]}(\operatorname{ses}), \sigma^2 \right) \\
\left(
\begin{array}{c}
\begin{aligned}
&\alpha_{j} \\
&\beta_{1j}
\end{aligned}
\end{array}
\right)
&\sim N \left(
\left(
\begin{array}{c}
\begin{aligned}
&\gamma_{0}^{\alpha} + \gamma_{1}^{\alpha}(\operatorname{sector}) \\
&\gamma^{\beta_{1}}_{0} + \gamma^{\beta_{1}}_{1}(\operatorname{sector})
\end{aligned}
\end{array}
\right)
,
\left(
\begin{array}{cc}
\sigma^2_{\alpha_{j}} & \rho_{\alpha_{j}\beta_{1j}} \\
\rho_{\beta_{1j}\alpha_{j}} & \sigma^2_{\beta_{1j}}
\end{array}
\right)
\right)
\text{, for sch.id j = 1,} \dots \text{,J}
\end{aligned}`
$$
]
---
# Even more complicated
This model doesn't actually fit well - I omitted some convergence warnings
.small50[
```r
hsb_m4 <- lmer(
math ~ ses * sector + minority + female + meanses + size +
(ses + minority + female|sch.id),
data = hsb
)
extract_eq(hsb_m4)
```
$$
`\begin{aligned}
\operatorname{math}_{i} &\sim N \left(\mu, \sigma^2 \right) \\
\mu &=\alpha_{j[i]} + \beta_{1j[i]}(\operatorname{ses}) + \beta_{2j[i]}(\operatorname{minority}) + \beta_{3j[i]}(\operatorname{female}) \\
\left(
\begin{array}{c}
\begin{aligned}
&\alpha_{j} \\
&\beta_{1j} \\
&\beta_{2j} \\
&\beta_{3j}
\end{aligned}
\end{array}
\right)
&\sim N \left(
\left(
\begin{array}{c}
\begin{aligned}
&\gamma_{0}^{\alpha} + \gamma_{1}^{\alpha}(\operatorname{sector}) + \gamma_{2}^{\alpha}(\operatorname{meanses}) + \gamma_{3}^{\alpha}(\operatorname{size}) \\
&\gamma^{\beta_{1}}_{0} + \gamma^{\beta_{1}}_{1}(\operatorname{sector}) \\
&\mu_{\beta_{2j}} \\
&\mu_{\beta_{3j}}
\end{aligned}
\end{array}
\right)
,
\left(
\begin{array}{cccc}
\sigma^2_{\alpha_{j}} & \rho_{\alpha_{j}\beta_{1j}} & \rho_{\alpha_{j}\beta_{2j}} & \rho_{\alpha_{j}\beta_{3j}} \\
\rho_{\beta_{1j}\alpha_{j}} & \sigma^2_{\beta_{1j}} & \rho_{\beta_{1j}\beta_{2j}} & \rho_{\beta_{1j}\beta_{3j}} \\
\rho_{\beta_{2j}\alpha_{j}} & \rho_{\beta_{2j}\beta_{1j}} & \sigma^2_{\beta_{2j}} & \rho_{\beta_{2j}\beta_{3j}} \\
\rho_{\beta_{3j}\alpha_{j}} & \rho_{\beta_{3j}\beta_{1j}} & \rho_{\beta_{3j}\beta_{2j}} & \sigma^2_{\beta_{3j}}
\end{array}
\right)
\right)
\text{, for sch.id j = 1,} \dots \text{,J}
\end{aligned}`
$$
]
---
# Multiple levels
Let's go to a different dataset from equatiomatic
```r
head(sim_longitudinal)
```
```
## # A tibble: 6 x 8
## # Groups: school [1]
## sid school district group treatment prop_low wave score
## <int> <int> <int> <chr> <fct> <dbl> <dbl> <dbl>
## 1 1 1 1 medium 1 0.1428571 0 102.2686
## 2 1 1 1 medium 1 0.1428571 1 102.0135
## 3 1 1 1 medium 1 0.1428571 2 102.5216
## 4 1 1 1 medium 1 0.1428571 3 102.2792
## 5 1 1 1 medium 1 0.1428571 4 102.2834
## 6 1 1 1 medium 1 0.1428571 5 102.7963
```
---
# Four levels
Model doesn't really fit again
.small70[
```r
sl_m <- lmer(
score ~ wave*treatment + group + prop_low +
(wave|sid) + (wave + treatment| school) + (1|district),
data = sim_longitudinal
)
extract_eq(sl_m)
```
$$
`\begin{aligned}
\operatorname{score}_{i} &\sim N \left(\alpha_{j[i],k[i],l[i]} + \beta_{1j[i],k[i]}(\operatorname{wave}), \sigma^2 \right) \\
\left(
\begin{array}{c}
\begin{aligned}
&\alpha_{j} \\
&\beta_{1j}
\end{aligned}
\end{array}
\right)
&\sim N \left(
\left(
\begin{array}{c}
\begin{aligned}
&\gamma_{0}^{\alpha} + \gamma_{1k[i]}^{\alpha}(\operatorname{treatment}_{\operatorname{1}}) + \gamma_{2}^{\alpha}(\operatorname{group}_{\operatorname{low}}) + \gamma_{3}^{\alpha}(\operatorname{group}_{\operatorname{medium}}) \\
&\gamma^{\beta_{1}}_{0} + \gamma^{\beta_{1}}_{1}(\operatorname{treatment}_{\operatorname{1}})
\end{aligned}
\end{array}
\right)
,
\left(
\begin{array}{cc}
\sigma^2_{\alpha_{j}} & \rho_{\alpha_{j}\beta_{1j}} \\
\rho_{\beta_{1j}\alpha_{j}} & \sigma^2_{\beta_{1j}}
\end{array}
\right)
\right)
\text{, for sid j = 1,} \dots \text{,J} \\
\left(
\begin{array}{c}
\begin{aligned}
&\alpha_{k} \\
&\beta_{1k} \\
&\gamma_{1k}
\end{aligned}
\end{array}
\right)
&\sim N \left(
\left(
\begin{array}{c}
\begin{aligned}
&\gamma_{0}^{\alpha} + \gamma_{1}^{\alpha}(\operatorname{prop\_low}) \\
&\mu_{\beta_{1k}} \\
&\mu_{\gamma_{1k}}
\end{aligned}
\end{array}
\right)
,
\left(
\begin{array}{ccc}
\sigma^2_{\alpha_{k}} & \rho_{\alpha_{k}\beta_{1k}} & \rho_{\alpha_{k}\gamma_{1k}} \\
\rho_{\beta_{1k}\alpha_{k}} & \sigma^2_{\beta_{1k}} & \rho_{\beta_{1k}\gamma_{1k}} \\
\rho_{\gamma_{1k}\alpha_{k}} & \rho_{\gamma_{1k}\beta_{1k}} & \sigma^2_{\gamma_{1k}}
\end{array}
\right)
\right)
\text{, for school k = 1,} \dots \text{,K} \\ \alpha_{l} &\sim N \left(\mu_{\alpha_{l}}, \sigma^2_{\alpha_{l}} \right)
\text{, for district l = 1,} \dots \text{,L}
\end{aligned}`
$$
]
---
class: inverse-blue middle
# Residual structures
---
# Data
[Willett, 1988](https://www.jstor.org/stable/1167368?seq=1#metadata_info_tab_contents)
* `\(n\)` = 35 people
* Each completed a cognitive inventory on "opposites naming"
* At first time point, participants also completed a general cognitive measure
---
# Read in data
```r
willett <- read_csv(here::here("data", "willett-1988.csv"))
willett
```
```
## # A tibble: 140 x 4
## id time opp cog
## <dbl> <dbl> <dbl> <dbl>
## 1 1 0 205 137
## 2 1 1 217 137
## 3 1 2 268 137
## 4 1 3 302 137
## 5 2 0 219 123
## 6 2 1 243 123
## 7 2 2 279 123
## 8 2 3 302 123
## 9 3 0 142 129
## 10 3 1 212 129
## # … with 130 more rows
```
---
# Standard OLS
* We have four observations per participant.
* If we fit a standard OLS model, it would look like this
```r
bad <- lm(opp ~ time, data = willett)
summary(bad)
```
```
##
## Call:
## lm(formula = opp ~ time, data = willett)
##
## Residuals:
## Min 1Q Median 3Q Max
## -88.374 -25.584 1.186 28.926 64.746
##
## Coefficients:
## Estimate Std. Error t value Pr(>|t|)
## (Intercept) 164.374 5.035 32.65 <2e-16 ***
## time 26.960 2.691 10.02 <2e-16 ***
## ---
## Signif. codes: 0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
##
## Residual standard error: 35.6 on 138 degrees of freedom
## Multiple R-squared: 0.421, Adjusted R-squared: 0.4168
## F-statistic: 100.3 on 1 and 138 DF, p-value: < 2.2e-16
```
---
# Assumptions
As we discussed previously, this model looks like this
$$
\operatorname{opp} = \alpha + \beta_{1}(\operatorname{time}) + \epsilon
$$
where
$$
\epsilon \sim \left(0, \sigma \right)
$$
---
# Individual level residuals
We can expand our notation, so it looks like a multivariate normal distribution
$$
`\begin{equation}
\left(
\begin{array}{c}
\epsilon_1 \\\
\epsilon_2 \\\
\epsilon_3 \\\
\vdots \\\
\epsilon_n
\end{array}
\right)
\sim MVN
\left(
\left[
\begin{array}{c}
0\\\
0\\\
0\\\
\vdots \\\
0
\end{array}
\right],
\left[
\begin{array}{ccccc}
\sigma_{\epsilon} & 0 & 0 & \dots & 0 \\\
0 & \sigma_{\epsilon} & 0 & 0 & 0 \\\
0 & 0 & \sigma_{\epsilon} & 0 & 0 \\\
\vdots & 0 & 0 & \ddots & \vdots \\\
0 & 0 & 0 & \dots & \sigma_{\epsilon}
\end{array}
\right]
\right)
\end{equation}`
$$
This is where the `\(i.i.d.\)` part comes in. The residuals are assumed `\(i\)`ndependent and `\(i\)`dentically `\(d\)`istributed.
---
# Multilevel model
Very regularly, there are reasons to believe the `\(i.i.d.\)` assumption is violated. Consider our current case, with 4 time points for each individual.
* Is an observation for one time point for one individual *independent* from the other observations for that individual?
--
* Rather than estimating a single residual variance, we estimate an additional components associated with individuals, leading to a *block* diagonal structure
---
# Block diagonal
.small70[
$$
`\begin{equation}
\left(
\begin{array}{c}
\epsilon_{11} \\
\epsilon_{12} \\
\epsilon_{13} \\
\epsilon_{14} \\
\epsilon_{21} \\
\epsilon_{22} \\
\epsilon_{23} \\
\epsilon_{24} \\
\vdots \\
\epsilon_{n1} \\
\epsilon_{n2} \\
\epsilon_{n3} \\
\epsilon_{n4}
\end{array}
\right)
\sim
\left(
\left[
\begin{array}{c}
\\
0\\
0\\
0\\
0\\
0\\
0\\
0\\
0\\
\vdots \\
0\\
0\\
0\\
0
\end{array}
\right],
\left[
\begin{array}{{@{}*{13}c@{}}}
\\
\sigma_{11} & \sigma_{12} & \sigma_{13} & \sigma_{14} & 0 & 0 & 0 & 0 & \dots & 0 & 0 & 0 & 0 \\
\sigma_{21} & \sigma_{22} & \sigma_{23} & \sigma_{24} & 0 & 0 & 0 & 0 & \dots & 0 & 0 & 0 & 0 \\
\sigma_{31} & \sigma_{32} & \sigma_{33} & \sigma_{34} & 0 & 0 & 0 & 0 & \dots & 0 & 0 & 0 & 0 \\
\sigma_{41} & \sigma_{42} & \sigma_{43} & \sigma_{44} & 0 & 0 & 0 & 0 & \dots & 0 & 0 & 0 & 0 \\
0 & 0 & 0 & 0 & \sigma_{11} & \sigma_{12} & \sigma_{13} & \sigma_{14} & \dots & 0 & 0 & 0 & 0 \\
0 & 0 & 0 & 0 & \sigma_{21} & \sigma_{22} & \sigma_{23} & \sigma_{24} & \dots & 0 & 0 & 0 & 0 \\
0 & 0 & 0 & 0 & \sigma_{31} & \sigma_{32} & \sigma_{33} & \sigma_{34} & \dots & 0 & 0 & 0 & 0 \\
0 & 0 & 0 & 0 & \sigma_{41} & \sigma_{42} & \sigma_{43} & \sigma_{44} & \dots & 0 & 0 & 0 & 0 \\
\vdots & \vdots & \vdots & \vdots & \vdots & \vdots & \vdots & \vdots & \ddots & \vdots & \vdots & \vdots & \vdots \\
0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & \dots & \sigma_{11} & \sigma_{12} & \sigma_{13} & \sigma_{14} \\
0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & \dots & \sigma_{21} & \sigma_{22} & \sigma_{23} & \sigma_{24} \\
0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & \dots & \sigma_{31} & \sigma_{32} & \sigma_{33} & \sigma_{34} \\
0 & 0 & 0 & 0 & 0 & 0 & 0 & 0 & \dots & \sigma_{41} & \sigma_{42} & \sigma_{43} & \sigma_{44}
\end{array}
\right]
\right)
\end{equation}`
$$
]
--
Correlations for off-diagonals estimated
--
Same variance components for all blocks
--
Out-of-block diagonals are still zero
---
# Homogeneity of variance
As mentioned on the previous slide, we assume the same variance components across all student
This is referred to as the homogeneity of variance assumption - although the block (often referred to as the composite residual) may be heteroscedastic and dependent **within** a grouping factor (i.e., people) the entire error structure is repeated identically across units (i.e., people)
---
# Block diagonal
Because of the homogeneity of variance assumption, we can re-express our block diagonal design as follows
$$
`\begin{equation}
r \sim N \left(\boldsymbol{0},
\left[
\begin{array}{ccccc}
\boldsymbol{\Sigma_r} & \boldsymbol{0} & \boldsymbol{0} & \dots & \boldsymbol{0} \\
\boldsymbol{0} & \boldsymbol{\Sigma_r} & \boldsymbol{0} & \dots & \boldsymbol{0} \\
\boldsymbol{0} & \boldsymbol{0} & \boldsymbol{\Sigma_r} & \dots & \boldsymbol{0} \\
\vdots & \vdots & \vdots & \ddots & \vdots & \\
\boldsymbol{0} & \boldsymbol{0} & \boldsymbol{0} & \dots & \boldsymbol{\Sigma_r}
\end{array}
\right]
\right)
\end{equation}`
$$
---
# Composite residual
We then define the composite residual, which is common across units
$$
`\begin{equation}
\boldsymbol{\Sigma_r} = \left[
\begin{array}{cccc}
\sigma_{11} & \sigma_{12} & \sigma_{13} & \sigma_{14} \\
\sigma_{21} & \sigma_{22} & \sigma_{23} & \sigma_{24} \\
\sigma_{31} & \sigma_{32} & \sigma_{33} & \sigma_{34} \\
\sigma_{41} & \sigma_{42} & \sigma_{43} & \sigma_{44}
\end{array}
\right]
\end{equation}`
$$
---
# Let's try!
Let's fit a parallel slopes model with the Willett data. You try first.
<div class="countdown" id="timer_60b90245" style="right:0;bottom:0;" data-warnwhen="0">
<code class="countdown-time"><span class="countdown-digits minutes">02</span><span class="countdown-digits colon">:</span><span class="countdown-digits seconds">00</span></code>
</div>
--
```r
w0 <- lmer(opp ~ time + (1|id), willett)
```
--
What does the residual variance-covariance look like? Let's use **sundry** to pull it
```r
library(sundry)
w0_rvcv <- pull_residual_vcov(w0)
```
---
# Image
Sparse matrix - we can view it with `image()`
```r
image(w0_rvcv)
```
<!-- -->
---
# Pull first few rows/cols
```r
w0_rvcv[1:8, 1:8]
```
```
## 8 x 8 sparse Matrix of class "dgCMatrix"
## 1 2 3 4 5 6 7 8
## 1 1280.7065 904.8054 904.8054 904.8054 . . . .
## 2 904.8054 1280.7065 904.8054 904.8054 . . . .
## 3 904.8054 904.8054 1280.7065 904.8054 . . . .
## 4 904.8054 904.8054 904.8054 1280.7065 . . . .
## 5 . . . . 1280.7065 904.8054 904.8054 904.8054
## 6 . . . . 904.8054 1280.7065 904.8054 904.8054
## 7 . . . . 904.8054 904.8054 1280.7065 904.8054
## 8 . . . . 904.8054 904.8054 904.8054 1280.7065
```
---
class: inverse-green middle
# Next time
## Modeling growth (part 1)
### Also Homework 2 is assigned
</textarea>
<style data-target="print-only">@media screen {.remark-slide-container{display:block;}.remark-slide-scaler{box-shadow:none;}}</style>
<script src="https://remarkjs.com/downloads/remark-latest.min.js"></script>
<script src="https://platform.twitter.com/widgets.js"></script>
<script>var slideshow = remark.create({
"navigation": {
"scroll": false
},
"highlightLines": true,
"countIncrementalSlides": false
});
if (window.HTMLWidgets) slideshow.on('afterShowSlide', function (slide) {
window.dispatchEvent(new Event('resize'));
});
(function(d) {
var s = d.createElement("style"), r = d.querySelector(".remark-slide-scaler");
if (!r) return;
s.type = "text/css"; s.innerHTML = "@page {size: " + r.style.width + " " + r.style.height +"; }";
d.head.appendChild(s);
})(document);
(function(d) {
var el = d.getElementsByClassName("remark-slides-area");
if (!el) return;
var slide, slides = slideshow.getSlides(), els = el[0].children;
for (var i = 1; i < slides.length; i++) {
slide = slides[i];
if (slide.properties.continued === "true" || slide.properties.count === "false") {
els[i - 1].className += ' has-continuation';
}
}
var s = d.createElement("style");
s.type = "text/css"; s.innerHTML = "@media print { .has-continuation { display: none; } }";
d.head.appendChild(s);
})(document);
// delete the temporary CSS (for displaying all slides initially) when the user
// starts to view slides
(function() {
var deleted = false;
slideshow.on('beforeShowSlide', function(slide) {
if (deleted) return;
var sheets = document.styleSheets, node;
for (var i = 0; i < sheets.length; i++) {
node = sheets[i].ownerNode;
if (node.dataset["target"] !== "print-only") continue;
node.parentNode.removeChild(node);
}
deleted = true;
});
})();
(function() {
"use strict"
// Replace <script> tags in slides area to make them executable
var scripts = document.querySelectorAll(
'.remark-slides-area .remark-slide-container script'
);
if (!scripts.length) return;
for (var i = 0; i < scripts.length; i++) {
var s = document.createElement('script');
var code = document.createTextNode(scripts[i].textContent);
s.appendChild(code);
var scriptAttrs = scripts[i].attributes;
for (var j = 0; j < scriptAttrs.length; j++) {
s.setAttribute(scriptAttrs[j].name, scriptAttrs[j].value);
}
scripts[i].parentElement.replaceChild(s, scripts[i]);
}
})();
(function() {
var links = document.getElementsByTagName('a');
for (var i = 0; i < links.length; i++) {
if (/^(https?:)?\/\//.test(links[i].getAttribute('href'))) {
links[i].target = '_blank';
}
}
})();
// adds .remark-code-has-line-highlighted class to <pre> parent elements
// of code chunks containing highlighted lines with class .remark-code-line-highlighted
(function(d) {
const hlines = d.querySelectorAll('.remark-code-line-highlighted');
const preParents = [];
const findPreParent = function(line, p = 0) {
if (p > 1) return null; // traverse up no further than grandparent
const el = line.parentElement;
return el.tagName === "PRE" ? el : findPreParent(el, ++p);
};
for (let line of hlines) {
let pre = findPreParent(line);
if (pre && !preParents.includes(pre)) preParents.push(pre);
}
preParents.forEach(p => p.classList.add("remark-code-has-line-highlighted"));
})(document);</script>
<script>
slideshow._releaseMath = function(el) {
var i, text, code, codes = el.getElementsByTagName('code');
for (i = 0; i < codes.length;) {
code = codes[i];
if (code.parentNode.tagName !== 'PRE' && code.childElementCount === 0) {
text = code.textContent;
if (/^\\\((.|\s)+\\\)$/.test(text) || /^\\\[(.|\s)+\\\]$/.test(text) ||
/^\$\$(.|\s)+\$\$$/.test(text) ||
/^\\begin\{([^}]+)\}(.|\s)+\\end\{[^}]+\}$/.test(text)) {
code.outerHTML = code.innerHTML; // remove <code></code>
continue;
}
}
i++;
}
};
slideshow._releaseMath(document);
</script>
<!-- dynamically load mathjax for compatibility with self-contained -->
<script>
(function () {
var script = document.createElement('script');
script.type = 'text/javascript';
script.src = 'https://mathjax.rstudio.com/latest/MathJax.js?config=TeX-MML-AM_CHTML';
if (location.protocol !== 'file:' && /^https?:/.test(script.src))
script.src = script.src.replace(/^https?:/, '');
document.getElementsByTagName('head')[0].appendChild(script);
})();
</script>
</body>
</html>
| 24.886188 | 288 | 0.574749 |
5c6d6d7934e6b231bfa9456c41cd92447a4d98e0 | 746 | css | CSS | data/usercss/75074.user.css | 33kk/uso-archive | 2c4962d1d507ff0eaec6dcca555efc531b37a9b4 | [
"MIT"
] | 118 | 2020-08-28T19:59:28.000Z | 2022-03-26T16:28:40.000Z | data/usercss/75074.user.css | 33kk/uso-archive | 2c4962d1d507ff0eaec6dcca555efc531b37a9b4 | [
"MIT"
] | 38 | 2020-09-02T01:08:45.000Z | 2022-01-23T02:47:24.000Z | data/usercss/75074.user.css | 33kk/uso-archive | 2c4962d1d507ff0eaec6dcca555efc531b37a9b4 | [
"MIT"
] | 21 | 2020-08-19T01:12:43.000Z | 2022-03-15T21:55:17.000Z | /* ==UserStyle==
@name Jeremy Renner Icons 2
@namespace USO Archive
@author maybeaperson
@description `Changes text, photo, quote, etc. icons into pictures of Jeremy Renner's glorious face.`
@version 20120917.4.15
@license NO-REDISTRIBUTION
@preprocessor uso
==/UserStyle== */
@-moz-document domain(tumblr.com) {
.new_post_label{
font-size:0px !important;
}
.new_post_label_icon{background-image:none !important}
/* Code repaired by admin. See http://forum.userstyles.org/discussion/37591/attempting-to-mass-fix-broken-tumblr-dash-icon-styles */
#new_post{
background: url(http://media.tumblr.com/tumblr_mahitcuv0K1r9f6ce.png) center no-repeat !important;
background-color:#fff !important;
}
} | 33.909091 | 132 | 0.72252 |
a9986cf1ead150b8d5210cbcf435c3cfde44cd6e | 1,983 | tab | SQL | landes-bioscience/_journals.tab | rordi/journals | ce4a95e86987ebf0815fa7fdde6da433e31d359a | [
"MIT"
] | 35 | 2016-03-11T06:00:00.000Z | 2022-03-01T06:01:31.000Z | landes-bioscience/_journals.tab | rordi/journals | ce4a95e86987ebf0815fa7fdde6da433e31d359a | [
"MIT"
] | 87 | 2016-03-18T04:38:05.000Z | 2022-01-25T13:03:08.000Z | landes-bioscience/_journals.tab | rordi/journals | ce4a95e86987ebf0815fa7fdde6da433e31d359a | [
"MIT"
] | 25 | 2016-03-20T14:29:14.000Z | 2021-11-24T14:39:40.000Z | Title ISSN eISSN Field
Adipocyte 2162-3945 2162-397X medicine
Artificial DNA: PNA & XNA 1949-095X 1949-0968 biology
Autophagy 1554-8627 1554-8635 biology
Bacteriophage 2159-7073 2159-7081 medicine
Bioarchitecture 1949-0992 1949-100X biology
Bioengineered 1949-1018 1949-1026 biology
Biomatter 2159-2527 2159-2535 medicine
Cancer Biology & Therapy 1538-4047 1555-8576 medicine
Cell Adhesion & Migration 1933-6918 1933-6926 medicine
Cell Cycle 1538-4101 1551-4005 biology
Cellular Logistics 2159-2780 2159-2799 biology
Channels 1933-6950 1933-6969 biology
Chimerism 1938-1956 1938-1964 biology
Communicative & Integrative Biology x 1942-0889 biology
Dermato-Endocrinology 1938-1972 1938-1980 medicine
Disaster Health 2166-5044 2166-5052 medicine
Endocrine Disruptors 2327-3747 medicine
Epigenetics 1559-2294 1559-2308 biology
Fly 1933-6934 1933-6942 biology
GM Crops and Food: Biotechnology in Agriculture and the Food Chain 1938-1999 1938-2006 biology
Gut Microbes 1949-0976 1949-0984 medicine
h bioscience 2166-708X 2166-7098 medicine
Human Vaccines & Immunotherapeutics 1554-8600 1554-8619 medicine
Immunomics x 2324-9633 medicine
IntraVital 2165-9079 2165-9087 medicine
Intrinsically Disordered Proteins x 2169-0707 biology
Islets 1938-2014 1938-2022 medicine
JAK-STAT x 2162-3996 medicine
mAbs 1942-0862 1942-0870 medicine
Mobile Genetic Elements 2159-2543 2159-256X biology
Nucleus 1949-1034 1949-1042 biology
OncoImmunology 2162-4011 2162-402X medicine
Organogenesis 1547-6278 1555-8592 biology
Plant Signaling & Behavior 1559-2316 1559-2324 biology
Prion 1993-6896 1933-690X biology
Rare Diseases x 2167-5511 medicine
RNA Biology 1547-6286 1555-8584 biology
Small GTPases 2154-1248 2154-1256 biology
Spermatogenesis 2156-5554 2156-5562 biology
Systems Biomedicine 2162-8130 2162-8149 medicine
Tissue Barriers x 2168-8370 medicine
Transcription 2154-1264 2154-1272 biology
Translation x 2169-0731 biology
Virulence 2150-5594 2150-5608 medicine
Worm 2162-4046 2162-4054 biology
| 42.191489 | 94 | 0.838628 |
d92d013445b288f82b885d622a63185184f98571 | 61 | sql | SQL | src/test/resources/sql/drop_table/1e55923f.sql | Shuttl-Tech/antlr_psql | fcf83192300abe723f3fd3709aff5b0c8118ad12 | [
"MIT"
] | 66 | 2018-06-15T11:34:03.000Z | 2022-03-16T09:24:49.000Z | src/test/resources/sql/drop_table/1e55923f.sql | Shuttl-Tech/antlr_psql | fcf83192300abe723f3fd3709aff5b0c8118ad12 | [
"MIT"
] | 13 | 2019-03-19T11:56:28.000Z | 2020-08-05T04:20:50.000Z | src/test/resources/sql/drop_table/1e55923f.sql | Shuttl-Tech/antlr_psql | fcf83192300abe723f3fd3709aff5b0c8118ad12 | [
"MIT"
] | 28 | 2019-01-05T19:59:02.000Z | 2022-03-24T11:55:50.000Z | -- file:insert.sql ln:377 expect:true
drop table inserttest3
| 20.333333 | 37 | 0.786885 |
b2f42395c99cb32b176d6e1140d0291edc965ff1 | 1,210 | py | Python | src/amuse/community/sei/test_sei.py | joshuawall/amuse | c2034074ee76c08057c4faa96c32044ab40952e9 | [
"Apache-2.0"
] | 1 | 2019-12-28T22:47:51.000Z | 2019-12-28T22:47:51.000Z | src/amuse/community/sei/test_sei.py | joshuawall/amuse | c2034074ee76c08057c4faa96c32044ab40952e9 | [
"Apache-2.0"
] | null | null | null | src/amuse/community/sei/test_sei.py | joshuawall/amuse | c2034074ee76c08057c4faa96c32044ab40952e9 | [
"Apache-2.0"
] | 2 | 2021-11-19T04:41:37.000Z | 2021-11-20T02:11:17.000Z | from amuse.test.amusetest import TestWithMPI
from amuse.units import nbody_system
from amuse.units import units
import os
import sys
import numpy
import math
from amuse.community.sei.interface import SeiInterface
from amuse.community.sei.interface import Sei
from amuse import datamodel
class TestSeiInterface(TestWithMPI):
def test0(self):
instance = SeiInterface()
instance.initialization()
instance.set_state(0,1,0,0,0,0,0)
for i in range(0,10):
instance.evolve(i)
print instance.get_state(0)
instance.stop()
class TestSei(TestWithMPI):
def test0(self):
convert_nbody = nbody_system.nbody_to_si(1.0 | units.MSun, 1 | units.AU)
particle = datamodel.Particles(1)
particle.position = [1.0, 0.0, 0.0,]|units.AU
particle.velocity = [0.0, 2.0*3.1415926535*1.0/365, 0.0] | units.AUd
sei = Sei(convert_nbody)
sei.initialization()
sei.particles.add_particles(particle)
print sei.particles.position.x.value_in(units.AU)
for i in range(365):
sei.evolve_model(i|units.day)
print sei.particles.position.x.value_in(units.AU)
| 29.512195 | 80 | 0.661157 |
24a7a81d8efd6d37d35f80ef4bac69d33844c9f2 | 652 | swift | Swift | Data/Network/Models/MovieDB/ResponseModel.swift | timstudt/movieDB | e5beefb0410559e90ee0a42f5b2bd372bad3ef8e | [
"MIT"
] | 1 | 2019-07-15T09:44:25.000Z | 2019-07-15T09:44:25.000Z | Data/Network/Models/MovieDB/ResponseModel.swift | timstudt/movieDB | e5beefb0410559e90ee0a42f5b2bd372bad3ef8e | [
"MIT"
] | 33 | 2018-04-04T12:45:17.000Z | 2021-09-21T20:01:47.000Z | Data/Network/Models/MovieDB/ResponseModel.swift | timstudt/movieDB | e5beefb0410559e90ee0a42f5b2bd372bad3ef8e | [
"MIT"
] | 1 | 2020-02-19T08:16:08.000Z | 2020-02-19T08:16:08.000Z | //
// MovieDBResponseModel.swift
// MovieDB
//
// Created by Tim Studt on 31/03/2018.
// Copyright © 2018 Tim Studt. All rights reserved.
//
import Foundation
enum MovieDBNetwork {
///the response model all resources are wrapped in
struct Response<Result: Decodable>: Decodable {
let page: Int
let totalPages: Int
let totalResults: Int
let results: [Result]
// swiftlint:disable nesting
private enum CodingKeys: String, CodingKey {
case page
case totalPages = "total_pages"
case totalResults = "total_results"
case results
}
}
}
| 23.285714 | 54 | 0.615031 |
861e7c8fae430857009b817dd8fbc4e5045d4304 | 16,988 | go | Go | value_test.go | couchbase/dparval | 9def03782da875a2477c05bf64985db3f19f59ae | [
"Apache-2.0"
] | null | null | null | value_test.go | couchbase/dparval | 9def03782da875a2477c05bf64985db3f19f59ae | [
"Apache-2.0"
] | null | null | null | value_test.go | couchbase/dparval | 9def03782da875a2477c05bf64985db3f19f59ae | [
"Apache-2.0"
] | null | null | null | // Copyright (c) 2013 Couchbase, Inc.
// Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file
// except in compliance with the License. You may obtain a copy of the License at
// http://www.apache.org/licenses/LICENSE-2.0
// Unless required by applicable law or agreed to in writing, software distributed under the
// License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
// either express or implied. See the License for the specific language governing permissions
// and limitations under the License.
package dparval
import (
"compress/gzip"
"encoding/json"
"io/ioutil"
"os"
"reflect"
"testing"
// "time"
jsonpointer "github.com/dustin/go-jsonpointer"
)
var codeJSON []byte
func init() {
f, err := os.Open("testdata/code.json.gz")
if err != nil {
panic(err)
}
defer f.Close()
gz, err := gzip.NewReader(f)
if err != nil {
panic(err)
}
data, err := ioutil.ReadAll(gz)
if err != nil {
panic(err)
}
codeJSON = data
}
func TestTypeRecognition(t *testing.T) {
var tests = []struct {
input []byte
expectedType int
}{
{[]byte(`asdf`), NOT_JSON},
{[]byte(`null`), NULL},
{[]byte(`3.65`), NUMBER},
{[]byte(`-3.65`), NUMBER},
{[]byte(`"hello"`), STRING},
{[]byte(`["hello"]`), ARRAY},
{[]byte(`{"hello":7}`), OBJECT},
// with misc whitespace
{[]byte(` asdf`), NOT_JSON},
{[]byte(` null`), NULL},
{[]byte(` 3.65`), NUMBER},
{[]byte(` "hello"`), STRING},
{[]byte("\t[\"hello\"]"), ARRAY},
{[]byte("\n{\"hello\":7}"), OBJECT},
}
for _, test := range tests {
val := NewValueFromBytes(test.input)
actualType := val.Type()
if actualType != test.expectedType {
t.Errorf("Expected type of %s to be %d, got %d", string(test.input), test.expectedType, actualType)
}
}
}
func TestPathAccess(t *testing.T) {
val := NewValueFromBytes([]byte(`{"name":"marty","address":{"street":"sutton oaks"}}`))
var tests = []struct {
path string
result *Value
err error
}{
{"name", &Value{raw: []byte(`"marty"`), parsedType: STRING}, nil},
{"address", &Value{raw: []byte(`{"street":"sutton oaks"}`), parsedType: OBJECT}, nil},
{"dne", nil, &Undefined{"dne"}},
}
for _, test := range tests {
newval, err := val.Path(test.path)
if !reflect.DeepEqual(err, test.err) {
t.Errorf("Expected error %v got error %v for path %s", test.err, err, test.path)
}
if !reflect.DeepEqual(newval, test.result) {
t.Errorf("Expected %v got %v for path %s", test.result, newval, test.path)
}
}
}
func TestIndexAccess(t *testing.T) {
val := NewValueFromBytes([]byte(`["marty",{"type":"contact"}]`))
var tests = []struct {
index int
result *Value
err error
}{
{0, &Value{raw: []byte(`"marty"`), parsedType: STRING}, nil},
{1, &Value{raw: []byte(`{"type":"contact"}`), parsedType: OBJECT}, nil},
{2, nil, &Undefined{}},
}
for _, test := range tests {
newval, err := val.Index(test.index)
if !reflect.DeepEqual(err, test.err) {
t.Errorf("Expected error %v got error %v for index %d", test.err, err, test.index)
}
if !reflect.DeepEqual(newval, test.result) {
t.Errorf("Expected %v got %v for index %d", test.result, newval, test.index)
}
}
val = NewValue([]interface{}{"marty", map[string]interface{}{"type": "contact"}})
tests = []struct {
index int
result *Value
err error
}{
{0, &Value{parsedValue: "marty", parsedType: STRING}, nil},
{1, &Value{parsedValue: map[string]*Value{"type": NewValue("contact")}, parsedType: OBJECT}, nil},
{2, nil, &Undefined{}},
}
for _, test := range tests {
newval, err := val.Index(test.index)
if !reflect.DeepEqual(err, test.err) {
t.Errorf("Expected error %v got error %v for index %d", test.err, err, test.index)
}
if !reflect.DeepEqual(newval, test.result) {
t.Errorf("Expected %v got %v for index %d", test.result, newval, test.index)
}
}
}
func TestAliasOverrides(t *testing.T) {
val := NewValueFromBytes([]byte(`{"name":"marty","address":{"street":"sutton oaks"}}`))
val.SetPath("name", "steve")
name, err := val.Path("name")
if err != nil {
t.Errorf("Error getting path name")
}
nameVal := name.Value()
if nameVal != "steve" {
t.Errorf("Expected name to be steve, got %v", nameVal)
}
val = NewValueFromBytes([]byte(`["marty",{"type":"contact"}]`))
val.SetIndex(0, "gerald")
name, err = val.Index(0)
if err != nil {
t.Errorf("Error getting path name")
}
nameVal = name.Value()
if nameVal != "gerald" {
t.Errorf("Expected name to be gerald, got %v", nameVal)
}
}
func TestAttachments(t *testing.T) {
val := NewValueFromBytes([]byte(`{"name":"marty","address":{"street":"sutton oaks"}}`))
val.SetAttachment("meta", map[string]interface{}{"id": "doc1"})
meta := val.GetAttachment("meta").(map[string]interface{})
if meta == nil {
t.Errorf("metadata missing")
} else {
id := meta["id"].(string)
if id != "doc1" {
t.Errorf("Expected id doc1, got %v", id)
}
}
}
func TestRealWorkflow(t *testing.T) {
// get a doc from some source
doc := NewValueFromBytes([]byte(`{"name":"marty","address":{"street":"sutton oaks"}}`))
doc.SetAttachment("meta", map[string]interface{}{"id": "doc1"})
// mutate the document somehow
active := NewValue(true)
doc.SetPath("active", active)
testActiveVal, err := doc.Path("active")
if err != nil {
t.Errorf("Error accessing active in doc")
}
testActive := testActiveVal.Value()
if testActive != true {
t.Errorf("Expected active true, got %v", testActive)
}
// create an alias of this documents
top := NewValue(map[string]interface{}{"bucket": doc, "another": "rad"})
testDoc, err := top.Path("bucket")
if err != nil {
t.Errorf("Error accessing bucket in top")
}
if !reflect.DeepEqual(testDoc, doc) {
t.Errorf("Expected doc %v to match testDoc %v", doc, testDoc)
}
testRad, err := top.Path("another")
if err != nil {
t.Errorf("Error accessing another in top")
}
expectedRad := NewValue("rad")
if !reflect.DeepEqual(testRad, expectedRad) {
t.Errorf("Expected %v, got %v for rad", expectedRad, testRad)
}
// now project some value from the doc to a top-level alias
addressVal, err := doc.Path("address")
if err != nil {
t.Errorf("Error access path address in doc")
}
top.SetPath("a", addressVal)
// now access "a.street"
aVal, err := top.Path("a")
if err != nil {
t.Errorf("Error access a in top")
}
streetVal, err := aVal.Path("street")
if err != nil {
t.Errorf("Error accessing street in a")
}
street := streetVal.Value()
if street != "sutton oaks" {
t.Errorf("Expected sutton oaks, got %v", street)
}
}
func TestUndefined(t *testing.T) {
x := Undefined{"property"}
err := x.Error()
if err != "property is not defined" {
t.Errorf("Expected property is not defined, got %v", err)
}
y := Undefined{}
err = y.Error()
if err != "not defined" {
t.Errorf("Expected not defined, got %v", err)
}
}
func TestValue(t *testing.T) {
var tests = []struct {
input *Value
expectedValue interface{}
}{
{NewValue(nil), nil},
{NewValue(true), true},
{NewValue(false), false},
{NewValue(1.0), 1.0},
{NewValue(3.14), 3.14},
{NewValue(-7.0), -7.0},
{NewValue(""), ""},
{NewValue("marty"), "marty"},
{NewValue([]interface{}{"marty"}), []interface{}{"marty"}},
{NewValue([]interface{}{NewValue("marty2")}), []interface{}{"marty2"}},
{NewValue(map[string]interface{}{"marty": "cool"}), map[string]interface{}{"marty": "cool"}},
{NewValue(map[string]interface{}{"marty3": NewValue("cool")}), map[string]interface{}{"marty3": "cool"}},
{NewValueFromBytes([]byte("null")), nil},
{NewValueFromBytes([]byte("true")), true},
{NewValueFromBytes([]byte("false")), false},
{NewValueFromBytes([]byte("1")), 1.0},
{NewValueFromBytes([]byte("3.14")), 3.14},
{NewValueFromBytes([]byte("-7")), -7.0},
{NewValueFromBytes([]byte("\"\"")), ""},
{NewValueFromBytes([]byte("\"marty\"")), "marty"},
{NewValueFromBytes([]byte("[\"marty\"]")), []interface{}{"marty"}},
{NewValueFromBytes([]byte("{\"marty\": \"cool\"}")), map[string]interface{}{"marty": "cool"}},
{NewValueFromBytes([]byte("abc")), nil},
// new value from existing value
{NewValue(NewValue(true)), true},
}
for _, test := range tests {
val := test.input.Value()
if !reflect.DeepEqual(val, test.expectedValue) {
t.Errorf("Expected %#v, got %#v for %#v", test.expectedValue, val, test.input)
}
}
}
func TestValueOverlay(t *testing.T) {
val := NewValueFromBytes([]byte("{\"marty\": \"cool\"}"))
val.SetPath("marty", "ok")
expectedVal := map[string]interface{}{"marty": "ok"}
actualVal := val.Value()
if !reflect.DeepEqual(expectedVal, actualVal) {
t.Errorf("Expected %v, got %v, for value of %v", expectedVal, actualVal, val)
}
val = NewValue(map[string]interface{}{"marty": "cool"})
val.SetPath("marty", "ok")
actualVal = val.Value()
if !reflect.DeepEqual(expectedVal, actualVal) {
t.Errorf("Expected %v, got %v, for value of %v", expectedVal, actualVal, val)
}
val = NewValueFromBytes([]byte("[\"marty\"]"))
val.SetIndex(0, "gerald")
expectedVal2 := []interface{}{"gerald"}
actualVal = val.Value()
if !reflect.DeepEqual(expectedVal2, actualVal) {
t.Errorf("Expected %v, got %v, for value of %v", expectedVal2, actualVal, val)
}
val = NewValue([]interface{}{"marty"})
val.SetIndex(0, "gerald")
expectedVal2 = []interface{}{"gerald"}
actualVal = val.Value()
if !reflect.DeepEqual(expectedVal2, actualVal) {
t.Errorf("Expected %v, got %v, for value of %v", expectedVal2, actualVal, val)
}
}
func TestComplexOverlay(t *testing.T) {
// in this case we start with JSON bytes
// then add an alias
// then call value which causes it to be parsed
// then call value again, which goes through a different path with the already parsed data
val := NewValueFromBytes([]byte("{\"marty\": \"cool\"}"))
val.SetPath("marty", "ok")
expectedVal := map[string]interface{}{"marty": "ok"}
actualVal := val.Value()
if !reflect.DeepEqual(expectedVal, actualVal) {
t.Errorf("Expected %v, got %v, for value of %v", expectedVal, actualVal, val)
}
// now repeat the call to value
actualVal = val.Value()
if !reflect.DeepEqual(expectedVal, actualVal) {
t.Errorf("Expected %v, got %v, for value of %v", expectedVal, actualVal, val)
}
}
func TestUnmodifiedValuesFromBytesBackToBytes(t *testing.T) {
var tests = []struct {
input []byte
expectedBytes []byte
}{
{[]byte(`asdf`), []byte(`asdf`)},
{[]byte(`null`), []byte(`null`)},
{[]byte(`3.65`), []byte(`3.65`)},
{[]byte(`-3.65`), []byte(`-3.65`)},
{[]byte(`"hello"`), []byte(`"hello"`)},
{[]byte(`["hello"]`), []byte(`["hello"]`)},
{[]byte(`{"hello":7}`), []byte(`{"hello":7}`)},
// with misc whitespace
{[]byte(` asdf`), []byte(` asdf`)},
{[]byte(` null`), []byte(` null`)},
{[]byte(` 3.65`), []byte(` 3.65`)},
{[]byte(` "hello"`), []byte(` "hello"`)},
{[]byte(` "hello"`), []byte(` "hello"`)},
{[]byte("\n{\"hello\":7}"), []byte("\n{\"hello\":7}")},
}
for _, test := range tests {
val := NewValueFromBytes(test.input)
out := val.Bytes()
if !reflect.DeepEqual(out, test.expectedBytes) {
t.Errorf("Expected %s to be %s, got %s", string(test.input), string(test.expectedBytes), string(out))
}
}
}
func TestUnmodifiedValuesBackToBytes(t *testing.T) {
var tests = []struct {
input *Value
expectedBytes []byte
}{
{NewValue(nil), []byte(`null`)},
{NewValue(3.65), []byte(`3.65`)},
{NewValue(-3.65), []byte(`-3.65`)},
{NewValue("hello"), []byte(`"hello"`)},
{NewValue([]interface{}{"hello"}), []byte(`["hello"]`)},
{NewValue(map[string]interface{}{"hello": 7.0}), []byte(`{"hello":7}`)},
}
for _, test := range tests {
out := test.input.Bytes()
if !reflect.DeepEqual(out, test.expectedBytes) {
t.Errorf("Expected %v to be %s, got %s", test.input, string(test.expectedBytes), string(out))
}
}
}
func TestValuesWithAliasingBackToBytes(t *testing.T) {
val := NewValue(map[string]interface{}{"name": "marty", "level": 7.0})
val.SetPath("name", "gerald")
out := val.Bytes()
if !reflect.DeepEqual(out, []byte(`{"level":7,"name":"gerald"}`)) {
t.Errorf("Incorrect output %s", string(out))
}
val = NewValue([]interface{}{"name", "marty"})
val.SetIndex(1, "gerald")
out = val.Bytes()
if !reflect.DeepEqual(out, []byte(`["name","gerald"]`)) {
t.Errorf("Incorrect output %s", string(out))
}
}
func TestValuesFromBytesWithAliasingBackToBytes(t *testing.T) {
val := NewValueFromBytes([]byte(`{"name": "marty", "level": 7}`))
val.SetPath("name", "gerald")
out := val.Bytes()
if !reflect.DeepEqual(out, []byte(`{"level":7,"name":"gerald"}`)) {
t.Errorf("Incorrect output %s", string(out))
}
val = NewValueFromBytes([]byte(`["name", "marty"]`))
val.SetIndex(1, "gerald")
out = val.Bytes()
if !reflect.DeepEqual(out, []byte(`["name","gerald"]`)) {
t.Errorf("Incorrect output %s", string(out))
}
}
func BenchmarkLargeValue(b *testing.B) {
b.SetBytes(int64(len(codeJSON)))
keys := []interface{}{
"tree", "kids", 0, "kids", 0, "kids", 0, "kids", 0, "kids", 0, "name",
}
for i := 0; i < b.N; i++ {
var err error
val := NewValueFromBytes(codeJSON)
for _, key := range keys {
switch key := key.(type) {
case string:
val, err = val.Path(key)
if err != nil {
b.Errorf("error accessing path %v", key)
}
case int:
val, err = val.Index(key)
if err != nil {
b.Errorf("error accessing index %v", key)
}
}
}
value := val.Value()
if value.(string) != "ssh" {
b.Errorf("expected value ssh, got %v", value)
}
}
}
/* This benchmark contains a mix of Value creation of various data
types, Value() dereferencing, and SetIndex() and SetPath(). */
func BenchmarkProcessing(b *testing.B) {
vals := make([]*Value, 1<<16)
for i := 0; i < b.N; i++ {
for j := 0; j < len(vals); j++ {
val := make(map[string]interface{})
val["str"] = NewValue("string")
val["boolv"] = NewValue(true)
val["num"] = NewValue(1.0)
val["null"] = NewValue(nil)
arr := NewValue([]interface{}{"string", true, 1.0, nil})
arr.SetIndex(2, 1.0)
val["arr"] = arr
m := NewValue(map[string]interface{}{"string": "string", "bool": true, "num": 1.0, "null": nil})
m.SetPath("string", "string")
val["map"] = m
vals[j] = NewValue(val)
for k, v := range val {
actual := NewValue(v).Value()
if actual == nil {
val[k] = v
}
}
}
}
}
func BenchmarkLargeMap(b *testing.B) {
keys := []string{
"/tree/kids/0/kids/0/kids/0/kids/0/kids/0/name",
}
b.SetBytes(int64(len(codeJSON)))
for i := 0; i < b.N; i++ {
m := map[string]interface{}{}
err := json.Unmarshal(codeJSON, &m)
if err != nil {
b.Fatalf("Error parsing JSON: %v", err)
}
value := jsonpointer.Get(m, keys[0])
if value.(string) != "ssh" {
b.Errorf("expected value ssh, got %v", value)
}
}
}
func TestJsonPointerInvalidJSON(t *testing.T) {
bytes := []byte(`{"test":"value"`)
val, err := jsonpointer.Find(bytes, "/test")
if err != nil {
t.Errorf("unexpected error %v", err)
}
if !reflect.DeepEqual(val, []byte(`"value"`)) {
t.Errorf(`expected "value", got : %v`, string(val))
}
}
func TestDuplicateValueFromBytes(t *testing.T) {
val := NewValueFromBytes([]byte(`{"name":"marty","type":"contact","address":{"street":"sutton oaks"}}`))
val2 := val.Duplicate()
val2.SetPath("name", "bob")
name, err := val.Path("name")
if err != nil {
t.Errorf("unexpected error %v", err)
}
name2, err := val2.Path("name")
if err != nil {
t.Errorf("unexpected error %v", err)
}
if reflect.DeepEqual(name, name2) {
t.Errorf("expected different names")
}
typ, err := val.Path("type")
if err != nil {
t.Errorf("unexpected error %v", err)
}
typ2, err := val2.Path("type")
if err != nil {
t.Errorf("unexpected error %v", err)
}
if !reflect.DeepEqual(typ, typ2) {
t.Errorf("expected same types")
}
}
func TestDuplicateValueFromValue(t *testing.T) {
val := NewValue(map[string]interface{}{
"name": "marty",
"type": "contact",
"address": map[string]interface{}{
"street": "sutton oaks",
},
})
val2 := val.Duplicate()
val2.SetPath("name", "bob")
name, err := val.Path("name")
if err != nil {
t.Errorf("unexpected error %v", err)
}
name2, err := val2.Path("name")
if err != nil {
t.Errorf("unexpected error %v", err)
}
if reflect.DeepEqual(name, name2) {
t.Errorf("expected different names %s and %s", name, name2)
}
typ, err := val.Path("type")
if err != nil {
t.Errorf("unexpected error %v", err)
}
typ2, err := val2.Path("type")
if err != nil {
t.Errorf("unexpected error %v", err)
}
if !reflect.DeepEqual(typ, typ2) {
t.Errorf("expected same types")
}
}
func TestArraySetIndexLongerThanExistingArray(t *testing.T) {
val := NewValueFromBytes([]byte(`["x"]`))
val.SetIndex(1, "gerald")
valval := val.Value()
if !reflect.DeepEqual(valval, []interface{}{"x", "gerald"}) {
t.Errorf("Expected array containing x and geral,d got %v", valval)
}
}
| 27.444265 | 107 | 0.619084 |
16d6141211762a3741c14e3d1ad0ac269151dfda | 1,243 | tsx | TypeScript | src/AlgoVisual/Layout/Main/Documentation/Sections/Sorting/Sorting.tsx | eduardo-vidals/AlgoVisual | 6f5dcaf3b8b753464d45e12228f55efbc7a79225 | [
"MIT"
] | null | null | null | src/AlgoVisual/Layout/Main/Documentation/Sections/Sorting/Sorting.tsx | eduardo-vidals/AlgoVisual | 6f5dcaf3b8b753464d45e12228f55efbc7a79225 | [
"MIT"
] | null | null | null | src/AlgoVisual/Layout/Main/Documentation/Sections/Sorting/Sorting.tsx | eduardo-vidals/AlgoVisual | 6f5dcaf3b8b753464d45e12228f55efbc7a79225 | [
"MIT"
] | null | null | null | import React, {useEffect, useLayoutEffect} from "react";
import {sortingMarkdown} from "../Markdown/Markdown";
import Markdown from "../../Common/Markdown";
import Sections from "../../Common/Sections";
type Props = {
section: React.RefObject<HTMLDivElement>
};
const sections = ["Bubble Sort", "Insertion Sort", "Selection Sort", "Merge Sort", "Quick Sort", "Heap Sort", "Analysis of Sorting Algorithms"]
let wrapperStyle = {
width: "100%"
}
function Sorting(props: Props) {
const {section} = props;
useEffect(() => {
section.current!.style.borderLeft = "10px white solid";
section.current!.style.backgroundColor = "#29354b";
return () => {
if (section.current){
section.current!.style.borderLeft = "none";
section.current!.style.backgroundColor = "inherit";
}
}
}, [])
return (
<div className={"documentation-wrapper"}>
<div className={"documentation"}>
<div className={"markdown"}>
<Markdown markdown={sortingMarkdown}/>
</div>
<Sections wrapperStyle={wrapperStyle} sections={sections}
directory={"/AlgoVisual/documentation/sorting"} sectionHighlight={false}/>
</div>
</div>
);
}
export default Sorting;
| 28.906977 | 143 | 0.6428 |
75f8db78ce9a76bac1535fea194620a52590a8e1 | 11,101 | php | PHP | application/controllers/KorisnikKontroler.php | Dacy13/film | 500e26afc54b2cb7cc93d62623c72c4b893455e8 | [
"MIT"
] | null | null | null | application/controllers/KorisnikKontroler.php | Dacy13/film | 500e26afc54b2cb7cc93d62623c72c4b893455e8 | [
"MIT"
] | null | null | null | application/controllers/KorisnikKontroler.php | Dacy13/film | 500e26afc54b2cb7cc93d62623c72c4b893455e8 | [
"MIT"
] | null | null | null | <?php
defined('BASEPATH') OR exit('No direct script access allowed');
class KorisnikKontroler extends CI_Controller {
public function __construct() {
parent::__construct();
if(!$this->session->has_userdata('korisnik')){
redirect('LoginKontroler');
}
$tip = $this->session->userdata('korisnik')->Type;
if ($tip == 'prodavac') {
redirect ('ProdavacKontroler');
}
if ($tip == 'admin') {
redirect ('AdminKontroler');
}
$this->load->model('KorisnikModel');
}
public function index() {
$festival = $this->pretraga();
$festivali = $this->KorisnikModel->prikaziFestivale();
$broj = $this->brojPretrage();
$data['middle'] = 'middle/korisnik';
$data['middle_podaci'] = ['festivali' => $festivali, 'filmovi'=>$festival,
'broj'=>$broj];
$this->load->view('basicTemplate', $data);
}
// prikazuje kod pretrage broj dobijenih rezultata
public function brojPretrage(){
$imeFest = $this->input->post('imeFest');
$pocetak = $this->input->post('od');
$zavrsetak = $this->input->post('do');
$engNaziv = $this->input->post('engNaziv');
$srbNaziv = $this->input->post('srbNaziv');
if(!empty($imeFest) || !empty($pocetak) || !empty($zavrsetak)){
$broj = $this->KorisnikModel->brojF($imeFest,$pocetak,$zavrsetak);
}
elseif(!empty($engNaziv) || !empty($srbNaziv)){
$broj = $this->KorisnikModel->brojRez($imeFest,$pocetak,$zavrsetak,$engNaziv,$srbNaziv);
}
else {
$broj = null;
}
return $broj;
}
// funkcija za pretragu festivala i filmova sa vise polja
public function pretraga(){
if(!empty(($this->input->post('trazi')))){
$imeFest = $this->input->post('imeFest');
if(!empty($imeFest)){
$imeFest = $this->input->post('imeFest');
}
$pocetak = $this->input->post('od');
if(!empty($pocetak)){
$pocetak = date('Y-m-d', strtotime($pocetak));
}
$zavrsetak = $this->input->post('do');
if(!empty($zavrsetak)){
$zavrsetak = date('Y-m-d', strtotime($zavrsetak));
}
$engNaziv = $this->input->post('engNaziv');
if(!empty($engNaziv)){
$engNaziv = $this->input->post('engNaziv');
}
$srbNaziv = $this->input->post('srbNaziv');
if(!empty($srbNaziv)){
$srbNaziv = $this->input->post('srbNaziv');
}
// $prva = 0;
//
// if($this->uri->segment(3)){
// $prva = $this->uri->segment(3);
// }
if(!empty($imeFest) || !empty($pocetak) || !empty($zavrsetak)){
$festival = $this->KorisnikModel->dohvatiSveFestivale($imeFest,$pocetak,$zavrsetak);
}
elseif(!empty($engNaziv) || !empty($srbNaziv)){
$festival = $this->KorisnikModel->pretragaFestivala($imeFest,$pocetak,$zavrsetak,$engNaziv,$srbNaziv);
}
else {
$festival= null;
}
// $this->load->library('pagination');
//
// $config = $this->config->item('pagination');
//
// $config['base_url'] = site_url('KorisnikKontroler/pretraga');
// $config['total_rows'] = $this->KorisnikModel->brojRez($imeFest,$pocetak,$zavrsetak,$engNaziv,$srbNaziv);
// $config['per_page'] = LIMIT_PO_STRANICI;
//
// $this->pagination->initialize($config);
return $festival;
}
}
// podaci za view Nalog
public function nalog(){
$id = $this->session->korisnik->Username;
$podaci = $this->KorisnikModel->korisnici($id);
$data['middle'] = 'middle/korisnikNalog';
$data['middle_podaci'] = ['podaci' => $podaci];
$this->load->view('basicTemplate', $data);
}
// izmena podataka o korisniku
public function izmena(){
//if(!empty(($this->input->post('izmeni')))){
$id = $this->session->korisnik->Username;
$sifra = $this->session->korisnik->Password;
// $id = $this->input->post('username');
$ime = $this->input->post('ime');
$prezime = $this->input->post('prezime');
$broj = $this->input->post('broj');
$mejl = $this->input->post('mejl');
$pass = $this->input->post('password');
$novip= $this->input->post('novip');
$potvrda= $this->input->post('potvrda');
$bazaBroj = $this->KorisnikModel->dohvatiBroj($id);
if( strcmp($broj, $bazaBroj)) {
$is_unique = '|is_unique[korisnici.Mobile]';
}
else {
$is_unique = '';
}
$this->form_validation->set_message('required', 'Polje {field} je obavezno');
$this->form_validation->set_message('min_length', 'Polje {field} mora imati najmanje {param} karaktera');
$this->form_validation->set_message('max_length', 'Polje {field} mora imati najvise {param} karaktera');
$this->form_validation->set_message('matches', 'Lozinka i ponovljena lozinka nisu iste');
$this->form_validation->set_message('is_unique', '{field} već postoji u bazi!');
$this->form_validation->set_message('valid_email', 'Email format nije ispravan!');
$this->form_validation->set_message('password_check_numbers', "Lozinka mora sadržati bar jedan broj!");
$this->form_validation->set_message('password_check_upper', "Lozinka mora da sadrži bar 2 velika slova i da počinje velikim slovom!");
$this->form_validation->set_message('password_check_lower', "Lozinka mora sadržati bar 3 mala slova!");
$this->form_validation->set_message('password_two_same_char', "Lozinka ne sme sadržati dva ista karaktera uzastopno!");
if (!empty($novip)) {
$this->form_validation->set_rules ( "ime", "ime", "trim|required|min_length[5]|max_length[15]|callback_specijalni_znakovi");
$this->form_validation->set_rules ( "prezime", "prezime", "trim|required|min_length[5]|max_length[15]|callback_specijalni_znakovi");
$this->form_validation->set_rules ( "broj", "Broj mobilnog telefona", "trim|required|is_natural|regex_match['(06)(\d)(\d){3}(\d){3,4}']".$is_unique);
$this->form_validation->set_rules ( "mejl", "Email", "trim|required|valid_email");
$this->form_validation->set_rules ( "novip", "Password", "trim|min_length[8]|max_length[12]|alpha_numeric|callback_password_check_numbers|callback_password_check_upper|callback_password_check_lower|callback_password_two_same_char");
$this->form_validation->set_rules ( "potvrda", "Password Confirmation", "trim|matches[novip]");
if ($this->form_validation->run() == TRUE) {
$this->KorisnikModel->update($id, $ime, $prezime, $broj, $mejl, $novip);
}
}
else {
$this->form_validation->set_rules ( "ime", "ime", "trim|required|min_length[5]|max_length[15]|callback_specijalni_znakovi");
$this->form_validation->set_rules ( "prezime", "prezime", "trim|required|min_length[5]|max_length[15]|callback_specijalni_znakovi");
$this->form_validation->set_rules ( "broj", "Broj mobilnog telefona", "trim|required|is_natural|regex_match['(06)(\d)(\d){3}(\d){3,4}']".$is_unique);
$this->form_validation->set_rules ( "mejl", "Email", "trim|required|valid_email");
if ($this->form_validation->run() == TRUE) {
$this->KorisnikModel->updateBez($id, $ime, $prezime, $broj, $mejl, $pass);
}
}
// }
$this->nalog();
}
// potrebne dodatne funkcije za funkciju izmena()
public function password_check_numbers($str) {
if (!preg_match_all("#[0-9]+#", $str)) {
return false;
}
return true;
}
public function password_check_upper($str) {
if (!preg_match_all("#^(.*?[A-Z]){2,}#", $str)) {
return false;
}
return true;
}
public function password_check_lower($str) {
if (!preg_match_all("#[a-z]{3,}#", $str)) {
return false;
}
return true;
}
public function password_check($str) {
if($poruka=="")
return true;
else
return $passwordErr;
}
public function password_two_same_char ($str) {
if (!preg_match_all("#(?!.*(.)\1)#", $str)) {
return false;
}
return true;
}
public function specijalni_znakovi ($str) {
if (!preg_match_all("#\p{L}#", $str)) {
return false;
}
else if (preg_match_all("#.*\\d+.*#", $str)) {
return false;
}
else {
return true;
}
}
// prikazivanje podataka na stranici istorija
public function istorija() {
$k = $this->KorisnikModel->dohvatiKupljene();
$o = $this->KorisnikModel->dohvatiOtkazane();
$r = $this->KorisnikModel->dohvatiRezervisane();
$this->otkaziRez();
$data['middle'] = 'middle/istorija';
$data['middle_podaci'] = ['k'=>$k, 'o'=>$o, 'r'=>$r];
$this->load->view('basicTemplate', $data);
}
// otkazivanje rezervacije
public function otkaziRez(){
$idRez = $this->input->post('red');
$status = 'O';
$this->KorisnikModel->promeniRezervaciju($idRez, $status);
}
// logout
public function logout(){
$this->session->sess_destroy();
redirect('LoginKontroler');
}
}
| 37.251678 | 256 | 0.492838 |
647f4d507a3489a00f4b33c20455e577f2fabe40 | 2,592 | sql | SQL | FUNCTIONs.sql | uttgeorge/Database-Assignment-3 | 4ba8dd44771b867a302172168882a79828116b3f | [
"MIT"
] | null | null | null | FUNCTIONs.sql | uttgeorge/Database-Assignment-3 | 4ba8dd44771b867a302172168882a79828116b3f | [
"MIT"
] | null | null | null | FUNCTIONs.sql | uttgeorge/Database-Assignment-3 | 4ba8dd44771b867a302172168882a79828116b3f | [
"MIT"
] | null | null | null |
SET GLOBAL log_bin_trust_function_creators = 1;
# 1. Find the salary of a player
DELIMITER //
CREATE FUNCTION callsalary (firstname TEXT,lastname TEXT)
RETURNS INT
BEGIN
DECLARE Income INT;
SELECT t.Salary INTO Income
FROM (
SELECT d.FirstName,d.LastName,s.Salary
FROM Detail d join Salary s
ON d.Personid = s.Personid
WHERE d.FirstName = firstname and d.LastName = lastname
)t;
RETURN Income;
END;
//
DELIMITER ;
SELECT FirstName,LastName FROM Detail;
SELECT callsalary('John','Wall');
#2. To check whether a player is an allstar player
SELECT * FROM Detail;
DROP FUNCTION ifallstar;
DELIMITER //
CREATE FUNCTION ifallstar(firstname TEXT,lastname TEXT)
RETURNS Boolean
BEGIN
DECLARE idx TEXT;
SELECT t.AllStar INTO idx
FROM (
SELECT d.FirstName,d.LastName,s.AllStar
FROM Detail d join Salary s
ON d.Personid = s.Personid
WHERE d.FirstName = firstname and d.LastName = lastname
)t;
IF idx = 'True' THEN RETURN TRUE;
ELSE RETURN FALSE;
END IF;
END;
//
DELIMITER ;
SELECT ifallstar('John','Wall') "1 is true,0 is false";
SELECT ifallstar('Amir','Johnson') "1 is true,0 is false";
#3. find the most common hashtag
SELECT * FROM Hashtag;
DROP FUNCTION commonhashtag;
DELIMITER //
CREATE FUNCTION commonhashtag()
RETURNS TEXT
BEGIN
DECLARE hashtag TEXT;
SELECT ht INTO hashtag
FROM Hashtag
GROUP BY ht
ORDER BY count(ht) DESC
LIMIT 1;
RETURN hashtag;
END;
//
DELIMITER ;
select commonhashtag();
#4. find the most popular tweet of a team
SELECT * FROM Tweets;
DROP FUNCTION poptweet;
DELIMITER //
CREATE FUNCTION poptweet(abbr TEXT)
RETURNS TEXT
BEGIN
DECLARE popt TEXT;
SELECT a.Tweets INTO popt
FROM (
SELECT t.Tweets,t.likes
FROM Tweets t join nba_twitter_accounts n
on t.account = n.Account
WHERE n.Abbr = abbr
ORDER BY t.likes DESC
)a
limit 1;
RETURN popt;
END;
//
DELIMITER ;
SELECT poptweet('ATL');
#5. find the best player of a team
SELECT * FROM Stats;
DROP FUNCTION bestplayer;
DELIMITER //
CREATE FUNCTION bestplayer(teamabbr TEXT)
RETURNS TEXT
BEGIN
DECLARE player TEXT;
SELECT CONCAT(a.FirstName, ' ', a.LastName) INTO player
FROM(
SELECT d.FirstName,d.LastName,d.Team,
((s.PPG+s.RPG+s.APG+s.SPG+s.BPG)-((s.FGA-s.FGM)+(s.FTA-s.FTM)+s.TOV)) as eff
FROM Detail d join Stats s
ON d.Personid = s.Personid
) a
WHERE a.Team = teamabbr
ORDER BY a.eff DESC
limit 1;
RETURN player;
END;
//
DELIMITER ;
SELECT bestplayer('HOU');
| 20.093023 | 84 | 0.680941 |
78d687e12f5868ab9896961290f33492a8e93438 | 5,390 | asm | Assembly | libsrc/_DEVELOPMENT/math/float/am9511/asm/8085/am32_pushf.asm | dikdom/z88dk | 40c55771062b0ea9bb2f0d5b73e2f754fc12b6b0 | [
"ClArtistic"
] | null | null | null | libsrc/_DEVELOPMENT/math/float/am9511/asm/8085/am32_pushf.asm | dikdom/z88dk | 40c55771062b0ea9bb2f0d5b73e2f754fc12b6b0 | [
"ClArtistic"
] | 2 | 2022-03-20T22:17:35.000Z | 2022-03-24T16:10:00.000Z | libsrc/_DEVELOPMENT/math/float/am9511/asm/8085/am32_pushf.asm | jorgegv/z88dk | 127130cf11f9ff268ba53e308138b12d2b9be90a | [
"ClArtistic"
] | null | null | null | ;
; Copyright (c) 2022 Phillip Stevens
;
; This Source Code Form is subject to the terms of the Mozilla Public
; License, v. 2.0. If a copy of the MPL was not distributed with this
; file, You can obtain one at http://mozilla.org/MPL/2.0/.
;
; feilipu, January 2022
;
;-------------------------------------------------------------------------
; asm_am9511_pushf - am9511 APU push float
;-------------------------------------------------------------------------
;
; Load IEEE-754 float into Am9511 APU stack
;
;-------------------------------------------------------------------------
SECTION code_clib
SECTION code_fp_am9511
INCLUDE "../../_DEVELOPMENT/target/am9511/config_am9511_private.inc"
PUBLIC asm_am9511_pushf
PUBLIC asm_am9511_pushf_fastcall
.asm_am9511_pushf
; float primitive
; push a IEEE-754 floating point into Am9511 stack.
;
; Convert from IEEE_float to am9511_float.
;
; enter : stack = IEEE_float, ret1, ret0
;
; exit : stack = IEEE_float, ret1
;
; uses : af, bc
; preserves : de, hl
; in a,(__IO_APU_STATUS) ; read the APU status register
; rlca ; busy? and __IO_APU_STATUS_BUSY
; jp C,asm_am9511_pushf
push de ; preserve dehl
ld bc,hl
ld de,sp+6
ld a,(de) ; load LSW into APU
out (__IO_APU_DATA),a
inc de
ld a,(de)
out (__IO_APU_DATA),a
inc de
ld hl,(de) ; get exponent and mantissa MSW
add hl,hl ; shift exponent to h
ld a,h ; get exponent to a
or a ; set exponent flags
jp Z,asm_am9511_zero ; check for zero
cp 127+63 ; check for overflow
jp NC,asm_am9511_max
cp 127-64 ; check for underflow
jp C,asm_am9511_zero
sub 127-1 ; remove bias including shift binary point
rla ; position 7-bit exponent for sign
ld h,a
ld a,l ; get mantissa to a
scf ; set mantissa MSB to 1
rra
out (__IO_APU_DATA),a ; load mantissa MSB into APU
inc de
ld a,(de) ; get sign
rla
ld a,h
rra
out (__IO_APU_DATA),a ; load exponent into APU
ld hl,bc
pop de ; recover dehl
ret
.asm_am9511_max
in a,(__IO_APU_DATA)
in a,(__IO_APU_DATA)
ld a,0ffh ; confirm we have maximum
out (__IO_APU_DATA),a ; load mantissa into APU
out (__IO_APU_DATA),a
out (__IO_APU_DATA),a
inc de
ld a,(de) ; get sign
rla
ld a,07eh ; max exponent << 1
rra
out (__IO_APU_DATA),a ; load maximum exponent into APU
ld hl,bc
pop de ; recover dehl
ret
.asm_am9511_zero
in a,(__IO_APU_DATA)
in a,(__IO_APU_DATA)
xor a ; confirm we have a zero
out (__IO_APU_DATA),a ; load zero mantissa into APU
out (__IO_APU_DATA),a
out (__IO_APU_DATA),a
out (__IO_APU_DATA),a ; load zero exponent into APU
ld hl,bc
pop de ; recover dehl
ret
.asm_am9511_pushf_fastcall
; float primitive
; push a IEEE-754 floating point into Am9511 stack.
;
; Convert from IEEE_float to am9511_float.
;
; enter : stack = ret1, ret0
; : dehl = IEEE_float
;
; exit : stack = ret1
;
; uses : af, de, hl
rl de ; get sign to carry, move exponent to d
push af ; save sign in carry
ld a,d ; get exponent
or a ; check for zero
jp Z,asm_am9511_zero_fastcall
cp 127+63 ; check for overflow
jp NC,asm_am9511_max_fastcall
cp 127-64 ; check for underflow
jp C,asm_am9511_zero_fastcall
sub 127-1 ; bias including shift binary point
rla ; position 7-bit exponent for sign
ld d,a
pop af ; recover sign
ld a,d
rra ; position sign and exponent
ld d,a ; restore sign and exponent
ld a,e
scf ; set mantissa leading 1
rra ; restore 1 & mantissa
ld e,a
.pushf_fastcall
; in a,(__IO_APU_STATUS) ; read the APU status register
; rlca ; busy? and __IO_APU_STATUS_BUSY
; jp C,pushf_fastcall
ld a,l ; load LSW into APU
out (__IO_APU_DATA),a
ld a,h
out (__IO_APU_DATA),a
ld a,e ; load MSW into APU
out (__IO_APU_DATA),a
ld a,d
out (__IO_APU_DATA),a
ret
.asm_am9511_zero_fastcall
pop af ; recover sign
ld de,0 ; no signed zero available
ld h,d
ld l,e
jp pushf_fastcall
.asm_am9511_max_fastcall ; floating max value of sign d in dehl
pop af ; recover sign
ld a,07eh ; max exponent << 1
rra ; relocate sign and exponent
ld d,a
ld e, 0ffh ; max mantissa
ld h,e
ld l,e
jp pushf_fastcall
| 27.360406 | 74 | 0.504824 |
969e891e1a3497f35007a8e116133862b7e0b26a | 12,420 | html | HTML | storage/alfred-4/docs/www.alfredapp.com/help/powerpack/index.html | godbout/dash-docsets | c8d7ec14d29a0d5f90f511d809b51844e08a8c62 | [
"MIT"
] | 2 | 2020-07-15T17:36:04.000Z | 2021-11-27T18:37:54.000Z | storage/alfred-4/docs/www.alfredapp.com/help/powerpack/index.html | godbout/dash-docsets | c8d7ec14d29a0d5f90f511d809b51844e08a8c62 | [
"MIT"
] | 4 | 2020-06-28T15:43:23.000Z | 2020-07-23T13:45:11.000Z | storage/alfred-4/docs/www.alfredapp.com/help/powerpack/index.html | godbout/alfred-dash-docset | 5602ddeca3259e4b6a0fc749315f8ed8300ac197 | [
"MIT"
] | 1 | 2021-11-24T20:56:54.000Z | 2021-11-24T20:56:54.000Z | <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Alfred Powerpack - Alfred Help and Support</title>
<meta name="description" content="The Powerpack contains a huge range of features to help you be more productive on your Mac. Activate your Powerpack license and make the most of Alfred.">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="Shortcut Icon" href="../../favicon.ico">
<link rel="apple-touch-icon" href="../../apple-touch-icon.png">
<!-- Styles -->
<style>
@import url('../../../fonts.googleapis.com/css%3Ffamily=Bitter:400,700.css');
@import url('../../styles/style.css%3Fver=5.8.css');
</style>
</head>
<body id="helppage">
<!-- Navigation -->
<nav id="mainnav">
<div class="content">
<a href="https://www.alfredapp.com/" id="home">Alfred</a>
<div id="menu">
<a href="https://www.alfredapp.com/powerpack/" id="navpowerpack">Powerpack</a>
<a href="https://www.alfredapp.com/remote/">Remote</a>
<a href="https://www.alfredapp.com/workflows/" id="navworkflows">Workflows</a>
<a href="http://www.alfredforum.com/" id="navforum">Forum</a>
<a href="https://www.alfredapp.com/blog/">Blog</a>
<a href="../index.html">Help</a>
<a href="https://www.alfredapp.com/search/" id="navsearch">Search</a>
</div>
</div>
</nav>
<nav id="subnav">
<div class="content">
<form action="https://www.alfredapp.com/search/" method="get">
<input name="p" type="hidden" value="help">
<input name="q" type="text" placeholder="Search Help..." autocomplete="off" required>
<button type="submit">Search</button>
</form>
<div id="breadcrumbs"><a href="../index.html">Help and Support</a> > Alfred Powerpack</div>
</div>
</nav>
<section id="helpcontent">
<div class="content">
<article id="helparticle">
<h1>Using the Powerpack</h1>
<p>The Powerpack contains a huge range of features to help you be more productive on your Mac. </p>
<p>To get started, download the free version of Alfred 4 from our website, and <a href="https://www.alfredapp.com/shop/">buy a new Powerpack license</a> or <a href="https://www.alfredapp.com/shop/upgrade/">upgrade an existing license</a>. </p>
<p>If you've already installed Alfred, there's no need to install anything new! Activate your license in the preferences to unlock Alfred's Powerpack features! :) Take a look at <a href="https://www.alfredapp.com/whats-new/">what's new in Alfred 4</a>.</p>
<p>Once you're ready to go, take a look at the <a href="index.html#features">Getting Started with Powerpack features</a> section below. </p>
<p>Find out how to get started with the Powerpack in more details:</p>
<ul>
<li><a href="index.html#activating">Activating my Powerpack</a></li>
<li><a href="index.html#features">Getting started with Powerpack features</a></li>
<li><a href="index.html#recover">Recovering my license</a></li>
<li><a href="index.html#up-to-date">Upgrading or using an up-to-date license</a></li>
<li><a href="index.html#invalid">Alfred tells me my license is invalid or incomplete</a></li>
</ul>
<hr />
<h2 id="activating">How do I activate the Powerpack in Alfred 4?</h2>
<p>If you've purchased a Powerpack license, you'll need to enter your code to unlock the Powerpack features. When you complete your purchase, your license is emailed to you so if it hasn't arrived after a few minutes, please check your spam folder and filtered folders.</p>
<p>If you're already using the latest build of Alfred 4, which is free from <a href="https://www.alfredapp.com/">alfredapp.com</a>, you don't need to download a new different version of the app.</p>
<p>Upgrading from Alfred 3? As soon as you launch it, Alfred 4 will offer to migrate your v3 settings, and you'll be able to enter your Powerpack details. <a href="../getting-started/migration/index.html">Find more about migrating from Alfred 3</a>.</p>
<p>Alternatively, if you've installed the free version of Alfred 4 and want to enter your Powerpack details later, you can do so on the Powerpack tab.</p>
<p><img src="powerpack-prefs.png" alt="Powerpack tab in the Preferences" /></p>
<p>Need to buy a license? You can <a href="https://www.alfredapp.com/shop/">purchase a new Powerpack license</a> or <a href="https://www.alfredapp.com/shop/upgrade/">upgrade your existing Powerpack license</a>.</p>
<hr />
<h2 id="features">Getting started with the Powerpack features</h2>
<p>Congratulations, you're now a Powerpack user! To learn how to make the most of the advanced functionality you've unlocked, take a look at the <a href="../features/index.html">Features</a> section of the website. :)</p>
<p>There, you'll discover how you can use the many Powerpack-only features like <a href="../features/file-search/index.html#file-nav">File Navigation</a>, <a href="../features/clipboard/index.html">Clipboard History</a>, <a href="../features/contacts/index.html">Contacts Viewer</a>, <a href="../features/itunes/index.html">iTunes Mini Player</a>, custom <a href="../appearance/index.html">Theming</a> and, most exciting of all, <a href="../workflows/index.html">Workflows</a>. </p>
<p>You'll also find <a href="../guides-and-tutorials/index.html">Guides and Tutorials</a> on searching more efficiently, setting up workflows and being more productive at your Mac.</p>
<hr />
<h2>Powerpack License FAQ</h2>
<h3 id="recover">How can I recover my license?</h3>
<p>It's easy, just <a href="../recover-license/index.html">contact us to recover your license</a> and we'll reissue your details by email as quickly as we can.</p>
<h3 id="up-to-date">Do I have an up-to-date Powerpack license code? Can I upgrade?</h3>
<p>Alfred 4 was released in May 2019, and all users who purchased in 2019 are eligible for a free upgrade.</p>
<p>If you have a <strong>Single User</strong> or <strong>Family license</strong> purchased <em>before 2019</em>, you <a href="https://www.alfredapp.com/shop/upgrade/">can upgrade it to an Alfred 4 license at a discount</a>.</p>
<p>If you're a <strong>Mega Supporter</strong>, you are eligible for a free upgrade; You can request your free upgrade via the <a href="https://www.alfredapp.com/shop/upgrade/">upgrade page</a> by entering your previous license details.</p>
<p>If you can't find your license, contact us on <a class="leml"></a> from your registered Powerpack email address.</p>
<h3 id="invalid">Alfred tells me my license is invalid, incomplete or it can't connect to the activation server</h3>
<p>Ensure that you are using your valid Alfred 4 license and not an older license. You need to use the email address associated with your Powerpack license, as well as all four lines of your license code.</p>
<p>Take a look at the <a href="../troubleshooting/powerpack-activation-issues/index.html">Powerpack Activation Troubleshooting page for solutions for specific error messages</a>.</p>
<p>If you continue to have difficulties, contact us on <a class="leml"></a> from your registered Powerpack email address and we'll be happy to help you.</p>
</article>
<nav id="helpmenu">
<a href="../index.html">Home</a>
<a href="../overview/index.html">Overview</a>
<a href="../getting-started/index.html">Getting Started</a>
<a href="../guides-and-tutorials/index.html">Guides and Tutorials</a>
<hr>
<a href="../general/index.html">General</a>
<a href="../features/index.html">Features</a>
<a href="../workflows/index.html">Workflows</a>
<a href="../appearance/index.html">Appearance</a>
<a href="../advanced/index.html">Advanced</a>
<a href="../remote/index.html">Remote</a>
<hr>
<a href="index.html">Powerpack</a>
<a href="../update/index.html">Update</a>
<hr>
<a href="../troubleshooting/index.html">Troubleshooting</a>
<a href="../recover-license/index.html">Recover License</a>
<a href="../report-a-bug/index.html">Report a Bug</a>
<hr>
<a href="../contact/index.html">Contact Us</a>
</nav>
</div>
</section>
<section id="latestblogpost">
<div class="content">
<h2>Latest Blog Post:</h2>
<p><a href="https://www.alfredapp.com/blog/releases/alfred-4-1-embedded-snippets/">Alfred 4.1 Released: Embedded Snippets, Shared Hotkeys and Lots of Love for Workflows</a></p>
</div>
</section>
<!-- Footer -->
<footer id="footer">
<div class="content">
<div>
<h3>Alfred</h3>
<ul>
<li><a href="https://www.alfredapp.com/#download">Download Alfred</a></li>
<li><a href="https://www.alfredapp.com/powerpack/">Alfred Powerpack</a></li>
<li><a href="https://www.alfredapp.com/remote/">Alfred Remote</a></li>
<li><a href="https://www.alfredapp.com/workflows/">Workflows</a></li>
<li><a href="https://www.alfredapp.com/changelog/">Change Log</a></li>
</ul>
</div>
<div>
<h3>Resources</h3>
<ul>
<li><a href="../index.html">Support</a></li>
<li><a href="../getting-started/index.html">Getting Started</a></li>
<li><a href="../guides-and-tutorials/index.html">Tutorials</a></li>
<li><a href="https://www.alfredapp.com/labs/">Labs</a></li>
</ul>
</div>
<div>
<h3>Community</h3>
<ul>
<li><a href="https://www.alfredapp.com/blog/">Our Blog</a></li>
<li><a href="https://www.alfredapp.com/testimonials/">Testimonials</a></li>
<li><a href="http://alfredforum.com/">Forum</a></li>
<li><a href="../kb/buy-goodies-and-stickers/index.html">Buy Goodies</a></li>
</ul>
</div>
<div>
<h3>Company</h3>
<ul>
<li><a href="https://twitter.com/alfredapp" class="fimage"><img src="../../media/logos/Twitter.svg" alt="Twitter Logo">Twitter</a></li>
<li><a href="https://www.facebook.com/alfredapp" class="fimage"><img src="../../media/logos/Facebook.svg" alt="Facebook Logo">Facebook</a></li>
<li><a href="https://www.alfredapp.com/about/" class="fimage"><img src="../../media/logos/Person.svg" alt="About Logo">About Us</a></li>
<li><a href="../contact/index.html" class="fimage"><img src="../../media/logos/Contact.svg" alt="Contact ">Contact Us</a></li>
</ul>
</div>
<div id="newsletter">
<h3>Newsletter</h3>
<form action="https://alfredapp.createsend.com/t/y/s/hukjlh/" method="post" id="subform">
<input name="cm-hukjlh-hukjlh" type="email" placeholder="Enter your email address..." required />
<button type="submit">Subscribe</button>
</form>
<p>Sign up for updates, tips and sneak peeks. <a href="https://www.alfredapp.com/terms/" class="terms">Privacy Policy</a>.</p>
</div>
</div>
</footer>
<div id="footermeta">
<div class="content">
<div id="thanks">
<a href="http://www.cachefly.com/"><img src="../../media/cachefly.png" alt="CacheFly" id="cachefly"></a>
<a href="https://www.campaignmonitor.com"><img src="../../media/campaignmonitor.png" alt="Campaign Monitor" id="campaignmonitor"></a>
</div>
<div id="terms">
<p>
"Alfred" is a registered trademark of Running with Crayons Ltd.
©2020 Running with Crayons Ltd. All rights reserved.
</p>
<p><a href="https://www.alfredapp.com/terms/">Terms & Conditions, Privacy Policy, Cookies.</a></p>
</div>
</div>
</div>
<!-- Javascript Functions -->
<script src="../../scripts/functions.js%3Fver=1.3" defer></script>
<!-- Anonymised Google Analytics -->
<script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-183491-24', 'auto');
ga('set', 'anonymizeIp', true);
ga('send', 'pageview');
</script>
</body>
</html>
<!-- generated in 0.00117s on 10th Jul 2020 at 13:59 -->
<!-- served from static cache --> | 55.446429 | 482 | 0.644686 |
b5076f8e488846ffd8d9c470d0421cbafc68c881 | 2,222 | sql | SQL | SQL_JDBC/src/main/java/ru/job4j/SQL/ScriptCarFactory.sql | alekseyponkin/aponkin | 2b4794066ffb0aed9965646cfb8877553403e20f | [
"Apache-2.0"
] | null | null | null | SQL_JDBC/src/main/java/ru/job4j/SQL/ScriptCarFactory.sql | alekseyponkin/aponkin | 2b4794066ffb0aed9965646cfb8877553403e20f | [
"Apache-2.0"
] | null | null | null | SQL_JDBC/src/main/java/ru/job4j/SQL/ScriptCarFactory.sql | alekseyponkin/aponkin | 2b4794066ffb0aed9965646cfb8877553403e20f | [
"Apache-2.0"
] | null | null | null | -- Drop database
--DROP DATABASE car_factory;
-- Create database CarFactory
CREATE DATABASE car_factory;
-- Create table Engine
CREATE TABLE engine(
id SERIAL PRIMARY KEY,
name VARCHAR(200)
);
INSERT INTO engine(name) VALUES ('1.6 MPI');
INSERT INTO engine(name) VALUES ('1.4 TSI');
INSERT INTO engine(name) VALUES ('1.2 TSI');
-- Create table Transmission
CREATE TABLE transmission(
id SERIAL PRIMARY KEY,
name VARCHAR(200)
);
INSERT INTO transmission(name) VALUES ('7DSG');
INSERT INTO transmission(name) VALUES ('6AT');
INSERT INTO transmission(name) VALUES ('4st ZF4HP');
INSERT INTO transmission(name) VALUES ('5MT');
-- Create table Car body
CREATE TABLE car_body(
id SERIAL PRIMARY KEY,
name VARCHAR(200)
);
INSERT INTO car_body(name) VALUES ('sedan 4dr');
INSERT INTO car_body(name) VALUES ('hatchback 5dr');
INSERT INTO car_body(name) VALUES ('pickup truck');
-- Create table Car
CREATE TABLE car(
id SERIAL PRIMARY KEY,
name VARCHAR(200),
engine_id INTEGER REFERENCES engine(id),
transmission_id INTEGER REFERENCES transmission(id),
car_body_id INTEGER REFERENCES car_body(id)
);
INSERT INTO car(name, engine_id, transmission_id, car_body_id)
VALUES ('Skoda Octavia',
(SELECT id FROM engine WHERE name='1.4 TSI'),
(SELECT id FROM transmission WHERE name='7DSG'),
(SELECT id FROM car_body WHERE name='sedan 4dr')
);
INSERT INTO car(name, engine_id, transmission_id, car_body_id)
VALUES ('Kia Ceed',
(SELECT id FROM engine WHERE name='1.6 MPI'),
(SELECT id FROM transmission WHERE name='6AT'),
(SELECT id FROM car_body WHERE name='hatchback 5dr')
);
-- Select
-- 1
SELECT c.name, t.name, e.name, cb.name FROM car AS c
JOIN car_body AS cb ON c.car_body_id = cb.id
JOIN transmission AS t ON c.transmission_id = t.id
JOIN engine AS e ON c.engine_id = e.id;
-- 2
SELECT t.name, 'transmission' AS type FROM car AS c RIGHT JOIN transmission AS t ON c.transmission_id = t.id WHERE c.name IS NULL
UNION
SELECT cb.name, 'car body' AS type FROM car AS c RIGHT JOIN car_body AS cb ON c.car_body_id = cb.id WHERE c.name IS NULL
UNION
SELECT e.name, 'engine' AS type FROM car AS c RIGHT JOIN engine e ON c.engine_id = e.id WHERE c.name IS NULL; | 32.676471 | 129 | 0.722772 |
16aac01fb32d90f6c13dd94eb458c944581fad5e | 1,450 | sql | SQL | docker-containers/database-container/db_init.sql | freddygv/trabblex | c85184523ccf88d81b090c40e3c5a4c5cf07b029 | [
"MIT"
] | 2 | 2017-12-02T17:30:13.000Z | 2018-01-20T23:00:35.000Z | docker-containers/database-container/db_init.sql | freddygv/trabblex | c85184523ccf88d81b090c40e3c5a4c5cf07b029 | [
"MIT"
] | null | null | null | docker-containers/database-container/db_init.sql | freddygv/trabblex | c85184523ccf88d81b090c40e3c5a4c5cf07b029 | [
"MIT"
] | 1 | 2018-11-12T03:15:36.000Z | 2018-11-12T03:15:36.000Z | CREATE TABLE videos (
file_hash VARCHAR(64) NOT NULL PRIMARY KEY,
file_name VARCHAR(64) NOT NULL,
file_size VARCHAR(10) NOT NULL,
protocol VARCHAR(3) NOT NULL,
video_size_x SMALLINT NOT NULL,
video_size_y SMALLINT NOT NULL,
bitrate VARCHAR(10) NOT NULL,
seeder_is_active BOOLEAN NOT NULL
);
CREATE TABLE file_keywords (
file_hash VARCHAR(64) NOT NULL REFERENCES videos (file_hash),
keyword VARCHAR(64) NOT NULL
);
CREATE TABLE chunk_owners (
file_hash VARCHAR(64) NOT NULL,
chunk_hash VARCHAR(64) NOT NULL,
chunk_id SMALLINT NOT NULL,
owner_ip VARCHAR(64) NOT NULL,
owner_port SMALLINT NOT NULL,
is_seeder BOOLEAN NOT NULL
);
INSERT INTO videos (file_hash, file_name, file_size, protocol, video_size_x, video_size_y, bitrate, seeder_is_active)
VALUES('C52057A4A2555D007A6B2D13FE2BBCA813AF936EBC3E26ACFF13CFAD5C54CED5', 'tl_512kb.mp4', '27546', 'TCP', '320', '240', '800', 'f');
INSERT INTO videos (file_hash, file_name, file_size, protocol, video_size_x, video_size_y, bitrate, seeder_is_active)
VALUES('0ED4C30A5625D538DEC9F1CF39BE643439CADF42AA27CEC17935DC0E7B073B25', 'PopeyeAliBaba_512kb.mp4', '75674', 'TCP', '320', '240', '700', 'f');
INSERT INTO videos (file_hash, file_name, file_size, protocol, video_size_x, video_size_y, bitrate, seeder_is_active)
VALUES('B07E7827BAAC4009C173DF2DFEDEC186CFDDE1AAB6CEBBF02C9D7C52D04A26EE', 'CC_1916_07_10_TheVagabond.mp4', '153600', 'TCP', '640', '480', '1024', 'f');
| 41.428571 | 152 | 0.771724 |
3ab92302630f7b1807577b47211613bfb9cdf694 | 142 | lua | Lua | globalConst.lua | wcguo/xiuxian | 953cf54b3eea558ee7dee4ec6f161b9a66c137ac | [
"MIT"
] | null | null | null | globalConst.lua | wcguo/xiuxian | 953cf54b3eea558ee7dee4ec6f161b9a66c137ac | [
"MIT"
] | null | null | null | globalConst.lua | wcguo/xiuxian | 953cf54b3eea558ee7dee4ec6f161b9a66c137ac | [
"MIT"
] | null | null | null | global.xiuxian = global.xiuxian or {}
global.xiuxian.Level = global.xiuxian.Level or {}
global.xiuxian.usedAge = global.xiuxian.usedAge or {}
| 35.5 | 53 | 0.760563 |