repo_name
stringlengths
6
101
path
stringlengths
4
300
text
stringlengths
7
1.31M
OttoWinter/esphomeyaml
esphome/components/ota/ota_backend_arduino_esp32.cpp
<gh_stars>100-1000 #include "esphome/core/defines.h" #ifdef USE_ESP32_FRAMEWORK_ARDUINO #include "ota_backend_arduino_esp32.h" #include "ota_component.h" #include "ota_backend.h" #include <Update.h> namespace esphome { namespace ota { OTAResponseTypes ArduinoESP32OTABackend::begin(size_t image_size) { bool ret = Update.begin(image_size, U_FLASH); if (ret) { return OTA_RESPONSE_OK; } uint8_t error = Update.getError(); if (error == UPDATE_ERROR_SIZE) return OTA_RESPONSE_ERROR_ESP32_NOT_ENOUGH_SPACE; return OTA_RESPONSE_ERROR_UNKNOWN; } void ArduinoESP32OTABackend::set_update_md5(const char *md5) { Update.setMD5(md5); } OTAResponseTypes ArduinoESP32OTABackend::write(uint8_t *data, size_t len) { size_t written = Update.write(data, len); if (written != len) { return OTA_RESPONSE_ERROR_WRITING_FLASH; } return OTA_RESPONSE_OK; } OTAResponseTypes ArduinoESP32OTABackend::end() { if (!Update.end()) return OTA_RESPONSE_ERROR_UPDATE_END; return OTA_RESPONSE_OK; } void ArduinoESP32OTABackend::abort() { Update.abort(); } } // namespace ota } // namespace esphome #endif // USE_ESP32_FRAMEWORK_ARDUINO
lisongwang/java-core
src/main/java/com/lisong/learn/core/reusing/Exercise14.java
package com.lisong.learn.core.reusing; import static com.lisong.learn.core.util.Print.print; /** * Show the composition and inheritance */ public class Exercise14 { public static void main(String[] args) { Car car = new Car(); car.engine.start(); car.engine.service(); car.left.window.rollup(); car.right.window.rolldown(); } } class Engine { public void start() { print("Engine start"); } public void stop() { print("Engine stop"); } public void rev() { print("Engine rev"); } public void service() { print("Engine service"); } } class Wheel { public void inflate(int psi) { print("Wheel inflate at " + psi); } } class Window { public void rollup() { print("Window rollup"); } public void rolldown() { print("Window rolldown"); } } class Door { public Window window = new Window(); public void open() { print("Door open"); } public void close() { print("Door close"); } } class Car { public Engine engine = new Engine(); public Wheel[] wheels = new Wheel[4]; public Door left = new Door(), right = new Door(); public Car() { for (int i = 0; i < wheels.length; i++) { wheels[i] = new Wheel(); } } }
das-praktische-schreinerlein/mycms-commons
dist/search-commons/model/forms/generic-searchform.js
<gh_stars>0 "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var generic_validator_util_1 = require("./generic-validator.util"); var GenericSearchFormFieldConfig = /** @class */ (function () { function GenericSearchFormFieldConfig(datatype, validator) { this._datatype = datatype; this._validator = validator; } Object.defineProperty(GenericSearchFormFieldConfig.prototype, "datatype", { get: function () { return this._datatype; }, enumerable: true, configurable: true }); Object.defineProperty(GenericSearchFormFieldConfig.prototype, "validator", { get: function () { return this._validator; }, enumerable: true, configurable: true }); return GenericSearchFormFieldConfig; }()); exports.GenericSearchFormFieldConfig = GenericSearchFormFieldConfig; var GenericSearchForm = /** @class */ (function () { function GenericSearchForm(values) { this.fulltext = values['fulltext'] || ''; this.sort = values['sort'] || ''; this.perPage = values['perPage'] || 10; this.pageNum = values['pageNum'] || 1; } GenericSearchForm.prototype.toString = function () { return 'GenericSearchForm {\n' + ' fulltext: ' + this.fulltext + '\n' + ' sort: ' + this.sort + '\n' + ' perPage: ' + this.perPage + '\n' + ' pageNum: ' + this.pageNum + '' + '}'; }; GenericSearchForm.genericFields = { fulltext: new GenericSearchFormFieldConfig(generic_validator_util_1.GenericValidatorDatatypes.FULLTEXT, new generic_validator_util_1.SolrValidationRule(false)), sort: new GenericSearchFormFieldConfig(generic_validator_util_1.GenericValidatorDatatypes.SORT, new generic_validator_util_1.IdValidationRule(false)), perPage: new GenericSearchFormFieldConfig(generic_validator_util_1.GenericValidatorDatatypes.PERPAGE, new generic_validator_util_1.NumberValidationRule(false, 0, 100, 10)), pageNum: new GenericSearchFormFieldConfig(generic_validator_util_1.GenericValidatorDatatypes.PAGENUM, new generic_validator_util_1.NumberValidationRule(false, 1, 999999, 1)) }; return GenericSearchForm; }()); exports.GenericSearchForm = GenericSearchForm; //# sourceMappingURL=generic-searchform.js.map
jukanntenn/Cpp-Primer-Plus-6th-exercises
Chapter14/Exercise4/personmi.h
#ifndef PERSONMI_H_ #define PERSONMI_H_ #include <string> using std::string; class Person { private: string first_name; string last_name; protected: virtual void Data() const; virtual void Get(); public: Person(char *fn = "unset", char *ln = "unset") : first_name(fn), last_name(ln) {} virtual ~Person() = 0; virtual void Set() = 0; virtual void Show() const = 0; }; class Gunslinger : virtual public Person { private: double draw_time; int notches; protected: void Data() const; void Get(); public: Gunslinger(char *fn = "unset", char *ln = "unset", double d = 0.0, int n = 0) : Person(fn, ln), draw_time(d), notches(n) {} void Set(); double Draw() const { return draw_time; }; void Show() const; }; class PokerPlayer : virtual public Person { protected: class Card { public: enum FACE { SPADES, CLUBES, HEARTS, DIAMONDS }; private: FACE face; char suit; public: Card(FACE f, char s) : face(f), suit(s) {} void Show() const; }; public: PokerPlayer(char *fn = "unset", char *ln = "unset") : Person(fn, ln) {} void Show() const { Person::Data(); } void Set() { Person::Get(); } Card Draw() const; }; class BadDude : public Gunslinger, public PokerPlayer { public: BadDude(){}; double Gdraw() { return Gunslinger::Draw(); } Card Cdraw() const { return PokerPlayer::Draw(); } void Set(); void Show() const; }; #endif
davidmallasen/Napol
Analizador/asint/ast/Programa.java
package asint.ast; import asint.ast.ambitos.TablaSimbolos; import asint.ast.sentencias.Sentencia; import asint.ast.sentencias.TipoS; import java.util.ArrayList; import java.util.LinkedList; /** * Representa un programa Napol. Estara compuesto por una lista de sentencias. * Estas seran las unidades independientes que aparezcan en un archivo Napol. * P.ej:Declaracion de varibles globales, procedimientos, funciones... */ public class Programa { /** * Lista de sentencias del programa. */ private LinkedList<Sentencia> sentencias; public Programa(LinkedList<Sentencia> sentencias, Sentencia proc) { this.sentencias = sentencias; this.sentencias.add(proc); } /** * Metodo encargado de la fase de identificacion de identificadores. */ public void checkAmbitos() { TablaSimbolos ts = new TablaSimbolos(); ts.abreBloque(); for (Sentencia s : sentencias) { s.checkAmbitos(ts); } ts.cierraBloque(); } /** * Metodo encargado de la comprobacion estatica de tipos. */ public void checkTipos() { for (Sentencia s : sentencias) { s.checkTipos(); } } /** * Calcula la rho usada en la generacion de codigo y los niveles de uso y * declaracion. */ public void precalculo() { int x = 0; for (Sentencia s : sentencias) { x = s.precalculo(x, 0); //El nivel 0 es el "global" } } /** * Longitud pila evaluacion expresiones en el programa global. * * @return Longitud de la pila de evaluacion de expresiones. */ private int longitudPilaEvaluacionExpresiones() { int max = 0; for (Sentencia s : sentencias) { if (!(s.tipo() == TipoS.FUND || s.tipo() == TipoS.PROCD)) { max = Math.max(max, s.longitudPilaEvaluacionExpresiones()); } } return max; } /** * @return Numero de variables globales (declaradas fuera de cualquier * procedimiento o funcion). */ private int declarVarLocales() { int numVarLocales = 0; for (Sentencia s : sentencias) { if (!(s.tipo() == TipoS.FUND || s.tipo() == TipoS.PROCD)) { numVarLocales += s.declarVarLocales(); } } return numVarLocales; } /** * Genera el codigo del programa y lo devuelve. * * @return Codigo del programa */ public ArrayList<String> generaCodigo() { ArrayList<String> codigo = new ArrayList<>(); codigo.add("ssp " + Math.max(1, declarVarLocales()) + ";\n"); codigo.add("sep " + longitudPilaEvaluacionExpresiones() + ";\n"); for (Sentencia s : sentencias) { s.generaCodigo(codigo); } codigo.add("stp;\n"); return codigo; } @Override public String toString() { StringBuilder sb = new StringBuilder(); for (Sentencia s : sentencias) { sb.append(s.toString()); sb.append('\n'); } return sb.toString(); } }
helloShen/leetcode
java/src/main/java/com/ciaoshen/leetcode/reorder_log_files/Solution5.java
<reponame>helloShen/leetcode /** * Leetcode - reorder_log_files */ package com.ciaoshen.leetcode.reorder_log_files; import java.util.*; import com.ciaoshen.leetcode.util.*; /** * log instance is defined in Solution interface * this is how slf4j will work in this class: * ============================================= * if (log.isDebugEnabled()) { * log.debug("a + b = {}", sum); * } * ============================================= */ class Solution5 implements Solution { public String[] reorderLogFiles(String[] logs) { List<String> letterLogs = new LinkedList<String>(); List<String> digitLogs = new LinkedList<String>(); for (String log : logs) { if (Character.isDigit(log.charAt(log.indexOf(' ') + 1))) { digitLogs.add(log); } else { letterLogs.add(log); } } // lambda表达式严重影响效率 // Collections.sort(letterLogs, (String a, String b) -> (a.substring(a.indexOf(' ') + 1)).compareTo(b.substring(b.indexOf(' ') + 1))); Collections.sort(letterLogs, new Comparator<String>(){ @Override public int compare(String a, String b) { return (a.substring(a.indexOf(' ') + 1)).compareTo(b.substring(b.indexOf(' ') + 1)); } }); letterLogs.addAll(digitLogs); String[] res = new String[logs.length]; return letterLogs.toArray(res); } }
sandfox/planner
app/helpers/courses_helper.rb
<gh_stars>0 module CoursesHelper def twitter_url_for(username) "http://twitter.com/#{username}" end end
zzhmark/vaa3d_tools
hackathon/mBrainAligner/src/src_othertools/swc_registration/stps_inv_warp_swc/src/q_medianfilter.cpp
// q_medianfilter.cpp #ifndef __Q_MEDIANFILTER_CPP__ #define __Q_MEDIANFILTER_CPP__ #include <math.h> #include "../../v3d_main/basic_c_fun/basic_memory.cpp" #include "../../v3d_main/basic_c_fun/v3d_basicdatatype.h" template <class T> void median_filter(T* data1d, long long *in_sz, unsigned int Wx, unsigned int Wy, unsigned int Wz, unsigned int c, T* &outimg) { long long N = in_sz[0]; long long M = in_sz[1]; long long P = in_sz[2]; long long sc = in_sz[3]; long long pagesz = N*M*P; T *arr, tmp; int ii, jj; int size = (2 * Wx + 1)*(2 * Wy + 1)*(2 * Wz + 1); arr = new T[size]; //filtering long long offsetc = (c - 1)*pagesz; //declare temporary pointer T *pImage = new T[pagesz](); if (!pImage) { printf("Fail to allocate memory.\n"); return; } //Median Filtering for (long long iz = 0; iz < P; iz++) { printf("\r median filter : %d %% completed ", ((iz + 1) * 100) / P); fflush(stdout); long long offsetk = iz*M*N; for (long long iy = 0; iy < M; iy++) { long long offsetj = iy*N; for (long long ix = 0; ix < N; ix++) { long long xb = ix - Wx; if (xb < 0) xb = 0; long long xe = ix + Wx; if (xe >= N - 1) xe = N - 1; long long yb = iy - Wy; if (yb < 0) yb = 0; long long ye = iy + Wy; if (ye >= M - 1) ye = M - 1; long long zb = iz - Wz; if (zb < 0) zb = 0; long long ze = iz + Wz; if (ze >= P - 1) ze = P - 1; ii = 0; for (long long k = zb; k <= ze; k++) { long long offsetkl = k*M*N; for (long long j = yb; j <= ye; j++) { long long offsetjl = j*N; for (long long i = xb; i <= xe; i++) { T dataval = data1d[offsetc + offsetkl + offsetjl + i]; arr[ii] = dataval; if (ii > 0) { jj = ii; while (jj > 0 && arr[jj - 1] > arr[jj]) { tmp = arr[jj]; arr[jj] = arr[jj - 1]; arr[jj - 1] = tmp; jj--; } } ii++; } } } //set value long long index_pim = offsetk + offsetj + ix; pImage[index_pim] = arr[int(0.5*ii) + 1]; } } } printf("\n"); outimg = pImage; delete[] arr; } #endif
BenZhao-forever/Ben-leetcode-practice
src/main/java/ListNode.java
class ListNode { int val; ListNode next; ListNode() {} ListNode(int val) { this.val = val; } ListNode(int val, ListNode next) { this.val = val; this.next = next;} public static ListNode create(int[] list) { ListNode head = new ListNode(); ListNode temphead = head; for (int j : list) { temphead.next = new ListNode(j); temphead = temphead.next; } return head.next; } public static void print(ListNode head) { while (head != null) { System.out.print(head.val + "->"); head = head.next; } } public static String toString(ListNode head) { StringBuilder stringBuilder = new StringBuilder(); if (head == null) { return stringBuilder.toString(); } while (head.next != null) { stringBuilder.append(head.val); stringBuilder.append("->"); head = head.next; } stringBuilder.append(head.val); return stringBuilder.toString(); } @Override public String toString() { ListNode temp = this; StringBuilder stringBuilder = new StringBuilder(); while (temp.next != null) { stringBuilder.append(temp.val); stringBuilder.append("->"); temp = temp.next; } stringBuilder.append(temp.val); return stringBuilder.toString(); } }
rrjha/dosp
xinu/device/nam/nammap.c
<filename>xinu/device/nam/nammap.c /* nammap.c - nammap, namrepl, namcpy */ #include <xinu.h> status namcpy(char *, char *, int32); did32 namrepl(char *, char[]); /*------------------------------------------------------------------------ * nammap - Using namespace, map name to new name and new device *------------------------------------------------------------------------ */ devcall nammap( char *name, /* The name to map */ char newname[NM_MAXLEN], /* Buffer for mapped name */ did32 namdev /* ID of the namespace device */ ) { did32 newdev; /* Device descriptor to return */ char tmpname[NM_MAXLEN]; /* Temporary buffer for name */ int32 iter; /* Number of iterations */ /* Place original name in temporary buffer and null terminate */ if (namcpy(tmpname, name, NM_MAXLEN) == SYSERR) { return SYSERR; } /* Repeatedly substitute the name prefix until a non-namespace */ /* device is reached or an iteration limit is exceeded */ for (iter=0; iter<nnames ; iter++) { newdev = namrepl(tmpname, newname); if (newdev != namdev) { namcpy(tmpname, newname, NM_MAXLEN); return newdev; /* Either valid ID or SYSERR */ } } return SYSERR; } /*------------------------------------------------------------------------ * namrepl - Use the name table to perform prefix substitution *------------------------------------------------------------------------ */ did32 namrepl( char *name, /* Original name */ char newname[NM_MAXLEN] /* Buffer for mapped name */ ) { int32 i; /* Iterate through name table */ char *pptr; /* Walks through a prefix */ char *rptr; /* Walks through a replacement */ char *optr; /* Walks through original name */ char *nptr; /* Walks through new name */ char olen; /* Length of original name */ /* including the NULL byte */ int32 plen; /* Length of a prefix string */ /* *not* including NULL byte */ int32 rlen; /* Length of replacment string */ int32 remain; /* Bytes in name beyond prefix */ struct nmentry *namptr; /* Pointer to a table entry */ /* Search name table for first prefix that matches */ for (i=0; i<nnames; i++) { namptr = &nametab[i]; optr = name; /* Start at beginning of name */ pptr = namptr->nprefix; /* Start at beginning of prefix */ /* Compare prefix to string and count prefix size */ for (plen=0; *pptr != NULLCH ; plen++) { if (*pptr != *optr) { break; } pptr++; optr++; } if (*pptr != NULLCH) { /* Prefix does not match */ continue; } /* Found a match - check that replacement string plus */ /* bytes remaining at the end of the original name will */ /* fit into new name buffer. Ignore null on replacement*/ /* string, but keep null on remainder of name. */ olen = namlen(name ,NM_MAXLEN); rlen = namlen(namptr->nreplace,NM_MAXLEN) - 1; remain = olen - plen; if ( (rlen + remain) > NM_MAXLEN) { return (did32)SYSERR; } /* Place replacement string followed by remainder of */ /* original name (and null) into the new name buffer */ nptr = newname; rptr = namptr->nreplace; for (; rlen>0 ; rlen--) { *nptr++ = *rptr++; } for (; remain>0 ; remain--) { *nptr++ = *optr++; } return namptr->ndevice; } return (did32)SYSERR; } /*------------------------------------------------------------------------ * namcpy - Copy a name from one buffer to another, checking length *------------------------------------------------------------------------ */ status namcpy( char *newname, /* Buffer to hold copy */ char *oldname, /* Buffer containing name */ int32 buflen /* Size of buffer for copy */ ) { char *nptr; /* Point to new name */ char *optr; /* Point to old name */ int32 cnt; /* Count of characters copied */ nptr = newname; optr = oldname; for (cnt=0; cnt<buflen; cnt++) { if ( (*nptr++ = *optr++) == NULLCH) { return OK; } } return SYSERR; /* Buffer filled before copy completed */ }
UnusualAbsurd/adv-discord-bot
Applications/misc/userinfo.js
<reponame>UnusualAbsurd/adv-discord-bot<filename>Applications/misc/userinfo.js const { Client, CommandInteraction, MessageEmbed, MessageActionRow, MessageButton, } = require("discord.js"); module.exports = { name: "userinfo", description: "Get information of a user!", options: [ { name: "user", description: "The user that you want to get information from", type: "USER", required: false, }, ], /** * @param {Client} client * @param {CommandInteraction} interaction * @param {String[]} args */ async execute(client, interaction, args) { const user = interaction.options.getMember("user") || interaction.member; const row = new MessageActionRow().addComponents([ new MessageButton() .setCustomId("showroles") .setLabel("Show Roles") .setStyle("SECONDARY"), ]); const filter = { owner: interaction.guild.ownerId === user.id, }; let ack; if (interaction.guild.ownerId === user.id) ack = "Server Owner"; if (user.permissions.has("ADMINISTRATOR") && !filter.owner) ack = "Server Administrator"; if ( user.permissions.has(["MANAGE_ROLES", "MANAGE_MESSAGES"]) && !user.permissions.has("ADMINISTRATOR") && !filter.owner ) ack = "Server Moderator"; if ( user.permissions.has(["SEND_MESSAGES"]) && !user.permissions.has(["MANAGE_ROLES", "MANAGE_MESSAGES"]) && !filter.owner ) ack = "Server Member"; const embed = new MessageEmbed() .setColor( user.user.accentColor || user.roles.highest.color || client.config.color ) .setAuthor(user.user.tag, user.displayAvatarURL({ dynamic: true })) .setThumbnail(user.displayAvatarURL({ dynamic: true })) .setDescription( `<@!${user.id}> (\`${user.id}\`) - [Avatar](${user.displayAvatarURL({ dynamic: true, })})` ) .addFields( { name: "Creation Date", value: `<t:${Math.floor( user.user.createdTimestamp / 1000 )}:D>\n[ <t:${Math.floor(user.user.createdTimestamp / 1000)}:R> ]`, inline: true, }, { name: `Server Joined Date`, value: `<t:${Math.floor( user.joinedTimestamp / 1000 )}:D>\n[ <t:${Math.floor(user.joinedTimestamp / 1000)}:R> ]`, inline: true, }, { name: "Acknowledgement", value: `${ack}` } ) .setFooter(user.id) .setTimestamp(); if (user.user.banner) embed.setImage(user.user.bannerURL({ dynamic: true })); interaction.reply({ embeds: [embed], components: [row] }); }, };
swobspace/lackmus
app/views/signatures/index.json.jbuilder
<reponame>swobspace/lackmus<gh_stars>0 json.array!(@signatures) do |signature| json.extract! signature, :id, :signature_id, :signature_info, :references, :action json.url signature_url(signature, format: :json) end
toventang/debezium-client
subscriber/subscriber.go
<filename>subscriber/subscriber.go<gh_stars>1-10 package subscriber import ( "context" "github.com/Shopify/sarama" ) type Subscriber struct { kafka sarama.ConsumerGroup handler handler opts Options } func NewSubscriber(opt ...Option) (Subscriber, error) { opts := NewOptions(opt...) subscriber := Subscriber{opts: opts, handler: handler{opts.connector}} conf := sarama.NewConfig() conf.Version = sarama.V0_11_0_0 cg, err := sarama.NewConsumerGroup(opts.Addresses, opts.GroupID, conf) if err != nil { return subscriber, err } subscriber.kafka = cg return subscriber, nil } func (sub Subscriber) Subscribe(ctx context.Context) error { return sub.kafka.Consume(ctx, sub.opts.Topics, &sub) } func (sub Subscriber) Close() error { if sub.kafka != nil { return sub.kafka.Close() } return nil } func (sub Subscriber) ConsumeClaim(sess sarama.ConsumerGroupSession, claim sarama.ConsumerGroupClaim) error { for msg := range claim.Messages() { if err := sub.handler.process(msg); err != nil { break } else { sess.MarkMessage(msg, "") } } return nil } func (Subscriber) Setup(sarama.ConsumerGroupSession) error { return nil } func (Subscriber) Cleanup(sarama.ConsumerGroupSession) error { return nil }
badi91/iPlug2
Examples/IPlugDrumSynth/IPlugDrumSynth_DSP.h
#pragma once #include "Oscillator.h" #include "ADSREnvelope.h" #include <vector> static constexpr int kNumDrums = 4; static constexpr double kStartFreq = 300.; //Hz static constexpr double kFreqDiff = 100.; //Hz static constexpr double kPitchEnvRange = 100.; //Hz static constexpr double kAmpDecayTime = 300; //Ms static constexpr double kPitchDecayTime = 50.; //Ms using namespace iplug; class DrumSynthDSP { public: struct DrumVoice { ADSREnvelope<sample> mPitchEnv {"pitch", nullptr, false}; ADSREnvelope<sample> mAmpEnv {"amp", nullptr, false}; FastSinOscillator<sample> mOsc; double mBaseFreq; DrumVoice(double baseFreq) : mBaseFreq(baseFreq) { mAmpEnv.SetStageTime(ADSREnvelope<sample>::kAttack, 0.); mAmpEnv.SetStageTime(ADSREnvelope<sample>::kDecay, kAmpDecayTime); mPitchEnv.SetStageTime(ADSREnvelope<sample>::kAttack, 0.); mPitchEnv.SetStageTime(ADSREnvelope<sample>::kDecay, kPitchDecayTime); } inline sample Process() { return mOsc.Process(mBaseFreq + mPitchEnv.Process()) * mAmpEnv.Process(); } void Trigger(double amp) { mOsc.Reset(); mPitchEnv.Start(amp * kPitchEnvRange); mAmpEnv.Start(amp); } inline bool IsActive() const { return mAmpEnv.GetBusy(); } }; DrumSynthDSP() // : mMidiQueue(IMidiMsg::QueueSize(DEFAULT_BLOCK_SIZE, DEFAULT_SAMPLE_RATE)) { for(int d=0;d<kNumDrums;d++) { mDrums.push_back(DrumVoice(kStartFreq + (d * kFreqDiff))); } } void Reset(double sampleRate, int blockSize) { mMidiQueue.Resize(blockSize); // mMidiQueue.Resize(IMidiMsg::QueueSize(blockSize, sampleRate)); } void ProcessBlock(sample** outputs, int nFrames) { for(int s=0;s<nFrames;s++) { while (!mMidiQueue.Empty()) { IMidiMsg& msg = mMidiQueue.Peek(); if (msg.mOffset > s) break; if(msg.StatusMsg() == IMidiMsg::kNoteOn && msg.Velocity()) { int pitchClass = msg.NoteNumber() % 12; if(pitchClass < kNumDrums) mDrums[pitchClass].Trigger(msg.Velocity() / 127.f); } mMidiQueue.Remove(); } if(mMultiOut) { int channel=0; for(int d=0;d<kNumDrums;d++) { outputs[channel][s] = 0.; if(mDrums[d].IsActive()) outputs[channel][s] = mDrums[d].Process(); outputs[channel + 1][s] = outputs[channel][s]; channel += 2; } } else { outputs[0][s] = 0.; for(int d=0;d<kNumDrums;d++) { if(mDrums[d].IsActive()) outputs[0][s] += mDrums[d].Process(); } outputs[1][s] = outputs[0][s]; } } mMidiQueue.Flush(nFrames); } void ProcessMidiMsg(const IMidiMsg& msg) { mMidiQueue.Add(msg); } void SetMultiOut(bool multiOut) { mMultiOut = multiOut; } private: bool mMultiOut = false; std::vector<DrumVoice> mDrums; IMidiQueue mMidiQueue; };
MKattaa/surveyless
src/components/ui/Slider.js
<reponame>MKattaa/surveyless import 'rc-slider/assets/index.css'; import {Box} from 'rebass'; import RCSlider from 'rc-slider'; import React from 'react'; import Tooltip from 'rc-tooltip'; const Handle = RCSlider.Handle; const handle = props => { const {value, dragging, index, ...restProps} = props; return ( <Tooltip prefixCls="rc-slider-tooltip" overlay={value} visible={dragging} placement="top" key={index}> <Handle value={value} {...restProps} /> </Tooltip> ); }; // TODO implement a better slider function Slider({disabled, marks, max, min, onChange, step, value}) { return ( <Box p={4}> <RCSlider disabled={disabled} handle={handle} marks={marks} max={max} min={min} step={step} onChange={onChange} value={value} /> </Box> ); } export default Slider;
TheBiggerGuy/iridium-toolk
rtl-sdr/rtl-peak-hold.py
#!/usr/bin/env python # vim: set ts=4 sw=4 tw=0 et pm=: import sys import math import numpy import os.path import re import getopt import time from functools import partial import matplotlib.pyplot as plt import threading import time def normalize(v): m = max(v) return [x/m for x in v] class PeakHold(object): def __init__(self, fft_size, use_8bit=False, verbose=False): self._slice_size=fft_size self._fft_size=self._slice_size if use_8bit: self._struct_elem = numpy.uint8 self._struct_len = numpy.dtype(self._struct_elem).itemsize * self._slice_size *2 else: self._struct_elem = numpy.complex64 self._struct_len = numpy.dtype(self._struct_elem).itemsize * self._slice_size self._window = numpy.blackman(self._fft_size) self.peaks = numpy.array([-100000000]*self._fft_size) def _fft(self, slice, fft_len=None): if fft_len: fft_result = numpy.fft.fft(slice, fft_len) else: fft_result = numpy.fft.fft(slice) fft_result = numpy.fft.fftshift(fft_result) return fft_result/len(slice) def process_file(self, file_name): with open(file_name, "rb") as f: f.read(self._struct_len) while True: data = f.read(self._struct_len) if not data: break if len(data) != self._struct_len: break slice = numpy.frombuffer(data, dtype=self._struct_elem) if self._struct_elem == numpy.uint8: slice = slice.astype(numpy.float32) # convert to float slice = (slice-127.35)/128. # Normalize slice = slice.view(numpy.complex64) # reinterpret as complex spectrum = self._fft(slice, self._fft_size) mag = spectrum mag = numpy.abs(spectrum)**2 #print max(numpy.abs(slice)), max(mag) mag = 10*numpy.log10(mag) self.peaks = numpy.maximum(self.peaks, mag) def plot_peaks(data): plt.ion() fig = plt.figure() ax = fig.add_subplot(111) ax.set_ylim([-80,-20]) time.sleep(1) l, = ax.plot(data.peaks, ) while 1: l.set_ydata(data.peaks) fig.canvas.draw() time.sleep(1) if __name__ == "__main__": fft_size = int(sys.argv[1]) verbose = False file_name = "/dev/stdin" d = PeakHold(fft_size=fft_size, use_8bit=False, verbose=verbose) drawer = threading.Thread(target=plot_peaks, args=[d]) drawer.setDaemon(True) drawer.start() d.process_file(file_name) while True: time.sleep(1)
youngzil/quickstart-framework
quickstart-design-pattern/src/test/java/org/quickstart/design/pattern/decorator/DecoratorZero.java
/** * 项目名称:quickstart-design-pattern * 文件名:DecoratorZero.java * 版本信息: * 日期:2018年1月26日 * Copyright yangzl Corporation 2018 * 版权所有 * */ package org.quickstart.design.pattern.decorator; /** * DecoratorZero * * @author:<EMAIL> * @2018年1月26日 下午7:57:09 * @since 1.0 */ // 下面定义三种装饰,这是第一个,第二个第三个功能依次细化,即装饰者的功能越来越多 public class DecoratorZero extends Decorator { public DecoratorZero(Human human) { super(human); } public void goHome() { System.out.println("进房子。。"); } public void findMap() { System.out.println("书房找找Map。。"); } @Override public void wearClothes() { // TODO Auto-generated method stub super.wearClothes(); goHome(); } @Override public void walkToWhere() { // TODO Auto-generated method stub super.walkToWhere(); findMap(); } }
usenixatc2021/SoftRefresh_Scheduling
linsched-linsched-alpha/arch/m32r/include/asm/timex.h
#ifndef _ASM_M32R_TIMEX_H #define _ASM_M32R_TIMEX_H /* * linux/include/asm-m32r/timex.h * * m32r architecture timex specifications */ #define CLOCK_TICK_RATE (CONFIG_BUS_CLOCK / CONFIG_TIMER_DIVIDE) #define CLOCK_TICK_FACTOR 20 /* Factor of both 1000000 and CLOCK_TICK_RATE */ #ifdef __KERNEL__ /* * Standard way to access the cycle counter. * Currently only used on SMP. */ typedef unsigned long long cycles_t; static __inline__ cycles_t get_cycles (void) { return 0; } #endif /* __KERNEL__ */ #endif /* _ASM_M32R_TIMEX_H */
jpbelang/raml-java-tools
pojo-to-raml/src/test/java/org/raml/pojotoraml/types/CollectionRamlTypeTest.java
package org.raml.pojotoraml.types; import org.junit.Test; import org.raml.pojotoraml.Fun; import static org.junit.Assert.*; /** * Created. There, you have it. */ public class CollectionRamlTypeTest { @Test public void wrappingScalar() throws Exception { CollectionRamlType collectionRamlType = CollectionRamlType.of(ScalarType.BOOLEAN); assertTrue(collectionRamlType.isScalar()); assertEquals(boolean.class, collectionRamlType.type()); assertEquals("boolean[]", collectionRamlType.getRamlSyntax()); } @Test public void wrappingComposed() throws Exception { CollectionRamlType collectionRamlType = CollectionRamlType.of(ComposedRamlType.forClass(Fun.class, "myName")); assertFalse(collectionRamlType.isScalar()); assertEquals(Fun.class, collectionRamlType.type()); assertEquals("myName[]", collectionRamlType.getRamlSyntax()); } }
touxiong88/92_mediatek
packages/apps/Weather3D/src/com/mediatek/weather3dwidget/Alarm.java
/* Copyright Statement: * * This software/firmware and related documentation ("MediaTek Software") are * protected under relevant copyright laws. The information contained herein is * confidential and proprietary to MediaTek Inc. and/or its licensors. Without * the prior written permission of MediaTek inc. and/or its licensors, any * reproduction, modification, use or disclosure of MediaTek Software, and * information contained herein, in whole or in part, shall be strictly * prohibited. * * MediaTek Inc. (C) 2010. All rights reserved. * * BY OPENING THIS FILE, RECEIVER HEREBY UNEQUIVOCALLY ACKNOWLEDGES AND AGREES * THAT THE SOFTWARE/FIRMWARE AND ITS DOCUMENTATIONS ("MEDIATEK SOFTWARE") * RECEIVED FROM MEDIATEK AND/OR ITS REPRESENTATIVES ARE PROVIDED TO RECEIVER * ON AN "AS-IS" BASIS ONLY. MEDIATEK EXPRESSLY DISCLAIMS ANY AND ALL * WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED * WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE OR * NONINFRINGEMENT. NEITHER DOES MEDIATEK PROVIDE ANY WARRANTY WHATSOEVER WITH * RESPECT TO THE SOFTWARE OF ANY THIRD PARTY WHICH MAY BE USED BY, * INCORPORATED IN, OR SUPPLIED WITH THE MEDIATEK SOFTWARE, AND RECEIVER AGREES * TO LOOK ONLY TO SUCH THIRD PARTY FOR ANY WARRANTY CLAIM RELATING THERETO. * RECEIVER EXPRESSLY ACKNOWLEDGES THAT IT IS RECEIVER'S SOLE RESPONSIBILITY TO * OBTAIN FROM ANY THIRD PARTY ALL PROPER LICENSES CONTAINED IN MEDIATEK * SOFTWARE. MEDIATEK SHALL ALSO NOT BE RESPONSIBLE FOR ANY MEDIATEK SOFTWARE * RELEASES MADE TO RECEIVER'S SPECIFICATION OR TO CONFORM TO A PARTICULAR * STANDARD OR OPEN FORUM. RECEIVER'S SOLE AND EXCLUSIVE REMEDY AND MEDIATEK'S * ENTIRE AND CUMULATIVE LIABILITY WITH RESPECT TO THE MEDIATEK SOFTWARE * RELEASED HEREUNDER WILL BE, AT MEDIATEK'S OPTION, TO REVISE OR REPLACE THE * MEDIATEK SOFTWARE AT ISSUE, OR REFUND ANY SOFTWARE LICENSE FEES OR SERVICE * CHARGE PAID BY RECEIVER TO MEDIATEK FOR SUCH MEDIATEK SOFTWARE AT ISSUE. * * The following software/firmware and/or related documentation ("MediaTek * Software") have been modified by MediaTek Inc. All revisions are subject to * any receiver's applicable license agreements with MediaTek Inc. */ package com.mediatek.weather3dwidget; import android.app.AlarmManager; import android.app.PendingIntent; import android.content.Context; import android.content.Intent; import java.util.Calendar; public final class Alarm { private static final String TAG = "W3D/Alarm"; private Alarm() {} public static void setAlarm(Context context, String timezone) { LogUtil.v(TAG, "timezone = " + timezone); Calendar c = Calendar.getInstance(); LogUtil.v(TAG, "now = " + c.getTimeInMillis()); Calendar worldCalendar = Util.getTime(timezone); Calendar tempCalendar = Util.getTime(timezone); long deltaTime; int worldHour = worldCalendar.get(Calendar.HOUR_OF_DAY); if (worldHour >= 6 && worldHour < 18) { tempCalendar.set(Calendar.HOUR_OF_DAY, 18); tempCalendar.set(Calendar.MINUTE, 0); tempCalendar.set(Calendar.SECOND, 0); tempCalendar.set(Calendar.MILLISECOND, 0); deltaTime = tempCalendar.getTimeInMillis() - worldCalendar.getTimeInMillis(); } else if (worldHour >= 18) { tempCalendar.set(Calendar.HOUR_OF_DAY, 23); tempCalendar.set(Calendar.MINUTE, 59); tempCalendar.set(Calendar.SECOND, 59); tempCalendar.set(Calendar.MILLISECOND, 0); deltaTime = tempCalendar.getTimeInMillis() - worldCalendar.getTimeInMillis() + 1000 + 6 * 60 * 60 * 1000; } else { tempCalendar.set(Calendar.HOUR_OF_DAY, 6); tempCalendar.set(Calendar.MINUTE, 0); tempCalendar.set(Calendar.SECOND, 0); tempCalendar.set(Calendar.MILLISECOND, 0); deltaTime = tempCalendar.getTimeInMillis() - worldCalendar.getTimeInMillis(); } LogUtil.v(TAG, "deltaTime = " + deltaTime); Intent intent = new Intent(context, WeatherWidget.class); intent.setAction(WeatherWidgetAction.ACTION_ALARM_TIME_UP); PendingIntent sender = PendingIntent.getBroadcast(context, 1, intent, 0); AlarmManager am = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); am.set(AlarmManager.RTC_WAKEUP, c.getTimeInMillis() + deltaTime, sender); } public static void stopAlarm(Context context) { LogUtil.v(TAG); Intent intent = new Intent(context, WeatherWidget.class); PendingIntent sender = PendingIntent.getBroadcast(context, 1, intent, 0); AlarmManager am = (AlarmManager) context.getSystemService(Context.ALARM_SERVICE); am.cancel(sender); } }
Atomic-Reactor/Actinium-Plugins
actinium_modules/@atomic-reactor/actinium-media/plugin.js
const _ = require('underscore'); const ENUMS = require('./enums'); const pkg = require('./package'); const op = require('object-path'); const { CloudHasCapabilities, CloudRunOptions, } = require(`${ACTINIUM_DIR}/lib/utils`); const COLLECTION = ENUMS.COLLECTION; const PLUGIN = { ID: 'Media', name: 'Media Plugin', description: 'Media plugin used to manage files.', version: { actinium: op.get(pkg, 'actinium.version', '>=3.2.6'), plugin: op.get(pkg, 'version'), }, meta: { group: 'core', builtIn: true, }, }; const PLUGIN_SDK = require('./sdk'); const PLUGIN_SCHEMA = require('./schema'); // Create SDK Singleton const Media = op.get(Actinium, COLLECTION.MEDIA, PLUGIN_SDK); Actinium[COLLECTION.MEDIA] = Media; // Register Plugin Actinium.Plugin.register(PLUGIN, true); // Register Capabilities & Schema Actinium.Hook.register('schema', async ({ ID }) => { if (ID !== PLUGIN.ID) return; Actinium.Collection.register( COLLECTION.DIRECTORY, PLUGIN_SCHEMA.ACTIONS.DIRECTORY, PLUGIN_SCHEMA.SCHEMA.DIRECTORY, ); Actinium.Collection.register( COLLECTION.MEDIA, PLUGIN_SCHEMA.ACTIONS.MEDIA, PLUGIN_SCHEMA.SCHEMA.MEDIA, ); }); const PLUGIN_BLUEPRINTS = require('./blueprints'); const registerBlueprints = (reg = true) => ({ ID }) => { if (ID && ID !== PLUGIN.ID) return; if (reg === true) PLUGIN_BLUEPRINTS.forEach(bp => Actinium.Blueprint.register(bp.ID, bp)); else PLUGIN_BLUEPRINTS.forEach(bp => Actinium.Blueprint.unregister(bp.ID)); }; // Start: Blueprints Actinium.Hook.register('start', registerBlueprints(true)); // Capabilities Actinium.Hook.register('before-capability-load', () => { if (!Actinium.Plugin.isActive(PLUGIN.ID)) return; const caps = [ 'media-ui.view', 'media.addfield', 'media.create', 'media.update', 'media.update', 'media.retrieve', ]; caps.forEach(cap => Actinium.Capability.register(cap, { allowed: ['contributor', 'moderator'], }), ); }); // Activate: Blueprints Actinium.Hook.register('activate', registerBlueprints(true)); // Deactivate: Blueprints Actinium.Hook.register('deactivate', registerBlueprints(false)); const PLUGIN_ROUTES = require('./routes'); const saveRoutes = async () => { for (const route of PLUGIN_ROUTES) { await Actinium.Route.save(route); } }; // Update routes on startup Actinium.Hook.register('start', async () => { if (Actinium.Plugin.isActive(PLUGIN.ID)) { await saveRoutes(); } }); // Update routes on plugin activation Actinium.Hook.register('activate', async ({ ID }) => { if (ID === PLUGIN.ID) { await saveRoutes(); } }); // Update routes on plugin update Actinium.Hook.register('update', async ({ ID }) => { if (ID === PLUGIN.ID) { await saveRoutes(); } }); // Remove routes on deactivation Actinium.Hook.register('deactivate', async ({ ID }) => { if (ID === PLUGIN.ID) { for (const route of PLUGIN_ROUTES) { await Actinium.Route.delete(route); } } }); // Load MediaDirectories to memory Actinium.Hook.register('start', async () => { if (!Actinium.Plugin.isActive(PLUGIN.ID)) return; await Actinium.Media.load(); // Register a pulse to reload the MediaDirectories every minute Actinium.Pulse.define('media-directories', Actinium.Media.load); }); // Setup pulses on install Actinium.Hook.register('install', ({ ID }) => { if (ID !== PLUGIN.ID) return; if ( _.pluck(Actinium.Pulse.definitions, 'id').includes('media-directories') ) { return; } Actinium.Pulse.define('media-directories', Actinium.Media.load); }); // Remove pulses on uninstall Actinium.Hook.register('uninstall', ({ ID }) => { if (ID !== PLUGIN.ID) return; Actinium.Pulse.remove('media-directories'); }); // Directory save hook Actinium.Hook.register('directory-save', async req => { if (req.object.isNew()) { const { directory } = req.object.toJSON(); // Lookup the directory before we create it const fetch = await new Parse.Query(COLLECTION.DIRECTORY) .equalTo('directory', directory) .first({ useMasterKey: true }); if (fetch) throw new Error('directory exists'); return; } }); // Recycle a deleted Actinium.Hook.register('directory-delete', req => { if (!Actinium.Plugin.isActive(PLUGIN.ID)) return; const collection = req.object.className; const object = req.object; return Actinium.Recycle.trash( { collection, object }, { useMasterKey: true }, ); }); Actinium.Hook.register('directory-query', qry => qry.exists('directory')); // Media save Actinium.Hook.register('media-save', async req => { if (!Actinium.Plugin.isActive(PLUGIN.ID)) return; let { thumbnail, type } = req.object.toJSON(); const file = req.object.get('file'); // Set Type if (file && !type) { type = Actinium.Media.fileType(file.name()); req.object.set('type', type); } // Clear existing file if uploading a new one if (!req.object.isNew() && op.get(req, 'context.upload')) { const prevObj = await new Parse.Object(COLLECTION.MEDIA) .set('objectId', req.object.id) .fetch({ useMasterKey: true }); if (prevObj) { await Actinium.Media.cleanup([prevObj]); thumbnail = undefined; } } // Create thumbnail if (type === 'IMAGE' && file && !thumbnail) { thumbnail = await Actinium.Media.crop({ url: file }); if (thumbnail) { req.object.set('thumbnail', thumbnail); } } }); // Media after delete Actinium.Hook.register('after-media-delete', req => Actinium.Media.cleanup([req.object], true), ); // content-schema-field-types hook Actinium.Hook.register('content-schema-field-types', fieldTypes => { if (!Actinium.Plugin.isActive(PLUGIN.ID)) return; fieldTypes['Media'] = { type: 'Relation', targetClass: 'Media' }; }); // content-retrieve hook Actinium.Hook.register('content-retrieve', async (content, params, options) => { if (!Actinium.Plugin.isActive(PLUGIN.ID)) return; const { type } = content; const files = await Media.Content.retrieve({ content, type }, options); Object.entries(files).forEach(([key, value]) => op.set(content, key, value), ); }); // user media query Actinium.Hook.register('media-query', async (qry, params) => { if (!Actinium.Plugin.isActive(PLUGIN.ID)) return; if (op.get(params, 'user')) { let user = params.user; if (_.isString(user)) { user = new Actinium.Object(Parse.User).set('objectId', user); } qry.equalTo('user', user); } }); Actinium.Hook.register( 'user-retrieve-response', async (user, params, options) => { const { verbose } = params; if (!Actinium.Plugin.isActive(PLUGIN.ID) || !verbose) return; options = options || { useMasterKey: true }; const media = await Actinium.Media.User.files({ user }, options); if (_.isError(media)) return; const meta = user.get('meta') || {}; op.set(meta, 'media', media); user.set('meta', meta); }, ); // Register Cloud functions /** * @api {Cloud} directories directories * @apiVersion 3.1.3 * @apiGroup Cloud * @apiName directories * @apiDescription Retrieves the complete list of Media directories. Runs the `directory-query` hook allowing you to change or replace the default query. The results are reduced based on the capabilities applied to each directory and the current user request. Permission: `Media.retrieve` _(use the **media.capabilities.list** setting to change)_. * @apiParam {String} [search] Search for a specific directory. Uses `Parse.Query.startsWith()` to execute the query. * @apiParam {Boolean} [verbose] Return an Array of ParseObjects instead of the default array of strings. * @apiExample Example usage: Actinium.Cloud.run('directories').then(directories => { console.log(directories); }); */ Actinium.Cloud.define(PLUGIN.ID, 'directories', async req => { if (!CloudHasCapabilities(req, 'media-ui.view')) { return Promise.reject(ENUMS.ERRORS.PERMISSION); } const { user } = req; const { search, verbose } = req.params; let directories = verbose === true ? await Actinium.Media.directoriesFetch(CloudRunOptions(req)) : Actinium.Media.directories(search, user); await Actinium.Hook.run('directories', { directories, req }); return directories; }); /** * @api {Cloud} directory-save directory-save * @apiVersion 3.1.3 * @apiGroup Cloud * @apiName directory-save * @apiDescription Create or update a new Media directory. Permission: `Media.create` _(use the **media.capabilities.directory** setting to change)_. * @apiParam {String} directory The directory path. * @apiParam {Array} [capabilities='[Media.create]'] The capabilities array. * @apiParam {String} objectId Used when updating an existing directory object. * @apiParam {Array} permissions List of permissions to apply to the directory. If empty the directory is read/write for all users. * @apiExample Example usage: Actinium.Cloud.run('directory-save', { directory: 'uploads', capabilities: ['media.create'] permissions: [ { objectId: "Lxank79qjx", type: "role", permission: "write", name: "super-admin" }, { objectId: "s0UJ2Hk7XC", type: "user", permission: "write" } ] }).then(result => { console.log(result); }); */ Actinium.Cloud.define(PLUGIN.ID, 'directory-save', async req => { if (!CloudHasCapabilities(req, ['media.create'])) { return Promise.reject(ENUMS.ERRORS.PERMISSION); } const { capabilities, directory, objectId, permissions = [] } = req.params; if (!directory) return Promise.reject(ENUMS.ERRORS.DIRECTORY); return Actinium.Media.directorySave({ directory, capabilities, permissions, objectId, options: CloudRunOptions(req), }); }); /** * @api {Cloud} directory-delete directory-delete * @apiVersion 3.1.3 * @apiGroup Cloud * @apiName directory-delete * @apiDescription Delete a directory from the `MediaDirectory` table. This will NOT delete the files within the directory. _Use the `media-delete` function for deleting a directory of files._ Permission: `Media.create` _(use the **media.capabilities.directory** setting to change)_ * @apiParam {String} directory The directory path. * @apiExample Example usage: Actinium.Cloud.run('directory-delete', { directory: 'avatars' }); */ Actinium.Cloud.define(PLUGIN.ID, 'directory-delete', async req => { if (!CloudHasCapabilities(req, ['media.delete'])) { return Promise.reject(ENUMS.ERRORS.PERMISSION); } const { user } = req; const { directory, content = false } = req.params; if (!user) return Promise.reject(ENUMS.ERRORS.PERMISSIONS); if (!directory) return Promise.reject(ENUMS.ERRORS.DIRECTORY); return Actinium.Media.directoryDelete(directory, user, content); }); /** * @api {Cloud} media media * @apiVersion 3.1.3 * @apiGroup Cloud * @apiName media * @apiDescription Retrieves a paginated list of `Media` objects. Permission: `Media.retrieve` _(use the **media.capabilities.retrieve** setting to change)_ * @apiParam {String} [directory] Retrieve a specific directory. * @apiParam {String} [search] Search for a specific `url` or `filename`. * @apiParam {Number} [page=1] Return the specified page of the results. * @apiParam {Number} [limit=50] Number of objections to return per page. * @apiExample Example usage: Actinium.Cloud.run('media', { page: 1, limit: 20 directory: 'avatars', search: 'user-123.jpg'}); * @apiExample Returns { files: Object, directories: Array, count: Number page: Number, pages: Number, index: Number, limit: Number, next: Number, prev: Number } */ Actinium.Cloud.define(PLUGIN.ID, 'media', async req => Actinium.Media.files({ ...req.params, user: req.user }), ); /** * @api {Cloud} media-delete media-delete * @apiVersion 3.1.3 * @apiGroup Cloud * @apiName media-delete * @apiDescription Delete a single file or directory containing multiple files. The file to search for will be matched against the following fields: `url, objectId, uuid, filename, directory` When deleting based on `filename` or `directory` There are a couple protections built in: 1. You must specify `useMasterKey` in the run `options` object. 2. Only 50 files will be deleted per request. Permission: `Media.create` _(use the **media.capabilities.upload** setting to change)_ * @apiParam {String} match The search string. * @apiExample Example usage: // URL delete Actinium.Cloud.run('media-delete', { match: '/uploads/some-file.txt' }); // Directory Delete Actinium.Cloud.run('media-delete', { match: '/uploads' }, { useMasterKey: true }); */ Actinium.Cloud.define(PLUGIN.ID, 'media-delete', async req => { if (!CloudHasCapabilities(req, ['media.delete'])) { return Promise.reject(ENUMS.ERRORS.PERMISSION); } const { user, master } = req; return Actinium.Media.fileDelete(req.params, user, master); }); Actinium.Cloud.define(PLUGIN.ID, 'media-delete-thumbnail', async req => { if (!CloudHasCapabilities(req, ['media.delete'])) { return Promise.reject(ENUMS.ERRORS.PERMISSION); } const { objectId, property } = req.params; let file; const options = CloudRunOptions(req); const obj = await new Parse.Object(COLLECTION.MEDIA) .set('objectId', objectId) .fetch(options); const isMeta = String(property).startsWith('meta.'); if (isMeta) { const fld = String(property).substr(5); const meta = obj.get('meta') || {}; file = op.get(meta, fld); op.del(meta, fld); obj.set('meta', meta); } else { file = obj.get(property); obj.unset(property); } if (file) { const filename = file.name(); await Actinium.Media.deleteFileObject(filename); } return obj.save(null, options); }); /** * @api {Cloud} media-update media-update * @apiVersion 3.1.3 * @apiGroup Cloud * @apiName media-update * @apiDescription Function that updates a Media Object. * @apiParam {Object} params The Media Object data to update. * @apiParam {String} .objectId The `objectId` field is required and is used to fetch the Media Object to update. * @apiParam {String} .filedata If you're trying replace the `file` object via dataurl, you can pass the `filedata` property to accomplish this. * @apiParam {Object} options Parse options object. * @apiExample Example usage: const updatedMediaObj = await Parse.Cloud.run('media-update', { objectId: 'tP66wMkNPx', filename: 'different-file-name.jpg', meta: { title: 'A new title', description: 'A new decription', } }, { useMasterKey: true, }); */ Actinium.Cloud.define(PLUGIN.ID, 'media-update', async req => { if (!CloudHasCapabilities(req, ['media.update'])) { return Promise.reject(ENUMS.ERRORS.PERMISSION); } delete req.params.thumbnail; return Actinium.Media.update(req.params, CloudRunOptions(req)); }); /** * @api {Cloud} media-upload media-upload * @apiVersion 3.1.3 * @apiGroup Cloud * @apiName media-upload * @apiDescription Cloud function that creates a file and adds it to the Media Library. Permission: `Media.create` _(use the **media.capabilities.upload** setting to change)_ Returns: `Parse.Object('Media')` * @apiParam {Mixed} data The contents of the file. This can be any valid `Actinium.File` file data value. * @apiParam {Object} meta The meta object for the file upload. * @apiParam {String} .directory The directory where the file will be saved. Required. * @apiParam {String} .filename The file name. Required. * @apiParam {Number} [.size] The number of bytes the file contains. * @apiParam {String} [.ID] Unique ID of the file. If empty, a new UUID will be created. * @apiExample Base64 Example: const upload = { data: { base64: "V29ya2luZyBhdCBQYXJzZSBpcyBncmVhdCE=" } meta: { directory: 'uploads', filename: 'avatar.png', size: 139894 } }; Actinium.Cloud.run('media-upload', upload); * @apiExample ByteArray Example: const upload = { data: [ 0xBE, 0xEF, 0xCA, 0xFE ], meta: { directory: 'uploads', filename: 'avatar.png', size: 139894 } }; Actinium.Cloud.run('media-upload', upload); */ Actinium.Cloud.define(PLUGIN.ID, 'media-upload', async req => { if (!CloudHasCapabilities(req, ['media.create'])) { return Promise.reject(ENUMS.ERRORS.PERMISSION); } return Actinium.Media.upload( req.params.data, req.params.meta, req.user, CloudRunOptions(req), ); }); /** * @api {Cloud} media-retrieve media-retrieve * @apiVersion 3.1.7 * @apiGroup Cloud * @apiName media-retrieve * @apiDescription Retrieves a specific `Media` object. * @apiParam {String} [directory] Retrieve a file by it's directory value. You must also specify `filename`. * @apiParam {String} [filename] Retrieve a file by it's filename value. You must also specify `directory`. * @apiParam {String} [objectId] Retrieve a file by it's objectId value. * @apiParam {String} [uuid] Retrieve a file by it's uuid value. * @apiParam {String} [url] Retrieve a file by it's url value. */ Actinium.Cloud.define(PLUGIN.ID, 'media-retrieve', async req => { if (!CloudHasCapabilities(req, ['media.retrieve'])) { return Promise.reject(ENUMS.ERRORS.PERMISSION); } const options = CloudRunOptions(req); return Actinium.Media.get(req.params, options); }); /** * @api {Asynchronous} media-image-crop media-image-crop * @apiVersion 3.1.3 * @apiGroup Cloud * @apiName media-image-crop * @apiDescription Generate a cropped version of the specified image from an `Actinium.File` object or image URL. Useful for creating thumbnails or responsive image sizes. Returns: `Actinium.File` object. * @apiParam {Mixed} url `String` or `Actinium.File` object. The source image url. If the value is an `Actinium.File` object, the `Actinium.File.url()` value used to fetch the image. * @apiParam {String} [objectId] The Parse Object to attach the cropped image to. * @apiParam {String} [field='thumbnail'] The field to attach the new image to. Used when the `objectId` parameter is set. * @apiParam {Object} [options] Sharp image [resize](https://sharp.pixelplumbing.com/api-resize) options. By default, `width` and `height` are set to `400`. * @apiExample Example usage: ... const thumbnail = await Actinium.Cloud.run('media-image-crop', { url: 'http://somesite/someimage.jpg', options: { width: 200, height: 200 } }); ... */ Actinium.Cloud.define(PLUGIN.ID, 'media-image-crop', async req => { let { ext, field, objectId, options, url } = req.params; if (!url) throw new Error('url is a required parameter'); field = field || 'thumbnail'; const image = await Actinium.Media.crop({ ext, prefix: field, url, options, }); if (objectId) { const cloudopts = CloudRunOptions(req); const obj = await new Parse.Object(COLLECTION.MEDIA) .set('objectId', objectId) .fetch(cloudopts); if (field === 'thumbnail') { // Delete previous image const prevTHM = obj.get('thumbnail'); if (prevTHM) { await Actinium.Media.deleteFileObject(prevTHM.name()); } // Set new thumbnail obj.set(field, image); } else { // Delete previous image const f = String(field).replace('meta.', ''); const meta = obj.get('meta') || {}; const prevURL = op.get(meta, f); if (prevURL) { await Actinium.Media.deleteFileObject(prevURL.name()); } // Set new image op.set(meta, f, image); obj.set('meta', meta); } await obj.save(null, cloudopts); } return image; }); Actinium.Cloud.beforeDelete(COLLECTION.DIRECTORY, async req => { await Actinium.Hook.run('directory-delete', req); }); Actinium.Cloud.beforeSave(COLLECTION.DIRECTORY, req => Actinium.Hook.run('directory-save', req), ); Actinium.Cloud.afterDelete(COLLECTION.DIRECTORY, req => { const dirs = () => { const directories = Actinium.Cache.get('Media.directories', []); return _.chain(directories) .pluck('directory') .compact() .uniq() .value() .sort(); }; const { directory } = req.object.toJSON(); let directories = _.without(dirs(), directory).sort(); Actinium.Cache.set('Media.directories', directories); Actinium.Hook.run('after-directory-delete', req); }); Actinium.Cloud.beforeSave(COLLECTION.MEDIA, req => { req.context = req.object.get('context') || {}; req.object.unset('context'); return Actinium.Hook.run('media-save', req); }); Actinium.Cloud.beforeDelete(COLLECTION.MEDIA, async req => { await Actinium.Hook.run('before-media-delete', req); }); Actinium.Cloud.afterDelete(COLLECTION.MEDIA, req => { const id = req.object.id; const files = Actinium.Cache.get('Media.files', {}); delete files[id]; Actinium.Cache.set('Media.files', files); Actinium.Hook.run('after-media-delete', req); }); Actinium.Cloud.afterFind(COLLECTION.MEDIA, async req => { req.objects.forEach(obj => { const file = obj.get('file'); if (file) { const type = Actinium.Media.fileType(file.name()); obj.set('type', type); } }); await Actinium.Hook.run('media-find', req); return req.objects; }); Actinium.Cloud.afterSave(COLLECTION.MEDIA, async req => { await Actinium.Hook.run('after-media-save', req); await Actinium.Media.load(); }); Actinium.Cloud.afterSave(COLLECTION.DIRECTORY, async req => { await Actinium.Hook.run('after-directory-save', req); await Actinium.Media.load(); }); Actinium.Cloud.define(PLUGIN.ID, 'media-create-from-url', async req => { if (!CloudHasCapabilities(req, ['media.create'])) { return Promise.reject(ENUMS.ERRORS.PERMISSION); } const options = CloudRunOptions(req); const params = { ...req.params, user: req.user }; return Media.createFromURL(params, options); });
simlt/myrobotlab
src/org/myrobotlab/service/InverseKinematics3D.java
package org.myrobotlab.service; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; import org.myrobotlab.framework.Service; import org.myrobotlab.framework.ServiceType; import org.myrobotlab.genetic.GeneticAlgorithm; import org.myrobotlab.genetic.Chromosome; import org.myrobotlab.genetic.Genetic; import org.myrobotlab.kinematics.CollisionDectection; import org.myrobotlab.kinematics.CollisionItem; import org.myrobotlab.kinematics.DHLink; import org.myrobotlab.kinematics.DHRobotArm; import org.myrobotlab.kinematics.Matrix; import org.myrobotlab.kinematics.Point; import org.myrobotlab.logging.Level; import org.myrobotlab.logging.LoggerFactory; import org.myrobotlab.logging.LoggingFactory; import org.myrobotlab.math.MathUtils; import org.myrobotlab.service.Servo.IKData; import org.myrobotlab.service.data.JoystickData; import org.myrobotlab.service.interfaces.IKJointAnglePublisher; import org.myrobotlab.service.interfaces.PointsListener; import org.slf4j.Logger; /** * * InverseKinematics3D - This class provides a 3D based inverse kinematics * implementation that allows you to specify the robot arm geometry based on DH * Parameters. This will use a pseudo-inverse jacobian gradient descent approach * to move the end affector to the desired x,y,z postions in space with respect * to the base frame. * * Rotation and Orientation information is not currently supported. (but should * be easy to add) * * @author kwatters * */ public class InverseKinematics3D extends Service implements IKJointAnglePublisher, PointsListener, Genetic { private static final long serialVersionUID = 1L; public final static Logger log = LoggerFactory.getLogger(InverseKinematics3D.class.getCanonicalName()); private DHRobotArm currentArm = null; private HashMap<String, DHRobotArm> arms = new HashMap<String, DHRobotArm>(); // we will track the joystick input to specify our velocity. private Point joystickLinearVelocity = new Point(0, 0, 0, 0, 0, 0); private Matrix inputMatrix = null; transient InputTrackingThread trackingThread = null; Point goTo; private CollisionDectection collisionItems = new CollisionDectection(); public static final int IK_COMPUTE_METHOD_PI_JACOBIAN = 1; public static final int IK_COMPUTE_METHOD_GENETIC_ALGORYTHM = 2; private int computeMethod = IK_COMPUTE_METHOD_PI_JACOBIAN; private int geneticPoolSize = 200; private double geneticMutationRate = 0.01; private double geneticRecombinationRate = 0.7; private int geneticGeneration = 300; private boolean geneticComputeSimulation = false; private HashMap<String, Servo> currentServos = new HashMap<String, Servo>(); private HashMap<String, HashMap<String, Servo>> servos = new HashMap<String, HashMap<String, Servo>>(); private double time; public InverseKinematics3D(String n) { super(n); // TODO: init } public void startTracking() { log.info(String.format("startTracking - starting new joystick input tracking thread %s_tracking", getName())); if (trackingThread != null) { stopTracking(); } trackingThread = new InputTrackingThread(String.format("%s_tracking", getName())); trackingThread.start(); } public void stopTracking() { if (trackingThread != null) { trackingThread.setTracking(false); } } public class InputTrackingThread extends Thread { private boolean isTracking = false; public InputTrackingThread(String name) { super(name); } @Override public void run() { // Ok, here we are. if we're running.. // we should be updating the move to based on the velocities // that are being tracked with the joystick. // how many ms to wait between movements. long pollInterval = 250; isTracking = true; long now = System.currentTimeMillis(); while (isTracking) { long pause = now + pollInterval - System.currentTimeMillis(); try { // the number of milliseconds until we update the position Thread.sleep(pause); } catch (InterruptedException e) { // TODO Auto-generated catch block log.info("Interrupted tracking thread."); e.printStackTrace(); isTracking = false; } // lets get the current position // current position + velocity * time Point current = currentPosition(); Point targetPoint = current.add(joystickLinearVelocity.multiplyXYZ(pollInterval / 1000.0)); if (!targetPoint.equals(current)) { log.info("Velocity: {} Old: {} New: {}", joystickLinearVelocity, current, targetPoint); } invoke("publishTracking", targetPoint); moveTo(targetPoint); // update current timestamp to determine how long we should wait // before the next moveTo is called. now = System.currentTimeMillis(); } } public boolean isTracking() { return isTracking; } public void setTracking(boolean isTracking) { this.isTracking = isTracking; } } public void changeArm(String arm) { if (arms.containsKey(arm)) { currentArm = arms.get(arm); currentServos = servos.get(arm); } else { log.info("IK service have no data for {}", arm); } } public Point currentPosition() { return currentArm.getPalmPosition(); } public Point currentPosition(String arm) { if (arms.containsKey(arm)) { return arms.get(arm).getPalmPosition(); } log.info("IK service have no data for {}", arm); return new Point(0, 0, 0, 0, 0, 0); } public void moveTo(double x, double y, double z) { // TODO: allow passing roll pitch and yaw moveTo(new Point(x, y, z, 0, 0, 0)); } public void moveTo(String arm, double x, double y, double z) { moveTo(arm, new Point(x, y, z, 0, 0, 0)); } /** * This create a rotation and translation matrix that will be applied on the * "moveTo" call. * * @param dx * - x axis translation * @param dy * - y axis translation * @param dz * - z axis translation * @param roll * - rotation about z (in degrees) * @param pitch * - rotation about x (in degrees) * @param yaw * - rotation about y (in degrees) * @return */ public Matrix createInputMatrix(double dx, double dy, double dz, double roll, double pitch, double yaw) { roll = MathUtils.degToRad(roll); pitch = MathUtils.degToRad(pitch); yaw = MathUtils.degToRad(yaw); Matrix trMatrix = Matrix.translation(dx, dy, dz); Matrix rotMatrix = Matrix.zRotation(roll).multiply(Matrix.yRotation(yaw).multiply(Matrix.xRotation(pitch))); inputMatrix = trMatrix.multiply(rotMatrix); return inputMatrix; } public Point rotateAndTranslate(Point pIn) { Matrix m = new Matrix(4, 1); m.elements[0][0] = pIn.getX(); m.elements[1][0] = pIn.getY(); m.elements[2][0] = pIn.getZ(); m.elements[3][0] = 1; Matrix pOM = inputMatrix.multiply(m); // TODO: compute the roll pitch yaw double roll = 0; double pitch = 0; double yaw = 0; Point pOut = new Point(pOM.elements[0][0], pOM.elements[1][0], pOM.elements[2][0], roll, pitch, yaw); return pOut; } public void centerAllJoints() { currentArm.centerAllJoints(); publishTelemetry(); } public void centerAllJoints(String arm) { if (arms.containsKey(arm)) { arms.get(arm).centerAllJoints(); } log.info("IK service have no data for {}", arm); } public void moveTo(Point p) { // log.info("Move TO {}", p ); if (inputMatrix != null) { p = rotateAndTranslate(p); } boolean success = false; if(computeMethod == IK_COMPUTE_METHOD_PI_JACOBIAN) { success = currentArm.moveToGoal(p); } else if (computeMethod == IK_COMPUTE_METHOD_GENETIC_ALGORYTHM) { goTo = p; GeneticAlgorithm GA = new GeneticAlgorithm(this, geneticPoolSize, currentArm.getNumLinks(), 8, geneticRecombinationRate, geneticMutationRate); //HashMap<Integer,Integer> lastIteration = new HashMap<Integer,Integer>(); int retry = 0; long timeToWait = 0; while (retry++ < 100) { Chromosome bestFit = GA.doGeneration(geneticGeneration); // this is the number of time the chromosome pool will be recombined and mutate //DHRobotArm checkedArm = simulateMove(bestFit.getDecodedGenome()); currentArm = simulateMove(bestFit.getDecodedGenome()); for (int i = 0; i < currentArm.getNumLinks(); i++){ Servo servo = currentServos.get(currentArm.getLink(i).getName()); while (timeToWait + servo.lastActivityTime > System.currentTimeMillis()) { sleep(1); } servo.moveTo(currentArm.getLink(i).getPositionValueDeg().intValue()); } timeToWait = (long)(time*1000); if (collisionItems.haveCollision()) { //collision avoiding need to be improved CollisionItem ci = null; int itemIndex = 0; int linkIndex = 0; for (DHLink l : currentArm.getLinks()) { boolean foundIt = false; for (itemIndex = 0; itemIndex < 2; itemIndex++) { if (l.getName().equals(collisionItems.getCollisionItem()[itemIndex].getName())) { ci = collisionItems.getCollisionItem()[itemIndex]; foundIt = true; break; } } if (foundIt) break; //we have the item to watch linkIndex++; } if (ci == null) { log.info("Collision between static item {} and {} detected", collisionItems.getCollisionItem()[0].getName(), collisionItems.getCollisionItem()[1].getName()); break; //collision is between items that we can't control } int dmove = 0; int deltaMove = 5; if (collisionItems.getCollisionPoint()[itemIndex].getX() >= collisionItems.getCollisionPoint()[1-itemIndex].getX()) { dmove+=deltaMove; } else dmove-=deltaMove; if (collisionItems.getCollisionPoint()[itemIndex].getY() >= collisionItems.getCollisionPoint()[1-itemIndex].getY()) { dmove+=deltaMove; } else dmove-=deltaMove; if (collisionItems.getCollisionPoint()[itemIndex].getZ() >= collisionItems.getCollisionPoint()[1-itemIndex].getZ()) { dmove+=deltaMove; } else dmove-=deltaMove; ArrayList<Object> tempPos = new ArrayList<Object>(); for (DHLink l : currentArm.getLinks()) { Point actPoint = currentArm.getJointPosition(linkIndex); Double distAct = actPoint.distanceTo(collisionItems.getCollisionPoint()[1-itemIndex]); l.incrRotate(MathUtils.degToRad(dmove)); Point newPoint = currentArm.getJointPosition(linkIndex); Double distNew = newPoint.distanceTo(collisionItems.getCollisionPoint()[1-itemIndex]); if (distAct < distNew) { l.incrRotate(MathUtils.degToRad(dmove * -2)); } tempPos.add(l.getPositionValueDeg()); } currentArm = simulateMove(tempPos); for (int k = 0; k < currentArm.getNumLinks(); k++){ Servo servo = currentServos.get(currentArm.getLink(k).getName()); while (timeToWait + servo.lastActivityTime > System.currentTimeMillis()) { sleep(1); } servo.moveTo(currentArm.getLink(k).getPositionValueDeg().intValue()); } timeToWait = (long) (time*1000); } else break; } } if (success) { publishTelemetry(); } } public void moveTo(String arm, Point p) { changeArm(arm); moveTo(p); } public void publishTelemetry() { Map<String, Double> angleMap = new HashMap<String, Double>(); for (DHLink l : currentArm.getLinks()) { String jointName = l.getName(); double theta = l.getTheta(); // angles between 0 - 360 degrees.. not sure what people will really want? // - 180 to + 180 ? angleMap.put(jointName, (double) MathUtils.radToDeg(theta) % 360.0F); } invoke("publishJointAngles", angleMap); // we want to publish the joint positions // this way we can render on the web gui.. double[][] jointPositionMap = createJointPositionMap(); // TODO: pass a better datastructure? invoke("publishJointPositions", (Object) jointPositionMap); } public double[][] createJointPositionMap() { return createJointPositionMap(currentArm); } public double[][] createJointPositionMap(String arm) { changeArm(arm); return createJointPositionMap(currentArm); } public double[][] createJointPositionMap(DHRobotArm arm) { double[][] jointPositionMap = new double[arm.getNumLinks() + 1][3]; // first position is the origin... second is the end of the first link jointPositionMap[0][0] = 0; jointPositionMap[0][1] = 0; jointPositionMap[0][2] = 0; for (int i = 1; i <= arm.getNumLinks(); i++) { Point jp = arm.getJointPosition(i - 1); jointPositionMap[i][0] = jp.getX(); jointPositionMap[i][1] = jp.getY(); jointPositionMap[i][2] = jp.getZ(); } return jointPositionMap; } public DHRobotArm getCurrentArm() { return currentArm; } public DHRobotArm getArm(String arm) { if (arms.containsKey(arm)) { return arms.get(arm); } else return currentArm; } public void setCurrentArm(DHRobotArm currentArm) { this.currentArm = currentArm; } public void addArm(String name, DHRobotArm currentArm) { arms.put(name, currentArm); this.currentArm = currentArm; } public static void main(String[] args) throws Exception { LoggingFactory.init(Level.INFO); Runtime.createAndStart("python", "Python"); Runtime.createAndStart("gui", "GUIService"); InverseKinematics3D inversekinematics = (InverseKinematics3D) Runtime.start("ik3d", "InverseKinematics3D"); // InverseKinematics3D inversekinematics = new InverseKinematics3D("iksvc"); inversekinematics.setCurrentArm(InMoovArm.getDHRobotArm()); // inversekinematics.getCurrentArm().setIk3D(inversekinematics); // Create a new DH Arm.. simpler for initial testing. // d , r, theta , alpha // DHRobotArm testArm = new DHRobotArm(); // testArm.addLink(new DHLink("one" ,400,0,0,90)); // testArm.addLink(new DHLink("two" ,300,0,0,90)); // testArm.addLink(new DHLink("three",200,0,0,0)); // testArm.addLink(new DHLink("two", 0,0,0,0)); // inversekinematics.setCurrentArm(testArm); // set up our input translation/rotation // // if (false) { // double dx = 400.0; // double dy = -600.0; // double dz = -350.0; // double roll = 0.0; // double pitch = 0.0; // double yaw = 0.0; // inversekinematics.createInputMatrix(dx, dy, dz, roll, pitch, yaw); // } // Rest position... // Point rest = new Point(100,-300,0,0,0,0); // rest. // inversekinematics.moveTo(rest); // LeapMotion lm = (LeapMotion)Runtime.start("leap", "LeapMotion"); // lm.addPointsListener(inversekinematics); boolean attached = true; if (attached) { // set up the left inmoov arm InMoovArm leftArm = (InMoovArm) Runtime.start("leftArm", "InMoovArm"); leftArm.connect("COM21"); // leftArm.omoplate.setMinMax(0, 180); // attach the publish joint angles to the on JointAngles for the inmoov // arm. inversekinematics.addListener("publishJointAngles", leftArm.getName(), "onJointAngles"); } // Runtime.createAndStart("gui", "GUIService"); // OpenCV cv1 = (OpenCV)Runtime.createAndStart("cv1", "OpenCV"); // OpenCVFilterAffine aff1 = new OpenCVFilterAffine("aff1"); // aff1.setAngle(270); // aff1.setDx(-80); // aff1.setDy(-80); // cv1.addFilter(aff1); // // cv1.setCameraIndex(0); // cv1.capture(); // cv1.undockDisplay(true); /* * GUIService gui = new GUIService("gui"); gui.startService(); */ Joystick joystick = (Joystick) Runtime.start("joystick", "Joystick"); joystick.setController(2); // joystick.startPolling(); // attach the joystick input to the ik3d service. joystick.addInputListener(inversekinematics); Runtime.start("webgui", "WebGui"); Runtime.start("log", "Log"); } @Override public Map<String, Double> publishJointAngles(HashMap<String, Double> angleMap) { // TODO Auto-generated method stub return angleMap; } public double[][] publishJointPositions(double[][] jointPositionMap) { return jointPositionMap; } public Point publishTracking(Point tracking) { return tracking; } @Override public void onPoints(List<Point> points) { // TODO : move input matrix translation to here? or somewhere? // TODO: also don't like that i'm going to just say take the first point // now. // TODO: points should probably be a map, each point should have a name ? moveTo(points.get(0)); } public void onJoystickInput(JoystickData input) { // a few control button pushes // Ok, lets say the the "a" button starts tracking if ("0".equals(input.id)) { log.info("Start Tracking button pushed."); startTracking(); } else if ("1".equals(input.id)) { stopTracking(); } // and the "b" button stops tracking // TODO: use the joystick input to drive the "moveTo" command. // TODO: joystick listener interface? // input.id // input.value // depending on input we want to get the current position and move in some // direction. // or potentially stay in the same place.. // we start at the origin // initially at rest. // we can set the velocities to be equal to the joystick inputs // with some gain/amplification. // Ok, so this will track the y,rx,ry inputs from the joystick as x,y,z // velocities // we want to have a minimum threshold o/w we set the value to zero // quantize float threshold = 0.1F; if (Math.abs(input.value) < threshold) { input.value = 0.0F; } double totalGain = 100.0; double xGain = totalGain; // invert y control. double yGain = -1.0 * totalGain; double zGain = totalGain; if ("x".equals(input.id)) { // x axis control (left/right) joystickLinearVelocity.setX(input.value * xGain); } else if ("y".equals(input.id)) { // y axis control (up/down) joystickLinearVelocity.setY(input.value * yGain); } if ("ry".equals(input.id)) { // z axis control (forward / backwards) joystickLinearVelocity.setZ(input.value * zGain); } // log.info("Linear Velocity : {}", joystickLinearVelocity); // on a loop I want to sample the current joystickLinearVelocity // at some interval and move the current position by the new dx,dy,dz // computed based // off the input from the joystick. // relying on the current position is probably bad. // TODO: track the desired position independently of the current position. // we will allow translation, x,y,z // for the input point. } /** * This static method returns all the details of the class without it having * to be constructed. It has description, categories, dependencies, and peer * definitions. * * @return ServiceType - returns all the data * */ static public ServiceType getMetaData() { ServiceType meta = new ServiceType(InverseKinematics3D.class.getCanonicalName()); meta.addDescription("a 3D kinematics service supporting D-H parameters"); meta.addCategory("robot", "control"); return meta; } public void setDHLink (String name, double d, double theta, double r, double alpha) { DHLink dhLink = new DHLink(name, d, r, MathUtils.degToRad(theta), MathUtils.degToRad(alpha)); currentArm.addLink(dhLink); } public void setDHLink (Servo servo, double d, double theta, double r, double alpha) { DHLink dhLink = new DHLink(servo.getName(), d, r, MathUtils.degToRad(theta), MathUtils.degToRad(alpha)); servo.addIKServoEventListener(this); currentServos.put(servo.getName(), servo); dhLink.addPositionValue(servo.getPos()); dhLink.setMin(MathUtils.degToRad(theta + Math.min(servo.getMinInput(), servo.getMaxInput()))); dhLink.setMax(MathUtils.degToRad(theta + Math.max(servo.getMaxInput(), servo.getMinInput()))); currentArm.addLink(dhLink); } public void setDHLink (String armName, String name, double d, double theta, double r, double alpha) { changeArm(armName); setDHLink(name, d, theta, r, alpha); } public void setDHLink (String armName, Servo servo, double d, double theta, double r, double alpha) { changeArm(armName); setDHLink(servo, d, theta, r, alpha); } public void setNewDHRobotArm() { currentArm = new DHRobotArm(); } public void moveTo(int x , int y, int z, int roll, int pitch, int yaw) { moveTo(new Point(x, y, z, roll, pitch, yaw)); } public void moveTo(int x, int y, int z) { Point goTo = new Point((double)x,(double)y,(double)z,0.0,0.0,0.0); moveTo(goTo); } public void moveTo(String arm, int x, int y, int z) { changeArm(arm); moveTo(x, y, z); } @Override public void calcFitness(ArrayList<Chromosome> pool) { for (Chromosome chromosome : pool) { DHRobotArm arm = new DHRobotArm(); double fitnessMult = 1; double fitnessTime = 0; for (int i = 0; i < currentArm.getNumLinks(); i++){ //copy the value of the currentArm DHLink newLink = new DHLink(currentArm.getLink(i)); newLink.addPositionValue((double)chromosome.getDecodedGenome().get(i)); Double delta = currentArm.getLink(i).getPositionValueDeg() - (Double)chromosome.getDecodedGenome().get(i); double timeOfMove = Math.abs(delta / currentServos.get(currentArm.getLink(i).getName()).getVelocity()); if (timeOfMove > fitnessTime) { fitnessTime = timeOfMove; } arm.addLink(newLink); } if (geneticComputeSimulation) { //work well but long computing time arm = simulateMove(chromosome.getDecodedGenome()); } Point potLocation = arm.getPalmPosition(); Double distance = potLocation.distanceTo(goTo); //not sure about weight for roll/pitch/yaw. adding a wrist will probably help // double dRoll = (potLocation.getRoll() - goTo.getRoll())/360; // fitnessMult*=(1-dRoll)*10000; // double dPitch = (potLocation.getPitch() - goTo.getPitch())/360; // fitnessMult*=(1-dPitch)*10000; // double dYaw = (potLocation.getYaw() - goTo.getYaw())/360; // fitnessMult*=(1-dYaw)*10000; if (fitnessTime < 0.1) { fitnessTime = 0.1; } //fitness is the score showing how close the results is to the target position Double fitness = (fitnessMult/distance*1000);// + (1/fitnessTime*.01); if (fitness < 0) fitness *=-1; chromosome.setFitness(fitness); } return; } // convert the genetic algorythm to the data we want to use @Override public void decode(ArrayList<Chromosome> chromosomes) { // TODO Auto-generated method stub for (Chromosome chromosome : chromosomes ){ int pos=0; ArrayList<Object>decodedGenome = new ArrayList<Object>(); for (DHLink link: currentArm.getLinks()){ Double value=0.0; for (int i= pos; i< chromosome.getGenome().length() && i < pos+8; i++){ if(chromosome.getGenome().charAt(i) == '1') value += 1 << i-pos; } pos += 8; if (value < MathUtils.radToDeg(link.getMin()-link.getInitialTheta())) value = link.getPositionValueDeg(); if (value > MathUtils.radToDeg(link.getMax()-link.getInitialTheta())) value = link.getPositionValueDeg(); decodedGenome.add(value); } chromosome.setDecodedGenome(decodedGenome); } } private DHRobotArm simulateMove(ArrayList<Object> decodedGenome) { // simulate movement of the servos in time to get an approximation of their position time = 0.1; boolean isMoving = true; DHRobotArm oldArm = currentArm; // stop simulating when all servo reach position while (isMoving) { isMoving = false; DHRobotArm newArm = new DHRobotArm(); for (int i = 0; i < currentArm.getNumLinks(); i++) { DHLink newLink = new DHLink(currentArm.getLink(i)); double degrees = currentArm.getLink(i).getPositionValueDeg(); double deltaDegree = java.lang.Math.abs(degrees - (Double)decodedGenome.get(i)); double deltaDegree2 = time * (Integer)currentServos.get(currentArm.getLink(i).getName()).getVelocity(); if (deltaDegree >= deltaDegree2) { deltaDegree = deltaDegree2; isMoving = true; } if (degrees > ((Double)decodedGenome.get(i)).intValue()) { degrees -= deltaDegree; } else if (degrees < ((Double)decodedGenome.get(i)).intValue()) { degrees += deltaDegree; } newLink.addPositionValue( degrees); newArm.addLink(newLink); } double[][] jp = createJointPositionMap(newArm); //send data to the collision detector class for (int i = 0; i < currentArm.getNumLinks(); i++) { CollisionItem ci = new CollisionItem(new Point(jp[i][0], jp[i][1], jp[i][2], 0 , 0, 0), new Point(jp[i+1][0], jp[i+1][1], jp[i+1][2], 0, 0, 0), currentArm.getLink(i).getName()); if (i != currentArm.getNumLinks()-1) { ci.addIgnore(currentArm.getLink(i+1).getName()); } collisionItems.addItem(ci); } collisionItems.runTest(); if (collisionItems.haveCollision() ){ //log.info("Collision at {} - {}", collisionItems.getCollisionPoint()[0], collisionItems.getCollisionPoint()[1]); return oldArm; } oldArm = newArm; //log.info("time: {} Position:{}", ((Double)time).floatValue(), newArm.getPalmPosition().toString()); //log.info("collision: {}", collisionItems.haveCollision()); for (int i = 1; i < jp.length; i++){ //log.info("jp:{} {} - {} - {}", newArm.getLink(i-1).getName(), ((Double)jp[i][0]).intValue(), ((Double)jp[i][1]).intValue(), ((Double)jp[i][2]).intValue()); } time += 0.2; } return oldArm; } public String addObject(double oX, double oY, double oZ, double eX, double eY, double eZ, String name, double radius) { return addObject(new Point(oX, oY, oZ, 0, 0, 0), new Point(eX, eY, eZ, 0, 0, 0), name, radius); } public String addObject(Point origin, Point end, String name, double radius) { CollisionItem item = new CollisionItem(origin, end, name, radius); collisionItems.addItem(item); return item.getName(); } public String addObject(String name, double radius) { return addObject(new Point(0, 0, 0, 0, 0, 0), new Point(0, 0, 0, 0, 0, 0), name, radius); } public void clearObject(){ collisionItems.clearItem(); } public void setComputeMethodPSIJacobian() { computeMethod = IK_COMPUTE_METHOD_PI_JACOBIAN; } public void setComputeMethodGeneticAlgorythm() { computeMethod = IK_COMPUTE_METHOD_GENETIC_ALGORYTHM; } public void setGeneticPoolSize(int size) { geneticPoolSize = size; } public void setGeneticMutationRate(double rate) { geneticMutationRate = rate; } public void setGeneticRecombinationRate(double rate) { geneticRecombinationRate = rate; } public void setGeneticGeneration(int generation) { geneticGeneration = generation; } public void setGeneticComputeSimulation(boolean compute) { geneticComputeSimulation = compute; } public void objectAddIgnore(String object1, String object2) { collisionItems.addIgnore(object1, object2); } public void onIKServoEvent(IKData data) { for (DHLink l: currentArm.getLinks()) { if (l.getName().equals(data.name)){ l.addPositionValue(data.pos.doubleValue()); } } } }
tspence/lockstep-sdk-ruby
lib/lockstep_sdk/clients/provisioning_client.rb
# # Lockstep Platform SDK for Ruby # # (c) 2021-2022 Lockstep, Inc. # # For the full copyright and license information, please view the LICENSE # file that was distributed with this source code. # # @author <NAME> <<EMAIL>> # @copyright 2021-2022 Lockstep, Inc. # @link https://github.com/Lockstep-Network/lockstep-sdk-ruby # require 'awrence' class ProvisioningClient ## # Initialize the ProvisioningClient class with an API client instance. # @param connection [LockstepApi] The API client object for this connection def initialize(connection) @connection = connection end ## # Creates a new User or updates an Invited user based on metadata provided by the User during the onboarding process # # @param body [ProvisioningModel] Represents a User and their related metadata def provision_user_account(body:) path = "/api/v1/Provisioning" @connection.request(:post, path, body, nil) end ## # Updates user, company and group metadata for a User of status 'Onboarding' and finalizes a user's onboarding process by changing the user status to 'Active' # # @param body [ProvisioningFinalizeRequestModel] Represents a User and their related metadata def finalize_user_account_provisioning(body:) path = "/api/v1/Provisioning/finalize" @connection.request(:post, path, body, nil) end ## # Creates a new account for a developer, sending an email with information on how to access the API. # @param body [DeveloperAccountSubmitModel] def provision_free_developer_account(body:) path = "/api/v1/Provisioning/free-account" @connection.request(:post, path, body, nil) end end
nikulinn/angular-gulp
node_modules/popsicle/dist/plugins/common.js
<reponame>nikulinn/angular-gulp "use strict"; var FormData = require("form-data"); var querystring_1 = require("querystring"); var index_1 = require("./is-host/index"); var form_1 = require("../form"); var JSON_MIME_REGEXP = /^application\/(?:[\w!#\$%&\*`\-\.\^~]*\+)?json$/i; var URL_ENCODED_MIME_REGEXP = /^application\/x-www-form-urlencoded$/i; var FORM_MIME_REGEXP = /^multipart\/form-data$/i; var JSON_PROTECTION_PREFIX = /^\)\]\}',?\n/; function wrap(value) { return function () { return value; }; } exports.wrap = wrap; exports.headers = wrap(function (request, next) { if (!request.get('Accept')) { request.set('Accept', '*/*'); } request.remove('Host'); return next(); }); exports.stringify = wrap(function (request, next) { var body = request.body; if (Object(body) !== body) { request.body = body == null ? null : String(body); return next(); } if (index_1.default(body)) { return next(); } var type = request.type(); if (!type) { type = 'application/json'; request.type(type); } try { if (JSON_MIME_REGEXP.test(type)) { request.body = JSON.stringify(body); } else if (FORM_MIME_REGEXP.test(type)) { request.body = form_1.default(body); } else if (URL_ENCODED_MIME_REGEXP.test(type)) { request.body = querystring_1.stringify(body); } } catch (err) { return Promise.reject(request.error('Unable to stringify request body: ' + err.message, 'ESTRINGIFY', err)); } if (request.body instanceof FormData) { request.remove('Content-Type'); } return next(); }); function parse(type, strict) { var types = Array.isArray(type) ? type : [type]; for (var _i = 0, types_1 = types; _i < types_1.length; _i++) { var type_1 = types_1[_i]; if (type_1 !== 'json' && type_1 !== 'urlencoded') { throw new TypeError("Unexpected parse type: " + type_1); } } return function (request, next) { return next() .then(function (response) { var body = response.body; var responseType = response.type(); if (body == null || body === '') { response.body = null; return response; } if (responseType == null) { throw request.error("Unable to parse empty response content type", 'EPARSE'); } if (typeof body !== 'string') { throw request.error("Unable to parse non-string response body", 'EPARSE'); } for (var _i = 0, types_2 = types; _i < types_2.length; _i++) { var type_2 = types_2[_i]; if (type_2 === 'json' && JSON_MIME_REGEXP.test(responseType)) { try { response.body = JSON.parse(body.replace(JSON_PROTECTION_PREFIX, '')); } catch (err) { throw request.error("Unable to parse response body: " + err.message, 'EPARSE', err); } return response; } if (type_2 === 'urlencoded' && URL_ENCODED_MIME_REGEXP.test(responseType)) { response.body = querystring_1.parse(body); return response; } } if (strict !== false) { throw request.error("Unhandled response type: " + responseType, 'EPARSE'); } return response; }); }; } exports.parse = parse; //# sourceMappingURL=common.js.map
piougy/CzechIdMng
Realization/backend/core/core-impl/src/test/java/eu/bcvsolutions/idm/core/eav/service/impl/IdmFormValueControllerRestTest.java
package eu.bcvsolutions.idm.core.eav.service.impl; import org.junit.Assert; import org.junit.Test; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.security.core.Authentication; import com.google.common.collect.Lists; import eu.bcvsolutions.idm.core.api.dto.AbstractDto; import eu.bcvsolutions.idm.core.api.dto.IdmIdentityContractDto; import eu.bcvsolutions.idm.core.api.dto.IdmIdentityDto; import eu.bcvsolutions.idm.core.api.dto.IdmRoleDto; import eu.bcvsolutions.idm.core.api.dto.IdmTreeNodeDto; import eu.bcvsolutions.idm.core.api.entity.AbstractEntity; import eu.bcvsolutions.idm.core.api.service.IdmIdentityService; import eu.bcvsolutions.idm.core.eav.api.domain.PersistentType; import eu.bcvsolutions.idm.core.eav.api.dto.IdmFormAttributeDto; import eu.bcvsolutions.idm.core.eav.api.dto.IdmFormDefinitionDto; import eu.bcvsolutions.idm.core.eav.api.service.FormService; import eu.bcvsolutions.idm.core.model.entity.IdmIdentity; import eu.bcvsolutions.idm.core.model.entity.IdmIdentityContract; import eu.bcvsolutions.idm.core.model.entity.IdmRole; import eu.bcvsolutions.idm.core.model.entity.IdmTreeNode; import eu.bcvsolutions.idm.core.security.api.domain.GuardedString; import eu.bcvsolutions.idm.core.security.api.domain.IdmJwtAuthentication; import eu.bcvsolutions.idm.core.security.api.utils.IdmAuthorityUtils; import eu.bcvsolutions.idm.test.api.AbstractRestTest; import eu.bcvsolutions.idm.test.api.TestHelper; /** * For values agenda tests * * @author <NAME> * @author <NAME> */ public class IdmFormValueControllerRestTest extends AbstractRestTest { @Autowired private IdmIdentityService identityService; @Autowired private FormService formService; private Authentication getAuthentication() { return new IdmJwtAuthentication(identityService.getByUsername(TestHelper.ADMIN_USERNAME), null, Lists.newArrayList(IdmAuthorityUtils.getAdminAuthority()), "core"); } @Test public void findValues() throws Exception { IdmIdentityDto ownerIdentity = getHelper().createIdentity((GuardedString) null); IdmRoleDto ownerRole = getHelper().createRole(); IdmIdentityContractDto ownerIdentityContract = getHelper().createContract(ownerIdentity); IdmTreeNodeDto ownerTreeNode = null; try { getHelper().loginAdmin(); ownerTreeNode = getHelper().createTreeNode(); } finally { logout(); } // Assert.assertEquals(1, prepareDataAndSearch(IdmIdentity.class, ownerIdentity)); Assert.assertEquals(1, prepareDataAndSearch(IdmRole.class, ownerRole)); Assert.assertEquals(1, prepareDataAndSearch(IdmTreeNode.class, ownerTreeNode)); Assert.assertEquals(1, prepareDataAndSearch(IdmIdentityContract.class, ownerIdentityContract)); } private int prepareDataAndSearch(Class<? extends AbstractEntity> type, AbstractDto owner) throws Exception { // create attribute IdmFormAttributeDto attribute = new IdmFormAttributeDto(); String attributeName = "name_" + System.currentTimeMillis(); attribute.setCode(attributeName); attribute.setName(attribute.getCode()); attribute.setPersistentType(PersistentType.SHORTTEXT); // create definition IdmFormDefinitionDto definition = formService.createDefinition(type, getHelper().createName(), Lists.newArrayList(attribute)); attribute = definition.getMappedAttributeByCode(attribute.getCode()); // save value formService.saveValues(owner.getId(), type, attribute, Lists.newArrayList("one")); String response = getJsonAsString("/form-values", "definitionId=" + definition.getId(), 20l, 0l, null, null, getAuthentication()); return getEmbeddedList("formValues", response).size(); } }
Blocks-Editor/blocks
src/editor/useCases.js
export const USE_CASES = []; export const FOR_LEARNING_MOTOKO = addUseCase('learning Motoko'); export const FOR_BUILDING_API = addUseCase('building an API'); export const FOR_STORING_DATA = addUseCase('storing data'); export const FOR_TRANSACTIONS = addUseCase('transaction logic'); export const FOR_REUSABLE_LOGIC = addUseCase('reusable logic'); export const FOR_ORGANIZATION = addUseCase('project organization'); export const FOR_ASSIGNING_ID = addUseCase('assigning unique IDs'); export const FOR_DOCUMENTATION = addUseCase('documentation'); export const FOR_CONFIGURATION = addUseCase('configuration'); export const FOR_DEBUGGING = addUseCase('debugging'); export const FOR_ERROR_HANDLING = addUseCase('error handling'); export const FOR_CUSTOM_LOGIC = addUseCase('custom logic'); export const FOR_VALIDATION = addUseCase('validation'); export const FOR_TESTING = addUseCase('testing'); function addUseCase(useCase) { USE_CASES.push(useCase); return useCase; }
KenG98/magma
lte/gateway/c/oai/tasks/nas/emm/sap/emm_cnDef.h
<gh_stars>0 /* * Licensed to the OpenAirInterface (OAI) Software Alliance under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. * The OpenAirInterface Software Alliance licenses this file to You under * the Apache License, Version 2.0 (the "License"); you may not use this file * except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. *------------------------------------------------------------------------------- * For more information about the OpenAirInterface (OAI) Software Alliance: * <EMAIL> */ /***************************************************************************** Source emm_cnDef.h Version 0.1 Date 2013/12/05 Product NAS stack Subsystem EPS Core Network Author <NAME>, <NAME> Description *****************************************************************************/ #ifndef FILE_EMM_CNDEF_SEEN #define FILE_EMM_CNDEF_SEEN #include "intertask_interface_types.h" #include "nas/as_message.h" #include "common_ies.h" #include "LocationAreaIdentification.h" typedef enum emmcn_primitive_s { _EMMCN_START = 400, _EMMCN_AUTHENTICATION_PARAM_RES, _EMMCN_AUTHENTICATION_PARAM_FAIL, _EMMCN_DEREGISTER_UE, _EMMCN_PDN_CONFIG_RES, // LG _EMMCN_PDN_CONNECTIVITY_RES, // LG _EMMCN_PDN_CONNECTIVITY_FAIL, // LG _EMMCN_ACTIVATE_DEDICATED_BEARER_REQ, // LG _EMMCN_IMPLICIT_DETACH_UE, _EMMCN_SMC_PROC_FAIL, _EMMCN_NW_INITIATED_DETACH_UE, _EMMCN_CS_DOMAIN_LOCATION_UPDT_ACC, _EMMCN_CS_DOMAIN_LOCATION_UPDT_FAIL, _EMMCN_CS_DOMAIN_MM_INFORMATION_REQ, _EMMCN_DEACTIVATE_BEARER_REQ, // LG _EMMCN_END } emm_cn_primitive_t; typedef struct emm_cn_auth_res_s { /* UE identifier */ mme_ue_s1ap_id_t ue_id; /* For future use: nb of vectors provided */ uint8_t nb_vectors; /* Consider only one E-UTRAN vector for the moment... */ eutran_vector_t *vector[MAX_EPS_AUTH_VECTORS]; } emm_cn_auth_res_t; typedef struct emm_cn_auth_fail_s { /* UE identifier */ mme_ue_s1ap_id_t ue_id; /* S6A mapped to NAS cause */ nas_cause_t cause; } emm_cn_auth_fail_t; struct itti_nas_pdn_config_rsp_s; struct itti_nas_pdn_connectivity_rsp_s; struct itti_nas_pdn_connectivity_fail_s; struct itti_mme_app_create_dedicated_bearer_req_s; typedef struct itti_nas_pdn_config_rsp_s emm_cn_pdn_config_res_t; typedef struct itti_nas_pdn_connectivity_rsp_s emm_cn_pdn_res_t; typedef struct itti_nas_pdn_connectivity_fail_s emm_cn_pdn_fail_t; typedef struct itti_mme_app_create_dedicated_bearer_req_s emm_cn_activate_dedicated_bearer_req_t; typedef struct itti_mme_app_delete_dedicated_bearer_req_s emm_cn_deactivate_dedicated_bearer_req_t; typedef struct emm_cn_deregister_ue_s { uint32_t ue_id; } emm_cn_deregister_ue_t; typedef struct emm_cn_implicit_detach_ue_s { uint32_t ue_id; } emm_cn_implicit_detach_ue_t; typedef struct emm_cn_smc_fail_s { mme_ue_s1ap_id_t ue_id; nas_cause_t emm_cause; } emm_cn_smc_fail_t; typedef struct emm_cn_nw_initiated_detach_ue_s { uint32_t ue_id; uint8_t detach_type; } emm_cn_nw_initiated_detach_ue_t; typedef itti_nas_cs_domain_location_update_acc_t emm_cn_cs_domain_location_updt_acc_t; typedef itti_nas_cs_domain_location_update_fail_t emm_cn_cs_domain_location_updt_fail_t; typedef itti_sgsap_mm_information_req_t emm_cn_cs_domain_mm_information_req_t; typedef struct emm_mme_ul_s { emm_cn_primitive_t primitive; union { emm_cn_auth_res_t *auth_res; emm_cn_auth_fail_t *auth_fail; emm_cn_deregister_ue_t deregister; emm_cn_pdn_config_res_t *emm_cn_pdn_config_res; emm_cn_pdn_res_t *emm_cn_pdn_res; emm_cn_pdn_fail_t *emm_cn_pdn_fail; emm_cn_activate_dedicated_bearer_req_t *activate_dedicated_bearer_req; emm_cn_deactivate_dedicated_bearer_req_t *deactivate_dedicated_bearer_req; emm_cn_implicit_detach_ue_t emm_cn_implicit_detach; emm_cn_smc_fail_t *smc_fail; emm_cn_nw_initiated_detach_ue_t emm_cn_nw_initiated_detach; emm_cn_cs_domain_location_updt_acc_t emm_cn_cs_domain_location_updt_acc; emm_cn_cs_domain_location_updt_fail_t emm_cn_cs_domain_location_updt_fail; emm_cn_cs_domain_mm_information_req_t *emm_cn_cs_domain_mm_information_req; } u; } emm_cn_t; #endif /* FILE_EMM_CNDEF_SEEN */
Bladez1753/lightning
common/billboard.h
<gh_stars>1000+ #ifndef LIGHTNING_COMMON_BILLBOARD_H #define LIGHTNING_COMMON_BILLBOARD_H #include "config.h" #include <ccan/ccan/tal/tal.h> #include <common/htlc.h> char *billboard_message(const tal_t *ctx, const bool funding_locked[NUM_SIDES], const bool have_sigs[NUM_SIDES], const bool shutdown_sent[NUM_SIDES], u32 depth_togo, size_t num_htlcs); #endif /* LIGHTNING_COMMON_BILLBOARD_H */
Tahul/flamingo
src/theme.js
<filename>src/theme.js export const theme = { borderRadius: { xl: 'var(--f-borderRadius--xl)', l: 'var(--f-borderRadius--l)', m: 'var(--f-borderRadius--m)', s: 'var(--f-borderRadius--s)', }, breakPoint: { sUp: '@media (min-width: 460px)', s: '@media (max-width: 460px)', m: '@media (min-width: 460px) and (max-width: 800px)', l: '@media (min-width: 1100px)', }, color: { brand: { primary: 'var(--f-color-brandPrimary)', primaryLight: 'var(--f-color-brandPrimary--light)', primaryInactive: 'var(--f-color-brandPrimary--inactive)', secondary: 'var(--f-color-brandSecondary)', secondaryLight: 'var(--f-color-brandSecondary--light)', }, icon: { white: 'var(--f-color-icon--white)', disabled: 'var(--f-color-icon--disabled)', dark: 'var(--f-color-icon--dark)', }, element: { primary: 'var(--f-color-element--primary)', secondary: 'var(--f-color-element--secondary)', tertiary: 'var(--f-color-element--tertiary)', inactive: 'var(--f-color-element--inactive)', error: 'var(--f-color-element--error)', success: 'var(--f-color-element--success)', overlay: 'var(--f-color-element--overlay)', }, text: { primary: 'var(--f-color-text--primary)', secondary: 'var(--f-color-text--secondary)', tertiary: 'var(--f-color-text--tertiary)', link: 'var(--f-color-text--link)', white: 'var(--f-color-text--white)', lightGrey: 'var(--f-color-text--lightGrey)', }, }, fontSize: { xxs: 'var(--f-fontSize--xxs)', xs: 'var(--f-fontSize--xs)', s: 'var(--f-fontSize--s)', m: 'var(--f-fontSize--m)', l: 'var(--f-fontSize--l)', xl: 'var(--f-fontSize--xl)', xxl: 'var(--f-fontSize--xxl)', }, fontWeight: { normal: 'var(--f-fontWeight--normal)', bold: 'var(--f-fontWeight--bold)', black: 'var(--f-fontWeight--black)', }, iconSize: { s: 'var(--f-iconSize--s)', m: 'var(--f-iconSize--m)', l: 'var(--f-iconSize--l)', }, lineHeight: { s: 'var(--f-lineHeight--s)', m: 'var(--f-lineHeight--m)', l: 'var(--f-lineHeight--l)', xl: 'var(--f-lineHeight--xl)', }, space: { s: 'var(--f-space--s)', m: 'var(--f-space--m)', l: 'var(--f-space--l)', xl: 'var(--f-space--xl)', xxl: 'var(--f-space--xxl)', }, zIndex: { overlay: 'var(--f-zIndex--Overlay)', }, };
mmienko/aws-cdk-scala
modules/ec2/src/main/scala/io/burkard/cdk/services/ec2/CfnVPCCidrBlockProps.scala
package io.burkard.cdk.services.ec2 @SuppressWarnings(Array("org.wartremover.warts.DefaultArguments", "org.wartremover.warts.Null", "DisableSyntax.null")) object CfnVPCCidrBlockProps { def apply( vpcId: String, amazonProvidedIpv6CidrBlock: Option[Boolean] = None, ipv6Pool: Option[String] = None, cidrBlock: Option[String] = None, ipv6CidrBlock: Option[String] = None ): software.amazon.awscdk.services.ec2.CfnVPCCidrBlockProps = (new software.amazon.awscdk.services.ec2.CfnVPCCidrBlockProps.Builder) .vpcId(vpcId) .amazonProvidedIpv6CidrBlock(amazonProvidedIpv6CidrBlock.map(Boolean.box).getOrElse(java.lang.Boolean.FALSE)) .ipv6Pool(ipv6Pool.orNull) .cidrBlock(cidrBlock.orNull) .ipv6CidrBlock(ipv6CidrBlock.orNull) .build() }
jese1987/Dipper-Protocol
x/vm/types/keys.go
<filename>x/vm/types/keys.go<gh_stars>1-10 package types const ( // ModuleName is the name of the vm module ModuleName = "vm" // StoreKey is the string store representation StoreKey = ModuleName CodeKey = StoreKey + "_code" LogKey = StoreKey + "_log" StoreDebugKey = StoreKey + "_debug" // QuerierRoute is the querier route for the vm module QuerierRoute = ModuleName // RouterKey is the msg router key for the vm module RouterKey = ModuleName ) var ( LogIndexKey = []byte("logIndexKey") )
JaneMandy/CS
org/w3c/css/sac/Selector.java
<gh_stars>1-10 package org.w3c.css.sac; public interface Selector { short SAC_CONDITIONAL_SELECTOR = 0; short SAC_ANY_NODE_SELECTOR = 1; short SAC_ROOT_NODE_SELECTOR = 2; short SAC_NEGATIVE_SELECTOR = 3; short SAC_ELEMENT_NODE_SELECTOR = 4; short SAC_TEXT_NODE_SELECTOR = 5; short SAC_CDATA_SECTION_NODE_SELECTOR = 6; short SAC_PROCESSING_INSTRUCTION_NODE_SELECTOR = 7; short SAC_COMMENT_NODE_SELECTOR = 8; short SAC_PSEUDO_ELEMENT_SELECTOR = 9; short SAC_DESCENDANT_SELECTOR = 10; short SAC_CHILD_SELECTOR = 11; short SAC_DIRECT_ADJACENT_SELECTOR = 12; short getSelectorType(); }
DaokoHu/itmp
src/main/java/com/huadi/itmp/core/lock/RedisLockFactory.java
package com.huadi.itmp.core.lock; import org.springframework.data.redis.core.StringRedisTemplate; import java.util.concurrent.locks.Lock; /** * @author meteor */ public class RedisLockFactory { private StringRedisTemplate redisTemplate; public RedisLockFactory(StringRedisTemplate redisTemplate) { this.redisTemplate = redisTemplate; } public Lock createLock(String lockKey) { return new RedisLock(redisTemplate, lockKey); } }
adas2/swtpm_1.2
libtpm/lib/tpmutil_libtpms.c
/********************************************************************************/ /* */ /* TPM LibTPMS Interface Functions */ /* Written by <NAME> */ /* IBM <NAME> Research Center */ /* $Id: tpmutil_libtpms.c 4752 2015-09-25 23:30:23Z kgoldman $ */ /* */ /* (c) Copyright IBM Corporation 2006, 2010. */ /* */ /* All rights reserved. */ /* */ /* Redistribution and use in source and binary forms, with or without */ /* modification, are permitted provided that the following conditions are */ /* met: */ /* */ /* Redistributions of source code must retain the above copyright notice, */ /* this list of conditions and the following disclaimer. */ /* */ /* Redistributions in binary form must reproduce the above copyright */ /* notice, this list of conditions and the following disclaimer in the */ /* documentation and/or other materials provided with the distribution. */ /* */ /* Neither the names of the IBM Corporation nor the names of its */ /* contributors may be used to endorse or promote products derived from */ /* this software without specific prior written permission. */ /* */ /* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS */ /* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT */ /* LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR */ /* A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT */ /* HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, */ /* SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT */ /* LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, */ /* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY */ /* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT */ /* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE */ /* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ /********************************************************************************/ #ifdef TPM_USE_LIBTPMS #include <stdio.h> #include <string.h> #include <stdlib.h> #include "tpm_types.h" #include "tpm_error.h" #ifdef USE_IN_TREE_LIBTPMS #include "../../../src/tpm_library.h" #else #include <libtpms/tpm_library.h> #endif #include "tpmutil.h" #include "tpm_lowlevel.h" static uint32_t TPM_OpenLibTPMS(int *sockfd); static uint32_t TPM_CloseLibTPMS(int sockfd); static uint32_t TPM_SendLibTPMS(int sockfd, struct tpm_buffer *tb, const char *msg); static uint32_t TPM_ReceiveLibTPMS(int sockfd, struct tpm_buffer *tb); static struct tpm_transport libtpms_transport = { .open = TPM_OpenLibTPMS, .close = TPM_CloseLibTPMS, .send = TPM_SendLibTPMS, .recv = TPM_ReceiveLibTPMS, }; void TPM_LowLevel_TransportLibTPMS_Set(void) { TPM_LowLevel_Transport_Set(&libtpms_transport); } /* * Functions that implement the transport */ static uint32_t TPM_OpenLibTPMS(int *sockfd) { (void)sockfd; return 0; } static uint32_t TPM_CloseLibTPMS(int sockfd) { (void)sockfd; return 0; } static uint32_t TPM_SendLibTPMS(int sockfd, struct tpm_buffer *tb, const char *msg) { unsigned char *respbuffer = NULL; uint32_t resp_size; uint32_t respbufsize; uint32_t rc; char mymsg[1024]; (void)sockfd; snprintf(mymsg, sizeof(mymsg), "TPM_SendLibTPMS: To TPM [%s]", msg); showBuff(tb->buffer, mymsg); rc = TPMLIB_Process(&respbuffer, &resp_size, &respbufsize, tb->buffer, tb->used); if (rc != TPM_SUCCESS) return ERR_IO; if (tb->size < resp_size) return ERR_BUFFER; memcpy(tb->buffer, respbuffer, resp_size); tb->used = resp_size; free(respbuffer); snprintf(mymsg, sizeof(mymsg), "TPM_SendLibTPMS: From TPM [%s]", msg); showBuff(tb->buffer, mymsg); return 0; } static uint32_t TPM_ReceiveLibTPMS(int sockfd, struct tpm_buffer *tb) { /* * Doing everything in the transmit function */ (void)sockfd; (void)tb; return 0; } #endif /* TPM_USE_LIBTPMS */
treech/AndroidSdk
ui/src/main/java/io/github/treech/ui/widget/layout/linkage/LinkageScrollHandler.java
package io.github.treech.ui.widget.layout.linkage; import android.view.View; /** * 子布局向 LinkageScrollLayout {@link LinkageScrollLayout} 提供的滚动处理实现接口 * * @since 2020/3/11 5:46 PM */ public interface LinkageScrollHandler { /** * fling(抛,快速滑动后产生的动作) target with a velocity(速度) * * @param target * @param velocityY */ void flingContent(View target, int velocityY); /** * 滚动到顶部 */ void scrollContentToTop(); /** * 滚动到底部 */ void scrollContentToBottom(); /** * 停止滚动 * * @param target */ void stopContentScroll(View target); /** * 是否可以垂直滚动 * * @param direction * @return */ boolean canScrollVertically(int direction); /** * 子布局是否可滚动 * * @return */ boolean isScrollable(); /** * 获取垂直滚动条的大小 * * @return extent */ int getVerticalScrollExtent(); /** * 获取垂直滚动条在垂直范围内的偏移 * * @return extent */ int getVerticalScrollOffset(); /** * 获取垂直滚动条的滚动范围 * * @return extent */ int getVerticalScrollRange(); }
ashishfarmer/rocm-caffe2
caffe2/operators/negative_op_hip.cc
/** * Copyright (c) 2016-present, Facebook, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #include "caffe2/core/context_hip.h" #include "caffe2/operators/elementwise_op.h" #include "hip/hip_runtime.h" namespace caffe2 { template <typename T> __global__ void NegativeKernel(const int N, const T* x, T* y) { HIP_1D_KERNEL_LOOP(i, N) { y[i] = -x[i]; } } struct NegativeCUDAFunctor { template <typename T> inline void operator()(const int n, const T* x, T* y, HIPContext* device_context) { hipLaunchKernelGGL((NegativeKernel<T>), dim3(CAFFE_GET_BLOCKS(n)), dim3(CAFFE_HIP_NUM_THREADS), 0, device_context->hip_stream(), n, x, y); return; } }; REGISTER_HIP_OPERATOR( Negative, UnaryElementwiseOp<TensorTypes<float, double, int, long>, HIPContext, NegativeCUDAFunctor>); } // namespace caffe2
kabbi/zanzarah-tools
src/utils/paths.js
<gh_stars>10-100 exports.CommonPaths = { Resources: 'Resources', Pack: 'Pack', Worlds: 'Pack/WORLDS', ActorModels: 'Pack/MODELS/ACTORSEX', BackdropModels: 'Pack/MODELS/BACKDROPS', StaticModels: 'Pack/MODELS/MODELS', Textures: 'Pack/TEXTURES', ActorTextures: 'Pack/TEXTURES/ACTORSEX', BackdropTextures: 'Pack/TEXTURES/BACKDROPS', EffectTextures: 'Pack/TEXTURES/EFFECTS', MiscTextures: 'Pack/TEXTURES/MISC', StaticTextures: 'Pack/TEXTURES/MODELS', WorldTextures: 'Pack/TEXTURES/WORLDS', }; exports.getRootPath = () => { if (global.window) { const { hostname } = window.location; return `http://${hostname}:4343/`; } if (!process.env.ZANZARAH_ROOT) { throw new Error('You must specify zanzarah root path in ZANZARAH_ROOT env var'); } return process.env.ZANZARAH_ROOT; };
devibizsys/unip
srv_unip_pub/src/main/java/com/sa/unip/srv/counter/MobCountCounterHandler.java
/** * iBizSys 5.0 机器人生产代码(不要直接修改当前代码) * http://www.ibizsys.net */ package com.sa.unip.srv.counter; import net.ibizsys.paas.demodel.IDataEntityModel; import net.ibizsys.paas.demodel.DEModelGlobal; import net.ibizsys.paas.ctrlhandler.CounterGlobal; /** * 移动端计数器计数器处理基类 */ public class MobCountCounterHandler extends net.ibizsys.paas.ctrlhandler.CustomCounterHandlerBase { public MobCountCounterHandler() { super(); this.setId("A2788F84-01B1-442F-BA42-9D0A6440A443"); this.setName("移动端计数器"); CounterGlobal.registerCounterHandler("com.sa.unip.srv.counter.MobCountCounterHandler", this); CounterGlobal.registerCounterHandler("A2788F84-01B1-442F-BA42-9D0A6440A443", this); } protected void onInit() throws Exception { super.onInit(); } }
mattfoster/matplotlib
examples/pylab_examples/logo.py
<gh_stars>1-10 #!/usr/bin/env python # This file generates the matplotlib web page logo from pylab import * # convert data to mV x = 1000*0.1*fromstring( file('../data/membrane.dat', 'rb').read(), float32) # 0.0005 is the sample interval t = 0.0005*arange(len(x)) figure(1, figsize=(7,1), dpi=100) ax = subplot(111, axisbg='y') plot(t, x) text(0.5, 0.5,'matplotlib', color='r', fontsize=40, fontname='Courier', horizontalalignment='center', verticalalignment='center', transform = ax.transAxes, ) axis([1, 1.72,-60, 10]) setp(gca(), 'xticklabels', []) setp(gca(), 'yticklabels', []) #savefig('logo2.png', dpi=300) show()
letin97/EventApp
app/src/main/java/com/uit/letrongtin/eventapp/Interface/CheckItemClickListener.java
package com.uit.letrongtin.eventapp.Interface; import android.view.View; public interface CheckItemClickListener { void onClick(View view, int position, boolean ischeck, String name); }
Rillke/opencast
modules/common/src/main/java/org/opencastproject/util/data/Throwables.java
/** * Licensed to The Apereo Foundation under one or more contributor license * agreements. See the NOTICE file distributed with this work for additional * information regarding copyright ownership. * * * The Apereo Foundation licenses this file to you under the Educational * Community 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://opensource.org/licenses/ecl2.txt * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the * License for the specific language governing permissions and limitations under * the License. * */ package org.opencastproject.util.data; import static org.opencastproject.util.data.functions.Misc.chuck; public final class Throwables { private Throwables() { } /** * Forward exception <code>t</code> directly or wrap it into an instance of <code>wrapper</code> * if it is not of the wrapper's type. Class <code>wrapper</code> needs a constructor taking just * a {@link Throwable}. */ public static <T extends Throwable, A> A forward(Throwable t, Class<T> wrapper) throws T { if (wrapper.isAssignableFrom(t.getClass())) { throw (T) t; } else { try { throw wrapper.getConstructor(Exception.class).newInstance(t); } catch (Exception e) { return chuck(e); } } } }
mikiec84/OpenSPIFe
gov.nasa.ensemble.common/src/gov/nasa/ensemble/common/mission/MissionTimeConstants.java
/******************************************************************************* * Copyright 2014 United States Government as represented by the * Administrator of the National Aeronautics and Space Administration. * All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. ******************************************************************************/ package gov.nasa.ensemble.common.mission; public class MissionTimeConstants { /** * Property key to access the start time of mission. Should be ignored if * the <code>MISSION_SIMULATION_START_TIME_ACTIVE</code> property value * is 'true', and <code>MISSION_SIMULATION_START_TIME</code> should be * used instead. */ public static final String MISSION_START_TIME = "mission.time.start"; /** * Property key to access the default start day of time for a specific mission. * This value can be overriden in the new plan wizard. */ public static final String MISSION_HOUR_START_OF_DAY = "mission.time.hour.startofday"; /** * Property key to access in order to determine if the mission start time simulation is active. * If so, the <code>MISSION_START_TIME</code> property is to be ignored, and * <code>MISSION_SIMULATION_START_TIME</code> should be used instead. */ public static final String MISSION_SIMULATION_START_TIME_ACTIVE = "mission.simulation.start.active"; /** * Property key to access the simulated mission start time. Should be ignored if * <code> MISSION_SIMULATION_START_TIME_ACTIVE</code> property value is 'false' */ public static final String MISSION_SIMULATION_START_TIME = "mission.simulation.start"; /** * Property key to access in order to determine if the Mission Elapsed Time is to be determined * from the current date, or from the <code>MISSION_SIMULATION_PLAN_DAY</code>. */ public static final String MISSION_SIMULATION_PLAN_DAY_ACTIVE = "mission.simulation.planday.default.active"; /** * Property key to access the simulated current time in order to determine the Mission Elapsed * Time for the application. This should not be referenced unless the property value for * <code>MISSION_SIMULATION_PLAN_DAY_ACTIVE</code> evaluates to true. */ public static final String MISSION_SIMULATION_PLAN_DAY = "mission.simulation.planday.default"; }
jabdoa2/blitzmax
mod/pub.mod/glew.mod/glew_static.c
#define GLEW_STATIC 1 #include "glew.c"
nerdmaennchen/qrqma
actions/print_statement.h
#pragma once #include "context.h" namespace qrqma { namespace grammar { struct print_expression; } namespace actions { template<typename Rule> struct action; template <> struct action<grammar::print_expression> { static void apply(ContextP &context); template <typename Input> static void apply(const Input &, ContextP &context) { apply(context); } }; } }
rahulyesantharao/tuplex
tuplex/codegen/include/CleanAstVisitor.h
<gh_stars>100-1000 //--------------------------------------------------------------------------------------------------------------------// // // // Tuplex: Blazing Fast Python Data Science // // // // // // (c) 2017 - 2021, Tuplex team // // Created by <NAME> on 1/1/2021 // // License: Apache 2.0 // //--------------------------------------------------------------------------------------------------------------------// #ifndef TUPLEX_CLEANASTVISITOR_H #define TUPLEX_CLEANASTVISITOR_H #include "IReplaceVisitor.h" namespace tuplex { // @Todo: add here logs on what this visitor does... // clean visitor optimizes currently the following: // (1) collapses suites (except for upward merging!) // (2) collapsed cmp nodes if they only consist of lhs class CleanAstVisitor : public IReplaceVisitor { private: // visits next node // tries to remove the next node if possible ASTNode* replace(ASTNode* parent, ASTNode *next); public: CleanAstVisitor() {} // there is no point in visiting these Literals or endnodes since they won't be pruned in any way // hence, just define them as empty functions. void visit(NNone*) {} void visit(NNumber*){} void visit(NIdentifier*){} void visit(NBoolean*){} void visit(NEllipsis*){} void visit(NString*){} }; } #endif //TUPLEX_CLEANASTVISITOR_H
msgmaxim/sapphire-platform-server
modules/follows/follows.controller.js
module.exports = { /** user_follow */ setFollows: function(data, deleted, id, ts, callback) { //console.log('dispatcher.js::setFollows - data', data) // data can be null if (data) { //console.log('dispatcher.js::setFollows - has data') // update user object // so we need the username check // because user/ID/follow calls this without looking up the complete user if (data.user && data.user.username) { this.updateUser(data.user, ts) //} else { //console.log('dispatcher.js::setFollows - no user', data) } // update user object if (data.follows_user && data.follows_user.username) { this.updateUser(data.follows_user, ts) //} else { //console.log('dispatcher.js::setFollows - no follows_user', data) } // set relationship status //console.log('dispatcher.js::setFollows - has data', data.user.id, data.follows_user.id, 'id', id, 'deleted', deleted, 'ts', ts) // probably dont' need this first one but we're an internal API // maybe something will need it eventually const ref = this this.normalizeUserID(data.user.id, {}, function(err, normalUserId) { if (err) console.error('follows.controller.js::setFollows - normalizeUserID err', err) ref.normalizeUserID(data.follows_user.id, {}, function(err, normalFollowId) { if (err) console.error('follows.controller.js::setFollows - normalizeUserID2 err', err) ref.cache.setFollow(normalUserId, normalFollowId, id, deleted, ts) }) }) } else { // likely deleted is true in this path this.cache.setFollow(0, 0, id, deleted, ts) } if (this.notsilent) { process.stdout.write(deleted ? 'f' : 'F') } if (callback) { callback() } }, getFollowings: function(user, params, tokenObj, callback) { //console.log('dispatcher.js::getFollowing - for', userid) const ref = this this.normalizeUserID(user, tokenObj, function(err, userid) { if (err) console.error('follows.controller.js::getFollowings - normalizeUserID err', err) ref.cache.getFollowing(userid, params, function(err, follows, meta) { if (err || !follows || !follows.length) { callback(err, []) return } const users = [] //console.log('dispatcher.js::getFollowing', follows.length) let min_id = 9999 let max_id = 0 for (const i in follows) { min_id = Math.min(min_id, follows[i].id) max_id = Math.max(max_id, follows[i].id) ; (function(i) { ref.getUser(follows[i].followsid, { tokenobj: tokenObj }, function(err, user) { if (err) { console.error('follows.controller.js::getFollowers - err', err) } if (!user) { console.log('follows.controller.js::getFollowers - empty user gotten for', follows[i].userid) user = {} // fix it so setting pagination doesn't crash } /* if (!user.avatar_image.url) { user.avatar_image.url='http://cdn.discordapp.com/icons/235920083535265794/a0f48aa4e45d17d1183a563b20e15a54.png' user.avatar_image.height=128 user.avatar_image.width=128 } */ //console.log('dispatcher.js::getFollowing - adding user', user) // alpha needs this dummy wrapper // but it's against spec /* const obj={ id: 0, text: 'alpha hack', created_at: '2014-10-24T17:04:48Z', source: { }, user: user } */ user.pagination_id = follows[i].id users.push(user) if (users.length === follows.length) { // supposed to return meta too const imeta = { code: 200, min_id: min_id, max_id: max_id, more: users.length === parseInt(params.count) } callback(err, users, imeta) } }) }(i)) } }) }) }, getFollowers: function(user, params, tokenObj, callback) { //console.log('dispatcher.js::getFollowers - for', userid) const ref = this this.normalizeUserID(user, tokenObj, function(err, userid) { if (err) console.error('follows.controller.js::getFollowers - normalizeUserID err', err) ref.cache.getFollows(userid, params, function(err, follows, meta) { if (err || !follows || !follows.length) { if (err) console.error('follows.controller.js::getFollowers', err) callback(err, []) return } const users = [] //console.log('dispatcher.js::getFollowers', follows.length) for (const i in follows) { ref.getUser(follows[i].userid, { tokenobj: tokenObj }, function(err, user) { if (err) { console.error('follows.controller.js::getFollowers - err', err) } if (!user) { console.log('follows.controller.js::getFollowers - empty user gotten for', follows[i].userid) } //console.log('follows.controller.js::getFollowers - adding user', user) // alpha needs this dummy wrapper // but it's against spec /* const obj={ id: 0, text: 'alpha hack', created_at: '2014-10-24T17:04:48Z', source: { }, user: user } */ users.push(user) //console.log('dispatcher.js::getFollowers - users', users.length, 'follows', follows.length) if (users.length === follows.length) { // supposed to return meta too callback(err, users, meta) } }) } }) }) } }
lordjoe/SparkAccumulators
src/main/java/com/lordjoe/distributed/spark/accumulators/IAccumulator.java
<gh_stars>0 package com.lordjoe.distributed.spark.accumulators; import java.io.*; /** * com.lordjoe.distributed.spark.accumulators.IAccumulator * * interface marking the class as something which can be used as an accumulator \ * User: Steve * Note it is normal for these classes to have * 1) * public static final AccumulatorParam<MY_CLASS> PARAM_INSTANCE = new IAccumulatorParam<MY_CLASS>(); public static MY_CLASS empty() { return new MY_CLASS(); } 2) private constructor to encourage the use of empty * Date: 7/6/2015 */ public interface IAccumulator<K> extends Serializable { /** * add the accumulated data to another instance * @param added * @return */ public K add(K added); /** * given a value return it as 0 * default behavior is to return the value itself * @param added * @return */ public K asZero(); /** * like toString but might add more information than a shorter string * usually implemented bu appending toString * @param out */ public void buildReport(Appendable out); }
ZTO-Express/test-case-app
test-case/src/main/java/com/zto/testcase/request/PmsRequest.java
<filename>test-case/src/main/java/com/zto/testcase/request/PmsRequest.java package com.zto.testcase.request; import javax.validation.constraints.NotNull; import lombok.AllArgsConstructor; import lombok.Builder; import lombok.Data; import lombok.NoArgsConstructor; import org.hibernate.validator.constraints.Length; import org.hibernate.validator.constraints.NotBlank; @Data @Builder @NoArgsConstructor @AllArgsConstructor public class PmsRequest { @NotBlank(message = "系统ID 不能为空", groups = {deleteByUiMetaId.class, deleteByRoleCode.class, insert.class, batchInsert.class, deleteById.class, updateById.class, batchUpdateById.class, select.class, treeByRoleCode.class, topTree.class}) // @InEnum(message = "系统编号必须合法", enumClass = AppIpEnum.class, attribute = "appId", groups = {deleteByUiMetaId.class, deleteByRoleCode.class, insert.class, batchInsert.class, deleteById.class, updateById.class, batchUpdateById.class, select.class, treeByRoleCode.class, topTree.class}) private String appId; @NotBlank(message = "角色编码 不能为空", groups = {deleteByRoleCode.class, insert.class, batchInsert.class, treeByRoleCode.class}) @Length(max = 20, message = "1 - 20的字符串", groups = {deleteByRoleCode.class, insert.class, batchInsert.class, updateById.class, batchUpdateById.class}) private String roleCode; @NotBlank(message = "控件记录ID 不能为空", groups = {deleteByUiMetaId.class, insert.class, batchInsert.class}) private String uiMetaId; @NotNull(message = "操作元素展现方式 不能为空", groups = {insert.class, batchInsert.class}) private Integer operationShowType; @NotNull(message = "字段元素展现方式 不能为空", groups = {insert.class, batchInsert.class}) private Integer fieldPermissionType; @NotNull(message = "ID 不能为空", groups = {updateById.class, batchUpdateById.class, deleteById.class}) private Long id; interface insert { } interface updateById { } interface deleteById { } interface select { } interface treeByRoleCode { } interface topTree { } interface batchInsert { } interface batchUpdateById { } interface deleteByRoleCode { } interface deleteByUiMetaId { } }
justshiv/weicoder
redis/src/main/java/com/weicoder/redis/base/BaseRedis.java
package com.weicoder.redis.base; import java.util.List; import com.weicoder.common.W.C; import com.weicoder.common.lang.Bytes; import com.weicoder.common.lang.Lists; import com.weicoder.common.util.ThreadUtil; import com.weicoder.common.zip.ZipEngine; import com.weicoder.json.JsonEngine; import com.weicoder.redis.Redis; /** * Redis基类 * * @author WD */ public abstract class BaseRedis implements Redis { // redismingc private String name; public BaseRedis(String name) { super(); this.name = name; } @Override public String name() { return name; } /** * 压缩值 当值能压缩时才压缩 * * @param key 键 * @param value 值 */ public final String compress(String key, Object value) { return set(Bytes.toBytes(key), ZipEngine.compress(value)); } /** * 根据键获得压缩值 如果是压缩的返回解压缩的byte[] 否是返回Object * * @param key 键 * @return 值 */ public final byte[] extract(String key) { return ZipEngine.extract(get(key)); } /** * 获得多个键的数组 * * @param keys 键 * @return 值 */ public Object[] get(String... keys) { // 声明列表 Object[] objs = new Object[keys.length]; // 循环解压数据 for (int i = 0; i < keys.length; i++) objs[i] = get(keys[i]); // 返回列表 return objs; } @Override public boolean hexists(String key, Object field) { return hexists(key, toString(field)); } @Override public boolean sexists(String key, Object member) { return sexists(key, toString(member)); } /** * 获得多个键的数组 * * @param keys 键 * @return 值 */ public List<byte[]> extract(String... keys) { // 声明列表 List<byte[]> list = Lists.newList(keys.length); // 循环解压数据 for (Object o : get(keys)) list.add(ZipEngine.extract(o)); // 返回列表 return list; } @Override public String set(String key, Object value) { return set(key, toString(value)); } @Override public long hset(String key, Object field, Object value) { return hset(key, toString(field), toString(value)); } @Override public void lock(String key) { lock(key, -1L); } @Override public boolean lock(String key, int s) { return lock(key, s, -1L); } @Override public void unlock(String key) { exec(r -> r.del(key)); } @Override public boolean lock(String key, long ms) { return lock(key, 1, ms); } @Override public boolean lock(String key, int seconds, long timeout) { try { exec(r -> { // 当前时间 long curr = System.currentTimeMillis(); // 检查分布式锁是否存在 如果存在循环等待 while (r.exists(key)) { // 等待5毫秒 ThreadUtil.sleep(5L); // 检查是否超时 if (timeout > 0 && System.currentTimeMillis() - curr > timeout) throw new RuntimeException("timeout .."); } // 加锁 // if (r.exists(key)) // throw new RuntimeException("other server is lock"); if (seconds == -1) r.set(key, key); else r.setex(key, seconds, key); }); return true; } catch (Exception e) { return false; } } /** * 根据传入类型转换成String * * @param o * @return */ protected String toString(Object o) { return o instanceof Number || o instanceof String ? C.toString(o) : JsonEngine.toJson(o); } }
martin-ockajak/automorph
codec/jackson/src/main/scala/automorph/codec/json/JacksonWebRpc.scala
package automorph.codec.json import automorph.protocol.webrpc.{Message, MessageError} import com.fasterxml.jackson.core.{JsonGenerator, JsonParseException, JsonParser} import com.fasterxml.jackson.databind.deser.std.StdDeserializer import com.fasterxml.jackson.databind.module.SimpleModule import com.fasterxml.jackson.databind.node.ObjectNode import com.fasterxml.jackson.databind.ser.std.StdSerializer import com.fasterxml.jackson.databind.{DeserializationContext, JsonNode, SerializerProvider} /** Web-RPC protocol support for Jackson message codec plugin using JSON format. */ private[automorph] object JacksonWebRpc { type RpcMessage = Message[JsonNode] type RpcError = MessageError def module: SimpleModule = new SimpleModule() .addSerializer(classOf[JacksonWebRpc.RpcError], JacksonWebRpc.messageErrorSerializer) .addDeserializer(classOf[JacksonWebRpc.RpcError], JacksonWebRpc.messageErrorDeserializer) .addSerializer(classOf[JacksonWebRpc.RpcMessage], JacksonWebRpc.messageSerializer) .addDeserializer(classOf[JacksonWebRpc.RpcMessage], JacksonWebRpc.messageDeserializer) private def messageErrorSerializer = new StdSerializer[RpcError](classOf[RpcError]) { override def serialize(value: RpcError, generator: JsonGenerator, provider: SerializerProvider): Unit = { val entries = value.productElementNames.zip(value.productIterator).flatMap { case (name, Some(value)) => Some(name -> value) case (_, None) => None }.toMap generator.writeObject(entries) } } private def messageErrorDeserializer = new StdDeserializer[RpcError](classOf[RpcError]) { override def deserialize(parser: JsonParser, context: DeserializationContext): RpcError = context.readTree(parser) match { case node: ObjectNode => MessageError( field("message", value => Option.when(value.isTextual)(value.asText), node, parser), field("code", value => Option.when(value.isInt)(value.asInt), node, parser) ) case _ => throw new JsonParseException(parser, "Invalid message error", parser.getCurrentLocation) } } private def messageSerializer = new StdSerializer[RpcMessage](classOf[RpcMessage]) { override def serialize(value: RpcMessage, generator: JsonGenerator, provider: SerializerProvider): Unit = { val entries = value.productElementNames.zip(value.productIterator).flatMap { case (name, Some(value)) => Some(name -> value) case (_, None) => None }.toMap generator.writeObject(entries) } } private def messageDeserializer = new StdDeserializer[RpcMessage](classOf[RpcMessage]) { override def deserialize(parser: JsonParser, context: DeserializationContext): RpcMessage = context.readTree(parser) match { case node: ObjectNode => Message[JsonNode]( field("result", Some(_), node, parser), field("error", value => Some(context.readValue[RpcError](value.traverse(), classOf[RpcError])), node, parser) ) case _ => throw new JsonParseException(parser, "Invalid message", parser.getCurrentLocation) } } private def field[T](name: String, extract: JsonNode => Option[T], node: ObjectNode, parser: JsonParser): Option[T] = Option(node.get(name)).filter(!_.isNull).map(extract).map(_.getOrElse { throw new JsonParseException(parser, s"Invalid $name", parser.getCurrentLocation) }) }
chaoannricardo/StudyNotes
III_DataEngineer_BDSE10/1902_Java/JavaWorkspace/JavaLab/src/Collection/TestHashMap.java
<filename>III_DataEngineer_BDSE10/1902_Java/JavaWorkspace/JavaLab/src/Collection/TestHashMap.java package Collection; import java.io.ObjectInputStream.GetField; import java.util.HashMap; import java.util.Iterator; import java.util.Map; import java.util.Map.Entry; import java.util.Set; public class TestHashMap { public static void main(String[] args) { Map<String, Double> dog = new HashMap<>(); //利用Map<String, Double>來使用Generic性質 dog.put("Ricardo", 100000000000000000d); dog.put("John", 1d); dog.put("Tim", 400d); dog.put("Henry", 200d); dog.put("Kate", 500d); // System.out.println(dog.get("Kate")); Set<String> abs = dog.keySet(); Iterator<String> its = abs.iterator(); //這邊的Iterator只有抓到String,所以將不能在下段的Iterator中沿用 while (its.hasNext()) { Object object = (Object) its.next(); //System.out.println(object + " = " + dog.get(object)); } //dog是map;abs是所有的key;its是iterator;object是每個iterator抓到的key Set<Entry<String, Double>> abses = dog.entrySet(); for (Object itses : abses) { Map.Entry entry = (Map.Entry) itses; //System.out.println(entry.getKey() + "= " + entry.getValue()); } //需使用一個不同的Iterator,Recall上方的Iterator,這邊需定義一個全新的Iterator Iterator<Entry<String, Double>> iterator = abses.iterator(); while (iterator.hasNext()) { Map.Entry<String, Double> object = iterator.next(); System.out.println(object.getKey() + " = " + object.getValue()); } } }
Sol-0/sdk
pkg/registry/common/dnsresolve/nse_server_test.go
// Copyright (c) 2020-2021 Doc.ai and/or its affiliates. // // SPDX-License-Identifier: Apache-2.0 // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at: // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. package dnsresolve_test import ( "context" "net/url" "testing" "time" "go.uber.org/goleak" "github.com/networkservicemesh/sdk/pkg/tools/clienturlctx" "github.com/networkservicemesh/sdk/pkg/tools/sandbox" "github.com/golang/protobuf/ptypes/empty" "github.com/networkservicemesh/api/pkg/api/registry" "github.com/stretchr/testify/require" "github.com/networkservicemesh/sdk/pkg/registry/common/dnsresolve" "github.com/networkservicemesh/sdk/pkg/registry/common/memory" "github.com/networkservicemesh/sdk/pkg/registry/core/adapters" "github.com/networkservicemesh/sdk/pkg/registry/core/next" "github.com/networkservicemesh/sdk/pkg/registry/core/streamchannel" ) type checkNSEContext struct { *testing.T expectedURL *url.URL } func (c *checkNSEContext) Register(ctx context.Context, ns *registry.NetworkServiceEndpoint) (*registry.NetworkServiceEndpoint, error) { require.Equal(c, c.expectedURL, clienturlctx.ClientURL(ctx)) return next.NetworkServiceEndpointRegistryServer(ctx).Register(ctx, ns) } func (c *checkNSEContext) Find(q *registry.NetworkServiceEndpointQuery, s registry.NetworkServiceEndpointRegistry_FindServer) error { require.Equal(c, c.expectedURL, clienturlctx.ClientURL(s.Context())) return next.NetworkServiceEndpointRegistryServer(s.Context()).Find(q, s) } func (c *checkNSEContext) Unregister(ctx context.Context, ns *registry.NetworkServiceEndpoint) (*empty.Empty, error) { require.Equal(c, c.expectedURL, clienturlctx.ClientURL(ctx)) return next.NetworkServiceEndpointRegistryServer(ctx).Unregister(ctx, ns) } func Test_DNSResolve(t *testing.T) { const srv = "service1" var resolver = new(sandbox.FakeDNSResolver) u, err := url.Parse("tcp://127.0.0.1:80") require.NoError(t, err) resolver.AddSRVEntry("domain1", srv, u) s := dnsresolve.NewNetworkServiceEndpointRegistryServer( dnsresolve.WithRegistryService(srv), dnsresolve.WithResolver(resolver), ) s = next.NewNetworkServiceEndpointRegistryServer(s, &checkNSEContext{T: t, expectedURL: u}) ctx, cancel := context.WithTimeout(context.Background(), time.Second) defer cancel() resp, err := s.Register(ctx, &registry.NetworkServiceEndpoint{Name: "nse-1@domain1"}) require.NoError(t, err) require.Equal(t, "nse-1@domain1", resp.Name) resp, err = s.Register(ctx, &registry.NetworkServiceEndpoint{ Name: "nse-1", NetworkServiceNames: []string{"ns1@domain1"}, NetworkServiceLabels: map[string]*registry.NetworkServiceLabels{ "ns1@domain1": { Labels: map[string]string{ "app": "myapp", }, }, }, }) require.NoError(t, err) require.Equal(t, "nse-1@domain1", resp.Name) require.Len(t, resp.GetNetworkServiceLabels(), 1) require.NotNil(t, resp.GetNetworkServiceLabels()["ns1@domain1"]) require.Equal(t, "myapp", resp.GetNetworkServiceLabels()["ns1@domain1"].Labels["app"]) _, err = s.Register(ctx, &registry.NetworkServiceEndpoint{Name: "nse-1@domain1"}) require.NoError(t, err) err = s.Find(&registry.NetworkServiceEndpointQuery{NetworkServiceEndpoint: &registry.NetworkServiceEndpoint{Name: "nse-1@domain1"}}, streamchannel.NewNetworkServiceEndpointFindServer((ctx), nil)) require.NoError(t, err) _, err = s.Unregister(ctx, &registry.NetworkServiceEndpoint{Name: "nse-1@domain1"}) require.NoError(t, err) } func Test_DNSResolve_LookupNsmgrProxy(t *testing.T) { defer goleak.VerifyNone(t) const ( regSrv = "service1" nsmgrProxySrv = "service2" domain = "domain1" ) ctx, cancel := context.WithTimeout(context.Background(), time.Second) defer cancel() var resolver = new(sandbox.FakeDNSResolver) regURL, err := url.Parse("tcp://127.0.0.1:80") require.NoError(t, err) resolver.AddSRVEntry(domain, regSrv, regURL) nsmgrProxyURL, err := url.Parse("tcp://127.0.0.1:81") require.NoError(t, err) resolver.AddSRVEntry(domain, nsmgrProxySrv, nsmgrProxyURL) s := dnsresolve.NewNetworkServiceEndpointRegistryServer( dnsresolve.WithRegistryService(regSrv), dnsresolve.WithNSMgrProxyService(nsmgrProxySrv), dnsresolve.WithResolver(resolver), ) s = next.NewNetworkServiceEndpointRegistryServer(s, &checkNSEContext{T: t, expectedURL: regURL}, memory.NewNetworkServiceEndpointRegistryServer()) _, err = s.Register(ctx, &registry.NetworkServiceEndpoint{Name: "nse-1@" + domain}) require.NoError(t, err) resp, err := adapters.NetworkServiceEndpointServerToClient(s).Find(ctx, &registry.NetworkServiceEndpointQuery{NetworkServiceEndpoint: &registry.NetworkServiceEndpoint{Name: "nse-1@" + domain}}) require.NoError(t, err) r, err := resp.Recv() require.NoError(t, err) require.Equal(t, nsmgrProxyURL.String(), r.NetworkServiceEndpoint.Url) _, err = s.Unregister(ctx, &registry.NetworkServiceEndpoint{Name: "nse-1@" + domain}) require.NoError(t, err) }
mccsssk2/SimVascularPM3_March2020
SimVascular-master/Code/Source/sv4gui/Modules/Model/Common/sv4gui_ModelVtkMapper2D.cxx
<reponame>mccsssk2/SimVascularPM3_March2020<filename>SimVascular-master/Code/Source/sv4gui/Modules/Model/Common/sv4gui_ModelVtkMapper2D.cxx<gh_stars>0 /* Copyright (c) Stanford University, The Regents of the University of * California, and others. * * All Rights Reserved. * * See Copyright-SimVascular.txt for additional details. * * 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. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS * IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. */ #include "sv4gui_ModelVtkMapper2D.h" //mitk includes #include <mitkDataNode.h> #include <mitkProperties.h> #include "mitkVtkPropRenderer.h" #include <mitkLookupTableProperty.h> #include <mitkVtkScalarModeProperty.h> #include <mitkTransferFunctionProperty.h> //vtk includes #include <vtkActor.h> #include <vtkCutter.h> #include <vtkLookupTable.h> #include <vtkPlane.h> #include <vtkPolyData.h> #include <vtkAssembly.h> #include <vtkPointData.h> #include <vtkTransformPolyDataFilter.h> sv4guiModelVtkMapper2D::LocalStorage::LocalStorage() { m_PropAssembly = vtkSmartPointer <vtkPropAssembly>::New(); } sv4guiModelVtkMapper2D::LocalStorage::~LocalStorage() { } const sv4guiModel* sv4guiModelVtkMapper2D::GetInput() const { return static_cast<const sv4guiModel * > ( GetDataNode()->GetData() ); } sv4guiModelVtkMapper2D::sv4guiModelVtkMapper2D() { } sv4guiModelVtkMapper2D::~sv4guiModelVtkMapper2D() { } void sv4guiModelVtkMapper2D::ResetMapper( mitk::BaseRenderer* renderer ) { LocalStorage *ls = m_LSH.GetLocalStorage(renderer); ls->m_PropAssembly->VisibilityOff(); } vtkProp* sv4guiModelVtkMapper2D::GetVtkProp(mitk::BaseRenderer * renderer) { LocalStorage *ls = m_LSH.GetLocalStorage(renderer); return ls->m_PropAssembly; } //Comment the code below to make sure to always update the renderwindows //void sv4guiModelVtkMapper2D::Update(mitk::BaseRenderer* renderer) //{ // const mitk::DataNode* node = GetDataNode(); // if( node == NULL ) // return; // bool visible = true; // node->GetVisibility(visible, renderer, "visible"); // if ( !visible ) // return; // sv4guiModel* model = static_cast<sv4guiModel*>( node->GetData() ); // if ( model == NULL ) // return; // this->CalculateTimeStep( renderer ); // const mitk::TimeGeometry *dataTimeGeometry = model->GetTimeGeometry(); // if ( ( dataTimeGeometry == NULL ) // || ( dataTimeGeometry->CountTimeSteps() == 0 ) // || ( !dataTimeGeometry->IsValidTimeStep( this->GetTimestep() ) ) ) // { // return; // } // model->UpdateOutputInformation(); // LocalStorage* localStorage = m_LSH.GetLocalStorage(renderer); // //check if something important has changed and we need to rerender // if ( (localStorage->m_LastUpdateTime < node->GetMTime()) //was the node modified? // || (localStorage->m_LastUpdateTime < model->GetPipelineMTime()) //Was the data modified? // || (localStorage->m_LastUpdateTime < renderer->GetCurrentWorldPlaneGeometryUpdateTime()) //was the geometry modified? // || (localStorage->m_LastUpdateTime < renderer->GetCurrentWorldPlaneGeometry()->GetMTime()) // || (localStorage->m_LastUpdateTime < node->GetPropertyList()->GetMTime()) //was a property modified? // || (localStorage->m_LastUpdateTime < node->GetPropertyList(renderer)->GetMTime()) ) // { // this->GenerateDataForRenderer( renderer ); // } // localStorage->m_LastUpdateTime.Modified(); //} void sv4guiModelVtkMapper2D::GenerateDataForRenderer( mitk::BaseRenderer *renderer ) { mitk::DataNode* node = GetDataNode(); if(node==NULL) return; LocalStorage* localStorage = m_LSH.GetLocalStorage(renderer); bool visible = true; node->GetVisibility(visible, renderer, "visible"); if(!visible) { localStorage->m_PropAssembly->VisibilityOff(); return; } sv4guiModel* model = static_cast<sv4guiModel *>( node->GetData() ); if(model==NULL) { localStorage->m_PropAssembly->VisibilityOff(); return; } int timestep=this->GetTimestep(); sv4guiModelElement* me=model->GetModelElement(timestep); if(me==NULL) { localStorage->m_PropAssembly->VisibilityOff(); return; } vtkSmartPointer<vtkPolyData> wholePolyData=me->GetWholeVtkPolyData(); if ((wholePolyData == NULL) || (wholePolyData->GetNumberOfPoints() < 1)) { localStorage->m_PropAssembly->VisibilityOff(); return; } const mitk::PlaneGeometry* planeGeometry = renderer->GetCurrentWorldPlaneGeometry(); if( ( planeGeometry == NULL ) || ( !planeGeometry->IsValid() ) || ( !planeGeometry->HasReferenceGeometry() )) { localStorage->m_PropAssembly->VisibilityOff(); return; } double origin[3]; origin[0] = planeGeometry->GetOrigin()[0]; origin[1] = planeGeometry->GetOrigin()[1]; origin[2] = planeGeometry->GetOrigin()[2]; double normal[3]; normal[0] = planeGeometry->GetNormal()[0]; normal[1] = planeGeometry->GetNormal()[1]; normal[2] = planeGeometry->GetNormal()[2]; float lineWidth = 1.0f; node->GetFloatProperty("line 2D width", lineWidth, renderer); bool showWholeSurface=false; node->GetBoolProperty("show whole surface", showWholeSurface, renderer); bool showFaces=true; node->GetBoolProperty("show faces", showFaces, renderer); if(me->GetFaceNumber()==0) showWholeSurface=true; if(showWholeSurface) showFaces=false; // bool forceShowWholeSurface=false; // node->GetBoolProperty("show whole surface", forceShowWholeSurface, renderer); // bool showWholeSurface=false; // bool showFaces=false; // if(me->GetFaceNumber()>0) // { // showWholeSurface=false||forceShowWholeSurface; // showFaces=true; // }else{ // showWholeSurface=true; // showFaces=false; // } int numProps=localStorage->m_PropAssembly->GetParts()->GetNumberOfItems(); for(int i=0;i<numProps;i++) { vtkProp* prop= (vtkProp*)localStorage->m_PropAssembly->GetParts()->GetItemAsObject(i); localStorage->m_PropAssembly->RemovePart(prop); } if(showWholeSurface) { float color[3]= { 1.0f, 1.0f, 1.0f }; node->GetColor(color, renderer, "color"); float opacity = 1.0f; node->GetOpacity(opacity, renderer, "opacity"); vtkSmartPointer<vtkPlane> cuttingPlane = vtkSmartPointer<vtkPlane>::New(); cuttingPlane->SetOrigin(origin); cuttingPlane->SetNormal(normal); vtkSmartPointer<vtkCutter> cutter = vtkSmartPointer<vtkCutter>::New(); cutter->SetCutFunction(cuttingPlane); vtkSmartPointer<vtkLinearTransform> vtktransform = GetDataNode()->GetVtkTransform(this->GetTimestep()); vtkSmartPointer<vtkTransformPolyDataFilter> filter = vtkSmartPointer<vtkTransformPolyDataFilter>::New(); filter->SetTransform(vtktransform); filter->SetInputData(wholePolyData); cutter->SetInputConnection(filter->GetOutputPort()); cutter->Update(); vtkSmartPointer<vtkPolyDataMapper> mapper = vtkSmartPointer<vtkPolyDataMapper>::New(); mapper->ScalarVisibilityOff(); mapper->SetInputConnection(cutter->GetOutputPort()); ApplyMapperProperties(mapper, renderer); vtkSmartPointer<vtkActor> actor= vtkSmartPointer<vtkActor>::New(); actor->SetMapper(mapper); actor->GetProperty()->SetColor(color[0], color[1], color[2]); actor->GetProperty()->SetOpacity(opacity); actor->GetProperty()->SetLineWidth(lineWidth); actor->GetProperty()->SetLighting(0); localStorage->m_PropAssembly->AddPart(actor ); } if(showFaces) { float selectedColor[3]= { 1.0f, 1.0f, 0.0f }; node->GetColor(selectedColor, renderer, "face selected color"); for(int i=0;i<me->GetFaces().size();i++) { sv4guiModelElement::svFace* face=me->GetFaces()[i]; if(!face) continue; if(!face->visible) continue; vtkSmartPointer<vtkPolyData> facePolyData=face->vpd; if(!facePolyData) continue; vtkSmartPointer<vtkPlane> cuttingPlane = vtkSmartPointer<vtkPlane>::New(); cuttingPlane->SetOrigin(origin); cuttingPlane->SetNormal(normal); vtkSmartPointer<vtkCutter> cutter = vtkSmartPointer<vtkCutter>::New(); cutter->SetCutFunction(cuttingPlane); vtkSmartPointer<vtkLinearTransform> vtktransform = GetDataNode()->GetVtkTransform(this->GetTimestep()); vtkSmartPointer<vtkTransformPolyDataFilter> filter = vtkSmartPointer<vtkTransformPolyDataFilter>::New(); filter->SetTransform(vtktransform); filter->SetInputData(facePolyData); cutter->SetInputConnection(filter->GetOutputPort()); cutter->Update(); vtkSmartPointer<vtkPolyDataMapper> mapper = vtkSmartPointer<vtkPolyDataMapper>::New(); mapper->ScalarVisibilityOff(); mapper->SetInputConnection(cutter->GetOutputPort()); ApplyMapperProperties(mapper, renderer); vtkSmartPointer<vtkActor> actor= vtkSmartPointer<vtkActor>::New(); actor->SetMapper(mapper); if(face->selected){ actor->GetProperty()->SetColor(selectedColor[0], selectedColor[1], selectedColor[2]); }else{ actor->GetProperty()->SetColor(face->color[0], face->color[1], face->color[2]); } actor->GetProperty()->SetOpacity(face->opacity); actor->GetProperty()->SetLineWidth(lineWidth); actor->GetProperty()->SetLighting(0); localStorage->m_PropAssembly->AddPart(actor ); } } if(visible) localStorage->m_PropAssembly->VisibilityOn(); } void sv4guiModelVtkMapper2D::ApplyMapperProperties(vtkSmartPointer<vtkPolyDataMapper> mapper, mitk::BaseRenderer* renderer) { const mitk::DataNode * node = GetDataNode(); if(node == NULL) { return; } // same block for scalar data rendering as in 3D mapper mitk::TransferFunctionProperty::Pointer transferFuncProp; this->GetDataNode()->GetProperty(transferFuncProp, "Surface.TransferFunction", renderer); if (transferFuncProp.IsNotNull() ) { mapper->SetLookupTable(transferFuncProp->GetValue()->GetColorTransferFunction()); } mitk::LookupTableProperty::Pointer lookupTableProp; this->GetDataNode()->GetProperty(lookupTableProp, "LookupTable", renderer); if (lookupTableProp.IsNotNull() ) { mapper->SetLookupTable(lookupTableProp->GetLookupTable()->GetVtkLookupTable()); } mitk::LevelWindow levelWindow; if(this->GetDataNode()->GetLevelWindow(levelWindow, renderer, "levelWindow")) { mapper->SetScalarRange(levelWindow.GetLowerWindowBound(),levelWindow.GetUpperWindowBound()); } else if(this->GetDataNode()->GetLevelWindow(levelWindow, renderer)) { mapper->SetScalarRange(levelWindow.GetLowerWindowBound(),levelWindow.GetUpperWindowBound()); } bool scalarVisibility = false; this->GetDataNode()->GetBoolProperty("scalar visibility", scalarVisibility); mapper->SetScalarVisibility( (scalarVisibility ? 1 : 0) ); if(scalarVisibility) { mitk::VtkScalarModeProperty* scalarMode; if(this->GetDataNode()->GetProperty(scalarMode, "scalar mode", renderer)) mapper->SetScalarMode(scalarMode->GetVtkScalarMode()); else mapper->SetScalarModeToDefault(); bool colorMode = false; this->GetDataNode()->GetBoolProperty("color mode", colorMode); mapper->SetColorMode( (colorMode ? 1 : 0) ); double scalarsMin = 0; this->GetDataNode()->GetDoubleProperty("ScalarsRangeMinimum", scalarsMin, renderer); double scalarsMax = 1.0; this->GetDataNode()->GetDoubleProperty("ScalarsRangeMaximum", scalarsMax, renderer); mapper->SetScalarRange(scalarsMin,scalarsMax); } } void sv4guiModelVtkMapper2D::SetDefaultProperties(mitk::DataNode* node, mitk::BaseRenderer* renderer, bool overwrite) { // mitk::IPropertyAliases* aliases = mitk::CoreServices::GetPropertyAliases(); node->AddProperty( "color", mitk::ColorProperty::New(1.0f,1.0f,1.0f), renderer, overwrite ); node->AddProperty( "opacity", mitk::FloatProperty::New(1.0), renderer, overwrite ); node->AddProperty( "show whole surface", mitk::BoolProperty::New(false), renderer, overwrite ); node->AddProperty( "show faces", mitk::BoolProperty::New(true), renderer, overwrite ); node->AddProperty( "face selected color",mitk::ColorProperty::New(1,1,0),renderer, overwrite ); node->AddProperty( "line 2D width", mitk::FloatProperty::New(2.0f), renderer, overwrite ); node->AddProperty( "scalar mode", mitk::VtkScalarModeProperty::New(), renderer, overwrite ); node->AddProperty( "layer", mitk::IntProperty::New(100), renderer, overwrite); Superclass::SetDefaultProperties(node, renderer, overwrite); }
yangbajing/algorithm-study
algs4/src/main/java/edu/princeton/cs/algs4/Arbitrage.java
/** * **************************************************************************** Compilation: javac * Arbitrage.java Execution: java Arbitrage < input.txt Dependencies: EdgeWeightedDigraph.java * DirectedEdge.java BellmanFordSP.java Data file: https://algs4.cs.princeton.edu/44sp/rates.txt * * <p>Arbitrage detection. * * <p>% more rates.txt 5 USD 1 0.741 0.657 1.061 1.005 EUR 1.349 1 0.888 1.433 1.366 GBP 1.521 1.126 * 1 1.614 1.538 CHF 0.942 0.698 0.619 1 0.953 CAD 0.995 0.732 0.650 1.049 1 * * <p>% java Arbitrage < rates.txt 1000.00000 USD = 741.00000 EUR 741.00000 EUR = 1012.20600 CAD * 1012.20600 CAD = 1007.14497 USD * * <p>**************************************************************************** */ package edu.princeton.cs.algs4; /** * The {@code Arbitrage} class provides a client that finds an arbitrage opportunity in a currency * exchange table by constructing a complete-digraph representation of the exchange table and then * finding a negative cycle in the digraph. * * <p>This implementation uses the Bellman-Ford algorithm to find a negative cycle in the complete * digraph. The running time is proportional to <em>V</em><sup>3</sup> in the worst case, where * <em>V</em> is the number of currencies. * * <p>For additional documentation, see <a href="https://algs4.cs.princeton.edu/44sp">Section * 4.4</a> of <i>Algorithms, 4th Edition</i> by <NAME> and <NAME>. * * @author <NAME> * @author <NAME> */ public class Arbitrage { // this class cannot be instantiated private Arbitrage() {} /** * Reads the currency exchange table from standard input and prints an arbitrage opportunity to * standard output (if one exists). * * @param args the command-line arguments */ public static void main(String[] args) { // V currencies int V = StdIn.readInt(); String[] name = new String[V]; // create complete network EdgeWeightedDigraph G = new EdgeWeightedDigraph(V); for (int v = 0; v < V; v++) { name[v] = StdIn.readString(); for (int w = 0; w < V; w++) { double rate = StdIn.readDouble(); DirectedEdge e = new DirectedEdge(v, w, -Math.log(rate)); G.addEdge(e); } } // find negative cycle BellmanFordSP spt = new BellmanFordSP(G, 0); if (spt.hasNegativeCycle()) { double stake = 1000.0; for (DirectedEdge e : spt.negativeCycle()) { StdOut.printf("%10.5f %s ", stake, name[e.from()]); stake *= Math.exp(-e.weight()); StdOut.printf("= %10.5f %s\n", stake, name[e.to()]); } } else { StdOut.println("No arbitrage opportunity"); } } } /** * **************************************************************************** Copyright 2002-2019, * <NAME> and <NAME>. * * <p>This file is part of algs4.jar, which accompanies the textbook * * <p>Algorithms, 4th edition by <NAME> and <NAME>, Addison-Wesley Professional, * 2011, ISBN 0-321-57351-X. http://algs4.cs.princeton.edu * * <p>algs4.jar is free software: you can redistribute it and/or modify it under the terms of the * GNU General Public License as published by the Free Software Foundation, either version 3 of the * License, or (at your option) any later version. * * <p>algs4.jar is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without * even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * General Public License for more details. * * <p>You should have received a copy of the GNU General Public License along with algs4.jar. If * not, see http://www.gnu.org/licenses. * **************************************************************************** */
Toromino/chromiumos-platform2
croslog/cursor_util_test.cc
<reponame>Toromino/chromiumos-platform2 // Copyright 2020 The Chromium OS Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "croslog/cursor_util.h" #include <memory> #include <string> #include <utility> #include "base/files/file_path.h" #include "gtest/gtest.h" #include "croslog/log_line_reader.h" #include "croslog/test_util.h" namespace croslog { class CursorUtilTest : public ::testing::Test { public: CursorUtilTest() = default; CursorUtilTest(const CursorUtilTest&) = delete; CursorUtilTest& operator=(const CursorUtilTest&) = delete; }; TEST_F(CursorUtilTest, Generate) { base::Time time1 = TimeFromExploded(2020, 5, 25, 14, 15, 22, 402258, +9); EXPECT_EQ("time=002F0508595AD1D2", GenerateCursor(time1)); base::Time time2 = TimeFromExploded(2021, 10, 5, 12, 5, 43, 465480, +0); EXPECT_EQ("time=002F2C3021DB2E08", GenerateCursor(time2)); base::Time time3 = TimeFromExploded(2019, 3, 14, 1, 22, 23, 2258, -9); EXPECT_EQ("time=002EE2A194D09E92", GenerateCursor(time3)); } TEST_F(CursorUtilTest, Parse) { base::Time output; EXPECT_TRUE(ParseCursor("time=002F0508595AD1D2", &output)); EXPECT_EQ(TimeFromExploded(2020, 5, 25, 14, 15, 22, 402258, +9), output); EXPECT_TRUE(ParseCursor("time=002F2C3021DB2E08", &output)); EXPECT_EQ(TimeFromExploded(2021, 10, 5, 12, 5, 43, 465480, +0), output); EXPECT_TRUE(ParseCursor("time=002EE2A194D09E92", &output)); EXPECT_EQ(TimeFromExploded(2019, 3, 14, 1, 22, 23, 2258, -9), output); } TEST_F(CursorUtilTest, ParseInvalid) { base::Time output; EXPECT_FALSE(ParseCursor("TIME=002F0508595AD1D2", &output)); EXPECT_FALSE(ParseCursor("time=FF2F0508595AD1D2", &output)); EXPECT_FALSE(ParseCursor("time=002F0508595AD1D2;", &output)); EXPECT_FALSE(ParseCursor("time=2F0508595AD1D2", &output)); } } // namespace croslog
shaochangbin/chromium-crosswalk
cc/output/overlay_candidate.cc
<reponame>shaochangbin/chromium-crosswalk // Copyright 2014 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "cc/output/overlay_candidate.h" #include "ui/gfx/rect_conversions.h" namespace cc { OverlayCandidate::OverlayCandidate() : transform(NONE), format(RGBA_8888), uv_rect(0.f, 0.f, 1.f, 1.f), resource_id(0), plane_z_order(0), overlay_handled(false) {} OverlayCandidate::~OverlayCandidate() {} // static OverlayCandidate::OverlayTransform OverlayCandidate::GetOverlayTransform( const gfx::Transform& quad_transform, bool flipped) { if (!quad_transform.IsIdentityOrTranslation()) return INVALID; return flipped ? FLIP_VERTICAL : NONE; } // static gfx::Rect OverlayCandidate::GetOverlayRect(const gfx::Transform& quad_transform, const gfx::Rect& rect) { DCHECK(quad_transform.IsIdentityOrTranslation()); gfx::RectF float_rect(rect); quad_transform.TransformRect(&float_rect); return gfx::ToNearestRect(float_rect); } } // namespace cc
Krozark/Harpe-v1.0
Harpe/harpe/execution/Socket/Socket/FuncWrapper.hpp
<filename>Harpe/harpe/execution/Socket/Socket/FuncWrapper.hpp #ifndef NTW_FUNCWRAPPER #define NTW_FUNCWRAPPER #include <Socket/SocketSerialized.hpp> #include <Socket/define.hpp> namespace ntw { class FuncWrapper { public: FuncWrapper() = delete; FuncWrapper(const FuncWrapper&) = delete; FuncWrapper& operator=(const FuncWrapper&) = delete; static int msg(SocketSerialized& sock,const std::string message,unsigned int code); ///< initialise the socket (client : verify the msg, serveur: send hello) static int verifyIsConnected(SocketSerialized& sock); static int getVersion(SocketSerialized& sock); ///< get serveur version static int testParamInt(SocketSerialized& sock,int); enum FUNCTONS_ID { UNKNOW=0, GET_VERSION, TESTPARAMINT, ANALYSE_ANALYSEMGF, MAX_FN_ID }; #if NTW_MODE == NTW_SERVER static int analyseAnalyseMgf(SocketSerialized& sock,int analyseMGF_pk); static void dispatch(SocketSerialized& request); #endif protected: #if NTW_MODE == NTW_CLIENT template<typename ... Args> static void addPackage(FUNCTONS_ID id,SocketSerialized& sock,Args& ... args); template<typename T,typename ... Args> static void addPackage(SocketSerialized& sock,T& a,Args& ... args); static void addPackage(SocketSerialized& sock); template<typename Ret,typename ... Args> static Ret send(SocketSerialized& sock,FUNCTONS_ID id,Args&& ... args); #else template<typename Ret,typename ... Args> static Ret exec(Ret(*func)(SocketSerialized&,Args ...),SocketSerialized& sock); #endif }; }; #include <Socket/FuncWrapper.tpl> #endif
PerformanceHorizonGroup/JS-Browser-Driver
doc/doc.js
var documentor=require('documentor.js'), api=new documentor.Api({ ns:{ name:'BrowserDriver API', description:"..." }, sourceFiles:[ // '../server/clientManager.js', '../server/server.js', '../client/browserDriver.js', '../client/manager/manager.js' ], sourceLoader:new documentor.FileSourceLoader(), sourceProcessor:new documentor.PHGDoc.PHGSourceProcessor(), renderer:new documentor.PHGDoc.PHGDocRenderer({exportPath:__dirname}), listeners:{ 'sourceQueueEmpty':function (){ // try to set the content of README.md as the desription this.ns.description='<pre>'+this.sourceLoader.getSourceFile(require('path').resolve(__dirname, '../README.md'))+'</pre>'; } } }); //documentor.processArguments(process.argv); //documentor.run();
sezero/windows-sdk-headers
Include/10.0.15063.0/winrt/Windows.ApplicationModel.core.h
<reponame>sezero/windows-sdk-headers<gh_stars>1-10 /* this ALWAYS GENERATED file contains the definitions for the interfaces */ /* File created by MIDL compiler version 8.01.0622 */ /* @@MIDL_FILE_HEADING( ) */ /* verify that the <rpcndr.h> version is high enough to compile this file*/ #ifndef __REQUIRED_RPCNDR_H_VERSION__ #define __REQUIRED_RPCNDR_H_VERSION__ 500 #endif /* verify that the <rpcsal.h> version is high enough to compile this file*/ #ifndef __REQUIRED_RPCSAL_H_VERSION__ #define __REQUIRED_RPCSAL_H_VERSION__ 100 #endif #include "rpc.h" #include "rpcndr.h" #ifndef __RPCNDR_H_VERSION__ #error this stub requires an updated version of <rpcndr.h> #endif /* __RPCNDR_H_VERSION__ */ #ifndef COM_NO_WINDOWS_H #include "windows.h" #include "ole2.h" #endif /*COM_NO_WINDOWS_H*/ #ifndef __windows2Eapplicationmodel2Ecore_h__ #define __windows2Eapplicationmodel2Ecore_h__ #if defined(_MSC_VER) && (_MSC_VER >= 1020) #pragma once #endif /* Forward Declarations */ #ifndef ____FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ #define ____FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ typedef interface __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry; #endif /* ____FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ */ #ifndef ____FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ #define ____FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ typedef interface __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry; #endif /* ____FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ */ #ifndef ____FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ #define ____FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ typedef interface __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView; #endif /* ____FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ */ #ifndef ____FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ #define ____FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ typedef interface __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView; #endif /* ____FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ */ #ifndef ____FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ #define ____FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ typedef interface __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry; #endif /* ____FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ */ #ifndef ____FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ #define ____FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ typedef interface __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView; #endif /* ____FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ */ #ifndef ____FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_FWD_DEFINED__ #define ____FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_FWD_DEFINED__ typedef interface __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs; #endif /* ____FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_FWD_DEFINED__ */ #ifndef ____FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ #define ____FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ typedef interface __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry; #endif /* ____FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ */ #ifndef ____FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ #define ____FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ typedef interface __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry; #endif /* ____FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ */ #ifndef ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_FWD_DEFINED__ #define ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_FWD_DEFINED__ typedef interface __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs; #endif /* ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_FWD_DEFINED__ */ #ifndef ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_FWD_DEFINED__ #define ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_FWD_DEFINED__ typedef interface __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable; #endif /* ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface IAppListEntry; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplication; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplication2; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplicationExit; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplicationUnhandledError; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplicationUseCount; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplicationView; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2 __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplicationView2; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplicationView3; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5 __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplicationView5; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplicationViewTitleBar; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreImmersiveApplication; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2 __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreImmersiveApplication2; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3 __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreImmersiveApplication3; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface IFrameworkView; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface IFrameworkViewSource; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface IHostedViewClosingEventArgs; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface IUnhandledError; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_FWD_DEFINED__ */ #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_FWD_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_FWD_DEFINED__ typedef interface __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs; #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface IUnhandledErrorDetectedEventArgs; } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ #endif /* __cplusplus */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_FWD_DEFINED__ */ /* header files for imported files */ #include "inspectable.h" #include "AsyncInfo.h" #include "EventToken.h" #include "Windows.Foundation.h" #include "Windows.ApplicationModel.h" #ifdef __cplusplus extern "C"{ #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0000 */ /* [local] */ #ifdef __cplusplus } /*extern "C"*/ #endif #include <windows.foundation.collections.h> #ifdef __cplusplus extern "C" { #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { class AppListEntry; } /*Core*/ } /*ApplicationModel*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface IAppListEntry; } /*Core*/ } /*ApplicationModel*/ } /*Windows*/ } #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0000 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0000_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0000_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4632 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4632 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4632_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4632_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0001 */ /* [local] */ #ifndef DEF___FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_USE #define DEF___FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { namespace Collections { template <> struct __declspec(uuid("b93e2028-50bc-599e-b3d9-427b61d26c01")) IIterator<ABI::Windows::ApplicationModel::Core::AppListEntry*> : IIterator_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Core::AppListEntry*, ABI::Windows::ApplicationModel::Core::IAppListEntry*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.Collections.IIterator`1<Windows.ApplicationModel.Core.AppListEntry>"; } }; typedef IIterator<ABI::Windows::ApplicationModel::Core::AppListEntry*> __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_t; #define ____FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ #define __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry ABI::Windows::Foundation::Collections::__FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_t /* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_USE */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0001 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0001_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0001_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4633 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4633 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4633_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4633_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0002 */ /* [local] */ #ifndef DEF___FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_USE #define DEF___FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { namespace Collections { template <> struct __declspec(uuid("86f4d4ef-d8fd-5fb5-807c-72da8fc9e544")) IIterable<ABI::Windows::ApplicationModel::Core::AppListEntry*> : IIterable_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Core::AppListEntry*, ABI::Windows::ApplicationModel::Core::IAppListEntry*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.Collections.IIterable`1<Windows.ApplicationModel.Core.AppListEntry>"; } }; typedef IIterable<ABI::Windows::ApplicationModel::Core::AppListEntry*> __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_t; #define ____FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ #define __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry ABI::Windows::Foundation::Collections::__FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_t /* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_USE */ #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { class CoreApplicationView; } /*Core*/ } /*ApplicationModel*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplicationView; } /*Core*/ } /*ApplicationModel*/ } /*Windows*/ } #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0002 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0002_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0002_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4634 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4634 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4634_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4634_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0003 */ /* [local] */ #ifndef DEF___FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_USE #define DEF___FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { namespace Collections { template <> struct __declspec(uuid("4f5f6944-264b-5868-809e-c7ac1ac5edad")) IIterator<ABI::Windows::ApplicationModel::Core::CoreApplicationView*> : IIterator_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Core::CoreApplicationView*, ABI::Windows::ApplicationModel::Core::ICoreApplicationView*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.Collections.IIterator`1<Windows.ApplicationModel.Core.CoreApplicationView>"; } }; typedef IIterator<ABI::Windows::ApplicationModel::Core::CoreApplicationView*> __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_t; #define ____FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ #define __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView ABI::Windows::Foundation::Collections::__FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_t /* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_USE */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0003 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0003_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0003_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4635 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4635 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4635_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4635_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0004 */ /* [local] */ #ifndef DEF___FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_USE #define DEF___FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { namespace Collections { template <> struct __declspec(uuid("32bc12d1-2653-5a41-a55e-88a12af2026a")) IIterable<ABI::Windows::ApplicationModel::Core::CoreApplicationView*> : IIterable_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Core::CoreApplicationView*, ABI::Windows::ApplicationModel::Core::ICoreApplicationView*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.Collections.IIterable`1<Windows.ApplicationModel.Core.CoreApplicationView>"; } }; typedef IIterable<ABI::Windows::ApplicationModel::Core::CoreApplicationView*> __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_t; #define ____FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ #define __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView ABI::Windows::Foundation::Collections::__FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_t /* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_USE */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0004 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0004_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0004_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4636 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4636 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4636_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4636_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0005 */ /* [local] */ #ifndef DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_USE #define DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { namespace Collections { template <> struct __declspec(uuid("920c8b92-d5ef-5899-8776-2ad97aca6e1d")) IVectorView<ABI::Windows::ApplicationModel::Core::AppListEntry*> : IVectorView_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Core::AppListEntry*, ABI::Windows::ApplicationModel::Core::IAppListEntry*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.Collections.IVectorView`1<Windows.ApplicationModel.Core.AppListEntry>"; } }; typedef IVectorView<ABI::Windows::ApplicationModel::Core::AppListEntry*> __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_t; #define ____FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ #define __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry ABI::Windows::Foundation::Collections::__FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_t /* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_USE */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0005 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0005_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0005_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4637 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4637 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4637_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4637_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0006 */ /* [local] */ #ifndef DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_USE #define DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { namespace Collections { template <> struct __declspec(uuid("de9e16c4-1b7c-5126-b1d8-7cd04f13bd08")) IVectorView<ABI::Windows::ApplicationModel::Core::CoreApplicationView*> : IVectorView_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Core::CoreApplicationView*, ABI::Windows::ApplicationModel::Core::ICoreApplicationView*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.Collections.IVectorView`1<Windows.ApplicationModel.Core.CoreApplicationView>"; } }; typedef IVectorView<ABI::Windows::ApplicationModel::Core::CoreApplicationView*> __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_t; #define ____FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_FWD_DEFINED__ #define __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView ABI::Windows::Foundation::Collections::__FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_t /* ABI */ } /* Windows */ } /* Foundation */ } /* Collections */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_USE */ #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { class UnhandledErrorDetectedEventArgs; } /*Core*/ } /*ApplicationModel*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface IUnhandledErrorDetectedEventArgs; } /*Core*/ } /*ApplicationModel*/ } /*Windows*/ } #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0006 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0006_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0006_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4638 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4638 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4638_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4638_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0007 */ /* [local] */ #ifndef DEF___FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_USE #define DEF___FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("f68bc421-6b54-559b-9cdd-489aad0bd41d")) IEventHandler<ABI::Windows::ApplicationModel::Core::UnhandledErrorDetectedEventArgs*> : IEventHandler_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Core::UnhandledErrorDetectedEventArgs*, ABI::Windows::ApplicationModel::Core::IUnhandledErrorDetectedEventArgs*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.EventHandler`1<Windows.ApplicationModel.Core.UnhandledErrorDetectedEventArgs>"; } }; typedef IEventHandler<ABI::Windows::ApplicationModel::Core::UnhandledErrorDetectedEventArgs*> __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_t; #define ____FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_FWD_DEFINED__ #define __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs ABI::Windows::Foundation::__FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_USE */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0007 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0007_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0007_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4639 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4639 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4639_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4639_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0008 */ /* [local] */ #ifndef DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_USE #define DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("51c74372-9452-57ce-9270-762009fbfe4d")) IAsyncOperationCompletedHandler<__FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry*> : IAsyncOperationCompletedHandler_impl<__FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry*> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.AsyncOperationCompletedHandler`1<Windows.Foundation.Collections.IVectorView`1<Windows.ApplicationModel.Core.AppListEntry>>"; } }; typedef IAsyncOperationCompletedHandler<__FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry*> __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_t; #define ____FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ #define __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry ABI::Windows::Foundation::__FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_USE */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0008 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0008_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0008_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4640 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4640 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4640_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4640_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0009 */ /* [local] */ #ifndef DEF___FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_USE #define DEF___FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("d3bcf8a0-3538-5dae-98d7-1f2ab88c3f01")) IAsyncOperation<__FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry*> : IAsyncOperation_impl<__FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry*> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.IAsyncOperation`1<Windows.Foundation.Collections.IVectorView`1<Windows.ApplicationModel.Core.AppListEntry>>"; } }; typedef IAsyncOperation<__FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry*> __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_t; #define ____FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_FWD_DEFINED__ #define __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry ABI::Windows::Foundation::__FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_USE */ #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { class HostedViewClosingEventArgs; } /*Core*/ } /*ApplicationModel*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface IHostedViewClosingEventArgs; } /*Core*/ } /*ApplicationModel*/ } /*Windows*/ } #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0009 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0009_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0009_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4641 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4641 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4641_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4641_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0010 */ /* [local] */ #ifndef DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_USE #define DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("d9a3f433-9bcc-54d6-b3cf-7b01f026d4cd")) ITypedEventHandler<ABI::Windows::ApplicationModel::Core::CoreApplicationView*,ABI::Windows::ApplicationModel::Core::HostedViewClosingEventArgs*> : ITypedEventHandler_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Core::CoreApplicationView*, ABI::Windows::ApplicationModel::Core::ICoreApplicationView*>,ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Core::HostedViewClosingEventArgs*, ABI::Windows::ApplicationModel::Core::IHostedViewClosingEventArgs*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.TypedEventHandler`2<Windows.ApplicationModel.Core.CoreApplicationView, Windows.ApplicationModel.Core.HostedViewClosingEventArgs>"; } }; typedef ITypedEventHandler<ABI::Windows::ApplicationModel::Core::CoreApplicationView*,ABI::Windows::ApplicationModel::Core::HostedViewClosingEventArgs*> __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_t; #define ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_FWD_DEFINED__ #define __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs ABI::Windows::Foundation::__FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_USE */ #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { class CoreApplicationViewTitleBar; } /*Core*/ } /*ApplicationModel*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { interface ICoreApplicationViewTitleBar; } /*Core*/ } /*ApplicationModel*/ } /*Windows*/ } #endif interface IInspectable; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0010 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0010_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0010_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4642 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4642 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4642_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4642_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0011 */ /* [local] */ #ifndef DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_USE #define DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("28342e21-dad3-5e32-bae1-afe7b26c66fb")) ITypedEventHandler<ABI::Windows::ApplicationModel::Core::CoreApplicationViewTitleBar*,IInspectable*> : ITypedEventHandler_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Core::CoreApplicationViewTitleBar*, ABI::Windows::ApplicationModel::Core::ICoreApplicationViewTitleBar*>,IInspectable*> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.TypedEventHandler`2<Windows.ApplicationModel.Core.CoreApplicationViewTitleBar, Object>"; } }; typedef ITypedEventHandler<ABI::Windows::ApplicationModel::Core::CoreApplicationViewTitleBar*,IInspectable*> __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_t; #define ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_FWD_DEFINED__ #define __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable ABI::Windows::Foundation::__FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_USE */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0011 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0011_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0011_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4643 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4643 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4643_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4643_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0012 */ /* [local] */ #ifndef DEF___FIAsyncOperationCompletedHandler_1_boolean_USE #define DEF___FIAsyncOperationCompletedHandler_1_boolean_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("c1d3d1a2-ae17-5a5f-b5a2-bdcc8844889a")) IAsyncOperationCompletedHandler<bool> : IAsyncOperationCompletedHandler_impl<ABI::Windows::Foundation::Internal::AggregateType<bool, boolean>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.AsyncOperationCompletedHandler`1<Boolean>"; } }; typedef IAsyncOperationCompletedHandler<bool> __FIAsyncOperationCompletedHandler_1_boolean_t; #define ____FIAsyncOperationCompletedHandler_1_boolean_FWD_DEFINED__ #define __FIAsyncOperationCompletedHandler_1_boolean ABI::Windows::Foundation::__FIAsyncOperationCompletedHandler_1_boolean_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIAsyncOperationCompletedHandler_1_boolean_USE */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0012 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0012_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0012_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4644 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4644 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4644_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4644_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0013 */ /* [local] */ #ifndef DEF___FIAsyncOperation_1_boolean_USE #define DEF___FIAsyncOperation_1_boolean_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("cdb5efb3-5788-509d-9be1-71ccb8a3362a")) IAsyncOperation<bool> : IAsyncOperation_impl<ABI::Windows::Foundation::Internal::AggregateType<bool, boolean>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.IAsyncOperation`1<Boolean>"; } }; typedef IAsyncOperation<bool> __FIAsyncOperation_1_boolean_t; #define ____FIAsyncOperation_1_boolean_FWD_DEFINED__ #define __FIAsyncOperation_1_boolean ABI::Windows::Foundation::__FIAsyncOperation_1_boolean_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIAsyncOperation_1_boolean_USE */ #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { class SuspendingEventArgs; } /*ApplicationModel*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { interface ISuspendingEventArgs; } /*ApplicationModel*/ } /*Windows*/ } #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0013 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0013_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0013_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4645 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4645 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4645_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4645_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0014 */ /* [local] */ #ifndef DEF___FIEventHandler_1_Windows__CApplicationModel__CSuspendingEventArgs_USE #define DEF___FIEventHandler_1_Windows__CApplicationModel__CSuspendingEventArgs_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("338579bf-1a35-5cc4-a622-a6f384fd892c")) IEventHandler<ABI::Windows::ApplicationModel::SuspendingEventArgs*> : IEventHandler_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::SuspendingEventArgs*, ABI::Windows::ApplicationModel::ISuspendingEventArgs*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.EventHandler`1<Windows.ApplicationModel.SuspendingEventArgs>"; } }; typedef IEventHandler<ABI::Windows::ApplicationModel::SuspendingEventArgs*> __FIEventHandler_1_Windows__CApplicationModel__CSuspendingEventArgs_t; #define ____FIEventHandler_1_Windows__CApplicationModel__CSuspendingEventArgs_FWD_DEFINED__ #define __FIEventHandler_1_Windows__CApplicationModel__CSuspendingEventArgs ABI::Windows::Foundation::__FIEventHandler_1_Windows__CApplicationModel__CSuspendingEventArgs_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIEventHandler_1_Windows__CApplicationModel__CSuspendingEventArgs_USE */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0014 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0014_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0014_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4646 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4646 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4646_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4646_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0015 */ /* [local] */ #ifndef DEF___FIEventHandler_1_IInspectable_USE #define DEF___FIEventHandler_1_IInspectable_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("c50898f6-c536-5f47-8583-8b2c2438a13b")) IEventHandler<IInspectable*> : IEventHandler_impl<IInspectable*> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.EventHandler`1<Object>"; } }; typedef IEventHandler<IInspectable*> __FIEventHandler_1_IInspectable_t; #define ____FIEventHandler_1_IInspectable_FWD_DEFINED__ #define __FIEventHandler_1_IInspectable ABI::Windows::Foundation::__FIEventHandler_1_IInspectable_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIEventHandler_1_IInspectable_USE */ #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Activation { class BackgroundActivatedEventArgs; } /*Activation*/ } /*ApplicationModel*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Activation { interface IBackgroundActivatedEventArgs; } /*Activation*/ } /*ApplicationModel*/ } /*Windows*/ } #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0015 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0015_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0015_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4647 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4647 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4647_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4647_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0016 */ /* [local] */ #ifndef DEF___FIEventHandler_1_Windows__CApplicationModel__CActivation__CBackgroundActivatedEventArgs_USE #define DEF___FIEventHandler_1_Windows__CApplicationModel__CActivation__CBackgroundActivatedEventArgs_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("49a07732-e7b8-5c5b-9de7-22e33cb97004")) IEventHandler<ABI::Windows::ApplicationModel::Activation::BackgroundActivatedEventArgs*> : IEventHandler_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Activation::BackgroundActivatedEventArgs*, ABI::Windows::ApplicationModel::Activation::IBackgroundActivatedEventArgs*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.EventHandler`1<Windows.ApplicationModel.Activation.BackgroundActivatedEventArgs>"; } }; typedef IEventHandler<ABI::Windows::ApplicationModel::Activation::BackgroundActivatedEventArgs*> __FIEventHandler_1_Windows__CApplicationModel__CActivation__CBackgroundActivatedEventArgs_t; #define ____FIEventHandler_1_Windows__CApplicationModel__CActivation__CBackgroundActivatedEventArgs_FWD_DEFINED__ #define __FIEventHandler_1_Windows__CApplicationModel__CActivation__CBackgroundActivatedEventArgs ABI::Windows::Foundation::__FIEventHandler_1_Windows__CApplicationModel__CActivation__CBackgroundActivatedEventArgs_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIEventHandler_1_Windows__CApplicationModel__CActivation__CBackgroundActivatedEventArgs_USE */ #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { class LeavingBackgroundEventArgs; } /*ApplicationModel*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { interface ILeavingBackgroundEventArgs; } /*ApplicationModel*/ } /*Windows*/ } #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0016 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0016_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0016_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4648 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4648 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4648_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4648_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0017 */ /* [local] */ #ifndef DEF___FIEventHandler_1_Windows__CApplicationModel__CLeavingBackgroundEventArgs_USE #define DEF___FIEventHandler_1_Windows__CApplicationModel__CLeavingBackgroundEventArgs_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("9b6171c2-abb2-5194-afc0-cef167c424eb")) IEventHandler<ABI::Windows::ApplicationModel::LeavingBackgroundEventArgs*> : IEventHandler_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::LeavingBackgroundEventArgs*, ABI::Windows::ApplicationModel::ILeavingBackgroundEventArgs*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.EventHandler`1<Windows.ApplicationModel.LeavingBackgroundEventArgs>"; } }; typedef IEventHandler<ABI::Windows::ApplicationModel::LeavingBackgroundEventArgs*> __FIEventHandler_1_Windows__CApplicationModel__CLeavingBackgroundEventArgs_t; #define ____FIEventHandler_1_Windows__CApplicationModel__CLeavingBackgroundEventArgs_FWD_DEFINED__ #define __FIEventHandler_1_Windows__CApplicationModel__CLeavingBackgroundEventArgs ABI::Windows::Foundation::__FIEventHandler_1_Windows__CApplicationModel__CLeavingBackgroundEventArgs_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIEventHandler_1_Windows__CApplicationModel__CLeavingBackgroundEventArgs_USE */ #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { class EnteredBackgroundEventArgs; } /*ApplicationModel*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { interface IEnteredBackgroundEventArgs; } /*ApplicationModel*/ } /*Windows*/ } #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0017 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0017_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0017_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4649 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4649 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4649_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4649_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0018 */ /* [local] */ #ifndef DEF___FIEventHandler_1_Windows__CApplicationModel__CEnteredBackgroundEventArgs_USE #define DEF___FIEventHandler_1_Windows__CApplicationModel__CEnteredBackgroundEventArgs_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("e0739c32-fc14-5361-a8b3-0809699fbcbd")) IEventHandler<ABI::Windows::ApplicationModel::EnteredBackgroundEventArgs*> : IEventHandler_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::EnteredBackgroundEventArgs*, ABI::Windows::ApplicationModel::IEnteredBackgroundEventArgs*>> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.EventHandler`1<Windows.ApplicationModel.EnteredBackgroundEventArgs>"; } }; typedef IEventHandler<ABI::Windows::ApplicationModel::EnteredBackgroundEventArgs*> __FIEventHandler_1_Windows__CApplicationModel__CEnteredBackgroundEventArgs_t; #define ____FIEventHandler_1_Windows__CApplicationModel__CEnteredBackgroundEventArgs_FWD_DEFINED__ #define __FIEventHandler_1_Windows__CApplicationModel__CEnteredBackgroundEventArgs ABI::Windows::Foundation::__FIEventHandler_1_Windows__CApplicationModel__CEnteredBackgroundEventArgs_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FIEventHandler_1_Windows__CApplicationModel__CEnteredBackgroundEventArgs_USE */ #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Activation { interface IActivatedEventArgs; } /*Activation*/ } /*ApplicationModel*/ } /*Windows*/ } #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0018 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0018_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0018_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4650 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4650 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4650_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4650_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0019 */ /* [local] */ #ifndef DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CActivation__CIActivatedEventArgs_USE #define DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CActivation__CIActivatedEventArgs_USE #if defined(__cplusplus) && !defined(RO_NO_TEMPLATE_NAME) } /*extern "C"*/ namespace ABI { namespace Windows { namespace Foundation { template <> struct __declspec(uuid("cf193a96-eb13-5e3b-8bdf-87b6efae8339")) ITypedEventHandler<ABI::Windows::ApplicationModel::Core::CoreApplicationView*,ABI::Windows::ApplicationModel::Activation::IActivatedEventArgs*> : ITypedEventHandler_impl<ABI::Windows::Foundation::Internal::AggregateType<ABI::Windows::ApplicationModel::Core::CoreApplicationView*, ABI::Windows::ApplicationModel::Core::ICoreApplicationView*>,ABI::Windows::ApplicationModel::Activation::IActivatedEventArgs*> { static const wchar_t* z_get_rc_name_impl() { return L"Windows.Foundation.TypedEventHandler`2<Windows.ApplicationModel.Core.CoreApplicationView, Windows.ApplicationModel.Activation.IActivatedEventArgs>"; } }; typedef ITypedEventHandler<ABI::Windows::ApplicationModel::Core::CoreApplicationView*,ABI::Windows::ApplicationModel::Activation::IActivatedEventArgs*> __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CActivation__CIActivatedEventArgs_t; #define ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CActivation__CIActivatedEventArgs_FWD_DEFINED__ #define __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CActivation__CIActivatedEventArgs ABI::Windows::Foundation::__FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CActivation__CIActivatedEventArgs_t /* ABI */ } /* Windows */ } /* Foundation */ } extern "C" { #endif //__cplusplus #endif /* DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CActivation__CIActivatedEventArgs_USE */ #if defined(__cplusplus) } #endif // defined(__cplusplus) #include <Windows.Foundation.h> #if !defined(__windows2Eapplicationmodel_h__) #include <Windows.ApplicationModel.h> #endif // !defined(__windows2Eapplicationmodel_h__) #if !defined(__windows2Eapplicationmodel2Eactivation_h__) #include <Windows.ApplicationModel.Activation.h> #endif // !defined(__windows2Eapplicationmodel2Eactivation_h__) #if !defined(__windows2Eui2Ecore_h__) #include <Windows.UI.Core.h> #endif // !defined(__windows2Eui2Ecore_h__) #if defined(__cplusplus) extern "C" { #endif // defined(__cplusplus) #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { class AppDisplayInfo; } /*ApplicationModel*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace Foundation { class Deferral; } /*Foundation*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace UI { namespace Core { class CoreDispatcher; } /*Core*/ } /*UI*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace UI { namespace Core { class CoreWindow; } /*Core*/ } /*UI*/ } /*Windows*/ } #endif #ifdef __cplusplus namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { class UnhandledError; } /*Core*/ } /*ApplicationModel*/ } /*Windows*/ } #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0019 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0019_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0019_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4651 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4651 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4651_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4651_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0020 */ /* [local] */ #ifndef DEF___FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry #define DEF___FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry #if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME) /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0020 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0020_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0020_v0_0_s_ifspec; #ifndef ____FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ #define ____FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ /* interface __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* [unique][uuid][object] */ /* interface __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* [unique][uuid][object] */ EXTERN_C const IID IID___FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry; #if defined(__cplusplus) && !defined(CINTERFACE) MIDL_INTERFACE("b93e2028-50bc-599e-b3d9-427b61d26c01") __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry : public IInspectable { public: virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Current( /* [retval][out] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::IAppListEntry **current) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_HasCurrent( /* [retval][out] */ __RPC__out boolean *hasCurrent) = 0; virtual HRESULT STDMETHODCALLTYPE MoveNext( /* [retval][out] */ __RPC__out boolean *hasCurrent) = 0; virtual HRESULT STDMETHODCALLTYPE GetMany( /* [in] */ unsigned int capacity, /* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::ApplicationModel::Core::IAppListEntry **items, /* [retval][out] */ __RPC__out unsigned int *actual) = 0; }; #else /* C style interface */ typedef struct __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Current )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry **current); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_HasCurrent )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [retval][out] */ __RPC__out boolean *hasCurrent); HRESULT ( STDMETHODCALLTYPE *MoveNext )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [retval][out] */ __RPC__out boolean *hasCurrent); HRESULT ( STDMETHODCALLTYPE *GetMany )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [in] */ unsigned int capacity, /* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry **items, /* [retval][out] */ __RPC__out unsigned int *actual); END_INTERFACE } __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl; interface __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry { CONST_VTBL struct __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl *lpVtbl; }; #ifdef COBJMACROS #define __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_get_Current(This,current) \ ( (This)->lpVtbl -> get_Current(This,current) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_get_HasCurrent(This,hasCurrent) \ ( (This)->lpVtbl -> get_HasCurrent(This,hasCurrent) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_MoveNext(This,hasCurrent) \ ( (This)->lpVtbl -> MoveNext(This,hasCurrent) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_GetMany(This,capacity,items,actual) \ ( (This)->lpVtbl -> GetMany(This,capacity,items,actual) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0021 */ /* [local] */ #endif /* pinterface */ #endif /* DEF___FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0021 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0021_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0021_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4652 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4652 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4652_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4652_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0022 */ /* [local] */ #ifndef DEF___FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry #define DEF___FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry #if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME) /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0022 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0022_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0022_v0_0_s_ifspec; #ifndef ____FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ #define ____FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ /* interface __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* [unique][uuid][object] */ /* interface __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* [unique][uuid][object] */ EXTERN_C const IID IID___FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry; #if defined(__cplusplus) && !defined(CINTERFACE) MIDL_INTERFACE("86f4d4ef-d8fd-5fb5-807c-72da8fc9e544") __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE First( /* [retval][out] */ __RPC__deref_out_opt __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry **first) = 0; }; #else /* C style interface */ typedef struct __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *First )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [retval][out] */ __RPC__deref_out_opt __FIIterator_1_Windows__CApplicationModel__CCore__CAppListEntry **first); END_INTERFACE } __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl; interface __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry { CONST_VTBL struct __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl *lpVtbl; }; #ifdef COBJMACROS #define __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_First(This,first) \ ( (This)->lpVtbl -> First(This,first) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0023 */ /* [local] */ #endif /* pinterface */ #endif /* DEF___FIIterable_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0023 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0023_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0023_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4653 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4653 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4653_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4653_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0024 */ /* [local] */ #ifndef DEF___FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView #define DEF___FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView #if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME) /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0024 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0024_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0024_v0_0_s_ifspec; #ifndef ____FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_INTERFACE_DEFINED__ #define ____FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_INTERFACE_DEFINED__ /* interface __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView */ /* [unique][uuid][object] */ /* interface __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView */ /* [unique][uuid][object] */ EXTERN_C const IID IID___FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView; #if defined(__cplusplus) && !defined(CINTERFACE) MIDL_INTERFACE("4f5f6944-264b-5868-809e-c7ac1ac5edad") __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView : public IInspectable { public: virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Current( /* [retval][out] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationView **current) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_HasCurrent( /* [retval][out] */ __RPC__out boolean *hasCurrent) = 0; virtual HRESULT STDMETHODCALLTYPE MoveNext( /* [retval][out] */ __RPC__out boolean *hasCurrent) = 0; virtual HRESULT STDMETHODCALLTYPE GetMany( /* [in] */ unsigned int capacity, /* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::ApplicationModel::Core::ICoreApplicationView **items, /* [retval][out] */ __RPC__out unsigned int *actual) = 0; }; #else /* C style interface */ typedef struct __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationViewVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Current )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView **current); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_HasCurrent )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [retval][out] */ __RPC__out boolean *hasCurrent); HRESULT ( STDMETHODCALLTYPE *MoveNext )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [retval][out] */ __RPC__out boolean *hasCurrent); HRESULT ( STDMETHODCALLTYPE *GetMany )( __RPC__in __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [in] */ unsigned int capacity, /* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView **items, /* [retval][out] */ __RPC__out unsigned int *actual); END_INTERFACE } __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationViewVtbl; interface __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView { CONST_VTBL struct __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationViewVtbl *lpVtbl; }; #ifdef COBJMACROS #define __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_get_Current(This,current) \ ( (This)->lpVtbl -> get_Current(This,current) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_get_HasCurrent(This,hasCurrent) \ ( (This)->lpVtbl -> get_HasCurrent(This,hasCurrent) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_MoveNext(This,hasCurrent) \ ( (This)->lpVtbl -> MoveNext(This,hasCurrent) ) #define __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetMany(This,capacity,items,actual) \ ( (This)->lpVtbl -> GetMany(This,capacity,items,actual) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0025 */ /* [local] */ #endif /* pinterface */ #endif /* DEF___FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0025 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0025_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0025_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4654 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4654 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4654_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4654_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0026 */ /* [local] */ #ifndef DEF___FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView #define DEF___FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView #if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME) /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0026 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0026_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0026_v0_0_s_ifspec; #ifndef ____FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_INTERFACE_DEFINED__ #define ____FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_INTERFACE_DEFINED__ /* interface __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView */ /* [unique][uuid][object] */ /* interface __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView */ /* [unique][uuid][object] */ EXTERN_C const IID IID___FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView; #if defined(__cplusplus) && !defined(CINTERFACE) MIDL_INTERFACE("32bc12d1-2653-5a41-a55e-88a12af2026a") __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE First( /* [retval][out] */ __RPC__deref_out_opt __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView **first) = 0; }; #else /* C style interface */ typedef struct __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationViewVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *First )( __RPC__in __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [retval][out] */ __RPC__deref_out_opt __FIIterator_1_Windows__CApplicationModel__CCore__CCoreApplicationView **first); END_INTERFACE } __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationViewVtbl; interface __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView { CONST_VTBL struct __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationViewVtbl *lpVtbl; }; #ifdef COBJMACROS #define __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_First(This,first) \ ( (This)->lpVtbl -> First(This,first) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0027 */ /* [local] */ #endif /* pinterface */ #endif /* DEF___FIIterable_1_Windows__CApplicationModel__CCore__CCoreApplicationView */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0027 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0027_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0027_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4655 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4655 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4655_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4655_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0028 */ /* [local] */ #ifndef DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry #define DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry #if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME) /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0028 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0028_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0028_v0_0_s_ifspec; #ifndef ____FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ #define ____FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ /* interface __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* [unique][uuid][object] */ /* interface __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* [unique][uuid][object] */ EXTERN_C const IID IID___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry; #if defined(__cplusplus) && !defined(CINTERFACE) MIDL_INTERFACE("920c8b92-d5ef-5899-8776-2ad97aca6e1d") __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE GetAt( /* [in] */ unsigned int index, /* [retval][out] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::IAppListEntry **item) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Size( /* [retval][out] */ __RPC__out unsigned int *size) = 0; virtual HRESULT STDMETHODCALLTYPE IndexOf( /* [in] */ __RPC__in_opt ABI::Windows::ApplicationModel::Core::IAppListEntry *item, /* [out] */ __RPC__out unsigned int *index, /* [retval][out] */ __RPC__out boolean *found) = 0; virtual HRESULT STDMETHODCALLTYPE GetMany( /* [in] */ unsigned int startIndex, /* [in] */ unsigned int capacity, /* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::ApplicationModel::Core::IAppListEntry **items, /* [retval][out] */ __RPC__out unsigned int *actual) = 0; }; #else /* C style interface */ typedef struct __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *GetAt )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [in] */ unsigned int index, /* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry **item); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Size )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [retval][out] */ __RPC__out unsigned int *size); HRESULT ( STDMETHODCALLTYPE *IndexOf )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [in] */ __RPC__in_opt __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry *item, /* [out] */ __RPC__out unsigned int *index, /* [retval][out] */ __RPC__out boolean *found); HRESULT ( STDMETHODCALLTYPE *GetMany )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [in] */ unsigned int startIndex, /* [in] */ unsigned int capacity, /* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry **items, /* [retval][out] */ __RPC__out unsigned int *actual); END_INTERFACE } __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl; interface __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry { CONST_VTBL struct __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl *lpVtbl; }; #ifdef COBJMACROS #define __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_GetAt(This,index,item) \ ( (This)->lpVtbl -> GetAt(This,index,item) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_get_Size(This,size) \ ( (This)->lpVtbl -> get_Size(This,size) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_IndexOf(This,item,index,found) \ ( (This)->lpVtbl -> IndexOf(This,item,index,found) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_GetMany(This,startIndex,capacity,items,actual) \ ( (This)->lpVtbl -> GetMany(This,startIndex,capacity,items,actual) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0029 */ /* [local] */ #endif /* pinterface */ #endif /* DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0029 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0029_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0029_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4656 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4656 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4656_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4656_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0030 */ /* [local] */ #ifndef DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView #define DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView #if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME) /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0030 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0030_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0030_v0_0_s_ifspec; #ifndef ____FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_INTERFACE_DEFINED__ #define ____FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_INTERFACE_DEFINED__ /* interface __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView */ /* [unique][uuid][object] */ /* interface __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView */ /* [unique][uuid][object] */ EXTERN_C const IID IID___FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView; #if defined(__cplusplus) && !defined(CINTERFACE) MIDL_INTERFACE("de9e16c4-1b7c-5126-b1d8-7cd04f13bd08") __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE GetAt( /* [in] */ unsigned int index, /* [retval][out] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationView **item) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Size( /* [retval][out] */ __RPC__out unsigned int *size) = 0; virtual HRESULT STDMETHODCALLTYPE IndexOf( /* [in] */ __RPC__in_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationView *item, /* [out] */ __RPC__out unsigned int *index, /* [retval][out] */ __RPC__out boolean *found) = 0; virtual HRESULT STDMETHODCALLTYPE GetMany( /* [in] */ unsigned int startIndex, /* [in] */ unsigned int capacity, /* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) ABI::Windows::ApplicationModel::Core::ICoreApplicationView **items, /* [retval][out] */ __RPC__out unsigned int *actual) = 0; }; #else /* C style interface */ typedef struct __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationViewVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *GetAt )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [in] */ unsigned int index, /* [retval][out] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView **item); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Size )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [retval][out] */ __RPC__out unsigned int *size); HRESULT ( STDMETHODCALLTYPE *IndexOf )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [in] */ __RPC__in_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView *item, /* [out] */ __RPC__out unsigned int *index, /* [retval][out] */ __RPC__out boolean *found); HRESULT ( STDMETHODCALLTYPE *GetMany )( __RPC__in __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView * This, /* [in] */ unsigned int startIndex, /* [in] */ unsigned int capacity, /* [size_is][length_is][out] */ __RPC__out_ecount_part(capacity, *actual) __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView **items, /* [retval][out] */ __RPC__out unsigned int *actual); END_INTERFACE } __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationViewVtbl; interface __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView { CONST_VTBL struct __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationViewVtbl *lpVtbl; }; #ifdef COBJMACROS #define __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetAt(This,index,item) \ ( (This)->lpVtbl -> GetAt(This,index,item) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_get_Size(This,size) \ ( (This)->lpVtbl -> get_Size(This,size) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_IndexOf(This,item,index,found) \ ( (This)->lpVtbl -> IndexOf(This,item,index,found) ) #define __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_GetMany(This,startIndex,capacity,items,actual) \ ( (This)->lpVtbl -> GetMany(This,startIndex,capacity,items,actual) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0031 */ /* [local] */ #endif /* pinterface */ #endif /* DEF___FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0031 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0031_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0031_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4657 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4657 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4657_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4657_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0032 */ /* [local] */ #ifndef DEF___FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs #define DEF___FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs #if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME) /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0032 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0032_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0032_v0_0_s_ifspec; #ifndef ____FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_INTERFACE_DEFINED__ #define ____FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_INTERFACE_DEFINED__ /* interface __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs */ /* [unique][uuid][object] */ /* interface __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs */ /* [unique][uuid][object] */ EXTERN_C const IID IID___FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs; #if defined(__cplusplus) && !defined(CINTERFACE) MIDL_INTERFACE("f68bc421-6b54-559b-9cdd-489aad0bd41d") __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs : public IUnknown { public: virtual HRESULT STDMETHODCALLTYPE Invoke( /* [in] */ __RPC__in_opt IInspectable *sender, /* [in] */ __RPC__in_opt ABI::Windows::ApplicationModel::Core::IUnhandledErrorDetectedEventArgs *e) = 0; }; #else /* C style interface */ typedef struct __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgsVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs * This); HRESULT ( STDMETHODCALLTYPE *Invoke )( __RPC__in __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs * This, /* [in] */ __RPC__in_opt IInspectable *sender, /* [in] */ __RPC__in_opt __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs *e); END_INTERFACE } __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgsVtbl; interface __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs { CONST_VTBL struct __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgsVtbl *lpVtbl; }; #ifdef COBJMACROS #define __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_Invoke(This,sender,e) \ ( (This)->lpVtbl -> Invoke(This,sender,e) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0033 */ /* [local] */ #endif /* pinterface */ #endif /* DEF___FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0033 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0033_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0033_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4658 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4658 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4658_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4658_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0034 */ /* [local] */ #ifndef DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry #define DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry #if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME) /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0034 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0034_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0034_v0_0_s_ifspec; #ifndef ____FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ #define ____FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ /* interface __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* [unique][uuid][object] */ /* interface __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* [unique][uuid][object] */ EXTERN_C const IID IID___FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry; #if defined(__cplusplus) && !defined(CINTERFACE) MIDL_INTERFACE("51c74372-9452-57ce-9270-762009fbfe4d") __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry : public IUnknown { public: virtual HRESULT STDMETHODCALLTYPE Invoke( /* [in] */ __RPC__in_opt __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry *asyncInfo, /* [in] */ AsyncStatus status) = 0; }; #else /* C style interface */ typedef struct __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This); HRESULT ( STDMETHODCALLTYPE *Invoke )( __RPC__in __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [in] */ __RPC__in_opt __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry *asyncInfo, /* [in] */ AsyncStatus status); END_INTERFACE } __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl; interface __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry { CONST_VTBL struct __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl *lpVtbl; }; #ifdef COBJMACROS #define __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_Invoke(This,asyncInfo,status) \ ( (This)->lpVtbl -> Invoke(This,asyncInfo,status) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0035 */ /* [local] */ #endif /* pinterface */ #endif /* DEF___FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0035 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0035_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0035_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4659 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4659 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4659_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4659_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0036 */ /* [local] */ #ifndef DEF___FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry #define DEF___FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry #if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME) /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0036 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0036_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0036_v0_0_s_ifspec; #ifndef ____FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ #define ____FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ /* interface __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* [unique][uuid][object] */ /* interface __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* [unique][uuid][object] */ EXTERN_C const IID IID___FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry; #if defined(__cplusplus) && !defined(CINTERFACE) MIDL_INTERFACE("d3bcf8a0-3538-5dae-98d7-1f2ab88c3f01") __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry : public IInspectable { public: virtual /* [propput] */ HRESULT STDMETHODCALLTYPE put_Completed( /* [in] */ __RPC__in_opt __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry *handler) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Completed( /* [retval][out] */ __RPC__deref_out_opt __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry **handler) = 0; virtual HRESULT STDMETHODCALLTYPE GetResults( /* [retval][out] */ __RPC__deref_out_opt __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry **results) = 0; }; #else /* C style interface */ typedef struct __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propput] */ HRESULT ( STDMETHODCALLTYPE *put_Completed )( __RPC__in __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [in] */ __RPC__in_opt __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry *handler); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Completed )( __RPC__in __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [retval][out] */ __RPC__deref_out_opt __FIAsyncOperationCompletedHandler_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry **handler); HRESULT ( STDMETHODCALLTYPE *GetResults )( __RPC__in __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry * This, /* [retval][out] */ __RPC__deref_out_opt __FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry **results); END_INTERFACE } __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl; interface __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry { CONST_VTBL struct __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntryVtbl *lpVtbl; }; #ifdef COBJMACROS #define __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_put_Completed(This,handler) \ ( (This)->lpVtbl -> put_Completed(This,handler) ) #define __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_get_Completed(This,handler) \ ( (This)->lpVtbl -> get_Completed(This,handler) ) #define __FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_GetResults(This,results) \ ( (This)->lpVtbl -> GetResults(This,results) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0037 */ /* [local] */ #endif /* pinterface */ #endif /* DEF___FIAsyncOperation_1___FIVectorView_1_Windows__CApplicationModel__CCore__CAppListEntry */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0037 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0037_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0037_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4660 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4660 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4660_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4660_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0038 */ /* [local] */ #ifndef DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs #define DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs #if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME) /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0038 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0038_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0038_v0_0_s_ifspec; #ifndef ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_INTERFACE_DEFINED__ #define ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_INTERFACE_DEFINED__ /* interface __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs */ /* [unique][uuid][object] */ /* interface __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs */ /* [unique][uuid][object] */ EXTERN_C const IID IID___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs; #if defined(__cplusplus) && !defined(CINTERFACE) MIDL_INTERFACE("d9a3f433-9bcc-54d6-b3cf-7b01f026d4cd") __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs : public IUnknown { public: virtual HRESULT STDMETHODCALLTYPE Invoke( /* [in] */ __RPC__in_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationView *sender, /* [in] */ __RPC__in_opt ABI::Windows::ApplicationModel::Core::IHostedViewClosingEventArgs *e) = 0; }; #else /* C style interface */ typedef struct __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgsVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs * This); HRESULT ( STDMETHODCALLTYPE *Invoke )( __RPC__in __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs * This, /* [in] */ __RPC__in_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView *sender, /* [in] */ __RPC__in_opt __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs *e); END_INTERFACE } __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgsVtbl; interface __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs { CONST_VTBL struct __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgsVtbl *lpVtbl; }; #ifdef COBJMACROS #define __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_Invoke(This,sender,e) \ ( (This)->lpVtbl -> Invoke(This,sender,e) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0039 */ /* [local] */ #endif /* pinterface */ #endif /* DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0039 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0039_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0039_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4661 */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4661 */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4661_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore2Eidl_0000_4661_v0_0_s_ifspec; /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0040 */ /* [local] */ #ifndef DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable #define DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable #if !defined(__cplusplus) || defined(RO_NO_TEMPLATE_NAME) /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0040 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0040_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0040_v0_0_s_ifspec; #ifndef ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_INTERFACE_DEFINED__ #define ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_INTERFACE_DEFINED__ /* interface __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable */ /* [unique][uuid][object] */ /* interface __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable */ /* [unique][uuid][object] */ EXTERN_C const IID IID___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable; #if defined(__cplusplus) && !defined(CINTERFACE) MIDL_INTERFACE("28342e21-dad3-5e32-bae1-afe7b26c66fb") __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable : public IUnknown { public: virtual HRESULT STDMETHODCALLTYPE Invoke( /* [in] */ __RPC__in_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationViewTitleBar *sender, /* [in] */ __RPC__in_opt IInspectable *e) = 0; }; #else /* C style interface */ typedef struct __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectableVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable * This); HRESULT ( STDMETHODCALLTYPE *Invoke )( __RPC__in __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable * This, /* [in] */ __RPC__in_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar *sender, /* [in] */ __RPC__in_opt IInspectable *e); END_INTERFACE } __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectableVtbl; interface __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable { CONST_VTBL struct __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectableVtbl *lpVtbl; }; #ifdef COBJMACROS #define __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_Invoke(This,sender,e) \ ( (This)->lpVtbl -> Invoke(This,sender,e) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0041 */ /* [local] */ #endif /* pinterface */ #endif /* DEF___FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_IAppListEntry[] = L"Windows.ApplicationModel.Core.IAppListEntry"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0041 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0041_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0041_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::IAppListEntry */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("EF00F07F-2108-490A-877A-8A9F17C25FAD") IAppListEntry : public IInspectable { public: virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_DisplayInfo( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::IAppDisplayInfo **value) = 0; virtual HRESULT STDMETHODCALLTYPE LaunchAsync( /* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_boolean **operation) = 0; }; extern const __declspec(selectany) IID & IID_IAppListEntry = __uuidof(IAppListEntry); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntryVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_DisplayInfo )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CIAppDisplayInfo **value); HRESULT ( STDMETHODCALLTYPE *LaunchAsync )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry * This, /* [out][retval] */ __RPC__deref_out_opt __FIAsyncOperation_1_boolean **operation); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntryVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntryVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_get_DisplayInfo(This,value) \ ( (This)->lpVtbl -> get_DisplayInfo(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_LaunchAsync(This,operation) \ ( (This)->lpVtbl -> LaunchAsync(This,operation) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIAppListEntry_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0042 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreApplication[] = L"Windows.ApplicationModel.Core.ICoreApplication"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0042 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0042_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0042_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreApplication */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("0AACF7A4-5E1D-49DF-8034-FB6A68BC5ED1") ICoreApplication : public IInspectable { public: virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Id( /* [out][retval] */ __RPC__deref_out_opt HSTRING *value) = 0; virtual HRESULT STDMETHODCALLTYPE add_Suspending( /* [in] */ __RPC__in_opt __FIEventHandler_1_Windows__CApplicationModel__CSuspendingEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0; virtual HRESULT STDMETHODCALLTYPE remove_Suspending( /* [in] */ EventRegistrationToken token) = 0; virtual HRESULT STDMETHODCALLTYPE add_Resuming( /* [in] */ __RPC__in_opt __FIEventHandler_1_IInspectable *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0; virtual HRESULT STDMETHODCALLTYPE remove_Resuming( /* [in] */ EventRegistrationToken token) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Properties( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Foundation::Collections::IPropertySet **value) = 0; virtual HRESULT STDMETHODCALLTYPE GetCurrentView( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationView **value) = 0; virtual HRESULT STDMETHODCALLTYPE Run( /* [in] */ __RPC__in_opt ABI::Windows::ApplicationModel::Core::IFrameworkViewSource *viewSource) = 0; virtual HRESULT STDMETHODCALLTYPE RunWithActivationFactories( /* [in] */ __RPC__in_opt ABI::Windows::Foundation::IGetActivationFactory *activationFactoryCallback) = 0; }; extern const __declspec(selectany) IID & IID_ICoreApplication = __uuidof(ICoreApplication); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Id )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [out][retval] */ __RPC__deref_out_opt HSTRING *value); HRESULT ( STDMETHODCALLTYPE *add_Suspending )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [in] */ __RPC__in_opt __FIEventHandler_1_Windows__CApplicationModel__CSuspendingEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token); HRESULT ( STDMETHODCALLTYPE *remove_Suspending )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [in] */ EventRegistrationToken token); HRESULT ( STDMETHODCALLTYPE *add_Resuming )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [in] */ __RPC__in_opt __FIEventHandler_1_IInspectable *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token); HRESULT ( STDMETHODCALLTYPE *remove_Resuming )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [in] */ EventRegistrationToken token); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Properties )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CCollections_CIPropertySet **value); HRESULT ( STDMETHODCALLTYPE *GetCurrentView )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView **value); HRESULT ( STDMETHODCALLTYPE *Run )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [in] */ __RPC__in_opt __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource *viewSource); HRESULT ( STDMETHODCALLTYPE *RunWithActivationFactories )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication * This, /* [in] */ __RPC__in_opt __x_ABI_CWindows_CFoundation_CIGetActivationFactory *activationFactoryCallback); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_get_Id(This,value) \ ( (This)->lpVtbl -> get_Id(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_add_Suspending(This,handler,token) \ ( (This)->lpVtbl -> add_Suspending(This,handler,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_remove_Suspending(This,token) \ ( (This)->lpVtbl -> remove_Suspending(This,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_add_Resuming(This,handler,token) \ ( (This)->lpVtbl -> add_Resuming(This,handler,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_remove_Resuming(This,token) \ ( (This)->lpVtbl -> remove_Resuming(This,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_get_Properties(This,value) \ ( (This)->lpVtbl -> get_Properties(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_GetCurrentView(This,value) \ ( (This)->lpVtbl -> GetCurrentView(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_Run(This,viewSource) \ ( (This)->lpVtbl -> Run(This,viewSource) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_RunWithActivationFactories(This,activationFactoryCallback) \ ( (This)->lpVtbl -> RunWithActivationFactories(This,activationFactoryCallback) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0043 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreApplication2[] = L"Windows.ApplicationModel.Core.ICoreApplication2"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0043 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0043_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0043_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreApplication2 */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("998681FB-1AB6-4B7F-BE4A-9A0645224C04") ICoreApplication2 : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE add_BackgroundActivated( /* [in] */ __RPC__in_opt __FIEventHandler_1_Windows__CApplicationModel__CActivation__CBackgroundActivatedEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0; virtual HRESULT STDMETHODCALLTYPE remove_BackgroundActivated( /* [in] */ EventRegistrationToken token) = 0; virtual HRESULT STDMETHODCALLTYPE add_LeavingBackground( /* [in] */ __RPC__in_opt __FIEventHandler_1_Windows__CApplicationModel__CLeavingBackgroundEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0; virtual HRESULT STDMETHODCALLTYPE remove_LeavingBackground( /* [in] */ EventRegistrationToken token) = 0; virtual HRESULT STDMETHODCALLTYPE add_EnteredBackground( /* [in] */ __RPC__in_opt __FIEventHandler_1_Windows__CApplicationModel__CEnteredBackgroundEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0; virtual HRESULT STDMETHODCALLTYPE remove_EnteredBackground( /* [in] */ EventRegistrationToken token) = 0; virtual HRESULT STDMETHODCALLTYPE EnablePrelaunch( /* [in] */ boolean value) = 0; }; extern const __declspec(selectany) IID & IID_ICoreApplication2 = __uuidof(ICoreApplication2); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2Vtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *add_BackgroundActivated )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This, /* [in] */ __RPC__in_opt __FIEventHandler_1_Windows__CApplicationModel__CActivation__CBackgroundActivatedEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token); HRESULT ( STDMETHODCALLTYPE *remove_BackgroundActivated )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This, /* [in] */ EventRegistrationToken token); HRESULT ( STDMETHODCALLTYPE *add_LeavingBackground )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This, /* [in] */ __RPC__in_opt __FIEventHandler_1_Windows__CApplicationModel__CLeavingBackgroundEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token); HRESULT ( STDMETHODCALLTYPE *remove_LeavingBackground )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This, /* [in] */ EventRegistrationToken token); HRESULT ( STDMETHODCALLTYPE *add_EnteredBackground )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This, /* [in] */ __RPC__in_opt __FIEventHandler_1_Windows__CApplicationModel__CEnteredBackgroundEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token); HRESULT ( STDMETHODCALLTYPE *remove_EnteredBackground )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This, /* [in] */ EventRegistrationToken token); HRESULT ( STDMETHODCALLTYPE *EnablePrelaunch )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 * This, /* [in] */ boolean value); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2Vtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2 { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2Vtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_add_BackgroundActivated(This,handler,token) \ ( (This)->lpVtbl -> add_BackgroundActivated(This,handler,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_remove_BackgroundActivated(This,token) \ ( (This)->lpVtbl -> remove_BackgroundActivated(This,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_add_LeavingBackground(This,handler,token) \ ( (This)->lpVtbl -> add_LeavingBackground(This,handler,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_remove_LeavingBackground(This,token) \ ( (This)->lpVtbl -> remove_LeavingBackground(This,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_add_EnteredBackground(This,handler,token) \ ( (This)->lpVtbl -> add_EnteredBackground(This,handler,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_remove_EnteredBackground(This,token) \ ( (This)->lpVtbl -> remove_EnteredBackground(This,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_EnablePrelaunch(This,value) \ ( (This)->lpVtbl -> EnablePrelaunch(This,value) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplication2_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0044 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreApplicationExit[] = L"Windows.ApplicationModel.Core.ICoreApplicationExit"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0044 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0044_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0044_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreApplicationExit */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("CF86461D-261E-4B72-9ACD-44ED2ACE6A29") ICoreApplicationExit : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE Exit( void) = 0; virtual HRESULT STDMETHODCALLTYPE add_Exiting( /* [in] */ __RPC__in_opt __FIEventHandler_1_IInspectable *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0; virtual HRESULT STDMETHODCALLTYPE remove_Exiting( /* [in] */ EventRegistrationToken token) = 0; }; extern const __declspec(selectany) IID & IID_ICoreApplicationExit = __uuidof(ICoreApplicationExit); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExitVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *Exit )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit * This); HRESULT ( STDMETHODCALLTYPE *add_Exiting )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit * This, /* [in] */ __RPC__in_opt __FIEventHandler_1_IInspectable *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token); HRESULT ( STDMETHODCALLTYPE *remove_Exiting )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit * This, /* [in] */ EventRegistrationToken token); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExitVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExitVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_Exit(This) \ ( (This)->lpVtbl -> Exit(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_add_Exiting(This,handler,token) \ ( (This)->lpVtbl -> add_Exiting(This,handler,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_remove_Exiting(This,token) \ ( (This)->lpVtbl -> remove_Exiting(This,token) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationExit_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0045 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreApplicationUnhandledError[] = L"Windows.ApplicationModel.Core.ICoreApplicationUnhandledError"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0045 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0045_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0045_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreApplicationUnhandledError */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("F0E24AB0-DD09-42E1-B0BC-E0E131F78D7E") ICoreApplicationUnhandledError : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE add_UnhandledErrorDetected( /* [in] */ __RPC__in_opt __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0; virtual HRESULT STDMETHODCALLTYPE remove_UnhandledErrorDetected( /* [in] */ EventRegistrationToken token) = 0; }; extern const __declspec(selectany) IID & IID_ICoreApplicationUnhandledError = __uuidof(ICoreApplicationUnhandledError); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledErrorVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *add_UnhandledErrorDetected )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError * This, /* [in] */ __RPC__in_opt __FIEventHandler_1_Windows__CApplicationModel__CCore__CUnhandledErrorDetectedEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token); HRESULT ( STDMETHODCALLTYPE *remove_UnhandledErrorDetected )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError * This, /* [in] */ EventRegistrationToken token); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledErrorVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledErrorVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_add_UnhandledErrorDetected(This,handler,token) \ ( (This)->lpVtbl -> add_UnhandledErrorDetected(This,handler,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_remove_UnhandledErrorDetected(This,token) \ ( (This)->lpVtbl -> remove_UnhandledErrorDetected(This,token) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUnhandledError_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0046 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreApplicationUseCount[] = L"Windows.ApplicationModel.Core.ICoreApplicationUseCount"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0046 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0046_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0046_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreApplicationUseCount */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("518DC408-C077-475B-809E-0BC0C57E4B74") ICoreApplicationUseCount : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE IncrementApplicationUseCount( void) = 0; virtual HRESULT STDMETHODCALLTYPE DecrementApplicationUseCount( void) = 0; }; extern const __declspec(selectany) IID & IID_ICoreApplicationUseCount = __uuidof(ICoreApplicationUseCount); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCountVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *IncrementApplicationUseCount )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount * This); HRESULT ( STDMETHODCALLTYPE *DecrementApplicationUseCount )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount * This); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCountVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCountVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_IncrementApplicationUseCount(This) \ ( (This)->lpVtbl -> IncrementApplicationUseCount(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_DecrementApplicationUseCount(This) \ ( (This)->lpVtbl -> DecrementApplicationUseCount(This) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationUseCount_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0047 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreApplicationView[] = L"Windows.ApplicationModel.Core.ICoreApplicationView"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0047 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0047_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0047_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreApplicationView */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("638BB2DB-451D-4661-B099-414F34FFB9F1") ICoreApplicationView : public IInspectable { public: virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_CoreWindow( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::UI::Core::ICoreWindow **value) = 0; virtual HRESULT STDMETHODCALLTYPE add_Activated( /* [in] */ __RPC__in_opt __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CActivation__CIActivatedEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0; virtual HRESULT STDMETHODCALLTYPE remove_Activated( /* [in] */ EventRegistrationToken token) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsMain( /* [out][retval] */ __RPC__out boolean *value) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsHosted( /* [out][retval] */ __RPC__out boolean *value) = 0; }; extern const __declspec(selectany) IID & IID_ICoreApplicationView = __uuidof(ICoreApplicationView); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_CoreWindow )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CUI_CCore_CICoreWindow **value); HRESULT ( STDMETHODCALLTYPE *add_Activated )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView * This, /* [in] */ __RPC__in_opt __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CActivation__CIActivatedEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token); HRESULT ( STDMETHODCALLTYPE *remove_Activated )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView * This, /* [in] */ EventRegistrationToken token); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsMain )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView * This, /* [out][retval] */ __RPC__out boolean *value); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsHosted )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView * This, /* [out][retval] */ __RPC__out boolean *value); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_get_CoreWindow(This,value) \ ( (This)->lpVtbl -> get_CoreWindow(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_add_Activated(This,handler,token) \ ( (This)->lpVtbl -> add_Activated(This,handler,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_remove_Activated(This,token) \ ( (This)->lpVtbl -> remove_Activated(This,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_get_IsMain(This,value) \ ( (This)->lpVtbl -> get_IsMain(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_get_IsHosted(This,value) \ ( (This)->lpVtbl -> get_IsHosted(This,value) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0048 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreApplicationView2[] = L"Windows.ApplicationModel.Core.ICoreApplicationView2"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0048 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0048_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0048_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2 */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreApplicationView2 */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("68EB7ADF-917F-48EB-9AEB-7DE53E086AB1") ICoreApplicationView2 : public IInspectable { public: virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Dispatcher( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::UI::Core::ICoreDispatcher **value) = 0; }; extern const __declspec(selectany) IID & IID_ICoreApplicationView2 = __uuidof(ICoreApplicationView2); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2Vtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2 * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2 * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2 * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2 * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2 * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2 * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Dispatcher )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2 * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CUI_CCore_CICoreDispatcher **value); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2Vtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2 { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2Vtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_get_Dispatcher(This,value) \ ( (This)->lpVtbl -> get_Dispatcher(This,value) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView2_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0049 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreApplicationView3[] = L"Windows.ApplicationModel.Core.ICoreApplicationView3"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0049 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0049_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0049_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreApplicationView3 */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("07EBE1B3-A4CF-4550-AB70-B07E85330BC8") ICoreApplicationView3 : public IInspectable { public: virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsComponent( /* [out][retval] */ __RPC__out boolean *value) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_TitleBar( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationViewTitleBar **value) = 0; virtual HRESULT STDMETHODCALLTYPE add_HostedViewClosing( /* [in] */ __RPC__in_opt __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0; virtual HRESULT STDMETHODCALLTYPE remove_HostedViewClosing( /* [in] */ EventRegistrationToken token) = 0; }; extern const __declspec(selectany) IID & IID_ICoreApplicationView3 = __uuidof(ICoreApplicationView3); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3Vtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsComponent )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 * This, /* [out][retval] */ __RPC__out boolean *value); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_TitleBar )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar **value); HRESULT ( STDMETHODCALLTYPE *add_HostedViewClosing )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 * This, /* [in] */ __RPC__in_opt __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationView_Windows__CApplicationModel__CCore__CHostedViewClosingEventArgs *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token); HRESULT ( STDMETHODCALLTYPE *remove_HostedViewClosing )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 * This, /* [in] */ EventRegistrationToken token); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3Vtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3 { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3Vtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_get_IsComponent(This,value) \ ( (This)->lpVtbl -> get_IsComponent(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_get_TitleBar(This,value) \ ( (This)->lpVtbl -> get_TitleBar(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_add_HostedViewClosing(This,handler,token) \ ( (This)->lpVtbl -> add_HostedViewClosing(This,handler,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_remove_HostedViewClosing(This,token) \ ( (This)->lpVtbl -> remove_HostedViewClosing(This,token) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView3_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0050 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreApplicationView5[] = L"Windows.ApplicationModel.Core.ICoreApplicationView5"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0050 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0050_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0050_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5 */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreApplicationView5 */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("2BC095A8-8EF0-446D-9E60-3A3E0428C671") ICoreApplicationView5 : public IInspectable { public: virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Properties( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Foundation::Collections::IPropertySet **value) = 0; }; extern const __declspec(selectany) IID & IID_ICoreApplicationView5 = __uuidof(ICoreApplicationView5); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5Vtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5 * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5 * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5 * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5 * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5 * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5 * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Properties )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5 * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CCollections_CIPropertySet **value); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5Vtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5 { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5Vtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_get_Properties(This,value) \ ( (This)->lpVtbl -> get_Properties(This,value) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView5_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0051 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreApplicationViewTitleBar[] = L"Windows.ApplicationModel.Core.ICoreApplicationViewTitleBar"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0051 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0051_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0051_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreApplicationViewTitleBar */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("006D35E3-E1F1-431B-9508-29B96926AC53") ICoreApplicationViewTitleBar : public IInspectable { public: virtual /* [propput] */ HRESULT STDMETHODCALLTYPE put_ExtendViewIntoTitleBar( /* [in] */ boolean value) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_ExtendViewIntoTitleBar( /* [out][retval] */ __RPC__out boolean *value) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_SystemOverlayLeftInset( /* [out][retval] */ __RPC__out DOUBLE *value) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_SystemOverlayRightInset( /* [out][retval] */ __RPC__out DOUBLE *value) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Height( /* [out][retval] */ __RPC__out DOUBLE *value) = 0; virtual HRESULT STDMETHODCALLTYPE add_LayoutMetricsChanged( /* [in] */ __RPC__in_opt __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0; virtual HRESULT STDMETHODCALLTYPE remove_LayoutMetricsChanged( /* [in] */ EventRegistrationToken token) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_IsVisible( /* [out][retval] */ __RPC__out boolean *value) = 0; virtual HRESULT STDMETHODCALLTYPE add_IsVisibleChanged( /* [in] */ __RPC__in_opt __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token) = 0; virtual HRESULT STDMETHODCALLTYPE remove_IsVisibleChanged( /* [in] */ EventRegistrationToken token) = 0; }; extern const __declspec(selectany) IID & IID_ICoreApplicationViewTitleBar = __uuidof(ICoreApplicationViewTitleBar); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBarVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propput] */ HRESULT ( STDMETHODCALLTYPE *put_ExtendViewIntoTitleBar )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [in] */ boolean value); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_ExtendViewIntoTitleBar )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [out][retval] */ __RPC__out boolean *value); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_SystemOverlayLeftInset )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [out][retval] */ __RPC__out DOUBLE *value); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_SystemOverlayRightInset )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [out][retval] */ __RPC__out DOUBLE *value); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Height )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [out][retval] */ __RPC__out DOUBLE *value); HRESULT ( STDMETHODCALLTYPE *add_LayoutMetricsChanged )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [in] */ __RPC__in_opt __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token); HRESULT ( STDMETHODCALLTYPE *remove_LayoutMetricsChanged )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [in] */ EventRegistrationToken token); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_IsVisible )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [out][retval] */ __RPC__out boolean *value); HRESULT ( STDMETHODCALLTYPE *add_IsVisibleChanged )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [in] */ __RPC__in_opt __FITypedEventHandler_2_Windows__CApplicationModel__CCore__CCoreApplicationViewTitleBar_IInspectable *handler, /* [out][retval] */ __RPC__out EventRegistrationToken *token); HRESULT ( STDMETHODCALLTYPE *remove_IsVisibleChanged )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar * This, /* [in] */ EventRegistrationToken token); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBarVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBarVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_put_ExtendViewIntoTitleBar(This,value) \ ( (This)->lpVtbl -> put_ExtendViewIntoTitleBar(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_get_ExtendViewIntoTitleBar(This,value) \ ( (This)->lpVtbl -> get_ExtendViewIntoTitleBar(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_get_SystemOverlayLeftInset(This,value) \ ( (This)->lpVtbl -> get_SystemOverlayLeftInset(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_get_SystemOverlayRightInset(This,value) \ ( (This)->lpVtbl -> get_SystemOverlayRightInset(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_get_Height(This,value) \ ( (This)->lpVtbl -> get_Height(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_add_LayoutMetricsChanged(This,handler,token) \ ( (This)->lpVtbl -> add_LayoutMetricsChanged(This,handler,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_remove_LayoutMetricsChanged(This,token) \ ( (This)->lpVtbl -> remove_LayoutMetricsChanged(This,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_get_IsVisible(This,value) \ ( (This)->lpVtbl -> get_IsVisible(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_add_IsVisibleChanged(This,handler,token) \ ( (This)->lpVtbl -> add_IsVisibleChanged(This,handler,token) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_remove_IsVisibleChanged(This,token) \ ( (This)->lpVtbl -> remove_IsVisibleChanged(This,token) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationViewTitleBar_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0052 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreImmersiveApplication[] = L"Windows.ApplicationModel.Core.ICoreImmersiveApplication"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0052 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0052_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0052_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreImmersiveApplication */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("1ADA0E3E-E4A2-4123-B451-DC96BF800419") ICoreImmersiveApplication : public IInspectable { public: virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Views( /* [out][retval] */ __RPC__deref_out_opt __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView **value) = 0; virtual HRESULT STDMETHODCALLTYPE CreateNewView( /* [in] */ __RPC__in HSTRING runtimeType, /* [in] */ __RPC__in HSTRING entryPoint, /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationView **view) = 0; virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_MainView( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationView **value) = 0; }; extern const __declspec(selectany) IID & IID_ICoreImmersiveApplication = __uuidof(ICoreImmersiveApplication); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplicationVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Views )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication * This, /* [out][retval] */ __RPC__deref_out_opt __FIVectorView_1_Windows__CApplicationModel__CCore__CCoreApplicationView **value); HRESULT ( STDMETHODCALLTYPE *CreateNewView )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication * This, /* [in] */ __RPC__in HSTRING runtimeType, /* [in] */ __RPC__in HSTRING entryPoint, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView **view); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_MainView )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView **value); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplicationVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplicationVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_get_Views(This,value) \ ( (This)->lpVtbl -> get_Views(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_CreateNewView(This,runtimeType,entryPoint,view) \ ( (This)->lpVtbl -> CreateNewView(This,runtimeType,entryPoint,view) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_get_MainView(This,value) \ ( (This)->lpVtbl -> get_MainView(This,value) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0053 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreImmersiveApplication2[] = L"Windows.ApplicationModel.Core.ICoreImmersiveApplication2"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0053 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0053_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0053_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2 */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreImmersiveApplication2 */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("828E1E36-E9E3-4CFC-9B66-48B78EA9BB2C") ICoreImmersiveApplication2 : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE CreateNewViewFromMainView( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationView **view) = 0; }; extern const __declspec(selectany) IID & IID_ICoreImmersiveApplication2 = __uuidof(ICoreImmersiveApplication2); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2Vtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2 * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2 * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2 * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2 * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2 * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2 * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *CreateNewViewFromMainView )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2 * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView **view); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2Vtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2 { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2Vtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_CreateNewViewFromMainView(This,view) \ ( (This)->lpVtbl -> CreateNewViewFromMainView(This,view) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication2_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0054 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_ICoreImmersiveApplication3[] = L"Windows.ApplicationModel.Core.ICoreImmersiveApplication3"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0054 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0054_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0054_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3 */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::ICoreImmersiveApplication3 */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("34A05B2F-EE0D-41E5-8314-CF10C91BF0AF") ICoreImmersiveApplication3 : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE CreateNewViewWithViewSource( /* [in] */ __RPC__in_opt ABI::Windows::ApplicationModel::Core::IFrameworkViewSource *viewSource, /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationView **view) = 0; }; extern const __declspec(selectany) IID & IID_ICoreImmersiveApplication3 = __uuidof(ICoreImmersiveApplication3); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3Vtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3 * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3 * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3 * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3 * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3 * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3 * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *CreateNewViewWithViewSource )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3 * This, /* [in] */ __RPC__in_opt __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource *viewSource, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView **view); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3Vtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3 { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3Vtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_CreateNewViewWithViewSource(This,viewSource,view) \ ( (This)->lpVtbl -> CreateNewViewWithViewSource(This,viewSource,view) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CICoreImmersiveApplication3_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0055 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_IFrameworkView[] = L"Windows.ApplicationModel.Core.IFrameworkView"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0055 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0055_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0055_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::IFrameworkView */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("FAAB5CD0-8924-45AC-AD0F-A08FAE5D0324") IFrameworkView : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE Initialize( /* [in] */ __RPC__in_opt ABI::Windows::ApplicationModel::Core::ICoreApplicationView *applicationView) = 0; virtual HRESULT STDMETHODCALLTYPE SetWindow( /* [in] */ __RPC__in_opt ABI::Windows::UI::Core::ICoreWindow *window) = 0; virtual HRESULT STDMETHODCALLTYPE Load( /* [in] */ __RPC__in HSTRING entryPoint) = 0; virtual HRESULT STDMETHODCALLTYPE Run( void) = 0; virtual HRESULT STDMETHODCALLTYPE Uninitialize( void) = 0; }; extern const __declspec(selectany) IID & IID_IFrameworkView = __uuidof(IFrameworkView); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *Initialize )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView * This, /* [in] */ __RPC__in_opt __x_ABI_CWindows_CApplicationModel_CCore_CICoreApplicationView *applicationView); HRESULT ( STDMETHODCALLTYPE *SetWindow )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView * This, /* [in] */ __RPC__in_opt __x_ABI_CWindows_CUI_CCore_CICoreWindow *window); HRESULT ( STDMETHODCALLTYPE *Load )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView * This, /* [in] */ __RPC__in HSTRING entryPoint); HRESULT ( STDMETHODCALLTYPE *Run )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView * This); HRESULT ( STDMETHODCALLTYPE *Uninitialize )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView * This); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_Initialize(This,applicationView) \ ( (This)->lpVtbl -> Initialize(This,applicationView) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_SetWindow(This,window) \ ( (This)->lpVtbl -> SetWindow(This,window) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_Load(This,entryPoint) \ ( (This)->lpVtbl -> Load(This,entryPoint) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_Run(This) \ ( (This)->lpVtbl -> Run(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_Uninitialize(This) \ ( (This)->lpVtbl -> Uninitialize(This) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0056 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_IFrameworkViewSource[] = L"Windows.ApplicationModel.Core.IFrameworkViewSource"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0056 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0056_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0056_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::IFrameworkViewSource */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("CD770614-65C4-426C-9494-34FC43554862") IFrameworkViewSource : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE CreateView( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::IFrameworkView **viewProvider) = 0; }; extern const __declspec(selectany) IID & IID_IFrameworkViewSource = __uuidof(IFrameworkViewSource); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSourceVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *CreateView )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkView **viewProvider); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSourceVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSourceVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_CreateView(This,viewProvider) \ ( (This)->lpVtbl -> CreateView(This,viewProvider) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIFrameworkViewSource_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0057 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_IHostedViewClosingEventArgs[] = L"Windows.ApplicationModel.Core.IHostedViewClosingEventArgs"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0057 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0057_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0057_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::IHostedViewClosingEventArgs */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("D238943C-B24E-4790-ACB5-3E4243C4FF87") IHostedViewClosingEventArgs : public IInspectable { public: virtual HRESULT STDMETHODCALLTYPE GetDeferral( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::Foundation::IDeferral **result) = 0; }; extern const __declspec(selectany) IID & IID_IHostedViewClosingEventArgs = __uuidof(IHostedViewClosingEventArgs); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgsVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs * This, /* [out] */ __RPC__out TrustLevel *trustLevel); HRESULT ( STDMETHODCALLTYPE *GetDeferral )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CFoundation_CIDeferral **result); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgsVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgsVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_GetDeferral(This,result) \ ( (This)->lpVtbl -> GetDeferral(This,result) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIHostedViewClosingEventArgs_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0058 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_IUnhandledError[] = L"Windows.ApplicationModel.Core.IUnhandledError"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0058 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0058_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0058_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::IUnhandledError */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("9459B726-53B5-4686-9EAF-FA8162DC3980") IUnhandledError : public IInspectable { public: virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_Handled( /* [out][retval] */ __RPC__out boolean *value) = 0; virtual HRESULT STDMETHODCALLTYPE Propagate( void) = 0; }; extern const __declspec(selectany) IID & IID_IUnhandledError = __uuidof(IUnhandledError); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_Handled )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError * This, /* [out][retval] */ __RPC__out boolean *value); HRESULT ( STDMETHODCALLTYPE *Propagate )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError * This); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_get_Handled(This,value) \ ( (This)->lpVtbl -> get_Handled(This,value) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_Propagate(This) \ ( (This)->lpVtbl -> Propagate(This) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0059 */ /* [local] */ #if !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_INTERFACE_DEFINED__) extern const __declspec(selectany) _Null_terminated_ WCHAR InterfaceName_Windows_ApplicationModel_Core_IUnhandledErrorDetectedEventArgs[] = L"Windows.ApplicationModel.Core.IUnhandledErrorDetectedEventArgs"; #endif /* !defined(____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_INTERFACE_DEFINED__) */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0059 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0059_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0059_v0_0_s_ifspec; #ifndef ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_INTERFACE_DEFINED__ #define ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_INTERFACE_DEFINED__ /* interface __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs */ /* [uuid][object] */ /* interface ABI::Windows::ApplicationModel::Core::IUnhandledErrorDetectedEventArgs */ /* [uuid][object] */ EXTERN_C const IID IID___x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs; #if defined(__cplusplus) && !defined(CINTERFACE) } /* end extern "C" */ namespace ABI { namespace Windows { namespace ApplicationModel { namespace Core { MIDL_INTERFACE("679AB78B-B336-4822-AC40-0D750F0B7A2B") IUnhandledErrorDetectedEventArgs : public IInspectable { public: virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_UnhandledError( /* [out][retval] */ __RPC__deref_out_opt ABI::Windows::ApplicationModel::Core::IUnhandledError **value) = 0; }; extern const __declspec(selectany) IID & IID_IUnhandledErrorDetectedEventArgs = __uuidof(IUnhandledErrorDetectedEventArgs); } /* end namespace */ } /* end namespace */ } /* end namespace */ } /* end namespace */ extern "C" { #else /* C style interface */ typedef struct __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgsVtbl { BEGIN_INTERFACE HRESULT ( STDMETHODCALLTYPE *QueryInterface )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs * This, /* [in] */ __RPC__in REFIID riid, /* [annotation][iid_is][out] */ _COM_Outptr_ void **ppvObject); ULONG ( STDMETHODCALLTYPE *AddRef )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs * This); ULONG ( STDMETHODCALLTYPE *Release )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs * This); HRESULT ( STDMETHODCALLTYPE *GetIids )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs * This, /* [out] */ __RPC__out ULONG *iidCount, /* [size_is][size_is][out] */ __RPC__deref_out_ecount_full_opt(*iidCount) IID **iids); HRESULT ( STDMETHODCALLTYPE *GetRuntimeClassName )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs * This, /* [out] */ __RPC__deref_out_opt HSTRING *className); HRESULT ( STDMETHODCALLTYPE *GetTrustLevel )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs * This, /* [out] */ __RPC__out TrustLevel *trustLevel); /* [propget] */ HRESULT ( STDMETHODCALLTYPE *get_UnhandledError )( __RPC__in __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs * This, /* [out][retval] */ __RPC__deref_out_opt __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledError **value); END_INTERFACE } __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgsVtbl; interface __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs { CONST_VTBL struct __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgsVtbl *lpVtbl; }; #ifdef COBJMACROS #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_QueryInterface(This,riid,ppvObject) \ ( (This)->lpVtbl -> QueryInterface(This,riid,ppvObject) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_AddRef(This) \ ( (This)->lpVtbl -> AddRef(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_Release(This) \ ( (This)->lpVtbl -> Release(This) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_GetIids(This,iidCount,iids) \ ( (This)->lpVtbl -> GetIids(This,iidCount,iids) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_GetRuntimeClassName(This,className) \ ( (This)->lpVtbl -> GetRuntimeClassName(This,className) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_GetTrustLevel(This,trustLevel) \ ( (This)->lpVtbl -> GetTrustLevel(This,trustLevel) ) #define __x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_get_UnhandledError(This,value) \ ( (This)->lpVtbl -> get_UnhandledError(This,value) ) #endif /* COBJMACROS */ #endif /* C style interface */ #endif /* ____x_ABI_CWindows_CApplicationModel_CCore_CIUnhandledErrorDetectedEventArgs_INTERFACE_DEFINED__ */ /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0060 */ /* [local] */ #ifndef RUNTIMECLASS_Windows_ApplicationModel_Core_AppListEntry_DEFINED #define RUNTIMECLASS_Windows_ApplicationModel_Core_AppListEntry_DEFINED extern const __declspec(selectany) _Null_terminated_ WCHAR RuntimeClass_Windows_ApplicationModel_Core_AppListEntry[] = L"Windows.ApplicationModel.Core.AppListEntry"; #endif #ifndef RUNTIMECLASS_Windows_ApplicationModel_Core_CoreApplication_DEFINED #define RUNTIMECLASS_Windows_ApplicationModel_Core_CoreApplication_DEFINED extern const __declspec(selectany) _Null_terminated_ WCHAR RuntimeClass_Windows_ApplicationModel_Core_CoreApplication[] = L"Windows.ApplicationModel.Core.CoreApplication"; #endif #ifndef RUNTIMECLASS_Windows_ApplicationModel_Core_CoreApplicationView_DEFINED #define RUNTIMECLASS_Windows_ApplicationModel_Core_CoreApplicationView_DEFINED extern const __declspec(selectany) _Null_terminated_ WCHAR RuntimeClass_Windows_ApplicationModel_Core_CoreApplicationView[] = L"Windows.ApplicationModel.Core.CoreApplicationView"; #endif #ifndef RUNTIMECLASS_Windows_ApplicationModel_Core_CoreApplicationViewTitleBar_DEFINED #define RUNTIMECLASS_Windows_ApplicationModel_Core_CoreApplicationViewTitleBar_DEFINED extern const __declspec(selectany) _Null_terminated_ WCHAR RuntimeClass_Windows_ApplicationModel_Core_CoreApplicationViewTitleBar[] = L"Windows.ApplicationModel.Core.CoreApplicationViewTitleBar"; #endif #ifndef RUNTIMECLASS_Windows_ApplicationModel_Core_HostedViewClosingEventArgs_DEFINED #define RUNTIMECLASS_Windows_ApplicationModel_Core_HostedViewClosingEventArgs_DEFINED extern const __declspec(selectany) _Null_terminated_ WCHAR RuntimeClass_Windows_ApplicationModel_Core_HostedViewClosingEventArgs[] = L"Windows.ApplicationModel.Core.HostedViewClosingEventArgs"; #endif #ifndef RUNTIMECLASS_Windows_ApplicationModel_Core_UnhandledError_DEFINED #define RUNTIMECLASS_Windows_ApplicationModel_Core_UnhandledError_DEFINED extern const __declspec(selectany) _Null_terminated_ WCHAR RuntimeClass_Windows_ApplicationModel_Core_UnhandledError[] = L"Windows.ApplicationModel.Core.UnhandledError"; #endif #ifndef RUNTIMECLASS_Windows_ApplicationModel_Core_UnhandledErrorDetectedEventArgs_DEFINED #define RUNTIMECLASS_Windows_ApplicationModel_Core_UnhandledErrorDetectedEventArgs_DEFINED extern const __declspec(selectany) _Null_terminated_ WCHAR RuntimeClass_Windows_ApplicationModel_Core_UnhandledErrorDetectedEventArgs[] = L"Windows.ApplicationModel.Core.UnhandledErrorDetectedEventArgs"; #endif /* interface __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0060 */ /* [local] */ extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0060_v0_0_c_ifspec; extern RPC_IF_HANDLE __MIDL_itf_windows2Eapplicationmodel2Ecore_0000_0060_v0_0_s_ifspec; /* Additional Prototypes for ALL interfaces */ unsigned long __RPC_USER HSTRING_UserSize( __RPC__in unsigned long *, unsigned long , __RPC__in HSTRING * ); unsigned char * __RPC_USER HSTRING_UserMarshal( __RPC__in unsigned long *, __RPC__inout_xcount(0) unsigned char *, __RPC__in HSTRING * ); unsigned char * __RPC_USER HSTRING_UserUnmarshal(__RPC__in unsigned long *, __RPC__in_xcount(0) unsigned char *, __RPC__out HSTRING * ); void __RPC_USER HSTRING_UserFree( __RPC__in unsigned long *, __RPC__in HSTRING * ); unsigned long __RPC_USER HSTRING_UserSize64( __RPC__in unsigned long *, unsigned long , __RPC__in HSTRING * ); unsigned char * __RPC_USER HSTRING_UserMarshal64( __RPC__in unsigned long *, __RPC__inout_xcount(0) unsigned char *, __RPC__in HSTRING * ); unsigned char * __RPC_USER HSTRING_UserUnmarshal64(__RPC__in unsigned long *, __RPC__in_xcount(0) unsigned char *, __RPC__out HSTRING * ); void __RPC_USER HSTRING_UserFree64( __RPC__in unsigned long *, __RPC__in HSTRING * ); /* end of Additional Prototypes */ #ifdef __cplusplus } #endif #endif
Geeks-Z/PAT-Advanced-Level-Practice
PATA1022.cpp
/* * @Descripttion: 参考https://blog.csdn.net/SYaoJun/article/details/87351227 * @version: 1.0 * @Author: Geeks_Z * @Date: 2021-05-15 16:37:07 * @LastEditors: Geeks_Z * @LastEditTime: 2021-05-15 17:11:25 */ #include <cstdio> #include <iostream> #include <map> #include <set> #include <algorithm> using namespace std; map<string, set<int>> mpT, mpA, mpK, mpP, mpY; void query(map<string, set<int>> &mp, string &str) { if (mp.find(str) == mp.end()) printf("Not Found\n"); else { for (set<int>::iterator it = mp[str].begin(); it != mp[str].end(); it++) { printf("%07d\n", *it); } } } int main() { // freopen("input.txt", "r", stdin); int n, m, id, type; string title, author, key, pub, year; scanf("%d", &n); for (int i = 0; i < n; i++) { scanf("%d", &id); char c = getchar(); getline(cin, title); mpT[title].insert(id); getline(cin, author); mpA[author].insert(id); while (cin >> key) { mpK[key].insert(id); c = getchar(); if (c == '\n') break; } getline(cin, pub); mpP[pub].insert(id); getline(cin, year); mpY[year].insert(id); } string temp; scanf("%d", &m); for (int i = 0; i < m; i++) { scanf("%d: ", &type); getline(cin, temp); cout << type << ": " << temp << endl; if (type == 1) query(mpT, temp); else if (type == 2) query(mpA, temp); else if (type == 3) query(mpK, temp); else if (type == 4) query(mpP, temp); else query(mpY, temp); } return 0; }
xyxiaoyou/snappy-store
tests/core/src/main/java/hydra/TestConfigComparison.java
<filename>tests/core/src/main/java/hydra/TestConfigComparison.java /* * Copyright (c) 2010-2015 Pivotal Software, Inc. All rights reserved. * * 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. See accompanying * LICENSE file. */ package hydra; import java.io.*; import java.util.*; import util.*; /** * * Used to compare test configuration files for test runs. * */ public class TestConfigComparison { /** * Returns the result of comparing latest.conf files as an array of sorted * difference lists: (dir1diffset,dir2diffset,...dir3diffset). * * @see FileUtil#getTextAsSet */ public static List[] getLatestConfDiffs( List dirs ) { if ( dirs == null ) { throw new HydraRuntimeException( "No test directories provided" ); } List[] diffs = new List[ dirs.size() ]; if ( dirs.size() == 1 ) { return diffs; } // read the files into sorted sets Vector sets = new Vector(); for ( Iterator i = dirs.iterator(); i.hasNext(); ) { String dir = (String) i.next(); try { SortedSet set = FileUtil.getTextAsSet( dir + "/latest.conf" ); sets.add( set ); } catch( FileNotFoundException e ) { Log.getLogWriter().warning( "...skipping " + dir + " for lack of a latest.conf file" ); sets.add( null ); } catch( IOException e ) { throw new HydraRuntimeException( "Problem reading file", e ); } } // capture the differences in sorted sets for ( int i = 0; i < sets.size(); i++ ) { SortedSet set = (SortedSet) sets.elementAt(i); if ( set == null ) { diffs[i] = null; } else { diffs[i] = new ArrayList(); for ( Iterator it = set.iterator(); it.hasNext(); ) { String entry = (String) it.next(); for ( int j = 0; j < sets.size(); j++ ) { if ( j != i ) { SortedSet other = (SortedSet) sets.elementAt(j); if ( other != null && ! other.contains( entry ) ) { diffs[i].add( entry ); break; } } } } } } return diffs; } public static void main( String args[] ) { if ( args.length < 1 ) { System.out.println( "Usage: TestConfigComparison <testDirs>" ); System.exit(1); } List fns = new ArrayList(); for ( int i = 0; i < args.length; i++ ) { fns.add( args[i] ); } try { List[] diffs = getLatestConfDiffs( fns ); for ( int i = 0; i < diffs.length; i++ ) { System.out.println( args[i] + "\n" + diffs[i] + "\n" ); } } catch (VirtualMachineError e) { // Don't try to handle this; let thread group catch it. throw e; } catch( Throwable t ) { System.out.println( TestHelper.getStackTrace( t ) ); System.exit(1); } } }
IceDragon200/rm-macl
lib/rm-macl/vxa-ext/rpg/base_item.rb
<filename>lib/rm-macl/vxa-ext/rpg/base_item.rb # # rm-macl/lib/rm-macl/vxa-ext/rpg/base_item.rb # by IceDragon module RPG #:nodoc: class BaseItem end end MACL.register('macl/vxa/rpg/base_item', '0.0.0')
vzhd1701/enex2notion
enex2notion/note_parser/webclip_stages_common.py
<filename>enex2notion/note_parser/webclip_stages_common.py from bs4 import Tag BLOCK_TAGS = ( "div", "h1", "h2", "h3", "hr", "ul", "ol", "en-media", "img", ) STANDALONE_TAGS = ("en-media", "img", "ol", "ul", "hr") def rename_tags(root: Tag, tags_to_rename: list, new_name: str): for e in root.find_all(tags_to_rename): e.name = new_name
jdeschamps/scifio
src/test/java/io/scif/img/cell/SCIFIOCellImgTest.java
/* * #%L * SCIFIO library for reading and converting scientific file formats. * %% * Copyright (C) 2011 - 2021 SCIFIO developers. * %% * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions are met: * * 1. Redistributions of source code must retain the above copyright notice, * this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright notice, * this list of conditions and the following disclaimer in the documentation * and/or other materials provided with the distribution. * * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. * #L% */ package io.scif.img.cell; import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertNull; import io.scif.img.ImgOpener; import io.scif.img.SCIFIOImgPlus; import io.scif.io.location.TestImgLocation; import org.junit.AfterClass; import org.junit.BeforeClass; import org.junit.Test; /** * Tests for the {@link SCIFIOCellImg} and related classes. * * @author <NAME> */ public class SCIFIOCellImgTest { private static ImgOpener opener; @BeforeClass public static void createOpener() { opener = new ImgOpener(); } @AfterClass public static void disposeOpener() { opener.context().dispose(); } /** * Test that when a {@link SCIFIOCellImg} is opened and disposed, the * associated reader is closed. */ @Test public void testReaderCleanup() { // Make an id that will trigger cell creation TestImgLocation loc = TestImgLocation.builder().name("lotsofplanes").axes( "X", "Y", "Z").lengths(256, 256, 100000).build(); final SCIFIOImgPlus<?> img = opener.openImgs(loc).get(0); assertNotNull(((SCIFIOCellImg) img.getImg()).reader().getMetadata()); img.dispose(); assertNull(((SCIFIOCellImg) img.getImg()).reader().getMetadata()); } // This test is currently disabled because it fails for unknown reasons. // It passes from Eclipse, it passes from Maven on the command line, but it // fails when run by Jenkins using Maven. // We're testing the dispose behavior above, the purpose of this test is // just // to confirm that disposal occurs when an ImgPlus is garbage collected. // Unfortunately, this will have to wait until we have a better // understanding // of how to test post-GC events. // /** // * Test that when a {@link SCIFIOCellImg} is opened and goes out of scope, the // * associated reader is closed. // */ // @Test // public void testReaderOutOfScopeCleanup() { // // Make an id that will trigger cell creation // final String id = "lotsofplanes&axes=X,Y,Z&lengths=256,256,100000.fake"; // SCIFIOImgPlus<?> img = IO.open(id); // assertNotNull(((SCIFIOCellImg) img.getImg()).reader().getMetadata()); // final WeakReference<Metadata> wr = // new WeakReference<Metadata>(((SCIFIOCellImg) img.getImg()).reader() // .getMetadata()); // img = null; // long arraySize = MemoryTools.totalAvailableMemory(); // if (arraySize > Integer.MAX_VALUE) { // arraySize = Integer.MAX_VALUE; // } // final long maxCounts = // Math.round(Math.max(100, // (2 * Math.ceil(((double)Runtime.getRuntime().maxMemory() / arraySize))))); // for (int i = 0; i < maxCounts && // wr.get() != null; i++) // { // final byte[] tmp = new byte[(int) arraySize]; // } // assertNull(wr.get()); // } }
demin-dmitriy/wine
dlls/winebus.sys/controller.h
/* * Common controller functions and structures * * Copyright 2018 <NAME> * * This library 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 library 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 St, Fifth Floor, Boston, MA 02110-1301, USA */ /* Blocks of data for building HID device descriptions */ static const BYTE REPORT_HEADER[] = { 0x05, 0x01, /* USAGE_PAGE (Generic Desktop) */ 0x09, 0x00, /* USAGE (??) */ 0xa1, 0x01, /* COLLECTION (Application) */ 0x09, 0x01, /* USAGE () */ 0xa1, 0x00, /* COLLECTION (Physical) */ }; #define IDX_HEADER_PAGE 1 #define IDX_HEADER_USAGE 3 static const BYTE REPORT_BUTTONS[] = { 0x05, 0x09, /* USAGE_PAGE (Button) */ 0x19, 0x01, /* USAGE_MINIMUM (Button 1) */ 0x29, 0x03, /* USAGE_MAXIMUM (Button 3) */ 0x15, 0x00, /* LOGICAL_MINIMUM (0) */ 0x25, 0x01, /* LOGICAL_MAXIMUM (1) */ 0x35, 0x00, /* PHYSICAL_MINIMUM (0) */ 0x45, 0x01, /* PHYSICAL_MAXIMUM (1) */ 0x95, 0x03, /* REPORT_COUNT (3) */ 0x75, 0x01, /* REPORT_SIZE (1) */ 0x81, 0x02, /* INPUT (Data,Var,Abs) */ }; #define IDX_BUTTON_MIN_USAGE 3 #define IDX_BUTTON_MAX_USAGE 5 #define IDX_BUTTON_COUNT 15 static const BYTE REPORT_PADDING[] = { 0x95, 0x03, /* REPORT_COUNT (3) */ 0x75, 0x01, /* REPORT_SIZE (1) */ 0x81, 0x03, /* INPUT (Cnst,Var,Abs) */ }; #define IDX_PADDING_BIT_COUNT 1 static const BYTE REPORT_AXIS_HEADER[] = { 0x05, 0x01, /* USAGE_PAGE (Generic Desktop) */ }; #define IDX_AXIS_PAGE 1 static const BYTE REPORT_AXIS_USAGE[] = { 0x09, 0x30, /* USAGE (X) */ }; #define IDX_AXIS_USAGE 1 static const BYTE REPORT_REL_AXIS_TAIL[] = { 0x15, 0x81, /* LOGICAL_MINIMUM (0) */ 0x25, 0x7f, /* LOGICAL_MAXIMUM (0xffff) */ 0x75, 0x08, /* REPORT_SIZE (16) */ 0x95, 0x02, /* REPORT_COUNT (2) */ 0x81, 0x06, /* INPUT (Data,Var,Rel) */ }; #define IDX_REL_AXIS_COUNT 7 static const BYTE REPORT_HATSWITCH[] = { 0x05, 0x01, /* USAGE_PAGE (Generic Desktop) */ 0x09, 0x39, /* USAGE (Hatswitch) */ 0x15, 0x01, /* LOGICAL_MINIMUM (1) */ 0x25, 0x08, /* LOGICAL_MAXIMUM (0x08) */ 0x35, 0x00, /* PHYSICAL_MINIMUM (0) */ 0x45, 0x08, /* PHYSICAL_MAXIMUM (8) */ 0x75, 0x04, /* REPORT_SIZE (4) */ 0x95, 0x01, /* REPORT_COUNT (1) */ 0x81, 0x02, /* INPUT (Data,Var,Abs) */ }; #define IDX_HATSWITCH_COUNT 15 static const BYTE REPORT_TAIL[] = { 0xc0, /* END_COLLECTION */ 0xc0 /* END_COLLECTION */ }; static inline BYTE *add_button_block(BYTE* report_ptr, BYTE usage_min, BYTE usage_max) { memcpy(report_ptr, REPORT_BUTTONS, sizeof(REPORT_BUTTONS)); report_ptr[IDX_BUTTON_MIN_USAGE] = usage_min; report_ptr[IDX_BUTTON_MAX_USAGE] = usage_max; report_ptr[IDX_BUTTON_COUNT] = (usage_max - usage_min) + 1; return report_ptr + sizeof(REPORT_BUTTONS); } static inline BYTE *add_padding_block(BYTE *report_ptr, BYTE bitcount) { memcpy(report_ptr, REPORT_PADDING, sizeof(REPORT_PADDING)); report_ptr[IDX_PADDING_BIT_COUNT] = bitcount; return report_ptr + sizeof(REPORT_PADDING); } static inline BYTE *add_hatswitch(BYTE *report_ptr, INT count) { memcpy(report_ptr, REPORT_HATSWITCH, sizeof(REPORT_HATSWITCH)); report_ptr[IDX_HATSWITCH_COUNT] = count; return report_ptr + sizeof(REPORT_HATSWITCH); }
jason-simmons/flutter_buildroot
mojo/edk/system/test/scoped_test_dir.h
// Copyright 2015 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef MOJO_EDK_SYSTEM_TEST_SCOPED_TEST_DIR_H_ #define MOJO_EDK_SYSTEM_TEST_SCOPED_TEST_DIR_H_ #include "base/files/scoped_temp_dir.h" #include "mojo/edk/util/scoped_file.h" #include "mojo/public/cpp/system/macros.h" namespace mojo { namespace system { namespace test { // Creates/destroyes a temporary directory for test purposes. (Unlike // |base::ScopedTempDir|, this automatically creates the temporary directory.) class ScopedTestDir final { public: ScopedTestDir(); ~ScopedTestDir(); util::ScopedFILE CreateFile(); private: base::ScopedTempDir temp_dir_; MOJO_DISALLOW_COPY_AND_ASSIGN(ScopedTestDir); }; } // namespace test } // namespace system } // namespace mojo #endif // MOJO_EDK_SYSTEM_TEST_SCOPED_TEST_DIR_H_
JLLeitschuh/myfaces-trinidad_20165019
trinidad-examples/trinidad-demo/src/main/java/org/apache/myfaces/trinidaddemo/ProgressStepsBean.java
<gh_stars>0 /* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information * regarding copyright ownership. The ASF licenses this file * to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance * with the License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, * software distributed under the License is distributed on an * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY * KIND, either express or implied. See the License for the * specific language governing permissions and limitations * under the License. */ package org.apache.myfaces.trinidaddemo; import java.io.IOException; import java.util.ArrayList; import java.util.List; import java.util.logging.Level; import java.util.logging.Logger; import javax.faces.context.ExternalContext; import javax.faces.context.FacesContext; import org.apache.myfaces.trinidad.event.PollEvent; import org.apache.myfaces.trinidad.model.DefaultBoundedRangeModel; /** * Bean for progress steps demos. * * @version $Name: $ ($Revision: adfrt/faces/adf-faces-demo/src/main/java/oracle/adfdemo/view/faces/ProgressStepsBean.java#1 $) $Date: 16-aug-2005.15:12:28 $ */ public class ProgressStepsBean extends ProgressBean { public List<String> getProgressSteps() { return _PROGRESS_STEPS; } public void onPoll(PollEvent event) { if ( __model != null && (__model.getMaximum() <= __model.getValue()) ) { //pu: This means the background task is complete. // End the task and navigate off to a different page. endProcess(); try { ExternalContext ec = FacesContext.getCurrentInstance().getExternalContext(); ec.redirect("../components/progressEnd.jspx?taskStatus=completed"); } catch(IOException ioe) { _LOG.log(Level.WARNING, "Could not redirect", ioe); } catch (RuntimeException re) { _LOG.log(Level.SEVERE, "Could not redirect", re); throw re; } } } @Override protected void prepare() { __model = new DefaultBoundedRangeModel(-1, 6); //pu: simulate asynchronous model updates on a different thread __processThread = new ProcessThread(1500, 1); __processThread.start(); } static private List<String> _PROGRESS_STEPS; static private final Logger _LOG = Logger.getLogger( ProgressStepsBean.class.getName()); static { _PROGRESS_STEPS = new ArrayList<String>(); _PROGRESS_STEPS.add("Checking for latest version"); _PROGRESS_STEPS.add("Checking available disk space"); _PROGRESS_STEPS.add("Copying files"); _PROGRESS_STEPS.add("Analyzing dependencies"); _PROGRESS_STEPS.add("Install in progress"); _PROGRESS_STEPS.add("Building icons and shortcuts"); } }
yyao84/aws-athena-query-federation
athena-cloudwatch-metrics/src/test/java/com/amazonaws/athena/connectors/cloudwatch/metrics/TestUtils.java
<filename>athena-cloudwatch-metrics/src/test/java/com/amazonaws/athena/connectors/cloudwatch/metrics/TestUtils.java<gh_stars>100-1000 /*- * #%L * athena-cloudwatch-metrics * %% * Copyright (C) 2019 Amazon Web Services * %% * 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. * #L% */ package com.amazonaws.athena.connectors.cloudwatch.metrics; import com.amazonaws.athena.connector.lambda.data.BlockAllocator; import com.amazonaws.athena.connector.lambda.domain.predicate.EquatableValueSet; import com.amazonaws.athena.connector.lambda.domain.predicate.ValueSet; import org.apache.arrow.vector.types.Types; public class TestUtils { private TestUtils() {} public static ValueSet makeStringEquals(BlockAllocator allocator, String value) { return EquatableValueSet.newBuilder(allocator, Types.MinorType.VARCHAR.getType(), true, false) .add(value).build(); } }
glacier0315/evo-admin
evo-web-app/src/test/java/com/glacier/evo/app/sys/service/UserServiceTest.java
<filename>evo-web-app/src/test/java/com/glacier/evo/app/sys/service/UserServiceTest.java package com.glacier.evo.app.sys.service; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.boot.test.context.SpringBootTest; import static org.junit.jupiter.api.Assertions.*; /** * date 2021-12-15 15:19 * * @author glacier * @version 1.0 */ @SpringBootTest class UserServiceTest { @Autowired private UserService userService; @BeforeEach void setUp() { } @AfterEach void tearDown() { } @Test void findById() { } @Test void findUserByUsername() { } @Test void findUserInfoByUsername() { } @Test void findUserProfileByUsername() { } @Test void loadUserByUsername() { } @Test void findPage() { } @Test void findList() { userService.findList(null) .forEach(System.out::println); } @Test void save() { } @Test void testSave() { } @Test void delete() { } @Test void resetPassword() { } @Test void updatePassword() { } @Test void updateProfile() { } @Test void updateAvatar() { } @Test void checkUsername() { } @Test void checkIdCard() { } }
steshaw/donkey
src/java/test/org/burroloco/butcher/util/dbunit/DefaultPrimaryKeyColumnFilter.java
<reponame>steshaw/donkey package org.burroloco.butcher.util.dbunit; import edge.org.dbunit.database.IDatabaseConnection; import edge.org.dbunit.dataset.IDataSet; import edge.org.dbunit.dataset.ITableMetaData; import org.dbunit.database.DatabaseConfig; import org.dbunit.dataset.Column; import org.dbunit.dataset.filter.IColumnFilter; public class DefaultPrimaryKeyColumnFilter implements PrimaryKeyColumnFilter { private static final String FILTER = "http://www.dbunit.org/properties/primaryKeyFilter"; public void set(IDatabaseConnection connection, IDataSet dataSet) { DatabaseConfig config = connection.getConfig(); config.setProperty(FILTER, new PrimaryKeyFilter(dataSet)); } private class PrimaryKeyFilter implements IColumnFilter { private IDataSet dataSet; public PrimaryKeyFilter(IDataSet dataSet) { this.dataSet = dataSet; } public boolean accept(String tableName, Column column) { String name = firstColumn(tableName); return isFirstColumn(column, name); } private boolean isFirstColumn(Column column, String name) { return name.equalsIgnoreCase(column.getColumnName()); } private String firstColumn(String tableName) { ITableMetaData md = dataSet.getTableMetaData(tableName); edge.org.dbunit.dataset.Column first = md.getColumns()[0]; return first.getColumnName(); } } }
elva2596/whitestorm.js
modules/whs-module-audio/src/index.js
<filename>modules/whs-module-audio/src/index.js import { PositionalAudio, AudioListener, AudioLoader } from 'three'; export default class PositionalAudioModule { constructor(params = {}) { this.params = Object.assign({ loop: true }, params); this.audioListener = new AudioListener(); this.audioLoader = new AudioLoader(); this.positionalAudio = new PositionalAudio(this.audioListener); this.positionalAudio.setLoop(this.params.loop); } addListener(object) { object.native.add(this.audioListener); }; playAudio(path) { const sound = this.positionalAudio; this.audioLoader.load(path, buffer => { sound.setBuffer(buffer); sound.setRefDistance(50); sound.play(); }); }; bridge = { mesh(mesh, self) { mesh.add(self.positionalAudio); return mesh; } } }
mengerzhuanyong/CommonPeopleFarmers
src/components/default/Overlay/Views/OverlayBase.js
'use strict'; import React, { useMemo } from 'react'; import { StyleSheet, Animated, View, ViewPropTypes, TouchableWithoutFeedback, } from 'react-native'; import PropTypes from 'prop-types'; function OverlayBase(props) { const { style, maskStyle, maskPointerEvents, onPressMask, children } = props; const buildStyles = useMemo(() => { return { style: [StyleSheet.absoluteFill, style], maskStyle: [styles.maskStyle, maskStyle], }; }, [maskStyle, style]); return ( <View style={buildStyles.style} pointerEvents={maskPointerEvents}> <TouchableWithoutFeedback onPress={onPressMask}> <Animated.View pointerEvents={maskPointerEvents} style={buildStyles.maskStyle} /> </TouchableWithoutFeedback> {children} </View> ); } const styles = StyleSheet.create({ maskStyle: { ...StyleSheet.absoluteFillObject, backgroundColor: '#000', }, }); OverlayBase.propTypes = { style: ViewPropTypes.style, modal: PropTypes.bool, maskOpacity: PropTypes.number, maskPointerEvents: ViewPropTypes.pointerEvents, closeOnHardwareBackPress: PropTypes.bool, onAppearCompleted: PropTypes.func, onDisappearCompleted: PropTypes.func, }; OverlayBase.defaultProps = { modal: false, maskPointerEvents: 'auto', closeOnHardwareBackPress: true, maskOpacity: 0.3, }; export default React.memo(OverlayBase);
allansrc/fuchsia
src/connectivity/bluetooth/core/bt-host/gap/low_energy_connection_request.cc
<reponame>allansrc/fuchsia<gh_stars>1-10 // Copyright 2020 The Fuchsia Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #include "low_energy_connection_request.h" namespace bt::gap::internal { LowEnergyConnectionRequest::LowEnergyConnectionRequest( PeerId peer_id, ConnectionResultCallback first_callback, LowEnergyConnectionOptions connection_options, Peer::InitializingConnectionToken peer_conn_token) : peer_id_(peer_id, MakeToStringInspectConvertFunction()), callbacks_(/*convert=*/[](const auto& cbs) { return cbs.size(); }), connection_options_(connection_options), peer_conn_token_(std::move(peer_conn_token)) { callbacks_.Mutable()->push_back(std::move(first_callback)); } void LowEnergyConnectionRequest::NotifyCallbacks(fitx::result<HostError, RefFunc> result) { peer_conn_token_.reset(); for (const auto& callback : *callbacks_) { if (result.is_error()) { callback(fitx::error(result.error_value())); continue; } auto conn_ref = result.value()(); callback(fitx::ok(std::move(conn_ref))); } } void LowEnergyConnectionRequest::AttachInspect(inspect::Node& parent, std::string name) { inspect_node_ = parent.CreateChild(name); peer_id_.AttachInspect(inspect_node_, "peer_id"); callbacks_.AttachInspect(inspect_node_, "callbacks"); } } // namespace bt::gap::internal
iabd/modernmt
src/commons/src/main/java/eu/modernmt/config/xml/XMLConfigBuilder.java
package eu.modernmt.config.xml; import eu.modernmt.config.ConfigException; import eu.modernmt.config.NodeConfig; import org.w3c.dom.Document; import org.w3c.dom.Element; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.ParserConfigurationException; import javax.xml.transform.*; import javax.xml.transform.dom.DOMResult; import javax.xml.transform.stream.StreamSource; import java.io.File; /** * Created by davide on 04/01/17. */ public class XMLConfigBuilder extends XMLAbstractBuilder { private final XMLNetworkConfigBuilder networkConfigBuilder; private final XMLDataStreamConfigBuilder dataStreamConfigBuilder; private final XMLDatabaseConfigBuilder databaseConfigBuilder; private final XMLEngineConfigBuilder engineConfigBuilder; private XMLConfigBuilder(Element element) { super(element); networkConfigBuilder = new XMLNetworkConfigBuilder(getChild("network")); dataStreamConfigBuilder = new XMLDataStreamConfigBuilder(getChild("datastream")); databaseConfigBuilder = new XMLDatabaseConfigBuilder(getChild("db")); engineConfigBuilder = new XMLEngineConfigBuilder(getChild("engine")); } public static NodeConfig build(File file) throws ConfigException { Document document; try { Transformer transformer = TransformerFactory.newInstance().newTransformer(); Source source = new StreamSource(file); DocumentBuilder builder = DocumentBuilderFactory.newInstance().newDocumentBuilder(); document = builder.newDocument(); Result result = new DOMResult(document); transformer.transform(source, result); } catch (TransformerException | ParserConfigurationException e) { throw new ConfigException("Unable to parse config file " + file, e); } XMLConfigBuilder instance = new XMLConfigBuilder(document.getDocumentElement()); return instance.build(new NodeConfig()); } private NodeConfig build(NodeConfig config) throws ConfigException { networkConfigBuilder.build(config.getNetworkConfig()); dataStreamConfigBuilder.build(config.getDataStreamConfig()); databaseConfigBuilder.build(config.getDatabaseConfig()); engineConfigBuilder.build(config.getEngineConfig()); return config; } }
stormtheh4ck3r/python-for-android
python-modules/twisted/twisted/test/test_fdesc.py
# Copyright (c) 2007-2009 Twisted Matrix Laboratories. # See LICENSE for details. """ Tests for L{twisted.internet.fdesc}. """ import os, sys import errno try: import fcntl except ImportError: skip = "not supported on this platform" else: from twisted.internet import fdesc from twisted.python.util import untilConcludes from twisted.trial import unittest class ReadWriteTestCase(unittest.TestCase): """ Tests for fdesc.readFromFD, fdesc.writeToFD. """ def setUp(self): """ Create two non-blocking pipes that can be used in tests. """ self.r, self.w = os.pipe() fdesc.setNonBlocking(self.r) fdesc.setNonBlocking(self.w) def tearDown(self): """ Close pipes. """ try: os.close(self.w) except OSError: pass try: os.close(self.r) except OSError: pass def write(self, d): """ Write data to the pipe. """ return fdesc.writeToFD(self.w, d) def read(self): """ Read data from the pipe. """ l = [] res = fdesc.readFromFD(self.r, l.append) if res is None: if l: return l[0] else: return "" else: return res def test_writeAndRead(self): """ Test that the number of bytes L{fdesc.writeToFD} reports as written with its return value are seen by L{fdesc.readFromFD}. """ n = self.write("hello") self.failUnless(n > 0) s = self.read() self.assertEquals(len(s), n) self.assertEquals("hello"[:n], s) def test_writeAndReadLarge(self): """ Similar to L{test_writeAndRead}, but use a much larger string to verify the behavior for that case. """ orig = "0123456879" * 10000 written = self.write(orig) self.failUnless(written > 0) result = [] resultlength = 0 i = 0 while resultlength < written or i < 50: result.append(self.read()) resultlength += len(result[-1]) # Increment a counter to be sure we'll exit at some point i += 1 result = "".join(result) self.assertEquals(len(result), written) self.assertEquals(orig[:written], result) def test_readFromEmpty(self): """ Verify that reading from a file descriptor with no data does not raise an exception and does not result in the callback function being called. """ l = [] result = fdesc.readFromFD(self.r, l.append) self.assertEquals(l, []) self.assertEquals(result, None) def test_readFromCleanClose(self): """ Test that using L{fdesc.readFromFD} on a cleanly closed file descriptor returns a connection done indicator. """ os.close(self.w) self.assertEquals(self.read(), fdesc.CONNECTION_DONE) def test_writeToClosed(self): """ Verify that writing with L{fdesc.writeToFD} when the read end is closed results in a connection lost indicator. """ os.close(self.r) self.assertEquals(self.write("s"), fdesc.CONNECTION_LOST) def test_readFromInvalid(self): """ Verify that reading with L{fdesc.readFromFD} when the read end is closed results in a connection lost indicator. """ os.close(self.r) self.assertEquals(self.read(), fdesc.CONNECTION_LOST) def test_writeToInvalid(self): """ Verify that writing with L{fdesc.writeToFD} when the write end is closed results in a connection lost indicator. """ os.close(self.w) self.assertEquals(self.write("s"), fdesc.CONNECTION_LOST) def test_writeErrors(self): """ Test error path for L{fdesc.writeTod}. """ oldOsWrite = os.write def eagainWrite(fd, data): err = OSError() err.errno = errno.EAGAIN raise err os.write = eagainWrite try: self.assertEquals(self.write("s"), 0) finally: os.write = oldOsWrite def eintrWrite(fd, data): err = OSError() err.errno = errno.EINTR raise err os.write = eintrWrite try: self.assertEquals(self.write("s"), 0) finally: os.write = oldOsWrite class CloseOnExecTests(unittest.TestCase): """ Tests for L{fdesc._setCloseOnExec} and L{fdesc._unsetCloseOnExec}. """ program = ''' import os, errno try: os.write(%d, 'lul') except OSError, e: if e.errno == errno.EBADF: os._exit(0) os._exit(5) except: os._exit(10) else: os._exit(20) ''' def _execWithFileDescriptor(self, fObj): pid = os.fork() if pid == 0: try: os.execv(sys.executable, [sys.executable, '-c', self.program % (fObj.fileno(),)]) except: import traceback traceback.print_exc() os._exit(30) else: # On Linux wait(2) doesn't seem ever able to fail with EINTR but # POSIX seems to allow it and on OS X it happens quite a lot. return untilConcludes(os.waitpid, pid, 0)[1] def test_setCloseOnExec(self): """ A file descriptor passed to L{fdesc._setCloseOnExec} is not inherited by a new process image created with one of the exec family of functions. """ fObj = file(self.mktemp(), 'w') fdesc._setCloseOnExec(fObj.fileno()) status = self._execWithFileDescriptor(fObj) self.assertTrue(os.WIFEXITED(status)) self.assertEqual(os.WEXITSTATUS(status), 0) def test_unsetCloseOnExec(self): """ A file descriptor passed to L{fdesc._unsetCloseOnExec} is inherited by a new process image created with one of the exec family of functions. """ fObj = file(self.mktemp(), 'w') fdesc._setCloseOnExec(fObj.fileno()) fdesc._unsetCloseOnExec(fObj.fileno()) status = self._execWithFileDescriptor(fObj) self.assertTrue(os.WIFEXITED(status)) self.assertEqual(os.WEXITSTATUS(status), 20)
gtalarico/revitpythonwrapper
rpw/__revit.py
""" The main rpw namespace and rpw.revit provide you with most of the imports will need. >>> from rpw import revit, db, ui >>> db.Element(SomeElement) >>> ui.Selection() >>> revit.doc >>> revit.uidoc.ActiveView Revit Namespaces are also available: >>> from rpw import DB, UI >>> DB.ElementId(00000) >>> UI.TaskDialog In summary, if you use rpw, this could potentially be the only import line you would need: >>> from rpw import revit, db, ui, DB, UI """ # import rpw from rpw.utils.dotnet import clr, Process from rpw.utils.logger import logger from rpw.base import BaseObject class Revit(BaseObject): """ Revit Application Wrapper Note: The module path for the Revit Wrapper and its namespaces is ``rpw.__revit.Revit``. However, the ``Revit()`` is always instantiated on the initialization of rpw, and is stored along with the ``DB`` and ``UI`` namespaces in the root of rpw module. In other words, to use this wrapper all you need is to import ``from rpw import revit`` >>> from rpw import revit >>> revit.doc <Autodesk.Revit.DB.Document> >>> revit.username gtalarico >>> revit.host 'Dynamo' """ class HOSTS(): RPS = 'RPS' DYNAMO = 'Dynamo' def __init__(self): try: self.uiapp = __revit__ self._host = Revit.HOSTS.RPS except NameError: try: # Try Getting handler from Dynamo RevitServices self.uiapp = self.find_dynamo_uiapp() self._host = Revit.HOSTS.DYNAMO except Exception as errmsg: logger.warning('Revit Application handle could not be found') try: # Add DB UI Import to globals so it can be imported by rpw clr.AddReference('RevitAPI') clr.AddReference('RevitAPIUI') from Autodesk.Revit import DB, UI globals().update({'DB': DB, 'UI': UI}) except Exception: # Replace Globals with Mock Objects for Sphinx and ipy direct exec. logger.warning('RevitAPI References could not be added') from rpw.utils.sphinx_compat import MockObject globals().update({'DB': MockObject(fullname='Autodesk.Revit.DB'), 'UI': MockObject(fullname='Autodesk.Revit.DB')}) self.uiapp = MockObject(fullname='Autodesk.Revit.UI.UIApplication') self._host = None def find_dynamo_uiapp(self): clr.AddReference("RevitServices") import RevitServices from RevitServices.Persistence import DocumentManager import sys sys.path.append(r'C:\Program Files (x86)\IronPython 2.7\Lib') return DocumentManager.Instance.CurrentUIApplication @property def host(self): """ Host is set based on how revit handle was found. Returns: Host (str): Revit Application Host ['RPS', 'Dynamo'] """ return self._host def open(self, path): """ Opens New Document """ @property def doc(self): """ Returns: uiapp.ActiveUIDocument.Document """ return getattr(self.uiapp.ActiveUIDocument, 'Document', None) @property def uidoc(self): """ Returns: uiapp.ActiveUIDocument """ return getattr(self.uiapp, 'ActiveUIDocument', None) @property def active_view(self): """ Returns: uidoc.ActiveView """ return rpw.db.Element(self.uidoc.ActiveView) @active_view.setter def active_view(self, view_reference): self.uidoc.ActiveView = view_reference @property def app(self): """ Returns: uidoc.Application """ return self.uiapp.Application @property def docs(self): """ Returns: uidoc.Application.Documents """ return [doc for doc in self.app.Documents] @property def username(self): """ Returns: uidoc.Application.Username """ return self.uiapp.Application.Username @property def version(self): """ Returns: uidoc.Application.Username """ return RevitVersion(self.uiapp) @property def process(self): """ Returns: Process.GetCurrentProcess() """ return Process.GetCurrentProcess() @property def process_id(self): """ Returns: Process.GetCurrentProcess() """ return self.process.Id @property def process_name(self): """ Returns: Process.GetCurrentProcess() """ return self.process.ProcessName def __repr__(self): return '<{version} [{process}:{pid}]>'.format(version=self.version, process=self.process_name, pid=self.process_id) # Check what this is # @property # def process(self): # clr.AddReferenceByPartialName('System.Windows.Forms') # # noinspection PyUnresolvedReferences # from System.Windows.Forms import Screen # return Screen.FromHandle(Process.GetCurrentProcess().MainWindowHandle) class RevitVersion(): def __init__(self, uiapp): self.uiapp = uiapp @property def year(self): return self.uiapp.Application.VersionNumber @property def name(self): return self.uiapp.Application.VersionName @property def build(self): return self.uiapp.Application.VersionBuild def __lt__(self, other): """ Handle Version Comparison Logic""" raise NotImplemented def __gt__(self, other): """ Handle Version Comparison Logic""" raise NotImplemented def __repr__(self): return '<Version: {year}: {build}>'.format(year=self.name, build=self.build) def __str__(self): return '{name}:{build}'.format(name=self.name, build=self.build) revit = Revit()
bluemir/hive
app/utils/ErrorViews.java
<reponame>bluemir/hive package utils; import controllers.UserApp; import models.Project; import models.User; import play.api.templates.Html; import views.html.index.index; /** * The Enum Views. */ public enum ErrorViews { Forbidden { @Override public Html render(String messageKey) { return views.html.error.forbidden_default.render(messageKey); } @Override public Html render(String messageKey, Project project) { return views.html.error.forbidden.render(messageKey, project); } public Html render(String messageKey, String returnUrl) { if(UserApp.currentUser() == User.anonymous){ return views.html.user.login.render("error.fobidden", null, returnUrl); } else { return views.html.error.forbidden_default.render(messageKey); } } @Deprecated @Override public Html render(String messageKey, Project project, String type) { return null; } @Override public Html render() { return render("error.forbidden"); } }, NotFound { @Override public Html render(String messageKey) { return views.html.error.notfound_default.render(messageKey); } @Override public Html render(String messageKey, Project project) { return render(messageKey, project, null); } @Override public Html render(String messageKey, Project project, String type) { return views.html.error.notfound.render(messageKey, project, type); } @Override public Html render() { return render("error.notfound"); } }, RequestTextEntityTooLarge { @Override public Html render() { return views.html.error.requestTextEntityTooLarge.render(); } @Override public Html render(String messageKey) { throw new UnsupportedOperationException(); } @Override public Html render(String messageKey, Project project) { throw new UnsupportedOperationException(); } @Override public Html render(String messageKey, Project project, String target) { throw new UnsupportedOperationException(); } }, BadRequest { @Override public Html render(String messageKey) { return views.html.error.badrequest_default.render(messageKey); } @Override public Html render(String messageKey, Project project) { return views.html.error.badrequest.render(messageKey, project); } @Deprecated @Override public Html render(String messageKey, Project project, String type) { return null; } @Override public Html render() { return render("error.badrequest"); } }; /** * 오류페이지 HTML을 레더링 한다. * 오류타입에 따라 default messageKey를 사용하고 레이아웃은 사이트레벨이 된다. * * notfound : error.notfound * fobidden : error.forbidden * badrequest : error.badrequest * * @return */ public abstract Html render(); /** * 오류페이지 HTML을 레더링 한다. * 메세지는 파라미터로 전달되는 messageKey를 사용하고 레이아웃은 사이트레벨이 된다. * * @param messageKey 메세지키 * @return */ public abstract Html render(String messageKey); /** * 오류페이지 HTML을 레더링 한다. * 메세지는 파라미터로 전달되는 messageKey를 사용하고 레이아웃은 프로젝트레벨이 된다. * * @param messageKey 메세지키 * @param project 프로젝트 정보 * @return */ public abstract Html render(String messageKey, Project project); /** * 오류페이지 HTML을 레더링 한다. * 메세지와 레이아웃은 세부타겟정보에 따라 이슈/게시판/프로젝트로 나뉘어 진다. * * @param messageKey 메세지키 * @param project 프로젝트 정보 * @param type 세부타겟 issue/post/etc(null, ... ) * @return */ public abstract Html render(String messageKey, Project project, String target); public Html render(String messageKey, String returnUrl) { return index.render(UserApp.currentUser()); }; }
alexzacher/BMI-Body-Mass-Index-Calculator-APP
venv/lib/python3.7/site-packages/PyInstaller/hooks/hook-pywintypes.py
#----------------------------------------------------------------------------- # Copyright (c) 2005-2020, PyInstaller Development Team. # # Distributed under the terms of the GNU General Public License (version 2 # or later) with exception for distributing the bootloader. # # The full license is in the file COPYING.txt, distributed with this software. # # SPDX-License-Identifier: (GPL-2.0-or-later WITH Bootloader-exception) #----------------------------------------------------------------------------- """ pywin32 module supports frozen mode. In frozen mode it is looking in sys.path for file pywintypesXX.dll. Include the pywintypesXX.dll as a data file. The path to this dll is contained in __file__ attribute. """ from PyInstaller.utils.hooks import get_pywin32_module_file_attribute _pth = get_pywin32_module_file_attribute('pywintypes') binaries = [(_pth, '.')]
shivampandey0/build
solutions/arrays/05.js
<reponame>shivampandey0/build // Find sum of two arrays. // [3, 5, 2, 9, 4] = 3 + 5 + 2 + 9 + 4 = 23 // [6, 2, 8, 1, 3] = 6 + 2 + 8 + 1 + 3 = 20 // Final Output: 20 + 23 = 43 const getSum = (arr1,arr2) => { let sum = 0; for (const num of arr1) { sum+=num; } for (const num of arr2) { sum += num; } return sum; } console.log(getSum([3, 5, 2, 9, 4], [6, 2, 8, 1, 3]));
PaccMann/paccmann_chemistry
examples/train_vae.py
#!/usr/bin/env python3 """Train TeacherVAE molecule generator.""" import argparse import json import logging import os import sys from time import time from paccmann_chemistry.utils import ( collate_fn, get_device, disable_rdkit_logging ) from paccmann_chemistry.models.vae import ( StackGRUDecoder, StackGRUEncoder, TeacherVAE ) from paccmann_chemistry.models.training import train_vae from paccmann_chemistry.utils.hyperparams import SEARCH_FACTORY from pytoda.datasets import SMILESDataset from pytoda.smiles.smiles_language import SMILESLanguage from torch.utils.tensorboard import SummaryWriter import torch # setup logging logging.basicConfig(stream=sys.stdout, level=logging.DEBUG) logger = logging.getLogger('training_vae') # yapf: disable parser = argparse.ArgumentParser(description='Chemistry VAE training script.') parser.add_argument( 'train_smiles_filepath', type=str, help='Path to the train data file (.smi).' ) parser.add_argument( 'test_smiles_filepath', type=str, help='Path to the test data file (.smi).' ) parser.add_argument( 'smiles_language_filepath', type=str, help='Path to SMILES language object.' ) parser.add_argument( 'model_path', type=str, help='Directory where the model will be stored.' ) parser.add_argument( 'params_filepath', type=str, help='Path to the parameter file.' ) parser.add_argument( 'training_name', type=str, help='Name for the training.' ) # yapf: enable def main(parser_namespace): try: device = get_device() disable_rdkit_logging() # read the params json params = dict() with open(parser_namespace.params_filepath) as f: params.update(json.load(f)) # get params train_smiles_filepath = parser_namespace.train_smiles_filepath test_smiles_filepath = parser_namespace.test_smiles_filepath smiles_language_filepath = ( parser_namespace.smiles_language_filepath if parser_namespace.smiles_language_filepath.lower() != 'none' else None ) model_path = parser_namespace.model_path training_name = parser_namespace.training_name writer = SummaryWriter(f'logs/{training_name}') logger.info(f'Model with name {training_name} starts.') model_dir = os.path.join(model_path, training_name) log_path = os.path.join(model_dir, 'logs') val_dir = os.path.join(log_path, 'val_logs') os.makedirs(os.path.join(model_dir, 'weights'), exist_ok=True) os.makedirs(os.path.join(model_dir, 'results'), exist_ok=True) os.makedirs(log_path, exist_ok=True) os.makedirs(val_dir, exist_ok=True) # Load SMILES language smiles_language = None if smiles_language_filepath is not None: smiles_language = SMILESLanguage.load(smiles_language_filepath) logger.info(f'Smiles filepath: {train_smiles_filepath}') # create SMILES eager dataset smiles_train_data = SMILESDataset( train_smiles_filepath, smiles_language=smiles_language, padding=False, selfies=params.get('selfies', False), add_start_and_stop=params.get('add_start_stop_token', True), augment=params.get('augment_smiles', False), canonical=params.get('canonical', False), kekulize=params.get('kekulize', False), all_bonds_explicit=params.get('all_bonds_explicit', False), all_hs_explicit=params.get('all_hs_explicit', False), remove_bonddir=params.get('remove_bonddir', False), remove_chirality=params.get('remove_chirality', False), backend='lazy', device=device, ) smiles_test_data = SMILESDataset( test_smiles_filepath, smiles_language=smiles_language, padding=False, selfies=params.get('selfies', False), add_start_and_stop=params.get('add_start_stop_token', True), augment=params.get('augment_smiles', False), canonical=params.get('canonical', False), kekulize=params.get('kekulize', False), all_bonds_explicit=params.get('all_bonds_explicit', False), all_hs_explicit=params.get('all_hs_explicit', False), remove_bonddir=params.get('remove_bonddir', False), remove_chirality=params.get('remove_chirality', False), backend='lazy', device=device, ) if smiles_language_filepath is None: smiles_language = smiles_train_data.smiles_language smiles_language.save( os.path.join(model_path, f'{training_name}.lang') ) else: smiles_language_filename = os.path.basename(smiles_language_filepath) smiles_language.save( os.path.join(model_dir, smiles_language_filename) ) params.update( { 'vocab_size': smiles_language.number_of_tokens, 'pad_index': smiles_language.padding_index } ) vocab_dict = smiles_language.index_to_token params.update( { 'start_index': list(vocab_dict.keys()) [list(vocab_dict.values()).index('<START>')], 'end_index': list(vocab_dict.keys()) [list(vocab_dict.values()).index('<STOP>')] } ) if params.get('embedding', 'learned') == 'one_hot': params.update({'embedding_size': params['vocab_size']}) with open(os.path.join(model_dir, 'model_params.json'), 'w') as fp: json.dump(params, fp) # create DataLoaders train_data_loader = torch.utils.data.DataLoader( smiles_train_data, batch_size=params.get('batch_size', 64), collate_fn=collate_fn, drop_last=True, shuffle=True, pin_memory=params.get('pin_memory', True), num_workers=params.get('num_workers', 8) ) test_data_loader = torch.utils.data.DataLoader( smiles_test_data, batch_size=params.get('batch_size', 64), collate_fn=collate_fn, drop_last=True, shuffle=True, pin_memory=params.get('pin_memory', True), num_workers=params.get('num_workers', 8) ) # initialize encoder and decoder gru_encoder = StackGRUEncoder(params).to(device) gru_decoder = StackGRUDecoder(params).to(device) gru_vae = TeacherVAE(gru_encoder, gru_decoder).to(device) # TODO I haven't managed to get this to work. I will leave it here # if somewant (or future me) wants to give it a look and get the # tensorboard graph to work # if writer and False: # gru_vae.set_batch_mode('padded') # dummy_input = torch.ones(smiles_train_data[0].shape) # dummy_input = dummy_input.unsqueeze(0).to(device) # writer.add_graph(gru_vae, (dummy_input, dummy_input, dummy_input)) # gru_vae.set_batch_mode(params.get('batch_mode')) logger.info('\n****MODEL SUMMARY***\n') for name, parameter in gru_vae.named_parameters(): logger.info(f'Param {name}, shape:\t{parameter.shape}') total_params = sum(p.numel() for p in gru_vae.parameters()) logger.info(f'Total # params: {total_params}') loss_tracker = { 'test_loss_a': 10e4, 'test_rec_a': 10e4, 'test_kld_a': 10e4, 'ep_loss': 0, 'ep_rec': 0, 'ep_kld': 0 } # train for n_epoch epochs logger.info( 'Model creation and data processing done, Training starts.' ) decoder_search = SEARCH_FACTORY[ params.get('decoder_search', 'sampling') ]( temperature=params.get('temperature', 1.), beam_width=params.get('beam_width', 3), top_tokens=params.get('top_tokens', 5) ) # yapf: disable if writer: pparams = params.copy() pparams['training_file'] = train_smiles_filepath pparams['test_file'] = test_smiles_filepath pparams['language_file'] = smiles_language_filepath pparams['model_path'] = model_path pparams = { k: v if v is not None else 'N.A.' for k, v in params.items() } pparams['training_name'] = training_name from pprint import pprint pprint(pparams) writer.add_hparams(hparam_dict=pparams, metric_dict={}) for epoch in range(params['epochs'] + 1): t = time() loss_tracker = train_vae( epoch, gru_vae, train_data_loader, test_data_loader, smiles_language, model_dir, search=decoder_search, optimizer=params.get('optimizer', 'adadelta'), lr=params['learning_rate'], kl_growth=params['kl_growth'], input_keep=params['input_keep'], test_input_keep=params['test_input_keep'], generate_len=params['generate_len'], log_interval=params['log_interval'], save_interval=params['save_interval'], eval_interval=params['eval_interval'], loss_tracker=loss_tracker, logger=logger, # writer=writer, batch_mode=params.get('batch_mode') ) logger.info(f'Epoch {epoch}, took {time() - t:.1f}.') logger.info( 'OVERALL: \t Best loss = {0:.4f} in Ep {1}, ' 'best Rec = {2:.4f} in Ep {3}, ' 'best KLD = {4:.4f} in Ep {5}'.format( loss_tracker['test_loss_a'], loss_tracker['ep_loss'], loss_tracker['test_rec_a'], loss_tracker['ep_rec'], loss_tracker['test_kld_a'], loss_tracker['ep_kld'] ) ) logger.info('Training done, shutting down.') except Exception: logger.exception('Exception occurred while running train_vae.py.') if __name__ == '__main__': args = parser.parse_args() main(parser_namespace=args)
acety23/algorithms-sedgewick-wayne
src/chapter1/section4/Exercise16_ClosestPair.java
<gh_stars>1000+ package chapter1.section4; import edu.princeton.cs.algs4.StdOut; import java.util.Arrays; /** * Created by <NAME> on 9/30/16. */ public class Exercise16_ClosestPair { public static void main(String[] args) { double[] array1 = {-5.2, 9.4, 20, -10, 21.1, 40, 50, -20}; double[] array2 = {-4, -3, 0, 10, 20}; double[] array3 = {-10, -3, 0, 2, 4, 20}; double[] closestPair1 = closestPair(array1); double[] closestPair2 = closestPair(array2); double[] closestPair3 = closestPair(array3); StdOut.println("Closest pair: " + closestPair1[0] + " " + closestPair1[1] + " Expected: 20.0 21.1"); StdOut.println("Closest pair: " + closestPair2[0] + " " + closestPair2[1] + " Expected: -4.0 -3.0"); StdOut.println("Closest pair: " + closestPair3[0] + " " + closestPair3[1] + " Expected: 0.0 2.0"); } private static double[] closestPair(double[] array) { double[] closestPair = new double[2]; double currentMinimumDifference = Double.MAX_VALUE; Arrays.sort(array); for(int i = 0; i < array.length - 1; i++) { if (Math.abs(array[i] - array[i + 1]) < currentMinimumDifference) { currentMinimumDifference = Math.abs(array[i] - array[i + 1]); closestPair[0] = array[i]; closestPair[1] = array[i + 1]; } } return closestPair; } }
Matthelonianxl/deltacloud-core
clients/java/org.apache.deltacloud.client/src/org/apache/deltacloud/client/StateAware.java
<gh_stars>1-10 /************************************************************************* * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed with * this work for additional information regarding copyright ownership. The * ASF licenses this file to you under the Apache License, Version 2.0 (the * "License"); you may not use this file except in compliance with the * License. You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the * License for the specific language governing permissions and limitations * under the License. * *************************************************************************/ package org.apache.deltacloud.client; /** * @author <NAME> * * @param <OWNER> */ public abstract class StateAware<OWNER> extends ActionAware<OWNER> { public static enum State { RUNNING, STOPPED, PENDING, TERMINATED, BOGUS }; private State state; public void setState(String state) { try { this.state = State.valueOf(state); } catch (Exception e) { this.state = State.BOGUS; } } public State getState() { return state; } public boolean isRunning() { return getState() == State.RUNNING; } public boolean isStopped() { return getState() == State.STOPPED; } }
f0rb/doyto-query
doyto-query-mongodb/src/main/java/win/doyto/query/mongodb/MongoDataAccess.java
/* * Copyright © 2019-2022 <NAME> * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ package win.doyto.query.mongodb; import com.fasterxml.jackson.core.type.TypeReference; import com.mongodb.client.FindIterable; import com.mongodb.client.MongoClient; import com.mongodb.client.MongoCollection; import com.mongodb.client.MongoDatabase; import com.mongodb.client.model.Projections; import lombok.Getter; import lombok.extern.slf4j.Slf4j; import org.apache.commons.lang3.StringUtils; import org.bson.Document; import org.bson.conversions.Bson; import org.bson.types.ObjectId; import win.doyto.query.core.DataAccess; import win.doyto.query.core.DoytoQuery; import win.doyto.query.core.IdWrapper; import win.doyto.query.entity.MongoEntity; import win.doyto.query.entity.Persistable; import win.doyto.query.mongodb.entity.ObjectIdAware; import win.doyto.query.mongodb.entity.ObjectIdMapper; import win.doyto.query.mongodb.filter.MongoFilterBuilder; import win.doyto.query.util.BeanUtil; import java.io.Serializable; import java.util.ArrayList; import java.util.Arrays; import java.util.List; import java.util.stream.Collectors; import static com.mongodb.client.model.Filters.eq; import static com.mongodb.client.model.Filters.in; /** * MongoDataAccess * * @author f0rb on 2021-11-23 */ @Slf4j public class MongoDataAccess<E extends Persistable<I>, I extends Serializable, Q extends DoytoQuery> implements DataAccess<E, I, Q> { private static final String MONGO_ID = "_id"; private final Class<E> entityClass; @Getter private final MongoCollection<Document> collection; public MongoDataAccess(MongoClient mongoClient, Class<E> testEntityClass) { this.entityClass = testEntityClass; MongoEntity table = testEntityClass.getAnnotation(MongoEntity.class); MongoDatabase database = mongoClient.getDatabase(table.database()); this.collection = database.getCollection(table.collection()); } private void setObjectId(E entity, Document document) { ObjectId objectId = (ObjectId) document.get(MONGO_ID); if (entity instanceof ObjectIdAware) { ((ObjectIdAware) entity).setObjectId(objectId); } } private Bson getIdFilter(Object id) { return eq(MONGO_ID, new ObjectId(id.toString())); } private Bson buildFilterForChange(Q query) { return query.needPaging() ? in(MONGO_ID, queryObjectId(query)) : MongoFilterBuilder.buildFilter(query); } @Override public List<E> query(Q query) { return queryColumns(query, entityClass); } @Override public long count(Q query) { return collection.countDocuments(MongoFilterBuilder.buildFilter(query)); } @Override public <V> List<V> queryColumns(Q query, Class<V> clazz, String... columns) { FindIterable<Document> findIterable = collection .find(MongoFilterBuilder.buildFilter(query)) .projection(Projections.include(columns)); if (query.getSort() != null) { findIterable.sort(MongoFilterBuilder.buildSort(query.getSort())); } if (query.needPaging()) { findIterable.skip(query.calcOffset()).limit(query.getPageSize()); } return findIterable .map(document -> convert(document, columns, clazz)) .into(new ArrayList<>()); } private <V> V convert(Document document, String[] columns, Class<V> clazz) { V e; if (columns.length == 1) { if (columns[0].contains(".")) { e = document.getEmbedded(splitToKeys(columns[0]), clazz); } else { e = document.get(columns[0], clazz); } } else { e = BeanUtil.parse(document.toJson(), clazz); } if (log.isDebugEnabled()) { log.debug("Entity parsed: {}", BeanUtil.stringify(e)); } return e; } private List<String> splitToKeys(String column) { return Arrays.asList(StringUtils.split(column, ".")); } @Override public E get(IdWrapper<I> w) { return collection .find(getIdFilter(w.getId())) .map(document -> BeanUtil.parse(document.toJson(), entityClass)).first(); } @Override public int delete(IdWrapper<I> w) { return (int) collection.deleteOne(getIdFilter(w.getId())).getDeletedCount(); } @Override public int delete(Q query) { Bson inId = buildFilterForChange(query); return (int) collection.deleteMany(inId).getDeletedCount(); } @Override public void create(E entity) { Document document = BeanUtil.convertToIgnoreNull(entity, Document.class); collection.insertOne(document); setObjectId(entity, document); } @Override public int batchInsert(Iterable<E> entities, String... columns) { List<Document> documents = BeanUtil.convertToIgnoreNull(entities, new TypeReference<List<Document>>() {}); collection.insertMany(documents); int i = 0; for (E entity : entities) { setObjectId(entity, documents.get(i)); i++; } return documents.size(); } @Override public int update(E e) { Bson filter = getIdFilter(e.getId()); Document replacement = BeanUtil.convertTo(e, Document.class); replacement.remove(MONGO_ID); return (int) collection.replaceOne(filter, replacement).getModifiedCount(); } @Override public int patch(E e) { Bson updates = MongoFilterBuilder.buildUpdates(e); return (int) collection.updateOne(getIdFilter(e.getId()), updates).getModifiedCount(); } @Override public int patch(E e, Q q) { Bson updates = MongoFilterBuilder.buildUpdates(e); Bson inId = buildFilterForChange(q); return (int) collection.updateMany(inId, updates).getModifiedCount(); } @Override public List<I> queryIds(Q query) { return queryObjectId(query) .stream() .<I>map(objectId -> ObjectIdMapper.convert(entityClass, objectId)) .collect(Collectors.toList()); } public List<ObjectId> queryObjectId(Q query) { return queryColumns(query, ObjectId.class, MONGO_ID); } }
adammillerio/vsphere-automation-sdk-python
com/vmware/vcenter/tokenservice_client.py
<reponame>adammillerio/vsphere-automation-sdk-python # -*- coding: utf-8 -*- #--------------------------------------------------------------------------- # Copyright 2020 VMware, Inc. All rights reserved. # AUTO GENERATED FILE -- DO NOT MODIFY! # # vAPI stub file for package com.vmware.vcenter.tokenservice. #--------------------------------------------------------------------------- """ The ``com.vmware.vcenter.tokenservice_client`` module provides Token classes. """ __author__ = 'VMware, Inc.' __docformat__ = 'restructuredtext en' import sys from vmware.vapi.bindings import type from vmware.vapi.bindings.converter import TypeConverter from vmware.vapi.bindings.enum import Enum from vmware.vapi.bindings.error import VapiError from vmware.vapi.bindings.struct import VapiStruct from vmware.vapi.bindings.stub import ( ApiInterfaceStub, StubFactoryBase, VapiInterface) from vmware.vapi.bindings.common import raise_core_exception from vmware.vapi.data.validator import (UnionValidator, HasFieldsOfValidator) from vmware.vapi.exception import CoreException from vmware.vapi.lib.constants import TaskType from vmware.vapi.lib.rest import OperationRestMetadata class Error(VapiError): """ The ``Error`` exception describes theattributes common to all standard exceptions. This exception serves two purposes: #. It is the exception that clients in many programming languages can catch to handle all standard exceptions. Typically those clients will display one or more of the localizable messages from :attr:`Error.messages` to a human. #. It is the exception that methods can report when they need to report some exception, but the exception doesn't fit into any other standard exception, and in fact the only reasonable way for a client to react to the exception is to display the message(s) to a human. .. tip:: The arguments are used to initialize data attributes with the same names. """ _qualname = 'Error' def __init__(self, messages=None, data=None, ): """ :type messages: :class:`list` of :class:`com.vmware.vapi.std_client.LocalizableMessage` :param messages: Stack of one or more localizable messages for human exception consumers. The message at the top of the stack (first in the list) describes the exception from the perspective of the method the client invoked. Each subsequent message in the stack describes the "cause" of the prior message. :type data: :class:`vmware.vapi.struct.VapiStruct` or ``None`` :param data: Data to facilitate clients responding to the method reporting a standard exception to indicating that it was unable to complete successfully. Methods may provide data that clients can use when responding to exceptions. Since the data that clients need may be specific to the context of the method reporting the exception, different methods that report the same exception may provide different data in the exception. The documentation for each each method will describe what, if any, data it provides for each exception it reports. The null, null, and null classes are intended as possible values for this attribute. :class:`com.vmware.vapi.std_client.DynamicID` may also be useful as a value for this attribute (although that is not its primary purpose). Some classes may provide their own specific classes for use as the value of this attribute when reporting exceptions from their methods. Some methods will not set this attribute when reporting exceptions. """ self.messages = messages self.data = data VapiError.__init__(self) Error._set_binding_type(type.ErrorType( 'com.vmware.vcenter.tokenservice.error', { 'messages': type.ListType(type.ReferenceType('com.vmware.vapi.std_client', 'LocalizableMessage')), 'data': type.OptionalType(type.DynamicStructType('vmware.vapi.dynamic_struct', {}, VapiStruct)), }, Error)) class InvalidScope(Error): """ The ``InvalidScope`` exception indicates requested scope is invalid, unknown, malformed, or exceeds the scope granted by the resource owner. .. tip:: The arguments are used to initialize data attributes with the same names. """ _qualname = 'InvalidScope' def __init__(self, messages=None, data=None, ): """ :type messages: :class:`list` of :class:`com.vmware.vapi.std_client.LocalizableMessage` :param messages: Stack of one or more localizable messages for human exception consumers. The message at the top of the stack (first in the list) describes the exception from the perspective of the method the client invoked. Each subsequent message in the stack describes the "cause" of the prior message. :type data: :class:`vmware.vapi.struct.VapiStruct` or ``None`` :param data: Data to facilitate clients responding to the method reporting a standard exception to indicating that it was unable to complete successfully. Methods may provide data that clients can use when responding to exceptions. Since the data that clients need may be specific to the context of the method reporting the exception, different methods that report the same exception may provide different data in the exception. The documentation for each each method will describe what, if any, data it provides for each exception it reports. The null, null, and null classes are intended as possible values for this attribute. :class:`com.vmware.vapi.std_client.DynamicID` may also be useful as a value for this attribute (although that is not its primary purpose). Some classes may provide their own specific classes for use as the value of this attribute when reporting exceptions from their methods. Some methods will not set this attribute when reporting exceptions. """ Error.__init__( self, messages=messages, data=data, ) InvalidScope._set_binding_type(type.ErrorType( 'com.vmware.vcenter.tokenservice.invalid_scope', { 'messages': type.ListType(type.ReferenceType('com.vmware.vapi.std_client', 'LocalizableMessage')), 'data': type.OptionalType(type.DynamicStructType('vmware.vapi.dynamic_struct', {}, VapiStruct)), }, InvalidScope)) class InvalidRequest(Error): """ The ``InvalidRequest`` exception indicates that :class:`TokenExchange.ExchangeSpec` is missing a required parameter, includes an unsupported parameter value (other than :attr:`TokenExchange.ExchangeSpec.grant_type`) .. tip:: The arguments are used to initialize data attributes with the same names. """ _qualname = 'InvalidRequest' def __init__(self, messages=None, data=None, ): """ :type messages: :class:`list` of :class:`com.vmware.vapi.std_client.LocalizableMessage` :param messages: Stack of one or more localizable messages for human exception consumers. The message at the top of the stack (first in the list) describes the exception from the perspective of the method the client invoked. Each subsequent message in the stack describes the "cause" of the prior message. :type data: :class:`vmware.vapi.struct.VapiStruct` or ``None`` :param data: Data to facilitate clients responding to the method reporting a standard exception to indicating that it was unable to complete successfully. Methods may provide data that clients can use when responding to exceptions. Since the data that clients need may be specific to the context of the method reporting the exception, different methods that report the same exception may provide different data in the exception. The documentation for each each method will describe what, if any, data it provides for each exception it reports. The null, null, and null classes are intended as possible values for this attribute. :class:`com.vmware.vapi.std_client.DynamicID` may also be useful as a value for this attribute (although that is not its primary purpose). Some classes may provide their own specific classes for use as the value of this attribute when reporting exceptions from their methods. Some methods will not set this attribute when reporting exceptions. """ Error.__init__( self, messages=messages, data=data, ) InvalidRequest._set_binding_type(type.ErrorType( 'com.vmware.vcenter.tokenservice.invalid_request', { 'messages': type.ListType(type.ReferenceType('com.vmware.vapi.std_client', 'LocalizableMessage')), 'data': type.OptionalType(type.DynamicStructType('vmware.vapi.dynamic_struct', {}, VapiStruct)), }, InvalidRequest)) class InvalidGrant(Error): """ The ``InvalidGrant`` exception indicates that provided authorization grant (e.g., authorization code, resource owner credentials) or refresh token is invalid, expired, revoked, does not match the redirection URI used in the authorization request, or was issued to another client. .. tip:: The arguments are used to initialize data attributes with the same names. """ _qualname = 'InvalidGrant' def __init__(self, messages=None, data=None, ): """ :type messages: :class:`list` of :class:`com.vmware.vapi.std_client.LocalizableMessage` :param messages: Stack of one or more localizable messages for human exception consumers. The message at the top of the stack (first in the list) describes the exception from the perspective of the method the client invoked. Each subsequent message in the stack describes the "cause" of the prior message. :type data: :class:`vmware.vapi.struct.VapiStruct` or ``None`` :param data: Data to facilitate clients responding to the method reporting a standard exception to indicating that it was unable to complete successfully. Methods may provide data that clients can use when responding to exceptions. Since the data that clients need may be specific to the context of the method reporting the exception, different methods that report the same exception may provide different data in the exception. The documentation for each each method will describe what, if any, data it provides for each exception it reports. The null, null, and null classes are intended as possible values for this attribute. :class:`com.vmware.vapi.std_client.DynamicID` may also be useful as a value for this attribute (although that is not its primary purpose). Some classes may provide their own specific classes for use as the value of this attribute when reporting exceptions from their methods. Some methods will not set this attribute when reporting exceptions. """ Error.__init__( self, messages=messages, data=data, ) InvalidGrant._set_binding_type(type.ErrorType( 'com.vmware.vcenter.tokenservice.invalid_grant', { 'messages': type.ListType(type.ReferenceType('com.vmware.vapi.std_client', 'LocalizableMessage')), 'data': type.OptionalType(type.DynamicStructType('vmware.vapi.dynamic_struct', {}, VapiStruct)), }, InvalidGrant)) class TokenExchange(VapiInterface): """ The ``TokenExchange`` interface provides possibility to exchange between different tokens types. Implementation of "OAuth 2.0 Token Exchange" standard (https://tools.ietf.org/html/draft-ietf-oauth-token-exchange-12). """ TOKEN_EXCHANGE_GRANT = "urn:ietf:params:oauth:grant-type:token-exchange" """ Class attribute indicates that token exchange grant type. """ ACCESS_TOKEN_TYPE = "urn:ietf:params:oauth:token-type:access_token" """ Class attribute indicates OAuth 2.0 access token type. """ REFRESH_TOKEN_TYPE = "urn:ietf:params:oauth:token-type:refresh_token" """ Class attribute indicates OAuth 2.0 refresh token type. """ ID_TOKEN_TYPE = "urn:ietf:params:oauth:token-type:id_token" """ Class attribute indicates OIDC ID token type. """ SAML1_TOKEN_TYPE = "urn:ietf:params:oauth:token-type:saml1" """ Class attribute indicates base64-encoded SAML 1.1 token type. """ SAML2_TOKEN_TYPE = "urn:ietf:params:oauth:token-type:saml2" """ Class attribute indicates base64-encoded SAML 2.0 token type. """ BEARER_TOKEN_METHOD_TYPE = "Bearer" """ Class attribute indicates that the security token is a bearer token. """ N_A_TOKEN_METHOD_TYPE = "N_A" """ Class attribute indicates :attr:`TokenExchange.Info.token_type` identifier is not applicable in that context. """ _VAPI_SERVICE_ID = 'com.vmware.vcenter.tokenservice.token_exchange' """ Identifier of the service in canonical form. """ def __init__(self, config): """ :type config: :class:`vmware.vapi.bindings.stub.StubConfiguration` :param config: Configuration to be used for creating the stub. """ VapiInterface.__init__(self, config, _TokenExchangeStub) self._VAPI_OPERATION_IDS = {} class ExchangeSpec(VapiStruct): """ The ``TokenExchange.ExchangeSpec`` class contains arguments required for token exchange. .. tip:: The arguments are used to initialize data attributes with the same names. """ def __init__(self, grant_type=None, resource=None, audience=None, scope=None, requested_token_type=None, subject_token=None, subject_token_type=None, actor_token=None, actor_token_type=None, ): """ :type grant_type: :class:`str` :param grant_type: The value of :attr:`TokenExchange.TOKEN_EXCHANGE_GRANT` indicates that a token exchange is being performed. :type resource: :class:`str` or ``None`` :param resource: Indicates the location of the target service or resource where the client intends to use the requested security token. if can be inferred from other arguments or not needed for specific case of exchange. :type audience: :class:`str` or ``None`` :param audience: The logical name of the target service where the client intends to use the requested security token. This serves a purpose similar to the :attr:`TokenExchange.ExchangeSpec.resource` parameter, but with the client providing a logical name rather than a location. if can be inferred from other arguments or not needed for specific case of exchange. :type scope: :class:`str` or ``None`` :param scope: A list of space-delimited, case-sensitive strings, that allow the client to specify the desired scope of the requested security token in the context of the service or resource where the token will be used. if can be inferred from other arguments or not needed for specific case of exchange. :type requested_token_type: :class:`str` or ``None`` :param requested_token_type: An identifier for the type of the requested security token. If the requested type is unspecified, the issued token type is at the discretion of the server and may be dictated by knowledge of the requirements of the service or resource indicated by the :attr:`TokenExchange.ExchangeSpec.resource` or :attr:`TokenExchange.ExchangeSpec.audience` parameter. if can be inferred from other arguments or not needed for specific case of exchange. :type subject_token: :class:`str` :param subject_token: A security token that represents the identity of the party on behalf of whom exchange is being made. Typically, the subject of this token will be the subject of the security token issued. Token is base64-encoded. :type subject_token_type: :class:`str` :param subject_token_type: An identifier, that indicates the type of the security token in the :attr:`TokenExchange.ExchangeSpec.subject_token` parameter. :type actor_token: :class:`str` or ``None`` :param actor_token: A security token that represents the identity of the acting party. Typically, this will be the party that is authorized to use the requested security token and act on behalf of the subject. if not needed for specific case of exchange. :type actor_token_type: :class:`str` or ``None`` :param actor_token_type: An identifier, that indicates the type of the security token in the :attr:`TokenExchange.ExchangeSpec.actor_token` parameter. if :attr:`TokenExchange.ExchangeSpec.actor_token` parameter is not present. """ self.grant_type = grant_type self.resource = resource self.audience = audience self.scope = scope self.requested_token_type = requested_token_type self.subject_token = subject_token self.subject_token_type = subject_token_type self.actor_token = actor_token self.actor_token_type = actor_token_type VapiStruct.__init__(self) ExchangeSpec._set_binding_type(type.StructType( 'com.vmware.vcenter.tokenservice.token_exchange.exchange_spec', { 'grant_type': type.StringType(), 'resource': type.OptionalType(type.StringType()), 'audience': type.OptionalType(type.StringType()), 'scope': type.OptionalType(type.StringType()), 'requested_token_type': type.OptionalType(type.StringType()), 'subject_token': type.StringType(), 'subject_token_type': type.StringType(), 'actor_token': type.OptionalType(type.StringType()), 'actor_token_type': type.OptionalType(type.StringType()), }, ExchangeSpec, False, None)) class Info(VapiStruct): """ The ``TokenExchange.Info`` class contains data that represents successful token exchange response. .. tip:: The arguments are used to initialize data attributes with the same names. """ def __init__(self, access_token=None, issued_token_type=None, token_type=None, expires_in=None, scope=None, refresh_token=None, ): """ :type access_token: :class:`str` :param access_token: The security token issued by the server in response to the token exchange request. Token is base64-encoded. :type issued_token_type: :class:`str` :param issued_token_type: An identifier, that indicates the type of the security token in the :attr:`TokenExchange.Info.access_token` parameter. :type token_type: :class:`str` :param token_type: A case-insensitive value specifying the method of using the access token issued. :type expires_in: :class:`long` or ``None`` :param expires_in: The validity lifetime, in seconds, of the token issued by the server. if not applicable for issued token. :type scope: :class:`str` or ``None`` :param scope: Scope of the issued security token. if the scope of the issued security token is identical to the scope requested by the client. :type refresh_token: :class:`str` or ``None`` :param refresh_token: A refresh token can be issued in cases where the client of the token exchange needs the ability to access a resource even when the original credential is no longer valid. if not needed for specific case of exchange. """ self.access_token = access_token self.issued_token_type = issued_token_type self.token_type = token_type self.expires_in = expires_in self.scope = scope self.refresh_token = refresh_token VapiStruct.__init__(self) Info._set_binding_type(type.StructType( 'com.vmware.vcenter.tokenservice.token_exchange.info', { 'access_token': type.StringType(), 'issued_token_type': type.StringType(), 'token_type': type.StringType(), 'expires_in': type.OptionalType(type.IntegerType()), 'scope': type.OptionalType(type.StringType()), 'refresh_token': type.OptionalType(type.StringType()), }, Info, False, None)) def exchange(self, spec, ): """ Exchanges incoming token based on the spec and current client authorization data. :type spec: :class:`TokenExchange.ExchangeSpec` :param spec: ``TokenExchange.ExchangeSpec`` class contains arguments that define exchange process. :rtype: :class:`TokenExchange.Info` :return: :class:`TokenExchange.Info` class that contains new token. :raise: :class:`InvalidGrant` provided authorization grant (e.g., authorization code, resource owner credentials) or refresh token is invalid, expired, revoked, does not match the redirection URI used in the authorization request, or was issued to another client. :raise: :class:`InvalidScope` If the server is unwilling or unable to issue a token for all the target services indicated by the :attr:`TokenExchange.ExchangeSpec.resource` or :attr:`TokenExchange.ExchangeSpec.audience` parameters. :raise: :class:`com.vmware.vapi.std.errors_client.Unauthorized` if authorization is not given to a caller. """ return self._invoke('exchange', { 'spec': spec, }) class _TokenExchangeStub(ApiInterfaceStub): def __init__(self, config): # properties for exchange operation exchange_input_type = type.StructType('operation-input', { 'spec': type.ReferenceType(__name__, 'TokenExchange.ExchangeSpec'), }) exchange_error_dict = { 'com.vmware.vapi.std.errors.invalid_request': type.ReferenceType('com.vmware.vapi.std.errors_client', 'InvalidRequest'), 'com.vmware.vcenter.tokenservice.invalid_request': type.ReferenceType(__name__, 'InvalidRequest'), 'com.vmware.vcenter.tokenservice.invalid_grant': type.ReferenceType(__name__, 'InvalidGrant'), 'com.vmware.vcenter.tokenservice.invalid_scope': type.ReferenceType(__name__, 'InvalidScope'), 'com.vmware.vapi.std.errors.unauthorized': type.ReferenceType('com.vmware.vapi.std.errors_client', 'Unauthorized'), } exchange_input_value_validator_list = [ ] exchange_output_validator_list = [ ] exchange_rest_metadata = OperationRestMetadata( http_method='POST', url_template='/vcenter/tokenservice/token-exchange', path_variables={ }, query_parameters={ } ) operations = { 'exchange': { 'input_type': exchange_input_type, 'output_type': type.ReferenceType(__name__, 'TokenExchange.Info'), 'errors': exchange_error_dict, 'input_value_validator_list': exchange_input_value_validator_list, 'output_validator_list': exchange_output_validator_list, 'task_type': TaskType.NONE, }, } rest_metadata = { 'exchange': exchange_rest_metadata, } ApiInterfaceStub.__init__( self, iface_name='com.vmware.vcenter.tokenservice.token_exchange', config=config, operations=operations, rest_metadata=rest_metadata, is_vapi_rest=True) class StubFactory(StubFactoryBase): _attrs = { 'TokenExchange': TokenExchange, }
SharePointPro/spfx-40-fantastics-Sppro
lib/webparts/mediaPlayer/MediaPlayer.module.scss.js
<filename>lib/webparts/mediaPlayer/MediaPlayer.module.scss.js<gh_stars>1-10 "use strict"; Object.defineProperty(exports, "__esModule", { value: true }); /* tslint:disable */ require('./MediaPlayer.module.css'); var styles = { carousel3D: 'carousel3D_b11555b1', container: 'container_b11555b1', row: 'row_b11555b1', listItem: 'listItem_b11555b1', button: 'button_b11555b1', }; exports.default = styles; /* tslint:enable */ //# sourceMappingURL=MediaPlayer.module.scss.js.map
mortenpoulsen/kanbanik
kanbanik-web/src/main/java/com/googlecode/kanbanik/client/modules/editworkflow/projects/ProjectDeletingComponent.java
package com.googlecode.kanbanik.client.modules.editworkflow.projects; import com.google.gwt.event.dom.client.HasClickHandlers; import com.googlecode.kanbanik.client.Modules; import com.googlecode.kanbanik.client.api.Dtos; import com.googlecode.kanbanik.client.api.Dtos.ProjectDto; import com.googlecode.kanbanik.client.api.ResourceClosingCallback; import com.googlecode.kanbanik.client.api.ServerCaller; import com.googlecode.kanbanik.client.messaging.Message; import com.googlecode.kanbanik.client.messaging.MessageBus; import com.googlecode.kanbanik.client.messaging.MessageListener; import com.googlecode.kanbanik.client.messaging.messages.project.ProjectChangedMessage; import com.googlecode.kanbanik.client.messaging.messages.project.ProjectDeletedMessage; import com.googlecode.kanbanik.client.messaging.messages.project.ProjectEditedMessage; import com.googlecode.kanbanik.client.modules.editworkflow.boards.AbstractDeletingComponent; import com.googlecode.kanbanik.client.modules.lifecyclelisteners.ModulesLifecycleListener; import com.googlecode.kanbanik.client.modules.lifecyclelisteners.ModulesLyfecycleListenerHandler; import com.googlecode.kanbanik.client.security.CurrentUser; import com.googlecode.kanbanik.dto.CommandNames; public class ProjectDeletingComponent extends AbstractDeletingComponent implements ModulesLifecycleListener, MessageListener<ProjectDto> { private ProjectDto projectDto; public ProjectDeletingComponent(ProjectDto projectDto, HasClickHandlers hasClickHandler) { super(hasClickHandler); this.projectDto = projectDto; MessageBus.registerListener(ProjectEditedMessage.class, this); MessageBus.registerListener(ProjectChangedMessage.class, this); new ModulesLyfecycleListenerHandler(Modules.CONFIGURE, this); } @Override protected String getMessageSpecificPart() { return "Project with name: '" + projectDto.getName() + "'"; } @Override protected void onOkClicked() { projectDto.setCommandName(CommandNames.DELETE_PROJECT.name); projectDto.setSessionId(CurrentUser.getInstance().getSessionId()); ServerCaller.<Dtos.ProjectDto, Dtos.EmptyDto>sendRequest( projectDto, Dtos.EmptyDto.class, new ResourceClosingCallback<Dtos.EmptyDto>(ProjectDeletingComponent.this) { @Override public void success(Dtos.EmptyDto response) { MessageBus.sendMessage(new ProjectDeletedMessage(projectDto, this)); } } ); } public void activated() { if (!MessageBus.listens(ProjectEditedMessage.class, this)) { MessageBus.registerListener(ProjectEditedMessage.class, this); } if (!MessageBus.listens(ProjectChangedMessage.class, this)) { MessageBus.registerListener(ProjectChangedMessage.class, this); } } public void deactivated() { MessageBus.unregisterListener(ProjectEditedMessage.class, this); MessageBus.unregisterListener(ProjectChangedMessage.class, this); } public void messageArrived(Message<ProjectDto> message) { if (message.getPayload() == null) { return; } if (message.getPayload().getId().equals(projectDto.getId())) { projectDto = message.getPayload(); } } }
kirkovg/university-microservices
public-transport-service/src/main/java/mk/ukim/finki/publictransport/repository/LineRepository.java
<reponame>kirkovg/university-microservices package mk.ukim.finki.publictransport.repository; import mk.ukim.finki.publictransport.domain.Line; import org.springframework.data.jpa.repository.*; import org.springframework.stereotype.Repository; /** * Spring Data repository for the Line entity. */ @SuppressWarnings("unused") @Repository public interface LineRepository extends JpaRepository<Line, Long>, JpaSpecificationExecutor<Line> { }
linminglu/lanxi-mahjong-server
src/algorithm/hu_qingluanfeng.go
<reponame>linminglu/lanxi-mahjong-server package algorithm // 乱风胡检测 // 所有牌都为风牌(东南西北中发白),无需成胡牌型 // 碰杠牌要加入检测 func existLuanFeng(cards []byte) int64 { for _, v := range cards { if v != WILDCARD { if v>>4 < FENG { return 0 } } } return HU_LUAN_FENG } // 清一色检测 func existOneSuit(cards []byte) int64 { var c byte le := len(cards) hasWildcard:=false for i := 0; i < le; i++ { card := cards[i] if card != WILDCARD { if c > 0 && c>>4 != card>>4 { return 0 } c = card }else{ hasWildcard = true } } if hasWildcard{ return HU_ONE_SUIT_CAI } return HU_ONE_SUIT }
5GExchange/tads-network-protocols
src/main/java/es/tid/pce/pcep/constructs/P2MPEndpoints.java
<filename>src/main/java/es/tid/pce/pcep/constructs/P2MPEndpoints.java<gh_stars>0 package es.tid.pce.pcep.constructs; import java.util.LinkedList; import es.tid.pce.pcep.PCEPProtocolViolationException; import es.tid.pce.pcep.objects.MalformedPCEPObjectException; public class P2MPEndpoints extends PCEPConstruct { private EndPointAndRestrictions EndpointAndRestrictions; private LinkedList <EndPointAndRestrictions> EndpointAndRestrictionsList; public P2MPEndpoints(){ EndpointAndRestrictionsList=new LinkedList<EndPointAndRestrictions> (); } public P2MPEndpoints(byte[] object_bytes, int offset) throws PCEPProtocolViolationException, MalformedPCEPObjectException { EndpointAndRestrictionsList=new LinkedList<EndPointAndRestrictions> (); this.bytes = object_bytes; decode(bytes,offset); } @Override public void encode() throws PCEPProtocolViolationException { //Encoding P2MPEndpoints Construct int len=0; if (EndpointAndRestrictionsList.size()>0){ for (int i=0;i<EndpointAndRestrictionsList.size();++i){ (EndpointAndRestrictionsList.get(i)).encode(); len=len+(EndpointAndRestrictionsList.get(i)).getLength(); } } if (EndpointAndRestrictions != null) { EndpointAndRestrictions.encode(); len=len+EndpointAndRestrictions.getLength(); } this.setLength(len); bytes=new byte[len]; int offset=0; System.arraycopy(EndpointAndRestrictions.getBytes(), 0, bytes, offset, EndpointAndRestrictions.getLength()); offset=offset+EndpointAndRestrictions.getLength(); if (EndpointAndRestrictionsList!=null) { for (int i=0;i<EndpointAndRestrictionsList.size();++i) { System.arraycopy(EndpointAndRestrictionsList.get(i).getBytes(), 0, bytes, offset, EndpointAndRestrictionsList.get(i).getLength()); offset=offset+EndpointAndRestrictionsList.get(i).getLength(); } } } private void decode(byte[] bytes, int offset) throws PCEPProtocolViolationException, MalformedPCEPObjectException { int max_offset = bytes.length; if (offset>=max_offset){ log.warn("Empty P2MPEndpoints construct!!!"); throw new PCEPProtocolViolationException(); } EndpointAndRestrictions = new EndPointAndRestrictions(bytes, offset); offset = offset + EndpointAndRestrictions.getLength(); while (offset < max_offset) { EndPointAndRestrictions EndpointAndRestrictions = new EndPointAndRestrictions(bytes, offset); EndpointAndRestrictionsList.add(EndpointAndRestrictions); offset = offset + EndpointAndRestrictions.getLength(); } } public EndPointAndRestrictions getEndPointAndRestrictions() { return EndpointAndRestrictions; } public void setEndPointAndRestrictions(EndPointAndRestrictions EndPointAndRestrictions) { this.EndpointAndRestrictions = EndPointAndRestrictions; } public LinkedList <EndPointAndRestrictions> getEndPointAndRestrictionsList() { return EndpointAndRestrictionsList; } public void setEndPointAndRestrictionsList(LinkedList <EndPointAndRestrictions> EndPointAndRestrictionsList) { this.EndpointAndRestrictionsList = EndPointAndRestrictionsList; } @Override public int hashCode() { final int prime = 31; int result = super.hashCode(); result = prime * result + ((EndpointAndRestrictions == null) ? 0 : EndpointAndRestrictions.hashCode()); result = prime * result + ((EndpointAndRestrictionsList == null) ? 0 : EndpointAndRestrictionsList.hashCode()); return result; } @Override public boolean equals(Object obj) { if (this == obj) return true; if (!super.equals(obj)) return false; if (getClass() != obj.getClass()) return false; P2MPEndpoints other = (P2MPEndpoints) obj; if (EndpointAndRestrictions == null) { if (other.EndpointAndRestrictions != null) return false; } else if (!EndpointAndRestrictions .equals(other.EndpointAndRestrictions)) return false; if (EndpointAndRestrictionsList == null) { if (other.EndpointAndRestrictionsList != null) return false; } else if (!EndpointAndRestrictionsList .equals(other.EndpointAndRestrictionsList)) return false; return true; } }
ardeshir/gohazel
code-samples/enterprise/hidensity-cache/src/main/java/HiDensityCacheIteratorUsage.java
import com.hazelcast.cache.ICache; import javax.cache.Cache; import java.util.Iterator; /** * HiDensity cache {@link Iterator} usage example. * * You have to set your Hazelcast Enterprise license key to make this code sample work. * Please have a look at {@link com.hazelcast.examples.helper.LicenseUtils} for details. */ public class HiDensityCacheIteratorUsage extends HiDensityCacheUsageSupport { private static final int SIZE = 1000; public static void main(String[] args) { init(); try { ICache<Integer, Integer> cache = createCache("MyCacheForIteratorUsage"); for (int i = 0; i < SIZE; i++) { cache.put(i, i * i); } Iterator<Cache.Entry<Integer, Integer>> iter = cache.iterator(); while (iter.hasNext()) { Cache.Entry<Integer, Integer> e = iter.next(); int key = e.getKey(); int value = e.getValue(); System.out.println("Key: " + key + ", Value: " + value); } cache.destroy(); } catch (Throwable t) { t.printStackTrace(); } finally { destroy(); } } }
mihaicarabas/dragonfly
lib/libncp/ncpl_subr.c
/* * Copyright (c) 1999, <NAME> * All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: * 1. Redistributions of source code must retain the above copyright * notice, this list of conditions and the following disclaimer. * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in the * documentation and/or other materials provided with the distribution. * 3. All advertising materials mentioning features or use of this software * must display the following acknowledgement: * This product includes software developed by <NAME>. * 4. Neither the name of the author nor the names of any co-contributors * may be used to endorse or promote products derived from this software * without specific prior written permission. * * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * * $FreeBSD: src/lib/libncp/ncpl_subr.c,v 1.3 2000/01/01 14:21:31 bp Exp $ */ #include <sys/param.h> #include <sys/types.h> #include <sys/errno.h> #include <sys/sysctl.h> #include <sys/syscall.h> #include <unistd.h> #include <ctype.h> #include <string.h> #include <stdio.h> #include <stdlib.h> #include <stdarg.h> #include <netncp/ncp_lib.h> #include <netncp/ncp_rcfile.h> #include <netncp/ncp_nls.h> /*#include <netncp/ncp_cfg.h>*/ #include "ncp_mod.h" extern char *__progname; int sysentoffset; void ncp_add_word_lh(struct ncp_buf *conn, u_int16_t x) { setwle(conn->packet, conn->rqsize, x); conn->rqsize += 2; return; } void ncp_add_dword_lh(struct ncp_buf *conn, u_int32_t x) { setdle(conn->packet, conn->rqsize, x); conn->rqsize += 4; return; } void ncp_add_word_hl(struct ncp_buf *conn, u_int16_t x){ setwbe(conn->packet, conn->rqsize, x); conn->rqsize += 2; return; } void ncp_add_dword_hl(struct ncp_buf *conn, u_int32_t x) { setdbe(conn->packet, conn->rqsize, x); conn->rqsize += 4; return; } void ncp_add_mem(struct ncp_buf *conn, const void *source, int size) { memcpy(conn->packet+conn->rqsize, source, size); conn->rqsize += size; return; } void ncp_add_mem_nls(struct ncp_buf *conn, const void *source, int size) { ncp_nls_mem_u2n(conn->packet+conn->rqsize, source, size); conn->rqsize += size; return; } void ncp_add_pstring(struct ncp_buf *conn, const char *s) { int len = strlen(s); if (len > 255) { ncp_printf("ncp_add_pstring: string too long: %s\n", s); len = 255; } ncp_add_byte(conn, len); ncp_add_mem(conn, s, len); return; } void ncp_add_handle_path(struct ncp_buf *conn, nuint32 volNumber, nuint32 dirNumber, int handleFlag, const char *path) { ncp_add_byte(conn, volNumber); ncp_add_dword_lh(conn, dirNumber); ncp_add_byte(conn, handleFlag); if (path) { ncp_add_byte(conn, 1); /* 1 component */ ncp_add_pstring(conn, path); } else { ncp_add_byte(conn, 0); } } void ncp_init_request(struct ncp_buf *conn) { conn->rqsize = 0; conn->rpsize = 0; } void ncp_init_request_s(struct ncp_buf *conn, int subfn) { ncp_init_request(conn); ncp_add_word_lh(conn, 0); ncp_add_byte(conn, subfn); } u_int16_t ncp_reply_word_hl(struct ncp_buf *conn, int offset) { return getwbe(ncp_reply_data(conn, offset), 0); } u_int16_t ncp_reply_word_lh(struct ncp_buf *conn, int offset) { return getwle(ncp_reply_data(conn, offset), 0); } u_int32_t ncp_reply_dword_hl(struct ncp_buf *conn, int offset) { return getdbe(ncp_reply_data(conn, offset), 0); } u_int32_t ncp_reply_dword_lh(struct ncp_buf *conn, int offset) { return getdle(ncp_reply_data(conn, offset), 0); } int ncp_connect(struct ncp_conn_args *li, int *connHandle) { return syscall(NCP_CONNECT,li,connHandle); } int ncp_disconnect(int cH) { DECLARE_RQ; ncp_init_request(conn); ncp_add_byte(conn, NCP_CONN_CONNCLOSE); return ncp_conn_request(cH, conn); } int ncp_request(int connHandle,int function, struct ncp_buf *ncpbuf){ int err = syscall(SNCP_REQUEST,connHandle,function,ncpbuf); return (err<0) ? errno : 0; } int ncp_conn_request(int connHandle, struct ncp_buf *ncpbuf){ return syscall(SNCP_REQUEST, connHandle, NCP_CONN, ncpbuf); } int ncp_conn_scan(struct ncp_conn_loginfo *li, int *connid) { return syscall(NCP_CONNSCAN,li, connid); } NWCCODE NWRequest(NWCONN_HANDLE cH, nuint16 fn, nuint16 nrq, NW_FRAGMENT* rq, nuint16 nrp, NW_FRAGMENT* rp) { int error; struct ncp_conn_frag nf; DECLARE_RQ; ncp_init_request(conn); ncp_add_byte(conn, NCP_CONN_FRAG); nf.fn = fn; nf.rqfcnt = nrq; nf.rqf = rq; nf.rpf = rp; nf.rpfcnt = nrp; ncp_add_mem(conn, &nf, sizeof(nf)); error = ncp_conn_request(cH, conn); return error; } int ncp_initlib(void){ int error; size_t len = sizeof(sysentoffset); int kv; size_t kvlen = sizeof(kv); static int ncp_initialized; if (ncp_initialized) return 0; error = sysctlbyname("net.ncp.sysent", &sysentoffset, &len, NULL, 0); if (error) { fprintf(stderr, "%s: can't find kernel module\n", __func__); return error; } error = sysctlbyname("net.ncp.version", &kv, &kvlen, NULL, 0); if (error) { fprintf(stderr, "%s: kernel module is old, please recompile it.\n", __func__); return error; } if (NCP_VERSION != kv) { fprintf(stderr, "%s: kernel module version(%d) don't match library(%d).\n", __func__, kv, NCP_VERSION); return EINVAL; } if ((error = ncp_nls_setrecode(0)) != 0) { fprintf(stderr, "%s: can't initialise recode\n", __func__); return error; } if ((error = ncp_nls_setlocale("")) != 0) { fprintf(stderr, "%s: can't initialise locale\n", __func__); return error; } ncp_initialized++; return 0; } /* */ int ncp_opterr = 1, /* if error message should be printed */ ncp_optind = 1, /* index into parent argv vector */ ncp_optopt, /* character checked for validity */ ncp_optreset; /* reset getopt */ char *ncp_optarg; /* argument associated with option */ #define BADCH (int)'?' #define BADARG (int)':' #define EMSG "" int ncp_getopt(int nargc, char * const *nargv, const char *ostr) { static char *place = EMSG; /* option letter processing */ char *oli; /* option letter list index */ int tmpind; if (ncp_optreset || !*place) { /* update scanning pointer */ ncp_optreset = 0; tmpind = ncp_optind; while (1) { if (tmpind >= nargc) { place = EMSG; return (-1); } if (*(place = nargv[tmpind]) != '-') { tmpind++; continue; /* lookup next option */ } if (place[1] && *++place == '-') { /* found "--" */ ncp_optind = ++tmpind; place = EMSG; return (-1); } ncp_optind = tmpind; break; } } /* option letter okay? */ if ((ncp_optopt = (int)*place++) == (int)':' || !(oli = strchr(ostr, ncp_optopt))) { /* * if the user didn't specify '-' as an option, * assume it means -1. */ if (ncp_optopt == (int)'-') return (-1); if (!*place) ++ncp_optind; if (ncp_opterr && *ostr != ':') (void)fprintf(stderr, "%s: illegal option -- %c\n", __progname, ncp_optopt); return (BADCH); } if (*++oli != ':') { /* don't need argument */ ncp_optarg = NULL; if (!*place) ++ncp_optind; } else { /* need an argument */ if (*place) /* no white space */ ncp_optarg = place; else if (nargc <= ++ncp_optind) { /* no arg */ place = EMSG; if (*ostr == ':') return (BADARG); if (ncp_opterr) (void)fprintf(stderr, "%s: option requires an argument -- %c\n", __progname, ncp_optopt); return (BADCH); } else /* white space */ ncp_optarg = nargv[ncp_optind]; place = EMSG; ++ncp_optind; } return (ncp_optopt); /* dump back option letter */ } /* * misc options parsing routines */ int ncp_args_parserc(struct ncp_args *na, char *sect, ncp_setopt_t *set_callback) { int len, error; for (; na->opt; na++) { switch (na->at) { case NCA_STR: if (rc_getstringptr(ncp_rc,sect,na->name,&na->str) == 0) { len = strlen(na->str); if (len > na->ival) { fprintf(stderr,"rc: Argument for option '%c' (%s) too long\n",na->opt,na->name); return EINVAL; } set_callback(na); } break; case NCA_BOOL: error = rc_getbool(ncp_rc,sect,na->name,&na->ival); if (error == ENOENT) break; if (error) return EINVAL; set_callback(na); break; case NCA_INT: if (rc_getint(ncp_rc,sect,na->name,&na->ival) == 0) { if (((na->flag & NAFL_HAVEMIN) && (na->ival < na->min)) || ((na->flag & NAFL_HAVEMAX) && (na->ival > na->max))) { fprintf(stderr,"rc: Argument for option '%c' (%s) should be in [%d-%d] range\n",na->opt,na->name,na->min,na->max); return EINVAL; } set_callback(na); } break; default: break; } } return 0; } int ncp_args_parseopt(struct ncp_args *na, int opt, char *optarg, ncp_setopt_t *set_callback) { int len; for (; na->opt; na++) { if (na->opt != opt) continue; switch (na->at) { case NCA_STR: na->str = optarg; if (optarg) { len = strlen(na->str); if (len > na->ival) { fprintf(stderr,"opt: Argument for option '%c' (%s) too long\n",na->opt,na->name); return EINVAL; } set_callback(na); } break; case NCA_BOOL: na->ival = 0; set_callback(na); break; case NCA_INT: errno = 0; na->ival = strtol(optarg, NULL, 0); if (errno) { fprintf(stderr,"opt: Invalid integer value for option '%c' (%s).\n",na->opt,na->name); return EINVAL; } if (((na->flag & NAFL_HAVEMIN) && (na->ival < na->min)) || ((na->flag & NAFL_HAVEMAX) && (na->ival > na->max))) { fprintf(stderr,"opt: Argument for option '%c' (%s) should be in [%d-%d] range\n",na->opt,na->name,na->min,na->max); return EINVAL; } set_callback(na); break; default: break; } break; } return 0; } /* * Print a (descriptive) error message * error values: * 0 - no specific error code available; * -999..-1 - NDS error * 1..32767 - system error * the rest - requester error; */ void ncp_error(const char *fmt, int error,...) { va_list ap; fprintf(stderr, "%s: ", __progname); va_start(ap, error); vfprintf(stderr, fmt, ap); va_end(ap); if (error == -1) error = errno; if (error > -1000 && error < 0) { fprintf(stderr, ": dserr = %d\n", error); } else if (error & 0x8000) { fprintf(stderr, ": nwerr = %04x\n", error); } else if (error) { fprintf(stderr, ": syserr = %s\n", strerror(error)); } else fprintf(stderr, "\n"); } char * ncp_printb(char *dest, int flags, const struct ncp_bitname *bnp) { int first = 1; strcpy(dest, "<"); for(; bnp->bn_bit; bnp++) { if (flags & bnp->bn_bit) { strcat(dest, bnp->bn_name); first = 0; } if (!first && (flags & bnp[1].bn_bit)) strcat(dest, "|"); } strcat(dest, ">"); return dest; }
emrecosar/leetcode
191-NumberOf1Bits/NumberOf1Bits.java
public class NumberOf1Bits { // you need to treat n as an unsigned value public int hammingWeight(int n) { int ones = 0; while (n != 0) { ones = ones + (n & 1); n = n >>> 1; } return ones; } }
lintonv/aws-sdk-cpp
aws-cpp-sdk-workdocs/source/model/FolderMetadata.cpp
/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #include <aws/workdocs/model/FolderMetadata.h> #include <aws/core/utils/json/JsonSerializer.h> #include <utility> using namespace Aws::Utils::Json; using namespace Aws::Utils; namespace Aws { namespace WorkDocs { namespace Model { FolderMetadata::FolderMetadata() : m_idHasBeenSet(false), m_nameHasBeenSet(false), m_creatorIdHasBeenSet(false), m_parentFolderIdHasBeenSet(false), m_createdTimestampHasBeenSet(false), m_modifiedTimestampHasBeenSet(false), m_resourceState(ResourceStateType::NOT_SET), m_resourceStateHasBeenSet(false), m_signatureHasBeenSet(false), m_labelsHasBeenSet(false), m_size(0), m_sizeHasBeenSet(false), m_latestVersionSize(0), m_latestVersionSizeHasBeenSet(false) { } FolderMetadata::FolderMetadata(JsonView jsonValue) : m_idHasBeenSet(false), m_nameHasBeenSet(false), m_creatorIdHasBeenSet(false), m_parentFolderIdHasBeenSet(false), m_createdTimestampHasBeenSet(false), m_modifiedTimestampHasBeenSet(false), m_resourceState(ResourceStateType::NOT_SET), m_resourceStateHasBeenSet(false), m_signatureHasBeenSet(false), m_labelsHasBeenSet(false), m_size(0), m_sizeHasBeenSet(false), m_latestVersionSize(0), m_latestVersionSizeHasBeenSet(false) { *this = jsonValue; } FolderMetadata& FolderMetadata::operator =(JsonView jsonValue) { if(jsonValue.ValueExists("Id")) { m_id = jsonValue.GetString("Id"); m_idHasBeenSet = true; } if(jsonValue.ValueExists("Name")) { m_name = jsonValue.GetString("Name"); m_nameHasBeenSet = true; } if(jsonValue.ValueExists("CreatorId")) { m_creatorId = jsonValue.GetString("CreatorId"); m_creatorIdHasBeenSet = true; } if(jsonValue.ValueExists("ParentFolderId")) { m_parentFolderId = jsonValue.GetString("ParentFolderId"); m_parentFolderIdHasBeenSet = true; } if(jsonValue.ValueExists("CreatedTimestamp")) { m_createdTimestamp = jsonValue.GetDouble("CreatedTimestamp"); m_createdTimestampHasBeenSet = true; } if(jsonValue.ValueExists("ModifiedTimestamp")) { m_modifiedTimestamp = jsonValue.GetDouble("ModifiedTimestamp"); m_modifiedTimestampHasBeenSet = true; } if(jsonValue.ValueExists("ResourceState")) { m_resourceState = ResourceStateTypeMapper::GetResourceStateTypeForName(jsonValue.GetString("ResourceState")); m_resourceStateHasBeenSet = true; } if(jsonValue.ValueExists("Signature")) { m_signature = jsonValue.GetString("Signature"); m_signatureHasBeenSet = true; } if(jsonValue.ValueExists("Labels")) { Array<JsonView> labelsJsonList = jsonValue.GetArray("Labels"); for(unsigned labelsIndex = 0; labelsIndex < labelsJsonList.GetLength(); ++labelsIndex) { m_labels.push_back(labelsJsonList[labelsIndex].AsString()); } m_labelsHasBeenSet = true; } if(jsonValue.ValueExists("Size")) { m_size = jsonValue.GetInt64("Size"); m_sizeHasBeenSet = true; } if(jsonValue.ValueExists("LatestVersionSize")) { m_latestVersionSize = jsonValue.GetInt64("LatestVersionSize"); m_latestVersionSizeHasBeenSet = true; } return *this; } JsonValue FolderMetadata::Jsonize() const { JsonValue payload; if(m_idHasBeenSet) { payload.WithString("Id", m_id); } if(m_nameHasBeenSet) { payload.WithString("Name", m_name); } if(m_creatorIdHasBeenSet) { payload.WithString("CreatorId", m_creatorId); } if(m_parentFolderIdHasBeenSet) { payload.WithString("ParentFolderId", m_parentFolderId); } if(m_createdTimestampHasBeenSet) { payload.WithDouble("CreatedTimestamp", m_createdTimestamp.SecondsWithMSPrecision()); } if(m_modifiedTimestampHasBeenSet) { payload.WithDouble("ModifiedTimestamp", m_modifiedTimestamp.SecondsWithMSPrecision()); } if(m_resourceStateHasBeenSet) { payload.WithString("ResourceState", ResourceStateTypeMapper::GetNameForResourceStateType(m_resourceState)); } if(m_signatureHasBeenSet) { payload.WithString("Signature", m_signature); } if(m_labelsHasBeenSet) { Array<JsonValue> labelsJsonList(m_labels.size()); for(unsigned labelsIndex = 0; labelsIndex < labelsJsonList.GetLength(); ++labelsIndex) { labelsJsonList[labelsIndex].AsString(m_labels[labelsIndex]); } payload.WithArray("Labels", std::move(labelsJsonList)); } if(m_sizeHasBeenSet) { payload.WithInt64("Size", m_size); } if(m_latestVersionSizeHasBeenSet) { payload.WithInt64("LatestVersionSize", m_latestVersionSize); } return payload; } } // namespace Model } // namespace WorkDocs } // namespace Aws
bherrmann7/jbum
fixed-src/com/thoughtworks/xstream/io/xml/DomDriver.java
<filename>fixed-src/com/thoughtworks/xstream/io/xml/DomDriver.java package com.thoughtworks.xstream.io.xml; import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.io.OutputStreamWriter; import java.io.Reader; import java.io.UnsupportedEncodingException; import java.io.Writer; import javax.xml.parsers.DocumentBuilder; import javax.xml.parsers.DocumentBuilderFactory; import javax.xml.parsers.FactoryConfigurationError; import javax.xml.parsers.ParserConfigurationException; import org.w3c.dom.Document; import org.xml.sax.InputSource; import org.xml.sax.SAXException; import com.thoughtworks.xstream.io.HierarchicalStreamReader; import com.thoughtworks.xstream.io.HierarchicalStreamWriter; import com.thoughtworks.xstream.io.StreamException; public class DomDriver extends AbstractXmlDriver { private final String encoding; private final DocumentBuilderFactory documentBuilderFactory; public DomDriver() { this("UTF-8"); } public DomDriver(String encoding) { this(encoding, new XmlFriendlyReplacer()); } /** * @since 1.2 */ public DomDriver(String encoding, XmlFriendlyReplacer replacer) { super(replacer); documentBuilderFactory = DocumentBuilderFactory.newInstance(); this.encoding = encoding; } public HierarchicalStreamReader createReader(Reader xml) { return createReader(new InputSource(xml)); } public HierarchicalStreamReader createReader(InputStream xml) { return createReader(new InputSource(xml)); } private HierarchicalStreamReader createReader(InputSource source) { try { DocumentBuilder documentBuilder = documentBuilderFactory.newDocumentBuilder(); source.setEncoding(encoding); Document document = documentBuilder.parse(source); return new DomReader(document); } catch (FactoryConfigurationError e) { throw new StreamException(e); } catch (ParserConfigurationException e) { throw new StreamException(e); } catch (SAXException e) { throw new StreamException(e); } catch (IOException e) { throw new StreamException(e); } } public HierarchicalStreamWriter createWriter(Writer out) { return new PrettyPrintWriter(out); } public HierarchicalStreamWriter createWriter(OutputStream out) { try { return createWriter(new OutputStreamWriter(out, this.encoding)); } catch (UnsupportedEncodingException e) { throw new StreamException(e); } } }
windystrife/UnrealEngine_NVIDIAGameWork
Engine/Source/Editor/AnimationModifiers/Public/AnimationModifier.h
<gh_stars>1-10 // Copyright 1998-2017 Epic Games, Inc. All Rights Reserved. #pragma once #include "Animation/AnimEnums.h" #include "Animation/AnimCurveTypes.h" #include "AnimationBlueprintLibrary.h" #include "AnimationModifier.generated.h" class USkeleton; UCLASS(Blueprintable, Experimental, config = Editor, defaultconfig) class ANIMATIONMODIFIERS_API UAnimationModifier : public UObject { GENERATED_BODY() friend class FAnimationModifierDetailCustomization; public: /** Applying and reverting the modifier for the given Animation Sequence */ void ApplyToAnimationSequence(class UAnimSequence* InAnimationSequence); void RevertFromAnimationSequence(class UAnimSequence* InAnimationSequence); /** Executed when the Animation is initialized (native event for debugging / testing purposes) */ UFUNCTION(BlueprintNativeEvent) void OnApply(UAnimSequence* AnimationSequence); virtual void OnApply_Implementation(UAnimSequence* AnimationSequence) {} UFUNCTION(BlueprintNativeEvent) void OnRevert(UAnimSequence* AnimationSequence); virtual void OnRevert_Implementation(UAnimSequence* AnimationSequence) {} /** Whether or not the latest compiled version of the blueprint is applied for this instance */ bool IsLatestRevisionApplied() const; // Begin UObject Overrides virtual void PostInitProperties() override; // End UObject Overrides protected: // Derived class accessors to skeleton and anim sequence const UAnimSequence* GetAnimationSequence(); const USkeleton* GetSkeleton(); /** Used for natively updating the revision GUID, fairly basic and relies on config files currently */ virtual int32 GetNativeClassRevision() const; /** Checks if the animation data has to be re-baked / compressed and does so */ void UpdateCompressedAnimationData(); /** Updating of blueprint and native GUIDs*/ void UpdateRevisionGuid(UClass* ModifierClass); void UpdateNativeRevisionGuid(); private: UAnimSequence* CurrentAnimSequence; USkeleton* CurrentSkeleton; void UpdateStoredRevisions(); void ResetStoredRevisions(); void SetInstanceRevisionGuid(FGuid Guid); // This holds the GUID representing the latest version of the modifier UPROPERTY(/*VisibleAnywhere for testing, Category = Revision*/) FGuid RevisionGuid; // This indicates whether or not the modifier is newer than what has been applied UPROPERTY(/*VisibleAnywhere for testing, Category = Revision */) FGuid AppliedGuid; // This holds the latest value returned by UpdateNativeRevisionGuid during the last PostLoad (changing this value will invalidate the GUIDs for all instances) UPROPERTY(config) int32 StoredNativeRevision; };
FelisCatusKR/Baekjoon_Python3
1016.py
# 1016.py import math # 최솟값과 최댓값 입력 min, max = map(int, input().split()) # 제곱수 집합과 최솟값~최댓값 수 집합 생성 squareSet = set(pow(i, 2) for i in range(2, int(math.sqrt(max)) + 1)) numSet = set(range(min, max+1)) # 제곱수의 배수를 담은 집합 생성 tempSet = set() for n in squareSet: tempSet.update([n * i for i in range(min // n, max // n + 1)]) # 수 집합과 제곱수의 배수를 담음 집합의 차집합 원소 갯수 출력 print(len(numSet - tempSet))
Ying1131271533/www.caomaokj.com
public/static/mobile/js/common.js
// token登录状态 function isToken(){ var jwt = storage('token'); if(jwt) { $.ajax({ type: "GET", url: "https://www.caomaokj.com/index/login_api/isToken", beforeSend: function(xhr) { xhr.setRequestHeader("Authorization", jwt); }, success: function(json) { if(json.data.code == 0) { // token验证通过 // layer.msg(json.data.msg, {icon: 1}); return true }else{ // token验证未通过 // layer.msg(json.data.msg, {icon: 2}); return false; } } }); } } // 退出登录 function logout(){ storage('token', null); window.location.href = "/index/login/logout"; } // 本地储存 function storage(key, value){ if(!key) { return false; } if(typeof value != "undefined"){ window.localStorage.setItem(key, value); }else{ var jwt = window.localStorage.getItem(key); return jwt; } }
mkawserm/hypcore
package/core/onlineusermemorymap.go
package core import ( "sort" "sync" ) type OnlineUserMemoryMap struct { UserMap map[string][]int SocketIDToUserMap map[int]string SocketIDToUserGroupMap map[int]string UserMapLock *sync.RWMutex } func NewOnlineUserMemoryMap() *OnlineUserMemoryMap { return &OnlineUserMemoryMap{ UserMap: make(map[string][]int), SocketIDToUserMap: make(map[int]string), SocketIDToUserGroupMap: make(map[int]string), UserMapLock: &sync.RWMutex{}, } } func (o *OnlineUserMemoryMap) AddUser(uid string, group string, sid int) { o.UserMapLock.Lock() defer o.UserMapLock.Unlock() o.SocketIDToUserMap[sid] = uid if group != "" { o.SocketIDToUserGroupMap[sid] = group } if _, ok := o.UserMap[uid]; ok { o.UserMap[uid] = append(o.UserMap[uid], sid) } else { o.UserMap[uid] = make([]int, 1) o.UserMap[uid] = append(o.UserMap[uid], sid) } } func (o *OnlineUserMemoryMap) RemoveUser(sid int) { o.UserMapLock.Lock() defer o.UserMapLock.Unlock() _, ok2 := o.SocketIDToUserGroupMap[sid] if ok2 { delete(o.SocketIDToUserGroupMap, sid) } uid, ok1 := o.SocketIDToUserMap[sid] if ok1 { delete(o.SocketIDToUserMap, sid) val, ok := o.UserMap[uid] if ok { index := sort.Search(len(val), func(i int) bool { return val[i] == sid }) if index >= len(val) || val[index] != sid { return } else { val[index] = val[len(val)-1] val = val[0 : len(val)-1] } if len(val) == 0 { delete(o.UserMap, uid) } } } } func (o *OnlineUserMemoryMap) GetIdList(uid string) []int { o.UserMapLock.RLock() defer o.UserMapLock.RUnlock() val, ok := o.UserMap[uid] if ok { tmp := make([]int, len(val)) copy(tmp, val) return tmp } else { return make([]int, 0) } } func (o *OnlineUserMemoryMap) GetUIDFromSID(sid int) string { o.UserMapLock.RLock() defer o.UserMapLock.RUnlock() val, ok := o.SocketIDToUserMap[sid] if ok { return val } else { return "" } } func (o *OnlineUserMemoryMap) GetGroupFromSID(sid int) string { o.UserMapLock.RLock() defer o.UserMapLock.RUnlock() val, ok := o.SocketIDToUserGroupMap[sid] if ok { return val } else { return "" } } func (o *OnlineUserMemoryMap) GetUIDList() []string { o.UserMapLock.RLock() defer o.UserMapLock.RUnlock() var uidList []string for user, _ := range o.UserMap { uidList = append(uidList, user) } return uidList } func (o *OnlineUserMemoryMap) GetTotalUID() int { o.UserMapLock.RLock() defer o.UserMapLock.RUnlock() return len(o.UserMap) }
xiaozhu36/alibaba-cloud-sdk-go
services/yundun-ds/struct_rule.go
package yundun_ds //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. // // Code generated by Alibaba Cloud SDK Code Generator. // Changes may cause incorrect behavior and will be lost if the code is regenerated. // Rule is a nested struct in yundun_ds response type Rule struct { Name string `json:"Name" xml:"Name"` Status int `json:"Status" xml:"Status"` RiskLevelName string `json:"RiskLevelName" xml:"RiskLevelName"` RuleName string `json:"RuleName" xml:"RuleName"` DepartName string `json:"DepartName" xml:"DepartName"` Id int64 `json:"Id" xml:"Id"` CustomType int `json:"CustomType" xml:"CustomType"` DisplayName string `json:"DisplayName" xml:"DisplayName"` GmtCreate int64 `json:"GmtCreate" xml:"GmtCreate"` CategoryName string `json:"CategoryName" xml:"CategoryName"` Content string `json:"Content" xml:"Content"` LoginName string `json:"LoginName" xml:"LoginName"` Count int64 `json:"Count" xml:"Count"` GmtModified int64 `json:"GmtModified" xml:"GmtModified"` Category int `json:"Category" xml:"Category"` RiskLevelId int64 `json:"RiskLevelId" xml:"RiskLevelId"` UserId int64 `json:"UserId" xml:"UserId"` Description string `json:"Description" xml:"Description"` }
mythoss/midpoint
repo/repo-sql-impl/src/main/java/com/evolveum/midpoint/repo/sql/data/common/embedded/REmbeddedReference.java
<gh_stars>0 /* * Copyright (c) 2010-2020 Evolveum and contributors * * This work is dual-licensed under the Apache License 2.0 * and European Union Public License. See LICENSE file for details. */ package com.evolveum.midpoint.repo.sql.data.common.embedded; import static com.evolveum.midpoint.repo.sql.util.RUtil.*; import java.util.Objects; import javax.persistence.*; import org.apache.commons.lang3.StringUtils; import org.hibernate.annotations.NotFound; import org.hibernate.annotations.NotFoundAction; import com.evolveum.midpoint.prism.PrismContext; import com.evolveum.midpoint.repo.sql.data.common.ObjectReference; import com.evolveum.midpoint.repo.sql.data.common.RObject; import com.evolveum.midpoint.repo.sql.data.common.other.RObjectType; import com.evolveum.midpoint.repo.sql.query.definition.NotQueryable; import com.evolveum.midpoint.repo.sql.util.ClassMapper; import com.evolveum.midpoint.schema.RelationRegistry; import com.evolveum.midpoint.xml.ns._public.common.common_3.ObjectReferenceType; /** * @author lazyman */ @Embeddable public class REmbeddedReference implements ObjectReference { //target private String targetOid; //other fields private RObjectType targetType; //relation qname private String relation; @Column(length = COLUMN_LENGTH_QNAME) @Override public String getRelation() { return relation; } @ManyToOne(fetch = FetchType.LAZY) @JoinColumn(referencedColumnName = "oid", updatable = false, insertable = false, foreignKey = @ForeignKey(ConstraintMode.NO_CONSTRAINT)) // commented because of The NotFoundAction.IGNORE @ManyToOne and @OneToOne associations are always fetched eagerly. (HHH-12770) // @NotFound(action = NotFoundAction.IGNORE) @NotQueryable public RObject getTarget() { return null; } @Column(length = COLUMN_LENGTH_OID) @Override public String getTargetOid() { return targetOid; } @Enumerated(EnumType.ORDINAL) @Override public RObjectType getTargetType() { return targetType; } public void setRelation(String relation) { this.relation = relation; } public void setTargetOid(String targetOid) { this.targetOid = targetOid; } public void setTargetType(RObjectType type) { this.targetType = type; } // only for ORM/JPA public void setTarget(RObject target) { } @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } REmbeddedReference that = (REmbeddedReference) o; return Objects.equals(targetOid, that.targetOid) && Objects.equals(targetType, that.targetType) && Objects.equals(relation, that.relation); } @Override public int hashCode() { // TODO: before june 2020 targetOid field was missing here (but was in equals) return Objects.hash(targetOid, targetType, relation); } @Override public String toString() { return "REmbeddedReference{" + "targetOid='" + targetOid + '\'' + ", type=" + targetType + ", relation='" + relation + '\'' + '}'; } public static void copyToJAXB(REmbeddedReference repo, ObjectReferenceType jaxb, PrismContext prismContext) { Objects.requireNonNull(repo, "Repo object must not be null."); Objects.requireNonNull(jaxb, "JAXB object must not be null."); jaxb.setType(ClassMapper.getQNameForHQLType(repo.getTargetType())); jaxb.setRelation(stringToQName(repo.getRelation())); if (StringUtils.isNotEmpty(repo.getTargetOid())) { jaxb.setOid(repo.getTargetOid()); } } public static REmbeddedReference fromJaxb(ObjectReferenceType jaxb, REmbeddedReference repo, RelationRegistry relationRegistry) { Objects.requireNonNull(repo, "Repo object must not be null."); Objects.requireNonNull(jaxb, "JAXB object must not be null."); repo.setTargetType(ClassMapper.getHQLTypeForQName(jaxb.getType())); repo.setRelation(qnameToString(relationRegistry.normalizeRelation(jaxb.getRelation()))); repo.setTargetOid(jaxb.getOid()); return repo; } public ObjectReferenceType toJAXB(PrismContext prismContext) { ObjectReferenceType ref = new ObjectReferenceType(); copyToJAXB(this, ref, prismContext); return ref; } }