repo_name stringlengths 5 122 | path stringlengths 3 232 | text stringlengths 6 1.05M |
|---|---|---|
cvxgrp/coneos | coneOSdense/normalize.h | <filename>coneOSdense/normalize.h
#ifndef NORMAL_H_GUARD
#define NORMAL_H_GUARD
#define MIN_SCALE 1e-2
#define MAX_SCALE 1e3
void normalize(Data * d, Work * w, Cone * k){
double * D = coneOS_calloc(d->m, sizeof(double));
double * E = coneOS_calloc(d->n, sizeof(double));
int i, j, count;
double wrk;
// lo... |
cvxgrp/coneos | coneOSsparse/linAlg.c | #include "linAlg.h"
#include <math.h>
/*
* All basic linear operations are inlined (and further optimized) by the
* compiler. If compiling without optimization, causes code bloat.
*/
inline void _accumByAtrans(int n, double * Ax, int * Ai, int * Ap, const double *x, double *y);
inline void _accumByA(int n, double... |
cvxgrp/coneos | coneOSdense/cones.h | <reponame>cvxgrp/coneos
#ifndef CONES_H_GUARD
#define CONES_H_GUARD
#include <string.h>
typedef struct Cone_t {
int f; /* number of linear equality constraints */
int l; /* length of LP cone */
int *q; /* array of second-o... |
cvxgrp/coneos | coneOSsparse/coneOS.c | <reponame>cvxgrp/coneos
/* coneos 1.0 */
#include "coneOS.h"
#include "normalize.h"
static int _lineLen_;
// constants and data structures
static const char* HEADER[] = {
" Iter ",
" pri res ",
" dua res ",
" rel gap ",
" pri obj ",
" dua obj ",
" kappa ",
" time (s)",
};
static const int HEADER_L... |
cvxgrp/coneos | coneOSsparse/indirect/private.h | #ifndef PRIV_H_GUARD
#define PRIV_H_GUARD
#include "cs.h"
#include "coneOS.h"
#include <math.h>
struct PRIVATE_DATA{
double *p; // cg iterate
double *r; // cg residual
double *x;
double * Ap;
double * tmp;
double * Atx;
int * Ati;
int * ... |
cvxgrp/coneos | coneOSsparse/matlab/coneOS_mex.c | <reponame>cvxgrp/coneos
#include "mex.h"
#include "matrix.h"
#include "coneOS.h"
#include "linAlg.h"
void mexFunction(int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[])
{
/* matlab usage: coneOS(data,cone,params); */
if (nrhs != 3){
mexErrMsgTxt("Three arguments are required in this order: data st... |
cvxgrp/coneos | coneOSdense/linAlg.c | #include "coneOS.h"
#include <cblas.h>
#include <math.h>
// x = b*a
inline void setAsScaledArray(double *x, const double * a,const double b,int len) {
int i;
for( i=0;i<len;++i ) x[i] = b*a[i];
}
// a*= b
inline void scaleArray(double * a,const double b,int len){
//b_dscal(len,b,a,1);
cblas_dscal(len,b,a,1);... |
cvxgrp/coneos | coneOSdense/direct/private.c | #include "private.h"
int privateInitWork(Data * d, Work * w){
w->method = strdup("dense-direct");
int k,j, n=d->n, m=d->m;
w->p = coneOS_malloc(sizeof(Priv));
double * A = d->Ax;
/* sparse A input:
w->p->A = coneOS_calloc(m*n, sizeof(double));
for (j = 0; j < n; ++j) {
for (k =... |
cvxgrp/coneos | coneOSsparse/indirect/private.c | #include "private.h"
#include "linAlg.h"
#define CG_BEST_TOL 1e-9
#define CG_EXPONENT 1.5
#define CG_VERBOSE 1
#define PRINT_INTERVAL 100
static inline void calcAx(Data * d, Work * w, const double * x, double * y);
static int cgCustom(Data *d, Work *w, const double *s, double * b, int max_its, double tol);
static inl... |
cvxgrp/coneos | coneOSsparse/run_coneOS.h | #ifndef RUN_coneOS_H_GUARD
#define RUN_coneOS_H_GUARD
int main(int argc, char **argv);
void free_data(Data * d, Cone * k);
int read_in_data(FILE * fp,Data * d, Cone * k);
int open_file(int argc, char ** argv, int idx, char * default_file, FILE ** fb);
void freeData(Data *d, Cone *k);
void freeSol(Sol *sol);
#endif
|
cvxgrp/coneos | coneOSsparse/linAlg.h | <gh_stars>1-10
#ifndef LINALG_H_GUARD
#define LINALG_H_GUARD
#include "coneOS.h"
#include <math.h>
void _accumByAtrans(int n, double * Ax, int * Ai, int * Ap, const double *x, double *y);
void _accumByA(int n, double * Ax, int * Ai, int * Ap, const double *x, double *y);
void setAsScaledArray(double *x, const double ... |
cvxgrp/coneos | coneOSdense/indirect/private.c | #include "private.h"
int privateInitWork(Data * d, Work * w){
char str[80];
int len = sprintf(str, "dense-indirect, CG: iters %i, tol %.2e", d->CG_MAX_ITS, d->CG_TOL);
w->method = strndup(str, len);
int j;
w->p = coneOS_malloc(sizeof(Priv));
w->p->x = coneOS_malloc(d->n*sizeof(double));
w->p->p = coneOS_... |
cvxgrp/coneos | coneOSsparse/cs.h | #ifndef CS_H_GUARD
#define CS_H_GUARD
//#include <string.h>
//#include <stdlib.h>
typedef struct cs_sparse /* matrix in compressed-column or triplet form */
{
int nzmax ; /* maximum number of entries */
int m ; /* number of rows */
int n ; /* number of columns */
int *p ; ... |
cvxgrp/coneos | coneOSsparse/util.h | #ifndef UTIL_H_GUARD
#define UTIL_H_GUARD
#include <stdlib.h>
#include <stdio.h>
#include "coneOS.h"
void tic(void);
double toc(void);
double tocq(void);
void printConeData(Cone * k);
void printData(Data * d);
void printAll(Data * d, Work * w);
#endif
|
cvxgrp/coneos | coneOSdense/run_coneOS.c | <gh_stars>1-10
#include "coneOS.h"
#include "run_coneOS.h"
#ifndef DEMO_PATH
#define DEMO_PATH "../data_dense"
#endif
#define NUM_TRIALS 1
#define RHOX 1e-3
int main(int argc, char **argv)
{
FILE * fp;
if(open_file(argc, argv, 1, DEMO_PATH, &fp)==-1) return -1;
Cone * k = coneOS_malloc(sizeof(Cone));
Data * d ... |
cvxgrp/coneos | coneOSsparse/normalize.h | #ifndef NORMAL_H_GUARD
#define NORMAL_H_GUARD
#define MIN_SCALE 1e-2
#define MAX_SCALE 1e3
void normalize(Data * d, Work * w, Cone * k){
double * D = coneOS_calloc(d->m, sizeof(double));
double * E = coneOS_calloc(d->n, sizeof(double));
int i, j, count;
double wrk;
// heuristic rescaling, seems to do we... |
cvxgrp/coneos | coneOSdense/linAlg.h | #ifndef LINALG_H_GUARD
#define LINALG_H_GUARD
#include "coneOS.h"
#include <cblas.h>
#include <math.h>
void setAsScaledArray(double *x, const double * a,const double b,int len);
void scaleArray(double * a,const double b,int len);
double innerProd(const double * x, const double * y, int len);
double calcNorm(const dou... |
cvxgrp/coneos | coneOSsparse/direct/private.h | #ifndef PRIV_H_GUARD
#define PRIV_H_GUARD
#include "cs.h"
#include "amd.h"
#include "ldl.h"
#include "coneOS.h"
struct PRIVATE_DATA {
cs * L; /* KKT, and factorization matrix L resp. */
double * D; /* diagonal matrix of factorization */
int * P; /* perm... |
9re/QROAuth | QROAuthSample/Classes/QROAuthSampleAppDelegate.h | //
// QROAuthSampleDelegate.h
// QROAuth
//
// Created by <NAME> on 25/01/2014.
// Copyright (c) 2014 <NAME>. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface QROAuthSampleDelegate : UIResponder <UIApplicationDelegate>
@property (strong, nonatomic) UIWindow *window;
@end
|
9re/QROAuth | Classes/QROAuthDelegate.h | //
// QROAuthDelegate.h
// QROAuth
//
// Created by <NAME> on 27/01/2014.
// Copyright (c) 2014 <NAME>. All rights reserved.
//
#ifndef QROAuth_QROAuthDelegate_h
#define QROAuth_QROAuthDelegate_h
@protocol QROAuthDelegate <NSObject>
@required
- (void) onFetchedAccessToken:(NSString *) accessToken
acce... |
9re/QROAuth | Classes/QROAuthProvider.h | //
// QROAuthProvider.h
// QROAuth
//
// Created by <NAME> on 25/01/2014.
// Copyright (c) 2014 <NAME>. All rights reserved.
//
#import <Foundation/Foundation.h>
#import "OAConsumer.h"
@interface QROAuthProvider : NSObject
@property (retain) NSString *requestTokenUrl;
@property (retain) NSString *accessTokenUrl;
... |
9re/QROAuth | QROAuthSample/Classes/Config.h | <reponame>9re/QROAuth<filename>QROAuthSample/Classes/Config.h
//
// Header.h
// QROAuth
//
// Created by <NAME> on 25/01/2014.
// Copyright (c) 2014 <NAME>. All rights reserved.
//
#ifndef QROAuth_Header_h
#define QROAuth_Header_h
#define TWITTER_CONSUMER_KEY <PUT YOUR TWITTER_CONSUMER_KEY>
#define TWITTER_CONSUM... |
9re/QROAuth | Classes/QROAuthLoginViewController.h | <filename>Classes/QROAuthLoginViewController.h<gh_stars>0
//
// QROAuthLoginViewController.h
// QROAuth
//
// Created by <NAME> on 25/01/2014.
// Copyright (c) 2014 <NAME>. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "OAConsumer.h"
#import "QROAuthDelegate.h"
#import "QROAuthProvider.h"
@interface QR... |
9re/QROAuth | Classes/NSDictionary+OARequestParameter.h | <reponame>9re/QROAuth
//
// NSDictionary+OAParameter.h
// QROAuth
//
// Created by <NAME> on 27/01/2014.
// Copyright (c) 2014 <NAME>. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface NSDictionary (OAParameter)
- (NSArray*) castAsOAParameters;
@end
|
9re/QROAuth | Classes/QRResourceUtil.h | //
// QRResourceUtil.h
// QROAuth
//
// Created by <NAME> on 25/01/2014.
// Copyright (c) 2014 <NAME>. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface QRResourceUtil : NSObject
+ (NSBundle *)frameworkBundle;
@end
|
9re/QROAuth | Classes/QROAuth.h | //
// QROAuth.h
// QROAuth
//
// Created by <NAME> on 25/01/2014.
// Copyright (c) 2014 <NAME>. All rights reserved.
//
#ifndef QROAuth_QROAuth_h
#define QROAuth_QROAuth_h
#import "QROAuthLoginViewController.h"
#import "QROAuthDelegate.h"
#endif
|
9re/QROAuth | QROAuthSample/Classes/QROAuthSampleViewController.h | //
// QRSampleViewController.h
// QROAuth
//
// Created by <NAME> on 25/01/2014.
// Copyright (c) 2014 <NAME>. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "QROAuth.h"
@interface QRSampleViewController : UIViewController <QROAuthDelegate>
@property (retain, nonatomic) IBOutlet UIButton *loginButton;
- ... |
vdm-dev/gpsinformer | src/TcpClient.h | //
// Copyright (c) 2017 <NAME> (<EMAIL>)
//
// 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, mer... |
vdm-dev/gpsinformer | src/Device.h | //
// Copyright (c) 2017 <NAME> (<EMAIL>)
//
// 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, mer... |
vdm-dev/gpsinformer | src/HttpsClient.h | <reponame>vdm-dev/gpsinformer
//
// Copyright (c) 2017 <NAME> (<EMAIL>)
//
// 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... |
vdm-dev/gpsinformer | src/TelegramBot.h | //
// Copyright (c) 2017 <NAME> (<EMAIL>)
// Copyright (c) 2015 <NAME>
//
// 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... |
vdm-dev/gpsinformer | src/Application.h | <reponame>vdm-dev/gpsinformer
//
// Copyright (c) 2017 <NAME> (<EMAIL>)
//
// 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... |
vdm-dev/gpsinformer | src/HttpParser.h | //
// Copyright (c) 2017 <NAME> (<EMAIL>)
// Copyright (c) 2015 <NAME>
//
// 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... |
vdm-dev/gpsinformer | src/tgbot/types/InlineQueryResultLocation.h | <reponame>vdm-dev/gpsinformer
//
// Created by <NAME> on 27/12/16
//
#ifndef TGBOT_INLINEQUERYRESULTLOCATION_H
#define TGBOT_INLINEQUERYRESULTLOCATION_H
#include <string>
#include <memory>
#include "tgbot/types/InlineQueryResult.h"
namespace TgBot {
/**
* Represents a location on a map.
* @ingroup types
*/
cla... |
vdm-dev/gpsinformer | src/StdAfx.h | <filename>src/StdAfx.h
//
// Copyright (c) 2017 <NAME> (<EMAIL>)
//
// 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... |
vdm-dev/gpsinformer | src/SslClient.h | //
// Copyright (c) 2017 <NAME> (<EMAIL>)
//
// 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, mer... |
vdm-dev/gpsinformer | src/Url.h | //
// Copyright (c) 2017 <NAME> (<EMAIL>)
// Copyright (c) 2015 <NAME>
//
// 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... |
vdm-dev/gpsinformer | src/HttpRequest.h | <reponame>vdm-dev/gpsinformer<gh_stars>1-10
//
// Copyright (c) 2017 <NAME> (<EMAIL>)
//
// 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 limitat... |
vdm-dev/gpsinformer | src/ChatCommand.h | //
// Copyright (c) 2017 <NAME> (<EMAIL>)
//
// 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, mer... |
vdm-dev/gpsinformer | src/TelegramBotHandler.h | <filename>src/TelegramBotHandler.h
//
// Copyright (c) 2017 <NAME> (<EMAIL>)
//
// 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 r... |
wujiangwei/FFToastView | FFToastView.h | <gh_stars>1-10
//
// FFToastView.h
//
// Created by Kevin on 14-3-17.
// Copyright (c) 2014年 Wu. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface FFToastView : UIView
{
@private
UILabel *_label;
BOOL _stoped;
BOOL _refreshed;
}
//get handle
+ (id)sharedInstance;
//config toast font and... |
michael-groble/motioncapture | MotionCapture/MCMotionPeripheral.h | // Copyright (c) 2014 <NAME>
//
// 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, d... |
michael-groble/motioncapture | MotionCapture/MCMeasurement.h | // Copyright (c) 2014 <NAME>
//
// 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, d... |
ftl999/libkatherine | src/udp.c | <reponame>ftl999/libkatherine
//
// Created by petr on 29.5.18.
// Edited by Felix for Windows on 28.09.18
//
#include <stdlib.h>
#ifndef WIN32
#include <unistd.h>
#include <sys/socket.h>
#else
#include "unistd.h"
#include <WinSock2.h>
#include <WS2tcpip.h>
#include <sys/types.h>
WSADATA wsaData;
int UDP_connection_c... |
ftl999/libkatherine | src/bmc.c | //
// Created by petr on 9.6.18.
//
#include <katherine/bmc.h>
#include <string.h>
/**
* Initialize new BMC matrix.
* @param bmc Matrix to initialize.
* @return Error code.
*/
int
katherine_bmc_init(katherine_bmc_t *bmc)
{
// Nothing done.
return 0;
}
/**
* Finalize BMC matrix.
* @param bmc Matrix to f... |
ftl999/libkatherine | include/katherine/bmc.h | //
// Created by petr on 9.6.18.
//
#ifndef THESIS_BMC_H
#define THESIS_BMC_H
/**
* @file
* @brief Functions related to the BMC matrix configuration format.
*/
#ifdef __cplusplus
extern "C" {
#endif
typedef struct katherine_bmc {
char pconf[65536];
} katherine_bmc_t;
int
katherine_bmc_init(katherine_bmc_t ... |
ftl999/libkatherine | include/katherine/MultiplattformNetwork.h | <filename>include/katherine/MultiplattformNetwork.h<gh_stars>0
#pragma once
#ifndef WIN32
#include <arpa/inet.h>
#include <sys/time.h>
#define SOCKETTYPE int
#define SOCKET_ADDR_T struct sockaddr_in
#define CLOSESOCK(sock) close(sock)
#define INITWSDATA()
#define SOCKET_ERROR -1
#define INVALID_SOCKET -1
static inline... |
ftl999/libkatherine | include/katherine/KatherineConfigParser.h | #pragma once
#include <katherine/katherine.h>
namespace YAML
{
class Node;
}
class KatherineConfigParser
{
public:
KatherineConfigParser(const char* configFile);
~KatherineConfigParser();
int getFrameCount();
katherine_config_t* getConfig();
size_t getBufferMD_Size();
size_t getBufferPixel_Size();
protected... |
ftl999/libkatherine | include/katherine/MultiplattformTypes.h | #pragma once
#ifndef WIN32
#include <pthread.h>
#define MUTEXTYPE pthread_mutex_t
#define CREATEMUTEX(mux) pthread_mutex_init(&mux, NULL)
#define DESTROYMUTEX(mux) pthread_mutex_destroy(&mux)
#define IS_MUTEX_VALID(mux) 1
#define ACQUIRE_MUTEX(mux) pthread_mutex_lock(&mux);
#define RELEASE_MUTEX(mux) pthread_mutex_unl... |
ftl999/libkatherine | src/status.c | <gh_stars>0
//
// Created by petr on 14.6.18.
//
#include <stdio.h>
#include <string.h>
#include <katherine/status.h>
#include <katherine/device.h>
#include <katherine/command_interface.h>
#ifndef WIN32
#define PACKED( __Declaration__ ) __Declaration__ __attribute__((__packed__))
#else
#define PACKED( __Declaration__... |
ftl999/libkatherine | include/katherine/config.h | //
// Created by petr on 10.6.18.
//
#ifndef THESIS_CONFIG_H
#define THESIS_CONFIG_H
/**
* @file
* @brief Functions related to detector and readout configuration.
*/
#include <stdbool.h>
#include <stdint.h>
#include <katherine/bmc.h>
#ifdef __cplusplus
extern "C" {
#endif
typedef struct katherine_device katheri... |
ftl999/libkatherine | include/katherine/device.h | <reponame>ftl999/libkatherine<filename>include/katherine/device.h<gh_stars>0
//
// Created by petr on 14.6.18.
//
#ifndef THESIS_DEVICE_H
#define THESIS_DEVICE_H
/**
* @file
* @brief Functions related to Katherine.
*/
#include <katherine/udp.h>
#ifdef __cplusplus
extern "C" {
#endif
typedef struct katherine_dev... |
ftl999/libkatherine | include/katherine/status.h | <filename>include/katherine/status.h
//
// Created by petr on 14.6.18.
//
#ifndef THESIS_STATUS_H
#define THESIS_STATUS_H
/**
* @file
* @brief Functions related to readout status inquiry.
*/
#include <stdint.h>
#include <stdbool.h>
#ifdef __cplusplus
extern "C" {
#endif
typedef struct katherine_device katherine... |
ftl999/libkatherine | include/katherine/acquisition.h | <filename>include/katherine/acquisition.h
//
// Created by petr on 29.5.18.
//
#ifndef THESIS_ACQUISITION_H
#define THESIS_ACQUISITION_H
/**
* @file
* @brief Functions related to the data acquisition process.
*/
#include <stdio.h>
#include <stdint.h>
#include <stdbool.h>
#include <katherine/device.h>
#include <ka... |
ftl999/libkatherine | include/katherine/katherine.h | <reponame>ftl999/libkatherine<filename>include/katherine/katherine.h
//
// Created by petr on 29.5.18.
//
#ifndef THESIS_KATHERINE_H
#define THESIS_KATHERINE_H
/**
* @file
* @brief Main umbrella header.
*/
#include "acquisition.h"
#include "bmc.h"
#include "config.h"
#include "device.h"
#include "status.h"
#inclu... |
ftl999/libkatherine | include/katherine/udp.h | <gh_stars>0
//
// Created by petr on 29.5.18.
//
#ifndef THESIS_UDP_H
#define THESIS_UDP_H
/**
* @file
* @brief Functions related to the UDP communication layer.
*/
#include <stdio.h>
#ifndef WIN32
#include <arpa/inet.h>
#include <pthread.h>
#else
#include "Winsock2.h"
#include <Windows.h>
#include <stdin... |
ftl999/libkatherine | src/device.c | //
// Created by petr on 14.6.18.
//
#include <katherine/device.h>
#ifndef DOXYGEN_SHOULD_SKIP_THIS
static const uint16_t CONTROL_PORT = 1555;
static const uint16_t DATA_PORT = 1556;
static const uint16_t REMOTE_PORT = 1555;
static const uint32_t CONTROL_TIMEOUT = 100;
static const uint32_t DATA_TIMEOUT = 2000;
#e... |
ftl999/libkatherine | src/acquisition.c | <reponame>ftl999/libkatherine
//
// Created by petr on 29.5.18.
//
#include <stdlib.h>
#include <string.h>
#include <katherine/acquisition.h>
#include <katherine/command_interface.h>
#include "katherine/MultiplattformTypes.h"
#ifndef DOXYGEN_SHOULD_SKIP_THIS
PACKED(
typedef struct md {
uint64_t : 44;
uint8_t... |
danidiaz1/Estructura-de-Datos-UGR-2017-2018 | QuienEsQuien/include/pregunta.h | <filename>QuienEsQuien/include/pregunta.h
#ifndef _PREGUNTA_H_
#define _PREGUNTA_H_
#include <string>
#include <iostream>
#include <cassert>
using namespace std;
/**
* @brief En cada estructura pregunta se almacena la cadena de la pregunta y el
* número de personajes que aún no han sido eliminados. Si el... |
danidiaz1/Estructura-de-Datos-UGR-2017-2018 | P3_STL_Iteradores/include/cronologia.h | /**
* @file cronologia.h
* @brief Fichero cabecera del TDA Cronologia
*
*/
#ifndef __CRONOLOGIA
#define __CRONOLOGIA
#include <iostream>
#include <map>
#include "fechahistorica.h"
using namespace std;
/**
* @brief T.D.A. Cronologia
*
* Una instancia @e c del tipo de datos abstracto @c Cronologia es u... |
danidiaz1/Estructura-de-Datos-UGR-2017-2018 | P2_Abstraccion/include/fechahistorica.h | <reponame>danidiaz1/Estructura-de-Datos-UGR-2017-2018<filename>P2_Abstraccion/include/fechahistorica.h
/**
* @file fechahistorica.h
* @brief Fichero cabecera del TDA Fecha Histórica
*
*/
#ifndef __FECHAHISTORICA
#define __FECHAHISTORICA
#include <iostream>
#include <vector>
#include <string>
using namespace ... |
danidiaz1/Estructura-de-Datos-UGR-2017-2018 | P2_Abstraccion/include/cronologia.h | /**
* @file cronologia.h
* @brief Fichero cabecera del TDA Cronologia
*
*/
#ifndef __CRONOLOGIA
#define __CRONOLOGIA
#include <iostream>
#include <vector>
#include "fechahistorica.h"
using namespace std;
/**
* @brief T.D.A. Cronologia
*
* Una instancia @e c del tipo de datos abstracto @c Cronologia e... |
JeanVinge/OHHTTPStubsExample | OHHTTPStubs/Constants.h | <filename>OHHTTPStubs/Constants.h
//
// Constants.h
// OHHTTPStubs
//
// Created by <NAME> on 27/10/15.
// Copyright © 2015 <NAME>. All rights reserved.
//
#ifndef Constants_h
#define Constants_h
static NSString *const kAPIBase = @"https://tests.com";
static NSString *const kPathTest = @"tests";
#endif /* Consta... |
JeanVinge/OHHTTPStubsExample | OHHTTPStubs/Client.h | <reponame>JeanVinge/OHHTTPStubsExample
//
// Client.h
// Wattpad-app
//
// Created by <NAME> on 24/08/15.
// Copyright (c) 2015 <NAME>. All rights reserved.
//
#import <AFNetworking/AFHTTPRequestOperationManager.h>
@interface Client : AFHTTPRequestOperationManager
+ (instancetype)sharedInstance;
- (void)testsWi... |
JeanVinge/OHHTTPStubsExample | OHHTTPStubs/ViewController.h | <reponame>JeanVinge/OHHTTPStubsExample
//
// ViewController.h
// OHHTTPStubs
//
// Created by <NAME> on 27/10/15.
// Copyright © 2015 <NAME>. All rights reserved.
//
#import <UIKit/UIKit.h>
@interface ViewController : UIViewController
@end
|
JeanVinge/OHHTTPStubsExample | OHHTTPStubs/StubRequests.h | //
// StubRequests.h
// OHHTTPStubs
//
// Created by <NAME> on 27/10/15.
// Copyright © 2015 <NAME>. All rights reserved.
//
#import <Foundation/Foundation.h>
@interface StubRequests : NSObject
+ (void)mockTest;
@end
|
nilsreichardt/Agora-Flutter-RTM-SDK | ios/Classes/RTMChannel.h | //
// RTMChannel.h
// agora_rtm
//
// Created by LY on 2019/8/16.
//
#import <AgoraRtmKit/AgoraRtmKit.h>
#import <Flutter/Flutter.h>
@interface RTMChannel : NSObject<FlutterStreamHandler, AgoraRtmChannelDelegate>
@property (strong, nonatomic) NSObject<FlutterBinaryMessenger> *messenger;
@property (strong, nona... |
nilsreichardt/Agora-Flutter-RTM-SDK | ios/Classes/RTMClient.h | <filename>ios/Classes/RTMClient.h
//
// RTMClient.h
// agora_rtm
//
// Created by LY on 2019/8/15.
//
#import <AgoraRtmKit/AgoraRtmKit.h>
#import <Flutter/Flutter.h>
#import "RTMChannel.h"
@interface RTMClient : NSObject<FlutterStreamHandler, AgoraRtmDelegate, AgoraRtmCallDelegate>
@property (strong, nonatomic) ... |
1320014053/V8-debugger | debugger.h | <gh_stars>0
#pragma once
#pragma warning(disable:4996)
#define JumpIfFalseHandler 0 |
DossierSansTitreEx/MiaouOS | include/stddef.h | <reponame>DossierSansTitreEx/MiaouOS
#ifndef _STDDEF_H
#define _STDDEF_H 1
#include <sys/cdefs.h>
#include <sys/_types/_null.h>
#define offsetof(st, m) __builtin_offsetof(st, m)
#include <sys/_types/_ptrdiff_t.h>
#include <sys/_types/_wchar_t.h>
#include <sys/_types/_size_t.h>
#endif
|
DossierSansTitreEx/MiaouOS | include/sys/_types/_ssize_t.h | #ifndef _SYS__TYPES__SSIZE_T_H_
#define _SYS__TYPES__SSIZE_T_H_
#if (__SIZEOF_SIZE_T__ == 8)
typedef __INT64_TYPE__ ssize_t;
#endif
#endif
|
DossierSansTitreEx/MiaouOS | src/effel/mfs.h | <gh_stars>1-10
#ifndef _EFFEL_MFS_H
#define _EFFEL_MFS_H 1
#include <stddef.h>
#include <stdint.h>
#include <boot/boot_params.h>
struct mfs
{
uint8_t device;
uint64_t lba;
struct dpte dpte;
uint64_t root;
char* buffers[4];
};
struct mfs_fileinfo_
{
uint64_t inode;
uint6... |
DossierSansTitreEx/MiaouOS | src/boot/stage3.c | <gh_stars>1-10
#include <boot/boot_params.h>
#define PAGESIZE 4096
struct file_info_
{
uint64_t size;
uint64_t data[12];
uint64_t idata;
};
typedef struct file_info_ file_info;
void disk_read(void* dst, uint64_t lba, uint64_t count, void* dpte);
static volatile char* monitor;
static uint16_... |
DossierSansTitreEx/MiaouOS | src/effel/tss.h | <gh_stars>1-10
#ifndef TSS_H
#define TSS_H
#include <stdint.h>
struct tss
{
uint32_t zero1;
uint64_t rsp[3];
uint64_t zero2;
uint64_t ist[8];
uint64_t zero3;
uint16_t zero4;
uint16_t iomb;
} __attribute__ ((packed, aligned(16)));
extern struct tss tss;
void tss_init();
#endif
|
DossierSansTitreEx/MiaouOS | src/effel/vmm.h | <gh_stars>1-10
#ifndef _VMM_H
#define _VMM_H 1
#include <stddef.h>
#include <boot/boot_params.h>
#define PAGESIZE 4096
#define VMM_WRITE 0x00000002
#define VMM_USER 0x00000004
void vmm_init(boot_params* params);
void* vmm_alloc_over(uint64_t physical_addr, size_t size, uint32_t flags);
void* ... |
DossierSansTitreEx/MiaouOS | src/effel/proc.h | #ifndef _EFFEL_PROC_
#define _EFFEL_PROC_ 1
#include <stdint.h>
#include <stddef.h>
#define P_PRESENT 1
typedef uint64_t proc_id;
struct cpu_state
{
/* iret-style state */
uint64_t ss;
uint64_t rsp;
uint64_t rflags;
uint64_t cs;
uint64_t rip;
/* regulat state */
... |
DossierSansTitreEx/MiaouOS | src/effel/syscall.c | #include <syscall.h>
#include <stdint.h>
#include <stddef.h>
#include <screen.h>
void* sys_table[512];
void syscall_handler();
void syscall_set_handler(void* handler);
void sys_write(int fd, const void* mem, size_t size)
{
(void)fd;
kprint_raw(mem, size);
}
void syscall_init()
{
sys_table[0x01] = sys_wr... |
DossierSansTitreEx/MiaouOS | src/libc/string/strrchr.c | <reponame>DossierSansTitreEx/MiaouOS
#include <string.h>
char* strrchr(const char* s, int c)
{
char cc;
char sc;
size_t i;
cc = c;
i = strlen(s) + 1;
while (i--)
{
sc = s[i - 1];
if (sc == cc)
return (char*)s + i;
}
return NULL;
}
|
DossierSansTitreEx/MiaouOS | include/sys/_types/_uintmax_t.h | #ifndef _SYS__TYPES__UINTMAX_T_H_
#define _SYS__TYPES__UINTMAX_T_H_
typedef unsigned long long uintmax_t;
#endif
|
DossierSansTitreEx/MiaouOS | include/sys/_types/_int32_t.h | <filename>include/sys/_types/_int32_t.h
#ifndef _SYS__TYPES__INT32_T_H_
#define _SYS__TYPES__INT32_T_H_
#if defined(__INT32_TYPE__)
typedef __INT32_TYPE__ int32_t;
#endif
#endif
|
DossierSansTitreEx/MiaouOS | src/effel/vmm.c | <filename>src/effel/vmm.c
#include <string.h>
#include <vmm.h>
#include <util.h>
#define PAGE_MASK 0xfffffffffffff000
#define PAGE_RECURSE 0x1fe
#define PAGES_PER_TABLE 512
#define KERNEL_HEAP_BASE 0xffffffffc0000000
typedef struct
{
uint64_t base;
uint64_t length;
} vmm_mem_stor... |
DossierSansTitreEx/MiaouOS | src/libc/string/memcmp.c | #include <string.h>
int memcmp(const void* s1, const void* s2, size_t n)
{
const unsigned char* u1;
const unsigned char* u2;
int diff;
u1 = s1;
u2 = s2;
for (size_t i = 0; i < n; ++i)
{
diff = (int)(u1[i]) - (int)(u2[i]);
if (diff)
return diff;
}
return ... |
DossierSansTitreEx/MiaouOS | src/effel/interrupt.h | <reponame>DossierSansTitreEx/MiaouOS<gh_stars>1-10
#ifndef _INTERRUPT_H
#define _INTERRUPT_H 1
void irq_enable(uint8_t line);
void irq_disable(uint8_t line);
void interrupt_register(uint8_t slot, void* isr);
void interrupt_init();
#endif
|
DossierSansTitreEx/MiaouOS | include/unistd.h | <filename>include/unistd.h
#ifndef _UNISTD_H
#define _UNISTD_H 1
#include <sys/cdefs.h>
#include <sys/_types/_size_t.h>
#include <sys/_types/_ssize_t.h>
#ifndef __KERNEL
__BEGIN_DECL
ssize_t write(int fd, const void* buf, size_t len);
__END_DECL
#endif
#endif
|
DossierSansTitreEx/MiaouOS | include/sys/_types/_intmax_t.h | #ifndef _SYS__TYPES__INTMAX_T_H_
#define _SYS__TYPES__INTMAX_T_H_
typedef long long intmax_t;
#endif
|
DossierSansTitreEx/MiaouOS | src/libc/string/strcmp.c | #include <string.h>
int strcmp(const char* s1, const char* s2)
{
size_t i;
int diff;
int c1;
int c2;
i = 0;
for (;;)
{
c1 = (unsigned char)(s1[i]);
c2 = (unsigned char)(s2[i]);
diff = c1 - c2;
if (diff)
return diff;
if (c1 == 0)
... |
DossierSansTitreEx/MiaouOS | include/sys/cpuinfo.h | <gh_stars>1-10
#ifndef _SYS_CPUINFO_H_
#define _SYS_CPUINFO_H_
#include <sys/cdefs.h>
#include <sys/cpuid.h>
#define CPUINFO_SSE (1 << 0)
#define CPUINFO_SSE2 (1 << 1)
#define CPUINFO_SSE3 (1 << 2)
#define CPUINFO_SSSE3 (1 << 3)
#define CPUINFO_SSE4_1 (1 << 4)
#define CPUINFO_SSE4_2 (1 << 5)
#define CPU... |
DossierSansTitreEx/MiaouOS | include/sys/_types/_uint16_t.h | #ifndef _SYS__TYPES__UINT16_T_H_
#define _SYS__TYPES__UINT16_T_H_
#if defined(__UINT16_TYPE__)
typedef __UINT16_TYPE__ uint16_t;
#endif
#endif
|
DossierSansTitreEx/MiaouOS | src/effel/util.h | #ifndef _UTIL_H
#define _UTIL_H 1
static inline void magic_break()
{
__asm__ __volatile__ ("xchg %bx, %bx");
}
#endif
|
DossierSansTitreEx/MiaouOS | include/string.h | <gh_stars>1-10
#ifndef _STRING_H
#define _STRING_H 1
#include <sys/cdefs.h>
#include <sys/_types/_null.h>
#include <sys/_types/_size_t.h>
__BEGIN_DECL
void* memcpy(void* __restrict dst, const void* __restrict src, size_t n);
void* memmove(void* dst, const void* src, size_t len);
void* memchr(const void* s, int... |
DossierSansTitreEx/MiaouOS | src/libc/string/memchr.c | <reponame>DossierSansTitreEx/MiaouOS
#include <string.h>
void* memchr(const void* s, int c, size_t num)
{
unsigned char* cptr;
unsigned char cc;
cptr = (unsigned char*)s;
cc = c;
for (size_t i = 0; i < num; ++i)
{
if (cptr[i] == cc)
return cptr + i;
}
return NULL;
... |
DossierSansTitreEx/MiaouOS | include/stdlib.h | <filename>include/stdlib.h
#ifndef _STDLIB_H
#define _STDLIB_H 1
#include <sys/cdefs.h>
__BEGIN_DECL
void abort(void) __attribute__((noreturn));
__END_DECL
#endif
|
DossierSansTitreEx/MiaouOS | include/stdint.h | <reponame>DossierSansTitreEx/MiaouOS
#ifndef _STDINT_H
#define _STDINT_H 1
#include <sys/cdefs.h>
#include <sys/_types/_int8_t.h>
#include <sys/_types/_int16_t.h>
#include <sys/_types/_int32_t.h>
#include <sys/_types/_int64_t.h>
#include <sys/_types/_uint8_t.h>
#include <sys/_types/_uint16_t.h>
#include <sys/_types/... |
DossierSansTitreEx/MiaouOS | src/libc/string/memmove.c | <filename>src/libc/string/memmove.c<gh_stars>1-10
#include <string.h>
void* memmove(void* dst, const void* src, size_t len)
{
char* dst_ptr;
const char* src_ptr;
size_t i;
dst_ptr = dst;
src_ptr = src;
/* No overlap */
if (src_ptr + len < dst_ptr || dst_ptr + len < src_ptr)
return... |
DossierSansTitreEx/MiaouOS | src/effel/gdt.h | #ifndef _GDT_H
#define _GDT_H 1
void gdt_init();
#endif
|
DossierSansTitreEx/MiaouOS | include/sys/cdefs.h | #ifndef _SYS_CDEFS_H_
#define _SYS_CDEFS_H_
#if !defined(__GNUC__)
# define __attribute__(x)
#endif
#if defined(__cplusplus)
# define __BEGIN_DECL extern "C" {
# define __END_DECL }
# define __restrict
#else
# define __BEGIN_DECL
# define __END_DECL
# define __restrict restrict
#endif
#endif
|
DossierSansTitreEx/MiaouOS | src/libc/string/strncpy.c | <reponame>DossierSansTitreEx/MiaouOS<filename>src/libc/string/strncpy.c
#include <string.h>
char* strncpy(char* dst, const char* src, size_t n)
{
size_t i;
char c;
for (i = 0; i < n; ++i)
{
c = src[i];
dst[i] = c;
if (c == 0)
break;
i++;
}
for (i = 0... |
DossierSansTitreEx/MiaouOS | include/stdbool.h | <filename>include/stdbool.h
#ifndef _STDBOOL_H
#define _STDBOOL_H 1
#define bool _Bool
#define true 1
#define false 0
#define __bool_true_false_are_defined 1
#endif
|
DossierSansTitreEx/MiaouOS | src/effel/screen.c | <reponame>DossierSansTitreEx/MiaouOS
#include <stdint.h>
#include <string.h>
#include <screen.h>
#include <vmm.h>
static char* monitor;
static int32_t cursor_x;
static int32_t cursor_y;
void kscroll()
{
memmove(monitor, monitor + 80 * 2, 80 * 24 * 2);
memset(monitor + 80 * 24 * 2, 0, 80 * 2);
cursor_x = 0... |
DossierSansTitreEx/MiaouOS | include/sys/_types/_size_t.h | #ifndef _SYS__TYPES__SIZE_T_H_
#define _SYS__TYPES__SIZE_T_H_
#if defined(__SIZE_TYPE__)
typedef __SIZE_TYPE__ size_t;
#endif
#endif
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.