code
stringlengths 3
1.01M
| repo_name
stringlengths 5
116
| path
stringlengths 3
311
| language
stringclasses 30
values | license
stringclasses 15
values | size
int64 3
1.01M
|
|---|---|---|---|---|---|
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
<title>Examples</title>
<meta name="description" content="">
<meta name="keywords" content="">
<link href="" rel="stylesheet">
<style type="text/css">
.bg{
background: url('D6Q5_@F95YCMK}XWS4@L5W.gif') repeat;
}
.ads{position:relative;
top:50%;left:50%;width:100px;height:100px;border:1px solid #f00;boredr-radius:50px;}
</style>
</head>
<body>
<div id='ads'>Loading...</div>
<audio src='究刺少女大百合 - 【哲学】新日暮里电♂音节-Astronomia【强烈推荐】.mp3' autoplay="autoplay" loop="loop" preload="preload">
<script type="text/javascript">
var ads=document.getElementById('ads');
function completeloading(){
if(document.readyState=='complete'){ads.style.display = 'none'}
}
document.onreadystatechange=completeloading;
window.onload=function(){
document.body.style.background="url('D6Q5_@F95YCMK}XWS4@L5W.gif') repeat";}
</script>
</body>
</html>
|
kyuUryuU/xinrimuli
|
index.html
|
HTML
|
mit
| 1,007
|
using System;
namespace FF9
{
public enum command_data_buf_tags
{
CB_NORMAL,
CB_COUNTER,
CB_SYSTEM,
CB_W_COMMAND,
CB_TRANCE,
CB_RERAISE,
CB_MAX
}
}
|
Albeoris/Memoria
|
Assembly-CSharp/FF9/command_data_buf_tags.cs
|
C#
|
mit
| 169
|
body {
font-family: "Droid Sans Mono", monospace;
}
.limited-row {
margin: auto;
max-width: 600px;
}
.custom-input {
border-color: #6c757d;
}
.custom-input:focus {
border-color: #6c757d;
box-shadow: 0 0 0 0.2rem rgba(108, 117, 125, .5);
}
.custom-input:disabled {
opacity: .65;
}
.custom-input.is-valid, .custom-input.is-invalid {
background-image: none;
}
#download-button:disabled {
background-color: #e9ecef;
}
|
ClaudiuGeorgiu/PlaystoreDownloader
|
static/site.css
|
CSS
|
mit
| 456
|
module L {
export class Operator1 extends LogicElement {
constructor(
private operation: string, // string reprasenting given operation, like -, + etc.
public log_operand: LogicElement,
private hadSideEffects: boolean
) {
super();
this.logicFunction =
new L.FunctionCall(
new L.Path(this.log_operand, this.operation).setAsInternalOperation(),
[]
).setAsInternalOperation();
}
logicFunction: LogicElement;
_compile(environment: Compiler.TypeEnvironment): boolean {
this.cs = this.logicFunction.compile(environment) && this.cs;
this.errorIfEmpty(this.log_operand);
if (this.log_operand.cs)
this.errorIfNot(this.cs, 'These two values cannot be aplied to this operator');
if (!this.cs) return false;
this.returns = this.logicFunction.returns;
return this.cs;
}
*execute(environment: Memory.Environment): IterableIterator<Operation> {
yield* this.logicFunction.run(environment);
environment.passTempValue();
if (this.hadSideEffects)
yield Operation.memory(this);
else
yield Operation.tempMemory(this);
return;
}
}
}
module E {
abstract class Operator1 extends Element {
c_operand: C.DropField
elemType; // class of descent of this class, which defines new operator
operator: string;
private hadSideEffects;
constructor(elemType, operator: string, post: boolean, left: E.Element = null, sideEffects: boolean = false) {
super();
this.c_operand = new C.DropField(this, left),
this.initialize(
post ?
[[this.c_operand, new C.Label(operator)]] :
[[new C.Label(operator), this.c_operand]]
, ElementType.Math);
this.elemType = elemType;
this.operator = post ? '_' + operator : operator;
this.hadSideEffects = sideEffects;
}
constructCode(): L.LogicElement {
var logic = new L.Operator1(
this.operator,
this.c_operand.constructCode(),
this.hadSideEffects
);
logic.setObserver(this);
return logic;
}
getCopy(): Element {
return new this.elemType(
this.c_operand.getContentCopy()).copyMetadata(this);
}
}
/////////////// Operators ////////////////////
export class Increment extends Operator1 {
getJSONName() { return 'Increment' }
constructor(a: E.Element = null) {
super(Increment, '++', false, a, true);
}
}
export class Decrement extends Operator1 {
getJSONName() { return 'Decrement' }
constructor(a: E.Element = null) {
super(Decrement, '--', false, a, true);
}
}
export class PostIncrement extends Operator1 {
getJSONName() { return 'PostIncrement' }
constructor(a: E.Element = null) {
super(PostIncrement, '++', true, a, true);
}
}
export class PostDecrement extends Operator1 {
getJSONName() { return 'PostDecrement' }
constructor(a: E.Element = null) {
super(PostDecrement, '--', true, a, true);
}
}
export class Print extends Operator1 {
getJSONName() { return 'Print' }
constructor(a: E.Element = null) {
super(Print, 'print', false, a, true);
}
}
export class Scan extends Operator1 {
getJSONName() { return 'Scan' }
constructor(a: E.Element = null) {
super(Scan, 'scan', false, a, true);
}
}
export class Not extends Operator1 {
getJSONName() { return 'Not' }
constructor(a: E.Element = null) {
super(Not, '!', false, a);
}
}
}
|
TomaszRewak/TREPL
|
Source/scripts/compiler/Elements/Operator1.ts
|
TypeScript
|
mit
| 4,094
|
using GenderPayGap.Core.Abstractions;
namespace GenderPayGap.Core.Models
{
public class OrganisationRegistrationDeclinedTemplate : AEmailTemplate
{
public string Reason { get; set; }
}
}
|
DFEAGILEDEVOPS/gender-pay-gap
|
Beta/GenderPayGap.Core/Models/EmailTemplates/OrganisationRegistrationDeclinedTemplate.cs
|
C#
|
mit
| 215
|
import Instruction from './Instruction';
import Container from './Container';
import Share from './Share';
import React from 'react';
import request from 'superagent';
var Mememe = React.createClass({
getInitialState (){
var memesGenerated = false;
return{
memesGenerated: memesGenerated
};
},
generateMemes (descriptions){
for(var key in descriptions) {
var VALUE = descriptions[key];
var YOUR_API_KEY = "xxx";
var YOUR_CSE_ID = "yyy";
var searchQuery = `https://www.googleapis.com/customsearch/v1?key=${YOUR_API_KEY}&cx=${YOUR_CSE_ID}&q=${VALUE}&searchType=image&fileType=jpg&imgSize=small&alt=json`
request
.get(searchQuery)
.end((err, results) => {
debugger
})
debugger
}
var memesGenerated = true;
this.setState({memesGenerated: memesGenerated});
},
render (){
var generateMemes = this.generateMemes;
var memesGenerated = this.state.memesGenerated;
return (
<div className="mememe">
<Instruction/>
<Container
memesGenerated={memesGenerated}
generateMemes={generateMemes}/>
<Share/>
</div>
)
}
});
module.exports = Mememe;
|
amysimmons/mememe
|
src/Mememe.js
|
JavaScript
|
mit
| 1,230
|
---
layout: page
title: Contact Me
permalink: /contact/
tags: contact
---
<div class="py2">
{% if site.ajaxify_contact_form %}
<form class="form-stacked">
<input type="text" name="email" class="field-light" placeholder="{{ site.text.contact.email }}">
<textarea type="text" name="content" class="field-light" rows="5" placeholder="{{ site.text.contact.content }}" style="resize: vertical"></textarea>
<input type="text" name="_gotcha" style="display:none" />
<button type='submit' class="button button-blue button-big mobile-block">{{ site.text.contact.submit }}</button>
</form>
{% else %}
<form action="https://formspree.io/{{ site.email }}" method="POST" class="form-stacked">
<input type="text" name="email" class="field-light" placeholder="{{ site.text.contact.email }}" value="{{ site.email }}">
<textarea type="text" name="content" class="field-light" rows="5" placeholder="{{ site.text.contact.content }}" style="resize: vertical"></textarea>
<input type="hidden" name="_next" value="{{ site.baseurl }}/thanks/" />
<input type="hidden" name="_subject" value="{{ site.text.contact.subject }}" />
<input type="text" name="_gotcha" style="display:none" />
<input type="submit" class="button button-blue button-big mobile-block" value="{{ site.text.contact.submit }}">
</form>
{% endif %}
</div>
{% if site.ajaxify_contact_form %}
{% include ajaxify_content_form.html %}
{% endif %}
|
ZDYoung/zdyoung.github.io
|
contact.html
|
HTML
|
mit
| 1,473
|
#include "SoundObject.hpp"
#include <iostream>
namespace mv
{
bool SoundObject::EmplaceSound( const std::string & name )
{
if ( sounds.find( name ) != sounds.end() )
{
Logger::Log( constants::error::soundObject::ALREADY_EXIST, Logger::STREAM::CONSOLE, Logger::TYPE::WARNING );
return false;
}
sf::SoundBuffer soundBuffer;
if ( !soundBuffer.loadFromFile( "data/sounds/" + name ) )
{
return false;
}
sf::Sound sound;
soundSource.push_back( std::pair<sf::Sound, sf::SoundBuffer>( sound, soundBuffer ) );
soundSource.back().first.setBuffer( soundSource.back().second );
sounds.emplace( std::pair<std::string, int>( name, sounds.size() ) );
return true;
}
int8_t SoundObject::GetNumberOfSound( const std::string & name )
{
auto itr = sounds.find( name );
if ( itr == sounds.end() )
{
Logger::Log( constants::error::soundObject::DOES_NOT_EXIST_IN_SYSTEM, Logger::STREAM::CONSOLE, Logger::TYPE::WARNING );
return -1;
}
else return itr->second;
}
bool SoundObject::EraseSound( const std::string & name )
{
auto soundIterator = sounds.find( name );
if ( soundIterator == sounds.end() )
{
Logger::Log( constants::error::soundObject::DOES_NOT_EXIST_IN_SYSTEM, Logger::STREAM::CONSOLE, Logger::TYPE::WARNING );
return false;
}
int8_t number = soundIterator->second;
auto soundSourceIterator = soundSource.begin() + soundIterator->second;
sounds.erase( soundIterator );
soundSource.erase( soundSourceIterator );
return true;
}
bool SoundObject::PlaySound( const std::string & name )
{
if ( !IsSoundExist( name ) )
{
Logger::Log( constants::error::soundObject::DOES_NOT_EXIST_IN_SYSTEM, Logger::STREAM::CONSOLE, Logger::TYPE::WARNING );
return false;
}
for ( auto&var : sounds )
{
std::cout << var.first << " " << var.second << std::endl;
}
soundSource[sounds[name]].first.play();
return true;
}
}
|
mvxxx/Tiles-Map-Simple-Editor
|
Editor/source/MV/soundObject/SoundObject.cpp
|
C++
|
mit
| 1,908
|
# napp-boilerplate
WIP boilerplate for node web applications.
## Install
```sh
$ npm install
```
## Usage
Run Express server:
```sh
$ npm start
```
Build JS applications:
```sh
$ npm run build
$ npm run build.prd (files are concatenated & minified)
```
## The Stack
Made with OSS <3.
- [AngularJS](https://angularjs.org)
- [Bootstrap 3](http://getbootstrap.com)
- [Bower](http://bower.io)
- [Express](http://expressjs.com)
- [Gulp](http://gulpjs.com)
- [JSHint](http://www.jshint.com)
- [node.js](http://nodejs.org)
- [Stylus](http://learnboost.github.io/stylus/)
## License
[MIT](LICENSE)
## Contribute
Pull Requests always welcome, as well as any feedback or issues.
|
nesbert/napp-boilerplate
|
README.md
|
Markdown
|
mit
| 681
|
/*
* AVFRAMEINFO.h
* Define AVFRAME Info
* Created on:2013-08-12
* Last update on:2013-10-07
* Author: UBIA
*
*
*/
#ifndef _AVFRAME_INFO_H_
#define _AVFRAME_INFO_H_
/* CODEC ID */
typedef enum
{
MEDIA_CODEC_UNKNOWN = 0x00,
MEDIA_CODEC_VIDEO_MPEG4 = 0x4C,
MEDIA_CODEC_VIDEO_H263 = 0x4D,
MEDIA_CODEC_VIDEO_H264 = 0x4E,
MEDIA_CODEC_VIDEO_MJPEG = 0x4F,
MEDIA_CODEC_AUDIO_ADPCM = 0X8B,
MEDIA_CODEC_AUDIO_PCM = 0x8C,
MEDIA_CODEC_AUDIO_SPEEX = 0x8D,
MEDIA_CODEC_AUDIO_MP3 = 0x8E,
MEDIA_CODEC_AUDIO_G726 = 0x8F,
}ENUM_CODECID;
/* FRAME Flag */
typedef enum
{
IPC_FRAME_FLAG_PBFRAME = 0x00, // A/V P/B frame..
IPC_FRAME_FLAG_IFRAME = 0x01, // A/V I frame.
IPC_FRAME_FLAG_MD = 0x02, // For motion detection.
IPC_FRAME_FLAG_IO = 0x03, // For Alarm IO detection.
}ENUM_FRAMEFLAG;
typedef enum
{
AUDIO_SAMPLE_8K = 0x00,
AUDIO_SAMPLE_11K = 0x01,
AUDIO_SAMPLE_12K = 0x02,
AUDIO_SAMPLE_16K = 0x03,
AUDIO_SAMPLE_22K = 0x04,
AUDIO_SAMPLE_24K = 0x05,
AUDIO_SAMPLE_32K = 0x06,
AUDIO_SAMPLE_44K = 0x07,
AUDIO_SAMPLE_48K = 0x08,
}ENUM_AUDIO_SAMPLERATE;
typedef enum
{
AUDIO_DATABITS_8 = 0,
AUDIO_DATABITS_16 = 1,
}ENUM_AUDIO_DATABITS;
typedef enum
{
AUDIO_CHANNEL_MONO = 0,
AUDIO_CHANNEL_STERO = 1,
}ENUM_AUDIO_CHANNEL;
/* Audio Frame: flags = (samplerate << 2) | (databits << 1) | (channel) */
/* Audio/Video Frame Header Info */
typedef struct _FRAMEINFO
{
unsigned short codec_id; // Media codec type defined in sys_mmdef.h,
// MEDIA_CODEC_AUDIO_PCMLE16 for audio,
// MEDIA_CODEC_VIDEO_H264 for video.
unsigned char flags; // Combined with IPC_FRAME_xxx.
unsigned char cam_index; // 0 - n
unsigned char onlineNum; // number of client connected this device
unsigned char reserve1[3];
unsigned int reserve2; //
unsigned int timestamp; // Timestamp of the frame, in milliseconds
// unsigned int videoWidth;
// unsigned int videoHeight;
}FRAMEINFO_t;
#endif
|
gb-6k-house/PIXPO-HD
|
KitchenSink/ubiastack/include/P4PCam/AVFRAMEINFO.h
|
C
|
mit
| 1,971
|
version https://git-lfs.github.com/spec/v1
oid sha256:2cb956200f1ddeebd2c2ee83cbd9bb8621fea85e7fb619d19d64835bce2098ff
size 3005
|
yogeshsaroya/new-cdnjs
|
ajax/libs/metrics-graphics/0.2.0/css/metrics-graphics.min.css
|
CSS
|
mit
| 129
|
/* -*- C++ -*- */
//=============================================================================
/**
* @file Configuration.h
*
* $Id: Configuration.h 78476 2007-05-24 07:55:50Z johnnyw $
*
* @author Chris Hafey <chafey@stentor.com>
*
* The ACE configuration API provides a portable abstraction for
* program configuration similar to the Microsoft Windows registry.
* The API supports a tree based hierarchy of configuration sections. Each
* section contains other sections or values. Values may contain string,
* unsigned integer and binary data.
*
* @note These classes are not thread safe, if multiple threads use these
* classes, you are responsible for serializing access.
*
* For examples of using this class, see:
* -# The test code in ACE_wrappers/test
* -# wxConfigViewer, a Windows like Registry Editor for ACE_Configuration
* -# TAO's IFR, it makes extensive use of ACE_Configuration
*
* @todo Templatize this class with an ACE_LOCK to provide thread safety
*
*/
//=============================================================================
#ifndef ACE_CONFIGURATION_H
#define ACE_CONFIGURATION_H
#include /**/ "ace/pre.h"
#include "ace/SStringfwd.h"
#include "ace/Hash_Map_With_Allocator_T.h"
#include "ace/Malloc_T.h"
#include "ace/MMAP_Memory_Pool.h"
#include "ace/Local_Memory_Pool.h"
#include "ace/Synch_Traits.h"
#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */
// configurable parameters
#if !defined (ACE_CONFIG_SECTION_INDEX)
# define ACE_CONFIG_SECTION_INDEX "Config_Section_Index"
#endif /* ! ACE_CONFIG_SECTION_INDEX */
#if !defined (ACE_DEFAULT_CONFIG_SECTION_SIZE)
#define ACE_DEFAULT_CONFIG_SECTION_SIZE 16
#endif /* ACE_DEFAULT_CONFIG_SECTION_SIZE */
ACE_BEGIN_VERSIONED_NAMESPACE_DECL
/**
* @class ACE_Section_Key_Internal
*
* @internal
*
* @brief A base class for internal handles to section keys for
* configuration implementations
*
* Implementations subclass this base class to represent a
* section key.
*
*/
class ACE_Export ACE_Section_Key_Internal
{
public:
/// Virtual destructor, make sure descendants are virtual!
virtual ~ACE_Section_Key_Internal (void);
/// Increment reference count
virtual int add_ref (void);
/// Decrement reference count. Will delete this if count gets to 0
virtual int dec_ref (void);
protected:
ACE_Section_Key_Internal (void);
ACE_Section_Key_Internal (const ACE_Section_Key_Internal& rhs);
ACE_Section_Key_Internal& operator= (ACE_Section_Key_Internal& rhs);
u_int ref_count_;
};
/**
* @class ACE_Configuration_Section_Key
*
* @brief Reference counted wrapper for ACE_Section_Key_Internal.
*
* Reference counted wrapper class for the abstract internal
* section key. A user gets one of these to represent a section
* in the configuration database.
*/
class ACE_Export ACE_Configuration_Section_Key
{
friend class ACE_Configuration;
public:
/// Default constructor.
ACE_Configuration_Section_Key (void);
/// Constructor that initializes to a pointer to a concrete internal key.
/**
* @param key The section key to reference. Calls add_ref() with @a key.
*/
explicit ACE_Configuration_Section_Key (ACE_Section_Key_Internal *key);
/// Copy constructor, increments the reference count on the key.
ACE_Configuration_Section_Key (const ACE_Configuration_Section_Key &rhs);
/// Destructor, decrements reference count on the referenced key.
~ACE_Configuration_Section_Key (void);
/// Assignment operator, increments reference count for this object
/// and decrements it on @a rhs.
ACE_Configuration_Section_Key &
operator= (const ACE_Configuration_Section_Key &rhs);
private:
ACE_Section_Key_Internal *key_;
};
/**
* @class ACE_Configuration
*
* @internal
*
* @brief Base class for configuration databases
*
* This class provides an interface for configuration databases. A concrete
* class is required that implements the interface.
*
* @sa ACE_Configuration_Heap
* @sa ACE_Configuration_Win32Registry
*/
class ACE_Export ACE_Configuration
{
public:
/// Enumeration for the various types of values we can store.
enum VALUETYPE
{
STRING,
INTEGER,
BINARY,
INVALID
};
/// Destructor
virtual ~ACE_Configuration (void);
/// Obtain a reference to the root section of this configuration.
/*
* @return Reference to the configuration's root section. Note that
* it is a const reference.
*/
virtual const ACE_Configuration_Section_Key& root_section (void) const;
/**
* Opens a named section in an existing section.
*
* @param base Existing section in which to open the named section.
* @param sub_section Name of the section to open.
* @param create If zero, the named section must exist. If non-zero,
* the named section will be created if it does not exist.
* @param result Reference; receives the section key for the new
* section.
*
* @retval 0 for success.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int open_section (const ACE_Configuration_Section_Key &base,
const ACE_TCHAR *sub_section,
int create,
ACE_Configuration_Section_Key& result) = 0;
/// Removes a named section.
/**
* @param key Section key to remove the named section from.
* @param sub_section Name of the section to remove.
* @param recursive If non zero, any subkeys below @a sub_section are
* removed as well.
*
* @retval 0 for success.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int remove_section (const ACE_Configuration_Section_Key &key,
const ACE_TCHAR *sub_section,
int recursive) = 0;
/**
* Enumerates through the values in a section.
*
* @param key Section key to iterate through.
* @param index Iteration position. Must be zero on the first call to
* iterate through @a key. Increment @a index by one on each
* successive call to this method.
* @param name Receives the value's name.
* @param type Receives the value's data type.
*
* @note You may not delete or add values while enumerating. If the
* section is modified during enumeration, results are undefined;
* you must restart the enumeration from index 0.
*
* @retval 0 for success, @a name and @a type are valid.
* @retval 1 there are no more values in the section.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int enumerate_values (const ACE_Configuration_Section_Key& key,
int index,
ACE_TString& name,
VALUETYPE& type) = 0;
/**
* Enumerates through the subsections in a section.
*
* @param key Section key to iterate through.
* @param index Iteration position. Must be zero on the first call to
* iterate through @a key. Increment @a index by one on each
* successive call to this method.
* @param name Receives the subsection's name.
*
* @note You may not modify the @a key section while enumerating. If the
* section is modified during enumeration, results are undefined;
* you must restart the enumeration from index 0.
*
* @retval 0 for success, @a name has a valid name.
* @retval 1 there are no more subsections in the section.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int enumerate_sections (const ACE_Configuration_Section_Key& key,
int index, ACE_TString& name) = 0;
/// Sets a string-typed value.
/**
* @param key Configuration section to set the value in.
* @param name Name of the configuration value to set. If a value with
* the specified name exists, it is replaced.
* @param value The string to set the configuration value to.
*
* @retval 0 for success.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int set_string_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
const ACE_TString& value) = 0;
/// Sets a integer-typed value.
/**
* @param key Configuration section to set the value in.
* @param name Name of the configuration value to set. If a value with
* the specified name exists, it is replaced.
* @param value The integer to set the configuration value to.
*
* @retval 0 for success.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int set_integer_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
u_int value) = 0;
/// Sets a binary-typed value.
/**
* @param key Configuration section to set the value in.
* @param name Name of the configuration value to set. If a value with
* the specified name exists, it is replaced.
* @param data Pointer to the binary data for the value.
* @param length Number of bytes for the new value.
*
* @retval 0 for success.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int set_binary_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
const void* data,
size_t length) = 0;
/// Gets a string-typed value.
/**
* @param key Configuration section to get the value from.
* @param name Name of the configuration value to get.
* @param value Receives the configuration value if it exists and
* has type STRING.
*
* @retval 0 for success.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int get_string_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
ACE_TString& value) = 0;
/// Gets an integer-typed value.
/**
* @param key Configuration section to get the value from.
* @param name Name of the configuration value to get.
* @param value Receives the configuration value if it exists and
* has type INTEGER.
*
* @retval 0 for success.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int get_integer_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
u_int& value) = 0;
/// Gets a binary-typed value.
/**
* @param key Configuration section to get the value from.
* @param name Name of the configuration value to get.
* @param data Receives a pointer to memory holding the binary data
* for the value. This method allocates the memory pointed
* to using operator new[]. The caller is responsible for
* freeing the memory using operator delete[].
* @param length Receives the number of bytes in the value.
*
* @retval 0 for success; caller is responsible for freeing the
* returned memory.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int get_binary_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
void*& data,
size_t& length) = 0;
/**
* Retrieves the type of a named configuration value.
*
* @param key Configuration section to look up the name in.
* @param name Name of the configuration value to get the type of.
* @param type Receives the data type of the named value, if it exists.
*
* @retval 0 for success.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int find_value(const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
VALUETYPE& type) = 0;
/// Removes a named value.
/**
* @param key Configuration section to remove the named value from.
* @param name Name of the configuration value to remove.
*
* @retval 0 for success.
* @retval -1 for error; ACE_OS::last_error() retrieves error code.
*/
virtual int remove_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name) = 0;
/**
* Expands <path_in> to <key_out> from @a key. If create is true,
* the subsections are created. Returns 0 on success, non zero on
* error The path consists of sections separated by the backslash
* '\' or forward slash '/'.
* Returns 0 on success, -1 if <create) is 0 and the path refers
* a nonexistant section
*/
int expand_path (const ACE_Configuration_Section_Key& key,
const ACE_TString& path_in,
ACE_Configuration_Section_Key& key_out,
int create = 1);
/**
* @deprecated Exports the configuration database to filename.
* If @a filename is already present, it is overwritten. This function is
* deprecated and will be removed in a future version of ACE. Please use
* either ACE_Registry_ImpExp or ACE_Ini_ImpExp instead.
*/
int export_config (const ACE_TCHAR* filename);
/**
* @deprecated Imports the configuration database from filename. Any
* existing data is not removed. This function is deprecated and will be
* removed in a future version of ACE. Please use ACE_Registry_ImpExp
* or ACE_Ini_ImpExp instead.
*/
int import_config (const ACE_TCHAR* filename);
/**
* Determine if the contents of this object is the same as the
* contents of the object on the right hand side.
* Returns 1 (True) if they are equal and 0 (False) if they are not equal
*/
bool operator==(const ACE_Configuration& rhs) const;
/**
* Determine if the contents of this object are different from the
* contents of the object on the right hand side.
* Returns 0 (False) if they are equal and 1 (True) if they are not equal
*/
bool operator!=(const ACE_Configuration& rhs) const;
/**
* * Represents the "NULL" string to simplify the internal logic.
* */
static ACE_TCHAR NULL_String_;
protected:
/// Default ctor
ACE_Configuration (void);
/// Resolves the internal key from a section key
ACE_Section_Key_Internal* get_internal_key
(const ACE_Configuration_Section_Key& key);
/**
* Tests to see if @a name is valid. @a name must be < 255 characters
* and not contain the path separator '\', brackets [] or = (maybe
* just restrict to alphanumeric?) returns non zero if name is not
* valid. The path separator is allowed, except for the first character,
* if <allow_path> is true.
*/
int validate_name (const ACE_TCHAR* name, int allow_path = 0);
/**
* Test to see if @a name is valid. The default value for a key can be
* unnamed, which means either @a name is == 0 or @a name == '\0` is
* valid. Otherwise, it calls validate_name() to test @a name for the
* same rules that apply to keys.
*/
int validate_value_name (const ACE_TCHAR* name);
// Not used
ACE_Configuration (const ACE_Configuration& rhs);
ACE_Configuration& operator= (const ACE_Configuration& rhs);
ACE_Configuration_Section_Key root_;
};
#if defined (ACE_WIN32) && !defined (ACE_LACKS_WIN32_REGISTRY)
/**
* @class ACE_Section_Key_Win32
*
* @brief The Win32 registry implementation of an internal section key.
*
* Holds the HKEY for a section (registry key).
*/
class ACE_Export ACE_Section_Key_Win32 : public ACE_Section_Key_Internal
{
public:
/// Constructor based on an HKEY
ACE_Section_Key_Win32 (HKEY hKey);
HKEY hKey_;
protected:
/// Destructor - invokes <RegCloseKey>
virtual ~ACE_Section_Key_Win32 (void);
// Not used
ACE_Section_Key_Win32 (const ACE_Section_Key_Win32& rhs);
ACE_Section_Key_Win32& operator= (const ACE_Section_Key_Win32& rhs);
};
/**
* @class ACE_Configuration_Win32Registry
*
* @brief The win32 registry implementation of a configuration database
*
* The win32 implementation basically makes calls through to the
* registry functions. The API is very similar so very little
* work must be done
*/
class ACE_Export ACE_Configuration_Win32Registry : public ACE_Configuration
{
public:
/**
* Constructor for registry configuration database. hKey is the
* base registry key to attach to. This class takes ownership of
* hKey, it will invoke <RegCloseKey> on it upon destruction.
*/
explicit ACE_Configuration_Win32Registry (HKEY hKey);
/// Destructor
virtual ~ACE_Configuration_Win32Registry (void);
virtual int open_section (const ACE_Configuration_Section_Key& base,
const ACE_TCHAR* sub_section,
int create,
ACE_Configuration_Section_Key& result);
virtual int remove_section (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* sub_section,
int recursive);
virtual int enumerate_values (const ACE_Configuration_Section_Key& key,
int index,
ACE_TString& name,
VALUETYPE& type);
virtual int enumerate_sections (const ACE_Configuration_Section_Key& key,
int index,
ACE_TString& name);
virtual int set_string_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
const ACE_TString& value);
virtual int set_integer_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
u_int value);
virtual int set_binary_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
const void* data,
size_t length);
virtual int get_string_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
ACE_TString& value);
virtual int get_integer_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
u_int& value);
virtual int get_binary_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
void*& data,
size_t& length);
virtual int find_value(const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
VALUETYPE& type);
/// Removes the the value @a name from @a key. returns non zero on error
virtual int remove_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name);
/**
* This method traverses <path> through <hKey>. It is useful when
* you want the HKEY for a specific registry key, especially when
* initializing this implementation. Caller is responsible for
* closeing this key when it is no longer used. If create is 1
* (default) the keys are create if they don't already exist.
* Returns 0 on error
*/
static HKEY resolve_key (HKEY hKey,
const ACE_TCHAR* path,
int create = 1);
virtual bool operator== (const ACE_Configuration_Win32Registry &rhs) const;
virtual bool operator!= (const ACE_Configuration_Win32Registry &rhs) const;
protected:
/// Gets the HKEY for a configuration section
int load_key (const ACE_Configuration_Section_Key& key, HKEY& hKey);
// Not used
ACE_Configuration_Win32Registry (void);
ACE_Configuration_Win32Registry (const ACE_Configuration_Win32Registry& rhs);
ACE_Configuration_Win32Registry& operator= (const ACE_Configuration_Win32Registry& rhs);
};
#endif /* ACE_WIN32 && !ACE_LACKS_WIN32_REGISTRY */
// ACE_Allocator version
typedef ACE_Allocator_Adapter <ACE_Malloc <ACE_MMAP_MEMORY_POOL,
ACE_SYNCH_MUTEX> >
PERSISTENT_ALLOCATOR;
typedef ACE_Allocator_Adapter <ACE_Malloc <ACE_LOCAL_MEMORY_POOL,
ACE_SYNCH_MUTEX> >
HEAP_ALLOCATOR;
/**
* @class ACE_Configuration_ExtId
*
* @brief External ID for the section and value hash
*
* Contains a pointer to the section or value name.
*/
class ACE_Export ACE_Configuration_ExtId
{
public:
/// Defeault ctor
ACE_Configuration_ExtId (void);
/// Named constructor
explicit ACE_Configuration_ExtId (const ACE_TCHAR* name);
/// Copy ctor
ACE_Configuration_ExtId (const ACE_Configuration_ExtId& rhs);
/// destructor
~ACE_Configuration_ExtId (void);
/// Assignment operator
ACE_Configuration_ExtId& operator= (const ACE_Configuration_ExtId& rhs);
/// Equality comparison operator (must match name_).
bool operator== (const ACE_Configuration_ExtId &rhs) const;
/// Inequality comparison operator.
bool operator!= (const ACE_Configuration_ExtId &rhs) const;
/// Frees the name of the value. needed since we don't know the
/// allocator name_ was created in
void free (ACE_Allocator *alloc);
/// <hash> function is required in order for this class to be usable by
/// ACE_Hash_Map_Manager.
u_long hash (void) const;
// = Data members.
const ACE_TCHAR * name_;
// Accessors
const ACE_TCHAR *name (void);
};
typedef ACE_Hash_Map_With_Allocator<ACE_Configuration_ExtId, int>
SUBSECTION_MAP;
typedef ACE_Hash_Map_Manager_Ex<ACE_Configuration_ExtId,
int,
ACE_Hash<ACE_Configuration_ExtId>,
ACE_Equal_To<ACE_Configuration_ExtId>,
ACE_Null_Mutex>
SUBSECTION_HASH;
/// @deprecated Deprecated typedef. Use the SUBSECTION_HASH::ENTRY trait instead.
typedef SUBSECTION_HASH::ENTRY SUBSECTION_ENTRY;
/**
* @class ACE_Configuration_Value_IntId
*
* @brief The section hash table internal value class
*
* This class is present as the internal portion of a section's
* value hash table It may store string, integer or binary data.
*/
class ACE_Export ACE_Configuration_Value_IntId
{
public:
/// Default constructor
ACE_Configuration_Value_IntId (void);
/// String constructor, takes ownership of string
explicit ACE_Configuration_Value_IntId (ACE_TCHAR* string);
/// Integer constructor
explicit ACE_Configuration_Value_IntId (u_int integer);
/// Binary constructor, takes ownership of data
ACE_Configuration_Value_IntId (void* data, size_t length);
/// Copy ctor
ACE_Configuration_Value_IntId (const ACE_Configuration_Value_IntId& rhs);
/// Destructor
~ACE_Configuration_Value_IntId (void);
/// Assignment operator
ACE_Configuration_Value_IntId& operator= (
const ACE_Configuration_Value_IntId& rhs);
void free (ACE_Allocator *alloc);
// = Data members.
/**
* Points to the string value or binary data or IS the integer
* Length is only used when type_ == BINARY
*/
ACE_Configuration::VALUETYPE type_;
union {
void * ptr_;
u_int int_;
} data_;
size_t length_;
};
typedef ACE_Hash_Map_With_Allocator<ACE_Configuration_ExtId,
ACE_Configuration_Value_IntId>
VALUE_MAP;
typedef ACE_Hash_Map_Manager_Ex<ACE_Configuration_ExtId,
ACE_Configuration_Value_IntId,
ACE_Hash<ACE_Configuration_ExtId>,
ACE_Equal_To<ACE_Configuration_ExtId>,
ACE_Null_Mutex>
VALUE_HASH;
// Deprecated typedef. Use the VALUE_HASH::ENTRY trait instead.
typedef VALUE_HASH::ENTRY VALUE_ENTRY;
/**
* @class ACE_Configuration_Section_IntId
*
* @brief The internal ID for a section hash table
*
* Contains a hash table containing value name/values
*/
class ACE_Export ACE_Configuration_Section_IntId
{
public:
/// Default ctor
ACE_Configuration_Section_IntId (void);
/// Named ctor
ACE_Configuration_Section_IntId (VALUE_MAP* value_hash_map,
SUBSECTION_MAP* section_hash_map);
/// Copy ctor
ACE_Configuration_Section_IntId (const ACE_Configuration_Section_IntId& rhs);
/// Destructor
~ACE_Configuration_Section_IntId (void);
/// Assignment operator
ACE_Configuration_Section_IntId& operator= (
const ACE_Configuration_Section_IntId& rhs);
/// Frees the hash table and all its values
void free (ACE_Allocator *alloc);
// = Data Members.
VALUE_MAP* value_hash_map_;
SUBSECTION_MAP* section_hash_map_;
};
typedef ACE_Hash_Map_With_Allocator<ACE_Configuration_ExtId,
ACE_Configuration_Section_IntId>
SECTION_MAP;
typedef ACE_Hash_Map_Manager_Ex<ACE_Configuration_ExtId,
ACE_Configuration_Section_IntId,
ACE_Hash<ACE_Configuration_ExtId>,
ACE_Equal_To<ACE_Configuration_ExtId>,
ACE_Null_Mutex>
SECTION_HASH;
// Deprecated typedef. Use the SECTION_HASH::ENTRY trait instead.
typedef SECTION_HASH::ENTRY SECTION_ENTRY;
/**
* @class ACE_Configuration_Section_Key_Heap
*
* @brief Internal section key class for heap based configuration
* database.
*
* Contains a value iterator and full path name of section.
*/
class ACE_Export ACE_Configuration_Section_Key_Heap
: public ACE_Section_Key_Internal
{
public:
/// Constructor based on the full path of the section
ACE_Configuration_Section_Key_Heap (const ACE_TCHAR* path);
/// The path itself
ACE_TCHAR* path_;
/// The value iterator
VALUE_HASH::ITERATOR* value_iter_;
/// The sub section iterator
SUBSECTION_HASH::ITERATOR* section_iter_;
protected:
/// Destructor - will delete the iterators
virtual ~ACE_Configuration_Section_Key_Heap (void);
// Not used
ACE_Configuration_Section_Key_Heap (const ACE_Configuration_Section_Key_Heap& rhs);
ACE_Configuration_Section_Key_Heap& operator= (const ACE_Configuration_Section_Key_Heap& rhs);
};
/**
* @class ACE_Configuration_Heap
*
* @brief The concrete implementation of a allocator based
* configuration database
*
* This class uses ACE's Allocators to manage a memory
* representation of a configuraiton database. A persistent heap
* may be used to store configurations persistently
*
* @note Before using this class you must call one of the open methods.
*
* @todo
* - Need to investigate what happens if memory mapped file gets mapped to
* a location different than it was created with.
*/
class ACE_Export ACE_Configuration_Heap : public ACE_Configuration
{
public:
/// Default ctor
ACE_Configuration_Heap (void);
/// Destructor
virtual ~ACE_Configuration_Heap (void);
/// Opens a configuration based on a file name
int open (const ACE_TCHAR* file_name,
void* base_address = ACE_DEFAULT_BASE_ADDR,
size_t default_map_size = ACE_DEFAULT_CONFIG_SECTION_SIZE);
/// Opens a heap based configuration
int open (size_t default_map_size = ACE_DEFAULT_CONFIG_SECTION_SIZE);
virtual int open_section (const ACE_Configuration_Section_Key& base,
const ACE_TCHAR* sub_section,
int create, ACE_Configuration_Section_Key& result);
virtual int remove_section (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* sub_section,
int recursive);
virtual int enumerate_values (const ACE_Configuration_Section_Key& key,
int index,
ACE_TString& name,
VALUETYPE& type);
virtual int enumerate_sections (const ACE_Configuration_Section_Key& key,
int index,
ACE_TString& name);
virtual int set_string_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
const ACE_TString& value);
virtual int set_integer_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
u_int value);
virtual int set_binary_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
const void* data,
size_t length);
virtual int get_string_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
ACE_TString& value);
virtual int get_integer_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
u_int& value);
virtual int get_binary_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
void* &data,
size_t &length);
virtual int find_value(const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name,
VALUETYPE& type);
/// Removes the the value @a name from @a key. returns non zero on error
virtual int remove_value (const ACE_Configuration_Section_Key& key,
const ACE_TCHAR* name);
private:
/// <sub_section> may not contain path separators
int open_simple_section (const ACE_Configuration_Section_Key &base,
const ACE_TCHAR *sub_section,
int create, ACE_Configuration_Section_Key &result);
/// Adds a new section
int add_section (const ACE_Configuration_Section_Key &base,
const ACE_TCHAR *sub_section,
ACE_Configuration_Section_Key &result);
/// Helper for the <open> method.
int create_index (void);
/// Helper for create_index() method: places hash table into an
/// allocated space.
int create_index_helper (void *buffer);
int value_open_helper (size_t hash_table_size, void *buffer);
int section_open_helper (size_t hash_table_size, void *buffer);
int load_key (const ACE_Configuration_Section_Key& key, ACE_TString& name);
int new_section (const ACE_TString& section,
ACE_Configuration_Section_Key& result);
ACE_Configuration_Heap (const ACE_Configuration_Heap& rhs);
ACE_Configuration_Heap& operator= (const ACE_Configuration_Heap& rhs);
ACE_Allocator *allocator_;
SECTION_MAP *index_;
size_t default_map_size_;
};
ACE_END_VERSIONED_NAMESPACE_DECL
#include /**/ "ace/post.h"
#endif /* ACE_CONFIGURATION_H */
|
yuanxu/liveshow_r2
|
P2pNet/ace/Configuration.h
|
C
|
mit
| 32,450
|
var Deferred = require('stupid-deferred')
var Imageloader = require('stupid-imageloader');
/**
* Image collection loader
* @constructor
*/
function Imagesloader(opts){
/**
* @define {object} Collection of public methods.
*/
var self = {};
/**
* @define {object} Options for the constructor
*/
var opts = opts || {};
/**
* @define {object} A image loader object
*/
var imageloader = Imageloader();
/**
* @define {array} A holder for when an image is loaded
*/
var imgs = [];
/**
* @define {array} A holder for the image src that should be loaded
*/
var srcs = [];
/**
* @define {object} A promise container for promises
*/
var def;
/**
* Load a collection of images
* @example imageloader.load(['img1.jpg', 'img2.jpg', 'img3.jpg']).success(function(){ // Do something });
* @param {array} images A collection of img object or img.src (paths)
* @config {object} def Create a promise object
* @return {object} Return the promise object
*/
function load(images){
def = Deferred();
/**
* Check if the images is img objects or image src
* return string of src
*/
srcs = convertImagesToSrc(images);
/**
* Loop through src's and load image
*/
for (var i = 0; i < srcs.length; i++) {
imageloader.load(srcs[i])
.success(function(img){
/** call imageloaded a pass the img that is loaded */
imageLoaded(img);
})
.error(function(msg){
def.reject(msg + ' couldn\'t be loaded');
});
};
return def.promise;
}
/**
* Image loaded checker
* @param {img} img The loaded image
*/
function imageLoaded(img){
/** Notify the promise */
def.notify("notify");
/** Add the image to the imgs array */
imgs.push(img);
/** If the imgs array size is the same as the src's */
if(imgs.length == srcs.length){
/** First sort images, to have the same order as src's */
sortImages();
/** Resolve the promise with the images */
def.resolve(imgs);
}
}
/**
* Convert img to src
* @param {array} imgs A collection og img/img paths
* @config {array} src A temporally array for storing img path/src
* @return {array} Return an array of img src's
*/
function convertImagesToSrc(imgs){
var src = [];
for (var i = 0; i < imgs.length; i++) {
/** If the img is an object (img) get the src */
if(typeof imgs[i] == 'object'){
src.push(imgs[i].src);
}
};
/** If the src array is null return the original imgs array */
return src.length ? src : imgs;
}
/**
* Sort images after the originally order
* @config {array} arr A temporally array for sorting images
*/
function sortImages(){
var arr = [];
/**
* Create a double loop
* And match the order of the srcs array
*/
for (var i = 0; i < srcs.length; i++) {
for (var j = 0; j < imgs.length; j++) {
var str = imgs[j].src.toString();
var reg = new RegExp(srcs[i])
/** If srcs matches the imgs add it the the new array */
if(str.match(reg)) arr.push(imgs[j]);
};
};
/** Override imgs array with the new sorted arr */
imgs = arr;
}
/**
* Public methods
* @public {function}
*/
self.load = load;
/**
* @return {object} Public methods
*/
return self;
}
/** @export */
module.exports = Imagesloader;
|
StupidStudio/stupid-imagesloader
|
imagesloader.js
|
JavaScript
|
mit
| 3,300
|
var reactTools = require('react-tools');
var path = require('path');
var mkdirp = require('mkdirp');
var fs = require('fs');
module.exports = function(root, options) {
var dest = options && options.dest || root;
return function(req, res, next) {
if (!req.path.match(/\.js$/)) {
return next();
}
var jsPath = path.join(dest, req.path);
var jsxPath = path.join(root, req.path + 'x');
function transform() {
fs.readFile(jsxPath, 'utf8', function (err, jsx) {
var annotationAdded = false;
if (!jsx.match(/\/[\*\s]*\@jsx/)) {
jsx = "/** @jsx React.DOM */\n\n" + jsx;
annotationAdded = true;
}
try {
var js = reactTools.transform(jsx)
if (annotationAdded) {
js = js.split("\n").slice(1).join("\n");
}
} catch (err) {
return next(err);
}
mkdirp(path.dirname(jsPath), 511, function() {
fs.writeFile(jsPath, js, 'utf8', next);
});
});
}
fs.stat(jsxPath, function(err, jsxStats) {
if (err) {
return next('ENOENT' == err.code ? null : err);
}
fs.stat(jsPath, function(err, jsStats) {
if (err) {
return 'ENOENT' == err.code ? transform() : next(err);
}
if (jsxStats.mtime > jsStats.mtime) {
return transform();
} else {
next();
}
});
});
}
};
|
mattlorey/express-jsx
|
lib/express-jsx.js
|
JavaScript
|
mit
| 1,446
|
;(function(global) {
"use strict";
var Rpd = global.Rpd;
if (typeof Rpd === "undefined" && typeof require !== "undefined") {
Rpd = require('rpd');
}
Rpd.style('compact-v', 'svg', (function() {
var ƒ = Rpd.unit;
var δ = Rpd.Render.data;
var socketPadding = 20, // distance between inlets/outlets in SVG units
socketsMargin = 8; // distance between first/last inlet/outlet and body edge
var headerHeight = 10; // height of a node header in SVG units
function _createSvgElement(name) {
return document.createElementNS(d3.namespaces.svg, name);
}
function getPos(elm) { var bounds = elm.getBoundingClientRect();
return { x: bounds.left, y: bounds.top } };
return function(config) {
var lastCanvas;
var listeners = {};
var inletToConnector = {},
outletToConnector = {};
return {
edgePadding: { horizontal: 20, vertical: 40 },
boxPadding: { horizontal: 20, vertical: 80 },
createCanvas: function(patch, parent) {
return {
element: d3.select(_createSvgElement('g'))
.classed('rpd-patch', true).node()
};
},
createNode: function(node, render, description, icon) {
var minContentSize = render.size ? { width: render.size.width || 60,
height: render.size.height || 25 }
: { width: 60, height: 25 };
var pivot = render.pivot || { x: 0.5, y: 0.5 };
function findBestNodeSize(numInlets, numOutlets, minContentSize) {
var requiredContentHeight = (2 * socketsMargin) + ((Math.max(numInlets, numOutlets) - 1) * socketPadding);
return { width: minContentSize.width,
height: Math.max(headerHeight + requiredContentHeight, headerHeight + minContentSize.height) };
}
var initialSize = findBestNodeSize(node.def.inlets ? Object.keys(node.def.inlets).length : 0,
node.def.outlets ? Object.keys(node.def.outlets).length : 0,
minContentSize);
var width = initialSize.width, height = initialSize.height;
var bodyWidth = width,
bodyHeight = height - headerHeight;
var nodeElm = d3.select(_createSvgElement('g')).attr('class', 'rpd-node');
// append shadow
nodeElm.append('rect').attr('class', 'rpd-shadow')
.attr('width', width).attr('height', height)
.attr('x', 5).attr('y', 6).attr('rx', 3).attr('ry', 3);
// append node header
nodeElm.append('rect').attr('class', 'rpd-header').classed('rpd-drag-handle', true)
.attr('x', 0).attr('y', 0)
.attr('width', width).attr('height', headerHeight);
nodeElm.append('g').attr('class', 'rpd-name-holder')
.attr('transform', 'translate(0, 3)')
.append('text').attr('class', 'rpd-name').text(node.def.title || node.type)
.attr('x', 3).attr('y', 2)
.style('pointer-events', 'none');
// append node body
nodeElm.append('rect').attr('class', 'rpd-content')
.attr('x', 0).attr('y', headerHeight)
.attr('width', width).attr('height', height - headerHeight);
nodeElm.append('rect').attr('class', 'rpd-body')
.attr('width', width).attr('height', height)
.style('pointer-events', 'none');
// append tooltip with description
nodeElm.select('.rpd-header')
.append(ƒ(_createSvgElement('title')))
.text(description ? (description + ' (' + node.type + ')') : node.type);
// append remove button
nodeElm.append('g').attr('class', 'rpd-remove-button')
.attr('transform', 'translate(' + (width-10.5) + ',0.5)')
.call(function(button) {
button.append('rect').attr('width', 10).attr('height', headerHeight - 0.5)
.attr('class', 'rpd-remove-button-handle');
button.append('text').text('x').attr('x', 3).attr('y', 1.5)
.style('pointer-events', 'none');
});
// append placeholders for inlets, outlets and a target element to render body into
var inletsGroup = nodeElm.append('g').attr('class', 'rpd-inlets')
.attr('transform', 'translate(0,' + headerHeight + ')');
var processGroup = nodeElm.append('g').attr('class', 'rpd-process')
.attr('transform', 'translate(' + (bodyWidth * pivot.x) + ','
+ (headerHeight + ((height - headerHeight) * pivot.y)) + ')');
var outletsGroup = nodeElm.append('g').attr('class', 'rpd-outlets')
.attr('transform', 'translate(' + bodyWidth + ',' + headerHeight + ')');
δ(inletsGroup, { position: { x: 0, y: headerHeight } });
δ(outletsGroup, { position: { x: width, y: headerHeight } });
nodeElm.classed('rpd-'+node.type.slice(0, node.type.indexOf('/'))+'-toolkit-node', true)
.classed('rpd-'+node.type.replace('/','-'), true);
var numInlets = 0, numOutlets = 0;
var inletElms = [], outletElms = [];
var lastSize = initialSize;
function checkNodeSize() {
var curSize = lastSize;
var newSize = findBestNodeSize(numInlets, numOutlets, minContentSize);
if ((newSize.width === curSize.width) && (newSize.height === curSize.height)) return;
nodeElm.select('rect.rpd-shadow').attr('height', newSize.height).attr('width', newSize.width);
nodeElm.select('rect.rpd-body').attr('height', newSize.height).attr('width', newSize.width);
nodeElm.select('rect.rpd-content').attr('height', newSize.height - headerHeight);
nodeElm.select('g.rpd-process').attr('transform', 'translate(' + (newSize.width * pivot.x) + ','
+ (headerHeight + ((newSize.height - headerHeight) / 2)) + ')');
lastSize = newSize;
}
function recalculateSockets() {
inletElms.forEach(function(inletElm, idx) {
var inletPos = findInletPos(idx);
inletElm.attr('transform', 'translate(' + inletPos.x + ',' + inletPos.y + ')');
//δ(inletElm).position = inletPos;
});
outletElms.forEach(function(outletElm, idx) {
var outletPos = findOutletPos(idx);
outletElm.attr('transform', 'translate(' + outletPos.x + ',' + outletPos.y + ')');
//δ(outletElm).position = outletPos;
});
}
function notifyNewInlet(elm) {
numInlets++; inletElms.push(elm); checkNodeSize();
recalculateSockets();
}
function notifyNewOutlet(elm) {
numOutlets++; outletElms.push(elm); checkNodeSize();
recalculateSockets();
}
function findInletPos(idx) { // index from top to bottom
return { x: 0, y: socketsMargin + (socketPadding * idx) };
}
function findOutletPos(idx) { // index from top to bottom
return { x: 0, y: socketsMargin + (socketPadding * idx) };
}
listeners[node.id] = {
inlet: notifyNewInlet,
outlet: notifyNewOutlet
};
return {
element: nodeElm.node(),
size: initialSize
};
},
createInlet: function(inlet, render) {
var inletElm = d3.select(_createSvgElement('g')).attr('class', 'rpd-inlet');
inletElm.call(function(group) {
//group.attr('transform', 'translate(' + inletPos.x + ',' + inletPos.y + ')')
group.append('rect').attr('class', 'rpd-connector')
.attr('x', -2).attr('y', -2)
.attr('width', 4).attr('height', 4);
group.append('text').attr('class', 'rpd-name').text(inlet.def.label || inlet.alias)
.attr('x', -5).attr('y', 0);
group.append('g').attr('class', 'rpd-value-holder')
.attr('transform', 'translate(-5,7)')
.append('text').attr('class', 'rpd-value');
});
listeners[inlet.node.id].inlet(inletElm);
inletToConnector[inlet.id] = inletElm.select('.rpd-connector');
return { element: inletElm.node() };
},
createOutlet: function(outlet, render) {
var outletElm = d3.select(_createSvgElement('g')).attr('class', 'rpd-outlet');
outletElm.call(function(group) {
//group.attr('transform', 'translate(' + outletPos.x + ',' + outletPos.y + ')')
group.append('rect').attr('class', 'rpd-connector')
.attr('x', -2).attr('y', -2)
.attr('width', 4).attr('height', 4);
group.append('text').attr('class', 'rpd-name').text(outlet.def.label || outlet.alias)
.attr('x', 5).attr('y', 0);
group.append('g').attr('class', 'rpd-value-holder')
.attr('transform', 'translate(5,7)')
.append('text').attr('class', 'rpd-value')
.attr('x', 0).attr('y', 0)
.style('pointer-events', 'none');
});
listeners[outlet.node.id].outlet(outletElm);
outletToConnector[outlet.id] = outletElm.select('.rpd-connector');
return { element: outletElm.node() };
},
createLink: function(link) {
var linkElm = d3.select(_createSvgElement(
(config.linkForm && (config.linkForm == 'curve')) ? 'path' : 'line'
)).attr('class', 'rpd-link');
return { element: linkElm.node(),
rotate: function(x0, y0, x1, y1) {
if (config.linkForm && (config.linkForm == 'curve')) {
linkElm.attr('d', bezierByH(x0, y0, x1, y1));
} else {
linkElm.attr('x1', x0).attr('y1', y0)
.attr('x2', x1).attr('y2', y1);
}
},
noPointerEvents: function() {
linkElm.style('pointer-events', 'none');
} };
},
getInletPos: function(inlet) {
var connectorPos = getPos(inletToConnector[inlet.id].node());
return { x: connectorPos.x + 2, y: connectorPos.y + 2};
},
getOutletPos: function(outlet) {
var connectorPos = getPos(outletToConnector[outlet.id].node());
return { x: connectorPos.x + 2, y: connectorPos.y + 2 };
},
getLocalPos: function(pos) {
if (!lastCanvas) return pos;
// calculate once on patch switch?
var canvasPos = getPos(lastCanvas.node());
return { x: pos.x - canvasPos.x, y: pos.y - canvasPos.y };
},
onPatchSwitch: function(patch, canvas) {
lastCanvas = d3.select(canvas);
},
onNodeRemove: function(node) {
listeners[node.id] = null;
}
};
function bezierByH(x0, y0, x1, y1) {
var mx = x0 + (x1 - x0) / 2;
return 'M' + x0 + ' ' + y0 + ' '
+ 'C' + mx + ' ' + y0 + ' '
+ mx + ' ' + y1 + ' '
+ x1 + ' ' + y1;
}
} })());
})(this);
|
shamansir/rpd
|
src/style/compact-v/svg.js
|
JavaScript
|
mit
| 11,801
|
<?php
if(!defined('PROTECT')){ exit('NO ACCESS'); }
if(!isset($_SESSION['typeuser'])) header('location: '.SITE_URL.'sys/login');
require_once('victro_system/victro_settings/mainMethod.class.php');
$victro_maker = new VictroFunc();
if(isset($_GET['id']) or isset($_GET['name'])){
if(isset($_GET['pass'])){
$victro_ret['pass'] = $_GET['pass'];
}
if(isset($_GET['id']) and isset($_GET['name'])){
$victro_ret['id'] = $_GET['id'];
$victro_ret['name'] = $_GET['name'];
} else if(isset($_GET['id'])){
$victro_ret['id'] = $_GET['id'];
} else if(isset($_GET['name'])){
$victro_ret['name'] = $_GET['name'];
}
$victro_file = $victro_maker->load_file_db($victro_ret);
if(!isset($victro_file['error'])){
$victro_folder = SITE_URL.'victro_apps/victro_storage/';
$victro_folder1 = 'victro_apps/victro_storage/';
if($victro_file['type'] == "png" or $victro_file['type'] == "PNG" or $victro_file['type'] == "jpg" or
$victro_file['type'] == "JPG" or $victro_file['type'] == "gif" or $victro_file['type'] == "GIF" or
$victro_file['type'] == "JPEG" or $victro_file['type'] == "jpeg"){
if(file_exists($victro_folder1.$victro_file['folder'].'/'.$victro_file['name'])){
$victro_filecont = file_get_contents($victro_folder.$victro_file['folder'].'/'.$victro_file['name']);
$victro_cont = explode("+?+|+?+",base64_decode($victro_filecont));
header('Content-type:image/'.$victro_file['type']);
echo ($victro_cont[1]);
} else {
header("Content-type: image/gif"); //Informa ao browser que o arquivo é uma imagem no formato GIF
$victro_imagem = ImageCreate(250,250); //Cria uma imagem com as dimensões 100x20
$victro_vermelho = ImageColorAllocate($victro_imagem, 150, 0, 0); //Cria o segundo plano da imagem e o configura para vermelho
$victro_branco = ImageColorAllocate($victro_imagem, 255, 255, 255); //Cria a cor de primeiro plano da imagem e configura-a para branco
ImageString($victro_imagem,150, 100, 110, "404 ;(", $victro_branco); //Imprime na imagem o texto PHPBrasil na cor branca que está na variável $victro_branco
ImageGif($victro_imagem); //Converte a imagem para um GIF e a envia para o browser
ImageDestroy($victro_imagem); //Destrói a memória alocada para a construção da imagem GIF.
}
} else {
if(file_exists($victro_folder1.$victro_file['folder'].'/'.$victro_file['name'])){
$victro_rand = mt_rand(111, 9999999);
$victro_namefile = $victro_rand.time().'.'.$victro_file['type'];
$victro_filecont = file_get_contents($victro_folder.$victro_file['folder'].'/'.$victro_file['name']);
$victro_cont = explode("+?+|+?+",base64_decode($victro_filecont));
file_put_contents($victro_namefile, $victro_cont[1]);
header('Content-Description: File Transfer');
header('Content-Disposition: attachment; filename="'.$victro_namefile.'"');
header('Content-Transfer-Encoding: binary');
header("Content-Type: text/html");
header('Content-Length: ' . filesize($victro_namefile));
header('Cache-Control: must-revalidate, post-check=0, pre-check=0');
header('Pragma: public');
header('Expires: 0');
ob_end_clean(); //essas duas linhas antes do readfile
flush();
readfile($victro_namefile);
unlink($victro_namefile);
}
}
} else {
exit($victro_file['error']);
}
}
?>
|
jeanprmr/victrobrain
|
victro_system/victro_system/sys/fileload.php
|
PHP
|
mit
| 3,408
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.CodeDom.Compiler;
using System.Diagnostics;
using System.Reflection;
namespace RMUD
{
public partial class GithubDatabase : WorldDataService
{
public String StaticPath { get; private set; }
public String DynamicPath { get; private set; }
private System.Net.WebClient WebClient = new System.Net.WebClient();
private class FileTableEntry
{
public String Path;
public int FirstLine;
}
private static String PathToNamespace(String Path)
{
return "__" + Path.Replace("/", "_").Replace("-", "_");
}
}
}
|
Reddit-Mud/RMUD
|
Core/GithubDatabase/Database.cs
|
C#
|
mit
| 722
|
---
title: Lesson 10
layout: post
author: nathan.davies
permalink: /lesson-10/
source-id: 1pIkUwxIRuv1wdZX3Jf-hLRsPuK5fE4WmvRDAOhDBKN8
published: true
---
**Lesson 10**
In today's lesson, we had a great time! We watched our teacher code the letter 'A’ and then we had a go at coding it ourselves. We all had to go back to our places and spend around twenty minutes trying to code the letter ‘A’. After we had done this, we had to create a three letter word with our initials and the letter ‘A’. I coded the word ‘AND’ because my initials are ‘ND’. However, it wasn’t just that easy. We also had to then put them on a straight line and make it neat. To start off with, my word looked like this:

But after a bit of coding, I was able to make my word legible and this was my final outcome:

|
NathanDavies2323/nathandavies2323.github.io
|
_posts/2018-03-14-Lesson-10.md
|
Markdown
|
mit
| 960
|
package com.github.steveice10.mc.classic.protocol.packet.server;
import com.github.steveice10.mc.classic.protocol.packet.ClassicPacketUtil;
import com.github.steveice10.packetlib.io.NetInput;
import com.github.steveice10.packetlib.io.NetOutput;
import com.github.steveice10.packetlib.packet.Packet;
import java.io.IOException;
/**
* Sent by a server to provide level data to the client.
*/
public class ServerLevelDataPacket implements Packet {
private byte data[];
private int percent;
@SuppressWarnings("unused")
private ServerLevelDataPacket() {
}
/**
* Creates a new ServerLevelDataPacket instance.
*
* @param data Level data to send.
* @param percent Percent of level data sent so far.
*/
public ServerLevelDataPacket(byte data[], int percent) {
this.data = data;
this.percent = percent;
}
/**
* Gets the level data being sent.
*
* @return The level data being sent.
*/
public byte[] getData() {
return this.data;
}
/**
* Gets the percent of level data sent so far.
*
* @return The percent of level data sent so far.
*/
public int getPercent() {
return this.percent;
}
@Override
public void read(NetInput in) throws IOException {
this.data = ClassicPacketUtil.readBytes(in);
this.percent = in.readUnsignedByte();
}
@Override
public void write(NetOutput out) throws IOException {
ClassicPacketUtil.writeBytes(out, this.data);
out.writeByte(this.percent);
}
@Override
public boolean isPriority() {
return false;
}
}
|
Steveice10/ClassicProtocolLib
|
src/main/java/com/github/steveice10/mc/classic/protocol/packet/server/ServerLevelDataPacket.java
|
Java
|
mit
| 1,663
|
var is = function(x) {
return (elem) => elem && elem.nodeType === x;
};
// commented-out methods are not being used
module.exports = {
elem: is(1),
attr: is(2),
text: is(3),
// cdata: is(4),
// entity_reference: is(5),
// entity: is(6),
// processing_instruction: is(7),
comment: is(8),
doc: is(9),
// document_type: is(10),
doc_frag: is(11)
// notation: is(12),
};
|
JosephClay/d-js
|
src/nodeType.js
|
JavaScript
|
mit
| 418
|
PROJECT = github.com/fulldump/goconfig
GOCMD=go
.PHONY: all setup test coverage example
all: test
setup:
mkdir -p src/$(PROJECT)
rmdir src/$(PROJECT)
ln -s ../../.. src/$(PROJECT)
test:
$(GOCMD) version
$(GOCMD) env
$(GOCMD) test -v $(PROJECT)
example:
$(GOCMD) install $(PROJECT)/example
coverage:
$(GOCMD) test ./src/github.com/fulldump/goconfig -cover -covermode=count -coverprofile=coverage.out; \
$(GOCMD) tool cover -html=coverage.out
|
fulldump/goconfig
|
Makefile
|
Makefile
|
mit
| 458
|
require 'minitest/spec'
require 'minitest/autorun'
require 'alipass'
require 'fakeweb'
Alipass.app_id = 'app_id'
Alipass.private_key_file = 'YOUR_SHOULR_FILL_THIS'
|
HungYuHei/alipass
|
spec/spec_helper.rb
|
Ruby
|
mit
| 175
|
/**
* @file
* @brief Contains the TPZGenPartialGrid class which implements the generation of a geometric grid.
*/
//
// Author: MISAEL LUIS SANTANA MANDUJANO/Philippe Devloo
//
// File: tpargrid.h
//
// Class: tparrid
//
// Obs.: Gera uma malha retangular:
//
// Versao: 06 / 1996.
//
#ifndef _TPZPARGRIDHH_
#define _TPZPARGRIDHH_
class TPZCompMesh;
class TPZGeoMesh;
#include <stdio.h>
#include <iostream>
#include "pzreal.h"
#include "pzvec.h"
/**
* @ingroup pre
* @brief Implements the generation of a geometric grid. \ref pre "Getting Data"
*/
/** Implements the generation of part of the grid
* This class uses DEPRECATED objects, but can be easily updated
*/
class TPZGenPartialGrid{
public:
/**
@param x0 lower left coordinate
@param x1 upper right coordinate
@param nx number of nodes in x and y
@param rangex range of nodes which need to be created
@param rangey range of nodes which need to be created
*/
TPZGenPartialGrid(TPZVec<int> &nx, TPZVec<int> &rangex, TPZVec<int> &rangey, TPZVec<REAL> &x0, TPZVec<REAL> &x1);
~TPZGenPartialGrid();
short Read (TPZGeoMesh & malha);
void SetBC(TPZGeoMesh &gr, int side, int bc);
void Print( char *name = NULL, std::ostream &out = std::cout );
void SetElementType(int type) {
fElementType = type;
}
protected:
void Coord(int i, TPZVec<REAL> &coord);
int NodeIndex(int i, int j);
int ElementIndex(int i, int j);
void ElementConnectivity(int iel, TPZVec<int> &nodes);
TPZVec<int> fNx;
TPZVec<int> fRangex,fRangey;
TPZVec<REAL> fX0,fX1,fDelx;
int fNumNodes;
int fElementType;
};
#endif // _TPZGENGRIDHH_
|
gems-uff/oceano
|
core/src/test/resources/CPP/neopz/Pre/pzpargrid.h
|
C
|
mit
| 1,625
|
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package gui.controls;
import java.awt.Component;
import java.awt.Cursor;
import java.awt.Dimension;
import java.awt.Point;
import java.awt.event.MouseEvent;
import java.awt.event.MouseListener;
import java.awt.event.MouseMotionListener;
import javax.swing.BorderFactory;
import javax.swing.JPanel;
/**
* JPanel permettant l'agrandissement vers la gauche
*
* @author Vincent
*/
public class PanelDynamique extends JPanel implements MouseListener, MouseMotionListener
{
public static final int LARGEUR_SELECTION = 5;
private boolean enModification;
private Point origine;
/**
* Constructeur principal
*/
public PanelDynamique()
{
this.resetModifications();
this.setOpaque(false);
this.setBorder(BorderFactory.createEmptyBorder(0,LARGEUR_SELECTION,0,0));
this.addMouseMotionListener(this);
//this.setMaximumSize(new Dimension(500, this.getMaximumSize().height));
}
private void resetModifications()
{
enModification = false;
origine = null;
}
@Override
public void mouseDragged(MouseEvent e)
{
int translationX = 0;
if (enModification &&
origine != null)
{
translationX = (e.getX() - origine.x) * -1;
for (Component c : this.getComponents())
{
int width = c.getPreferredSize().width + translationX;
if (width < 900 &&
width > 350)
c.setPreferredSize(new Dimension(width, c.getPreferredSize().height));
}
//if (this.getPreferredSize().width + translationX >= this.getMinimumSize().width &&
// this.getPreferredSize().width + translationX < 600)
//{
// this.setPreferredSize(new Dimension(this.getPreferredSize().width + translationX, this.getPreferredSize().height));
//}
}
this.revalidate();
}
@Override
public void mouseMoved(MouseEvent e)
{
origine = e.getPoint();
if ((e.getX() >= 0 && e.getX() <= LARGEUR_SELECTION))
{
enModification = true;
this.setCursor(Cursor.getPredefinedCursor(Cursor.W_RESIZE_CURSOR));
}
else
{
this.resetModifications();
this.setCursor(Cursor.getPredefinedCursor(Cursor.DEFAULT_CURSOR));
}
}
// <editor-fold desc="MouseListener event non-utilisés">
@Override
public void mouseReleased(MouseEvent e)
{
this.resetModifications();
}
@Override
public void mouseClicked(MouseEvent e)
{
}
@Override
public void mousePressed(MouseEvent e)
{
}
@Override
public void mouseEntered(MouseEvent e)
{
}
@Override
public void mouseExited(MouseEvent e)
{
}
// </editor-fold>
}
|
Vaub/GLO-2004-A2014
|
RecyclApp/src/gui/controls/PanelDynamique.java
|
Java
|
mit
| 3,188
|
/*! UIkit 2.24.2 | http://www.getuikit.com | (c) 2014 YOOtheme | MIT License */
/* ========================================================================
Component: Autocomplete
========================================================================== */
/*
* 1. Container width fits its content
* 2. Create position context
* 3. Prevent `inline-block` consequences
* 4. Remove the gap between the container and its child element
*/
.uk-autocomplete {
/* 1 */
display: inline-block;
/* 2 */
position: relative;
/* 3 */
max-width: 100%;
/* 4 */
vertical-align: middle;
}
/* Nav modifier `uk-nav-autocomplete`
========================================================================== */
/*
* Items
*/
.uk-nav-autocomplete > li > a {
color: #444;
}
/*
* Active
* 1. Remove default focus style
*/
.uk-nav-autocomplete > li.uk-active > a {
background: #00a8e6;
color: #fff;
/* 1 */
outline: none;
box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.05);
text-shadow: 0 -1px 0 rgba(0, 0, 0, 0.1);
}
/*
* Sub-object: `uk-nav-header`
*/
.uk-nav-autocomplete .uk-nav-header {
color: #999;
}
/*
* Sub-object: `uk-nav-divider`
*/
.uk-nav-autocomplete .uk-nav-divider {
border-top: 1px solid #ddd;
}
|
calben/riotjs-uikit-startkit
|
src/css/components/autocomplete.almost-flat.css
|
CSS
|
mit
| 1,235
|
const katex = require('katex')
const renderKatexFormula = function(text, displayMode) {
try {
return katex.renderToString(text, { displayMode: displayMode })
} catch (err) {
console.log(
'Katex error trying to parse: "' + text + '". Description: ' + err
)
}
}
module.exports = function(inlineMathSelector, displayMathSelector) {
const inlineVsDisplayLogic =
typeof displayMathSelector !== 'undefined'
? 'separateSelector'
: 'spanIsInline'
inlineMathSelector = arguments.length > 0 ? inlineMathSelector : '.math'
return function(deck) {
let foundMath = false
let mathElements
switch (inlineVsDisplayLogic) {
case 'separateSelector':
mathElements = deck.parent.querySelectorAll(inlineMathSelector)
Array.from(mathElements).forEach(el => {
el.innerHTML = renderKatexFormula(el.innerHTML, false)
foundMath = true
})
mathElements = deck.parent.querySelectorAll(displayMathSelector)
Array.from(mathElements).forEach(el => {
el.innerHTML = renderKatexFormula(el.innerHTML, true)
foundMath = true
})
break
case 'spanIsInline':
mathElements = deck.parent.querySelectorAll(inlineMathSelector)
Array.from(mathElements).forEach(el => {
el.innerHTML = renderKatexFormula(
el.textContent,
el.tagName.toLowerCase() !== 'span'
)
foundMath = true
})
break
}
if (foundMath) {
try {
require('katex/dist/katex.min.css')
} catch (e) {
console.log(
'It was not possible to load the CSS from KaTeX. Details: ' + e
)
}
}
}
}
|
fegemo/bespoke-math
|
lib/bespoke-math.js
|
JavaScript
|
mit
| 1,682
|
import React from "react";
import PropTypes from "prop-types";
import styled from "styled-components";
import Image, { thumbnailSizes } from "@crave/farmblocks-image";
import { fontTypes } from "@crave/farmblocks-text";
const Icon = styled.div`
font-size: ${({ iconFontSize }) => iconFontSize || "72px"};
color: ${fontTypes.SUBTLE};
`;
const Thumbnail = ({ imageSrc, icon, iconFontSize }) => {
if (imageSrc) {
return (
<Image className="thumbnail" size={thumbnailSizes.LARGE} src={imageSrc} />
);
}
if (icon) {
return (
<Icon className="icon-wrapper" iconFontSize={iconFontSize}>
{icon}
</Icon>
);
}
return null;
};
Thumbnail.propTypes = {
imageSrc: PropTypes.string,
iconFontSize: PropTypes.string,
icon: PropTypes.node,
};
export default Thumbnail;
|
CraveFood/farmblocks
|
packages/empty-state/src/Thumbnail.js
|
JavaScript
|
mit
| 819
|
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
/*
| -------------------------------------------------------------------
| DATABASE CONNECTIVITY SETTINGS
| -------------------------------------------------------------------
| This file will contain the settings needed to access your database.
|
| For complete instructions please consult the 'Database Connection'
| page of the User Guide.
|
| -------------------------------------------------------------------
| EXPLANATION OF VARIABLES
| -------------------------------------------------------------------
|
| ['hostname'] The hostname of your database server.
| ['username'] The username used to connect to the database
| ['password'] The password used to connect to the database
| ['database'] The name of the database you want to connect to
| ['dbdriver'] The database type. ie: mysql. Currently supported:
mysql, mysqli, postgre, odbc, mssql, sqlite, oci8
| ['dbprefix'] You can add an optional prefix, which will be added
| to the table name when using the Active Record class
| ['pconnect'] TRUE/FALSE - Whether to use a persistent connection
| ['db_debug'] TRUE/FALSE - Whether database errors should be displayed.
| ['cache_on'] TRUE/FALSE - Enables/disables query caching
| ['cachedir'] The path to the folder where cache files should be stored
| ['char_set'] The character set used in communicating with the database
| ['dbcollat'] The character collation used in communicating with the database
| ['swap_pre'] A default table prefix that should be swapped with the dbprefix
| ['autoinit'] Whether or not to automatically initialize the database.
| ['stricton'] TRUE/FALSE - forces 'Strict Mode' connections
| - good for ensuring strict SQL while developing
|
| The $active_group variable lets you choose which connection group to
| make active. By default there is only one group (the 'default' group).
|
| The $active_record variables lets you determine whether or not to load
| the active record class
*/
$active_group = 'development';
$active_record = TRUE;
<% @environments.each do |env, config| %>
$db['<%= env %>']['hostname'] = "<%= config['host'] %>";
$db['<%= env %>']['username'] = "<%= config['username'] %>";
$db['<%= env %>']['password'] = "<%= config['password'] %>";
$db['<%= env %>']['database'] = "<%= config['database'] %>";
$db['<%= env %>']['dbdriver'] = 'mysql';
$db['<%= env %>']['dbprefix'] = '';
$db['<%= env %>']['pconnect'] = TRUE;
$db['<%= env %>']['db_debug'] = TRUE;
$db['<%= env %>']['cache_on'] = FALSE;
$db['<%= env %>']['cachedir'] = '';
$db['<%= env %>']['char_set'] = 'utf8';
$db['<%= env %>']['dbcollat'] = 'utf8_general_ci';
$db['<%= env %>']['swap_pre'] = '';
$db['<%= env %>']['autoinit'] = TRUE;
$db['<%= env %>']['stricton'] = FALSE;
/* End of <%= env %> mode */
<% end %>
/* End of file database.php */
/* Location: ./application/config/database.php */
|
qichunren/codeigniter_vender
|
lib/generators/ci/install/templates/config/database.php
|
PHP
|
mit
| 2,911
|
var express = require('express');
var path = require('path');
var favicon = require('serve-favicon');
var logger = require('morgan');
var cookieParser = require('cookie-parser');
var bodyParser = require('body-parser');
// Connect to DB
var dbConfig = require('./config/db');
var mongoose = require('mongoose');
mongoose.connect(dbConfig.url,function(res,err){
if(err){ console.log('ERROR connecting to : ' + dbConfig.url + '. ' + err); process.exit(0);}
else {
if ( res === undefined ) console.log('connected to ' + dbConfig.url );
else { console.log('ERROR connecting to : ' + dbConfig.url + '. ' + res.errmsg); process.exit(0);}
}
});
var app = express();
// view engine setup
app.set('views', path.join(__dirname, 'views'));
app.set('view engine', 'jade');
app.locals.moment = require('moment');
// uncomment after placing your favicon in /public
//app.use(favicon(path.join(__dirname, 'public', 'favicon.ico')));
app.use(logger('dev'));
app.use(bodyParser.json());
app.use(bodyParser.urlencoded({ extended: false }));
app.use(cookieParser());
app.use(express.static(path.join(__dirname, 'public')));
app.use(express.static(path.join(__dirname, 'bower_components')));
// Configuring Passport
var passport = require('passport');
var expressSession = require('express-session');
app.use(expressSession({
secret: 'mySecretKey',
resave: true,
saveUninitialized: true})
);
app.use(passport.initialize());
app.use(passport.session());
// Using the flash middleware provided by connect-flash to store messages in session
// and displaying in templates
var flash = require('connect-flash');
app.use(flash());
// Initialize Passport
var initPassport = require('./passport/init');
initPassport(passport);
var routes = require('./routes/index');
var auth = require('./routes/auth')(passport);
var agenda = require('./routes/agenda');
app.use('/', routes);
app.use('/auth', auth);
app.use('/agenda', agenda);
// catch 404 and forward to error handler
app.use(function(req, res, next) {
var err = new Error('Not Found');
err.status = 404;
next(err);
});
// error handlers
// development error handler
// will print stacktrace
if (app.get('env') === 'development') {
app.use(function(err, req, res, next) {
res.status(err.status || 500);
res.render('error', {
message: err.message,
error: err
});
});
}
// production error handler
// no stacktraces leaked to user
app.use(function(err, req, res, next) {
res.status(err.status || 500);
res.render('error', {
message: err.message,
error: {}
});
});
module.exports = app;
|
iv-devs/cowork-solicitud
|
app.js
|
JavaScript
|
mit
| 2,609
|
<!DOCTYPE html>
<html lang="en-us">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="generator" content="Source Themes Academic 4.4.0">
<meta name="author" content="Lorena Pantano">
<meta name="description" content="Senior Computational Biologist">
<link rel="alternate" hreflang="en-us" href="http://lpantano.github.io/authors/n.-lee/">
<meta name="theme-color" content="#2962ff">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/academicons/1.8.6/css/academicons.min.css" integrity="sha256-uFVgMKfistnJAfoCUQigIl+JfUaP47GrRKjf6CTPVmw=" crossorigin="anonymous">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.6.0/css/all.css" integrity="sha384-aOkxzJ5uQz7WBObEZcHvV5JvRW3TUc2rNPA7pe3AwnsUohiw1Vj2Rgx2KSOkF5+h" crossorigin="anonymous">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/fancybox/3.2.5/jquery.fancybox.min.css" integrity="sha256-ygkqlh3CYSUri3LhQxzdcm0n1EQvH2Y+U5S2idbLtxs=" crossorigin="anonymous">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.15.6/styles/github.min.css" crossorigin="anonymous" title="hl-light">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.15.6/styles/dracula.min.css" crossorigin="anonymous" title="hl-dark" disabled>
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Montserrat:400,700|Roboto:400,400italic,700|Roboto+Mono&display=swap">
<link rel="stylesheet" href="/css/academic.min.3bc694af15fd1e4ff7262e7dd46f11a8.css">
<link rel="alternate" href="/authors/n.-lee/index.xml" type="application/rss+xml" title="My BioBits">
<link rel="manifest" href="/site.webmanifest">
<link rel="icon" type="image/png" href="/img/icon.png">
<link rel="apple-touch-icon" type="image/png" href="/img/icon-192.png">
<link rel="canonical" href="http://lpantano.github.io/authors/n.-lee/">
<meta property="twitter:card" content="summary">
<meta property="twitter:site" content="@lopantano">
<meta property="twitter:creator" content="@lopantano">
<meta property="og:site_name" content="My BioBits">
<meta property="og:url" content="http://lpantano.github.io/authors/n.-lee/">
<meta property="og:title" content="N. Lee | My BioBits">
<meta property="og:description" content="Senior Computational Biologist"><meta property="og:image" content="http://lpantano.github.io/img/icon-192.png">
<meta property="twitter:image" content="http://lpantano.github.io/img/icon-192.png"><meta property="og:locale" content="en-us">
<meta property="og:updated_time" content="2014-01-01T00:00:00+00:00">
<title>N. Lee | My BioBits</title>
</head>
<body id="top" data-spy="scroll" data-offset="70" data-target="#TableOfContents" >
<aside class="search-results" id="search">
<div class="container">
<section class="search-header">
<div class="row no-gutters justify-content-between mb-3">
<div class="col-6">
<h1>Search</h1>
</div>
<div class="col-6 col-search-close">
<a class="js-search" href="#"><i class="fas fa-times-circle text-muted" aria-hidden="true"></i></a>
</div>
</div>
<div id="search-box">
<input name="q" id="search-query" placeholder="Search..." autocapitalize="off"
autocomplete="off" autocorrect="off" spellcheck="false" type="search">
</div>
</section>
<section class="section-search-results">
<div id="search-hits">
</div>
</section>
</div>
</aside>
<nav class="navbar navbar-light fixed-top navbar-expand-lg py-0 compensate-for-scrollbar" id="navbar-main">
<div class="container">
<a class="navbar-brand" href="/">My BioBits</a>
<button type="button" class="navbar-toggler" data-toggle="collapse"
data-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation">
<span><i class="fas fa-bars"></i></span>
</button>
<div class="collapse navbar-collapse" id="navbar">
<ul class="navbar-nav mr-auto">
<li class="nav-item">
<a class="nav-link " href="/#about"><span>Home</span></a>
</li>
<li class="nav-item">
<a class="nav-link " href="/#posts"><span>Posts</span></a>
</li>
<li class="nav-item">
<a class="nav-link " href="/#featured"><span>Publications</span></a>
</li>
<li class="nav-item">
<a class="nav-link " href="/#talks"><span>Talks</span></a>
</li>
<li class="nav-item">
<a class="nav-link " href="/#contact"><span>Contact</span></a>
</li>
</ul>
<ul class="navbar-nav ml-auto">
<li class="nav-item">
<a class="nav-link js-search" href="#"><i class="fas fa-search" aria-hidden="true"></i></a>
</li>
<li class="nav-item">
<a class="nav-link js-dark-toggle" href="#"><i class="fas fa-moon" aria-hidden="true"></i></a>
</li>
</ul>
</div>
</div>
</nav>
<div class="universal-wrapper pt-3">
<h1 itemprop="name">N. Lee</h1>
</div>
<section id="profile-page" class="pt-5">
<div class="container">
<div class="article-widget">
<div class="hr-light"></div>
<h3>Latest</h3>
<ul>
<li>
<a href="/publication/meijer-2014/">Regulation of miRNA strand selection: follow the leader?</a>
</li>
</ul>
</div>
</div>
</section>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.4.1/jquery.min.js" integrity="sha256-CSXorXvZcTkaix6Yvo6HppcZGetbYMGWSFlBw8HfCJo=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery.imagesloaded/4.1.4/imagesloaded.pkgd.min.js" integrity="sha256-lqvxZrPLtfffUl2G/e7szqSvPBILGbwmsGE1MKlOi0Q=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery.isotope/3.0.6/isotope.pkgd.min.js" integrity="sha256-CBrpuqrMhXwcLLUd5tvQ4euBHCdh7wGlDfNz8vbu/iI=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/fancybox/3.2.5/jquery.fancybox.min.js" integrity="sha256-X5PoE3KU5l+JcX+w09p/wHl9AzK333C4hJ2I9S5mD4M=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.15.6/highlight.min.js" integrity="sha256-aYTdUrn6Ow1DDgh5JTc3aDGnnju48y/1c8s1dgkYPQ8=" crossorigin="anonymous"></script>
<script>hljs.initHighlightingOnLoad();</script>
<script>
const search_index_filename = "/index.json";
const i18n = {
'placeholder': "Search...",
'results': "results found",
'no_results': "No results found"
};
const content_type = {
'post': "Posts",
'project': "Projects",
'publication' : "Publications",
'talk' : "Talks"
};
</script>
<script id="search-hit-fuse-template" type="text/x-template">
<div class="search-hit" id="summary-{{key}}">
<div class="search-hit-content">
<div class="search-hit-name">
<a href="{{relpermalink}}">{{title}}</a>
<div class="article-metadata search-hit-type">{{type}}</div>
<p class="search-hit-description">{{snippet}}</p>
</div>
</div>
</div>
</script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/fuse.js/3.2.1/fuse.min.js" integrity="sha256-VzgmKYmhsGNNN4Ph1kMW+BjoYJM2jV5i4IlFoeZA9XI=" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/mark.js/8.11.1/jquery.mark.min.js" integrity="sha256-4HLtjeVgH0eIB3aZ9mLYF6E8oU5chNdjU6p6rrXpl9U=" crossorigin="anonymous"></script>
<script src="/js/academic.min.16bbb3750feb7244c9bc409a5a4fe678.js"></script>
<div class="container">
<footer class="site-footer">
<p class="powered-by">
Powered by the
<a href="https://sourcethemes.com/academic/" target="_blank" rel="noopener">Academic theme</a> for
<a href="https://gohugo.io" target="_blank" rel="noopener">Hugo</a>.
<span class="float-right" aria-hidden="true">
<a href="#" id="back_to_top">
<span class="button_icon">
<i class="fas fa-chevron-up fa-2x"></i>
</span>
</a>
</span>
</p>
</footer>
</div>
<div id="modal" class="modal fade" role="dialog">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title">Cite</h5>
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">×</span>
</button>
</div>
<div class="modal-body">
<pre><code class="tex hljs"></code></pre>
</div>
<div class="modal-footer">
<a class="btn btn-outline-primary my-1 js-copy-cite" href="#" target="_blank">
<i class="fas fa-copy"></i> Copy
</a>
<a class="btn btn-outline-primary my-1 js-download-cite" href="#" target="_blank">
<i class="fas fa-download"></i> Download
</a>
<div id="modal-error"></div>
</div>
</div>
</div>
</div>
</body>
</html>
|
lpantano/lpantano.github.io
|
authors/n.-lee/index.html
|
HTML
|
mit
| 11,142
|
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<meta name="description" content="">
<meta name="author" content="">
<title>Davi Wesley - Programador</title>
<!-- Bootstrap core CSS -->
<link href="vendor/bootstrap/css/bootstrap.min.css" rel="stylesheet">
<!-- Custom fonts for this template -->
<link href="vendor/font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css">
<link href='https://fonts.googleapis.com/css?family=Open+Sans:300italic,400italic,600italic,700italic,800italic,400,300,600,700,800' rel='stylesheet' type='text/css'>
<link href='https://fonts.googleapis.com/css?family=Merriweather:400,300,300italic,400italic,700,700italic,900,900italic' rel='stylesheet' type='text/css'>
<!-- Plugin CSS -->
<link href="vendor/magnific-popup/magnific-popup.css" rel="stylesheet">
<!-- Custom styles for this template -->
<link href="css/creative.min.css" rel="stylesheet">
</head>
<body id="page-top">
<!-- Navigation -->
<nav class="navbar navbar-expand-lg navbar-light fixed-top" id="mainNav">
<div class="container">
<a class="navbar-brand js-scroll-trigger" href="#page-top">INÍCIO</a>
<button class="navbar-toggler navbar-toggler-right" type="button" data-toggle="collapse" data-target="#navbarResponsive" aria-controls="navbarResponsive" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarResponsive">
<ul class="navbar-nav ml-auto">
<li class="nav-item">
<a class="nav-link js-scroll-trigger" href="#Sobre">Sobre</a>
</li>
<li class="nav-item">
<a class="nav-link js-scroll-trigger" href="#Serviços">Serviços</a>
</li>
<li class="nav-item">
<a class="nav-link js-scroll-trigger" href="#portfólio">Portfólio</a>
</li>
<li class="nav-item">
<a class="nav-link js-scroll-trigger" href="#contato">Contato</a>
</li>
</ul>
</div>
</div>
</nav>
<header class="masthead text-center text-white d-flex">
<div class="container my-auto">
<div class="row">
<div class="col-lg-10 mx-auto">
<h1 class="text-uppercase">
<!-- Texto inicial GRANDE -->
<strong>Your Favorite Source of Free Bootstrap Themes</strong>
</h1>
<hr>
</div>
<div class="col-lg-8 mx-auto">
<!-- Texto inicial PEQUENO -->
<p class="text-faded mb-5">Start Bootstrap can help you build better websites using the Bootstrap CSS framework! Just download your template and start going, no strings attached!</p>
<a class="btn btn-primary btn-xl js-scroll-trigger" href="#about">Veja mais</a>
</div>
</div>
</div>
</header>
<section class="bg-primary" id="about">
<div class="container">
<div class="row">
<div class="col-lg-8 mx-auto text-center">
<h2 class="section-heading text-white">We've got what you need!</h2>
<hr class="light my-4">
<p class="text-faded mb-4">Start Bootstrap has everything you need to get your new website up and running in no time! All of the templates and themes on Start Bootstrap are open source, free to download, and easy to use. No strings attached!</p>
<a class="btn btn-light btn-xl js-scroll-trigger" href="#services">Get Started!</a>
</div>
</div>
</div>
</section>
<section id="services">
<div class="container">
<div class="row">
<div class="col-lg-12 text-center">
<h2 class="section-heading">At Your Service</h2>
<hr class="my-4">
</div>
</div>
</div>
<div class="container">
<div class="row">
<div class="col-lg-3 col-md-6 text-center">
<div class="service-box mt-5 mx-auto">
<i class="fa fa-4x fa-diamond text-primary mb-3 sr-icons"></i>
<h3 class="mb-3">Sturdy Templates</h3>
<p class="text-muted mb-0">Our templates are updated regularly so they don't break.</p>
</div>
</div>
<div class="col-lg-3 col-md-6 text-center">
<div class="service-box mt-5 mx-auto">
<i class="fa fa-4x fa-paper-plane text-primary mb-3 sr-icons"></i>
<h3 class="mb-3">Ready to Ship</h3>
<p class="text-muted mb-0">You can use this theme as is, or you can make changes!</p>
</div>
</div>
<div class="col-lg-3 col-md-6 text-center">
<div class="service-box mt-5 mx-auto">
<i class="fa fa-4x fa-newspaper-o text-primary mb-3 sr-icons"></i>
<h3 class="mb-3">Up to Date</h3>
<p class="text-muted mb-0">We update dependencies to keep things fresh.</p>
</div>
</div>
<div class="col-lg-3 col-md-6 text-center">
<div class="service-box mt-5 mx-auto">
<i class="fa fa-4x fa-heart text-primary mb-3 sr-icons"></i>
<h3 class="mb-3">Made with Love</h3>
<p class="text-muted mb-0">You have to make your websites with love these days!</p>
</div>
</div>
</div>
</div>
</section>
<section class="p-0" id="portfolio">
<div class="container-fluid p-0">
<div class="row no-gutters popup-gallery">
<div class="col-lg-4 col-sm-6">
<a class="portfolio-box" href="img/portfolio/fullsize/1.jpg">
<img class="img-fluid" src="img/portfolio/thumbnails/1.jpg" alt="">
<div class="portfolio-box-caption">
<div class="portfolio-box-caption-content">
<div class="project-category text-faded">
Category
</div>
<div class="project-name">
Project Name
</div>
</div>
</div>
</a>
</div>
<div class="col-lg-4 col-sm-6">
<a class="portfolio-box" href="img/portfolio/fullsize/2.jpg">
<img class="img-fluid" src="img/portfolio/thumbnails/2.jpg" alt="">
<div class="portfolio-box-caption">
<div class="portfolio-box-caption-content">
<div class="project-category text-faded">
Category
</div>
<div class="project-name">
Project Name
</div>
</div>
</div>
</a>
</div>
<div class="col-lg-4 col-sm-6">
<a class="portfolio-box" href="img/portfolio/fullsize/3.jpg">
<img class="img-fluid" src="img/portfolio/thumbnails/3.jpg" alt="">
<div class="portfolio-box-caption">
<div class="portfolio-box-caption-content">
<div class="project-category text-faded">
Category
</div>
<div class="project-name">
Project Name
</div>
</div>
</div>
</a>
</div>
<div class="col-lg-4 col-sm-6">
<a class="portfolio-box" href="img/portfolio/fullsize/4.jpg">
<img class="img-fluid" src="img/portfolio/thumbnails/4.jpg" alt="">
<div class="portfolio-box-caption">
<div class="portfolio-box-caption-content">
<div class="project-category text-faded">
Category
</div>
<div class="project-name">
Project Name
</div>
</div>
</div>
</a>
</div>
<div class="col-lg-4 col-sm-6">
<a class="portfolio-box" href="img/portfolio/fullsize/5.jpg">
<img class="img-fluid" src="img/portfolio/thumbnails/5.jpg" alt="">
<div class="portfolio-box-caption">
<div class="portfolio-box-caption-content">
<div class="project-category text-faded">
Category
</div>
<div class="project-name">
Project Name
</div>
</div>
</div>
</a>
</div>
<div class="col-lg-4 col-sm-6">
<a class="portfolio-box" href="img/portfolio/fullsize/6.jpg">
<img class="img-fluid" src="img/portfolio/thumbnails/6.jpg" alt="">
<div class="portfolio-box-caption">
<div class="portfolio-box-caption-content">
<div class="project-category text-faded">
Category
</div>
<div class="project-name">
Project Name
</div>
</div>
</div>
</a>
</div>
</div>
</div>
</section>
<section id="contact">
<div class="container">
<div class="row">
<div class="col-lg-8 mx-auto text-center">
<h2 class="section-heading">Let's Get In Touch!</h2>
<hr class="my-4">
<p class="mb-5">Ready to start your next project with us? That's great! Give us a call or send us an email and we will get back to you as soon as possible!</p>
</div>
</div>
<div class="row">
<div class="col-lg-4 ml-auto text-center">
<i class="fa fa-phone fa-3x mb-3 sr-contact"></i>
<p>123-456-6789</p>
</div>
<div class="col-lg-4 mr-auto text-center">
<i class="fa fa-envelope-o fa-3x mb-3 sr-contact"></i>
<p>
<a href="mailto:your-email@your-domain.com">feedback@startbootstrap.com</a>
</p>
</div>
</div>
</div>
</section>
<!-- Bootstrap core JavaScript -->
<script src="vendor/jquery/jquery.min.js"></script>
<script src="vendor/bootstrap/js/bootstrap.bundle.min.js"></script>
<!-- Plugin JavaScript -->
<script src="vendor/jquery-easing/jquery.easing.min.js"></script>
<script src="vendor/scrollreveal/scrollreveal.min.js"></script>
<script src="vendor/magnific-popup/jquery.magnific-popup.min.js"></script>
<!-- Custom scripts for this template -->
<script src="js/creative.min.js"></script>
</body>
</html>
|
daviwesley/daviwesley.github.io
|
index.html
|
HTML
|
mit
| 10,884
|
# default-lines
|
gordon2285/default-lines
|
README.md
|
Markdown
|
mit
| 15
|
/**
* @jest-environment ./__tests__/html/__jest__/WebChatEnvironment.js
*/
describe('deprecated <Localize>', () => {
test('should localize text in navigator language', () => runHTMLTest('deprecated.localize.html'));
test('should localize text in "en"', () => runHTMLTest('deprecated.localize.html#l=en'));
test('should localize text in "yue"', () => runHTMLTest('deprecated.localize.html#l=yue'));
});
|
billba/botchat
|
__tests__/html/deprecated.localize.js
|
JavaScript
|
mit
| 411
|
/*
* Swaggy Jenkins
*
* Jenkins API clients generated from Swagger / Open API specification
*
* The version of the OpenAPI document: 1.1.2-pre.0
* Contact: blah@cliffano.com
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// ExtensionClassImpllinks
/// </summary>
[DataContract(Name = "ExtensionClassImpllinks")]
public partial class ExtensionClassImpllinks : IEquatable<ExtensionClassImpllinks>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="ExtensionClassImpllinks" /> class.
/// </summary>
/// <param name="self">self.</param>
/// <param name="_class">_class.</param>
public ExtensionClassImpllinks(Link self = default(Link), string _class = default(string))
{
this.Self = self;
this.Class = _class;
}
/// <summary>
/// Gets or Sets Self
/// </summary>
[DataMember(Name = "self", EmitDefaultValue = false)]
public Link Self { get; set; }
/// <summary>
/// Gets or Sets Class
/// </summary>
[DataMember(Name = "_class", EmitDefaultValue = false)]
public string Class { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
StringBuilder sb = new StringBuilder();
sb.Append("class ExtensionClassImpllinks {\n");
sb.Append(" Self: ").Append(Self).Append("\n");
sb.Append(" Class: ").Append(Class).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return this.Equals(input as ExtensionClassImpllinks);
}
/// <summary>
/// Returns true if ExtensionClassImpllinks instances are equal
/// </summary>
/// <param name="input">Instance of ExtensionClassImpllinks to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(ExtensionClassImpllinks input)
{
if (input == null)
{
return false;
}
return
(
this.Self == input.Self ||
(this.Self != null &&
this.Self.Equals(input.Self))
) &&
(
this.Class == input.Class ||
(this.Class != null &&
this.Class.Equals(input.Class))
);
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.Self != null)
{
hashCode = (hashCode * 59) + this.Self.GetHashCode();
}
if (this.Class != null)
{
hashCode = (hashCode * 59) + this.Class.GetHashCode();
}
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
public IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> Validate(ValidationContext validationContext)
{
yield break;
}
}
}
|
cliffano/swaggy-jenkins
|
clients/csharp-netcore/generated/src/Org.OpenAPITools/Model/ExtensionClassImpllinks.cs
|
C#
|
mit
| 4,780
|
/**
* Created by twi18192 on 25/08/15.
*/
var React = require('react');
var mainPaneStore = require('../stores/mainPaneStore');
var mainPaneActions = require('../actions/mainPaneActions');
var ButtonStyle = {
backgroundColor: 'grey',
height: 25,
width: 70,
borderRadius: 8,
borderStyle:'solid',
borderWidth: 1,
borderColor: 'black',
fontFamily: 'Verdana',
// color: 'white',
textAlign: 'center',
display: 'inline-block',
cursor: 'pointer',
MozUserSelect: 'none'
};
var ButtonTitlePadding = {
position: 'relative',
top: -6
};
function getConfigButtonState(){
return {
configPanelOpen:mainPaneStore.getConfigPanelState()
}
}
var ConfigButton = React.createClass({
getInitialState: function(){
return {
configPanelOpen: mainPaneStore.getConfigPanelState()
}
},
_onChange: function(){
this.setState(getConfigButtonState)
},
handleActionConfigToggle:function(){
mainPaneActions.toggleConfigPanel("this is the item")
},
componentDidMount: function(){
mainPaneStore.addChangeListener(this._onChange)
},
componentWillUnmount: function(){
mainPaneStore.removeChangeListener(this._onChange)
},
render: function() {
return(
<div>
<div id="config" style={ButtonStyle} onClick={this.handleActionConfigToggle} ><span style={ButtonTitlePadding}>Config</span>
</div>
</div>
)}
});
module.exports = ConfigButton;
|
yousefmoazzam/ZebraWithFlux
|
js/views/configButton.js
|
JavaScript
|
mit
| 1,441
|
html, body {
margin: 0;
padding: 0;
overflow: hidden;
height: 100%;
-webkit-touch-callout: none;
-webkit-user-select: none;
-khtml-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
user-select: none;}
html.preload {
/* Would rather have black during loading than white. */
background-color: #000;
}
.mouseIdle, .mouseIdle * {
/* Keeping this for reference, but it causes the mouse to flicker on pushState in chrome */
/*cursor: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAZdEVYdFNvZnR3YXJlAFBhaW50Lk5FVCB2My41LjbQg61aAAAADUlEQVQYV2P4//8/IwAI/QL/+TZZdwAAAABJRU5ErkJggg=='), url(cursors/blank.cur), none !important;*/
cursor: none !important;
}
.docspinner {
display: block;
margin-top: -30px;
margin-left: -30px;
width: 60px;
height: 60px;
position: fixed;
top: 50%;
left: 50%;
z-index: 9999999;
}
.mainAnimatedPages {
position: absolute;
top: 0px;
bottom: 0px;
left: 0px;
right: 0px;
height: 100%;
}
.mainHeader {
position: fixed;
left: 0;
right: 0;
top: 0;
/* This will ensure it is on top of the main body */
z-index: 1;
}
.backdropContainer {
}
.backdropImage {
background-repeat: no-repeat;
background-position: center center;
background-size: cover;
background-attachment: fixed;
position: absolute;
top: 0;
left: 0;
right: 0;
bottom: 0;
}
|
babgvant/Emby.Web
|
css/style.css
|
CSS
|
mit
| 1,558
|
#pragma once
#include <string>
#include <gloperate/gloperate_api.h>
#include <signalzeug/Signal.h>
namespace gloperate
{
class AbstractData;
class AbstractStage;
class GLOPERATE_API AbstractInputSlot
{
friend class AbstractStage;
public:
AbstractInputSlot(const std::string & name = "");
virtual ~AbstractInputSlot();
const std::string & name() const;
void setName(const std::string & name);
bool hasName() const;
std::string asPrintable() const;
bool hasOwner() const;
const AbstractStage * owner() const;
virtual std::string qualifiedName() const;
virtual bool connectTo(const AbstractData & data) = 0;
virtual bool matchType(const AbstractData & data) = 0;
bool hasChanged() const;
void changed();
void processed();
bool isUsable() const;
bool isOptional() const;
void setOptional(bool optional);
bool isFeedback() const;
void setFeedback(bool isFeedback);
virtual const AbstractData * connectedData() const = 0;
bool isConnected() const;
public:
signalzeug::Signal<> connectionChanged;
protected:
AbstractStage * m_owner;
std::string m_name;
bool m_hasChanged;
bool m_isOptional;
bool m_isFeedback;
void setOwner(AbstractStage * owner);
};
} // namespace gloperate
|
hpi-r2d2/gloperate
|
source/gloperate/include/gloperate/pipeline/AbstractInputSlot.h
|
C
|
mit
| 1,313
|
[](https://travis-ci.org/emwi/FlashingmessageTest) [](https://scrutinizer-ci.com/g/emwi/FlashingmessageTest/?branch=master) [](https://scrutinizer-ci.com/g/emwi/FlashingmessageTest/?branch=master)
Flashingmessage - for Anax MVC
=========
This is a message module for Anax-MVC. Can be used outside of anax too. Handles debug, error, success and warning messages/status.
For Anax MVC, see https://github.com/mosbth/Anax-MVC.
License
------------------
This software is free software and carries a MIT license.
How to use
----------------
First you need a area on your page where Flashingmessage can show the div elements. In anax mvc use this:
File: /theme/anax-base/index.tpl.php
<?php if ($this->views->hasContent('status')) : ?>
<div id='status'>
<?php if(isset($status)) echo $status?>
<?php $this->views->render('status')?>
</div>
<?php endif; ?>
Then you need to add Flashingmessage to your CDIFacrotyDefault:
$this->setShared('StatusMessage', function() {
$module = new \TBM\StatusMessage\CStatusMessage($this);
//$module->setDI($this);
return $module;
});
Then for displaying Flashingmessage on your page copy this to your code.
$status = $app->StatusMessage;
$app->views->addString($status->messagesHtml(), 'status');
Then you can choose between four different messages:
addDebugMessage($message)
addErrorMessage($message)
addSuccessMessage($message)
addWarningMessage($message)
```
.
..: Created by Emma Wiklund, wiklund_e@hotmail.com.
```
|
emwi/FlashingmessageTest
|
README.md
|
Markdown
|
mit
| 1,825
|
<?php
/**
* Github Stylish Repository Viewer
* An easy way to show your Github profile on your site - in style!
*
* @author Austin Burdine <austin@acburdine.me>
* @copyright 2015 Austin Burdine
* @link https://github.com/acburdine/repo-viewer/
* @license (MIT) - https://github.com/acburdine/repo-viewer/blob/master/LICENSE
* @version 1.0.0
*/
namespace Acburdine\RepoViewer\Model;
class Theme {
protected static $themesDir = './content/themes/';
protected static $requiredFiles = array(
'index.hbs',
'project.hbs',
'package.json'
);
protected $dir;
protected $name;
protected $version;
public function __construct($dir) {
$this->dir = $dir;
$this->setThemeInfo();
}
public function getPath($pathToAdd = '') {
return self::$themesDir . $this->dir . $pathToAdd;
}
public function getArray() {
return array(
'name' => $this->name,
'version' => $this->version
);
}
protected function setThemeInfo() {
$package = json_decode(file_get_contents($this->dir.DIRECTORY_SEPARATOR.'package.json'), true);
$this->name = $package['name'];
$this->version = $package['version'];
}
public static function getActiveTheme() {
$settings = Settings::getSettings();
return new Theme($settings->get('activeTheme'));
}
public static function getAllThemes() {
$foldersInDir = scandir(self::$themesDir);
$themes = array();
foreach($foldersInDir as $folder) {
$path = self::$themesDir.$folder;
if(self::checkIsValidTheme($path)) {
$theme = new Theme($path);
$themes[] = $theme->getArray();
}
}
return $themes;
}
protected static function checkIsValidTheme($themeDir) {
if(array_diff(self::$requiredFiles, scandir($themeDir))) {
return false;
}
$package = json_decode(file_get_contents($themeDir.DIRECTORY_SEPARATOR.'package.json'), true);
return array_key_exists('name', $package) && array_key_exists('version', $package);
}
}
|
acburdine/repo-viewer
|
src/Model/Theme.php
|
PHP
|
mit
| 2,203
|
<div>
<h3>You must be logged in to see this page</h3>
</div>
|
JS-Applications-Team-Mai-Tai/Team-Mai-Tai
|
templates/userGames.html
|
HTML
|
mit
| 64
|
#include "treeface/math/Mat4.h"
#include <stdio.h>
using namespace treecore;
namespace treeface {
static_assert( sizeof(Mat4f) == sizeof(float)*16 , "");
static_assert( sizeof(Mat4f::DataType) == sizeof(float)*4, "");
static_assert( sizeof(Mat4f::DataType::DataType) == sizeof(float)*4, "");
template<>
float Mat4<float>::determinant() const noexcept
{
// + 00*11*22*33 + 00*21*32*13 + 00*31*12*23 - 00*31*22*13 - 00*21*12*33 - 00*11*32*23
// + 10*31*22*03 + 10*21*02*33 + 10*01*32*23 - 10*01*22*33 - 10*21*32*03 - 10*31*02*23
// + 20*01*12*33 + 20*11*32*03 + 20*31*02*13 - 20*31*12*03 - 20*11*02*33 - 20*01*32*13
// + 30*21*12*03 + 30*11*02*23 + 30*01*22*13 - 30*01*12*23 - 30*11*22*03 - 30*21*02*13
DataType re(0.0f);
DataType v0 = data[0];
// +
DataType v1 = data[1].template get_shuffle<1, 3, 0, 2>();
DataType v2 = data[2].template get_shuffle<2, 2, 1, 1>();
DataType v3 = data[3].template get_shuffle<3, 0, 3, 0>();
re += v0 * v1 * v2 * v3;
v1 = data[1].template get_shuffle<2, 2, 1, 1>();
v2 = data[2].template get_shuffle<3, 0, 3, 0>();
v3 = data[3].template get_shuffle<1, 3, 0, 2>();
re += v0 * v1 * v2 * v3;
v1 = data[1].template get_shuffle<3, 0, 3, 0>();
v2 = data[2].template get_shuffle<1, 3, 0, 2>();
v3 = data[3].template get_shuffle<2, 2, 1, 1>();
re += v0 * v1 * v2 * v3;
// -
v1 = data[1].template get_shuffle<3, 0, 3, 0>();
v2 = data[2].template get_shuffle<2, 2, 1, 1>();
v3 = data[3].template get_shuffle<1, 3, 0, 2>();
re -= v0 * v1 * v2 * v3;
v1 = data[1].template get_shuffle<2, 2, 1, 1>();
v2 = data[2].template get_shuffle<1, 3, 0, 2>();
v3 = data[3].template get_shuffle<3, 0, 3, 0>();
re -= v0 * v1 * v2 * v3;
v1 = data[1].template get_shuffle<1, 3, 0, 2>();
v2 = data[2].template get_shuffle<3, 0, 3, 0>();
v3 = data[3].template get_shuffle<2, 2, 1, 1>();
re -= v0 * v1 * v2 * v3;
return re.sum();
}
template<>
void Mat4<float>::set_perspective(float vertical_angle, float ratio, float near, float far) noexcept
{
if (ratio == 0.0f || near == far)
return;
float sine = std::sin(vertical_angle);
if (sine == 0.0f)
return;
float cotan = std::cos(vertical_angle) / sine;
float depth = far - near;
float xx = cotan / ratio;
float yy = cotan;
float zz = -(near + far) / depth;
float zw = -2.0f * near * far / depth;
set(xx, 0, 0, 0,
0, yy, 0, 0,
0, 0, zz, -1,
0, 0, zw, 1);
}
template<typename T>
Mat4<T> operator * (const Mat4<T>& a, const Mat4<T>& b) noexcept
{
// column to row
Mat4<T> a_t = a;
a_t.transpose();
// multiply rows in A with columns in B
Mat4f::DataType re0((a_t.data[0] * b.data[0]).sum(),
(a_t.data[1] * b.data[0]).sum(),
(a_t.data[2] * b.data[0]).sum(),
(a_t.data[3] * b.data[0]).sum());
Mat4f::DataType re1((a_t.data[0] * b.data[1]).sum(),
(a_t.data[1] * b.data[1]).sum(),
(a_t.data[2] * b.data[1]).sum(),
(a_t.data[3] * b.data[1]).sum());
Mat4f::DataType re2((a_t.data[0] * b.data[2]).sum(),
(a_t.data[1] * b.data[2]).sum(),
(a_t.data[2] * b.data[2]).sum(),
(a_t.data[3] * b.data[2]).sum());
Mat4f::DataType re3((a_t.data[0] * b.data[3]).sum(),
(a_t.data[1] * b.data[3]).sum(),
(a_t.data[2] * b.data[3]).sum(),
(a_t.data[3] * b.data[3]).sum());
return Mat4<T>(re0, re1, re2, re3);
}
template
Mat4<float> operator * (const Mat4<float>& a, const Mat4<float>& b) noexcept;
template<typename T>
Vec4<T> operator * (const Mat4<T>& mat, const Vec4<T>& vec) noexcept
{
// column to row
Mat4<T> mat_t = mat;
mat_t.transpose();
return Vec4<T>((mat_t.data[0] * vec.data).sum(),
(mat_t.data[1] * vec.data).sum(),
(mat_t.data[2] * vec.data).sum(),
(mat_t.data[3] * vec.data).sum());
}
template
Vec4<float> operator * (const Mat4<float>& mat, const Vec4<float>& vec) noexcept;
} // namespace treeface
|
jiandingzhe/treeface
|
src/treeface/math/Mat4.cpp
|
C++
|
mit
| 4,277
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Frameset//EN""http://www.w3.org/TR/REC-html40/frameset.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc on Fri Sep 14 18:24:04 EDT 2007 -->
<TITLE>
Xerces2 Implementation: Class XMLEntityManager.InternalEntity
</TITLE>
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style">
</HEAD>
<BODY BGCOLOR="white">
<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_top"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.ExternalEntity.html"><B>PREV CLASS</B></A>
<A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.RewindableInputStream.html"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A>
<A HREF="XMLEntityManager.InternalEntity.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: INNER | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
org.apache.xerces.impl</FONT>
<BR>
Class XMLEntityManager.InternalEntity</H2>
<PRE>
java.lang.Object
|
+--<A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html">org.apache.xerces.impl.XMLEntityManager.Entity</A>
|
+--<B>org.apache.xerces.impl.XMLEntityManager.InternalEntity</B>
</PRE>
<DL>
<DT><B>Enclosing class: </B><DD><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.html">XMLEntityManager</A></DD>
</DL>
<HR>
<DL>
<DT>protected static class <B>XMLEntityManager.InternalEntity</B><DT>extends <A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html">XMLEntityManager.Entity</A></DL>
<P>
Internal entity.
<DL><DT><H1 style="font-size:110%">INTERNAL:</H1><DD>Usage of this class is not supported. It may be altered or removed at any time.</DD></DT></DL>
<P>
<DL>
<DT><B>Author: </B><DD>Andy Clark, IBM</DD>
</DL>
<HR>
<P>
<!-- ======== INNER CLASS SUMMARY ======== -->
<!-- =========== FIELD SUMMARY =========== -->
<A NAME="field_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Field Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> java.lang.String</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.InternalEntity.html#text">text</A></B></CODE>
<BR>
Text value of entity.</TD>
</TR>
</TABLE>
<A NAME="fields_inherited_from_class_org.apache.xerces.impl.XMLEntityManager.Entity"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Fields inherited from class org.apache.xerces.impl.<A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html">XMLEntityManager.Entity</A></B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html#inExternalSubset">inExternalSubset</A>, <A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html#name">name</A></CODE></TD>
</TR>
</TABLE>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.InternalEntity.html#XMLEntityManager.InternalEntity()">XMLEntityManager.InternalEntity</A></B>()</CODE>
<BR>
Default constructor.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.InternalEntity.html#XMLEntityManager.InternalEntity(java.lang.String, java.lang.String, boolean)">XMLEntityManager.InternalEntity</A></B>(java.lang.String name,
java.lang.String text,
boolean inExternalSubset)</CODE>
<BR>
Constructs an internal entity.</TD>
</TR>
</TABLE>
<!-- ========== METHOD SUMMARY =========== -->
<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=2><FONT SIZE="+2">
<B>Method Summary</B></FONT></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.InternalEntity.html#clear()">clear</A></B>()</CODE>
<BR>
Clears the entity.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.InternalEntity.html#isExternal()">isExternal</A></B>()</CODE>
<BR>
Returns true if this is an external entity.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> boolean</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.InternalEntity.html#isUnparsed()">isUnparsed</A></B>()</CODE>
<BR>
Returns true if this is an unparsed entity.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.InternalEntity.html#setValues(org.apache.xerces.impl.XMLEntityManager.Entity)">setValues</A></B>(<A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html">XMLEntityManager.Entity</A> entity)</CODE>
<BR>
Sets the values of the entity.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.InternalEntity.html#setValues(org.apache.xerces.impl.XMLEntityManager.InternalEntity)">setValues</A></B>(<A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.InternalEntity.html">XMLEntityManager.InternalEntity</A> entity)</CODE>
<BR>
Sets the values of the entity.</TD>
</TR>
</TABLE>
<A NAME="methods_inherited_from_class_org.apache.xerces.impl.XMLEntityManager.Entity"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class org.apache.xerces.impl.<A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html">XMLEntityManager.Entity</A></B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html#isEntityDeclInExternalSubset()">isEntityDeclInExternalSubset</A></CODE></TD>
</TR>
</TABLE>
<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TD><B>Methods inherited from class java.lang.Object</B></TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
<P>
<!-- ============ FIELD DETAIL =========== -->
<A NAME="field_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Field Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="text"><!-- --></A><H3>
text</H3>
<PRE>
public java.lang.String <B>text</B></PRE>
<DL>
<DD>Text value of entity.</DL>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="XMLEntityManager.InternalEntity()"><!-- --></A><H3>
XMLEntityManager.InternalEntity</H3>
<PRE>
public <B>XMLEntityManager.InternalEntity</B>()</PRE>
<DL>
<DD>Default constructor.</DL>
<HR>
<A NAME="XMLEntityManager.InternalEntity(java.lang.String, java.lang.String, boolean)"><!-- --></A><H3>
XMLEntityManager.InternalEntity</H3>
<PRE>
public <B>XMLEntityManager.InternalEntity</B>(java.lang.String name,
java.lang.String text,
boolean inExternalSubset)</PRE>
<DL>
<DD>Constructs an internal entity.</DL>
<!-- ============ METHOD DETAIL ========== -->
<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TD COLSPAN=1><FONT SIZE="+2">
<B>Method Detail</B></FONT></TD>
</TR>
</TABLE>
<A NAME="isExternal()"><!-- --></A><H3>
isExternal</H3>
<PRE>
public final boolean <B>isExternal</B>()</PRE>
<DL>
<DD>Returns true if this is an external entity.<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html#isExternal()">isExternal</A></CODE> in class <CODE><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html">XMLEntityManager.Entity</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="isUnparsed()"><!-- --></A><H3>
isUnparsed</H3>
<PRE>
public final boolean <B>isUnparsed</B>()</PRE>
<DL>
<DD>Returns true if this is an unparsed entity.<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html#isUnparsed()">isUnparsed</A></CODE> in class <CODE><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html">XMLEntityManager.Entity</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="clear()"><!-- --></A><H3>
clear</H3>
<PRE>
public void <B>clear</B>()</PRE>
<DL>
<DD>Clears the entity.<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html#clear()">clear</A></CODE> in class <CODE><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html">XMLEntityManager.Entity</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="setValues(org.apache.xerces.impl.XMLEntityManager.Entity)"><!-- --></A><H3>
setValues</H3>
<PRE>
public void <B>setValues</B>(<A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html">XMLEntityManager.Entity</A> entity)</PRE>
<DL>
<DD>Sets the values of the entity.<DD><DL>
<DT><B>Overrides:</B><DD><CODE><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html#setValues(org.apache.xerces.impl.XMLEntityManager.Entity)">setValues</A></CODE> in class <CODE><A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.Entity.html">XMLEntityManager.Entity</A></CODE></DL>
</DD>
</DL>
<HR>
<A NAME="setValues(org.apache.xerces.impl.XMLEntityManager.InternalEntity)"><!-- --></A><H3>
setValues</H3>
<PRE>
public void <B>setValues</B>(<A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.InternalEntity.html">XMLEntityManager.InternalEntity</A> entity)</PRE>
<DL>
<DD>Sets the values of the entity.</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>
<!-- ========== START OF NAVBAR ========== -->
<A NAME="navbar_bottom"><!-- --></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.ExternalEntity.html"><B>PREV CLASS</B></A>
<A HREF="../../../../org/apache/xerces/impl/XMLEntityManager.RewindableInputStream.html"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../index.html" TARGET="_top"><B>FRAMES</B></A>
<A HREF="XMLEntityManager.InternalEntity.html" TARGET="_top"><B>NO FRAMES</B></A></FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: INNER | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<!-- =========== END OF NAVBAR =========== -->
<HR>
Copyright © 1999-2007 The Apache Software Foundation. All Rights Reserved.
</BODY>
</HTML>
|
Baltasarq/Gia
|
src/JDom/Xerces-J-bin.2.9.1/docs/javadocs/xerces2/org/apache/xerces/impl/XMLEntityManager.InternalEntity.html
|
HTML
|
mit
| 16,446
|
/**
* Copyright (C) 2010-14 diirt developers. See COPYRIGHT.TXT
* All rights reserved. Use is subject to license terms. See LICENSE.TXT
*/
package org.diirt.graphene;
import org.diirt.util.stats.StatisticsUtil;
import org.diirt.util.stats.Statistics;
import java.util.Random;
import org.diirt.util.array.ArrayDouble;
import org.diirt.util.array.ListNumber;
import org.diirt.util.stats.Range;
/**
*
* @author carcassi
*/
public class MockDataset1D implements Point1DDataset {
private ListNumber values;
private double minValue = Double.POSITIVE_INFINITY;
private double maxValue = Double.NEGATIVE_INFINITY;
private Statistics statistics;
public MockDataset1D(double[] data) {
values = new ArrayDouble(data);
statistics = StatisticsUtil.statisticsOf(values);
}
@Override
public Statistics getStatistics() {
return statistics;
}
@Override
public Range getDisplayRange() {
return null;
}
@Override
public int getCount() {
return values.size();
}
@Override
public ListNumber getValues() {
return values;
}
public static Point1DDataset gaussian(int nSamples) {
Random rand = new Random();
double[] values = new double[nSamples];
for (int i = 0; i < values.length; i++) {
values[i] = rand.nextGaussian();
}
return new MockDataset1D(values);
}
}
|
ControlSystemStudio/diirt
|
graphene/graphene/src/test/java/org/diirt/graphene/MockDataset1D.java
|
Java
|
mit
| 1,433
|
---
layout: default
---
<article class="post">
<h1>{{ page.title }}</h1>
<div class="entry">
<!-- code highlight -->
<link rel="stylesheet" href="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/styles/default.min.css">
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/highlight.min.js"></script>
<!-- code highlight end-->
{{ content }}
</div>
<div class="date">
Written on {{ page.date | date: "%B %e, %Y" }}
</div>
{% include disqus.html %}
</article>
|
superblr/superblr.github.io
|
_layouts/post.html
|
HTML
|
mit
| 519
|
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>18 --> 19</title>
<link href="./../../assets/style.css" rel="stylesheet">
</head>
<body>
<h2>You have to be fast</h2>
<a href="./7791359f81254f68d7746c6b8fbb52c191d06fbc9c100d07bdcfed08b3a6afc9.html">Teleport</a>
<hr>
<a href="./../../about.md">About</a> (Spoilers! )
<script src="./../../assets/md5.js"></script>
<script>
window.currentLevel = 7;
</script>
<script src="./../../assets/script.js"></script>
</body>
</html>
|
simonmysun/praxis
|
TAIHAO2019/pub/SmallGame/AsFastAsYouCan2/15936ea97c16c093bcf7ae4c53d6bf5e4c1712bf51abdfc119dcb9e063cb19c3.html
|
HTML
|
mit
| 550
|
<?php
namespace Cssr\MainBundle\Entity;
use Doctrine\ORM\Mapping as ORM;
use Doctrine\Common\Collections\ArrayCollection;
/**
* @ORM\Entity
* @ORM\Table(name="cssr_standard")
*/
class Standard
{
/**
* @var integer
*
* @ORM\Column(name="id", type="integer")
* @ORM\Id
* @ORM\GeneratedValue(strategy="IDENTITY")
*/
protected $id;
/**
* @var string
*
* @ORM\Column(name="name", type="string", length=100, nullable=true)
*/
protected $name;
/**
* @var \Doctrine\Common\Collections\Collection
*
* @ORM\ManyToMany(targetEntity="Cssr\MainBundle\Entity\Comment", mappedBy="standards")
*/
protected $comments;
/**
* Constructor
*/
public function __construct()
{
$this->comments = new ArrayCollection();
}
/**
* Get id
*
* @return integer
*/
public function getId()
{
return $this->id;
}
/**
* Set name
*
* @param string $name
* @return Standard
*/
public function setName($name)
{
$this->name = $name;
return $this;
}
/**
* Get name
*
* @return string
*/
public function getName()
{
return $this->name;
}
/**
* Add comments
*
* @param \Cssr\MainBundle\Entity\Comment $comment
* @return Center
*/
public function addComment(\Cssr\MainBundle\Entity\Comment $comment)
{
$this->comments->add($comment);
return $this;
}
/**
* Remove comments
*
* @param \Cssr\MainBundle\Entity\Comment $comment
*/
public function removeComment(\Cssr\MainBundle\Entity\Comment $comment)
{
$this->comments->removeElement($comment);
}
/**
* Get comments
*
* @return \Doctrine\Common\Collections\Collection
*/
public function getComments()
{
return $this->comments;
}
/**
* Set comments
*
* @param \Doctrine\Common\Collections\ArrayCollection $comments
*/
public function setComments(ArrayCollection $comments)
{
$this->comments = $comments;
}
}
|
spcmky/cssr
|
src/Cssr/MainBundle/Entity/Standard.php
|
PHP
|
mit
| 2,191
|
<!doctype html>
<html ng-app="app">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<script type="text/javascript" src="../lib/angular/angular.js" charset="utf-8"></script>
<script type="text/javascript" src="../lib/rxjs/rx.lite.js" charset="utf-8"></script>
<script type="text/javascript" src="../../reactiveproperty-angular.js" charset="utf-8"></script>
<script type="text/javascript" src="validation.js" charset="utf-8"></script>
</head>
<body>
<div ng-controller="ValidationCtrl">
<form name="myform" nonvalidate>
<input type="text" name="inputText" ng-model="inputText.value" ng-minlength="4" ng-maxlength="10" required>
<span class="error" ng-show="myform.inputText.$error.required">Required</span>
<span class="error" ng-show="myform.inputText.$error.minlength">Length too short</span>
<span class="error" ng-show="myform.inputText.$error.maxlength">Length too long</span>
<span class="valid" ng-show="myform.inputText.$valid">OK</span>
</form>
<br/>
{{displayText.value}}
<br/>
<button rp-command="displayCommand" rp-parameter="inputText.value">Is TextBox invalid?</button>
</div>
</body>
</html>
|
zoetrope/reactiveproperty-angular
|
sample/validation/validation.html
|
HTML
|
mit
| 1,231
|
@extends('layouts.admin_template')
@section('content')
<div class='row'>
<div class='col-md-8'>
<!-- Box -->
<div class="box box-primary">
<div class="box-header with-border">
<h3 class="box-title">@if($function=='create')新建@else更新@endif角色</h3>
</div>
@if($function=='create')
{!! Form::open(['route' => 'role.store']) !!}
@else
{!! Form::model($role, ['route' => ['role.update', $role->id],'method' => 'put']) !!}
@endif
<div class="box-body">
@include('errors.submitError')
{{ Form::bsText('name','角色名称') }}
{{ Form::bsText('display_name','显示名称') }}
{{ Form::bsTextArea('description','描述',null,['style'=>'height:4em']) }}
</div><!-- /.box-body -->
<div class="box-footer">
{{ Form::bsButton('cancel','btn-default','取消',route('role.index')) }}
{{ Form::bsButton('submit','btn-info pull-right','保存') }}
</div><!-- /.box-footer-->
{!! Form::close() !!}
</div><!-- /.box -->
</div><!-- /.col -->
</div><!-- /.row -->
@endsection
|
cornor/newwarehouse
|
resources/views/admin/role/create.blade.php
|
PHP
|
mit
| 1,368
|
package org.reasm.m68k.assembly.internal;
import java.io.IOException;
import javax.annotation.Nonnull;
import javax.annotation.concurrent.Immutable;
/**
* The <code>CHK</code> instruction.
*
* @author Francis Gagné
*/
@Immutable
class ChkInstruction extends TwoFixedEaInstruction {
@Nonnull
static final ChkInstruction CHK = new ChkInstruction();
private ChkInstruction() {
super(AddressingModeCategory.DATA, AddressingModeCategory.DATA_REGISTER_DIRECT);
}
@Override
void assemble(M68KAssemblyContext context, InstructionSize size, EffectiveAddress ea0, EffectiveAddress ea1) throws IOException {
final int sizeField;
switch (size) {
case BYTE:
context.addInvalidSizeAttributeErrorMessage();
//$FALL-THROUGH$
case WORD:
case DEFAULT:
default:
sizeField = 1 << 7;
break;
case LONG:
checkInstructionSet(InstructionSetCheck.MC68020_OR_LATER, context);
sizeField = 0;
break;
}
ea0.word0 |= 0b01000001_00000000 | ea1.getRegister() << 9 | sizeField;
context.appendEffectiveAddress(ea0);
}
}
|
reasm/reasm-m68k
|
src/main/java/org/reasm/m68k/assembly/internal/ChkInstruction.java
|
Java
|
mit
| 1,200
|
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "pl.h"
/**
* Returns true if the character is a letter.
*
* @param c The character
* @return True if a letter.
*/
static uint32_t is_letter(char c)
{
return (c >= 'a' && c <= 'z') || (c >= 'A' && c <= 'Z');
}
/**
* Counts the number of tokens in string str separated by delimiter delim.
*
* @param str The input string.
* @param delim The token delimiter.
* @return The number of tokens.
*/
static uint32_t count_tokens(char *str, char delim)
{
uint32_t count = 1;
char *tmp = str;
while (*tmp) {
if (*tmp == delim) {
count++;
}
tmp++;
}
return count;
}
/**
* public domain strtok_r() by Charlie Gordon
*
* from comp.lang.c 9/14/2007
*
* http://groups.google.com/group/comp.lang.c/msg/2ab1ecbb86646684
*
* (Declaration that it's public domain):
* http://groups.google.com/group/comp.lang.c/msg/7c7b39328fefab9c
*/
static char* strtok_r(char *str, const char *delim, char **nextp)
{
char *ret;
if (str == NULL) {
str = *nextp;
}
str += strspn(str, delim);
if (*str == '\0') {
return NULL;
}
ret = str;
str += strcspn(str, delim);
if (*str) {
*str++ = '\0';
}
*nextp = str;
return ret;
}
/**
* Parses a propositional logic literal.
*
* @param str The input string.
* @param literal The output literal.
*/
static void parse_literal(char *str, PL_LITERAL *literal)
{
literal->negated = 0;
char *tmp = str;
while (*tmp) {
if (*tmp == '~') {
literal->negated = 1;
} else if (is_letter(*tmp)) {
literal->variable = *tmp;
break;
}
tmp++;
}
}
/**
* Parses a propositional logic disjunctions.
*
* @param str The input string.
* @param result The output disjunction.
*/
static void parse_disjunction(char *str, PL_DISJUNCTION *result)
{
result->count = count_tokens(str, 'v');
result->literals = calloc(result->count, sizeof(PL_LITERAL));
char *end_str = NULL;
char* token = strtok_r(str, "v", &end_str);
uint32_t index = 0;
while (token) {
parse_literal(token, &result->literals[index]);
token = strtok_r(NULL, "v", &end_str);
index++;
}
}
/**
* Parses a propositional logic conjunction.
*
* @param str The input string.
* @return A propositional logic conjunction.
*/
PL_CONJUNCTION* pl_parse(char *str)
{
PL_CONJUNCTION* result = calloc(1, sizeof(PL_CONJUNCTION));
result->count = count_tokens(str, '^');
result->disjunctions = calloc(result->count, sizeof(PL_DISJUNCTION));
char *end_str = NULL;
char* token = strtok_r(str, "^", &end_str);
uint32_t index = 0;
while (token) {
parse_disjunction(token, &result->disjunctions[index]);
token = strtok_r(NULL, "^", &end_str);
index++;
}
return result;
}
/**
* Determines if a literal is satisfied by an interpretation.
*
* @param lit The literal.
* @param inter The interpretation.
* @return PL_TRUE if satisfied;
* PL_FALSE if not satisfied;
* PL_UNDEFINED if unsolvable.
*/
static uint8_t lit_satisfied(PL_LITERAL *lit, PL_INTERPRETATION *inter)
{
uint8_t result = inter->dictionary[(uint8_t)lit->variable];
if (result == PL_UNDEFINED) {
return PL_UNDEFINED;
}
if (lit->negated) {
return result == PL_TRUE ? PL_FALSE : PL_TRUE;
}
return result;
}
/**
* Determines if a disjunction is satisfied by an interpretation.
*
* @param disj The disjunction.
* @param inter The interpretation.
* @return PL_TRUE if satisfied;
* PL_FALSE if not satisfied;
* PL_UNDEFINED if unsolvable.
*/
uint8_t pl_is_disjunction_satisfied(
PL_DISJUNCTION* disj,
PL_INTERPRETATION *inter)
{
uint32_t undefined = 0;
for (uint32_t i = 0; i < disj->count; i++) {
PL_LITERAL *literal = &disj->literals[i];
uint8_t result = lit_satisfied(literal, inter);
if (result == PL_TRUE) {
return PL_TRUE;
}
if (result == PL_UNDEFINED) {
undefined = 1;
}
}
return undefined ? PL_UNDEFINED : PL_FALSE;
}
/**
* Determines if a conjunction is satisfied by an interpretation.
*
* @param conj The conjunction.
* @param inter The interpretation.
* @return PL_TRUE if satisfied;
* PL_FALSE if not satisfied;
* PL_UNDEFINED if unsolvable.
*/
uint8_t pl_is_satisfied(PL_CONJUNCTION *conj, PL_INTERPRETATION *inter)
{
for (uint32_t i = 0; i < conj->count; i++) {
PL_DISJUNCTION *disjunction = &conj->disjunctions[i];
uint8_t result = pl_is_disjunction_satisfied(disjunction, inter);
if (result != PL_TRUE) {
return result;
}
}
return PL_TRUE;
}
/**
* Creates a default interpretation for the conjunction.
* All used variables are set to PL_FALSE.
* All unused variables are set to PL_UNDEFINED.
*
* @param conjunction The conjunction.
* @param default_value The default value for all used variables.
* @return A default interpretation.
*/
PL_INTERPRETATION* pl_create_interpretation(
PL_CONJUNCTION *conjunction,
uint8_t default_value)
{
PL_INTERPRETATION* result = calloc(1, sizeof(PL_INTERPRETATION));
for (uint32_t i = 0; i < PL_MAX_VARS; i++) {
result->dictionary[i] = PL_UNUSED;
}
for (uint32_t i = 0; i < conjunction->count; i++) {
PL_DISJUNCTION* disjunction = &conjunction->disjunctions[i];
for (uint32_t j = 0; j < disjunction->count; j++) {
PL_LITERAL* literal = &disjunction->literals[j];
result->dictionary[(uint8_t)literal->variable] = default_value;
}
}
return result;
}
/**
* Prints the interpretation to stdout.
*
* @param inter The interpretation.
*/
void pl_print_interpretation(PL_INTERPRETATION *inter)
{
if (inter == NULL) {
printf("No solution\n");
return;
}
for (uint32_t i = 0; i < PL_MAX_VARS; i++) {
if (inter->dictionary[i] == PL_UNUSED) {
continue;
}
if (is_letter(i)) {
printf("%c = ", (char)i);
switch (inter->dictionary[i]) {
case PL_FALSE:
printf("False\n");
break;
case PL_TRUE:
printf("True\n");
break;
case PL_UNDEFINED:
printf("Undefined\n");
break;
}
}
}
}
/**
* Steps the brute force solution.
* Imagine that each *used* variable is a bit in a twos compliment number.
* We simply count up in binary.
* If there is an overflow (i.e., all bits are true), then we quit.
*
* @param conj The conjunction.
* @param inter The interpretation.
* @return True if exhausted; false if more possible solutions exist.
*/
static uint8_t step_brute_force(PL_CONJUNCTION *conj, PL_INTERPRETATION *inter)
{
for (uint32_t i = 0; i < PL_MAX_VARS; i++) {
if (inter->dictionary[i] == PL_UNDEFINED ||
inter->dictionary[i] == PL_UNUSED) {
// Unused variable -> ignore
continue;
}
if (inter->dictionary[i] == PL_TRUE) {
// Variable is true -> flip to false and continue.
inter->dictionary[i] = PL_FALSE;
} else {
inter->dictionary[i] = PL_TRUE;
// First false variable -> flip to true and return.
return 0;
}
}
return 1;
}
/**
* Attempts to solve the conjunction using brute force.
*
* @param conjunction The conjunction.
* @return The first interpretation that solves the conjunction.
*/
PL_INTERPRETATION* pl_brute_force(PL_CONJUNCTION *conjunction)
{
PL_INTERPRETATION* inter = pl_create_interpretation(conjunction, PL_FALSE);
while (pl_is_satisfied(conjunction, inter) != PL_TRUE) {
if (step_brute_force(conjunction, inter)) {
// We exhausted all possible interpretations.
// The conjunction is unsolvable.
free(inter);
return NULL;
}
}
return inter;
}
|
codyebberson/sat
|
src/pl.c
|
C
|
mit
| 8,227
|
'use strict';
/**
* Profile class that normalizes profile data fetched from authentication provider
*/
Object.defineProperty(exports, "__esModule", {
value: true
});
function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
function formatAddress(address) {
var result = address;
if (result) {
result.formatted = result.street_address + '\n' + result.postal_code + ' ' + result.locality + '\n' + result.country;
return result;
}
return null;
}
var Profile =
/**
* @param data {object}
*/
exports.Profile = function Profile(data) {
_classCallCheck(this, Profile);
var fields = ['_raw', 'address', 'at_hash', 'birthdate', 'email_verified', 'email', 'family_name', 'gender', 'given_name', 'id', 'locale', 'middle_name', 'name', 'nickname', 'phone_number_verified', 'phone_number', 'picture', 'preferred_username', 'profile', 'provider', 'sub', 'updated_at', 'website', 'zoneinfo'];
this._raw = data;
var _iteratorNormalCompletion = true;
var _didIteratorError = false;
var _iteratorError = undefined;
try {
for (var _iterator = fields[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
var field = _step.value;
if (data.hasOwnProperty(field)) {
var value = data[field];
if (field === 'address') {
this.address = formatAddress(data.address);
} else {
this[field] = value || null;
}
}
}
} catch (err) {
_didIteratorError = true;
_iteratorError = err;
} finally {
try {
if (!_iteratorNormalCompletion && _iterator.return) {
_iterator.return();
}
} finally {
if (_didIteratorError) {
throw _iteratorError;
}
}
}
};
|
securityvoid/serverless-authentication
|
lib/profile.js
|
JavaScript
|
mit
| 1,866
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace _24___Order_words
{
class OrderWords
{
static void Main()
{
Console.WriteLine("Enter text: ");
string input = Console.ReadLine();
string[] words = input.Split(' ');
var sortedWords =
from w in words
orderby w
select w;
Console.WriteLine("The sorted list of words:");
foreach (var w in sortedWords)
{
Console.Write(w + " ");
}
}
}
}
|
pawelangelow/TelerikAcademy
|
C#2/Strings and Text Processing/24 - Order words/OrderWords.cs
|
C#
|
mit
| 646
|
import React from 'react';
import PureComponent from 'react-pure-render/component';
class Description extends PureComponent {
render() {
return (
<div><input type="text" value="" placeholder="I am description" /></div>
);
}
}
export default Description;
|
trendmicro/serverless-survey-forms
|
web/portal/src/components/Form/Description/index.js
|
JavaScript
|
mit
| 294
|
/*
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
#pragma once
namespace facebook {
namespace memcache {
namespace mcrouter {
/**
* This function will issue a metaget to the route handle specified
* to retrieve its exptime and then calculate a TTL based on the
* current time and the object's exptime. The TTL from this
* moment forward should be very close in exptime of the original
* object queried.
* This is useful when we need a TTL to be set onto a new object that
* has the same expiration time of another object.
*
* @param(rh) - route handle to send the metaget to
* @param(key) - the key of the object in question
* @param(newExptime) - an out parameter of the new exptime
*
* @return(bool) - true if operation is successful,
* false if a miss or if the new exptime
* is already in the past.
*/
template <class RouteHandleIf>
static bool getExptimeFromRoute(
const std::shared_ptr<RouteHandleIf>& rh,
const folly::StringPiece& key,
uint32_t& newExptime) {
McMetagetRequest reqMetaget(key);
auto warmMeta = rh->route(reqMetaget);
if (isHitResult(*warmMeta.result_ref())) {
newExptime = *warmMeta.exptime_ref();
if (newExptime != 0) {
auto curTime = time(nullptr);
if (curTime >= newExptime) {
return false;
}
newExptime -= curTime;
}
return true;
}
return false;
}
/**
* This will create a new write request based on the value
* of a Reply or Request object.
*
* @param(key) - the key of the new request
* @param(message) - the message that contains the value
* @param(exptime) - exptime of the new object
*
* @return(ToRequest)
*/
template <class ToRequest, class Message>
static ToRequest createRequestFromMessage(
const folly::StringPiece& key,
const Message& message,
uint32_t exptime) {
ToRequest newReq(key);
folly::IOBuf cloned = carbon::valuePtrUnsafe(message)
? carbon::valuePtrUnsafe(message)->cloneAsValue()
: folly::IOBuf();
newReq.value_ref() = std::move(cloned);
newReq.flags_ref() = *message.flags_ref();
newReq.exptime_ref() = exptime;
return newReq;
}
} // namespace mcrouter
} // namespace memcache
} // namespace facebook
|
facebook/mcrouter
|
mcrouter/routes/RoutingUtils.h
|
C
|
mit
| 2,394
|
use serde::de::DeserializeOwned;
use crate::algorithms::AlgorithmFamily;
use crate::crypto::verify;
use crate::errors::{new_error, ErrorKind, Result};
use crate::header::Header;
#[cfg(feature = "use_pem")]
use crate::pem::decoder::PemEncodedKey;
use crate::serialization::{b64_decode, DecodedJwtPartClaims};
use crate::validation::{validate, Validation};
/// The return type of a successful call to [decode](fn.decode.html).
#[derive(Debug)]
pub struct TokenData<T> {
/// The decoded JWT header
pub header: Header,
/// The decoded JWT claims
pub claims: T,
}
/// Takes the result of a rsplit and ensure we only get 2 parts
/// Errors if we don't
macro_rules! expect_two {
($iter:expr) => {{
let mut i = $iter;
match (i.next(), i.next(), i.next()) {
(Some(first), Some(second), None) => (first, second),
_ => return Err(new_error(ErrorKind::InvalidToken)),
}
}};
}
#[derive(Clone)]
pub(crate) enum DecodingKeyKind {
SecretOrDer(Vec<u8>),
RsaModulusExponent { n: Vec<u8>, e: Vec<u8> },
}
/// All the different kind of keys we can use to decode a JWT
/// This key can be re-used so make sure you only initialize it once if you can for better performance
#[derive(Clone)]
pub struct DecodingKey {
pub(crate) family: AlgorithmFamily,
pub(crate) kind: DecodingKeyKind,
}
impl DecodingKey {
/// If you're using HMAC, use this.
pub fn from_secret(secret: &[u8]) -> Self {
DecodingKey {
family: AlgorithmFamily::Hmac,
kind: DecodingKeyKind::SecretOrDer(secret.to_vec()),
}
}
/// If you're using HMAC with a base64 encoded secret, use this.
pub fn from_base64_secret(secret: &str) -> Result<Self> {
let out = base64::decode(&secret)?;
Ok(DecodingKey { family: AlgorithmFamily::Hmac, kind: DecodingKeyKind::SecretOrDer(out) })
}
/// If you are loading a public RSA key in a PEM format, use this.
/// Only exists if the feature `use_pem` is enabled.
#[cfg(feature = "use_pem")]
pub fn from_rsa_pem(key: &[u8]) -> Result<Self> {
let pem_key = PemEncodedKey::new(key)?;
let content = pem_key.as_rsa_key()?;
Ok(DecodingKey {
family: AlgorithmFamily::Rsa,
kind: DecodingKeyKind::SecretOrDer(content.to_vec()),
})
}
/// If you have (n, e) RSA public key components as strings, use this.
pub fn from_rsa_components(modulus: &str, exponent: &str) -> Result<Self> {
let n = b64_decode(modulus)?;
let e = b64_decode(exponent)?;
Ok(DecodingKey {
family: AlgorithmFamily::Rsa,
kind: DecodingKeyKind::RsaModulusExponent { n, e },
})
}
/// If you have (n, e) RSA public key components already decoded, use this.
pub fn from_rsa_raw_components(modulus: &[u8], exponent: &[u8]) -> Self {
DecodingKey {
family: AlgorithmFamily::Rsa,
kind: DecodingKeyKind::RsaModulusExponent { n: modulus.to_vec(), e: exponent.to_vec() },
}
}
/// If you have a ECDSA public key in PEM format, use this.
/// Only exists if the feature `use_pem` is enabled.
#[cfg(feature = "use_pem")]
pub fn from_ec_pem(key: &[u8]) -> Result<Self> {
let pem_key = PemEncodedKey::new(key)?;
let content = pem_key.as_ec_public_key()?;
Ok(DecodingKey {
family: AlgorithmFamily::Ec,
kind: DecodingKeyKind::SecretOrDer(content.to_vec()),
})
}
/// If you have a EdDSA public key in PEM format, use this.
/// Only exists if the feature `use_pem` is enabled.
#[cfg(feature = "use_pem")]
pub fn from_ed_pem(key: &[u8]) -> Result<Self> {
let pem_key = PemEncodedKey::new(key)?;
let content = pem_key.as_ed_public_key()?;
Ok(DecodingKey {
family: AlgorithmFamily::Ed,
kind: DecodingKeyKind::SecretOrDer(content.to_vec()),
})
}
/// If you know what you're doing and have a RSA DER encoded public key, use this.
pub fn from_rsa_der(der: &[u8]) -> Self {
DecodingKey {
family: AlgorithmFamily::Rsa,
kind: DecodingKeyKind::SecretOrDer(der.to_vec()),
}
}
/// If you know what you're doing and have a RSA EC encoded public key, use this.
pub fn from_ec_der(der: &[u8]) -> Self {
DecodingKey {
family: AlgorithmFamily::Ec,
kind: DecodingKeyKind::SecretOrDer(der.to_vec()),
}
}
/// If you know what you're doing and have a Ed DER encoded public key, use this.
pub fn from_ed_der(der: &[u8]) -> Self {
DecodingKey {
family: AlgorithmFamily::Ed,
kind: DecodingKeyKind::SecretOrDer(der.to_vec()),
}
}
pub(crate) fn as_bytes(&self) -> &[u8] {
match &self.kind {
DecodingKeyKind::SecretOrDer(b) => b,
DecodingKeyKind::RsaModulusExponent { .. } => unreachable!(),
}
}
}
/// Verify signature of a JWT, and return header object and raw payload
///
/// If the token or its signature is invalid, it will return an error.
fn verify_signature<'a>(
token: &'a str,
key: &DecodingKey,
validation: &Validation,
) -> Result<(Header, &'a str)> {
if validation.validate_signature && validation.algorithms.is_empty() {
return Err(new_error(ErrorKind::MissingAlgorithm));
}
if validation.validate_signature {
for alg in &validation.algorithms {
if key.family != alg.family() {
return Err(new_error(ErrorKind::InvalidAlgorithm));
}
}
}
let (signature, message) = expect_two!(token.rsplitn(2, '.'));
let (payload, header) = expect_two!(message.rsplitn(2, '.'));
let header = Header::from_encoded(header)?;
if validation.validate_signature && !validation.algorithms.contains(&header.alg) {
return Err(new_error(ErrorKind::InvalidAlgorithm));
}
if validation.validate_signature && !verify(signature, message.as_bytes(), key, header.alg)? {
return Err(new_error(ErrorKind::InvalidSignature));
}
Ok((header, payload))
}
/// Decode and validate a JWT
///
/// If the token or its signature is invalid or the claims fail validation, it will return an error.
///
/// ```rust
/// use serde::{Deserialize, Serialize};
/// use jsonwebtoken::{decode, DecodingKey, Validation, Algorithm};
///
/// #[derive(Debug, Serialize, Deserialize)]
/// struct Claims {
/// sub: String,
/// company: String
/// }
///
/// let token = "a.jwt.token".to_string();
/// // Claims is a struct that implements Deserialize
/// let token_message = decode::<Claims>(&token, &DecodingKey::from_secret("secret".as_ref()), &Validation::new(Algorithm::HS256));
/// ```
pub fn decode<T: DeserializeOwned>(
token: &str,
key: &DecodingKey,
validation: &Validation,
) -> Result<TokenData<T>> {
match verify_signature(token, key, validation) {
Err(e) => Err(e),
Ok((header, claims)) => {
let decoded_claims = DecodedJwtPartClaims::from_jwt_part_claims(claims)?;
let claims = decoded_claims.deserialize()?;
validate(decoded_claims.deserialize()?, validation)?;
Ok(TokenData { header, claims })
}
}
}
/// Decode a JWT without any signature verification/validations and return its [Header](struct.Header.html).
///
/// If the token has an invalid format (ie 3 parts separated by a `.`), it will return an error.
///
/// ```rust
/// use jsonwebtoken::decode_header;
///
/// let token = "a.jwt.token".to_string();
/// let header = decode_header(&token);
/// ```
pub fn decode_header(token: &str) -> Result<Header> {
let (_, message) = expect_two!(token.rsplitn(2, '.'));
let (_, header) = expect_two!(message.rsplitn(2, '.'));
Header::from_encoded(header)
}
|
Keats/jsonwebtoken
|
src/decoding.rs
|
Rust
|
mit
| 7,899
|
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Numerics;
namespace _03.Endurance_Rally
{
class Program
{
static void Main(string[] args)
{
var driversNames = Console.ReadLine().Split(' ').ToArray();
var zones = Console.ReadLine().Split(' ').Select(double.Parse).ToArray();
var checkpointsIndex = Console.ReadLine().Split(' ').Select(int.Parse).ToArray();
foreach (var driver in driversNames)
{
double currentFuel = (int)driver[0];
var isFinish = false;
for (int i = 0; i < zones.Length; i++)
{
if (checkpointsIndex.Contains(i))
{
currentFuel += zones[i];
}
else
{
currentFuel -= zones[i];
}
if (currentFuel <= 0)
{
var reachedIndex = i;
Console.WriteLine("{0} - reached {1}", driver, reachedIndex);
isFinish = true;
break;
}
}
if (!isFinish)
{
Console.WriteLine("{0} - fuel left {1:F2}", driver, currentFuel);
}
}
}
}
}
|
AneliaDoychinova/Programming-Fundamentals
|
13. Exam Preparation/Exam Preparation 1/03. Endurance Rally/03. Endurance Rally.cs
|
C#
|
mit
| 1,492
|
<div class="content-wrap">
<aside>
<h4><a href="#">Resume Coming Soon</a></h4>
<p>Bacon ipsum dolor amet pork chop ground round ham sirloin. Cupim strip steak beef ribs kielbasa pork short loin pork loin bresaola shoulder jowl chicken leberkas porchetta prosciutto. Picanha t-bone ground round capicola tail, pork prosciutto pork loin tri-tip. Ground round biltong pork chop capicola. Pork filet mignon strip steak, pastrami drumstick shankle alcatra.</p>
</aside>
<section class="white-box-2">
<h2>Dev Bootcamp</h2>
<p><em>Feb 2015 - May 2015</em><br>
Learning programming and web development.</p>
</section>
<section class="white-box-2">
<h2>Universities Attended</h2>
<h4><a href="http://www.upenn.edu/">Penn</a></h4>
<p><em>Sept 2009 - Dec 2010</em><br>
Master of Science, Engineering</p>
<hr>
<h4><a href="http://www.columbia.edu/">Columbia</a></h4>
<p><em>Sep 2003 - Jun 2007</em><br>
Bachelor of Science, Applied Math</p>
</section>
<section class="white-box-2">
<h2>Developer Skills</h2>
<p>HTML/CSS, JavaScript, jQuery, AngularJS, ReactJS, Ruby, SQL, Git, <em>more to come...</em></p>
</section>
</div>
|
derekztang/derekztang.github.io
|
partials/education.html
|
HTML
|
mit
| 1,190
|
# frozen_string_literal: true
require "test_helper"
require "zen_wallet/hd/account"
require "zen_wallet/insight/client"
module ZenWallet
module HD
class AccountsTest < Minitest::Test
def test_fetch_history
account = Account.new(nil, id: "id", order: 0, private_key: "pк",
public_key: "pub", address: "0")
Insight::Client.any_instance.expects(:tx_history_all)
.with("0")
.returns([{ tx: 0 }])
assert_equal [{ tx: 0 }], account.fetch_tx_history
end
def test_spend
end
end
end
end
|
zenhome/zen_wallet
|
test/zen_wallet/hd/account_test.rb
|
Ruby
|
mit
| 621
|
xst -intstyle ise -ifn "C:/dropbox/GadgetFactory/GadgetFactory_Engineering/Papilio-Schematic-Library/Papilio_Schematic_Projects/Template_Wishbone_Example/500K/Papilio_One_500K.xst" -ofn "C:/dropbox/GadgetFactory/GadgetFactory_Engineering/Papilio-Schematic-Library/Papilio_Schematic_Projects/Template_Wishbone_Example/500K/Papilio_One_500K.syr"
ngdbuild -intstyle ise -dd _ngo -aul -nt timestamp -uc C:/dropbox/GadgetFactory/GadgetFactory_Engineering/Papilio-Schematic-Library/Libraries/ZPUino_1/board_Papilio_One_500k/papilio_one.ucf -p xc3s500e-vq100-5 Papilio_One_500K.ngc Papilio_One_500K.ngd
map -intstyle ise -p xc3s500e-vq100-5 -cm area -ir off -pr off -c 100 -o Papilio_One_500K_map.ncd Papilio_One_500K.ngd Papilio_One_500K.pcf
par -w -intstyle ise -ol high -t 1 Papilio_One_500K_map.ncd Papilio_One_500K.ncd Papilio_One_500K.pcf
trce -intstyle ise -v 3 -s 5 -n 3 -fastpaths -xml Papilio_One_500K.twx Papilio_One_500K.ncd -o Papilio_One_500K.twr Papilio_One_500K.pcf
bitgen -intstyle ise -f Papilio_One_500K.ut Papilio_One_500K.ncd
|
chcbaram/FPGA
|
zap-2.3.0-windows/papilio-zap-ide/examples/00.Papilio_Schematic_Library/examples/Template_Wishbone_Example/500K/Papilio_One_500K.cmd
|
Batchfile
|
mit
| 1,047
|
using System;
using System.Diagnostics;
using System.Linq;
using System.Net;
using System.Net.Sockets;
using System.Text;
using System.Threading.Tasks;
using Pdelvo.Async.Extensions;
using Pdelvo.Minecraft.Network;
using Pdelvo.Minecraft.Protocol;
using Pdelvo.Minecraft.Protocol.Helper;
using Pdelvo.Minecraft.Protocol.Packets;
using Pdelvo.Minecraft.Proxy.Library.Plugins.Events;
using log4net;
namespace Pdelvo.Minecraft.Proxy.Library.Connection
{
/// <summary>
/// The basic implementation of the IProxyConnection interface
/// </summary>
public class ProxyConnection : IProxyConnection
{
private readonly ILog _logger;
private readonly Socket _networkSocket;
private readonly Random _random;
private readonly ProxyServer _server;
private ProxyEndPoint _clientEndPoint;
private bool _connectionClosed;
private bool _isMotDRequest;
private bool _quitMessagePosted;
private ProxyEndPoint _serverEndPoint;
/// <summary>
/// Creates a new instance of the ProxyConnection class with the remote socket of the client
/// and the ProxyServer this connection should belong to.
/// </summary>
/// <param name="networkSocket"> The network socket of the network client </param>
/// <param name="server"> The proxy server this connection belongs to </param>
public ProxyConnection(Socket networkSocket, ProxyServer server)
{
_logger = LogManager.GetLogger("Proxy Connection");
_networkSocket = networkSocket;
_server = server;
_random = new Random ();
}
#region IProxyConnection Members
/// <summary>
/// Get the username of the current user
/// </summary>
public string Username { get; protected set; }
/// <summary>
/// Get the Hostname and port the user used to connect to the server
/// </summary>
public string Host { get; protected set; }
/// <summary>
/// Get the current entity id of the user
/// </summary>
public int EntityID { get; protected set; }
/// <summary>
/// Asynchronously close this connection
/// </summary>
/// <returns> A task representating the closing process </returns>
public async Task CloseAsync()
{
await KickUserAsync("Proxy connection shutdown");
if (_serverEndPoint != null)
{
_serverEndPoint.Close ();
_serverEndPoint = null;
}
}
/// <summary>
/// Cleans all resources of this connection
/// </summary>
public async void Dispose()
{
await CloseAsync ();
}
/// <summary>
/// Asynchronously initialize the server side of this connection
/// </summary>
/// <param name="serverEndPoint"> Information of the new server this connection should connect to. </param>
/// <returns> A task which returns the LogOnPacket or DisconnectPacket of the established connection. </returns>
public async Task<Packet> InitializeServerAsync(RemoteServerInfo serverEndPoint)
{
ProxyEndPoint server = null;
try
{
UnregisterServer ();
_serverEndPoint = null;
if (!string.IsNullOrEmpty(serverEndPoint.KickMessage))
{
await KickUserAsync(serverEndPoint.KickMessage);
throw new OperationCanceledException("User got kicked.");
}
if (serverEndPoint.MinecraftVersion == 0)
_server.GetServerVersion(this, serverEndPoint);
if (serverEndPoint.MinecraftVersion == null)
{
var information =await MinecraftPinger.GetServerInformationAsync(serverEndPoint.EndPoint);
if((serverEndPoint.MinecraftVersion = information.ProtocolVersion) == null)
throw new InvalidOperationException("Could not auto detect server version");
}
var socket = new Socket(serverEndPoint.EndPoint.AddressFamily, SocketType.Stream, ProtocolType.Tcp)
{
ReceiveBufferSize = 1024*1024
};
await socket.ConnectTaskAsync(serverEndPoint.EndPoint);
server =
new ProxyEndPoint(
ServerRemoteInterface.Create(new NetworkStream(socket), (int)serverEndPoint.MinecraftVersion),
(int)serverEndPoint.MinecraftVersion);
server.RemoteEndPoint = (IPEndPoint) socket.RemoteEndPoint;
var handshakeRequest = new HandshakeRequest
{
UserName = Username,
Host = Host,
ProtocolVersion = (byte) serverEndPoint.MinecraftVersion
};
await server.SendPacketAsync(handshakeRequest);
Packet tp = await server.ReceivePacketAsync ();
if (tp is DisconnectPacket)
{
throw new OperationCanceledException((tp as DisconnectPacket).Reason);
}
var encryptionKeyRequest = tp as EncryptionKeyRequest;
server.ConnectionKey = ProtocolSecurity.GenerateAes128Key ();
byte[] key = ProtocolSecurity.RsaEncrypt(server.ConnectionKey, encryptionKeyRequest.PublicKey.ToArray (),
false);
byte[] verifyToken = ProtocolSecurity.RsaEncrypt(encryptionKeyRequest.VerifyToken.ToArray (),
encryptionKeyRequest.PublicKey.ToArray (), false);
var encryptionKeyResponse = new EncryptionKeyResponse
{
SharedKey = key,
VerifyToken = verifyToken
};
await server.SendPacketAsync(encryptionKeyResponse);
Packet p = await server.ReceivePacketAsync ();
server.EnableAes ();
await server.SendPacketAsync(new RespawnRequestPacket ());
return await server.ReceivePacketAsync ();
}
catch (Exception ex)
{
_quitMessagePosted = true;
_logger.Error("Could not connect to remote server", ex);
throw;
}
finally
{
_serverEndPoint = server;
}
}
/// <summary>
/// Start waiting for server packets
/// </summary>
public void StartServerListening()
{
ServerEndPoint.ConnectionLost += ServerConnectionLost;
ServerEndPoint.PacketReceived += ServerPacketReceived;
ServerEndPoint.StartListening ();
}
/// <summary>
/// Start waiting for client packets
/// </summary>
public void StartClientListening()
{
ClientEndPoint.ConnectionLost += ClientConnectionLost;
ClientEndPoint.PacketReceived += ClientPacketReceived;
ClientEndPoint.StartListening ();
}
/// <summary>
/// Asyncronously kicking a client
/// </summary>
/// <param name="message"> The kick message </param>
/// <returns> A task representing the asynchronous operation </returns>
public async Task KickUserAsync(string message)
{
try
{
await ClientEndPoint.SendPacketAsync(new DisconnectPacket {Reason = message});
if (!_quitMessagePosted && !_isMotDRequest)
{
_logger.Info(Username + " lost connection, message: " + message);
_quitMessagePosted = true;
}
ClientEndPoint.Close ();
if (ServerEndPoint != null)
{
ServerEndPoint.Close ();
}
}
catch (Exception)
{
}
finally
{
_server.RemoveConnection(this);
}
}
/// <summary>
/// Get the current server end point
/// </summary>
public IProxyEndPoint ServerEndPoint
{
get { return _serverEndPoint; }
}
/// <summary>
/// Get the current client end point
/// </summary>
public IProxyEndPoint ClientEndPoint
{
get { return _clientEndPoint; }
}
#endregion
internal virtual async void HandleClient()
{
string kickMessage = "Failed to login";
bool success = true;
try
{
ClientRemoteInterface clientRemoteInterface =
ClientRemoteInterface.Create(new NetworkStream(_networkSocket), 60);
_clientEndPoint = new ProxyEndPoint(clientRemoteInterface, clientRemoteInterface.EndPoint.Version);
_clientEndPoint.RemoteEndPoint = (IPEndPoint) _networkSocket.RemoteEndPoint;
Packet packet = await clientRemoteInterface.ReadPacketAsync ();
var listPing = packet as PlayerListPing;
var handshakeRequest = packet as HandshakeRequest;
if (listPing != null) // send motd
{
_isMotDRequest = true;
if (listPing.MagicByte == 1)
{
//Plugin Message begins @ 1.6
AdditionalServerListInformation additionalInformation = null;
try
{
clientRemoteInterface.EndPoint.Stream.ReadTimeout = 1;
}
catch (InvalidOperationException)
{
}
try
{
additionalInformation =
await clientRemoteInterface.ReadAdditionalServerListInformationAsync();
}
catch (TimeoutException timeOut)
{
}
additionalInformation = additionalInformation ?? new AdditionalServerListInformation
{
Host = _server.LocalEndPoint.Address.ToString(),
Port = _server.LocalEndPoint.Port,
ProtocolVersion = (byte) _server.PublicMinecraftVersion
};
additionalInformation.ProtocolVersion = ProtocolInformation.MaxSupportedClientVersion <
additionalInformation.ProtocolVersion
? (byte) ProtocolInformation.MaxSupportedClientVersion
: additionalInformation.ProtocolVersion;
additionalInformation.ProtocolVersion = ProtocolInformation.MinSupportedClientVersion >
additionalInformation.ProtocolVersion
? (byte) ProtocolInformation.MinSupportedClientVersion
: additionalInformation.ProtocolVersion;
string response = ProtocolHelper.BuildMotDString(additionalInformation.ProtocolVersion,
_server.ServerVersionName, _server.MotD,
_server.ConnectedUsers, _server.MaxUsers);
await KickUserAsync(response);
}
else
{
string response = ProtocolHelper.BuildMotDString(_server.MotD, _server.ConnectedUsers,
_server.MaxUsers);
await KickUserAsync(response);
}
return;
}
if (handshakeRequest != null)
{
Username = handshakeRequest.UserName;
Host = handshakeRequest.Host;
ClientEndPoint.ProtocolVersion = handshakeRequest.ProtocolVersion;
if (handshakeRequest.ProtocolVersion < ProtocolInformation.MinSupportedClientVersion)
{
await KickUserAsync("Outdated Client");
return;
}
else if (handshakeRequest.ProtocolVersion > ProtocolInformation.MaxSupportedClientVersion)
{
await KickUserAsync("Outdated Server");
return;
}
var args = new UserEventArgs(this);
_server.PluginManager.TriggerPlugin.OnPlayerConnected(args);
if (args.Canceled)
{
await ClientEndPoint.SendPacketAsync(new DisconnectPacket {Reason = args.CancelMessage});
_networkSocket.Close ();
_server.RemoveConnection(this);
return;
}
bool onlineMode = _server.OnlineModeEnabled(this);
string serverId = onlineMode ? Session.GetSessionHash () : "-";
var randomBuffer = new byte[4];
_random.NextBytes(randomBuffer);
await ClientEndPoint.SendPacketAsync(new EncryptionKeyRequest
{
ServerId = serverId,
PublicKey =
AsnKeyBuilder.PublicKeyToX509(_server.RSAKeyPair).
GetBytes (),
VerifyToken = randomBuffer
});
do
{
packet = await ClientEndPoint.ReceivePacketAsync ();
} while (packet is KeepAlive);
var encryptionKeyResponse = (EncryptionKeyResponse) packet;
byte[] verification = ProtocolSecurity.RsaDecrypt(
encryptionKeyResponse.VerifyToken.ToArray (), _server.RSACryptoServiceProvider, true);
byte[] sharedKey = ProtocolSecurity.RsaDecrypt(
encryptionKeyResponse.SharedKey.ToArray (), _server.RSACryptoServiceProvider, true);
if (verification.Length != randomBuffer.Length
|| !verification.Zip(randomBuffer, (a, b) => a == b).All(a => a))
{
await KickUserAsync("Verify token failure");
_logger.Error("Failed to login a Client, Verify token failure");
return;
}
await ClientEndPoint.SendPacketAsync(new EncryptionKeyResponse {SharedKey = new byte[0]});
ClientEndPoint.ConnectionKey = sharedKey;
ClientEndPoint.EnableAes (); //now everything is encrypted
Packet p = await ClientEndPoint.ReceivePacketAsync ();
if (!(p is RespawnRequestPacket))
{
await KickUserAsync("Protocol failure");
_logger.Error("Failed to login a Client, Protocol failure");
return;
}
string hash = ProtocolSecurity.ComputeHash(
Encoding.ASCII.GetBytes(serverId),
ClientEndPoint.ConnectionKey,
AsnKeyBuilder.PublicKeyToX509(_server.RSAKeyPair).GetBytes ());
if (onlineMode)
{
bool result;
try
{
result = await _server.CheckUserAccountAsync(this, hash);
}
catch (OperationCanceledException ex)
{
Task t = KickUserAsync(ex.Message);
return;
}
if (!result)
{
await KickUserAsync("User not premium");
return;
}
}
_logger.InfoFormat("{0}[{1}] is connected", Username, _networkSocket.RemoteEndPoint);
_server.PromoteConnection(this);
Packet response = await InitializeServerAsync ();
var logonResponse = response as LogOnResponse;
if (logonResponse != null)
{
EntityID = logonResponse.EntityId;
}
await ClientEndPoint.SendPacketAsync(response);
StartClientListening ();
StartServerListening ();
args = new UserEventArgs(this);
_server.PluginManager.TriggerPlugin.OnUserConnectedCompleted(args);
args.EnsureSuccess ();
}
}
catch (TaskCanceledException)
{
return;
}
catch (OperationCanceledException ex)
{
kickMessage = ex.Message;
success = false;
_quitMessagePosted = true;
_logger.Error(string.Format("Client login aborted ({0})", Username), ex);
}
catch (Exception ex)
{
success = false;
_quitMessagePosted = true;
if (!string.IsNullOrEmpty(Username))
_logger.Error(string.Format("Failed to login a client ({0})", Username), ex);
}
if (!success)
await KickUserAsync(kickMessage);
}
private async Task<Packet> InitializeServerAsync()
{
bool success = true;
RemoteServerInfo info = null;
try
{
info = _server.GetServerEndPoint(this);
}
catch (Exception ex)
{
_quitMessagePosted = true;
_logger.Error("Could not get remote server info", ex);
success = false;
}
if (success)
{
try
{
return await InitializeServerAsync(info);
}
catch (Exception ex)
{
_quitMessagePosted = true;
_logger.Error(string.Format("Could not connect to remote server ({0})", info.EndPoint), ex);
success = false;
}
}
if (!success)
await KickUserAsync("Could not connect to remote server");
throw new TaskCanceledException ();
}
private void ClientConnectionLost(object sender, EventArgs e)
{
OnConnectionLost ();
}
private void OnConnectionLost()
{
if (_connectionClosed) return;
_connectionClosed = true;
ServerEndPoint.Close ();
ClientEndPoint.Close ();
if (!_quitMessagePosted)
{
_logger.Info(Username + " lost connection");
_quitMessagePosted = true;
}
_server.RemoveConnection(this);
}
private void ServerConnectionLost(object sender, EventArgs e)
{
OnConnectionLost ();
}
private async void ClientPacketReceived(object sender, PacketReceivedEventArgs args)
{
Trace.WriteLine("C->S: " + args.Packet);
if (ServerEndPoint == null) return;
string kickMessage = null;
try
{
args.Connection = this;
_server.PluginManager.ApplyClientPacket(args);
if (!args.Handled)
ServerEndPoint.SendPacketQueued(args.Packet);
}
catch (OperationCanceledException ex)
{
kickMessage = ex.Message;
}
if (kickMessage != null)
await KickUserAsync(kickMessage);
}
private async void ServerPacketReceived(object sender, PacketReceivedEventArgs args)
{
Trace.WriteLine("S->C: " + args.Packet);
if (args.Packet is ChatPacket) return;
string kickMessage = null;
try
{
args.Connection = this;
_server.PluginManager.ApplyServerPacket(args);
if (!args.Handled)
ClientEndPoint.SendPacketQueued(args.Packet);
}
catch (OperationCanceledException ex)
{
kickMessage = ex.Message;
}
if (kickMessage != null)
await KickUserAsync(kickMessage);
}
private void UnregisterServer()
{
if (ServerEndPoint != null)
{
ServerEndPoint.PacketReceived -= ServerPacketReceived;
ServerEndPoint.ConnectionLost -= ServerConnectionLost;
ServerEndPoint.Close ();
_serverEndPoint = null;
}
}
}
}
|
pdelvo/Pdelvo.Minecraft.Proxy
|
Pdelvo.Minecraft.Proxy/Pdelvo.Minecraft.Proxy.Library/Connection/ProxyConnection.cs
|
C#
|
mit
| 22,467
|
System fonts bug demo
---
This sample project demonstrates and issue affecting iOS 8.2 and newer: when attempting to use `-[UIFont fontWithSize:]` method on a system font object returned from `+[UIFont systemFontOfSize:weight:]`, the returned font will have a different font name (and thus, weight) than the original font. This issue does not affect fonts with `UIFontWeightRegular` and `UIFontWeightMedium` weights and fonts returned from other system font static methods.
This project also demonstrates a workaround for this issue: instead of using `-[UIFont fontWithSize:]`, one can do something like this:
```
UIFont *newFont = [UIFont fontWithDescriptor:font.fontDescriptor size:newSize];
```
where `font` is the original font object and `newSize` is the required new font size. This technique seems to return correct new fonts regardless of where the original font originates from.
Details can be found in [rdar://22007646](http://www.openradar.me/radar?id=5708224070156288).
|
vlas-voloshin/SystemFontsBugDemo
|
README.md
|
Markdown
|
mit
| 986
|
<html><head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
</head><body>Time,TemperatureF,DewpointF,PressureIn,WindDirection,WindDirectionDegrees,WindSpeedMPH,WindSpeedGustMPH,Humidity,HourlyPrecipIn,Conditions,Clouds,dailyrainin,SoftwareType<br>
2010-04-03 00:02:00,48.2,42.1,30.14,ESE,112,0.0,1.0,79,0.00,,,0.00,meteohub,
<br>
2010-04-03 00:03:00,48.2,42.1,30.14,SE,135,0.0,1.0,79,0.00,,,0.00,meteohub,
<br>
2010-04-03 00:09:00,47.7,41.7,30.14,SE,135,0.0,1.0,80,0.00,,,0.00,meteohub,
<br>
2010-04-03 00:14:00,47.7,41.7,30.14,ESE,112,0.0,1.0,80,0.00,,,0.00,meteohub,
<br>
2010-04-03 00:19:00,47.7,42.1,30.14,ESE,112,0.0,0.0,81,0.00,,,0.00,meteohub,
<br>
2010-04-03 00:25:00,47.7,42.1,30.14,ESE,112,0.0,0.0,81,0.00,,,0.00,meteohub,
<br>
2010-04-03 00:40:00,47.5,42.3,30.12,ESE,112,0.0,1.0,82,0.00,,,0.00,meteohub,
<br>
2010-04-03 00:56:00,47.1,42.3,30.12,ENE,68,0.0,0.0,83,0.00,,,0.00,meteohub,
<br>
2010-04-03 01:01:00,46.8,41.9,30.12,ESE,112,0.0,0.0,83,0.00,,,0.00,meteohub,
<br>
2010-04-03 01:07:00,46.8,41.9,30.12,ESE,112,0.0,0.0,83,0.00,,,0.00,meteohub,
<br>
2010-04-03 01:12:00,46.8,42.3,30.12,ESE,112,0.0,0.0,84,0.00,,,0.00,meteohub,
<br>
2010-04-03 01:17:00,46.8,42.3,30.14,ESE,112,0.0,0.0,84,0.00,,,0.00,meteohub,
<br>
2010-04-03 01:22:00,46.4,41.9,30.14,ESE,112,0.0,0.0,84,0.00,,,0.00,meteohub,
<br>
2010-04-03 01:32:00,46.2,41.9,30.12,ESE,112,0.0,0.0,85,0.00,,,0.00,meteohub,
<br>
2010-04-03 01:37:00,46.2,41.9,30.12,ESE,112,0.0,0.0,85,0.00,,,0.00,meteohub,
<br>
2010-04-03 01:42:00,46.0,41.7,30.12,ESE,112,0.0,0.0,85,0.00,,,0.00,meteohub,
<br>
2010-04-03 01:47:00,46.0,41.7,30.12,ESE,112,0.0,0.0,85,0.00,,,0.00,meteohub,
<br>
2010-04-03 02:02:00,45.5,41.5,30.12,East,90,0.0,0.0,86,0.00,,,0.00,meteohub,
<br>
2010-04-03 02:17:00,45.0,41.4,30.12,East,90,0.0,0.0,87,0.00,,,0.00,meteohub,
<br>
2010-04-03 02:27:00,45.0,41.4,30.12,ESE,112,0.0,0.0,87,0.00,,,0.00,meteohub,
<br>
2010-04-03 02:32:00,45.3,41.7,30.12,ESE,112,0.0,2.0,87,0.00,,,0.00,meteohub,
<br>
2010-04-03 02:37:00,45.1,41.5,30.12,ESE,112,0.0,2.0,87,0.00,,,0.00,meteohub,
<br>
2010-04-03 02:42:00,44.8,41.5,30.12,ESE,112,0.0,2.0,88,0.00,,,0.00,meteohub,
<br>
2010-04-03 02:47:00,44.6,41.4,30.12,ESE,112,0.0,0.0,88,0.00,,,0.00,meteohub,
<br>
2010-04-03 02:57:00,44.6,41.4,30.12,ESE,112,0.0,0.0,88,0.00,,,0.00,meteohub,
<br>
2010-04-03 03:03:00,44.4,41.4,30.14,ESE,112,0.0,0.0,89,0.00,,,0.00,meteohub,
<br>
2010-04-03 03:08:00,44.2,41.2,30.14,ESE,112,0.0,0.0,89,0.00,,,0.00,meteohub,
<br>
2010-04-03 03:14:00,44.4,41.4,30.14,ESE,112,0.0,0.0,89,0.00,,,0.00,meteohub,
<br>
2010-04-03 03:19:00,44.1,41.0,30.12,ESE,112,0.0,0.0,89,0.00,,,0.00,meteohub,
<br>
2010-04-03 03:24:00,44.1,41.4,30.12,ESE,112,0.0,0.0,90,0.00,,,0.00,meteohub,
<br>
2010-04-03 03:29:00,44.1,41.4,30.12,ESE,112,0.0,0.0,90,0.00,,,0.00,meteohub,
<br>
2010-04-03 03:35:00,44.1,41.4,30.12,ESE,112,0.0,0.0,90,0.00,,,0.00,meteohub,
<br>
2010-04-03 03:40:00,44.4,41.7,30.12,ESE,112,0.0,0.0,90,0.00,,,0.00,meteohub,
<br>
2010-04-03 03:45:00,44.4,41.7,30.12,ESE,112,0.0,0.0,90,0.00,,,0.00,meteohub,
<br>
2010-04-03 03:50:00,44.4,41.7,30.12,East,90,0.0,0.0,90,0.00,,,0.00,meteohub,
<br>
2010-04-03 03:55:00,44.2,41.7,30.12,East,90,0.0,1.0,91,0.00,,,0.00,meteohub,
<br>
2010-04-03 04:00:00,44.1,41.5,30.12,East,90,0.0,1.0,91,0.00,,,0.00,meteohub,
<br>
2010-04-03 04:06:00,43.7,41.2,30.12,East,90,0.0,0.0,91,0.00,,,0.00,meteohub,
<br>
2010-04-03 04:11:00,43.3,40.8,30.12,East,90,0.0,0.0,91,0.00,,,0.00,meteohub,
<br>
2010-04-03 04:16:00,43.2,40.6,30.14,East,90,0.0,0.0,91,0.00,,,0.00,meteohub,
<br>
2010-04-03 04:27:00,43.3,40.8,30.14,East,90,0.0,0.0,91,0.00,,,0.00,meteohub,
<br>
2010-04-03 04:37:00,42.8,40.3,30.12,East,90,0.0,0.0,91,0.00,,,0.00,meteohub,
<br>
2010-04-03 04:42:00,42.8,40.6,30.12,East,90,0.0,0.0,92,0.00,,,0.00,meteohub,
<br>
2010-04-03 04:47:00,42.8,40.6,30.12,East,90,0.0,0.0,92,0.00,,,0.00,meteohub,
<br>
2010-04-03 04:52:00,42.6,40.5,30.12,East,90,0.0,0.0,92,0.00,,,0.00,meteohub,
<br>
2010-04-03 04:57:00,43.0,40.8,30.12,East,90,0.0,0.0,92,0.00,,,0.00,meteohub,
<br>
2010-04-03 05:02:00,42.6,40.8,30.12,East,90,0.0,0.0,93,0.00,,,0.00,meteohub,
<br>
2010-04-03 05:07:00,42.8,40.6,30.12,ENE,68,0.0,0.0,92,0.00,,,0.00,meteohub,
<br>
2010-04-03 05:12:00,42.8,41.0,30.12,ENE,68,0.0,0.0,93,0.00,,,0.00,meteohub,
<br>
2010-04-03 05:17:00,42.8,40.6,30.12,ENE,68,0.0,0.0,92,0.00,,,0.00,meteohub,
<br>
2010-04-03 05:19:00,42.8,41.0,30.12,ENE,68,0.0,0.0,93,0.00,,,0.00,meteohub,
<br>
2010-04-03 05:24:00,42.8,41.0,30.12,ESE,112,0.0,0.0,93,0.00,,,0.00,meteohub,
<br>
2010-04-03 05:34:00,42.8,41.0,30.12,ESE,112,0.0,1.0,93,0.00,,,0.00,meteohub,
<br>
2010-04-03 05:39:00,42.4,40.6,30.12,ESE,112,0.0,1.0,93,0.00,,,0.00,meteohub,
<br>
2010-04-03 05:44:00,42.3,40.5,30.12,ESE,112,0.0,0.0,93,0.00,,,0.00,meteohub,
<br>
2010-04-03 05:50:00,42.3,40.6,30.12,ESE,112,0.0,0.0,94,0.00,,,0.00,meteohub,
<br>
2010-04-03 06:05:00,42.1,40.5,30.14,ESE,112,0.0,0.0,94,0.00,,,0.00,meteohub,
<br>
2010-04-03 06:16:00,42.1,40.5,30.12,ESE,112,0.0,0.0,94,0.00,,,0.00,meteohub,
<br>
2010-04-03 06:21:00,41.9,40.3,30.12,ESE,112,0.0,0.0,94,0.00,,,0.00,meteohub,
<br>
2010-04-03 06:27:00,41.9,40.3,30.12,ESE,112,0.0,0.0,94,0.00,,,0.00,meteohub,
<br>
2010-04-03 06:32:00,42.1,40.5,30.09,ESE,112,0.0,0.0,94,0.00,,,0.00,meteohub,
<br>
2010-04-03 06:37:00,41.9,40.3,30.09,ESE,112,0.0,0.0,94,0.00,,,0.00,meteohub,
<br>
2010-04-03 06:42:00,42.1,40.8,30.09,ESE,112,0.0,0.0,95,0.00,,,0.00,meteohub,
<br>
2010-04-03 06:52:00,42.3,41.0,30.12,ESE,112,0.0,0.0,95,0.00,,,0.00,meteohub,
<br>
2010-04-03 06:57:00,42.4,41.2,30.12,ESE,112,0.0,0.0,95,0.00,,,0.00,meteohub,
<br>
2010-04-03 07:07:00,42.8,41.5,30.12,ESE,112,0.0,0.0,95,0.00,,,0.00,meteohub,
<br>
2010-04-03 07:17:00,43.3,42.1,30.12,ESE,112,0.0,0.0,95,0.00,,,0.00,meteohub,
<br>
2010-04-03 07:37:00,48.0,46.4,30.09,East,90,1.0,0.0,94,0.00,,,0.00,meteohub,
<br>
2010-04-03 07:42:00,49.8,47.8,30.09,East,90,0.0,2.0,93,0.00,,,0.00,meteohub,
<br>
2010-04-03 07:52:00,51.1,48.0,30.12,West,270,0.0,2.0,89,0.00,,,0.00,meteohub,
<br>
2010-04-03 07:57:00,51.4,48.4,30.12,SW,225,1.0,2.0,89,0.00,,,0.00,meteohub,
<br>
2010-04-03 08:03:00,53.2,49.8,30.12,SW,225,0.0,2.0,88,0.00,,,0.00,meteohub,
<br>
2010-04-03 08:08:00,54.5,50.0,30.12,SSW,202,3.0,3.0,85,0.00,,,0.00,meteohub,
<br>
2010-04-03 08:18:00,56.3,49.3,30.09,NW,315,4.0,4.0,77,0.00,,,0.00,meteohub,
<br>
2010-04-03 08:23:00,57.0,48.4,30.09,West,270,1.0,4.0,73,0.00,,,0.00,meteohub,
<br>
2010-04-03 08:34:00,58.8,48.4,30.12,SSE,158,2.0,4.0,68,0.00,,,0.00,meteohub,
<br>
2010-04-03 08:39:00,59.5,46.0,30.12,WNW,292,2.0,4.0,61,0.00,,,0.00,meteohub,
<br>
2010-04-03 08:44:00,60.6,46.8,30.12,SW,225,2.0,4.0,60,0.00,,,0.00,meteohub,
<br>
2010-04-03 08:49:00,61.3,46.0,30.12,SE,135,3.0,4.0,57,0.00,,,0.00,meteohub,
<br>
2010-04-03 08:55:00,62.8,46.4,30.12,SE,135,0.0,4.0,55,0.00,,,0.00,meteohub,
<br>
2010-04-03 09:00:00,63.5,45.1,30.12,West,270,1.0,4.0,51,0.00,,,0.00,meteohub,
<br>
2010-04-03 09:05:00,63.9,43.3,30.09,WNW,292,2.0,4.0,47,0.00,,,0.00,meteohub,
<br>
2010-04-03 09:11:00,64.4,42.1,30.09,SSW,202,2.0,6.0,44,0.00,,,0.00,meteohub,
<br>
2010-04-03 09:17:00,65.5,43.5,30.12,SSW,202,1.0,6.0,45,0.00,,,0.00,meteohub,
<br>
2010-04-03 09:27:00,67.5,43.5,30.12,West,270,4.0,4.0,42,0.00,,,0.00,meteohub,
<br>
2010-04-03 09:32:00,67.3,42.1,30.12,West,270,3.0,5.0,40,0.00,,,0.00,meteohub,
<br>
2010-04-03 09:38:00,68.0,41.5,30.12,West,270,2.0,5.0,38,0.00,,,0.00,meteohub,
<br>
2010-04-03 09:43:00,68.9,42.3,30.12,SE,135,3.0,5.0,38,0.00,,,0.00,meteohub,
<br>
2010-04-03 09:48:00,69.6,41.5,30.12,SW,225,2.0,5.0,36,0.00,,,0.00,meteohub,
<br>
2010-04-03 09:53:00,70.0,42.6,30.12,WSW,248,2.0,5.0,37,0.00,,,0.00,meteohub,
<br>
2010-04-03 09:58:00,70.5,41.5,30.12,NNW,338,2.0,5.0,35,0.00,,,0.00,meteohub,
<br>
2010-04-03 10:09:00,71.1,41.4,30.12,WSW,248,2.0,4.0,34,0.00,,,0.00,meteohub,
<br>
2010-04-03 10:14:00,71.6,41.7,30.12,NW,315,2.0,6.0,34,0.00,,,0.00,meteohub,
<br>
2010-04-03 10:19:00,72.1,41.5,30.12,South,180,2.0,6.0,33,0.00,,,0.00,meteohub,
<br>
2010-04-03 10:24:00,72.9,42.1,30.12,WNW,292,2.0,6.0,33,0.00,,,0.00,meteohub,
<br>
2010-04-03 10:30:00,73.6,42.8,30.12,WSW,248,2.0,4.0,33,0.00,,,0.00,meteohub,
<br>
2010-04-03 10:40:00,74.5,42.8,30.09,West,270,2.0,6.0,32,0.00,,,0.00,meteohub,
<br>
2010-04-03 10:45:00,74.5,42.8,30.09,ESE,112,4.0,6.0,32,0.00,,,0.00,meteohub,
<br>
2010-04-03 10:50:00,75.2,42.4,30.09,SSW,202,2.0,6.0,31,0.00,,,0.00,meteohub,
<br>
2010-04-03 11:01:00,76.6,43.7,30.09,WNW,292,2.0,6.0,31,0.00,,,0.00,meteohub,
<br>
2010-04-03 11:06:00,76.8,43.9,30.09,WNW,292,2.0,6.0,31,0.00,,,0.00,meteohub,
<br>
2010-04-03 11:17:00,77.9,44.1,30.09,NW,315,2.0,7.0,30,0.00,,,0.00,meteohub,
<br>
2010-04-03 11:22:00,77.5,43.7,30.09,WSW,248,3.0,7.0,30,0.00,,,0.00,meteohub,
<br>
2010-04-03 11:37:00,78.4,43.5,30.06,SSW,202,2.0,8.0,29,0.00,,,0.00,meteohub,
<br>
2010-04-03 11:42:00,78.8,42.1,30.06,SSE,158,3.0,6.0,27,0.00,,,0.00,meteohub,
<br>
2010-04-03 11:47:00,78.6,41.9,30.03,WSW,248,2.0,8.0,27,0.00,,,0.00,meteohub,
<br>
2010-04-03 11:52:00,79.0,41.2,30.03,WSW,248,4.0,8.0,26,0.00,,,0.00,meteohub,
<br>
2010-04-03 11:58:00,79.9,43.0,30.03,WSW,248,3.0,8.0,27,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:03:00,79.9,41.9,30.06,SW,225,2.0,8.0,26,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:08:00,79.7,40.8,30.06,West,270,5.0,8.0,25,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:13:00,81.7,43.5,30.06,WSW,248,2.0,8.0,26,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:18:00,81.1,42.1,30.06,NW,315,2.0,6.0,25,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:23:00,81.5,42.3,30.06,East,90,1.0,9.0,25,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:29:00,81.7,42.4,30.06,SW,225,6.0,9.0,25,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:31:00,81.7,42.4,30.03,SSE,158,2.0,6.0,25,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:36:00,81.7,41.4,30.03,SSE,158,4.0,6.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:41:00,81.5,41.2,30.03,WNW,292,4.0,6.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:47:00,81.3,41.2,30.06,SW,225,3.0,7.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:52:00,81.0,39.7,30.06,SSE,158,5.0,7.0,23,0.00,,,0.00,meteohub,
<br>
2010-04-03 12:57:00,81.3,41.2,30.06,South,180,4.0,6.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 13:02:00,81.3,41.2,30.06,WSW,248,3.0,6.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 13:07:00,80.4,40.3,30.06,WSW,248,6.0,9.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 13:12:00,81.1,41.0,30.06,WSW,248,3.0,9.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 13:17:00,80.4,40.3,30.06,West,270,7.0,9.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 13:22:00,80.4,40.3,30.06,WSW,248,3.0,9.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 13:27:00,81.3,41.2,30.06,WNW,292,4.0,7.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 13:42:00,81.5,40.1,30.06,WSW,248,4.0,6.0,23,0.00,,,0.00,meteohub,
<br>
2010-04-03 13:48:00,80.6,39.4,30.03,WNW,292,3.0,6.0,23,0.00,,,0.00,meteohub,
<br>
2010-04-03 13:53:00,81.3,40.1,30.03,WNW,292,3.0,8.0,23,0.00,,,0.00,meteohub,
<br>
2010-04-03 13:58:00,81.0,39.7,30.03,West,270,2.0,8.0,23,0.00,,,0.00,meteohub,
<br>
2010-04-03 14:03:00,80.8,38.5,30.06,WNW,292,6.0,10.0,22,0.00,,,0.00,meteohub,
<br>
2010-04-03 14:08:00,81.3,40.1,30.06,WSW,248,4.0,10.0,23,0.00,,,0.00,meteohub,
<br>
2010-04-03 14:11:00,81.3,38.8,30.06,West,270,3.0,10.0,22,0.00,,,0.00,meteohub,
<br>
2010-04-03 14:16:00,81.3,38.8,30.03,SE,135,3.0,9.0,22,0.00,,,0.00,meteohub,
<br>
2010-04-03 14:21:00,81.7,39.2,30.03,NW,315,6.0,8.0,22,0.00,,,0.00,meteohub,
<br>
2010-04-03 14:27:00,81.9,39.4,30.03,NW,315,2.0,10.0,22,0.00,,,0.00,meteohub,
<br>
2010-04-03 14:33:00,83.5,40.6,30.03,SSW,202,8.0,10.0,22,0.00,,,0.00,meteohub,
<br>
2010-04-03 14:38:00,83.5,40.6,30.03,South,180,3.0,10.0,22,0.00,,,0.00,meteohub,
<br>
2010-04-03 14:43:00,83.7,39.6,30.03,SW,225,1.0,8.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 14:49:00,84.2,40.1,30.00,NW,315,2.0,8.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 14:59:00,85.1,40.8,30.00,SSE,158,2.0,7.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 15:04:00,84.9,40.6,30.00,WNW,292,4.0,7.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 15:10:00,85.1,40.8,30.00,West,270,4.0,7.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 15:15:00,85.3,41.0,30.00,SSW,202,2.0,7.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 15:20:00,85.5,41.2,30.03,NNE,22,1.0,7.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 15:25:00,85.5,41.2,30.03,SW,225,2.0,7.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 15:36:00,84.7,39.2,30.00,West,270,2.0,9.0,20,0.00,,,0.00,meteohub,
<br>
2010-04-03 15:42:00,85.1,40.8,30.00,SSE,158,3.0,10.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 15:47:00,85.1,39.6,30.00,WSW,248,3.0,10.0,20,0.00,,,0.00,meteohub,
<br>
2010-04-03 15:57:00,85.1,40.8,30.00,West,270,3.0,8.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 16:02:00,85.8,41.4,29.97,SE,135,1.0,8.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 16:07:00,86.2,40.5,29.97,WNW,292,3.0,7.0,20,0.00,,,0.00,meteohub,
<br>
2010-04-03 16:13:00,85.5,41.2,29.97,SW,225,5.0,7.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 16:18:00,84.9,39.4,29.97,SW,225,3.0,10.0,20,0.00,,,0.00,meteohub,
<br>
2010-04-03 16:23:00,84.4,39.0,29.97,SSW,202,4.0,10.0,20,0.00,,,0.00,meteohub,
<br>
2010-04-03 16:28:00,84.6,39.0,29.97,West,270,3.0,10.0,20,0.00,,,0.00,meteohub,
<br>
2010-04-03 16:33:00,84.6,39.0,30.00,NE,45,4.0,8.0,20,0.00,,,0.00,meteohub,
<br>
2010-04-03 16:38:00,84.0,39.9,30.00,NW,315,4.0,10.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 16:43:00,83.8,39.7,30.00,WSW,248,8.0,10.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 17:04:00,82.4,38.7,30.00,SW,225,2.0,6.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 17:20:00,82.6,38.7,30.00,SW,225,3.0,7.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 17:25:00,82.0,38.3,30.00,SW,225,2.0,6.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 17:31:00,81.9,38.1,30.00,WSW,248,1.0,6.0,21,0.00,,,0.00,meteohub,
<br>
2010-04-03 17:36:00,80.6,39.4,30.00,ESE,112,4.0,6.0,23,0.00,,,0.00,meteohub,
<br>
2010-04-03 17:41:00,78.8,37.9,30.00,SE,135,5.0,7.0,23,0.00,,,0.00,meteohub,
<br>
2010-04-03 17:47:00,77.5,37.9,30.00,SSW,202,6.0,8.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 17:52:00,77.0,37.4,30.00,SSE,158,4.0,8.0,24,0.00,,,0.00,meteohub,
<br>
2010-04-03 18:02:00,76.1,38.8,30.00,NW,315,3.0,8.0,26,0.00,,,0.00,meteohub,
<br>
2010-04-03 18:07:00,75.4,38.1,30.00,WNW,292,6.0,8.0,26,0.00,,,0.00,meteohub,
<br>
2010-04-03 18:12:00,74.7,37.6,30.00,ESE,112,7.0,8.0,26,0.00,,,0.00,meteohub,
<br>
2010-04-03 18:17:00,73.8,37.8,30.00,East,90,3.0,8.0,27,0.00,,,0.00,meteohub,
<br>
2010-04-03 18:22:00,73.4,38.3,30.00,SSW,202,4.0,7.0,28,0.00,,,0.00,meteohub,
<br>
2010-04-03 18:32:00,72.1,38.1,30.00,SSE,158,3.0,6.0,29,0.00,,,0.00,meteohub,
<br>
2010-04-03 18:37:00,70.9,37.9,30.00,SSW,202,2.0,6.0,30,0.00,,,0.00,meteohub,
<br>
2010-04-03 18:42:00,69.6,38.5,30.00,ESE,112,2.0,4.0,32,0.00,,,0.00,meteohub,
<br>
2010-04-03 18:47:00,69.1,37.9,30.00,East,90,2.0,5.0,32,0.00,,,0.00,meteohub,
<br>
2010-04-03 18:52:00,68.2,37.2,30.00,SE,135,0.0,5.0,32,0.00,,,0.00,meteohub,
<br>
2010-04-03 18:58:00,67.3,37.2,30.00,SSE,158,1.0,5.0,33,0.00,,,0.00,meteohub,
<br>
2010-04-03 19:03:00,66.4,36.5,30.00,ESE,112,0.0,5.0,33,0.00,,,0.00,meteohub,
<br>
2010-04-03 19:19:00,65.3,37.8,30.00,ENE,68,5.0,5.0,36,0.00,,,0.00,meteohub,
<br>
2010-04-03 19:24:00,65.3,37.8,30.00,SSE,158,2.0,4.0,36,0.00,,,0.00,meteohub,
<br>
2010-04-03 19:29:00,65.1,37.6,30.00,WSW,248,2.0,5.0,36,0.00,,,0.00,meteohub,
<br>
2010-04-03 19:35:00,64.8,37.9,29.97,WNW,292,2.0,5.0,37,0.00,,,0.00,meteohub,
<br>
2010-04-03 19:45:00,63.9,37.8,29.97,SSE,158,1.0,5.0,38,0.00,,,0.00,meteohub,
<br>
2010-04-03 19:50:00,63.5,38.1,29.97,WNW,292,4.0,5.0,39,0.00,,,0.00,meteohub,
<br>
2010-04-03 19:59:00,62.8,37.6,29.97,WSW,248,2.0,5.0,39,0.00,,,0.00,meteohub,
<br>
2010-04-03 20:04:00,62.2,37.6,30.00,SSE,158,0.0,5.0,40,0.00,,,0.00,meteohub,
<br>
2010-04-03 20:20:00,61.7,39.0,30.00,West,270,1.0,3.0,43,0.00,,,0.00,meteohub,
<br>
2010-04-03 20:25:00,61.5,38.8,30.00,West,270,0.0,4.0,43,0.00,,,0.00,meteohub,
<br>
2010-04-03 20:30:00,61.2,38.5,30.00,SW,225,2.0,6.0,43,0.00,,,0.00,meteohub,
<br>
2010-04-03 20:36:00,61.2,39.0,30.00,SSW,202,2.0,6.0,44,0.00,,,0.00,meteohub,
<br>
2010-04-03 20:45:00,61.0,39.0,30.00,WNW,292,2.0,6.0,44,0.00,,,0.00,meteohub,
<br>
2010-04-03 20:51:00,60.8,38.8,30.00,WSW,248,3.0,6.0,44,0.00,,,0.00,meteohub,
<br>
2010-04-03 20:56:00,60.8,38.8,30.00,WSW,248,3.0,6.0,44,0.00,,,0.00,meteohub,
<br>
2010-04-03 21:01:00,60.4,39.0,30.03,West,270,1.0,6.0,45,0.00,,,0.00,meteohub,
<br>
2010-04-03 21:11:00,59.7,38.3,30.03,SSW,202,2.0,6.0,45,0.00,,,0.00,meteohub,
<br>
2010-04-03 21:22:00,59.7,38.3,30.03,SSW,202,2.0,8.0,45,0.00,,,0.00,meteohub,
<br>
2010-04-03 21:27:00,59.4,38.1,30.03,West,270,4.0,8.0,45,0.00,,,0.00,meteohub,
<br>
2010-04-03 21:34:00,58.8,38.1,30.00,WSW,248,3.0,8.0,46,0.00,,,0.00,meteohub,
<br>
2010-04-03 21:40:00,58.6,38.5,30.00,WSW,248,3.0,6.0,47,0.00,,,0.00,meteohub,
<br>
2010-04-03 21:45:00,58.5,38.3,30.00,SSW,202,4.0,5.0,47,0.00,,,0.00,meteohub,
<br>
2010-04-03 21:50:00,58.5,38.8,30.00,NW,315,2.0,7.0,48,0.00,,,0.00,meteohub,
<br>
2010-04-03 21:55:00,58.1,38.5,30.00,WSW,248,3.0,7.0,48,0.00,,,0.00,meteohub,
<br>
2010-04-03 22:11:00,57.6,38.7,30.03,West,270,1.0,6.0,49,0.00,,,0.00,meteohub,
<br>
2010-04-03 22:16:00,57.2,38.8,30.00,WSW,248,1.0,6.0,50,0.00,,,0.00,meteohub,
<br>
2010-04-03 22:21:00,57.0,38.7,30.00,SSW,202,2.0,6.0,50,0.00,,,0.00,meteohub,
<br>
2010-04-03 22:27:00,56.8,39.0,30.00,NW,315,2.0,5.0,51,0.00,,,0.00,meteohub,
<br>
2010-04-03 22:32:00,56.8,39.9,30.03,WSW,248,3.0,6.0,53,0.00,,,0.00,meteohub,
<br>
2010-04-03 22:42:00,56.5,40.5,30.03,SSW,202,2.0,6.0,55,0.00,,,0.00,meteohub,
<br>
2010-04-03 22:47:00,56.3,40.3,30.03,WSW,248,2.0,6.0,55,0.00,,,0.00,meteohub,
<br>
2010-04-03 22:52:00,55.9,40.1,30.03,SSW,202,3.0,6.0,55,0.00,,,0.00,meteohub,
<br>
2010-04-03 22:58:00,55.9,41.4,30.03,SSW,202,3.0,6.0,58,0.00,,,0.00,meteohub,
<br>
2010-04-03 23:08:00,55.6,41.0,30.00,SSW,202,3.0,6.0,58,0.00,,,0.00,meteohub,
<br>
2010-04-03 23:13:00,55.6,41.5,30.00,ENE,68,3.0,6.0,59,0.00,,,0.00,meteohub,
<br>
2010-04-03 23:18:00,55.6,41.9,30.00,WSW,248,2.0,7.0,60,0.00,,,0.00,meteohub,
<br>
2010-04-03 23:24:00,55.4,41.4,30.00,WNW,292,2.0,7.0,59,0.00,,,0.00,meteohub,
<br>
2010-04-03 23:29:00,55.2,42.1,30.00,WSW,248,2.0,7.0,61,0.00,,,0.00,meteohub,
<br>
2010-04-03 23:34:00,55.0,41.9,30.03,WSW,248,3.0,7.0,61,0.00,,,0.00,meteohub,
<br>
2010-04-03 23:39:00,55.0,42.3,30.03,WSW,248,2.0,7.0,62,0.00,,,0.00,meteohub,
<br>
2010-04-03 23:45:00,54.9,42.1,30.03,West,270,2.0,8.0,62,0.00,,,0.00,meteohub,
<br>
2010-04-03 23:50:00,54.9,42.4,30.00,WNW,292,1.0,7.0,63,0.00,,,0.00,meteohub,
<br>
2010-04-03 23:55:00,54.7,42.4,30.00,SSW,202,2.0,5.0,63,0.00,,,0.00,meteohub,
<br>
<!-- 0.275:1 -->
</body></html>
|
arkadyan/Wind-Dance
|
data/winddatafiles/94WXDailyHistory.asp.html
|
HTML
|
mit
| 18,504
|
### [demo地址](https://gitee.com/muzi131313/function_program)
### 函数式编程的缺点
- 不易阅读
- 难于调试
### 优点/解决的问题
- 把数据处理的过程,定义成与参数无关的合成运算
````
// define
var addOne = x => x + 1;
var squre = x => x * x;
// usage
var addResult = addOne(2);
var addSqureResult = squre(addResult);
console.log('addSqureResult: ', addSqureResult);
````
- ramda
````
var addOneThenSquare = R.pipe(addOne, square);
addOneThenSquare(2);
````
### 友情链接
- [Pointfree 编程风格指南](http://www.ruanyifeng.com/blog/2017/03/pointfree.html)
- [Ramda 函数库参考教程](http://www.ruanyifeng.com/blog/2017/03/ramda.html)
|
muzi131313/muzi131313.github.com
|
_posts/2017-11-15-ramda学习.md
|
Markdown
|
mit
| 694
|
<nav class="navbar navbar-expand-lg navbar-light bg-white fixed-top" id="topNavigation">
<span class="navbar-text">
<?= $view->getWebsiteTitle() ?>
</span>
<ul class="navbar-nav navbar-expand ml-auto">
<?php
if (!is_routing('install_*')) {
if ($view->settings()->getLanguages()->count() > 1) {
?>
<li class="nav-item dropdown">
<a href="#" class="nav-link dropdown-toggle" data-toggle="dropdown">
<span class="nav-link-icon">
<?= $view->translator()
->getCurrentLanguage()
->renderFlagIcon() ?>
</span>
</a>
<div class="dropdown-menu">
<?php foreach ($view->settings()->getLanguages() as $language) { ?>
<a class="dropdown-item<?= ($language->code === $view->translator()->getCurrentLanguageCode() ? ' active' : '') ?>"
href="<?= generate_url('', [], $_GET, $language->code) ?>">
<?= $language->renderFlagIcon() ?>
</a>
<?php } ?>
</div>
</li>
<?php
}
if ($view->service('auth')->isAuthenticated()) {
?>
<li class="nav-item">
<a class="nav-link" href="<?= generate_url('backend_profile_index') ?>" title="<?= translate('Profile') ?>">
<span class="nav-link-icon">
<i class="fa fa-fw fa-user"></i>
</span>
<span class="nav-link-text d-none d-md-inline">
<?= translate('Profile') ?>
</span>
</a>
</li>
<?php } ?>
<li class="nav-item">
<a class="nav-link" target="_blank" href="<?= generate_url('frontend_index') ?>" title="<?= translate('To the frontend') ?>">
<span class="nav-link-icon">
<i class="fa fa-fw fa-desktop"></i>
</span>
<span class="nav-link-text d-none d-md-inline">
<?= translate('To the frontend') ?>
</span>
</a>
</li>
<?php if ($view->service('auth')->isAuthenticated()) { ?>
<li class="nav-item">
<a class="nav-link" href="<?= generate_url('backend_auth_logout') ?>" title="<?= translate('Logout') ?>">
<span class="nav-link-text d-none d-md-inline">
<?= translate('Logout') ?>
</span>
<span class="nav-link-icon">
<i class="fa fa-fw fa-sign-out-alt"></i>
</span>
</a>
</li>
<?php
}
}
?>
</ul>
</nav>
|
Neoflow/Neoflow-CMS
|
themes/everest-backend/templates/navigation/top.php
|
PHP
|
mit
| 3,167
|
#if C_GRAPHICSMEDIA_LAB_DMOROZ_C
#/*******************************************************************************
# * (C) Copyright 2003/2004 by Vladimir Vezhnevets <vvp@graphics.cs.msu.su> *
# *******************************************************************************/
#endif
// MFC_GML3View.cpp : implementation of the CImageView class
//
#include "stdafx.h"
#include "MFC_GML3.h"
#include "MFC_GML3Doc.h"
#include "MFC_GML3View.h"
#include "Processing.h"
#include "FloatInput.h"
#include ".\mfc_gml3view.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CImageView
IMPLEMENT_DYNCREATE(CImageView, CView)
BEGIN_MESSAGE_MAP(CImageView, CView)
ON_COMMAND(ID_NOISE_WHITE, OnNoiseWhite)
ON_COMMAND(ID_NOISE_IMPULSE, OnNoiseImpulse)
ON_COMMAND(ID_FILTERS3X3_SHARPEN, OnFilters3x3Sharpen)
ON_COMMAND(ID_FILTERS3X3_BLUR, OnFilters3x3Blur)
ON_COMMAND(ID_FILTERS3X3_FINDEDGES, OnFilters3x3Findedges)
ON_COMMAND(ID_GAUSSIANBLUR_1DVERSION, OnGaussianblur1dversion)
ON_COMMAND(ID_GAUSSIANBLUR_2DVERSION, OnGaussianblur2dversion)
ON_COMMAND(ID_MEDIAN_NORMAL, OnMedianNormal)
ON_COMMAND(ID_MEDIAN_VECTOR, OnMedianVector)
ON_COMMAND(ID_KNN_MANUAL, OnKnnManual)
ON_COMMAND(ID_NLM_MANUAL, OnNlmManual)
ON_COMMAND(ID_KNN_AUTOMATIC, OnKnnAutomatic)
ON_COMMAND(ID_NLM_AUTOMATIC, OnNlmAutomatic)
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CImageView construction/destruction
CImageView::CImageView()
{
// TODO: add construction code here
}
CImageView::~CImageView()
{
}
BOOL CImageView::PreCreateWindow(CREATESTRUCT& cs)
{
// TODO: Modify the Window class or styles here by modifying
// the CREATESTRUCT cs
return CView::PreCreateWindow(cs);
}
/////////////////////////////////////////////////////////////////////////////
// CImageView drawing
void CImageView::OnDraw(CDC* pDC)
{
CImageDoc* pDoc = GetDocument();
ASSERT_VALID(pDoc);
/// Òðåáóåòñÿ îòðèñîâàòü íàøå èçîáðàæåíèå â ïðèñëàííûé device context
pDoc->Paint(pDC->m_hDC);
}
/////////////////////////////////////////////////////////////////////////////
// CImageView diagnostics
#ifdef _DEBUG
void CImageView::AssertValid() const
{
CView::AssertValid();
}
void CImageView::Dump(CDumpContext& dc) const
{
CView::Dump(dc);
}
CImageDoc* CImageView::GetDocument() // non-debug version is inline
{
ASSERT(m_pDocument->IsKindOf(RUNTIME_CLASS(CImageDoc)));
return (CImageDoc*)m_pDocument;
}
#endif //_DEBUG
/////////////////////////////////////////////////////////////////////////////
// CImageView message handlers
unsigned char pcBuf[1024 * 1024];
void CImageView::OnNoiseWhite()
{
CImageDoc* pDoc=GetDocument();
WhiteNoise(&pDoc->m_Image, (int)QueryFloat("Enter Noise Amplitude.\nRecommended Values: 1-300\nExample: 50", 0));
Invalidate();
}
void CImageView::OnNoiseImpulse()
{
CImageDoc* pDoc=GetDocument();
ImpulseNoise(&pDoc->m_Image, (int)QueryFloat("Enter Noise Probability.\nRecommended Values: 1-100\nExample: 20", 0));
Invalidate();
}
void CImageView::OnFilters3x3Sharpen()
{
CImageDoc* pDoc=GetDocument();
Sharpen(&pDoc->m_Image);
Invalidate();
}
void CImageView::OnFilters3x3Blur()
{
CImageDoc* pDoc=GetDocument();
Blur(&pDoc->m_Image);
Invalidate();
}
void CImageView::OnFilters3x3Findedges()
{
CImageDoc* pDoc=GetDocument();
FindEdges(&pDoc->m_Image);
Invalidate();
}
void CImageView::OnGaussianblur1dversion()
{
CImageDoc* pDoc=GetDocument();
GaussianBlur1D(&pDoc->m_Image, QueryFloat("Enter Gaussian Blur Power.\nRecommended Values: 0-50\nExample: 1.5", 0));
Invalidate();
}
void CImageView::OnGaussianblur2dversion()
{
CImageDoc* pDoc=GetDocument();
GaussianBlur2D(&pDoc->m_Image, QueryFloat("Enter Gaussian Blur Power.\nRecommended Values: 0-50\nExample: 1.5", 0));
Invalidate();
}
void CImageView::OnMedianNormal()
{
CImageDoc* pDoc=GetDocument();
MedianNormal(&pDoc->m_Image, (int)QueryFloat("Enter Median Radius.\nRecommended Values: 1-10\nExample: 2", 0));
Invalidate();
}
void CImageView::OnMedianVector()
{
CImageDoc* pDoc=GetDocument();
MedianVector(&pDoc->m_Image, (int)QueryFloat("Enter Median Radius.\nRecommended Values: 1-10\nExample: 2", 0));
Invalidate();
}
void CImageView::OnKnnManual()
{
CImageDoc* pDoc=GetDocument();
KNN(&pDoc->m_Image, (int)QueryFloat("Enter KNN Radius.\nRecommended Values: 1-10\nExample: 2", 0),
QueryFloat("Enter KNN Power.\nRecommended Values: 25-50\nExample: 27.5", 0));
Invalidate();
}
void CImageView::OnNlmManual()
{
CImageDoc* pDoc=GetDocument();
NLM(&pDoc->m_Image, (int)QueryFloat("Enter NLM Radius.\nRecommended Values: 1-10\nExample: 2", 0),
QueryFloat("Enter NLM Power.\nRecommended Values: 8-30\nExample: 12.5", 0));
Invalidate();
}
void CImageView::OnKnnAutomatic()
{
CImageDoc* pDoc=GetDocument();
KNNAutomatic(&pDoc->m_Image);
Invalidate();
}
void CImageView::OnNlmAutomatic()
{
CImageDoc* pDoc=GetDocument();
NLMAutomatic(&pDoc->m_Image);
Invalidate();
}
|
retgone/cmc-cg
|
2006 - Task2 {20 of 22} [m]/src/MFC_GML3View.cpp
|
C++
|
mit
| 5,326
|
using SG.Util;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
namespace SG.Examples
{
/// <summary> A script to rotate an object around a specified axis </summary>
public class SGEx_RotateSimple : MonoBehaviour
{
public SG_Util.MoveAxis moveAround = SG_Util.MoveAxis.Y;
public float rotationSpeed = 10f;
public bool resetOnEnable = false;
public Quaternion OriginalRotation { get; protected set; }
public void ResetRotation()
{
this.transform.rotation = OriginalRotation;
}
void Awake()
{
OriginalRotation = this.transform.rotation;
}
void OnEnable()
{
if (resetOnEnable) { ResetRotation(); }
}
// Update is called once per frame
void Update()
{
float dAngle = Time.deltaTime * rotationSpeed;
this.transform.rotation = this.transform.rotation * Quaternion.AngleAxis(dAngle, SG.Util.SG_Util.GetAxis(this.moveAround));
}
}
}
|
Adjuvo/SenseGlove-Unity
|
SenseGlove/Examples/Resources/SGEx_RotateSimple.cs
|
C#
|
mit
| 1,076
|
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Contact Form</title>
<link rel="stylesheet" href="styles.css">
</head>
<body>
<h1>Contact Us</h1>
<form>
<span>First name:</span>
<input type="text" name="firstname">
<br/>
<span>Last name:</span>
<input type="text" name="secondname">
<br/>
<span>Email:</span>
<input type="text" name="email">
<br/>
<span>Town:</span>
<select name="town">
<option value="1">Sofia</option>
<option value="2">Plovdiv</option>
<option value="3">Asenovgrad</option>
<option value="5">Varna</option>
<option value="6">Burgas</option>
<option value="7">Stara Zagora</option>
<option value="8">Pazardzik</option>
<option value="9">Pernik</option>
</select>
<br/>
<input type="submit" value="Submit"/>
</form>
</body>
</html>
|
DGochew/Software-Technologies
|
HTML5 and CSS - Exercises 28.02.2017/13.Contact Us Form/contact-us-form.html
|
HTML
|
mit
| 1,011
|
---
layout: post
title: Paragon Character Texturing | Unreal Dev Day Montreal 2017
tags: [Unreal Dev Day, GAME]
categories:
- blog
---
In this Unreal Dev Day Montreal presentation, Technical Artist Harrison Moore goes through the texturing pipeline used
on Paragon from start to finish, breaking down the steps and techniques the team uses to texture hyper-realistic characters in UE4.
{% include youtubePlayer.html id="nVes6OUyzdw" %}
|
yoann01/yoann01.github.io
|
_posts/2017-09-11-Paragon_Character_Texturing.md
|
Markdown
|
mit
| 444
|
<?php
/*
* This file is part of the GenemuFormBundle package.
*
* (c) Olivier Chauvel <olivier@generation-multiple.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Genemu\Bundle\FormBundle\Form\Core\Validator;
use Symfony\Component\EventDispatcher\EventSubscriberInterface;
use Symfony\Component\Form\FormEvent;
use Symfony\Component\Form\FormError;
use Symfony\Component\Form\FormEvents;
use Symfony\Component\Form\Exception\InvalidConfigurationException;
use Symfony\Component\HttpFoundation\Request;
/**
* ReCaptchaValidator
*
* @author Olivier Chauvel <olivier@generation-multiple.com>
*/
class ReCaptchaValidator implements EventSubscriberInterface
{
private $httpRequest;
private $request;
private $privateKey;
private $options;
/**
* @param Request $request
* @param string $privateKey
* @param array $options Validation options
*/
public function __construct(Request $request, $privateKey, array $options = array())
{
$this->options = $options;
$this->request = $request;
if (empty($options['code'])) {
if (empty($privateKey)) {
throw new InvalidConfigurationException('The child node "private_key" at path "genenu_form.recaptcha" must be configured.');
}
$this->request = $request;
$this->privateKey = $privateKey;
$this->httpRequest = array(
'POST %s HTTP/1.0',
'Host: %s',
'Content-Type: application/x-www-form-urlencoded',
'Content-Length: %d',
'User-Agent: reCAPTCHA/PHP'
);
$this->httpRequest = implode("\r\n", $this->httpRequest)."\r\n\r\n%s";
}
}
public function addOptions(array $options)
{
$this->options = array_merge($this->options, $options);
}
public function getOptions()
{
return $this->options;
}
public function validate(FormEvent $event)
{
$form = $event->getForm();
$error = '';
$request = $this->request->request;
$datas = array(
'privatekey' => $this->privateKey,
'challenge' => $request->get('recaptcha_challenge_field'),
'response' => $request->get('recaptcha_response_field'),
'remoteip' => $this->request->getClientIp()
);
if (empty($this->options['code'])) {
if (empty($datas['challenge']) || empty($datas['response'])) {
$error = 'genemu_form.recaptcha.incorrect-captcha-sol';
} elseif (true !== ($answer = $this->check($datas, $form->getConfig()->getAttribute('option_validator')))) {
$error = 'genemu_form.recaptcha.unable-to-check-the-captcha-from-the-server';
}
} elseif ($this->options['code'] != $datas['response']) {
$error = 'genemu_form.recaptcha.incorrect-captcha-sol';
}
if (!empty($error)) {
$form->addError(new FormError($error));
}
}
/**
* Checks if the passed value is valid.
*
* @param array $datas The value that should be validated
* @param array $options The option server
*
* @return Boolean Whether or not the value is valid
*/
private function check(array $datas, array $options)
{
$options = array_merge($this->options, $options);
$response = '';
$datas = http_build_query($datas, null, '&');
$httpRequest = sprintf($this->httpRequest, $options['path'], $options['host'], strlen($datas), $datas);
$errno = 0;
$errstr = '';
if (false === ($fs = @fsockopen(
empty($options['proxy']) ? $options['host'] : $options['proxy']['host'],
empty($options['proxy']) ? $options['port'] : $options['proxy']['port'],
$errno,
$errstr,
$options['timeout']
))) {
return $errstr;
}
fwrite($fs, $httpRequest);
while (!feof($fs)) {
$response .= fgets($fs, 1160);
}
fclose($fs);
$response = explode("\r\n\r\n", $response, 2);
$answers = explode("\n", $response[1]);
return 'true' === trim($answers[0]) ? true : $answers[1];
}
public static function getSubscribedEvents()
{
return array(FormEvents::POST_BIND => 'validate');
}
}
|
lapoiz/WindServer2-vendor
|
genemu/form-bundle/Genemu/Bundle/FormBundle/Form/Core/Validator/ReCaptchaValidator.php
|
PHP
|
mit
| 4,535
|
'use strict';
const fs = require('fs');
const exec = require('child_process').exec;
const helpers = require('yeoman-test');
const assert = require('yeoman-assert');
const util = require('./support/util');
const defaultAnswers = require('./support/defaultPromptAnswers');
const promptOptions = require("../generators/app/promptOptions");
const defaultInit = require('./support/defaultInit');
const initTest = require('./support/initTest');
const answers = Object.assign({},defaultAnswers, {
"moduleType": promptOptions.moduleType.ES6_MODULES,
"language": promptOptions.language.ES6,
"advancedOptions": [
promptOptions.advanced.DEVLIB,
promptOptions.advanced.WEBSTORM
]
});
describe('ES Modules + ES6 + WebStorm', function () {
this.timeout(125000)
before(initTest(answers))
before(function(done) {
const that = this;
this.app = helpers
.run(require.resolve('../generators/app'))
.withGenerators([[helpers.createDummyGenerator(),require.resolve('../generators/class')]])
.withOptions({
'skip-welcome-message': true,
'skip-message': true,
'skip-install': false
})
.withPrompts(answers).then(function(dir) {return defaultInit(__filename, dir)}).then(function(dir) {
that.dir = dir;
done();
})
});
describe('check files', function() {
it('generates base files', function () {
assert.file([
'app/index.html',
'app/scripts/app.js',
'app/typings/yfiles-api-modules-ts43-webstorm.d.ts',
'package.json',
'webpack.config.js',
'app/lib/yfiles/yfiles.js',
'.idea/libraries/yFiles_for_HTML.xml',
'.idea/jsLibraryMappings.xml',
'.idea/testApp.iml',
'.idea/modules.xml',
'.idea/misc.xml',
'.idea/webResources.xml'
]);
assert.noFile([
'app/lib/es2015-shim.js',
'app/styles/yfiles.css',
'jsconfig.json',
'bower.json',
'tsconfig.json',
'app/scripts/license.json',
'app/typings/yfiles-api-umd-ts43-vscode.d.ts',
'app/typings/yfiles-api-umd-ts43-webstorm.d.ts',
'Gruntfile.js'
]);
});
});
describe('build result', function() {
it('created the bundles and sourcemaps', function() {
assert.file([
'app/dist/app.js',
'app/dist/app.js.map',
'app/dist/lib.js'
]);
});
it('uses webpack 4', function() {
assert.fileContent('package.json', /"webpack": "\^?4/)
})
it('runs', function (done) {
util.maybeOpenInBrowser(this.dir,done);
});
it('succeeds to run production build', function (done) {
const dir = this.dir;
const child = exec('npm run production', {cwd: dir.cwd}, function(error, stdout, stderr) {
console.log("\nbuild done!")
assert.ok(error === null, "Production build failed: "+error);
util.maybeOpenInBrowser(dir,done);
});
child.stdout.on('data', function(data) {
console.log(data.toString());
});
});
});
});
|
yWorks/generator-yfiles-app
|
test/esmodules-es6-webstorm.js
|
JavaScript
|
mit
| 3,069
|
.main{
margin-left:20px;
}
#searchbar{
width:50%;
}
#barAndBtn{
margin-top:30px;
}
#searchBlock{
background-color:#999;
margin:20px 0px;
}
a {
color:#FFF;
}
.underBtns{
margin:20px;
}
.underBtns .btn{
margin:5px;
}
|
ChenYuHsin/Admin-HR
|
dist/css/talentPool.css
|
CSS
|
mit
| 228
|
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Bootswatch: United</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="./bootstrap.css" media="screen">
<link rel="stylesheet" href="../assets/css/bootswatch.min.css">
<!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
<!--[if lt IE 9]>
<script src="../bower_components/html5shiv/dist/html5shiv.js"></script>
<script src="../bower_components/respond/dest/respond.min.js"></script>
<![endif]-->
<script>
var _gaq = _gaq || [];
_gaq.push(['_setAccount', 'UA-23019901-1']);
_gaq.push(['_setDomainName', "bootswatch.com"]);
_gaq.push(['_setAllowLinker', true]);
_gaq.push(['_trackPageview']);
(function() {
var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
})();
</script>
</head>
<body>
<div class="navbar navbar-default navbar-fixed-top">
<div class="container">
<div class="navbar-header">
<a href="../" class="navbar-brand">Bootswatch</a>
<button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#navbar-main">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
</div>
<div class="navbar-collapse collapse" id="navbar-main">
<ul class="nav navbar-nav">
<li class="dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#" id="themes">Themes <span class="caret"></span></a>
<ul class="dropdown-menu" aria-labelledby="themes">
<li><a href="../default/">Default</a></li>
<li class="divider"></li>
<li><a href="../cerulean/">Cerulean</a></li>
<li><a href="../cosmo/">Cosmo</a></li>
<li><a href="../cyborg/">Cyborg</a></li>
<li><a href="../darkly/">Darkly</a></li>
<li><a href="../flatly/">Flatly</a></li>
<li><a href="../journal/">Journal</a></li>
<li><a href="../lumen/">Lumen</a></li>
<li><a href="../paper/">Paper</a></li>
<li><a href="../readable/">Readable</a></li>
<li><a href="../sandstone/">Sandstone</a></li>
<li><a href="../simplex/">Simplex</a></li>
<li><a href="../slate/">Slate</a></li>
<li><a href="../spacelab/">Spacelab</a></li>
<li><a href="../superhero/">Superhero</a></li>
<li><a href="../united/">United</a></li>
<li><a href="../yeti/">Yeti</a></li>
</ul>
</li>
<li>
<a href="../help/">Help</a>
</li>
<li>
<a href="http://news.bootswatch.com">Blog</a>
</li>
<li class="dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#" id="download">Download <span class="caret"></span></a>
<ul class="dropdown-menu" aria-labelledby="download">
<li><a href="./bootstrap.min.css">bootstrap.min.css</a></li>
<li><a href="./bootstrap.css">bootstrap.css</a></li>
<li class="divider"></li>
<li><a href="./_variables.scss">_variables.scss</a></li>
<li><a href="./_bootswatch.scss">_bootswatch.scss</a></li>
</ul>
</li>
</ul>
<ul class="nav navbar-nav navbar-right">
<li><a href="http://builtwithbootstrap.com/" target="_blank">Built With Bootstrap</a></li>
<li><a href="https://wrapbootstrap.com/?ref=bsw" target="_blank">WrapBootstrap</a></li>
</ul>
</div>
</div>
</div>
<div class="container">
<div class="page-header" id="banner">
<div class="row">
<div class="col-lg-8 col-md-7 col-sm-6">
<h1>United</h1>
<p class="lead">Ubuntu orange and unique font</p>
</div>
<div class="col-lg-4 col-md-5 col-sm-6">
<div class="sponsor">
<a href="http://www.shopify.com/?ref=bootswatch" target="_blank" onclick="_gaq.push(['_trackEvent', 'banner', 'click', 'shopify']);"><img src="../assets/img/shopify.png" alt="Shopify" onload="_gaq.push(['_trackEvent', 'banner', 'impression', 'shopify']);"></a>
</div>
</div>
</div>
</div>
<!-- Navbar
================================================== -->
<div class="bs-docs-section clearfix">
<div class="row">
<div class="col-lg-12">
<div class="page-header">
<h1 id="navbar">Navbar</h1>
</div>
<div class="bs-component">
<div class="navbar navbar-default">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-responsive-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="#">Brand</a>
</div>
<div class="navbar-collapse collapse navbar-responsive-collapse">
<ul class="nav navbar-nav">
<li class="active"><a href="#">Active</a></li>
<li><a href="#">Link</a></li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li class="dropdown-header">Dropdown header</li>
<li><a href="#">Separated link</a></li>
<li><a href="#">One more separated link</a></li>
</ul>
</li>
</ul>
<form class="navbar-form navbar-left">
<input type="text" class="form-control col-lg-8" placeholder="Search">
</form>
<ul class="nav navbar-nav navbar-right">
<li><a href="#">Link</a></li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li><a href="#">Separated link</a></li>
</ul>
</li>
</ul>
</div>
</div>
</div>
<div class="bs-component">
<div class="navbar navbar-inverse">
<div class="navbar-header">
<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-inverse-collapse">
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="#">Brand</a>
</div>
<div class="navbar-collapse collapse navbar-inverse-collapse">
<ul class="nav navbar-nav">
<li class="active"><a href="#">Active</a></li>
<li><a href="#">Link</a></li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li class="dropdown-header">Dropdown header</li>
<li><a href="#">Separated link</a></li>
<li><a href="#">One more separated link</a></li>
</ul>
</li>
</ul>
<form class="navbar-form navbar-left">
<input type="text" class="form-control col-lg-8" placeholder="Search">
</form>
<ul class="nav navbar-nav navbar-right">
<li><a href="#">Link</a></li>
<li class="dropdown">
<a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li><a href="#">Separated link</a></li>
</ul>
</li>
</ul>
</div>
</div>
</div><!-- /example -->
</div>
</div>
</div>
<!-- Buttons
================================================== -->
<div class="bs-docs-section">
<div class="page-header">
<div class="row">
<div class="col-lg-12">
<h1 id="buttons">Buttons</h1>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-6">
<p class="bs-component">
<a href="#" class="btn btn-default">Default</a>
<a href="#" class="btn btn-primary">Primary</a>
<a href="#" class="btn btn-success">Success</a>
<a href="#" class="btn btn-info">Info</a>
<a href="#" class="btn btn-warning">Warning</a>
<a href="#" class="btn btn-danger">Danger</a>
<a href="#" class="btn btn-link">Link</a>
</p>
<p class="bs-component">
<a href="#" class="btn btn-default disabled">Default</a>
<a href="#" class="btn btn-primary disabled">Primary</a>
<a href="#" class="btn btn-success disabled">Success</a>
<a href="#" class="btn btn-info disabled">Info</a>
<a href="#" class="btn btn-warning disabled">Warning</a>
<a href="#" class="btn btn-danger disabled">Danger</a>
<a href="#" class="btn btn-link disabled">Link</a>
</p>
<div style="margin-bottom: 15px;">
<div class="btn-toolbar bs-component" style="margin: 0;">
<div class="btn-group">
<a href="#" class="btn btn-default">Default</a>
<a href="#" class="btn btn-default dropdown-toggle" data-toggle="dropdown"><span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li><a href="#">Separated link</a></li>
</ul>
</div>
<div class="btn-group">
<a href="#" class="btn btn-primary">Primary</a>
<a href="#" class="btn btn-primary dropdown-toggle" data-toggle="dropdown"><span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li><a href="#">Separated link</a></li>
</ul>
</div>
<div class="btn-group">
<a href="#" class="btn btn-success">Success</a>
<a href="#" class="btn btn-success dropdown-toggle" data-toggle="dropdown"><span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li><a href="#">Separated link</a></li>
</ul>
</div>
<div class="btn-group">
<a href="#" class="btn btn-info">Info</a>
<a href="#" class="btn btn-info dropdown-toggle" data-toggle="dropdown"><span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li><a href="#">Separated link</a></li>
</ul>
</div>
<div class="btn-group">
<a href="#" class="btn btn-warning">Warning</a>
<a href="#" class="btn btn-warning dropdown-toggle" data-toggle="dropdown"><span class="caret"></span></a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li><a href="#">Separated link</a></li>
</ul>
</div>
</div>
</div>
<p class="bs-component">
<a href="#" class="btn btn-primary btn-lg">Large button</a>
<a href="#" class="btn btn-primary">Default button</a>
<a href="#" class="btn btn-primary btn-sm">Small button</a>
<a href="#" class="btn btn-primary btn-xs">Mini button</a>
</p>
</div>
<div class="col-lg-6">
<p class="bs-component">
<a href="#" class="btn btn-default btn-lg btn-block">Block level button</a>
</p>
<div class="bs-component" style="margin-bottom: 15px;">
<div class="btn-group btn-group-justified">
<a href="#" class="btn btn-default">Left</a>
<a href="#" class="btn btn-default">Middle</a>
<a href="#" class="btn btn-default">Right</a>
</div>
</div>
<div class="bs-component" style="margin-bottom: 15px;">
<div class="btn-toolbar">
<div class="btn-group">
<a href="#" class="btn btn-default">1</a>
<a href="#" class="btn btn-default">2</a>
<a href="#" class="btn btn-default">3</a>
<a href="#" class="btn btn-default">4</a>
</div>
<div class="btn-group">
<a href="#" class="btn btn-default">5</a>
<a href="#" class="btn btn-default">6</a>
<a href="#" class="btn btn-default">7</a>
</div>
<div class="btn-group">
<a href="#" class="btn btn-default">8</a>
<div class="btn-group">
<a href="#" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
Dropdown
<span class="caret"></span>
</a>
<ul class="dropdown-menu">
<li><a href="#">Dropdown link</a></li>
<li><a href="#">Dropdown link</a></li>
<li><a href="#">Dropdown link</a></li>
</ul>
</div>
</div>
</div>
</div>
<div class="bs-component">
<div class="btn-group-vertical">
<a href="#" class="btn btn-default">Button</a>
<a href="#" class="btn btn-default">Button</a>
<a href="#" class="btn btn-default">Button</a>
<a href="#" class="btn btn-default">Button</a>
</div>
</div>
</div>
</div>
</div>
<!-- Typography
================================================== -->
<div class="bs-docs-section">
<div class="row">
<div class="col-lg-12">
<div class="page-header">
<h1 id="type">Typography</h1>
</div>
</div>
</div>
<!-- Headings -->
<div class="row">
<div class="col-lg-4">
<div class="bs-component">
<h1>Heading 1</h1>
<h2>Heading 2</h2>
<h3>Heading 3</h3>
<h4>Heading 4</h4>
<h5>Heading 5</h5>
<h6>Heading 6</h6>
<p class="lead">Vivamus sagittis lacus vel augue laoreet rutrum faucibus dolor auctor.</p>
</div>
</div>
<div class="col-lg-4">
<div class="bs-component">
<h2>Example body text</h2>
<p>Nullam quis risus eget <a href="#">urna mollis ornare</a> vel eu leo. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Nullam id dolor id nibh ultricies vehicula.</p>
<p><small>This line of text is meant to be treated as fine print.</small></p>
<p>The following snippet of text is <strong>rendered as bold text</strong>.</p>
<p>The following snippet of text is <em>rendered as italicized text</em>.</p>
<p>An abbreviation of the word attribute is <abbr title="attribute">attr</abbr>.</p>
</div>
</div>
<div class="col-lg-4">
<div class="bs-component">
<h2>Emphasis classes</h2>
<p class="text-muted">Fusce dapibus, tellus ac cursus commodo, tortor mauris nibh.</p>
<p class="text-primary">Nullam id dolor id nibh ultricies vehicula ut id elit.</p>
<p class="text-warning">Etiam porta sem malesuada magna mollis euismod.</p>
<p class="text-danger">Donec ullamcorper nulla non metus auctor fringilla.</p>
<p class="text-success">Duis mollis, est non commodo luctus, nisi erat porttitor ligula.</p>
<p class="text-info">Maecenas sed diam eget risus varius blandit sit amet non magna.</p>
</div>
</div>
</div>
<!-- Blockquotes -->
<div class="row">
<div class="col-lg-12">
<h2 id="type-blockquotes">Blockquotes</h2>
</div>
</div>
<div class="row">
<div class="col-lg-6">
<div class="bs-component">
<blockquote>
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere erat a ante.</p>
<small>Someone famous in <cite title="Source Title">Source Title</cite></small>
</blockquote>
</div>
</div>
<div class="col-lg-6">
<div class="bs-component">
<blockquote class="pull-right">
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Integer posuere erat a ante.</p>
<small>Someone famous in <cite title="Source Title">Source Title</cite></small>
</blockquote>
</div>
</div>
</div>
</div>
<!-- Tables
================================================== -->
<div class="bs-docs-section">
<div class="row">
<div class="col-lg-12">
<div class="page-header">
<h1 id="tables">Tables</h1>
</div>
<div class="bs-component">
<table class="table table-striped table-hover ">
<thead>
<tr>
<th>#</th>
<th>Column heading</th>
<th>Column heading</th>
<th>Column heading</th>
</tr>
</thead>
<tbody>
<tr>
<td>1</td>
<td>Column content</td>
<td>Column content</td>
<td>Column content</td>
</tr>
<tr>
<td>2</td>
<td>Column content</td>
<td>Column content</td>
<td>Column content</td>
</tr>
<tr class="info">
<td>3</td>
<td>Column content</td>
<td>Column content</td>
<td>Column content</td>
</tr>
<tr class="success">
<td>4</td>
<td>Column content</td>
<td>Column content</td>
<td>Column content</td>
</tr>
<tr class="danger">
<td>5</td>
<td>Column content</td>
<td>Column content</td>
<td>Column content</td>
</tr>
<tr class="warning">
<td>6</td>
<td>Column content</td>
<td>Column content</td>
<td>Column content</td>
</tr>
<tr class="active">
<td>7</td>
<td>Column content</td>
<td>Column content</td>
<td>Column content</td>
</tr>
</tbody>
</table>
</div><!-- /example -->
</div>
</div>
</div>
<!-- Forms
================================================== -->
<div class="bs-docs-section">
<div class="row">
<div class="col-lg-12">
<div class="page-header">
<h1 id="forms">Forms</h1>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-6">
<div class="well bs-component">
<form class="form-horizontal">
<fieldset>
<legend>Legend</legend>
<div class="form-group">
<label for="inputEmail" class="col-lg-2 control-label">Email</label>
<div class="col-lg-10">
<input type="text" class="form-control" id="inputEmail" placeholder="Email">
</div>
</div>
<div class="form-group">
<label for="inputPassword" class="col-lg-2 control-label">Password</label>
<div class="col-lg-10">
<input type="password" class="form-control" id="inputPassword" placeholder="Password">
<div class="checkbox">
<label>
<input type="checkbox"> Checkbox
</label>
</div>
</div>
</div>
<div class="form-group">
<label for="textArea" class="col-lg-2 control-label">Textarea</label>
<div class="col-lg-10">
<textarea class="form-control" rows="3" id="textArea"></textarea>
<span class="help-block">A longer block of help text that breaks onto a new line and may extend beyond one line.</span>
</div>
</div>
<div class="form-group">
<label class="col-lg-2 control-label">Radios</label>
<div class="col-lg-10">
<div class="radio">
<label>
<input type="radio" name="optionsRadios" id="optionsRadios1" value="option1" checked="">
Option one is this
</label>
</div>
<div class="radio">
<label>
<input type="radio" name="optionsRadios" id="optionsRadios2" value="option2">
Option two can be something else
</label>
</div>
</div>
</div>
<div class="form-group">
<label for="select" class="col-lg-2 control-label">Selects</label>
<div class="col-lg-10">
<select class="form-control" id="select">
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
<option>5</option>
</select>
<br>
<select multiple="" class="form-control">
<option>1</option>
<option>2</option>
<option>3</option>
<option>4</option>
<option>5</option>
</select>
</div>
</div>
<div class="form-group">
<div class="col-lg-10 col-lg-offset-2">
<button class="btn btn-default">Cancel</button>
<button type="submit" class="btn btn-primary">Submit</button>
</div>
</div>
</fieldset>
</form>
</div>
</div>
<div class="col-lg-4 col-lg-offset-1">
<form class="bs-component">
<div class="form-group">
<label class="control-label" for="focusedInput">Focused input</label>
<input class="form-control" id="focusedInput" type="text" value="This is focused...">
</div>
<div class="form-group">
<label class="control-label" for="disabledInput">Disabled input</label>
<input class="form-control" id="disabledInput" type="text" placeholder="Disabled input here..." disabled="">
</div>
<div class="form-group has-warning">
<label class="control-label" for="inputWarning">Input warning</label>
<input type="text" class="form-control" id="inputWarning">
</div>
<div class="form-group has-error">
<label class="control-label" for="inputError">Input error</label>
<input type="text" class="form-control" id="inputError">
</div>
<div class="form-group has-success">
<label class="control-label" for="inputSuccess">Input success</label>
<input type="text" class="form-control" id="inputSuccess">
</div>
<div class="form-group">
<label class="control-label" for="inputLarge">Large input</label>
<input class="form-control input-lg" type="text" id="inputLarge">
</div>
<div class="form-group">
<label class="control-label" for="inputDefault">Default input</label>
<input type="text" class="form-control" id="inputDefault">
</div>
<div class="form-group">
<label class="control-label" for="inputSmall">Small input</label>
<input class="form-control input-sm" type="text" id="inputSmall">
</div>
<div class="form-group">
<label class="control-label">Input addons</label>
<div class="input-group">
<span class="input-group-addon">$</span>
<input type="text" class="form-control">
<span class="input-group-btn">
<button class="btn btn-default" type="button">Button</button>
</span>
</div>
</div>
</form>
</div>
</div>
</div>
<!-- Navs
================================================== -->
<div class="bs-docs-section">
<div class="row">
<div class="col-lg-12">
<div class="page-header">
<h1 id="nav">Navs</h1>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-4">
<h2 id="nav-tabs">Tabs</h2>
<div class="bs-component">
<ul class="nav nav-tabs">
<li class="active"><a href="#home" data-toggle="tab">Home</a></li>
<li><a href="#profile" data-toggle="tab">Profile</a></li>
<li class="disabled"><a>Disabled</a></li>
<li class="dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#">
Dropdown <span class="caret"></span>
</a>
<ul class="dropdown-menu">
<li><a href="#dropdown1" data-toggle="tab">Action</a></li>
<li class="divider"></li>
<li><a href="#dropdown2" data-toggle="tab">Another action</a></li>
</ul>
</li>
</ul>
<div id="myTabContent" class="tab-content">
<div class="tab-pane fade active in" id="home">
<p>Raw denim you probably haven't heard of them jean shorts Austin. Nesciunt tofu stumptown aliqua, retro synth master cleanse. Mustache cliche tempor, williamsburg carles vegan helvetica. Reprehenderit butcher retro keffiyeh dreamcatcher synth. Cosby sweater eu banh mi, qui irure terry richardson ex squid. Aliquip placeat salvia cillum iphone. Seitan aliquip quis cardigan american apparel, butcher voluptate nisi qui.</p>
</div>
<div class="tab-pane fade" id="profile">
<p>Food truck fixie locavore, accusamus mcsweeney's marfa nulla single-origin coffee squid. Exercitation +1 labore velit, blog sartorial PBR leggings next level wes anderson artisan four loko farm-to-table craft beer twee. Qui photo booth letterpress, commodo enim craft beer mlkshk aliquip jean shorts ullamco ad vinyl cillum PBR. Homo nostrud organic, assumenda labore aesthetic magna delectus mollit.</p>
</div>
<div class="tab-pane fade" id="dropdown1">
<p>Etsy mixtape wayfarers, ethical wes anderson tofu before they sold out mcsweeney's organic lomo retro fanny pack lo-fi farm-to-table readymade. Messenger bag gentrify pitchfork tattooed craft beer, iphone skateboard locavore carles etsy salvia banksy hoodie helvetica. DIY synth PBR banksy irony. Leggings gentrify squid 8-bit cred pitchfork.</p>
</div>
<div class="tab-pane fade" id="dropdown2">
<p>Trust fund seitan letterpress, keytar raw denim keffiyeh etsy art party before they sold out master cleanse gluten-free squid scenester freegan cosby sweater. Fanny pack portland seitan DIY, art party locavore wolf cliche high life echo park Austin. Cred vinyl keffiyeh DIY salvia PBR, banh mi before they sold out farm-to-table VHS viral locavore cosby sweater.</p>
</div>
</div>
</div>
</div>
<div class="col-lg-4">
<h2 id="nav-pills">Pills</h2>
<div class="bs-component">
<ul class="nav nav-pills">
<li class="active"><a href="#">Home</a></li>
<li><a href="#">Profile</a></li>
<li class="disabled"><a href="#">Disabled</a></li>
<li class="dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#">
Dropdown <span class="caret"></span>
</a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li><a href="#">Separated link</a></li>
</ul>
</li>
</ul>
</div>
<br>
<div class="bs-component">
<ul class="nav nav-pills nav-stacked">
<li class="active"><a href="#">Home</a></li>
<li><a href="#">Profile</a></li>
<li class="disabled"><a href="#">Disabled</a></li>
<li class="dropdown">
<a class="dropdown-toggle" data-toggle="dropdown" href="#">
Dropdown <span class="caret"></span>
</a>
<ul class="dropdown-menu">
<li><a href="#">Action</a></li>
<li><a href="#">Another action</a></li>
<li><a href="#">Something else here</a></li>
<li class="divider"></li>
<li><a href="#">Separated link</a></li>
</ul>
</li>
</ul>
</div>
</div>
<div class="col-lg-4">
<h2 id="nav-breadcrumbs">Breadcrumbs</h2>
<div class="bs-component">
<ul class="breadcrumb">
<li class="active">Home</li>
</ul>
<ul class="breadcrumb">
<li><a href="#">Home</a></li>
<li class="active">Library</li>
</ul>
<ul class="breadcrumb">
<li><a href="#">Home</a></li>
<li><a href="#">Library</a></li>
<li class="active">Data</li>
</ul>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-4">
<h2 id="pagination">Pagination</h2>
<div class="bs-component">
<ul class="pagination">
<li class="disabled"><a href="#">«</a></li>
<li class="active"><a href="#">1</a></li>
<li><a href="#">2</a></li>
<li><a href="#">3</a></li>
<li><a href="#">4</a></li>
<li><a href="#">5</a></li>
<li><a href="#">»</a></li>
</ul>
<ul class="pagination pagination-lg">
<li class="disabled"><a href="#">«</a></li>
<li class="active"><a href="#">1</a></li>
<li><a href="#">2</a></li>
<li><a href="#">3</a></li>
<li><a href="#">»</a></li>
</ul>
<ul class="pagination pagination-sm">
<li class="disabled"><a href="#">«</a></li>
<li class="active"><a href="#">1</a></li>
<li><a href="#">2</a></li>
<li><a href="#">3</a></li>
<li><a href="#">4</a></li>
<li><a href="#">5</a></li>
<li><a href="#">»</a></li>
</ul>
</div>
</div>
<div class="col-lg-4">
<h2 id="pager">Pager</h2>
<div class="bs-component">
<ul class="pager">
<li><a href="#">Previous</a></li>
<li><a href="#">Next</a></li>
</ul>
<ul class="pager">
<li class="previous disabled"><a href="#">← Older</a></li>
<li class="next"><a href="#">Newer →</a></li>
</ul>
</div>
</div>
<div class="col-lg-4">
</div>
</div>
</div>
<!-- Indicators
================================================== -->
<div class="bs-docs-section">
<div class="row">
<div class="col-lg-12">
<div class="page-header">
<h1 id="indicators">Indicators</h1>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-12">
<h2>Alerts</h2>
<div class="bs-component">
<div class="alert alert-dismissable alert-warning">
<button type="button" class="close" data-dismiss="alert">×</button>
<h4>Warning!</h4>
<p>Best check yo self, you're not looking too good. Nulla vitae elit libero, a pharetra augue. Praesent commodo cursus magna, <a href="#" class="alert-link">vel scelerisque nisl consectetur et</a>.</p>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-4">
<div class="bs-component">
<div class="alert alert-dismissable alert-danger">
<button type="button" class="close" data-dismiss="alert">×</button>
<strong>Oh snap!</strong> <a href="#" class="alert-link">Change a few things up</a> and try submitting again.
</div>
</div>
</div>
<div class="col-lg-4">
<div class="bs-component">
<div class="alert alert-dismissable alert-success">
<button type="button" class="close" data-dismiss="alert">×</button>
<strong>Well done!</strong> You successfully read <a href="#" class="alert-link">this important alert message</a>.
</div>
</div>
</div>
<div class="col-lg-4">
<div class="bs-component">
<div class="alert alert-dismissable alert-info">
<button type="button" class="close" data-dismiss="alert">×</button>
<strong>Heads up!</strong> This <a href="#" class="alert-link">alert needs your attention</a>, but it's not super important.
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-4">
<h2>Labels</h2>
<div class="bs-component" style="margin-bottom: 40px;">
<span class="label label-default">Default</span>
<span class="label label-primary">Primary</span>
<span class="label label-success">Success</span>
<span class="label label-warning">Warning</span>
<span class="label label-danger">Danger</span>
<span class="label label-info">Info</span>
</div>
</div>
<div class="col-lg-4">
<h2>Badges</h2>
<div class="bs-component">
<ul class="nav nav-pills">
<li class="active"><a href="#">Home <span class="badge">42</span></a></li>
<li><a href="#">Profile <span class="badge"></span></a></li>
<li><a href="#">Messages <span class="badge">3</span></a></li>
</ul>
</div>
</div>
</div>
</div>
<!-- Progress bars
================================================== -->
<div class="bs-docs-section">
<div class="row">
<div class="col-lg-12">
<div class="page-header">
<h1 id="progress">Progress bars</h1>
</div>
<h3 id="progress-basic">Basic</h3>
<div class="bs-component">
<div class="progress">
<div class="progress-bar" style="width: 60%;"></div>
</div>
</div>
<h3 id="progress-alternatives">Contextual alternatives</h3>
<div class="bs-component">
<div class="progress">
<div class="progress-bar progress-bar-info" style="width: 20%"></div>
</div>
<div class="progress">
<div class="progress-bar progress-bar-success" style="width: 40%"></div>
</div>
<div class="progress">
<div class="progress-bar progress-bar-warning" style="width: 60%"></div>
</div>
<div class="progress">
<div class="progress-bar progress-bar-danger" style="width: 80%"></div>
</div>
</div>
<h3 id="progress-striped">Striped</h3>
<div class="bs-component">
<div class="progress progress-striped">
<div class="progress-bar progress-bar-info" style="width: 20%"></div>
</div>
<div class="progress progress-striped">
<div class="progress-bar progress-bar-success" style="width: 40%"></div>
</div>
<div class="progress progress-striped">
<div class="progress-bar progress-bar-warning" style="width: 60%"></div>
</div>
<div class="progress progress-striped">
<div class="progress-bar progress-bar-danger" style="width: 80%"></div>
</div>
</div>
<h3 id="progress-animated">Animated</h3>
<div class="bs-component">
<div class="progress progress-striped active">
<div class="progress-bar" style="width: 45%"></div>
</div>
</div>
<h3 id="progress-stacked">Stacked</h3>
<div class="bs-component">
<div class="progress">
<div class="progress-bar progress-bar-success" style="width: 35%"></div>
<div class="progress-bar progress-bar-warning" style="width: 20%"></div>
<div class="progress-bar progress-bar-danger" style="width: 10%"></div>
</div>
</div>
</div>
</div>
</div>
<!-- Containers
================================================== -->
<div class="bs-docs-section">
<div class="row">
<div class="col-lg-12">
<div class="page-header">
<h1 id="container">Containers</h1>
</div>
<div class="bs-component">
<div class="jumbotron">
<h1>Jumbotron</h1>
<p>This is a simple hero unit, a simple jumbotron-style component for calling extra attention to featured content or information.</p>
<p><a class="btn btn-primary btn-lg">Learn more</a></p>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-12">
<h2>List groups</h2>
</div>
</div>
<div class="row">
<div class="col-lg-4">
<div class="bs-component">
<ul class="list-group">
<li class="list-group-item">
<span class="badge">14</span>
Cras justo odio
</li>
<li class="list-group-item">
<span class="badge">2</span>
Dapibus ac facilisis in
</li>
<li class="list-group-item">
<span class="badge">1</span>
Morbi leo risus
</li>
</ul>
</div>
</div>
<div class="col-lg-4">
<div class="bs-component">
<div class="list-group">
<a href="#" class="list-group-item active">
Cras justo odio
</a>
<a href="#" class="list-group-item">Dapibus ac facilisis in
</a>
<a href="#" class="list-group-item">Morbi leo risus
</a>
</div>
</div>
</div>
<div class="col-lg-4">
<div class="bs-component">
<div class="list-group">
<a href="#" class="list-group-item">
<h4 class="list-group-item-heading">List group item heading</h4>
<p class="list-group-item-text">Donec id elit non mi porta gravida at eget metus. Maecenas sed diam eget risus varius blandit.</p>
</a>
<a href="#" class="list-group-item">
<h4 class="list-group-item-heading">List group item heading</h4>
<p class="list-group-item-text">Donec id elit non mi porta gravida at eget metus. Maecenas sed diam eget risus varius blandit.</p>
</a>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-12">
<h2>Panels</h2>
</div>
</div>
<div class="row">
<div class="col-lg-4">
<div class="bs-component">
<div class="panel panel-default">
<div class="panel-body">
Basic panel
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading">Panel heading</div>
<div class="panel-body">
Panel content
</div>
</div>
<div class="panel panel-default">
<div class="panel-body">
Panel content
</div>
<div class="panel-footer">Panel footer</div>
</div>
</div>
</div>
<div class="col-lg-4">
<div class="bs-component">
<div class="panel panel-primary">
<div class="panel-heading">
<h3 class="panel-title">Panel primary</h3>
</div>
<div class="panel-body">
Panel content
</div>
</div>
<div class="panel panel-success">
<div class="panel-heading">
<h3 class="panel-title">Panel success</h3>
</div>
<div class="panel-body">
Panel content
</div>
</div>
<div class="panel panel-warning">
<div class="panel-heading">
<h3 class="panel-title">Panel warning</h3>
</div>
<div class="panel-body">
Panel content
</div>
</div>
</div>
</div>
<div class="col-lg-4">
<div class="bs-component">
<div class="panel panel-danger">
<div class="panel-heading">
<h3 class="panel-title">Panel danger</h3>
</div>
<div class="panel-body">
Panel content
</div>
</div>
<div class="panel panel-info">
<div class="panel-heading">
<h3 class="panel-title">Panel info</h3>
</div>
<div class="panel-body">
Panel content
</div>
</div>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-12">
<h2>Wells</h2>
</div>
</div>
<div class="row">
<div class="col-lg-4">
<div class="bs-component">
<div class="well">
Look, I'm in a well!
</div>
</div>
</div>
<div class="col-lg-4">
<div class="bs-component">
<div class="well well-sm">
Look, I'm in a small well!
</div>
</div>
</div>
<div class="col-lg-4">
<div class="bs-component">
<div class="well well-lg">
Look, I'm in a large well!
</div>
</div>
</div>
</div>
</div>
<!-- Dialogs
================================================== -->
<div class="bs-docs-section">
<div class="row">
<div class="col-lg-12">
<div class="page-header">
<h1 id="tables">Dialogs</h1>
</div>
</div>
</div>
<div class="row">
<div class="col-lg-6">
<h2>Modals</h2>
<div class="bs-component">
<div class="modal">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
<h4 class="modal-title">Modal title</h4>
</div>
<div class="modal-body">
<p>One fine body…</p>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" data-dismiss="modal">Close</button>
<button type="button" class="btn btn-primary">Save changes</button>
</div>
</div>
</div>
</div>
</div>
</div>
<div class="col-lg-6">
<h2>Popovers</h2>
<div class="bs-component">
<button type="button" class="btn btn-default" data-container="body" data-toggle="popover" data-placement="left" data-content="Vivamus sagittis lacus vel augue laoreet rutrum faucibus.">Left</button>
<button type="button" class="btn btn-default" data-container="body" data-toggle="popover" data-placement="top" data-content="Vivamus sagittis lacus vel augue laoreet rutrum faucibus.">Top</button>
<button type="button" class="btn btn-default" data-container="body" data-toggle="popover" data-placement="bottom" data-content="Vivamus
sagittis lacus vel augue laoreet rutrum faucibus.">Bottom</button>
<button type="button" class="btn btn-default" data-container="body" data-toggle="popover" data-placement="right" data-content="Vivamus sagittis lacus vel augue laoreet rutrum faucibus.">Right</button>
</div>
<h2>Tooltips</h2>
<div class="bs-component">
<button type="button" class="btn btn-default" data-toggle="tooltip" data-placement="left" title="" data-original-title="Tooltip on left">Left</button>
<button type="button" class="btn btn-default" data-toggle="tooltip" data-placement="top" title="" data-original-title="Tooltip on top">Top</button>
<button type="button" class="btn btn-default" data-toggle="tooltip" data-placement="bottom" title="" data-original-title="Tooltip on bottom">Bottom</button>
<button type="button" class="btn btn-default" data-toggle="tooltip" data-placement="right" title="" data-original-title="Tooltip on right">Right</button>
</div>
</div>
</div>
</div>
<div id="source-modal" class="modal fade">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
<h4 class="modal-title">Source Code</h4>
</div>
<div class="modal-body">
<pre></pre>
</div>
</div>
</div>
</div>
<footer>
<div class="row">
<div class="col-lg-12">
<ul class="list-unstyled">
<li class="pull-right"><a href="#top">Back to top</a></li>
<li><a href="http://news.bootswatch.com" onclick="pageTracker._link(this.href); return false;">Blog</a></li>
<li><a href="http://feeds.feedburner.com/bootswatch">RSS</a></li>
<li><a href="https://twitter.com/bootswatch">Twitter</a></li>
<li><a href="https://github.com/guru-digital/bootswatch-sass/">GitHub</a></li>
<li><a href="../help/#api">API</a></li>
<li><a href="../help/#support">Support</a></li>
</ul>
<p>Made by <a href="http://thomaspark.me" rel="nofollow">Thomas Park</a>. Contact him at <a href="mailto:thomas@bootswatch.com">thomas@bootswatch.com</a>.</p>
<p>Code released under the <a href="https://github.com/guru-digital/bootswatch-sass/blob/gh-pages/LICENSE">MIT License</a>.</p>
<p>Based on <a href="http://getbootstrap.com" rel="nofollow">Bootstrap</a>. Icons from <a href="http://fortawesome.github.io/Font-Awesome/" rel="nofollow">Font Awesome</a>. Web fonts from <a href="http://www.google.com/webfonts" rel="nofollow">Google</a>.</p>
</div>
</div>
</footer>
</div>
<script src="https://code.jquery.com/jquery-1.10.2.min.js"></script>
<script src="../bower_components/bootstrap/dist/js/bootstrap.min.js"></script>
<script src="../assets/js/bootswatch.js"></script>
</body>
</html>
|
arroyolabs-blog/roll-dice
|
app/themes/bootstrap/node_modules/bootswatch-sass/united/index.html
|
HTML
|
mit
| 55,633
|
package de.torqdev.easysettings.core;
/**
* @author <a href="mailto:christopher.guckes@torq-dev.de">Christopher Guckes</a>
* @version 1.0
*/
public class RangeSettingBuilder<T extends Number> {
private T defaultValue;
private Class<T> valueType;
private T min;
private T max;
private String helpMessage;
public RangeSettingBuilder<T> forType(final Class<T> clazz) {
this.valueType = clazz;
return this;
}
public RangeSettingBuilder<T> defaultValue(final T defaultValue) {
this.defaultValue = defaultValue;
return this;
}
public RangeSettingBuilder<T> lowerBound(final T min) {
this.min = min;
return this;
}
public RangeSettingBuilder<T> upperBound(final T max) {
this.max = max;
return this;
}
public RangeSettingBuilder<T> withHelpMessage(final String helpMessage) {
this.helpMessage = helpMessage;
return this;
}
public RangeSetting<T> build() {
return new RangeSetting<>(defaultValue, valueType, min, max, helpMessage);
}
}
|
GuckesRohrkaGbR/easy-settings
|
src/main/java/de/torqdev/easysettings/core/RangeSettingBuilder.java
|
Java
|
mit
| 1,095
|
#ifndef __NV40_SHADER_H__
#define __NV40_SHADER_H__
/* Vertex programs instruction set
*
* The NV40 instruction set is very similar to NV30. Most fields are in
* a slightly different position in the instruction however.
*
* Merged instructions
* In some cases it is possible to put two instructions into one opcode
* slot. The rules for when this is OK is not entirely clear to me yet.
*
* There are separate writemasks and dest temp register fields for each
* grouping of instructions. There is however only one field with the
* ID of a result register. Writing to temp/result regs is selected by
* setting VEC_RESULT/SCA_RESULT.
*
* Temporary registers
* The source/dest temp register fields have been extended by 1 bit, to
* give a total of 32 temporary registers.
*
* Relative Addressing
* NV40 can use an address register to index into vertex attribute regs.
* This is done by putting the offset value into INPUT_SRC and setting
* the INDEX_INPUT flag.
*
* Conditional execution (see NV_vertex_program{2,3} for details)
* There is a second condition code register on NV40, it's use is enabled
* by setting the COND_REG_SELECT_1 flag.
*
* Texture lookup
* TODO
*/
/* ---- OPCODE BITS 127:96 / data DWORD 0 --- */
#define NV40_VP_INST_VEC_RESULT (1 << 30)
/* uncertain.. */
#define NV40_VP_INST_COND_UPDATE_ENABLE ((1 << 14)|1<<29)
/* use address reg as index into attribs */
#define NV40_VP_INST_INDEX_INPUT (1 << 27)
#define NV40_VP_INST_SATURATE (1 << 26)
#define NV40_VP_INST_COND_REG_SELECT_SHIFT 25
#define NV40_VP_INST_COND_REG_SELECT_1 (1 << 25)
#define NV40_VP_INST_ADDR_REG_SELECT_1 (1 << 24)
#define NV40_VP_INST_SRC2_ABS (1 << 23)
#define NV40_VP_INST_SRC1_ABS (1 << 22)
#define NV40_VP_INST_SRC0_ABS (1 << 21)
#define NV40_VP_INST_VEC_DEST_TEMP_SHIFT 15
#define NV40_VP_INST_VEC_DEST_TEMP_MASK (0x3F << 15)
#define NV40_VP_INST_COND_TEST_SHIFT 13
#define NV40_VP_INST_COND_TEST_ENABLE (1 << 13)
#define NV40_VP_INST_COND_SHIFT 10
#define NV40_VP_INST_COND_MASK (0x7 << 10)
#define NV40_VP_INST_COND_SWZ_X_SHIFT 8
#define NV40_VP_INST_COND_SWZ_X_MASK (3 << 8)
#define NV40_VP_INST_COND_SWZ_Y_SHIFT 6
#define NV40_VP_INST_COND_SWZ_Y_MASK (3 << 6)
#define NV40_VP_INST_COND_SWZ_Z_SHIFT 4
#define NV40_VP_INST_COND_SWZ_Z_MASK (3 << 4)
#define NV40_VP_INST_COND_SWZ_W_SHIFT 2
#define NV40_VP_INST_COND_SWZ_W_MASK (3 << 2)
#define NV40_VP_INST_COND_SWZ_ALL_SHIFT 2
#define NV40_VP_INST_COND_SWZ_ALL_MASK (0xFF << 2)
#define NV40_VP_INST_ADDR_SWZ_SHIFT 0
#define NV40_VP_INST_ADDR_SWZ_MASK (0x03 << 0)
#define NV40_VP_INST0_KNOWN ( \
NV40_VP_INST_INDEX_INPUT | \
NV40_VP_INST_COND_REG_SELECT_1 | \
NV40_VP_INST_ADDR_REG_SELECT_1 | \
NV40_VP_INST_SRC2_ABS | \
NV40_VP_INST_SRC1_ABS | \
NV40_VP_INST_SRC0_ABS | \
NV40_VP_INST_VEC_DEST_TEMP_MASK | \
NV40_VP_INST_COND_TEST_ENABLE | \
NV40_VP_INST_COND_MASK | \
NV40_VP_INST_COND_SWZ_ALL_MASK | \
NV40_VP_INST_ADDR_SWZ_MASK)
/* ---- OPCODE BITS 95:64 / data DWORD 1 --- */
#define NV40_VP_INST_VEC_OPCODE_SHIFT 22
#define NV40_VP_INST_VEC_OPCODE_MASK (0x1F << 22)
#define NV40_VP_INST_SCA_OPCODE_SHIFT 27
#define NV40_VP_INST_SCA_OPCODE_MASK (0x1F << 27)
#define NV40_VP_INST_CONST_SRC_SHIFT 12
#define NV40_VP_INST_CONST_SRC_MASK (0xFF << 12)
#define NV40_VP_INST_INPUT_SRC_SHIFT 8
#define NV40_VP_INST_INPUT_SRC_MASK (0x0F << 8)
#define NV40_VP_INST_SRC0H_SHIFT 0
#define NV40_VP_INST_SRC0H_MASK (0xFF << 0)
#define NV40_VP_INST1_KNOWN ( \
NV40_VP_INST_VEC_OPCODE_MASK | \
NV40_VP_INST_SCA_OPCODE_MASK | \
NV40_VP_INST_CONST_SRC_MASK | \
NV40_VP_INST_INPUT_SRC_MASK | \
NV40_VP_INST_SRC0H_MASK \
)
/* ---- OPCODE BITS 63:32 / data DWORD 2 --- */
#define NV40_VP_INST_SRC0L_SHIFT 23
#define NV40_VP_INST_SRC0L_MASK (0x1FF << 23)
#define NV40_VP_INST_SRC1_SHIFT 6
#define NV40_VP_INST_SRC1_MASK (0x1FFFF << 6)
#define NV40_VP_INST_SRC2H_SHIFT 0
#define NV40_VP_INST_SRC2H_MASK (0x3F << 0)
#define NV40_VP_INST_IADDRH_SHIFT 0
#define NV40_VP_INST_IADDRH_MASK (0x3F << 0)
/* ---- OPCODE BITS 31:0 / data DWORD 3 --- */
#define NV40_VP_INST_IADDRL_SHIFT 29
#define NV40_VP_INST_IADDRL_MASK (7 << 29)
#define NV40_VP_INST_SRC2L_SHIFT 21
#define NV40_VP_INST_SRC2L_MASK (0x7FF << 21)
#define NV40_VP_INST_SCA_WRITEMASK_SHIFT 17
#define NV40_VP_INST_SCA_WRITEMASK_MASK (0xF << 17)
# define NV40_VP_INST_SCA_WRITEMASK_X (1 << 20)
# define NV40_VP_INST_SCA_WRITEMASK_Y (1 << 19)
# define NV40_VP_INST_SCA_WRITEMASK_Z (1 << 18)
# define NV40_VP_INST_SCA_WRITEMASK_W (1 << 17)
#define NV40_VP_INST_VEC_WRITEMASK_SHIFT 13
#define NV40_VP_INST_VEC_WRITEMASK_MASK (0xF << 13)
# define NV40_VP_INST_VEC_WRITEMASK_X (1 << 16)
# define NV40_VP_INST_VEC_WRITEMASK_Y (1 << 15)
# define NV40_VP_INST_VEC_WRITEMASK_Z (1 << 14)
# define NV40_VP_INST_VEC_WRITEMASK_W (1 << 13)
#define NV40_VP_INST_SCA_RESULT (1 << 12)
#define NV40_VP_INST_SCA_DEST_TEMP_SHIFT 7
#define NV40_VP_INST_SCA_DEST_TEMP_MASK (0x3F << 7)
#define NV40_VP_INST_DEST_SHIFT 2
#define NV40_VP_INST_DEST_MASK (31 << 2)
# define NV40_VP_INST_DEST_POS 0
# define NV40_VP_INST_DEST_COL0 1
# define NV40_VP_INST_DEST_COL1 2
# define NV40_VP_INST_DEST_BFC0 3
# define NV40_VP_INST_DEST_BFC1 4
# define NV40_VP_INST_DEST_FOGC 5
# define NV40_VP_INST_DEST_PSZ 6
# define NV40_VP_INST_DEST_TC0 7
# define NV40_VP_INST_DEST_TC(n) (7+n)
# define NV40_VP_INST_DEST_TEMP 0x1F
#define NV40_VP_INST_INDEX_CONST (1 << 1)
#define NV40_VP_INST3_KNOWN ( \
NV40_VP_INST_SRC2L_MASK |\
NV40_VP_INST_SCA_WRITEMASK_MASK |\
NV40_VP_INST_VEC_WRITEMASK_MASK |\
NV40_VP_INST_SCA_DEST_TEMP_MASK |\
NV40_VP_INST_DEST_MASK |\
NV40_VP_INST_INDEX_CONST)
/* Useful to split the source selection regs into their pieces */
#define NV40_VP_SRC0_HIGH_SHIFT 9
#define NV40_VP_SRC0_HIGH_MASK 0x0001FE00
#define NV40_VP_SRC0_LOW_MASK 0x000001FF
#define NV40_VP_SRC2_HIGH_SHIFT 11
#define NV40_VP_SRC2_HIGH_MASK 0x0001F800
#define NV40_VP_SRC2_LOW_MASK 0x000007FF
/* Source selection - these are the bits you fill NV40_VP_INST_SRCn with */
#define NV40_VP_SRC_NEGATE (1 << 16)
#define NV40_VP_SRC_SWZ_X_SHIFT 14
#define NV40_VP_SRC_SWZ_X_MASK (3 << 14)
#define NV40_VP_SRC_SWZ_Y_SHIFT 12
#define NV40_VP_SRC_SWZ_Y_MASK (3 << 12)
#define NV40_VP_SRC_SWZ_Z_SHIFT 10
#define NV40_VP_SRC_SWZ_Z_MASK (3 << 10)
#define NV40_VP_SRC_SWZ_W_SHIFT 8
#define NV40_VP_SRC_SWZ_W_MASK (3 << 8)
#define NV40_VP_SRC_SWZ_ALL_SHIFT 8
#define NV40_VP_SRC_SWZ_ALL_MASK (0xFF << 8)
#define NV40_VP_SRC_TEMP_SRC_SHIFT 2
#define NV40_VP_SRC_TEMP_SRC_MASK (0x1F << 2)
#define NV40_VP_SRC_REG_TYPE_SHIFT 0
#define NV40_VP_SRC_REG_TYPE_MASK (3 << 0)
# define NV40_VP_SRC_REG_TYPE_UNK0 0
# define NV40_VP_SRC_REG_TYPE_TEMP 1
# define NV40_VP_SRC_REG_TYPE_INPUT 2
# define NV40_VP_SRC_REG_TYPE_CONST 3
#include "nvfx_shader.h"
#endif
|
nevik-xx/psl1ght
|
tools/cgcomp/include/nv40_vertprog.h
|
C
|
mit
| 11,307
|
package com.github.ufologist.android;
import android.app.Activity;
import android.os.Bundle;
import com.umeng.analytics.MobclickAgent;
import com.umeng.message.PushAgent;
/**
* 基础Activity, 已经实现了友盟的session统计
*
* @author Sun
* @version 2015-01-09
*/
public class BaseActivity extends Activity {
private String activityName = "BaseActivity";
private static final String STATUS_ONRESUME = "onResume";
private static final String STATUS_ONPAUSE = "onPause";
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
this.activityName = getClass().getSimpleName();
analyseAppLaunch();
}
@Override
public void onResume() {
super.onResume();
analyseSession(STATUS_ONRESUME);
}
@Override
public void onPause() {
super.onPause();
analyseSession(STATUS_ONPAUSE);
}
/**
* 友盟消息推送服务需要统计应用启动数据
* 在所有的Activity 的onCreate 函数添加
* 注意: 如果不调用此方法,将会导致按照"几天不活跃"条件来推送失效。
*/
protected void analyseAppLaunch() {
PushAgent.getInstance(this).onAppStart();
}
/**
* session的统计
*
* @param status
*/
protected void analyseSession(String status) {
if (status.equals(STATUS_ONRESUME)) {
MobclickAgent.onResume(this);
} else {
MobclickAgent.onPause(this);
}
}
public String getOnlineConfigParam(String name) {
// 获取友盟在线参数, 会有延时或者说是缓存, 不是在页面上改了, 下次进app就会立马看见修改后的内容
return MobclickAgent.getConfigParams(this, name);
}
public String getActivityName() {
return this.activityName;
}
public void setActivityName(String activityName) {
this.activityName = activityName;
}
}
|
androidquickstart/androidquickstart
|
AndroidQuickStart/src/com/github/ufologist/android/BaseActivity.java
|
Java
|
mit
| 2,071
|
# Alert
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**level** | **str** | | [optional]
**info** | **str** | Extra information for an alert. | [optional]
**begin** | **float** | Start time of alert. | [optional]
**end** | **float** | End time of alert. | [optional]
**stream** | **int** | | [optional]
**detail** | **str** | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
|
Telestream/telestream-cloud-python-sdk
|
telestream_cloud_qc_sdk/docs/Alert.md
|
Markdown
|
mit
| 577
|
import { expect } from 'chai';
import { createTheme } from '@mui/material/styles';
import defaultTheme from './defaultTheme';
import responsiveFontSizes from './responsiveFontSizes';
describe('responsiveFontSizes', () => {
it('should support unitless line height', () => {
const defaultVariant = {
fontFamily: '"Roboto", "Helvetica", "Arial", sans-serif',
fontSize: '6rem',
fontWeight: 300,
letterSpacing: '-0.01562em',
lineHeight: 1,
};
const theme = createTheme({
typography: {
h1: defaultVariant,
},
});
const { typography } = responsiveFontSizes(theme);
expect(typography.h1).to.deep.equal({
...defaultVariant,
fontSize: '3.5rem',
[`@media (min-width:${defaultTheme.breakpoints.values.sm}px)`]: { fontSize: '4.75rem' },
[`@media (min-width:${defaultTheme.breakpoints.values.md}px)`]: { fontSize: '5.5rem' },
[`@media (min-width:${defaultTheme.breakpoints.values.lg}px)`]: {
fontSize: defaultVariant.fontSize,
},
});
});
it('should disable vertical alignment', () => {
const defaultVariant = {
fontFamily: '"Roboto", "Helvetica", "Arial", sans-serif',
fontSize: '6rem',
fontWeight: 300,
letterSpacing: '-0.01562em',
lineHeight: '6rem',
};
const theme = createTheme({
typography: {
h1: defaultVariant,
},
});
const { typography } = responsiveFontSizes(theme, {
disableAlign: true,
});
expect(typography.h1).to.deep.equal({
...defaultVariant,
fontSize: '3.5rem',
[`@media (min-width:${defaultTheme.breakpoints.values.sm}px)`]: { fontSize: '4.75rem' },
[`@media (min-width:${defaultTheme.breakpoints.values.md}px)`]: { fontSize: '5.375rem' },
[`@media (min-width:${defaultTheme.breakpoints.values.lg}px)`]: {
fontSize: defaultVariant.fontSize,
},
});
});
describe('when requesting a responsive typography with non unitless line height and alignment', () => {
it('should throw an error, as this is not supported', () => {
const theme = createTheme({
typography: {
h1: {
lineHeight: '6rem',
},
},
});
expect(() => {
responsiveFontSizes(theme);
}).toThrowMinified(
'MUI: Unsupported non-unitless line height with grid alignment.\n' +
'Use unitless line heights instead.',
);
});
});
});
|
oliviertassinari/material-ui
|
packages/mui-material/src/styles/responsiveFontSizes.test.js
|
JavaScript
|
mit
| 2,468
|
---
title: Integration
category: integration
authors: knesenko, mgoldboi, rafaelmartins, sandrobonazzola
wiki_category: Integration
wiki_title: Integration
wiki_revision_count: 10
wiki_last_updated: 2015-09-10
---
# Integration
## Who's in Integration team?
The members of the Integration team are
* Yedidyah Bar David (Didi)
* Doron Fediuck (Doron)
* [Sandro Bonazzola](https://github.com/sandrobonazzola)
* Simone Tiraboschi (Stirabos)
* Lev Veyde (Lveyde)
* Rafael Martins (RafaelMartins)
Outstanding contributors
* Alon Bar-Lev (Alonbl)
* Antoni Segura Puimedon (APuimedo)
* David Caro (Dcaroest)
* Juan Hernandez (juan)
## What does Integration team do?
Leads the following projects:
* oVirt Engine Setup
* oVirt DWH Setup
* oVirt Reports Setup
* oVirt Host Deploy
* oVirt Hosted Engine Setup
* oVirt Websoket Proxy Setup
* oVirt [Iso Uploader](/develop/developer-guide/engine/engine-tools/#ovirt-iso-uploader)
* oVirt [Image Uploader](/develop/developer-guide/engine/engine-tools/#engine-image-uploader)
* oVirt [Log Collector](/develop/developer-guide/engine/engine-tools/#ovirt-log-collector)
* oVirt [Releases](/develop/release-management/releases/) and [Release management](/Category:Release_management)
* [oVirt Live](/download/ovirt-live/)
* [oVirt Windows Guest Tools](/develop/release-management/features/engine/windows-guest-tools/)
* [oVirt Quality Assurance](/develop/projects/project-qa/)
* [OTOPI](/develop/developer-guide/engine/otopi/)
Collaborates with other communities / projects:
* [Fedora](https://getfedora.org/)
* [CentOS](http://centos.org/)
* [SOS](https://github.com/sosreport)
* [Sanlock](https://fedorahosted.org/sanlock/)
* [VDSM](/develop/developer-guide/vdsm/vdsm/)
* [Libvirt](http://libvirt.org/)
* [oVirt Continuous Integration / Infra](/develop/infra/infrastructure/)
* [Gluster](http://www.gluster.org/)
### How may I help?
* Fixing one of the [open bugs](https://bugzilla.redhat.com/buglist.cgi?quicksearch=product%3Aovirt%20whiteboard%3Aintegration%20status%3Anew) we have
* Testing one of the [bugs we fixed](https://bugzilla.redhat.com/buglist.cgi?quicksearch=product%3Aovirt%20whiteboard%3Aintegration%20status%3Amodifed%2Con_qa)
* Joining the [oVirt Quality Assurance](/develop/projects/project-qa/) effort
* Help porting oVirt to other distributions
|
rafaelmartins/ovirt-site
|
source/develop/projects/project-integration.html.md
|
Markdown
|
mit
| 2,383
|
<!doctype html>
<html class="no-js" lang="">
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<title></title>
<meta name="description" content="">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="apple-touch-icon" href="apple-touch-icon.png">
<!-- Place favicon.ico in the root directory -->
<link rel="stylesheet" href="css/normalize.css">
<link rel="stylesheet" href="css/main.css">
<script src="js/vendor/modernizr-2.8.3.min.js"></script>
</head>
<body>
<!--[if lt IE 8]>
<p class="browserupgrade">You are using an <strong>outdated</strong> browser. Please <a href="http://browsehappy.com/">upgrade your browser</a> to improve your experience.</p>
<![endif]-->
<!-- Add your site or application content here -->
<p>Hello Professor Williams! This is HTML5 Boilerplate.</p>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/{{JQUERY_VERSION}}/jquery.min.js"></script>
<script>window.jQuery || document.write('<script src="js/vendor/jquery-{{JQUERY_VERSION}}.min.js"><\/script>')</script>
<script src="js/plugins.js"></script>
<script src="js/main.js"></script>
<!-- Google Analytics: change UA-XXXXX-X to be your site's ID. -->
<script>
(function(b,o,i,l,e,r){b.GoogleAnalyticsObject=l;b[l]||(b[l]=
function(){(b[l].q=b[l].q||[]).push(arguments)});b[l].l=+new Date;
e=o.createElement(i);r=o.getElementsByTagName(i)[0];
e.src='https://www.google-analytics.com/analytics.js';
r.parentNode.insertBefore(e,r)}(window,document,'script','ga'));
ga('create','UA-XXXXX-X','auto');ga('send','pageview');
</script>
</body>
</html>
|
sn357/is117html5-
|
src/index.html
|
HTML
|
mit
| 1,869
|
## Description
The Segmentation filter transforms a volume data set into a segmented volume data set.
This filter uses the thresholding method for the segmentation.
>'The simplest thresholding methods replace each pixel in an image with a black pixel if the image intensity I_i,j is less than some fixed constant T (that is, I_i , j < T ), or a white pixel if the image intensity is greater than that constant.' [Thresholding on Wiki](<https://en.wikipedia.org/wiki/Thresholding_(image_processing)>)
For experienced users the thresholding can be performed with a set value. Alternatively the segmentation can be generated automaticly with the otsu-based thresholding.
### Manual thresholding
The manual thresholding requires a constant value as input from the user for the threshold.
### Otsu-based thresholding
By contrast to the manual thresholding the otsu-method generates an automatic value for the threshold.
>'In the simplest form, the algorithm returns a single intensity threshold that separate pixels into two classes, foreground and background. This threshold is determined by minimizing intra-class intensity variance, or equivalently, by maximizing inter-class variance.' [Otu's Method on Wiki](https://en.wikipedia.org/wiki/Otsu's_Method)
### Negate Output
The negate-output function inverts the calculation of the data, resulting into a negated output.
Source Code:
```outputBuffer.array[:] = (threshold > inputArray[:]) if negateOutput else (threshold <= inputArray[:])```
An example is shown below. On the left side a normal segmentated suprise egg with the otsu method and on the right side the same setup with the negated output function.
 
|
voxie-viewer/voxie
|
doc/prototype/de.uni_stuttgart.Voxie.Filter.BinarySegmentation.md
|
Markdown
|
mit
| 1,750
|
# This code is supporting material for the book
# Building Machine Learning Systems with Python
# by Willi Richert and Luis Pedro Coelho
# published by PACKT Publishing
#
# It is made available under the MIT License
from load import load_dataset
import numpy as np
from threshold import learn_model, apply_model, accuracy
features, labels = load_dataset('seeds')
# Turn the labels into a binary array
labels = (labels == 'Canadian')
error = 0.0
for fold in range(10):
training = np.ones(len(features), bool)
# numpy magic to make an array with 10% of 0s starting at fold
training[fold::10] = 0
# whatever is not training is for testing
testing = ~training
model = learn_model(features[training], labels[training])
test_error = accuracy(features[testing], labels[testing], model)
error += test_error
error /= 10.0
print('Ten fold cross-validated error was {0:.1%}.'.format(error))
|
krahman/BuildingMachineLearningSystemsWithPython
|
ch02/seeds_threshold.py
|
Python
|
mit
| 921
|
import * as THREE from 'three';
import PropTypes from 'prop-types';
import MaterialDescriptorBase from './MaterialDescriptorBase';
class LineBasicMaterialDescriptor extends MaterialDescriptorBase {
constructor(react3RendererInstance) {
super(react3RendererInstance);
this.hasColor();
this.hasProp('linewidth', {
type: PropTypes.number,
simple: true,
default: 1,
});
// what are these properties used for?
[
'linecap',
'linejoin',
].forEach((propName) => {
this.hasProp(propName, {
type: PropTypes.oneOf([
'round',
]),
simple: true,
default: 'round',
});
});
this.hasProp('fog', {
type: PropTypes.bool,
update(threeObject, fog, existsInProps) {
if (existsInProps) {
threeObject.fog = fog;
}
threeObject.needsUpdate = true;
},
updateInitial: true,
default: true,
});
}
construct(props) {
const materialDescription = this.getMaterialDescription(props);
return new THREE.LineBasicMaterial(materialDescription);
}
}
module.exports = LineBasicMaterialDescriptor;
|
toxicFork/react-three-renderer
|
src/lib/descriptors/Material/LineBasicMaterialDescriptor.js
|
JavaScript
|
mit
| 1,171
|
#!/usr/bin/env node
var util = require('util'),
http = require('http'),
fs = require('fs'),
url = require('url'),
events = require('events');
var DEFAULT_PORT = 8123;
function main(argv) {
new HttpServer({
'GET': createServlet(StaticServlet),
'HEAD': createServlet(StaticServlet)
}).start(Number(argv[2]) || DEFAULT_PORT);
}
function escapeHtml(value) {
return value.toString().
replace('<', '<').
replace('>', '>').
replace('"', '"');
}
function createServlet(Class) {
var servlet = new Class();
return servlet.handleRequest.bind(servlet);
}
/**
* An Http server implementation that uses a map of methods to decide
* action routing.
*
* @param {Object} Map of method => Handler function
*/
function HttpServer(handlers) {
this.handlers = handlers;
this.server = http.createServer(this.handleRequest_.bind(this));
}
HttpServer.prototype.start = function(port) {
this.port = port;
this.server.listen(port);
util.puts('Http Server running at http://localhost:' + port + '/');
};
HttpServer.prototype.parseUrl_ = function(urlString) {
var parsed = url.parse(urlString);
parsed.pathname = url.resolve('/', parsed.pathname);
return url.parse(url.format(parsed), true);
};
HttpServer.prototype.handleRequest_ = function(req, res) {
var logEntry = req.method + ' ' + req.url;
if (req.headers['user-agent']) {
logEntry += ' ' + req.headers['user-agent'];
}
util.puts(logEntry);
req.url = this.parseUrl_(req.url);
var handler = this.handlers[req.method];
if (!handler) {
res.writeHead(501);
res.end();
} else {
handler.call(this, req, res);
}
};
/**
* Handles static content.
*/
function StaticServlet() {}
StaticServlet.MimeMap = {
'txt': 'text/plain',
'html': 'text/html',
'css': 'text/css',
'xml': 'application/xml',
'json': 'application/json',
'js': 'application/javascript',
'jpg': 'image/jpeg',
'jpeg': 'image/jpeg',
'gif': 'image/gif',
'png': 'image/png',
'svg': 'image/svg+xml'
};
StaticServlet.prototype.handleRequest = function(req, res) {
var self = this;
var path = ('./' + req.url.pathname).replace('//','/').replace(/%(..)/g, function(match, hex){
return String.fromCharCode(parseInt(hex, 16));
});
var parts = path.split('/');
if (parts[parts.length-1].charAt(0) === '.')
return self.sendForbidden_(req, res, path);
fs.stat(path, function(err, stat) {
if (err)
return self.sendMissing_(req, res, path);
if (stat.isDirectory())
return self.sendDirectory_(req, res, path);
return self.sendFile_(req, res, path);
});
}
StaticServlet.prototype.sendError_ = function(req, res, error) {
res.writeHead(500, {
'Content-Type': 'text/html'
});
res.write('<!doctype html>\n');
res.write('<title>Internal Server Error</title>\n');
res.write('<h1>Internal Server Error</h1>');
res.write('<pre>' + escapeHtml(util.inspect(error)) + '</pre>');
util.puts('500 Internal Server Error');
util.puts(util.inspect(error));
};
StaticServlet.prototype.sendMissing_ = function(req, res, path) {
path = path.substring(1);
res.writeHead(404, {
'Content-Type': 'text/html'
});
res.write('<!doctype html>\n');
res.write('<title>404 Not Found</title>\n');
res.write('<h1>Not Found</h1>');
res.write(
'<p>The requested URL ' +
escapeHtml(path) +
' was not found on this server.</p>'
);
res.end();
util.puts('404 Not Found: ' + path);
};
StaticServlet.prototype.sendForbidden_ = function(req, res, path) {
path = path.substring(1);
res.writeHead(403, {
'Content-Type': 'text/html'
});
res.write('<!doctype html>\n');
res.write('<title>403 Forbidden</title>\n');
res.write('<h1>Forbidden</h1>');
res.write(
'<p>You do not have permission to access ' +
escapeHtml(path) + ' on this server.</p>'
);
res.end();
util.puts('403 Forbidden: ' + path);
};
StaticServlet.prototype.sendRedirect_ = function(req, res, redirectUrl) {
res.writeHead(301, {
'Content-Type': 'text/html',
'Location': redirectUrl
});
res.write('<!doctype html>\n');
res.write('<title>301 Moved Permanently</title>\n');
res.write('<h1>Moved Permanently</h1>');
res.write(
'<p>The document has moved <a href="' +
redirectUrl +
'">here</a>.</p>'
);
res.end();
util.puts('301 Moved Permanently: ' + redirectUrl);
};
StaticServlet.prototype.sendFile_ = function(req, res, path) {
var self = this;
var file = fs.createReadStream(path);
res.writeHead(200, {
'Content-Type': StaticServlet.
MimeMap[path.split('.').pop()] || 'text/plain'
});
if (req.method === 'HEAD') {
res.end();
} else {
file.on('data', res.write.bind(res));
file.on('close', function() {
res.end();
});
file.on('error', function(error) {
self.sendError_(req, res, error);
});
}
};
StaticServlet.prototype.sendDirectory_ = function(req, res, path) {
var self = this;
if (path.match(/[^\/]$/)) {
req.url.pathname += '/';
var redirectUrl = url.format(url.parse(url.format(req.url)));
return self.sendRedirect_(req, res, redirectUrl);
}
fs.readdir(path, function(err, files) {
if (err)
return self.sendError_(req, res, error);
if (!files.length)
return self.writeDirectoryIndex_(req, res, path, []);
var remaining = files.length;
files.forEach(function(fileName, index) {
fs.stat(path + '/' + fileName, function(err, stat) {
if (err)
return self.sendError_(req, res, err);
if (stat.isDirectory()) {
files[index] = fileName + '/';
}
if (!(--remaining))
return self.writeDirectoryIndex_(req, res, path, files);
});
});
});
};
StaticServlet.prototype.writeDirectoryIndex_ = function(req, res, path, files) {
path = path.substring(1);
res.writeHead(200, {
'Content-Type': 'text/html'
});
if (req.method === 'HEAD') {
res.end();
return;
}
res.write('<!doctype html>\n');
res.write('<title>' + escapeHtml(path) + '</title>\n');
res.write('<style>\n');
res.write(' ol { list-style-type: none; font-size: 1.2em; }\n');
res.write('</style>\n');
res.write('<h1>Directory: ' + escapeHtml(path) + '</h1>');
res.write('<ol>');
files.forEach(function(fileName) {
if (fileName.charAt(0) !== '.') {
res.write('<li><a href="' +
escapeHtml(fileName) + '">' +
escapeHtml(fileName) + '</a></li>');
}
});
res.write('</ol>');
res.end();
};
// Must be last,
main(process.argv);
|
a5hik/angular-highcharts
|
scripts/web-server.js
|
JavaScript
|
mit
| 6,556
|
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
<title>datagram_socket_service::native</title>
<link rel="stylesheet" href="../../../boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.75.2">
<link rel="home" href="../../../index.html" title="Asio">
<link rel="up" href="../datagram_socket_service.html" title="datagram_socket_service">
<link rel="prev" href="move_construct.html" title="datagram_socket_service::move_construct">
<link rel="next" href="native_handle.html" title="datagram_socket_service::native_handle">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr><td valign="top"><img alt="asio C++ library" width="250" height="60" src="../../../asio.png"></td></tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="move_construct.html"><img src="../../../prev.png" alt="Prev"></a><a accesskey="u" href="../datagram_socket_service.html"><img src="../../../up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../home.png" alt="Home"></a><a accesskey="n" href="native_handle.html"><img src="../../../next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h4 class="title">
<a name="asio.reference.datagram_socket_service.native"></a><a class="link" href="native.html" title="datagram_socket_service::native">datagram_socket_service::native</a>
</h4></div></div></div>
<p>
<a class="indexterm" name="idp129540816"></a>
(Deprecated: Use <code class="computeroutput"><span class="identifier">native_handle</span><span class="special">()</span></code>.) Get the native socket implementation.
</p>
<pre class="programlisting"><span class="identifier">native_type</span> <span class="identifier">native</span><span class="special">(</span>
<span class="identifier">implementation_type</span> <span class="special">&</span> <span class="identifier">impl</span><span class="special">);</span>
</pre>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright © 2003-2014 Christopher M. Kohlhoff<p>
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
</p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="move_construct.html"><img src="../../../prev.png" alt="Prev"></a><a accesskey="u" href="../datagram_socket_service.html"><img src="../../../up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../home.png" alt="Home"></a><a accesskey="n" href="native_handle.html"><img src="../../../next.png" alt="Next"></a>
</div>
</body>
</html>
|
dhh1128/intent
|
old/src/external/asio-1.10.2/doc/asio/reference/datagram_socket_service/native.html
|
HTML
|
mit
| 2,959
|
# -*- coding: utf8 -*-
import re
from unidecode import unidecode
import os, sys
from hashlib import md5 as hasher
import binascii
import settings
def gen_flattened_list(iterables):
for item in iterables:
if hasattr(item, '__iter__'):
for i in item:
yield i
else:
yield item
def crc32(val):
return binascii.crc32(val) & 0xffffffff
# brennan added this
def wrap(text, width):
"""
A word-wrap function that preserves existing line breaks
and most spaces in the text. Expects that existing line
breaks are posix newlines (\n).
"""
return reduce(lambda line, word, width=width: '%s%s%s' %
(line,
' \n'[(len(line)-line.rfind('\n')-1
+ len(word.split('\n',1)[0]
) >= width)],
word),
text.split(' ')
)
_punct_re = re.compile(r'[\t !"#$%&\'()*\-/<=>?@\[\\\]^_`{|},.;:]+')
htmlCodes = (
('&', '&'),
('<', '<'),
('>', '>'),
('"', '"'),
(''', "'"),
)
def escape_html(s):
for bad, good in htmlCodes:
s = s.replace(bad, good)
return s
def slugify(text, delim='', lowercase=True):
"""ex: slugify(u'Шамиль Абетуллаев','')
returns u'shamilabetullaev'"""
text = escape_html(text)
result = []
if lowercase:
text=text.lower()
for word in _punct_re.split(text):
decoded = _punct_re.split(unidecode(word))
result.extend(decoded)
result = unicode(delim.join(result))
return result.lower() if lowercase else result
def salted_hash(val):
hash = hasher(settings.CRYPTO_SECRET)
hash.update(unicode(val, 'utf-8') if isinstance(val, str) else unicode(val))
return hash.hexdigest()
|
jumoconnect/openjumo
|
jumodjango/etc/func.py
|
Python
|
mit
| 1,840
|
<!DOCTYPE html>
<html lang="ko">
<head>
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="viewport" content="width=device-width">
<title>Junshoong의 기술블로그 - ssh tag</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta.2/css/bootstrap.min.css" integrity="sha384-PsH8R72JQ3SOdhVi3uxftmaW6Vc51MKb0q5P2rRUpPvrszuE4W1povHYgTpBfshb" crossorigin="anonymous">
<link rel="stylesheet" href="../../theme/css/pygment.css" />
<link rel="stylesheet" href="../../theme/css/style.css" />
<link rel="alternate" type="application/rss+xml" title="RSS" href="/atom.xml">
</head>
<body>
<div class="container-fluid">
<div class="row justify-content-start sticky-top header">
<div class="col-1 header-img">
<img class="profile-img" src="../../images/profile.png">
</div>
<div class="col header-title">
<h2 class="sitename"><a href="../.."> Junshoong의 기술블로그 </a></h2>
</div>
</div> <div class="row justify-content-around">
<div class="col-md-8 content">
<div class="posts">
<div class="post">
<h1 class="post-title">
<a href="../../linux/linux-sshfs-share/">[Linux] sshfs로 리눅스간 디렉터리 공유하기</a>
</h1>
<span class="post-date">2015-11-17, Tue</span>
<p>
<p>집에 있는 리눅스 데스크톱과 디렉터리를 공유하고 싶다. 그래서 조금 찾아봤더니 sshfs라는 방법이 있다.</p>
<p>ssh 연결을 기반으로 하기 때문에 일단 ssh …</p>
</p>
</div>
</div>
</div>
<div class="col-md-3 sidebar">
<div class="list-group category">
<div class="list-group-item list-group-item-primary"> Category </div>
<a class="list-group-item list-group-item-action category-item" href="../../agile/">
Agile
<span class="category-item-count">(2)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../angular/">
Angular
<span class="category-item-count">(1)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../blog/">
Blog
<span class="category-item-count">(3)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../book/">
Book
<span class="category-item-count">(3)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../css/">
CSS
<span class="category-item-count">(1)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../ctf/">
CTF
<span class="category-item-count">(4)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../devops/">
DevOps
<span class="category-item-count">(2)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../django/">
Django
<span class="category-item-count">(6)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../docker/">
Docker
<span class="category-item-count">(2)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../editor/">
Editor
<span class="category-item-count">(3)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../english/">
English
<span class="category-item-count">(2)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../etc/">
ETC
<span class="category-item-count">(11)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../game/">
Game
<span class="category-item-count">(2)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../git/">
Git
<span class="category-item-count">(2)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../life/">
Life
<span class="category-item-count">(22)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../linux/">
Linux
<span class="category-item-count">(19)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../mac/">
Mac
<span class="category-item-count">(1)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../movie/">
Movie
<span class="category-item-count">(1)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../nginx/">
Nginx
<span class="category-item-count">(2)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../pelican/">
Pelican
<span class="category-item-count">(1)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../python/">
Python
<span class="category-item-count">(8)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../regex/">
Regex
<span class="category-item-count">(1)</span>
</a>
<a class="list-group-item list-group-item-action category-item" href="../../shell/">
Shell
<span class="category-item-count">(2)</span>
</a>
</div>
<div class="list-group social">
<div class="list-group-item list-group-item-primary"> Social </div>
<a class="list-group-item list-group-item-action" href="mailto:junshoong@gmail.com"> email </a>
<a class="list-group-item list-group-item-action" href="https://www.facebook.com/vaporize93"> facebook </a>
<a class="list-group-item list-group-item-action" href="https://www.linkedin.com/in/junshoong"> linkedin </a>
<a class="list-group-item list-group-item-action" href="https://www.slideshare.net/junshoong"> slideshare </a>
<a class="list-group-item list-group-item-action" href="https://github.com/junshoong"> github </a>
<a class="list-group-item list-group-item-action" href="https://www.stackoverflow.com/users/4466697/junsu-kim"> stack-overflow </a>
<a class="list-group-item list-group-item-action" href=""> FEED </a>
</div>
</div> </div>
</div>
</body>
</html>
|
vaporize93/blog
|
tag/ssh/index.html
|
HTML
|
mit
| 7,067
|
export * from './other-person-profile.component'
|
Directive14/HolidayAdvisor
|
src/app/page-components/other-person-profile/index.ts
|
TypeScript
|
mit
| 49
|
namespace $ {
export function $mol_dom_render_attributes (
el : Element ,
attrs : { [ key : string ] : string|number|boolean|null }
) {
for( let name in attrs ) {
let val = attrs[ name ] as any
if( val === null || val === false ) {
if( !el.hasAttribute( name ) ) continue
el.removeAttribute( name )
} else {
const str = String( val )
if( el.getAttribute( name ) === str ) continue
el.setAttribute( name , str )
}
}
}
}
|
eigenmethod/mol
|
dom/render/attributes/attributes.ts
|
TypeScript
|
mit
| 489
|
<?php
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateImagesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
//
Schema::create('images', function (Blueprint $table) {
$table->increments('id');
$table->string('image');
$table->rememberToken();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
//
Schema::dropIfExists('images');
}
}
|
abhisheksharma14/laravel-crud
|
database/migrations/2017_07_19_162546_create_images_table.php
|
PHP
|
mit
| 685
|
<style>
/*
stats card
*/
.count, .label {
z-index: 1 !important;
}
.chart-stats-card {
display:block;
position:relative;
overflow:hidden;
}
.chart-stats-card i {
position:absolute;
font-size:6rem;
right:0;
bottom:-1rem;
}
.chart-stats-card .count {
position:relative;
font-weight:100;
font-size:2.1rem;
line-height:2.1rem;
}
.chart-stats-card .label {
position:relative;
font-weight:100;
font-size:1.2rem;
line-height:1.2rem;
color:#757575;
}
.chart-stats-card .name {
position:relative;
font-weight:300;
font-size:1.1rem;
line-height:1.1rem;
}
table.flood-forecast-chart-legend thead {
border-bottom: none;
}
table.flood-forecast-chart-legend td {
padding: 5px;
}
</style>
<!-- row -->
<div class="row" ng-show="highchart.label.center.label.label === 0">
<div class="col s6">
<!-- chart with zero -->
<div ng-show="highchart.label.center.label.label === 0">
<div class="count" style="text-align:center; width:100%; height:100%; position:absolute; top:70px; padding-top:6%; font-size:5.6rem;">
0
</div>
<div id="subLabel-center-{{highchart.id}}" class="label"
style="text-align:center; width:100%; height:100%; position:absolute; top:140px; padding-top:6%;">
<span>ZERO {{ highchart.title.text }}</span>
</div>
</div>
</div>
</div>
<div class="row" ng-show="highchart.label.center.label.label !== 0">
<!-- title -->
<div ng-if="highchart.title.text"
align="{{ highchart.title.align }}"
style="{{ highchart.title.style }}">{{ highchart.title.text }}</div>
<!-- column -->
<div class="col s4" style="padding-left:40px;">
<!-- table -->
<table class="highlight flood-forecast-chart-legend" height="120px;">
<tr ng-repeat="row in highchart.table.data" style="cursor: pointer; cursor: hand;">
<td style="background-color:{{ row.color }};" width="10%"> </td>
<td style="padding-left: 20px;">{{ row.name }}</td>
<td>{{ row.value | number }}</td>
</tr>
</table>
</div>
<!-- column -->
<div class="col s2">
<!-- chart with data -->
<div ng-show="highchart.label.center.label.label !==0 ">
<div id="{{highchart.id}}" align="{{ highchart.align }}" ng-if="highchart.chartConfig">
<!-- label -->
<div id="label-center-{{highchart.id}}" class="count"
style="text-align:center; width: 70%; height: 100%; position:absolute; top:85px; padding-top:6%;">
{{ highchart.label.center.label.prefix }}
<span
value="{{ highchart.label.center.label.from }}"
ng-count-to="{{ highchart.label.center.label.label }}"
duration="{{ highchart.label.center.label.duration }}"
filter="{{ highchart.label.center.label.filter }}"
params="{{ highchart.label.center.label.params }}"
fraction-size="{{ highchart.label.center.label.fractionSize }}">
</span>{{ highchart.label.center.label.postfix }}
</div>
<!-- sublabel -->
<div id="subLabel-center-{{highchart.id}}" class="label"
style="text-align:center; width:70%; height:100%; position:absolute; top:120px; padding-top:6%;">
<span>{{ highchart.label.center.subLabel.label }}</span>
</div>
<highchart config="highchart.chartConfig"
style="text-align:center; width:70%; height:100%; position:absolute; top:30px; padding-top:6%;"></highchart>
</div>
</div>
</div>
</div>
|
pfitzpaddy/ngm-reportHub
|
app/scripts/widgets/ngm-highchart/template/flood-forecast.html
|
HTML
|
mit
| 3,772
|
GCCARGS = -g -Wall -Werror
all: lisp
lisp: main.o eval.c builtins.o parse.o tokenize.o sequence.o object.o util.o dictionary.o
gcc ${GCCARGS} -lreadline -o $@ $^
main.o: main.c parse.h object.h tokenize.h eval.h util.h
gcc ${GCCARGS} -c -o $@ $<
eval.o: eval.c eval.h builtins.h object.h
gcc ${GCCARGS} -c -o $@ $<
builtins.o: builtins.c builtins.h object.h dictionary.h
gcc ${GCCARGS} -c -o $@ $<
parse.o: parse.c parse.h object.h tokenize.h
gcc ${GCCARGS} -c -o $@ $<
tokenize.o: tokenize.c tokenize.h
gcc ${GCCARGS} -c -o $@ $<
sequence.o: sequence.c sequence.h
gcc ${GCCARGS} -c -o $@ $<
object.o: object.c object.h
gcc ${GCCARGS} -c -o $@ $<
util.o: util.c util.h
gcc ${GCCARGS} -c -o $@ $<
dictionary.o: dictionary.c dictionary.h object.h
gcc ${GCCARGS} -c -o $@ $<
clean:
rm -f lisp *.o
.PHONY: all clean
|
ids1024/idslisp
|
Makefile
|
Makefile
|
mit
| 836
|
package compression
import (
c "gopkg.in/h2non/gentleman.v2/context"
p "gopkg.in/h2non/gentleman.v2/plugin"
"net/http"
)
// Disable disables the authorization basic header in the outgoing request
func Disable() p.Plugin {
return p.NewRequestPlugin(func(ctx *c.Context, h c.Handler) {
// Assert http.Transport to work with the instance
transport, ok := ctx.Client.Transport.(*http.Transport)
if !ok {
h.Next(ctx)
return
}
// Override the http.Client transport
transport.DisableCompression = true
ctx.Client.Transport = transport
h.Next(ctx)
})
}
|
h2non/gentleman
|
plugins/compression/compression.go
|
GO
|
mit
| 576
|
-- @docclass Player
PlayerStates = {
None = 0,
Poison = 1,
Burn = 2,
Energy = 4,
Drunk = 8,
Manashield = 16,
Paralyze = 32,
Haste = 64,
Swords = 128,
Drowning = 256,
Freezing = 512,
Dazzled = 1024,
Cursed = 2048,
PartyBuff = 4096,
PzBlock = 8192,
Pz = 16384,
Bleeding = 32768,
Hungry = 65536
}
InventorySlotOther = 0
InventorySlotHead = 1
InventorySlotNeck = 2
InventorySlotBack = 3
InventorySlotBody = 4
InventorySlotRight = 5
InventorySlotLeft = 6
InventorySlotLeg = 7
InventorySlotFeet = 8
InventorySlotFinger = 9
InventorySlotAmmo = 10
InventorySlotFinger2 = 11
InventorySlotBelt = 12
InventorySlotPurse = 13
InventorySlotFirst = 1
InventorySlotLast = 12
function Player:isPartyLeader()
local Pshield = self:getPshield()
return (Pshield == pshieldWhiteYellow or
Pshield == pshieldYellow or
Pshield == pshieldYellowSharedExp or
Pshield == pshieldYellowNoSharedExpBlink or
Pshield == pshieldYellowNoSharedExp)
end
function Player:isPartyMember()
local Pshield = self:getPshield()
return (Pshield == pshieldWhiteYellow or
Pshield == pshieldYellow or
Pshield == pshieldYellowSharedExp or
Pshield == pshieldYellowNoSharedExpBlink or
Pshield == pshieldYellowNoSharedExp or
Pshield == pshieldBlueSharedExp or
Pshield == pshieldBlueNoSharedExpBlink or
Pshield == pshieldBlueNoSharedExp or
Pshield == pshieldBlue)
end
function Player:isPartySharedExperienceActive()
local Pshield = self:getPshield()
return (Pshield == pshieldYellowSharedExp or
Pshield == pshieldYellowNoSharedExpBlink or
Pshield == pshieldYellowNoSharedExp or
Pshield == pshieldBlueSharedExp or
Pshield == pshieldBlueNoSharedExpBlink or
Pshield == pshieldBlueNoSharedExp)
end
function Player:hasVip(creatureName)
for id, vip in pairs(g_game.getVips()) do
if (vip[1] == creatureName) then return true end
end
return false
end
function Player:isMounted()
local outfit = self:getOutfit()
return outfit.mount ~= nil and outfit.mount > 0
end
function Player:toggleMount()
if g_game.getFeature(GamePlayerMounts) then
g_game.mount(not self:isMounted())
end
end
function Player:mount()
if g_game.getFeature(GamePlayerMounts) then
g_game.mount(true)
end
end
function Player:dismount()
if g_game.getFeature(GamePlayerMounts) then
g_game.mount(false)
end
end
function Player:getItem(itemid)
for i=InventorySlotFirst,InventorySlotLast do
local item = self:getInventoryItem(i)
if item and item:getId() == itemid then
return item
end
end
for i, container in pairs(g_game.getContainers()) do
for j, item in pairs(container:getItems()) do
if item:getId() == itemid then
item.container = container
return item
end
end
end
return items
end
function Player:getItems(itemid)
local items = {}
for i=InventorySlotFirst,InventorySlotLast do
local item = self:getInventoryItem(i)
if item and item:getId() == itemid then
table.insert(items, item)
end
end
for i, container in pairs(g_game.getContainers()) do
for j, item in pairs(container:getItems()) do
if item:getId() == itemid then
item.container = container
table.insert(items, item)
end
end
end
return items
end
function Player:getItemsCount(itemid)
local items, count = self:getItems(itemid), 0
for i=1,#items do
count = count + items[i]:getCount()
end
return count
end
function Player:hasState(_state, states)
if not states then
states = self:getStates()
end
for i = 1, 32 do
local pow = math.pow(2, i-1)
if pow > states then break end
local states = bit32.band(states, pow)
if states == _state then
return true
end
end
return false
end
|
Flatlander57/TheImaginedOTClient
|
modules/gamelib/player.lua
|
Lua
|
mit
| 3,889
|
/* eslint-env mocha */
const path = require('path');
const should = require('should');
const { openDb, closeDb } = require('../../lib/db');
const gtfs = require('../..');
const config = {
agencies: [{
agency_key: 'caltrain',
path: path.join(__dirname, '../fixture/caltrain_20160406.zip')
}],
verbose: false
};
describe('gtfs.getLevels():', () => {
before(async () => {
await openDb(config);
await gtfs.import(config);
});
after(async () => {
await closeDb();
});
it('should return empty array if no levels', async () => {
const levelId = 'not_real';
const results = await gtfs.getLevels({
level_id: levelId
});
should.exists(results);
results.should.have.length(0);
});
});
|
brendannee/node-gtfs
|
test/mocha/gtfs.get-levels.js
|
JavaScript
|
mit
| 745
|
using System.Collections.Generic;
using System.Threading;
using System.Threading.Tasks;
using TypedRest.Endpoints.Rpc;
namespace TypedRest.CommandLine.Commands.Rpc
{
/// <summary>
/// Command operating on an <see cref="IProducerEndpoint{TResult}"/>.
/// </summary>
/// <typeparam name="TResult">The type of entity the <see cref="IProducerEndpoint{TResult}"/> returns as a result.</typeparam>
public class ProducerCommand<TResult> : EndpointCommand<IProducerEndpoint<TResult>>
{
/// <summary>
/// Creates a new REST function command.
/// </summary>
/// <param name="endpoint">The endpoint this command operates on.</param>
public ProducerCommand(IProducerEndpoint<TResult> endpoint)
: base(endpoint)
{}
protected override async Task ExecuteInnerAsync(IReadOnlyList<string> args, CancellationToken cancellationToken = default)
=> OutputEntity(await Endpoint.InvokeAsync(cancellationToken));
/// <summary>
/// Outputs a <typeparamref name="TResult"/> to the user via the console.
/// </summary>
protected virtual void OutputEntity(TResult entity)
=> Console.Write(entity);
}
}
|
1and1/TypedRest-DotNet
|
src/TypedRest.CommandLine/Commands/Rpc/ProducerCommand.cs
|
C#
|
mit
| 1,232
|
import Model.Model;
import org.easymock.EasyMock;
import static org.easymock.EasyMock.expect;
import org.junit.Test;
/**
*
* @author prash_000
*/
public class UpdateUserTest {
public UpdateUserTest() {
}
@Test
public void aUserIsCorrectlyUpdated() {
Model model = EasyMock.createMock(Model.class);
expect(model.updateUser("T13", "Test Name","Mid Name","Test",20,'M',"1234567891",12
)).andReturn(1);
}
@Test
public void aUserIsNotFound() {
Model model = EasyMock.createMock(Model.class);
expect(model.updateUser("T14", "Test Name","Mid Name","Test",20,'M',"1234567891",12
)).andReturn(0);
}
}
|
prashantban/Java-Spark-FTL
|
src/test/java/UpdateUserTest.java
|
Java
|
mit
| 737
|
(function($) {
var UserInputView = Backbone.View.extend({
el : '#UserInput',
initialize : function() {
this.helloListView = new HelloListView();
},
events : {
'click button' : 'addToHelloCollection'
},
addToHelloCollection : function(e) {
var hello = new Hello({
name : this.$('input').val()
});
this.helloListView.collection.add(hello);
}
});
var Hello = Backbone.Model.extend({
initialize : function() {
this.name = 'name'
}
});
var HelloView = Backbone.View.extend({
tagName : 'li',
render : function() {
$(this.el).html('Hello ' + this.model.get('name'));
return this;
}
});
var HelloList = Backbone.Collection.extend({
model : Hello
});
var HelloListView = Backbone.View.extend({
el : '#HelloList',
initialize : function() {
_.bindAll(this, 'render', 'appendToHelloUL');
this.collection = new HelloList();
this.collection.bind('add', this.appendToHelloUL);
},
render:function(){
$.each(this.collection.models, function(i, helloModel){
self.appendToHelloUL(helloModel);
});
},
appendToHelloUL : function(helloModel) {
var helloView = new HelloView({
model : helloModel
});
$(this.el).append(helloView.render().el);
}
});
new UserInputView();
})(jQuery);
|
jesuscuesta/Backbone
|
01.- Vistas/01.- Ejemplo inicial. Algo complicado/hello.js
|
JavaScript
|
mit
| 1,636
|
<!DOCTYPE html>
<html class="no-js" lang="en-US">
<head>
<meta charset="utf8">
<meta name="viewport" content="width=device-width, height=device-height, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<title>Wedding</title>
<link href='http://fonts.googleapis.com/css?family=Josefin+Sans&subset=latin,latin-ext' rel='stylesheet' type='text/css'>
<link href='http://fonts.googleapis.com/css?family=Great+Vibes' rel='stylesheet' type='text/css'>
<link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/css/bootstrap.min.css">
<link rel="stylesheet" href="http://yui.yahooapis.com/pure/0.5.0/pure-min.css">
<link href="http://nmcapule.github.io/kg/static/css/main.css" rel="stylesheet">
<link href="http://nmcapule.github.io/kg/static/css/ribbon.css" rel="stylesheet">
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script>
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.2.0/js/bootstrap.min.js"></script>
</head>
<body lang="en">
<div class="site-wrapper">
<div class="header">
<div class="header-content">
Kimi Go
<div class="header-subtitle">
One Stop Wedding Shop
</div>
</div>
</div>
<div id="home-menu" class="pure-menu pure-menu-open pure-menu-horizontal">
<a href="#" class="pure-menu-heading">WEDDING KIMI GO</a>
<a class="nav-button-burger" id="nav-button">
<i class="fa fa-navicon fa"></i>
</a>
<ul id="mainnav">
<li>
<a href="http://nmcapule.github.io/kg/">
<span>Home</span>
</a>
<li>
<a href="http://nmcapule.github.io/kg/about/">
<span>About</span>
</a>
<li>
<a href="http://nmcapule.github.io/kg/gallery/">
<span>Gallery</span>
</a>
<li>
<a href="http://nmcapule.github.io/kg/events/">
<span>Events</span>
</a>
<li>
<a href="http://nmcapule.github.io/kg/blog/">
<span>Blog</span>
</a>
<li>
<a href="http://nmcapule.github.io/kg/contactus/">
<span>Contact Us</span>
</a>
</ul>
</div>
<script type="text/javascript">
$('.nav-button-burger').click(function () {
$('#home-menu ul').toggle();
});
if ($('.nav-button-burger').css('visibility') == 'visible')
$('#home-menu ul').hide();
$(window).resize(function () {
$('#home-menu ul').show();
if ($('.nav-button-burger').css('visibility') == 'visible')
$('#home-menu ul').hide();
});
$(window).scroll(function() {
var top = window.pageXOffset ? window.pageXOffset :
document.documentElement.scrollTop ?
document.documentElement.scrollTop : document.body.scrollTop;
if (top > 300) {
$('#home-menu').addClass('pure-menu-fixed');
} else {
$('#home-menu').removeClass('pure-menu-fixed');
}
});
</script>
<hr/>
<div class="content-header">
<h1 class="content-title">Wedding</h1>
</div>
<section id="main" class="content-wrapper">
<ul id="content-list">
<div class="post">
<div class="post-title">
<h2>
<a href="http://nmcapule.github.io/kg/contactus/">
Contact Us
</a>
</h2>
<div class="post-meta">Sat, Sep 20, 2014 </div>
</div>
<div class="post-summary">
</div>
</div>
<div class="post">
<div class="post-title">
<h2>
<a href="http://nmcapule.github.io/kg/blog/second-entry/">
SM Novaliches Bridal Exhibit
</a>
</h2>
<div class="post-meta">Fri, Sep 19, 2014 </div>
</div>
<div class="post-summary">
SM Novaliches Bridal Exhibit PHILTRADE Exhibits was established in 2000 with the objective of supporting the Filipino enterprises through trade promotion like exhibitions, trade shows and special trade events. For the last decade, it has done thematic exhibitions and has worked with organizations and associations all over the Philippines and abroad. As an event management company, we believe that you can capture your public’s and stakeholders through careful analysis and strategic execution of your marketing tools.
</div>
</div>
<div class="post">
<div class="post-title">
<h2>
<a href="http://nmcapule.github.io/kg/blog/first-entry/">
blog/first entry
</a>
</h2>
<div class="post-meta">Fri, Sep 19, 2014 </div>
</div>
<div class="post-summary">
Crisologo - Valencirina Wedding When: November 27, 2010 Where: Edsa Shangri-La
</div>
</div>
<div class="post">
<div class="post-title">
<h2>
<a href="http://nmcapule.github.io/kg/about/">
About Us
</a>
</h2>
<div class="post-meta">Thu, Sep 18, 2014 </div>
</div>
<div class="post-summary">
About Us KIMI GO, business established since 1992, serving various clienteles for their needs in casual, formal, and office/school uniforms with only three sewing machines as for our start At home. In late 1994, due to the big response of our customers, we open KIMI GO in Zamora St. Tondo Manila to accommodate the increasing number of our regular client.Since then, we been accepting made to order clothes formal, evening dress, and wedding gowns and uniforms for large and small scale establishments.
</div>
</div>
</ul>
</section>
<hr/>
<div class="footer">
<div class="container-fluid">
<div class="col-md-4">
<h4 class="footer-col-h">Posts</h4>
<p>Lorem ipsuma nd shit poask ppsdk pdkp[qwl [qw[l [qwl[d las[dl as;dlasd' asld as c;l ;c';s 'das ;.c;'a. as </p>
</div>
<div class="col-md-4">
<h4 class="footer-col-h">Social Media</h4>
<p>Lorem ipsuma nd shit poask ppsdk pdkp[qwl [qw[l [qwl[d las[dl as;dlasd' asld as c;l ;c';s 'das ;.c;'a. as </p>
</div>
<div class="col-md-4">
<h4 class="footer-col-h">Quick Contact</h4>
<div class="footer-col-content">
<div><i class="fa fa-phone fa-fw"></i> 794-1122/ 525-6465/ 343-2765</div>
<div><i class="fa fa-envelope-o fa-fw"></i> weddingkimigo@yahoo.com</div>
<div><i class="fa fa-envelope-o fa-fw"></i> kimigo_gallery@yahoo.com.ph</div>
<div><i class="fa fa-map-marker fa-fw"></i> Unit 1, Royalle Parthenon Square, Tandang Sora QC</div>
</div>
</div>
</div>
<hr/>
<div class="footer-copyright">
Copyright 2014. Wedding Kimi Go. All Rights Reserved.
</div>
</div>
</div>
</body>
</html>
|
nmcapule/kg
|
public/tags/wedding/index.html
|
HTML
|
mit
| 6,977
|
// This file defines an API that would be nice, but it's not required
// Initialize the editor
var editor = new Editor("");
// Activate/deactivate the editor
editor.active(true || false);
// Set a new action
editor.add("", {
shortcut: {} || "" || false, // The key for Ctrl+key or { key: "esc" }
menu: {} || "" || false, // The html or icon to show
init: function(){} || false, // Called when activating an editor
action: function(){} || false, // Click or shortcut for that action
destroy: function(){} || false // Deactivating an editor
});
// The editor is initialized or re-activated
editor.on("init", function(){});
// Some action is triggered for any reason
editor.on("action", function(){});
// Registered action
editor.on("action:save", function(){});
// The editor is destroyed or de-activated
editor.on("destroy", function(){});
// The editor re-reads its data
editor.on("refresh", function(){});
// Some part of the editor is clicked or touched
editor.on("click", function(){});
// Some key is introduced (for example, "tab")
editor.on("key", function(){});
editor.on("select", function(){});
// Special events
editor.on("<event>:before", function(){});
editor.on("<event>:pre", function(){});
editor.on("<event>:post", function(){});
editor.on("<event>:after", function(){});
editor.on("<event>:none", function(){});
// Example (not part of the API)
editor.action.list = { actionname1: function(){}, actionname2: function(){} };
editor.menu.inline.list = { actionname1: "html1", actionname2: "html2" };
editor.menu.block.list = { actionname1: "html1", actionname2: "html2" };
editor.menu.list = {};
editor.shortcuts.list = { actionname1: { control: true, keyCode: 16 }, actionname2: { control: false, keyCode: 27 } };
editor.shortcuts.get(e);
|
franciscop/modern-editor
|
spec.js
|
JavaScript
|
mit
| 1,808
|
#facebox .b {
background:url(/images/facebox/b.png);
}
#facebox .tl {
background:url(/images/facebox/tl.png);
}
#facebox .tr {
background:url(/images/facebox/tr.png);
}
#facebox .bl {
background:url(/images/facebox/bl.png);
}
#facebox .br {
background:url(/images/facebox/br.png);
}
#facebox {
position: absolute;
top: 0;
left: 0;
z-index: 100;
text-align: left;
}
#facebox h1.facebox {color: green;}
#facebox .popup {
position: relative;
}
#facebox table {
border-collapse: collapse;
}
#facebox td {
border-bottom: 0;
padding: 0;
}
#facebox .body {
padding: 10px;
background: #fff;
width: 370px;
}
#facebox .loading {
text-align: center;
}
#facebox .image {
text-align: center;
}
#facebox img {
border: 0;
margin: 0;
}
#facebox .footer {
border-top: 1px solid #DDDDDD;
padding-top: 5px;
margin-top: 10px;
text-align: right;
}
#facebox .tl, #facebox .tr, #facebox .bl, #facebox .br {
height: 10px;
width: 10px;
overflow: hidden;
padding: 0;
}
#facebox_overlay {
position: fixed;
top: 0px;
left: 0px;
height:100%;
width:100%;
}
.facebox_hide {
z-index:-100;
}
.facebox_overlayBG {
background-color: #000;
z-index: 99;
}
* html #facebox_overlay { /* ie6 hack */
position: absolute;
height: expression(document.body.scrollHeight > document.body.offsetHeight ? document.body.scrollHeight : document.body.offsetHeight + 'px');
}
|
bcalloway/rails-calendar
|
public/stylesheets/facebox.css
|
CSS
|
mit
| 1,421
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.