text
stringlengths 4
6.14k
|
|---|
//
// PPOcrResultView.h
// PhotoPayFramework
//
// Created by Jura on 01/02/14.
// Copyright (c) 2014 MicroBlink Ltd. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "PPOverlaySubview.h"
NS_ASSUME_NONNULL_BEGIN
@class PPOcrLayout;
/**
* Overlay subview presenting status of OCR detection. OCR results are displayed as green characters over detected locations.
*/
PP_CLASS_AVAILABLE_IOS(6.0) @interface PPOcrResultOverlaySubview : PPOverlaySubview
@end
NS_ASSUME_NONNULL_END
|
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2018-2019 Damien P. George
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
#include "py/runtime.h"
#include "py/mphal.h"
#include "extmod/nimble/nimble/hci_uart.h"
#if MICROPY_BLUETOOTH_NIMBLE
#if defined(STM32WB)
/******************************************************************************/
// HCI over IPCC
#include "rfcore.h"
int nimble_hci_uart_configure(uint32_t port) {
(void)port;
return 0;
}
int nimble_hci_uart_set_baudrate(uint32_t baudrate) {
(void)baudrate;
return 0;
}
int nimble_hci_uart_activate(void) {
rfcore_ble_init();
return 0;
}
void nimble_hci_uart_rx(hal_uart_rx_cb_t rx_cb, void *rx_arg) {
// Protect in case it's called from ble_npl_sem_pend at thread-level
MICROPY_PY_LWIP_ENTER
rfcore_ble_check_msg(rx_cb, rx_arg);
MICROPY_PY_LWIP_EXIT
}
void nimble_hci_uart_tx_strn(const char *str, uint len) {
MICROPY_PY_LWIP_ENTER
rfcore_ble_hci_cmd(len, (const uint8_t*)str);
MICROPY_PY_LWIP_EXIT
}
#else
/******************************************************************************/
// HCI over UART
#include "pendsv.h"
#include "uart.h"
#include "drivers/cyw43/cywbt.h"
pyb_uart_obj_t bt_hci_uart_obj;
static uint8_t hci_uart_rxbuf[512];
#ifdef pyb_pin_BT_DEV_WAKE
static uint32_t bt_sleep_ticks;
#endif
extern void nimble_poll(void);
mp_obj_t mp_uart_interrupt(mp_obj_t self_in) {
pendsv_schedule_dispatch(PENDSV_DISPATCH_NIMBLE, nimble_poll);
return mp_const_none;
}
MP_DEFINE_CONST_FUN_OBJ_1(mp_uart_interrupt_obj, mp_uart_interrupt);
int nimble_hci_uart_set_baudrate(uint32_t baudrate) {
uart_init(&bt_hci_uart_obj, baudrate, UART_WORDLENGTH_8B, UART_PARITY_NONE, UART_STOPBITS_1, UART_HWCONTROL_RTS | UART_HWCONTROL_CTS);
uart_set_rxbuf(&bt_hci_uart_obj, sizeof(hci_uart_rxbuf), hci_uart_rxbuf);
return 0;
}
int nimble_hci_uart_configure(uint32_t port) {
// bits (8), stop (1), parity (none) and flow (rts/cts) are assumed to match MYNEWT_VAL_BLE_HCI_UART_ constants in syscfg.h.
bt_hci_uart_obj.base.type = &pyb_uart_type;
bt_hci_uart_obj.uart_id = port;
bt_hci_uart_obj.is_static = true;
bt_hci_uart_obj.timeout = 2;
bt_hci_uart_obj.timeout_char = 2;
MP_STATE_PORT(pyb_uart_obj_all)[bt_hci_uart_obj.uart_id - 1] = &bt_hci_uart_obj;
return 0;
}
int nimble_hci_uart_activate(void) {
// Interrupt on RX chunk received (idle)
// Trigger nimble poll when this happens
mp_obj_t uart_irq_fn = mp_load_attr(&bt_hci_uart_obj, MP_QSTR_irq);
mp_obj_t uargs[] = {
MP_OBJ_FROM_PTR(&mp_uart_interrupt_obj),
MP_OBJ_NEW_SMALL_INT(UART_FLAG_IDLE),
mp_const_true,
};
mp_call_function_n_kw(uart_irq_fn, 3, 0, uargs);
#if MICROPY_PY_NETWORK_CYW43
cywbt_init();
cywbt_activate();
#endif
return 0;
}
void nimble_hci_uart_rx(hal_uart_rx_cb_t rx_cb, void *rx_arg) {
#ifdef pyb_pin_BT_HOST_WAKE
int host_wake = 0;
host_wake = mp_hal_pin_read(pyb_pin_BT_HOST_WAKE);
/*
// this is just for info/tracing purposes
static int last_host_wake = 0;
if (host_wake != last_host_wake) {
printf("HOST_WAKE change %d -> %d\n", last_host_wake, host_wake);
last_host_wake = host_wake;
}
*/
#endif
while (uart_rx_any(&bt_hci_uart_obj)) {
uint8_t data = uart_rx_char(&bt_hci_uart_obj);
//printf("UART RX: %02x\n", data);
rx_cb(rx_arg, data);
}
#ifdef pyb_pin_BT_DEV_WAKE
if (host_wake == 1 && mp_hal_pin_read(pyb_pin_BT_DEV_WAKE) == 0) {
if (mp_hal_ticks_ms() - bt_sleep_ticks > 500) {
//printf("BT SLEEP\n");
mp_hal_pin_high(pyb_pin_BT_DEV_WAKE); // let sleep
}
}
#endif
}
void nimble_hci_uart_tx_strn(const char *str, uint len) {
#ifdef pyb_pin_BT_DEV_WAKE
bt_sleep_ticks = mp_hal_ticks_ms();
if (mp_hal_pin_read(pyb_pin_BT_DEV_WAKE) == 1) {
//printf("BT WAKE for TX\n");
mp_hal_pin_low(pyb_pin_BT_DEV_WAKE); // wake up
// Use delay_us rather than delay_ms to prevent running the scheduler (which
// might result in more BLE operations).
mp_hal_delay_us(5000); // can't go lower than this
}
#endif
uart_tx_strn(&bt_hci_uart_obj, str, len);
}
#endif // defined(STM32WB)
#endif // MICROPY_BLUETOOTH_NIMBLE
|
#include "tlc_window.h"
namespace Centauri {
class TLC {
public:
TLC();
~TLC();
int test();
void init();
void error(std::string);
TLCWindow* createWindow();
};
}
|
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Sep 30 2020 21:18:12).
//
// Copyright (C) 1997-2019 Steve Nygard.
//
#import <Foundation/NSDictionary.h>
@class NSArray;
@interface DVTStablePropertyListDictionary : NSDictionary
{
NSDictionary *_dictionary;
NSArray *_orderedKeys;
}
- (void).cxx_destruct;
- (id)keyEnumerator;
- (id)objectForKey:(id)arg1;
- (unsigned long long)count;
- (id)initWithContents:(id)arg1 memoTable:(id)arg2;
@end
|
//
// AppDelegate.h
// RaisedCenterButton
//
// Created by Johnnie Pittman on 5/13/12.
// Copyright (c) 2012 Group 6. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface AppDelegate : UIResponder <UIApplicationDelegate, UITabBarControllerDelegate>
@property (strong, nonatomic) UIWindow *window;
@property (strong, nonatomic) UITabBarController *tabBarController;
@end
|
#ifndef _MOSTRONET_H_
#define _MOSTRONET_H_
#include <stdio.h>
#include <stdlib.h>
#include <unistd.h>
#include <fcntl.h>
#include <string.h>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <netinet/tcp.h>
#include <signal.h>
#include <arpa/inet.h>
#include <time.h>
#include <sys/stat.h>
#include <mqueue.h>
#include <pthread.h>
#define NOTSET 0
#define IPV4 1
#define IPV6 2
#define FULLSUPPORT 3
#define MAXREQUESTS
typedef struct
{
char *port;
char *droot;
char *device;
int mqd;
int requests;
} serverData;
int setConfig(int confd, serverData * sd);
int parser(char *request, char *path, char *contentType);
int getFile(char * droot, char *path, char *contentType, char *header);
int mode(serverData config, int _mode);
void * handle(void *);
void * safemalloc(size_t size);
#endif
|
// This file was generated based on 'C:\ProgramData\Uno\Packages\Fuse.Animations\0.11.3\$.uno'.
// WARNING: Changes might be lost if you edit this file directly.
#ifndef __APP_FUSE_ANIMATIONS_CONVERTER__FUSE_ELEMENTS_CACHING_MODE_H__
#define __APP_FUSE_ANIMATIONS_CONVERTER__FUSE_ELEMENTS_CACHING_MODE_H__
#include <app/Uno.Object.h>
#include <Uno.h>
namespace app { namespace Uno { struct Float4; } }
namespace app {
namespace Fuse {
namespace Animations {
struct Converter__Fuse_Elements_CachingMode;
struct Converter__Fuse_Elements_CachingMode__uType : ::uClassType
{
::app::Uno::Float4(*__fp_In)(Converter__Fuse_Elements_CachingMode*, int);
int(*__fp_Out)(Converter__Fuse_Elements_CachingMode*, ::app::Uno::Float4);
};
Converter__Fuse_Elements_CachingMode__uType* Converter__Fuse_Elements_CachingMode__typeof();
struct Converter__Fuse_Elements_CachingMode : ::uObject
{
::app::Uno::Float4 In(int value);
int Out(::app::Uno::Float4 value);
};
}}}
#include <app/Uno.Float4.h>
namespace app {
namespace Fuse {
namespace Animations {
inline ::app::Uno::Float4 Converter__Fuse_Elements_CachingMode::In(int value) { return (((Converter__Fuse_Elements_CachingMode__uType*)this->__obj_type)->__fp_In)(this, value); }
inline int Converter__Fuse_Elements_CachingMode::Out(::app::Uno::Float4 value) { return (((Converter__Fuse_Elements_CachingMode__uType*)this->__obj_type)->__fp_Out)(this, value); }
}}}
#endif
|
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* Mupen64plus-rsp-hle - alist_internal.h *
* Mupen64Plus homepage: http://code.google.com/p/mupen64plus/ *
* Copyright (C) 2002 Hacktarux *
* *
* This program is free software; you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
* This program is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with this program; if not, write to the *
* Free Software Foundation, Inc., *
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
#ifndef ALIST_INTERNAL_H
#define ALIST_INTERNAL_H
#include "hle.h"
typedef void (*acmd_callback_t)(u32 inst1, u32 inst2);
/*
* Audio flags
*/
#define A_INIT 0x01
#define A_CONTINUE 0x00
#define A_LOOP 0x02
#define A_OUT 0x02
#define A_LEFT 0x02
#define A_RIGHT 0x00
#define A_VOL 0x04
#define A_RATE 0x00
#define A_AUX 0x08
#define A_NOAUX 0x00
#define A_MAIN 0x00
#define A_MIX 0x10
extern u16 AudioInBuffer, AudioOutBuffer, AudioCount;
extern u16 AudioAuxA, AudioAuxC, AudioAuxE;
extern u32 loopval; // Value set by A_SETLOOP : Possible conflict with SETVOLUME???
#endif
|
#import "GPUImageTwoInputFilter.h"
// This is the feature extraction phase of the ColourFAST feature detector, as described in:
//
// A. Ensor and S. Hall. ColourFAST: GPU-based feature point detection and tracking on mobile devices. 28th International Conference of Image and Vision Computing, New Zealand, 2013, p. 124-129.
//
// Seth Hall, "GPU accelerated feature algorithms for mobile devices", PhD thesis, School of Computing and Mathematical Sciences, Auckland University of Technology 2014.
// http://aut.researchgateway.ac.nz/handle/10292/7991
@interface GPUImageColourFASTSamplingOperation : GPUImageTwoInputFilter
{
GLint texelWidthUniform, texelHeightUniform;
CGFloat texelWidth, texelHeight;
BOOL hasOverriddenImageSizeFactor;
}
// The texel width and height determines how far out to sample from this texel. By default, this is the normalized width of a pixel, but this can be overridden for different effects.
@property(readwrite, nonatomic) CGFloat texelWidth;
@property(readwrite, nonatomic) CGFloat texelHeight;
@end
|
//
// TIPImage.h
// TriviaOutlineView
//
// Created by Nur Monson on 1/30/07.
// Copyright 2007 theidiotproject. All rights reserved.
//
#import <Cocoa/Cocoa.h>
@interface TIPImage : NSImage {
NSString *thePathToFile;
}
- (NSString *)pathToFile;
- (void)setPathToFile:(NSString *)newPathToFile;
@end
|
#include<stdio.h>
int search(int v[],int num,int low,int high)
{
int middle;
middle=(low+high)/2;
if(low<=high)
{
if(num==v[middle])
{
return middle;
}
else if(num>v[middle])
{
return search(v,num,middle+1,high);
}
else
{
return search(v,num,low,middle-1);
}
}
return -1;
}
int main(void)
{
int a[5]={1,2,3,4,5};
printf("%d",search(a,7,0,4));
return 0;
}
|
#ifndef CLINE_JOIN_TYPE_H
#define CLINE_JOIN_TYPE_H
enum CLineJoinType {
LINE_JOIN_TYPE_NONE = 0,
LINE_JOIN_TYPE_MITRE = 1,
LINE_JOIN_TYPE_ROUND = 2,
LINE_JOIN_TYPE_BEVEL = 3
};
#endif
|
//
// ViewController.h
// SimpleWeather
//
// Created by choushayne on 14/12/31.
// Copyright (c) 2014年 ShayneChow. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface ViewController : UIViewController
@end
|
//
// DSDefinitions.h
// sunny
//
// Created by Draco on 2013-08-20.
// Copyright (c) 2013 Draco. All rights reserved.
//
// Configurations
#define kShouldPlayWalkAnimationWhenBlocked YES
#define kGameScale 1
#define kChatBoxZIndex 10
#define kChatBoxCursorBlinkFrequency 1
////// Character Contants //////
#define kCharacterZIndex 2
#define kCharacterJumpHeight 15 // In points
#define kCharacterJumpSpeed 0.23
// A character's default travel distance per step
#define kCharacterDistancePerStep 18
// A character's default speed per step in seconds
#define kCharacterSpeedPerStep 0.25
// A character's default frames for walk animations
#define kCharacterWalkAnimationFrames 3
typedef enum {
kBallonTypeExclaimation = 0,
kBallonTypeQuestion,
kBallonTypeMusic,
kBallonTypeHeart,
kBallonTypeAnnoyed,
kBallonTypeWaterDrip,
kBallonTypeConfused,
kBallonTypeDotDot,
kBallonTypeLightBulb,
kBallonTypeSleeping,
kBallonTypeMAX
} BalloonType;
typedef enum {
kDirectionNorth = 0,
kDirectionEast,
kDirectionSouth,
kDirectionWest
} Direction;
|
//
// MBSetupController.h
// SetupController
//
// Created by Maksim Bauer on 26/04/14.
// Copyright (c) 2014 Maksim Bauer. All rights reserved.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@protocol MBSetupControllerDataSource;
@protocol MBSetupControllerDelegate;
#pragma mark - MBPage
@protocol MBPage <NSObject>
/**
Indicates whether setup controller should remove the receiver from stack when its done (i.e. another page controller has been pushed on stack above it)
*/
@property (nonatomic) BOOL removeWhenDone;
/**
Will be set to YES if receiver has been skipped.
*/
@property (nonatomic, readonly, getter=isSkipped) BOOL skipped;
@end
#pragma mark - MBSetupController
@interface MBSetupController : UIViewController
@property (weak, nonatomic, nullable) id<MBSetupControllerDataSource> dataSource;
@property (weak, nonatomic, nullable) id<MBSetupControllerDelegate> delegate;
#pragma mark - Customizing Appearance
@property (nonatomic, readonly) UINavigationController *setupNavigationController;
#pragma mark - Providing Content
/**
The view controllers currently on stack.
*/
@property (nonatomic, readonly) NSArray<UIViewController<MBPage> *> *viewControllers;
- (void)setViewControllers:(NSArray<UIViewController<MBPage> *> *)controllers animated:(BOOL)animated;
#pragma mark - Navigating
/**
Pop current view controller from stack.
*/
- (void)popBack;
/**
Push next view controller on stack.
*/
- (void)pushNext;
@end
#pragma mark - Protocols
@protocol MBSetupControllerDataSource <NSObject>
/**
Returns the next page view controller after the given view controller.
*/
- (nullable UIViewController<MBPage> *)setupController:(MBSetupController *)setupController viewControllerAfterViewController:(nullable UIViewController<MBPage> *)viewController;
@end
@protocol MBSetupControllerDelegate <NSObject>
@optional
- (void)setupController:(MBSetupController *)setupController willShowViewController:(UIViewController<MBPage> *)viewController animated:(BOOL)animated;
- (void)setupController:(MBSetupController *)setupController didShowViewController:(UIViewController<MBPage> *)viewController animated:(BOOL)animated;
- (void)setupControllerDidFinish:(MBSetupController *)setupController;
@end
NS_ASSUME_NONNULL_END
|
/**
* @file glfw_mesh_renderer.h
* @brief Defines GLFWMeshRenderer.
*/
#pragma once
#include "std/ogle_std.inc"
#include "renderer/glfw_buffered_mesh.h"
#include "renderer/mesh_renderer.h"
#include "renderer/opengl_primitive_types.h"
namespace ogle {
class GLSLShaderProgram;
/**
* @brief MeshRenderer implemented with GLFW & OpenGL.
*/
class GLFWMeshRenderer : public MeshRenderer {
public:
/// String to specify use of this implementation in configuration file.
static const stl_string kConfigImplementationName;
/**
* @brief Constructor. Call Create() to complete object construction.
*
* @param mesh Mesh to render.
* @param material Material to use in render pass.
*/
GLFWMeshRenderer(const BufferedMesh& mesh, Material* material);
/**
* @brief Destructor. Deallocates OpenGL objects.
*/
~GLFWMeshRenderer() override;
/**
* @brief Allocates OpenGL objects used for rendering.
* @return success/failure.
*/
bool Create();
void Render(const Transform& transform, const Entity& camera,
const stl_vector<const Entity*>& lights) override;
private:
struct Data;
/// Material to use to render mesh.
Material* material_;
/// OpenGL ID for vertex buffer.
ogle::GLuint vertex_buffer_id_;
/// OpenGL ID for normal buffer.
ogle::GLuint normal_buffer_id_;
/// OpenGL ID for vertex buffer array object.
ogle::GLuint vertex_array_id_;
/// OpenGL ID for index buffer.
ogle::GLuint index_buffer_id_;
};
} // namespace ogle
|
/*
+----------------------------------------------------------------------+
| Forp |
+----------------------------------------------------------------------+
| Copyright (c) 2012 Anthony Terrien |
+----------------------------------------------------------------------+
| This source file is subject to version 3.01 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
| available through the world-wide-web at the following url: |
| http://www.php.net/license/3_01.txt |
| If you did not receive a copy of the PHP license and are unable to |
| obtain it through the world-wide-web, please send a note to |
| license@php.net so we can mail you a copy immediately. |
+----------------------------------------------------------------------+
| Author: Anthony Terrien <forp@anthonyterrien.com> |
| Author: ____Shies Gukai <gukai@bilibili.com> |
+----------------------------------------------------------------------+
*/
#ifndef FORP_LOG_H
#define FORP_LOG_H
#define FORP_LOG_DEPTH 2
#include "php.h"
#ifdef ZTS
#include "TSRM.h"
#endif
typedef struct forp_var_t {
char *type;
char *name;
char *key;
char *level;
char *value;
char *class;
struct forp_var_t **arr;
uint arr_len;
uint is_ref;
int refcount;
int stack_idx;
} forp_var_t;
forp_var_t *forp_zval_var(forp_var_t *v, zval *expr, int depth TSRMLS_DC);
// zval forp_find_symbol(zend_string *name TSRMLS_DC);
// void forp_inspect_symbol(char *name TSRMLS_DC);
void forp_inspect_zval(zend_string *name, zval *expr TSRMLS_DC);
#endif /* FORP_LOG_H */
/*
* Local variables:
* tab-width: 4
* c-basic-offset: 4
* End:
* vim600: noet sw=4 ts=4 fdm=marker
* vim<600: noet sw=4 ts=4
*/
|
/*
* Copyright (c) 2013 Jeremy Yallop.
*
* This file is distributed under the terms of the MIT License.
* See the file LICENSE for details.
*/
#include <caml/mlvalues.h>
#include <caml/bigarray.h>
#include "raw_pointer.h"
/* address : 'b -> pointer */
value ctypes_bigarray_address(value ba)
{
return CTYPES_FROM_PTR(Caml_ba_data_val(ba));
}
/* _view : ('a, 'b) kind -> dims:int array -> fatptr ->
('a, 'b, Bigarray.c_layout) Bigarray.Genarray.t */
value ctypes_bigarray_view(value kind_, value dims_, value ptr_)
{
int kind = Int_val(kind_);
int ndims = Wosize_val(dims_);
intnat dims[CAML_BA_MAX_NUM_DIMS];
int i;
for (i = 0; i < ndims; i++) {
dims[i] = Int_val(Field(dims_, i));
}
int flags = kind | CAML_BA_C_LAYOUT | CAML_BA_EXTERNAL;
void *data = CTYPES_ADDR_OF_FATPTR(ptr_);
return caml_ba_alloc(flags, ndims, data, dims);
}
|
#define PYBV3
#define MICROPY_HW_BOARD_NAME "PYBv3"
#define MICROPY_HW_HAS_SWITCH (1)
#define MICROPY_HW_HAS_SDCARD (1)
#define MICROPY_HW_HAS_MMA7660 (1)
#define MICROPY_HW_HAS_LIS3DSH (0)
#define MICROPY_HW_HAS_LCD (0)
#define MICROPY_HW_HAS_WLAN (0)
#define MICROPY_HW_ENABLE_RNG (1)
#define MICROPY_HW_ENABLE_RTC (1)
#define MICROPY_HW_ENABLE_TIMER (1)
#define MICROPY_HW_ENABLE_SERVO (1)
#define MICROPY_HW_ENABLE_DAC (0)
// USRSW has no pullup or pulldown, and pressing the switch makes the input go low
#define MICROPY_HW_USRSW_PIN (pin_A13)
#define MICROPY_HW_USRSW_PULL (GPIO_PULLUP)
#define MICROPY_HW_USRSW_EXTI_MODE (GPIO_MODE_IT_FALLING)
#define MICROPY_HW_USRSW_PRESSED (0)
// LEDs
#define MICROPY_HW_LED1 (pin_A8) // R1 - red
#define MICROPY_HW_LED2 (pin_A10) // R2 - red
#define MICROPY_HW_LED3 (pin_C4) // G1 - green
#define MICROPY_HW_LED4 (pin_C5) // G2 - green
#define MICROPY_HW_LED_OTYPE (GPIO_MODE_OUTPUT_PP)
#define MICROPY_HW_LED_ON(pin) (pin->gpio->BSRRH = pin->pin_mask)
#define MICROPY_HW_LED_OFF(pin) (pin->gpio->BSRRL = pin->pin_mask)
// SD card detect switch
#define MICROPY_HW_SDCARD_DETECT_PIN (pin_C13)
#define MICROPY_HW_SDCARD_DETECT_PULL (GPIO_PULLDOWN)
#define MICROPY_HW_SDCARD_DETECT_PRESENT (GPIO_PIN_SET)
|
/*
*
* Confidential Information of Telekinesys Research Limited (t/a Havok). Not for disclosure or distribution without Havok's
* prior written consent. This software contains code, techniques and know-how which is confidential and proprietary to Havok.
* Product and Trade Secret source code contains trade secrets of Havok. Havok Software (C) Copyright 1999-2014 Telekinesys Research Limited t/a Havok. All Rights Reserved. Use of this software is subject to the terms of an end user license agreement.
*
*/
#ifndef HK_FPU_MORPHING_DEFORMER_H
#define HK_FPU_MORPHING_DEFORMER_H
#include <Animation/Animation/Deform/Morphing/hkaMorphingDeformer.h>
/// The derived reference counted class for weighted vertex deformation.
/// Applies to both indexed and non indexed skinning.
/// By FPU it really means that it will not enforce any alignment on the input
/// or output data, but if your math configuration uses SIMD, it will use the SIMD ops
/// where it can. If you have data that has its deformable members (pos, normals, etc)
/// properly aligned, then use the SIMD version of this deformer
/// as it will be more streamlined.
/// Note this deformer only processes 3-component vectors.
/// N.B. It is important to note that these deformers are here to be used by Havok's demos but are not production quality.
/// It is assumed that deforming will be done most commonly by your graphics engine, usually in hardware on GPUs or VUs.
/// That hardware deformation is usually performed at the same time as per vertex lighting operations, so Havok cannot
/// provide optimized deformers for all such game specific usage.
class HK_EXPORT_ANIMATION hkaFPUMorphingDeformer : public hkReferencedObject, public hkaMorphingDeformer
{
public:
HK_DECLARE_CLASS_ALLOCATOR(HK_MEMORY_CLASS_ANIM_RUNTIME);
/// Initializes to an unbound deformer
hkaFPUMorphingDeformer();
/// Bind the buffers.
/// The output buffer should be preallocated.
/// Returns false if the deformer does not support the input or output buffer format.
hkBool bind( const hkaVertexDeformerInput& input, const hkxVertexBuffer* inputBuffer1, const hkxVertexBuffer* inputBuffer2, hkxVertexBuffer* outputBuffer );
/// Interpolate the input buffers into the output buffer.
/// The deformer must first be bound and the output buffer locked before deforming.
virtual void deform ( hkReal delta ) HK_OVERRIDE;
};
#endif // HK_FPU_MORPHING_DEFORMER_H
/*
* Havok SDK - NO SOURCE PC DOWNLOAD, BUILD(#20140907)
*
* Confidential Information of Havok. (C) Copyright 1999-2014
* Telekinesys Research Limited t/a Havok. All Rights Reserved. The Havok
* Logo, and the Havok buzzsaw logo are trademarks of Havok. Title, ownership
* rights, and intellectual property rights in the Havok software remain in
* Havok and/or its suppliers.
*
* Use of this software for evaluation purposes is subject to and indicates
* acceptance of the End User licence Agreement for this product. A copy of
* the license is included with this software and is also available at www.havok.com/tryhavok.
*
*/
|
/***********************************************\
* draw.h *
* George Koskeridis (C) 2016 *
\***********************************************/
#pragma once
#ifndef __DRAW_H
#define __DRAW_H
#include "common.h"
#include "main.h"
void ScaleGraphics(int scaling_exp);
void DrawBufferToWindow(HWND to, backbuffer_data *from);
void DrawToBuffer(backbuffer_data *buf);
void UpdateState(LONG num_of_customers, int *customer_states, int barber_state,
BOOL enable_animations, BOOL barbershop_door_is_open);
void CleanupGraphics(void);
#endif //__DRAW_H
|
/*
* author: muggle wei <mugglewei@gmail.com>
*
* Use of this source code is governed by the MIT license that can be
* found in the LICENSE file.
*/
#include "thread.h"
#include "muggle/c/base/err.h"
#if MUGGLE_PLATFORM_WINDOWS
#include <process.h>
int muggle_thread_create(muggle_thread_t *thread, muggle_thread_routine routine, void *args)
{
thread->handle = (HANDLE)_beginthreadex(
NULL, 0, routine, args, 0, &thread->id);
if (thread->handle == NULL)
{
return MUGGLE_ERR_SYS_CALL;
}
return MUGGLE_OK;
}
int muggle_thread_join(muggle_thread_t *thread)
{
if (WaitForSingleObject(thread->handle, INFINITE) == WAIT_FAILED)
{
return MUGGLE_ERR_SYS_CALL;
}
if (!CloseHandle(thread->handle))
{
return MUGGLE_ERR_SYS_CALL;
}
return MUGGLE_OK;
}
int muggle_thread_detach(muggle_thread_t *thread)
{
return MUGGLE_OK;
}
muggle_thread_id muggle_thread_current_id()
{
return GetCurrentThreadId();
}
int muggle_thread_hardware_concurrency()
{
SYSTEM_INFO sysinfo;
GetSystemInfo(&sysinfo);
return (int)sysinfo.dwNumberOfProcessors;
}
#else
#include <unistd.h>
int muggle_thread_create(muggle_thread_t *thread, muggle_thread_routine routine, void *args)
{
return pthread_create(&thread->th, NULL, routine, args) == 0 ? MUGGLE_OK : MUGGLE_ERR_SYS_CALL;
}
int muggle_thread_join(muggle_thread_t *thread)
{
return pthread_join(thread->th, NULL) == 0 ? MUGGLE_OK : MUGGLE_ERR_SYS_CALL;
}
int muggle_thread_detach(muggle_thread_t *thread)
{
return pthread_detach(thread->th) == 0 ? MUGGLE_OK : MUGGLE_ERR_SYS_CALL;
}
muggle_thread_id muggle_thread_current_id()
{
return pthread_self();
}
int muggle_thread_hardware_concurrency()
{
return sysconf(_SC_NPROCESSORS_ONLN);
}
#endif
|
#import "MOBProjection.h"
@interface MOBProjectionEPSG53010 : MOBProjection
@end
|
/*! \file cg_keyboard.h
* \brief Enter description here.
* \author Georgi Gerganov
*/
#pragma once
#include <mutex>
#include <memory>
#include <map>
namespace CG {
class Timer;
class Keyboard {
private:
Keyboard();
~Keyboard();
public:
inline static Keyboard & getInstance() {
static Keyboard instance;
return instance;
}
enum TypeState { KEY_NOT_PRESSED, KEY_PRESSED };
typedef int TypeKey;
typedef int TypeAction;
private:
typedef struct {
float lastUpdated;
TypeState state;
} TypeKeyState;
public:
void update(TypeKey key, int scancode, TypeAction action, int mods);
bool isPressed(TypeKey key);
TypeState getState(TypeKey key);
std::map<TypeKey, TypeAction> _actions;
std::map<TypeKey, TypeKeyState> _keys;
private:
mutable std::mutex _mutex;
std::unique_ptr<Timer> _timer;
};
}
|
#ifndef TEST_H
#define TEST_H
#pragma systemFile
void BlockCubix(DesiredMotorVals *desiredMotorVals,DesiredEncVals *desiredEncVals){
joyWaitForStart();
while(true){
time1[T1] = 0; //in ms
driveSetMecMotorN(desiredMotorVals, 1.0);
while (time1[T1] < 2250) {
motorSetActualPowerToDesired(desiredMotorVals);
writeDebugStream("Driving forward!\n");
}
driveZeroMecMotor(desiredMotorVals);
while (time1[T1] < 3000) {
motorSetActualPowerToDesired(desiredMotorVals);
writeDebugStream("Stopping!\n");
}
}
}
#endif
|
//
// IVVServiceAssembly.h
// AwesomeCurrencyConverter
//
// Created by Vladimir Ignatov on 04/03/2017.
// Copyright © 2017 Ignatov inc. All rights reserved.
//
#import "TyphoonAssembly.h"
#import "IVVServiceAssembly.h"
// Helpers
#import <RamblerTyphoonUtils/AssemblyCollector.h>
@protocol IVVHelperAssembly, IVVCoreComponentsAssembly;
@class IVVStoryboardAssembly;
@interface IVVServiceAssemblyImplementation : TyphoonAssembly <IVVServiceAssembly, RamblerInitialAssembly>
@property (nonatomic, strong) IVVStoryboardAssembly *storyboardAssembly;
@property (nonatomic, strong) TyphoonAssembly<IVVHelperAssembly> *helperAssembly;
@property (nonatomic, strong) TyphoonAssembly<IVVCoreComponentsAssembly> *coreAssembly;
@end
|
// Copyright (c) 2012-2014 The Bitcoin developers
// Distributed under the MIT software license, see the accompanying
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
#ifndef BITCOIN_VERSION_H
#define BITCOIN_VERSION_H
/**
* network protocol versioning
*/
static const int PROTOCOL_VERSION = 60102; // incremented one for woodcoin-b
//! initial proto version, to be increased after version/verack negotiation
static const int INIT_PROTO_VERSION = 209;
//! In this version, 'getheaders' was introduced.
static const int GETHEADERS_VERSION = 31800;
//! disconnect from peers older than this proto version
static const int MIN_PEER_PROTO_VERSION = 60003;
//! nTime field added to CAddress, starting with this version;
//! if possible, avoid requesting addresses nodes older than this
static const int CADDR_TIME_VERSION = 31402;
//! only request blocks from nodes outside this range of versions
static const int NOBLKS_VERSION_START = 32000;
static const int NOBLKS_VERSION_END = 32400;
//! BIP 0031, pong message, is enabled for all versions AFTER this one
static const int BIP0031_VERSION = 60000;
//! "mempool" command, enhanced "getdata" behavior starts with this version
static const int MEMPOOL_GD_VERSION = 60002;
#endif // BITCOIN_VERSION_H
|
//
// Generated by class-dump 3.5 (64 bit).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by Steve Nygard.
//
#import "CDStructures.h"
#import <IDEKit/IDEKeyDrivenNavigableItem.h>
#import "IDENavigableItemFileReferenceProxy-Protocol.h"
@class IDENavigableItem, NSString;
@interface IDEContainerItemSnapshotNavigableItem : IDEKeyDrivenNavigableItem <IDENavigableItemFileReferenceProxy>
{
}
- (BOOL)showSubitems;
@property(readonly) IDENavigableItem *primaryChildItem;
- (BOOL)isLeaf;
- (BOOL)isMajorGroup;
// Remaining properties
@property(readonly, copy) NSString *debugDescription;
@property(readonly, copy) NSString *description;
@property(readonly) unsigned long long hash;
@property(readonly) Class superclass;
@end
|
#ifndef GAUSSSIANDIALOG_H
#define GAUSSSIANDIALOG_H
#include <QDialog>
#include <QColor>
#include <gaussianfunctionpainter.h>
#include <QImage>
#include <QDial>
class GausssianDialog : public QDialog
{
Q_OBJECT
public:
GausssianDialog(int xCenterCoordinate, int yCenterCoordinate, QColor color, QImage& image, QWidget* parent);
private:
void initDialogLayout();
int imageWidth;
int imageHeight;
int xCenterCoordinate;
int yCenterCoordinate;
QColor color;
GaussianFunctionPainter* gaussianFunctionPainter;
QImage* ptr2image;
void sigmaXChangedSlot(int newSiamaX);
void sigmaYChangedSlot(int newSiamaY);
void isInverseSelectedSlot(bool newBool);
QDial* xDial;
QDial* yDial;
signals:
void updateCanvas();
};
#endif // GAUSSSIANDIALOG_H
|
/*
this example was written to debug a problem with a display width, which
is not multiple of 8.
the display width is set to 102 for this purpose
*/
#include "u8g2.h"
#include <stdio.h>
u8g2_t u8g2;
int main(void)
{
u8g2_SetupBuffer_Utf8(&u8g2, U8G2_R0);
u8g2_InitDisplay(&u8g2);
u8g2_SetPowerSave(&u8g2, 0);
u8g2_SetFont(&u8g2, u8g2_font_6x13_tf);
u8g2_SetFontDirection(&u8g2, 0);
u8g2_FirstPage(&u8g2);
do
{
u8g2_DrawHLine(&u8g2, u8g2_GetDisplayWidth(&u8g2)-1, 2, 4);
u8g2_DrawStr(&u8g2, 10, 20, "Clip");
} while( u8g2_NextPage(&u8g2) );
utf8_show();
printf("DisplayWidth = %d\n", u8g2_GetDisplayWidth(&u8g2));
return 0;
}
|
//
// SphereBlock.h
// sunflow
//
// Created by Okami Satoshi on 12/05/31.
// Copyright (c) 2012 Okami Satoshi. All rights reserved.
//
#ifndef _SphereBlock_h
#define _SphereBlock_h
#include "MeshBlock.h"
#include "BufferStream.h"
class SphereBlock : public MeshBlock {
public:
SphereBlock(const string _name) {
type = "sphere";
name = _name;
m.makeScaleMatrix(1, 1, 1);
}
void flush(BufferStream& stream) {
stream.push("object");
stream.write("shader", shader);
stream.write("transform col");
for (int i = 0; i < 16; i = i + 4) {
stream.write("", m.getPtr()[i], m.getPtr()[i + 1], m.getPtr()[i + 2], m.getPtr()[i + 3]);
}
stream.write("type", type);
stream.write("name", name);
stream.pop();
}
};
#endif
|
/*
* DVFSOriginal.h
*
* Created on: 15 Feb, 2015
* Author: yeokm1
*/
#ifndef DVFS_DVFSORIGINAL_H_
#define DVFS_DVFSORIGINAL_H_
#include <dvfs/DVFS.h>
class DVFSOriginal: public DVFS {
public:
DVFSOriginal(int fpsLowBound, int fpsHighBound, bool maxTargetIfCharging);
virtual ~DVFSOriginal();
protected:
void regularRunner();
private:
void makeCPUMeetThisFPS(int targetFPS, int currentFPS, CPU * cpu);
void makeGPUMeetThisFPS(int targetFPS, int currentFPS, GPU * gpu);
void processInputs(int currentFPS, int newFPSValue, bool fpsInRange, CPU * cpu, GPU * gpu);
};
#endif /* DVFS_DVFSORIGINAL_H_ */
|
// Comparator
extern struct {
// control and status register
struct {
unsigned int COMP1EN: 1; // Comparator 1 enable
unsigned int COMP1_INP_DAC: 1; // COMP1_INP_DAC
unsigned int COMP1MODE: 2; // Comparator 1 mode
unsigned int COMP1INSEL: 3; // Comparator 1 inverting input selection
unsigned int : 3; // Reserved
unsigned int COMP1_OUT_SEL: 4; // Comparator 1 output selection
unsigned int : 1; // Reserved
unsigned int COMP1POL: 1; // Comparator 1 output polarity
unsigned int COMP1HYST: 2; // Comparator 1 hysteresis
unsigned int COMP1_BLANKING: 3; // Comparator 1 blanking source
unsigned int : 9; // Reserved
unsigned int COMP1OUT: 1; // Comparator 1 output
unsigned int COMP1LOCK: 1; // Comparator 1 lock
} COMP1_CSR;
// control and status register
struct {
unsigned int COMP2EN: 1; // Comparator 2 enable
unsigned int : 1; // Reserved
unsigned int COMP2MODE: 2; // Comparator 2 mode
unsigned int COMP2INSEL: 3; // Comparator 2 inverting input selection
unsigned int COMP2INPSEL: 1; // Comparator 2 non inverted input selection
unsigned int : 1; // Reserved
unsigned int COMP2INMSEL: 1; // Comparator 1inverting input selection
unsigned int COMP2_OUT_SEL: 4; // Comparator 2 output selection
unsigned int : 1; // Reserved
unsigned int COMP2POL: 1; // Comparator 2 output polarity
unsigned int COMP2HYST: 2; // Comparator 2 hysteresis
unsigned int COMP2_BLANKING: 3; // Comparator 2 blanking source
unsigned int : 10; // Reserved
unsigned int COMP2LOCK: 1; // Comparator 2 lock
} COMP2_CSR;
// control and status register
struct {
unsigned int COMP3EN: 1; // Comparator 3 enable
unsigned int : 1; // Reserved
unsigned int COMP3MODE: 2; // Comparator 3 mode
unsigned int COMP3INSEL: 3; // Comparator 3 inverting input selection
unsigned int COMP3INPSEL: 1; // Comparator 3 non inverted input selection
unsigned int : 2; // Reserved
unsigned int COMP3_OUT_SEL: 4; // Comparator 3 output selection
unsigned int : 1; // Reserved
unsigned int COMP3POL: 1; // Comparator 3 output polarity
unsigned int COMP3HYST: 2; // Comparator 3 hysteresis
unsigned int COMP3_BLANKING: 3; // Comparator 3 blanking source
unsigned int : 9; // Reserved
unsigned int COMP3OUT: 1; // Comparator 3 output
unsigned int COMP3LOCK: 1; // Comparator 3 lock
} COMP3_CSR;
// control and status register
struct {
unsigned int COMP4EN: 1; // Comparator 4 enable
unsigned int : 1; // Reserved
unsigned int COMP4MODE: 2; // Comparator 4 mode
unsigned int COMP4INSEL: 3; // Comparator 4 inverting input selection
unsigned int COMP4INPSEL: 1; // Comparator 4 non inverted input selection
unsigned int : 1; // Reserved
unsigned int COM4WINMODE: 1; // Comparator 4 window mode
unsigned int COMP4_OUT_SEL: 4; // Comparator 4 output selection
unsigned int : 1; // Reserved
unsigned int COMP4POL: 1; // Comparator 4 output polarity
unsigned int COMP4HYST: 2; // Comparator 4 hysteresis
unsigned int COMP4_BLANKING: 3; // Comparator 4 blanking source
unsigned int : 9; // Reserved
unsigned int COMP4OUT: 1; // Comparator 4 output
unsigned int COMP4LOCK: 1; // Comparator 4 lock
} COMP4_CSR;
// control and status register
struct {
unsigned int COMP5EN: 1; // Comparator 5 enable
unsigned int : 1; // Reserved
unsigned int COMP5MODE: 2; // Comparator 5 mode
unsigned int COMP5INSEL: 3; // Comparator 5 inverting input selection
unsigned int COMP5INPSEL: 1; // Comparator 5 non inverted input selection
unsigned int : 2; // Reserved
unsigned int COMP5_OUT_SEL: 4; // Comparator 5 output selection
unsigned int : 1; // Reserved
unsigned int COMP5POL: 1; // Comparator 5 output polarity
unsigned int COMP5HYST: 2; // Comparator 5 hysteresis
unsigned int COMP5_BLANKING: 3; // Comparator 5 blanking source
unsigned int : 9; // Reserved
unsigned int COMP5OUT: 1; // Comparator51 output
unsigned int COMP5LOCK: 1; // Comparator 5 lock
} COMP5_CSR;
// control and status register
struct {
unsigned int COMP6EN: 1; // Comparator 6 enable
unsigned int : 1; // Reserved
unsigned int COMP6MODE: 2; // Comparator 6 mode
unsigned int COMP6INSEL: 3; // Comparator 6 inverting input selection
unsigned int COMP6INPSEL: 1; // Comparator 6 non inverted input selection
unsigned int : 1; // Reserved
unsigned int COM6WINMODE: 1; // Comparator 6 window mode
unsigned int COMP6_OUT_SEL: 4; // Comparator 6 output selection
unsigned int : 1; // Reserved
unsigned int COMP6POL: 1; // Comparator 6 output polarity
unsigned int COMP6HYST: 2; // Comparator 6 hysteresis
unsigned int COMP6_BLANKING: 3; // Comparator 6 blanking source
unsigned int : 9; // Reserved
unsigned int COMP6OUT: 1; // Comparator 6 output
unsigned int COMP6LOCK: 1; // Comparator 6 lock
} COMP6_CSR;
// control and status register
struct {
unsigned int COMP7EN: 1; // Comparator 7 enable
unsigned int : 1; // Reserved
unsigned int COMP7MODE: 2; // Comparator 7 mode
unsigned int COMP7INSEL: 3; // Comparator 7 inverting input selection
unsigned int COMP7INPSEL: 1; // Comparator 7 non inverted input selection
unsigned int : 2; // Reserved
unsigned int COMP7_OUT_SEL: 4; // Comparator 7 output selection
unsigned int : 1; // Reserved
unsigned int COMP7POL: 1; // Comparator 7 output polarity
unsigned int COMP7HYST: 2; // Comparator 7 hysteresis
unsigned int COMP7_BLANKING: 3; // Comparator 7 blanking source
unsigned int : 9; // Reserved
unsigned int COMP7OUT: 1; // Comparator 7 output
unsigned int COMP7LOCK: 1; // Comparator 7 lock
} COMP7_CSR;
} SVD_COMP;
asm(".equ SVD_COMP, 0x4001001c");
|
#pragma once
namespace Engine {
template <typename Cmp>
struct comparator_traits : Cmp::traits {};
template <typename T>
struct comparator_traits<std::less<T>> {
using type = T;
using cmp_type = std::less<T>;
using item_type = T;
static const T &to_cmp_type(const T &t)
{
return t;
}
};
}
|
#ifndef _SRL_RADMIN_
#define _SRL_RADMIN_
#include "srl/sys/Daemon.h"
#include "srl/radmin/Monitor.h"
#include "srl/xml/XmlRpcProtocol.h"
#include "srl/app/IniParser.h"
#include "srl/log/Logger.h"
#include "srl/radmin/RadminFTP.h"
namespace SRL
{
namespace Radmin
{
/**
* Simple thread to handle monitor cleanup
*/
class GarbageCollector : public System::Thread
{
public:
GarbageCollector();
virtual ~GarbageCollector();
void add(Monitor *monitor);
void add(RadminFTP *ftp);
protected:
System::Mutex _critsec;
Util::Vector<Monitor*> _garbage;
Util::Vector<RadminFTP*> _ftp_garbage;
bool run();
};
/**
* RadminService : public System::Daemon
* The radmin serivce manages protocols and different monitors
* that are loaded via a config file
*/
class RadminDaemon : public System::Daemon, public Monitor::Listener, public RPC::RpcService
{
public:
/** default contstructor */
RadminDaemon(const String& config_path);
/** default destructor */
virtual ~RadminDaemon();
/**
* Starts a Monitored Process
* The arguments should be:
* commands + argumetns as a string
* array of trigger stuctures
* option uid and gid
*/
RPC::RpcValue* monitorProcess(RPC::RpcArrayValue *args);
/**
* Kill all the processes owned by the specified user
*/
RPC::RpcValue* killAllProcs(const String& user);
protected:
// daemon callbacks
bool initial();
bool run();
void final();
void thread_exception(SRL::Errors::Exception &e);
void stop_event();
void reload_event();
// RPC Callback
RPC::RpcValue* execute(const String& method_name, RPC::RpcArrayValue *args);
// monitor call backs
void monitor_triggered(Monitor &monitor, Trigger &trigger);
void monitor_error(Monitor &monitor, SRL::Errors::Exception &e);
void monitor_stopped(Monitor &monitor);
void createEventChannel();
int getNextFtpPort();
protected:
Util::Vector<Monitor*> _monitors;
Util::Vector<RadminFTP*> _ftp_servers;
Net::Socket _event_channel;
App::IniParser _config;
XML::XmlRpcProtocol *_protocol;
Net::HttpServer *_http_server;
GarbageCollector _gc;
int _ftp_port;
System::Mutex _event_critsec;
System::Mutex _ftp_critsec;
};
} /* Radmin */
} /* SRL */
#endif /* _SRL_RADMIN_ */
|
// This file was generated based on 'C:\ProgramData\Uno\Packages\FuseCore\0.11.3\Input\$.uno'.
// WARNING: Changes might be lost if you edit this file directly.
#ifndef __APP_FUSE_INPUT_POINTER_LEFT_ARGS_H__
#define __APP_FUSE_INPUT_POINTER_LEFT_ARGS_H__
#include <app/Fuse.Input.PointerEventArgs.h>
#include <app/Fuse.Scripting.IScriptEvent.h>
#include <Uno.h>
namespace app { namespace Fuse { namespace Input { struct PointerEventData; } } }
namespace app { namespace Fuse { struct Node; } }
namespace app {
namespace Fuse {
namespace Input {
struct PointerLeftArgs;
struct PointerLeftArgs__uType : ::app::Fuse::Input::PointerEventArgs__uType
{
};
PointerLeftArgs__uType* PointerLeftArgs__typeof();
void PointerLeftArgs___ObjInit_3(PointerLeftArgs* __this, ::app::Fuse::Input::PointerEventData* data, ::app::Fuse::Node* node);
PointerLeftArgs* PointerLeftArgs__New_3(::uStatic* __this, ::app::Fuse::Input::PointerEventData* data, ::app::Fuse::Node* node);
struct PointerLeftArgs : ::app::Fuse::Input::PointerEventArgs
{
void _ObjInit_3(::app::Fuse::Input::PointerEventData* data, ::app::Fuse::Node* node) { PointerLeftArgs___ObjInit_3(this, data, node); }
};
}}}
#endif
|
class view {
view( const view& v ); // Deny copy construction
void operator=( const view& v ); // Deny assignment
public:
sum_and_count* array;
size_t change;
view( size_t k ) : array(new sum_and_count[k]), change(0) {}
~view() {delete[] array;}
};
typedef tbb::enumerable_thread_specific<view> tls_type;
|
/*
* Copyright (c) 2012 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the file PATENTS. All contributing project authors may
* be found in the AUTHORS file in the root of the source tree.
*/
/*
* WebRTC's wrapper to libyuv.
*/
#ifndef COMMON_VIDEO_LIBYUV_INCLUDE_WEBRTC_LIBYUV_H_
#define COMMON_VIDEO_LIBYUV_INCLUDE_WEBRTC_LIBYUV_H_
#include <stdio.h>
#include <vector>
#include BOSS_WEBRTC_U_api__video__video_frame_h //original-code:"api/video/video_frame.h"
#include BOSS_WEBRTC_U_common_types_h //original-code:"common_types.h" // NOLINT(build/include) // VideoTypes.
namespace webrtc {
// This is the max PSNR value our algorithms can return.
const double kPerfectPSNR = 48.0f;
// TODO(nisse): Some downstream apps call CalcBufferSize with
// ::webrtc::kI420 as the first argument. Delete after they are updated.
const VideoType kI420 = VideoType::kI420;
// Calculate the required buffer size.
// Input:
// - type :The type of the designated video frame.
// - width :frame width in pixels.
// - height :frame height in pixels.
// Return value: :The required size in bytes to accommodate the specified
// video frame.
size_t CalcBufferSize(VideoType type, int width, int height);
// TODO(mikhal): Add unit test for these two functions and determine location.
// Print VideoFrame to file
// Input:
// - frame : Reference to video frame.
// - file : pointer to file object. It is assumed that the file is
// already open for writing.
// Return value: 0 if OK, < 0 otherwise.
int PrintVideoFrame(const VideoFrame& frame, FILE* file);
int PrintVideoFrame(const I420BufferInterface& frame, FILE* file);
// Extract buffer from VideoFrame or I420BufferInterface (consecutive
// planes, no stride)
// Input:
// - frame : Reference to video frame.
// - size : pointer to the size of the allocated buffer. If size is
// insufficient, an error will be returned.
// - buffer : Pointer to buffer
// Return value: length of buffer if OK, < 0 otherwise.
int ExtractBuffer(const rtc::scoped_refptr<I420BufferInterface>& input_frame,
size_t size,
uint8_t* buffer);
int ExtractBuffer(const VideoFrame& input_frame, size_t size, uint8_t* buffer);
// Convert From I420
// Input:
// - src_frame : Reference to a source frame.
// - dst_video_type : Type of output video.
// - dst_sample_size : Required only for the parsing of MJPG.
// - dst_frame : Pointer to a destination frame.
// Return value: 0 if OK, < 0 otherwise.
// It is assumed that source and destination have equal height.
int ConvertFromI420(const VideoFrame& src_frame,
VideoType dst_video_type,
int dst_sample_size,
uint8_t* dst_frame);
// Compute PSNR for an I420 frame (all planes).
// Returns the PSNR in decibel, to a maximum of kInfinitePSNR.
double I420PSNR(const VideoFrame* ref_frame, const VideoFrame* test_frame);
double I420PSNR(const I420BufferInterface& ref_buffer,
const I420BufferInterface& test_buffer);
// Compute SSIM for an I420 frame (all planes).
double I420SSIM(const VideoFrame* ref_frame, const VideoFrame* test_frame);
double I420SSIM(const I420BufferInterface& ref_buffer,
const I420BufferInterface& test_buffer);
// Helper function for scaling NV12 to NV12.
// If the |src_width| and |src_height| matches the |dst_width| and |dst_height|,
// then |tmp_buffer| is not used. In other cases, the minimum size of
// |tmp_buffer| should be:
// (src_width/2) * (src_height/2) * 2 + (dst_width/2) * (dst_height/2) * 2
void NV12Scale(uint8_t* tmp_buffer,
const uint8_t* src_y,
int src_stride_y,
const uint8_t* src_uv,
int src_stride_uv,
int src_width,
int src_height,
uint8_t* dst_y,
int dst_stride_y,
uint8_t* dst_uv,
int dst_stride_uv,
int dst_width,
int dst_height);
// Helper class for directly converting and scaling NV12 to I420. The Y-plane
// will be scaled directly to the I420 destination, which makes this faster
// than separate NV12->I420 + I420->I420 scaling.
class NV12ToI420Scaler {
public:
NV12ToI420Scaler();
~NV12ToI420Scaler();
void NV12ToI420Scale(const uint8_t* src_y,
int src_stride_y,
const uint8_t* src_uv,
int src_stride_uv,
int src_width,
int src_height,
uint8_t* dst_y,
int dst_stride_y,
uint8_t* dst_u,
int dst_stride_u,
uint8_t* dst_v,
int dst_stride_v,
int dst_width,
int dst_height);
private:
std::vector<uint8_t> tmp_uv_planes_;
};
// Convert VideoType to libyuv FourCC type
int ConvertVideoType(VideoType video_type);
} // namespace webrtc
#endif // COMMON_VIDEO_LIBYUV_INCLUDE_WEBRTC_LIBYUV_H_
|
//
// SoCMViewController.h
// 01-SinglePageApp
//
// Created by Nicholas Outram on 22/05/2014.
// Copyright (c) 2014 Plymouth University. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "SoCMDetailTableTableViewController.h"
//This is the class declaration
@interface SoCMViewController : UIViewController<SoCMDetailTableTableViewControllerDelegate> {
//Publically visible instance variable can do here
}
//Declare public methods and properties here
@property (weak, nonatomic) IBOutlet UILabel *messageLabel;
- (IBAction)doTellMeAll:(id)sender;
@end
|
// This file is part of Wintermute Engine
// For conditions of distribution and use, see copyright notice in license.txt
// http://dead-code.org/redir.php?target=wme
#if !defined(AFX_BSURFACESTORAGE_H__DAA97524_137F_11D4_9F37_8F90855A4202__INCLUDED_)
#define AFX_BSURFACESTORAGE_H__DAA97524_137F_11D4_9F37_8F90855A4202__INCLUDED_
#if _MSC_VER >= 1000
#pragma once
#endif // _MSC_VER >= 1000
#include "coll_templ.h"
class CBSurfaceStorage:CBBase
{
public:
DWORD m_LastCleanupTime;
HRESULT InitLoop();
HRESULT SortSurfaces();
int static __cdecl SurfaceSortCB(const VOID* arg1, const VOID* arg2);
HRESULT Cleanup(bool Warn=false);
//DECLARE_PERSISTENT(CBSurfaceStorage, CBBase);
HRESULT RestoreAll();
CBSurface* AddSurface(char* Filename, bool default_ck=true, BYTE ck_red=0, BYTE ck_green=0, BYTE ck_blue=0, int LifeTime=-1, bool KeepLoaded=false);
HRESULT RemoveSurface(CBSurface* surface);
CBSurfaceStorage(CBGame* inGame);
virtual ~CBSurfaceStorage();
CBArray<CBSurface*, CBSurface*> m_Surfaces;
};
#endif // !defined(AFX_BSURFACESTORAGE_H__DAA97524_137F_11D4_9F37_8F90855A4202__INCLUDED_)
|
/*
* port.h
*
* Created: 2017-10-16 17:32:54
* Author: kjph
*/
#ifndef PORT_H_
#define PORT_H_
#include <Arduino.h>
/*******************************************************************************
* Pin Mappins
******************************************************************************/
// Direct-Pins
#define DP_PORT__M1P1 9 /// PB1 (PCTIN1/OC1A)
#define DP_PORT__M2P1 5 /// PD5 (PCINT21/OC0B/T1)
#define DP_PORT__M3P1 4 /// PD4 (PCINT20/XCK/T0)
#define DP_PORT__M4P1 3 /// PD3 (PCINT19/OC2B/INT1)
#define DP_PORT__M5P1 A2 /// PC2 (ADC2/PCINT10)
#define DP_PORT__M6P1 A1 /// PC1 (ADC1/PCINT9)
#define DP_PORT__M7P1 7 /// PD7 (PCINT23/AIN1)
/*******************************************************************************
* USART
******************************************************************************/
/**
*
* Dusty-to-DuinoPro (NP)
* ____ ______________________
* | |
* RTS | ------> | DP_PORT__UART_NP_RTS = M7P1
* TX | ------> | RX = M7P4
* CTS | <------ | DP_PORT__UART_NP_CTS = M6P1
* ____| |_______________________
*
*/
#define DP_PORT__UART_NP_RTS DP_PORT__M7P1
#define DP_PORT__UART_NP_CTS DP_PORT__M6P1
/**
*
* DuinoPro-to-Dusty (PN)
* _______________________ ______
* | |
* M4P1 = DP_PORT__UART_PN_RTS | ------> | RTS
* M7P5 = TX | ------> | RX
* M5P1 = DP_PORT__UART_PN_CTS | <------ | CTS
* _______________________| |______
*
*/
#define DP_PORT__UART_PN_RTS DP_PORT__M5P1
#define DP_PORT__UART_PN_CTS DP_PORT__M1P1
/*******************************************************************************
* Interrupts
******************************************************************************/
//=====================================
/*! @brief Pin Change Interrupt 1
*
* PCINT 8 - 13
*
* This interrupt is defined in usart_flow
*
*/
//ISR(PCINT1_vect);
//=====================================
/*! @brief Pin Change Interrupt 1
*
* PCINT 8 - 13
*
* This interrupt is defined in usart_flow
*
*/
//ISR(PCINT1_vect);
//=====================================
/*! @brief Pin Change Interrupt 2
*
* PCINT 16- 23
*
* This interrupt is defined in usart_flow
*
*/
ISR(PCTIN2_vect);
//=====================================
/*! @brief Sets up PCINT (Pin Change
* Interrupts)
*
* @param pin the Arduino pin reference
*
*/
void interrupt_pci_init(int pin);
//=====================================
/*! @brief Initialises all pins
*
*/
void port_init(void);
//=====================================
/*! @brief Wrapper for arduino pinMode
*
* @param pin the Arduino pin reference
* @param mode Output or Input
*/
void pin_set_mode(int, int);
//=====================================
/*! @brief Wrapper for arduino DigialWrite
*
* @param pin the Arduion pin reference
* @param value High or Low
*/
void pin_set_digital(int, int);
//=====================================
/*! @brief Wrapper for arduino DigitalRead
*
* @param pin the Arduion pin reference
*
* @return digital value of pin
*/
int pin_read(int pin);
#endif /* PORT_H_ */
|
/*
* Copyright 2015, Yahoo Inc.
* Copyrights licensed under the MIT License.
* See the accompanying LICENSE file for terms.
*/
#import <Foundation/Foundation.h>
#import "SNBBugCreateModelCell.h"
@class SNBStateDataItem;
@protocol SNBBugCreateScreenShotModel <SNBBugCreateModelCell>
- (NSUInteger)screenShotCount;
- (SNBStateDataItem *)itemAtIndex:(NSUInteger)index;
- (void)didSelectIndexPath:(NSIndexPath *)indexPath;
- (NSIndexPath *)selectedIndexPath;
- (void)reloadData;
@end
@interface SNBBugCreateScreenShotModel : NSObject <SNBBugCreateScreenShotModel>
- (instancetype)initWithContentPath:(NSString *)contentPath;
@end
|
//
// Generated by class-dump 3.5 (64 bit).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by Steve Nygard.
//
#import "NSObject.h"
@protocol BITFeedbackUserDataDelegate <NSObject>
- (void)userDataUpdateFinished;
- (void)userDataUpdateCancelled;
@end
|
#include <stdio.h>
int find_substr(char *sl, char *s2);
int main(int argc, char **argv) {
if (find_substr("C is fun", "fun") != -1) {
printf("Substring is found.\n");
}
}
int find_substr(char *s1, char *s2) {
register int t;
char *p, *p2;
for (t = 0; s1[t]; t++) {
p = &s1[t];
p2 = s2;
while(*p2 && *p2 == *p) {
p++;
p2++;
}
if (!*p2) {
return t;
}
}
return -1;
}
|
#import <Foundation/Foundation.h>
@interface MultipleMatchingClasses : NSObject
@end
@interface FirstMultipleClass : MultipleMatchingClasses
+(void) setSuccesses: (int) successes andFailures: (int) failures;
@end
@interface SecondMultipleClass : MultipleMatchingClasses
+(void) setSuccesses: (int) successes andFailures: (int) failures;
@end
|
//
// UIImageView+MKNetworkKitAdditions.h
// MKNetworkKit-iOS
//
// Created by Mugunth Kumar (@mugunthkumar) on 18/01/13.
// Copyright (C) 2011-2020 by Steinlogic Consulting and Training Pte Ltd
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
#if TARGET_OS_IPHONE
#import <UIKit/UIKit.h>
extern const float kFromCacheAnimationDuration;
extern const float kFreshLoadAnimationDuration;
@class MKNetworkEngine;
@class MKNetworkOperation;
@interface UIImageView (MKNetworkKitAdditions)
+(void) setDefaultEngine:(MKNetworkEngine*) engine;
-(MKNetworkOperation*) setImageFromURL:(NSURL*) url;
-(MKNetworkOperation*) setImageFromURL:(NSURL*) url placeHolderImage:(UIImage*) image;
-(MKNetworkOperation*) setImageFromURL:(NSURL*) url placeHolderImage:(UIImage*) image animation:(BOOL) yesOrNo;
-(MKNetworkOperation*) setImageFromURL:(NSURL*) url placeHolderImage:(UIImage*) image usingEngine:(MKNetworkEngine*) imageCacheEngine animation:(BOOL) yesOrNo;
@end
#endif
|
// Fill out your copyright notice in the Description page of Project Settings.
#pragma once
#include "Components/StaticMeshComponent.h"
#include "TankTracks.generated.h"
/**
* TankTraks is used to set maximum driving force, and to apply forces to the tank.
*/
UCLASS( ClassGroup=(BattleTank), meta=( BlueprintSpawnableComponent) )
class BATTLETANK_API UTankTracks : public UStaticMeshComponent
{
GENERATED_BODY()
public:
UFUNCTION(BlueprintCallable, Category = TankInput)
void SetThrottle(float Throttle);
private:
UPROPERTY(EditDefaultsOnly)
float TrackMaxDrivingForce = 400000.0f;
};
|
#pragma once
#include "ofMain.h"
class Particle
{
public:
Particle();
~Particle();
void update();
void draw();
glm::vec3 position;
glm::vec3 velocity;
glm::vec3 acceleration;
glm::vec3 force;
ofColor color;
glm::vec3 orientation;
glm::vec3 angularVelocity;
glm::vec3 angularAcceleration;
};
|
//
// JPAppDelegate.h
// JPCanvas
//
// Created by John McGlone on 11/13/13.
// Copyright (c) 2013 JP. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface JPAppDelegate : UIResponder <UIApplicationDelegate>
@property (strong, nonatomic) UIWindow *window;
@end
|
/*
*
* Confidential Information of Telekinesys Research Limited (t/a Havok). Not for disclosure or distribution without Havok's
* prior written consent. This software contains code, techniques and know-how which is confidential and proprietary to Havok.
* Product and Trade Secret source code contains trade secrets of Havok. Havok Software (C) Copyright 1999-2014 Telekinesys Research Limited t/a Havok. All Rights Reserved. Use of this software is subject to the terms of an end user license agreement.
*
*/
#ifndef HK_EASE_PENETRATION_ACTION_H
#define HK_EASE_PENETRATION_ACTION_H
#include <Physics2012/Dynamics/Action/hkpUnaryAction.h>
#include <Common/Base/hkBase.h>
/// You can use this action to reduce CPU hits that occur when a new body is added to a hkpWorld in a penetrating state.
///
/// When you add a simple shape, like a box, and place it in a way that it deeply intersects with around 8 triangles of a landscape
/// mesh -- then you can expect high numbers of unjustified TOI events being handled. In a simple test case we performed, there were
/// around 10 TOIs for a moving-quality body, and around 80 for a critical-quality body.
///
/// This utility controls the m_allowedPenetrationDepth property of a rigid body over a short time of, e.g., a few seconds, to
/// avoid those unneeded TOIs and to allow the bodies to recover from penetration with normal collision response.
/// After m_timePassed reaches m_duration, the m_alloedPenetrationDepth of the hkpRigidBody is set back to its original value.
///
/// Additionally this utility can also reduce the strength at which the solver corrects inter-body penetrations. This is done by
/// iterating over all contact points, and reducing the penetration distance, that is later fed into the constraint solver.
/// As the result, less jitter may occur when bodies recover from penetration.
class hkpEasePenetrationAction : public hkpUnaryAction
{
public:
HK_DECLARE_CLASS_ALLOCATOR(HK_MEMORY_CLASS_BASE);
// This allows you to specify duration of the action. Other values can be set directly after the action is constructed.
hkpEasePenetrationAction(hkpEntity* entity, hkReal duration);
virtual ~hkpEasePenetrationAction();
// hkpAction implementation.
virtual void applyAction( const hkStepInfo& stepInfo );
virtual hkpAction* clone( const hkArray<hkpEntity*>& newEntities, const hkArray<hkpPhantom*>& newPhantoms ) const ;
public:
/// Duration of this action. After the time passes the action removes itself from the hkpWorld.
hkReal m_duration;
/// Initial multiplier for the m_entity's m_allowedPenetrationDepth. It's reduced linearly with time to reach 1.0f at the end of m_duration.
hkReal m_initialAllowedPenetrationDepthMultiplier;
/// Initial added value for the m_entity's m_allowedPenetrationDepth. It's reduced linearly with time to reach 0.0f at the end of m_duration.
hkReal m_initialAdditionalAllowedPenetrationDepth;
/// Shall the action soften the solver response too, by reducing penetration distances for contact points.
bool m_reducePenetrationDistance;
/// Initial distance multiplier applied for all penetrating contact points. It's reduced linearly with time to reach 1.0f at the end of m_duration.
/// Don't use small values, as this may cause bodies to fall through the ground. It's set to 0.2 by default.
hkReal m_initialContactDepthMultiplier;
private:
/// Time passed since the action was added to the world.
hkReal m_timePassed;
/// Original allowed penetration depth of the m_entity.
hkReal m_originalAllowedPenetrationDepth;
};
#endif // HK_EASE_PENETRATION_ACTION_H
/*
* Havok SDK - NO SOURCE PC DOWNLOAD, BUILD(#20140907)
*
* Confidential Information of Havok. (C) Copyright 1999-2014
* Telekinesys Research Limited t/a Havok. All Rights Reserved. The Havok
* Logo, and the Havok buzzsaw logo are trademarks of Havok. Title, ownership
* rights, and intellectual property rights in the Havok software remain in
* Havok and/or its suppliers.
*
* Use of this software for evaluation purposes is subject to and indicates
* acceptance of the End User licence Agreement for this product. A copy of
* the license is included with this software and is also available at www.havok.com/tryhavok.
*
*/
|
#ifdef __OBJC__
#import <UIKit/UIKit.h>
#else
#ifndef FOUNDATION_EXPORT
#if defined(__cplusplus)
#define FOUNDATION_EXPORT extern "C"
#else
#define FOUNDATION_EXPORT extern
#endif
#endif
#endif
FOUNDATION_EXPORT double Pods_Plus_VersionNumber;
FOUNDATION_EXPORT const unsigned char Pods_Plus_VersionString[];
|
#ifndef _code
void encode(char* input, char* output);
void decode(char* input);
#endif
|
#ifndef MASTERNODELIST_H
#define MASTERNODELIST_H
#include "primitives/transaction.h"
#include "platformstyle.h"
#include "sync.h"
#include "util.h"
#include <QMenu>
#include <QTimer>
#include <QWidget>
#define MY_MASTERNODELIST_UPDATE_SECONDS 60
#define MASTERNODELIST_UPDATE_SECONDS 15
#define MASTERNODELIST_FILTER_COOLDOWN_SECONDS 3
namespace Ui {
class SmartnodeList;
}
class ClientModel;
class WalletModel;
QT_BEGIN_NAMESPACE
class QModelIndex;
QT_END_NAMESPACE
/** Smartnode Manager page widget */
class SmartnodeList : public QWidget
{
Q_OBJECT
public:
explicit SmartnodeList(const PlatformStyle *platformStyle, QWidget *parent = 0);
~SmartnodeList();
void setClientModel(ClientModel *clientModel);
void setWalletModel(WalletModel *walletModel);
void StartAlias(std::string strAlias);
void StartAll(std::string strCommand = "start-all");
private:
QMenu *contextMenu;
int64_t nTimeFilterUpdated;
bool fFilterUpdated;
public Q_SLOTS:
void updateMySmartnodeInfo(QString strAlias, QString strAddr, const COutPoint& outpoint);
void updateMyNodeList(bool fForce = false);
void updateNodeList();
Q_SIGNALS:
private:
QTimer *timer;
Ui::SmartnodeList *ui;
ClientModel *clientModel;
WalletModel *walletModel;
// Protects tableWidgetSmartnodes
CCriticalSection cs_mnlist;
// Protects tableWidgetMySmartnodes
CCriticalSection cs_mymnlist;
QString strCurrentFilter;
private Q_SLOTS:
void showContextMenu(const QPoint &);
void on_filterLineEdit_textChanged(const QString &strFilterIn);
void on_startButton_clicked();
void on_startAllButton_clicked();
void on_startMissingButton_clicked();
void on_tableWidgetMySmartnodes_itemSelectionChanged();
void on_UpdateButton_clicked();
};
#endif // MASTERNODELIST_H
|
/*!
* \~chinese
* @header EMClientDelegate.h
* @abstract 此协议提供了一些实用工具类的回调
* @author Hyphenate
* @version 3.00
*
* \~english
* @header EMClientDelegate.h
* @abstract This protocol provides a number of utility classes callback
* @author Hyphenate
* @version 3.00
*/
#import <Foundation/Foundation.h>
/*!
* \~chinese
* 网络连接状态
*
* \~english
* Network Connection Status
*/
typedef enum {
EMConnectionConnected = 0, /*! *\~chinese 已连接 *\~english Connected */
EMConnectionDisconnected, /*! *\~chinese 未连接 *\~english Disconnected */
} EMConnectionState;
@class EMError;
/*!
* \~chinese
* @abstract 此协议提供了一些实用工具类的回调
*
* \~english
* @abstract This protocol provides a number of utility classes callback
*/
@protocol EMClientDelegate <NSObject>
@optional
/*!
* \~chinese
* SDK连接服务器的状态变化时会接收到该回调
*
* 有以下几种情况, 会引起该方法的调用:
* 1. 登录成功后, 手机无法上网时, 会调用该回调
* 2. 登录成功后, 网络状态变化时, 会调用该回调
*
* @param aConnectionState 当前状态
*
* \~english
* Invoked when server connection state has changed
*
* @param aConnectionState Current state
*/
- (void)connectionStateDidChange:(EMConnectionState)aConnectionState;
/*!
* \~chinese
* 自动登录完成时的回调
*
* @param aError 错误信息
*
* \~english
* Invoked when auto login is completed
*
* @param aError Error
*/
- (void)autoLoginDidCompleteWithError:(EMError *)aError;
/*!
* \~chinese
* 当前登录账号在其它设备登录时会接收到此回调
*
* \~english
* Invoked when current IM account logged into another device
*/
- (void)userAccountDidLoginFromOtherDevice;
/*!
* \~chinese
* 当前登录账号已经被从服务器端删除时会收到该回调
*
* \~english
* Invoked when current IM account is removed from server
*/
- (void)userAccountDidRemoveFromServer;
/*!
* \~chinese
* 服务被禁用
*
* \~english
* Delegate method will be invoked when User is forbidden
*/
- (void)userDidForbidByServer;
/*!
* \~chinese
* 当前登录账号被强制退出时会收到该回调,有以下原因:
* 1.密码被修改;
* 2.登陆设备数过多;
*
* \~english
* Delegate method will be invoked when current IM account is forced to logout with the following reasons:
* 1. The password is modified
* 2. Logged in too many devices
*/
- (void)userAccountDidForcedToLogout:(EMError *)aError;
#pragma mark - Deprecated methods
/*!
* \~chinese
* SDK连接服务器的状态变化时会接收到该回调
*
* 有以下几种情况, 会引起该方法的调用:
* 1. 登录成功后, 手机无法上网时, 会调用该回调
* 2. 登录成功后, 网络状态变化时, 会调用该回调
*
* @param aConnectionState 当前状态
*
* \~english
* Connection to the server status changes will receive the callback
*
* calling the method causes:
* 1. After successful login, the phone can not access
* 2. After a successful login, network status change
*
* @param aConnectionState Current state
*/
- (void)didConnectionStateChanged:(EMConnectionState)aConnectionState __deprecated_msg("Use -connectionStateDidChange:");
/*!
* \~chinese
* 自动登录完成时的回调
*
* @param aError 错误信息
*
* \~english
* Callback Automatic login fails
*
* @param aError Error
*/
- (void)didAutoLoginWithError:(EMError *)aError __deprecated_msg("Use -autoLoginDidCompleteWithError:");
/*!
* \~chinese
* 当前登录账号在其它设备登录时会接收到此回调
*
* \~english
* Will receive this callback when current account login from other device
*/
- (void)didLoginFromOtherDevice __deprecated_msg("Use -userAccountDidLoginFromOtherDevice");
/*!
* \~chinese
* 当前登录账号已经被从服务器端删除时会收到该回调
*
* \~english
* Current login account will receive the callback is deleted from the server
*/
- (void)didRemovedFromServer __deprecated_msg("Use -userAccountDidRemoveFromServer");
@end
|
//
// AppDelegate.h
// Observer
//
// Created by hukaiyin on 16/3/12.
// Copyright © 2016年 HKY. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface AppDelegate : UIResponder <UIApplicationDelegate>
@property (strong, nonatomic) UIWindow *window;
@end
|
#include <stdio.h>
void main(){
unsigned z = output("z");
fput_float(1, z);
fput_float(2, z);
fput_float(3, z);
fput_float(4, z);
fput_float(5, z);
fput_float(6, z);
fput_float(7, z);
fput_float(8, z);
fput_float(9, z);
fput_float(10, z);
}
|
//
// toastView.h
// saltfish
//
// Created by alfred on 16/2/1.
// Copyright © 2016年 Alfred. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface toastView : UIView
+ (void)showToastWith:(NSString *)text isErr:(BOOL)isErr duration:(double)duration superView:(UIView *)superView;
@end
|
//
// Generated by class-dump 3.5 (64 bit).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by Steve Nygard.
//
#import "UIView.h"
#import "SBIconAccessoryView.h"
@class NSString, SBDarkeningImageView, SBIconAccessoryImage;
@interface SBIconBadgeView : UIView <SBIconAccessoryView>
{
NSString *_text;
SBDarkeningImageView *_incomingTextView;
_Bool _animating;
CDUnknownBlockType _queuedAnimation;
_Bool _displayingAccessory;
SBIconAccessoryImage *_backgroundImage;
SBDarkeningImageView *_backgroundView;
SBIconAccessoryImage *_textImage;
SBDarkeningImageView *_textView;
}
+ (id)_createImageForText:(id)arg1 highlighted:(_Bool)arg2;
+ (id)_checkoutImageForText:(id)arg1 highlighted:(_Bool)arg2;
+ (id)_checkoutBackgroundImage;
+ (id)checkoutAccessoryImagesForIcon:(id)arg1 location:(int)arg2;
+ (struct CGPoint)_overhang;
+ (double)_textPadding;
+ (struct CGPoint)_textOffset;
+ (double)_maxTextWidth;
+ (id)_textFont;
- (void)_resizeForTextImage:(id)arg1;
- (void)_clearText;
- (void)_zoomOutWithPreparation:(CDUnknownBlockType)arg1 animation:(CDUnknownBlockType)arg2 completion:(CDUnknownBlockType)arg3;
- (void)_zoomInWithTextImage:(id)arg1 preparation:(CDUnknownBlockType)arg2 animation:(CDUnknownBlockType)arg3 completion:(CDUnknownBlockType)arg4;
- (void)_crossfadeToTextImage:(id)arg1 withPreparation:(CDUnknownBlockType)arg2 animation:(CDUnknownBlockType)arg3 completion:(CDUnknownBlockType)arg4;
- (void)_configureAnimatedForText:(id)arg1 highlighted:(_Bool)arg2 withPreparation:(CDUnknownBlockType)arg3 animation:(CDUnknownBlockType)arg4 completion:(CDUnknownBlockType)arg5;
- (void)setAccessoryBrightness:(double)arg1;
- (struct CGPoint)accessoryOriginForIconBounds:(struct CGRect)arg1;
- (void)prepareForReuse;
- (_Bool)displayingAccessory;
- (void)configureForIcon:(id)arg1 location:(int)arg2 highlighted:(_Bool)arg3;
- (void)configureAnimatedForIcon:(id)arg1 location:(int)arg2 highlighted:(_Bool)arg3 withPreparation:(CDUnknownBlockType)arg4 animation:(CDUnknownBlockType)arg5 completion:(CDUnknownBlockType)arg6;
- (void)layoutSubviews;
- (void)dealloc;
- (id)init;
// Remaining properties
@property(readonly, copy) NSString *debugDescription;
@property(readonly, copy) NSString *description;
@property(readonly) unsigned long long hash;
@property(readonly) Class superclass;
@end
|
#ifndef TheaMaterialOverride_H
#define TheaMaterialOverride_H
//-
// ===========================================================================
// Copyright 2012 Autodesk, Inc. All rights reserved.
//
// Use of this software is subject to the terms of the Autodesk license
// agreement provided at the time of installation or download, or which
// otherwise accompanies this software in either electronic or hard copy form.
// ===========================================================================
//+
//
// This is the MPxSurfaceShadingNodeOverride implementation to go along with
// the node defined in TheaMaterial.cpp. This provides draw support in
// Viewport 2.0.
//
#include <maya/MPxSurfaceShadingNodeOverride.h>
class TheaMaterialOverride : public MHWRender::MPxSurfaceShadingNodeOverride
{
public:
static MHWRender::MPxSurfaceShadingNodeOverride* creator(const MObject& obj);
virtual ~TheaMaterialOverride();
virtual MHWRender::DrawAPI supportedDrawAPIs() const;
virtual MString fragmentName() const;
virtual void getCustomMappings(
MHWRender::MAttributeParameterMappingList& mappings);
virtual MString primaryColorParameter() const;
virtual MString transparencyParameter() const;
virtual MString bumpAttribute() const;
private:
TheaMaterialOverride(const MObject& obj);
};
#endif // _TheaMaterialOverride
|
//
// CocoaPodsWarehouse.h
// SecondApp
//
// Created by qianfeng01 on 15-8-4.
// Copyright (c) 2015年 zg. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface CocoaPodsWarehouse : NSObject
@end
|
//
// Created by ron on 16/09/17.
//
#ifndef FORTUNA_LINUX_INTEGERTASK_H
#define FORTUNA_LINUX_INTEGERTASK_H
#include "ITask.h"
// Create Fortuna with All Integer Sources
// This class is used for testing, to determine how the sources are mixed together
// when the source bytes are copied to the Pools when each source is a fixed integer
// This class is used to determine how much 'mixing' there is of the source data
// being sent to each Pool because the Sources and Pools are all on separate threads
class IntegerTask : public ITask
{
public:
IntegerTask();
~IntegerTask();
virtual bool RunTask();
static ITask* Create() { return new IntegerTask();}
private:
};
#endif //FORTUNA_LINUX_INTEGERTASK_H
|
/**
@file SrRenderContext.h
@author yikaiming
ver:1.0
*/
#ifndef SrRenderContext_h__
#define SrRenderContext_h__
#include <thread>
class SrFragmentBuffer;
SR_ALIGN struct SrRendContext
{
SrRendContext(int w, int h, int obpp)
{
memset(this, 0, sizeof(SrRendContext));
width = w;
height = h;
bpp = obpp / 8;
viewport = SrViewport(0.f,0.f,(float)width,(float)height,1.f,1000.f);
processorNum = 8;
// use std thread in c++11
unsigned concurentThreadsSupported = std::thread::hardware_concurrency();
if(concurentThreadsSupported != 0)
{
processorNum = concurentThreadsSupported;
}
}
void OpenFeature( ERenderFeature feature )
{
features |= feature;
}
void CloseFeature( ERenderFeature feature )
{
features &= ~feature;
}
bool IsFeatureEnable( ERenderFeature feature )
{
return features & feature;
}
uint32 width;
uint32 height;
SrViewport viewport;
int bpp;
uint32 features;
int processorNum;
SrFragmentBuffer* fBuffer; ///< FragBuffer
};
extern SrRendContext* g_context;
#endif
|
#pragma once
#include <mtao/types.h>
namespace mtao { namespace geometry { namespace mesh {
template <int D, typename IndexType = int>
struct CellIndexer {
public:
template <typename Derived>
std::array<IndexType,D> sorted_facet(const Eigen::DenseBase<Derived>& f) const {
std::array<IndexType,D> ret;
for(IndexType i = 0; i < D; ++i) {
ret[i] = f(i);
}
std::sort(ret.begin(),ret.end());
return ret;
}
CellIndexer(const mtao::ColVectors<IndexType,D>& F) {
for(IndexType i = 0; i < F.cols(); ++i) {
m_map[sorted_facet(F.col(i))] = i;
}
}
template <typename Derived>
IndexType operator()(const Eigen::DenseBase<Derived>& f) const {
return (*this)(sorted_fact(f));
}
IndexType operator()(std::array<IndexType,D> f) const {
std::sort(f.begin(),f.end());
return m_map.at(f);
}
const auto& map() const { return m_map; }
private:
std::map<std::array<IndexType,D>,IndexType> m_map;
};
}}}
|
/*
* Copyright 2010-2013 Amazon.com, Inc. or its affiliates. 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.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file accompanying this file. This file 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.
*/
/**
* Provisioned Throughput
*/
@interface DynamoDBProvisionedThroughput:NSObject
{
NSNumber *readCapacityUnits;
NSNumber *writeCapacityUnits;
}
/**
* Default constructor for a new object. Callers should use the
* property methods to initialize this object after creating it.
*/
-(id)init;
/**
* The maximum number of strongly consistent reads consumed per second
* before Amazon DynamoDB returns a <i>ThrottlingException</i>. For more
* information, see <a
* eloperguide/WorkingWithDDTables.html#ProvisionedThroughput">Specifying
* Read and Write Requirements</a> of the <i>Amazon DynamoDB Developer
* Guide</i>.
* <p>
* <b>Constraints:</b><br/>
* <b>Range: </b>1 - <br/>
*/
@property (nonatomic, retain) NSNumber *readCapacityUnits;
/**
* The maximum number of writes consumed per second before Amazon
* DynamoDB returns a <i>ThrottlingException</i>. For more information,
* see <a
* eloperguide/WorkingWithDDTables.html#ProvisionedThroughput">Specifying
* Read and Write Requirements</a> of the <i>Amazon DynamoDB Developer
* Guide</i>.
* <p>
* <b>Constraints:</b><br/>
* <b>Range: </b>1 - <br/>
*/
@property (nonatomic, retain) NSNumber *writeCapacityUnits;
/**
* Returns a string representation of this object; useful for testing and
* debugging.
*
* @return A string representation of this object.
*/
-(NSString *)description;
@end
|
#ifdef HAVE_CONFIG_H
#include "../../../../ext_config.h"
#endif
#include <php.h>
#include "../../../../php_ext.h"
#include "../../../../ext.h"
#include <Zend/zend_exceptions.h>
#include "kernel/main.h"
/*
This file is part of the php-ext-zendframework package.
For the full copyright and license information, please view the LICENSE
file that was distributed with this source code.
*/
/**
* Exception class for Zend\ProgressBar\Adapter
*/
ZEPHIR_INIT_CLASS(ZendFramework_ProgressBar_Adapter_Exception_ExceptionInterface) {
ZEPHIR_REGISTER_INTERFACE(Zend\\ProgressBar\\Adapter\\Exception, ExceptionInterface, zendframework, progressbar_adapter_exception_exceptioninterface, NULL);
zend_class_implements(zendframework_progressbar_adapter_exception_exceptioninterface_ce TSRMLS_CC, 1, zendframework_progressbar_exception_exceptioninterface_ce);
return SUCCESS;
}
|
#ifndef _UBER_LIBRARY_EXAMPLE
#define _UBER_LIBRARY_EXAMPLE
// Make library cross-compatiable
// with Arduino, GNU C++ for tests, and Particle.
//#if defined(ARDUINO) && ARDUINO >= 100
//#include "Arduino.h"
//#elif defined(SPARK)
//#include "application.h"
//#endif
// TEMPORARY UNTIL the stuff that supports the code above is deployed to the build IDE
#include "application.h"
namespace UberLibraryExample
{
class Pin
{
private:
int number;
int mode;
bool state;
public:
Pin(int _number);
void beginInPinMode(PinMode _pinMode);
void modulateAtFrequency(int _ms);
int getNumber();
bool getState();
bool getMode();
bool isHigh();
void setHigh();
void setLow();
void setActualPinState();
};
}
#endif
|
/*******************************************************************************
SPI Peripheral Library Template Implementation
File Name:
spi_FrameSyncPulseEdge_Default.h
Summary:
SPI PLIB Template Implementation
Description:
This header file contains template implementations
For Feature : FrameSyncPulseEdge
and its Variant : Default
For following APIs :
PLIB_SPI_FrameSyncPulseEdgeSelect
PLIB_SPI_ExistsFrameSyncPulseEdge
*******************************************************************************/
//DOM-IGNORE-BEGIN
/*******************************************************************************
Copyright (c) 2013 released Microchip Technology Inc. All rights reserved.
Microchip licenses to you the right to use, modify, copy and distribute
Software only when embedded on a Microchip microcontroller or digital signal
controller that is integrated into your product or third party product
(pursuant to the sublicense terms in the accompanying license agreement).
You should refer to the license agreement accompanying this Software for
additional information regarding your rights and obligations.
SOFTWARE AND DOCUMENTATION ARE PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND,
EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF
MERCHANTABILITY, TITLE, NON-INFRINGEMENT AND FITNESS FOR A PARTICULAR PURPOSE.
IN NO EVENT SHALL MICROCHIP OR ITS LICENSORS BE LIABLE OR OBLIGATED UNDER
CONTRACT, NEGLIGENCE, STRICT LIABILITY, CONTRIBUTION, BREACH OF WARRANTY, OR
OTHER LEGAL EQUITABLE THEORY ANY DIRECT OR INDIRECT DAMAGES OR EXPENSES
INCLUDING BUT NOT LIMITED TO ANY INCIDENTAL, SPECIAL, INDIRECT, PUNITIVE OR
CONSEQUENTIAL DAMAGES, LOST PROFITS OR LOST DATA, COST OF PROCUREMENT OF
SUBSTITUTE GOODS, TECHNOLOGY, SERVICES, OR ANY CLAIMS BY THIRD PARTIES
(INCLUDING BUT NOT LIMITED TO ANY DEFENSE THEREOF), OR OTHER SIMILAR COSTS.
*******************************************************************************/
//DOM-IGNORE-END
#ifndef _SPI_FRAMESYNCPULSEEDGE_DEFAULT_H
#define _SPI_FRAMESYNCPULSEEDGE_DEFAULT_H
#include "spi_registers.h"
//******************************************************************************
/* Function : SPI_FrameSyncPulseEdgeSelect_Default
Summary:
Implements Default variant of PLIB_SPI_FrameSyncPulseEdgeSelect
Description:
This template implements the Default variant of the PLIB_SPI_FrameSyncPulseEdgeSelect function.
*/
PLIB_TEMPLATE void SPI_FrameSyncPulseEdgeSelect_Default( SPI_MODULE_ID index , SPI_FRAME_PULSE_EDGE edge )
{
spi_registers_t volatile * spi = ((spi_registers_t *)(index));
spi->SPIxCON.SPIFE = edge;
}
//******************************************************************************
/* Function : SPI_ExistsFrameSyncPulseEdge_Default
Summary:
Implements Default variant of PLIB_SPI_ExistsFrameSyncPulseEdge
Description:
This template implements the Default variant of the PLIB_SPI_ExistsFrameSyncPulseEdge function.
*/
#define PLIB_SPI_ExistsFrameSyncPulseEdge PLIB_SPI_ExistsFrameSyncPulseEdge
PLIB_TEMPLATE bool SPI_ExistsFrameSyncPulseEdge_Default( SPI_MODULE_ID index )
{
return true;
}
#endif /*_SPI_FRAMESYNCPULSEEDGE_DEFAULT_H*/
/******************************************************************************
End of File
*/
|
// To check if a library is compiled with CocoaPods you
// can use the `COCOAPODS` macro definition which is
// defined in the xcconfigs so it is available in
// headers also when they are imported in the client
// project.
// Facebook-iOS-SDK
#define COCOAPODS_POD_AVAILABLE_Facebook_iOS_SDK
#define COCOAPODS_VERSION_MAJOR_Facebook_iOS_SDK 3
#define COCOAPODS_VERSION_MINOR_Facebook_iOS_SDK 9
#define COCOAPODS_VERSION_PATCH_Facebook_iOS_SDK 0
// LUKeychainAccess
#define COCOAPODS_POD_AVAILABLE_LUKeychainAccess
#define COCOAPODS_VERSION_MAJOR_LUKeychainAccess 1
#define COCOAPODS_VERSION_MINOR_LUKeychainAccess 2
#define COCOAPODS_VERSION_PATCH_LUKeychainAccess 0
// SHActionSheetBlocks
#define COCOAPODS_POD_AVAILABLE_SHActionSheetBlocks
#define COCOAPODS_VERSION_MAJOR_SHActionSheetBlocks 2
#define COCOAPODS_VERSION_MINOR_SHActionSheetBlocks 2
#define COCOAPODS_VERSION_PATCH_SHActionSheetBlocks 0
// SHAlertViewBlocks
#define COCOAPODS_POD_AVAILABLE_SHAlertViewBlocks
#define COCOAPODS_VERSION_MAJOR_SHAlertViewBlocks 1
#define COCOAPODS_VERSION_MINOR_SHAlertViewBlocks 1
#define COCOAPODS_VERSION_PATCH_SHAlertViewBlocks 0
// SHFastEnumerationProtocols
#define COCOAPODS_POD_AVAILABLE_SHFastEnumerationProtocols
#define COCOAPODS_VERSION_MAJOR_SHFastEnumerationProtocols 1
#define COCOAPODS_VERSION_MINOR_SHFastEnumerationProtocols 3
#define COCOAPODS_VERSION_PATCH_SHFastEnumerationProtocols 0
// SHOmniAuth
#define COCOAPODS_POD_AVAILABLE_SHOmniAuth
#define COCOAPODS_VERSION_MAJOR_SHOmniAuth 0
#define COCOAPODS_VERSION_MINOR_SHOmniAuth 2
#define COCOAPODS_VERSION_PATCH_SHOmniAuth 1
// SHOmniAuthFacebook
#define COCOAPODS_POD_AVAILABLE_SHOmniAuthFacebook
#define COCOAPODS_VERSION_MAJOR_SHOmniAuthFacebook 0
#define COCOAPODS_VERSION_MINOR_SHOmniAuthFacebook 2
#define COCOAPODS_VERSION_PATCH_SHOmniAuthFacebook 2
|
//
// ShapedImageView.h
// Boobuz
//
// Created by songmeng on 16/8/11.
// Copyright © 2016年 erlinyou.com. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface ShapedImageView : UIView
@property (nonatomic, strong) UIImage * image;
@property (nonatomic, copy) void(^removeMessage)();
- (instancetype)initWithDirectionRight:(BOOL)right;
@end
|
// This file was generated based on 'C:\ProgramData\Uno\Packages\UnoCore\0.13.2\Source\Uno\$.uno'.
// WARNING: Changes might be lost if you edit this file directly.
#ifndef __APP_UNO_COMPARISON__FUSE_STYLE_PROPERTY_H__
#define __APP_UNO_COMPARISON__FUSE_STYLE_PROPERTY_H__
#include <app/Uno.Delegate.h>
#include <Uno.h>
namespace app {
namespace Uno {
::uDelegateType* Comparison__Fuse_StyleProperty__typeof();
}}
#endif
|
/*
* IRremote
* Version 0.1 July, 2009
* Copyright 2009 Ken Shirriff
* For details, see http://arcfn.com/2009/08/multi-protocol-infrared-remote-library.htm http://arcfn.com
* Edited by Mitra to add new controller SANYO
*
* Interrupt code based on NECIRrcv by Joe Knapp
* http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1210243556
* Also influenced by http://zovirl.com/2008/11/12/building-a-universal-remote-with-an-arduino/
*
* JVC and Panasonic protocol added by Kristian Lauszus (Thanks to zenwheel and other people at the original blog post)
* LG added by Darryl Smith (based on the JVC protocol)
*/
#ifndef IR_h
#define IR_h
// The following are compile-time library options.
// If you change them, recompile the library.
// If DEBUG is defined, a lot of debugging output will be printed during decoding.
// TEST must be defined for the IRtest unittests to work. It will make some
// methods virtual, which will be slightly slower, which is why it is optional.
// #define DEBUG
// #define TEST
// Results returned from the decoder
class decode_results {
public:
int decode_type; // NEC, SONY, RC5, UNKNOWN
union { // This is used for decoding Panasonic and Sharp data
unsigned int panasonicAddress;
unsigned int sharpAddress;
};
unsigned long value; // Decoded value
int bits; // Number of bits in decoded value
volatile unsigned int *rawbuf; // Raw intervals in .5 us ticks
int rawlen; // Number of records in rawbuf.
};
// Values for decode_type
#define NEC 1
#define SONY 2
#define RC5 3
#define RC6 4
#define DISH 5
#define SHARP 6
#define PANASONIC 7
#define JVC 8
#define SANYO 9
#define MITSUBISHI 10
#define SAMSUNG 11
#define LG 12
#define UNKNOWN -1
// Decoded value for NEC when a repeat code is received
#define REPEAT 0xffffffff
// main class for receiving IR
class IRrecv
{
public:
IRrecv(int recvpin);
void blink13(int blinkflag);
int decode(decode_results *results);
void enableIRIn();
void resume();
private:
// These are called by decode
int getRClevel(decode_results *results, int *offset, int *used, int t1);
long decodeNEC(decode_results *results);
long decodeSony(decode_results *results);
long decodeSanyo(decode_results *results);
long decodeMitsubishi(decode_results *results);
long decodeRC5(decode_results *results);
long decodeRC6(decode_results *results);
long decodePanasonic(decode_results *results);
long decodeLG(decode_results *results);
long decodeJVC(decode_results *results);
long decodeSAMSUNG(decode_results *results);
long decodeHash(decode_results *results);
int compare(unsigned int oldval, unsigned int newval);
}
;
// Only used for testing; can remove virtual for shorter code
#ifdef TEST
#define VIRTUAL virtual
#else
#define VIRTUAL
#endif
class IRsend
{
public:
IRsend() {}
void sendNEC(unsigned long data, int nbits);
void sendSony(unsigned long data, int nbits);
// Neither Sanyo nor Mitsubishi send is implemented yet
// void sendSanyo(unsigned long data, int nbits);
// void sendMitsubishi(unsigned long data, int nbits);
void sendRaw(unsigned int buf[], int len, int hz);
void sendRC5(unsigned long data, int nbits);
void sendRC6(unsigned long data, int nbits);
void sendDISH(unsigned long data, int nbits);
void sendSharp(unsigned int address, unsigned int command);
void sendSharpRaw(unsigned long data, int nbits);
void sendPanasonic(unsigned int address, unsigned long data);
void sendJVC(unsigned long data, int nbits, int repeat); // *Note instead of sending the REPEAT constant if you want the JVC repeat signal sent, send the original code value and change the repeat argument from 0 to 1. JVC protocol repeats by skipping the header NOT by sending a separate code value like NEC does.
// private:
void sendSAMSUNG(unsigned long data, int nbits);
void enableIROut(int khz);
VIRTUAL void mark(int usec);
VIRTUAL void space(int usec);
}
;
// Some useful constants
#define USECPERTICK 50 // microseconds per clock interrupt tick
#define RAWBUF 100 // Length of raw duration buffer
// Marks tend to be 100us too long, and spaces 100us too short
// when received due to sensor lag.
#define MARK_EXCESS 100
#endif
|
//
// Copyright (c) 2006 - 2021 Stephen F. Booth <me@sbooth.org>
// Part of https://github.com/sbooth/SFBAudioEngine
// MIT license
//
#import "SFBAudioFile+Internal.h"
// An SFBAudioFile subclass supporting Musepack files
@interface SFBMusepackFile : SFBAudioFile
@end
|
//
// GCIPAssetGridCell.h
//
// Copyright (c) 2011-2012 Caleb Davenport.
//
#import <UIKit/UIKit.h>
@class GCIPAssetView;
// cell designed to display a grid of assets
@interface GCIPAssetGridCell : UITableViewCell
// number of columns for the cell to display
@property (nonatomic, assign) NSUInteger numberOfColumns;
// set assets to display and pass a set of selected asset urls
- (void)setAssets:(NSArray *)assets selected:(NSSet *)selected;
// get the asset view at the given column
- (GCIPAssetView *)assetViewAtColumn:(NSUInteger)column;
@end
|
#ifndef KEYBOARD_H
#define KEYBOARD_H
#include "Arduino.h"
class Keyboard {
public:
Keyboard();
void init();
void run();
uint32_t data;
bool isAvailable;
};
#endif
|
//
// BRSendViewController.h
// DashWallet
//
// Created by Aaron Voisine on 5/8/13.
// Copyright (c) 2013 Aaron Voisine <voisine@gmail.com>
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
#import <UIKit/UIKit.h>
#import <AVFoundation/AVFoundation.h>
#import "BRAmountViewController.h"
@interface BRSendViewController : UIViewController <UIAlertViewDelegate, UITextViewDelegate,
BRAmountViewControllerDelegate, AVCaptureMetadataOutputObjectsDelegate, UIViewControllerTransitioningDelegate,
UIViewControllerAnimatedTransitioning>
- (IBAction)tip:(id)sender;
- (void)handleURL:(NSURL *)url;
- (void)handleFile:(NSData *)file;
- (void)updateClipboardText;
@end
|
/*
* Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the file PATENTS. All contributing project authors may
* be found in the AUTHORS file in the root of the source tree.
*/
#ifndef MODULES_VIDEO_CODING_INTERNAL_DEFINES_H_
#define MODULES_VIDEO_CODING_INTERNAL_DEFINES_H_
namespace webrtc {
#define MASK_32_BITS(x) (0xFFFFFFFF & (x))
inline uint32_t MaskWord64ToUWord32(int64_t w64) {
return static_cast<uint32_t>(MASK_32_BITS(w64));
}
#define VCM_MAX(a, b) (((a) > (b)) ? (a) : (b))
#define VCM_MIN(a, b) (((a) < (b)) ? (a) : (b))
#define VCM_DEFAULT_CODEC_WIDTH 352
#define VCM_DEFAULT_CODEC_HEIGHT 288
#define VCM_DEFAULT_FRAME_RATE 30
#define VCM_MIN_BITRATE 30
#define VCM_FLUSH_INDICATOR 4
#define VCM_NO_RECEIVER_ID 0
inline int32_t VCMId(const int32_t vcmId, const int32_t receiverId = 0) {
return static_cast<int32_t>((vcmId << 16) + receiverId);
}
} // namespace webrtc
#endif // MODULES_VIDEO_CODING_INTERNAL_DEFINES_H_
|
/* Daniel Perry
* for cs6620 - spring 2005
* started 27jan05
*/
/* Background: superclass for different types of backgrounds
*
* direct subclasses: ConstantBackground, GradientBackground, StarfieldBackground, EnvironmentMapBackground.
*
*/
#ifndef _BACKGROUND_H
#define _BACKGROUND_H
using namespace std;
class RenderContext;
//#include "RenderContext.h"
#include "ray.h"
#include "rgb.h"
class Background{
public:
virtual void preprocess()=0;
virtual void getBackgroundColor( rgb & result, const RenderContext & context, const ray & r ) = 0;
};
#endif
|
#include <stdbool.h>
#include "md22DeviceInterface.h"
#include "../../device/device.h"
#include "../../device/deviceInterface.h"
#include "../../device/deviceConstants.h"
const char* getMD22MotorDeviceName(void) {
return "MD22_MOTOR";
}
int deviceMD22GetInterface(unsigned char header, DeviceInterfaceMode mode, bool fillDeviceArgumentList) {
if (header == COMMAND_MD22_MOVE) {
if (fillDeviceArgumentList) {
setFunction("runMotor", 2, 0);
setArgumentSignedHex2(0, "left");
setArgumentSignedHex2(1, "right");
}
return commandLengthValueForMode(mode, 4, 0);
} else if (header == COMMAND_MD22_READ_VALUE) {
if (fillDeviceArgumentList) {
setFunction("readMotorValue", 0, 2);
setResultSignedHex2(0, "left");
setResultSignedHex2(1, "right");
}
return commandLengthValueForMode(mode, 0, 4);
} else if (header == COMMAND_MD22_STOP) {
if (fillDeviceArgumentList) {
setFunctionNoArgumentAndNoResult("stopMotor");
}
return commandLengthValueForMode(mode, 0, 0);
} else if (header == COMMAND_MD22_SOFTWARE_REVISION) {
if (fillDeviceArgumentList) {
setFunction("Software revision", 0, 1);
setResultUnsignedHex2(0, "Software revision");
}
return commandLengthValueForMode(mode, 0, 2);
}
return DEVICE_HEADER_NOT_HANDLED;
}
static DeviceInterface deviceInterface = {
.deviceHeader = MD22_DEVICE_HEADER,
.deviceGetName = &getMD22MotorDeviceName,
.deviceGetInterface = &deviceMD22GetInterface
};
DeviceInterface* getMD22DeviceInterface(void) {
return &deviceInterface;
}
|
/* TEMPLATE GENERATED TESTCASE FILE
Filename: CWE789_Uncontrolled_Mem_Alloc__malloc_wchar_t_listen_socket_61a.c
Label Definition File: CWE789_Uncontrolled_Mem_Alloc__malloc.label.xml
Template File: sources-sinks-61a.tmpl.c
*/
/*
* @description
* CWE: 789 Uncontrolled Memory Allocation
* BadSource: listen_socket Read data using a listen socket (server side)
* GoodSource: Small number greater than zero
* Sinks:
* GoodSink: Allocate memory with malloc() and check the size of the memory to be allocated
* BadSink : Allocate memory with malloc(), but incorrectly check the size of the memory to be allocated
* Flow Variant: 61 Data flow: data returned from one function to another in different source files
*
* */
#include "std_testcase.h"
#ifndef _WIN32
#include <wchar.h>
#endif
#ifdef _WIN32
#include <winsock2.h>
#include <windows.h>
#include <direct.h>
#pragma comment(lib, "ws2_32") /* include ws2_32.lib when linking */
#define CLOSE_SOCKET closesocket
#else
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
#include <unistd.h>
#define INVALID_SOCKET -1
#define SOCKET_ERROR -1
#define CLOSE_SOCKET close
#define SOCKET int
#endif
#define TCP_PORT 27015
#define LISTEN_BACKLOG 5
#define CHAR_ARRAY_SIZE (3 * sizeof(data) + 2)
#define HELLO_STRING L"hello"
#ifndef OMITBAD
/* bad function declaration */
size_t CWE789_Uncontrolled_Mem_Alloc__malloc_wchar_t_listen_socket_61b_badSource(size_t data);
void CWE789_Uncontrolled_Mem_Alloc__malloc_wchar_t_listen_socket_61_bad()
{
size_t data;
/* Initialize data */
data = 0;
data = CWE789_Uncontrolled_Mem_Alloc__malloc_wchar_t_listen_socket_61b_badSource(data);
{
wchar_t * myString;
/* POTENTIAL FLAW: No MAXIMUM limitation for memory allocation, but ensure data is large enough
* for the wcscpy() function to not cause a buffer overflow */
/* INCIDENTAL FLAW: The source could cause a type overrun in data or in the memory allocation */
if (data > wcslen(HELLO_STRING))
{
myString = (wchar_t *)malloc(data*sizeof(wchar_t));
/* Copy a small string into myString */
wcscpy(myString, HELLO_STRING);
printWLine(myString);
free(myString);
}
else
{
printLine("Input is less than the length of the source string");
}
}
}
#endif /* OMITBAD */
#ifndef OMITGOOD
/* goodG2B uses the GoodSource with the BadSink */
size_t CWE789_Uncontrolled_Mem_Alloc__malloc_wchar_t_listen_socket_61b_goodG2BSource(size_t data);
static void goodG2B()
{
size_t data;
/* Initialize data */
data = 0;
data = CWE789_Uncontrolled_Mem_Alloc__malloc_wchar_t_listen_socket_61b_goodG2BSource(data);
{
wchar_t * myString;
/* POTENTIAL FLAW: No MAXIMUM limitation for memory allocation, but ensure data is large enough
* for the wcscpy() function to not cause a buffer overflow */
/* INCIDENTAL FLAW: The source could cause a type overrun in data or in the memory allocation */
if (data > wcslen(HELLO_STRING))
{
myString = (wchar_t *)malloc(data*sizeof(wchar_t));
/* Copy a small string into myString */
wcscpy(myString, HELLO_STRING);
printWLine(myString);
free(myString);
}
else
{
printLine("Input is less than the length of the source string");
}
}
}
/* goodB2G uses the BadSource with the GoodSink */
size_t CWE789_Uncontrolled_Mem_Alloc__malloc_wchar_t_listen_socket_61b_goodB2GSource(size_t data);
static void goodB2G()
{
size_t data;
/* Initialize data */
data = 0;
data = CWE789_Uncontrolled_Mem_Alloc__malloc_wchar_t_listen_socket_61b_goodB2GSource(data);
{
wchar_t * myString;
/* FIX: Include a MAXIMUM limitation for memory allocation and a check to ensure data is large enough
* for the wcscpy() function to not cause a buffer overflow */
/* INCIDENTAL FLAW: The source could cause a type overrun in data or in the memory allocation */
if (data > wcslen(HELLO_STRING) && data < 100)
{
myString = (wchar_t *)malloc(data*sizeof(wchar_t));
/* Copy a small string into myString */
wcscpy(myString, HELLO_STRING);
printWLine(myString);
free(myString);
}
else
{
printLine("Input is less than the length of the source string or too large");
}
}
}
void CWE789_Uncontrolled_Mem_Alloc__malloc_wchar_t_listen_socket_61_good()
{
goodG2B();
goodB2G();
}
#endif /* OMITGOOD */
/* Below is the main(). It is only used when building this testcase on
its own for testing or for building a binary to use in testing binary
analysis tools. It is not used when compiling all the testcases as one
application, which is how source code analysis tools are tested. */
#ifdef INCLUDEMAIN
int main(int argc, char * argv[])
{
/* seed randomness */
srand( (unsigned)time(NULL) );
#ifndef OMITGOOD
printLine("Calling good()...");
CWE789_Uncontrolled_Mem_Alloc__malloc_wchar_t_listen_socket_61_good();
printLine("Finished good()");
#endif /* OMITGOOD */
#ifndef OMITBAD
printLine("Calling bad()...");
CWE789_Uncontrolled_Mem_Alloc__malloc_wchar_t_listen_socket_61_bad();
printLine("Finished bad()");
#endif /* OMITBAD */
return 0;
}
#endif
|
//
// JKHomeTopItem.h
// 美团HD
//
// Created by 谢聪捷 on 3/10/15.
// Copyright (c) 2015 Jack-Xie. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface JKHomeTopItem : UIView
+ (instancetype)item;
// 标题
- (void)setTitle:(NSString *)title;
// 子标题
- (void)setSubtitle:(NSString *)subtitle;
// 设置普通 / 高亮图片
- (void)setIcon:(NSString *)icon highIcon:(NSString *)highIcon;
// 按钮点击事件
- (void)addTarget:(id)target action:(SEL)action;
@end
|
//
// AppDelegate.h
// TimAFAppConnectClient
//
// Created by tim on 16/11/17.
// Copyright © 2016年 timRabbit. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface AppDelegate : UIResponder <UIApplicationDelegate>
@property (strong, nonatomic) UIWindow *window;
@end
|
/*
* Generated by class-dump 3.3.4 (64 bit).
*
* class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2011 by Steve Nygard.
*/
#import "WebSecurityOrigin.h"
@interface WebSecurityOrigin (SafariExtras)
- (id)safari_userVisibleName;
@end
|
//
// MPIMotionManager.h
// Multipeer.Instrument
//
// Created by Kyle Beyer on 7/2/14.
// Copyright (c) 2014 Kyle Beyer. All rights reserved.
//
#import <Foundation/Foundation.h>
@protocol MPIMotionManagerDelegate;
@interface MPIMotionManager : NSObject
+ (MPIMotionManager*)instance;
@property (nonatomic,weak) id<MPIMotionManagerDelegate> delegate;
-(void)start;
-(void)stop;
@end
// Delegate methods for motion manager
@protocol MPIMotionManagerDelegate <NSObject>
- (void)attitudeChanged:(float)yaw pitch:(float)pitch roll:(float)roll;
- (void)rotationChanged:(float)x y:(float)y z:(float)z;
@end
|
#include <string.h>
#include "shared.h"
int main(int argc, char **argv)
{
if (argc > 1 && strcmp("-s", argv[1]) == 0) {
server_main();
} else {
client_main(argc, argv);
}
return 0;
}
|
#ifndef OPTIONSMODEL_H
#define OPTIONSMODEL_H
#include <QAbstractListModel>
/** Interface from Qt to configuration data structure for Bitcoin client.
To Qt, the options are presented as a list with the different options
laid out vertically.
This can be changed to a tree once the settings become sufficiently
complex.
*/
class OptionsModel : public QAbstractListModel
{
Q_OBJECT
public:
explicit OptionsModel(QObject *parent = 0);
enum OptionID {
StartAtStartup, // bool
MinimizeToTray, // bool
MapPortUPnP, // bool
MinimizeOnClose, // bool
ProxyUse, // bool
ProxyIP, // QString
ProxyPort, // int
ProxySocksVersion, // int
Fee, // qint64
DisplayUnit, // BitcoinUnits::Unit
DisplayAddresses, // bool
Language, // QString
OptionIDRowCount,
};
void Init();
void Reset();
/* Migrate settings from wallet.dat after app initialization */
bool Upgrade(); /* returns true if settings upgraded */
int rowCount(const QModelIndex & parent = QModelIndex()) const;
QVariant data(const QModelIndex & index, int role = Qt::DisplayRole) const;
bool setData(const QModelIndex & index, const QVariant & value, int role = Qt::EditRole);
/* Explicit getters */
qint64 getTransactionFee();
bool getMinimizeToTray() { return fMinimizeToTray; }
bool getMinimizeOnClose() { return fMinimizeOnClose; }
int getDisplayUnit() { return nDisplayUnit; }
bool getDisplayAddresses() { return bDisplayAddresses; }
QString getLanguage() { return language; }
private:
int nDisplayUnit;
bool bDisplayAddresses;
bool fMinimizeToTray;
bool fMinimizeOnClose;
QString language;
signals:
void displayUnitChanged(int unit);
};
#endif // OPTIONSMODEL_H
|
//
// Generated by class-dump 3.5 (64 bit).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by Steve Nygard.
//
#import "NSObject.h"
@class DVTDispatchLock, NSMutableDictionary;
@interface IDEIndexProductInfoManager : NSObject
{
DVTDispatchLock *_lock;
NSMutableDictionary *_productInfos;
id _productInfoRegisteredObserver;
id _productInfoUpdatedObserver;
id _productInfoUnregisteredObserver;
}
+ (id)sharedManager;
+ (void)initialize;
- (void).cxx_destruct;
- (void)informSourceKit:(struct sourcekitd_uid_s *)arg1 productInfo:(id)arg2 productBlock:(CDUnknownBlockType)arg3;
- (void)reregisterProductInfo:(id)arg1 settings:(id)arg2;
- (void)reregisterAllProductInfos;
- (void)unregisterProductInfo:(id)arg1;
- (void)updateProductInfo:(id)arg1;
- (void)registerProductInfo:(id)arg1;
- (void)requestBuildSettingsForProduct:(id)arg1;
- (void)dealloc;
- (id)init;
@end
|
//
// KMYBlock.h
// KMYKit
//
// Created on 29/03/16.
// Copyright © 2016 Karmeye. All rights reserved.
//
@import Foundation;
#import <KMYKit/KMYDispatch.h>
#import <KMYKit/KMYAssert.h>
///
/// See Checking For Null Blocks: http://nshipster.com/new-years-2016/
///
#define KMYInvokeBlockIfSet(block, ...) if (block) { block(__VA_ARGS__); };
#define KMYInvokeBlockAsyncOnQueueIfSet(queue, block, ...) if (block) { KMYAssert(queue != NULL); dispatch_async(queue, ^{ block(__VA_ARGS__); }); };
#define KMYInvokeBlockAsyncOnMainQueueIfSet(block, ...) if (block) { dispatch_async(dispatch_get_main_queue(), ^{ block(__VA_ARGS__); }); };
|
// *********************************************************************
// ____ _____ ____
// / ___| _ __ ___ _ __ ___|___ /| _ \
// \___ \| '_ \ / _ \| '__/ _ \ |_ \| | | |
// ___) | |_) | (_) | | | __/___) | |_| |
// |____/| .__/ \___/|_| \___|____/|____/
// |_|
//
// Spore3D
// -- High performance , Lightweight 3D Game Engine
// -- github.com/pgdnxu/Spore3D
// --------------------------------------------------------------------
//
// Copyright (C) 2016 Shannon Xu
//
// This software is distributed under the terms of the MIT License.
// A copy of the license may be obtained at: https://opensource.org/licenses/MIT
//
// .--. --. -.. -. .. -. ..-. --.-. --. -- .- .. .-.. .-.-.- -.-. --- --
#ifndef _cCamera_h_
#define _cCamera_h_
#include <vector>
#include "cBehaviour.h"
#include "uTypes.h"
#include "cColor.h"
#include "uMath.h"
namespace Spore3D {
const std::string CAMERA_TYPE_NAME = "Camera";
enum CameraClearFlags {
Skybox,
SolidColor,
Depth,
Nothing
};
struct Viewport {
float x;
float y;
float width;
float height;
Viewport() : x(0.f), y(0.f), width(0.f), height(0.f) {}
Viewport(const float x, const float y, const float width, const float height)
:x(x), y(y), width(width), height(height) {}
};
class Camera : public Behaviour {
public:
static void registerComponentTypes(void);
static ComponentTypeId TypeId(void);
static std::vector<Camera*> allCameras(void);
static uint32 allCamerasCount(void);
//TODO : static Camera *current(void);
//TODO : static Gamera *main(void);
CameraClearFlags clearFlags;
void setBackgroundColor(const Color &color) {
m_BackgroundColor = color;
}
Color getBackgroundColor(void) const {
return m_BackgroundColor;
}
Mat4 getCameraToWorldMatrix(void) const;
void setViewport(const Viewport &viewport) { m_Viewport = viewport; };
Viewport getViewport(void) { return m_Viewport; }
Camera *setFOV(const float fov) { m_FOV = fov; return this; }
Camera *setWidth(const float width) { m_Width = width; return this; }
Camera *setHeight(const float height) { m_Height = height; return this; }
Camera *setNear(const float near) { m_Near = near; return this; }
Camera *setFar(const float far) { m_Far = far; return this; }
float getFOV(void) const { return m_FOV; }
float getWidth(void) const { return m_Width; }
float getHeight(void) const { return m_Height; }
float getNear(void) const { return m_Near; }
float getFar(void) const { return m_Far; }
protected:
Camera(const std::string&);
virtual ~Camera();
virtual Camera *clone(void) override;
virtual Camera *cloneFromGameObject(void) override;
private:
static CoreObject *_alloc_obj(const std::string&);
Color m_BackgroundColor;
Viewport m_Viewport;
float m_FOV;
float m_Width;
float m_Height;
float m_Near;
float m_Far;
};
}
#endif /* _cCamera_h_ */
|
//
// PAWWallPostsTableViewController.h
// AnyWall
//
// Created by Christopher Bowns on 2/6/12.
// Copyright (c) 2012 Parse. All rights reserved.
//
#import <UIKit/UIKit.h>
#import <Parse/Parse.h>
#import "PAWWallViewController.h"
@interface PAWWallPostsTableViewController : PFQueryTableViewController <PAWWallViewControllerHighlight>
- (void)highlightCellForPost:(PAWPost *)post;
- (void)unhighlightCellForPost:(PAWPost *)post;
@end
|
#ifndef USERSCONTROLLER_H
#define USERSCONTROLLER_H
#include <string>
#include <vector>
class UsersController {
private:
bool signedIn;
std::string username;
public:
UsersController(): signedIn(false) {}
UsersController(bool _signedIn) : signedIn(_signedIn) {}
bool isSignedIn() {
return signedIn;
}
void setSignedIn(bool _signedIn) {
signedIn = _signedIn;
}
void removeFriend(std::string friendName);
void shareFileWithFriend(std::string friendName, std::string fileName);
void messageFriend(std::string friendName, std::string message);
void addFriend(std::string friendName);
void acceptFriendRequest(std::string friendName);
std::vector<std::string> getFriends();
std::string getUsername() {
return username;
}
void setUsername(std::string _username) {
username = _username;
}
};
//bool UsersController::isSignedIn(){
// return signedIn;
//}
//void UsersController::setSignedIn(bool _signedIn) {
// signedIn = _signedIn;
//}
//void UsersController::removeFriend(std::string friendName){
// //TODO call clientcommand's method to remove a friend
//}
//void UsersController::shareFileWithFriend(std::string friendName, std::string fileName){
// //TODO call clientcommand's method
//}
//void UsersController::messageFriend(std::string friendName, std::string message){
// //TODO call clientcommand's method
//}
//void UsersController::addFriend(std::string friendName){
// //TODO call clientcommand's method
//}
//void UsersController::acceptFriendRequest(std::string friendName){
// //TODO call clientcommand's method
//}
//std::vector<std::string> UsersController::getFriends(){
// //TODO call clientcommand's method
//}
#endif // USERSCONTROLLER_H
|
/* TEMPLATE GENERATED TESTCASE FILE
Filename: CWE190_Integer_Overflow__int_fscanf_square_09.c
Label Definition File: CWE190_Integer_Overflow__int.label.xml
Template File: sources-sinks-09.tmpl.c
*/
/*
* @description
* CWE: 190 Integer Overflow
* BadSource: fscanf Read data from the console using fscanf()
* GoodSource: Set data to a small, non-zero number (two)
* Sinks: square
* GoodSink: Ensure there will not be an overflow before squaring data
* BadSink : Square data, which can lead to overflow
* Flow Variant: 09 Control flow: if(GLOBAL_CONST_TRUE) and if(GLOBAL_CONST_FALSE)
*
* */
#include "std_testcase.h"
#include <math.h>
#ifndef OMITBAD
void CWE190_Integer_Overflow__int_fscanf_square_09_bad()
{
int data;
/* Initialize data */
data = 0;
if(GLOBAL_CONST_TRUE)
{
/* POTENTIAL FLAW: Read data from the console using fscanf() */
fscanf(stdin, "%d", &data);
}
if(GLOBAL_CONST_TRUE)
{
{
/* POTENTIAL FLAW: if (data*data) > INT_MAX, this will overflow */
int result = data * data;
printIntLine(result);
}
}
}
#endif /* OMITBAD */
#ifndef OMITGOOD
/* goodB2G1() - use badsource and goodsink by changing the second GLOBAL_CONST_TRUE to GLOBAL_CONST_FALSE */
static void goodB2G1()
{
int data;
/* Initialize data */
data = 0;
if(GLOBAL_CONST_TRUE)
{
/* POTENTIAL FLAW: Read data from the console using fscanf() */
fscanf(stdin, "%d", &data);
}
if(GLOBAL_CONST_FALSE)
{
/* INCIDENTAL: CWE 561 Dead Code, the code below will never run */
printLine("Benign, fixed string");
}
else
{
/* FIX: Add a check to prevent an overflow from occurring */
if (abs((long)data) <= (long)sqrt((double)INT_MAX))
{
int result = data * data;
printIntLine(result);
}
else
{
printLine("data value is too large to perform arithmetic safely.");
}
}
}
/* goodB2G2() - use badsource and goodsink by reversing the blocks in the second if */
static void goodB2G2()
{
int data;
/* Initialize data */
data = 0;
if(GLOBAL_CONST_TRUE)
{
/* POTENTIAL FLAW: Read data from the console using fscanf() */
fscanf(stdin, "%d", &data);
}
if(GLOBAL_CONST_TRUE)
{
/* FIX: Add a check to prevent an overflow from occurring */
if (abs((long)data) <= (long)sqrt((double)INT_MAX))
{
int result = data * data;
printIntLine(result);
}
else
{
printLine("data value is too large to perform arithmetic safely.");
}
}
}
/* goodG2B1() - use goodsource and badsink by changing the first GLOBAL_CONST_TRUE to GLOBAL_CONST_FALSE */
static void goodG2B1()
{
int data;
/* Initialize data */
data = 0;
if(GLOBAL_CONST_FALSE)
{
/* INCIDENTAL: CWE 561 Dead Code, the code below will never run */
printLine("Benign, fixed string");
}
else
{
/* FIX: Use a small, non-zero value that will not cause an integer overflow in the sinks */
data = 2;
}
if(GLOBAL_CONST_TRUE)
{
{
/* POTENTIAL FLAW: if (data*data) > INT_MAX, this will overflow */
int result = data * data;
printIntLine(result);
}
}
}
/* goodG2B2() - use goodsource and badsink by reversing the blocks in the first if */
static void goodG2B2()
{
int data;
/* Initialize data */
data = 0;
if(GLOBAL_CONST_TRUE)
{
/* FIX: Use a small, non-zero value that will not cause an integer overflow in the sinks */
data = 2;
}
if(GLOBAL_CONST_TRUE)
{
{
/* POTENTIAL FLAW: if (data*data) > INT_MAX, this will overflow */
int result = data * data;
printIntLine(result);
}
}
}
void CWE190_Integer_Overflow__int_fscanf_square_09_good()
{
goodB2G1();
goodB2G2();
goodG2B1();
goodG2B2();
}
#endif /* OMITGOOD */
/* Below is the main(). It is only used when building this testcase on
its own for testing or for building a binary to use in testing binary
analysis tools. It is not used when compiling all the testcases as one
application, which is how source code analysis tools are tested. */
#ifdef INCLUDEMAIN
int main(int argc, char * argv[])
{
/* seed randomness */
srand( (unsigned)time(NULL) );
#ifndef OMITGOOD
printLine("Calling good()...");
CWE190_Integer_Overflow__int_fscanf_square_09_good();
printLine("Finished good()");
#endif /* OMITGOOD */
#ifndef OMITBAD
printLine("Calling bad()...");
CWE190_Integer_Overflow__int_fscanf_square_09_bad();
printLine("Finished bad()");
#endif /* OMITBAD */
return 0;
}
#endif
|
/*
* This file is part of the MicroPython project, http://micropython.org/
*
* The MIT License (MIT)
*
* Copyright (c) 2019 Dan Halbert for Adafruit Industries
* Copyright (c) 2018 Artur Pacholec
* Copyright (c) 2016 Glenn Ruben Bakke
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
*/
#include <stdbool.h>
#include <stdio.h>
#include "ble.h"
#include "ble_drv.h"
#include "nrf_nvic.h"
#include "nrf_sdm.h"
#include "nrf_soc.h"
#include "nrfx_power.h"
#include "py/misc.h"
#include "py/mpstate.h"
#include "supervisor/shared/bluetooth.h"
nrf_nvic_state_t nrf_nvic_state = { 0 };
// Flag indicating progress of internal flash operation.
volatile sd_flash_operation_status_t sd_flash_operation_status;
__attribute__((aligned(4)))
static uint8_t m_ble_evt_buf[sizeof(ble_evt_t) + (BLE_GATTS_VAR_ATTR_LEN_MAX)];
void ble_drv_reset() {
// Linked list items will be gc'd.
MP_STATE_VM(ble_drv_evt_handler_entries) = NULL;
sd_flash_operation_status = SD_FLASH_OPERATION_DONE;
}
void ble_drv_add_event_handler_entry(ble_drv_evt_handler_entry_t* entry, ble_drv_evt_handler_t func, void *param) {
entry->next = MP_STATE_VM(ble_drv_evt_handler_entries);
entry->param = param;
entry->func = func;
MP_STATE_VM(ble_drv_evt_handler_entries) = entry;
}
void ble_drv_add_event_handler(ble_drv_evt_handler_t func, void *param) {
ble_drv_evt_handler_entry_t *it = MP_STATE_VM(ble_drv_evt_handler_entries);
while (it != NULL) {
// If event handler and its corresponding param are already on the list, don't add again.
if ((it->func == func) && (it->param == param)) {
return;
}
it = it->next;
}
// Add a new handler to the front of the list
ble_drv_evt_handler_entry_t *handler = m_new_ll(ble_drv_evt_handler_entry_t, 1);
ble_drv_add_event_handler_entry(handler, func, param);
}
void ble_drv_remove_event_handler(ble_drv_evt_handler_t func, void *param) {
ble_drv_evt_handler_entry_t *it = MP_STATE_VM(ble_drv_evt_handler_entries);
ble_drv_evt_handler_entry_t **prev = &MP_STATE_VM(ble_drv_evt_handler_entries);
while (it != NULL) {
if ((it->func == func) && (it->param == param)) {
// Splice out the matching handler.
*prev = it->next;
return;
}
prev = &(it->next);
it = it->next;
}
}
extern void tusb_hal_nrf_power_event (uint32_t event);
void SD_EVT_IRQHandler(void) {
uint32_t evt_id;
while (sd_evt_get(&evt_id) != NRF_ERROR_NOT_FOUND) {
switch (evt_id) {
// usb power event
case NRF_EVT_POWER_USB_DETECTED:
case NRF_EVT_POWER_USB_POWER_READY:
case NRF_EVT_POWER_USB_REMOVED: {
int32_t usbevt = (evt_id == NRF_EVT_POWER_USB_DETECTED ) ? NRFX_POWER_USB_EVT_DETECTED:
(evt_id == NRF_EVT_POWER_USB_POWER_READY) ? NRFX_POWER_USB_EVT_READY :
(evt_id == NRF_EVT_POWER_USB_REMOVED ) ? NRFX_POWER_USB_EVT_REMOVED : -1;
tusb_hal_nrf_power_event(usbevt);
}
break;
// Set flag indicating that a flash operation has finished.
case NRF_EVT_FLASH_OPERATION_SUCCESS:
sd_flash_operation_status = SD_FLASH_OPERATION_DONE;
break;
case NRF_EVT_FLASH_OPERATION_ERROR:
sd_flash_operation_status = SD_FLASH_OPERATION_ERROR;
break;
default:
break;
}
}
while (1) {
uint16_t evt_len = sizeof(m_ble_evt_buf);
const uint32_t err_code = sd_ble_evt_get(m_ble_evt_buf, &evt_len);
if (err_code != NRF_SUCCESS) {
if (err_code == NRF_ERROR_DATA_SIZE) {
printf("NRF_ERROR_DATA_SIZE\n");
}
break;
}
ble_evt_t* event = (ble_evt_t *)m_ble_evt_buf;
#if CIRCUITPY_VERBOSE_BLE
mp_printf(&mp_plat_print, "BLE event: 0x%04x\n", event->header.evt_id);
#endif
if (supervisor_bluetooth_hook(event)) {
continue;
}
ble_drv_evt_handler_entry_t *it = MP_STATE_VM(ble_drv_evt_handler_entries);
bool done = false;
while (it != NULL) {
#if CIRCUITPY_VERBOSE_BLE
// mp_printf(&mp_plat_print, " calling handler: 0x%08lx, param: 0x%08lx\n", it->func-1, it->param);
#endif
done = it->func(event, it->param) || done;
it = it->next;
}
#if CIRCUITPY_VERBOSE_BLE
if (event->header.evt_id == BLE_GATTS_EVT_WRITE) {
ble_gatts_evt_write_t* write_evt = &event->evt.gatts_evt.params.write;
mp_printf(&mp_plat_print, "Write to: UUID(0x%04x) handle %x of length %d auth %x\n", write_evt->uuid.uuid, write_evt->handle, write_evt->len, write_evt->auth_required);
}
#endif
}
}
|
//
// Generated by class-dump 3.5 (64 bit).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2013 by Steve Nygard.
//
#import "CDStructures.h"
@class NSDictionary, NSMutableDictionary, NSString;
@interface IDEAlertEvent : NSObject
{
NSString *_identifier;
NSString *_title;
NSString *_titleSortKey;
NSString *_group;
NSString *_groupSortKey;
NSString *_iconName;
NSMutableDictionary *_alerts;
NSMutableDictionary *_observationTokensByAlert;
BOOL _showInPreferences;
}
+ (id)alertEventsForGroup:(id)arg1;
+ (id)alertEventGroups;
+ (id)alertEvents;
+ (id)alertEventForIdentifier:(id)arg1;
+ (void)_cacheAlertEvents;
+ (void)_registerAlertEventExtension:(id)arg1;
@property BOOL showInPreferences; // @synthesize showInPreferences=_showInPreferences;
@property(retain) NSString *iconName; // @synthesize iconName=_iconName;
@property(readonly) NSDictionary *alerts; // @synthesize alerts=_alerts;
@property(retain, nonatomic) NSString *groupSortKey; // @synthesize groupSortKey=_groupSortKey;
@property(retain) NSString *group; // @synthesize group=_group;
@property(retain, nonatomic) NSString *titleSortKey; // @synthesize titleSortKey=_titleSortKey;
@property(retain) NSString *title; // @synthesize title=_title;
@property(readonly) NSString *identifier; // @synthesize identifier=_identifier;
- (void)ide_setIdentifier:(id)arg1;
- (void)saveToUserDefaults;
- (id)propertyList;
- (id)propertyListForVersion:(int)arg1;
- (id)alertDefaults;
- (id)alertDefaultsKey;
- (void)observeValueForKeyPath:(id)arg1 ofObject:(id)arg2 change:(id)arg3 context:(void *)arg4;
- (void)runInWorkspace:(id)arg1 context:(id)arg2;
- (void)runInWorkspace:(id)arg1 context:(id)arg2 completionBlock:(dispatch_block_t)arg3;
- (id)ide_initializeAlertContext:(id)arg1 forWorkspace:(id)arg2;
- (BOOL)hasEnabledAlerts;
- (void)removeAlert:(id)arg1;
- (void)addAlert:(id)arg1;
- (id)description;
- (id)initWithIdentifier:(id)arg1 title:(id)arg2 group:(id)arg3;
- (id)init;
- (void)ide_initializeAlertsFromDefaults:(id)arg1;
@end
|
//
// UIImage+CTAssetsPicker.h
// Pods
//
// Created by wshaolin on 16/7/7.
// Copyright © 2016年 wshaolin. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface UIImage (CTAssetsPicker)
+ (UIImage *)ctAssets_imageNamed:(NSString *)name;
@end
|
// UE4 Procedural Mesh Generation from the Epic Wiki (https://wiki.unrealengine.com/Procedural_Mesh_Generation)
//
// forked from "Engine/Plugins/Runtime/CustomMeshComponent/Source/CustomMeshComponent/Classes/CustomMeshComponent.h"
#pragma once
#include "GeneratedMeshComponent.generated.h"
USTRUCT(BlueprintType)
struct FGeneratedMeshVertex
{
GENERATED_USTRUCT_BODY()
UPROPERTY(EditAnywhere, Category=Triangle)
FVector Position;
UPROPERTY(EditAnywhere, Category=Triangle)
FColor Color;
UPROPERTY(EditAnywhere, Category=Triangle)
float U;
UPROPERTY(EditAnywhere, Category=Triangle)
float V;
};
USTRUCT(BlueprintType)
struct FGeneratedMeshTriangle
{
GENERATED_USTRUCT_BODY()
UPROPERTY(EditAnywhere, Category=Triangle)
FGeneratedMeshVertex Vertex0;
UPROPERTY(EditAnywhere, Category=Triangle)
FGeneratedMeshVertex Vertex1;
UPROPERTY(EditAnywhere, Category=Triangle)
FGeneratedMeshVertex Vertex2;
};
/** Component that allows you to specify custom triangle mesh geometry */
UCLASS(editinlinenew, meta = (BlueprintSpawnableComponent), ClassGroup=Rendering)
class UGeneratedMeshComponent : public UMeshComponent, public IInterface_CollisionDataProvider
{
GENERATED_UCLASS_BODY()
public:
/** Set the geometry to use on this triangle mesh */
UFUNCTION(BlueprintCallable, Category="Components|GeneratedMesh")
bool SetGeneratedMeshTriangles(const TArray<FGeneratedMeshTriangle>& Triangles);
/** Add to the geometry to use on this triangle mesh. This may cause an allocation. Use SetCustomMeshTriangles() instead when possible to reduce allocations. */
UFUNCTION(BlueprintCallable, Category="Components|GeneratedMesh")
void AddGeneratedMeshTriangles(const TArray<FGeneratedMeshTriangle>& Triangles);
/** Removes all geometry from this triangle mesh. Does not deallocate memory, allowing new geometry to reuse the existing allocation. */
UFUNCTION(BlueprintCallable, Category="Components|GeneratedMesh")
void ClearGeneratedMeshTriangles();
/** Description of collision */
UPROPERTY(BlueprintReadOnly, Category="Collision")
class UBodySetup* ModelBodySetup;
// Begin Interface_CollisionDataProvider Interface
virtual bool GetPhysicsTriMeshData(struct FTriMeshCollisionData* CollisionData, bool InUseAllTriData) override;
virtual bool ContainsPhysicsTriMeshData(bool InUseAllTriData) const override;
virtual bool WantsNegXTriMesh() override{ return false; }
// End Interface_CollisionDataProvider Interface
// Begin UPrimitiveComponent interface.
virtual FPrimitiveSceneProxy* CreateSceneProxy() override;
virtual class UBodySetup* GetBodySetup() override;
// End UPrimitiveComponent interface.
// Begin UMeshComponent interface.
virtual int32 GetNumMaterials() const override;
// End UMeshComponent interface.
void UpdateBodySetup();
void UpdateCollision();
private:
// Begin USceneComponent interface.
virtual FBoxSphereBounds CalcBounds(const FTransform & LocalToWorld) const override;
// Begin USceneComponent interface.
/** */
TArray<FGeneratedMeshTriangle> GeneratedMeshTris;
friend class FGeneratedMeshSceneProxy;
};
|
/*
* Copyright(c) Sophist Solutions, Inc. 1990-2022. All rights reserved
*/
#include "../../StroikaPreComp.h"
#include <map>
#include "../Mapping.h"
#ifndef _Stroika_Foundation_Containers_Concrete_Mapping_stdmap_h_
#define _Stroika_Foundation_Containers_Concrete_Mapping_stdmap_h_
/**
* \file
*
* \version <a href="Code-Status.md#Beta">Beta</a>
*
* TODO:
*/
namespace Stroika::Foundation::Containers::Concrete {
/**
* \brief Mapping_stdmap<KEY_TYPE, MAPPED_VALUE_TYPE, TRAITS> is an std::map-based concrete implementation of the Mapping<KEY_TYPE, MAPPED_VALUE_TYPE, typename TRAITS::MappingTraitsType> container pattern.
*
* \note \em Implementation Details
* This module is essentially identical to SortedMapping_stdmap, but making it dependent on SortedMapping<> creates
* problems with circular dependencies - especially give how the default Mapping CTOR calls the factory class
* which maps back to the _stdmap<> variant.
*
* There maybe another (better) way, but this works.
*
* \note Performance Notes:
* o size () is constant complexity
*
* \note \em Thread-Safety <a href="Thread-Safety.md#C++-Standard-Thread-Safety">C++-Standard-Thread-Safety</a>
*/
template <typename KEY_TYPE, typename MAPPED_VALUE_TYPE>
class Mapping_stdmap : public Mapping<KEY_TYPE, MAPPED_VALUE_TYPE> {
private:
using inherited = Mapping<KEY_TYPE, MAPPED_VALUE_TYPE>;
public:
template <typename POTENTIALLY_ADDABLE_T>
static constexpr bool IsAddable_v = inherited::template IsAddable_v<POTENTIALLY_ADDABLE_T>;
using KeyEqualsCompareFunctionType = typename inherited::KeyEqualsCompareFunctionType;
using key_type = typename inherited::key_type;
using value_type = typename inherited::value_type;
using mapped_type = typename inherited::mapped_type;
public:
/**
* \brief STDMAP is std::map<> that can be used inside Mapping_stdmap
*/
template <typename KEY_INORDER_COMPARER = less<key_type>>
using STDMAP = map<KEY_TYPE, MAPPED_VALUE_TYPE, KEY_INORDER_COMPARER, Memory::BlockAllocatorOrStdAllocatorAsAppropriate<pair<const key_type, mapped_type>, sizeof (value_type) <= 1024>>;
public:
/**
* \see docs on Mapping<> constructor, except that KEY_EQUALS_COMPARER is replaced with KEY_INORDER_COMPARER and IsEqualsComparer is replaced by IsStrictInOrderComparer
* and added Mapping_stdmap (STDMAP<>&& src)
*/
Mapping_stdmap ();
Mapping_stdmap (STDMAP<>&& src);
template <typename KEY_INORDER_COMPARER, enable_if_t<Common::IsStrictInOrderComparer<KEY_INORDER_COMPARER, KEY_TYPE> ()>* = nullptr>
explicit Mapping_stdmap (KEY_INORDER_COMPARER&& keyComparer);
Mapping_stdmap (Mapping_stdmap&& src) noexcept = default;
Mapping_stdmap (const Mapping_stdmap& src) noexcept = default;
Mapping_stdmap (const initializer_list<KeyValuePair<KEY_TYPE, MAPPED_VALUE_TYPE>>& src);
template <typename KEY_INORDER_COMPARER, enable_if_t<Common::IsStrictInOrderComparer<KEY_INORDER_COMPARER, KEY_TYPE> ()>* = nullptr>
Mapping_stdmap (KEY_INORDER_COMPARER&& keyComparer, const initializer_list<KeyValuePair<KEY_TYPE, MAPPED_VALUE_TYPE>>& src);
template <typename ITERABLE_OF_ADDABLE, enable_if_t<Configuration::IsIterable_v<ITERABLE_OF_ADDABLE> and not is_base_of_v<Mapping_stdmap<KEY_TYPE, MAPPED_VALUE_TYPE>, decay_t<ITERABLE_OF_ADDABLE>>>* = nullptr>
explicit Mapping_stdmap (ITERABLE_OF_ADDABLE&& src);
template <typename KEY_INORDER_COMPARER, typename ITERABLE_OF_ADDABLE, enable_if_t<Common::IsStrictInOrderComparer<KEY_INORDER_COMPARER, KEY_TYPE> () and Configuration::IsIterable_v<ITERABLE_OF_ADDABLE>>* = nullptr>
Mapping_stdmap (KEY_INORDER_COMPARER&& keyComparer, ITERABLE_OF_ADDABLE&& src);
template <typename ITERATOR_OF_ADDABLE, enable_if_t<Configuration::IsIterator_v<ITERATOR_OF_ADDABLE>>* = nullptr>
Mapping_stdmap (ITERATOR_OF_ADDABLE&& start, ITERATOR_OF_ADDABLE&& end);
template <typename KEY_INORDER_COMPARER, typename ITERATOR_OF_ADDABLE, enable_if_t<Common::IsStrictInOrderComparer<KEY_INORDER_COMPARER, KEY_TYPE> () and Configuration::IsIterator_v<ITERATOR_OF_ADDABLE>>* = nullptr>
Mapping_stdmap (KEY_INORDER_COMPARER&& keyComparer, ITERATOR_OF_ADDABLE&& start, ITERATOR_OF_ADDABLE&& end);
public:
/**
*/
nonvirtual Mapping_stdmap& operator= (Mapping_stdmap&& rhs) noexcept = default;
nonvirtual Mapping_stdmap& operator= (const Mapping_stdmap& rhs) = default;
protected:
using _IterableRepSharedPtr = typename inherited::_IterableRepSharedPtr;
using _MappingRepSharedPtr = typename inherited::_IRepSharedPtr;
private:
class IImplRepBase_;
template <typename KEY_INORDER_COMPARER>
class Rep_;
private:
nonvirtual void AssertRepValidType_ () const;
};
}
/*
********************************************************************************
******************************* Implementation Details *************************
********************************************************************************
*/
#include "Mapping_stdmap.inl"
#endif /*_Stroika_Foundation_Containers_Concrete_Mapping_stdmap_h_ */
|
//
// DataItemModel.h
// downDropMenu
//
// Created by 凯东源 on 17/6/22.
// Copyright © 2017年 xx. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface DataItemModel : NSObject
@property (nonatomic, assign) NSInteger selected;
@property (nonatomic, strong) NSString * title;
-(instancetype)initWithDictionary:(NSDictionary *)dictionary;
-(NSDictionary *)toDictionary;
@end
|
#ifndef CONWAY_H
#define CONWAY_H
char *genField(int w, int h);
#endif
|
//
// TableViewHeader.h
// CJUIKitDemo
//
// Created by ciyouzen on 8/26/15.
// Copyright (c) 2015 dvlproad. All rights reserved.
//
#import "CJTableViewHeaderFooterView.h"
@interface TableViewHeader : CJTableViewHeaderFooterView {
}
@property(nonatomic, strong) IBOutlet UILabel *tilteLabel;
@end
|
//
// ViewController.h
// LiftTrack
//
// Created by Jerry Wong on 5/1/15.
// Copyright (c) 2015 Jerry Wong. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface ViewController : UIViewController
@end
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.