 'InvoiceDate', DbType.datetime);
  }

  static TableField? _fBillingAddress;
  static TableField get BillingAddress {
    return _fBillingAddress = _fBillingAddress ??
        SqlSyntax.setField(_fBillingAddress, 'BillingAddress', DbType.text);
  }

  static TableField? _fBillingCity;
  static TableField get BillingCity {
    return _fBillingCity = _fBillingCity ??
        SqlSyntax.setField(_fBillingCity, 'BillingCity', DbType.text);
  }

  static TableField? _fBillingState;
  static TableField get BillingState {
    return _fBillingState = _fBillingState ??
        SqlSyntax.setField(_fBillingState, 'BillingState', DbType.text);
  }

  static TableField? _fBillingCountry;
  static TableField get BillingCountry {
    return _fBillingCountry = _fBillingCountry ??
        SqlSyntax.setField(_fBillingCountry, 'BillingCountry', DbType.text);
  }

  static TableField? _fBillingPostalCode;
  static TableField get BillingPostalCode {
    return _fBillingPostalCode = _fBillingPostalCode ??
        SqlSyntax.setField(
            _fBillingPostalCode, 'BillingPostalCode', DbType.text);
  }

  static TableField? _fTotal;
  static TableField get Total {
    return _fTotal =
        _fTotal ?? SqlSyntax.setField(_fTotal, 'Total', DbType.real);
  }

  static TableField? _fCustomerId;
  static TableField get CustomerId {
    return _fCustomerId = _fCustomerId ??
        SqlSyntax.setField(_fCustomerId, 'CustomerId', DbType.integer);
  }
}
// endregion InvoiceFields

//region InvoiceManager
class InvoiceManager extends SqfEntityProvider {
  InvoiceManager()
      : super(Chinookdb(),
            tableName: _tableName,
            primaryKeyList: _primaryKeyList,
            whereStr: _whereStr);
  static const String _tableName = 'Invoice';
  static const List<String> _primaryKeyList = ['InvoiceId'];
  static const String _whereStr = 'InvoiceId=?';
}

//endregion InvoiceManager
// region InvoiceLine
class InvoiceLine extends TableBase {
  InvoiceLine(
      {this.InvoiceLineId,
      this.UnitPrice,
      this.Quantity,
      this.TrackId,
      this.InvoiceId}) {
    _setDefaultValues();
    softDeleteActivated = false;
  }
  InvoiceLine.withFields(
      this.UnitPrice, this.Quantity, this.TrackId, this.InvoiceId) {
    _setDefaultValues();
  }
  InvoiceLine.withId(this.InvoiceLineId, this.UnitPrice, this.Quantity,
      this.TrackId, this.InvoiceId) {
    _setDefaultValues();
  }
  // fromMap v2.0
  InvoiceLine.fromMap(Map<String, dynamic> o, {bool setDefaultValues = true}) {
    if (setDefaultValues) {
      _setDefaultValues();
    }
    InvoiceLineId = int.tryParse(o['InvoiceLineId'].toString());
    if (o['UnitPrice'] != null) {
      UnitPrice = double.tryParse(o['UnitPrice'].toString());
    }
    if (o['Quantity'] != null) {
      Quantity = int.tryParse(o['Quantity'].toString());
    }
    TrackId = int.tryParse(o['TrackId'].toString());

    InvoiceId = int.tryParse(o['InvoiceId'].toString());

    // RELATIONSHIPS FromMAP
    plTrack = o['track'] != null
        ? Track.fromMap(o['track'] as Map<String, dynamic>)
        : null;
    plInvoice = o['invoice'] != null
        ? Invoice.fromMap(o['invoice'] as Map<String, dynamic>)


NumProcessors = (ListPreference)getPreferenceScreen().findPreference(PrefsHelper.PREF_EMU_NUM_PROCESSORS);
	}

	  @Override
	    protected void onResume() {
	        super.onResume();
	        boolean enable;
	        // Setup the initial values
	        //mCheckBoxPreference.setSummary(sharedPreferences.getBoolean(key, false) ? "Disable this setting" : "Enable this setting");
	        mPrefGlobalVideoRenderMode.setSummary("Current value is '" + mPrefGlobalVideoRenderMode.getEntry()+"'");

	        mPrefResolution.setSummary("Current value is '" + mPrefResolution.getEntry()+"'");
		    mPrefOSDResolution.setSummary("Current value is '" + mPrefOSDResolution.getEntry()+"'");
	        mPrefPortraitMode.setSummary("Current value is '" + mPrefPortraitMode.getEntry()+"'");
	        mPrefLandsMode.setSummary("Current value is '" + mPrefLandsMode.getEntry()+"'");
			mPrefOverlay.setSummary("Current value is '" + mPrefOverlay.getEntry()+"'");
		    mPrefOrientation.setSummary("Current value is '" + mPrefOrientation.getEntry()+"'");

	        mPrefControllerType.setSummary("Current value is '" + mPrefControllerType.getEntry()+"'");

	        mPrefAnalogDZ.setSummary("Current value is '" + mPrefAnalogDZ.getEntry()+"'");
	        mPrefGamepadDZ.setSummary("Current value is '" + mPrefGamepadDZ.getEntry()+"'");
	        mPrefTiltDZ.setSummary("Current value is '" + mPrefTiltDZ.getEntry()+"'");
	        mPrefTiltNeutral.setSummary("Current value is '" + mPrefTiltNeutral.getEntry()+"'");
	        mPrefSound.setSummary("Current value is '" + mPrefSound.getEntry()+"'");
	        mPrefStickType.setSummary("Current value is '" + mPrefStickType.getEntry()+"'");
	        mPrefNumButtons.setSummary("Current value is '" + mPrefNumButtons.getEntry()+"'");
	        mPrefSizeButtons.setSummary("Current value is '" + mPrefSizeButtons.getEntry()+"'");
		    mPrefAlphaButtons.setSummary("Current value is '" + mPrefAlphaButtons.getEntry()+"'");
	        mPrefSizeStick.setSummary("Current value is '" + mPrefSizeStick.getEntry()+"'");
	        mPrefMainThPr.setSummary("Current value is '" + mPrefMainThPr.getEntry()+"'");
	        mPrefSoundEngine.setSummary("Current value is '" + mPrefSoundEngine.getEntry()+"'");
	        mPrefNavbar.setSummary("Current value is '" + mPrefNavbar.getEntry()+"'");
			mPrefInstPath.setSummary("Current value is '" + mPrefInstPath.getText()+"'");
		    mPrefShader.setSummary("Current value is '" + mPrefShader.getEntry()+"'");
		    mPrefNumProcessors.setSummary("Current value is '" + mPrefNumProcessors.getEntry()+"'");

	        // Set up a listener whenever a key changes
	        getPreferenceScreen().getSharedPreferences().registerOnSharedPreferenceChangeListener(this);

	    }

	    @Override
	    protected void onPause() {
	        super.onPause();

	        // Unregister the listener whenever a key changes
	        getPreferenceScreen().getSharedPreferences().unregisterOnSharedPreferenceChangeListener(this);
	    }

	    public void onSharedPreferenceChanged(SharedPreferences sharedPreferences, String key) {
	        // Let's do something a preference values changes
	    	/*
	        if (key.equals(KEY_CHECKBOX_PREFERENCE)) {
	          mCheckBoxPreference.setSu


 row: HTMLDivElement = document.createElement('div');
			row.className = 'chartrow';
			this.html.appendChild(row);
			var node: HTMLElement = document.createElement('div');
			node.className = 'rowname';
			node.innerText = item.getName();
			row.appendChild(node);
			node = document.createElement('div');
			node.className = 'rowline';
			node.setAttribute('id', 'line_' + item.getProtocol());
			node.addEventListener('click', this.onClick.bind(this));
			node.style.width = 0 + '%';
			var c: string = !item.getStatus()
				? 'bad-bg'
				: item.getValue() > 20
				? 'good-bg'
				: item.getValue() > 10
				? 'poor-bg'
				: 'bad-bg';
			node.classList.add(c);
			row.appendChild(node);
			node = document.createElement('div');
			node.className = 'rowvalue';
			node.setAttribute('id', 'value_' + item.getProtocol());
			node.innerText = item.getValue().toString();
			row.appendChild(node);
		}
		setTimeout(this.updateAll.bind(this), 100);
	}
	private updateAll(): void {
		this.protocolList.forEach((p) => this.update(p));
	}
	private onClick(evt: Event): void {
		var p: string = (evt.target as Element).id.split('_')[1];
		var item: StateData = this.getItem(p as Protocol);
		if (!item) {
			return;
		}
		window.open('http://' + item.getLink());
	}
}
export const HorizontalTabsExample = `
const HorizontalTabsExample = () => {
  const selectedId = useUID();
  return (
    <Tabs selectedId={selectedId} baseId="horizontal-tabs-example">
      <TabList aria-label="My tabs">
        <Tab>Tab 1</Tab>
        <Tab disabled>Tab 2</Tab>
        <Tab id={selectedId}>Tab 3</Tab>
      </TabList>
      <TabPanels>
        <TabPanel>Tab 1</TabPanel>
        <TabPanel>Tab 2</TabPanel>
        <TabPanel>Tab 3</TabPanel>
      </TabPanels>
    </Tabs>
  );
};

render(
  <HorizontalTabsExample />
)
`.trim();

export const VerticalTabsExample = `
const VerticalTabsExample = () => {
  const selectedId = useUID();
  return (
    <Tabs orientation="vertical" selectedId={selectedId} baseId="vertical-tabs-example">
      <TabList aria-label="My tabs">
        <Tab id={selectedId}>Tab 1 is a long tab name because the server sent a long tab name</Tab>
        <Tab>Tab 2</Tab>
        <Tab>Tab 3</Tab>
      </TabList>
      <TabPanels>
        <TabPanel>Tab 1</TabPanel>
        <TabPanel>Tab 2</TabPanel>
        <TabPanel>Tab 3</TabPanel>
      </TabPanels>
    </Tabs>
  );
};

render(
  <VerticalTabsExample />
)
`.trim();
import { MinMax } from '../../../src/math/minmax';
import { Vec2AsObject } from '../../../src/math/vec2';
import {
  Body, Shape, Spring, Stick, StickOrSpring, Vec2,
} from '../../../src/physics';
import Group from './group';

/**
 * Converts a body into a plain object.
 *
 * @param {Body} body The body to be serialised
 * @param {number | 'none'} textureNum The index of the texture of the body
 * @returns {any} The body as a JSON string
 */
function bodyToPlain(body: Body, textureNum: number | 'none' = 'none') {
  const plain: any = body.copy;
  plain.texture = textureNum;
  return plain;
}

/**
 * Converts a spring or stick into a plain object.
 *
 * @param {Stick


 1527, 17669, 19, 24, 673, 17, 28756, 150, 12943, 4354, 153, 27, 442, 37, 45, 668, 21, 24, 256, 20, 416, 22, 2771, 4901, 9, 12943, 4354, 153, 51, 24, 3004, 21, 28142, 23, 65, 20, 18, 416, 34, 24, 2958, 22947, 9, 1177, 45, 668, 3097, 13768, 23, 103, 28, 441, 148, 48, 20522, 19, 12943, 4354, 153, 12860, 34, 18, 326, 27, 17492, 684, 21, 6709, 9, 8585, 123, 266, 19, 12943, 4354, 153, 6872, 24, 3004, 20, 18, 9225, 2198, 19, 12717, 103, 22, 401, 24, 6348, 9, 12943, 4354, 153, 1068, 2768, 2286, 19, 33, 104, 19, 176, 24, 9313, 19, 20086, 28, 45, 10292, 9, 4, 3, 19, 12943, 4354, 153, 27, 442, 22, 2771, 4901, 9, 69, 27, 442, 22, 2771, 24, 11335, 20, 18, 9225, 2198, 9, 69, 27, 442, 22, 2771, 24, 11335, 20, 18, 9225, 2198, 9, 69, 27, 442, 22, 2771,
        ]
        # fmt: on
        #  In 1991, the remains of Russian Tsar Nicholas II and his family (except for Alexei and Maria)
        #  are discovered. The voice of Nicholas's young son, Tsarevich Alexei Nikolaevich,
        #  narrates the remainder of the story. 1883 Western Siberia, a young Grigori Rasputin
        #  is asked by his father and a group of men to perform magic. Rasputin has a vision and
        #  denounces one of the men as a horse thief. Although his father initially slaps
        #  him for making such an accusation, Rasputin watches as the man is chased outside and beaten.
        #  Twenty years later, Rasputin sees a vision of the Virgin Mary, prompting him to become a priest.
        #  Rasputin quickly becomes famous, with people, even a bishop, begging for his blessing.
        #  <sep><cls>, Rasputin is asked to perform magic. He is asked to perform a ritual of the Virgin Mary.
        #  He is asked to perform a ritual of the Virgin Mary. He is asked to perform

        output_ids = model.generate(input_ids, max_length=200, do_sample=False)
        self.assertListEqual(output_ids[0].tolist(), expected_output_ids)


y.ArmyData);
                }
            }
        }

        private void OnTriggerExit(Collider other) {
            //ײʱ¾uiʾ
            ArmyModelDetector detector = other.gameObject.GetComponent<ArmyModelDetector>();
            if (detector != null) {
                Army army = detector.GetComponentInParent<Army>();
                if (army != null) {
                    //Debug.Log("army nomore collision!");

                    //⵽army岻ײui
                    UpdateThisArmyUI(army.ArmyData, false);
                }
            }

        }

        private void UpdateThisArmyUI(ArmyData collisionArmyData, bool IsAdd = true) {
            if (IsAdd) {
                //thisArmyData.UpdateArmyUI_Add(collisionArmyData);
            } else {
                //ȥarmydata
                //thisArmyData.UpdateArmyUI_Reduce(collisionArmyData);
            }

        }
    }
}


   paths = dict()
    paths['exec'] = os.path.join(cur_dir, '../../bin/joy')
    paths['pcap'] = os.path.join(cur_dir, '../pcaps/sample.pcap')

    validate_exporter = ValidateExporter(paths=paths)
    validate_exporter.validate_export_against_sniff()

def main_ipfix():
    """
    Main IPFIX testing entry point.
    :return:
    """
    global logger
    logger = logging.getLogger(__name__)

    os_platform = platform.system()
    unix_platforms = ['Linux', 'Darwin']

    if os_platform in unix_platforms:
        test_unix_os()

    logger.warning('SUCCESS')


    AreaInfo &area = info.areas[info.active];

            if (randoms.empty() && active && mixer) {
                area.time += ms;
                if (area.time > area.randomTime) {
                    // Create random ambient
                    const std::string &file = area.getRandomSound();
                    float volume = area.getRandomVolume();
                    float panning = area.getRandomPanning();

                    if ( !file.empty() ) {
                        boost::shared_ptr<Stream> ptr( new Stream(mixer->getStream(
                                                               file.c_str(),
                                                               SoundMixer::SOUNDSTREAMTYPE_AMBIENT), volume, panning) );
                        if (ptr) {
                            randoms.push_back(ptr);
                        } else {
                            Logger::getInstance()->warning("Unable to load random ambient stream");
                            Logger::getInstance()->warning( file.c_str() );
                        }
                    }

                    area.time = 0;
                    area.makeRandomTime();
                }
            }
        }

        void fadeOut(int ms)
        {
            AmbientStreamList::iterator it = ambients.begin();
            for (; it != ambients.end(); ++it) {
                (*it)->fadeOut(ms);
            }

            it = randoms.begin();
            for (; it != randoms.end(); ++it) {
                (*it)->fadeOut(ms);
            }

            active = false;
        }
    };

    AmbientAreaManager::AmbientAreaManager(SoundMixer *mixer)
    {
        scoped_ptr<Data> tempData( new Data(mixer) );
        data.swap(tempData);
    }

    AmbientAreaManager::~AmbientAreaManager()
    {
    }

    void AmbientAreaManager::loadList(const std::string &file)
    {
        data->load(file);
    }

    void AmbientAreaManager::enterArea(AreaType type)
    {
        data->enterArea(type);
    }

    void AmbientAreaManager::setArea(AreaType type, const std::string &name)
    {
        data->setArea(type, name);
    }

    void AmbientAreaManager::setEaxArea(AreaType type, const std::string &name)
    {
        data->setEaxArea(type, name);
    }

    void AmbientAreaManager::fadeIn()
    {
        data->fadeIn();
    }

    void AmbientAreaManager::update(int ms)
    {
        if (ms > 100)
            ms = 100;

        data->update(ms);
    }

    void AmbientAreaManager::fadeOut(int ms)
    {
        data->fadeOut(ms);
    }

    void AmbientAreaManager::enableAmbient()
    {
        if (data->ambientEnabled)
            return;

        data->setArea(Outdoor, data->oldActives[0]);
        data->setArea(Indoor, data->oldActives[1]);

        data->ambientEnabled = false;
    }

    void AmbientAreaManager::disableAmbient()
    {
        if (!data->ambientEnabled)
            return;

        data->ambientEnabled = false;

        data->oldActives[0] = data->list[0].active;
        data->oldActives[1] = data->list[1].active;

        data->setArea(Outdoor, "VerySpecialSilentArea");
        data->setArea(Indoor, "VerySpecialSilentArea");
    }

} // sfx

// Copyright(C) Jukka Kokkonen, 2002

#include "DummyConnection.h"

#include "DummyBind.h"
#include "DummyDriver.h"
#include "../../system/Timer.h"
#include <assert.h>

// TEMP: for debugging
#include <stdio.h>

#define DUMMYCONNECTION_BUF_SIZE (65536 * 4) * 2

namespace net
{
  namespace dummy
  {

		int DummyConnection::lagRand[DUMMYCONNECTION_LAG_RAND_AMOUNT] =
		{ 0, 30, 60, 100, 100, -20, -20, 100, 0, 40,
			0, -30, -60, -100, -100, 20, 20, -100, 0, -40, };

    DummyConnection::DummyConnection(DummyConnection *peer)
    {
      this->connectedTo = peer;
      if (peer != NULL)
      {
        peer->connectedTo = this;
      }
      recvBuf = new char[DUMMYCONNE


space,
			"scope.type", "namespace-scoped")
	} else {
		setupLog.Info("Operator watching all namespaces",
			"scope.type", "cluster-wide")
	}

	// Create controller-runtime manager
	setupLog.Info("Creating controller-runtime manager",
		"component", "controller-manager")
	mgrOptions := ctrl.Options{
		Scheme:                 scheme,
		LeaderElection:         false,
		WebhookServer:          webhookServer,
		HealthProbeBindAddress: fmt.Sprintf(":%d", cfg.HealthPort), // Enable health probes
	}

	// Set namespace if watching specific namespace
	if watchNamespace != "" {
		setupLog.Info("Setting namespace-scoped cache",
			"component", "controller-manager",
			"watch.namespace", watchNamespace)
		mgrOptions.Cache = cache.Options{
			DefaultNamespaces: map[string]cache.Config{
				watchNamespace: {},
			},
		}
	}

	mgr, err := ctrl.NewManager(k8sConfig, mgrOptions)
	if err != nil {
		setupLog.Error("Failed to create controller manager", err,
			"controller.manager.type", "webhook")
		os.Exit(1)
	}
	setupLog.Info("Controller manager created successfully",
		"component", "controller-manager")

	// Set controller-runtime logger to use our OpenTelemetry logger
	// This prevents "log.SetLogger(...) was never called" warnings and captures controller logs
	ctrl.SetLogger(observability.NewLogr("controller-runtime"))

	// Use the main context

	// Setup TLS certificate management
	setupLog.Info("Setting up TLS certificate management",
		"component", "certificate-manager",
		"tls.certificate.validity_days", cfg.CertValidityDays,
		"tls.certificate.refresh_days", cfg.CertRefreshDays,
		"k8s.secret.name", cfg.SecretName)
	certManager := openlitwebhook.NewCertificateManager(
		client,
		cfg.Namespace,
		cfg.ServiceName,
		cfg.SecretName,
		cfg.CertValidityDays,
		cfg.CertRefreshDays,
	)
	setupLog.Info("Certificate manager created",
		"component", "certificate-manager")

	// Ensure certificates exist
	setupLog.Info("Ensuring TLS certificates",
		"component", "certificate-manager")
	caCert, err := certManager.EnsureCertificate(ctx)
	if err != nil {
		fmt.Printf("DEBUG: Failed to ensure certificates: %v\n", err)
		setupLog.Error("Failed to ensure TLS certificate", err,
			"k8s.secret.name", cfg.SecretName,
			"k8s.namespace.name", cfg.Namespace)
		os.Exit(1)
	}
	fmt.Printf("DEBUG: Certificates ensured successfully\n")

	// Setup webhook configuration
	webhookConfigManager := openlitwebhook.NewWebhookConfigManager(
		client,
		cfg.Namespace,
		cfg.ServiceName,
		cfg.ConfigName,
		cfg.WebhookPath,
		443, // Service port
		cfg.FailurePolicy,
		cfg.ReinvocationPolicy,
		observability.NewLogger("webhook-config").WithContext(ctx),
	)

	// Note: Webhook configuration will be created after the manager starts and webhook server is ready

	// Copy certificates to filesystem for webhook server
	fmt.Printf("DEBUG: About to copy certificates to filesystem...\n")
	if err := copyCertificatesToFileSystem(ctx, client, cfg.Namespace, cfg.SecretName, cfg.WebhookCertDir, setupLog); err != nil {
		fmt.Printf("DEBUG: Failed to copy certificates: %v\n", err)
		setupLog.Error("Failed to copy certificates to filesystem", err,
			"certificate.directory", cfg.WebhookCertDir,
			"k8s.secret.name", cfg.SecretName)
		os.Exit(1)


                }
                }
            }
        }

        // Image element classification.
        inline bool IsValid(size_t i) const
        {
            return (Real)0 <= mTimes[i] && mTimes[i] < std::numeric_limits<Real>::max();
        }

        inline bool IsTrial(size_t i) const
        {
            return mTrials[i] != nullptr;
        }

        inline bool IsFar(size_t i) const
        {
            return mTimes[i] == std::numeric_limits<Real>::max();
        }

        inline bool IsZeroSpeed(size_t i) const
        {
            return mTimes[i] == -std::numeric_limits<Real>::max();
        }

        inline bool IsInterior(size_t i) const
        {
            return IsValid(i) && !IsTrial(i);
        }

        void GetInterior(std::vector<size_t>& interior) const
        {
            interior.clear();
            for (size_t i = 0; i < mQuantity; ++i)
            {
                if (IsValid(i) && !IsTrial(i))
                {
                    interior.push_back(i);
                }
            }
        }

        virtual void GetBoundary(std::vector<size_t>& boundary) const = 0;
        virtual bool IsBoundary(size_t i) const = 0;

        // Run one step of the fast marching algorithm.
        virtual void Iterate() = 0;

    protected:
        size_t mQuantity;
        std::vector<Real> mTimes;
        std::vector<Real> mInvSpeeds;
        MinHeap<size_t, Real> mHeap;
        std::vector<typename MinHeap<size_t, Real>::Record*> mTrials;
    };
}


d {
		return struct{}{}
	}
	initializeVDLCalled = true

	// Register native type conversions first, so that vdl.TypeOf works.
	vdl.RegisterNative(WireMultiImportToNative, WireMultiImportFromNative)
	vdl.RegisterNative(WireSamePkgToNative, WireSamePkgFromNative)
	vdl.RegisterNative(WireStringToNative, WireStringFromNative)
	vdl.RegisterNative(WireTimeToNative, WireTimeFromNative)

	// Register types.
	vdl.Register((*WireString)(nil))
	vdl.Register((*WireTime)(nil))
	vdl.Register((*WireSamePkg)(nil))
	vdl.Register((*WireMultiImport)(nil))
	vdl.Register((*WireRenameMe)(nil))
	vdl.Register((*WireAll)(nil))
	vdl.Register((*ignoreme)(nil))

	// Initialize type definitions.
	vdlTypeInt321 = vdl.TypeOf((*WireString)(nil))
	vdlTypeInt322 = vdl.TypeOf((*WireTime)(nil))
	vdlTypeInt323 = vdl.TypeOf((*WireSamePkg)(nil))
	vdlTypeInt324 = vdl.TypeOf((*WireMultiImport)(nil))
	vdlTypeInt325 = vdl.TypeOf((*WireRenameMe)(nil))
	vdlTypeStruct6 = vdl.TypeOf((*WireAll)(nil)).Elem()
	vdlTypeString7 = vdl.TypeOf((*ignoreme)(nil))

	return struct{}{}
}
// Copyright 2015 The Vanadium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package testutil

import (
	"io"
	"sort"

	v23 "v.io/v23"
	"v.io/v23/context"
	"v.io/v23/naming"
	"v.io/v23/rpc"
)

// GlobName calls __Glob on the given object with the given pattern and returns
// a sorted list of matching object names, or an error.
func GlobName(ctx *context.T, name, pattern string) ([]string, []naming.GlobError, error) {
	client := v23.GetClient(ctx)
	call, err := client.StartCall(ctx, name, rpc.GlobMethod, []interface{}{pattern})
	if err != nil {
		return nil, nil, err
	}
	results := []string{}
	globErrors := []naming.GlobError{}
Loop:
	for {
		var gr naming.GlobReply
		switch err := call.Recv(&gr); err {
		case nil:
			switch v := gr.(type) {
			case naming.GlobReplyEntry:
				results = append(results, v.Value.Name)
			case naming.GlobReplyError:
				globErrors = append(globErrors, v.Value)
			}
		case io.EOF:
			break Loop
		default:
			return nil, nil, err
		}
	}
	sort.Strings(results)
	if err := call.Finish(); err != nil {
		return nil, nil, err
	}
	return results, globErrors, nil
}
// Copyright 2015 The Vanadium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

// Package benchmark implements utilities to augment the standard Go
// testing.Benchmark functionality.
package benchmark

import (
	"bytes"
	"fmt"
	"io"
	"math"
	"time"

	"v.io/x/ref/lib/stats/histogram"
)

// Stats is a simple helper for gathering additional statistics like histogram
// during benchmarks. This is not thread safe.
type Stats struct {
	numBuckets int
	unit       time.Duration
	min, max   int64
	histogram  *histogram.Histogram

	durations durationSlice
	dirty     bool
}

type durationSlice []time.Duration

// NewStats creates a new Stats instance. If numBuckets is not positive,
// the default value (16) will be used.
func NewStats(numBuckets int)


ersion: version,
          mode: mode,
          memory: memory,
          parallelism: parallelism,
          iterations: iterations,
          hashLength: hashLength,
          buffer: buffer,
          maxIsolates: 0, // Do not create isolates
          blocksPerProcessingChunk: -1, // No need to give time to other tasks
        );
        assert(lanesLength >= 1);
        for (var i = 0; i < lanesLength; i++) {
          // ignore: invalid_use_of_visible_for_testing_member
          await state.processSegment(
            iteration: iteration,
            slice: slice,
            lane: lanesStart + i,
          );
        }
        replyPort.send(null);
      } catch (error) {
        replyPort.send('Error: $error');
      }
    });
    replyPort.send(receivePort.sendPort);
  }
}
// Copyright 2019-2020 Gohilla.
//
// 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.

import 'dart:typed_data';

import 'package:cryptography/dart.dart';
import 'package:meta/meta.dart';

import '../../cryptography.dart';
import '../_internal/rotate.dart';

/// A pure Dart implementation of [Sha224].
///
/// For examples and more information about the algorithm, see documentation for
/// the class [Sha224].
class DartSha224 extends Sha224 with DartHashAlgorithmMixin {
  static const _initialValues = [
    0xc1059ed8,
    0x367cd507,
    0x3070dd17,
    0xf70e5939,
    0xffc00b31,
    0x68581511,
    0x64f98fa7,
    0xbefa4fa4,
  ];

  const DartSha224() : super.constructor();

  @override
  DartHashSink newHashSink() {
    return _DartSha256BasedState(28, _initialValues);
  }
}

/// A pure Dart implementation of [Sha256].
///
/// For examples and more information about the algorithm, see documentation for
/// the class [Sha256].
class DartSha256 extends Sha256 with DartHashAlgorithmMixin {
  static const _initialValues = [
    0x6a09e667,
    0xbb67ae85,
    0x3c6ef372,
    0xa54ff53a,
    0x510e527f,
    0x9b05688c,
    0x1f83d9ab,
    0x5be0cd19,
  ];

  @literal
  const DartSha256() : super.constructor();

  @override
  DartHashSink newHashSink() {
    return _DartSha256BasedState(32, _initialValues);
  }
}

class _DartSha256BasedState extends DartHashSink implements HashSink {
  static const _noise = [
    0x428a2f98, 0x71374491, 0xb5c0fbcf, 0xe9b5dba5, 0x3956c25b, 0x59f111f1, //
    0x923f82a4, 0xab1c5ed5, 0xd807aa98, 0x12835b01, 0x243185be, 0x550c7dc3,
    0x72be5d74, 0x80deb1fe, 0x9bdc06a7, 0xc19bf174, 0xe49b69c1, 0xefbe4786,
    0x0fc19dc6, 0x240ca1cc, 0x2de92c6f, 0x4a7484aa, 0x5cb0a9dc, 0x76f988da,
    0x983e5152, 0xa831c66d, 0xb00327c8, 0xbf597fc7, 0xc6e00bf3, 0xd5a79147,
    0x06ca6351, 0x14292967, 0x27b70a85, 0x2e1b2138, 0x4d2c6df


]
        if self.fd_config.graph_opt_config.graph_opt_level > 0:
            # 1. Prepare cuda graph input buffers (contain output of subgraphs)

            # 2. Convert dynamic graph to static graph

            backend = (
                ToStaticBackend.CINN if self.fd_config.graph_opt_config.graph_opt_level > 1 else ToStaticBackend.PHI
            )
            self.runnable = apply_to_static_optimization(
                self.runnable.__func__,
                backend,
            ).__get__(self.runnable.__self__)

    def __call__(self, **kwargs):
        if not self.fd_config.graph_opt_config.use_cudagraph:
            return self.runnable(**kwargs)
        if self.cudagraph_piecewise_backend is None:
            self.cudagraph_piecewise_backend = CudaGraphPiecewiseBackend(
                fd_config=self.fd_config, runnable=self.runnable
            )

        assert kwargs["forward_meta"].ids_remove_padding is not None
        real_shape = kwargs["forward_meta"].ids_remove_padding.shape[0]

        if (not kwargs["forward_meta"].step_use_cudagraph) or (real_shape > self.max_captre_size):
            return self.runnable(**kwargs)
        else:
            return self.cudagraph_piecewise_backend.__call__(**kwargs)

    def clear_cudagraph_piecewise_backend(self):
        """ """
        self.cudagraph_piecewise_backend.clear_graph()


bn.cmp   w18, w19
  jal      x1, trigger_fault_if_fg0_not_z

  /* Arithmetic masking:
   1. Generate a random mask
   2. Subtract masks from projective x coordinate
      (x, y, z) -> ((x - m) mod p,
                     y,
                     z)
   3. Convert masked curve point back to affine
      form.
   4. Multiply mask with z^-1 for use in
      affine space. */

  /* Fetch a fresh random number as mask.
       w2 <= URND() */
  bn.wsrr   w2, URND

  /* Subtract random mask from x coordinate of
     projective point.
     The subtraction has to be done within the underlying
     finite field -> mod p.
     w8 = (w8 - w2) mod p */
  bn.subm    w8, w8, w2

  /* Convert masked result back to affine coordinates.
     R = (x_a, y_a) = (w11, w12) */
  jal       x1, proj_to_affine

  /* Store result (masked affine x-coordinate) in DMEM.
     Y-coordinate not needed, will be overwritten with
     mask value below.
     dmem[x] <= x_a = w11 */
  li        x2, 11
  bn.sid    x2, 0(x21)

  /* Get modular inverse z^-1 of projective z coordinate
     and multiply the random masks with z^-1 to
     also convert them into affine space. */

  /* Move z^-1 and x coordinate mask to mul_modp input WDRs.
     z^-1 is still stored in w14 from previous
     proj_to_affine call.
     w25 <= w14 = z^-1
     w24 <= w2 = m_x */
  bn.mov    w25, w14
  bn.mov    w24, w2

  /* Compute modular multiplication of m_x and z^-1.
     w19 = w24 * w25 mod p = m_x * z^-1 mod p = x1 */
  jal       x1, mul_modp

  /* Store "affine" mask to DMEM. Use the y-coordinate
     to save memory (not needed afterwards)
     dmem[y] <= w19 = x1 */
  li        x2, 19
  bn.sid    x2, 0(x22)

  /* Arithmetic-to-boolean conversion.
       w20 <= x ^ x1 = x0 */
  jal       x1, arithmetic_to_boolean_mod

  /* dmem[x] <= w20 = x0 */
  li        x3, 20
  la        x4, x
  bn.sid    x3, 0(x4)

  ret

/**
 * Converts arithmetic shares mod p to boolean shares.
 *
 * Calls the 257-bit A2B function twice, first using unmodified 256-bit shares
 * in reduced form, and then using modified 257-bit shares in unreduced form.
 *
 * It then checks if the MSB (carry bit) is true or false, to decide
 * which of the two A2B results is used. This detects and handles an
 * underflow during the subtraction of arithmetic masking.
 *
 * The logic behind the carry bit handling is as follows:
 * If x >= r, then  A = (x - r) mod p = x - r exactly.
 * So when we add 2^257 - p and then add A and r, we get
 * (2^257 - p + x - r + r) mod 2^257 = 2^257 - p + x.
 * In this case, the high bit is always true since p - x <= p < 2^256,
 * so we choose the A2B conversion without the 2^257 - p added.
 * On the other hand, if x < r, then A = (x - r) mod p = x - r + p.
 * When we add 2^257 - p and then add A and r, we get
 * (2^257 - p + x - r + p + r) mod 2^257 =


stdin), _O_BINARY);
#endif
    setbuf(stdout, NULL);

    fpname = argv[0];
    ++argv;
    while ((*argv) && (!wavloaded)) {
        if      ( (strcmp(*argv, "-h") == 0) || (strcmp(*argv, "--help") == 0) ) {
            fprintf(stderr, "%s [options] audio.wav\n", fpname);
            fprintf(stderr, "  options:\n");
            //fprintf(stderr, "       -v, --verbose\n");
            fprintf(stderr, "       -r, --raw\n");
            fprintf(stderr, "       -c, --color\n");
            //fprintf(stderr, "       -o, --offset\n");
            return 0;
        }
        else if ( (strcmp(*argv, "-v") == 0) || (strcmp(*argv, "--verbose") == 0) ) {
            option_verbose = 1;
        }
        else if ( (strcmp(*argv, "-vv" ) == 0) ) option_verbose = 2;
        else if ( (strcmp(*argv, "-vvv") == 0) ) option_verbose = 3;
        else if ( (strcmp(*argv, "-r") == 0) || (strcmp(*argv, "--raw") == 0) ) {
            option_raw = 1;
        }
        else if ( (strcmp(*argv, "-i") == 0) || (strcmp(*argv, "--invert") == 0) ) {
            option_inv = 1;  // nicht noetig
        }
        else if ( (strcmp(*argv, "-c") == 0) || (strcmp(*argv, "--color") == 0) ) {
            option_color = 1;
        }
        else if   (strcmp(*argv, "--res") == 0) { option_res = 1; }
        else if ( (strcmp(*argv, "--avg") == 0) ) {
            option_avg = 1;
        }
        else if   (strcmp(*argv, "-b") == 0) { option_b = 1; }
        else if ( (strcmp(*argv, "--rawbits") == 0) ) {
            option_rawbits = 1;
        }
        else {
            fp = fopen(*argv, "rb");
            if (fp == NULL) {
                fprintf(stderr, "%s konnte nicht geoeffnet werden\n", *argv);
                return -1;
            }
            wavloaded = 1;
        }
        ++argv;
    }
    if (!wavloaded) fp = stdin;

    i = read_wav_header(fp);
    if (i) {
        fclose(fp);
        return -1;
    }

    pos = FRAMESTART;

    while (!read_bits_fsk(fp, &bit, &len)) {

        if (len == 0) { // reset_frame();
            if (pos > (pos_GPSweek+2)*2*BITS) {
                for (i = pos; i < RAWBITFRAME_LEN; i++) frame_rawbits[i] = 0x30 + 0;
                print_frame(pos);//byte_count
                header_found = 0;
                pos = FRAMESTART;
            }
            //inc_bufpos();
            //buf[bufpos] = 'x';
            continue;   // ...
        }

        for (i = 0; i < len; i++) {

            inc_bufpos();
            buf[bufpos] = 0x30 + bit;  // Ascii

            if (!header_found) {
                header_found = compare2();
            }
            else {
                frame_rawbits[pos] = 0x30 + bit;  // Ascii
                pos++;

                if (pos == RAWBITFRAME_LEN) {
                    frame_rawbits[pos] = '\0';
                    print_frame(pos);//FRAME_LEN
                    header_found = 0;
                    pos = FRAMESTART;
                }
            }

        }
        if (header_found && option_b) {
            bitstart = 1;

            while ( pos < RAWBITFRAME_LEN ) {
                if (read_rawbit(fp, &bit) == EOF) break;
                frame_rawbits[pos] = 0x30 + bit;
                pos++;
            }
            frame_rawbits[pos] = '\0';
            print_frame(pos);//FRAME_LEN
            header_found = 0;
            pos = FRAMESTART;
        }
    }

    printf("\n");

    fclose(fp);

    return 0;
}


isplay: inline-block;
  text-decoration: none; }

.slds-has-inline-block-links--space a {
  display: inline-block;
  text-decoration: none;
  padding: 0.75rem; }

@media (min-width: 48em) {
  .slds-has-inline-block-links--space a {
    padding: 0.5rem; } }

.slds-truncate {
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap; }

.slds-box {
  padding: 1rem;
  border-radius: 0.25rem;
  background-clip: padding-box;
  border: 1px solid #d8dde6; }

.slds-box--x-small {
  padding: 0.5rem; }

.slds-box--small {
  padding: 0.75rem; }

.slds-box--border {
  padding: 0;
  border-radius: 0.25rem;
  background-clip: padding-box;
  border: 1px solid #d8dde6; }

.slds-theme--default {
  background-color: white; }

.slds-theme--shade {
  background-color: #f4f6f9; }

.slds-theme--inverse {
  background-color: #061c3f;
  color: white;
  border-color: #061c3f; }

.slds-theme--inverse a:not(.slds-button--neutral) {
  color: white;
  text-decoration: underline; }

.slds-theme--inverse a:not(.slds-button--neutral):link, .slds-theme--inverse a:not(.slds-button--neutral):visited {
  color: white; }

.slds-theme--inverse a:not(.slds-button--neutral):hover, .slds-theme--inverse a:not(.slds-button--neutral):focus {
  color: rgba(255, 255, 255, 0.75); }

.slds-theme--inverse a:not(.slds-button--neutral):active {
  color: rgba(255, 255, 255, 0.5); }

.slds-theme--inverse a:not(.slds-button--neutral)[disabled] {
  color: rgba(255, 255, 255, 0.15); }

.slds-theme--alt-inverse {
  background-color: #16325c;
  color: white;
  border-color: #16325c; }

.slds-theme--alt-inverse a:not(.slds-button--neutral) {
  color: white;
  text-decoration: underline; }

.slds-theme--alt-inverse a:not(.slds-button--neutral):link, .slds-theme--alt-inverse a:not(.slds-button--neutral):visited {
  color: white; }

.slds-theme--alt-inverse a:not(.slds-button--neutral):hover, .slds-theme--alt-inverse a:not(.slds-button--neutral):focus {
  color: rgba(255, 255, 255, 0.75); }

.slds-theme--alt-inverse a:not(.slds-button--neutral):active {
  color: rgba(255, 255, 255, 0.5); }

.slds-theme--alt-inverse a:not(.slds-button--neutral)[disabled] {
  color: rgba(255, 255, 255, 0.15); }

.slds-theme--success {
  color: white;
  background-color: #04844b; }

.slds-theme--success a:not(.slds-button--neutral) {
  color: white;
  text


= 0, 1 do
for d = 0, 1 do
	local cid = tostring(d)..tostring(c)..tostring(b)..tostring(a)
	local node_name = BASENAME..cid
	local top = "jeija_luacontroller_top.png"
	if a == 1 then
		top = top.."^jeija_luacontroller_LED_A.png"
	end
	if b == 1 then
		top = top.."^jeija_luacontroller_LED_B.png"
	end
	if c == 1 then
		top = top.."^jeija_luacontroller_LED_C.png"
	end
	if d == 1 then
		top = top.."^jeija_luacontroller_LED_D.png"
	end

	local groups
	if a + b + c + d ~= 0 then
		groups = {dig_immediate=2, not_in_creative_inventory=1, overheat = 1}
	else
		groups = {dig_immediate=2, overheat = 1}
	end

	output_rules[cid] = {}
	input_rules[cid] = {}
	if a == 1 then table.insert(output_rules[cid], rules.a) end
	if b == 1 then table.insert(output_rules[cid], rules.b) end
	if c == 1 then table.insert(output_rules[cid], rules.c) end
	if d == 1 then table.insert(output_rules[cid], rules.d) end

	if a == 0 then table.insert( input_rules[cid], rules.a) end
	if b == 0 then table.insert( input_rules[cid], rules.b) end
	if c == 0 then table.insert( input_rules[cid], rules.c) end
	if d == 0 then table.insert( input_rules[cid], rules.d) end

	local mesecons = {
		effector = {
			rules = input_rules[cid],
			action_change = function (pos, _, rule_name, new_state)
				if update_real_port_states(pos, rule_name, new_state) then
					run(pos, {type=new_state, pin=rule_name})
				end
			end,
		},
		receptor = {
			state = mesecon.state.on,
			rules = output_rules[cid]
		},
		luacontroller = {
			get_program = get_program,
			set_program = set_program,
		},
	}

	minetest.register_node(node_name, {
		description = S("Luacontroller"),
		drawtype = "nodebox",
		tiles = {
			top,
			"jeija_microcontroller_bottom.png",
			"jeija_microcontroller_sides.png",
			"jeija_microcontroller_sides.png",
			"jeija_microcontroller_sides.png",
			"jeija_microcontroller_sides.png"
		},
		inventory_image = top,
		paramtype = "light",
		is_ground_content = false,
		groups = groups,
		drop = BASENAME.."0000",
		sunlight_propagates = true,
		selection_box = selection_box,
		node_box = node_box,
		on_construct = reset_meta,
		on_receive_fields = on_receive_fields,
		sounds = mesecon.node_sound.stone,
		mesecons = mesecons,
		digiline = digiline,
		-- Virtual portstates are the ports that
		-- the node shows as powered up (light up).
		virtual_portstates = {
			a = a == 1,
			b = b == 1,
			c = c == 1,
			d = d == 1,
		},
		after_dig_node = function (pos)
			mesecon.do_cooldown(pos)
			mesecon.receptor_off(pos, output_rules)
		end,
		is_luacontroller = true,
		on_timer = node_timer,
		on_blast = mesecon.on_blastnode,
	})
end
end
end


nerator.svgImageDefActive("lock"));
		}
	}

	/**
	 * 数据库 表 ddl语句,操作按钮
	 *
	 * @return
	 */
	public List<Node> tableDDLOptionBtns(SqluckyConnector sqluckyConn, VBox sp, TablePo table) {
		String name = table.getTableName();
		List<Node> ls = new ArrayList<>();
		VBox  vb = this.getTabVBox();
		// 查询按钮
		JFXButton selectBtn = MyBottomSheetUtility.createSelectBtn(sqluckyConn, table.getTableSchema(), name);

		ls.add(selectBtn);

		JFXButton showTableDDLBtn = new JFXButton("Table DDL");
		showTableDDLBtn.setGraphic(IconGenerator.svgImageDefActive("table"));

		JFXButton showIndexBtn = new JFXButton("Index");
		showIndexBtn.setGraphic(IconGenerator.svgImageDefActive("gears"));

		JFXButton showFKBtn = new JFXButton("Foreign Key");
		showFKBtn.setGraphic(IconGenerator.svgImageDefActive("foreign-key"));
		// table ddl
		showTableDDLBtn.setDisable(true);
		showTableDDLBtn.setOnMouseClicked(e -> {
			vb.getChildren().remove(1);
			vb.getChildren().add(sp);
			showTableDDLBtn.setDisable(true);
			showIndexBtn.setDisable(false);
			showFKBtn.setDisable(false);
		});
		ls.add(showTableDDLBtn);

		// 索引
		showIndexBtn.setOnMouseClicked(e -> {
			vb.getChildren().remove(1);
			var indexView = table.indexTableView();
			vb.getChildren().add(indexView);
			showTableDDLBtn.setDisable(false);
			showIndexBtn.setDisable(true);
			showFKBtn.setDisable(false);

		});
		ls.add(showIndexBtn);

		// 外键
		showFKBtn.setOnMouseClicked(e -> {
			vb.getChildren().remove(1);
			var foreignKeyTable = table.foreignKeyTableView();
			vb.getChildren().add(foreignKeyTable);

			showFKBtn.setDisable(true);
			showTableDDLBtn.setDisable(false);
			showIndexBtn.setDisable(false);
		});
		ls.add(showFKBtn);
		return ls;
	}

	public void show(Consumer<String> backcall) {
		this.setText(tableData.getTabName());
		Platform.runLater(() -> {
			var dataTab = ComponentGetter.dataTabPane;
			if (isDDL) {
				dataTab.getTabs().add(this);
			} else {
				if (idx > -1) {
					dataTab.getTabs().add(idx, this);
				} else {
					dataTab.getTabs().add(this);
				}
			}

			SdkComponent.showBottomSheetPane();
			dataTab.getSelectionModel().select(this);
			if(backcall != null ){
				backcall.accept("");
			}
		});
	}
	public void show() {
		show(null);
	}

	// 获取所有数据
	public ObservableList<ResultSetRowPo> getTabData() {
		ResultSetPo spo = tableData.getDataRs();
		ObservableList<ResultSetRowPo> val = spo.getDatas();
		return val;

	}

	public void rmAppendData() {
		tableData.getDataRs().getNewDatas().clear();
	}

	// 获取当前表中的信息: 连接, 表面, schema, ExportDDL类, 然后导出drop语句
	public RsVal tableInfo() {


}

/// A connection handler manages an incoming network connection.
#[async_trait]
pub trait ConnectionHandler {
    /// Returns the name of the connection handler for use in e.g. log messages.
    fn name(&self) -> &str;

    /// Determines whether this handler can accept the connection based on the
    /// first several bytes in the stream.
    fn match_handshake(&self, buf: &[u8]) -> bool;

    /// Handles the connection.
    async fn handle_connection(&self, conn: SniffedStream<TcpStream>) -> Result<(), anyhow::Error>;
}

#[async_trait]
impl ConnectionHandler for pgwire::Server {
    fn name(&self) -> &str {
        "pgwire server"
    }

    fn match_handshake(&self, buf: &[u8]) -> bool {
        pgwire::match_handshake(buf)
    }

    async fn handle_connection(&self, conn: SniffedStream<TcpStream>) -> Result<(), anyhow::Error> {
        // Using fully-qualified syntax means we won't accidentally call
        // ourselves (i.e., silently infinitely recurse) if the name or type of
        // `pgwire::Server::handle_connection` changes.
        pgwire::Server::handle_connection(self, conn).await
    }
}

#[async_trait]
impl ConnectionHandler for http::Server {
    fn name(&self) -> &str {
        "http server"
    }

    fn match_handshake(&self, buf: &[u8]) -> bool {
        self.match_handshake(buf)
    }

    async fn handle_connection(&self, conn: SniffedStream<TcpStream>) -> Result<(), anyhow::Error> {
        // Using fully-qualified syntax means we won't accidentally call
        // ourselves (i.e., silently infinitely recurse) if the name or type of
        // `http::Server::handle_connection` changes.
        http::Server::handle_connection(self, conn).await
    }
}
use std::fmt;
use bacon_rajan_cc::{Cc, Trace, Tracer};
use downcast_rs::Downcast;
use downcast_rs::impl_downcast;

use crate::interpreter::Namespace;

#[derive(Clone, Debug)]
pub enum SExpr {
    Atom(Atom),
    List(Vec<Cc<SExpr>>)
}

impl Trace for SExpr {
    fn trace(&mut self, tracer: &mut Tracer) {
        match self {
            SExpr::Atom(atom) => atom.trace(tracer),
            SExpr::List(list) => {
                for item in list.iter_mut() {
                    tracer(item);
                }
            }
        };
    }
}

#[derive(Clone, Debug)]
pub enum Atom {
    Native(NativeAtom),
    Extern(Box<dyn ExternObj>)
}

impl Trace for Atom {
    fn trace(&mut self, tracer: &mut Tracer) {
        match self {
            Atom::Native(na) => na.trace(tracer),
            Atom::Extern(ea) => ea.trace(tracer)
        };
    }
}

#[derive(Clone, Debug)]
pub enum NativeAtom {
    Int(i64),
    Float(f64),
    Str(String),
    Ident(String),
    Function(Function)
}

impl Trace for NativeAtom {
    fn trace(&mut self, tracer: &mut Tracer) {
        if let NativeAtom::Function(Function::Native(nf)) = self {
            nf.trace(tracer)
        }
    }
}

#[derive(Clone, Debug)]
pub enum Function {
    Native(NativeFunction),
    Extern(ExternFunction),
}

#[derive(Clone, Debug)]
pub


MS4944Uf53DPER6lS7z885QDZzhKSgAg1cBSelGoqWNx/Aczcp+u3OB9/yoAc6ZLPb6HYRuAvfI1r3qTigANvUnQUzz7fZ3cC8fF86KY4G2xhnMpAA29zc+gA8Mo+sUXt8x3r7RdTDcId6s75F4I0TkAAnMABh1mbdsqraTHlcqDUf6FMcjtIpl0cGQD4J/ORJZUD7FydnTLfYuEPSCDUODCEHAuZUrfsVVe4nzcGgE+xGS6CkAkfbyIGT4tI5NVHJfZ7DdGQE09U1ETo58Bj4QwcAjRSayvM6uWA29oxrsAFGGaTrnCabNORfZJJOiomE65Qk33aZodqrLBJA8Zk68c05JP9g4AAopHsL7OVlmhYBaAb/4WbfecXqjxoRxn9/8KhGm1XEsKUu3ypneCmchx6KJBWcYBcCHe5qOdZ6OfCE8mmjzON4fBjpYAEYHldOEvWC+X2MoSbmcAAAAASUVORK5CYII=);
  *content: url(images/arrows_user_online.png); /* IE7 and below */
}
.user_offline:after {
  margin: 0px 0px 0px 0px;   border: 0px;   padding: 0px 0px 0px 2px;
  content: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAANCAYAAACdKY9CAAAAAXNSR0IArs4c6QAAAAZiS0dEAP8A/wD/oL2nkwAAAAlwSFlzAAALEwAACxMBAJqcGAAAAQZJREFUKM910L8rhXEUBvDP+3qvK5IrPyZFUWQwmGS6GRjVHZVMdqv8JQbFqJRiVBY/BgNltclw0y1E9w7cy3LeehOnvn37fp/znOc5T4IZ7GDc39WO+wPrCa5xgmNMYzkannCERrw3UU3RwR56sY0+tLCKLZSCsI9KigSfWMFUWCzjIMgDQRhEkhU8juEQuwX/V5jDBbohK4AN1GNSXrN4DsUvpDmhhHtUfyVUwk0hrSyLHcoBLGG+QHjDCN7xjU6u0IN+vGAYd/E/hBrO8YpWHqsAHnGLB5zFgGYoyxXSmD4ZYAML0dTERHGpLLavhY3FSGU08Ho4uMQGsgQVnKLL/9WOs/YD64M56EAviLYAAAAASUVORK5CYII=);
  *content: url(images/arrows_user_offline.png); /* IE7 and below */
}
.user_idle:after {
  margin: 0px 0px 0px 0px;   border: 0px;   padding: 0px 0px 0px 2px;
  content: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAANCAYAAACdKY9CAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAdtJREFUeNp0kUtoE1EUhr87M7FJCCatWhJpjdSm6CoUihsbdGE3YkWk+FroWiniQopUEOtO3PgAQdCFCkJA7LZu2oVVKUhpLPhM1RRBWgqNkEyquTO3944ObvRsDufxn/+c/4jHDzhz9z43ymUc/mG2jTI+mUKNXWW3yGTwzg1TzXYwWmtwcHKS/aYhn8ftynEhEmHOxB/eMvHwEW2W0EF3F4e


ACK_IMPORTED_MODULE_0__.resolveComponent)("router-link");
  return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)("tr", null, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)("td", _hoisted_1, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)("input", {
    type: "checkbox",
    name: "select",
    checked: $props.checked,
    onInput: _cache[0] || (_cache[0] = function ($event) {
      return _ctx.$emit('select');
    }),
    "class": "cursor-pointer w-4 h-4 text-blue-600 border-gray-400 rounded focus:ring-blue-600 focus:ring-2 form-checkbox"
  }, null, 40 /* PROPS, HYDRATE_EVENTS */, _hoisted_2)]), ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(true), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)(vue__WEBPACK_IMPORTED_MODULE_0__.Fragment, null, (0,vue__WEBPACK_IMPORTED_MODULE_0__.renderList)($props.resource.fields, function (field) {
    return (0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementBlock)("td", {
      "class": (0,vue__WEBPACK_IMPORTED_MODULE_0__.normalizeClass)(["px-6 py-4 whitespace-nowrap", ["text-".concat(field.align)]])
    }, [((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBlock)(), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createBlock)((0,vue__WEBPACK_IMPORTED_MODULE_0__.resolveDynamicComponent)("index-".concat(field.component)), {
      field: field
    }, null, 8 /* PROPS */, ["field"]))], 2 /* CLASS */);
  }), 256 /* UNKEYED_FRAGMENT */)), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)("td", _hoisted_3, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createElementVNode)("div", _hoisted_4, [(0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(" Details link "), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_router_link, {
    to: {
      name: 'resource-show',
      params: {
        resourceName: _ctx.$route.params.resourceName,
        resourceId: $props.resource.key
      }
    },
    "class": "focus:outline-none focus:ring-2 focus:ring-blue-600 rounded hover:text-blue-600 p-1.5"
  }, {
    "default": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(function () {
      return [_hoisted_5];
    }),
    _: 1 /* STABLE */
  }, 8 /* PROPS */, ["to"]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(" Edit link "), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createVNode)(_component_router_link, {
    to: {
      name: 'resource-edit',
      params: {
        resourceName: _ctx.$route.params.resourceName,
        resourceId: $props.resource.key
      }
    },
    "class": "focus:outline-none focus:ring-2 focus:ring-blue-600 rounded hover:text-blue-600 p-1.5"
  }, {
    "default": (0,vue__WEBPACK_IMPORTED_MODULE_0__.withCtx)(function () {
      return [_hoisted_6];
    }),
    _: 1 /* STABLE */
  }, 8 /* PROPS */, ["to"]), (0,vue__WEBPACK_IMPORTED_MODULE_0__.createCommentVNode)(" Remove button "), !$props.resource.trashed ? ((0,vue__WEBPACK_IMPORTED_MODULE_0__.openBloc


#!/usr/bin/env python

from __future__ import print_function

# this example requires the pyliblo library from http://das.nasophon.de/pyliblo
import liblo, sys

# set the target address where MidiOSC will be listening (assumes the default port is used)
try:
    midiosc = liblo.Address("localhost", 8000)
except liblo.AddressError, err:
    print(err)
    sys.exit()

# change the device name to something appropriate for your system
device_name = "IAC Driver Bus 1".replace(' ', '_')
osc_address = "/midi/" + device_name + "/0"

# send a note on with note number 60 and velocity 100
liblo.send(midiosc, osc_address, "note_on", 60, 100)

# send a note off with note number 60 and velocity 0
liblo.send(midiosc, osc_address, "note_off", 60, 0)

# now to receive some messages
try:
    server = liblo.Server(7001)
except liblo.ServerError, err:
    print(err)
    sys.exit()

def callback(path, args, types, src):
    print("Got {0}".format(path))
    for a, t in zip(args, types):
        print("Argument type: {0}, value: {1}".format(t, a))

server.add_method(None, None, callback)

print("Kill the process with ctrl-c when you get bored")
while True:
    server.recv(100)


standard.com/world-news/no-govt-instructions-to-block-internet-during-polls-pakistan-telecom-body-124020800226_1.html">published report, The Pakistan Telecommunication Authority (PTA) said that Internet services would remain available as citizens went to the polls on February 8 to elect a new government. However, on that day, Pakistani authorities cut mobile Internet access across the country as the nation’s voters went to cast their ballots, with the authorities attributing the move "to maintain law and order" in the wake of the violence that occurred the previous day. The impact of the ordered shutdown was visible across multiple Internet providers in Pakistan, including AS59257 (Zong/CMPak), AS24499 (Telenor Pakistan), and AS45669 (Jazz/Mobilink), lasting from 07:00 until 20:00 (02:00 - 15:00 UTC), with traffic returning to expected levels approximately nine hours later. A post on the Internet Society’s Pulse blog estimated that the shutdown cost Pakistan nearly USD $18.5M in lost Gross Domestic Product.

Chad

			<svg width="16" height="16" viewBox="0 0 24 24">
				<path fill="currentcolor" d="m12.11 15.39-3.88 3.88a2.52 2.52 0 0 1-3.5 0 2.47 2.47 0 0 1 0-3.5l3.88-3.88a1 1 0 0 0-1.42-1.42l-3.88 3.89a4.48 4.48 0 0 0 6.33 6.33l3.89-3.88a1 1 0 1 0-1.42-1.42Zm8.58-12.08a4.49 4.49 0 0 0-6.33 0l-3.89 3.88a1 1 0 0 0 1.42 1.42l3.88-3.88a2.52 2.52 0 0 1 3.5 0 2.47 2.47 0 0 1 0 3.5l-3.88 3.88a1 1 0 1 0 1.42 1.42l3.88-3.89a4.49 4.49 0 0 0 0-6.


CREATE_NOTIFY: UShort = 2743u
    const val BLOSSOM_CHEST_INFO_NOTIFY: UShort = 847u
    const val BONUS_ACTIVITY_INFO_REQ: UShort = 2548u
    const val BONUS_ACTIVITY_INFO_RSP: UShort = 2599u
    const val BONUS_ACTIVITY_UPDATE_NOTIFY: UShort = 2539u
    const val BOSS_CHEST_ACTIVATE_NOTIFY: UShort = 861u
    const val BOUNCE_CONJURING_SETTLE_NOTIFY: UShort = 8653u
    const val BRICK_BREAKER_PLAYER_READY_NOTIFY: UShort = 5396u
    const val BRICK_BREAKER_PLAYER_SET_AVATAR_NOTIFY: UShort = 5362u
    const val BRICK_BREAKER_PLAYER_SET_CHANGING_NOTIFY: UShort = 5370u
    const val BRICK_BREAKER_PLAYER_SET_SKILL_NOTIFY: UShort = 5351u
    const val BRICK_BREAKER_QUIT_REQ: UShort = 24991u
    const val BRICK_BREAKER_QUIT_RSP: UShort = 24959u
    const val BRICK_BREAKER_SELECT_AVATAR_REQ: UShort = 5368u
    const val BRICK_BREAKER_SELECT_AVATAR_RSP: UShort = 5359u
    const val BRICK_BREAKER_SELECT_SKILL_REQ: UShort = 5329u
    const val BRICK_BREAKER_SELECT_SKILL_RSP: UShort = 5386u
    const val BRICK_BREAKER_SET_CHANGING_REQ: UShort = 5358u
    const val BRICK_BREAKER_SET_CHANGING_RSP: UShort = 5314u
    const val BRICK_BREAKER_SET_READY_REQ: UShort = 5371u
    const val BRICK_BREAKER_SET_READY_RSP: UShort = 5332u
    const val BRICK_BREAKER_SETTLE_NOTIFY: UShort = 23886u
    const val BRICK_BREAKER_TWICE_START_REQ: UShort = 24700u
    const val BRICK_BREAKER_TWICE_START_RSP: UShort = 20232u
    const val BUOYANT_COMBAT_SETTLE_NOTIFY: UShort = 8751u
    const val BUY_BATTLE_PASS_LEVEL_REQ: UShort = 2643u
    const val BUY_BATTLE_PASS_LEVEL_RSP: UShort = 2609u
    const val BUY_GOODS_REQ: UShort = 756u
    const val BUY_GOODS_RSP: UShort = 719u
    const val BUY_RESIN_REQ: UShort = 693u
    const val BUY_RESIN_RSP: UShort = 654u
    const val CALC_WEAPON_UPGRADE_RETURN_ITEMS_REQ: UShort = 666u
    const val CALC_WEAPON_UPGRADE_RETURN_ITEMS_RSP: UShort = 652u
    const val CANCEL_CITY_REPUTATION_REQUEST_REQ: UShort = 2857u
    const val CANCEL_CITY_REPUTATION_REQUEST_RSP: UShort = 2827u
    const val CANCEL_COOP_TASK_REQ: UShort = 1993u
    const val CANCEL_COOP_TASK_RSP: UShort = 1959u
    const val CANCEL_FINISH_PARENT_QUEST_NOTIFY: UShort = 422u
    const val CAN_USE_SKILL_NOTIFY: UShort = 1042u
    const val CARD_PRODUCT_REWARD_NOTIFY: UShort = 4135u
    const val CATA_LOG_FINISHED_GLOBAL_WATCHER_ALL_DATA_NOTIFY:


rray, dim: *const pblong) -> pbvalue;
    pub fn pbsession_SetValue(session: pbsession, dest: pbvalue, src: pbvalue);
    pub fn pbsession_SetArrayItemValue(session: pbsession, arr: pbarray, dim: *const pblong, src: pbvalue);
    pub fn pbsession_ReleaseValue(session: pbsession, value: pbvalue);

}

/// Arguments
extern "C" {
    pub fn pbargs_GetCount(pArgs: pbarguments) -> pbint;
    pub fn pbargs_GetAt(pArgs: pbarguments, index: pbint) -> pbvalue;
}

/// Value
extern "C" {
    pub fn pbvalue_GetClass(pVal: pbvalue) -> Option<pbclass>;
    pub fn pbvalue_GetType(pVal: pbvalue) -> pbuint;
    pub fn pbvalue_IsArray(pVal: pbvalue) -> pbboolean;
    pub fn pbvalue_IsObject(pVal: pbvalue) -> pbboolean;
    pub fn pbvalue_IsEnum(pVal: pbvalue) -> pbboolean;
    pub fn pbvalue_IsByRef(pVal: pbvalue) -> pbboolean;

    pub fn pbvalue_IsNull(pVal: pbvalue) -> pbboolean;
    pub fn pbvalue_SetToNull(pVal: pbvalue) -> PBXRESULT;

    pub fn pbvalue_GetInt(pVal: pbvalue) -> pbint;
    pub fn pbvalue_GetUint(pVal: pbvalue) -> pbuint;
    pub fn pbvalue_GetBool(pVal: pbvalue) -> pbboolean;
    pub fn pbvalue_GetLong(pVal: pbvalue) -> pblong;
    pub fn pbvalue_GetUlong(pVal: pbvalue) -> pbulong;
    pub fn pbvalue_GetReal(pVal: pbvalue) -> pbreal;
    pub fn pbvalue_GetDouble(pVal: pbvalue) -> pbdouble;
    pub fn pbvalue_GetDecimal(pVal: pbvalue) -> pbdec;
    pub fn pbvalue_GetChar(pVal: pbvalue) -> PBChar;
    pub fn pbvalue_GetString(pVal: pbvalue) -> pbstring;
    pub fn pbvalue_GetObject(pVal: pbvalue) -> pbobject;
    pub fn pbvalue_GetArray(pVal: pbvalue) -> pbarray;
    pub fn pbvalue_GetTime(pVal: pbvalue) -> pbtime;
    pub fn pbvalue_GetDate(pVal: pbvalue) -> pbdate;
    pub fn pbvalue_GetDateTime(pVal: pbvalue) -> pbdatetime;
    pub fn pbvalue_GetLongLong(pVal: pbvalue) -> pblonglong;
    pub fn pbvalue_GetBlob(pVal: pbvalue) -> pbblob;

    pub fn pbvalue_SetInt(pVal: pbvalue, v: pbint) -> PBXRESULT;
    pub fn pbvalue_SetUint(pVal: pbvalue, v: pbuint) -> PBXRESULT;
    pub fn pbvalue_SetBool(pVal: pbvalue, v: pbboolean) -> PBXRESULT;
    pub fn pbvalue_SetLong(pVal: pbvalue, v: pblong) -> PBXRESULT;
    pub fn pbvalue_SetUlong(pVal: pbvalue, v: pbulong) -> PBXRESULT;
    pub fn pbvalue_SetReal(pVal: pbvalue, v: pbreal) -> PBXRESULT;
    pub fn pbvalue_SetDouble(pVal: pbvalue, v: pbdouble) -> PBXRESULT;
    pub fn pbvalue_SetDecimal(pVal: pbvalue, v: pbdec) -> PBXRESULT;
    pub fn pbvalue_SetChar(pVal: pbvalue, v: PBChar) -> PBXRESULT;
    pub fn pbvalue_SetPBString(pVal: pbvalue, v: pbstring) -> PBXRESULT;
    pub fn pbvalue_SetString(pVal: pbvalue, v: LPCTSTR) -> PBXRESULT;
    pub fn pbvalue_SetArray(pVal: pbvalue, v: pbarray) ->


s.anonymous = true
s.addremove = true

o = s:option(Flag, "enable", ("启用"))
o.width = "33%"
o.default = 0
o.rmempty = false

o = s:option(Value, "ip_addr", translate("IP 地址"))
o.width = "33%"
o.datatype = "ip4addr"
o.placeholder = "0.0.0.0/0"
o.rmempty = false
luci.ip.neighbors({ family = 4 }, function(entry)
	if entry.reach


CloudFront caches separate versions of a
/// specified object based on the header values in viewer requests. For example,
/// suppose viewer requests for logo.jpg contain a custom
/// product header that has a value of either acme or
/// apex, and you configure CloudFront to cache your content based
/// on values in the product header. CloudFront forwards the
/// product header to the origin and caches the response from the
/// origin once for each header value. For more information about caching based
/// on header values, see How
/// CloudFront Forwards and Caches Headers in the Amazon CloudFront
/// Developer Guide.
class Headers {
  /// The number of different headers that you want CloudFront to base caching on
  /// for this cache behavior. You can configure each cache behavior in a web
  /// distribution to do one of the following:
  ///
  ///

  ///

  /// Forward all headers to your origin: Specify 1 for
  /// Quantity and * for Name.
  /// <important>
  /// CloudFront doesn't cache the objects that are associated with this cache
  /// behavior. Instead, CloudFront sends every request to the origin.
  /// </important>

  ///

  /// Forward a whitelist of headers you specify: Specify the number of
  /// headers that you want CloudFront to base caching on. Then specify the header
  /// names in Name elements. CloudFront caches your objects based on
  /// the values in the specified headers.
  ///

  ///

  /// Forward only the default headers: Specify 0 for
  /// Quantity and omit Items. In this configuration,
  /// CloudFront doesn't cache based on the values in the request headers.
  ///

  ///

  /// Regardless of which option you choose, CloudFront forwards headers to your
  /// origin based on whether the origin is an S3 bucket or a custom origin. See
  /// the following documentation:
  ///
  ///

  ///

  /// S3 bucket: See HTTP
  /// Request Headers That CloudFront Removes or Updates
  ///

  ///

  /// Custom origin: See HTTP
  /// Request Headers and CloudFront Behavior
  ///

  ///

  final int quantity;

  /// A list that contains one Name element for each header that you
  /// want CloudFront to use for caching in this cache behavior. If
  /// Quantity is 0, omit Items.
  final List<String>? items;

  Headers({
    required this.quantity,
    this.items,
  });
  factory Headers.fromXml(_s.XmlElement elem) {
    return Headers(
      quantity: _s.extractXmlIntValue(elem, 'Quantity')!,
      items: _s
          .extractXmlChild(elem, 'Items')
          ?.let((elem) => _s.extractXmlStringListValues(elem, 'Name')),
    );
  }

  Map<String, dynamic> toJson() {
    final quantity = this.quantity;
    final items = this.items;
    return {
      'Quantity': quantity,
      if (items != null) 'Items': items,
    };
  }

  _s.XmlElement toXml(String elemName, {List<_s.XmlAttribute>? attributes}) {
    final quantity


        },
    )
}
package mega.privacy.android.app.presentation.qrcode.mapper

import android.graphics.Bitmap
import android.graphics.Canvas
import android.graphics.Color
import android.graphics.Paint
import android.graphics.PorterDuff
import android.graphics.PorterDuffXfermode
import android.graphics.Rect
import android.graphics.RectF
import kotlinx.coroutines.CoroutineDispatcher
import kotlinx.coroutines.withContext
import mega.privacy.android.domain.qualifier.IoDispatcher
import javax.inject.Inject

/**
 * Implementation of [GetCircleBitmapMapper]
 */
class DefaultGetCircleBitmapMapper @Inject constructor(
    @IoDispatcher private val ioDispatcher: CoroutineDispatcher,
) : GetCircleBitmapMapper {

    override suspend fun invoke(bitmap: Bitmap): Bitmap = withContext(ioDispatcher) {
        val output = Bitmap.createBitmap(bitmap.width, bitmap.height, Bitmap.Config.ARGB_8888)
        val canvas = Canvas(output)
        val color = Color.RED
        val paint = Paint()
        val rect = Rect(0, 0, bitmap.width, bitmap.height)
        val rectF = RectF(rect)
        paint.isAntiAlias = true
        canvas.drawARGB(0, 0, 0, 0)
        paint.color = color
        canvas.drawOval(rectF, paint)
        paint.xfermode = PorterDuffXfermode(PorterDuff.Mode.SRC_IN)
        canvas.drawBitmap(bitmap, rect, rect, paint)
        bitmap.recycle()
        output
    }
}package mega.privacy.android.app.presentation.extensions.transfers

import androidx.compose.runtime.Composable
import androidx.compose.ui.res.stringResource
import mega.privacy.android.app.R
import mega.privacy.android.domain.entity.transfer.InProgressTransfer
import mega.privacy.android.domain.entity.transfer.TransferState
import mega.privacy.android.shared.resources.R as sharedR
import java.text.DecimalFormat

/**
 * Get the speed string for a given speed as Long.
 */
@Composable
internal fun InProgressTransfer.getSpeedString(
    areTransfersPaused: Boolean,
    isTransferOverQuota: Boolean,
    isStorageOverQuota: Boolean,
): String {
    val df = DecimalFormat("#.##")

    return when {
        isTransferOverQuota -> {
            stringResource(R.string.label_transfer_over_quota)
        }

        isStorageOverQuota -> {
            stringResource(R.string.label_storage_over_quota)
        }

        isPaused || areTransfersPaused -> {
            stringResource(R.string.transfer_paused)
        }

        state == TransferState.STATE_QUEUED -> {
            stringResource(R.string.transfer_queued)
        }

        state == TransferState.STATE_COMPLETING -> {
            stringResource(R.string.transfer_completing)
        }

        state == TransferState.STATE_RETRYING -> {
            stringResource(R.string.transfer_retrying)
        }

        speed < KB -> {
            stringResource(R.string.label_file_speed_byte, speed.toString())
        }

        speed < MB -> {
            stringResource(R.string.label_file_speed_kilo_byte, df.format((speed / KB).toDouble()))
        }

        speed < GB -> {
            stringResource(R.string.label_file_speed_mega_byte, df.format((speed / MB).toDouble()))
        }

        speed < TB -> {
            stringResource(R.string.label_file_speed_giga_byte, df.format((speed / GB).toDouble()))
        }

        speed < PB -> {
            stringResource(R.string.label_file_speed_tera_byte, df.format((speed / TB).toDouble()))
        }

        speed < EB -> {
            stringResource(R.string.label_file_size_peta_byte, df.format((speed / PB).toDouble()))
        }


"""
Pickling
========

This tutorial shows how to use Python's `pickle` module to quickly store and load neurons.

All neuron types including whole [`NeuronLists`][navis.NeuronList] can be "pickled" :cucumber:.
If you don't know what that is: pickling is storing the actual Python object as a
bytes stream. This is incredibly fast and works very well for short-term storage
but has a few downsides:

1. Pickle files can only be re-opened in Python
2. The pickled object is (sort of) specific to your current Python environment. If
   you e.g. update Python, {{ navis }} or even just `numpy` or `pandas` you may not
   be able to open the file again.
3. Pickle files can contain arbitrary Python code. Never open a pickle file from
   an untrusted source!

With that out of the way, pickling is incredibly easy:

```python
import navis
import pickle

# Load some example neurons
nl = navis.example_neurons(3, kind='mesh')

# Pickle neurons to file
with open('/Users/philipps/Downloads//meshes.pkl', 'wb') as f:
    pickle.dump(nl, f)
```

To "unpickle", i.e. read the file back into Python:

```python
# Read neurons back from pickle file
with open('/Users/philipps/Downloads//meshes.pkl', 'rb') as f:
    nl = pickle.load(f)
```

This tutorial has hopefully given you some entry points on how to load your data.
See also the [I/O API reference](../../../api.md#importexport).

"""

# %%

# mkdocs_gallery_thumbnail_path = '_static/pickle.png'


[i];
                if (!tc.HasControls()) continue;

                // search for the header link
                var lnk = tc.Controls[0] as LinkButton;
                if (lnk == null) continue;

                // initialize a new image
                var img = new Image
                {
                    ImageUrl = string.Format("~/images/{0}.png", (sortAscending ? "bullet_arrow_up" : "bullet_arrow_down")),
                    CssClass = "icon"
                };

                // setting the dynamically URL of the image
                // checking if the header link is the user's choice
                if (sortField == lnk.CommandArgument)
                {
                    // adding a space and the image to the header link
                    //tc.Controls.Add(new LiteralControl(" "));
                    tc.Controls.Add(img);
                }
            }
        }

        /// <summary>
        /// Gets the selected items integer list.
        /// </summary>
        /// <param name="listBox">The list box.</param>
        /// <param name="returnAll">Returns all the items regardless if selected or not</param>
        /// <returns></returns>
        public static List<int> GetSelectedItemsIntegerList(ListControl listBox, bool returnAll = false)
        {
            var items = new List<int>();

            foreach (ListItem item in listBox.Items)
            {
                if (!item.Value.Is<int>()) continue;

                if (returnAll || item.Selected)
                    items.Add(int.Parse(item.Value));
            }
            return items;
        }

        /// <summary>
        /// Gets the gravatar image URL.
        /// </summary>
        /// <param name="email">The email id.</param>
        /// <param name="imgSize">Size of the img.</param>
        /// <returns></returns>
        public static string GetGravatarImageUrl(string email, int imgSize)
        {
            // Convert emailID to lower-case
            email = email.Trim().ToLower();

            var emailBytes = Encoding.ASCII.GetBytes(email);
            var hashBytes = new MD5CryptoServiceProvider().ComputeHash(emailBytes);

            Debug.Assert(hashBytes.Length == 16);

            var hash = new StringBuilder();
            foreach (var b in hashBytes)
            {
                hash.Append(b.ToString("x2"));
            }

            // build Gravatar Image URL
            var imageUrl = string.Format("https://www.gravatar.com/avatar/{0}?s={1}&d=identicon&r=g", hash, imgSize);

            return imageUrl;
        }
    }
}


etElementsByTagName("*").length;
	});

	// Check if getElementsByClassName can be trusted
	support.getElementsByClassName = assert(function( div ) {
		div.innerHTML = "

";

		// Support: Safari<4
		// Catch class over-caching
		div.firstChild.className = "i";
		// Support: Opera<10
		// Catch gEBCN failure to find non-leading classes
		return div.getElementsByClassName("i").length === 2;
	});

	// Support: IE<10
	// Check if getElementById returns elements by name
	// The broken getElementById methods don't pick up programatically-set names,
	// so use a roundabout getElementsByName test
	support.getById = assert(function( div ) {
		docElem.appendChild( div ).id = expando;
		return !doc.getElementsByName || !doc.getElementsByName( expando ).length;
	});

	// ID find and filter
	if ( support.getById ) {
		Expr.find["ID"] = function( id, context ) {
			if ( typeof context.getElementById !== strundefined && documentIsHTML ) {
				var m = context.getElementById( id );
				// Check parentNode to catch when Blackberry 4.6 returns
				// nodes that are no longer in the document #6963
				return m && m.parentNode ? [m] : [];
			}
		};
		Expr.filter["ID"] = function( id ) {
			var attrId = id.replace( runescape, funescape );
			return function( elem ) {
				return elem.getAttribute("id") === attrId;
			};
		};
	} else {
		// Support: IE6/7
		// getElementById is not reliable as a find shortcut
		delete Expr.find["ID"];

		Expr.filter["ID"] =  function( id ) {
			var attrId = id.replace( runescape, funescape );
			return function( elem ) {
				var node = typeof elem.getAttributeNode !== strundefined && elem.getAttributeNode("id");
				return node && node.value === attrId;
			};
		};
	}

	// Tag
	Expr.find["TAG"] = support.getElementsByTagName ?
		function( tag, context ) {
			if ( typeof context.getElementsByTagName !== strundefined ) {
				return context.getElementsByTagName( tag );
			}
		} :
		function( tag, context ) {
			var elem,
				tmp = [],
				i = 0,
				results = context.getElementsByTagName( tag );

			// Filter out possible comments
			if ( tag === "*" ) {
				while ( (elem = results[i++]) ) {
					if ( elem.nodeType === 1 ) {
						tmp.push( elem );
					}
				}

				return tmp;
			}
			return results;
		};

	// Class
	Expr.find["CLASS"] = support.getElementsByClassName && function( className, context ) {
		if ( typeof context.getElementsByClassName !== strundefined && documentIsHTML ) {
			return context.getElementsByClassName( className );
		}
	};

	/* QSA/matchesSelector
	---------------------------------------------------------------------- */

	// QSA and matchesSelector support

	// matchesSelector(:active) reports false when true (IE9/Opera 11.5)
	rbuggyMatches = [];

	// qSa(:focus) reports false when true (Chrome 21)
	// We allow this because of a bug in IE8/9 that throws an error
	// whenever `document.activeElement` is accessed on an iframe
	// So, we allow :focus to pass through QSA all the time to avoid the IE error
	// See http://bugs.jquery.com/ticket/13378
	rbuggyQSA = [];

	if ( (support.qsa = rnative.test( doc.querySelectorAll )) ) {
		// Build QSA regex
		// Regex strategy adopted from Diego Perini
		assert(function( div ) {
			// Select is set to empty string on purpose
			// This is to test IE's treatment of not explicitly
			// setting a boolean content attribute,


test]
    #[serial(libbpf_sys)] // mock contexts are shared
    fn test_bpf_query_other_error() {
        // arrange
        let query = mock_libbpf_sys::bpf_prog_query_context();
        let get_fd_by_id = mock_libbpf_sys::bpf_prog_get_fd_by_id_context();

        // expect
        query.expect().times(1).returning(
            |_target_fd: std::os::raw::c_int,
             _type_: libbpf_sys::bpf_attach_type,
             _query_flags: libbpf_sys::__u32,
             _attach_flags: *mut libbpf_sys::__u32,
             _prog_ids: *mut libbpf_sys::__u32,
             _prog_cnt: *mut libbpf_sys::__u32|
             -> ::std::os::raw::c_int {
                set_errno(Errno(ENOSYS));
                1
            },
        );
        get_fd_by_id.expect().never();

        // act
        let error = prog::query(0);

        // assert
        assert!(error.is_err());
    }

    #[test]
    #[serial(libbpf_sys)] // mock contexts are shared
    fn test_bpf_detach2() {
        // arrange
        let detach2 = mock_libbpf_sys::bpf_prog_detach2_context();

        // expect
        detach2.expect().once().returning(|_, _, _| 0);

        // act
        let r = prog::detach2(0, 0);

        // assert
        assert!(r.is_ok());
    }

    #[test]
    #[serial(libbpf_sys)] // mock contexts are shared
    fn test_bpf_detach2_error() {
        // arrange
        let detach2 = mock_libbpf_sys::bpf_prog_detach2_context();

        // expect
        detach2.expect().once().returning(|_, _, _| 1);

        // act
        let r = prog::detach2(0, 0);

        // assert
        assert!(r.is_err());
    }

    #[test]
    #[serial(libc)] // mock contexts are shared
    fn test_bump_memlock_rlimit() {
        // arrange
        let setrlimit = mock_libc::setrlimit_context();

        // expect
        setrlimit.expect().once().returning(|_, _| 0);

        // act
        let r = prog::bump_memlock_rlimit();

        // assert
        assert!(r.is_ok());
    }

    #[test]
    #[serial(libc)] // mock contexts are shared
    fn test_bump_memlock_rlimit_error() {
        // arrange
        let setrlimit = mock_libc::setrlimit_context();

        // expect
        setrlimit.expect().once().returning(|_, _| 1);

        // act
        let r = prog::bump_memlock_rlimit();

        // assert
        assert!(r.is_err());
    }
}
//! Functions for performing affine transformations.

use crate::buffer::{ImageBuffer, Pixel};
use crate::image::{GenericImage, GenericImageView};

/// Rotate an image 90 degrees clockwise.
pub fn rotate90<I: GenericImageView>(
    image: &I,
) -> ImageBuffer<I::Pixel, Vec<<I::Pixel as Pixel>::Subpixel>>
    where I::Pixel: 'static,
{
    let (width, height) = image.dimensions();
    let mut out = ImageBuffer::new(height, width);
    let _ = rotate90_in(image, &mut out);
    out
}

/// Rotate an image 180 degrees clockwise.
pub fn rotate180<I: GenericImageView>(
    image: &I,
) -> ImageBuffer<I::Pixel, Vec<<I::Pixel as Pixel>::Subpixel>>
    where I::Pixel


       use_vllm=use_vllm
    )

    # Load audio prompt
    logging.info(f"Loading audio prompt: {prompt_wav_path}")
    prompt_wav, _ = data_utils.load_wav(
        prompt_wav_path, target_sample_rate=constants.CODEC_SAMPLE_RATE)

    # Inference settings
    inference_settings = inferencing.InferenceSettings(
        temperature=0.8,
        max_tokens=1792,
        min_tokens=10,
        top_p=1.0,
        top_k=50,
        repetition_penalty=1.4,
        frequency_penalty=0.4,
        seed=42,
    )

    audio_prompt_transcription = prompt_transcription

    # Generate speech
    logging.info(f"Generating speech for text: '{text_to_synthesize}'")
    inference_result = tts_model.synthesize_speech(
        inference_settings=inference_settings,
        text_to_synthesize=text_to_synthesize,
        prompt_id="simple_inference",
        prompt_wav=prompt_wav,
        audio_prompt_transcription=audio_prompt_transcription,
        voice_description="",
        enable_instruction=True
    )

    # Save output audio
    output_wav = inference_result.wav

    # Create output directory if it doesn't exist
    os.makedirs(os.path.dirname(output_path), exist_ok=True)
    torchaudio.save(output_path, output_wav, audio_decoder.sample_rate)

    # Print results
    logging.info(f"Generated audio saved to: {output_path}")
    logging.info(f"Encoding time: {inference_result.encoding_time:.2f}s")
    logging.info(f"Decoding time: {inference_result.decoding_time:.2f}s")

if __name__ == "__main__":
    flags.mark_flags_as_required([
        "model_checkpoint_path",
        "audio_encoder_path",
        "audio_decoder_path",
        "prompt_wav_path",
        "prompt_transcription",
        "text"
    ])
    app.run(main)


,2 0 0,1 22,4V16A2,2 0 0,1 20,18H13.9L10.2,21.71C10,21.9 9.75,22 9.5,22V22H9M10,16V19.08L13.08,16H20V4H4V16H10M6,7H18V9H6V7M6,11H15V13H6V11Z",
        MaterialIconKind.Compare => "M19,3H14V5H19V18L14,12V21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3M10,18H5L10,12M10,3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H10V23H12V1H10V3Z",
        MaterialIconKind.CompareHorizontal => "M9 14H2V16H9V19L13 15L9 11V14M15 13V10H22V8H15V5L11 9L15 13Z",
        MaterialIconKind.CompareRemove => "M19 5H14V3H19C20.1 3 21 3.9 21 5V13.4C20.4 13.2 19.7 13 19 13V5M10 1H12V23H10V21H5C3.9 21 3 20.1 3 19V5C3 3.9 3.9 3 5 3H10V1M10 12L5 18H10V12M15.7 14L14 12V15.7C14.4 15 15 14.5 15.7 14M21.1 15.5L19 17.6L16.9 15.5L15.5 16.9L17.6 19L15.5 21.1L16.9 22.5L19 20.4L21.1 22.5L22.5 21.1L20.4 19L22.5 16.9L21.1 15.5Z",
        MaterialIconKind.CompareVertical => "M14 15V22H16V15H19L15 11L11 15H14M13 9H10V2H8V9H5L9 13L13 9Z",
        MaterialIconKind.Compass => "M14.19,14.19L6,18L9.81,9.81L18,6M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M12,10.9A1.1,1.1 0 0,0 10.9,12A1.1,1.1 0 0,0 12,13.1A1.1,1.1 0 0,0 13.1,12A1.1,1.1 0 0,0 12,10.9Z",
        MaterialIconKind.CompassOff => "M1,3.5L2.28,2.25L21.75,21.72L20.5,23L17.7,20.22C16.08,21.34 14.12,22 12,22A10,10 0 0,1 2,12C2,9.88 2.66,7.92 3.78,6.3L1,3.5M6,18L12.47,15L9,11.53L6,18M18,6L11.56,9L6.33,3.76C7.94,2.65 9.9,2 12,2A10,10 0 0,1 22,12C22,14.1 21.35,16.06 20.24,17.67L15,12.44L18,6Z",
        MaterialIconKind.CompassOffOutline => "M1,3.5L2.28,2.25L21.75,21.72L20.5,23L17.7,20.22C16.08,21.34 14.12,22 12,22A10,10 0 0,1 2,12C


Other = {
            bunc_temporary_extra_chips = {['text'] = {[1] = '{C:chips}+#1#{} chip thêm tại ván này'}},
            bunc_linked_cards = {['text'] = {[1] = '{C:attention}Đã kết nối{} trong nhóm này:'}},
            bunc_linked_group = {
                ['name'] = 'Ghép nhóm',
                ['text'] = {
                    [1] = 'Các lá đã kết nối cùng nhóm',
                    [2] = 'được rút, được chọn',
                    [3] = 'và bị phá huỷ {C:attention}cùng nhau'
                }
            },
            bunc_drawn_linked_cards = {['text'] = {[1] = '{C:attention}Đã kết nối{} trong nhóm chờ'}},
            bunc_light_suits = {
                ['name'] = 'Chất Sáng',
                ['text'] = {
                    [1] = '{C:hearts}Cơ{} và {C:diamonds}Rô'
                }
            },
            bunc_light_suits_exotic = {
                ['name'] = 'Chất Sáng',
                ['text'] = {
                    [1] = '{C:hearts}Cơ{}, {C:diamonds}Rô,',
                    [2] = 'và {C:bunc_fleurons}Hoa'
                }
            },
            bunc_dark_suits = {
                ['name'] = 'Chất Tối',
                ['text'] = {
                    [1] = '{C:spades}Bích{} và {C:clubs}Tép'
                }
            },
            bunc_dark_suits_exotic = {
                ['name'] = 'Dark suits',
                ['text'] = {
                    [1] = '{C:spades}Bích{}, {C:clubs}Tép,',
                    [2] = 'và {C:bunc_halberds}Rìu'
                }
            },
            bunc_exotic_cards = {
                ['name'] = 'Lá Ngoại Lai',
                ['text'] = {
                    [1] = 'Lá với chất',
                    [2] = '{C:bunc_fleurons}Hoa{} hoặc {C:bunc_halberds}Rìu{}'
                }
            },
            bunc_consumable_edition_foil = {
                ['name'] = 'Tráng Bạc',
                ['text'] = {
                    [1] = 'Tạo một {C:attention}Nhãn Chip'
                }
            },
            bunc_consumable_edition_holo = {
                ['name'] = 'Lấp Lánh',
                ['text'] = {
                    [1] = 'Tạo một {C:attention}Nhãn +Nhân'
                }
            },
            bunc_consumable_edition_polychrome = {
                ['name'] = 'Đa Sắc',
                ['text'] = {
                    [1] = 'Tạo một {C:attention}Nhãn XNhân'
                }
            },
            bunc_consumable_edition_bunc_glitter = {
                ['name'] = 'Long Lanh',
                ['text'] = {
                    [1] = 'Tạo một {C:attention}Nhãn XChip'
                }
            },

            -- Undiscovered

            undiscovered_polymino = {
                ['name'] = 'Chưa Khám Phá',
                ['text'] = {
                    [1] = 'Mua hoặc dùng',


tionPointZ = -2F;
			this.beak.rotationPointZ = -2F;
			this.ass.rotationPointZ = 4F;
			this.feathers.rotationPointZ = 7.5F;
			this.leftWing.rotationPointX = 3F;
			this.rightWing.rotationPointX = -3F;
		}
	}

	@Override
	public void render(Entity entity, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch, float scaleFactor) {

		this.setRotationAngles(limbSwing, limbSwingAmount, ageInTicks, netHeadYaw, headPitch, scaleFactor, entity);
		this.head.render(scaleFactor);
		this.beak.render(scaleFactor);
		if(((EntityPigeon) entity).isFat()) {
			this.bodyFat.render(scaleFactor);
		} else {
			this.body.render(scaleFactor);
		}
		this.rightLeg.render(scaleFactor);
		this.leftLeg.render(scaleFactor);
		this.ass.render(scaleFactor);
		this.feathers.render(scaleFactor);
	}
}
package com.hbm.render.model;

import org.lwjgl.opengl.GL11;

import com.hbm.main.ResourceManager;

import net.minecraft.block.Block;
import net.minecraft.client.Minecraft;
import net.minecraft.client.model.ModelBase;
import net.minecraft.client.renderer.RenderBlocks;
import net.minecraft.client.renderer.texture.TextureMap;
import net.minecraft.entity.Entity;
import net.minecraft.util.MathHelper;

public class ModelBlockSpider extends ModelBase {

	@Override
	public void render(Entity entity, float limbSwing, float limbSwingAmount, float ageInTicks, float netHeadYaw, float headPitch, float scaleFactor) {

		int blockId = entity.getDataWatcher().getWatchableObjectInt(12);
		Block block = Block.getBlockById(blockId);

		if(block == null) {
			return;
		}

		float rot = -(MathHelper.cos(limbSwing * 0.6662F * 2.0F + 0.0F) * 0.4F) * limbSwingAmount * 57.3F;
		int meta = entity.getDataWatcher().getWatchableObjectInt(13);

		GL11.glPushMatrix();

		GL11.glRotatef(90, 0, -1, 0);
		GL11.glRotatef(180, 0, 0, 1);
		GL11.glTranslatef(0, -1.5F, 0);

		GL11.glPushMatrix();
		GL11.glTranslated(0, rot * 0.005, 0);
		GL11.glRotatef(rot, 0, 1, 0);
		ResourceManager.spider.renderPart("Leg1");
		ResourceManager.spider.renderPart("Leg3");
		ResourceManager.spider.renderPart("Leg5");
		ResourceManager.spider.renderPart("Leg7");
		GL11.glPopMatrix();

		GL11.glPushMatrix();
		GL11.glTranslated(0, rot * -0.005, 0);
		GL11.glRotatef(rot, 0, -1, 0);
		ResourceManager.spider.renderPart("Leg2");
		ResourceManager.spider.renderPart("Leg4");
		ResourceManager.spider.renderPart("Leg6");
		ResourceManager.spider.renderPart("Leg8");
		GL11.glPopMatrix();

		GL11.glPushMatrix();
		Minecraft.getMinecraft().renderEngine.bindTexture(


from pysisyphus.line_searches.LineSearch import (
    LineSearch,
    LineSearchNotConverged,
)

from pysisyphus.line_searches.interpol import interpol_alpha_quad, interpol_alpha_cubic
from pysisyphus.optimizers.poly_fit import cubic_fit, quartic_fit

class Backtracking(LineSearch):
    def __init__(self, *args, rho_lo=5e-2, rho_hi=0.9, use_grad=False, **kwargs):
        """Backtracking line search enforcing Armijo conditions.

        Uses only energy evaluations.

        See [1], Chapter 3, Line Search methods, Section 3.1 p. 31 and
        Section 3.5 p. 56."""

        kwargs["cond"] = "armijo"
        super().__init__(*args, **kwargs)

        self.rho_lo = float(rho_lo)
        self.rho_hi = float(rho_hi)
        self.use_grad = use_grad

    def alpha_new_from_phi(self, cycle, phi0, dphi0, alpha, alpha_prev):
        phi_i = self.get_phi_dphi("f", alpha)
        self.log(f"\tCycle {cycle:02d}: alpha={alpha:.6f}, ϕ={phi_i:.6f} au")

        if cycle == 0:
            # Quadratic interpolation
            alpha_new = interpol_alpha_quad(phi0, dphi0, phi_i, alpha)
            type_ = "quadratic"
        else:
            # Cubic interpolation
            phi_prev = self.get_phi_dphi("f", alpha_prev)
            alpha_new = interpol_alpha_cubic(
                phi0, dphi0, phi_prev, phi_i, alpha_prev, alpha
            )
            type_ = "cubic"
        return alpha_new, type_

    def alpha_new_from_phi_dphi(self, cycle, phi0, dphi0, alpha):
        phi_i, dphi_i = self.get_phi_dphi("fg", alpha)
        self.log(f"\tCycle {cycle:02d}: α={alpha:.6f}, ϕ={phi_i:.6f} au")

        # First we try a constrained quartic polynomial
        res = quartic_fit(phi0, phi_i, dphi0, dphi_i)
        type_ = "quartic"
        # If the quartic poly failed, we continue with a cubic polynomial
        if res is None:
            res = cubic_fit(phi0, phi_i, dphi0, dphi_i)
            type_ = "cubic"
        # If the cubic poly failed we resort to bisection. ohoh
        if res is None:
            alpha_new = 0.5 * alpha
            type_ = "bisection"
        else:
            alpha_new = res.x * alpha
        return alpha_new, type_

    def run_line_search(self):
        phi0, dphi0 = self.get_phi_dphi("fg", 0)

        alpha_prev = None
        alpha = self.alpha_init
        for i in range(self.max_cycles):
            if self.use_grad:
                alpha_new, type_ = self.alpha_new_from_phi_dphi(i, phi0, dphi0, alpha)
            else:
                alpha_new, type_ = self.alpha_new_from_phi(i, phi0, dphi0, alpha, alpha_prev)
            self.log(f"\tNew α from {type_} interpolation: {alpha_new:.6f}")

            lower_bound = alpha * self.rho_lo
            upper_bound = alpha * self.rho_hi
            if alpha_new < lower_bound:
                self.log("\tNew α is too small!")
            if alpha_new > upper_bound:
                self.log("\tNew α is too big!")

            # Assert that alpha doesn't change too much compared to the previous alpha
            alpha_new = min(alpha_new, upper_bound)
            alpha_new = max(alpha_new, lower_bound)
            alpha_prev = alpha
            alpha = alpha_new
            self.log(f"\tNext α: {alpha:.6f}\n")

        raise LineSearchNotConverged


�, 수정 또는 거부할 권리와 책임이 있으며, 적절한 경우 중재적 의사결정에 대한 이유를 전달할 것이다.

## 범위

이 행동 강령은 개인이 공개 영역에서 커뮤니티를 공식적으로 대표할 때를 포함하여 모든 커뮤니티 영역에 적용된다. 커뮤니티 대표의 예로 공식 이메일 주소 사용, 공식 소셜 미디어 계정을 통한 게시, 온/오프라인 이벤트에서 임명된 대표자의 활동이 있다.

## 집행

모욕적이거나 괴롭힘 또는 그 외 하지말아야 할 행동을 발견하면 [연락 방법 입력]을 통해 집행 책임이 있는 커뮤니티 리더에게 보고한다. 모든 불만사항은 신속하고 공정하게 검토되고 조사될 것이다.

커뮤니티 리더는 사건의 보고자의 사생활과 안전을 존중할 의무가 있다.

## 집행 지침

커뮤니티 리더는 행동 강령 위반으로 간주되는 행동에 대한 결과를 결정할 때, 다음의 커뮤니티 영향 지침을 준수한다:

### 1. 정정

**커뮤니티 영향**: 커뮤니티 내 부적절한 언어 사용이나 비전문적인 행동 또는 불쾌함을 주는 행동.

**결과**: 커뮤니티 리더가 별도로 위반에 대한 명확성과 부적절함에 대한 이유를 설명하고 서면 경고. 공개 사과를 요청할 수 있다.

### 2. 경고

**커뮤니티 영향**: 단일 사고 또는 연속된 행동 위반.

**결과**: 지속적인 행동에 대한 결과에 대해 경고. 특정 기간동안 행동 강령을 시행하는 사람들과의 원치 않는 상호작용을 포함한 관련된 사람들과


apons != null)
		{
			CharID id = dfce.getCharID();
			for (Equipment e : weapons)
			{
				remove(id, e, cdo);
			}
		}
	}
}
/*
 * Copyright (c) Thomas Parker, 2013.
 *
 * This program is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This program is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this library; if not, write to the Free Software Foundation, Inc.,
 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
 */
package pcgen.cdom.facet;

import java.util.ArrayList;
import java.util.Collection;
import java.util.List;

import pcgen.cdom.enumeration.CharID;
import pcgen.cdom.facet.base.AbstractSourcedListFacet;
import pcgen.cdom.facet.model.LanguageFacet;
import pcgen.cdom.meta.CorePerspective;
import pcgen.cdom.meta.CorePerspectiveDB;
import pcgen.cdom.meta.FacetBehavior;
import pcgen.cdom.meta.PerspectiveLocation;
import pcgen.core.Language;

/**
 * AutoLanguageFacet is a Facet that tracks the Languages that have been granted
 * to a Player Character through the AUTO:LANG and LANGAUTO tokens
 *
 */
public class AutoLanguageGrantedFacet extends AbstractSourcedListFacet<CharID, Language> implements PerspectiveLocation
{

	private AutoLanguageFacet autoLanguageFacet;

	private LanguageFacet languageFacet;

	public boolean update(CharID id)
	{
		Collection<Language> current = getSet(id);
		Collection<Language> qualified = autoLanguageFacet.getAutoLanguage(id);
		List<Language> toRemove = new ArrayList<>(current);
		toRemove.removeAll(qualified);
		List<Language> toAdd = new ArrayList<>(qualified);
		toAdd.removeAll(current);
		for (Language lang : toRemove)
		{
			remove(id, lang, autoLanguageFacet);
		}
		for (Language lang : toAdd)
		{
			add(id, lang, autoLanguageFacet);
		}
		return !toRemove.isEmpty() || !toAdd.isEmpty();
	}

	public void setAutoLanguageFacet(AutoLanguageFacet autoLanguageFacet)
	{
		this.autoLanguageFacet = autoLanguageFacet;
	}

	public void setLanguageFacet(LanguageFacet languageFacet)
	{
		this.languageFacet = languageFacet;
	}

	public void init()
	{
		addDataFacetChangeListener(languageFacet);
		CorePerspectiveDB.register(CorePerspective.LANGUAGE, FacetBehavior.CONDITIONAL_GRANTED, this);
		CorePerspectiveDB.registerVirtualParent(this, autoLanguageFacet);
	}

	@Override
	public String getIdentity()
	{
		return "AUTO:LANG|<ref> (passed defined prerequisites)";
	}
}
/*
 * Copyright (c) Thomas Parker, 2009.
 *
 * This program is free software; you can redistribute it and/or modify it under
 * the terms of the GNU Lesser General Public License as published by the Free
 * Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This program is distributed in the hope that it will be useful, but WITHOUT
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this library; if not, write to the Free Software Foundation, Inc.,
 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
 */
package pcgen.cdom.facet;

import pcgen.cdom.enumeration.CharID;
import pcgen.cd


// ObjectValuePad.cs
//
// Author:
//   Lluis Sanchez Gual <lluis@novell.com>
//
// Copyright (c) 2008 Novell, Inc (http://www.novell.com)
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
//
//

using System;

using Gtk;

using Mono.Debugging.Client;

using MonoDevelop.Core;
using MonoDevelop.Ide.Gui;
using MonoDevelop.Components;
using Foundation;

namespace MonoDevelop.Debugger
{
	public class ObjectValuePad : PadContent
	{
		protected readonly bool UseNewTreeView = PropertyService.Get ("MonoDevelop.Debugger.UseNewTreeView", true);

		protected ObjectValueTreeViewController controller;
		protected ObjectValueTreeView tree;
		// this is for the new treeview
		protected MacObjectValueTreeView _treeview;

		readonly Control control;
		PadFontChanger fontChanger;
		StackFrame lastFrame;
		bool needsUpdateValues;
		bool needsUpdateFrame;
		bool disposed;

		public override Control Control {
			get { return control; }
		}

		protected bool IsInitialResume {
			get; private set;
		}

		public ObjectValuePad (bool allowWatchExpressions = false)
		{
			if (UseNewTreeView) {
				controller = new ObjectValueTreeViewController (allowWatchExpressions);
				controller.AllowEditing = true;

				if (Platform.IsMac) {
					LoggingService.LogInfo ("Using MacObjectValueTreeView for {0}", allowWatchExpressions ? "Watch Pad" : "Locals Pad");
					var treeView = controller.GetMacControl (ObjectValueTreeViewFlags.ObjectValuePadFlags);
					treeView.UIElementName = allowWatchExpressions ? "WatchPad" : "LocalsPad";
					_treeview = treeView;

					fontChanger = new PadFontChanger (treeView, treeView.SetCustomFont, treeView.QueueResize);

					var scrolled = new AppKit.NSScrollView {
						DocumentView = treeView,
						AutohidesScrollers = false,
						HasVerticalScroller = true,
						HasHorizontalScroller = true,
					};

					// disable implicit animations
					scrolled.WantsLayer = true;
					scrolled.Layer.Actions = new NSDictionary (
						"actions", NSNull.Null,
						"contents", NSNull.Null,
						"hidden", NSNull.Null,
						"onLayout", NSNull.Null,
						"onOrderIn", NSNull.Null,
						"onOrderOut", NSNull.Null,
						"position", NSNull.Null,
						"sublayers", NSNull.Null,
						"transform", NSNull.Null,
						"bounds", NSNull.Null);

					var host = new GtkNSViewHost (scrolled);
					host.ShowAll ();

					control = host;
				} else {
					LoggingService.LogInfo ("Using GtkObjectValueTreeView for {0}", allowWatchExpressions ? "Watch Pad" : "Locals Pad");
					var treeView = controller.GetGtkControl (Obj


/*-------------------------------------------------------------------------
 *
 * pglogical_proto.h
 *		pglogical protocol
 *
 * Copyright (c) 2015, PostgreSQL Global Development Group
 *
 * IDENTIFICATION
 *		  pglogical_proto.h
 *
 *-------------------------------------------------------------------------
 */
#ifndef PG_LOGICAL_PROTO_H
#define PG_LOGICAL_PROTO_H

typedef void (*pglogical_write_rel_fn)(StringInfo out, PGLogicalOutputData *data, Relation rel);

typedef void (*pglogical_write_begin_fn)(StringInfo out, PGLogicalOutputData *data,
							 ReorderBufferTXN *txn);
typedef void (*pglogical_write_commit_fn)(StringInfo out, PGLogicalOutputData *data,
							 ReorderBufferTXN *txn, XLogRecPtr commit_lsn);

typedef void (*pglogical_write_origin_fn)(StringInfo out, const char *origin,
							 XLogRecPtr origin_lsn);

typedef void (*pglogical_write_insert_fn)(StringInfo out, PGLogicalOutputData *data,
							 Relation rel, HeapTuple newtuple);
typedef void (*pglogical_write_update_fn)(StringInfo out, PGLogicalOutputData *data,
							 Relation rel, HeapTuple oldtuple,
							 HeapTuple newtuple);
typedef void (*pglogical_write_delete_fn)(StringInfo out, PGLogicalOutputData *data,
							 Relation rel, HeapTuple oldtuple);

typedef void (*write_startup_message_fn)(StringInfo out, List *msg);

typedef struct PGLogicalProtoAPI
{
	pglogical_write_rel_fn		write_rel;
	pglogical_write_begin_fn	write_begin;
	pglogical_write_commit_fn	write_commit;
	pglogical_write_origin_fn	write_origin;
	pglogical_write_insert_fn	write_insert;
	pglogical_write_update_fn	write_update;
	pglogical_write_delete_fn	write_delete;
	write_startup_message_fn	write_startup_message;
} PGLogicalProtoAPI;

typedef enum PGLogicalProtoType
{
	PGLogicalProtoNative,
	PGLogicalProtoJson
} PGLogicalProtoType;

extern PGLogicalProtoAPI *pglogical_init_api(PGLogicalProtoType typ);

#endif /* PG_LOGICAL_PROTO_H */