text:
<!-- HTML footer for doxygen 1.8.11-->
<!-- start footer part -->
<!--BEGIN GENERATE_TREEVIEW-->

<!--END GENERATE_TREEVIEW-->

<hr class="footer"/><address class="footer"><small>
Generated by doxygen $doxygenversion
</small></address>

</div>
</body>
</html>

redpajama_set_name: RedPajamaGithub


text:
#include <iostream>
using std::cout; using std::endl;
#include <vector>
using std::vector;

// pass iterators to the first and one past the last element to print
void print(vector<int>::const_iterator beg,
           vector<int>::const_iterator end)
{
    while (beg != end) {
        cout << *beg++;
        if (beg != end) cout << " ";  // no space after last element
    }
    cout << endl;
}

// vec is potentially large, so copying vec might be expensive
// use a const reference to avoid the copy
void print(const vector<int> &vec)
{
    for (vector<int>::const_iterator it = vec.begin();
                                it != vec.end(); ++it) {
        if (it != vec.begin()) cout << " ";
        cout << *it;
    }
    cout << endl;
}

int main()
{
    vector<int> vec(42);
    print(vec.begin(), vec.end());
    print(vec);
}


text:
describe("Intermission", function() {

  var ___ = 0;

  // Koans 1 through 10 teach enough about Regular Expressions
  // to handle most common RegEx scenarios. This Koan is a series
  // of puzzles and problems to solve with Regular Expressions
  // to help cement your understanding as well as provide some
  // more Real World examples.

  // Note: The starter patterns (like /___/) will NOT include
  // the ^ $ hints that were used in the earlier Koans. It's up
  // to you to decide whether you want to capture the whole
  // string or just a substring to solve the puzzle.

  it('Find City, State, and Zip code', function() {
    // Assumptions:
    //   * US Addresses (no Canadian provinces, etc.)
    //   * Common American address format: City, ST 12345
    //   * Comma separating City and State is optional
    //   * US State will always use two uppercase letter abbreviation

    var fixThisPattern = /^\s*([a-zA-Z .]+),?\s+([A-Z]{2})\s+(\d{5}(-\d{4})?)/;

    // in matches1[cityGroup], etc., set the index to find each value
    var cityGroup  = 1;
    var stateGroup = 2;
    var zipGroup   = 3;

    var matches1 = fixThisPattern.exec(' Columbus, OH 43215'           );
    var matches2 = fixThisPattern.exec(' San Francisco, CA 94118-4503' );
    var matches3 = fixThisPattern.exec(' APO AE 09499-0074'            );
    var matches4 = fixThisPattern.exec(' Port St. Lucie FL 34952'      );

    // Debug:
    // jasmine.log("Debug: " + matches1);

    var city1  = matches1[cityGroup];
    var state1 = matches1[stateGroup];
    var zip1   = matches1[zipGroup];

    var city2  = matches2[cityGroup];
    var state2 = matches2[stateGroup];
    var zip2   = matches2[zipGroup];

    var city3  = matches3[cityGroup];
    var state3 = matches3[stateGroup];
    var zip3   = matches3[zipGroup];

    var city4  = matches4[cityGroup];
    var state4 = matches4[stateGroup];
    var zip4   = matches4[zipGroup];

    expect( city1  ).toEqual('Columbus');
    expect( state1 ).toEqual('OH');
    expect( zip1   ).toEqual('43215');

    expect( city2  ).toEqual('San Francisco');
    expect( state2 ).toEqual('CA');
    expect( zip2   ).toEqual('94118-4503');

    expect( city3  ).toEqual('APO');
    expect( state3 ).toEqual('AE');
    expect( zip3   ).toEqual('09499-0074');

    expect( city4  ).toEqual('Port St. Lucie');
    expect( state4 ).toEqual('FL');
    expect( zip4   ).toEqual('34952');
  });

  it('Parse URL, detect invalid format', function() {
    // Assumptions:
    //   * Only accept these protocols: http, https, ftp, sftp, ssh
    //   * server is required, may be numeric (IPv4) or named
    //   * server name may only be one word (e.g. 'localhost')
    //   * port is optional
    //   * directory and file name are both optional
    //   * directory, if present, will always end in /
    //   * GET parameters are optional
    //   * any missing value will be "" (instead of null)

    var fixThisPattern = /^(https?|s?ftp|ssh):\/\/(\d{1,3}(\.\d{1,3}){3}|[a-z]+(\.[a-z]+)*)((:\d+)?)\/(([^\/?]+\/)*)(([\w.]+)?)((\?.*)?)$/;

    var protocolGroup  = 1;
    var serverGroup    = 2;
    var portGroup      = 5;
    var directoryGroup = 7;
    var fileGroup      = 9;
    var getParamsGroup = 11;

    // valid
    var matches1 = fixThisPattern.exec( 'http://www.google.com/'                                );
    var matches2 = fixThisPattern.exec( 'https://mysearch.com/search.jsp?q=regular+expressions' );
    var matches3 = fixThisPattern.exec( 'ftp://192.168.0.100/home/myself/music/'                );
    var matches4 = fixThisPattern.exec( 'ssh://localhost/etc/passwd'                            );
    var matches5 = fixThisPattern.exec( 'http://127.0.0.1:8080/Admin/index.jsp'                 );

    // invalid
    var matches6 = fixThisPattern.exec( 'google.com'                  );
    var matches7 = fixThisPattern.exec( 'gopher://oldserver.arpanet/' );

    // Debug:
    // jasmine.log("Debug: " + matches1.length);

    var protocol1   = matches1.length > protocolGroup  ? matches1[protocolGroup]  : "";
    var server1     = matches1.length > serverGroup    ? matches1[serverGroup]    : "";
    var port1       = matches1.length > portGroup      ? matches1[portGroup]      : "";
    var directory1  = matches1.length > directoryGroup ? matches1[directoryGroup] : "";
    var file1       = matches1.length > fileGroup      ? matches1[fileGroup]      : "";
    var getParams1  = matches1.length > getParamsGroup ? matches1[getParamsGroup] : "";

    var protocol2   = matches2.length > protocolGroup  ? matches2[protocolGroup]  : "";
    var server2     = matches2.length > serverGroup    ? matches2[serverGroup]    : "";
    var port2       = matches2.length > portGroup      ? matches2[portGroup]      : "";
    var directory2  = matches2.length > directoryGroup ? matches2[directoryGroup] : "";
    var file2       = matches2.length > fileGroup      ? matches2[fileGroup]      : "";
    var getParams2  = matches2.length > getParamsGroup ? matches2[getParamsGroup] : "";

    var protocol3   = matches3.length > protocolGroup  ? matches3[protocolGroup]  : "";
    var server3     = matches3.length > serverGroup    ? matches3[serverGroup]    : "";
    var port3       = matches3.length > portGroup      ? matches3[portGroup]      : "";
    var directory3  = matches3.length > directoryGroup ? matches3[directoryGroup] : "";
    var file3       = matches3.length > fileGroup      ? matches3[fileGroup]      : "";
    var getParams3  = matches3.length > getParamsGroup ? matches3[getParamsGroup] : "";

    var protocol4   = matches4.length > protocolGroup  ? matches4[protocolGroup]  : "";
    var server4     = matches4.length > serverGroup    ? matches4[serverGroup]    : "";
    var port4       = matches4.length > portGroup      ? matches4[portGroup]      : "";
    var directory4  = matches4.length > directoryGroup ? matches4[directoryGroup] : "";
    var file4       = matches4.length > fileGroup      ? matches4[fileGroup]      : "";
    var getParams4  = matches4.length > getParamsGroup ? matches4[getParamsGroup] : "";

    var protocol5   = matches5.length > protocolGroup  ? matches5[protocolGroup]  : "";
    var server5     = matches5.length > serverGroup    ? matches5[serverGroup]    : "";
    var port5       = matches5.length > portGroup      ? matches5[portGroup]      : "";
    var directory5  = matches5.length > directoryGroup ? matches5[directoryGroup] : "";
    var file5       = matches5.length > fileGroup      ? matches5[fileGroup]      : "";
    var getParams5  = matches5.length > getParamsGroup ? matches5[getParamsGroup] : "";

    // http://www.google.com/
    expect( protocol1  ).toEqual('http');
    expect( server1    ).toEqual('www.google.com');
    expect( port1      ).toEqual('');
    expect( directory1 ).toEqual('');
    expect( file1      ).toEqual('');
    expect( getParams1 ).toEqual('');

    // https://mysearch.com/search.jsp?q=regular+expressions
    expect( protocol2  ).toEqual('https');
    expect( server2    ).toEqual('mysearch.com');
    expect( port2      ).toEqual('');
    expect( directory2 ).toEqual('');
    expect( file2      ).toEqual('search.jsp');
    expect( getParams2 ).toEqual('?q=regular+expressions');

    // ftp://192.168.0.100/home/myself/music/
    expect( protocol3  ).toEqual('ftp');
    expect( server3    ).toEqual('192.168.0.100');
    expect( port3      ).toEqual('');
    expect( directory3 ).toEqual('home/myself/music/');
    expect( file3      ).toEqual('');
    expect( getParams3 ).toEqual('');

    // ftp://192.168.0.100/home/myself/music/
    expect( protocol4  ).toEqual('ssh');
    expect( server4    ).toEqual('localhost');
    expect( port4      ).toEqual('');
    expect( directory4 ).toEqual('etc/');
    expect( file4      ).toEqual('passwd');
    expect( getParams4 ).toEqual('');

    // http://127.0.0.1:8080/Admin/index.jsp
    expect( protocol5  ).toEqual('http');
    expect( server5    ).toEqual('127.0.0.1');
    expect( port5      ).toEqual(':8080');
    expect( directory5 ).toEqual('Admin/');
    expect( file5      ).toEqual('index.jsp');
    expect( getParams5 ).toEqual('');

    // google.com
    expect( matches6 ).toBeNull();

    // gopher://oldserver.arpanet/
    expect( matches7 ).toBeNull();

  });

});


text:
<!DOCTYPE html>

  <meta charset="utf-8" />
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1"/>

  <title>Tomorrowland: Um Lugar Onde Nada é Impossível</title>
  <meta name="author" content="" />
  <meta name="description"
        content="Um “A Corrente do Bem” atualizado a nível tecnológico, inserido em uma aventura onde pessoas voam, coisas voam e a NASA é uma expansão da Disney. Ou seria o contrário?

Tomorrowland só não..."/>

  <meta name="yandex-verification" content="48a8210fc043c5e8" />

  <meta name="generator" content="Hugo 0.54.0" />

  <meta itemprop="name" content="Tomorrowland: Um Lugar Onde Nada é Impossível"/>
  <meta itemprop="description"
        content="Um “A Corrente do Bem” atualizado a nível tecnológico, inserido em uma aventura onde pessoas voam, coisas voam e a NASA é uma expansão da Disney. Ou seria o contrário?

Tomorrowland só não..."/>
  <meta itemprop="image"
        content="/img/logo.svg"/>

  <meta property="og:title" content="Tomorrowland: Um Lugar Onde Nada é Impossível"/>
  <meta property="og:type"
        content="article"/>
  <meta property="og:url" content="http://www.cinetenisverde.com.br/tomorrowland-um-lugar-onde-nada-e-impossivel/"/>
  <meta property="og:image"
        content="/img/logo.svg"/>
  <meta property="og:description"
        content="Um “A Corrente do Bem” atualizado a nível tecnológico, inserido em uma aventura onde pessoas voam, coisas voam e a NASA é uma expansão da Disney. Ou seria o contrário?

Tomorrowland só não..."/>
  <meta property="og:site_name" content="Cine Tênis Verde"/>
  <meta property="article:published_time"
        content="2015-11-23T00:00:00+00:00"/>
  <meta property="article:section" content="post"/>

  <meta name="twitter:card" content="summary"/>
  <meta name="twitter:site"
        content=""/>
  <meta name="twitter:title" content="Tomorrowland: Um Lugar Onde Nada é Impossível"/>
  <meta name="twitter:description"
        content="Um “A Corrente do Bem” atualizado a nível tecnológico, inserido em uma aventura onde pessoas voam, coisas voam e a NASA é uma expansão da Disney. Ou seria o contrário?

Tomorrowland só não..."/>
  <meta name="twitter:creator"
        content=""/>
  <meta name="twitter:image:src"
        content="/img/logo.svg"/>

  <link rel="stylesheet" type="text/css" href="/css/capsule.min.css"/>
  <link rel="stylesheet" type="text/css" href="/css/custom.css"/>

  <link rel="apple-touch-icon" href="/img/apple-touch-icon.png"/>
  <link rel="icon" href="/img/favicon.ico"/>

 Cine Tênis Verde

    <input type="checkbox" id="navbar-burger-state"/>

      search

      twitter

      rss

Tomorrowland: Um Lugar Onde Nada é Impossível

    ★★★☆☆

 Wanderley Caloni, November 23, 2015

Um “A Corrente do Bem” atualizado a nível tecnológico, inserido em uma aventura onde pessoas voam, coisas voam e a NASA é uma expansão da Disney. Ou seria o contrário?

Tomorrowland só não é um filme Sessão da Tarde graças ao toque mágico de Brad Bird (Os Incríveis, Ratatouille), que consegue pegar uma aventura insossa como essa e torná-la em algo divertido, que parece conter mais do que o simplório roteiro que escreveu com Damon Lindelof (Guerra Mundial Z, Prometheus), onde o futuro da humanidade está ameaçado, mas ao mesmo tempo seus gênios criaram um lugar onde tudo é possível (em que tudo se resume basicamente em voar e flutuar em diferentes versões). Com a ajuda dos visionários (que antes seriam apenas nerds) Frank Walker (George Clooney) e Casey Newton (nossa, como eles são originais nos nomes dos personagens!), talvez ainda haja esperança.

Com uma direção de arte que brinca a todo o momento com a animação – e onde os robôs do mal possuem um sorriso a la universo Roger Rabbit ou Máscara – Tomorrowland prefere jogar sensações na frente do seu público e piadas bem humoradas enquanto tenta adiar para sempre sua trama principal. Como resultado temos uma ótima diversão com pouca reflexão. Bom, a não ser que você ache super-genial a velha cartilha do “estamos destruindo o mundo, precisamos dar-nos as mãos” atual, originário dos desavisados do movimento Ocupy Wall Street e que agora gera mais e mais movimentos “nonsense” em volta do globo (seriam eles a causa do fim dos tempos?).

Mesmo assim, boa parte do filme funciona graças à nossa curiosidade mórbida em busca de soluções para este mundo fantástico. Seria uma viagem no tempo? Mas isso não geraria paradoxos temporais? Ou seriam alienígenas infiltrados como em MIB? Talvez fosse uma mistura de tudo isso junto… e a maior parte do tempo todas essas divagações funcionam, com uma ajuda de um elenco de atores afiados.

Com atuações inspiradas de Clooney e da simpática e divertida Britt Robertson, além da mais que especial performance da robótica Raffey Cassidy, o filme consegue fazer-nos ficar metade interessados nessas pessoas e a outra metade curiosos pela história que os une. No meio de tudo isso, tentamos descobrir sobre o que diz esse mundo fantástico. Talvez a maior virtude do seu roteiro seja esconder isso ao máximo, revelando aos poucos que não se trata apenas de uma versão futurista de Orlando, mas de uma gigantesca campanha de product placement (pelo jeito a crise unicamente brasileira já anda diminuindo o número de turistas na Flórida).

Recheado de efeitos digitais que impressionam graças aos movimentos graciosos que Bird desempenha em toda a história, Tomorrowland pode até ser chamada de Sessão da Tarde, pois merece o título pela sua história nada original. Porém, pela sua realização, este filme está contido em uma dimensão apartada da nossa realidade mesquinha e cruel. Pena que o que temos para hoje se chama realidade.

           Imagens e créditos no IMDB.

    ★★★☆☆

 Tomorrowland: Um Lugar Onde Nada é Impossível ● Tomorrowland: Um Lugar Onde Nada é Impossível. Tomorrowland (USA, 2015). Dirigido por Brad Bird. Escrito por Damon Lindelof, Brad Bird, Damon Lindelof, Brad Bird, Jeff Jensen. Com George Clooney, Hugh Laurie, Britt Robertson, Raffey Cassidy, Tim McGraw, Kathryn Hahn, Keegan-Michael Key, Chris Bauer, Thomas Robinson. ● Nota: 3/5. Categoria: movies.  Publicado em 2015-11-23.  Texto escrito por Wanderley Caloni.

Quer comentar?

      Share


text:
package ch.heigvd.amt.mvcdemo.model.entities;

import javax.persistence.Entity;
import javax.persistence.ManyToOne;

/**
 * This class implements the Employee domain model object.
 *
 * Notice the basicSalary and bonus attributes. We have added these attributes
 * because they are an example of sensitive information that you may not want to
 * disclose in all of your interfaces (UIs but also REST APIs). This is one
 * reason why we recommend the use of Data Transer Objects (DTOs).
 *
 * @author Olivier Liechti
 */
@Entity
public class Employee extends AbstractDomainModelEntity<Long> {

  private String firstName;
  private String lastName;
  private String title;

  private double basicSalary;
  private double bonus;

  @ManyToOne
  private Company company;

  public Employee() {
  }

  public Employee(String firstName, String lastName, String title, double basicSalary, double bonus) {
    this.firstName = firstName;
    this.lastName = lastName;
    this.title = title;
    this.basicSalary = basicSalary;
    this.bonus = bonus;
  }

  public String getFirstName() {
    return firstName;
  }

  public void setFirstName(String firstName) {
    this.firstName = firstName;
  }

  public String getLastName() {
    return lastName;
  }

  public void setLastName(String lastName) {
    this.lastName = lastName;
  }

  public String getTitle() {
    return title;
  }

  public void setTitle(String title) {
    this.title = title;
  }

  public double getBasicSalary() {
    return basicSalary;
  }

  public void setBasicSalary(double basicSalary) {
    this.basicSalary = basicSalary;
  }

  public double getBonus() {
    return bonus;
  }

  public void setBonus(double bonus) {
    this.bonus = bonus;
  }

  public Company getCompany() {
    return company;
  }

  public void setCompany(Company company) {
    this.company = company;
  }

}


text:
package org.gradle.test.performance.mediummonolithicjavaproject.p447;

import org.gradle.test.performance.mediummonolithicjavaproject.p446.Production8937;
import org.gradle.test.performance.mediummonolithicjavaproject.p446.Production8938;
import org.gradle.test.performance.mediummonolithicjavaproject.p446.Production8939;

public class Production8940 {

    private Production8937 property0;

    public Production8937 getProperty0() {
        return property0;
    }

    public void setProperty0(Production8937 value) {
        property0 = value;
    }

    private Production8938 property1;

    public Production8938 getProperty1() {
        return property1;
    }

    public void setProperty1(Production8938 value) {
        property1 = value;
    }

    private Production8939 property2;

    public Production8939 getProperty2() {
        return property2;
    }

    public void setProperty2(Production8939 value) {
        property2 = value;
    }

    private String property3;

    public String getProperty3() {
        return property3;
    }

    public void setProperty3(String value) {
        property3 = value;
    }

    private String property4;

    public String getProperty4() {
        return property4;
    }

    public void setProperty4(String value) {
        property4 = value;
    }

    private String property5;

    public String getProperty5() {
        return property5;
    }

    public void setProperty5(String value) {
        property5 = value;
    }

    private String property6;

    public String getProperty6() {
        return property6;
    }

    public void setProperty6(String value) {
        property6 = value;
    }

    private String property7;

    public String getProperty7() {
        return property7;
    }

    public void setProperty7(String value) {
        property7 = value;
    }

    private String property8;

    public String getProperty8() {
        return property8;
    }

    public void setProperty8(String value) {
        property8 = value;
    }

    private String property9;

    public String getProperty9() {
        return property9;
    }

    public void setProperty9(String value) {
        property9 = value;
    }

}


text:
'use strict';

var should = require('should');
var mockery = require('mockery');
var config = require('../../config.js');

describe('User', function() {
  describe('(Account Scope)', function() {
    var requestMock, Syncano, scope;
    before(function() {
      mockery.enable(config.mockSettings);
      mockery.registerMock('./request.js', config.browserRequestMock);
      mockery.registerSubstitute('../server/core.js', '../browser/core.js');

      Syncano = require('../../../lib/syncano.js');
      scope = new Syncano({
        accountKey: config.accountKey
      });
    });

    after(function() {
      mockery.deregisterMock('request');
      mockery.deregisterSubstitute('../server/core.js');
      mockery.disable();
    });

    it('instance.user is an user object', function() {
      (scope.instance(config.instance).user().type).should.equal('user');
      (scope.instance(config.instance).user()).should.have.keys(['list', 'add', 'detail', 'update', 'delete', 'resetKey']);
      (scope.instance(config.instance).user().list).should.be.a.Function();
      (scope.instance(config.instance).user().add).should.be.a.Function();
      (scope.instance(config.instance).user().detail).should.be.a.Function();
      (scope.instance(config.instance).user().delete).should.be.a.Function();
      (scope.instance(config.instance).user().update).should.be.a.Function();
      (scope.instance(config.instance).user().resetKey).should.be.a.Function();
    });

    it('list() should recieve correct options', function(done) {
      var func, res;
      func = scope.instance(config.instance).user().list();
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('GET');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('detail() should recieve correct options', function(done) {
      var func, res;
      func = scope.instance(config.instance).user().detail(config.userId);
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('GET');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('update() should recieve correct options', function(done) {
      var func, res;
      func = scope.instance(config.instance).user().update(config.userId, {});
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('PATCH');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('delete() should recieve correct options', function(done) {
      var func, res;
      func = scope.instance(config.instance).user().delete(config.userId);
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('DELETE');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('resetKey() should recieve correct options', function(done) {
      var func, res;
      func = scope.instance(config.instance).user().resetKey(config.userId);
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('POST');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/reset_key/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('should create a new user object', function() {
      scope = new scope.instance(config.instance).user(config.userId);
      (scope.type).should.equal('user');
      (scope).should.have.keys(['config', 'detail', 'update', 'delete', 'resetKey', 'group']);
      (scope.detail).should.be.a.Function();
      (scope.delete).should.be.a.Function();
      (scope.update).should.be.a.Function();
      (scope.resetKey).should.be.a.Function();
      (scope.group).should.be.an.Function();
    });

    it('detail() should recieve correct options', function(done) {
      var func, res;
      func = scope.detail();
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('GET');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('update() should recieve correct options', function(done) {
      var func, res;
      func = scope.update({});
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('PATCH');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('delete() should recieve correct options', function(done) {
      var func, res;
      func = scope.delete();
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('DELETE');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('resetKey() should recieve correct options', function(done) {
      var func, res;
      func = scope.resetKey();
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('POST');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/reset_key/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('group().list() should recieve correct options', function(done) {
      var func, res;
      func = scope.group().list();
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('GET');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/groups/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('group().add() should recieve correct options', function(done) {
      var func, res;
      func = scope.group().add({});
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('POST');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/groups/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('group().detail() should recieve correct options', function(done) {
      var func, res;
      func = scope.group().detail(config.groupId);
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('GET');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/groups/' + config.groupId + '/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('group().delete() should recieve correct options', function(done) {
      var func, res;
      func = scope.group().delete(config.groupId);
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('DELETE');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/' + config.userId + '/groups/' + config.groupId + '/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.accountKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });
    it('user().group() should return a group object', function() {
      scope = scope.group(config.groupId);
      (scope.type).should.equal('group');
      (scope).should.have.keys(['config', 'detail', 'delete']);
      (scope.detail).should.be.a.Function();
      (scope.delete).should.be.a.Function();
    });
  });

  describe('(Instance Scope)', function() {
    var requestMock, Syncano, scope;
    before(function() {
      mockery.enable(config.mockSettings);
      mockery.registerMock('./request.js', config.requestMock);

      Syncano = require('../../../lib/syncano.js');
      scope = new Syncano({
        apiKey: config.apiKey,
        instance: config.instance
      });
    });

    after(function() {
      mockery.deregisterMock('request');
      mockery.disable();
    });

    it('this.user should be user object', function() {
      (scope.user().type).should.equal('user');
      (scope.user()).should.have.keys(['add', 'login']);
      (scope.user().add).should.be.a.Function();
      (scope.user().login).should.be.a.Function();
    });

    it('add() should recieve correct options', function(done) {
      var func, res;
      func = scope.user().add({});
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('POST');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.apiKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('login() should recieve correct options', function(done) {
      var func, res;
      func = scope.user().login({});
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('POST');
        (res.url).should.equal('/v1/instances/' + config.instance + '/user/auth/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.apiKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('login() (social login) should recieve correct options', function(done) {
      var func, res;
      func = scope.user().login({socialToken: config.socialToken, backend: config.backend});
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('POST');
        (res.url).should.equal('/v1/instances/' + config.instance + '/user/auth/' + config.backend + '/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.apiKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

  });

  describe('(Logged User Scope)', function() {
    var requestMock, Syncano, scope;
    before(function() {
      mockery.enable(config.mockSettings);
      mockery.registerMock('./request.js', config.requestMock);

      Syncano = require('../../../lib/syncano.js');
      scope = new Syncano({
        apiKey: config.apiKey,
        instance: config.instance,
        userKey: config.userKey
      });
    });

    after(function() {
      mockery.deregisterMock('request');
      mockery.disable();
    });

    it('this.user should be user object', function() {
      (scope.user().type).should.equal('user');
      (scope.user()).should.have.keys(['add', 'detail', 'update']);
      (scope.user().add).should.be.a.Function();
      (scope.user().detail).should.be.a.Function();
      (scope.user().update).should.be.a.Function();
    });

    it('add() should recieve correct options', function(done) {
      var func, res;
      func = scope.user().add({});
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('POST');
        (res.url).should.equal('/v1/instances/' + config.instance + '/users/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY', 'X-USER-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.apiKey);
        (res.headers['X-USER-KEY']).should.equal(config.userKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('detail() should recieve correct options', function(done) {
      var func, res;
      func = scope.user().detail();
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('GET');
        (res.url).should.equal('/v1/instances/' + config.instance + '/user/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.apiKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

    it('update() should recieve correct options', function(done) {
      var func, res;
      func = scope.user().update({});
      func.then(function(res) {
        (res).should.have.properties(['method', 'url', 'headers']);
        (res.method).should.equal('PATCH');
        (res.url).should.equal('/v1/instances/' + config.instance + '/user/');
        (res.headers).should.have.properties(['Content-Type', 'X-API-KEY']);
        (res.headers['X-API-KEY']).should.equal(config.apiKey);
        done();
      }).catch(function(err) {
        done(err);
      });
    });

  });
});


text:
//
//  AdressController.m
//  宠爱有家
//
//  Created by XXXX on 16/5/19.
//  Copyright © 2016年 XXXX. All rights reserved.
//

#import "AdressController.h"
#import "UIViewController+addLeftOrRightBarButton.h"
#import "AddPeopleController.h"
#import "UIViewController+PushViewControllerWithBarHidden.h"
#import "MainTableViewCell.h"

@interface AdressController ()<UITableViewDataSource,UITableViewDelegate,KeepControlDelegate>
{

    AddPeopleController *addPeoVC;
}
@property (nonatomic,strong)UITableView *MainTableView;
@property (nonatomic,strong)NSMutableArray *SaveArr;
@property (nonatomic ,strong)MainTableViewCell *cell;

@end

@implementation AdressController

- (void)AddMessage:(NSMutableDictionary *)dic{

    [_SaveArr addObject:dic];
    [self.MainTableView reloadData];

}
- (void)viewWillAppear:(BOOL)animated{

    if (_SaveArr.count == 0) {
        self.view = [[[NSBundle mainBundle] loadNibNamed:@"AdressNoMessageView" owner:nil options:nil] lastObject];
    }

    if (_SaveArr.count != 0) {
        _MainTableView = [[UITableView alloc] initWithFrame:CGRectMake(10, 64 + 10, W - 20, H) style:UITableViewStylePlain];
        _MainTableView.dataSource = self;
        _MainTableView.delegate = self;
            _MainTableView.backgroundColor = [UIColor colorWithWhite:0.95 alpha:1.0];
        [self.view addSubview:_MainTableView];

        [_MainTableView registerNib:[UINib nibWithNibName:@"MainTableViewCell" bundle:nil] forCellReuseIdentifier:@"MainCell"];

    }

}

- (void)viewDidLoad {
    [super viewDidLoad];

    _SaveArr = [[NSMutableArray alloc] initWithCapacity:0];

    self.navigationItem.title = @"收货人信息";

    [self addRightBtnImageName:@"one" action:@selector(addNewAdressAction)];

    self.view.backgroundColor = [UIColor colorWithWhite:0.9 alpha:1.0];

}

#pragma mark -- UITableViewDataSource

- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{

    return 1;

}

- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{

    _cell = [tableView dequeueReusableCellWithIdentifier:@"MainCell"];

    _cell.NameLab.text = [_SaveArr[indexPath.section] objectForKey:@"name"];
    _cell.countryLab.text = [_SaveArr[indexPath.section] objectForKey:@"place"];

    _cell.phoneLab.text = [_SaveArr[indexPath.section] objectForKey:@"number"];

    return _cell;
}

#pragma mark -- UITableViewDelegate

- (CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(nonnull NSIndexPath *)indexPath

{
    return 95;
}

- (CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section{
    return 10;
}

- (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
{

    return _SaveArr.count;
}

- (void)addNewAdressAction{
    addPeoVC = [[AddPeopleController alloc] init];

    addPeoVC.delegate = self;
    [self pushViewControllerWithTabBarHidden:addPeoVC];
    self.hidesBottomBarWhenPushed = YES;

}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end


text:
<!DOCTYPE html>

    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="description" content="">
    <meta name="author" content="">

    <title>Chanyeol</title>

    <link href="css/bootstrap.min.css" rel="stylesheet">

    <link href="css/agency.css" rel="stylesheet">

    <link href="font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css">
    <link href="https://fonts.googleapis.com/css?family=Montserrat:400,700" rel="stylesheet" type="text/css">
    <link href='https://fonts.googleapis.com/css?family=Kaushan+Script' rel='stylesheet' type='text/css'>
    <link href='https://fonts.googleapis.com/css?family=Droid+Serif:400,700,400italic,700italic' rel='stylesheet' type='text/css'>
    <link href='https://fonts.googleapis.com/css?family=Roboto+Slab:400,100,300,700' rel='stylesheet' type='text/css'>

<link rel="icon" type="image/ico" href="http://67.media.tumblr.com/70ee0c0ce6f450e10e8d0991d1f94fbc/tumblr_inline_n1uaxkoTSy1s6tiqa.png"/>

                <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
                    Toggle navigation

                </button>
                Kpop Starter Kit

Chanyeol

찬열

"No matter how hard it is, I always smile like an idiot"

Park Chanyeol

            November 27, 1992

            Seoul

            Chanyeol is Exo's rapper. Chanyeol is very involved in producing music. He loves confetti and is known for an iconic line from Wolf "Chogiwa." Chanyeol is one of the tallest members. He looks like a fairy because of his beautiful eyes and big ears. Chanyeol is Exo's happy virus. Chanyeol plays the piano, guitar, and djembe.

Videos

Pictures

Enjoy big discounts for Links of London with these vouchers.
Powered by flickr embed.


text:
package com.mpush.tools.event;

public abstract class EventConsumer {

    public EventConsumer() {
        EventBus.register(this);
    }

}


text:
;(function($) {

$.ui = {
	plugin: {
		add: function(module, option, set) {
			var proto = $.ui[module].prototype;
			for(var i in set) {
				proto.plugins[i] = proto.plugins[i] || [];
				proto.plugins[i].push([option, set[i]]);
			}
		},
		call: function(instance, name, args) {
			var set = instance.plugins[name];
			if(!set) { return; }

			for (var i = 0; i < set.length; i++) {
				if (instance.options[set[i][0]]) {
					set[i][1].apply(instance.element, args);
				}
			}
		}
	},
	cssCache: {},
	css: function(name) {
		if ($.ui.cssCache[name]) { return $.ui.cssCache[name]; }
		var tmp = $('<div class="ui-resizable-gen">').addClass(name).css({position:'absolute', top:'-5000px', left:'-5000px', display:'block'}).appendTo('body');

		//if (!$.browser.safari)
			//tmp.appendTo('body');

		//Opera and Safari set width and height to 0px instead of auto
		//Safari returns rgba(0,0,0,0) when bgcolor is not set
		$.ui.cssCache[name] = !!(
			(!(/auto|default/).test(tmp.css('cursor')) || (/^[1-9]/).test(tmp.css('height')) || (/^[1-9]/).test(tmp.css('width')) ||
			!(/none/).test(tmp.css('backgroundImage')) || !(/transparent|rgba\(0, 0, 0, 0\)/).test(tmp.css('backgroundColor')))
		);
		try { $('body').get(0).removeChild(tmp.get(0));	} catch(e){}
		return $.ui.cssCache[name];
	},
	disableSelection: function(e) {
		e.unselectable = "on";
		e.onselectstart = function() { return false; };
		if (e.style) { e.style.MozUserSelect = "none"; }
	},
	enableSelection: function(e) {
		e.unselectable = "off";
		e.onselectstart = function() { return true; };
		if (e.style) { e.style.MozUserSelect = ""; }
	},
	hasScroll: function(e, a) {
		var scroll = /top/.test(a||"top") ? 'scrollTop' : 'scrollLeft', has = false;
		if (e[scroll] > 0) return true; e[scroll] = 1;
		has = e[scroll] > 0 ? true : false; e[scroll] = 0;
		return has;
	}
};

/** jQuery core modifications and additions **/

var _remove = $.fn.remove;
$.fn.remove = function() {
	$("*", this).add(this).trigger("remove");
	return _remove.apply(this, arguments );
};

// $.widget is a factory to create jQuery plugins
// taking some boilerplate code out of the plugin code
// created by Scott González and Jörn Zaefferer
function getter(namespace, plugin, method) {
	var methods = $[namespace][plugin].getter || [];
	methods = (typeof methods == "string" ? methods.split(/,?\s+/) : methods);
	return ($.inArray(method, methods) != -1);
}

var widgetPrototype = {
	init: function() {},
	destroy: function() {
		this.element.removeData(this.widgetName);
	},

	getData: function(key) {
		return this.options[key];
	},
	setData: function(key, value) {
		this.options[key] = value;
	},

	enable: function() {
		this.setData('disabled', false);
	},
	disable: function() {
		this.setData('disabled', true);
	}
};

$.widget = function(name, prototype) {
	var namespace = name.split(".")[0];
	name = name.split(".")[1];
	// create plugin method
	$.fn[name] = function(options) {
		var isMethodCall = (typeof options == 'string'),
			args = Array.prototype.slice.call(arguments, 1);

		if (isMethodCall && getter(namespace, name, options)) {
			var instance = $.data(this[0], name);
			return (instance ? instance[options].apply(instance, args)
				: undefined);
		}

		return this.each(function() {
			var instance = $.data(this, name);
			if (!instance) {
				$.data(this, name, new $[namespace][name](this, options));
			} else if (isMethodCall) {
				instance[options].apply(instance, args);
			}
		});
	};

	// create widget constructor
	$[namespace][name] = function(element, options) {
		var self = this;

		this.widgetName = name;

		this.options = $.extend({}, $[namespace][name].defaults, options);
		this.element = $(element)
			.bind('setData.' + name, function(e, key, value) {
				return self.setData(key, value);
			})
			.bind('getData.' + name, function(e, key) {
				return self.getData(key);
			})
			.bind('remove', function() {
				return self.destroy();
			});
		this.init();
	};

	// add widget prototype
	$[namespace][name].prototype = $.extend({}, widgetPrototype, prototype);
};

/** Mouse Interaction Plugin **/

$.ui.mouse = {
	mouseInit: function() {
		var self = this;

		this.element.bind('mousedown.'+this.widgetName, function(e) {
			return self.mouseDown(e);
		});

		// Prevent text selection in IE
		if ($.browser.msie) {
			this._mouseUnselectable = this.element.attr('unselectable');
			this.element.attr('unselectable', 'on');
		}

		this.started = false;
	},

	// TODO: make sure destroying one instance of mouse doesn't mess with
	// other instances of mouse
	mouseDestroy: function() {
		this.element.unbind('.'+this.widgetName);

		// Restore text selection in IE
		($.browser.msie
			&& this.element.attr('unselectable', this._mouseUnselectable));
	},

	mouseDown: function(e) {
		// we may have missed mouseup (out of window)
		(this._mouseStarted && this.mouseUp(e));

		this._mouseDownEvent = e;

		var self = this,
			btnIsLeft = (e.which == 1),
			elIsCancel = ($(e.target).is(this.options.cancel));
		if (!btnIsLeft || elIsCancel) {
			return true;
		}

		this._mouseDelayMet = !this.options.delay;
		if (!this._mouseDelayMet) {
			this._mouseDelayTimer = setTimeout(function() {
				self._mouseDelayMet = true;
			}, this.options.delay);
		}

		// these delegates are required to keep context
		this._mouseMoveDelegate = function(e) {
			return self.mouseMove(e);
		};
		this._mouseUpDelegate = function(e) {
			return self.mouseUp(e);
		};
		$(document)
			.bind('mousemove.'+this.widgetName, this._mouseMoveDelegate)
			.bind('mouseup.'+this.widgetName, this._mouseUpDelegate);

		return false;
	},

	mouseMove: function(e) {
		// IE mouseup check - mouseup happened when mouse was out of window
		if ($.browser.msie && !e.button) {
			return this.mouseUp(e);
		}

		if (this._mouseStarted) {
			this.mouseDrag(e);
			return false;
		}

		if (this.mouseDistanceMet(e) && this.mouseDelayMet(e)) {
			this._mouseStarted =
				(this.mouseStart(this._mouseDownEvent, e) !== false);
			(this._mouseStarted || this.mouseUp(e));
		}

		return !this._mouseStarted;
	},

	mouseUp: function(e) {
		$(document)
			.unbind('mousemove.'+this.widgetName, this._mouseMoveDelegate)
			.unbind('mouseup.'+this.widgetName, this._mouseUpDelegate);

		if (this._mouseStarted) {
			this._mouseStarted = false;
			this.mouseStop(e);
		}

		return false;
	},

	mouseDistanceMet: function(e) {
		return (Math.max(
				Math.abs(this._mouseDownEvent.pageX - e.pageX),
				Math.abs(this._mouseDownEvent.pageY - e.pageY)
			) >= this.options.distance
		);
	},

	mouseDelayMet: function(e) {
		return this._mouseDelayMet;
	},

	// These are placeholder methods, to be overriden by extending plugin
	mouseStart: function(e) {},
	mouseDrag: function(e) {},
	mouseStop: function(e) {}
};

$.ui.mouse.defaults = {
	cancel: null,
	distance: 0,
	delay: 0
};

})(jQuery);

/*
 * jQuery UI Stepper
 *
 * Copyright (c) 2008 Ca Phun Ung <caphun at yelotofu dot com>
 * Dual licensed under the MIT (MIT-LICENSE.txt)
 * and GPL (GPL-LICENSE.txt) licenses.
 *
 * http://yelotofu.com/labs/jquery/UI/stepper
 *
 * Depends:
 *	ui.core.js
 *	jquery.mousewheel.js
 *
 */
;(function($) {

$.widget("ui.stepper", {
	plugins: {},

	ui: function(e) {
		return {
			instance: this,
			options: this.options,
			element: this.element
		};
	},

	keys: {
		BACK: 8,
		TAB: 9,
		LEFT: 37,
		UP: 38,
		RIGHT: 39,
		DOWN: 40,
		PGUP: 33,
		PGDN: 34,
		HOME: 36,
		END: 35,
		PERIOD: 190,
		MINUS: 109,
		NUMPAD_DECIMAL: 110,
		NUMPAD_SUBTRACT: 109
	},

	init: function() {
		var self = this;
		this.element[0].value = this.options.start;
		this.element[0].textbox = $('input[type="text"]', this.element[0]);

		// check for decimals in step size
		if (this.options.step.toString().indexOf('.') != -1) {
			var s = this.options.step.toString();
			this.setData('decimals', s.slice(s.indexOf('.')+1, s.length).length);
		}

		this.element.each(function(){
			var ns = $(this);
			var textbox = $('input[type="text"]', ns); // get the input textbox
			var bup = $('.ui-stepper-plus', ns); // plus button
			var bdn = $('.ui-stepper-minus', ns); // minus button

			self.element[0].value = self.value(textbox.val());

			if (textbox.length > 0){
				if (self.element[0].value == '' || isNaN(self.element[0].value)) {
					textbox.val(self.format(self.options.start));
					self.element[0].value = self.value(textbox.val());
				}

				// detect key presses and restrict to numeric values only
				textbox
					.bind("keydown.stepper", function(e) {
						if(!self.counter) self.counter = 1;
						return self.keydown(e);
					})
					.bind("keyup.stepper", function(e) {
						if (e.keyCode !== self.keys.BACK && e.keyCode !== self.keys.MINUS && e.keyCode !== self.keys.PERIOD) {
							var val = self.value(this.value);
							var dif = parseFloat(val) % parseFloat(self.options.step);
							if (dif !== 0) {
								val = parseFloat(val) + (parseFloat(self.options.step) - parseFloat(dif));
							}
							if (val < self.options.min) val = self.options.min;
							if (val > self.options.max) val = self.options.max;
							self.element[0].value = self.value(val);
							this.value = self.format(val);
						}
						self.counter = 0;
						self.propagate("change", e);
					})
					// detect when textbox loses cursor focus
					.bind('blur', function(e){
						if (this.value < self.options.min) this.value = self.options.min;
						if (this.value > self.options.max) this.value = self.options.max;
						if (this.value === '') this.value = self.options.start;
					})
					.bind('mousewheel', function(e, delta){
						if (delta > 0)
							self.spin(self.options.step);
						else if (delta < 0)
							self.spin(-self.options.step);
						return false;
					})
					.attr('autocomplete', 'off') // turns off autocomplete in opera!
				;

			}

			// convert button type to button to prevent form submission onclick
			if (bup.attr('type') == 'submit') {
				try {
					bup.removeAttr('type');
					bup.attr('type', 'button');
				} catch(ex) {
					// IE fix
					bup.each(function(){
						this.removeAttribute('type');
						this.setAttribute('type','button');
					});
				}
			}
			//bup.click(function(){stepper(self.options.step);});
			bup
				.bind('mousedown', function(){
					self.mousedown(100, self.options.step);
				})
				.bind('mouseup', function(e){
					self.mouseup(e);
				})
				.bind('click', function(e){
					self.spin(self.options.step);
				})
				.bind('keyup', function(e) {
					var keynum = (window.event ? event.keyCode : (e.which ? e.which : null));
					switch (keynum) {
						// (prev object)
						case self.keys.UP :
						case self.keys.LEFT :
							textbox.focus(); break;
						// (next object)
						case self.keys.DOWN :
						case self.keys.RIGHT :
							bdn.focus(); break;
					}
				})
			;

			// convert button type to button to prevent form submission onclick
			if (bdn.attr('type') == 'submit') {
				try {
					bdn.removeAttr('type');
					bdn.attr('type', 'button');
				} catch(e) {
					// IE fix
					bdn.each(function(){
						this.removeAttribute('type');
						this.setAttribute('type','button');
					});
				}
			}
			bdn
				.bind('mousedown' ,function(){
					self.mousedown(100, -self.options.step);
				})
				.bind('mouseup', function(e){
					self.mouseup(e);
				})
				.bind('click', function(e){
					self.spin(-self.options.step);
				})
				.bind('keyup', function(e){
					var keynum = (window.event ? event.keyCode : (e.which ? e.which : null));
					switch (keynum) {
						// (prev object)
						case self.keys.UP :
						case self.keys.LEFT :
							bup.focus();
							break;
						// (next object)
						case self.keys.DOWN :
						case self.keys.RIGHT :
							break;
					}
				})
			;
		});
	},

	spin: function(val){
		var textbox = this.element[0].textbox;
		if (textbox == undefined)
			return false;

		if (val == undefined || isNaN(val))
			val = 1;

		var textboxVal = this.value(textbox.val());
		textboxVal = parseFloat(textboxVal) + parseFloat(val);

		if (isNaN(textboxVal)) textboxVal = this.options.start;
		if (textboxVal < this.options.min) textboxVal = this.options.min;
		if (textboxVal > this.options.max) textboxVal = this.options.max;

		textbox.val(this.format(textboxVal));
		this.element[0].value = textboxVal;
	},

	number: function(num, dec) {
		return Math.round(parseFloat(num)*Math.pow(10, dec)) / Math.pow(10, dec);
	},

	currency: function(num) {
		var s = this.number(num, 2).toString();
		var dot = parseInt(s).toString().length+1;
		s = s + ((s.indexOf('.') == -1) ? '.' : '') + '0000000001';
		s = s.substr(0, dot) + s.substr(dot, 2);
		return this.options.symbol + s;
	},

	value: function(val) {
		val = val.toString();
		return (this.options.format == 'currency') ? val.slice(this.options.symbol.length, val.length) : val;
	},

	format: function(val) {
		return (this.options.format == 'currency') ? this.currency(val) : this.number(val, this.options.decimals);
	},

	mousedown: function(i, val) {
		var self = this;
		i = i || 100;
		if(this.timer) window.clearInterval(this.timer);
		this.timer = window.setInterval(function() {
			self.spin(val);
			if(self.counter > 20) self.mousedown(20, val);
		}, i);
	},

	mouseup: function(e) {
		this.counter = 0;
		if(this.timer)
			window.clearInterval(this.timer);
		this.propagate("change", e);
	},

	keydown: function(e) {
		if(this.upKey(e.keyCode)) this.spin(this.options.step);
		if(this.downKey(e.keyCode)) this.spin(-this.options.step);
		return this.allowedKey(e.keyCode);
	},

	upKey: function(key){
		return (key === this.keys.UP || key === this.keys.PGUP) ? true : false;
	},

	downKey: function(key){
		return (key === this.keys.DOWN || key === this.keys.PGDN) ? true : false;
	},

	allowedKey: function(key){
		// add support for numeric keys 0-9
		if (key >= 96 && key <= 105) {
			key = 'NUMPAD';
		}

		switch (key) {
			case this.keys.TAB :
			case this.keys.BACK :
			case this.keys.LEFT :
			case this.keys.RIGHT :
			case this.keys.PERIOD :
			case this.keys.MINUS :
			case this.keys.NUMPAD_DECIMAL :
			case this.keys.NUMPAD_SUBTRACT :
			case 'NUMPAD' :
				return true;
			default :
				return (/[0-9\-\.]/).test(String.fromCharCode(key));
		}
	},

	propagate: function(n,e) {
		$.ui.plugin.call(this, n, [e, this.ui()]);
		return this.element.triggerHandler(n == "step" ? n : "step"+n, [e, this.ui()], this.options[n]);
	}

});

$.ui.stepper.defaults = {
	min: 0,
	max: 10,
	step: 1,
	start: 0,
	decimals: 0,
	format: '',
	symbol: '$'
};

})(jQuery);


text:
<?php

namespace Google\Site_Kit\Core\Util;

/**
 * Class for input superglobal access.
 *
 * @since 1.1.2
 * @access private
 * @ignore
 */
class Input {
	/**
	 * Map of input type to superglobal array.
	 *
	 * For use as fallback only.
	 *
	 * @since 1.1.4
	 * @var array
	 */
	protected $fallback_map;

	/**
	 * Constructor.
	 *
	 * @since 1.1.4
	 */
	public function __construct() {
		// Fallback map for environments where filter_input may not work with ENV or SERVER types.
		$this->fallback_map = array(
			INPUT_ENV    => $_ENV,
			INPUT_SERVER => $_SERVER, // phpcs:ignore WordPress.VIP.SuperGlobalInputUsage
		);
	}

	/**
	 * Gets a specific external variable by name and optionally filters it.
	 *
	 * @since 1.1.2
	 *
	 * @link https://php.net/manual/en/function.filter-input.php
	 *
	 * @param int    $type               One of INPUT_GET, INPUT_POST, INPUT_COOKIE, INPUT_SERVER, or INPUT_ENV.
	 * @param string $variable_name      Name of a variable to get.
	 * @param int    $filter [optional]  The ID of the filter to apply. The manual page lists the available filters.
	 * @param mixed  $options [optional] Associative array of options or bitwise disjunction of flags.
	 *                                   If filter accepts options, flags can be provided in "flags" field of array.
	 * @return mixed                     Value of the requested variable on success,
	 *                                      FALSE if the filter fails,
	 *                                      NULL if the $variable_name variable is not set.
	 *
	 *                                      If the flag FILTER_NULL_ON_FAILURE is used, it returns FALSE if the variable is not set
	 *                                      and NULL if the filter fails.
	 */
	public function filter( $type, $variable_name, $filter = FILTER_DEFAULT, $options = null ) {
		$value = filter_input( $type, $variable_name, $filter, $options );

		// Fallback for environments where filter_input may not work with specific types.
		if (
			// Only use this fallback for affected input types.
			isset( $this->fallback_map[ $type ] )
			// Only use the fallback if the value is not-set (could be either depending on FILTER_NULL_ON_FAILURE).
			&& in_array( $value, array( null, false ), true )
			// Only use the fallback if the key exists in the input map.
			&& array_key_exists( $variable_name, $this->fallback_map[ $type ] )
		) {
			return filter_var( $this->fallback_map[ $type ][ $variable_name ], $filter, $options );
		}

		return $value;
	}
}


text:
using System.Collections.Generic;
using AssemblyLine.DAL.Entities;

namespace AssemblyLine.Models
{
    public class ProjectLineCycleModel
    {
        public int Id { get; set; }

        public CycleStatus Status { get; set; }

        public List<ProjectCycleMilestoneListModel> Milestones { get; set; }
    }
}


text:
var child_process = require('child_process');

module.exports = function(grunt) {
  'use strict';

  require('load-grunt-tasks')(grunt);

  var pkg = require('./package.json');
  var protractorConfig = grunt.option('protractorConfig') || 'ui/common/tests/ci.conf.js';

  var config = pkg.gruntConfig || {};

  config.grunt = grunt;
  config.pkg = pkg;
  config.protractorConfig = protractorConfig;

  var browserifyConf = { };

  require('./ui/admin/grunt/config/browserify')(config, browserifyConf);
  require('./ui/tasklist/grunt/config/browserify')(config, browserifyConf);
  require('./ui/cockpit/grunt/config/browserify')(config, browserifyConf);

  var copyConf = require('./grunt/config/copy');
  require('./ui/admin/grunt/config/copy')(config, copyConf);
  require('./ui/cockpit/grunt/config/copy')(config, copyConf);
  require('./ui/tasklist/grunt/config/copy')(config, copyConf);

  var lessConf = { };
  require('./grunt/config/less')(config, lessConf, {
    appName: 'admin',
    sourceDir: pkg.gruntConfig.adminSourceDir,
    buildTarget: pkg.gruntConfig.adminBuildTarget,
  });
  require('./grunt/config/less')(config, lessConf, {
    appName: 'cockpit',
    sourceDir: pkg.gruntConfig.cockpitSourceDir,
    buildTarget: pkg.gruntConfig.cockpitBuildTarget,
  });
  require('./grunt/config/less')(config, lessConf, {
    appName: 'tasklist',
    sourceDir: pkg.gruntConfig.tasklistSourceDir,
    buildTarget: pkg.gruntConfig.tasklistBuildTarget,
  });

  var localesConf = { };
  require('./grunt/config/localescompile')(config, localesConf, {
    appName: 'tasklist',
    sourceDir: pkg.gruntConfig.tasklistSourceDir,
    buildTarget: pkg.gruntConfig.tasklistBuildTarget,
  });

  var watchConf = {
    commons_styles: {
      options: {
        liverreload: false,
      },
      files: [
        'ui/common/styles/**/*.less',
        'node_modules/camunda-commons-ui/{lib,resources}/**/*.less'
      ],
      tasks: ['less']
    }
  };
  require('./ui/tasklist/grunt/config/watch')(config, watchConf);
  require('./ui/cockpit/grunt/config/watch')(config, watchConf);
  require('./ui/admin/grunt/config/watch')(config, watchConf);

  var uglifyConf = {};
  require('./grunt/config/uglify')(config, uglifyConf);
  require('./ui/admin/grunt/config/uglify')(config, uglifyConf);
  require('./ui/tasklist/grunt/config/uglify')(config, uglifyConf);
  require('./ui/cockpit/grunt/config/uglify')(config, uglifyConf);

  grunt.initConfig({
    buildMode:        'dev',

    pkg:              pkg,

    browserify:       browserifyConf,

    copy:             copyConf,

    less:             lessConf,

    localescompile:   localesConf,

    uglify:           uglifyConf,

    clean:            require('./grunt/config/clean')(config),

    watch:            watchConf,

    protractor:       require('./grunt/config/protractor')(config)
  });

  require('camunda-commons-ui/grunt/tasks/localescompile')(grunt);

  grunt.registerTask('build', function(mode, app) {

    if(typeof app !== 'undefined') {
      console.log(' ------------  will build ' + app + ' -------------');
      var objs = [browserifyConf, copyConf, lessConf, localesConf, watchConf, uglifyConf];
      for(var i = 0; i < objs.length; i++) {
        var obj = objs[i];
        for (var key in obj) {
          if (obj.hasOwnProperty(key) && key.toLowerCase().indexOf(app) === -1 && key !== 'options' &&
                                         key.toLowerCase().indexOf('webapp') === -1 &&
                                         key.toLowerCase().indexOf('sdk') === -1) {
              delete obj[key];
          }
        }
      }
    }

    grunt.config.data.buildMode = mode || 'prod';

    var tasksToRun = [
      'clean',
      'browserify',
      'copy',
      'less'
    ];

    if(typeof app === 'undefined' || app === 'tasklist') {
      tasksToRun.push('localescompile');
    }

    if(grunt.config.data.buildMode === 'prod') {
      tasksToRun.push('uglify');
    }

    grunt.task.run(tasksToRun);

  });

  grunt.registerTask('auto-build', function(app) {
    if(app) {
      grunt.task.run([
        'build:dev:' + app,
        'watch'
      ]);
    } else {
      grunt.task.run([
        'build:dev',
        'watch'
      ]);
    }
  });

  grunt.registerTask('ensureSelenium', function() {
    // async task
    var done = this.async();

    child_process.execFile('node', [__dirname + '/node_modules/grunt-protractor-runner/node_modules/protractor/bin/webdriver-manager', '--chrome', 'update'], function(err) {
      done();
    });
  });

  grunt.registerTask('default', ['build']);

  grunt.registerTask('test-e2e', ['ensureSelenium', 'protractor:e2e']);
};


text:
using System;
using System.Collections.Generic;
using System.Linq.Expressions;
using System.Text;
using System.Web.Mvc;

namespace MvcTemplate.Components.Extensions
{
    public static class MvcTreeExtensions
    {
        public static MvcHtmlString TreeFor<TModel>(this HtmlHelper<TModel> html, Expression<Func<TModel, MvcTree>> expression, Int32? hideDepth = null, Boolean readOnly = false)
        {
            MvcTree model = ModelMetadata.FromLambdaExpression(expression, html.ViewData).Model as MvcTree;
            String name = ExpressionHelper.GetExpressionText(expression) + ".SelectedIds";
            TagBuilder tree = new TagBuilder("div");

            tree.AddCssClass("mvc-tree");
            tree.Attributes["data-for"] = name;

            if (readOnly)
                tree.Attributes["class"] += " mvc-tree-readonly";

            tree.InnerHtml = IdsFor(name, model) + ViewFor(model, hideDepth);

            return new MvcHtmlString(tree.ToString());
        }

        private static String IdsFor(String name, MvcTree model)
        {
            StringBuilder inputs = new StringBuilder();
            TagBuilder input = new TagBuilder("input");
            input.Attributes["type"] = "hidden";
            input.Attributes["name"] = name;

            foreach (Int32 id in model.SelectedIds)
            {
                input.Attributes["value"] = id.ToString();
                inputs.Append(input.ToString(TagRenderMode.SelfClosing));
            }

            TagBuilder ids = new TagBuilder("div");
            ids.InnerHtml = inputs.ToString();
            ids.AddCssClass("mvc-tree-ids");

            return ids.ToString();
        }
        private static String ViewFor(MvcTree model, Int32? hideDepth)
        {
            TagBuilder root = new TagBuilder("ul");
            root.AddCssClass("mvc-tree-view");

            return Build(model, root, model.Nodes, 1, hideDepth).ToString();
        }
        private static TagBuilder Build(MvcTree model, TagBuilder branch, List<MvcTreeNode> nodes, Int32? depth, Int32? hideDepth)
        {
            StringBuilder nodeBuilder = new StringBuilder();

            foreach (MvcTreeNode node in nodes)
            {
                TagBuilder item = new TagBuilder("li");
                item.InnerHtml = "<i></i>";

                if (node.Id != null)
                {
                    if (model.SelectedIds.Contains(node.Id.Value))
                        item.AddCssClass("mvc-tree-checked");

                    item.Attributes["data-id"] = node.Id.ToString();
                }

                TagBuilder anchor = new TagBuilder("a");
                anchor.Attributes["href"] = "#";
                anchor.InnerHtml += node.Title;

                item.InnerHtml += anchor;

                if (node.Children.Count > 0)
                {
                    item.AddCssClass("mvc-tree-branch");

                    if (hideDepth <= depth)
                        item.AddCssClass("mvc-tree-collapsed");

                    item.InnerHtml += Build(model, new TagBuilder("ul"), node.Children, depth + 1, hideDepth).ToString();
                }

                nodeBuilder.Append(item);
            }

            branch.InnerHtml = nodeBuilder.ToString();

            return branch;
        }
    }
}


text:
"""CPU module for Nehalem-EX"""

import bits
from cpu_gen import mwait_hint_to_cstate
from cpu_nhm import register_tests, generate_mwait_menu

name = 'Nehalem-EX'

def is_cpu():
    return bits.cpuid(bits.bsp_apicid(),1).eax & ~0xf == 0x206e0

def init():
    pass


text:
.class Lcom/samsung/android/settings/display/FullScreenAppsSettings$1;
.super Landroid/os/Handler;
.source "FullScreenAppsSettings.java"

# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Lcom/samsung/android/settings/display/FullScreenAppsSettings;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation

# instance fields
.field final synthetic this$0:Lcom/samsung/android/settings/display/FullScreenAppsSettings;

# direct methods
.method constructor <init>(Lcom/samsung/android/settings/display/FullScreenAppsSettings;)V
    .locals 0

    iput-object p1, p0, Lcom/samsung/android/settings/display/FullScreenAppsSettings$1;->this$0:Lcom/samsung/android/settings/display/FullScreenAppsSettings;

    invoke-direct {p0}, Landroid/os/Handler;-><init>()V

    return-void
.end method

# virtual methods
.method public handleMessage(Landroid/os/Message;)V
    .locals 4

    const/4 v3, 0x1

    const/4 v2, 0x0

    iget v0, p1, Landroid/os/Message;->what:I

    const/16 v1, 0x3e9

    if-ne v0, v1, :cond_0

    iget-object v0, p0, Lcom/samsung/android/settings/display/FullScreenAppsSettings$1;->this$0:Lcom/samsung/android/settings/display/FullScreenAppsSettings;

    invoke-static {v0}, Lcom/samsung/android/settings/display/FullScreenAppsSettings;->-get12(Lcom/samsung/android/settings/display/FullScreenAppsSettings;)Lcom/samsung/android/settings/display/FullScreenAppsShowTypePreference;

    move-result-object v0

    iget v0, v0, Lcom/samsung/android/settings/display/FullScreenAppsShowTypePreference;->mSelectedShowType:I

    if-nez v0, :cond_1

    iget-object v0, p0, Lcom/samsung/android/settings/display/FullScreenAppsSettings$1;->this$0:Lcom/samsung/android/settings/display/FullScreenAppsSettings;

    invoke-static {v0, v3}, Lcom/samsung/android/settings/display/FullScreenAppsSettings;->-set1(Lcom/samsung/android/settings/display/FullScreenAppsSettings;Z)Z

    :goto_0
    iget-object v0, p0, Lcom/samsung/android/settings/display/FullScreenAppsSettings$1;->this$0:Lcom/samsung/android/settings/display/FullScreenAppsSettings;

    invoke-static {v0, v3}, Lcom/samsung/android/settings/display/FullScreenAppsSettings;->-set0(Lcom/samsung/android/settings/display/FullScreenAppsSettings;Z)Z

    iget-object v0, p0, Lcom/samsung/android/settings/display/FullScreenAppsSettings$1;->this$0:Lcom/samsung/android/settings/display/FullScreenAppsSettings;

    invoke-static {v0}, Lcom/samsung/android/settings/display/FullScreenAppsSettings;->-wrap2(Lcom/samsung/android/settings/display/FullScreenAppsSettings;)V

    :cond_0
    return-void

    :cond_1
    iget-object v0, p0, Lcom/samsung/android/settings/display/FullScreenAppsSettings$1;->this$0:Lcom/samsung/android/settings/display/FullScreenAppsSettings;

    invoke-static {v0, v2}, Lcom/samsung/android/settings/display/FullScreenAppsSettings;->-set1(Lcom/samsung/android/settings/display/FullScreenAppsSettings;Z)Z

    goto :goto_0
.end method


text:
package org.aesh.command.man;

import org.aesh.command.man.parser.ManParameter;
import org.aesh.utils.ANSI;
import org.aesh.utils.Config;
import org.junit.Assert;
import org.junit.Test;

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

import static org.junit.Assert.assertEquals;

/**
 * @author Ståle W. Pedersen
 */
public class ManParameterTest {

    @Test
    public void testParameter() {

        List<String> input = new ArrayList<String>();
        input.add("*-a, --attribute*='ATTRIBUTE'::");
        Assert.assertEquals("  "+ ANSI.BOLD+
                "-a, --attribute"+
                ANSI.DEFAULT_TEXT+
                "="+ ANSI.UNDERLINE+
                "ATTRIBUTE"+
                ANSI.DEFAULT_TEXT+ Config.getLineSeparator(),
                new ManParameter().parseParams(input, 80).printToTerminal());

        input.clear();
        input.add("*-a, --attribute*='ATTRIBUTE'::");
        input.add("   Backend output file format");
        assertEquals("  "+ ANSI.BOLD+
                "-a, --attribute"+
                ANSI.DEFAULT_TEXT+
                "="+ ANSI.UNDERLINE+
                "ATTRIBUTE"+
                ANSI.DEFAULT_TEXT+ Config.getLineSeparator()+
                "    Backend output file format"+" "+ Config.getLineSeparator()+
                " "+ Config.getLineSeparator(),
                new ManParameter().parseParams(input, 80).printToTerminal());

    }
}


text:
@protocol AWRPlaylist;

NS_ASSUME_NONNULL_BEGIN

@interface KIFUITestActor (EXAdditions)

- (void)waitForMusic;
- (void)screenshotWithIdentifier:(NSString *)identifier;
- (void)scrollToBottom;
- (void)scrollToTop;
- (void)setSongName:(NSString *)songName
         artistName:(NSString *)artistName
            twitter:(NSString *)twitter
            website:(NSString *)website
             lyrics:(NSString *)lyrics
                art:(UIImage *)art;
- (void)goToLyricsTab;
- (void)goToTwitterTab;
- (void)goToWebsiteTab;

@end

NS_ASSUME_NONNULL_END


text:
package VMOMI::HostVFlashManagerVFlashCacheConfigSpec;
use parent 'VMOMI::DynamicData';

use strict;
use warnings;

our @class_ancestors = (
    'DynamicData',
);

our @class_members = (
    ['defaultVFlashModule', undef, 0, ],
    ['swapCacheReservationInGB', undef, 0, ],
);

sub get_class_ancestors {
    return @class_ancestors;
}

sub get_class_members {
    my $class = shift;
    my @super_members = $class->SUPER::get_class_members();
    return (@super_members, @class_members);
}

1;


text:
using System;
using System.IO;
using NServiceKit.Service;
using System.Net;

namespace NServiceKit.ServiceClient.Web
{
    using System.ServiceModel;
    using System.ServiceModel.Channels;
    using NServiceKit.Text;
    using NServiceKit.Service;

    /// A SOAP 12 service client.
    public class Soap12ServiceClient : WcfServiceClient
    {
        /// Initializes a new instance of the NServiceKit.ServiceClient.Web.Soap12ServiceClient class.
        ///
        /// <param name="uri">URI of the document.</param>
        public Soap12ServiceClient(string uri)
        {
            this.Uri = uri.WithTrailingSlash() + "Soap12";
            this.StoreCookies = true;
        }

        private WSHttpBinding binding;

        private Binding WsHttpBinding
        {
            get
            {
                if (this.binding == null)
                {
                    this.binding = new WSHttpBinding {
                        MaxReceivedMessageSize = int.MaxValue,
                        HostNameComparisonMode = HostNameComparisonMode.StrongWildcard,
                        MaxBufferPoolSize = 524288,
                    };
                    this.binding.Security.Mode = SecurityMode.None;
                    // CCB Custom
                    // Yes, you need this to manage cookies yourself.  Seems counterintutive, but set to true,
                    // it only means that the framework will manage cookie propagation for the same call, which is
                    // not what we want.
                    if (StoreCookies)
                        this.binding.AllowCookies = false;
                }
                return this.binding;
            }
        }

        /// Gets the binding.
        ///
        /// <value>The binding.</value>
        protected override Binding Binding
        {
            get { return this.WsHttpBinding; }
        }

        /// Gets the message version.
        ///
        /// <value>The message version.</value>
        protected override MessageVersion MessageVersion
        {
            get { return MessageVersion.Default; }
        }

        /// Sets a proxy.
        ///
        /// <param name="proxyAddress">The proxy address.</param>
        public override void SetProxy(Uri proxyAddress)
        {
            var wsHttpBinding = (WSHttpBinding)Binding;

            wsHttpBinding.ProxyAddress = proxyAddress;
            wsHttpBinding.UseDefaultWebProxy = false;
            wsHttpBinding.BypassProxyOnLocal = false;
            return;
        }
    }
}
#endif


text:
import Tkinter as tk
import ttk
import tkMessageBox
from TkDialog import TkDialog

###########################################################################
## The dialog
###########################################################################
class Dialog(TkDialog):
    def __init__(self,is3D = False):
        TkDialog.__init__(self)

        #Here you can make things pretty
        self.arraychannel = None

        self.wm_geometry("600x120")
        self.title("Spot Resizer - Copyright (c) 2018 Egor Zindy")

        self.add_menu("File",["Update objects", "Open configuration", "Save configuration","|","Exit"])
        self.add_menu("Help",["About"])

        #widget = [ttk.Combobox(self.mainframe, textvariable=self.arrayvar("objects"), values=[], exportselection=0, state="readonly"),
        #        ttk.Combobox(self.mainframe, textvariable=self.arrayvar("cc_type"), values=list_colourcoding, exportselection=0, state="readonly")]
        #self.add_control("Object and coding",widget, "ctrl_objects")

        widget = ttk.Combobox(self.mainframe, textvariable=self.arrayvar("objects"), values=[], exportselection=0, state="readonly")
        self.add_control("Spot object",widget, name="ctrl_objects", tick=None)

        widget = [ttk.Entry(self.mainframe,textvariable=self.arrayvar("xsize")),
                ttk.Entry(self.mainframe,textvariable=self.arrayvar("ysize"))]
        label = "Spot um size X/Y"
        if is3D:
            widget.append( ttk.Entry(self.mainframe,textvariable=self.arrayvar("zsize")) )
            label +="/Z"

        self.add_control(label,widget,tick=None)

        widget = ttk.Button(self.mainframe, text="Apply", name="btn3")
        self.add_control("",widget)

        #we have all the ingredients, now bake the dialog box!
        self.bake(has_cancel=False) #, has_preview=True) #"Calculate")

    def About(self):
        '''About XTSpotSize'''
        tkMessageBox.showinfo("About XTSpotResize", "Source code available from https://github.com/zindy/Imaris/\n\nAuthor: Egor Zindy <egor.zindy@manchester.ac.uk>\nWellcome Centre for Cell-Matrix Research\nUniversity of Manchester (UK)")

    def SetDefaults(self):
        #Here you set default values
        #self.arrayvar["plot_type"] = list_plots[0]
        pass

    def SetObjects(self, object_list, selected=0):
        self.SetDefaults()

        n_objects = len(object_list)
        self.ctrl_objects['values'] = object_list
        self.ctrl_objects.current(selected)

    def OnSaveFigure(self,*args):
        self.SaveFigure()

    def SaveFigure(self):
        print "Saving the figure..."

if __name__ == "__main__":
    app=Dialog(is3D=True)
    app.mainloop()


text:
go-digital-signage
========

[![Build Status](https://travis-ci.org/peketamin/go-digital-signage.svg?branch=master)](https://travis-ci.org/peketamin/go-digital-signage)

Overview
--------
Simple web server for pages like digital-signage.
Display some clipped HTMLs and images randomly in a DB.

This sample product **made for myself to study golang** :flushed: .

Description
--------
Pages in sqlite3 database are displayed in cycles.
Next page is picked up from remaining pages those are not displayed yet in a round.

Demo
--------
![Anime Gif](https://github.com/peketamin/go-digital-signage/blob/5dd11f4e8f294879b4907d17abab9cdc1ba914f0/demo.gif)

Usage
--------
Open `http://localhost:8080` on your browser and access to,

- `/`: view page randomly that pickuped from never watched pages in a round.
- `/add`: add new data
- `/[0-9]+`: view a specified page
- `/edit/[0-9]+`: edit a specified page

### How to modify the duration of displaying pages
Add parameter when start the program.
This means rotation pages every 15 seconds.

```bash
$ ./go-digital-signage 15
```

(Default: 86400 sec.)

<!--
VS.
--------
-->

Requirements
--------
### [The Go Programming Language](http://golang.org/)
as known as *golang*.

### [SQLite3](http://www.sqlite.org/).

Download from [SQLite Download Page](http://www.sqlite.org/download.html) precompiled archive and install them.

User of Linux or Mac may also choose following ways,

- Linux: using package manager of your distribution.
- Mac: using [Homebrew — The missing package manager for OS X](http://brew.sh/) or [The MacPorts Project -- Home](http://www.macports.org/)

Install
--------
Download zip or `git clone` this.

```bash
$ cd go-digital-signage
$ go build
$ ./go-digital-signage
```

<!--
Contribution
--------

1. Fork ([https://github.com/peketamin/go-digital-signage/fork](https://github.com/peketamin/go-digital-signage/fork))
2. Create a feature branch
3. Commit your changes
4. Rebase your local changes against the master branch
5. Run test suite with the `go test ./...` command and confirm that it passes
6. Run `gofmt -s`
7. Create new Pull Request
-->

TODO
--------
- Listing items page
- Disable flag into page data struct
- Authentification

Libraries
--------
- [github.com/jinzhu/gorm](https://github.com/jinzhu/gorm)
- [github.com/mattn/go-sqlite3](https://github.com/mattn/go-sqlite3)
- [github.com/go-sql-driver/mysql](https://github.com/go-sql-driver/mysql)
- [github.com/lib/pq](https://github.com/lib/pq)

Licence
--------
[MIT](https://github.com/tcnksm/tool/blob/master/LICENCE)

Author
--------
[peketamin](https://github.com/peketamin)

Thanks
----
- [tk0miya](https://twitter.com/tk0miya) ([blockdiag](http://blockdiag.com) developer)
- japanese: [わかりやすいREADME.mdを書く | SOTA](http://deeeet.com/writing/2014/07/31/readme/)


text:
<?xml version="1.0" encoding="utf-8"?>
<resources>
    <color name="ingest_date_tile_text">#ff33b5e5</color>
    <color name="ingest_highlight_semitransparent">#8833b5e5</color>
</resources>


text:
package management

import "github.com/packet-guardian/pg-dhcp/internal/server"

type Network int

func (n *Network) GetNameList(_ int, reply *[]string) error {
	*reply = server.GetNetworkList()
	return nil
}


text:
function(git_base_dir)
  git_dir("${ARGN}")
  ans(res)
  path_component("${res}" --parent-dir)
  ans(res)
  return_ref(res)
endfunction()


text:
import { Component } from '@angular/core';

@Component({
  selector: 'demo-app',
  template: '<weighted-screen [handicap] = "100" ></weighted-screen>',
  styles: [
    `
    :host {
      border: solid 1px #eee;
      border-bottom: solid 1px #ccc;
      display: block;
    }
    `
  ]
})

export class Demo {
}


text:
/*eslint-env node*/

module.exports = function(config){
    config.set({

        basePath : "./",

        files : [
            "bower_components/angular/angular.js",
            "bower_components/angular-route/angular-route.js",
            "bower_components/angular-mocks/angular-mocks.js",
            "app/components/**/*.js",
            "app/view*/**/*.js",
            "app/controllers/*.js",
            "app/services/*.js",
            "app/directives/*.js"
        ],

        autoWatch : true,

        frameworks: ["jasmine"],

        browsers : ["Firefox"],

        plugins : [
            "karma-chrome-launcher",
            "karma-firefox-launcher",
            "karma-jasmine",
            "karma-junit-reporter"
        ],

        junitReporter : {
            outputFile: "test_out/unit.xml",
            suite: "unit"
        },

        single_run: true

    });
};