code
stringlengths
3
1.05M
repo_name
stringlengths
4
116
path
stringlengths
3
942
language
stringclasses
30 values
license
stringclasses
15 values
size
int32
3
1.05M
line_mean
float64
0.5
100
line_max
int64
1
1k
alpha_frac
float64
0.25
1
autogenerated
bool
1 class
/* * The MIT License * Copyright © 2014 Cube Island * * Permission is hereby granted, free of charge, to any person obtaining a copy * of this software and associated documentation files (the "Software"), to deal * in the Software without restriction, including without limitation the rights * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell * copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: * * The above copyright notice and this permission notice shall be included in * all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * THE SOFTWARE. */ package de.cubeisland.engine.modularity.core; import java.lang.reflect.Field; import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import java.util.ArrayList; import java.util.Comparator; import java.util.HashMap; import java.util.LinkedList; import java.util.Map; import java.util.PriorityQueue; import java.util.Queue; import java.util.TreeMap; import javax.inject.Provider; import de.cubeisland.engine.modularity.core.graph.Dependency; import de.cubeisland.engine.modularity.core.graph.DependencyInformation; import de.cubeisland.engine.modularity.core.graph.meta.ModuleMetadata; import de.cubeisland.engine.modularity.core.graph.meta.ServiceDefinitionMetadata; import de.cubeisland.engine.modularity.core.graph.meta.ServiceImplementationMetadata; import de.cubeisland.engine.modularity.core.graph.meta.ServiceProviderMetadata; import de.cubeisland.engine.modularity.core.marker.Disable; import de.cubeisland.engine.modularity.core.marker.Enable; import de.cubeisland.engine.modularity.core.marker.Setup; import de.cubeisland.engine.modularity.core.service.ServiceProvider; import static de.cubeisland.engine.modularity.core.LifeCycle.State.*; public class LifeCycle { private static final Field MODULE_META_FIELD; private static final Field MODULE_MODULARITY_FIELD; private static final Field MODULE_LIFECYCLE; static { try { MODULE_META_FIELD = Module.class.getDeclaredField("metadata"); MODULE_META_FIELD.setAccessible(true); MODULE_MODULARITY_FIELD = Module.class.getDeclaredField("modularity"); MODULE_MODULARITY_FIELD.setAccessible(true); MODULE_LIFECYCLE = Module.class.getDeclaredField("lifeCycle"); MODULE_LIFECYCLE.setAccessible(true); } catch (NoSuchFieldException e) { throw new IllegalStateException(); } } private Modularity modularity; private DependencyInformation info; private State current = NONE; private Object instance; private Method enable; private Method disable; private Map<Integer, Method> setup = new TreeMap<Integer, Method>(); private Map<Dependency, SettableMaybe> maybes = new HashMap<Dependency, SettableMaybe>(); private Queue<LifeCycle> impls = new LinkedList<LifeCycle>(); public LifeCycle(Modularity modularity) { this.modularity = modularity; } public LifeCycle load(DependencyInformation info) { this.info = info; this.current = LOADED; return this; } public LifeCycle provide(ValueProvider provider) { this.instance = provider; this.current = PROVIDED; return this; } public LifeCycle initProvided(Object object) { this.instance = object; this.current = PROVIDED; return this; } public boolean isIn(State state) { return current == state; } public LifeCycle instantiate() { if (isIn(NONE)) { throw new IllegalStateException("Cannot instantiate when not loaded"); } if (isIn(LOADED)) { try { if (info instanceof ServiceDefinitionMetadata) { ClassLoader classLoader = info.getClassLoader(); if (classLoader == null) // may happen when loading from classpath { classLoader = modularity.getClass().getClassLoader(); // get parent classloader then } Class<?> instanceClass = Class.forName(info.getClassName(), true, classLoader); instance = new ServiceProvider(instanceClass, impls); // TODO find impls in modularity and link them to this // TODO transition all impls to INSTANTIATED? } else { this.instance = info.injectionPoints().get(INSTANTIATED.name(0)).inject(modularity, this); if (instance instanceof Module) { MODULE_META_FIELD.set(instance, info); MODULE_MODULARITY_FIELD.set(instance, modularity); MODULE_LIFECYCLE.set(instance, this); } info.injectionPoints().get(INSTANTIATED.name(1)).inject(modularity, this); findMethods(); } } catch (ClassNotFoundException e) { throw new IllegalStateException(e); } catch (IllegalAccessException e) { throw new IllegalStateException(e); } current = INSTANTIATED; } // else State already reached or provided return this; } public LifeCycle setup() { if (isIn(NONE)) { throw new IllegalStateException("Cannot instantiate when not loaded"); } if (isIn(LOADED)) { this.instantiate(); } if (isIn(INSTANTIATED)) { // TODO abstract those methods away for (Method method : setup.values()) { invoke(method); } for (LifeCycle impl : impls) { impl.setup(); } current = SETUP; } // else reached or provided return this; } public LifeCycle enable() { if (isIn(NONE)) { throw new IllegalStateException("Cannot instantiate when not loaded"); } if (isIn(LOADED)) { this.instantiate(); } if (isIn(INSTANTIATED)) { this.setup(); } if (isIn(SETUP)) { this.modularity.log("Enable " + info.getIdentifier().name()); modularity.runEnableHandlers(getInstance()); invoke(enable); for (SettableMaybe maybe : maybes.values()) { maybe.provide(getProvided(this)); } for (LifeCycle impl : impls) { impl.enable(); } current = ENABLED; } return this; } public LifeCycle disable() { if (isIn(ENABLED)) { modularity.runDisableHandlers(getInstance()); invoke(disable); for (SettableMaybe maybe : maybes.values()) { maybe.remove(); } // TODO if active impl replace in service with inactive OR disable service too // TODO if service disable all impls too modularity.getGraph().getNode(info.getIdentifier()).getPredecessors(); // TODO somehow implement reload too // TODO disable predecessors for (LifeCycle impl : impls) { impl.disable(); } current = DISABLED; } return this; } private void invoke(Method method) { if (method != null) { if (method.isAnnotationPresent(Setup.class)) { info.injectionPoints().get(SETUP.name(method.getAnnotation(Setup.class).value())) .inject(modularity, this); } else if (method.isAnnotationPresent(Enable.class)) { info.injectionPoints().get(ENABLED.name()).inject(modularity, this); } else { try { method.invoke(instance); } catch (IllegalAccessException e) { throw new IllegalStateException(e); } catch (IllegalArgumentException e) { throw new IllegalStateException(e); } catch (InvocationTargetException e) { throw new IllegalStateException(e); } } } } public boolean isInstantiated() { return instance != null; } private void findMethods() { // find enable and disable methods Class<?> clazz = instance.getClass(); for (Method method : clazz.getMethods()) { if (method.isAnnotationPresent(Enable.class)) { enable = method; } if (method.isAnnotationPresent(Disable.class)) { disable = method; } if (method.isAnnotationPresent(Setup.class)) { int value = method.getAnnotation(Setup.class).value(); setup.put(value, method); } } } public Object getInstance() { return instance; } @SuppressWarnings("unchecked") public Maybe getMaybe(LifeCycle other) { Dependency identifier = other == null ? null : other.getInformation().getIdentifier(); SettableMaybe maybe = maybes.get(identifier); if (maybe == null) { maybe = new SettableMaybe(getProvided(other)); maybes.put(identifier, maybe); } return maybe; } public Object getProvided(LifeCycle lifeCycle) { boolean enable = true; if (info instanceof ModuleMetadata) { enable = false; } if (instance == null) { this.instantiate(); } if (enable) { this.enable(); // Instantiate Setup and enable dependency before providing it to someone else } Object toSet = instance; if (toSet instanceof Provider) { toSet = ((Provider)toSet).get(); } if (toSet instanceof ValueProvider) { toSet = ((ValueProvider)toSet).get(lifeCycle, modularity); } return toSet; } public void addImpl(LifeCycle impl) { this.impls.add(impl); } public DependencyInformation getInformation() { return info; } public enum State { NONE, LOADED, INSTANTIATED, SETUP, ENABLED, DISABLED, SHUTDOWN, PROVIDED // TODO prevent changing / except shutdown? ; public String name(Integer value) { return value == null ? name() : name() + ":" + value; } } @Override public String toString() { return info.getIdentifier().name() + " " + super.toString(); } }
CubeEngine/Modularity
core/src/main/java/de/cubeisland/engine/modularity/core/LifeCycle.java
Java
mit
11,912
28.122249
119
0.567627
false
import { AppPage } from './app.po'; describe('material2 App', () => { let page: AppPage; beforeEach(() => { page = new AppPage(); }); it('should display welcome message', () => { page.navigateTo(); expect(page.getParagraphText()).toEqual('Welcome to app!'); }); });
dylan-smith/pokerleaguemanager
spikes/Material2/e2e/app.e2e-spec.ts
TypeScript
mit
291
19.785714
63
0.57732
false
Radiant.config do |config| config.define 'admin.title', :default => "Radiant CMS" config.define 'dev.host' config.define 'local.timezone', :allow_change => true, :select_from => lambda { ActiveSupport::TimeZone::MAPPING.keys.sort } config.define 'defaults.locale', :select_from => lambda { Radiant::AvailableLocales.locales }, :allow_blank => true config.define 'defaults.page.parts', :default => "Body,Extended" config.define 'defaults.page.status', :select_from => lambda { Status.selectable_values }, :allow_blank => true, :default => "Draft" config.define 'defaults.page.filter', :select_from => lambda { TextFilter.descendants.map { |s| s.filter_name }.sort }, :allow_blank => true config.define 'defaults.page.fields' config.define 'defaults.snippet.filter', :select_from => lambda { TextFilter.descendants.map { |s| s.filter_name }.sort }, :allow_blank => true config.define 'pagination.param_name', :default => 'page' config.define 'pagination.per_page_param_name', :default => 'per_page' config.define 'admin.pagination.per_page', :type => :integer, :default => 50 config.define 'site.title', :default => "Your site title", :allow_blank => false config.define 'site.host', :default => "www.example.com", :allow_blank => false config.define 'user.allow_password_reset?', :default => true end
jcasimir/radiant
config/initializers/radiant_config.rb
Ruby
mit
1,331
77.294118
145
0.705485
false
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>menhirlib: 48 s 🏆</title> <link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" /> <link href="../../../../../bootstrap.min.css" rel="stylesheet"> <link href="../../../../../bootstrap-custom.css" rel="stylesheet"> <link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet"> <script src="../../../../../moment.min.js"></script> <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries --> <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script> <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script> <![endif]--> </head> <body> <div class="container"> <div class="navbar navbar-default" role="navigation"> <div class="container-fluid"> <div class="navbar-header"> <a class="navbar-brand" href="../../../../.."><i class="fa fa-lg fa-flag-checkered"></i> Coq bench</a> </div> <div id="navbar" class="collapse navbar-collapse"> <ul class="nav navbar-nav"> <li><a href="../..">clean / released</a></li> <li class="active"><a href="">8.13.1 / menhirlib - 20200612</a></li> </ul> </div> </div> </div> <div class="article"> <div class="row"> <div class="col-md-12"> <a href="../..">« Up</a> <h1> menhirlib <small> 20200612 <span class="label label-success">48 s 🏆</span> </small> </h1> <p>📅 <em><script>document.write(moment("2022-01-13 08:04:05 +0000", "YYYY-MM-DD HH:mm:ss Z").fromNow());</script> (2022-01-13 08:04:05 UTC)</em><p> <h2>Context</h2> <pre># Packages matching: installed # Name # Installed # Synopsis base-bigarray base base-threads base base-unix base conf-findutils 1 Virtual package relying on findutils conf-gmp 3 Virtual package relying on a GMP lib system installation coq 8.13.1 Formal proof management system num 1.4 The legacy Num library for arbitrary-precision integer and rational arithmetic ocaml 4.10.2 The OCaml compiler (virtual package) ocaml-base-compiler 4.10.2 Official release 4.10.2 ocaml-config 1 OCaml Switch Configuration ocamlfind 1.9.1 A library manager for OCaml zarith 1.12 Implements arithmetic and logical operations over arbitrary-precision integers # opam file: opam-version: &quot;2.0&quot; synopsis: &quot;A support library for verified Coq parsers produced by Menhir&quot; maintainer: &quot;francois.pottier@inria.fr&quot; authors: [ &quot;Jacques-Henri Jourdan &lt;jacques-henri.jourdan@lri.fr&gt;&quot; ] homepage: &quot;https://gitlab.inria.fr/fpottier/menhir&quot; dev-repo: &quot;git+https://gitlab.inria.fr/fpottier/menhir.git&quot; bug-reports: &quot;jacques-henri.jourdan@lri.fr&quot; license: &quot;LGPL-3.0-or-later&quot; build: [ [make &quot;-C&quot; &quot;coq-menhirlib&quot; &quot;-j%{jobs}%&quot;] ] install: [ [make &quot;-C&quot; &quot;coq-menhirlib&quot; &quot;install&quot;] ] depends: [ &quot;coq&quot; { &gt;= &quot;8.7&quot; &amp; &lt; &quot;8.14&quot; } ] conflicts: [ &quot;menhir&quot; { != &quot;20200612&quot; } ] tags: [ &quot;date:2020-06-12&quot; &quot;logpath:MenhirLib&quot; ] url { src: &quot;https://gitlab.inria.fr/fpottier/menhir/-/archive/20200612/archive.tar.gz&quot; checksum: [ &quot;md5=eb1c13439a00195ee01e4a2e83b3e991&quot; &quot;sha512=c94ddc2b2d8b9f5d05d8493a3ccd4a32e4512c3bd19ac8948905eb64bb6f2fd9e236344d2baf3d2ebae379d08d5169c99aa5e721c65926127e22ea283eba6167&quot; ] } </pre> <h2>Lint</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Dry install 🏜️</h2> <p>Dry install with the current Coq version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam install -y --show-action coq-menhirlib.20200612 coq.8.13.1</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <p>Dry install without Coq/switch base, to test if the problem was incompatibility with the current Coq/OCaml version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Install dependencies</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam list; echo; ulimit -Sv 4000000; timeout 4h opam install -y --deps-only coq-menhirlib.20200612 coq.8.13.1</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>12 s</dd> </dl> <h2>Install 🚀</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam list; echo; ulimit -Sv 16000000; timeout 4h opam install -y -v coq-menhirlib.20200612 coq.8.13.1</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>48 s</dd> </dl> <h2>Installation size</h2> <p>Total: 6 M</p> <ul> <li>2 M <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Interpreter_complete.vo</code></li> <li>1 M <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Main.vo</code></li> <li>1 M <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Validator_complete.vo</code></li> <li>300 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Interpreter.vo</code></li> <li>236 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Interpreter_correct.vo</code></li> <li>133 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Validator_safe.vo</code></li> <li>114 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Interpreter_complete.glob</code></li> <li>102 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Automaton.vo</code></li> <li>71 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Alphabet.vo</code></li> <li>62 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Grammar.vo</code></li> <li>47 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Interpreter.glob</code></li> <li>43 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Validator_complete.glob</code></li> <li>35 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Alphabet.glob</code></li> <li>33 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Interpreter_complete.v</code></li> <li>29 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Validator_classes.vo</code></li> <li>21 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Interpreter_correct.glob</code></li> <li>20 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Validator_safe.glob</code></li> <li>18 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Interpreter.v</code></li> <li>15 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Validator_complete.v</code></li> <li>12 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Grammar.glob</code></li> <li>9 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Automaton.glob</code></li> <li>8 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Alphabet.v</code></li> <li>8 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Validator_safe.v</code></li> <li>8 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Main.glob</code></li> <li>7 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Validator_classes.glob</code></li> <li>7 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Interpreter_correct.v</code></li> <li>6 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Automaton.v</code></li> <li>6 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Grammar.v</code></li> <li>3 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Main.v</code></li> <li>3 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Validator_classes.v</code></li> <li>2 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Version.vo</code></li> <li>1 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Version.glob</code></li> <li>1 K <code>../ocaml-base-compiler.4.10.2/lib/coq/user-contrib/MenhirLib/Version.v</code></li> </ul> <h2>Uninstall 🧹</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam remove -y coq-menhirlib.20200612</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Missing removes</dt> <dd> none </dd> <dt>Wrong removes</dt> <dd> none </dd> </dl> </div> </div> </div> <hr/> <div class="footer"> <p class="text-center"> Sources are on <a href="https://github.com/coq-bench">GitHub</a> © Guillaume Claret 🐣 </p> </div> </div> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <script src="../../../../../bootstrap.min.js"></script> </body> </html>
coq-bench/coq-bench.github.io
clean/Linux-x86_64-4.10.2-2.0.6/released/8.13.1/menhirlib/20200612.html
HTML
mit
10,688
51.787129
159
0.577511
false
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>dpdgraph: 16 s 🏆</title> <link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" /> <link href="../../../../../bootstrap.min.css" rel="stylesheet"> <link href="../../../../../bootstrap-custom.css" rel="stylesheet"> <link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet"> <script src="../../../../../moment.min.js"></script> <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries --> <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script> <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script> <![endif]--> </head> <body> <div class="container"> <div class="navbar navbar-default" role="navigation"> <div class="container-fluid"> <div class="navbar-header"> <a class="navbar-brand" href="../../../../.."><i class="fa fa-lg fa-flag-checkered"></i> Coq bench</a> </div> <div id="navbar" class="collapse navbar-collapse"> <ul class="nav navbar-nav"> <li><a href="../..">clean / released</a></li> <li class="active"><a href="">8.9.0 / dpdgraph - 0.6.4</a></li> </ul> </div> </div> </div> <div class="article"> <div class="row"> <div class="col-md-12"> <a href="../..">« Up</a> <h1> dpdgraph <small> 0.6.4 <span class="label label-success">16 s 🏆</span> </small> </h1> <p>📅 <em><script>document.write(moment("2022-02-24 12:53:50 +0000", "YYYY-MM-DD HH:mm:ss Z").fromNow());</script> (2022-02-24 12:53:50 UTC)</em><p> <h2>Context</h2> <pre># Packages matching: installed # Name # Installed # Synopsis base-bigarray base base-num base Num library distributed with the OCaml compiler base-threads base base-unix base camlp5 7.14 Preprocessor-pretty-printer of OCaml conf-findutils 1 Virtual package relying on findutils conf-perl 2 Virtual package relying on perl coq 8.9.0 Formal proof management system num 0 The Num library for arbitrary-precision integer and rational arithmetic ocaml 4.03.0 The OCaml compiler (virtual package) ocaml-base-compiler 4.03.0 Official 4.03.0 release ocaml-config 1 OCaml Switch Configuration ocamlfind 1.9.3 A library manager for OCaml # opam file: opam-version: &quot;2.0&quot; maintainer: &quot;yves.bertot@inria.fr&quot; license: &quot;LGPL 2.1&quot; homepage: &quot;https://github.com/karmaki/coq-dpdgraph&quot; build: [ [&quot;./configure&quot;] [&quot;echo&quot; &quot;%{jobs}%&quot; &quot;jobs for the linter&quot;] [make] ] bug-reports: &quot;https://github.com/karmaki/coq-dpdgraph/issues&quot; dev-repo: &quot;git+https://github.com/karmaki/coq-dpdgraph.git&quot; install: [ [make &quot;install&quot; &quot;BINDIR=%{bin}%&quot;] ] remove: [ [&quot;rm&quot; &quot;%{bin}%/dpd2dot&quot; &quot;%{bin}%/dpdusage&quot;] [&quot;rm&quot; &quot;-R&quot; &quot;%{lib}%/coq/user-contrib/dpdgraph&quot;] ] depends: [ &quot;ocaml&quot; {&lt; &quot;4.08.0&quot;} &quot;coq&quot; {&gt;= &quot;8.9&quot; &amp; &lt; &quot;8.10~&quot;} &quot;ocamlgraph&quot; ] authors: [ &quot;Anne Pacalet&quot; &quot;Yves Bertot&quot;] synopsis: &quot;Compute dependencies between Coq objects (definitions, theorems) and produce graphs&quot; flags: light-uninstall url { src: &quot;https://github.com/Karmaki/coq-dpdgraph/releases/download/v0.6.4/coq-dpdgraph-0.6.4.tgz&quot; checksum: &quot;md5=93e5ffcfa808fdba9cc421866ee1d416&quot; } </pre> <h2>Lint</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Dry install 🏜️</h2> <p>Dry install with the current Coq version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam install -y --show-action coq-dpdgraph.0.6.4 coq.8.9.0</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <p>Dry install without Coq/switch base, to test if the problem was incompatibility with the current Coq/OCaml version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Install dependencies</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam list; echo; ulimit -Sv 4000000; timeout 4h opam install -y --deps-only coq-dpdgraph.0.6.4 coq.8.9.0</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>26 s</dd> </dl> <h2>Install 🚀</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam list; echo; ulimit -Sv 16000000; timeout 4h opam install -y -v coq-dpdgraph.0.6.4 coq.8.9.0</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>16 s</dd> </dl> <h2>Installation size</h2> <p>Total: 10 M</p> <ul> <li>5 M <code>../ocaml-base-compiler.4.03.0/bin/dpdusage</code></li> <li>5 M <code>../ocaml-base-compiler.4.03.0/bin/dpd2dot</code></li> <li>85 K <code>../ocaml-base-compiler.4.03.0/lib/coq/user-contrib/dpdgraph/dpdgraph.cmxs</code></li> <li>14 K <code>../ocaml-base-compiler.4.03.0/lib/coq/user-contrib/dpdgraph/graphdepend.cmi</code></li> <li>9 K <code>../ocaml-base-compiler.4.03.0/lib/coq/user-contrib/dpdgraph/dpdgraph.cmxa</code></li> <li>9 K <code>../ocaml-base-compiler.4.03.0/lib/coq/user-contrib/dpdgraph/graphdepend.cmx</code></li> <li>6 K <code>../ocaml-base-compiler.4.03.0/lib/coq/user-contrib/dpdgraph/searchdepend.cmi</code></li> <li>5 K <code>../ocaml-base-compiler.4.03.0/lib/coq/user-contrib/dpdgraph/searchdepend.cmx</code></li> <li>1 K <code>../ocaml-base-compiler.4.03.0/lib/coq/user-contrib/dpdgraph/dpdgraph.vo</code></li> <li>1 K <code>../ocaml-base-compiler.4.03.0/lib/coq/user-contrib/dpdgraph/dpdgraph.glob</code></li> <li>1 K <code>../ocaml-base-compiler.4.03.0/lib/coq/user-contrib/dpdgraph/dpdgraph.v</code></li> </ul> <h2>Uninstall 🧹</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam remove -y coq-dpdgraph.0.6.4</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Missing removes</dt> <dd> none </dd> <dt>Wrong removes</dt> <dd> none </dd> </dl> </div> </div> </div> <hr/> <div class="footer"> <p class="text-center"> Sources are on <a href="https://github.com/coq-bench">GitHub</a> © Guillaume Claret 🐣 </p> </div> </div> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <script src="../../../../../bootstrap.min.js"></script> </body> </html>
coq-bench/coq-bench.github.io
clean/Linux-x86_64-4.03.0-2.0.5/released/8.9.0/dpdgraph/0.6.4.html
HTML
mit
7,967
43.617978
159
0.543314
false
package com.bugsnag; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Conditional; import org.springframework.context.annotation.Configuration; import javax.annotation.PostConstruct; /** * If spring-webmvc is loaded, add configuration for reporting unhandled exceptions. */ @Configuration @Conditional(SpringWebMvcLoadedCondition.class) class MvcConfiguration { @Autowired private Bugsnag bugsnag; /** * Register an exception resolver to send unhandled reports to Bugsnag * for uncaught exceptions thrown from request handlers. */ @Bean BugsnagMvcExceptionHandler bugsnagHandlerExceptionResolver() { return new BugsnagMvcExceptionHandler(bugsnag); } /** * Add a callback to assign specified severities for some Spring exceptions. */ @PostConstruct void addExceptionClassCallback() { bugsnag.addCallback(new ExceptionClassCallback()); } }
bugsnag/bugsnag-java
bugsnag-spring/src/main/java/com/bugsnag/MvcConfiguration.java
Java
mit
1,039
27.861111
84
0.757459
false
import React, {Component} from 'react'; import MiniInfoBar from '../components/MiniInfoBar'; export default class About extends Component { state = { showKitten: false } handleToggleKitten() { this.setState({showKitten: !this.state.showKitten}); } render() { const {showKitten} = this.state; const kitten = require('./kitten.jpg'); return ( <div> <div className="container"> <h1>About Us</h1> <p>This project was orginally created by Erik Rasmussen (<a href="https://twitter.com/erikras" target="_blank">@erikras</a>), but has since seen many contributions from the open source community. Thank you to <a href="https://github.com/erikras/react-redux-universal-hot-example/graphs/contributors" target="_blank">all the contributors</a>. </p> <h3>Mini Bar <span style={{color: '#aaa'}}>(not that kind)</span></h3> <p>Hey! You found the mini info bar! The following component is display-only. Note that it shows the same time as the info bar.</p> <MiniInfoBar/> <h3>Images</h3> <p> Psst! Would you like to see a kitten? <button className={'btn btn-' + (showKitten ? 'danger' : 'success')} style={{marginLeft: 50}} onClick={::this.handleToggleKitten}> {showKitten ? 'No! Take it away!' : 'Yes! Please!'}</button> </p> {showKitten && <div><img src={kitten}/></div>} </div> </div> ); } }
vbdoug/hot-react
src/views/About.js
JavaScript
mit
1,598
30.333333
119
0.566333
false
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <!--NewPage--> <HTML> <HEAD> <meta name="collection" content="api"> <!-- Generated by javadoc (build 1.5.0-rc) on Wed Aug 11 07:24:05 PDT 2004 --> <TITLE> NumberOfDocuments (Java 2 Platform SE 5.0) </TITLE> <META NAME="keywords" CONTENT="javax.print.attribute.standard.NumberOfDocuments class"> <META NAME="keywords" CONTENT="equals()"> <META NAME="keywords" CONTENT="getCategory()"> <META NAME="keywords" CONTENT="getName()"> <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../stylesheet.css" TITLE="Style"> <SCRIPT type="text/javascript"> function windowTitle() { parent.document.title="NumberOfDocuments (Java 2 Platform SE 5.0)"; } </SCRIPT> <NOSCRIPT> </NOSCRIPT> </HEAD> <BODY BGCOLOR="white" onload="windowTitle();"> <!-- ========= START OF TOP NAVBAR ======= --> <A NAME="navbar_top"><!-- --></A> <A HREF="#skip-navbar_top" title="Skip navigation links"></A> <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""> <TR> <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A NAME="navbar_top_firstrow"><!-- --></A> <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/NumberOfDocuments.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD> </TR> </TABLE> </TD> <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM> <b>Java<sup><font size=-2>TM</font></sup>&nbsp;2&nbsp;Platform<br>Standard&nbsp;Ed. 5.0</b></EM> </TD> </TR> <TR> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> &nbsp;<A HREF="../../../../javax/print/attribute/standard/MultipleDocumentHandling.html" title="class in javax.print.attribute.standard"><B>PREV CLASS</B></A>&nbsp; &nbsp;<A HREF="../../../../javax/print/attribute/standard/NumberOfInterveningJobs.html" title="class in javax.print.attribute.standard"><B>NEXT CLASS</B></A></FONT></TD> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../index.html?javax/print/attribute/standard/NumberOfDocuments.html" target="_top"><B>FRAMES</B></A> &nbsp; &nbsp;<A HREF="NumberOfDocuments.html" target="_top"><B>NO FRAMES</B></A> &nbsp; &nbsp;<SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>'); } //--> </SCRIPT> <NOSCRIPT> <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A> </NOSCRIPT> </FONT></TD> </TR> <TR> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD> </TR> </TABLE> <A NAME="skip-navbar_top"></A> <!-- ========= END OF TOP NAVBAR ========= --> <HR> <!-- ======== START OF CLASS DATA ======== --> <H2> <FONT SIZE="-1"> javax.print.attribute.standard</FONT> <BR> Class NumberOfDocuments</H2> <PRE> <A HREF="../../../../java/lang/Object.html" title="class in java.lang">java.lang.Object</A> <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><A HREF="../../../../javax/print/attribute/IntegerSyntax.html" title="class in javax.print.attribute">javax.print.attribute.IntegerSyntax</A> <IMG SRC="../../../../resources/inherit.gif" ALT="extended by "><B>javax.print.attribute.standard.NumberOfDocuments</B> </PRE> <DL> <DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../../../java/io/Serializable.html" title="interface in java.io">Serializable</A>, <A HREF="../../../../java/lang/Cloneable.html" title="interface in java.lang">Cloneable</A>, <A HREF="../../../../javax/print/attribute/Attribute.html" title="interface in javax.print.attribute">Attribute</A>, <A HREF="../../../../javax/print/attribute/PrintJobAttribute.html" title="interface in javax.print.attribute">PrintJobAttribute</A></DD> </DL> <HR> <DL> <DT><PRE>public final class <B>NumberOfDocuments</B><DT>extends <A HREF="../../../../javax/print/attribute/IntegerSyntax.html" title="class in javax.print.attribute">IntegerSyntax</A><DT>implements <A HREF="../../../../javax/print/attribute/PrintJobAttribute.html" title="interface in javax.print.attribute">PrintJobAttribute</A></DL> </PRE> <P> Class NumberOfDocuments is an integer valued printing attribute that indicates the number of individual docs the printer has accepted for this job, regardless of whether the docs' print data has reached the printer or not. <P> <B>IPP Compatibility:</B> The integer value gives the IPP integer value. The category name returned by <CODE>getName()</CODE> gives the IPP attribute name. <P> <P> <P> <DL> <DT><B>See Also:</B><DD><A HREF="../../../../serialized-form.html#javax.print.attribute.standard.NumberOfDocuments">Serialized Form</A></DL> <HR> <P> <!-- ======== CONSTRUCTOR SUMMARY ======== --> <A NAME="constructor_summary"><!-- --></A> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2"> <B>Constructor Summary</B></FONT></TH> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD><CODE><B><A HREF="../../../../javax/print/attribute/standard/NumberOfDocuments.html#NumberOfDocuments(int)">NumberOfDocuments</A></B>(int&nbsp;value)</CODE> <BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Construct a new number of documents attribute with the given integer value.</TD> </TR> </TABLE> &nbsp; <!-- ========== METHOD SUMMARY =========== --> <A NAME="method_summary"><!-- --></A> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2"> <B>Method Summary</B></FONT></TH> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>&nbsp;boolean</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../javax/print/attribute/standard/NumberOfDocuments.html#equals(java.lang.Object)">equals</A></B>(<A HREF="../../../../java/lang/Object.html" title="class in java.lang">Object</A>&nbsp;object)</CODE> <BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns whether this number of documents attribute is equivalent to the passed in object.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>&nbsp;<A HREF="../../../../java/lang/Class.html" title="class in java.lang">Class</A>&lt;? extends <A HREF="../../../../javax/print/attribute/Attribute.html" title="interface in javax.print.attribute">Attribute</A>&gt;</CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../javax/print/attribute/standard/NumberOfDocuments.html#getCategory()">getCategory</A></B>()</CODE> <BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Get the printing attribute class which is to be used as the "category" for this printing attribute value.</TD> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"> <CODE>&nbsp;<A HREF="../../../../java/lang/String.html" title="class in java.lang">String</A></CODE></FONT></TD> <TD><CODE><B><A HREF="../../../../javax/print/attribute/standard/NumberOfDocuments.html#getName()">getName</A></B>()</CODE> <BR> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Get the name of the category of which this attribute value is an instance.</TD> </TR> </TABLE> &nbsp;<A NAME="methods_inherited_from_class_javax.print.attribute.IntegerSyntax"><!-- --></A> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"> <TH ALIGN="left"><B>Methods inherited from class javax.print.attribute.<A HREF="../../../../javax/print/attribute/IntegerSyntax.html" title="class in javax.print.attribute">IntegerSyntax</A></B></TH> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD><CODE><A HREF="../../../../javax/print/attribute/IntegerSyntax.html#getValue()">getValue</A>, <A HREF="../../../../javax/print/attribute/IntegerSyntax.html#hashCode()">hashCode</A>, <A HREF="../../../../javax/print/attribute/IntegerSyntax.html#toString()">toString</A></CODE></TD> </TR> </TABLE> &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor"> <TH ALIGN="left"><B>Methods inherited from class java.lang.<A HREF="../../../../java/lang/Object.html" title="class in java.lang">Object</A></B></TH> </TR> <TR BGCOLOR="white" CLASS="TableRowColor"> <TD><CODE><A HREF="../../../../java/lang/Object.html#clone()">clone</A>, <A HREF="../../../../java/lang/Object.html#finalize()">finalize</A>, <A HREF="../../../../java/lang/Object.html#getClass()">getClass</A>, <A HREF="../../../../java/lang/Object.html#notify()">notify</A>, <A HREF="../../../../java/lang/Object.html#notifyAll()">notifyAll</A>, <A HREF="../../../../java/lang/Object.html#wait()">wait</A>, <A HREF="../../../../java/lang/Object.html#wait(long)">wait</A>, <A HREF="../../../../java/lang/Object.html#wait(long, int)">wait</A></CODE></TD> </TR> </TABLE> &nbsp; <P> <!-- ========= CONSTRUCTOR DETAIL ======== --> <A NAME="constructor_detail"><!-- --></A> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2"> <B>Constructor Detail</B></FONT></TH> </TR> </TABLE> <A NAME="NumberOfDocuments(int)"><!-- --></A><H3> NumberOfDocuments</H3> <PRE> public <B>NumberOfDocuments</B>(int&nbsp;value)</PRE> <DL> <DD>Construct a new number of documents attribute with the given integer value. <P> <DL> <DT><B>Parameters:</B><DD><CODE>value</CODE> - Integer value. <DT><B>Throws:</B> <DD><CODE><A HREF="../../../../java/lang/IllegalArgumentException.html" title="class in java.lang">IllegalArgumentException</A></CODE> - (Unchecked exception) Thrown if <CODE>value</CODE> is less than 0.</DL> </DL> <!-- ============ METHOD DETAIL ========== --> <A NAME="method_detail"><!-- --></A> <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY=""> <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor"> <TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2"> <B>Method Detail</B></FONT></TH> </TR> </TABLE> <A NAME="equals(java.lang.Object)"><!-- --></A><H3> equals</H3> <PRE> public boolean <B>equals</B>(<A HREF="../../../../java/lang/Object.html" title="class in java.lang">Object</A>&nbsp;object)</PRE> <DL> <DD>Returns whether this number of documents attribute is equivalent to the passed in object. To be equivalent, all of the following conditions must be true: <OL TYPE=1> <LI> <CODE>object</CODE> is not null. <LI> <CODE>object</CODE> is an instance of class NumberOfDocuments. <LI> This number of documents attribute's value and <CODE>object</CODE>'s value are equal. </OL> <P> <DD><DL> <DT><B>Overrides:</B><DD><CODE><A HREF="../../../../javax/print/attribute/IntegerSyntax.html#equals(java.lang.Object)">equals</A></CODE> in class <CODE><A HREF="../../../../javax/print/attribute/IntegerSyntax.html" title="class in javax.print.attribute">IntegerSyntax</A></CODE></DL> </DD> <DD><DL> <DT><B>Parameters:</B><DD><CODE>object</CODE> - Object to compare to. <DT><B>Returns:</B><DD>True if <CODE>object</CODE> is equivalent to this number of documents attribute, false otherwise.<DT><B>See Also:</B><DD><A HREF="../../../../java/lang/Object.html#hashCode()"><CODE>Object.hashCode()</CODE></A>, <A HREF="../../../../java/util/Hashtable.html" title="class in java.util"><CODE>Hashtable</CODE></A></DL> </DD> </DL> <HR> <A NAME="getCategory()"><!-- --></A><H3> getCategory</H3> <PRE> public final <A HREF="../../../../java/lang/Class.html" title="class in java.lang">Class</A>&lt;? extends <A HREF="../../../../javax/print/attribute/Attribute.html" title="interface in javax.print.attribute">Attribute</A>&gt; <B>getCategory</B>()</PRE> <DL> <DD>Get the printing attribute class which is to be used as the "category" for this printing attribute value. <P> For class NumberOfDocuments, the category is class NumberOfDocuments itself. <P> <DD><DL> <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../javax/print/attribute/Attribute.html#getCategory()">getCategory</A></CODE> in interface <CODE><A HREF="../../../../javax/print/attribute/Attribute.html" title="interface in javax.print.attribute">Attribute</A></CODE></DL> </DD> <DD><DL> <DT><B>Returns:</B><DD>Printing attribute class (category), an instance of class <A HREF="../../../../java/lang/Class.html" title="class in java.lang"><CODE>java.lang.Class</CODE></A>.</DL> </DD> </DL> <HR> <A NAME="getName()"><!-- --></A><H3> getName</H3> <PRE> public final <A HREF="../../../../java/lang/String.html" title="class in java.lang">String</A> <B>getName</B>()</PRE> <DL> <DD>Get the name of the category of which this attribute value is an instance. <P> For class NumberOfDocuments, the category name is <CODE>"number-of-documents"</CODE>. <P> <DD><DL> <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../javax/print/attribute/Attribute.html#getName()">getName</A></CODE> in interface <CODE><A HREF="../../../../javax/print/attribute/Attribute.html" title="interface in javax.print.attribute">Attribute</A></CODE></DL> </DD> <DD><DL> <DT><B>Returns:</B><DD>Attribute category name.</DL> </DD> </DL> <!-- ========= END OF CLASS DATA ========= --> <HR> <!-- ======= START OF BOTTOM NAVBAR ====== --> <A NAME="navbar_bottom"><!-- --></A> <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A> <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY=""> <TR> <TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A NAME="navbar_bottom_firstrow"><!-- --></A> <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY=""> <TR ALIGN="center" VALIGN="top"> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/NumberOfDocuments.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD> <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD> </TR> </TABLE> </TD> <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM> <b>Java<sup><font size=-2>TM</font></sup>&nbsp;2&nbsp;Platform<br>Standard&nbsp;Ed. 5.0</b></EM> </TD> </TR> <TR> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> &nbsp;<A HREF="../../../../javax/print/attribute/standard/MultipleDocumentHandling.html" title="class in javax.print.attribute.standard"><B>PREV CLASS</B></A>&nbsp; &nbsp;<A HREF="../../../../javax/print/attribute/standard/NumberOfInterveningJobs.html" title="class in javax.print.attribute.standard"><B>NEXT CLASS</B></A></FONT></TD> <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2"> <A HREF="../../../../index.html?javax/print/attribute/standard/NumberOfDocuments.html" target="_top"><B>FRAMES</B></A> &nbsp; &nbsp;<A HREF="NumberOfDocuments.html" target="_top"><B>NO FRAMES</B></A> &nbsp; &nbsp;<SCRIPT type="text/javascript"> <!-- if(window==top) { document.writeln('<A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A>'); } //--> </SCRIPT> <NOSCRIPT> <A HREF="../../../../allclasses-noframe.html"><B>All Classes</B></A> </NOSCRIPT> </FONT></TD> </TR> <TR> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD> <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2"> DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD> </TR> </TABLE> <A NAME="skip-navbar_bottom"></A> <!-- ======== END OF BOTTOM NAVBAR ======= --> <HR> <font size="-1"><a href="http://java.sun.com/cgi-bin/bugreport.cgi">Submit a bug or feature</a><br>For further API reference and developer documentation, see <a href="../../../../../relnotes/devdocs-vs-specs.html">Java 2 SDK SE Developer Documentation</a>. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples. <p>Copyright &#169; 2004, 2010 Oracle and/or its affiliates. All rights reserved. Use is subject to <a href="../../../../../relnotes/license.html">license terms</a>. Also see the <a href="http://java.sun.com/docs/redist.html">documentation redistribution policy</a>.</font> <!-- Start SiteCatalyst code --> <script language="JavaScript" src="http://www.oracle.com/ocom/groups/systemobject/@mktg_admin/documents/systemobject/s_code_download.js"></script> <script language="JavaScript" src="http://www.oracle.com/ocom/groups/systemobject/@mktg_admin/documents/systemobject/s_code.js"></script> <!-- ********** DO NOT ALTER ANYTHING BELOW THIS LINE ! *********** --> <!-- Below code will send the info to Omniture server --> <script language="javascript">var s_code=s.t();if(s_code)document.write(s_code)</script> <!-- End SiteCatalyst code --> </body> </HTML>
Smolations/more-dash-docsets
docsets/Java 5.docset/Contents/Resources/Documents/javax/print/attribute/standard/NumberOfDocuments.html
HTML
mit
19,307
50.07672
695
0.653856
false
package com.seafile.seadroid2.transfer; /** * Download state listener * */ public interface DownloadStateListener { void onFileDownloadProgress(int taskID); void onFileDownloaded(int taskID); void onFileDownloadFailed(int taskID); }
huangbop/seadroid-build
seadroid/src/main/java/com/seafile/seadroid2/transfer/DownloadStateListener.java
Java
mit
249
21.636364
44
0.75502
false
from pydispatch import dispatcher from PySide import QtCore, QtGui import cbpos logger = cbpos.get_logger(__name__) from .page import BasePage class MainWindow(QtGui.QMainWindow): __inits = [] def __init__(self): super(MainWindow, self).__init__() self.tabs = QtGui.QTabWidget(self) self.tabs.setTabsClosable(False) self.tabs.setIconSize(QtCore.QSize(32, 32)) self.tabs.currentChanged.connect(self.onCurrentTabChanged) self.toolbar = self.addToolBar('Base') self.toolbar.setIconSize(QtCore.QSize(48,48)) #Suitable for touchscreens self.toolbar.setObjectName('BaseToolbar') toolbarStyle = cbpos.config['menu', 'toolbar_style'] # The index in this list is the same as that in the configuration page available_styles = ( QtCore.Qt.ToolButtonFollowStyle, QtCore.Qt.ToolButtonIconOnly, QtCore.Qt.ToolButtonTextOnly, QtCore.Qt.ToolButtonTextBesideIcon, QtCore.Qt.ToolButtonTextUnderIcon, ) try: toolbarStyle = available_styles[int(toolbarStyle)] except (ValueError, TypeError, IndexError): toolbarStyle = QtCore.Qt.ToolButtonFollowStyle self.toolbar.setToolButtonStyle(toolbarStyle) self.setCentralWidget(self.tabs) self.statusBar().showMessage(cbpos.tr._('Coinbox POS is ready.')) self.setWindowTitle('Coinbox') self.callInit() self.loadToolbar() self.loadMenu() def loadToolbar(self): """ Loads the toolbar actions, restore toolbar state, and restore window geometry. """ mwState = cbpos.config['mainwindow', 'state'] mwGeom = cbpos.config['mainwindow', 'geometry'] for act in cbpos.menu.actions: # TODO: Remember to load an icon with a proper size (eg 48x48 px for touchscreens) action = QtGui.QAction(QtGui.QIcon(act.icon), act.label, self) action.setShortcut(act.shortcut) action.triggered.connect(act.trigger) self.toolbar.addAction(action) #Restores the saved mainwindow's toolbars and docks, and then the window geometry. if mwState is not None: self.restoreState( QtCore.QByteArray.fromBase64(mwState) ) if mwGeom is not None: self.restoreGeometry( QtCore.QByteArray.fromBase64(mwGeom) ) else: self.setGeometry(0, 0, 800, 600) def loadMenu(self): """ Load the menu root items and items into the QTabWidget with the appropriate pages. """ show_empty_root_items = cbpos.config['menu', 'show_empty_root_items'] show_disabled_items = cbpos.config['menu', 'show_disabled_items'] hide_tab_bar = not cbpos.config['menu', 'show_tab_bar'] if hide_tab_bar: # Hide the tab bar and prepare the toolbar for extra QAction's self.tabs.tabBar().hide() # This pre-supposes that the menu items will come after the actions self.toolbar.addSeparator() for root in cbpos.menu.items: if not root.enabled and not show_disabled_items: continue if show_disabled_items: # Show all child items children = root.children else: # Filter out those which are disabled children = [i for i in root.children if i.enabled] # Hide empty menu root items if len(children) == 0 and not show_empty_root_items: continue # Add the tab widget = self.getTabWidget(children) icon = QtGui.QIcon(root.icon) index = self.tabs.addTab(widget, icon, root.label) widget.setEnabled(root.enabled) # Add the toolbar action if enabled if hide_tab_bar: # TODO: Remember to load an icon with a proper size (eg 48x48 px for touchscreens) action = QtGui.QAction(QtGui.QIcon(icon), root.label, self) action.onTrigger = lambda n=index: self.tabs.setCurrentIndex(n) action.triggered.connect(action.onTrigger) self.toolbar.addAction(action) def onCurrentTabChanged(self, index, tabs=None): if tabs is None: tabs = self.tabs widget = tabs.widget(index) try: signal = widget.shown except AttributeError: pass else: signal.emit() def getTabWidget(self, items): """ Returns the appropriate window to be placed in the main QTabWidget, depending on the number of children of a root menu item. """ count = len(items) if count == 0: # If there are no child items, just return an empty widget widget = QtGui.QWidget() widget.setEnabled(False) return widget elif count == 1: # If there is only one item, show it as is. logger.debug('Loading menu page for %s', items[0].name) widget = items[0].page() widget.setEnabled(items[0].enabled) return widget else: # If there are many children, add them in a QTabWidget tabs = QtGui.QTabWidget() tabs.currentChanged.connect(lambda i, t=tabs: self.onCurrentTabChanged(i, t)) for item in items: logger.debug('Loading menu page for %s', item.name) widget = item.page() icon = QtGui.QIcon(item.icon) tabs.addTab(widget, icon, item.label) widget.setEnabled(item.enabled) return tabs def saveWindowState(self): """ Saves the main window state (position, size, toolbar positions) """ mwState = self.saveState().toBase64() mwGeom = self.saveGeometry().toBase64() cbpos.config['mainwindow', 'state'] = unicode(mwState) cbpos.config['mainwindow', 'geometry'] = unicode(mwGeom) cbpos.config.save() def closeEvent(self, event): """ Perform necessary operations before closing the window. """ self.saveWindowState() #do any other thing before closing... event.accept() @classmethod def addInit(cls, init): """ Adds the `init` method to the list of extensions of the `MainWindow.__init__`. """ cls.__inits.append(init) def callInit(self): """ Handle calls to `__init__` methods of extensions of the MainWindow. """ for init in self.__inits: init(self)
coinbox/coinbox-mod-base
cbmod/base/views/window.py
Python
mit
7,111
35.426316
98
0.560681
false
package cn.javay.zheng.common.validator; import com.baidu.unbiz.fluentvalidator.ValidationError; import com.baidu.unbiz.fluentvalidator.Validator; import com.baidu.unbiz.fluentvalidator.ValidatorContext; import com.baidu.unbiz.fluentvalidator.ValidatorHandler; /** * 长度校验 * Created by shuzheng on 2017/2/18. */ public class LengthValidator extends ValidatorHandler<String> implements Validator<String> { private int min; private int max; private String fieldName; public LengthValidator(int min, int max, String fieldName) { this.min = min; this.max = max; this.fieldName = fieldName; } @Override public boolean validate(ValidatorContext context, String s) { if (null == s || s.length() > max || s.length() < min) { context.addError(ValidationError.create(String.format("%s长度必须介于%s~%s之间!", fieldName, min, max)) .setErrorCode(-1) .setField(fieldName) .setInvalidValue(s)); return false; } return true; } }
javay/zheng-lite
zheng-common/src/main/java/cn/javay/zheng/common/validator/LengthValidator.java
Java
mit
1,107
27.447368
107
0.648474
false
define([ "dojo/_base/array", "dojo/_base/connect", "dojo/_base/declare", "dojo/_base/lang", "dojo/_base/window", "dojo/dom", "dojo/dom-class", "dojo/dom-construct", "dojo/dom-style", "dijit/registry", "dijit/_Contained", "dijit/_Container", "dijit/_WidgetBase", "./ProgressIndicator", "./ToolBarButton", "./View", "dojo/has", "dojo/has!dojo-bidi?dojox/mobile/bidi/Heading" ], function(array, connect, declare, lang, win, dom, domClass, domConstruct, domStyle, registry, Contained, Container, WidgetBase, ProgressIndicator, ToolBarButton, View, has, BidiHeading){ // module: // dojox/mobile/Heading var dm = lang.getObject("dojox.mobile", true); var Heading = declare(has("dojo-bidi") ? "dojox.mobile.NonBidiHeading" : "dojox.mobile.Heading", [WidgetBase, Container, Contained],{ // summary: // A widget that represents a navigation bar. // description: // Heading is a widget that represents a navigation bar, which // usually appears at the top of an application. It usually // displays the title of the current view and can contain a // navigational control. If you use it with // dojox/mobile/ScrollableView, it can also be used as a fixed // header bar or a fixed footer bar. In such cases, specify the // fixed="top" attribute to be a fixed header bar or the // fixed="bottom" attribute to be a fixed footer bar. Heading can // have one or more ToolBarButton widgets as its children. // back: String // A label for the navigational control to return to the previous View. back: "", // href: String // A URL to open when the navigational control is pressed. href: "", // moveTo: String // The id of the transition destination of the navigation control. // If the value has a hash sign ('#') before the id (e.g. #view1) // and the dojox/mobile/bookmarkable module is loaded by the user application, // the view transition updates the hash in the browser URL so that the // user can bookmark the destination view. In this case, the user // can also use the browser's back/forward button to navigate // through the views in the browser history. // // If null, transitions to a blank view. // If '#', returns immediately without transition. moveTo: "", // transition: String // A type of animated transition effect. You can choose from the // standard transition types, "slide", "fade", "flip", or from the // extended transition types, "cover", "coverv", "dissolve", // "reveal", "revealv", "scaleIn", "scaleOut", "slidev", // "swirl", "zoomIn", "zoomOut", "cube", and "swap". If "none" is // specified, transition occurs immediately without animation. transition: "slide", // label: String // A title text of the heading. If the label is not specified, the // innerHTML of the node is used as a label. label: "", // iconBase: String // The default icon path for child items. iconBase: "", // tag: String // A name of HTML tag to create as domNode. tag: "h1", // busy: Boolean // If true, a progress indicator spins on this widget. busy: false, // progStyle: String // A css class name to add to the progress indicator. progStyle: "mblProgWhite", /* internal properties */ // baseClass: String // The name of the CSS class of this widget. baseClass: "mblHeading", buildRendering: function(){ if(!this.templateString){ // true if this widget is not templated // Create root node if it wasn't created by _TemplatedMixin this.domNode = this.containerNode = this.srcNodeRef || win.doc.createElement(this.tag); } this.inherited(arguments); if(!this.templateString){ // true if this widget is not templated if(!this.label){ array.forEach(this.domNode.childNodes, function(n){ if(n.nodeType == 3){ var v = lang.trim(n.nodeValue); if(v){ this.label = v; this.labelNode = domConstruct.create("span", {innerHTML:v}, n, "replace"); } } }, this); } if(!this.labelNode){ this.labelNode = domConstruct.create("span", null, this.domNode); } this.labelNode.className = "mblHeadingSpanTitle"; this.labelDivNode = domConstruct.create("div", { className: "mblHeadingDivTitle", innerHTML: this.labelNode.innerHTML }, this.domNode); } dom.setSelectable(this.domNode, false); }, startup: function(){ if(this._started){ return; } var parent = this.getParent && this.getParent(); if(!parent || !parent.resize){ // top level widget var _this = this; setTimeout(function(){ // necessary to render correctly _this.resize(); }, 0); } this.inherited(arguments); }, resize: function(){ if(this.labelNode){ // find the rightmost left button (B), and leftmost right button (C) // +-----------------------------+ // | |A| |B| |C| |D| | // +-----------------------------+ var leftBtn, rightBtn; var children = this.containerNode.childNodes; for(var i = children.length - 1; i >= 0; i--){ var c = children[i]; if(c.nodeType === 1 && domStyle.get(c, "display") !== "none"){ if(!rightBtn && domStyle.get(c, "float") === "right"){ rightBtn = c; } if(!leftBtn && domStyle.get(c, "float") === "left"){ leftBtn = c; } } } if(!this.labelNodeLen && this.label){ this.labelNode.style.display = "inline"; this.labelNodeLen = this.labelNode.offsetWidth; this.labelNode.style.display = ""; } var bw = this.domNode.offsetWidth; // bar width var rw = rightBtn ? bw - rightBtn.offsetLeft + 5 : 0; // rightBtn width var lw = leftBtn ? leftBtn.offsetLeft + leftBtn.offsetWidth + 5 : 0; // leftBtn width var tw = this.labelNodeLen || 0; // title width domClass[bw - Math.max(rw,lw)*2 > tw ? "add" : "remove"](this.domNode, "mblHeadingCenterTitle"); } array.forEach(this.getChildren(), function(child){ if(child.resize){ child.resize(); } }); }, _setBackAttr: function(/*String*/back){ // tags: // private this._set("back", back); if(!this.backButton){ this.backButton = new ToolBarButton({ arrow: "left", label: back, moveTo: this.moveTo, back: !this.moveTo, href: this.href, transition: this.transition, transitionDir: -1 }); this.backButton.placeAt(this.domNode, "first"); }else{ this.backButton.set("label", back); } this.resize(); }, _setMoveToAttr: function(/*String*/moveTo){ // tags: // private this._set("moveTo", moveTo); if(this.backButton){ this.backButton.set("moveTo", moveTo); } }, _setHrefAttr: function(/*String*/href){ // tags: // private this._set("href", href); if(this.backButton){ this.backButton.set("href", href); } }, _setTransitionAttr: function(/*String*/transition){ // tags: // private this._set("transition", transition); if(this.backButton){ this.backButton.set("transition", transition); } }, _setLabelAttr: function(/*String*/label){ // tags: // private this._set("label", label); this.labelNode.innerHTML = this.labelDivNode.innerHTML = this._cv ? this._cv(label) : label; }, _setBusyAttr: function(/*Boolean*/busy){ // tags: // private var prog = this._prog; if(busy){ if(!prog){ prog = this._prog = new ProgressIndicator({size:30, center:false}); domClass.add(prog.domNode, this.progStyle); } domConstruct.place(prog.domNode, this.domNode, "first"); prog.start(); }else if(prog){ prog.stop(); } this._set("busy", busy); } }); return has("dojo-bidi") ? declare("dojox.mobile.Heading", [Heading, BidiHeading]) : Heading; });
aguadev/aguadev
html/dojo-1.8.3/dojox-1.9.0/mobile/Heading.js
JavaScript
mit
7,774
29.727273
189
0.629792
false
/** @jsx jsx */ import { Editor } from 'slate' import { jsx } from '../..' export const input = ( <editor> <block> <mark key="a"> <anchor />o </mark> n <mark key="b"> e<focus /> </mark> </block> </editor> ) export const run = editor => { return Array.from(Editor.activeMarks(editor, { union: true })) } export const output = [{ key: 'a' }, { key: 'b' }]
isubastiCadmus/slate
packages/slate/test/queries/activeMarks/union.js
JavaScript
mit
418
16.416667
64
0.497608
false
/** * Logback: the reliable, generic, fast and flexible logging framework. * Copyright (C) 1999-2015, QOS.ch. All rights reserved. * * This program and the accompanying materials are dual-licensed under * either the terms of the Eclipse Public License v1.0 as published by * the Eclipse Foundation * * or (per the licensee's choosing) * * under the terms of the GNU Lesser General Public License version 2.1 * as published by the Free Software Foundation. */ package ch.qos.logback.access.spi; import ch.qos.logback.access.AccessConstants; import ch.qos.logback.access.pattern.AccessConverter; import ch.qos.logback.access.servlet.Util; import javax.servlet.http.Cookie; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import java.io.Serializable; import java.util.ArrayList; import java.util.Enumeration; import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.TreeMap; import java.util.Vector; // Contributors: Joern Huxhorn (see also bug #110) /** * The Access module's internal representation of logging events. When the * logging component instance is called in the container to log then a * <code>AccessEvent</code> instance is created. This instance is passed * around to the different logback components. * * @author Ceki G&uuml;lc&uuml; * @author S&eacute;bastien Pennec */ public class AccessEvent implements Serializable, IAccessEvent { private static final long serialVersionUID = 866718993618836343L; private static final String EMPTY = ""; private transient final HttpServletRequest httpRequest; private transient final HttpServletResponse httpResponse; String requestURI; String requestURL; String remoteHost; String remoteUser; String remoteAddr; String protocol; String method; String serverName; String requestContent; String responseContent; long elapsedTime; Map<String, String> requestHeaderMap; Map<String, String[]> requestParameterMap; Map<String, String> responseHeaderMap; Map<String, Object> attributeMap; long contentLength = SENTINEL; int statusCode = SENTINEL; int localPort = SENTINEL; transient ServerAdapter serverAdapter; /** * The number of milliseconds elapsed from 1/1/1970 until logging event was * created. */ private long timeStamp = 0; public AccessEvent(HttpServletRequest httpRequest, HttpServletResponse httpResponse, ServerAdapter adapter) { this.httpRequest = httpRequest; this.httpResponse = httpResponse; this.timeStamp = System.currentTimeMillis(); this.serverAdapter = adapter; this.elapsedTime = calculateElapsedTime(); } /** * Returns the underlying HttpServletRequest. After serialization the returned * value will be null. * * @return */ @Override public HttpServletRequest getRequest() { return httpRequest; } /** * Returns the underlying HttpServletResponse. After serialization the returned * value will be null. * * @return */ @Override public HttpServletResponse getResponse() { return httpResponse; } @Override public long getTimeStamp() { return timeStamp; } public void setTimeStamp(long timeStamp) { if (this.timeStamp != 0) { throw new IllegalStateException( "timeStamp has been already set for this event."); } else { this.timeStamp = timeStamp; } } @Override public String getRequestURI() { if (requestURI == null) { if (httpRequest != null) { requestURI = httpRequest.getRequestURI(); } else { requestURI = NA; } } return requestURI; } /** * The first line of the request. */ @Override public String getRequestURL() { if (requestURL == null) { if (httpRequest != null) { StringBuilder buf = new StringBuilder(); buf.append(httpRequest.getMethod()); buf.append(AccessConverter.SPACE_CHAR); buf.append(httpRequest.getRequestURI()); final String qStr = httpRequest.getQueryString(); if (qStr != null) { buf.append(AccessConverter.QUESTION_CHAR); buf.append(qStr); } buf.append(AccessConverter.SPACE_CHAR); buf.append(httpRequest.getProtocol()); requestURL = buf.toString(); } else { requestURL = NA; } } return requestURL; } @Override public String getRemoteHost() { if (remoteHost == null) { if (httpRequest != null) { // the underlying implementation of HttpServletRequest will // determine if remote lookup will be performed remoteHost = httpRequest.getRemoteHost(); } else { remoteHost = NA; } } return remoteHost; } @Override public String getRemoteUser() { if (remoteUser == null) { if (httpRequest != null) { remoteUser = httpRequest.getRemoteUser(); } else { remoteUser = NA; } } return remoteUser; } @Override public String getProtocol() { if (protocol == null) { if (httpRequest != null) { protocol = httpRequest.getProtocol(); } else { protocol = NA; } } return protocol; } @Override public String getMethod() { if (method == null) { if (httpRequest != null) { method = httpRequest.getMethod(); } else { method = NA; } } return method; } @Override public String getServerName() { if (serverName == null) { if (httpRequest != null) { serverName = httpRequest.getServerName(); } else { serverName = NA; } } return serverName; } @Override public String getRemoteAddr() { if (remoteAddr == null) { if (httpRequest != null) { remoteAddr = httpRequest.getRemoteAddr(); } else { remoteAddr = NA; } } return remoteAddr; } @Override public String getRequestHeader(String key) { String result = null; key = key.toLowerCase(); if (requestHeaderMap == null) { if (httpRequest != null) { buildRequestHeaderMap(); result = requestHeaderMap.get(key); } } else { result = requestHeaderMap.get(key); } if (result != null) { return result; } else { return NA; } } @Override public Enumeration getRequestHeaderNames() { // post-serialization if (httpRequest == null) { Vector<String> list = new Vector<String>(getRequestHeaderMap().keySet()); return list.elements(); } return httpRequest.getHeaderNames(); } @Override public Map<String, String> getRequestHeaderMap() { if (requestHeaderMap == null) { buildRequestHeaderMap(); } return requestHeaderMap; } public void buildRequestHeaderMap() { // according to RFC 2616 header names are case insensitive // latest versions of Tomcat return header names in lower-case requestHeaderMap = new TreeMap<String, String>(String.CASE_INSENSITIVE_ORDER); Enumeration e = httpRequest.getHeaderNames(); if (e == null) { return; } while (e.hasMoreElements()) { String key = (String) e.nextElement(); requestHeaderMap.put(key, httpRequest.getHeader(key)); } } public void buildRequestParameterMap() { requestParameterMap = new HashMap<String, String[]>(); Enumeration e = httpRequest.getParameterNames(); if (e == null) { return; } while (e.hasMoreElements()) { String key = (String) e.nextElement(); requestParameterMap.put(key, httpRequest.getParameterValues(key)); } } @Override public Map<String, String[]> getRequestParameterMap() { if (requestParameterMap == null) { buildRequestParameterMap(); } return requestParameterMap; } @Override public String getAttribute(String key) { Object value = null; if (attributeMap != null) { // Event was prepared for deferred processing so we have a copy of attribute map and must use that copy value = attributeMap.get(key); } else if (httpRequest != null) { // We have original request so take attribute from it value = httpRequest.getAttribute(key); } return value != null ? value.toString() : NA; } private void copyAttributeMap() { if (httpRequest == null) { return; } attributeMap = new HashMap<String, Object>(); Enumeration<String> names = httpRequest.getAttributeNames(); while (names.hasMoreElements()) { String name = names.nextElement(); Object value = httpRequest.getAttribute(name); if (shouldCopyAttribute(name, value)) { attributeMap.put(name, value); } } } private boolean shouldCopyAttribute(String name, Object value) { if (AccessConstants.LB_INPUT_BUFFER.equals(name) || AccessConstants.LB_OUTPUT_BUFFER.equals(name)) { // Do not copy attributes used by logback internally - these are available via other getters anyway return false; } else if (value == null) { // No reasons to copy nulls - Map.get() will return null for missing keys and the list of attribute // names is not available through IAccessEvent return false; } else { // Only copy what is serializable return value instanceof Serializable; } } @Override public String[] getRequestParameter(String key) { if (httpRequest != null) { String[] value = httpRequest.getParameterValues(key); if (value == null) { return new String[]{ NA }; } else { return value; } } else { return new String[]{ NA }; } } @Override public String getCookie(String key) { if (httpRequest != null) { Cookie[] cookieArray = httpRequest.getCookies(); if (cookieArray == null) { return NA; } for (Cookie cookie : cookieArray) { if (key.equals(cookie.getName())) { return cookie.getValue(); } } } return NA; } @Override public long getContentLength() { if (contentLength == SENTINEL) { if (httpResponse != null) { contentLength = serverAdapter.getContentLength(); return contentLength; } } return contentLength; } public int getStatusCode() { if (statusCode == SENTINEL) { if (httpResponse != null) { statusCode = serverAdapter.getStatusCode(); } } return statusCode; } public long getElapsedTime() { return elapsedTime; } private long calculateElapsedTime() { if (serverAdapter.getRequestTimestamp() < 0) { return -1; } return getTimeStamp() - serverAdapter.getRequestTimestamp(); } public String getRequestContent() { if (requestContent != null) { return requestContent; } if (Util.isFormUrlEncoded(httpRequest)) { StringBuilder buf = new StringBuilder(); Enumeration pramEnumeration = httpRequest.getParameterNames(); // example: id=1234&user=cgu // number=1233&x=1 int count = 0; try { while (pramEnumeration.hasMoreElements()) { String key = (String) pramEnumeration.nextElement(); if (count++ != 0) { buf.append("&"); } buf.append(key); buf.append("="); String val = httpRequest.getParameter(key); if (val != null) { buf.append(val); } else { buf.append(""); } } } catch (Exception e) { // FIXME Why is try/catch required? e.printStackTrace(); } requestContent = buf.toString(); } else { // retrieve the byte array placed by TeeFilter byte[] inputBuffer = (byte[]) httpRequest .getAttribute(AccessConstants.LB_INPUT_BUFFER); if (inputBuffer != null) { requestContent = new String(inputBuffer); } if (requestContent == null || requestContent.length() == 0) { requestContent = EMPTY; } } return requestContent; } public String getResponseContent() { if (responseContent != null) { return responseContent; } if (Util.isImageResponse(httpResponse)) { responseContent = "[IMAGE CONTENTS SUPPRESSED]"; } else { // retreive the byte array previously placed by TeeFilter byte[] outputBuffer = (byte[]) httpRequest .getAttribute(AccessConstants.LB_OUTPUT_BUFFER); if (outputBuffer != null) { responseContent = new String(outputBuffer); } if (responseContent == null || responseContent.length() == 0) { responseContent = EMPTY; } } return responseContent; } public int getLocalPort() { if (localPort == SENTINEL) { if (httpRequest != null) { localPort = httpRequest.getLocalPort(); } } return localPort; } public ServerAdapter getServerAdapter() { return serverAdapter; } public String getResponseHeader(String key) { buildResponseHeaderMap(); return responseHeaderMap.get(key); } void buildResponseHeaderMap() { if (responseHeaderMap == null) { responseHeaderMap = serverAdapter.buildResponseHeaderMap(); } } public Map<String, String> getResponseHeaderMap() { buildResponseHeaderMap(); return responseHeaderMap; } public List<String> getResponseHeaderNameList() { buildResponseHeaderMap(); return new ArrayList<String>(responseHeaderMap.keySet()); } public void prepareForDeferredProcessing() { getRequestHeaderMap(); getRequestParameterMap(); getResponseHeaderMap(); getLocalPort(); getMethod(); getProtocol(); getRemoteAddr(); getRemoteHost(); getRemoteUser(); getRequestURI(); getRequestURL(); getServerName(); getTimeStamp(); getElapsedTime(); getStatusCode(); getContentLength(); getRequestContent(); getResponseContent(); copyAttributeMap(); } }
cscfa/bartleby
library/logBack/logback-1.1.3/logback-access/src/main/java/ch/qos/logback/access/spi/AccessEvent.java
Java
mit
14,592
24.291892
109
0.6152
false
package appalounge; import org.json.JSONArray; import org.json.JSONObject; import resources.Constructors; import resources.exceptions.ApiException; import resources.exceptions.AuthRequiredException; import resources.exceptions.BadRequestException; import resources.exceptions.DataNotSetException; import resources.infrastructure.EasyApiComponent; /** * Returns an array of the announcements made on APPA Lounge * @author Aaron Vontell * @date 10/16/2015 * @version 0.1 */ public class APPAAnnounce implements EasyApiComponent{ private String url = ""; private JSONArray result; private String[] message; private String[] creator; private String[] created; /** * Create an announcement object */ protected APPAAnnounce() { url = AppaLounge.BASE_URL + "announcements/2/"; } /** * Downloads and parses all data from the given information */ @Override public void downloadData() throws ApiException, BadRequestException, DataNotSetException, AuthRequiredException { try { result = Constructors.constructJSONArray(url); message = new String[result.length()]; creator = new String[result.length()]; created = new String[result.length()]; for(int i = 0; i < result.length(); i++){ String mes = result.getJSONObject(i).getString("message"); String user = result.getJSONObject(i).getString("creator"); String date = result.getJSONObject(i).getString("created"); message[i] = mes; creator[i] = user; created[i] = date; } } catch (Exception e) { throw new ApiException("API Error: " + result.toString()); } } /** * Get the number of announcements * @return announcement amount */ public int getNumAnnouncements(){ return message.length; } /** * Get the message at a certain index * @param i The num message to get * @return The message at that position */ public String getMessageAt(int i){ return message[i]; } /** * Get the user at a certain index * @param i The num user to get * @return The user at that position */ public String getCreatorAt(int i){ return creator[i]; } /** * Get the date at a certain index * @param i The num date to get * @return The date at that position */ public String getCreatedAt(int i){ return created[i]; } @Override public String getRawData() { if(result != null){ return result.toString(); } else { return "No data"; } } }
vontell/EasyAPI
build/resources/main/appalounge/APPAAnnounce.java
Java
mit
2,768
25.113208
117
0.607659
false
package com.carlisle.incubators.PopupWindow; import android.os.Bundle; import android.support.annotation.Nullable; import android.support.v7.app.AppCompatActivity; import android.view.View; import com.carlisle.incubators.R; /** * Created by chengxin on 11/24/16. */ public class PopupWindowActivity extends AppCompatActivity { private PopupView popupView; @Override protected void onCreate(@Nullable Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_popup_window); popupView = new PopupView(this); } public void onButtonClick(View view) { //popupView.showAsDropDown(view); popupView.showAsDropUp(view); } }
CarlisleChan/Incubators
app/src/main/java/com/carlisle/incubators/PopupWindow/PopupWindowActivity.java
Java
mit
728
24.103448
66
0.732143
false
# Load the rails application require File.expand_path('../application', __FILE__) # Initialize the rails application Serenghetto::Application.initialize!
randomm/serenghetto-server
config/environment.rb
Ruby
mit
155
30
52
0.774194
false
# Phusion Passenger - https://www.phusionpassenger.com/ # Copyright (c) 2010 Phusion Holding B.V. # # "Passenger", "Phusion Passenger" and "Union Station" are registered # trademarks of Phusion Holding B.V. # # Permission is hereby granted, free of charge, to any person obtaining a copy # of this software and associated documentation files (the "Software"), to deal # in the Software without restriction, including without limitation the rights # to use, copy, modify, merge, publish, distribute, sublicense, and/or sell # copies of the Software, and to permit persons to whom the Software is # furnished to do so, subject to the following conditions: # # The above copyright notice and this permission notice shall be included in # all copies or substantial portions of the Software. # # THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR # IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, # FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE # AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER # LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN # THE SOFTWARE. require 'etc' module PhusionPassenger class Plugin @@hooks = {} @@classes = {} def self.load(name, load_once = true) PLUGIN_DIRS.each do |plugin_dir| if plugin_dir =~ /\A~/ # File.expand_path uses ENV['HOME'] which we don't want. home = Etc.getpwuid(Process.uid).dir plugin_dir = plugin_dir.sub(/\A~/, home) end plugin_dir = File.expand_path(plugin_dir) Dir["#{plugin_dir}/*/#{name}.rb"].each do |filename| if load_once require(filename) else load(filename) end end end end def self.register_hook(name, &block) hooks_list = (@@hooks[name] ||= []) hooks_list << block end def self.call_hook(name, *args, &block) last_result = nil if (hooks_list = @@hooks[name]) hooks_list.each do |callback| last_result = callback.call(*args, &block) end end return last_result end def self.register(name, klass) classes = (@@classes[name] ||= []) classes << klass end def initialize(name, *args, &block) Plugin.load(name) classes = @@classes[name] if classes @instances = classes.map do |klass| klass.new(*args, &block) end else return nil end end def call_hook(name, *args, &block) last_result = nil if @instances @instances.each do |instance| if instance.respond_to?(name.to_sym) last_result = instance.__send__(name.to_sym, *args, &block) end end end return last_result end end end # module PhusionPassenger
clemensg/passenger
src/ruby_supportlib/phusion_passenger/plugin.rb
Ruby
mit
2,994
30.1875
80
0.634603
false
// ReSharper disable RedundantNameQualifier // ReSharper disable InconsistentNaming namespace Gu.Analyzers.Benchmarks.Benchmarks { public class GU0050IgnoreEventsWhenSerializingBenchmarks { private static readonly Gu.Roslyn.Asserts.Benchmark Benchmark = Gu.Roslyn.Asserts.Benchmark.Create(Code.AnalyzersProject, new Gu.Analyzers.GU0050IgnoreEventsWhenSerializing()); [BenchmarkDotNet.Attributes.Benchmark] public void RunOnGuAnalyzersProject() { Benchmark.Run(); } } }
JohanLarsson/Gu.Analyzers
Gu.Analyzers.Benchmarks/Benchmarks/GU0050IgnoreEventsWhenSerializingBenchmarks.cs
C#
mit
534
34.6
184
0.741573
false
/*- * See the file LICENSE for redistribution information. * * Copyright (c) 2002,2008 Oracle. All rights reserved. * * $Id: EntityConverter.java,v 1.11 2008/01/07 14:28:58 cwl Exp $ */ package com.sleepycat.persist.evolve; import java.util.Collections; import java.util.HashSet; import java.util.Set; /** * A subclass of Converter that allows specifying keys to be deleted. * * <p>When a Converter is used with an entity class, secondary keys cannot be * automatically deleted based on field deletion, because field Deleter objects * are not used in conjunction with a Converter mutation. The EntityConverter * can be used instead of a plain Converter to specify the key names to be * deleted.</p> * * <p>It is not currently possible to rename or insert secondary keys when * using a Converter mutation with an entity class.</p> * * @see Converter * @see com.sleepycat.persist.evolve Class Evolution * @author Mark Hayes */ public class EntityConverter extends Converter { private static final long serialVersionUID = -988428985370593743L; private Set<String> deletedKeys; /** * Creates a mutation for converting all instances of the given entity * class version to the current version of the class. */ public EntityConverter(String entityClassName, int classVersion, Conversion conversion, Set<String> deletedKeys) { super(entityClassName, classVersion, null, conversion); /* Eclipse objects to assigning with a ternary operator. */ if (deletedKeys != null) { this.deletedKeys = new HashSet(deletedKeys); } else { this.deletedKeys = Collections.emptySet(); } } /** * Returns the set of key names that are to be deleted. */ public Set<String> getDeletedKeys() { return Collections.unmodifiableSet(deletedKeys); } /** * Returns true if the deleted and renamed keys are equal in this object * and given object, and if the {@link Converter#equals} superclass method * returns true. */ @Override public boolean equals(Object other) { if (other instanceof EntityConverter) { EntityConverter o = (EntityConverter) other; return deletedKeys.equals(o.deletedKeys) && super.equals(other); } else { return false; } } @Override public int hashCode() { return deletedKeys.hashCode() + super.hashCode(); } @Override public String toString() { return "[EntityConverter " + super.toString() + " DeletedKeys: " + deletedKeys + ']'; } }
plast-lab/DelphJ
examples/berkeleydb/com/sleepycat/persist/evolve/EntityConverter.java
Java
mit
2,735
30.079545
79
0.644241
false
/* * Popular Repositories * Copyright (c) 2014 Alberto Congiu (@4lbertoC) * * This source code is licensed under the MIT license found in the * LICENSE.txt file in the root directory of this source tree. */ 'use strict'; var React = require('react'); /** * Like Array.map(), but on an object's own properties. * Returns an array. * * @param {object} obj The object to call the function on. * @param {function(*, string)} func The function to call on each * of the object's properties. It takes as input parameters the * value and the key of the current property. * @returns {Array} The result. */ function mapObject(obj, func) { var results = []; if (obj) { for(var key in obj) { if (obj.hasOwnProperty(key)) { results.push(func(obj[key], key)); } } } return results; } /** * A component that displays a GitHub repo's languages. * * @prop {GitHubRepoLanguages} gitHubRepoLanguages. */ var LanguageList = React.createClass({ propTypes: { gitHubRepoLanguages: React.PropTypes.object.isRequired }, render() { var gitHubRepoLanguages = this.props.gitHubRepoLanguages; /* jshint ignore:start */ return ( <div className="text-center language-list"> {mapObject(gitHubRepoLanguages, (percentage, languageName) => { return ( <div className="language" key={languageName}> <h3 className="language-name">{languageName}</h3> <h5 className="language-percentage">{percentage}</h5> </div> ); })} </div> ); /* jshint ignore:end */ } }); module.exports = LanguageList;
4lbertoC/popularrepositories
src/components/layout/LanguageList.js
JavaScript
mit
1,648
23.597015
71
0.632282
false
# Arduino-Protothread-Library
Erutan409/Arduino-Protothread-Library
README.md
Markdown
mit
29
29
29
0.862069
false
<?php namespace Sitpac\ExtranetBundle\Entity; use Doctrine\ORM\Mapping as ORM; /** * DisponibilidadVehi * * @ORM\Table(name="disponibilidad_vehi") * @ORM\Entity */ class DisponibilidadVehi { /** * @var integer * * @ORM\Column(name="id_disp_vehi", type="integer", nullable=false) * @ORM\Id * @ORM\GeneratedValue(strategy="IDENTITY") */ private $idDispVehi; /** * @var \DateTime * * @ORM\Column(name="desde", type="datetime", nullable=false) */ private $desde; /** * @var \DateTime * * @ORM\Column(name="hasta", type="datetime", nullable=false) */ private $hasta; /** * @var string * * @ORM\Column(name="estado", type="string", length=100, nullable=false) */ private $estado; /** * @var \ServicioVehiculo * * @ORM\ManyToOne(targetEntity="ServicioVehiculo") * @ORM\JoinColumns({ * @ORM\JoinColumn(name="id_serv_vehi", referencedColumnName="idservicio_vehiculo") * }) */ private $idServVehi; /** * Get idDispVehi * * @return integer */ public function getIdDispVehi() { return $this->idDispVehi; } /** * Set desde * * @param \DateTime $desde * @return DisponibilidadVehi */ public function setDesde($desde) { $this->desde = $desde; return $this; } /** * Get desde * * @return \DateTime */ public function getDesde() { return $this->desde; } /** * Set hasta * * @param \DateTime $hasta * @return DisponibilidadVehi */ public function setHasta($hasta) { $this->hasta = $hasta; return $this; } /** * Get hasta * * @return \DateTime */ public function getHasta() { return $this->hasta; } /** * Set estado * * @param string $estado * @return DisponibilidadVehi */ public function setEstado($estado) { $this->estado = $estado; return $this; } /** * Get estado * * @return string */ public function getEstado() { return $this->estado; } /** * Set idServVehi * * @param \Sitpac\ExtranetBundle\Entity\ServicioVehiculo $idServVehi * @return DisponibilidadVehi */ public function setIdServVehi(\Sitpac\ExtranetBundle\Entity\ServicioVehiculo $idServVehi = null) { $this->idServVehi = $idServVehi; return $this; } /** * Get idServVehi * * @return \Sitpac\ExtranetBundle\Entity\ServicioVehiculo */ public function getIdServVehi() { return $this->idServVehi; } }
jorgeibarra87/SITPAC
src/Sitpac/ExtranetBundle/Entity/DisponibilidadVehi.php
PHP
mit
2,806
16.765823
100
0.532074
false
<!DOCTYPE html><meta charset=utf-8><title>WICS</title><script type="application/its+xml"> <its:rules xmlns:its="http://www.w3.org/2005/11/its" xmlns:h="http://www.w3.org/1999/xhtml" version="2.0"> <its:localeFilterRule selector="//@*" localeFilterType="include" localeFilterList="*"/> <its:dirRule dir="ltr" selector="//@*"/> <its:translateRule selector="//@*" translate="no"/> <its:withinTextRule selector="//h:span" withinText="no"/> <its:translateRule selector="id('ITS_1')|id('ITS_4')|id('ITS_5')" translate="no"/> <its:langRule selector="id('ITS_2')" langPointer="id('ITS_1')"/> <its:langRule selector="id('ITS_3')" langPointer="id('ITS_4')"/> <its:langRule selector="id('ITS_6')" langPointer="id('ITS_5')"/> </its:rules> </script><div title=text> <div title=head> </div> <div id=ITS_2 title=content><span class=_ITS_ATT id=ITS_1 its-within-text=no title=language>en</span> <div title=par>The motto of Québec is: <span id=ITS_3 title=q><span class=_ITS_ATT id=ITS_4 its-within-text=no title=language>fr-CA</span>Je me souviens</span>.</div> <div title=par>The one of Canada: <span id=ITS_6 title=q><span class=_ITS_ATT id=ITS_5 its-within-text=no title=language>la</span>A mari usque ad mare</span>.</div> </div> </div>
renatb/ITS2.0-WICS-converter
samples/output/ITS2.0_Test_Suite/XML/languageinformation/languageinfo1xml.html
HTML
mit
1,292
63.6
168
0.65763
false
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>ott: 31 s 🏆</title> <link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" /> <link href="../../../../../bootstrap.min.css" rel="stylesheet"> <link href="../../../../../bootstrap-custom.css" rel="stylesheet"> <link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet"> <script src="../../../../../moment.min.js"></script> <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries --> <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script> <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script> <![endif]--> </head> <body> <div class="container"> <div class="navbar navbar-default" role="navigation"> <div class="container-fluid"> <div class="navbar-header"> <a class="navbar-brand" href="../../../../.."><i class="fa fa-lg fa-flag-checkered"></i> Coq bench</a> </div> <div id="navbar" class="collapse navbar-collapse"> <ul class="nav navbar-nav"> <li><a href="../..">clean / released</a></li> <li class="active"><a href="">8.9.1 / ott - 0.29</a></li> </ul> </div> </div> </div> <div class="article"> <div class="row"> <div class="col-md-12"> <a href="../..">« Up</a> <h1> ott <small> 0.29 <span class="label label-success">31 s 🏆</span> </small> </h1> <p>📅 <em><script>document.write(moment("2022-01-31 22:04:34 +0000", "YYYY-MM-DD HH:mm:ss Z").fromNow());</script> (2022-01-31 22:04:34 UTC)</em><p> <h2>Context</h2> <pre># Packages matching: installed # Name # Installed # Synopsis base-bigarray base base-threads base base-unix base camlp5 7.14 Preprocessor-pretty-printer of OCaml conf-findutils 1 Virtual package relying on findutils conf-perl 2 Virtual package relying on perl coq 8.9.1 Formal proof management system num 1.4 The legacy Num library for arbitrary-precision integer and rational arithmetic ocaml 4.08.1 The OCaml compiler (virtual package) ocaml-base-compiler 4.08.1 Official release 4.08.1 ocaml-config 1 OCaml Switch Configuration ocamlfind 1.9.3 A library manager for OCaml # opam file: opam-version: &quot;2.0&quot; maintainer: &quot;palmskog@gmail.com&quot; homepage: &quot;http://www.cl.cam.ac.uk/~pes20/ott/&quot; dev-repo: &quot;git+https://github.com/ott-lang/ott.git&quot; bug-reports: &quot;https://github.com/ott-lang/ott/issues&quot; license: &quot;BSD-3-Clause&quot; synopsis: &quot;Auxiliary Coq library for Ott, a tool for writing definitions of programming languages and calculi&quot; description: &quot;&quot;&quot; Ott takes as input a definition of a language syntax and semantics, in a concise and readable ASCII notation that is close to what one would write in informal mathematics. It can then generate a Coq version of the definition, which requires this library. &quot;&quot;&quot; build: [make &quot;-j%{jobs}%&quot; &quot;-C&quot; &quot;coq&quot;] install: [make &quot;-C&quot; &quot;coq&quot; &quot;install&quot;] depends: [ &quot;coq&quot; {&gt;= &quot;8.5&quot; &amp; &lt; &quot;8.11~&quot;} ] tags: [ &quot;category:Computer Science/Semantics and Compilation/Semantics&quot; &quot;keyword:abstract syntax&quot; &quot;logpath:Ott&quot; &quot;date:2019-08-01&quot; ] authors: [ &quot;Peter Sewell&quot; &quot;Francesco Zappa Nardelli&quot; &quot;Scott Owens&quot; ] url { src: &quot;https://github.com/ott-lang/ott/archive/0.29.tar.gz&quot; checksum: &quot;sha512=2ffc10e5d6290b5a737add419e5441b85a60fda7a9c4544f91bcfd8cd69e318d465787b2500003109186cc3945c3dcb5661371a419c3ef117adff9fc2d8f3e5b&quot; } </pre> <h2>Lint</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Dry install 🏜️</h2> <p>Dry install with the current Coq version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam install -y --show-action coq-ott.0.29 coq.8.9.1</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <p>Dry install without Coq/switch base, to test if the problem was incompatibility with the current Coq/OCaml version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Install dependencies</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam list; echo; ulimit -Sv 4000000; timeout 4h opam install -y --deps-only coq-ott.0.29 coq.8.9.1</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>12 s</dd> </dl> <h2>Install 🚀</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam list; echo; ulimit -Sv 16000000; timeout 4h opam install -y -v coq-ott.0.29 coq.8.9.1</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>31 s</dd> </dl> <h2>Installation size</h2> <p>Total: 746 K</p> <ul> <li>82 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_predicate.vo</code></li> <li>68 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_takedrop.vo</code></li> <li>58 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_nth.vo</code></li> <li>56 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_distinct.vo</code></li> <li>54 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_base.vo</code></li> <li>48 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_mem.vo</code></li> <li>37 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_flat_map.vo</code></li> <li>36 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_predicate.glob</code></li> <li>35 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_repeat.vo</code></li> <li>31 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_support.vo</code></li> <li>26 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_takedrop.glob</code></li> <li>24 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list.vo</code></li> <li>19 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_nth.glob</code></li> <li>19 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_distinct.glob</code></li> <li>18 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_core.vo</code></li> <li>17 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_base.glob</code></li> <li>17 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_eq_dec.vo</code></li> <li>16 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_mem.glob</code></li> <li>13 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_predicate.v</code></li> <li>10 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_takedrop.v</code></li> <li>8 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_flat_map.glob</code></li> <li>6 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_core.glob</code></li> <li>6 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_base.v</code></li> <li>6 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_distinct.v</code></li> <li>6 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_nth.v</code></li> <li>6 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_repeat.glob</code></li> <li>5 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_mem.v</code></li> <li>5 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_support.glob</code></li> <li>3 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_eq_dec.glob</code></li> <li>3 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_flat_map.v</code></li> <li>2 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_core.v</code></li> <li>2 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_repeat.v</code></li> <li>2 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_eq_dec.v</code></li> <li>1 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list.v</code></li> <li>1 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list_support.v</code></li> <li>1 K <code>../ocaml-base-compiler.4.08.1/lib/coq/user-contrib/Ott/ott_list.glob</code></li> </ul> <h2>Uninstall 🧹</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam remove -y coq-ott.0.29</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Missing removes</dt> <dd> none </dd> <dt>Wrong removes</dt> <dd> none </dd> </dl> </div> </div> </div> <hr/> <div class="footer"> <p class="text-center"> Sources are on <a href="https://github.com/coq-bench">GitHub</a> © Guillaume Claret 🐣 </p> </div> </div> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <script src="../../../../../bootstrap.min.js"></script> </body> </html>
coq-bench/coq-bench.github.io
clean/Linux-x86_64-4.08.1-2.0.5/released/8.9.1/ott/0.29.html
HTML
mit
11,038
52.985294
159
0.57078
false
module ResetConfigHelper def self.included(base) base.instance_eval do around(:each) do |example| begin Capybara::AsyncRunner.config.commands_directory = ROOT.join('spec/support/js') example.run ensure Capybara::AsyncRunner.config.reset! end end end end end RSpec.configure do |config| config.include ResetConfigHelper end
iliabylich/capybara-async-runner
spec/support/reset_config_helper.rb
Ruby
mit
404
21.444444
88
0.65099
false
import assert from 'assert' import {fixCase} from '../../src/lib/words/case' import Locale from '../../src/locale/locale' describe('Corrects accidental uPPERCASE\n', () => { let testCase = { 'Hey, JEnnifer!': 'Hey, Jennifer!', 'CMSko': 'CMSko', 'FPs': 'FPs', 'ČSNka': 'ČSNka', 'BigONE': 'BigONE', // specific brand names 'two Panzer IVs': 'two Panzer IVs', 'How about ABC?': 'How about ABC?', 'cAPSLOCK': 'capslock', '(cAPSLOCK)': '(capslock)', 'iPhone': 'iPhone', 'iT': 'it', 'Central Europe and Cyrillic tests: aĎIÉUБUГ': 'Central Europe and Cyrillic tests: aďiéuбuг', } Object.keys(testCase).forEach((key) => { it('', () => { assert.equal(fixCase(key, new Locale('en-us')), testCase[key]) }) }) })
viktorbezdek/react-htmlcontent
test/words/case.test.js
JavaScript
mit
783
28.730769
97
0.586028
false
<?php /* * This file is part of the Sylius package. * * (c) Paweł Jędrzejewski * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Sylius\Bundle\ResourceBundle; use Sylius\Bundle\ResourceBundle\DependencyInjection\Compiler\ObjectToIdentifierServicePass; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\HttpKernel\Bundle\Bundle; /** * Resource bundle. * * @author Paweł Jędrzejewski <pjedrzejewski@sylius.pl> */ class SyliusResourceBundle extends Bundle { // Bundle driver list. const DRIVER_DOCTRINE_ORM = 'doctrine/orm'; const DRIVER_DOCTRINE_MONGODB_ODM = 'doctrine/mongodb-odm'; const DRIVER_DOCTRINE_PHPCR_ODM = 'doctrine/phpcr-odm'; /** * {@inheritdoc} */ public function build(ContainerBuilder $container) { $container->addCompilerPass(new ObjectToIdentifierServicePass()); } }
Symfomany/Sylius
src/Sylius/Bundle/ResourceBundle/SyliusResourceBundle.php
PHP
mit
976
25.27027
92
0.733539
false
#!/usr/bin/env python from __future__ import division, print_function, absolute_import from os.path import join def configuration(parent_package='', top_path=None): import warnings from numpy.distutils.misc_util import Configuration from numpy.distutils.system_info import get_info, BlasNotFoundError config = Configuration('odr', parent_package, top_path) libodr_files = ['d_odr.f', 'd_mprec.f', 'dlunoc.f'] blas_info = get_info('blas_opt') if blas_info: libodr_files.append('d_lpk.f') else: warnings.warn(BlasNotFoundError.__doc__) libodr_files.append('d_lpkbls.f') odrpack_src = [join('odrpack', x) for x in libodr_files] config.add_library('odrpack', sources=odrpack_src) sources = ['__odrpack.c'] libraries = ['odrpack'] + blas_info.pop('libraries', []) include_dirs = ['.'] + blas_info.pop('include_dirs', []) config.add_extension('__odrpack', sources=sources, libraries=libraries, include_dirs=include_dirs, depends=(['odrpack.h'] + odrpack_src), **blas_info ) config.add_data_dir('tests') return config if __name__ == '__main__': from numpy.distutils.core import setup setup(**configuration(top_path='').todict())
DailyActie/Surrogate-Model
01-codes/scipy-master/scipy/odr/setup.py
Python
mit
1,419
30.533333
71
0.572234
false
package photoeffect.effect.otherblur; import java.awt.image.BufferedImage; import measure.generic.IGenericWorkload; public interface IEffectOtherBlur extends IGenericWorkload<BufferedImage> { }
wolfposd/jadexphoto
photoeffect/src/photoeffect/effect/otherblur/IEffectOtherBlur.java
Java
mit
198
18.8
73
0.843434
false
#!/bin/bash -x # # Generated - do not edit! # # Macros TOP=`pwd` CND_CONF=default CND_DISTDIR=dist TMPDIR=build/${CND_CONF}/${IMAGE_TYPE}/tmp-packaging TMPDIRNAME=tmp-packaging OUTPUT_PATH=dist/${CND_CONF}/${IMAGE_TYPE}/PIC24_Dev_Board_Template.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} OUTPUT_BASENAME=PIC24_Dev_Board_Template.X.${IMAGE_TYPE}.${OUTPUT_SUFFIX} PACKAGE_TOP_DIR=pic24devboardtemplate.x/ # Functions function checkReturnCode { rc=$? if [ $rc != 0 ] then exit $rc fi } function makeDirectory # $1 directory path # $2 permission (optional) { mkdir -p "$1" checkReturnCode if [ "$2" != "" ] then chmod $2 "$1" checkReturnCode fi } function copyFileToTmpDir # $1 from-file path # $2 to-file path # $3 permission { cp "$1" "$2" checkReturnCode if [ "$3" != "" ] then chmod $3 "$2" checkReturnCode fi } # Setup cd "${TOP}" mkdir -p ${CND_DISTDIR}/${CND_CONF}/package rm -rf ${TMPDIR} mkdir -p ${TMPDIR} # Copy files and create directories and links cd "${TOP}" makeDirectory ${TMPDIR}/pic24devboardtemplate.x/bin copyFileToTmpDir "${OUTPUT_PATH}" "${TMPDIR}/${PACKAGE_TOP_DIR}bin/${OUTPUT_BASENAME}" 0755 # Generate tar file cd "${TOP}" rm -f ${CND_DISTDIR}/${CND_CONF}/package/pic24devboardtemplate.x.tar cd ${TMPDIR} tar -vcf ../../../../${CND_DISTDIR}/${CND_CONF}/package/pic24devboardtemplate.x.tar * checkReturnCode # Cleanup cd "${TOP}" rm -rf ${TMPDIR}
briandorey/PIC24-Dev-Board
Firmware/Template/PIC24 Dev Board Template.X/nbproject/Package-default.bash
Shell
mit
1,459
18.986301
100
0.647704
false
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>kildall: Not compatible 👼</title> <link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" /> <link href="../../../../../bootstrap.min.css" rel="stylesheet"> <link href="../../../../../bootstrap-custom.css" rel="stylesheet"> <link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet"> <script src="../../../../../moment.min.js"></script> <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries --> <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script> <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script> <![endif]--> </head> <body> <div class="container"> <div class="navbar navbar-default" role="navigation"> <div class="container-fluid"> <div class="navbar-header"> <a class="navbar-brand" href="../../../../.."><i class="fa fa-lg fa-flag-checkered"></i> Coq bench</a> </div> <div id="navbar" class="collapse navbar-collapse"> <ul class="nav navbar-nav"> <li><a href="../..">clean / released</a></li> <li class="active"><a href="">8.10.2 / kildall - 8.9.0</a></li> </ul> </div> </div> </div> <div class="article"> <div class="row"> <div class="col-md-12"> <a href="../..">« Up</a> <h1> kildall <small> 8.9.0 <span class="label label-info">Not compatible 👼</span> </small> </h1> <p>📅 <em><script>document.write(moment("2021-12-02 03:04:00 +0000", "YYYY-MM-DD HH:mm:ss Z").fromNow());</script> (2021-12-02 03:04:00 UTC)</em><p> <h2>Context</h2> <pre># Packages matching: installed # Name # Installed # Synopsis base-bigarray base base-threads base base-unix base conf-findutils 1 Virtual package relying on findutils coq 8.10.2 Formal proof management system num 1.4 The legacy Num library for arbitrary-precision integer and rational arithmetic ocaml 4.08.1 The OCaml compiler (virtual package) ocaml-base-compiler 4.08.1 Official release 4.08.1 ocaml-config 1 OCaml Switch Configuration ocamlfind 1.9.1 A library manager for OCaml # opam file: opam-version: &quot;2.0&quot; maintainer: &quot;Hugo.Herbelin@inria.fr&quot; homepage: &quot;http://www.lif-sud.univ-mrs.fr/Rapports/24-2005.html&quot; license: &quot;Unknown&quot; build: [make &quot;-j%{jobs}%&quot;] install: [make &quot;install&quot;] remove: [&quot;rm&quot; &quot;-R&quot; &quot;%{lib}%/coq/user-contrib/Kildall&quot;] depends: [ &quot;ocaml&quot; &quot;coq&quot; {&gt;= &quot;8.9&quot; &amp; &lt; &quot;8.10~&quot;} ] tags: [ &quot;keyword: Kildall&quot; &quot;keyword: data flow analysis&quot; &quot;keyword: bytecode verification&quot; &quot;category: Computer Science/Semantics and Compilation/Semantics&quot; &quot;date: 2005-07&quot; ] authors: [ &quot;Solange Coupet-Grimal &lt;Solange.Coupet@cmi.univ-mrs.fr&gt;&quot; &quot;William Delobel &lt;delobel@cmi.univ-mrs.fr&gt;&quot; ] bug-reports: &quot;https://github.com/coq-contribs/kildall/issues&quot; dev-repo: &quot;git+https://github.com/coq-contribs/kildall.git&quot; synopsis: &quot;Application of the Generic kildall&#39;s Data Flow Analysis Algorithm to a Type and Shape Static Analyses of Bytecode&quot; description: &quot;&quot;&quot; This Library provides a generic data flow analysis algorithm and a proof of its correctness. This algorithm is then used to perform type and shape analysis at bytecode level on a first order functionnal language.&quot;&quot;&quot; flags: light-uninstall url { src: &quot;https://github.com/coq-contribs/kildall/archive/v8.9.0.tar.gz&quot; checksum: &quot;md5=e90951bfbcbdfef76704b8f407b93125&quot; } </pre> <h2>Lint</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Dry install 🏜️</h2> <p>Dry install with the current Coq version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam install -y --show-action coq-kildall.8.9.0 coq.8.10.2</code></dd> <dt>Return code</dt> <dd>5120</dd> <dt>Output</dt> <dd><pre>[NOTE] Package coq is already installed (current version is 8.10.2). The following dependencies couldn&#39;t be met: - coq-kildall -&gt; coq &lt; 8.10~ -&gt; ocaml &lt; 4.06.0 base of this switch (use `--unlock-base&#39; to force) Your request can&#39;t be satisfied: - No available version of coq satisfies the constraints No solution found, exiting </pre></dd> </dl> <p>Dry install without Coq/switch base, to test if the problem was incompatibility with the current Coq/OCaml version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam remove -y coq; opam install -y --show-action --unlock-base coq-kildall.8.9.0</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Install dependencies</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>0 s</dd> </dl> <h2>Install 🚀</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>0 s</dd> </dl> <h2>Installation size</h2> <p>No files were installed.</p> <h2>Uninstall 🧹</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Missing removes</dt> <dd> none </dd> <dt>Wrong removes</dt> <dd> none </dd> </dl> </div> </div> </div> <hr/> <div class="footer"> <p class="text-center"> Sources are on <a href="https://github.com/coq-bench">GitHub</a> © Guillaume Claret 🐣 </p> </div> </div> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <script src="../../../../../bootstrap.min.js"></script> </body> </html>
coq-bench/coq-bench.github.io
clean/Linux-x86_64-4.08.1-2.0.5/released/8.10.2/kildall/8.9.0.html
HTML
mit
7,189
39.704545
159
0.552764
false
import Store from '../../Store'; import Expires from '../../Expires'; import { lpush } from '../lpush'; import { lpushx } from '../lpushx'; describe('Test lpushx command', () => { it('should prepend values to list', () => { const redis = new MockRedis(); redis.set('mylist', []); expect((<any>redis).lpushx('mylist', 'v1')).toBe(1); expect((<any>redis).lpushx('mylist1', 'v2')).toBe(0); expect(redis.get('mylist1')).toBeNull(); }); }); class MockRedis { private data: Store; constructor() { this.data = new Store(new Expires()); (<any>this)['lpush'] = lpush.bind(this); (<any>this)['lpushx'] = lpushx.bind(this); } get(key: string) { return this.data.get(key) || null; } set(key: string, value: any) { return this.data.set(key, value); } }
nileshmali/ioredis-in-memory
src/commands/__tests__/lpushx.spec.ts
TypeScript
mit
800
26.586207
57
0.5875
false
<!DOCTYPE html> <html xmlns:msxsl="urn:schemas-microsoft-com:xslt"> <head> <meta content="en-us" http-equiv="Content-Language" /> <meta content="text/html; charset=utf-16" http-equiv="Content-Type" /> <title _locid="PortabilityAnalysis0">.NET Portability Report</title> <style> /* Body style, for the entire document */ body { background: #F3F3F4; color: #1E1E1F; font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif; padding: 0; margin: 0; } /* Header1 style, used for the main title */ h1 { padding: 10px 0px 10px 10px; font-size: 21pt; background-color: #E2E2E2; border-bottom: 1px #C1C1C2 solid; color: #201F20; margin: 0; font-weight: normal; } /* Header2 style, used for "Overview" and other sections */ h2 { font-size: 18pt; font-weight: normal; padding: 15px 0 5px 0; margin: 0; } /* Header3 style, used for sub-sections, such as project name */ h3 { font-weight: normal; font-size: 15pt; margin: 0; padding: 15px 0 5px 0; background-color: transparent; } h4 { font-weight: normal; font-size: 12pt; margin: 0; padding: 0 0 0 0; background-color: transparent; } /* Color all hyperlinks one color */ a { color: #1382CE; } /* Paragraph text (for longer informational messages) */ p { font-size: 10pt; } /* Table styles */ table { border-spacing: 0 0; border-collapse: collapse; font-size: 10pt; } table th { background: #E7E7E8; text-align: left; text-decoration: none; font-weight: normal; padding: 3px 6px 3px 6px; } table td { vertical-align: top; padding: 3px 6px 5px 5px; margin: 0px; border: 1px solid #E7E7E8; background: #F7F7F8; } .NoBreakingChanges { color: darkgreen; font-weight:bold; } .FewBreakingChanges { color: orange; font-weight:bold; } .ManyBreakingChanges { color: red; font-weight:bold; } .BreakDetails { margin-left: 30px; } .CompatMessage { font-style: italic; font-size: 10pt; } .GoodMessage { color: darkgreen; } /* Local link is a style for hyperlinks that link to file:/// content, there are lots so color them as 'normal' text until the user mouse overs */ .localLink { color: #1E1E1F; background: #EEEEED; text-decoration: none; } .localLink:hover { color: #1382CE; background: #FFFF99; text-decoration: none; } /* Center text, used in the over views cells that contain message level counts */ .textCentered { text-align: center; } /* The message cells in message tables should take up all avaliable space */ .messageCell { width: 100%; } /* Padding around the content after the h1 */ #content { padding: 0px 12px 12px 12px; } /* The overview table expands to width, with a max width of 97% */ #overview table { width: auto; max-width: 75%; } /* The messages tables are always 97% width */ #messages table { width: 97%; } /* All Icons */ .IconSuccessEncoded, .IconInfoEncoded, .IconWarningEncoded, .IconErrorEncoded { min-width: 18px; min-height: 18px; background-repeat: no-repeat; background-position: center; } /* Success icon encoded */ .IconSuccessEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconSuccess#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAABPElEQVR4Xp1Tv0vDUBi8FqeA4NpBcBLcWnQSApncOnTo4FSnjP0DsnXpH5CxiwbHDg4Zuj4oOEXiJgiC4FDcCkLWmIMc1Pfw+eMgQ77v3Xf3Pe51YKGqqisAEwCR1TIAsiAIblSo6xrdHeJR85Xle3mdmCQKb0PsfqyxxzM8K15HZADl/H5+sHpZwYfxyRjTs+kWwKBx8yoHd2mRiuzF8mkJniWH/13u3Fjrs/EdhsdDFHGB/DLXEJBDLh1MWPAhPo1BLB4WX5yQywHR+m3tVe/t97D52CB/ziG0nIgD/qDuYg8WuCcVZ2YGwlJ3YDugkpR/VNcAEx6GEKhERSr71FuO4YCM4XBdwKvecjIlkSnsO0Hyp/GxSeJAdzBKzpOtnPwyyiPdAZhpZptT04tU+zk7s8czeges//s5C5+CwqrR4/gw+AAAAABJRU5ErkJggg==); } /* Information icon encoded */ .IconInfoEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconInformation#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAABHElEQVR4Xs2TsUoDQRRF7wwoziokjZUKadInhdhukR9YP8DMX1hYW+QvdsXa/QHBbcXC7W0CamWTQnclFutceIQJwwaWNLlwm5k5d94M76mmaeCrrmsLYOocY12FcxZFUeozCqKqqgYA8uevv1H6VuPxcwlfk5N92KHBxfFeCSAxxswlYAW/Xr989x/mv9gkhtyMDhcAxgzRsp7flj8B/HF1RsMXq+NZMkopaHe7lbKxQUEIGbKsYNoGn969060hZBkQex/W8oRQwsQaW2o3Ago2SVcJUzAgY3N0lTCZZm+zPS8HB51gMmS1DEYyOz9acKO1D8JWTlafKIMxdhvlfdyT94Vv5h7P8Ky7nQzACmhvKq3zk3PjW9asz9D/1oigecsioooAAAAASUVORK5CYII=); } /* Warning icon encoded */ .IconWarningEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconWarning#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAA7EAAAOxAGVKw4bAAAAx0lEQVR4XpWSMQ7CMAxFf4xAyBMLCxMrO8dhaBcuwdCJS3RJBw7SA/QGTCxdWJgiQYWKXJWKIXHIlyw5lqr34tQgEOdcBsCOx5yZK3hCCKdYXneQkh4pEfqzLfu+wVDSyyzFoJjfz9NB+pAF+eizx2Vruts0k15mPgvS6GYvpVtQhB61IB/dk6AF6fS4Ben0uIX5odtFe8Q/eW1KvFeH4e8khT6+gm5B+t3juyDt7n0jpe+CANTd+oTUjN/U3yVaABnSUjFz/gFq44JaVSCXeQAAAABJRU5ErkJggg==); } /* Error icon encoded */ .IconErrorEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconError#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAABQElEQVR4XqWTvUoEQRCE6wYPZUA80AfwAQz23uCMjA7MDRQEIzPBVEyNTQUFIw00vcQTTMzuAh/AxEQQT8HF/3G/oGGnEUGuoNnd6qoZuqltyKEsyzVJq5I6rnUp6SjGeGhESikzzlc1eL7opfuVbrqbU1Zw9NCgtQMaZpY0eNnaaL2fHusvTK5vKu7sjSS1Y4y3QUA6K3e3Mau5UFDyMP7tYF9o8cAHZv68vipoIJg971PZIZ5HiwdvYGGvFVFHmGmZ2MxwmQYPXubPl9Up0tfoMQGetXd6mRbvhBw+boZ6WF7Mbv1+GsHRk0fQmPAH1GfmZirbCfDJ61tw3Px8/8pZsPAG4jlVhcPgZ7adwNWBB68lkRQWFiTgFlbnLY3DGGM7izIJIyT/jjIvEJw6fdJTc6krDzh6aMwMP9bvDH4ADSsa9uSWVJkAAAAASUVORK5CYII=); } </style> </head> <body> <h1 _locid="PortabilityReport">.NET Portability Report</h1> <div id="content"> <div id="submissionId" style="font-size:8pt;"> <p> <i> Submission Id&nbsp; 984fc60a-8754-43ef-af0a-752445f9b305 </i> </p> </div> <h2 _locid="SummaryTitle"> <a name="Portability Summary"></a>Portability Summary </h2> <div id="summary"> <table> <tbody> <tr> <th>Assembly</th> <th>ASP.NET 5,Version=v1.0</th> <th>Windows,Version=v8.1</th> <th>.NET Framework,Version=v4.6</th> <th>Windows Phone,Version=v8.1</th> </tr> <tr> <td><strong><a href="#Concierge">Concierge</a></strong></td> <td class="text-center">83.31 %</td> <td class="text-center">74.39 %</td> <td class="text-center">100.00 %</td> <td class="text-center">67.42 %</td> </tr> </tbody> </table> </div> <div id="details"> <a name="Concierge"><h3>Concierge</h3></a> <table> <tbody> <tr> <th>Target type</th> <th>ASP.NET 5,Version=v1.0</th> <th>Windows,Version=v8.1</th> <th>.NET Framework,Version=v4.6</th> <th>Windows Phone,Version=v8.1</th> <th>Recommended changes</th> </tr> <tr> <td>Microsoft.Build.Framework.RequiredAttribute</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.AppDomain</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage of AppDomain. Use alternate means for managing configuration information.</td> </tr> <tr> <td style="padding-left:2em">get_BaseDirectory</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Currently there is no workaround, but we are working on it. Please check back.</td> </tr> <tr> <td style="padding-left:2em">get_CurrentDomain</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td style="padding-left:2em">get_SetupInformation</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage of AppDomain. Use alternate means for managing configuration information.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.AppDomainSetup</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td style="padding-left:2em">get_ConfigurationFile</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Attribute</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Reflection.CustomAttributeExtensions.IsDefined() in System.Reflection.Extensions</td> </tr> <tr> <td style="padding-left:2em">IsDefined(System.Reflection.MemberInfo,System.Type)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Reflection.CustomAttributeExtensions.IsDefined() in System.Reflection.Extensions</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Collections.Generic.KeyedByTypeCollection`1</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Collections.Generic.List`1</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">ForEach(System.Action{`0})</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Collections.Specialized.StringDictionary</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Add(System.String,System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">ContainsKey(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Item(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_Item(System.String,System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ComponentModel.Container</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ComponentModel.IContainer</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ComponentModel.RunInstallerAttribute</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.Boolean)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Configuration.Install.InstallContext</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Parameters</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Configuration.Install.Installer</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Context</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Installers</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">OnBeforeInstall(System.Collections.IDictionary)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">OnBeforeUninstall(System.Collections.IDictionary)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Configuration.Install.InstallerCollection</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Add(System.Configuration.Install.Installer)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Configuration.Install.InstallException</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Configuration.Install.ManagedInstallerClass</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">InstallHelper(System.String[])</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Console</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">OpenStandardInput</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">ReadLine</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_Title(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Write(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">WriteLine(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">WriteLine(System.String,System.Object[])</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Data.DuplicateNameException</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Data.InvalidExpressionException</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Diagnostics.Contracts.Internal.ContractHelper</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">RaiseContractFailedEvent(System.Diagnostics.Contracts.ContractFailureKind,System.String,System.String,System.Exception)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Diagnostics.FileVersionInfo</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Currently there is no workaround, but we are working on it. Please check back.</td> </tr> <tr> <td style="padding-left:2em">get_ProductVersion</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetVersionInfo(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Currently there is no workaround, but we are working on it. Please check back.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Diagnostics.Process</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_ExitCode</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_StartInfo</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Start</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">WaitForExit</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Diagnostics.ProcessStartInfo</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_Arguments(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_FileName(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_WindowStyle(System.Diagnostics.ProcessWindowStyle)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove ShellExecute usage (Can Pinvoke if needed)</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Diagnostics.ProcessWindowStyle</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove ShellExecute usage (Can Pinvoke if needed)</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Exception</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage.</td> </tr> <tr> <td style="padding-left:2em">add_SerializeObjectState(System.EventHandler{System.Runtime.Serialization.SafeSerializationEventArgs})</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.InvalidProgramException</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.IO.DirectoryNotFoundException</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.IO.File</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Exists(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">OpenText(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.IO.Stream</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Stream.ReadAsync</td> </tr> <tr> <td style="padding-left:2em">BeginRead(System.Byte[],System.Int32,System.Int32,System.AsyncCallback,System.Object)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Stream.ReadAsync</td> </tr> <tr> <td style="padding-left:2em">Close</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Dispose instead</td> </tr> <tr> <td style="padding-left:2em">EndRead(System.IAsyncResult)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Stream.ReadAsync</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.IO.StreamWriter</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use File.Open to get a Stream then pass it to StreamWriter constructor</td> </tr> <tr> <td style="padding-left:2em">#ctor(System.String,System.Boolean)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use File.Open to get a Stream then pass it to StreamWriter constructor</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Management.InvokeMethodOptions</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Management.ManagementBaseObject</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Item(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Management.ManagementObject</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.Management.ManagementPath)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Get</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">InvokeMethod(System.String,System.Management.ManagementBaseObject,System.Management.InvokeMethodOptions)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Management.ManagementPath</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.MethodAccessException</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Reflection.Assembly</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Assembly.DefinedTypes</td> </tr> <tr> <td style="padding-left:2em">get_Location</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td style="padding-left:2em">GetEntryAssembly</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetTypes</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Assembly.DefinedTypes</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Reflection.BindingFlags</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Reflection.TargetException</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Runtime.ConstrainedExecution.Cer</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Runtime.ConstrainedExecution.Consistency</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Runtime.ConstrainedExecution.ReliabilityContractAttribute</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td style="padding-left:2em">#ctor(System.Runtime.ConstrainedExecution.Consistency,System.Runtime.ConstrainedExecution.Cer)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Runtime.Serialization.ISafeSerializationData</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>either 1) Delete Serialization info from exceptions (since this can&#39;t be remoted) or 2) Use a different serialization technology if not for exceptions.</td> </tr> <tr> <td style="padding-left:2em">CompleteDeserialization(System.Object)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>either 1) Delete Serialization info from exceptions (since this can&#39;t be remoted) or 2) Use a different serialization technology if not for exceptions.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Runtime.Serialization.SafeSerializationEventArgs</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>either 1) Delete Serialization info from exceptions (since this can&#39;t be remoted) or 2) Use a different serialization technology if not for exceptions.</td> </tr> <tr> <td style="padding-left:2em">AddSerializedState(System.Runtime.Serialization.ISafeSerializationData)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>either 1) Delete Serialization info from exceptions (since this can&#39;t be remoted) or 2) Use a different serialization technology if not for exceptions.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.ChannelFactory</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Endpoint</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.ChannelFactory`1</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.ServiceModel.Channels.Binding,System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">CreateChannel</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Channels.Binding</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Channels.BindingParameterCollection</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Channels.CommunicationObject</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Close</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_State</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Open</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Channels.Message</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.CommunicationException</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.CommunicationState</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.ConcurrencyMode</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Description.ContractDescription</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Behaviors</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Description.IContractBehavior</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Description.IServiceBehavior</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Description.ServiceDescription</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Behaviors</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Endpoints</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Description.ServiceEndpoint</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Description.ServiceEndpointCollection</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Description.ServiceMetadataBehavior</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_HttpGetEnabled(System.Boolean)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Dispatcher.ClientRuntime</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Dispatcher.DispatchRuntime</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_InstanceProvider(System.ServiceModel.Dispatcher.IInstanceProvider)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.Dispatcher.IInstanceProvider</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.EndpointAddress</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.IClientChannel</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.ICommunicationObject</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Abort</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">add_Closed(System.EventHandler)</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">add_Faulted(System.EventHandler)</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">BeginOpen(System.AsyncCallback,System.Object)</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Close</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">EndOpen(System.IAsyncResult)</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_State</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Open</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Open(System.TimeSpan)</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">remove_Closed(System.EventHandler)</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">remove_Faulted(System.EventHandler)</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.IContextChannel</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_OperationTimeout</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_RemoteAddress</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.InstanceContext</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.NetTcpBinding</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.OperationContractAttribute</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.ServiceBehaviorAttribute</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.ServiceContractAttribute</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.ServiceHost</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.Type,System.Uri[])</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">AddServiceEndpoint(System.Type,System.ServiceModel.Channels.Binding,System.Uri)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceModel.ServiceHostBase</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Description</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_ImplementedContracts</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceProcess.ServiceAccount</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceProcess.ServiceBase</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Dispose(System.Boolean)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">OnStart(System.String[])</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Run(System.ServiceProcess.ServiceBase[])</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_ServiceName(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceProcess.ServiceController</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_DisplayName</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_ServiceName</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Status</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetServices</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Start</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Stop</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">WaitForStatus(System.ServiceProcess.ServiceControllerStatus,System.TimeSpan)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceProcess.ServiceControllerStatus</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceProcess.ServiceInstaller</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_Description(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_DisplayName(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_ServiceName(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_StartType(System.ServiceProcess.ServiceStartMode)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceProcess.ServiceProcessInstaller</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_Account(System.ServiceProcess.ServiceAccount)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_Password(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_Username(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ServiceProcess.ServiceStartMode</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Threading.Thread</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.Threading.ThreadStart)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_CurrentThread</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_ManagedThreadId</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Join</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Sleep(System.Int32)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Start</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Threading.ThreadStart</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.Object,System.IntPtr)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Type</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetMethods</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetProperties(System.Reflection.BindingFlags)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetProperty(System.String,System.Reflection.BindingFlags)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">IsSubclassOf(System.Type)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>.GetTypeInfo().IsSubclassOf</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> </tbody> </table> <p> <a href="#Portability Summary">Back to Summary</a> </p> </div> </div> </body> </html>
kuhlenh/port-to-core
Reports/co/concierge.1.0.5.2/Concierge-net40.html
HTML
mit
133,735
42.683261
562
0.326205
false
Rust-brainfuck ============== A Brainfuck interpreter made in Rust. - Yes, it works, and it's fully compliant. - No, it is not very fast (or at all (yet)). - Yes, it is overkill. - Yes, it is useless. Man, did you play with receipts as a kid or something? Usage ----- Make sure to have _Rust 0.10_ and _Make_ available: ```bash $ make mkdir -p dist rustc -O --out-dir dist src/lib.rs rustc -O -L dist -o dist/bf src/main.rs $ echo "Lbh unir n ehfgl yrnx, znqnz." | dist/bf examples/rot13.bf You have a rusty pipe, madam. ``` ### Notes - `EOF` is represented as zero. Be sure to take that into account when running your programs. For example, the _rot13_ program described on Wikipedia won't work here. - I/O operators `,` and `.` read from `STDIN` and write to `STDOUT` respectively. Motivation ---------- I am learning Rust, and Brainfuck happens to be a fun, simple project, which satisfies the following requisites: - Small: it is compact enough to be kept entirely in the head at once. - Flexible: it can be tackled in many different ways. - Comprehensive: it requires learning many different things. Plans and considerations ------------------------ - Test coverage is practically non-existent. - There is some unnecessary cloning of data, and many instantiation and borrows are probably more costly or less strict than they should. I was kinda expecting this to happen, though. - Parsing is not very efficient at the moment. Besides, non-orthogonal operators like `Incr` and `Decr`, or `Prev` and `Next` could be compacted to `Mutate` and `Seek`. It makes sense to lose the 1:1 compliance to the source to enable some low-hanging optimizations like operator condensation. - There are many interesting variations on the base language, which could be put behind some flag. - It should be easy enough to add a debugger (a rewindable one would be nice). - Performance is laughable, especially when compared to stuff like `bff4`. Rust's integrated micro-benchmarking may help with that. Right now I believe the culprits could be the many unneeded string manipulations, copying of data, and the unoptimized parsed tree. - It shouldn't be too hard to produce a compiled binary, or some custom byte-code. By the way, I saw some nice LLVM helpers hidden inside Rustc. - It should be embeddable. And read mail.
zenoamaro/rust-brainfuck
README.md
Markdown
mit
2,332
36.612903
293
0.734563
false
/** * Reparse the Grunt command line options flags. * * Using the arguments parsing logic from Grunt: * https://github.com/gruntjs/grunt/blob/master/lib/grunt/cli.js */ module.exports = function(grunt){ // Get the current Grunt CLI instance. var nopt = require('nopt'), parsedOptions = parseOptions(nopt, grunt.cli.optlist); grunt.log.debug('(nopt-grunt-fix) old flags: ', grunt.option.flags()); // Reassign the options. resetOptions(grunt, parsedOptions); grunt.log.debug('(nopt-grunt-fix) new flags: ', grunt.option.flags()); return grunt; }; // Normalise the parameters and then parse them. function parseOptions(nopt, optlist){ var params = getParams(optlist); var parsedOptions = nopt(params.known, params.aliases, process.argv, 2); initArrays(optlist, parsedOptions); return parsedOptions; } // Reassign the options on the Grunt instance. function resetOptions(grunt, parsedOptions){ for (var i in parsedOptions){ if (parsedOptions.hasOwnProperty(i) && i != 'argv'){ grunt.option(i, parsedOptions[i]); } } } // Parse `optlist` into a form that nopt can handle. function getParams(optlist){ var aliases = {}; var known = {}; Object.keys(optlist).forEach(function(key) { var short = optlist[key].short; if (short) { aliases[short] = '--' + key; } known[key] = optlist[key].type; }); return { known: known, aliases: aliases } } // Initialize any Array options that weren't initialized. function initArrays(optlist, parsedOptions){ Object.keys(optlist).forEach(function(key) { if (optlist[key].type === Array && !(key in parsedOptions)) { parsedOptions[key] = []; } }); }
widgetworks/nopt-grunt-fix
index.js
JavaScript
mit
1,652
22.942029
73
0.690678
false
module.exports = { "name": "ATmega16HVB", "timeout": 200, "stabDelay": 100, "cmdexeDelay": 25, "syncLoops": 32, "byteDelay": 0, "pollIndex": 3, "pollValue": 83, "preDelay": 1, "postDelay": 1, "pgmEnable": [172, 83, 0, 0], "erase": { "cmd": [172, 128, 0, 0], "delay": 45, "pollMethod": 1 }, "flash": { "write": [64, 76, 0], "read": [32, 0, 0], "mode": 65, "blockSize": 128, "delay": 10, "poll2": 0, "poll1": 0, "size": 16384, "pageSize": 128, "pages": 128, "addressOffset": null }, "eeprom": { "write": [193, 194, 0], "read": [160, 0, 0], "mode": 65, "blockSize": 4, "delay": 10, "poll2": 0, "poll1": 0, "size": 512, "pageSize": 4, "pages": 128, "addressOffset": 0 }, "sig": [30, 148, 13], "signature": { "size": 3, "startAddress": 0, "read": [48, 0, 0, 0] }, "fuses": { "startAddress": 0, "write": { "low": [172, 160, 0, 0], "high": [172, 168, 0, 0] }, "read": { "low": [80, 0, 0, 0], "high": [88, 8, 0, 0] } } }
noopkat/avrgirl-chips-json
atmega/atmega16hvb.js
JavaScript
mit
1,112
17.245902
31
0.442446
false
// Copyright (c) Microsoft. All rights reserved. // Licensed under the MIT license. See LICENSE file in the project root for full license information. namespace Microsoft.DocAsCode.DataContracts.Common { using System; using Newtonsoft.Json; using YamlDotNet.Serialization; using Microsoft.DocAsCode.Utility; [Serializable] public class SourceDetail { [YamlMember(Alias = "remote")] [JsonProperty("remote")] public GitDetail Remote { get; set; } [YamlMember(Alias = "base")] [JsonProperty("base")] public string BasePath { get; set; } [YamlMember(Alias = "id")] [JsonProperty("id")] public string Name { get; set; } /// <summary> /// The url path for current source, should be resolved at some late stage /// </summary> [YamlMember(Alias = Constants.PropertyName.Href)] [JsonProperty(Constants.PropertyName.Href)] public string Href { get; set; } /// <summary> /// The local path for current source, should be resolved to be relative path at some late stage /// </summary> [YamlMember(Alias = "path")] [JsonProperty("path")] public string Path { get; set; } [YamlMember(Alias = "startLine")] [JsonProperty("startLine")] public int StartLine { get; set; } [YamlMember(Alias = "endLine")] [JsonProperty("endLine")] public int EndLine { get; set; } [YamlMember(Alias = "content")] [JsonProperty("content")] public string Content { get; set; } /// <summary> /// The external path for current source if it is not locally available /// </summary> [YamlMember(Alias = "isExternal")] [JsonProperty("isExternal")] public bool IsExternalPath { get; set; } } }
sergey-vershinin/docfx
src/Microsoft.DocAsCode.DataContracts.Common/SourceDetail.cs
C#
mit
1,881
29.836066
104
0.599149
false
--- published: true title: Landed on TinyPress layout: post --- For a long time I tried to find a simple way to write technical articles mainly for my own consumption. Hopefully TinyPress is the way to go...
aanno/aanno.github.io
_posts/2016-02-21-landed-on-tinypress.markdown
Markdown
mit
212
33.666667
143
0.745283
false
--- layout: page title: Stokes Falls International Conference date: 2016-05-24 author: Christopher Barajas tags: weekly links, java status: published summary: Quisque sit amet risus finibus orci egestas posuere. Donec. banner: images/banner/leisure-03.jpg booking: startDate: 05/14/2016 endDate: 05/15/2016 ctyhocn: SANCSHX groupCode: SFIC published: true --- Aenean vel est tellus. Quisque ex nisi, aliquam a vulputate ac, varius at ligula. Vestibulum id sem viverra, elementum lorem a, sollicitudin tellus. Ut finibus leo metus, sed consectetur lorem pretium quis. Maecenas sed massa in lorem ornare dignissim semper vitae est. Mauris suscipit dignissim lacus luctus eleifend. Nulla facilisi. Aenean facilisis tristique justo, eget lobortis sapien tincidunt nec. Phasellus tincidunt ante sed eros feugiat feugiat. Aliquam ullamcorper ipsum nec dolor faucibus, non feugiat augue elementum. Etiam blandit ipsum at congue suscipit. Curabitur dictum ligula eget tortor mattis, et pharetra justo sodales. Pellentesque habitant morbi tristique senectus et netus et malesuada fames ac turpis egestas. Cras molestie imperdiet sapien vel imperdiet. Aliquam iaculis odio a augue semper varius. Sed id lorem libero. * Duis consequat massa eu ligula cursus, nec ullamcorper libero porttitor * Mauris in ligula sit amet velit fermentum tempus a vitae turpis * Morbi dapibus felis condimentum, feugiat est at, auctor felis * Mauris tempor magna eu lorem eleifend, id rutrum turpis dapibus. Nulla volutpat ex eget sapien suscipit, ac malesuada urna volutpat. Suspendisse viverra nec enim eget imperdiet. Vestibulum lobortis velit imperdiet metus suscipit blandit non in justo. Donec facilisis est rhoncus, pulvinar dolor eu, mattis dui. Proin lectus diam, aliquet vitae nulla at, scelerisque interdum ipsum. Aliquam sed rutrum nisl, eget congue lorem. Curabitur ut mauris vitae est maximus sodales nec a sapien. Vestibulum quis lobortis purus. Vestibulum consectetur iaculis enim, ut feugiat sem accumsan et. Suspendisse vehicula justo dolor, in ultricies ex consequat et. Vestibulum rutrum eros non accumsan semper. Phasellus lectus lacus, ultrices vitae bibendum nec, condimentum consequat quam. Nam porta massa non erat sagittis, sit amet rutrum tellus tempus. Donec magna mauris, dictum sed porttitor congue, venenatis ut eros. Integer eget lorem elementum, fringilla libero nec, consequat velit. Suspendisse molestie aliquam metus ac semper.
KlishGroup/prose-pogs
pogs/S/SANCSHX/SFIC/index.md
Markdown
mit
2,444
96.76
846
0.815057
false
export function JavapParser(input: any): this; export class JavapParser { constructor(input: any); _interp: any; ruleNames: string[]; literalNames: (string | null)[]; symbolicNames: (string | null)[]; constructor: typeof JavapParser; get atn(): any; compilationUnit(): CompilationUnitContext; state: number | undefined; sourceDeclaration(): SourceDeclarationContext; classOrInterface(): ClassOrInterfaceContext; classDeclaration(): ClassDeclarationContext; interfaceDeclaration(): InterfaceDeclarationContext; classModifier(): ClassModifierContext; interfaceModifier(): InterfaceModifierContext; typeList(): TypeListContext; type(): TypeContext; subType(): SubTypeContext; packageName(): PackageNameContext; typeArguments(): TypeArgumentsContext; typeArgument(): TypeArgumentContext; classBody(): ClassBodyContext; interfaceBody(): InterfaceBodyContext; modifier(): ModifierContext; classMember(): ClassMemberContext; interfaceMember(): InterfaceMemberContext; constructorDeclaration(): ConstructorDeclarationContext; fieldDeclaration(): FieldDeclarationContext; methodDeclaration(): MethodDeclarationContext; throwsException(): ThrowsExceptionContext; varargs(): VarargsContext; methodArguments(): MethodArgumentsContext; arrayBrackets(): ArrayBracketsContext; } export namespace JavapParser { export const EOF: number; export const T__0: number; export const T__1: number; export const T__2: number; export const T__3: number; export const T__4: number; export const T__5: number; export const T__6: number; export const T__7: number; export const T__8: number; export const T__9: number; export const T__10: number; export const T__11: number; export const T__12: number; export const T__13: number; export const T__14: number; export const T__15: number; export const T__16: number; export const T__17: number; export const T__18: number; export const T__19: number; export const T__20: number; export const T__21: number; export const T__22: number; export const T__23: number; export const T__24: number; export const T__25: number; export const T__26: number; export const T__27: number; export const T__28: number; export const T__29: number; export const T__30: number; export const T__31: number; export const T__32: number; export const T__33: number; export const T__34: number; export const Identifier: number; export const WS: number; export const RULE_compilationUnit: number; export const RULE_sourceDeclaration: number; export const RULE_classOrInterface: number; export const RULE_classDeclaration: number; export const RULE_interfaceDeclaration: number; export const RULE_classModifier: number; export const RULE_interfaceModifier: number; export const RULE_typeList: number; export const RULE_type: number; export const RULE_subType: number; export const RULE_packageName: number; export const RULE_typeArguments: number; export const RULE_typeArgument: number; export const RULE_classBody: number; export const RULE_interfaceBody: number; export const RULE_modifier: number; export const RULE_classMember: number; export const RULE_interfaceMember: number; export const RULE_constructorDeclaration: number; export const RULE_fieldDeclaration: number; export const RULE_methodDeclaration: number; export const RULE_throwsException: number; export const RULE_varargs: number; export const RULE_methodArguments: number; export const RULE_arrayBrackets: number; export { CompilationUnitContext }; export { SourceDeclarationContext }; export { ClassOrInterfaceContext }; export { ClassDeclarationContext }; export { InterfaceDeclarationContext }; export { ClassModifierContext }; export { InterfaceModifierContext }; export { TypeListContext }; export { TypeContext }; export { SubTypeContext }; export { PackageNameContext }; export { TypeArgumentsContext }; export { TypeArgumentContext }; export { ClassBodyContext }; export { InterfaceBodyContext }; export { ModifierContext }; export { ClassMemberContext }; export { InterfaceMemberContext }; export { ConstructorDeclarationContext }; export { FieldDeclarationContext }; export { MethodDeclarationContext }; export { ThrowsExceptionContext }; export { VarargsContext }; export { MethodArgumentsContext }; export { ArrayBracketsContext }; } declare function CompilationUnitContext(parser: any, parent: any, invokingState: any): this; declare class CompilationUnitContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof CompilationUnitContext; sourceDeclaration(i: any): any; classOrInterface(i: any): any; EOF(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function SourceDeclarationContext(parser: any, parent: any, invokingState: any): this; declare class SourceDeclarationContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof SourceDeclarationContext; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function ClassOrInterfaceContext(parser: any, parent: any, invokingState: any): this; declare class ClassOrInterfaceContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof ClassOrInterfaceContext; classDeclaration(): any; interfaceDeclaration(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function ClassDeclarationContext(parser: any, parent: any, invokingState: any): this; declare class ClassDeclarationContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof ClassDeclarationContext; type(i: any): any; classBody(): any; classModifier(i: any): any; typeList(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function InterfaceDeclarationContext(parser: any, parent: any, invokingState: any): this; declare class InterfaceDeclarationContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof InterfaceDeclarationContext; type(): any; interfaceBody(): any; interfaceModifier(i: any): any; typeList(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function ClassModifierContext(parser: any, parent: any, invokingState: any): this; declare class ClassModifierContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof ClassModifierContext; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function InterfaceModifierContext(parser: any, parent: any, invokingState: any): this; declare class InterfaceModifierContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof InterfaceModifierContext; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function TypeListContext(parser: any, parent: any, invokingState: any): this; declare class TypeListContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof TypeListContext; type(i: any): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function TypeContext(parser: any, parent: any, invokingState: any): this; declare class TypeContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof TypeContext; Identifier(): any; packageName(): any; typeArguments(): any; subType(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function SubTypeContext(parser: any, parent: any, invokingState: any): this; declare class SubTypeContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof SubTypeContext; Identifier(): any; typeArguments(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function PackageNameContext(parser: any, parent: any, invokingState: any): this; declare class PackageNameContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof PackageNameContext; Identifier(i: any): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function TypeArgumentsContext(parser: any, parent: any, invokingState: any): this; declare class TypeArgumentsContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof TypeArgumentsContext; arrayBrackets(i: any): any; typeArgument(i: any): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function TypeArgumentContext(parser: any, parent: any, invokingState: any): this; declare class TypeArgumentContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof TypeArgumentContext; type(i: any): any; Identifier(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function ClassBodyContext(parser: any, parent: any, invokingState: any): this; declare class ClassBodyContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof ClassBodyContext; classMember(i: any): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function InterfaceBodyContext(parser: any, parent: any, invokingState: any): this; declare class InterfaceBodyContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof InterfaceBodyContext; interfaceMember(i: any): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function ModifierContext(parser: any, parent: any, invokingState: any): this; declare class ModifierContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof ModifierContext; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function ClassMemberContext(parser: any, parent: any, invokingState: any): this; declare class ClassMemberContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof ClassMemberContext; constructorDeclaration(): any; fieldDeclaration(): any; methodDeclaration(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function InterfaceMemberContext(parser: any, parent: any, invokingState: any): this; declare class InterfaceMemberContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof InterfaceMemberContext; fieldDeclaration(): any; methodDeclaration(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function ConstructorDeclarationContext(parser: any, parent: any, invokingState: any): this; declare class ConstructorDeclarationContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof ConstructorDeclarationContext; type(): any; methodArguments(): any; modifier(i: any): any; typeArguments(): any; throwsException(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function FieldDeclarationContext(parser: any, parent: any, invokingState: any): this; declare class FieldDeclarationContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof FieldDeclarationContext; type(): any; Identifier(): any; modifier(i: any): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function MethodDeclarationContext(parser: any, parent: any, invokingState: any): this; declare class MethodDeclarationContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof MethodDeclarationContext; type(): any; Identifier(): any; methodArguments(): any; modifier(i: any): any; typeArguments(): any; throwsException(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function ThrowsExceptionContext(parser: any, parent: any, invokingState: any): this; declare class ThrowsExceptionContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof ThrowsExceptionContext; typeList(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function VarargsContext(parser: any, parent: any, invokingState: any): this; declare class VarargsContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof VarargsContext; type(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function MethodArgumentsContext(parser: any, parent: any, invokingState: any): this; declare class MethodArgumentsContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof MethodArgumentsContext; typeList(): any; varargs(): any; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } declare function ArrayBracketsContext(parser: any, parent: any, invokingState: any): this; declare class ArrayBracketsContext { constructor(parser: any, parent: any, invokingState: any); parser: any; ruleIndex: number; constructor: typeof ArrayBracketsContext; enterRule(listener: any): void; exitRule(listener: any): void; accept(visitor: any): any; } export {};
wizawu/1c
dist/parser/javap/JavapParser.d.ts
TypeScript
mit
15,534
35.379391
99
0.710377
false
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * Copyright by Brian Nelson 2016. * * See license in repo for more information * * https://github.com/sharpHDF/sharpHDF * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ using System; using System.Collections.Generic; using NUnit.Framework; using sharpHDF.Library.Enums; using sharpHDF.Library.Exceptions; using sharpHDF.Library.Objects; namespace sharpHDF.Library.Tests.Objects { [TestFixture] public class Hdf5AttributeTests : BaseTest { [OneTimeSetUp] public void Setup() { DirectoryName = @"c:\temp\hdf5tests\attributetests"; CleanDirectory(); } [Test] public void CreateAttributeOnFile() { string fileName = GetFilename("createattributeonfile.h5"); Hdf5File file = Hdf5File.Create(fileName); file.Attributes.Add("attribute1", "test"); file.Attributes.Add("attribute2", 5); Assert.AreEqual(2, file.Attributes.Count); file.Close(); } [Test] public void CreateAttributeTwiceOnFile() { string fileName = GetFilename("createattributetwiceonfile.h5"); Hdf5File file = Hdf5File.Create(fileName); file.Attributes.Add("attribute1", "test"); try { file.Attributes.Add("attribute1", "test2"); Assert.Fail("Should have thrown an exception"); } catch (Exception ex) { file.Close(); Assert.IsInstanceOf<Hdf5AttributeAlreadyExistException>(ex); } } [Test] public void CreateAttributeTwiceOnGroup() { string fileName = GetFilename("createattributetwiceongroup.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("test"); group.Attributes.Add("attribute1", "test"); try { group.Attributes.Add("attribute1", "test2"); Assert.Fail("Should have thrown an exception"); } catch (Exception ex) { file.Close(); Assert.IsInstanceOf<Hdf5AttributeAlreadyExistException>(ex); } } [Test] public void CreateAttributeTwiceOnDataset() { string fileName = GetFilename("createattributetwiceondataset.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("test"); List<Hdf5DimensionProperty> dimensionProps = new List<Hdf5DimensionProperty>(); Hdf5DimensionProperty prop = new Hdf5DimensionProperty { CurrentSize = 1 }; dimensionProps.Add(prop); Hdf5Dataset dataset = group.Datasets.Add("dataset1", Hdf5DataTypes.Int32, dimensionProps); dataset.Attributes.Add("attribute1", "test"); try { dataset.Attributes.Add("attribute1", "test2"); Assert.Fail("Should have thrown an exception"); } catch (Exception ex) { file.Close(); Assert.IsInstanceOf<Hdf5AttributeAlreadyExistException>(ex); } } [Test] public void UpdateAttributeWithMismatchOnFile() { string fileName = GetFilename("updateattributewithmistmachonfile.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Attribute attribute = file.Attributes.Add("attribute1", "test"); try { attribute.Value = 5; file.Attributes.Update(attribute); Assert.Fail("Should have thrown an exception"); } catch (Exception ex) { file.Close(); Assert.IsInstanceOf<Hdf5TypeMismatchException>(ex); } } [Test] public void UpdateAttributeWithMismatchOnGroup() { string fileName = GetFilename("updateattributewithmistmachongroup.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("group"); Hdf5Attribute attribute = group.Attributes.Add("attribute1", "test"); try { attribute.Value = 5; group.Attributes.Update(attribute); Assert.Fail("Should have thrown an exception"); } catch (Exception ex) { file.Close(); Assert.IsInstanceOf<Hdf5TypeMismatchException>(ex); } } [Test] public void UpdateAttributeWithMismatchOnDataset() { string fileName = GetFilename("updateattributewithmistmachondataset.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("group"); List<Hdf5DimensionProperty> dimensionProps = new List<Hdf5DimensionProperty>(); Hdf5DimensionProperty prop = new Hdf5DimensionProperty { CurrentSize = 1 }; dimensionProps.Add(prop); Hdf5Dataset dataset = group.Datasets.Add("dataset1", Hdf5DataTypes.Int32, dimensionProps); Hdf5Attribute attribute = dataset.Attributes.Add("attribute1", "test"); try { attribute.Value = 5; dataset.Attributes.Update(attribute); Assert.Fail("Should have thrown an exception"); } catch (Exception ex) { file.Close(); Assert.IsInstanceOf<Hdf5TypeMismatchException>(ex); } } [Test] public void UpdateStringAttributeOnFile() { string fileName = GetFilename("updatestringattributeonfile.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Attribute attribute = file.Attributes.Add("attribute1", "test"); attribute.Value = "test2"; file.Attributes.Update(attribute); file.Close(); file = new Hdf5File(fileName); attribute = file.Attributes[0]; Assert.AreEqual("test2", attribute.Value); } [Test] public void UpdateStringAttributeOnGroup() { string fileName = GetFilename("updatestringattributeongroup.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("group"); Hdf5Attribute attribute = group.Attributes.Add("attribute1", "test"); attribute.Value = "test2"; group.Attributes.Update(attribute); file.Close(); file = new Hdf5File(fileName); group = file.Groups[0]; attribute = group.Attributes[0]; Assert.AreEqual("test2", attribute.Value); } [Test] public void UpdateStringAttributeOnDataset() { string fileName = GetFilename("updatestringattributeondataset.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("group"); List<Hdf5DimensionProperty> dimensionProps = new List<Hdf5DimensionProperty>(); Hdf5DimensionProperty prop = new Hdf5DimensionProperty { CurrentSize = 1 }; dimensionProps.Add(prop); Hdf5Dataset dataset = group.Datasets.Add("dataset1", Hdf5DataTypes.Int32, dimensionProps); Hdf5Attribute attribute = dataset.Attributes.Add("attribute1", "test"); attribute.Value = "test2"; dataset.Attributes.Update(attribute); file.Close(); file = new Hdf5File(fileName); group = file.Groups[0]; dataset = group.Datasets[0]; attribute = dataset.Attributes[0]; Assert.AreEqual("test2", attribute.Value); } [Test] public void GetAttributeOnFile() { string fileName = GetFilename("getattributeonfile.h5"); Hdf5File file = Hdf5File.Create(fileName); file.Attributes.Add("attribute1", "test"); file.Attributes.Add("attribute2", 5); Assert.AreEqual(2, file.Attributes.Count); file.Close(); file = new Hdf5File(fileName); var attibutes = file.Attributes; Assert.AreEqual(2, attibutes.Count); var attribute1 = attibutes[0]; Assert.AreEqual("attribute1", attribute1.Name); Assert.AreEqual("test", attribute1.Value); var attribute2 = attibutes[1]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); } [Test] public void CreateAttributeOnGroup() { string fileName = GetFilename("createattributeongroup.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("group1"); group.Attributes.Add("attribute1", "test"); group.Attributes.Add("attribute2", 5); Assert.AreEqual(2, group.Attributes.Count); file.Close(); } [Test] public void GetAttributeOnGroup() { string fileName = GetFilename("getattributeongroup.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("group1"); group.Attributes.Add("attribute1", "test"); group.Attributes.Add("attribute2", 5); Assert.AreEqual(2, group.Attributes.Count); file.Close(); file = new Hdf5File(fileName); group = file.Groups[0]; var attibutes = group.Attributes; Assert.AreEqual(2, attibutes.Count); var attribute1 = attibutes[0]; Assert.AreEqual("attribute1", attribute1.Name); Assert.AreEqual("test", attribute1.Value); var attribute2 = attibutes[1]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); } [Test] public void CreateAttributeOnDataset() { string fileName = GetFilename("createattributeondataset.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("group1"); List<Hdf5DimensionProperty> dimensionProps = new List<Hdf5DimensionProperty>(); Hdf5DimensionProperty prop = new Hdf5DimensionProperty {CurrentSize = 1}; dimensionProps.Add(prop); Hdf5Dataset dataset = group.Datasets.Add("dataset1", Hdf5DataTypes.Int32, dimensionProps); dataset.Attributes.Add("attribute1", "test"); dataset.Attributes.Add("attribute2", 5); Assert.AreEqual(2, dataset.Attributes.Count); file.Close(); } [Test] public void GetAttributeOnDataset() { string fileName = GetFilename("getattributeondataset.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("group1"); List<Hdf5DimensionProperty> dimensionProps = new List<Hdf5DimensionProperty>(); Hdf5DimensionProperty prop = new Hdf5DimensionProperty { CurrentSize = 1 }; dimensionProps.Add(prop); Hdf5Dataset dataset = group.Datasets.Add("dataset1", Hdf5DataTypes.Int32, dimensionProps); dataset.Attributes.Add("attribute1", "test"); dataset.Attributes.Add("attribute2", 5); Assert.AreEqual(2, dataset.Attributes.Count); file.Close(); file = new Hdf5File(fileName); group = file.Groups[0]; dataset = group.Datasets[0]; var attibutes = dataset.Attributes; Assert.AreEqual(2, attibutes.Count); var attribute1 = attibutes[0]; Assert.AreEqual("attribute1", attribute1.Name); Assert.AreEqual("test", attribute1.Value); var attribute2 = attibutes[1]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); } [Test] public void DeleteAttributeOnFile() { string fileName = GetFilename("deleteattributeonfile.h5"); Hdf5File file = Hdf5File.Create(fileName); file.Attributes.Add("attribute1", "test"); file.Attributes.Add("attribute2", 5); Assert.AreEqual(2, file.Attributes.Count); file.Close(); file = new Hdf5File(fileName); var attibutes = file.Attributes; Assert.AreEqual(2, attibutes.Count); var attribute1 = attibutes[0]; Assert.AreEqual("attribute1", attribute1.Name); Assert.AreEqual("test", attribute1.Value); var attribute2 = attibutes[1]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); file.Attributes.Delete(attribute1); Assert.AreEqual(1, attibutes.Count); attribute2 = attibutes[0]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); file.Close(); file = new Hdf5File(fileName); attibutes = file.Attributes; Assert.AreEqual(1, attibutes.Count); attribute2 = attibutes[0]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); } [Test] public void DeleteAttributeOnGroup() { string fileName = GetFilename("deleteattributeongroup.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("group1"); group.Attributes.Add("attribute1", "test"); group.Attributes.Add("attribute2", 5); Assert.AreEqual(2, group.Attributes.Count); file.Close(); file = new Hdf5File(fileName); group = file.Groups[0]; var attibutes = group.Attributes; Assert.AreEqual(2, attibutes.Count); var attribute1 = attibutes[0]; Assert.AreEqual("attribute1", attribute1.Name); Assert.AreEqual("test", attribute1.Value); var attribute2 = attibutes[1]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); group.Attributes.Delete(attribute1); Assert.AreEqual(1, attibutes.Count); attribute2 = attibutes[0]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); file.Close(); file = new Hdf5File(fileName); group = file.Groups[0]; attibutes = group.Attributes; Assert.AreEqual(1, attibutes.Count); attribute2 = attibutes[0]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); } [Test] public void DeleteAttributeOnDataset() { string fileName = GetFilename("deleteattributeondataset.h5"); Hdf5File file = Hdf5File.Create(fileName); Hdf5Group group = file.Groups.Add("group1"); List<Hdf5DimensionProperty> dimensionProps = new List<Hdf5DimensionProperty>(); Hdf5DimensionProperty prop = new Hdf5DimensionProperty { CurrentSize = 1 }; dimensionProps.Add(prop); Hdf5Dataset dataset = group.Datasets.Add("dataset1", Hdf5DataTypes.Int32, dimensionProps); dataset.Attributes.Add("attribute1", "test"); dataset.Attributes.Add("attribute2", 5); Assert.AreEqual(2, dataset.Attributes.Count); file.Close(); file = new Hdf5File(fileName); group = file.Groups[0]; dataset = group.Datasets[0]; var attibutes = dataset.Attributes; Assert.AreEqual(2, attibutes.Count); var attribute1 = attibutes[0]; Assert.AreEqual("attribute1", attribute1.Name); Assert.AreEqual("test", attribute1.Value); var attribute2 = attibutes[1]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); dataset.Attributes.Delete(attribute1); Assert.AreEqual(1, attibutes.Count); attribute2 = attibutes[0]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); file.Close(); file = new Hdf5File(fileName); group = file.Groups[0]; dataset = group.Datasets[0]; attibutes = dataset.Attributes; Assert.AreEqual(1, attibutes.Count); attribute2 = attibutes[0]; Assert.AreEqual("attribute2", attribute2.Name); Assert.AreEqual(5, attribute2.Value); } [Test] public void AllAttributeTypesOnFile() { string fileName = GetFilename("allattributetypesonfile.h5"); Hdf5File file = Hdf5File.Create(fileName); file.Attributes.Add("attributea", "test"); sbyte b = sbyte.MaxValue; file.Attributes.Add("attributeb", b); Int16 c = Int16.MaxValue; file.Attributes.Add("attributec", c); Int32 d = Int32.MaxValue; file.Attributes.Add("attributed", d); Int64 e = Int64.MaxValue; file.Attributes.Add("attributee", e); byte f = Byte.MaxValue; file.Attributes.Add("attibutef", f); UInt16 g = UInt16.MaxValue; file.Attributes.Add("attributeg", g); UInt32 h = UInt32.MaxValue; file.Attributes.Add("attibuteh", h); UInt64 i = UInt64.MaxValue; file.Attributes.Add("attributei", i); float j = float.MaxValue; file.Attributes.Add("attibutej", j); double k = double.MaxValue; file.Attributes.Add("attributek", k); Assert.AreEqual(11, file.Attributes.Count); file.Close(); file = new Hdf5File(fileName); var attibutes = file.Attributes; Assert.AreEqual(11, attibutes.Count); var attribute1 = attibutes[0]; Assert.AreEqual("test", attribute1.Value); var attribute2 = attibutes[1]; Assert.AreEqual(sbyte.MaxValue, attribute2.Value); var attribute3 = attibutes[2]; Assert.AreEqual(Int16.MaxValue, attribute3.Value); var attribute4 = attibutes[3]; Assert.AreEqual(Int32.MaxValue, attribute4.Value); var attribute5 = attibutes[4]; Assert.AreEqual(Int64.MaxValue, attribute5.Value); var attribute6 = attibutes[5]; Assert.AreEqual(byte.MaxValue, attribute6.Value); var attribute7 = attibutes[6]; Assert.AreEqual(UInt16.MaxValue, attribute7.Value); var attribute8 = attibutes[7]; Assert.AreEqual(UInt32.MaxValue, attribute8.Value); var attribute9 = attibutes[8]; Assert.AreEqual(UInt64.MaxValue, attribute9.Value); var attribute10 = attibutes[9]; Assert.AreEqual(float.MaxValue, attribute10.Value); var attribute11 = attibutes[10]; Assert.AreEqual(double.MaxValue, attribute11.Value); } [Test] public void UpdateAllAttributeTypesOnFile() { string fileName = GetFilename("updateallattributetypesonfile.h5"); Hdf5File file = Hdf5File.Create(fileName); var atta = file.Attributes.Add("attributea", "test"); atta.Value = "test2"; file.Attributes.Update(atta); sbyte b = sbyte.MaxValue; var attb = file.Attributes.Add("attributeb", b); attb.Value = sbyte.MinValue; file.Attributes.Update(attb); Int16 c = Int16.MaxValue; var attc = file.Attributes.Add("attributec", c); attc.Value = Int16.MinValue; file.Attributes.Update(attc); Int32 d = Int32.MaxValue; var attd = file.Attributes.Add("attributed", d); attd.Value = Int32.MinValue; file.Attributes.Update(attd); Int64 e = Int64.MaxValue; var atte = file.Attributes.Add("attributee", e); atte.Value = Int64.MinValue; file.Attributes.Update(atte); byte f = Byte.MaxValue; var attf = file.Attributes.Add("attibutef", f); attf.Value = Byte.MinValue; file.Attributes.Update(attf); UInt16 g = UInt16.MaxValue; var attg = file.Attributes.Add("attributeg", g); attg.Value = UInt16.MinValue; file.Attributes.Update(attg); UInt32 h = UInt32.MaxValue; var atth = file.Attributes.Add("attibuteh", h); atth.Value = UInt32.MinValue; file.Attributes.Update(atth); UInt64 i = UInt64.MaxValue; var atti = file.Attributes.Add("attributei", i); atti.Value = UInt64.MinValue; file.Attributes.Update(atti); float j = float.MaxValue; var attj = file.Attributes.Add("attibutej", j); attj.Value = float.MinValue; file.Attributes.Update(attj); double k = double.MaxValue; var attk = file.Attributes.Add("attributek", k); attk.Value = double.MinValue; file.Attributes.Update(attk); Assert.AreEqual(11, file.Attributes.Count); file.Close(); file = new Hdf5File(fileName); var attibutes = file.Attributes; Assert.AreEqual(11, attibutes.Count); var attribute1 = attibutes[0]; Assert.AreEqual("test2", attribute1.Value); var attribute2 = attibutes[1]; Assert.AreEqual(sbyte.MinValue, attribute2.Value); var attribute3 = attibutes[2]; Assert.AreEqual(Int16.MinValue, attribute3.Value); var attribute4 = attibutes[3]; Assert.AreEqual(Int32.MinValue, attribute4.Value); var attribute5 = attibutes[4]; Assert.AreEqual(Int64.MinValue, attribute5.Value); var attribute6 = attibutes[5]; Assert.AreEqual(byte.MinValue, attribute6.Value); var attribute7 = attibutes[6]; Assert.AreEqual(UInt16.MinValue, attribute7.Value); var attribute8 = attibutes[7]; Assert.AreEqual(UInt32.MinValue, attribute8.Value); var attribute9 = attibutes[8]; Assert.AreEqual(UInt64.MinValue, attribute9.Value); var attribute10 = attibutes[9]; Assert.AreEqual(float.MinValue, attribute10.Value); var attribute11 = attibutes[10]; Assert.AreEqual(double.MinValue, attribute11.Value); } } }
sharpHDF/sharpHDF
src/sharpHDFTests/Objects/Hdf5AttributeTests.cs
C#
mit
23,622
33.532164
102
0.567062
false
# Integration tests for rust_fuse The purpose of this crate is to provide a set of tests that will verify filesystems written with rust_fuse in action. To run it, you need to be capable of mounting arbitrary weird FUSE filesystems under temp directories.
MicahChalmer/rust-fuse-mc-original
src/test/README.md
Markdown
mit
257
84.666667
221
0.801556
false
SHELL = /bin/sh # V=0 quiet, V=1 verbose. other values don't work. V = 0 Q1 = $(V:1=) Q = $(Q1:0=@) ECHO1 = $(V:1=@ :) ECHO = $(ECHO1:0=@ echo) NULLCMD = : #### Start of system configuration section. #### srcdir = . topdir = /usr/local/include/ruby-2.6.0 hdrdir = $(topdir) arch_hdrdir = /usr/local/include/ruby-2.6.0/x86_64-linux-musl PATH_SEPARATOR = : VPATH = $(srcdir):$(arch_hdrdir)/ruby:$(hdrdir)/ruby prefix = $(DESTDIR)/usr/local rubysitearchprefix = $(rubylibprefix)/$(sitearch) rubyarchprefix = $(rubylibprefix)/$(arch) rubylibprefix = $(libdir)/$(RUBY_BASE_NAME) exec_prefix = $(prefix) vendorarchhdrdir = $(vendorhdrdir)/$(sitearch) sitearchhdrdir = $(sitehdrdir)/$(sitearch) rubyarchhdrdir = $(rubyhdrdir)/$(arch) vendorhdrdir = $(rubyhdrdir)/vendor_ruby sitehdrdir = $(rubyhdrdir)/site_ruby rubyhdrdir = $(includedir)/$(RUBY_VERSION_NAME) vendorarchdir = $(vendorlibdir)/$(sitearch) vendorlibdir = $(vendordir)/$(ruby_version) vendordir = $(rubylibprefix)/vendor_ruby sitearchdir = $(DESTDIR)./.gem.20200804-31-1pi4ltr sitelibdir = $(DESTDIR)./.gem.20200804-31-1pi4ltr sitedir = $(rubylibprefix)/site_ruby rubyarchdir = $(rubylibdir)/$(arch) rubylibdir = $(rubylibprefix)/$(ruby_version) sitearchincludedir = $(includedir)/$(sitearch) archincludedir = $(includedir)/$(arch) sitearchlibdir = $(libdir)/$(sitearch) archlibdir = $(libdir)/$(arch) ridir = $(datarootdir)/$(RI_BASE_NAME) mandir = $(datarootdir)/man localedir = $(datarootdir)/locale libdir = $(exec_prefix)/lib psdir = $(docdir) pdfdir = $(docdir) dvidir = $(docdir) htmldir = $(docdir) infodir = $(datarootdir)/info docdir = $(datarootdir)/doc/$(PACKAGE) oldincludedir = $(DESTDIR)/usr/include includedir = $(prefix)/include runstatedir = $(localstatedir)/run localstatedir = $(prefix)/var sharedstatedir = $(prefix)/com sysconfdir = $(prefix)/etc datadir = $(datarootdir) datarootdir = $(prefix)/share libexecdir = $(exec_prefix)/libexec sbindir = $(exec_prefix)/sbin bindir = $(exec_prefix)/bin archdir = $(rubyarchdir) CC_WRAPPER = CC = gcc CXX = g++ LIBRUBY = $(LIBRUBY_SO) LIBRUBY_A = lib$(RUBY_SO_NAME)-static.a LIBRUBYARG_SHARED = -Wl,-rpath,$(libdir) -L$(libdir) -l$(RUBY_SO_NAME) LIBRUBYARG_STATIC = -Wl,-rpath,$(libdir) -L$(libdir) -l$(RUBY_SO_NAME)-static $(MAINLIBS) empty = OUTFLAG = -o $(empty) COUTFLAG = -o $(empty) CSRCFLAG = $(empty) RUBY_EXTCONF_H = cflags = $(optflags) $(debugflags) $(warnflags) cxxflags = $(optflags) $(debugflags) $(warnflags) optflags = -O3 debugflags = -ggdb3 warnflags = -Wall -Wextra -Wdeclaration-after-statement -Wdeprecated-declarations -Wduplicated-cond -Wimplicit-function-declaration -Wimplicit-int -Wmisleading-indentation -Wpointer-arith -Wrestrict -Wwrite-strings -Wimplicit-fallthrough=0 -Wmissing-noreturn -Wno-cast-function-type -Wno-constant-logical-operand -Wno-long-long -Wno-missing-field-initializers -Wno-overlength-strings -Wno-packed-bitfield-compat -Wno-parentheses-equality -Wno-self-assign -Wno-tautological-compare -Wno-unused-parameter -Wno-unused-value -Wsuggest-attribute=format -Wsuggest-attribute=noreturn -Wunused-variable cppflags = CCDLFLAGS = -fPIC CFLAGS = $(CCDLFLAGS) $(cflags) -fPIC $(ARCH_FLAG) INCFLAGS = -I. -I$(arch_hdrdir) -I$(hdrdir)/ruby/backward -I$(hdrdir) -I$(srcdir) DEFS = CPPFLAGS = -DBUILD_FOR_RUBY -DHAVE_RB_THREAD_CALL_WITHOUT_GVL -DHAVE_RB_THREAD_FD_SELECT -DHAVE_TYPE_RB_FDSET_T -DHAVE_RB_WAIT_FOR_SINGLE_FD -DHAVE_RB_TIME_NEW -DHAVE_INOTIFY_INIT -DHAVE_INOTIFY -DHAVE_WRITEV -DHAVE_PIPE2 -DHAVE_ACCEPT4 -DHAVE_CONST_SOCK_CLOEXEC -DOS_UNIX -DHAVE_EPOLL_CREATE -DHAVE_EPOLL -DHAVE_CLOCK_GETTIME -DHAVE_CONST_CLOCK_MONOTONIC_RAW -DHAVE_CONST_CLOCK_MONOTONIC -DHAVE_MAKE_PAIR -I/usr/local/opt/openssl/include -I/opt/local/include -I/usr/local/include $(DEFS) $(cppflags) CXXFLAGS = $(CCDLFLAGS) $(cxxflags) $(ARCH_FLAG) ldflags = -L. -fstack-protector-strong -rdynamic -Wl,-export-dynamic dldflags = -Wl,--compress-debug-sections=zlib ARCH_FLAG = DLDFLAGS = $(ldflags) $(dldflags) $(ARCH_FLAG) LDSHARED = $(CXX) -shared LDSHAREDXX = $(CXX) -shared AR = ar EXEEXT = RUBY_INSTALL_NAME = $(RUBY_BASE_NAME) RUBY_SO_NAME = ruby RUBYW_INSTALL_NAME = RUBY_VERSION_NAME = $(RUBY_BASE_NAME)-$(ruby_version) RUBYW_BASE_NAME = rubyw RUBY_BASE_NAME = ruby arch = x86_64-linux-musl sitearch = $(arch) ruby_version = 2.6.0 ruby = $(bindir)/$(RUBY_BASE_NAME) RUBY = $(ruby) ruby_headers = $(hdrdir)/ruby.h $(hdrdir)/ruby/backward.h $(hdrdir)/ruby/ruby.h $(hdrdir)/ruby/defines.h $(hdrdir)/ruby/missing.h $(hdrdir)/ruby/intern.h $(hdrdir)/ruby/st.h $(hdrdir)/ruby/subst.h $(arch_hdrdir)/ruby/config.h RM = rm -f RM_RF = $(RUBY) -run -e rm -- -rf RMDIRS = rmdir --ignore-fail-on-non-empty -p MAKEDIRS = /bin/mkdir -p INSTALL = /usr/bin/install -c INSTALL_PROG = $(INSTALL) -m 0755 INSTALL_DATA = $(INSTALL) -m 644 COPY = cp TOUCH = exit > #### End of system configuration section. #### preload = libpath = . $(libdir) /usr/local/opt/openssl/lib /opt/local/lib /usr/local/lib LIBPATH = -L. -L$(libdir) -Wl,-rpath,$(libdir) -L/usr/local/opt/openssl/lib -Wl,-rpath,/usr/local/opt/openssl/lib -L/opt/local/lib -Wl,-rpath,/opt/local/lib -L/usr/local/lib -Wl,-rpath,/usr/local/lib DEFFILE = CLEANFILES = mkmf.log DISTCLEANFILES = DISTCLEANDIRS = extout = extout_prefix = target_prefix = LOCAL_LIBS = LIBS = $(LIBRUBYARG_SHARED) -lm -lc ORIG_SRCS = binder.cpp cmain.cpp ed.cpp em.cpp kb.cpp page.cpp pipe.cpp rubymain.cpp ssl.cpp SRCS = $(ORIG_SRCS) OBJS = binder.o cmain.o ed.o em.o kb.o page.o pipe.o rubymain.o ssl.o HDRS = $(srcdir)/page.h $(srcdir)/binder.h $(srcdir)/ssl.h $(srcdir)/em.h $(srcdir)/project.h $(srcdir)/eventmachine.h $(srcdir)/ed.h LOCAL_HDRS = TARGET = rubyeventmachine TARGET_NAME = rubyeventmachine TARGET_ENTRY = Init_$(TARGET_NAME) DLLIB = $(TARGET).so EXTSTATIC = STATIC_LIB = TIMESTAMP_DIR = . BINDIR = $(bindir) RUBYCOMMONDIR = $(sitedir)$(target_prefix) RUBYLIBDIR = $(sitelibdir)$(target_prefix) RUBYARCHDIR = $(sitearchdir)$(target_prefix) HDRDIR = $(rubyhdrdir)/ruby$(target_prefix) ARCHHDRDIR = $(rubyhdrdir)/$(arch)/ruby$(target_prefix) TARGET_SO_DIR = TARGET_SO = $(TARGET_SO_DIR)$(DLLIB) CLEANLIBS = $(TARGET_SO) CLEANOBJS = *.o *.bak all: $(DLLIB) static: $(STATIC_LIB) .PHONY: all install static install-so install-rb .PHONY: clean clean-so clean-static clean-rb clean-static:: clean-rb-default:: clean-rb:: clean-so:: clean: clean-so clean-static clean-rb-default clean-rb -$(Q)$(RM) $(CLEANLIBS) $(CLEANOBJS) $(CLEANFILES) .*.time distclean-rb-default:: distclean-rb:: distclean-so:: distclean-static:: distclean: clean distclean-so distclean-static distclean-rb-default distclean-rb -$(Q)$(RM) Makefile $(RUBY_EXTCONF_H) conftest.* mkmf.log -$(Q)$(RM) core ruby$(EXEEXT) *~ $(DISTCLEANFILES) -$(Q)$(RMDIRS) $(DISTCLEANDIRS) 2> /dev/null || true realclean: distclean install: install-so install-rb install-so: $(DLLIB) $(TIMESTAMP_DIR)/.sitearchdir.time $(INSTALL_PROG) $(DLLIB) $(RUBYARCHDIR) clean-static:: -$(Q)$(RM) $(STATIC_LIB) install-rb: pre-install-rb do-install-rb install-rb-default install-rb-default: pre-install-rb-default do-install-rb-default pre-install-rb: Makefile pre-install-rb-default: Makefile do-install-rb: do-install-rb-default: pre-install-rb-default: @$(NULLCMD) $(TIMESTAMP_DIR)/.sitearchdir.time: $(Q) $(MAKEDIRS) $(@D) $(RUBYARCHDIR) $(Q) $(TOUCH) $@ site-install: site-install-so site-install-rb site-install-so: install-so site-install-rb: install-rb .SUFFIXES: .c .m .cc .mm .cxx .cpp .o .S .cc.o: $(ECHO) compiling $(<) $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$< .cc.S: $(ECHO) translating $(<) $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$< .mm.o: $(ECHO) compiling $(<) $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$< .mm.S: $(ECHO) translating $(<) $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$< .cxx.o: $(ECHO) compiling $(<) $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$< .cxx.S: $(ECHO) translating $(<) $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$< .cpp.o: $(ECHO) compiling $(<) $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$< .cpp.S: $(ECHO) translating $(<) $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$< .c.o: $(ECHO) compiling $(<) $(Q) $(CC) $(INCFLAGS) $(CPPFLAGS) $(CFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$< .c.S: $(ECHO) translating $(<) $(Q) $(CC) $(INCFLAGS) $(CPPFLAGS) $(CFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$< .m.o: $(ECHO) compiling $(<) $(Q) $(CC) $(INCFLAGS) $(CPPFLAGS) $(CFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$< .m.S: $(ECHO) translating $(<) $(Q) $(CC) $(INCFLAGS) $(CPPFLAGS) $(CFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$< $(TARGET_SO): $(OBJS) Makefile $(ECHO) linking shared-object $(DLLIB) -$(Q)$(RM) $(@) $(Q) $(LDSHAREDXX) -o $@ $(OBJS) $(LIBPATH) $(DLDFLAGS) $(LOCAL_LIBS) $(LIBS) $(OBJS): $(HDRS) $(ruby_headers)
fractalbass/data_science
vendor/bundle/gems/eventmachine-1.2.7/ext/Makefile
Makefile
mit
9,074
33.112782
594
0.679193
false
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <title>najaxjs Tutorial: relaylinker | Ajax simple library</title> <!--[if lt IE 9]> <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script> <![endif]--> <link type="text/css" rel="stylesheet" href="styles/sunlight.default.css"> <link type="text/css" rel="stylesheet" href="styles/site.yeti.css"> </head> <body> <div class="navbar navbar-default navbar-fixed-top navbar-inverse"> <div class="container"> <div class="navbar-header"> <a class="navbar-brand" href="index.html">najaxjs</a> <button class="navbar-toggle" type="button" data-toggle="collapse" data-target="#topNavigation"> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </button> </div> <div class="navbar-collapse collapse" id="topNavigation"> <ul class="nav navbar-nav"> <li class="dropdown"> <a href="namespaces.list.html" class="dropdown-toggle" data-toggle="dropdown">Namespaces<b class="caret"></b></a> <ul class="dropdown-menu "> <li><a href="$najax.html">$najax</a></li><li><a href="$najax.define.html">$najax.define</a></li><li><a href="$najax.history.html">$najax.history</a></li><li><a href="$najax@class.html">$najax@class</a></li><li><a href="$najax@ex.html">$najax@ex</a></li><li><a href="$najax@helper.html">$najax@helper</a></li><li><a href="$najax@read.html">$najax@read</a></li><li><a href="$najax@rlk.html">$najax@rlk</a></li> </ul> </li> <li class="dropdown"> <a href="classes.list.html" class="dropdown-toggle" data-toggle="dropdown">Classes<b class="caret"></b></a> <ul class="dropdown-menu "> <li><a href="Linker.html">Linker</a></li><li><a href="Nx.html">Nx</a></li><li><a href="Pager.html">Pager</a></li><li><a href="Reflector.html">Reflector</a></li><li><a href="Relay.html">Relay</a></li><li><a href="RESTful.html">RESTful</a></li><li><a href="Singular.html">Singular</a></li><li><a href="Tx.html">Tx</a></li> </ul> </li> <li class="dropdown"> <a href="tutorials.list.html" class="dropdown-toggle" data-toggle="dropdown">Tutorials<b class="caret"></b></a> <ul class="dropdown-menu "> <li><a href="tutorial-demo-ui-ajax.html">demo-ui-ajax</a></li><li><a href="tutorial-najax-class.html">najax-class</a></li><li><a href="tutorial-najax-ex.html">najax-ex</a></li><li><a href="tutorial-najax-helper.html">najax-helper</a></li><li><a href="tutorial-najax-read.html">najax-read</a></li><li><a href="tutorial-relaylinker.html">relaylinker</a></li><li><a href="tutorial-rlk-standalone.html">rlk-standalone</a></li><li><a href="tutorial-static-history.html">static-history</a></li><li><a href="tutorial-static-najax-micro.html">static-najax-micro</a></li><li><a href="tutorial-static-najax.html">static-najax</a></li> </ul> </li> <li class="dropdown"> <a href="global.html" class="dropdown-toggle" data-toggle="dropdown">Global<b class="caret"></b></a> <ul class="dropdown-menu "> <li><a href="global.html">Global</a></li> </ul> </li> </ul> <div class="col-sm-3 col-md-3"> <form class="navbar-form" role="search"> <div class="input-group"> <input type="text" class="form-control" placeholder="Search" name="q" id="search-input"> <div class="input-group-btn"> <button class="btn btn-default" id="search-submit"><i class="glyphicon glyphicon-search"></i></button> </div> </div> </form> </div> </div> </div> </div> <div class="container" id="toc-content"> <div class="row"> <div class="col-md-12"> <div id="main"> <section class="tutorial-section"> <header> <h2>relaylinker</h2> </header> <article> <script type="text/javascript" src="includes/load.js"></script> <link href="./includes/common.css" rel="stylesheet"> <div>Demo is iframe content. Standalone demo is <a href="../demos/relaylinker.html" target="_blank">here</a>. <u>Require php activation in server.</u></div> <iframe src="../demos/relaylinker.html" width="100%" height="1000" scrolling="no"></iframe> </article> </section> </div> </div> <div class="clearfix"></div> </div> </div> <div class="modal fade" id="searchResults"> <div class="modal-dialog"> <div class="modal-content"> <div class="modal-header"> <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button> <h4 class="modal-title">Search results</h4> </div> <div class="modal-body"></div> <div class="modal-footer"> <button type="button" class="btn btn-default" data-dismiss="modal">Close</button> </div> </div><!-- /.modal-content --> </div><!-- /.modal-dialog --> </div> <footer> &nbsp; <span class="jsdoc-message"> Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.4.0</a> using the <a href="https://github.com/docstrap/docstrap">DocStrap template</a>. </span> </footer> <script src="scripts/docstrap.lib.js"></script> <script src="scripts/toc.js"></script> <script type="text/javascript" src="scripts/fulltext-search-ui.js"></script> <script> $( function () { $( "[id*='$']" ).each( function () { var $this = $( this ); $this.attr( "id", $this.attr( "id" ).replace( "$", "__" ) ); } ); $( ".tutorial-section pre, .readme-section pre" ).each( function () { var $this = $( this ); var example = $this.find( "code" ); exampleText = example.html(); var lang = /{@lang (.*?)}/.exec( exampleText ); if ( lang && lang[1] ) { exampleText = exampleText.replace( lang[0], "" ); example.html( exampleText ); lang = lang[1]; } else { var langClassMatch = example.parent()[0].className.match(/lang\-(\S+)/); lang = langClassMatch ? langClassMatch[1] : "javascript"; } if ( lang ) { $this .addClass( "sunlight-highlight-" + lang ) .addClass( "linenums" ) .html( example.html() ); } } ); Sunlight.highlightAll( { lineNumbers : true, showMenu : true, enableDoclinks : true } ); $.catchAnchorLinks( { navbarOffset: 10 } ); $( "#toc" ).toc( { anchorName : function ( i, heading, prefix ) { var id = $( heading ).attr( "id" ); return id && id.replace(/\~/g, '-inner-').replace(/\./g, '-static-') || ( prefix + i ); }, selectors : "#toc-content h1,#toc-content h2,#toc-content h3,#toc-content h4", showAndHide : false, smoothScrolling: true } ); $( "#main span[id^='toc']" ).addClass( "toc-shim" ); $( '.dropdown-toggle' ).dropdown(); $( "table" ).each( function () { var $this = $( this ); $this.addClass('table'); } ); } ); </script> <!--Navigation and Symbol Display--> <!--Google Analytics--> <script type="text/javascript"> $(document).ready(function() { SearcherDisplay.init(); }); </script> </body> </html>
any-js/any-js.github.io
any-js/najaxjs/docs/tutorial-relaylinker.html
HTML
mit
6,971
30.547511
629
0.610242
false
using System.Security.Claims; using System.Threading.Tasks; using Microsoft.AspNet.Identity; using Microsoft.AspNet.Identity.EntityFramework; using Microsoft.AspNet.Identity.Owin; namespace UniversityStudents.Models { // You can add profile data for the user by adding more properties to your ApplicationUser class, please visit http://go.microsoft.com/fwlink/?LinkID=317594 to learn more. public class ApplicationUser : IdentityUser { public async Task<ClaimsIdentity> GenerateUserIdentityAsync(UserManager<ApplicationUser> manager, string authenticationType) { // Note the authenticationType must match the one defined in CookieAuthenticationOptions.AuthenticationType var userIdentity = await manager.CreateIdentityAsync(this, authenticationType); // Add custom user claims here return userIdentity; } } public class ApplicationDbContext : IdentityDbContext<ApplicationUser> { public ApplicationDbContext() : base("DefaultConnection", throwIfV1Schema: false) { } public static ApplicationDbContext Create() { return new ApplicationDbContext(); } } }
twabbott/FeralNerd
Projects/AspDemo/UniversityStudents/Models/IdentityModels.cs
C#
mit
1,238
36.484848
175
0.704693
false
const express = require('express'); const app = express(); const path = require('path'); const userCtrl = require('./userCtrl.js'); //extra middleware const bodyParser = require('body-parser'); app.use(bodyParser.urlencoded({extended: true}), bodyParser.json()); app.use(express.static(path.join(__dirname, '../../node_modules/'))); app.use(express.static(path.join(__dirname, '../client/'))); app.post('/requestDB', userCtrl.sendTableList); app.post('/requestTable', userCtrl.sendTable); app.post('/createTable', userCtrl.createTable); app.post('/insert', userCtrl.insertEntry); app.post('/update', userCtrl.updateEntry); app.post('/delete', userCtrl.deleteEntry); app.post('/query', userCtrl.rawQuery); app.post('/dropTable', userCtrl.dropTable); app.listen(3000, ()=> console.log('listening on port 3000'));
dbviews/dbview
src/server/server.js
JavaScript
mit
814
36.045455
69
0.717445
false
package com.wjiec.learn.reordering; public class SynchronizedThreading { private int number = 0; private boolean flag = false; public synchronized void write() { number = 1; flag = true; } public synchronized int read() { if (flag) { return number * number; } return -1; } }
JShadowMan/package
java/concurrency-arts/src/main/java/com/wjiec/learn/reordering/SynchronizedThreading.java
Java
mit
357
16
38
0.560224
false
--- layout: base --- <div class="body-container"> <!--[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]--> <nav class="navbar navbar-light bg-faded"> <div class="d-flex justify-content-between"> <a class="navbar-brand" href="{{ '/' | relative_url }}">{{ site.title | escape }}</a> <ul class="navbar-nav"> <li class="nav-item"> <a class="nav-link" href="{{ '/about/' | relative_url }}" title="About">About</a> </li> </ul> </div> </nav> <div class="content"> {{ content }} </div> <footer class="bg-faded p-3"> <p class="text-center mb-0 text-muted">&copy; 2017 {{ site.author | escape }}</p> </footer> </div>
bulnab/bulnab.github.io
_layouts/default.html
HTML
mit
801
27.607143
177
0.605493
false
<?php namespace Torchbox\Thankq\Api; class doContactInsert { /** * @var esitWSdoContactInsertArgument $doContactInsertArgument */ protected $doContactInsertArgument = null; /** * @param esitWSdoContactInsertArgument $doContactInsertArgument */ public function __construct($doContactInsertArgument) { $this->doContactInsertArgument = $doContactInsertArgument; } /** * @return esitWSdoContactInsertArgument */ public function getDoContactInsertArgument() { return $this->doContactInsertArgument; } /** * @param esitWSdoContactInsertArgument $doContactInsertArgument * @return \Torchbox\Thankq\Api\doContactInsert */ public function setDoContactInsertArgument($doContactInsertArgument) { $this->doContactInsertArgument = $doContactInsertArgument; return $this; } }
mrhorse/crm_api
lib/Api/doContactInsert.php
PHP
mit
894
21.923077
72
0.692394
false
package eu.hgross.blaubot.android.views; import android.content.Context; import android.graphics.drawable.Drawable; import android.os.Handler; import android.os.Looper; import android.util.AttributeSet; import android.view.View; import android.widget.ImageView; import android.widget.LinearLayout; import android.widget.TextView; import java.util.ArrayList; import java.util.List; import java.util.Map.Entry; import java.util.Set; import eu.hgross.blaubot.admin.AbstractAdminMessage; import eu.hgross.blaubot.admin.CensusMessage; import eu.hgross.blaubot.android.R; import eu.hgross.blaubot.core.Blaubot; import eu.hgross.blaubot.core.IBlaubotConnection; import eu.hgross.blaubot.core.State; import eu.hgross.blaubot.core.acceptor.IBlaubotConnectionManagerListener; import eu.hgross.blaubot.core.statemachine.IBlaubotConnectionStateMachineListener; import eu.hgross.blaubot.core.statemachine.states.IBlaubotState; import eu.hgross.blaubot.messaging.IBlaubotAdminMessageListener; import eu.hgross.blaubot.ui.IBlaubotDebugView; /** * Android view to display informations about the StateMachine's state. * * Add this view to a blaubot instance like this: stateView.registerBlaubotInstance(blaubot); * * @author Henning Gross {@literal (mail.to@henning-gross.de)} * */ public class KingdomView extends LinearLayout implements IBlaubotDebugView { private Handler mUiHandler; private Blaubot mBlaubot; private Context mContext; public KingdomView(Context context, AttributeSet attrs) { super(context, attrs); initView(context); } public KingdomView(Context context, AttributeSet attrs, int defStyle) { super(context, attrs, defStyle); initView(context); } private void initView(Context context) { this.mContext = context; mUiHandler = new Handler(Looper.getMainLooper()); } private final static String NO_CENSUS_MESSAGE_SO_FAR_TEXT = "Got no census message so far"; private void updateUI(final CensusMessage censusMessage) { mUiHandler.post(new Runnable() { @Override public void run() { final List<View> stateItems = new ArrayList<>(); if(censusMessage != null) { final Set<Entry<String, State>> entries = censusMessage.getDeviceStates().entrySet(); for(Entry<String, State> entry : entries) { final String uniqueDeviceId = entry.getKey(); final State state = entry.getValue(); View item = createKingdomViewListItem(mContext, state, uniqueDeviceId); stateItems.add(item); } } // Never got a message if(stateItems.isEmpty()) { TextView tv = new TextView(mContext); tv.setText(NO_CENSUS_MESSAGE_SO_FAR_TEXT); stateItems.add(tv); } removeAllViews(); for(View v : stateItems) { addView(v); } } }); } /** * Creates a kingdom view list item * * @param context the context * @param state the state of the device to visualize * @param uniqueDeviceId the unique device id * @return the constructed view */ public static View createKingdomViewListItem(Context context, State state, String uniqueDeviceId) { final Drawable icon = ViewUtils.getDrawableForBlaubotState(context, state); View item = inflate(context, R.layout.blaubot_kingdom_view_list_item, null); TextView uniqueDeviceIdTextView = (TextView) item.findViewById(R.id.uniqueDeviceIdLabel); TextView stateTextView = (TextView) item.findViewById(R.id.stateLabel); ImageView iconImageView = (ImageView) item.findViewById(R.id.stateIcon); iconImageView.setImageDrawable(icon); uniqueDeviceIdTextView.setText(uniqueDeviceId); stateTextView.setText(state.toString()); return item; } private IBlaubotConnectionManagerListener mConnectionManagerListener = new IBlaubotConnectionManagerListener() { @Override public void onConnectionClosed(IBlaubotConnection connection) { } @Override public void onConnectionEstablished(IBlaubotConnection connection) { } }; private IBlaubotConnectionStateMachineListener mBlaubotConnectionStateMachineListener = new IBlaubotConnectionStateMachineListener() { @Override public void onStateChanged(IBlaubotState oldState, final IBlaubotState state) { if(State.getStateByStatemachineClass(state.getClass()) == State.Free) { updateUI(null); } } @Override public void onStateMachineStopped() { updateUI(null); } @Override public void onStateMachineStarted() { } }; private IBlaubotAdminMessageListener connectionLayerAdminMessageListener = new IBlaubotAdminMessageListener() { @Override public void onAdminMessage(AbstractAdminMessage adminMessage) { if(adminMessage instanceof CensusMessage) { updateUI((CensusMessage) adminMessage); } } }; /** * Register this view with the given blaubot instance * * @param blaubot * the blaubot instance to connect with */ @Override public void registerBlaubotInstance(Blaubot blaubot) { if (mBlaubot != null) { unregisterBlaubotInstance(); } this.mBlaubot = blaubot; this.mBlaubot.getConnectionStateMachine().addConnectionStateMachineListener(mBlaubotConnectionStateMachineListener); this.mBlaubot.getChannelManager().addAdminMessageListener(connectionLayerAdminMessageListener); this.mBlaubot.getConnectionManager().addConnectionListener(mConnectionManagerListener); // update updateUI(null); } @Override public void unregisterBlaubotInstance() { if(mBlaubot != null) { this.mBlaubot.getConnectionStateMachine().removeConnectionStateMachineListener(mBlaubotConnectionStateMachineListener); this.mBlaubot.getChannelManager().removeAdminMessageListener(connectionLayerAdminMessageListener); this.mBlaubot.getConnectionManager().removeConnectionListener(mConnectionManagerListener); } // force some updates updateUI(null); } }
Blaubot/Blaubot
blaubot-android/src/main/java/eu/hgross/blaubot/android/views/KingdomView.java
Java
mit
6,132
32.513661
135
0.721461
false
using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; // General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information // associated with an assembly. [assembly: AssemblyTitle("17.July.02.Harvest")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("17.July.02.Harvest")] [assembly: AssemblyCopyright("Copyright © 2016")] [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] // Setting ComVisible to false makes the types in this assembly not visible // to COM components. If you need to access a type in this assembly from // COM, set the ComVisible attribute to true on that type. [assembly: ComVisible(false)] // The following GUID is for the ID of the typelib if this project is exposed to COM [assembly: Guid("b8294d81-675a-43f5-bf13-a79537f648ad")] // Version information for an assembly consists of the following four values: // // Major Version // Minor Version // Build Number // Revision // // You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] [assembly: AssemblyVersion("1.0.0.0")] [assembly: AssemblyFileVersion("1.0.0.0")]
kalinmarkov/SoftUni
Programming Basic/ProgrammingBasic-EXAMS/17.July.02.Harvest/Properties/AssemblyInfo.cs
C#
mit
1,412
38.138889
84
0.74308
false
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title>Td</title> <!-- <script src="http://use.edgefonts.net/source-sans-pro;source-code-pro.js"></script> --> <link href='http://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,700,300italic,400italic,700italic|Source+Code+Pro:300,400,700' rel='stylesheet' type='text/css'> <link rel="stylesheet" href="../assets/css/bootstrap.css"> <link rel="stylesheet" href="../assets/css/jquery.bonsai.css"> <link rel="stylesheet" href="../assets/css/main.css"> <link rel="stylesheet" href="../assets/css/icons.css"> <script type="text/javascript" src="../assets/js/jquery-2.1.0.min.js"></script> <script type="text/javascript" src="../assets/js/bootstrap.js"></script> <script type="text/javascript" src="../assets/js/jquery.bonsai.js"></script> <!-- <script type="text/javascript" src="../assets/js/main.js"></script> --> </head> <body> <div> <!-- Name Title --> <h1>Td</h1> <!-- Type and Stereotype --> <section style="margin-top: .5em;"> <span class="alert alert-info"> <span class="node-icon _icon-UMLParameter"></span> UMLParameter </span> </section> <!-- Path --> <section style="margin-top: 10px"> <span class="label label-info"><a href='cf9c8b720f3815adeccaf3ef6e48c6c4.html'><span class='node-icon _icon-Project'></span>Ciayn Docu</a></span> <span>::</span> <span class="label label-info"><a href='cc25605218a28e217adbc7728949f89f.html'><span class='node-icon _icon-UMLModel'></span>Ciyn Diagrams</a></span> <span>::</span> <span class="label label-info"><a href='1ce3e8f6a47545f4bc7d28061651914e.html'><span class='node-icon _icon-UMLPackage'></span>ciayn</a></span> <span>::</span> <span class="label label-info"><a href='827ad12437c057ca4ed8997111b6750e.html'><span class='node-icon _icon-UMLPackage'></span>controller</a></span> <span>::</span> <span class="label label-info"><a href='205361937e6ade829af9cc74c8ff5741.html'><span class='node-icon _icon-UMLClass'></span>D</a></span> <span>::</span> <span class="label label-info"><a href='3696e822dc0cb5b6495b48c9c834ee22.html'><span class='node-icon _icon-UMLOperation'></span>«constructor»D</a></span> <span>::</span> <span class="label label-info"><a href='ff1586271018a6e64d655d6b829080ce.html'><span class='node-icon _icon-UMLParameter'></span>Td</a></span> </section> <!-- Diagram --> <!-- Description --> <section> <h3>Description</h3> <div> <span class="label label-info">none</span> </div> </section> <!-- Specification --> <!-- Directed Relationship --> <!-- Undirected Relationship --> <!-- Classifier --> <!-- Interface --> <!-- Component --> <!-- Node --> <!-- Actor --> <!-- Use Case --> <!-- Template Parameters --> <!-- Literals --> <!-- Attributes --> <!-- Operations --> <!-- Receptions --> <!-- Extension Points --> <!-- Parameters --> <!-- Diagrams --> <!-- Behavior --> <!-- Action --> <!-- Interaction --> <!-- CombinedFragment --> <!-- Activity --> <!-- State Machine --> <!-- State Machine --> <!-- State --> <!-- Vertex --> <!-- Transition --> <!-- Properties --> <section> <h3>Properties</h3> <table class="table table-striped table-bordered"> <tr> <th width="50%">Name</th> <th width="50%">Value</th> </tr> <tr> <td>name</td> <td>Td</td> </tr> <tr> <td>stereotype</td> <td><span class='label label-info'>null</span></td> </tr> <tr> <td>visibility</td> <td>public</td> </tr> <tr> <td>isStatic</td> <td><span class='label label-info'>false</span></td> </tr> <tr> <td>isLeaf</td> <td><span class='label label-info'>false</span></td> </tr> <tr> <td>type</td> <td><span class='label label-info'>void</span></td> </tr> <tr> <td>multiplicity</td> <td></td> </tr> <tr> <td>isReadOnly</td> <td><span class='label label-info'>false</span></td> </tr> <tr> <td>isOrdered</td> <td><span class='label label-info'>false</span></td> </tr> <tr> <td>isUnique</td> <td><span class='label label-info'>false</span></td> </tr> <tr> <td>defaultValue</td> <td></td> </tr> <tr> <td>direction</td> <td>in</td> </tr> </table> </section> <!-- Tags --> <!-- Constraints, Dependencies, Dependants --> <!-- Relationships --> <!-- Owned Elements --> </div> </body> </html>
lki1354/Ciayn
documentation/html-docs/contents/ff1586271018a6e64d655d6b829080ce.html
HTML
mit
6,768
17.846797
174
0.392994
false
#!/usr/bin/env python # -*- coding: utf-8 -*- import zmq from zmq.eventloop import ioloop as ioloop_mod import zmqdecorators import time SERVICE_NAME = "urpobot.motor" SERVICE_PORT = 7575 SIGNALS_PORT = 7576 # How long to wait for new commands before stopping automatically COMMAND_GRACE_TIME = 0.250 class motorserver(zmqdecorators.service): def __init__(self, service_name, service_port, serialport): super(motorserver, self).__init__(service_name, service_port) self.serial_port = serialport self.input_buffer = "" self.evthandler = ioloop_mod.IOLoop.instance().add_handler(self.serial_port.fileno(), self.handle_serial_event, ioloop_mod.IOLoop.instance().READ) self.last_command_time = time.time() self.pcb = ioloop_mod.PeriodicCallback(self.check_data_reveived, COMMAND_GRACE_TIME) self.pcb.start() def check_data_reveived(self, *args): if (time.time() - self.last_command_time > COMMAND_GRACE_TIME): self._setspeeds(0,0) def _setspeeds(self, m1speed, m2speed): self.serial_port.write("S%04X%04X\n" % ((m1speed & 0xffff), (m2speed & 0xffff))) @zmqdecorators.method() def setspeeds(self, resp, m1speed, m2speed): self.last_command_time = time.time() #print("Got speeds %s,%s" % (m1speed, m2speed)) self._setspeeds(m1speed, m2speed) # TODO: actually handle ACK/NACK somehow (we need to read it from the serialport but we can't block while waiting for it...) resp.send("ACK") def handle_serial_event(self, fd, events): # Copied from arbus that was thread based if not self.serial_port.inWaiting(): # Don't try to read if there is no data, instead sleep (yield) a bit time.sleep(0) return data = self.serial_port.read(1) if len(data) == 0: return #print("DEBUG: data=%s" % data) # Put the data into inpit buffer and check for CRLF self.input_buffer += data # Trim prefix NULLs and linebreaks self.input_buffer = self.input_buffer.lstrip(chr(0x0) + "\r\n") #print "input_buffer=%s" % repr(self.input_buffer) if ( len(self.input_buffer) > 1 and self.input_buffer[-2:] == "\r\n"): # Got a message, parse it (sans the CRLF) and empty the buffer self.message_received(self.input_buffer[:-2]) self.input_buffer = "" def message_received(self, message): #print("DEBUG: msg=%s" % message) try: # Currently we have no incoming messages from this board pass except Exception as e: print "message_received exception: Got exception %s" % repr(e) # Ignore indexerrors, they just mean we could not parse the command pass pass def cleanup(self): print("Cleanup called") self._setspeeds(0,0) def run(self): print("Starting motorserver") super(motorserver, self).run() if __name__ == "__main__": import serial import sys,os port = serial.Serial(sys.argv[1], 115200, xonxoff=False, timeout=0.01) instance = motorserver(SERVICE_NAME, SERVICE_PORT, port) instance.run()
HelsinkiHacklab/urpobotti
python/motorctrl.py
Python
mit
3,257
35.595506
154
0.621738
false
from rest_framework import serializers from . import models class Invoice(serializers.ModelSerializer): class Meta: model = models.Invoice fields = ( 'id', 'name', 'additional_infos', 'owner', 'creation_date', 'update_date', )
linovia/microinvoices
microinvoices/invoices/serializers.py
Python
mit
281
24.545455
54
0.601423
false
<footer class="site-footer"> <div class="wrapper"> <h2 class="footer-heading small-site-title">{{ site.title }}</h2> <div class="footer-col-wrapper"> <div class="footer-col footer-col-1"> <ul class="contact-list footer-content"> <li>Powered By <a href="http://github.com/hemangsk/Gravity">Gravity</a></li> <li>Made with <i class="fa fa-heart"></i> on <a href="jekyll.com"><span style="color:black">{ { Jekyll } }</a></span></li> </ul> </div> <div class="footer-col footer-col-2 footer-content"> <ul class="social-media-list"> {% if site.github_username %} <li> {% include icon-github.html username=site.github_username %} </li> {% endif %} {% if site.twitter_username %} <li> {% include icon-twitter.html username=site.twitter_username %} </li> {% endif %} </ul> </div> <div class="footer-col footer-col-3 site-description"> <p>{{ site.description }}</p> </div> </div> </div> </footer>
tylerhether/tylerhether.github.io
_includes/footer.html
HTML
mit
1,112
26.8
132
0.532374
false
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; namespace Izzo.Collections.Immutable { [DebuggerDisplay( "Count = {Count}" )] public sealed partial class ImmutableList<T> : IImmutableList<T> { public static readonly ImmutableList<T> Empty = new ImmutableList<T>(); private readonly List<T> items; private ImmutableList() { this.items = new List<T>(); } private ImmutableList( IEnumerable<T> items ) { if( items is ImmutableList<T> ) { var otherList = items as ImmutableList<T>; this.items = otherList.items; } else { this.items = new List<T>( items ); } } private ImmutableList( List<T> items, bool noAlloc ) { if( noAlloc ) { this.items = items; } else { this.items = new List<T>( items ); } } public T this[int index] { get { return items[index]; } } public int Count { get { return items.Count; } } public bool IsEmpty { get { return Count == 0; } } public ImmutableList<T> Add( T item ) { var newList = new ImmutableList<T>( items ); newList.items.Add( item ); return newList; } public ImmutableList<T> AddRange( IEnumerable<T> range ) { var newList = new ImmutableList<T>( items ); newList.items.AddRange( range ); return newList; } public ImmutableList<T> Set( int index, T item ) { var newList = new ImmutableList<T>( items ); newList.items[index] = item; return newList; } public ImmutableList<T> Clear() { return Empty; } public IEnumerator<T> GetEnumerator() { return items.GetEnumerator(); } IEnumerator IEnumerable.GetEnumerator() { return items.GetEnumerator(); } public int IndexOf( T item, int startIndex, int count, IEqualityComparer<T> equalityComparer ) { for( int i = startIndex; i < startIndex + count; i++ ) { if( equalityComparer.Equals( item, items[i] ) ) { return i; } } return -1; } public ImmutableList<T> Insert( int index, T item ) { var newList = new ImmutableList<T>( items ); newList.items.Insert( index, item ); return newList; } public ImmutableList<T> Remove( T item, IEqualityComparer<T> equalityComparer ) { int idx = IndexOf( item, 0, Count, equalityComparer ); if( idx >= 0 ) { return RemoveAt( idx ); } return this; } public ImmutableList<T> Remove( T item ) { return Remove( item, EqualityComparer<T>.Default ); } public ImmutableList<T> RemoveAt( int index ) { var newList = new ImmutableList<T>( items ); newList.items.RemoveAt( index ); return newList; } public bool Contains( T item ) { return items.Contains( item ); } public T Find( Predicate<T> match ) { return items.Find( match ); } public ImmutableList<T> FindAll( Predicate<T> match ) { return new ImmutableList<T>( items.FindAll( match ), true ); } public int FindIndex( Predicate<T> match ) { return items.FindIndex( match ); } IImmutableList<T> IImmutableList<T>.Add( T item ) { return Add( item ); } IImmutableList<T> IImmutableList<T>.AddRange( IEnumerable<T> items ) { return AddRange( items ); } IImmutableList<T> IImmutableList<T>.SetItem( int index, T item ) { return Set( index, item ); } IImmutableList<T> IImmutableList<T>.Clear() { return Clear(); } IImmutableList<T> IImmutableList<T>.Insert( int index, T item ) { return Insert( index, item ); } IImmutableList<T> IImmutableList<T>.RemoveAt( int index ) { return RemoveAt( index ); } IImmutableList<T> IImmutableList<T>.FindAll( Predicate<T> match ) { return FindAll( match ); } IImmutableList<T> IImmutableList<T>.Remove( T value, IEqualityComparer<T> equalityComparer ) { return Remove( value, equalityComparer ); } } }
SuperIzzo/Unity3D-Immutable-Collections
Assets/Collections/Immutable/ImmutableList_1.cs
C#
mit
5,038
24.563452
102
0.492256
false
#!/usr/bin/env bash CURRENT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" SESSION_NAME="$1" source "$CURRENT_DIR/helpers.sh" dismiss_session_list_page_from_view() { tmux send-keys C-c } session_name_not_provided() { [ -z "$SESSION_NAME" ] } main() { if session_name_not_provided; then dismiss_session_list_page_from_view exit 0 fi if session_exists; then dismiss_session_list_page_from_view tmux switch-client -t "$SESSION_NAME" else "$CURRENT_DIR/show_goto_prompt.sh" "$SESSION_NAME" fi } main
disser/tmux-sessionist
scripts/switch_or_loop.sh
Shell
mit
528
17.206897
63
0.670455
false
<html> <head> <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII"> <title>Function template begins_with</title> <link rel="stylesheet" href="../../../../../../../doc/src/boostbook.css" type="text/css"> <meta name="generator" content="DocBook XSL Stylesheets V1.76.1"> <link rel="home" href="../../../index.html" title="Chapter&#160;1.&#160;Boost.Log v2"> <link rel="up" href="../../../expressions.html#header.boost.log.expressions.predicates.begins_with_hpp" title="Header &lt;boost/log/expressions/predicates/begins_with.hpp&gt;"> <link rel="prev" href="begins_with_idp21049056.html" title="Function template begins_with"> <link rel="next" href="begins_with_idp21061200.html" title="Function template begins_with"> </head> <body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF"> <table cellpadding="2" width="100%"><tr><td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../../../../../boost.png"></td></tr></table> <hr> <div class="spirit-nav"> <a accesskey="p" href="begins_with_idp21049056.html"><img src="../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../../expressions.html#header.boost.log.expressions.predicates.begins_with_hpp"><img src="../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="begins_with_idp21061200.html"><img src="../../../../../../../doc/src/images/next.png" alt="Next"></a> </div> <div class="refentry"> <a name="boost.log.expressions.begins_with_idp21055696"></a><div class="titlepage"></div> <div class="refnamediv"> <h2><span class="refentrytitle">Function template begins_with</span></h2> <p>boost::log::expressions::begins_with</p> </div> <h2 xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv-title">Synopsis</h2> <div xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" class="refsynopsisdiv"><pre class="synopsis"><span class="comment">// In header: &lt;<a class="link" href="../../../expressions.html#header.boost.log.expressions.predicates.begins_with_hpp" title="Header &lt;boost/log/expressions/predicates/begins_with.hpp&gt;">boost/log/expressions/predicates/begins_with.hpp</a>&gt; </span> <span class="keyword">template</span><span class="special">&lt;</span><span class="keyword">typename</span> DescriptorT<span class="special">,</span> <span class="keyword">template</span><span class="special">&lt;</span> <span class="keyword">typename</span> <span class="special">&gt;</span> <span class="keyword">class</span> ActorT<span class="special">,</span> <span class="keyword">typename</span> SubstringT<span class="special">&gt;</span> <span class="emphasis"><em><span class="identifier">unspecified</span></em></span> <span class="identifier">begins_with</span><span class="special">(</span><a class="link" href="attribute_keyword.html" title="Struct template attribute_keyword">attribute_keyword</a><span class="special">&lt;</span> <span class="identifier">DescriptorT</span><span class="special">,</span> <span class="identifier">ActorT</span> <span class="special">&gt;</span> <span class="keyword">const</span> <span class="special">&amp;</span><span class="special">,</span> <span class="identifier">SubstringT</span> <span class="keyword">const</span> <span class="special">&amp;</span> substring<span class="special">)</span><span class="special">;</span></pre></div> <div class="refsect1"> <a name="idp88863136"></a><h2>Description</h2> <p>The function generates a terminal node in a template expression. The node will check if the attribute value, which is assumed to be a string, begins with the specified substring. </p> </div> </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 &#169; 2007-2016 Andrey Semashev<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="begins_with_idp21049056.html"><img src="../../../../../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../../../expressions.html#header.boost.log.expressions.predicates.begins_with_hpp"><img src="../../../../../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../../../index.html"><img src="../../../../../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="begins_with_idp21061200.html"><img src="../../../../../../../doc/src/images/next.png" alt="Next"></a> </div> </body> </html>
calvinfarias/IC2015-2
BOOST/boost_1_61_0/libs/log/doc/html/boost/log/expressions/begins_with_idp21055696.html
HTML
mit
4,908
97.16
548
0.670945
false
module Models class TimeStamp attr_accessor :sec attr_accessor :usec end end
Ruhrpottpatriot/WarframeApi
app/api/models/time_stamp.rb
Ruby
mit
88
13.833333
23
0.715909
false
class Users::SessionsController < Devise::SessionsController layout :layout def presign end def layout if params[:no_layout].present? return false else return 'user' end end end
sleepinglion/anti-kb
app/controllers/users/sessions_controller.rb
Ruby
mit
215
13.333333
60
0.665116
false
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>fcsl-pcm: Not compatible 👼</title> <link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" /> <link href="../../../../../bootstrap.min.css" rel="stylesheet"> <link href="../../../../../bootstrap-custom.css" rel="stylesheet"> <link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet"> <script src="../../../../../moment.min.js"></script> <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries --> <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script> <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script> <![endif]--> </head> <body> <div class="container"> <div class="navbar navbar-default" role="navigation"> <div class="container-fluid"> <div class="navbar-header"> <a class="navbar-brand" href="../../../../.."><i class="fa fa-lg fa-flag-checkered"></i> Coq bench</a> </div> <div id="navbar" class="collapse navbar-collapse"> <ul class="nav navbar-nav"> <li><a href="../..">clean / released</a></li> <li class="active"><a href="">8.5.2 / fcsl-pcm - 1.1.1</a></li> </ul> </div> </div> </div> <div class="article"> <div class="row"> <div class="col-md-12"> <a href="../..">« Up</a> <h1> fcsl-pcm <small> 1.1.1 <span class="label label-info">Not compatible 👼</span> </small> </h1> <p>📅 <em><script>document.write(moment("2022-01-04 10:12:16 +0000", "YYYY-MM-DD HH:mm:ss Z").fromNow());</script> (2022-01-04 10:12:16 UTC)</em><p> <h2>Context</h2> <pre># Packages matching: installed # Name # Installed # Synopsis base-bigarray base base-num base Num library distributed with the OCaml compiler base-ocamlbuild base OCamlbuild binary and libraries distributed with the OCaml compiler base-threads base base-unix base camlp5 7.14 Preprocessor-pretty-printer of OCaml conf-findutils 1 Virtual package relying on findutils conf-perl 1 Virtual package relying on perl coq 8.5.2 Formal proof management system num 0 The Num library for arbitrary-precision integer and rational arithmetic ocaml 4.02.3 The OCaml compiler (virtual package) ocaml-base-compiler 4.02.3 Official 4.02.3 release ocaml-config 1 OCaml Switch Configuration # opam file: opam-version: &quot;2.0&quot; maintainer: &quot;FCSL &lt;fcsl@software.imdea.org&gt;&quot; homepage: &quot;http://software.imdea.org/fcsl/&quot; bug-reports: &quot;https://github.com/imdea-software/fcsl-pcm/issues&quot; dev-repo: &quot;git+https://github.com/imdea-software/fcsl-pcm.git&quot; license: &quot;Apache-2.0&quot; build: [ make &quot;-j%{jobs}%&quot; ] install: [ make &quot;install&quot; ] depends: [ &quot;ocaml&quot; &quot;coq&quot; {(&gt;= &quot;8.9&quot; &amp; &lt; &quot;8.12~&quot;) | (= &quot;dev&quot;)} &quot;coq-mathcomp-ssreflect&quot; {(&gt;= &quot;1.10.0&quot; &amp; &lt; &quot;1.11~&quot;) | (= &quot;dev&quot;)} ] tags: [ &quot;keyword:separation logic&quot; &quot;keyword:partial commutative monoid&quot; &quot;category:Computer Science/Data Types and Data Structures&quot; &quot;logpath:fcsl&quot; &quot;date:2019-01-06&quot; ] authors: [ &quot;Aleksandar Nanevski&quot; ] synopsis: &quot;Partial Commutative Monoids&quot; description: &quot;&quot;&quot; The PCM library provides a formalisation of Partial Commutative Monoids (PCMs), a common algebraic structure used in separation logic for verification of pointer-manipulating sequential and concurrent programs. The library provides lemmas for mechanised and automated reasoning about PCMs in the abstract, but also supports concrete common PCM instances, such as heaps, histories and mutexes. This library relies on extensionality axioms: propositional and functional extentionality.&quot;&quot;&quot; url { src: &quot;https://github.com/imdea-software/fcsl-pcm/archive/v1.1.1.tar.gz&quot; checksum: &quot;sha256=3b52ae8f7dba4987ef2c2fc91480ebbecdbf7195bfc0d6892930f523e3475771&quot; } </pre> <h2>Lint</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Dry install 🏜️</h2> <p>Dry install with the current Coq version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam install -y --show-action coq-fcsl-pcm.1.1.1 coq.8.5.2</code></dd> <dt>Return code</dt> <dd>5120</dd> <dt>Output</dt> <dd><pre>[NOTE] Package coq is already installed (current version is 8.5.2). The following dependencies couldn&#39;t be met: - coq-fcsl-pcm -&gt; coq &gt;= dev -&gt; ocaml &gt;= 4.05.0 base of this switch (use `--unlock-base&#39; to force) Your request can&#39;t be satisfied: - No available version of coq satisfies the constraints No solution found, exiting </pre></dd> </dl> <p>Dry install without Coq/switch base, to test if the problem was incompatibility with the current Coq/OCaml version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam remove -y coq; opam install -y --show-action --unlock-base coq-fcsl-pcm.1.1.1</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Install dependencies</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>0 s</dd> </dl> <h2>Install 🚀</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>0 s</dd> </dl> <h2>Installation size</h2> <p>No files were installed.</p> <h2>Uninstall 🧹</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Missing removes</dt> <dd> none </dd> <dt>Wrong removes</dt> <dd> none </dd> </dl> </div> </div> </div> <hr/> <div class="footer"> <p class="text-center"> Sources are on <a href="https://github.com/coq-bench">GitHub</a> © Guillaume Claret 🐣 </p> </div> </div> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <script src="../../../../../bootstrap.min.js"></script> </body> </html>
coq-bench/coq-bench.github.io
clean/Linux-x86_64-4.02.3-2.0.6/released/8.5.2/fcsl-pcm/1.1.1.html
HTML
mit
7,591
41.033333
159
0.560534
false
exports.find = function(options) { options || (options = {}); options.param || (options.param = 'query'); options.parse || (options.parse = JSON.parse); return function(req, res, next) { var query = req.query[options.param]; var conditions = query ? options.parse(query) : {}; req.find = req.model.find(conditions); next(); }; }; exports.limit = function(options) { options || (options = {}); options.param || (options.param = 'limit'); return function(req, res, next) { if (req.query[options.param] !== undefined) { var limit = parseInt(req.query[options.param], 10); if (options.max) { limit = Math.min(limit, options.max); } req.find = req.find.limit(limit); } next(); }; }; exports.skip = function(options) { options || (options = {}); options.param || (options.param = 'skip'); return function(req, res, next) { if (req.query[options.param] !== undefined) { var skip = parseInt(req.query[options.param], 10); req.find = req.find.skip(skip); } next(); }; }; exports.select = function(options) { options || (options = {}); options.param || (options.param = 'select'); options.delimiter || (options.delimiter = ','); return function(req, res, next) { if (req.query[options.param] !== undefined) { var select = req.query[options.param].split(options.delimiter).join(' '); req.find = req.find.select(select); } next(); }; }; exports.sort = function(options) { options || (options = {}); options.param || (options.param = 'sort'); options.delimiter || (options.delimiter = ','); return function(req, res, next) { if (req.query[options.param] !== undefined) { var sort = req.query[options.param].split(options.delimiter).join(' '); req.find = req.find.sort(sort); } next(); }; }; exports.exec = function() { return function(req, res, next) { req.find.exec(function(err, results) { if (err) return next(err); req.results = results; next(); }); }; }; exports.count = function(options) { options || (options = {}); options.param || (options.param = 'query'); options.parse || (options.parse = JSON.parse); return function(req, res, next) { var query = req.query[options.param]; var conditions = query ? options.parse(query) : {}; req.model.count(conditions, function(err, count) { if (err) return next(err); req.count = count; next(); }); }; };
scttnlsn/emt
lib/query.js
JavaScript
mit
2,776
25.701923
85
0.536383
false
// MooTools: the javascript framework. // Load this file's selection again by visiting: http://mootools.net/more/f0c28d76aff2f0ba12270c81dc5e8d18 // Or build this file again with packager using: packager build More/Assets More/Hash.Cookie /* --- script: More.js name: More description: MooTools More license: MIT-style license authors: - Guillermo Rauch - Thomas Aylott - Scott Kyle - Arian Stolwijk - Tim Wienk - Christoph Pojer - Aaron Newton - Jacob Thornton requires: - Core/MooTools provides: [MooTools.More] ... */ MooTools.More = { 'version': '1.4.0.1', 'build': 'a4244edf2aa97ac8a196fc96082dd35af1abab87' }; /* --- script: Assets.js name: Assets description: Provides methods to dynamically load JavaScript, CSS, and Image files into the document. license: MIT-style license authors: - Valerio Proietti requires: - Core/Element.Event - /MooTools.More provides: [Assets] ... */ var Asset = { javascript: function(source, properties){ if (!properties) properties = {}; var script = new Element('script', {src: source, type: 'text/javascript'}), doc = properties.document || document, load = properties.onload || properties.onLoad; delete properties.onload; delete properties.onLoad; delete properties.document; if (load){ if (typeof script.onreadystatechange != 'undefined'){ script.addEvent('readystatechange', function(){ if (['loaded', 'complete'].contains(this.readyState)) load.call(this); }); } else { script.addEvent('load', load); } } return script.set(properties).inject(doc.head); }, css: function(source, properties){ if (!properties) properties = {}; var link = new Element('link', { rel: 'stylesheet', media: 'screen', type: 'text/css', href: source }); var load = properties.onload || properties.onLoad, doc = properties.document || document; delete properties.onload; delete properties.onLoad; delete properties.document; if (load) link.addEvent('load', load); return link.set(properties).inject(doc.head); }, image: function(source, properties){ if (!properties) properties = {}; var image = new Image(), element = document.id(image) || new Element('img'); ['load', 'abort', 'error'].each(function(name){ var type = 'on' + name, cap = 'on' + name.capitalize(), event = properties[type] || properties[cap] || function(){}; delete properties[cap]; delete properties[type]; image[type] = function(){ if (!image) return; if (!element.parentNode){ element.width = image.width; element.height = image.height; } image = image.onload = image.onabort = image.onerror = null; event.delay(1, element, element); element.fireEvent(name, element, 1); }; }); image.src = element.src = source; if (image && image.complete) image.onload.delay(1); return element.set(properties); }, images: function(sources, options){ sources = Array.from(sources); var fn = function(){}, counter = 0; options = Object.merge({ onComplete: fn, onProgress: fn, onError: fn, properties: {} }, options); return new Elements(sources.map(function(source, index){ return Asset.image(source, Object.append(options.properties, { onload: function(){ counter++; options.onProgress.call(this, counter, index, source); if (counter == sources.length) options.onComplete(); }, onerror: function(){ counter++; options.onError.call(this, counter, index, source); if (counter == sources.length) options.onComplete(); } })); })); } }; /* --- name: Hash description: Contains Hash Prototypes. Provides a means for overcoming the JavaScript practical impossibility of extending native Objects. license: MIT-style license. requires: - Core/Object - /MooTools.More provides: [Hash] ... */ (function(){ if (this.Hash) return; var Hash = this.Hash = new Type('Hash', function(object){ if (typeOf(object) == 'hash') object = Object.clone(object.getClean()); for (var key in object) this[key] = object[key]; return this; }); this.$H = function(object){ return new Hash(object); }; Hash.implement({ forEach: function(fn, bind){ Object.forEach(this, fn, bind); }, getClean: function(){ var clean = {}; for (var key in this){ if (this.hasOwnProperty(key)) clean[key] = this[key]; } return clean; }, getLength: function(){ var length = 0; for (var key in this){ if (this.hasOwnProperty(key)) length++; } return length; } }); Hash.alias('each', 'forEach'); Hash.implement({ has: Object.prototype.hasOwnProperty, keyOf: function(value){ return Object.keyOf(this, value); }, hasValue: function(value){ return Object.contains(this, value); }, extend: function(properties){ Hash.each(properties || {}, function(value, key){ Hash.set(this, key, value); }, this); return this; }, combine: function(properties){ Hash.each(properties || {}, function(value, key){ Hash.include(this, key, value); }, this); return this; }, erase: function(key){ if (this.hasOwnProperty(key)) delete this[key]; return this; }, get: function(key){ return (this.hasOwnProperty(key)) ? this[key] : null; }, set: function(key, value){ if (!this[key] || this.hasOwnProperty(key)) this[key] = value; return this; }, empty: function(){ Hash.each(this, function(value, key){ delete this[key]; }, this); return this; }, include: function(key, value){ if (this[key] == undefined) this[key] = value; return this; }, map: function(fn, bind){ return new Hash(Object.map(this, fn, bind)); }, filter: function(fn, bind){ return new Hash(Object.filter(this, fn, bind)); }, every: function(fn, bind){ return Object.every(this, fn, bind); }, some: function(fn, bind){ return Object.some(this, fn, bind); }, getKeys: function(){ return Object.keys(this); }, getValues: function(){ return Object.values(this); }, toQueryString: function(base){ return Object.toQueryString(this, base); } }); Hash.alias({indexOf: 'keyOf', contains: 'hasValue'}); })(); /* --- script: Hash.Cookie.js name: Hash.Cookie description: Class for creating, reading, and deleting Cookies in JSON format. license: MIT-style license authors: - Valerio Proietti - Aaron Newton requires: - Core/Cookie - Core/JSON - /MooTools.More - /Hash provides: [Hash.Cookie] ... */ Hash.Cookie = new Class({ Extends: Cookie, options: { autoSave: true }, initialize: function(name, options){ this.parent(name, options); this.load(); }, save: function(){ var value = JSON.encode(this.hash); if (!value || value.length > 4096) return false; //cookie would be truncated! if (value == '{}') this.dispose(); else this.write(value); return true; }, load: function(){ this.hash = new Hash(JSON.decode(this.read(), true)); return this; } }); Hash.each(Hash.prototype, function(method, name){ if (typeof method == 'function') Hash.Cookie.implement(name, function(){ var value = method.apply(this.hash, arguments); if (this.options.autoSave) this.save(); return value; }); });
donatj/CorpusPHP
Source/js/mootools.more.js
JavaScript
mit
7,181
17.897368
138
0.656594
false
"""Basic thermodynamic calculations for pickaxe.""" from typing import Union import pint from equilibrator_api import ( Q_, ComponentContribution, Reaction, default_physiological_ionic_strength, default_physiological_p_h, default_physiological_p_mg, default_physiological_temperature, ) from equilibrator_api.phased_reaction import PhasedReaction from equilibrator_assets.compounds import Compound from equilibrator_assets.local_compound_cache import LocalCompoundCache from equilibrator_cache.compound_cache import CompoundCache from pymongo import MongoClient from sqlalchemy import create_engine from minedatabase.pickaxe import Pickaxe class Thermodynamics: """Class to calculate thermodynamics of Pickaxe runs. Thermodynamics allows for the calculation of: 1) Standard ∆G' of formation 2) Standard ∆G'o of reaction 3) Physiological ∆G'm of reaction 4) Adjusted ∆G' of reaction eQuilibrator objects can also be obtained from r_ids and c_ids. Parameters ---------- mongo_uri: str URI of the mongo database. client: MongoClient Connection to Mongo. CC: ComponentContribution eQuilibrator Component Contribution object to calculate ∆G with. lc: LocalCompoundCache The local compound cache to generate eQuilibrator compounds from. """ def __init__( self, ): # Mongo params self.mongo_uri = None self.client = None self._core = None # eQ params self.CC = ComponentContribution() self.lc = None self._water = None def load_mongo(self, mongo_uri: Union[str, None] = None): if mongo_uri: self.mongo_uri = mongo_uri self.client = MongoClient(mongo_uri) else: self.mongo_uri = "localhost:27017" self.client = MongoClient() self._core = self.client["core"] def _all_dbs_loaded(self): if self.client and self._core and self.lc: return True else: print("Load connection to Mongo and eQuilibrator local cache.") return False def _eq_loaded(self): if self.lc: return True else: print("Load eQulibrator local cache.") return False def _reset_CC(self): """reset CC back to defaults""" self.CC.p_h = default_physiological_p_h self.CC.p_mg = default_physiological_p_mg self.CC.temperature = default_physiological_temperature self.CC.ionic_strength = default_physiological_ionic_strength def load_thermo_from_postgres( self, postgres_uri: str = "postgresql:///eq_compounds" ) -> None: """Load a LocalCompoundCache from a postgres uri for equilibrator. Parameters ---------- postgres_uri : str, optional uri of the postgres DB to use, by default "postgresql:///eq_compounds" """ self.lc = LocalCompoundCache() self.lc.ccache = CompoundCache(create_engine(postgres_uri)) self._water = self.lc.get_compounds("O") def load_thermo_from_sqlite( self, sqlite_filename: str = "compounds.sqlite" ) -> None: """Load a LocalCompoundCache from a sqlite file for equilibrator. compounds.sqlite can be generated through LocalCompoundCache's method generate_local_cache_from_default_zenodo Parameters ---------- sqlite_filename: str filename of the sqlite file to load. """ self.lc = LocalCompoundCache() self.lc.load_cache(sqlite_filename) self._water = self.lc.get_compounds("O") def get_eQ_compound_from_cid( self, c_id: str, pickaxe: Pickaxe = None, db_name: str = None ) -> Union[Compound, None]: """Get an equilibrator compound for a given c_id from the core. Attempts to retrieve a compound from the core or a specified db_name. Parameters ---------- c_id : str compound ID for MongoDB lookup of a compound. pickaxe : Pickaxe pickaxe object to look for the compound in, by default None. db_name : str Database to look for compound in before core database, by default None. Returns ------- equilibrator_assets.compounds.Compound eQuilibrator Compound """ # Find locally in pickaxe compound_smiles = None if pickaxe: if c_id in pickaxe.compounds: compound_smiles = pickaxe.compounds[c_id]["SMILES"] else: return None # Find in mongo db elif self._all_dbs_loaded(): if db_name: compound = self.client[db_name].compounds.find_one( {"_id": c_id}, {"SMILES": 1} ) if compound: compound_smiles = compound["SMILES"] # No cpd smiles from database name if not compound_smiles: compound = self._core.compounds.find_one({"_id": c_id}, {"SMILES": 1}) if compound: compound_smiles = compound["SMILES"] # No compound_smiles at all if not compound_smiles or "*" in compound_smiles: return None else: eQ_compound = self.lc.get_compounds( compound_smiles, bypass_chemaxon=True, save_empty_compounds=True ) return eQ_compound def standard_dg_formation_from_cid( self, c_id: str, pickaxe: Pickaxe = None, db_name: str = None ) -> Union[float, None]: """Get standard ∆Gfo for a compound. Parameters ---------- c_id : str Compound ID to get the ∆Gf for. pickaxe : Pickaxe pickaxe object to look for the compound in, by default None. db_name : str Database to look for compound in before core database, by default None. Returns ------- Union[float, None] ∆Gf'o for a compound, or None if unavailable. """ eQ_cpd = self.get_eQ_compound_from_cid(c_id, pickaxe, db_name) if not eQ_cpd: return None dgf = self.CC.standard_dg_formation(eQ_cpd) dgf = dgf[0] return dgf def get_eQ_reaction_from_rid( self, r_id: str, pickaxe: Pickaxe = None, db_name: str = None ) -> Union[PhasedReaction, None]: """Get an eQuilibrator reaction object from an r_id. Parameters ---------- r_id : str Reaction id to get object for. pickaxe : Pickaxe pickaxe object to look for the compound in, by default None. db_name : str Database to look for reaction in. Returns ------- PhasedReaction eQuilibrator reactiono to calculate ∆Gr with. """ if pickaxe: if r_id in pickaxe.reactions: reaction_info = pickaxe.reactions[r_id] else: return None elif db_name: mine = self.client[db_name] reaction_info = mine.reactions.find_one({"_id": r_id}) if not reaction_info: return None else: return None reactants = reaction_info["Reactants"] products = reaction_info["Products"] lhs = " + ".join(f"{r[0]} {r[1]}" for r in reactants) rhs = " + ".join(f"{p[0]} {p[1]}" for p in products) reaction_string = " => ".join([lhs, rhs]) compounds = set([r[1] for r in reactants]) compounds.update(tuple(p[1] for p in products)) eQ_compound_dict = { c_id: self.get_eQ_compound_from_cid(c_id, pickaxe, db_name) for c_id in compounds } if not all(eQ_compound_dict.values()): return None if "X73bc8ef21db580aefe4dbc0af17d4013961d9d17" not in compounds: eQ_compound_dict["water"] = self._water eq_reaction = Reaction.parse_formula(eQ_compound_dict.get, reaction_string) return eq_reaction def physiological_dg_prime_from_rid( self, r_id: str, pickaxe: Pickaxe = None, db_name: str = None ) -> Union[pint.Measurement, None]: """Calculate the ∆Gm' of a reaction. Parameters ---------- r_id : str ID of the reaction to calculate. pickaxe : Pickaxe pickaxe object to look for the compound in, by default None. db_name : str MINE the reaction is found in. Returns ------- pint.Measurement The calculated ∆G'm. """ eQ_reaction = self.get_eQ_reaction_from_rid(r_id, pickaxe, db_name) if not eQ_reaction: return None dGm_prime = self.CC.physiological_dg_prime(eQ_reaction) return dGm_prime def standard_dg_prime_from_rid( self, r_id: str, pickaxe: Pickaxe = None, db_name: str = None ) -> Union[pint.Measurement, None]: """Calculate the ∆G'o of a reaction. Parameters ---------- r_id : str ID of the reaction to calculate. pickaxe : Pickaxe pickaxe object to look for the compound in, by default None. db_name : str MINE the reaction is found in. Returns ------- pint.Measurement The calculated ∆G'o. """ eQ_reaction = self.get_eQ_reaction_from_rid(r_id, pickaxe, db_name) if not eQ_reaction: return None dG0_prime = self.CC.standard_dg_prime(eQ_reaction) return dG0_prime def dg_prime_from_rid( self, r_id: str, pickaxe: Pickaxe = None, db_name: str = None, p_h: Q_ = default_physiological_p_h, p_mg: Q_ = default_physiological_p_mg, ionic_strength: Q_ = default_physiological_ionic_strength, ) -> Union[pint.Measurement, None]: """Calculate the ∆G' of a reaction. Parameters ---------- r_id : str ID of the reaction to calculate. pickaxe : Pickaxe pickaxe object to look for the compound in, by default None. db_name : str MINE the reaction is found in. p_h : Q_ pH of system. p_mg: Q_ pMg of the system. ionic_strength: Q_ ionic strength of the system. Returns ------- pint.Measurement The calculated ∆G'. """ eQ_reaction = self.get_eQ_reaction_from_rid(r_id, pickaxe, db_name) if not eQ_reaction: return None self.CC.p_h = p_h self.CC.p_mg = p_mg self.CC.ionic_strength = ionic_strength dG_prime = self.CC.dg_prime(eQ_reaction) self._reset_CC() return dG_prime
JamesJeffryes/MINE-Database
minedatabase/thermodynamics.py
Python
mit
11,041
29.843137
86
0.567887
false
// MIT License // Copyright (c) 2017 Simon Pettersson // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Software without restriction, including without limitation the rights // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell // copies of the Software, and to permit persons to whom the Software is // furnished to do so, subject to the following conditions: // The above copyright notice and this permission notice shall be included in all // copies or substantial portions of the Software. // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE // SOFTWARE. #pragma once #include <stdexcept> #include <optional> namespace cmap { /* The underlying model for the binary tree */ namespace _model { /* A map is built like a binary tree as illustrated below. f1(k) / \ / \ f2(k) f3(k) / \ / \ f4(k) f5(k) Each subtree f1,f2,f3,f4,f5 is a function which evaluates a key and returns an `std::optional` with a value if the key matches a key in that subtree, or `std::nullopt` if there was no match in that subtree. To construct the tree we utilize two factory functions * One called `make_terminal(k,v)` which creates a function that evaluates a key and returns a std::optional. * One called `make_branch(left,right)` which creates a branch node, a function that first evaluates the left subtree, if there is a match the left subtree is returned. If unsuccessful it returns the right subtree. Example: Construct the tree above const auto f5 = make_terminal(5,15); const auto f4 = make_terminal(4,14); const auto f2 = make_terminal(3,13); const auto f3 = make_branch(f4, f5); const auto f1 = make_branch(f2, f3); // Performing a lookup for the value `5` would // produce the stacktrace f1(5) f2(5) -> {false, 13} f3(5) f4(5) -> {false, 14} f5(5) -> {true, 15} ... -> {true, 15} In order to easily chain together multiple subtrees there is a utility function called `merge(node1, ...)` which takes all the terminal nodes as arguments and automatically creates the branches. To reproduce the previous example using the merge function one could do the following. Example: Construct the same tree using the `merge` function const auto f5 = make_terminal(5,15); const auto f4 = make_terminal(4,14); const auto f2 = make_terminal(3,13); const auto f1 = merge(f2,f4,f5); Since the whole model is completely independent of the datatype stored there is literally no limit to what you can store in the map, as long as it is copy constructible. That means that you can nest maps and store complex types. */ template<typename K, typename V> constexpr auto make_terminal(const K key, const V value) { return [key,value](const auto _key) { return key == _key ? std::make_optional(value) : std::nullopt; }; }; constexpr auto make_branch(const auto left, const auto right) { return [left,right](auto key) -> decltype(left(key)) { const auto result = left(key); if(result != std::nullopt) { return result; } return right(key); }; } constexpr auto merge(const auto node) { return node; } constexpr auto merge(const auto left, const auto ... rest) { return make_branch(left, merge(rest...)); } } /* Functional interface Example: constexpr auto map = make_map(map(13,43), map(14,44)); constexpr auto fourty_three = lookup(map, 13); constexpr auto fourty_four = lookup(map, 14); */ constexpr auto make_map(const auto ... rest) { return _model::merge(rest...); } constexpr auto map(const auto key, const auto value) { return _model::make_terminal(key, value); } constexpr auto lookup(const auto tree, const auto key) { const auto result = tree(key); return result != std::nullopt ? result.value() : throw std::out_of_range("No such key"); } /* Class interface Example: constexpr auto map = make_lookup(map(13,43), map(14,44)); constexpr auto fourty_three = map[13]; constexpr auto fourty_four = map[14]; */ template<typename TLookup> struct lookup_type { constexpr lookup_type(const TLookup m) : map{m} {} constexpr auto operator[](const auto key) const { return lookup(map, key); } const TLookup map; }; constexpr auto make_lookup(lookup_type<auto> ... rest) { return lookup_type{make_map(rest.map...)}; } constexpr auto make_lookup(const auto ... rest) { return lookup_type{make_map(rest...)}; } } // namespace cmap
simonvpe/cmap
include/cmap.hpp
C++
mit
5,268
29.988235
90
0.66325
false
/* MicroJava Parser Semantic Tester * * Test only semantics. The grammar in all tests are correct. */ package MicroJava; import java.io.*; public class TestParserSemantic { public static void main(String args[]) { if (args.length == 0) { executeTests(); } else { for (int i = 0; i < args.length; ++i) { reportFile(args[i]); } } } private static void reportFile(String filename) { try { report("File: " + filename, new InputStreamReader(new FileInputStream(filename))); } catch (IOException e) { System.out.println("-- cannot open file " + filename); } } private static void report(String header, Reader reader) { System.out.println(header); Parser parser = new Parser(reader); parser.parse(); System.out.println(parser.errors + " errors detected\n"); } private static Parser createParser(String input) { Parser parser = new Parser(new StringReader(input)); parser.showSemanticError = true; parser.code.showError = false; parser.scan(); // get first token return parser; } private static void executeTests() { testClassDecl(); testCondition(); testConstDecl(); testDesignator(); testExpr(); testFactor(); testFormPars(); testMethodDecl(); testProgram(); testStatement(); testTerm(); testType(); testVarDecl(); } private static void testClassDecl() { System.out.println("Test: ClassDecl"); createParser("class A {}").ClassDecl(); createParser("class B { int b; }").ClassDecl(); createParser("class C { int c1; char[] c2; }").ClassDecl(); createParser("class D {} class E { D d; }").ClassDecl().ClassDecl(); System.out.println("Test: ClassDecl errors"); createParser("class int {}").ClassDecl(); createParser("class char {}").ClassDecl(); createParser("class F { F[] f; }").ClassDecl(); createParser("class H { int H; }").ClassDecl(); createParser("class J { int j; char j; }").ClassDecl(); // invalid type (X not declared) createParser("class K { X k; }").ClassDecl(); // atribute name is the same of the type of variable createParser("class L {} class M { L L; }").ClassDecl().ClassDecl(); createParser("class N { N N; }").ClassDecl(); System.out.println(); } private static void testCondition() { System.out.println("Test: Condition"); createParser("2 == 3").Condition(); createParser("int[] a, b; a == b").VarDecl().Condition(); createParser("char[] c, d; c != d").VarDecl().Condition(); createParser("class E{} E e, f; e == f e != f") .ClassDecl().VarDecl().Condition().Condition(); System.out.println("Test: Condition errors"); createParser("2 + 3 == 'a'").Condition(); createParser("int[] ia, ib; ia > ib").VarDecl().Condition(); createParser("class X{} X x, y; x <= y").ClassDecl().VarDecl().Condition(); createParser("class W{ int[] a; } W w; int[] b; w.a <= b") .ClassDecl().VarDecl().VarDecl().Condition(); createParser("class Z{} Z z; int[] r; r == z") .ClassDecl().VarDecl().VarDecl().Condition(); System.out.println(); } private static void testConstDecl() { System.out.println("Test: ConstDecl"); createParser("final int b = 2;").ConstDecl(); createParser("final char c = 'c';").ConstDecl(); System.out.println("Test: ConstDecl errors"); createParser("final int d = 'd';").ConstDecl(); createParser("final char e = 1;").ConstDecl(); // array is not accept createParser("final int[] f = 1;").ConstDecl(); createParser("final char[] g = 'g';").ConstDecl(); System.out.println(); } private static void testDesignator() { System.out.println("Test: Designator"); createParser("class A {} A a; a = new A; a") .ClassDecl().VarDecl().Statement().Designator(); createParser("class B { int bb; } B b; b = new B; b.bb") .ClassDecl().VarDecl().Statement().Designator(); createParser("class C { char c1; int c2; } C c; c = new C; c.c1 c.c2") .ClassDecl().VarDecl().Statement().Designator().Designator(); createParser("int[] d; d[2]").VarDecl().Designator(); System.out.println("Test: Designator errors"); createParser("int x; x.y").VarDecl().Designator(); createParser("class M { int m; } M.m").ClassDecl().Designator(); System.out.println(); } private static void testExpr() { System.out.println("Test: Expr"); createParser("2 + 3").Expr(); createParser("-4").Expr(); createParser("-5 * 6").Expr(); createParser("int a; a * 6").VarDecl().Expr(); createParser("int b, c, d; b * 6 + c * d").VarDecl().Expr(); System.out.println("Test: Expr errors"); createParser("-'a'").Expr(); createParser("-2 * 'b'").Expr(); createParser("-3 * 'c' * 4").Expr(); createParser("-5 * 'd' * 6 + 7").Expr(); createParser("char e; e - 'f' % 'g'").VarDecl().Expr(); createParser("void m(){} m + 8").MethodDecl().Expr(); System.out.println(); } private static void testFactor() { System.out.println("Test: Factor"); // new createParser("new int[2]").Factor(); createParser("int size; new char[size]").VarDecl().Factor(); createParser("class A {} new A").ClassDecl().Factor(); createParser("class B {} new B[2]").ClassDecl().Factor(); // designator: variable createParser("int i; i").VarDecl().Factor(); // designator: method */ createParser("int m1(int i, int j) {} m1(2, 3)").MethodDecl().Factor(); System.out.println("Test: Factor errors"); // new createParser("new int").Factor(); createParser("new char").Factor(); createParser("new X").Factor(); createParser("new Y[2]").Factor(); createParser("class G {} new G['b']").ClassDecl().Factor(); // designator: variable createParser("int w; w()").VarDecl().Factor(); // designator: method createParser("int me1() {} me1(1)").MethodDecl().Factor(); createParser("int me2(int i, int j) {} me2(2)").MethodDecl().Factor(); createParser("char me3(char c) {} me3(3)").MethodDecl().Factor(); createParser("char me4(int i, int j, char k) {} me4(4, 'c', 6)").MethodDecl().Factor(); // void methods (procedures) cannot be used in a expression context. // Factor is always called in an expression context (Expr -> Term -> Factor) createParser("void m5() {} m5()").MethodDecl().Factor(); createParser("void m6(char c) {} m6('c')").MethodDecl().Factor(); System.out.println(); } private static void testFormPars() { System.out.println("Test: FormPars"); createParser("int i, char c, int[] ia, char[] ca").FormPars(); createParser("class A {} A a, A[] aa").ClassDecl().FormPars(); System.out.println("Test: FormPars errors"); createParser("int char, int char").FormPars(); createParser("B b, C[] c").FormPars(); System.out.println(); } private static void testMethodDecl() { System.out.println("Test: MethodDecl"); createParser("int[] a(int[] ia, char[] ca) int i; char c; {}").MethodDecl(); createParser("void b() int i; char c; {}").MethodDecl(); createParser("class C {} \n C c() {}").ClassDecl().MethodDecl(); createParser("class D {} \n D[] d(D dp) D dv; {}").ClassDecl().MethodDecl(); System.out.println("Test: MethodDecl errors"); createParser("int char() {}").MethodDecl(); createParser("void m(G g) {}").MethodDecl(); System.out.println(); } private static void testProgram() { System.out.println("Test: Program"); createParser("program P { void main() {} }").Program(); createParser("program ABC {" + " void f() {}" + " void main() { return ; }" + " int g(int x) { return x*2; }" + " }").Program(); System.out.println("Test: Program errors"); createParser("program E1 { }").Program(); createParser("program E2 { int main() { } }").Program(); createParser("program E3 { void main(int i) { } }").Program(); System.out.println(); } private static void testStatement() { System.out.println("Test: Statement"); // Designator "=" Expr ";" createParser("int b; b = 2;").VarDecl().Statement(); createParser("char c, d; c = d;").VarDecl().Statement(); createParser("int[] e; e[3] = 3;").VarDecl().Statement(); createParser("class A { int i; } A a; a.i = 4;").ClassDecl().VarDecl().Statement(); createParser("int[] ia; ia = new int[5];").VarDecl().Statement(); createParser("char[] ca; ca = new char[6];").VarDecl().Statement(); // Designator ActPars ";" createParser("void f() {} f();").MethodDecl().Statement(); // "print" "(" Expr ["," number] ")" ";" createParser("print(2); print('c');").Statement().Statement(); createParser("print(3, 4);").Statement(); // "read" "(" Designator ")" ";" createParser("int i; read(i);").VarDecl().Statement(); createParser("char c; read(c);").VarDecl().Statement(); createParser("char[] ca; read(ca[2]);").VarDecl().Statement(); createParser("class C {int i;} C o; read(o.i);").ClassDecl().VarDecl().Statement(); // "return" [Expr] ";" createParser("void f() { return ;}").MethodDecl(); createParser("int g() { return 2;}").MethodDecl(); createParser("char h() { return 'c';}").MethodDecl(); System.out.println("Test: Statement errors"); // Designator "=" Expr createParser("int b; b = 'c';").VarDecl().Statement(); createParser("char[] c; c[4] = 4;").VarDecl().Statement(); createParser("class A { int i; } A a; a.i = '4';").ClassDecl().VarDecl().Statement(); createParser("int[] ia; ia = new char[5];").VarDecl().Statement(); createParser("char[] ca; ca = new int[6];").VarDecl().Statement(); // Designator ActPars createParser("int g; g();").VarDecl().Statement(); // "print" "(" Expr ["," number] ")" ";" createParser("class C {} C c; print(c);").ClassDecl().VarDecl().Statement(); createParser("print(5, 'd');").Statement(); // "read" "(" Designator ")" ";" createParser("class C {} C c; read(c);").ClassDecl().VarDecl().Statement(); // "return" [Expr] ";" createParser("void p() { return 1; }").MethodDecl(); createParser("int q() { return 'c';}").MethodDecl(); createParser("char r() { return 2;}").MethodDecl(); createParser("int s() { return ;}").MethodDecl(); System.out.println(); } private static void testTerm() { System.out.println("Test: Term"); createParser("2 * 3").Term(); createParser("4").Term(); createParser("5 * (-6)").Term(); createParser("'a'").Term(); createParser("int a, b; a * (-7) * b").VarDecl().Term(); createParser("char a; a").VarDecl().Term(); System.out.println("Test: Term errors"); createParser("2 * 'b'").Term(); createParser("'c' * 3").Term(); createParser("char d; d * 'e'").VarDecl().Term(); System.out.println(); } private static void testType() { System.out.println("Test: Type"); createParser("int").Type(); createParser("int[]").Type(); createParser("char").Type(); createParser("char[]").Type(); createParser("class A {} A").ClassDecl().Type(); System.out.println("Test: Type errors"); createParser("class").Type(); createParser("MyClass").Type(); System.out.println(); } private static void testVarDecl() { System.out.println("Test: VarDecl"); createParser("int x;").VarDecl(); createParser("int x, y;").VarDecl(); createParser("int x, X;").VarDecl(); // case-sensitive variables createParser("int x, y, z, X, Y, Z;").VarDecl(); System.out.println("Test: VarDecl errors"); createParser("int int;").VarDecl(); createParser("int char;").VarDecl(); createParser("char int;").VarDecl(); createParser("char char;").VarDecl(); createParser("int s, s;").VarDecl(); createParser("int t, char, t, int;").VarDecl(); createParser("int x, w, p, q, r, w;").VarDecl(); System.out.println(); } }
gabrielnobregal/mjcide
src/MicroJava/TestParserSemantic.java
Java
mit
13,139
40.579114
98
0.547606
false
.typeahead-container { width: 240px; position: relative; margin-top: 10px; margin-left: 10px; } .typeahead-container.show .dropdown-menu { display: block; } .dropdown-menu { display: none; }
JlineZen/angularComponents
typeahead/src/typeahead.css
CSS
mit
216
14.5
42
0.648148
false
import os #Decoration Starts print """ +=============================================================+ || Privilege Escalation Exploit || || +===================================================+ || || | _ _ _ ____ _ __ ____ ___ _____ | || || | | | | | / \ / ___| |/ / | _ \|_ _|_ _| | || || | | |_| | / _ \| | | ' / | |_) || | | | | || || | | _ |/ ___ \ |___| . \ | _ < | | | | | || || | |_| |_/_/ \_\____|_|\_\ |_| \_\___| |_| | || || | | || || +===================================================+ || || ~ by Yadnyawalkya Tale (yadnyawalkyatale@gmail.com) ~ || +=============================================================+ """ #Decoration Ends # Class according to Year Input print "\n1. B.Tech Final Year\n2. T.Y.B.Tech\n3. S.Y.B.Tech\n4. F.Y.Tech" year_input = input() if year_input == 1: year_choice = 1300000 #Final Year elif year_input == 2: year_choice = 1400000 #Third Year elif year_input == 3: year_choice = 1500000 #Second Year elif year_input == 4: year_choice = 1600000 #First Year # Department Class Input print "\n1.Automobile\n2.Civil\n3.ComputerScience\n4.InformationTechnology\n5.ETC\n6.Electrial\n7.Mech" class_input = input() if class_input == 1: class_choice = 1000 #Automobile Department elif class_input == 2: class_choice = 2000 #Civil Department elif class_input == 3: class_choice = 3000 #ComputerScience Department elif class_input == 4: class_choice = 4000 #InformationTechnology Department elif class_input == 5: class_choice = 5000 #ETC Department elif class_input == 6: class_choice = 8000 #Electrial Department elif class_input == 7: class_choice = 6000 #Mechanical Department startflag = year_choice + class_choice #For eg. Start @ 1303000 if class_input == 7: endflag = year_choice + class_choice + 70 +128 #Special Arrangement for Mechanical ;) else: endflag = year_choice + class_choice + 70 #For eg. End @ 1303070 os.system("mkdir ritphotos") decoration="=" while startflag < endflag: startflag = startflag + 1 cmd1 = "wget http://210.212.171.168/ritcloud/StudentPhoto.ashx?ID=SELECT%20Photo%20FROM%20StudMstAll%20WHERE%20EnrollNo%20=%20%27{0}%27 -O ritphotos/photo_{1}.jpg 2>/dev/null ".format(startflag,startflag) os.system(cmd1) decoration = "=" + decoration print "{0}".format(decoration) print "100%\tPlease Wait..." pstartflag = year_choice + class_choice + 150000 if class_input == 7: pendflag = year_choice + class_choice + 40 + 150000 #For All branches else: pendflag = year_choice + class_choice + 15 + 150000 #Special Arrangement for Mechanical ;) while pstartflag < pendflag: pstartflag = pstartflag + 1 cmd2 = "wget http://210.212.171.168/ritcloud/StudentPhoto.ashx?ID=SELECT%20Photo%20FROM%20StudMstAll%20WHERE%20EnrollNo%20=%20%27{0}%27 -O ritphotos/photo_{1}.jpg 2>/dev/null ".format(pstartflag,pstartflag) os.system(cmd2) print "Downloading Images Complete..." os.system("find ritphotos -size 0 -print0 |xargs -0 rm 2>/dev/null ") #Remove 0-Size Images
Yadnyawalkya/hackRIT
hackRIT.py
Python
mit
3,140
37.765432
210
0.569427
false
# pi ### Simple implementation of Pi calculation ### Calculates Pi by the infinite series: ``` 4 * Pi = 1 - 1/3 + 1/5 - 1/7 + ... ``` For simplicity of implementation, I have converted this to the equivalent formulation: ``` Pi = 4 - 4/3 + 4/5 - 4/7 + ... ``` The code algorithm is implemented in iterative style. While it is possible to implement this algorithm in a recursove style, since Java 8 compiler does not implement tail-call recursion optimisation, the code hits a Stack Overflow exception for n = 100 on my machine. By comparison, the Scala compiler does perform this optimisation, and a tail recursive solution would have the same performance characteristics as the iterative java version. ### Build using Maven: ``` mvn package ``` ### Usage: ``` java -jar ./target/pi-1.0-SNAPSHOT.jar n ``` where n = number or elements to use to approximate Pi.
adampwells/pi
README.md
Markdown
mit
886
28.533333
148
0.706546
false
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>coqoban: Not compatible 👼</title> <link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" /> <link href="../../../../../bootstrap.min.css" rel="stylesheet"> <link href="../../../../../bootstrap-custom.css" rel="stylesheet"> <link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet"> <script src="../../../../../moment.min.js"></script> <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries --> <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script> <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script> <![endif]--> </head> <body> <div class="container"> <div class="navbar navbar-default" role="navigation"> <div class="container-fluid"> <div class="navbar-header"> <a class="navbar-brand" href="../../../../.."><i class="fa fa-lg fa-flag-checkered"></i> Coq bench</a> </div> <div id="navbar" class="collapse navbar-collapse"> <ul class="nav navbar-nav"> <li><a href="../..">clean / extra-dev</a></li> <li class="active"><a href="">8.11.dev / coqoban - dev</a></li> </ul> </div> </div> </div> <div class="article"> <div class="row"> <div class="col-md-12"> <a href="../..">« Up</a> <h1> coqoban <small> dev <span class="label label-info">Not compatible 👼</span> </small> </h1> <p>📅 <em><script>document.write(moment("2020-07-16 03:01:33 +0000", "YYYY-MM-DD HH:mm:ss Z").fromNow());</script> (2020-07-16 03:01:33 UTC)</em><p> <h2>Context</h2> <pre># Packages matching: installed # Name # Installed # Synopsis base-bigarray base base-threads base base-unix base conf-findutils 1 Virtual package relying on findutils conf-m4 1 Virtual package relying on m4 coq 8.11.dev Formal proof management system num 1.3 The legacy Num library for arbitrary-precision integer and rational arithmetic ocaml 4.07.1 The OCaml compiler (virtual package) ocaml-base-compiler 4.07.1 Official release 4.07.1 ocaml-config 1 OCaml Switch Configuration ocamlfind 1.8.1 A library manager for OCaml # opam file: opam-version: &quot;2.0&quot; maintainer: &quot;dev@clarus.me&quot; homepage: &quot;https://github.com/coq-contribs/coqoban&quot; license: &quot;LGPL 2&quot; build: [ [&quot;coq_makefile&quot; &quot;-f&quot; &quot;Make&quot; &quot;-o&quot; &quot;Makefile&quot;] [make &quot;-j%{jobs}%&quot;] ] install: [make &quot;install&quot;] remove: [&quot;rm&quot; &quot;-R&quot; &quot;%{lib}%/coq/user-contrib/Coqoban&quot;] depends: [ &quot;ocaml&quot; &quot;coq&quot; {= &quot;dev&quot;} ] tags: [ &quot;keyword:sokoban&quot; &quot;keyword:puzzles&quot; &quot;category:Miscellaneous/Logical Puzzles and Entertainment&quot; &quot;date:2003-09-19&quot; ] authors: [ &quot;Jasper Stein &lt;&gt;&quot; ] synopsis: &quot;Coqoban (Sokoban).&quot; description: &quot;&quot;&quot; A Coq implementation of Sokoban, the Japanese warehouse keepers&#39; game&quot;&quot;&quot; flags: light-uninstall url { src: &quot;git+https://github.com/coq-contribs/coqoban.git#master&quot; } </pre> <h2>Lint</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Dry install 🏜️</h2> <p>Dry install with the current Coq version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam install -y --show-action coq-coqoban.dev coq.8.11.dev</code></dd> <dt>Return code</dt> <dd>5120</dd> <dt>Output</dt> <dd><pre>[NOTE] Package coq is already installed (current version is 8.11.dev). The following dependencies couldn&#39;t be met: - coq-coqoban -&gt; coq &gt;= dev Your request can&#39;t be satisfied: - No available version of coq satisfies the constraints No solution found, exiting </pre></dd> </dl> <p>Dry install without Coq/switch base, to test if the problem was incompatibility with the current Coq/OCaml version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam remove -y coq; opam install -y --show-action --unlock-base coq-coqoban.dev</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Install dependencies</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>0 s</dd> </dl> <h2>Install 🚀</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>0 s</dd> </dl> <h2>Installation size</h2> <p>No files were installed.</p> <h2>Uninstall 🧹</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Missing removes</dt> <dd> none </dd> <dt>Wrong removes</dt> <dd> none </dd> </dl> </div> </div> </div> <hr/> <div class="footer"> <p class="text-center"> Sources are on <a href="https://github.com/coq-bench">GitHub</a> © Guillaume Claret 🐣 </p> </div> </div> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <script src="../../../../../bootstrap.min.js"></script> </body> </html>
coq-bench/coq-bench.github.io
clean/Linux-x86_64-4.07.1-2.0.6/extra-dev/8.11.dev/coqoban/dev.html
HTML
mit
6,590
39.030488
162
0.531912
false
package fi.helsinki.cs.okkopa.main.stage; import fi.helsinki.cs.okkopa.mail.read.EmailRead; import fi.helsinki.cs.okkopa.main.ExceptionLogger; import java.io.IOException; import java.io.InputStream; import java.util.List; import javax.mail.Message; import javax.mail.MessagingException; import org.apache.commons.io.IOUtils; import org.apache.log4j.Logger; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; /** * Retrieves new emails and processes the attachments one by one by calling the next stage repeatedly. */ @Component public class GetEmailStage extends Stage<Object, InputStream> { private static final Logger LOGGER = Logger.getLogger(GetEmailStage.class.getName()); private EmailRead emailReader; private ExceptionLogger exceptionLogger; /** * * @param server * @param exceptionLogger */ @Autowired public GetEmailStage(EmailRead server, ExceptionLogger exceptionLogger) { this.exceptionLogger = exceptionLogger; this.emailReader = server; } @Override public void process(Object in) { try { emailReader.connect(); LOGGER.debug("Kirjauduttu sisään."); loopMessagesAsLongAsThereAreNew(); LOGGER.debug("Ei lisää viestejä."); } catch (MessagingException | IOException ex) { exceptionLogger.logException(ex); } finally { emailReader.closeQuietly(); } } private void processAttachments(Message nextMessage) throws MessagingException, IOException { List<InputStream> messagesAttachments = emailReader.getMessagesAttachments(nextMessage); for (InputStream attachment : messagesAttachments) { LOGGER.debug("Käsitellään liitettä."); processNextStages(attachment); IOUtils.closeQuietly(attachment); } } private void loopMessagesAsLongAsThereAreNew() throws MessagingException, IOException { Message nextMessage = emailReader.getNextMessage(); while (nextMessage != null) { LOGGER.debug("Sähköposti haettu."); processAttachments(nextMessage); emailReader.cleanUpMessage(nextMessage); nextMessage = emailReader.getNextMessage(); } } }
ohtuprojekti/OKKoPa_all
OKKoPa_core/src/main/java/fi/helsinki/cs/okkopa/main/stage/GetEmailStage.java
Java
mit
2,409
31.405405
102
0.67598
false
<!DOCTYPE html> <html xmlns:msxsl="urn:schemas-microsoft-com:xslt"> <head> <meta content="en-us" http-equiv="Content-Language" /> <meta content="text/html; charset=utf-16" http-equiv="Content-Type" /> <title _locid="PortabilityAnalysis0">.NET Portability Report</title> <style> /* Body style, for the entire document */ body { background: #F3F3F4; color: #1E1E1F; font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif; padding: 0; margin: 0; } /* Header1 style, used for the main title */ h1 { padding: 10px 0px 10px 10px; font-size: 21pt; background-color: #E2E2E2; border-bottom: 1px #C1C1C2 solid; color: #201F20; margin: 0; font-weight: normal; } /* Header2 style, used for "Overview" and other sections */ h2 { font-size: 18pt; font-weight: normal; padding: 15px 0 5px 0; margin: 0; } /* Header3 style, used for sub-sections, such as project name */ h3 { font-weight: normal; font-size: 15pt; margin: 0; padding: 15px 0 5px 0; background-color: transparent; } h4 { font-weight: normal; font-size: 12pt; margin: 0; padding: 0 0 0 0; background-color: transparent; } /* Color all hyperlinks one color */ a { color: #1382CE; } /* Paragraph text (for longer informational messages) */ p { font-size: 10pt; } /* Table styles */ table { border-spacing: 0 0; border-collapse: collapse; font-size: 10pt; } table th { background: #E7E7E8; text-align: left; text-decoration: none; font-weight: normal; padding: 3px 6px 3px 6px; } table td { vertical-align: top; padding: 3px 6px 5px 5px; margin: 0px; border: 1px solid #E7E7E8; background: #F7F7F8; } .NoBreakingChanges { color: darkgreen; font-weight:bold; } .FewBreakingChanges { color: orange; font-weight:bold; } .ManyBreakingChanges { color: red; font-weight:bold; } .BreakDetails { margin-left: 30px; } .CompatMessage { font-style: italic; font-size: 10pt; } .GoodMessage { color: darkgreen; } /* Local link is a style for hyperlinks that link to file:/// content, there are lots so color them as 'normal' text until the user mouse overs */ .localLink { color: #1E1E1F; background: #EEEEED; text-decoration: none; } .localLink:hover { color: #1382CE; background: #FFFF99; text-decoration: none; } /* Center text, used in the over views cells that contain message level counts */ .textCentered { text-align: center; } /* The message cells in message tables should take up all avaliable space */ .messageCell { width: 100%; } /* Padding around the content after the h1 */ #content { padding: 0px 12px 12px 12px; } /* The overview table expands to width, with a max width of 97% */ #overview table { width: auto; max-width: 75%; } /* The messages tables are always 97% width */ #messages table { width: 97%; } /* All Icons */ .IconSuccessEncoded, .IconInfoEncoded, .IconWarningEncoded, .IconErrorEncoded { min-width: 18px; min-height: 18px; background-repeat: no-repeat; background-position: center; } /* Success icon encoded */ .IconSuccessEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconSuccess#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAABPElEQVR4Xp1Tv0vDUBi8FqeA4NpBcBLcWnQSApncOnTo4FSnjP0DsnXpH5CxiwbHDg4Zuj4oOEXiJgiC4FDcCkLWmIMc1Pfw+eMgQ77v3Xf3Pe51YKGqqisAEwCR1TIAsiAIblSo6xrdHeJR85Xle3mdmCQKb0PsfqyxxzM8K15HZADl/H5+sHpZwYfxyRjTs+kWwKBx8yoHd2mRiuzF8mkJniWH/13u3Fjrs/EdhsdDFHGB/DLXEJBDLh1MWPAhPo1BLB4WX5yQywHR+m3tVe/t97D52CB/ziG0nIgD/qDuYg8WuCcVZ2YGwlJ3YDugkpR/VNcAEx6GEKhERSr71FuO4YCM4XBdwKvecjIlkSnsO0Hyp/GxSeJAdzBKzpOtnPwyyiPdAZhpZptT04tU+zk7s8czeges//s5C5+CwqrR4/gw+AAAAABJRU5ErkJggg==); } /* Information icon encoded */ .IconInfoEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconInformation#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAABHElEQVR4Xs2TsUoDQRRF7wwoziokjZUKadInhdhukR9YP8DMX1hYW+QvdsXa/QHBbcXC7W0CamWTQnclFutceIQJwwaWNLlwm5k5d94M76mmaeCrrmsLYOocY12FcxZFUeozCqKqqgYA8uevv1H6VuPxcwlfk5N92KHBxfFeCSAxxswlYAW/Xr989x/mv9gkhtyMDhcAxgzRsp7flj8B/HF1RsMXq+NZMkopaHe7lbKxQUEIGbKsYNoGn969060hZBkQex/W8oRQwsQaW2o3Ago2SVcJUzAgY3N0lTCZZm+zPS8HB51gMmS1DEYyOz9acKO1D8JWTlafKIMxdhvlfdyT94Vv5h7P8Ky7nQzACmhvKq3zk3PjW9asz9D/1oigecsioooAAAAASUVORK5CYII=); } /* Warning icon encoded */ .IconWarningEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconWarning#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAA7EAAAOxAGVKw4bAAAAx0lEQVR4XpWSMQ7CMAxFf4xAyBMLCxMrO8dhaBcuwdCJS3RJBw7SA/QGTCxdWJgiQYWKXJWKIXHIlyw5lqr34tQgEOdcBsCOx5yZK3hCCKdYXneQkh4pEfqzLfu+wVDSyyzFoJjfz9NB+pAF+eizx2Vruts0k15mPgvS6GYvpVtQhB61IB/dk6AF6fS4Ben0uIX5odtFe8Q/eW1KvFeH4e8khT6+gm5B+t3juyDt7n0jpe+CANTd+oTUjN/U3yVaABnSUjFz/gFq44JaVSCXeQAAAABJRU5ErkJggg==); } /* Error icon encoded */ .IconErrorEncoded { /* Note: Do not delete the comment below. It is used to verify the correctness of the encoded image resource below before the product is released */ /* [---XsltValidateInternal-Base64EncodedImage:IconError#Begin#background-image: url(data:image/png;base64,#Separator#);#End#] */ background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAABQElEQVR4XqWTvUoEQRCE6wYPZUA80AfwAQz23uCMjA7MDRQEIzPBVEyNTQUFIw00vcQTTMzuAh/AxEQQT8HF/3G/oGGnEUGuoNnd6qoZuqltyKEsyzVJq5I6rnUp6SjGeGhESikzzlc1eL7opfuVbrqbU1Zw9NCgtQMaZpY0eNnaaL2fHusvTK5vKu7sjSS1Y4y3QUA6K3e3Mau5UFDyMP7tYF9o8cAHZv68vipoIJg971PZIZ5HiwdvYGGvFVFHmGmZ2MxwmQYPXubPl9Up0tfoMQGetXd6mRbvhBw+boZ6WF7Mbv1+GsHRk0fQmPAH1GfmZirbCfDJ61tw3Px8/8pZsPAG4jlVhcPgZ7adwNWBB68lkRQWFiTgFlbnLY3DGGM7izIJIyT/jjIvEJw6fdJTc6krDzh6aMwMP9bvDH4ADSsa9uSWVJkAAAAASUVORK5CYII=); } </style> </head> <body> <h1 _locid="PortabilityReport">.NET Portability Report</h1> <div id="content"> <div id="submissionId" style="font-size:8pt;"> <p> <i> Submission Id&nbsp; e4ed6ab8-c844-4c3f-89cb-6d335214afa2 </i> </p> </div> <h2 _locid="SummaryTitle"> <a name="Portability Summary"></a>Portability Summary </h2> <div id="summary"> <table> <tbody> <tr> <th>Assembly</th> <th>ASP.NET 5,Version=v1.0</th> <th>Windows,Version=v8.1</th> <th>.NET Framework,Version=v4.6</th> <th>Windows Phone,Version=v8.1</th> </tr> <tr> <td><strong><a href="#System.Net.Http">System.Net.Http</a></strong></td> <td class="text-center">88.25 %</td> <td class="text-center">81.33 %</td> <td class="text-center">100.00 %</td> <td class="text-center">81.33 %</td> </tr> </tbody> </table> </div> <div id="details"> <a name="System.Net.Http"><h3>System.Net.Http</h3></a> <table> <tbody> <tr> <th>Target type</th> <th>ASP.NET 5,Version=v1.0</th> <th>Windows,Version=v8.1</th> <th>.NET Framework,Version=v4.6</th> <th>Windows Phone,Version=v8.1</th> <th>Recommended changes</th> </tr> <tr> <td>System.AppDomain</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use object with finalizer stored in static variable, or use app-model specific unload notifications (e.g. Application.Suspending event for modern apps)</td> </tr> <tr> <td style="padding-left:2em">add_DomainUnload(System.EventHandler)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use object with finalizer stored in static variable, or use app-model specific unload notifications (e.g. Application.Suspending event for modern apps)</td> </tr> <tr> <td style="padding-left:2em">add_ProcessExit(System.EventHandler)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use object with finalizer stored in static variable, or use app-model specific unload notifications (e.g. Application.Suspending event for modern apps)</td> </tr> <tr> <td style="padding-left:2em">add_UnhandledException(System.UnhandledExceptionEventHandler)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td style="padding-left:2em">get_CurrentDomain</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Collections.Hashtable</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Item(System.Object)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetEnumerator</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Remove(System.Object)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_Item(System.Object,System.Object)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Collections.Specialized.NameObjectCollectionBase</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Count</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Collections.Specialized.NameValueCollection</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Add(System.String,System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetKey(System.Int32)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetValues(System.Int32)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Collections.Specialized.StringDictionary</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">ContainsKey(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Item(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_Item(System.String,System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Diagnostics.SourceSwitch</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">ShouldTrace(System.Diagnostics.TraceEventType)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Diagnostics.TraceEventType</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Diagnostics.TraceSource</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Close</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Attributes</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_Switch</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">TraceEvent(System.Diagnostics.TraceEventType,System.Int32,System.String)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Exception</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage.</td> </tr> <tr> <td style="padding-left:2em">add_SerializeObjectState(System.EventHandler{System.Runtime.Serialization.SafeSerializationEventArgs})</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.ICloneable</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage. Implement cloning operation yourself if needed.</td> </tr> <tr> <td style="padding-left:2em">Clone</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage. Implement cloning operation yourself if needed.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.IO.MemoryStream</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use an overload that supplies a buffer and maintain that buffer outside of memory stream. If you need the internal buffer, create a copy via .ToArray();</td> </tr> <tr> <td style="padding-left:2em">GetBuffer</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use an overload that supplies a buffer and maintain that buffer outside of memory stream. If you need the internal buffer, create a copy via .ToArray();</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.IO.Stream</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Stream.WriteAsync</td> </tr> <tr> <td style="padding-left:2em">BeginRead(System.Byte[],System.Int32,System.Int32,System.AsyncCallback,System.Object)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Stream.ReadAsync</td> </tr> <tr> <td style="padding-left:2em">BeginWrite(System.Byte[],System.Int32,System.Int32,System.AsyncCallback,System.Object)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Stream.WriteAsync</td> </tr> <tr> <td style="padding-left:2em">Close</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Dispose instead</td> </tr> <tr> <td style="padding-left:2em">EndRead(System.IAsyncResult)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Stream.ReadAsync</td> </tr> <tr> <td style="padding-left:2em">EndWrite(System.IAsyncResult)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use Stream.WriteAsync</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Net.HttpVersion</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Version10</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Version11</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Net.HttpWebRequest</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpClientHandler.SetAutomaticDecompression(System.Net.DecompressionMethods)</td> </tr> <tr> <td style="padding-left:2em">AddRange(System.Int64)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">AddRange(System.Int64,System.Int64)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">EndGetRequestStream(System.IAsyncResult,System.Net.TransportContext@)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_ServicePoint</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Not supported - connections and connection groups are managed internally by the HTTP stack</td> </tr> <tr> <td style="padding-left:2em">set_AllowAutoRedirect(System.Boolean)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpClientHandler.AllowAutoRedirect</td> </tr> <tr> <td style="padding-left:2em">set_AutomaticDecompression(System.Net.DecompressionMethods)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpClientHandler.SetAutomaticDecompression(System.Net.DecompressionMethods)</td> </tr> <tr> <td style="padding-left:2em">set_Connection(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpResponseMessage.Headers.Connection.Add(System.String)</td> </tr> <tr> <td style="padding-left:2em">set_Date(System.DateTime)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_Expect(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http. HttpClient.DefaultRequestHeaders.Expect (applies to all requests made by that client) or System.Net.Http.HttpRequestMessage.Headers.Expect (applies to specific request)</td> </tr> <tr> <td style="padding-left:2em">set_Host(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_IfModifiedSince(System.DateTime)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpClient.DefaultRequestHeaders.IfModifiedSince (applies to all requests made by that client) or System.Net.Http.HttpRequestMessage.Headers.IfModifiedSince (applies to specific request)</td> </tr> <tr> <td style="padding-left:2em">set_KeepAlive(System.Boolean)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpResponseMessage.Headers.Connection.Add(&quot;Keep-Alive&quot;)</td> </tr> <tr> <td style="padding-left:2em">set_MaximumAutomaticRedirections(System.Int32)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpClientHandler.MaxAutomaticRedirections</td> </tr> <tr> <td style="padding-left:2em">set_ProtocolVersion(System.Version)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpRequestMessage.Version</td> </tr> <tr> <td style="padding-left:2em">set_Referer(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpRequestMessage.Headers.Referrer</td> </tr> <tr> <td style="padding-left:2em">set_SendChunked(System.Boolean)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Add &quot;chunked&quot; to System.Net.Http.HttpClient.DefaultRequestHeaders.TransferEncoding (applies to all requests made by that client) or System.Net.Http.HttpRequestMessage.Headers.TransferEncoding(applies to specific request)</td> </tr> <tr> <td style="padding-left:2em">set_TransferEncoding(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http. HttpClient.DefaultRequestHeaders.TransferEncoding (applies to all requests made by that client) or System.Net.Http.HttpRequestMessage.Headers.TransferEncoding(applies to specific request)</td> </tr> <tr> <td style="padding-left:2em">set_UserAgent(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpClient.DefaultRequestHeaders.UserAgent (applies to all requests made by that client) or System.Net.Http.HttpRequestMessage.Headers.UserAgent (applies to specific request)</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Net.HttpWebResponse</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_ProtocolVersion</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Net.IPAddress</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Net.IPEndPoint</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Net.Mail.MailAddress</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Net.NetworkAccess</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Net.ServicePoint</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpClient, System.Net.Http.HttpClientHandler and System.Net.Http.WinHttpHandler types instead</td> </tr> <tr> <td style="padding-left:2em">CloseConnectionGroup(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpClient, System.Net.Http.HttpClientHandler and System.Net.Http.WinHttpHandler types instead</td> </tr> <tr> <td style="padding-left:2em">set_Expect100Continue(System.Boolean)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Not supported. Expect: 100-Continue is turned off always.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Net.ServicePointManager</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.HttpClient or WinHttpHandler instead.</td> </tr> <tr> <td style="padding-left:2em">FindServicePoint(System.Uri)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Net.WebPermission</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.Net.NetworkAccess,System.Text.RegularExpressions.Regex)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Net.WebRequest</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">CreateDefault(System.Uri)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_ConnectionGroupName(System.String)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Not supported - connections and connection groups are managed internally by the HTTP stack</td> </tr> <tr> <td style="padding-left:2em">set_ContentLength(System.Int64)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpContent.Headers.ContentLength</td> </tr> <tr> <td style="padding-left:2em">set_PreAuthenticate(System.Boolean)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.WinHttpHandler.PreAuthenticate</td> </tr> <tr> <td style="padding-left:2em">set_Timeout(System.Int32)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Use System.Net.Http.HttpClient.Timeout. More granular timeouts available: Use System.Net.Http.WinHttpHandler.ConnectTimeout, .ReceiveTimeout, .SendTimeout</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Reflection.Assembly</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage: As CAS is not supported in newer frameworks, this property no longer has meaning</td> </tr> <tr> <td style="padding-left:2em">get_IsFullyTrusted</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage: As CAS is not supported in newer frameworks, this property no longer has meaning</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Runtime.Serialization.ISafeSerializationData</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>either 1) Delete Serialization info from exceptions (since this can&#39;t be remoted) or 2) Use a different serialization technology if not for exceptions.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Runtime.Serialization.SafeSerializationEventArgs</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>either 1) Delete Serialization info from exceptions (since this can&#39;t be remoted) or 2) Use a different serialization technology if not for exceptions.</td> </tr> <tr> <td style="padding-left:2em">AddSerializedState(System.Runtime.Serialization.ISafeSerializationData)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>either 1) Delete Serialization info from exceptions (since this can&#39;t be remoted) or 2) Use a different serialization technology if not for exceptions.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Security.CodeAccessPermission</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td style="padding-left:2em">Demand</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Security.Permissions.SecurityAction</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Security.Permissions.SecurityPermissionAttribute</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td style="padding-left:2em">#ctor(System.Security.Permissions.SecurityAction)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove usage</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Security.Principal.WindowsIdentity</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetCurrent</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Impersonate</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Security.Principal.WindowsImpersonationContext</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.SerializableAttribute</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove this attribute</td> </tr> <tr> <td style="padding-left:2em">#ctor</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Remove this attribute</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.StackOverflowException</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Do not use: Exception cannot be caught since HandleProcessCorruptedStateExceptions is not supported, never throw this type.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Text.DecoderFallback</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_ExceptionFallback</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Text.EncoderFallback</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_ExceptionFallback</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Text.Encoding</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_UTF32</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetEncoding(System.Int32)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetEncoding(System.String,System.Text.EncoderFallback,System.Text.DecoderFallback)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">GetString(System.Byte[])</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Call Encoding.GetString(byte[], int, int)</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Threading.ExecutionContext</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">IsFlowSuppressed</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Threading.Thread</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.Threading.ThreadStart)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_CurrentThread</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">get_ManagedThreadId</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">set_IsBackground(System.Boolean)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Sleep(System.Int32)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">Start</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Threading.ThreadAbortException</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Do not use: exception cannot be caught since it is not thrown by framework, never throw this type. Thread.Abort is only reliable in SQL Server. Elsewhere, don&#39;t use it.</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Threading.ThreadStart</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">#ctor(System.Object,System.IntPtr)</td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Threading.WaitHandle</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">WaitAny(System.Threading.WaitHandle[],System.Int32,System.Boolean)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">WaitOne(System.Int32,System.Boolean)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Type</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>.GetTypeInfo().Assembly</td> </tr> <tr> <td style="padding-left:2em">get_Assembly</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>.GetTypeInfo().Assembly</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.UnhandledExceptionEventArgs</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Avoid usage of the UnhandledException Event, handle exceptions directly at scope of method being called</td> </tr> <tr> <td style="padding-left:2em">get_ExceptionObject</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Avoid usage of the UnhandledException Event, handle exceptions directly at scope of method being called</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.UnhandledExceptionEventHandler</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Avoid usage of the UnhandledException Event, handle exceptions directly at scope of method being called</td> </tr> <tr> <td style="padding-left:2em">#ctor(System.Object,System.IntPtr)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td>Avoid usage of the UnhandledException Event, handle exceptions directly at scope of method being called</td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> <tr> <td>System.Uri</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">HexEscape(System.Char)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">HexUnescape(System.String,System.Int32@)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td style="padding-left:2em">IsHexEncoding(System.String,System.Int32)</td> <td class="IconErrorEncoded"></td> <td class="IconErrorEncoded"></td> <td class="IconSuccessEncoded"></td> <td class="IconErrorEncoded"></td> <td></td> </tr> <tr> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> <td>&nbsp;</td> </tr> </tbody> </table> <p> <a href="#Portability Summary">Back to Summary</a> </p> </div> </div> </body> </html>
kuhlenh/port-to-core
Reports/mi/microsoft.net.http.2.2.29/System.Net.Http-net40.html
HTML
mit
91,378
44.456533
562
0.362866
false
import codecs unicode_string = "Hello Python 3 String" bytes_object = b"Hello Python 3 Bytes" print(unicode_string, type(unicode_string)) print(bytes_object, type(bytes_object)) #decode to unicode_string ux = str(object=bytes_object, encoding="utf-8", errors="strict") print(ux, type(ux)) ux = bytes_object.decode(encoding="utf-8", errors="strict") print(ux, type(ux)) hex_bytes = codecs.encode(b"Binary Object", "hex_codec") def string_to_bytes( text ): return bin(int.from_bytes(text.encode(), 'big')) def bytes_to_string( btext ): #btext = int('0b110100001100101011011000110110001101111', 2) return btext.to_bytes((btext.bit_length() + 7) // 8, 'big').decode() def char_to_bytes(char): return bin(ord(char)) def encodes(text): bext = text.encode(encoding="utf-8") enc_bext = codecs.encode(bext, "hex_codec") return enc_bext.decode("utf-8") def decodes(): pass if __name__ == "__main__": print( encodes("walla") )
thedemz/python-gems
bitten.py
Python
mit
978
17.807692
72
0.666667
false
package simple.practice; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.stereotype.Component; import simple.practice.service.GreetingService; @Component public class Greeting { @Autowired private GreetingService greetingService; public String printGreeting(String name){ String msg = greetingService.greetingMessage() + " User: " + name; System.out.println(msg); return msg; } }
blackphenol/SimpleSpring
src/main/java/simple/practice/Greeting.java
Java
mit
438
22.052632
68
0.787671
false
"""Class to perform random over-sampling.""" # Authors: Guillaume Lemaitre <g.lemaitre58@gmail.com> # Christos Aridas # License: MIT from collections.abc import Mapping from numbers import Real import numpy as np from scipy import sparse from sklearn.utils import check_array, check_random_state from sklearn.utils import _safe_indexing from sklearn.utils.sparsefuncs import mean_variance_axis from .base import BaseOverSampler from ..utils import check_target_type from ..utils import Substitution from ..utils._docstring import _random_state_docstring from ..utils._validation import _deprecate_positional_args @Substitution( sampling_strategy=BaseOverSampler._sampling_strategy_docstring, random_state=_random_state_docstring, ) class RandomOverSampler(BaseOverSampler): """Class to perform random over-sampling. Object to over-sample the minority class(es) by picking samples at random with replacement. The bootstrap can be generated in a smoothed manner. Read more in the :ref:`User Guide <random_over_sampler>`. Parameters ---------- {sampling_strategy} {random_state} shrinkage : float or dict, default=None Parameter controlling the shrinkage applied to the covariance matrix. when a smoothed bootstrap is generated. The options are: - if `None`, a normal bootstrap will be generated without perturbation. It is equivalent to `shrinkage=0` as well; - if a `float` is given, the shrinkage factor will be used for all classes to generate the smoothed bootstrap; - if a `dict` is given, the shrinkage factor will specific for each class. The key correspond to the targeted class and the value is the shrinkage factor. The value needs of the shrinkage parameter needs to be higher or equal to 0. .. versionadded:: 0.8 Attributes ---------- sampling_strategy_ : dict Dictionary containing the information to sample the dataset. The keys corresponds to the class labels from which to sample and the values are the number of samples to sample. sample_indices_ : ndarray of shape (n_new_samples,) Indices of the samples selected. .. versionadded:: 0.4 shrinkage_ : dict or None The per-class shrinkage factor used to generate the smoothed bootstrap sample. When `shrinkage=None` a normal bootstrap will be generated. .. versionadded:: 0.8 n_features_in_ : int Number of features in the input dataset. .. versionadded:: 0.9 See Also -------- BorderlineSMOTE : Over-sample using the borderline-SMOTE variant. SMOTE : Over-sample using SMOTE. SMOTENC : Over-sample using SMOTE for continuous and categorical features. SMOTEN : Over-sample using the SMOTE variant specifically for categorical features only. SVMSMOTE : Over-sample using SVM-SMOTE variant. ADASYN : Over-sample using ADASYN. KMeansSMOTE : Over-sample applying a clustering before to oversample using SMOTE. Notes ----- Supports multi-class resampling by sampling each class independently. Supports heterogeneous data as object array containing string and numeric data. When generating a smoothed bootstrap, this method is also known as Random Over-Sampling Examples (ROSE) [1]_. .. warning:: Since smoothed bootstrap are generated by adding a small perturbation to the drawn samples, this method is not adequate when working with sparse matrices. References ---------- .. [1] G Menardi, N. Torelli, "Training and assessing classification rules with imbalanced data," Data Mining and Knowledge Discovery, 28(1), pp.92-122, 2014. Examples -------- >>> from collections import Counter >>> from sklearn.datasets import make_classification >>> from imblearn.over_sampling import \ RandomOverSampler # doctest: +NORMALIZE_WHITESPACE >>> X, y = make_classification(n_classes=2, class_sep=2, ... weights=[0.1, 0.9], n_informative=3, n_redundant=1, flip_y=0, ... n_features=20, n_clusters_per_class=1, n_samples=1000, random_state=10) >>> print('Original dataset shape %s' % Counter(y)) Original dataset shape Counter({{1: 900, 0: 100}}) >>> ros = RandomOverSampler(random_state=42) >>> X_res, y_res = ros.fit_resample(X, y) >>> print('Resampled dataset shape %s' % Counter(y_res)) Resampled dataset shape Counter({{0: 900, 1: 900}}) """ @_deprecate_positional_args def __init__( self, *, sampling_strategy="auto", random_state=None, shrinkage=None, ): super().__init__(sampling_strategy=sampling_strategy) self.random_state = random_state self.shrinkage = shrinkage def _check_X_y(self, X, y): y, binarize_y = check_target_type(y, indicate_one_vs_all=True) X, y = self._validate_data( X, y, reset=True, accept_sparse=["csr", "csc"], dtype=None, force_all_finite=False, ) return X, y, binarize_y def _fit_resample(self, X, y): random_state = check_random_state(self.random_state) if isinstance(self.shrinkage, Real): self.shrinkage_ = { klass: self.shrinkage for klass in self.sampling_strategy_ } elif self.shrinkage is None or isinstance(self.shrinkage, Mapping): self.shrinkage_ = self.shrinkage else: raise ValueError( f"`shrinkage` should either be a positive floating number or " f"a dictionary mapping a class to a positive floating number. " f"Got {repr(self.shrinkage)} instead." ) if self.shrinkage_ is not None: missing_shrinkage_keys = ( self.sampling_strategy_.keys() - self.shrinkage_.keys() ) if missing_shrinkage_keys: raise ValueError( f"`shrinkage` should contain a shrinkage factor for " f"each class that will be resampled. The missing " f"classes are: {repr(missing_shrinkage_keys)}" ) for klass, shrink_factor in self.shrinkage_.items(): if shrink_factor < 0: raise ValueError( f"The shrinkage factor needs to be >= 0. " f"Got {shrink_factor} for class {klass}." ) # smoothed bootstrap imposes to make numerical operation; we need # to be sure to have only numerical data in X try: X = check_array(X, accept_sparse=["csr", "csc"], dtype="numeric") except ValueError as exc: raise ValueError( "When shrinkage is not None, X needs to contain only " "numerical data to later generate a smoothed bootstrap " "sample." ) from exc X_resampled = [X.copy()] y_resampled = [y.copy()] sample_indices = range(X.shape[0]) for class_sample, num_samples in self.sampling_strategy_.items(): target_class_indices = np.flatnonzero(y == class_sample) bootstrap_indices = random_state.choice( target_class_indices, size=num_samples, replace=True, ) sample_indices = np.append(sample_indices, bootstrap_indices) if self.shrinkage_ is not None: # generate a smoothed bootstrap with a perturbation n_samples, n_features = X.shape smoothing_constant = (4 / ((n_features + 2) * n_samples)) ** ( 1 / (n_features + 4) ) if sparse.issparse(X): _, X_class_variance = mean_variance_axis( X[target_class_indices, :], axis=0, ) X_class_scale = np.sqrt(X_class_variance, out=X_class_variance) else: X_class_scale = np.std(X[target_class_indices, :], axis=0) smoothing_matrix = np.diagflat( self.shrinkage_[class_sample] * smoothing_constant * X_class_scale ) X_new = random_state.randn(num_samples, n_features) X_new = X_new.dot(smoothing_matrix) + X[bootstrap_indices, :] if sparse.issparse(X): X_new = sparse.csr_matrix(X_new, dtype=X.dtype) X_resampled.append(X_new) else: # generate a bootstrap X_resampled.append(_safe_indexing(X, bootstrap_indices)) y_resampled.append(_safe_indexing(y, bootstrap_indices)) self.sample_indices_ = np.array(sample_indices) if sparse.issparse(X): X_resampled = sparse.vstack(X_resampled, format=X.format) else: X_resampled = np.vstack(X_resampled) y_resampled = np.hstack(y_resampled) return X_resampled, y_resampled def _more_tags(self): return { "X_types": ["2darray", "string", "sparse", "dataframe"], "sample_indices": True, "allow_nan": True, }
scikit-learn-contrib/imbalanced-learn
imblearn/over_sampling/_random_over_sampler.py
Python
mit
9,497
35.519231
86
0.598104
false
StockPredict ============ Predict stock market prices based on discovered patterns
ozzioma/StockPredict
README.md
Markdown
mit
84
20
56
0.72619
false
# Source Generated with Decompyle++ # File: session_recording.pyc (Python 2.5) from __future__ import absolute_import from pushbase.session_recording_component import FixedLengthSessionRecordingComponent class SessionRecordingComponent(FixedLengthSessionRecordingComponent): def __init__(self, *a, **k): super(SessionRecordingComponent, self).__init__(*a, **a) self.set_trigger_recording_on_release(not (self._record_button.is_pressed)) def set_trigger_recording_on_release(self, trigger_recording): self._should_trigger_recording = trigger_recording def _on_record_button_pressed(self): pass def _on_record_button_released(self): if self._should_trigger_recording: self._trigger_recording() self._should_trigger_recording = True
phatblat/AbletonLiveMIDIRemoteScripts
Push2/session_recording.py
Python
mit
842
29.071429
85
0.687648
false
# Generated by Django 2.1 on 2018-08-26 00:54 from django.db import migrations, models class Migration(migrations.Migration): dependencies = [ ('model_filefields_example', '0001_initial'), ] operations = [ migrations.AlterField( model_name='book', name='cover', field=models.ImageField(blank=True, null=True, upload_to='model_filefields_example.BookCover/bytes/filename/mimetype'), ), migrations.AlterField( model_name='book', name='index', field=models.FileField(blank=True, null=True, upload_to='model_filefields_example.BookIndex/bytes/filename/mimetype'), ), migrations.AlterField( model_name='book', name='pages', field=models.FileField(blank=True, null=True, upload_to='model_filefields_example.BookPages/bytes/filename/mimetype'), ), migrations.AlterField( model_name='sounddevice', name='instruction_manual', field=models.FileField(blank=True, null=True, upload_to='model_filefields_example.SoundDeviceInstructionManual/bytes/filename/mimetype'), ), ]
victor-o-silva/db_file_storage
demo_and_tests/model_filefields_example/migrations/0002_auto_20180826_0054.py
Python
mit
1,197
35.272727
149
0.626566
false
\begin{figure}[H] \centering \includegraphics[width=6in]{figs/run_29/run_29_ctke_vs_r_mesh_scatter} \caption{Scatter plot of turbulent kinetic energy vs radius at $z/c$=7.75, $V_{free}$=31.26, station3} \label{fig:run_29_ctke_vs_r_mesh_scatter} \end{figure}
Jwely/pivpr
texdocs/figs/run_29/run_29_ctke_vs_r_mesh_scatter.tex
TeX
mit
260
31.5
102
0.730769
false
using System; using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; using Microsoft.AspNetCore.Builder; using Microsoft.AspNetCore.Hosting; using Microsoft.AspNetCore.Http; using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.Logging; using Microsoft.Extensions.FileProviders; using System.IO; namespace SpaClient { public class Startup { // This method gets called by the runtime. Use this method to add services to the container. // For more information on how to configure your application, visit https://go.microsoft.com/fwlink/?LinkID=398940 public void ConfigureServices(IServiceCollection services) { } // This method gets called by the runtime. Use this method to configure the HTTP request pipeline. public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory) { loggerFactory.AddConsole(); if (env.IsDevelopment()) { app.UseDeveloperExceptionPage(); } app.UseDefaultFiles(); app.UseStaticFiles(); //Copy appsettings.env to the wwwroot directory var settingsPath = Path.Combine(Directory.GetCurrentDirectory(), "wwwroot"); string sourceFile = Path.Combine(Directory.GetCurrentDirectory(), $"appsettings.{env.EnvironmentName}.json"); string destFile = Path.Combine(settingsPath, "appsettings.json"); File.Copy(sourceFile, destFile, true); app.Run(async (context) => { await context.Response.WriteAsync("Hello World!"); }); } } }
JohanPeeters/REST-IAM-demo
SpaClient/Startup.cs
C#
mit
1,770
34.833333
122
0.64819
false
<?php /* *--------------------------------------------------------------- * APPLICATION ENVIRONMENT *--------------------------------------------------------------- * * You can load different configurations depending on your * current environment. Setting the environment also influences * things like logging and error reporting. * * This can be set to anything, but default usage is: * * development * testing * production * * NOTE: If you change these, also change the error_reporting() code below * */ define('ENVIRONMENT', 'development'); /* *--------------------------------------------------------------- * ERROR REPORTING *--------------------------------------------------------------- * * Different environments will require different levels of error reporting. * By default development will show errors but testing and live will hide them. */ if (defined('ENVIRONMENT')) { switch (ENVIRONMENT) { case 'development': error_reporting(E_ALL); break; case 'testing': case 'production': error_reporting(0); break; default: exit('The application environment is not set correctly.'); } } /* *--------------------------------------------------------------- * SYSTEM FOLDER NAME *--------------------------------------------------------------- * * This variable must contain the name of your "system" folder. * Include the path if the folder is not in the same directory * as this file. * */ $system_path = 'system'; /* *--------------------------------------------------------------- * APPLICATION FOLDER NAME *--------------------------------------------------------------- * * If you want this front controller to use a different "application" * folder then the default one you can set its name here. The folder * can also be renamed or relocated anywhere on your server. If * you do, use a full server path. For more info please see the user guide: * http://codeigniter.com/user_guide/general/managing_apps.html * * NO TRAILING SLASH! * */ $application_folder = 'application'; /* * -------------------------------------------------------------------- * DEFAULT CONTROLLER * -------------------------------------------------------------------- * * Normally you will set your default controller in the routes.php file. * You can, however, force a custom routing by hard-coding a * specific controller class/function here. For most applications, you * WILL NOT set your routing here, but it's an option for those * special instances where you might want to override the standard * routing in a specific front controller that shares a common CI installation. * * IMPORTANT: If you set the routing here, NO OTHER controller will be * callable. In essence, this preference limits your application to ONE * specific controller. Leave the function name blank if you need * to call functions dynamically via the URI. * * Un-comment the $routing array below to use this feature * */ // The directory name, relative to the "controllers" folder. Leave blank // if your controller is not in a sub-folder within the "controllers" folder // $routing['directory'] = ''; // The controller class file name. Example: Mycontroller // $routing['controller'] = ''; // The controller function you wish to be called. // $routing['function'] = ''; /* * ------------------------------------------------------------------- * CUSTOM CONFIG VALUES * ------------------------------------------------------------------- * * The $assign_to_config array below will be passed dynamically to the * config class when initialized. This allows you to set custom config * items or override any default config values found in the config.php file. * This can be handy as it permits you to share one application between * multiple front controller files, with each file containing different * config values. * * Un-comment the $assign_to_config array below to use this feature * */ // $assign_to_config['name_of_config_item'] = 'value of config item'; // -------------------------------------------------------------------- // END OF USER CONFIGURABLE SETTINGS. DO NOT EDIT BELOW THIS LINE // -------------------------------------------------------------------- /* * --------------------------------------------------------------- * Resolve the system path for increased reliability * --------------------------------------------------------------- */ // Set the current directory correctly for CLI requests if (defined('STDIN')) { chdir(dirname(__FILE__)); } if (realpath($system_path) !== FALSE) { $system_path = realpath($system_path).'/'; } // ensure there's a trailing slash $system_path = rtrim($system_path, '/').'/'; // Is the system path correct? if ( ! is_dir($system_path)) { exit("Your system folder path does not appear to be set correctly. Please open the following file and correct this: ".pathinfo(__FILE__, PATHINFO_BASENAME)); } /* * ------------------------------------------------------------------- * Now that we know the path, set the main path constants * ------------------------------------------------------------------- */ // The name of THIS file define('SELF', pathinfo(__FILE__, PATHINFO_BASENAME)); // The PHP file extension // this global constant is deprecated. define('EXT', '.php'); // Path to the system folder define('BASEPATH', str_replace("\\", "/", $system_path)); // Path to the front controller (this file) define('FCPATH', str_replace(SELF, '', __FILE__)); // Name of the "system folder" define('SYSDIR', trim(strrchr(trim(BASEPATH, '/'), '/'), '/')); // The path to the "application" folder if (is_dir($application_folder)) { define('APPPATH', $application_folder.'/'); } else { if ( ! is_dir(BASEPATH.$application_folder.'/')) { exit("Your application folder path does not appear to be set correctly. Please open the following file and correct this: ".SELF); } define('APPPATH', BASEPATH.$application_folder.'/'); } /* -------------------------------------------------------------------- * LOAD THE DATAMAPPER BOOTSTRAP FILE * Author: Mohab Usama * -------------------------------------------------------------------- */ require_once APPPATH.'third_party/datamapper/bootstrap.php'; /* * -------------------------------------------------------------------- * LOAD THE BOOTSTRAP FILE * -------------------------------------------------------------------- * * And away we go... * */ require_once BASEPATH.'core/CodeIgniter.php'; /* End of file index.php */ /* Location: ./index.php */
mohabusama/ci-rest-api
index.php
PHP
mit
6,890
31.504717
165
0.51553
false
require 'active_service/model/attributes/nested_attributes' require 'active_service/model/attributes/attribute_map' require 'active_service/model/attributes/serializer' module ActiveService module Model # This module handles attribute methods not provided by ActiveAttr module Attributes extend ActiveSupport::Concern include ActiveService::Model::Attributes::NestedAttributes # Initialize a new object with data # # @param [Hash] attributes The attributes to initialize the object with # @option attributes [Boolean] :_destroyed # # @example # class User < ActiveService::Base # attribute :name # end # # User.new(name: "Tobias") # # => #<User name="Tobias"> # # User.new do |u| # u.name = "Tobias" # end # # => #<User name="Tobias"> def initialize(attributes={}) attributes ||= {} @destroyed = attributes.delete(:_destroyed) || false @owner_path = attributes.delete(:_owner_path) attributes = self.class.default_scope.apply_to(attributes) assign_attributes(attributes) && apply_defaults yield self if block_given? end # Handles missing methods # # @private def method_missing(method, *args, &blk) name = method.to_s.chop if method.to_s =~ /[?=]$/ && has_association?(name) (class << self; self; end).send(:define_method, method) do |value| @attributes[:"#{name}"] = value end send method, *args, &blk else super end end # @private def respond_to_missing?(method, include_private = false) method.to_s =~ /[?=]$/ && has_association?(method.to_s.chop) || super end # Assign new attributes to a resource # # @example # class User < ActiveService::Model # end # # user = User.find(1) # => #<User id=1 name="Tobias"> # user.assign_attributes(name: "Lindsay") # user.changes # => { :name => ["Tobias", "Lindsay"] } def assign_attributes(new_attributes) @attributes ||= attributes # Use setter methods first unset_attributes = self.class.use_setter_methods(self, new_attributes) # Then translate attributes of associations into association instances associations = self.class.parse_associations(unset_attributes) # Then merge the associations into @attributes @attributes.merge!(associations) end alias attributes= assign_attributes def attributes @attributes ||= HashWithIndifferentAccess.new end # Returns true if attribute is defined # # @private def has_attribute?(attribute_name) self.class.attribute_names.include?(attribute_name.to_s) end # @private def has_nested_attributes?(attributes_name) return false unless attributes_name.to_s.match(/_attributes/) associations = self.class.associations.values.flatten.map { |a| a[:name] } associations.include?(attributes_name.to_s.gsub("_attributes", "").to_sym) end # Handles returning data for a specific attribute # # @private def get_attribute(attribute_name) @attributes[attribute_name] end # Returns complete list of attributes and included associations # # @private def serialized_attributes Serializer.new(self).serialize end # Return the value of the model `primary_key` attribute # def id # @attributes[self.class.primary_key] # end # Return `true` if other object is an ActiveService::Base and has matching data # # @private def ==(other) other.is_a?(ActiveService::Base) && @attributes == other.attributes end # Delegate to the == method # # @private def eql?(other) self == other end # Delegate to @attributes, allowing models to act correctly in code like: # [ Model.find(1), Model.find(1) ].uniq # => [ Model.find(1) ] # @private def hash @attributes.hash end module ClassMethods # Initialize a single resource # # @private def instantiate_record(klass, record) if record.kind_of?(klass) record else klass.new(klass.parse(record)) do |resource| resource.send :clear_changes_information end end end # Initialize a collection of resources # # @private def instantiate_collection(klass, data = {}) collection_parser.new(klass.extract_array(data)).collect! do |record| instantiate_record(klass, record) end end # Initialize a collection of resources with raw data from an HTTP request # # @param [Array] parsed_data # @private def new_collection(parsed_data) instantiate_collection(self, parsed_data) end # Initialize a new object with the "raw" parsed_data from the parsing middleware # # @private def new_from_parsed_data(parsed_data) instantiate_record(self, parsed_data) end # Use setter methods of model for each key / value pair in params # Return key / value pairs for which no setter method was defined on the model # # @note Activeservice won't create attributes automatically # @private def use_setter_methods(model, params) params ||= {} params.inject({}) do |memo, (key, value)| writer = "#{key}=" if model.respond_to?(writer) && (model.has_attribute?(key) || model.has_nested_attributes?(key)) model.send writer, value else key = key.to_sym if key.is_a? String memo[key] = value end memo end end # Returns a mapping of attributes to fields # # ActiveService can map fields from a response to attributes defined on a # model. <tt>attribute_map</tt> translates source fields to their model # attributes and vice-versa during HTTP requests. def attribute_map @attribute_map ||= ActiveService::Model::Attributes::AttributeMap.new(attributes.values) end end end end end
zacharywelch/activeservice
lib/active_service/model/attributes.rb
Ruby
mit
6,526
30.52657
108
0.589795
false
require 'corelib/numeric' require 'corelib/rational/base' class ::Rational < ::Numeric def self.reduce(num, den) num = num.to_i den = den.to_i if den == 0 ::Kernel.raise ::ZeroDivisionError, 'divided by 0' elsif den < 0 num = -num den = -den elsif den == 1 return new(num, den) end gcd = num.gcd(den) new(num / gcd, den / gcd) end def self.convert(num, den) if num.nil? || den.nil? ::Kernel.raise ::TypeError, 'cannot convert nil into Rational' end if ::Integer === num && ::Integer === den return reduce(num, den) end if ::Float === num || ::String === num || ::Complex === num num = num.to_r end if ::Float === den || ::String === den || ::Complex === den den = den.to_r end if den.equal?(1) && !(::Integer === num) ::Opal.coerce_to!(num, ::Rational, :to_r) elsif ::Numeric === num && ::Numeric === den num / den else reduce(num, den) end end def initialize(num, den) @num = num @den = den end def numerator @num end def denominator @den end def coerce(other) case other when ::Rational [other, self] when ::Integer [other.to_r, self] when ::Float [other, to_f] end end def ==(other) case other when ::Rational @num == other.numerator && @den == other.denominator when ::Integer @num == other && @den == 1 when ::Float to_f == other else other == self end end def <=>(other) case other when ::Rational @num * other.denominator - @den * other.numerator <=> 0 when ::Integer @num - @den * other <=> 0 when ::Float to_f <=> other else __coerced__ :<=>, other end end def +(other) case other when ::Rational num = @num * other.denominator + @den * other.numerator den = @den * other.denominator ::Kernel.Rational(num, den) when ::Integer ::Kernel.Rational(@num + other * @den, @den) when ::Float to_f + other else __coerced__ :+, other end end def -(other) case other when ::Rational num = @num * other.denominator - @den * other.numerator den = @den * other.denominator ::Kernel.Rational(num, den) when ::Integer ::Kernel.Rational(@num - other * @den, @den) when ::Float to_f - other else __coerced__ :-, other end end def *(other) case other when ::Rational num = @num * other.numerator den = @den * other.denominator ::Kernel.Rational(num, den) when ::Integer ::Kernel.Rational(@num * other, @den) when ::Float to_f * other else __coerced__ :*, other end end def /(other) case other when ::Rational num = @num * other.denominator den = @den * other.numerator ::Kernel.Rational(num, den) when ::Integer if other == 0 to_f / 0.0 else ::Kernel.Rational(@num, @den * other) end when ::Float to_f / other else __coerced__ :/, other end end def **(other) case other when ::Integer if self == 0 && other < 0 ::Float::INFINITY elsif other > 0 ::Kernel.Rational(@num**other, @den**other) elsif other < 0 ::Kernel.Rational(@den**-other, @num**-other) else ::Kernel.Rational(1, 1) end when ::Float to_f**other when ::Rational if other == 0 ::Kernel.Rational(1, 1) elsif other.denominator == 1 if other < 0 ::Kernel.Rational(@den**other.numerator.abs, @num**other.numerator.abs) else ::Kernel.Rational(@num**other.numerator, @den**other.numerator) end elsif self == 0 && other < 0 ::Kernel.raise ::ZeroDivisionError, 'divided by 0' else to_f**other end else __coerced__ :**, other end end def abs ::Kernel.Rational(@num.abs, @den.abs) end def ceil(precision = 0) if precision == 0 (-(-@num / @den)).ceil else with_precision(:ceil, precision) end end def floor(precision = 0) if precision == 0 (-(-@num / @den)).floor else with_precision(:floor, precision) end end def hash "Rational:#{@num}:#{@den}" end def inspect "(#{self})" end def rationalize(eps = undefined) %x{ if (arguments.length > 1) { #{::Kernel.raise ::ArgumentError, "wrong number of arguments (#{`arguments.length`} for 0..1)"}; } if (eps == null) { return self; } var e = #{eps.abs}, a = #{self - `e`}, b = #{self + `e`}; var p0 = 0, p1 = 1, q0 = 1, q1 = 0, p2, q2; var c, k, t; while (true) { c = #{`a`.ceil}; if (#{`c` <= `b`}) { break; } k = c - 1; p2 = k * p1 + p0; q2 = k * q1 + q0; t = #{1 / (`b` - `k`)}; b = #{1 / (`a` - `k`)}; a = t; p0 = p1; q0 = q1; p1 = p2; q1 = q2; } return #{::Kernel.Rational(`c * p1 + p0`, `c * q1 + q0`)}; } end def round(precision = 0) return with_precision(:round, precision) unless precision == 0 return 0 if @num == 0 return @num if @den == 1 num = @num.abs * 2 + @den den = @den * 2 approx = (num / den).truncate if @num < 0 -approx else approx end end def to_f @num / @den end def to_i truncate end def to_r self end def to_s "#{@num}/#{@den}" end def truncate(precision = 0) if precision == 0 @num < 0 ? ceil : floor else with_precision(:truncate, precision) end end def with_precision(method, precision) ::Kernel.raise ::TypeError, 'not an Integer' unless ::Integer === precision p = 10**precision s = self * p if precision < 1 (s.send(method) / p).to_i else ::Kernel.Rational(s.send(method), p) end end def self.from_string(string) %x{ var str = string.trimLeft(), re = /^[+-]?[\d_]+(\.[\d_]+)?/, match = str.match(re), numerator, denominator; function isFloat() { return re.test(str); } function cutFloat() { var match = str.match(re); var number = match[0]; str = str.slice(number.length); return number.replace(/_/g, ''); } if (isFloat()) { numerator = parseFloat(cutFloat()); if (str[0] === '/') { // rational real part str = str.slice(1); if (isFloat()) { denominator = parseFloat(cutFloat()); return #{::Kernel.Rational(`numerator`, `denominator`)}; } else { return #{::Kernel.Rational(`numerator`, 1)}; } } else { return #{::Kernel.Rational(`numerator`, 1)}; } } else { return #{::Kernel.Rational(0, 1)}; } } end alias divide / alias quo / end
opal/opal
opal/corelib/rational.rb
Ruby
mit
7,210
17.346056
104
0.495562
false
using System; using System.Collections.Generic; using System.Text; using System.Diagnostics; using Microsoft.Xna.Framework; using Microsoft.Xna.Framework.Input; using Anarian.Interfaces; using Anarian.Events; namespace Anarian.DataStructures.Input { public class Controller : IUpdatable { PlayerIndex m_playerIndex; GamePadType m_gamePadType; GamePadCapabilities m_gamePadCapabilities; GamePadState m_gamePadState; GamePadState m_prevGamePadState; bool m_isConnected; public PlayerIndex PlayerIndex { get { return m_playerIndex; } } public GamePadType GamePadType { get { return m_gamePadType; } } public GamePadCapabilities GamePadCapabilities { get { return m_gamePadCapabilities; } } public GamePadState GamePadState { get { return m_gamePadState; } } public GamePadState PrevGamePadState { get { return m_prevGamePadState; } } public bool IsConnected { get { return m_isConnected; } } public Controller(PlayerIndex playerIndex) { m_playerIndex = playerIndex; Reset(); } public void Reset() { m_gamePadCapabilities = GamePad.GetCapabilities(m_playerIndex); m_gamePadType = m_gamePadCapabilities.GamePadType; m_gamePadState = GamePad.GetState(m_playerIndex); m_prevGamePadState = m_gamePadState; m_isConnected = m_gamePadState.IsConnected; } #region Interface Implimentations void IUpdatable.Update(GameTime gameTime) { Update(gameTime); } #endregion public void Update(GameTime gameTime) { //if (!m_isConnected) return; // Get the States m_prevGamePadState = m_gamePadState; m_gamePadState = GamePad.GetState(m_playerIndex); // Update if it is connected or not m_isConnected = m_gamePadState.IsConnected; #region Preform Events if (GamePadDown != null) { if (IsButtonDown(Buttons.A)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.A, PlayerIndex)); } if (IsButtonDown(Buttons.B)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.B, PlayerIndex)); } if (IsButtonDown(Buttons.X)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.X, PlayerIndex)); } if (IsButtonDown(Buttons.Y)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.Y, PlayerIndex)); } if (IsButtonDown(Buttons.LeftShoulder)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.LeftShoulder, PlayerIndex)); } if (IsButtonDown(Buttons.RightShoulder)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.RightShoulder, PlayerIndex)); } if (IsButtonDown(Buttons.LeftStick)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.LeftStick, PlayerIndex)); } if (IsButtonDown(Buttons.RightStick)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.RightStick, PlayerIndex)); } if (IsButtonDown(Buttons.DPadUp)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.DPadUp, PlayerIndex)); } if (IsButtonDown(Buttons.DPadDown)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.DPadDown, PlayerIndex)); } if (IsButtonDown(Buttons.DPadLeft)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.DPadLeft, PlayerIndex)); } if (IsButtonDown(Buttons.DPadRight)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.DPadRight, PlayerIndex)); } } if (GamePadClicked != null) { if (ButtonPressed(Buttons.A)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.A, PlayerIndex)); } if (ButtonPressed(Buttons.B)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.B, PlayerIndex)); } if (ButtonPressed(Buttons.X)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.X, PlayerIndex)); } if (ButtonPressed(Buttons.Y)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.Y, PlayerIndex)); } if (ButtonPressed(Buttons.LeftShoulder)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.LeftShoulder, PlayerIndex)); } if (ButtonPressed(Buttons.RightShoulder)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.RightShoulder, PlayerIndex)); } if (ButtonPressed(Buttons.LeftStick)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.LeftStick, PlayerIndex)); } if (ButtonPressed(Buttons.RightStick)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.RightStick, PlayerIndex)); } if (ButtonPressed(Buttons.DPadUp)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.DPadUp, PlayerIndex)); } if (ButtonPressed(Buttons.DPadDown)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.DPadDown, PlayerIndex)); } if (ButtonPressed(Buttons.DPadLeft)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.DPadLeft, PlayerIndex)); } if (ButtonPressed(Buttons.DPadRight)) { GamePadClicked(this, new GamePadPressedEventArgs(gameTime, Buttons.DPadRight, PlayerIndex)); } } if (GamePadMoved != null) { if (HasLeftThumbstickMoved()) { GamePadMoved(this, new GamePadMovedEventsArgs( gameTime, Buttons.LeftStick, PlayerIndex, m_gamePadState.ThumbSticks.Left, m_prevGamePadState.ThumbSticks.Left - m_gamePadState.ThumbSticks.Left) ); } if (HasRightThumbstickMoved()) { GamePadMoved(this, new GamePadMovedEventsArgs( gameTime, Buttons.RightStick, PlayerIndex, m_gamePadState.ThumbSticks.Right, m_prevGamePadState.ThumbSticks.Right - m_gamePadState.ThumbSticks.Right) ); } if (HasLeftTriggerMoved()) { GamePadMoved(this, new GamePadMovedEventsArgs( gameTime, Buttons.LeftTrigger, PlayerIndex, new Vector2(0.0f, m_gamePadState.Triggers.Left), new Vector2(0.0f, m_prevGamePadState.Triggers.Left) - new Vector2(0.0f, m_gamePadState.Triggers.Left)) ); } if (HasRightTriggerMoved()) { GamePadMoved(this, new GamePadMovedEventsArgs( gameTime, Buttons.RightTrigger, PlayerIndex, new Vector2(0.0f, m_gamePadState.Triggers.Right), new Vector2(0.0f, m_prevGamePadState.Triggers.Right) - new Vector2(0.0f, m_gamePadState.Triggers.Right)) ); } } #endregion } #region Helper Methods public bool ButtonPressed(Buttons button) { if (m_prevGamePadState.IsButtonDown(button) == true && m_gamePadState.IsButtonUp(button) == true) return true; return false; } public bool IsButtonDown(Buttons button) { return m_gamePadState.IsButtonDown(button); } public bool IsButtonUp(Buttons button) { return m_gamePadState.IsButtonUp(button); } public void SetVibration(float leftMotor, float rightMotor) { GamePad.SetVibration(m_playerIndex, leftMotor, rightMotor); } #region Thumbsticks public bool HasLeftThumbstickMoved() { if (m_gamePadState.ThumbSticks.Left == Vector2.Zero) return false; return true; } public bool HasRightThumbstickMoved() { if (m_gamePadState.ThumbSticks.Right == Vector2.Zero) return false; return true; } #endregion #region Triggers public bool HasLeftTriggerMoved() { if (m_gamePadState.Triggers.Left == 0.0f) return false; return true; } public bool HasRightTriggerMoved() { if (m_gamePadState.Triggers.Right == 0.0f) return false; return true; } #endregion public bool HasInputChanged(bool ignoreThumbsticks) { if ((m_gamePadState.IsConnected) && (m_gamePadState.PacketNumber != m_prevGamePadState.PacketNumber)) { //ignore thumbstick movement if ((ignoreThumbsticks == true) && ((m_gamePadState.ThumbSticks.Left.Length() != m_prevGamePadState.ThumbSticks.Left.Length()) && (m_gamePadState.ThumbSticks.Right.Length() != m_prevGamePadState.ThumbSticks.Right.Length()))) return false; return true; } return false; } #endregion #region Events public static event GamePadDownEventHandler GamePadDown; public static event GamePadPressedEventHandler GamePadClicked; public static event GamePadMovedEventHandler GamePadMoved; #endregion } }
KillerrinStudios/Anarian-Game-Engine-MonoGame
Anarian Game Engine.Shared/DataStructures/Input/Controller.cs
C#
mit
10,322
46.557604
240
0.585078
false
package api2go import ( "context" "time" ) // APIContextAllocatorFunc to allow custom context implementations type APIContextAllocatorFunc func(*API) APIContexter // APIContexter embedding context.Context and requesting two helper functions type APIContexter interface { context.Context Set(key string, value interface{}) Get(key string) (interface{}, bool) Reset() } // APIContext api2go context for handlers, nil implementations related to Deadline and Done. type APIContext struct { keys map[string]interface{} } // Set a string key value in the context func (c *APIContext) Set(key string, value interface{}) { if c.keys == nil { c.keys = make(map[string]interface{}) } c.keys[key] = value } // Get a key value from the context func (c *APIContext) Get(key string) (value interface{}, exists bool) { if c.keys != nil { value, exists = c.keys[key] } return } // Reset resets all values on Context, making it safe to reuse func (c *APIContext) Reset() { c.keys = nil } // Deadline implements net/context func (c *APIContext) Deadline() (deadline time.Time, ok bool) { return } // Done implements net/context func (c *APIContext) Done() <-chan struct{} { return nil } // Err implements net/context func (c *APIContext) Err() error { return nil } // Value implements net/context func (c *APIContext) Value(key interface{}) interface{} { if keyAsString, ok := key.(string); ok { val, _ := c.Get(keyAsString) return val } return nil } // Compile time check var _ APIContexter = &APIContext{} // ContextQueryParams fetches the QueryParams if Set func ContextQueryParams(c *APIContext) map[string][]string { qp, ok := c.Get("QueryParams") if ok == false { qp = make(map[string][]string) c.Set("QueryParams", qp) } return qp.(map[string][]string) }
manyminds/api2go
context.go
GO
mit
1,793
21.4125
92
0.707195
false
/************************** GENERAL ***************************/ body { background-color: #151515; color: #999; } a { text-decoration: none; color: #4db8ff; } #wrapper { max-width: 940px; margin: 0 auto; padding: 0 5%; } img { max-width: 100%; } h3{ margin: 0 0 1em 0; } /************************** HEADING ***************************/ header { font-family: 'Courgette', cursive; background: #009688; float: left; margin: 0 0 30px 0; padding: 5px 0 0 0; width: 100%; height: 80px; } #logo { text-align: center; margin: 0; } h1 { margin: 15px 0; font-size: 1.75em; font-weight: normal; line-height: 0.8em; color: #fff; } /************************** Inicio ***************************/ #texto_inicio { padding-top: 10em; font-family: 'Courgette', cursive; text-align: center; color: #fff; font-weight: 800; letter-spacing: 0.225em; margin: 0 0 1em 0; } #texto_inicio p{ color: #4bad92; margin: 0 0 2em 0; font-size: 100%; text-align: center; } #imagen_inicio{ } /************************** PÁGINA: PORTAFOLIO ***************************/ #gallery { margin: 0; padding: 0; list-style: none; } #gallery li { float: left; width: 45%; margin: 2.5%; background-color: #2E2E2E; color: #bdc3c7; } /*titulo de la galeria */ #gallery li a .titulo_trabajo { margin: 0; padding: 5%; font-size: 0.75em; color: #4bad92; } #gallery li a .parrafo_informacion{ margin: 0; padding: 5%; font-size: 0.75em; color: #E0F8EC; } #gallery li a .habilidades{ padding: 0; } #gallery li a ul .habilidad{ display:inline-block; background-color: #0F6A62; color: #fff; font-size: 0.65em; padding: 0.5em; text-transform: uppercase; width: 4em; border-radius: 40%; } /*Para lo que acompaña nuestras imagenes 3d*/ #gallery li .parrafo_informacion{ margin: 0; padding: 5%; font-size: 0.75em; color: #E0F8EC; } #gallery li .titulo_trabajo { margin: 0; padding: 5%; font-size: 0.75em; color: #4bad92; } #gallery li .titulo_trabajo2 { margin: 0; padding: 5%; font-size: 1em; color: #4bad92; } /* cambio de tamaño para las habilidades mas grandes cambiar el de comunicación en ilustraciones */ #gallery li a ul .habilidad_larga{ display:inline-block; background-color: #0F6A62; color: #fff; padding: 0.5em; text-transform: uppercase; width: 6em; border-radius: 40%; font-size: 0.55em; text-align: center; } /************************** PÁGINA: ACERCA DE ***************************/ .profile-photo { display: block; max-width: 150px; margin: 0 auto 30px; border-radius: 100%; } .profile-logo { display: block; max-width: 150px; margin: 0 auto 30px; border-radius: 100%; } .contact-info a { display: block; min-height: 20px; background-repeat: no-repeat; background-size: 20px 20px; padding: 0 0 0 30px; margin: 0 0 10; } .perfiles_individuales{ padding-top: 50px; } .contact-info li.phone a { background-image: url('../img/phone.png'); } .contact-info li.mail a { background-image: url('../img/mail.png'); } .contact-info li.twitter a { background-image: url('../img/twitter.png'); } /************************** PÁGINA: CONTACTO ***************************/ .contact-info { list-style: none; padding: 0; margin: 0; font-size: 0.9m; } /************************** NAVIGATION ***************************/ nav { } nav ul { list-style: none; margin: 20px 10px; padding: 0; } nav li { display: inline-block; } nav a { font-weight: 800; padding: 15px 10px; } /************************** FOOTER ***************************/ footer { font-size: 0.75em; text-align: center; padding-top: 50px; color: #ccc; clear: both; } .social-icon { width: 20px; height: 20px; margin: 0 5px; } /********************************** CONTACT FORM ***********************************/ .form-control { margin: 5px 0; clear: left; float: left; } form textarea { width: 20em; } /************************** COLORS ***************************/ /* links de navegación */ nav a, nav a:visited { color: #fff; } /* links seleccionados */ nav a.selected, a:hover { color: #4bad92; } header .selected{ color: #4bad92; } /*********************************************** PÁGINA: con texto largo y descripción proyectos ***********************************************/ #parrafo_descripción li { float: left; width: 80%; margin: 2.5%; background-color: #2E2E2E; color: #bdc3c7; list-style:none } /*titulo de la galeria */ .titulo_trabajo { margin: 0; padding: 5%; padding-bottom: 15px; font-size: 1.2em; color: #4bad92; } .parrafo_informacion{ margin: 0; padding: 5%; font-size: 0.9em; color: #E0F8EC; } .load_images { display: block; max-width: 150px; margin: 0 auto 30px; border-radius: 0%; } .load_images2 { display: block; max-width: 90%; margin: 0 auto 30px; border-radius: 0%; }
juanAlvarezM/vrExperiences
css/main.css
CSS
mit
4,980
13.535088
52
0.54668
false
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>fcsl-pcm: Not compatible 👼</title> <link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" /> <link href="../../../../../bootstrap.min.css" rel="stylesheet"> <link href="../../../../../bootstrap-custom.css" rel="stylesheet"> <link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet"> <script src="../../../../../moment.min.js"></script> <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries --> <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script> <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script> <![endif]--> </head> <body> <div class="container"> <div class="navbar navbar-default" role="navigation"> <div class="container-fluid"> <div class="navbar-header"> <a class="navbar-brand" href="../../../../.."><i class="fa fa-lg fa-flag-checkered"></i> Coq bench</a> </div> <div id="navbar" class="collapse navbar-collapse"> <ul class="nav navbar-nav"> <li><a href="../..">clean / released</a></li> <li class="active"><a href="">8.7.1+2 / fcsl-pcm - 1.2.0</a></li> </ul> </div> </div> </div> <div class="article"> <div class="row"> <div class="col-md-12"> <a href="../..">« Up</a> <h1> fcsl-pcm <small> 1.2.0 <span class="label label-info">Not compatible 👼</span> </small> </h1> <p>📅 <em><script>document.write(moment("2022-02-24 14:39:15 +0000", "YYYY-MM-DD HH:mm:ss Z").fromNow());</script> (2022-02-24 14:39:15 UTC)</em><p> <h2>Context</h2> <pre># Packages matching: installed # Name # Installed # Synopsis base-bigarray base base-num base Num library distributed with the OCaml compiler base-threads base base-unix base camlp5 7.14 Preprocessor-pretty-printer of OCaml conf-findutils 1 Virtual package relying on findutils conf-perl 2 Virtual package relying on perl coq 8.7.1+2 Formal proof management system num 0 The Num library for arbitrary-precision integer and rational arithmetic ocaml 4.05.0 The OCaml compiler (virtual package) ocaml-base-compiler 4.05.0 Official 4.05.0 release ocaml-config 1 OCaml Switch Configuration ocamlfind 1.9.3 A library manager for OCaml # opam file: opam-version: &quot;2.0&quot; maintainer: &quot;FCSL &lt;fcsl@software.imdea.org&gt;&quot; homepage: &quot;http://software.imdea.org/fcsl/&quot; bug-reports: &quot;https://github.com/imdea-software/fcsl-pcm/issues&quot; dev-repo: &quot;git+https://github.com/imdea-software/fcsl-pcm.git&quot; license: &quot;Apache-2.0&quot; build: [ make &quot;-j%{jobs}%&quot; ] install: [ make &quot;install&quot; ] depends: [ &quot;coq&quot; {(&gt;= &quot;8.10&quot; &amp; &lt; &quot;8.13~&quot;) | (= &quot;dev&quot;)} &quot;coq-mathcomp-ssreflect&quot; {(&gt;= &quot;1.10.0&quot; &amp; &lt; &quot;1.12~&quot;) | (= &quot;dev&quot;)} ] tags: [ &quot;keyword:separation logic&quot; &quot;keyword:partial commutative monoid&quot; &quot;category:Computer Science/Data Types and Data Structures&quot; &quot;logpath:fcsl&quot; &quot;date:2019-11-07&quot; ] authors: [ &quot;Aleksandar Nanevski&quot; ] synopsis: &quot;Partial Commutative Monoids&quot; description: &quot;&quot;&quot; The PCM library provides a formalisation of Partial Commutative Monoids (PCMs), a common algebraic structure used in separation logic for verification of pointer-manipulating sequential and concurrent programs. The library provides lemmas for mechanised and automated reasoning about PCMs in the abstract, but also supports concrete common PCM instances, such as heaps, histories and mutexes. This library relies on extensionality axioms: propositional and functional extentionality.&quot;&quot;&quot; url { src: &quot;https://github.com/imdea-software/fcsl-pcm/archive/v1.2.0.tar.gz&quot; checksum: &quot;sha256=5faabb3660fa7d9fe83d6947621ac34dc20076e28bcd9e87b46edb62154fd4e8&quot; } </pre> <h2>Lint</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Dry install 🏜️</h2> <p>Dry install with the current Coq version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam install -y --show-action coq-fcsl-pcm.1.2.0 coq.8.7.1+2</code></dd> <dt>Return code</dt> <dd>5120</dd> <dt>Output</dt> <dd><pre>[NOTE] Package coq is already installed (current version is 8.7.1+2). The following dependencies couldn&#39;t be met: - coq-fcsl-pcm -&gt; coq &gt;= dev no matching version Your request can&#39;t be satisfied: - No available version of coq satisfies the constraints No solution found, exiting </pre></dd> </dl> <p>Dry install without Coq/switch base, to test if the problem was incompatibility with the current Coq/OCaml version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam remove -y coq; opam install -y --show-action --unlock-base coq-fcsl-pcm.1.2.0</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Install dependencies</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>0 s</dd> </dl> <h2>Install 🚀</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>0 s</dd> </dl> <h2>Installation size</h2> <p>No files were installed.</p> <h2>Uninstall 🧹</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Missing removes</dt> <dd> none </dd> <dt>Wrong removes</dt> <dd> none </dd> </dl> </div> </div> </div> <hr/> <div class="footer"> <p class="text-center"> Sources are on <a href="https://github.com/coq-bench">GitHub</a> © Guillaume Claret 🐣 </p> </div> </div> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <script src="../../../../../bootstrap.min.js"></script> </body> </html>
coq-bench/coq-bench.github.io
clean/Linux-x86_64-4.05.0-2.0.1/released/8.7.1+2/fcsl-pcm/1.2.0.html
HTML
mit
7,473
40.608939
159
0.558136
false
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <title>relation-algebra: 4 m 10 s</title> <link rel="shortcut icon" type="image/png" href="../../../../../favicon.png" /> <link href="../../../../../bootstrap.min.css" rel="stylesheet"> <link href="../../../../../bootstrap-custom.css" rel="stylesheet"> <link href="//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css" rel="stylesheet"> <script src="../../../../../moment.min.js"></script> <!-- HTML5 Shim and Respond.js IE8 support of HTML5 elements and media queries --> <!-- WARNING: Respond.js doesn't work if you view the page via file:// --> <!--[if lt IE 9]> <script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script> <script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script> <![endif]--> </head> <body> <div class="container"> <div class="navbar navbar-default" role="navigation"> <div class="container-fluid"> <div class="navbar-header"> <a class="navbar-brand" href="../../../../.."><i class="fa fa-lg fa-flag-checkered"></i> Coq bench</a> </div> <div id="navbar" class="collapse navbar-collapse"> <ul class="nav navbar-nav"> <li><a href="../..">clean / released</a></li> <li class="active"><a href="">8.11.2 / relation-algebra - 1.7.3</a></li> </ul> </div> </div> </div> <div class="article"> <div class="row"> <div class="col-md-12"> <a href="../..">« Up</a> <h1> relation-algebra <small> 1.7.3 <span class="label label-success">4 m 10 s</span> </small> </h1> <p><em><script>document.write(moment("2020-09-11 16:27:45 +0000", "YYYY-MM-DD HH:mm:ss Z").fromNow());</script> (2020-09-11 16:27:45 UTC)</em><p> <h2>Context</h2> <pre># Packages matching: installed # Name # Installed # Synopsis base-bigarray base base-num base Num library distributed with the OCaml compiler base-threads base base-unix base conf-findutils 1 Virtual package relying on findutils conf-m4 1 Virtual package relying on m4 coq 8.11.2 Formal proof management system num 0 The Num library for arbitrary-precision integer and rational arithmetic ocaml 4.05.0 The OCaml compiler (virtual package) ocaml-base-compiler 4.05.0 Official 4.05.0 release ocaml-config 1 OCaml Switch Configuration ocamlfind 1.8.1 A library manager for OCaml # opam file: opam-version: &quot;2.0&quot; synopsis: &quot;Relation Algebra and KAT in Coq&quot; maintainer: &quot;Damien Pous &lt;Damien.Pous@ens-lyon.fr&gt;&quot; homepage: &quot;http://perso.ens-lyon.fr/damien.pous/ra/&quot; dev-repo: &quot;git+https://github.com/damien-pous/relation-algebra.git&quot; bug-reports: &quot;https://github.com/damien-pous/relation-algebra/issues&quot; license: &quot;LGPL-3.0-or-later&quot; depends: [ &quot;ocaml&quot; &quot;coq&quot; {&gt;= &quot;8.11&quot; &amp; &lt; &quot;8.12~&quot;} ] depopts: [ &quot;coq-mathcomp-ssreflect&quot; ] build: [ [&quot;sh&quot; &quot;-exc&quot; &quot;./configure --%{coq-mathcomp-ssreflect:enable}%-ssr&quot;] [make &quot;-j%{jobs}%&quot;] ] install: [make &quot;install&quot;] tags: [ &quot;keyword:relation algebra&quot; &quot;keyword:kleene algebra with tests&quot; &quot;keyword:kat&quot; &quot;keyword:allegories&quot; &quot;keyword:residuated structures&quot; &quot;keyword:automata&quot; &quot;keyword:regular expressions&quot; &quot;keyword:matrices&quot; &quot;category:Mathematics/Algebra&quot; &quot;logpath:RelationAlgebra&quot; ] authors: [ &quot;Damien Pous &lt;Damien.Pous@ens-lyon.fr&gt;&quot; &quot;Christian Doczkal &lt;christian.doczkal@ens-lyon.fr&gt;&quot; ] url { src: &quot;https://github.com/damien-pous/relation-algebra/archive/v1.7.3.tar.gz&quot; checksum: &quot;md5=69c916214840e742d3a78d6d3cb55a1c&quot; } </pre> <h2>Lint</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Dry install</h2> <p>Dry install with the current Coq version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam install -y --show-action coq-relation-algebra.1.7.3 coq.8.11.2</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <p>Dry install without Coq/switch base, to test if the problem was incompatibility with the current Coq/OCaml version:</p> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>true</code></dd> <dt>Return code</dt> <dd>0</dd> </dl> <h2>Install dependencies</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam list; echo; ulimit -Sv 4000000; timeout 2h opam install -y --deps-only coq-relation-algebra.1.7.3 coq.8.11.2</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>4 s</dd> </dl> <h2>Install</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam list; echo; ulimit -Sv 16000000; timeout 2h opam install -y -v coq-relation-algebra.1.7.3 coq.8.11.2</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Duration</dt> <dd>4 m 10 s</dd> </dl> <h2>Installation size</h2> <p>Total: 8 M</p> <ul> <li>395 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/normalisation.vo</code></li> <li>374 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/untyping.vo</code></li> <li>348 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_completeness.vo</code></li> <li>339 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_completeness.glob</code></li> <li>268 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/paterson.vo</code></li> <li>217 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/compiler_opts.vo</code></li> <li>194 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/matrix.glob</code></li> <li>188 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/relalg.vo</code></li> <li>185 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/monoid.vo</code></li> <li>168 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/matrix.vo</code></li> <li>164 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/paterson.glob</code></li> <li>163 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_reification.cmxs</code></li> <li>157 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/traces.vo</code></li> <li>149 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_common.cmxs</code></li> <li>138 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/normalisation.glob</code></li> <li>136 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/syntax.vo</code></li> <li>125 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/monoid.glob</code></li> <li>123 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/regex.vo</code></li> <li>121 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lattice.vo</code></li> <li>114 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/regex.glob</code></li> <li>112 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/relalg.glob</code></li> <li>111 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/untyping.glob</code></li> <li>105 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/atoms.glob</code></li> <li>100 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ka_completeness.glob</code></li> <li>99 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ugregex_dec.vo</code></li> <li>96 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lattice.glob</code></li> <li>89 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ka_completeness.vo</code></li> <li>89 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/rmx.vo</code></li> <li>85 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_fold.cmxs</code></li> <li>78 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/traces.glob</code></li> <li>77 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_reification.cmxs</code></li> <li>76 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ugregex_dec.glob</code></li> <li>76 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/matrix_ext.glob</code></li> <li>75 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/imp.vo</code></li> <li>74 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/compiler_opts.glob</code></li> <li>66 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/matrix_ext.vo</code></li> <li>65 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ordinal.vo</code></li> <li>65 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/gregex.vo</code></li> <li>61 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/rmx.glob</code></li> <li>59 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_reification.vo</code></li> <li>57 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kleene.glob</code></li> <li>56 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/nfa.vo</code></li> <li>56 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/sups.vo</code></li> <li>55 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ugregex.vo</code></li> <li>53 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kleene.vo</code></li> <li>50 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_tac.vo</code></li> <li>49 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/syntax.glob</code></li> <li>48 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/mrewrite.cmxs</code></li> <li>48 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ordinal.glob</code></li> <li>48 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/move.vo</code></li> <li>47 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/comparisons.vo</code></li> <li>47 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/atoms.vo</code></li> <li>46 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lang.vo</code></li> <li>44 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/level.vo</code></li> <li>42 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ugregex.glob</code></li> <li>40 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/rel.vo</code></li> <li>40 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/nfa.glob</code></li> <li>39 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/sups.glob</code></li> <li>38 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lsyntax.vo</code></li> <li>37 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/dfa.vo</code></li> <li>36 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/boolean.vo</code></li> <li>35 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/bmx.vo</code></li> <li>34 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_completeness.v</code></li> <li>34 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lset.vo</code></li> <li>33 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/level.glob</code></li> <li>32 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/pair.vo</code></li> <li>32 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/glang.vo</code></li> <li>31 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/imp.glob</code></li> <li>30 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/comparisons.glob</code></li> <li>28 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_reification.glob</code></li> <li>26 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/untyping.v</code></li> <li>26 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/normalisation.v</code></li> <li>25 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/gregex.glob</code></li> <li>25 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_tac.glob</code></li> <li>24 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_untyping.vo</code></li> <li>23 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_common.cmi</code></li> <li>22 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/rewriting.glob</code></li> <li>22 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/traces.v</code></li> <li>22 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/matrix.v</code></li> <li>22 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/rewriting.vo</code></li> <li>22 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/factors.glob</code></li> <li>22 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lattice.v</code></li> <li>21 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/monoid.v</code></li> <li>21 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/factors.vo</code></li> <li>21 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/denum.vo</code></li> <li>21 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/positives.vo</code></li> <li>20 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/dfa.glob</code></li> <li>19 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/paterson.v</code></li> <li>19 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/relalg.v</code></li> <li>18 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat.vo</code></li> <li>18 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/all.vo</code></li> <li>17 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/move.glob</code></li> <li>17 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/bmx.glob</code></li> <li>16 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ka_completeness.v</code></li> <li>16 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lang.glob</code></li> <li>16 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/regex.v</code></li> <li>15 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lsyntax.glob</code></li> <li>15 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/sums.vo</code></li> <li>15 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/syntax.v</code></li> <li>14 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ugregex_dec.v</code></li> <li>14 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/rel.glob</code></li> <li>14 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/common.vo</code></li> <li>13 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/boolean.glob</code></li> <li>13 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ordinal.v</code></li> <li>13 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lset.glob</code></li> <li>12 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_reification.cmi</code></li> <li>12 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_untyping.glob</code></li> <li>12 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/pair.glob</code></li> <li>11 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_common.cmx</code></li> <li>11 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/rmx.v</code></li> <li>11 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/glang.glob</code></li> <li>10 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/powerfix.vo</code></li> <li>9 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_tac.v</code></li> <li>9 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_reification.cmi</code></li> <li>9 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/imp.v</code></li> <li>9 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/matrix_ext.v</code></li> <li>9 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_reification.v</code></li> <li>9 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/mrewrite.cmi</code></li> <li>9 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ugregex.v</code></li> <li>8 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/gregex.v</code></li> <li>8 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/sups.v</code></li> <li>8 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/prop.vo</code></li> <li>8 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/powerfix.glob</code></li> <li>8 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_reification.cmx</code></li> <li>8 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/comparisons.v</code></li> <li>8 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat.glob</code></li> <li>8 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kleene.v</code></li> <li>7 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/denum.glob</code></li> <li>7 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/common.glob</code></li> <li>7 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_reification.cmx</code></li> <li>7 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lang.v</code></li> <li>7 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/atoms.v</code></li> <li>7 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_fold.cmi</code></li> <li>7 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/mrewrite.cmx</code></li> <li>7 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/nfa.v</code></li> <li>7 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lsyntax.v</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/compiler_opts.v</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/level.v</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/rewriting.v</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/rel.v</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/dfa.v</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_fold.cmx</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_reification.cmxa</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/sums.glob</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/positives.glob</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_common.cmxa</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_reification.cmxa</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/ra_fold.cmxa</code></li> <li>6 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/mrewrite.cmxa</code></li> <li>5 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/lset.v</code></li> <li>5 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/glang.v</code></li> <li>4 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/boolean.v</code></li> <li>4 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/bmx.v</code></li> <li>4 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/common.v</code></li> <li>4 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/pair.v</code></li> <li>4 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/move.v</code></li> <li>4 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat.v</code></li> <li>3 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/powerfix.v</code></li> <li>3 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_untyping.v</code></li> <li>3 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/factors.v</code></li> <li>2 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/denum.v</code></li> <li>2 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/positives.v</code></li> <li>2 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/all.glob</code></li> <li>2 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_dec.cmx</code></li> <li>2 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/sums.v</code></li> <li>2 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/prop.v</code></li> <li>2 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/prop.glob</code></li> <li>2 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/kat_dec.cmi</code></li> <li>1 K <code>../ocaml-base-compiler.4.05.0/lib/coq/user-contrib/RelationAlgebra/all.v</code></li> </ul> <h2>Uninstall</h2> <dl class="dl-horizontal"> <dt>Command</dt> <dd><code>opam remove -y coq-relation-algebra.1.7.3</code></dd> <dt>Return code</dt> <dd>0</dd> <dt>Missing removes</dt> <dd> none </dd> <dt>Wrong removes</dt> <dd> none </dd> </dl> </div> </div> </div> <hr/> <div class="footer"> <p class="text-center"> <small>Sources are on <a href="https://github.com/coq-bench">GitHub</a>. © Guillaume Claret.</small> </p> </div> </div> <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.1/jquery.min.js"></script> <script src="../../../../../bootstrap.min.js"></script> </body> </html>
coq-bench/coq-bench.github.io
clean/Linux-x86_64-4.05.0-2.0.6/released/8.11.2/relation-algebra/1.7.3.html
HTML
mit
27,183
78.709677
157
0.620029
false
<!-- HTML header for doxygen 1.8.6--> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=9"/> <meta name="generator" content="Doxygen 1.8.12"/> <title>OpenCV: Member List</title> <link href="../../opencv.ico" rel="shortcut icon" type="image/x-icon" /> <link href="../../tabs.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="../../jquery.js"></script> <script type="text/javascript" src="../../dynsections.js"></script> <link href="../../search/search.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="../../search/searchdata.js"></script> <script type="text/javascript" src="../../search/search.js"></script> <script type="text/x-mathjax-config"> MathJax.Hub.Config({ extensions: ["tex2jax.js", "TeX/AMSmath.js", "TeX/AMSsymbols.js"], jax: ["input/TeX","output/HTML-CSS"], }); //<![CDATA[ MathJax.Hub.Config( { TeX: { Macros: { matTT: [ "\\[ \\left|\\begin{array}{ccc} #1 & #2 & #3\\\\ #4 & #5 & #6\\\\ #7 & #8 & #9 \\end{array}\\right| \\]", 9], fork: ["\\left\\{ \\begin{array}{l l} #1 & \\mbox{#2}\\\\ #3 & \\mbox{#4}\\\\ \\end{array} \\right.", 4], forkthree: ["\\left\\{ \\begin{array}{l l} #1 & \\mbox{#2}\\\\ #3 & \\mbox{#4}\\\\ #5 & \\mbox{#6}\\\\ \\end{array} \\right.", 6], vecthree: ["\\begin{bmatrix} #1\\\\ #2\\\\ #3 \\end{bmatrix}", 3], vecthreethree: ["\\begin{bmatrix} #1 & #2 & #3\\\\ #4 & #5 & #6\\\\ #7 & #8 & #9 \\end{bmatrix}", 9], hdotsfor: ["\\dots", 1], mathbbm: ["\\mathbb{#1}", 1], bordermatrix: ["\\matrix{#1}", 1] } } } ); //]]> </script><script type="text/javascript" src="http://cdn.mathjax.org/mathjax/latest/MathJax.js"></script> <link href="../../doxygen.css" rel="stylesheet" type="text/css" /> <link href="../../stylesheet.css" rel="stylesheet" type="text/css"/> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <!--#include virtual="/google-search.html"--> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td id="projectlogo"><img alt="Logo" src="../../opencv-logo-small.png"/></td> <td style="padding-left: 0.5em;"> <div id="projectname">OpenCV &#160;<span id="projectnumber">3.2.0</span> </div> <div id="projectbrief">Open Source Computer Vision</div> </td> </tr> </tbody> </table> </div> <script type="text/javascript"> //<![CDATA[ function getLabelName(innerHTML) { var str = innerHTML.toLowerCase(); // Replace all '+' with 'p' str = str.split('+').join('p'); // Replace all ' ' with '_' str = str.split(' ').join('_'); // Replace all '#' with 'sharp' str = str.split('#').join('sharp'); // Replace other special characters with 'ascii' + code for (var i = 0; i < str.length; i++) { var charCode = str.charCodeAt(i); if (!(charCode == 95 || (charCode > 96 && charCode < 123) || (charCode > 47 && charCode < 58))) str = str.substr(0, i) + 'ascii' + charCode + str.substr(i + 1); } return str; } function addToggle() { var $getDiv = $('div.newInnerHTML').last(); var buttonName = $getDiv.html(); var label = getLabelName(buttonName.trim()); $getDiv.attr("title", label); $getDiv.hide(); $getDiv = $getDiv.next(); $getDiv.attr("class", "toggleable_div label_" + label); $getDiv.hide(); } //]]> </script> <!-- end header part --> <!-- Generated by Doxygen 1.8.12 --> <script type="text/javascript"> var searchBox = new SearchBox("searchBox", "../../search",false,'Search'); </script> <script type="text/javascript" src="../../menudata.js"></script> <script type="text/javascript" src="../../menu.js"></script> <script type="text/javascript"> $(function() { initMenu('../../',true,false,'search.php','Search'); $(document).ready(function() { init_search(); }); }); </script> <div id="main-nav"></div> <!-- window showing the filter options --> <div id="MSearchSelectWindow" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" onkeydown="return searchBox.OnSearchSelectKey(event)"> </div> <!-- iframe showing the search results (closed by default) --> <div id="MSearchResultsWindow"> <iframe src="javascript:void(0)" frameborder="0" name="MSearchResults" id="MSearchResults"> </iframe> </div> <div id="nav-path" class="navpath"> <ul> <li class="navelem"><a class="el" href="../../d2/d75/namespacecv.html">cv</a></li><li class="navelem"><a class="el" href="../../da/d6d/namespacecv_1_1videostab.html">videostab</a></li><li class="navelem"><a class="el" href="../../de/d24/classcv_1_1videostab_1_1IDenseOptFlowEstimator.html">IDenseOptFlowEstimator</a></li> </ul> </div> </div><!-- top --> <div class="header"> <div class="headertitle"> <div class="title">cv::videostab::IDenseOptFlowEstimator Member List</div> </div> </div><!--header--> <div class="contents"> <p>This is the complete list of members for <a class="el" href="../../de/d24/classcv_1_1videostab_1_1IDenseOptFlowEstimator.html">cv::videostab::IDenseOptFlowEstimator</a>, including all inherited members.</p> <table class="directory"> <tr class="even"><td class="entry"><a class="el" href="../../de/d24/classcv_1_1videostab_1_1IDenseOptFlowEstimator.html#a5e961d8501881347a113d3cb75b52aae">run</a>(InputArray frame0, InputArray frame1, InputOutputArray flowX, InputOutputArray flowY, OutputArray errors)=0</td><td class="entry"><a class="el" href="../../de/d24/classcv_1_1videostab_1_1IDenseOptFlowEstimator.html">cv::videostab::IDenseOptFlowEstimator</a></td><td class="entry"><span class="mlabel">pure virtual</span></td></tr> <tr><td class="entry"><a class="el" href="../../de/d24/classcv_1_1videostab_1_1IDenseOptFlowEstimator.html#aa56059e037f5271640e0a2415bdba994">~IDenseOptFlowEstimator</a>()</td><td class="entry"><a class="el" href="../../de/d24/classcv_1_1videostab_1_1IDenseOptFlowEstimator.html">cv::videostab::IDenseOptFlowEstimator</a></td><td class="entry"><span class="mlabel">virtual</span></td></tr> </table></div><!-- contents --> <!-- HTML footer for doxygen 1.8.6--> <!-- start footer part --> <hr class="footer"/><address class="footer"><small> Generated on Fri Dec 23 2016 13:00:29 for OpenCV by &#160;<a href="http://www.doxygen.org/index.html"> <img class="footer" src="../../doxygen.png" alt="doxygen"/> </a> 1.8.12 </small></address> <script type="text/javascript"> //<![CDATA[ function addButton(label, buttonName) { var b = document.createElement("BUTTON"); b.innerHTML = buttonName; b.setAttribute('class', 'toggleable_button label_' + label); b.onclick = function() { $('.toggleable_button').css({ border: '2px outset', 'border-radius': '4px' }); $('.toggleable_button.label_' + label).css({ border: '2px inset', 'border-radius': '4px' }); $('.toggleable_div').css('display', 'none'); $('.toggleable_div.label_' + label).css('display', 'block'); }; b.style.border = '2px outset'; b.style.borderRadius = '4px'; b.style.margin = '2px'; return b; } function buttonsToAdd($elements, $heading, $type) { if ($elements.length === 0) { $elements = $("" + $type + ":contains(" + $heading.html() + ")").parent().prev("div.newInnerHTML"); } var arr = jQuery.makeArray($elements); var seen = {}; arr.forEach(function(e) { var txt = e.innerHTML; if (!seen[txt]) { $button = addButton(e.title, txt); if (Object.keys(seen).length == 0) { var linebreak1 = document.createElement("br"); var linebreak2 = document.createElement("br"); ($heading).append(linebreak1); ($heading).append(linebreak2); } ($heading).append($button); seen[txt] = true; } }); return; } $("h2").each(function() { $heading = $(this); $smallerHeadings = $(this).nextUntil("h2").filter("h3").add($(this).nextUntil("h2").find("h3")); if ($smallerHeadings.length) { $smallerHeadings.each(function() { var $elements = $(this).nextUntil("h3").filter("div.newInnerHTML"); buttonsToAdd($elements, $(this), "h3"); }); } else { var $elements = $(this).nextUntil("h2").filter("div.newInnerHTML"); buttonsToAdd($elements, $heading, "h2"); } }); $(".toggleable_button").first().click(); var $clickDefault = $('.toggleable_button.label_python').first(); if ($clickDefault.length) { $clickDefault.click(); } $clickDefault = $('.toggleable_button.label_cpp').first(); if ($clickDefault.length) { $clickDefault.click(); } //]]> </script> </body> </html>
lucasbrsa/OpenCV-3.2
docs/3.2/d6/d26/classcv_1_1videostab_1_1IDenseOptFlowEstimator-members.html
HTML
mit
9,021
41.551887
495
0.607361
false
/* HEZahran CSS v1.0 ---------------------------------------------------------- Copyright (c) 2014, HEZahran.com. All rights reserved. Coded and Authored with all the love in the world. Coder: Hashem Zahran @antikano || @hezahran ------------------------------------------------------------*/ /*-- custom fonts ------------------------------------------------------------*/ @import url(http://fonts.googleapis.com/css?family=Fira+Sans:300,400,500,700|Rochester|Roboto:400,300,700); /*-- base ------------------------------------------------------------*/ html, body { height: 100%; width: 100%; margin: 0; padding: 0; } body { font-family: "Roboto", "Helvetica Neue", Helvetica, Arial, sans-serif; font-size: 16px; font-weight: 300; line-height: 1.6; padding-top: 50px; color: #34495e; } h1, h2, h3, h4, h5, h6 { font-family: "Fira Sans", "Helvetica Neue", Helvetica, Arial, sans-serif; font-weight: 300; color: #019875; } blockquote { margin-bottom: 0; } blockquote p { min-height: 115px; } blockquote footer { background: none; text-shadow: 0 0; padding: 0; } section { padding-bottom: 3em; margin-bottom: 0; } a { color: #019875; } footer { padding-top: 3em; padding-bottom: 3em; color: #ecf0f1; text-shadow: 0 -1px 1px rgba(0, 0, 0, 0.2); background-color: #2c3e50; } footer a { color: #34495e; } footer a:hover { color: #049372; } footer .copyright { margin-top: 1.5em; } footer .copyright a { color: #019875; } /*-- macifying ------------------------------------------------------------*/ .btn { font-weight: 300; } .pagination li a, .pagination li span { color: #019875; border-color: #ecf0f1; } .pagination .active a, .pagination .active a:hover, .pagination .active a:focus, .pagination .active span, .pagination .active span:hover, .pagination .active span:focus { background-color: #019875; border-color: #019875; } .pagination .disabled a, .pagination .disabled a:hover, .pagination .disabled a:focus, .pagination .disabled span, .pagination .disabled span:hover, .pagination .disabled span:focus { border-color: #ecf0f1; } .page-header { border-bottom: 1px solid #ecf0f1; } hr { border-top: 1px dotted #ecf0f1; } /*-- scaffolding ------------------------------------------------------------*/ .whitesmoke { background-color: whitesmoke; } .alizarin { color: #e74c3c; } .pumpkin { color: #d35400; } .cursive { font-family: "Rochester", cursive; font-style: normal; } .teaser { padding-top: 3em; margin-bottom: 0px; } .teaser h3 { margin: 0; line-height: 1.9em; } /*-- buttons ------------------------------------------------------------*/ .btn-outline { color: #019875; background-color: transparent; border-color: #019875; } .btn-outline:hover, .btn-outline:focus, .btn-outline:active, .btn-outline.active { color: whitesmoke; background-color: #019875; border-color: #019875; } .btn-brand { color: white; background-color: #019875; border-color: #049372; } .btn-brand:hover, .btn-brand:focus, .btn-brand:active { color: white; background-color: #2c3e50; border-color: #2c3e50; } .btn-link-brand { color: #019875; background: transparent; } .btn-link-brand:hover, .btn-link-brand:focus, .btn-link-brand:active { color: #049372; } /*-- about elements ------------------------------------------------------------*/ .carousel-indicators { bottom: -40px; } .carousel-indicators li { border-color: #049372; } .carousel-indicators li.active { background-color: #019875; } /*-- intro elements ------------------------------------------------------------*/ .intro { min-height: 100%; background-image: url("../img/personal/hashem_zahran-header_intro.jpg"); background-size: 100%; background-repeat: no-repeat; background-position: top right; } /*-- contact elements ------------------------------------------------------------*/ .form-group { margin-bottom: 0px; } .form-group .help-block { display: block; min-height: 1.5em; margin: 0px !important; font-size: 1em !important; color: #e74c3c; } .form-group .help-block ul { margin-bottom: 0px; list-style: none; } /*-- blog elements ------------------------------------------------------------*/ article h2 a:hover, article h3 a:hover { color: #049372; text-decoration: none; } article img { width: 100%; padding: 4px; -webkit-border-radius: 5px; -moz-border-radius: 5px; -ms-border-radius: 5px; border-radius: 5px; border: 1px solid #ecf0f1; } article pre { background-color: whitesmoke; border-color: #ecf0f1; } .pager li a:hover, .pager li a:focus, .pager li span:hover, .pager li span:focus { background-color: #049372; color: whitesmoke; border-color: #019875; } .post-banner { margin-bottom: 1em; } /*-- project & portfolio elements ------------------------------------------------------------*/ #portfolio-grid a:hover { text-decoration: none; } #portfolio-grid .mix { display: none; text-align: center; margin-bottom: 20px; } #portfolio-grid .mix img { padding: 0; border: 0; -webkit-box-shadow: 5px 5px 0px #ecf0f1; -moz-box-shadow: 5px 5px 0px #ecf0f1; box-shadow: 5px 5px 0px #ecf0f1; } #portfolio-grid .mix img:hover { opacity: 0.9; } #portfolio-grid .mix h4 { margin-top: 20px; margin-bottom: 0px; } #portfolio-grid .mix p { margin-bottom: 1.5em; } .project { padding-bottom: 48px; } .project h3 { border-top: 1px dotted #ecf0f1; border-bottom: 1px dotted #ecf0f1; padding-top: 20px; padding-bottom: 20px; margin-bottom: 20px; text-align: center; } .project hr { border-style: dotted; } .project img { display: block; height: auto; width: 100%; max-width: 100%; padding: 5px; -webkit-box-shadow: 0px 0px 3px rgba(0, 0, 0, 0.1); -moz-box-shadow: 0px 0px 3px rgba(0, 0, 0, 0.1); box-shadow: 0px 0px 3px rgba(0, 0, 0, 0.1); -webkit-border-radius: 6px; -moz-border-radius: 6px; -ms-border-radius: 6px; border-radius: 6px; } /*-- error pages ------------------------------------------------------------*/ .errorpage { height: 100%; width: 100%; margin-bottom: 0px; background-image: url("../img/personal/hashem_zahran-error.jpg"); background-position: top right; background-repeat: no-repeat; background-size: 100%; } .errorpage .container { padding-top: 100px; } /*-- resume elements ------------------------------------------------------------*/ body { padding-top: 0; font-size: 16px; } main p, footer p { margin: 0; line-height: 3em; } footer { padding: 0; } footer a { color: whitesmoke; } footer a:hover { color: white; text-decoration: none; } .whitesmoke { text-shadow: 0 0; } aside, section { box-shadow: 0 0; padding-bottom: 20px; } .header p { font-size: 2.2em; font-weight: 300; } .teaser p { font-size: 2.1em; font-weight: 300; } .jumbotron { margin-bottom: 0; } .greenhaze { background-color: #019875; color: whitesmoke; } .greenhaze h1 { color: white; } aside address { margin: 0; } .list-group { font-size: 15px; } .list-group .list-group-item { background: #ecf0f1; -webkit-border-radius: 0px; -moz-border-radius: 0px; -ms-border-radius: 0px; border-radius: 0px; border: 0; } .list-group .list-group-item:nth-child(even) { background: whitesmoke; } .skills { padding-left: 20px; } .skills p { margin-bottom: 0px; } .social a { color: #019875; } .social a:hover.facebook { color: #3b5998; } .social a:hover.twitter { color: #00aced; } .social a:hover.linkedin { color: #007bb6; } .social a:hover.instagram { color: #517fa4; } .social a:hover.github { color: #4183C4; } .social a:hover.behance { color: #1769FF; } .progress { background-color: whitesmoke; margin-bottom: 10px; } .progress .progress-bar-brand { background-color: #019875; } /*-- syntax highlighting ------------------------------------------------------------*/ .highlight { background: #fff; } .highlight .c { color: #998; font-style: italic; } .highlight .err { color: #a61717; background-color: #e3d2d2; } .highlight .k { font-weight: bold; } .highlight .o { font-weight: bold; } .highlight .cm { color: #998; font-style: italic; } .highlight .cp { color: #999; font-weight: bold; } .highlight .c1 { color: #998; font-style: italic; } .highlight .cs { color: #999; font-weight: bold; font-style: italic; } .highlight .gd { color: #000; background-color: #fdd; } .highlight .gd .x { color: #000; background-color: #faa; } .highlight .ge { font-style: italic; } .highlight .gr { color: #a00; } .highlight .gh { color: #999; } .highlight .gi { color: #000; background-color: #dfd; } .highlight .gi .x { color: #000; background-color: #afa; } .highlight .go { color: #888; } .highlight .gp { color: #555; } .highlight .gs { font-weight: bold; } .highlight .gu { color: #aaa; } .highlight .gt { color: #a00; } .highlight .kc { font-weight: bold; } .highlight .kd { font-weight: bold; } .highlight .kp { font-weight: bold; } .highlight .kr { font-weight: bold; } .highlight .kt { color: #458; font-weight: bold; } .highlight .m { color: #099; } .highlight .s { color: #d14; } .highlight .na { color: #008080; } .highlight .nb { color: #0086B3; } .highlight .nc { color: #458; font-weight: bold; } .highlight .no { color: #008080; } .highlight .ni { color: #800080; } .highlight .ne { color: #900; font-weight: bold; } .highlight .nf { color: #900; font-weight: bold; } .highlight .nn { color: #555; } .highlight .nt { color: #000080; } .highlight .nv { color: #008080; } .highlight .ow { font-weight: bold; } .highlight .w { color: #bbb; } .highlight .mf { color: #099; } .highlight .mh { color: #099; } .highlight .mi { color: #099; } .highlight .mo { color: #099; } .highlight .sb { color: #d14; } .highlight .sc { color: #d14; } .highlight .sd { color: #d14; } .highlight .s2 { color: #d14; } .highlight .se { color: #d14; } .highlight .sh { color: #d14; } .highlight .si { color: #d14; } .highlight .sx { color: #d14; } .highlight .sr { color: #009926; } .highlight .s1 { color: #d14; } .highlight .ss { color: #990073; } .highlight .bp { color: #999; } .highlight .vc { color: #008080; } .highlight .vg { color: #008080; } .highlight .vi { color: #008080; } .highlight .il { color: #099; }
hezahran/hezahran.github.io
assets/css/resume.css
CSS
mit
10,914
22.073996
107
0.557632
false
Network module for Go (UDP broadcast only) ========================================== See [`main.go`](main.go) for usage example. The code is runnable with just `go run main.go` Features -------- Channel-in/channel-out pairs of (almost) any custom or built-in datatype can be supplied to a pair of transmitter/receiver functions. Data sent to the transmitter function is automatically serialized and broadcasted on the specified port. Any messages received on the receiver's port are deserialized (as long as they match any of the receiver's supplied channel datatypes) and sent on the corresponding channel. See [bcast.Transmitter and bcast.Receiver](network/bcast/bcast.go). Peers on the local network can be detected by supplying your own ID to a transmitter and receiving peer updates (new, current and lost peers) from the receiver. See [peers.Transmitter and peers.Receiver](network/peers/peers.go). Finding your own local IP address can be done with the [LocalIP](network/localip/localip.go) convenience function, but only when you are connected to the internet. *Note: This network module does not work on Windows: Creating proper broadcast sockets on Windows is just not implemented yet in the Go libraries. See issues listed in [the comments here](network/conn/bcast_conn.go) for details.*
Adriabs/heisSquad
Network-go/README.md
Markdown
mit
1,310
67.947368
480
0.762595
false
// // ISNetworkingResponse.h // InventorySystemForiPhone // // Created by yangboshan on 16/4/28. // Copyright © 2016年 yangboshan. All rights reserved. // #import <Foundation/Foundation.h> #import "ISNetworkingConfiguration.h" @interface ISNetworkingResponse : NSObject @property (nonatomic, assign, readonly) ISURLResponseStatus status; @property (nonatomic, copy, readonly) NSString *contentString; @property (nonatomic, readonly) id content; @property (nonatomic, assign, readonly) NSInteger requestId; @property (nonatomic, copy, readonly) NSURLRequest *request; @property (nonatomic, copy, readonly) NSData *responseData; @property (nonatomic, copy) NSDictionary *requestParams; @property (nonatomic, assign, readonly) BOOL isCache; /** * * * @param responseString * @param requestId * @param request * @param responseData * @param status * * @return */ - (instancetype)initWithResponseString:(NSString *)responseString requestId:(NSNumber *)requestId request:(NSURLRequest *)request responseData:(NSData *)responseData status:(ISURLResponseStatus)status; /** * * * @param responseString * @param requestId * @param request * @param responseData * @param error * * @return */ - (instancetype)initWithResponseString:(NSString *)responseString requestId:(NSNumber *)requestId request:(NSURLRequest *)request responseData:(NSData *)responseData error:(NSError *)error; /** * 使用initWithData的response,它的isCache是YES,上面两个函数生成的response的isCache是NO * * @param data * * @return */ - (instancetype)initWithData:(NSData *)data; @end
yangboshan/InventorySystemForiPhone
InventorySystemForiPhone/Networking/ISNetworkingResponse.h
C
mit
1,617
26.172414
201
0.746827
false
// This file auto generated by plugin for ida pro. Generated code only for x64. Please, dont change manually #pragma once #include <common/common.h> START_ATF_NAMESPACE typedef int (WINAPIV *PSYM_ENUMERATESYMBOLS_CALLBACK)(_SYMBOL_INFO *, unsigned int, void *); END_ATF_NAMESPACE
goodwinxp/Yorozuya
library/ATF/PSYM_ENUMERATESYMBOLS_CALLBACK.hpp
C++
mit
287
30.888889
108
0.756098
false
/* * Copyright (C) 2013 Joseph Mansfield * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the * "Software"), to deal in the Software without restriction, including * without limitation the rights to use, copy, modify, merge, publish, * distribute, sublicense, and/or sell copies of the Software, and to * permit persons to whom the Software is furnished to do so, subject to * the following conditions: * * The above copyright notice and this permission notice shall be included * in all copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. * IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY * CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, * TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE * SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ package uk.co.sftrabbit.stackanswers.fragment; import android.app.Fragment; import android.os.Bundle; import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import uk.co.sftrabbit.stackanswers.R; public class AuthInfoFragment extends Fragment { public AuthInfoFragment() { // Do nothing } @Override public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) { return inflater.inflate(R.layout.authentication_info, container, false); } }
sftrabbit/StackAnswers
src/uk/co/sftrabbit/stackanswers/fragment/AuthInfoFragment.java
Java
mit
1,678
38.023256
74
0.761025
false
# Entity Framwork Guidelines Entity Framework (EF) is the recommended ORM to use these days. There are other options, but most documentation (read: stackoverflow posts) use EF. In EF, you make C# objects to represent your table, use special attributes or naming conventions to tell the EF database generator what tables to make. This is called the "code-first" method. EF has migrations built in, and detects changes to your C# objects usign reflection to generate up/down migrations. ## Connection management The EF main object is the `DbContext`, which has a `DbSet<T>` for each of your model classes. This is the main handle on the database, and everything comes from here. It's doing some result caching, but as with any ORM it's stupid easy to fetch more than you want. Your code changes objects in this context, then at some point you must call `DbContext.SaveChanges` to commit the work to the database. It's kinda like a transaction. Some common errors when you `SaveChanges`: * EF model validation errors * DB constraint violations The `DbContext` is not thread-safe, but should be re-used to take advantage of its result caching. Use Ninject web extensions to create one of these per HTTP request. Ninject can thread these around for you, but sometimes for one-off things or long-lived objects it might make more sense to just instantiate the dbcontext directly. ## Connection strings EF will look in the config file for a connection string named after your context. Use this along with the web publish options in visual studio to re-write config files at publish time to use different databases. This was you can always say `new MyContext()` and have it work, and not need to thread the single dbcontext instance across the universe. ## Model classes * put code-first database models in their own assembly. To generate/run migrations, you just need a compiled assembly and a connection string. If you change the model, you're gonna break some code. If your models and code are in the same assembly, you won't be able to generate a migration until you've fixed or commented out everything. * EF can handle inheritence, so make a `TableBase` with `Id` and `DateEntered` and inherit other classes from there * When making relationships in the model classes, make a `public int FooId {get;set;}` and a `public virtual Foo {get;}`. `FooId` will be the column with the foriegn key, and `Foo` will lazy-load the related object. You can do `public virtual Foo {get;set;}` and achieve a similar database, but some parts of the relation are much easier to deal with if you have direct access to the id - notably dropdowns in editors. * on model classes, adding a `public virtual ICollection<T> Models {get;set;}` will create lazy-loaded accessor for the other side of DB relationships. Initialize these in constructors to avoid errors when working with newly created objects, or implement a lazy initialzed collection, which is some annoying boilerplate * if there's going to be a lot of objects in a virtual collection, establish the relationship on the child by setting the foreign key property and add it to the dbcontext directly. For example: // SELECTs all the votes for the election into the collection, // then queues the INSERT election.Votes.Add(new Vote(){For="Bob"}); // queues the INSERT dbcontext.Votes.Add(new Vote(){For="Bob", ElectionId=election.Id}); ## Migrations * use the `Seed` method to setup things like type tables, admin users, and roles ## Querying * don't use `Contains` in EF5 LINQ queires, that prevents LINQ from caching query plans. See http://msdn.microsoft.com/en-us/data/hh949853.aspx * EF LINQ has a lot of weird constraints, but if you follow them then you'll only select the data you need from DB. Expect to get runtime errors like "we don't know how to do X from a LINQ query" and need to re-write the query. Some common ones: * use parameter-less constructors with the object initializer syntax * don't try to call static methods * can compose a query from multiple lambda expressions, but you probably don't want to try to pass those between methods. The type signature is unholy for the lambda: query.Where(f => f.Name == "bar") * don't pay too much attention to the crazy SQL it generates; it's usually fast enough ##### scratch allow `new DbContext()`, or require it be passed in via a method/constructor argument? `new` is ok when: * no model objects coming in or out of the function - things get hairy if you mix objects from different contexts * we might be a long-lived object that survives multiple HTTP requests, and therefore can't pull the one off the request context * the data we're dealing with probably isn't going to be cached in the per-request context * you're ok with hitting a real db to test this function * we're _always_ setting the connection string via the default name convention with app.config * we're _never_ going to do anything funky with the context that would require ninject * we're _never_ doing things with transactions
AccelerationNet/adwcodebase.net
doc/EF.md
Markdown
mit
5,177
42.141667
78
0.752753
false
Set-StrictMode -Version 2 function Test-SqlServer { <# .SYNOPSIS Tests if a SQL Server exists and can be connected to. Optonally checks for a specific database or table. .PARAMETER Server The SQL Server to test .PARAMETER Database The database to test exists on the SQL Server .PARAMETER Table The Table to test exists in the database being connected #> [CmdletBinding()] param( [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [string]$Server, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [string]$Database, [parameter(Mandatory=$false)] [ValidateNotNullOrEmpty()] [string]$Table ) if ($Database) { $Database = Encode-SqlName $Database } $parts = $Server.Split('\'); $hostName = Encode-SqlName $parts[0]; $instance = if ($parts.Count -eq 1) {'DEFAULT'} else { Encode-SqlName $parts[1] } #Test-Path will only fail after a timeout. Reduce the timeout for the local scope to Set-Variable -Scope Local -Name SqlServerConnectionTimeout 5 $path = "SQLSERVER:\Sql\$hostName\$instance" if (!(Test-Path $path -EA SilentlyContinue)) { throw "Unable to connect to SQL Instance '$Server'" return } elseif ($Database) { $path = Join-Path $path "Databases\$Database" if (!(Test-Path $path -EA SilentlyContinue)) { throw "Database '$Database' does not exist on server '$Server'" return } elseif($Table) { $parts = $Table.Split('.'); if ($parts.Count -eq 1) { $Table = "dbo.$Table" } $path = Join-Path $path "Tables\$Table" if (!(Test-Path $path -EA SilentlyContinue)) { throw "Table '$Table' does not exist in database '$Database' does not exist on server '$Server'" return } } } $true } function New-TelligentDatabase { <# .SYNOPSIS Creates a new database for Telligent Community. .PARAMETER Server The SQL server to install the community to .PARAMETER Database The name of the database to install the community to .PARAMETER Package The installation package to create the community database from .PARAMETER WebDomain The domain the community is being hosted at .PARAMETER AdminPassword The password to create the admin user with. #> [CmdletBinding()] param( [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [ValidateScript({ Test-SqlServer $_ })] [alias('ServerInstance')] [alias('DataSource')] [alias('dbServer')] [string]$Server, [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [alias('dbName')] [alias('InitialCatalog')] [string]$Database, [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [ValidateScript({Test-Zip $_ })] [string]$Package, [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [string]$WebDomain, [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [string]$AdminPassword, [parameter(Mandatory=$true)] [switch]$Legacy ) $connectionInfo = @{ ServerInstance = $Server Database = $database } Write-Progress "Database: $Database" 'Checking if database exists' if(!(Test-SqlServer -Server $Server -Database $Database -EA SilentlyContinue)) { Write-Progress "Database: $Database" 'Creating database' New-Database @connectionInfo } else { Write-Warning "Database $Database already exists." } Write-Progress "Database: $Database" 'Checking if schema exists' if(!(Test-SqlServer -Server $Server -Database $Database -Table 'cs_SchemaVersion' -ErrorAction SilentlyContinue)) { Write-Progress "Database: $database" 'Creating Schema' $tempDir = Join-Path ([System.IO.Path]::GetFullPath($env:TEMP)) ([guid]::NewGuid()) Expand-Zip -Path $package -Destination $tempDir -ZipDirectory SqlScripts $sqlScript = @('Install.sql', 'cs_CreateFullDatabase.sql') | ForEach-Object { Join-Path $tempDir $_ }| Where-Object { Test-Path $_} | Select-Object -First 1 Write-ProgressFromVerbose "Database: $database" 'Creating Schema' { Invoke-Sqlcmd @connectionInfo -InputFile $sqlScript -QueryTimeout 6000 -DisableVariables } Remove-Item $tempDir -Recurse -Force | out-null if($Legacy) { $createCommunityQuery = @" EXECUTE [dbo].[cs_system_CreateCommunity] @SiteUrl = N'http://${WebDomain}/' , @ApplicationName = N'$Name' , @AdminEmail = N'notset@${WebDomain}' , @AdminUserName = N'admin' , @AdminPassword = N'$adminPassword' , @PasswordFormat = 0 , @CreateSamples = 0 "@ } else { $createCommunityQuery = @" EXECUTE [dbo].[cs_system_CreateCommunity] @ApplicationName = N'$Name' , @AdminEmail = N'notset@${WebDomain}' , @AdminUserName = N'admin' , @AdminPassword = N'$adminPassword' , @PasswordFormat = 0 , @CreateSamples = 0 "@ } Write-ProgressFromVerbose "Database: $database" 'Creating Community' { Invoke-Sqlcmd @connectionInfo -query $createCommunityQuery -DisableVariables } } } function Update-TelligentDatabase { <# .SYNOPSIS Updates an existing Telligent Community database to upgrade it to the version in the package .PARAMETER Server The SQL server to install the community to .PARAMETER Database The name of the database to install the community to .PARAMETER Package The installation package to create the community database from #> [CmdletBinding()] param( [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [ValidateScript({ Test-SqlServer $_ })] [alias('ServerInstance')] [alias('DataSource')] [alias('dbServer')] [string]$Server, [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [alias('dbName')] [alias('InitialCatalog')] [string]$Database, [parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [ValidateScript({Test-Zip $_ })] [string]$Package ) $connectionInfo = @{ Server = $Server Database = $Database } Write-Progress "Database: $Database" 'Checking if database can be upgraded' if(!(Test-SqlServer @connectionInfo -Table dbo.cs_schemaversion -EA SilentlyContinue)) { throw "Database '$Database' on Server '$Server' is not a valid Telligent Community database to be upgraded" } Write-Progress "Database: $database" 'Creating Schema' $tempDir = Join-Path ([System.IO.Path]::GetFullPath($env:TEMP)) ([guid]::NewGuid()) Expand-Zip -Path $package -Destination $tempDir -ZipDirectory SqlScripts $sqlScript = @('Upgrade.sql', 'cs_UpdateSchemaAndProcedures.sql') | ForEach-Object { Join-Path $tempDir $_ }| Where-Object { Test-Path $_} | Select-Object -First 1 Write-ProgressFromVerbose "Database: $Database" 'Upgrading Schema' { Invoke-Sqlcmd @connectionInfo -InputFile $sqlScript -QueryTimeout 6000 -DisableVariables } Remove-Item $tempDir -Recurse -Force | out-null } function Grant-TelligentDatabaseAccess { <# .SYNOPSIS Grants a user access to a Telligent Community database. If the user or login doesn't exist, in SQL server, they are created before being granted access to the database. .PARAMETER CommunityPath The path to the Telligent Community you're granting database access for .PARAMETER Username The name of the user to grant access to. If no password is specified, the user is assumed to be a Windows login. .PARAMETER Password The password for the SQL user .EXAMPLE Grant-TelligentDatabaseAccess (local)\SqlExpress SampleCommunity 'NT AUTHORITY\NETWORK SERVICE' Description ----------- This command grant access to the SampleCommunity database on the SqlExpress instance of the local SQL server for the Network Service Windows account .EXAMPLE Grant-TelligentDatabaseAccess ServerName SampleCommunity CommunityUser -password SqlPa$$w0rd Description ----------- This command grant access to the SampleCommunity database on the default instance of the ServerName SQL server for the CommunityUser SQL account. If this login does not exist, it gets created using the password SqlPa$$w0rd #> [CmdletBinding()] param( [Parameter(Mandatory=$true)] [ValidateNotNullOrEmpty()] [ValidateScript({ Test-TelligentPath $_ })] [string]$CommunityPath, [parameter(Mandatory=$true, Position = 2)] [ValidateNotNullOrEmpty()] [string]$Username, [string]$Password ) $info = Get-TelligentCommunity $CommunityPath #TODO: Sanatise inputs Write-Verbose "Granting database access to $Username" if ($Password) { $CreateLogin = "CREATE LOGIN [$Username] WITH PASSWORD=N'$Password', DEFAULT_DATABASE=[$($info.DatabaseName)];" } else { $CreateLogin = "CREATE LOGIN [$Username] FROM WINDOWS WITH DEFAULT_DATABASE=[$($info.DatabaseName)];" } $query = @" IF NOT EXISTS (SELECT 1 FROM master.sys.server_principals WHERE name = N'$Username') BEGIN $CreateLogin END; IF NOT EXISTS (SELECT 1 FROM sys.database_principals WHERE name = N'$Username') BEGIN CREATE USER [$Username] FOR LOGIN [$Username]; END; EXEC sp_addrolemember N'aspnet_Membership_FullAccess', N'$Username'; EXEC sp_addrolemember N'aspnet_Profile_FullAccess', N'$Username'; EXEC sp_addrolemember N'db_datareader', N'$Username'; EXEC sp_addrolemember N'db_datawriter', N'$Username'; EXEC sp_addrolemember N'db_ddladmin', N'$Username'; "@ Invoke-TelligentSqlCmd -WebsitePath $CommunityPath -Query $query } function Invoke-TelligentSqlCmd { <# .SYNOPSIS Executes a SQL Script agains the specified community's database. .PARAMETER WebsitePath The path of the Telligent Community website. If not specified, defaults to the current directory. .PARAMETER Query A bespoke query to run agains the community's database. .PARAMETER File A script in an external file run agains the community's database. .PARAMETER QueryTimeout The maximum length of time the query can run for #> param ( [Parameter(Mandatory=$true, Position=0)] [ValidateScript({ Test-TelligentPath $_ -Web })] [string]$WebsitePath, [Parameter(ParameterSetName='Query', Mandatory=$true)] [string]$Query, [Parameter(ParameterSetName='File', Mandatory=$true)] [ValidateScript({Test-Path $_ -PathType Leaf})] [string]$File, [int]$QueryTimeout ) $info = Get-TelligentCommunity $WebsitePath $sqlParams = @{ ServerInstance = $info.DatabaseServer Database = $info.DatabaseName } if ($Query) { $sqlParams.Query = $Query } else { $sqlParams.InputFile = $File } if ($QueryTimeout) { $sqlParams.QueryTimeout = $QueryTimeout } Invoke-Sqlcmd @sqlParams -DisableVariables } function New-Database { <# .SYNOPSIS Creates a new SQL Database .PARAMETER Database The name of the database to create .PARAMETER Server The server to create the database on #> [CmdletBinding()] param( [parameter(Mandatory=$true, Position=0, ValueFromPipeline=$true)] [ValidateNotNullOrEmpty()] [alias('Database')] [string]$Name, [ValidateNotNullOrEmpty()] [alias('ServerInstance')] [string]$Server = "." ) $query = "Create Database [$Name]"; Invoke-Sqlcmd -ServerInstance $Server -Query $query } function Remove-Database { <# .SYNOPSIS Drops a SQL Database .PARAMETER Database The name of the database to drop .PARAMETER Server The server to drop the database from #> [CmdletBinding()] param( [parameter(Mandatory=$true, Position=0, ValueFromPipeline=$true)] [ValidateNotNullOrEmpty()] [alias('dbName')] [string]$Database, [ValidateNotNullOrEmpty()] [alias('dbServer')] [string]$Server = "." ) $query = @" if DB_ID('$Database') is not null begin exec msdb.dbo.sp_delete_database_backuphistory @database_name = N'$Database' alter database [$Database] set single_user with rollback immediate drop database [$Database] end "@ Invoke-Sqlcmd -ServerInstance $Server -Query $query }
afscrome/TelligentInstanceManager
TelligentInstall/sql.ps1
PowerShell
mit
13,166
32.667519
119
0.627393
false
<!DOCTYPE html> <!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]--> <!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]--> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>bartpy.node &mdash; BartPy 0.0.1 documentation</title> <link rel="stylesheet" href="../../_static/css/theme.css" type="text/css" /> <link rel="stylesheet" href="../../_static/pygments.css" type="text/css" /> <link rel="index" title="Index" href="../../genindex.html" /> <link rel="search" title="Search" href="../../search.html" /> <script src="../../_static/js/modernizr.min.js"></script> </head> <body class="wy-body-for-nav"> <div class="wy-grid-for-nav"> <nav data-toggle="wy-nav-shift" class="wy-nav-side"> <div class="wy-side-scroll"> <div class="wy-side-nav-search"> <a href="../../index.html" class="icon icon-home"> BartPy </a> <div class="version"> 0.0.1 </div> <div role="search"> <form id="rtd-search-form" class="wy-form" action="../../search.html" method="get"> <input type="text" name="q" placeholder="Search docs" /> <input type="hidden" name="check_keywords" value="yes" /> <input type="hidden" name="area" value="default" /> </form> </div> </div> <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation"> <p class="caption"><span class="caption-text">Contents:</span></p> <ul> <li class="toctree-l1"><a class="reference internal" href="../../node.html">Node</a></li> <li class="toctree-l1"><a class="reference internal" href="../../split.html">Split</a></li> <li class="toctree-l1"><a class="reference internal" href="../../tree.html">Tree</a></li> <li class="toctree-l1"><a class="reference internal" href="../../model.html">Model</a></li> <li class="toctree-l1"><a class="reference internal" href="../../sampling.html">Samplers</a></li> </ul> </div> </div> </nav> <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap"> <nav class="wy-nav-top" aria-label="top navigation"> <i data-toggle="wy-nav-top" class="fa fa-bars"></i> <a href="../../index.html">BartPy</a> </nav> <div class="wy-nav-content"> <div class="rst-content"> <div role="navigation" aria-label="breadcrumbs navigation"> <ul class="wy-breadcrumbs"> <li><a href="../../index.html">Docs</a> &raquo;</li> <li><a href="../index.html">Module code</a> &raquo;</li> <li>bartpy.node</li> <li class="wy-breadcrumbs-aside"> </li> </ul> <hr/> </div> <div role="main" class="document" itemscope="itemscope" itemtype="http://schema.org/Article"> <div itemprop="articleBody"> <h1>Source code for bartpy.node</h1><div class="highlight"><pre> <span></span><span class="kn">from</span> <span class="nn">typing</span> <span class="k">import</span> <span class="n">Union</span> <span class="kn">import</span> <span class="nn">numpy</span> <span class="k">as</span> <span class="nn">np</span> <span class="kn">from</span> <span class="nn">bartpy.data</span> <span class="k">import</span> <span class="n">Data</span> <span class="kn">from</span> <span class="nn">bartpy.split</span> <span class="k">import</span> <span class="n">Split</span><span class="p">,</span> <span class="n">SplitCondition</span> <div class="viewcode-block" id="TreeNode"><a class="viewcode-back" href="../../node.html#bartpy.node.TreeNode">[docs]</a><span class="k">class</span> <span class="nc">TreeNode</span><span class="p">:</span> <span class="sd">&quot;&quot;&quot;</span> <span class="sd"> A representation of a node in the Tree</span> <span class="sd"> Contains two main types of information:</span> <span class="sd"> - Data relevant for the node</span> <span class="sd"> - Links to children nodes</span> <span class="sd"> &quot;&quot;&quot;</span> <span class="k">def</span> <span class="nf">__init__</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">split</span><span class="p">:</span> <span class="n">Split</span><span class="p">,</span> <span class="n">depth</span><span class="p">:</span> <span class="nb">int</span><span class="p">,</span> <span class="n">left_child</span><span class="p">:</span> <span class="s1">&#39;TreeNode&#39;</span><span class="o">=</span><span class="kc">None</span><span class="p">,</span> <span class="n">right_child</span><span class="p">:</span> <span class="s1">&#39;TreeNode&#39;</span><span class="o">=</span><span class="kc">None</span><span class="p">):</span> <span class="bp">self</span><span class="o">.</span><span class="n">depth</span> <span class="o">=</span> <span class="n">depth</span> <span class="bp">self</span><span class="o">.</span><span class="n">_split</span> <span class="o">=</span> <span class="n">split</span> <span class="bp">self</span><span class="o">.</span><span class="n">_left_child</span> <span class="o">=</span> <span class="n">left_child</span> <span class="bp">self</span><span class="o">.</span><span class="n">_right_child</span> <span class="o">=</span> <span class="n">right_child</span> <span class="k">def</span> <span class="nf">update_data</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">data</span><span class="p">:</span> <span class="n">Data</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="kc">None</span><span class="p">:</span> <span class="bp">self</span><span class="o">.</span><span class="n">_split</span><span class="o">.</span><span class="n">_data</span> <span class="o">=</span> <span class="n">data</span> <span class="nd">@property</span> <span class="k">def</span> <span class="nf">data</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="n">Data</span><span class="p">:</span> <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">split</span><span class="o">.</span><span class="n">data</span> <span class="nd">@property</span> <span class="k">def</span> <span class="nf">left_child</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="s1">&#39;TreeNode&#39;</span><span class="p">:</span> <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">_left_child</span> <span class="nd">@property</span> <span class="k">def</span> <span class="nf">right_child</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="s1">&#39;TreeNode&#39;</span><span class="p">:</span> <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">_right_child</span> <span class="k">def</span> <span class="nf">is_leaf_node</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="nb">bool</span><span class="p">:</span> <span class="k">return</span> <span class="kc">False</span> <span class="k">def</span> <span class="nf">is_decision_node</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="nb">bool</span><span class="p">:</span> <span class="k">return</span> <span class="kc">False</span> <span class="nd">@property</span> <span class="k">def</span> <span class="nf">split</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span> <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">_split</span> <span class="k">def</span> <span class="nf">update_y</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">y</span><span class="p">):</span> <span class="bp">self</span><span class="o">.</span><span class="n">split</span><span class="o">.</span><span class="n">update_y</span><span class="p">(</span><span class="n">y</span><span class="p">)</span> <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">left_child</span> <span class="ow">is</span> <span class="ow">not</span> <span class="kc">None</span><span class="p">:</span> <span class="bp">self</span><span class="o">.</span><span class="n">left_child</span><span class="o">.</span><span class="n">update_y</span><span class="p">(</span><span class="n">y</span><span class="p">)</span> <span class="bp">self</span><span class="o">.</span><span class="n">right_child</span><span class="o">.</span><span class="n">update_y</span><span class="p">(</span><span class="n">y</span><span class="p">)</span></div> <div class="viewcode-block" id="LeafNode"><a class="viewcode-back" href="../../node.html#bartpy.node.LeafNode">[docs]</a><span class="k">class</span> <span class="nc">LeafNode</span><span class="p">(</span><span class="n">TreeNode</span><span class="p">):</span> <span class="sd">&quot;&quot;&quot;</span> <span class="sd"> A representation of a leaf node in the tree</span> <span class="sd"> In addition to the normal work of a `Node`, a `LeafNode` is responsible for:</span> <span class="sd"> - Interacting with `Data`</span> <span class="sd"> - Making predictions</span> <span class="sd"> &quot;&quot;&quot;</span> <span class="k">def</span> <span class="nf">__init__</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">split</span><span class="p">:</span> <span class="n">Split</span><span class="p">,</span> <span class="n">depth</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span> <span class="bp">self</span><span class="o">.</span><span class="n">_value</span> <span class="o">=</span> <span class="mf">0.0</span> <span class="bp">self</span><span class="o">.</span><span class="n">_residuals</span> <span class="o">=</span> <span class="mf">0.0</span> <span class="bp">self</span><span class="o">.</span><span class="n">_splittable_variables</span> <span class="o">=</span> <span class="kc">None</span> <span class="nb">super</span><span class="p">()</span><span class="o">.</span><span class="fm">__init__</span><span class="p">(</span><span class="n">split</span><span class="p">,</span> <span class="n">depth</span><span class="p">,</span> <span class="kc">None</span><span class="p">,</span> <span class="kc">None</span><span class="p">)</span> <span class="nd">@property</span> <span class="k">def</span> <span class="nf">splittable_variables</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span> <span class="k">if</span> <span class="bp">self</span><span class="o">.</span><span class="n">_splittable_variables</span> <span class="ow">is</span> <span class="kc">None</span><span class="p">:</span> <span class="bp">self</span><span class="o">.</span><span class="n">_splittable_variables</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">split</span><span class="o">.</span><span class="n">data</span><span class="o">.</span><span class="n">splittable_variables</span><span class="p">()</span> <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">_splittable_variables</span> <span class="k">def</span> <span class="nf">set_value</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">value</span><span class="p">:</span> <span class="nb">float</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="kc">None</span><span class="p">:</span> <span class="bp">self</span><span class="o">.</span><span class="n">_value</span> <span class="o">=</span> <span class="n">value</span> <span class="k">def</span> <span class="nf">residuals</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="n">np</span><span class="o">.</span><span class="n">ndarray</span><span class="p">:</span> <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">data</span><span class="o">.</span><span class="n">y</span> <span class="o">-</span> <span class="bp">self</span><span class="o">.</span><span class="n">predict</span><span class="p">()</span> <span class="nd">@property</span> <span class="k">def</span> <span class="nf">current_value</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span> <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">_value</span> <span class="k">def</span> <span class="nf">predict</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="nb">float</span><span class="p">:</span> <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">current_value</span> <span class="k">def</span> <span class="nf">is_splittable</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="nb">bool</span><span class="p">:</span> <span class="k">return</span> <span class="nb">len</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">splittable_variables</span><span class="p">)</span> <span class="o">&gt;</span> <span class="mi">0</span> <span class="k">def</span> <span class="nf">is_leaf_node</span><span class="p">(</span><span class="bp">self</span><span class="p">):</span> <span class="k">return</span> <span class="kc">True</span></div> <div class="viewcode-block" id="DecisionNode"><a class="viewcode-back" href="../../node.html#bartpy.node.DecisionNode">[docs]</a><span class="k">class</span> <span class="nc">DecisionNode</span><span class="p">(</span><span class="n">TreeNode</span><span class="p">):</span> <span class="sd">&quot;&quot;&quot;</span> <span class="sd"> A `DecisionNode` encapsulates internal node in the tree</span> <span class="sd"> Unlike a `LeafNode`, it contains very little actual logic beyond tying the tree together</span> <span class="sd"> &quot;&quot;&quot;</span> <span class="k">def</span> <span class="nf">__init__</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">split</span><span class="p">:</span> <span class="n">Split</span><span class="p">,</span> <span class="n">left_child_node</span><span class="p">:</span> <span class="n">Union</span><span class="p">[</span><span class="n">LeafNode</span><span class="p">,</span> <span class="s1">&#39;DecisionNode&#39;</span><span class="p">],</span> <span class="n">right_child_node</span><span class="p">:</span> <span class="n">Union</span><span class="p">[</span><span class="n">LeafNode</span><span class="p">,</span> <span class="s1">&#39;DecisionNode&#39;</span><span class="p">],</span> <span class="n">depth</span><span class="o">=</span><span class="mi">0</span><span class="p">):</span> <span class="nb">super</span><span class="p">()</span><span class="o">.</span><span class="fm">__init__</span><span class="p">(</span><span class="n">split</span><span class="p">,</span> <span class="n">depth</span><span class="p">,</span> <span class="n">left_child_node</span><span class="p">,</span> <span class="n">right_child_node</span><span class="p">)</span> <span class="k">def</span> <span class="nf">is_prunable</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="nb">bool</span><span class="p">:</span> <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">left_child</span><span class="o">.</span><span class="n">is_leaf_node</span><span class="p">()</span> <span class="ow">and</span> <span class="bp">self</span><span class="o">.</span><span class="n">right_child</span><span class="o">.</span><span class="n">is_leaf_node</span><span class="p">()</span> <span class="k">def</span> <span class="nf">is_decision_node</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="nb">bool</span><span class="p">:</span> <span class="k">return</span> <span class="kc">True</span> <span class="k">def</span> <span class="nf">variable_split_on</span><span class="p">(</span><span class="bp">self</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="n">SplitCondition</span><span class="p">:</span> <span class="k">return</span> <span class="bp">self</span><span class="o">.</span><span class="n">left_child</span><span class="o">.</span><span class="n">split</span><span class="o">.</span><span class="n">most_recent_split_condition</span><span class="p">()</span></div> <div class="viewcode-block" id="split_node"><a class="viewcode-back" href="../../node.html#bartpy.node.split_node">[docs]</a><span class="k">def</span> <span class="nf">split_node</span><span class="p">(</span><span class="n">node</span><span class="p">:</span> <span class="n">LeafNode</span><span class="p">,</span> <span class="n">split_condition</span><span class="p">:</span> <span class="n">SplitCondition</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="n">DecisionNode</span><span class="p">:</span> <span class="sd">&quot;&quot;&quot;</span> <span class="sd"> Converts a `LeafNode` into an internal `DecisionNode` by applying the split condition</span> <span class="sd"> The left node contains all values for the splitting variable less than the splitting value</span> <span class="sd"> &quot;&quot;&quot;</span> <span class="n">left_split</span><span class="p">,</span> <span class="n">right_split</span> <span class="o">=</span> <span class="n">node</span><span class="o">.</span><span class="n">split</span> <span class="o">+</span> <span class="n">split_condition</span> <span class="k">return</span> <span class="n">DecisionNode</span><span class="p">(</span><span class="n">node</span><span class="o">.</span><span class="n">split</span><span class="p">,</span> <span class="n">LeafNode</span><span class="p">(</span><span class="n">left_split</span><span class="p">,</span> <span class="n">depth</span><span class="o">=</span><span class="n">node</span><span class="o">.</span><span class="n">depth</span> <span class="o">+</span> <span class="mi">1</span><span class="p">),</span> <span class="n">LeafNode</span><span class="p">(</span><span class="n">right_split</span><span class="p">,</span> <span class="n">depth</span><span class="o">=</span><span class="n">node</span><span class="o">.</span><span class="n">depth</span> <span class="o">+</span> <span class="mi">1</span><span class="p">),</span> <span class="n">depth</span><span class="o">=</span><span class="n">node</span><span class="o">.</span><span class="n">depth</span><span class="p">)</span></div> </pre></div> </div> </div> <footer> <hr/> <div role="contentinfo"> <p> &copy; Copyright 2018, Jake Coltman. </p> </div> Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/rtfd/sphinx_rtd_theme">theme</a> provided by <a href="https://readthedocs.org">Read the Docs</a>. </footer> </div> </div> </section> </div> <script type="text/javascript"> var DOCUMENTATION_OPTIONS = { URL_ROOT:'../../', VERSION:'0.0.1', LANGUAGE:'None', COLLAPSE_INDEX:false, FILE_SUFFIX:'.html', HAS_SOURCE: true, SOURCELINK_SUFFIX: '.txt' }; </script> <script type="text/javascript" src="../../_static/jquery.js"></script> <script type="text/javascript" src="../../_static/underscore.js"></script> <script type="text/javascript" src="../../_static/doctools.js"></script> <script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.1/MathJax.js?config=TeX-AMS-MML_HTMLorMML"></script> <script type="text/javascript" src="../../_static/js/theme.js"></script> <script type="text/javascript"> jQuery(function () { SphinxRtdTheme.Navigation.enable(true); }); </script> </body> </html>
JakeColtman/bartpy
docs/_modules/bartpy/node.html
HTML
mit
21,467
62.703264
835
0.597941
false
<?php namespace moonland\phpexcel; use yii\helpers\ArrayHelper; use yii\base\InvalidConfigException; use yii\base\InvalidParamException; use yii\i18n\Formatter; use PhpOffice\PhpSpreadsheet\Spreadsheet; /** * Excel Widget for generate Excel File or for load Excel File. * * Usage * ----- * * Exporting data into an excel file. * * ~~~ * * // export data only one worksheet. * * \moonland\phpexcel\Excel::widget([ * 'models' => $allModels, * 'mode' => 'export', //default value as 'export' * 'columns' => ['column1','column2','column3'], * //without header working, because the header will be get label from attribute label. * 'headers' => ['column1' => 'Header Column 1','column2' => 'Header Column 2', 'column3' => 'Header Column 3'], * ]); * * \moonland\phpexcel\Excel::export([ * 'models' => $allModels, * 'columns' => ['column1','column2','column3'], * //without header working, because the header will be get label from attribute label. * 'headers' => ['column1' => 'Header Column 1','column2' => 'Header Column 2', 'column3' => 'Header Column 3'], * ]); * * // export data with multiple worksheet. * * \moonland\phpexcel\Excel::widget([ * 'isMultipleSheet' => true, * 'models' => [ * 'sheet1' => $allModels1, * 'sheet2' => $allModels2, * 'sheet3' => $allModels3 * ], * 'mode' => 'export', //default value as 'export' * 'columns' => [ * 'sheet1' => ['column1','column2','column3'], * 'sheet2' => ['column1','column2','column3'], * 'sheet3' => ['column1','column2','column3'] * ], * //without header working, because the header will be get label from attribute label. * 'headers' => [ * 'sheet1' => ['column1' => 'Header Column 1','column2' => 'Header Column 2', 'column3' => 'Header Column 3'], * 'sheet2' => ['column1' => 'Header Column 1','column2' => 'Header Column 2', 'column3' => 'Header Column 3'], * 'sheet3' => ['column1' => 'Header Column 1','column2' => 'Header Column 2', 'column3' => 'Header Column 3'] * ], * ]); * * \moonland\phpexcel\Excel::export([ * 'isMultipleSheet' => true, * 'models' => [ * 'sheet1' => $allModels1, * 'sheet2' => $allModels2, * 'sheet3' => $allModels3 * ], * 'columns' => [ * 'sheet1' => ['column1','column2','column3'], * 'sheet2' => ['column1','column2','column3'], * 'sheet3' => ['column1','column2','column3'] * ], * //without header working, because the header will be get label from attribute label. * 'headers' => [ * 'sheet1' => ['column1' => 'Header Column 1','column2' => 'Header Column 2', 'column3' => 'Header Column 3'], * 'sheet2' => ['column1' => 'Header Column 1','column2' => 'Header Column 2', 'column3' => 'Header Column 3'], * 'sheet3' => ['column1' => 'Header Column 1','column2' => 'Header Column 2', 'column3' => 'Header Column 3'] * ], * ]); * * ~~~ * * New Feature for exporting data, you can use this if you familiar yii gridview. * That is same with gridview data column. * Columns in array mode valid params are 'attribute', 'header', 'format', 'value', and footer (TODO). * Columns in string mode valid layout are 'attribute:format:header:footer(TODO)'. * * ~~~ * * \moonland\phpexcel\Excel::export([ * 'models' => Post::find()->all(), * 'columns' => [ * 'author.name:text:Author Name', * [ * 'attribute' => 'content', * 'header' => 'Content Post', * 'format' => 'text', * 'value' => function($model) { * return ExampleClass::removeText('example', $model->content); * }, * ], * 'like_it:text:Reader like this content', * 'created_at:datetime', * [ * 'attribute' => 'updated_at', * 'format' => 'date', * ], * ], * 'headers' => [ * 'created_at' => 'Date Created Content', * ], * ]); * * ~~~ * * * Import file excel and return into an array. * * ~~~ * * $data = \moonland\phpexcel\Excel::import($fileName, $config); // $config is an optional * * $data = \moonland\phpexcel\Excel::widget([ * 'mode' => 'import', * 'fileName' => $fileName, * 'setFirstRecordAsKeys' => true, // if you want to set the keys of record column with first record, if it not set, the header with use the alphabet column on excel. * 'setIndexSheetByName' => true, // set this if your excel data with multiple worksheet, the index of array will be set with the sheet name. If this not set, the index will use numeric. * 'getOnlySheet' => 'sheet1', // you can set this property if you want to get the specified sheet from the excel data with multiple worksheet. * ]); * * $data = \moonland\phpexcel\Excel::import($fileName, [ * 'setFirstRecordAsKeys' => true, // if you want to set the keys of record column with first record, if it not set, the header with use the alphabet column on excel. * 'setIndexSheetByName' => true, // set this if your excel data with multiple worksheet, the index of array will be set with the sheet name. If this not set, the index will use numeric. * 'getOnlySheet' => 'sheet1', // you can set this property if you want to get the specified sheet from the excel data with multiple worksheet. * ]); * * // import data with multiple file. * * $data = \moonland\phpexcel\Excel::widget([ * 'mode' => 'import', * 'fileName' => [ * 'file1' => $fileName1, * 'file2' => $fileName2, * 'file3' => $fileName3, * ], * 'setFirstRecordAsKeys' => true, // if you want to set the keys of record column with first record, if it not set, the header with use the alphabet column on excel. * 'setIndexSheetByName' => true, // set this if your excel data with multiple worksheet, the index of array will be set with the sheet name. If this not set, the index will use numeric. * 'getOnlySheet' => 'sheet1', // you can set this property if you want to get the specified sheet from the excel data with multiple worksheet. * ]); * * $data = \moonland\phpexcel\Excel::import([ * 'file1' => $fileName1, * 'file2' => $fileName2, * 'file3' => $fileName3, * ], [ * 'setFirstRecordAsKeys' => true, // if you want to set the keys of record column with first record, if it not set, the header with use the alphabet column on excel. * 'setIndexSheetByName' => true, // set this if your excel data with multiple worksheet, the index of array will be set with the sheet name. If this not set, the index will use numeric. * 'getOnlySheet' => 'sheet1', // you can set this property if you want to get the specified sheet from the excel data with multiple worksheet. * ]); * * ~~~ * * Result example from the code on the top : * * ~~~ * * // only one sheet or specified sheet. * * Array([0] => Array([name] => Anam, [email] => moh.khoirul.anaam@gmail.com, [framework interest] => Yii2), * [1] => Array([name] => Example, [email] => example@moonlandsoft.com, [framework interest] => Yii2)); * * // data with multiple worksheet * * Array([Sheet1] => Array([0] => Array([name] => Anam, [email] => moh.khoirul.anaam@gmail.com, [framework interest] => Yii2), * [1] => Array([name] => Example, [email] => example@moonlandsoft.com, [framework interest] => Yii2)), * [Sheet2] => Array([0] => Array([name] => Anam, [email] => moh.khoirul.anaam@gmail.com, [framework interest] => Yii2), * [1] => Array([name] => Example, [email] => example@moonlandsoft.com, [framework interest] => Yii2))); * * // data with multiple file and specified sheet or only one worksheet * * Array([file1] => Array([0] => Array([name] => Anam, [email] => moh.khoirul.anaam@gmail.com, [framework interest] => Yii2), * [1] => Array([name] => Example, [email] => example@moonlandsoft.com, [framework interest] => Yii2)), * [file2] => Array([0] => Array([name] => Anam, [email] => moh.khoirul.anaam@gmail.com, [framework interest] => Yii2), * [1] => Array([name] => Example, [email] => example@moonlandsoft.com, [framework interest] => Yii2))); * * // data with multiple file and multiple worksheet * * Array([file1] => Array([Sheet1] => Array([0] => Array([name] => Anam, [email] => moh.khoirul.anaam@gmail.com, [framework interest] => Yii2), * [1] => Array([name] => Example, [email] => example@moonlandsoft.com, [framework interest] => Yii2)), * [Sheet2] => Array([0] => Array([name] => Anam, [email] => moh.khoirul.anaam@gmail.com, [framework interest] => Yii2), * [1] => Array([name] => Example, [email] => example@moonlandsoft.com, [framework interest] => Yii2))), * [file2] => Array([Sheet1] => Array([0] => Array([name] => Anam, [email] => moh.khoirul.anaam@gmail.com, [framework interest] => Yii2), * [1] => Array([name] => Example, [email] => example@moonlandsoft.com, [framework interest] => Yii2)), * [Sheet2] => Array([0] => Array([name] => Anam, [email] => moh.khoirul.anaam@gmail.com, [framework interest] => Yii2), * [1] => Array([name] => Example, [email] => example@moonlandsoft.com, [framework interest] => Yii2)))); * * ~~~ * * @property string $mode is an export mode or import mode. valid value are 'export' and 'import' * @property boolean $isMultipleSheet for set the export excel with multiple sheet. * @property array $properties for set property on the excel object. * @property array $models Model object or DataProvider object with much data. * @property array $columns to get the attributes from the model, this valid value only the exist attribute on the model. * If this is not set, then all attribute of the model will be set as columns. * @property array $headers to set the header column on first line. Set this if want to custom header. * If not set, the header will get attributes label of model attributes. * @property string|array $fileName is a name for file name to export or import. Multiple file name only use for import mode, not work if you use the export mode. * @property string $savePath is a directory to save the file or you can blank this to set the file as attachment. * @property string $format for excel to export. Valid value are 'Xls','Xlsx','Xml','Ods','Slk','Gnumeric','Csv', and 'Html'. * @property boolean $setFirstTitle to set the title column on the first line. The columns will have a header on the first line. * @property boolean $asAttachment to set the file excel to download mode. * @property boolean $setFirstRecordAsKeys to set the first record on excel file to a keys of array per line. * If you want to set the keys of record column with first record, if it not set, the header with use the alphabet column on excel. * @property boolean $setIndexSheetByName to set the sheet index by sheet name or array result if the sheet not only one * @property string $getOnlySheet is a sheet name to getting the data. This is only get the sheet with same name. * @property array|Formatter $formatter the formatter used to format model attribute values into displayable texts. * This can be either an instance of [[Formatter]] or an configuration array for creating the [[Formatter]] * instance. If this property is not set, the "formatter" application component will be used. * * @author Moh Khoirul Anam <moh.khoirul.anaam@gmail.com> * @copyright 2014 * @since 1 */ class Excel extends \yii\base\Widget { // Border style const BORDER_NONE = 'none'; const BORDER_DASHDOT = 'dashDot'; const BORDER_DASHDOTDOT = 'dashDotDot'; const BORDER_DASHED = 'dashed'; const BORDER_DOTTED = 'dotted'; const BORDER_DOUBLE = 'double'; const BORDER_HAIR = 'hair'; const BORDER_MEDIUM = 'medium'; const BORDER_MEDIUMDASHDOT = 'mediumDashDot'; const BORDER_MEDIUMDASHDOTDOT = 'mediumDashDotDot'; const BORDER_MEDIUMDASHED = 'mediumDashed'; const BORDER_SLANTDASHDOT = 'slantDashDot'; const BORDER_THICK = 'thick'; const BORDER_THIN = 'thin'; // Colors const COLOR_BLACK = 'FF000000'; const COLOR_WHITE = 'FFFFFFFF'; const COLOR_RED = 'FFFF0000'; const COLOR_DARKRED = 'FF800000'; const COLOR_BLUE = 'FF0000FF'; const COLOR_DARKBLUE = 'FF000080'; const COLOR_GREEN = 'FF00FF00'; const COLOR_DARKGREEN = 'FF008000'; const COLOR_YELLOW = 'FFFFFF00'; const COLOR_DARKYELLOW = 'FF808000'; // Horizontal alignment styles const HORIZONTAL_GENERAL = 'general'; const HORIZONTAL_LEFT = 'left'; const HORIZONTAL_RIGHT = 'right'; const HORIZONTAL_CENTER = 'center'; const HORIZONTAL_CENTER_CONTINUOUS = 'centerContinuous'; const HORIZONTAL_JUSTIFY = 'justify'; const HORIZONTAL_FILL = 'fill'; const HORIZONTAL_DISTRIBUTED = 'distributed'; // Excel2007 only // Vertical alignment styles const VERTICAL_BOTTOM = 'bottom'; const VERTICAL_TOP = 'top'; const VERTICAL_CENTER = 'center'; const VERTICAL_JUSTIFY = 'justify'; const VERTICAL_DISTRIBUTED = 'distributed'; // Excel2007 only // Read order const READORDER_CONTEXT = 0; const READORDER_LTR = 1; const READORDER_RTL = 2; // Fill types const FILL_NONE = 'none'; const FILL_SOLID = 'solid'; const FILL_GRADIENT_LINEAR = 'linear'; const FILL_GRADIENT_PATH = 'path'; const FILL_PATTERN_DARKDOWN = 'darkDown'; const FILL_PATTERN_DARKGRAY = 'darkGray'; const FILL_PATTERN_DARKGRID = 'darkGrid'; const FILL_PATTERN_DARKHORIZONTAL = 'darkHorizontal'; const FILL_PATTERN_DARKTRELLIS = 'darkTrellis'; const FILL_PATTERN_DARKUP = 'darkUp'; const FILL_PATTERN_DARKVERTICAL = 'darkVertical'; const FILL_PATTERN_GRAY0625 = 'gray0625'; const FILL_PATTERN_GRAY125 = 'gray125'; const FILL_PATTERN_LIGHTDOWN = 'lightDown'; const FILL_PATTERN_LIGHTGRAY = 'lightGray'; const FILL_PATTERN_LIGHTGRID = 'lightGrid'; const FILL_PATTERN_LIGHTHORIZONTAL = 'lightHorizontal'; const FILL_PATTERN_LIGHTTRELLIS = 'lightTrellis'; const FILL_PATTERN_LIGHTUP = 'lightUp'; const FILL_PATTERN_LIGHTVERTICAL = 'lightVertical'; const FILL_PATTERN_MEDIUMGRAY = 'mediumGray'; // Pre-defined formats const FORMAT_GENERAL = 'General'; const FORMAT_TEXT = '@'; const FORMAT_NUMBER = '0'; const FORMAT_NUMBER_00 = '0.00'; const FORMAT_NUMBER_COMMA_SEPARATED1 = '#,##0.00'; const FORMAT_NUMBER_COMMA_SEPARATED2 = '#,##0.00_-'; const FORMAT_PERCENTAGE = '0%'; const FORMAT_PERCENTAGE_00 = '0.00%'; const FORMAT_DATE_YYYYMMDD2 = 'yyyy-mm-dd'; const FORMAT_DATE_YYYYMMDD = 'yy-mm-dd'; const FORMAT_DATE_DDMMYYYY = 'dd/mm/yy'; const FORMAT_DATE_DMYSLASH = 'd/m/yy'; const FORMAT_DATE_DMYMINUS = 'd-m-yy'; const FORMAT_DATE_DMMINUS = 'd-m'; const FORMAT_DATE_MYMINUS = 'm-yy'; const FORMAT_DATE_XLSX14 = 'mm-dd-yy'; const FORMAT_DATE_XLSX15 = 'd-mmm-yy'; const FORMAT_DATE_XLSX16 = 'd-mmm'; const FORMAT_DATE_XLSX17 = 'mmm-yy'; const FORMAT_DATE_XLSX22 = 'm/d/yy h:mm'; const FORMAT_DATE_DATETIME = 'd/m/yy h:mm'; const FORMAT_DATE_TIME1 = 'h:mm AM/PM'; const FORMAT_DATE_TIME2 = 'h:mm:ss AM/PM'; const FORMAT_DATE_TIME3 = 'h:mm'; const FORMAT_DATE_TIME4 = 'h:mm:ss'; const FORMAT_DATE_TIME5 = 'mm:ss'; const FORMAT_DATE_TIME6 = 'h:mm:ss'; const FORMAT_DATE_TIME7 = 'i:s.S'; const FORMAT_DATE_TIME8 = 'h:mm:ss;@'; const FORMAT_DATE_YYYYMMDDSLASH = 'yy/mm/dd;@'; const FORMAT_CURRENCY_USD_SIMPLE = '"$"#,##0.00_-'; const FORMAT_CURRENCY_USD = '$#,##0_-'; const FORMAT_CURRENCY_EUR_SIMPLE = '#,##0.00_-"€"'; const FORMAT_CURRENCY_EUR = '#,##0_-"€"'; /** * @var string mode is an export mode or import mode. valid value are 'export' and 'import'. */ public $mode = 'export'; /** * @var boolean for set the export excel with multiple sheet. */ public $isMultipleSheet = false; /** * @var array properties for set property on the excel object. */ public $properties; /** * @var Model object or DataProvider object with much data. */ public $models; /** * @var array columns to get the attributes from the model, this valid value only the exist attribute on the model. * If this is not set, then all attribute of the model will be set as columns. */ public $columns = []; /** * @var array header to set the header column on first line. Set this if want to custom header. * If not set, the header will get attributes label of model attributes. */ public $headers = []; /** * @var string|array name for file name to export or save. */ public $fileName; /** * @var string save path is a directory to save the file or you can blank this to set the file as attachment. */ public $savePath; /** * @var string format for excel to export. Valid value are 'Xls','Xlsx','Xml','Ods','Slk','Gnumeric','Csv', and 'Html'. */ public $format; /** * @var boolean to set the title column on the first line. */ public $setFirstTitle = true; /** * @var boolean to set the file excel to download mode. */ public $asAttachment = false; /** * @var boolean to set the first record on excel file to a keys of array per line. * If you want to set the keys of record column with first record, if it not set, the header with use the alphabet column on excel. */ public $setFirstRecordAsKeys = true; /** * @var boolean to set the sheet index by sheet name or array result if the sheet not only one. */ public $setIndexSheetByName = false; /** * @var string sheetname to getting. This is only get the sheet with same name. */ public $getOnlySheet; /** * @var boolean to set the import data will return as array. */ public $asArray; /** * @var array to unread record by index number. */ public $leaveRecordByIndex = []; /** * @var array to read record by index, other will leave. */ public $getOnlyRecordByIndex = []; /** * @var array|Formatter the formatter used to format model attribute values into displayable texts. * This can be either an instance of [[Formatter]] or an configuration array for creating the [[Formatter]] * instance. If this property is not set, the "formatter" application component will be used. */ public $formatter; /** * @var boolean define the column autosize */ public $autoSize = false; /** * @var boolean if true, this writer pre-calculates all formulas in the spreadsheet. This can be slow on large spreadsheets, and maybe even unwanted. */ public $preCalculationFormula = false; /** * @var boolean Because of a bug in the Office2003 compatibility pack, there can be some small issues when opening Xlsx spreadsheets (mostly related to formula calculation) */ public $compatibilityOffice2003 = false; /** * @var custom CSV delimiter for import. Works only with CSV files */ public $CSVDelimiter = ";"; /** * @var custom CSV encoding for import. Works only with CSV files */ public $CSVEncoding = "UTF-8"; /** * (non-PHPdoc) * @see \yii\base\Object::init() */ public function init() { parent::init(); if ($this->formatter == null) { $this->formatter = \Yii::$app->getFormatter(); } elseif (is_array($this->formatter)) { $this->formatter = \Yii::createObject($this->formatter); } if (!$this->formatter instanceof Formatter) { throw new InvalidConfigException('The "formatter" property must be either a Format object or a configuration array.'); } } /** * Setting data from models */ public function executeColumns(&$activeSheet = null, $models, $columns = [], $headers = []) { if ($activeSheet == null) { $activeSheet = $this->activeSheet; } $hasHeader = false; $row = 1; $char = 26; foreach ($models as $model) { if (empty($columns)) { $columns = $model->attributes(); } if ($this->setFirstTitle && !$hasHeader) { $isPlus = false; $colplus = 0; $colnum = 1; foreach ($columns as $key=>$column) { $col = ''; if ($colnum > $char) { $colplus += 1; $colnum = 1; $isPlus = true; } if ($isPlus) { $col .= chr(64+$colplus); } $col .= chr(64+$colnum); $header = ''; if (is_array($column)) { if (isset($column['header'])) { $header = $column['header']; } elseif (isset($column['attribute']) && isset($headers[$column['attribute']])) { $header = $headers[$column['attribute']]; } elseif (isset($column['attribute'])) { $header = $model->getAttributeLabel($column['attribute']); } elseif (isset($column['cellFormat']) && is_array($column['cellFormat'])) { $activeSheet->getStyle($col.$row)->applyFromArray($column['cellFormat']); } } else { if(isset($headers[$column])) { $header = $headers[$column]; } else { $header = $model->getAttributeLabel($column); } } if (isset($column['width'])) { $activeSheet->getColumnDimension(strtoupper($col))->setWidth($column['width']); } $activeSheet->setCellValue($col.$row,$header); $colnum++; } $hasHeader=true; $row++; } $isPlus = false; $colplus = 0; $colnum = 1; foreach ($columns as $key=>$column) { $col = ''; if ($colnum > $char) { $colplus++; $colnum = 1; $isPlus = true; } if ($isPlus) { $col .= chr(64+$colplus); } $col .= chr(64+$colnum); if (is_array($column)) { $column_value = $this->executeGetColumnData($model, $column); if (isset($column['cellFormat']) && is_array($column['cellFormat'])) { $activeSheet->getStyle($col.$row)->applyFromArray($column['cellFormat']); } } else { $column_value = $this->executeGetColumnData($model, ['attribute' => $column]); } $activeSheet->setCellValue($col.$row,$column_value); $colnum++; } $row++; if($this->autoSize){ foreach (range(0, $colnum) as $col) { $activeSheet->getColumnDimensionByColumn($col)->setAutoSize(true); } } } } /** * Setting label or keys on every record if setFirstRecordAsKeys is true. * @param array $sheetData * @return multitype:multitype:array */ public function executeArrayLabel($sheetData) { $keys = ArrayHelper::remove($sheetData, '1'); $new_data = []; foreach ($sheetData as $values) { $new_data[] = array_combine($keys, $values); } return $new_data; } /** * Leave record with same index number. * @param array $sheetData * @param array $index * @return array */ public function executeLeaveRecords($sheetData = [], $index = []) { foreach ($sheetData as $key => $data) { if (in_array($key, $index)) { unset($sheetData[$key]); } } return $sheetData; } /** * Read record with same index number. * @param array $sheetData * @param array $index * @return array */ public function executeGetOnlyRecords($sheetData = [], $index = []) { foreach ($sheetData as $key => $data) { if (!in_array($key, $index)) { unset($sheetData[$key]); } } return $sheetData; } /** * Getting column value. * @param Model $model * @param array $params * @return Ambigous <NULL, string, mixed> */ public function executeGetColumnData($model, $params = []) { $value = null; if (isset($params['value']) && $params['value'] !== null) { if (is_string($params['value'])) { $value = ArrayHelper::getValue($model, $params['value']); } else { $value = call_user_func($params['value'], $model, $this); } } elseif (isset($params['attribute']) && $params['attribute'] !== null) { $value = ArrayHelper::getValue($model, $params['attribute']); } if (isset($params['format']) && $params['format'] != null) $value = $this->formatter()->format($value, $params['format']); return $value; } /** * Populating columns for checking the column is string or array. if is string this will be checking have a formatter or header. * @param array $columns * @throws InvalidParamException * @return multitype:multitype:array */ public function populateColumns($columns = []) { $_columns = []; foreach ($columns as $key => $value) { if (is_string($value)) { $value_log = explode(':', $value); $_columns[$key] = ['attribute' => $value_log[0]]; if (isset($value_log[1]) && $value_log[1] !== null) { $_columns[$key]['format'] = $value_log[1]; } if (isset($value_log[2]) && $value_log[2] !== null) { $_columns[$key]['header'] = $value_log[2]; } } elseif (is_array($value)) { if (!isset($value['attribute']) && !isset($value['value'])) { throw new \InvalidArgumentException('Attribute or Value must be defined.'); } $_columns[$key] = $value; } } return $_columns; } /** * Formatter for i18n. * @return Formatter */ public function formatter() { if (!isset($this->formatter)) $this->formatter = \Yii::$app->getFormatter(); return $this->formatter; } /** * Setting header to download generated file xls */ public function setHeaders() { header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet'); header('Content-Disposition: attachment;filename="' . $this->getFileName() .'"'); header('Cache-Control: max-age=0'); } /** * Getting the file name of exporting xls file * @return string */ public function getFileName() { $fileName = 'exports.xlsx'; if (isset($this->fileName)) { $fileName = $this->fileName; if (strpos($fileName, '.xlsx') === false) $fileName .= '.xlsx'; } return $fileName; } /** * Setting properties for excel file * @param PHPExcel $objectExcel * @param array $properties */ public function properties(&$objectExcel, $properties = []) { foreach ($properties as $key => $value) { $keyname = "set" . ucfirst($key); $objectExcel->getProperties()->{$keyname}($value); } } /** * saving the xls file to download or to path */ public function writeFile($sheet) { if (!isset($this->format)) $this->format = 'Xlsx'; $objectwriter = \PhpOffice\PhpSpreadsheet\IOFactory::createWriter($sheet, $this->format); $path = 'php://output'; if (isset($this->savePath) && $this->savePath != null) { $path = $this->savePath . '/' . $this->getFileName(); } $objectwriter->setOffice2003Compatibility($this->compatibilityOffice2003); $objectwriter->setPreCalculateFormulas($this->preCalculationFormula); $objectwriter->save($path); if ($path == 'php://output') exit(); return true; } /** * reading the xls file */ public function readFile($fileName) { if (!isset($this->format)) $this->format = \PhpOffice\PhpSpreadsheet\IOFactory::identify($fileName); $objectreader = \PhpOffice\PhpSpreadsheet\IOFactory::createReader($this->format); if ($this->format == "Csv") { $objectreader->setDelimiter($this->CSVDelimiter); $objectreader->setInputEncoding($this->CSVEncoding); } $objectPhpExcel = $objectreader->load($fileName); $sheetCount = $objectPhpExcel->getSheetCount(); $sheetDatas = []; if ($sheetCount > 1) { foreach ($objectPhpExcel->getSheetNames() as $sheetIndex => $sheetName) { if (isset($this->getOnlySheet) && $this->getOnlySheet != null) { if(!$objectPhpExcel->getSheetByName($this->getOnlySheet)) { return $sheetDatas; } $objectPhpExcel->setActiveSheetIndexByName($this->getOnlySheet); $indexed = $this->getOnlySheet; $sheetDatas[$indexed] = $objectPhpExcel->getActiveSheet()->toArray(null, true, true, true); if ($this->setFirstRecordAsKeys) { $sheetDatas[$indexed] = $this->executeArrayLabel($sheetDatas[$indexed]); } if (!empty($this->getOnlyRecordByIndex)) { $sheetDatas[$indexed] = $this->executeGetOnlyRecords($sheetDatas[$indexed], $this->getOnlyRecordByIndex); } if (!empty($this->leaveRecordByIndex)) { $sheetDatas[$indexed] = $this->executeLeaveRecords($sheetDatas[$indexed], $this->leaveRecordByIndex); } return $sheetDatas[$indexed]; } else { $objectPhpExcel->setActiveSheetIndexByName($sheetName); $indexed = $this->setIndexSheetByName==true ? $sheetName : $sheetIndex; $sheetDatas[$indexed] = $objectPhpExcel->getActiveSheet()->toArray(null, true, true, true); if ($this->setFirstRecordAsKeys) { $sheetDatas[$indexed] = $this->executeArrayLabel($sheetDatas[$indexed]); } if (!empty($this->getOnlyRecordByIndex) && isset($this->getOnlyRecordByIndex[$indexed]) && is_array($this->getOnlyRecordByIndex[$indexed])) { $sheetDatas = $this->executeGetOnlyRecords($sheetDatas, $this->getOnlyRecordByIndex[$indexed]); } if (!empty($this->leaveRecordByIndex) && isset($this->leaveRecordByIndex[$indexed]) && is_array($this->leaveRecordByIndex[$indexed])) { $sheetDatas[$indexed] = $this->executeLeaveRecords($sheetDatas[$indexed], $this->leaveRecordByIndex[$indexed]); } } } } else { $sheetDatas = $objectPhpExcel->getActiveSheet()->toArray(null, true, true, true); if ($this->setFirstRecordAsKeys) { $sheetDatas = $this->executeArrayLabel($sheetDatas); } if (!empty($this->getOnlyRecordByIndex)) { $sheetDatas = $this->executeGetOnlyRecords($sheetDatas, $this->getOnlyRecordByIndex); } if (!empty($this->leaveRecordByIndex)) { $sheetDatas = $this->executeLeaveRecords($sheetDatas, $this->leaveRecordByIndex); } } return $sheetDatas; } /** * (non-PHPdoc) * @see \yii\base\Widget::run() */ public function run() { if ($this->mode == 'export') { $sheet = new Spreadsheet(); if (!isset($this->models)) throw new InvalidConfigException('Config models must be set'); if (isset($this->properties)) { $this->properties($sheet, $this->properties); } if ($this->isMultipleSheet) { $index = 0; $worksheet = []; foreach ($this->models as $title => $models) { $sheet->createSheet($index); $sheet->getSheet($index)->setTitle($title); $worksheet[$index] = $sheet->getSheet($index); $columns = isset($this->columns[$title]) ? $this->columns[$title] : []; $headers = isset($this->headers[$title]) ? $this->headers[$title] : []; $this->executeColumns($worksheet[$index], $models, $this->populateColumns($columns), $headers); $index++; } } else { $worksheet = $sheet->getActiveSheet(); $this->executeColumns($worksheet, $this->models, isset($this->columns) ? $this->populateColumns($this->columns) : [], isset($this->headers) ? $this->headers : []); } if ($this->asAttachment) { $this->setHeaders(); } $this->writeFile($sheet); $sheet->disconnectWorksheets(); unset($sheet); } elseif ($this->mode == 'import') { if (is_array($this->fileName)) { $datas = []; foreach ($this->fileName as $key => $filename) { $datas[$key] = $this->readFile($filename); } return $datas; } else { return $this->readFile($this->fileName); } } } /** * Exporting data into an excel file. * * ~~~ * * \moonland\phpexcel\Excel::export([ * 'models' => $allModels, * 'columns' => ['column1','column2','column3'], * //without header working, because the header will be get label from attribute label. * 'header' => ['column1' => 'Header Column 1','column2' => 'Header Column 2', 'column3' => 'Header Column 3'], * ]); * * ~~~ * * New Feature for exporting data, you can use this if you familiar yii gridview. * That is same with gridview data column. * Columns in array mode valid params are 'attribute', 'header', 'format', 'value', and footer (TODO). * Columns in string mode valid layout are 'attribute:format:header:footer(TODO)'. * * ~~~ * * \moonland\phpexcel\Excel::export([ * 'models' => Post::find()->all(), * 'columns' => [ * 'author.name:text:Author Name', * [ * 'attribute' => 'content', * 'header' => 'Content Post', * 'format' => 'text', * 'value' => function($model) { * return ExampleClass::removeText('example', $model->content); * }, * ], * 'like_it:text:Reader like this content', * 'created_at:datetime', * [ * 'attribute' => 'updated_at', * 'format' => 'date', * ], * ], * 'headers' => [ * 'created_at' => 'Date Created Content', * ], * ]); * * ~~~ * * @param array $config * @return string */ public static function export($config=[]) { $config = ArrayHelper::merge(['mode' => 'export'], $config); return self::widget($config); } /** * Import file excel and return into an array. * * ~~~ * * $data = \moonland\phpexcel\Excel::import($fileName, ['setFirstRecordAsKeys' => true]); * * ~~~ * * @param string!array $fileName to load. * @param array $config is a more configuration. * @return string */ public static function import($fileName, $config=[]) { $config = ArrayHelper::merge(['mode' => 'import', 'fileName' => $fileName, 'asArray' => true], $config); return self::widget($config); } /** * @param array $config * @return string */ public static function widget($config = []) { if ((isset($config['mode']) and $config['mode'] == 'import') && !isset($config['asArray'])) { $config['asArray'] = true; } if (isset($config['asArray']) && $config['asArray']==true) { $config['class'] = get_called_class(); $widget = \Yii::createObject($config); return $widget->run(); } else { return parent::widget($config); } } }
moonlandsoft/yii2-phpexcel
Excel.php
PHP
mit
33,886
34.62776
188
0.622218
false
module Text class Sorter def self.sort(text_components) components = text_components.clone components = components.shuffle nil_priorities, components = components.partition {|c| c.priority.nil? } components = components.sort_by(&:priority_index) components = components.reverse components = components + nil_priorities end end end
roschaefer/story.board
app/lib/text/sorter.rb
Ruby
mit
379
30.583333
78
0.699208
false