text
stringlengths
2
1.04M
meta
dict
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.17.1: http://docutils.sourceforge.net/" /> <meta name="viewport" content="width=device-width,initial-scale=1"> <meta http-equiv="x-ua-compatible" content="ie=edge"> <meta name="lang:clipboard.copy" content="Copy to clipboard"> <meta name="lang:clipboard.copied" content="Copied to clipboard"> <meta name="lang:search.language" content="en"> <meta name="lang:search.pipeline.stopwords" content="True"> <meta name="lang:search.pipeline.trimmer" content="True"> <meta name="lang:search.result.none" content="No matching documents"> <meta name="lang:search.result.one" content="1 matching document"> <meta name="lang:search.result.other" content="# matching documents"> <meta name="lang:search.tokenizer" content="[\s\-]+"> <link href="https://fonts.gstatic.com/" rel="preconnect" crossorigin> <link href="https://fonts.googleapis.com/css?family=Roboto+Mono:400,500,700|Roboto:300,400,400i,700&display=fallback" rel="stylesheet"> <style> body, input { font-family: "Roboto", "Helvetica Neue", Helvetica, Arial, sans-serif } code, kbd, pre { font-family: "Roboto Mono", "Courier New", Courier, monospace } </style> <link rel="stylesheet" href="../_static/stylesheets/application.css"/> <link rel="stylesheet" href="../_static/stylesheets/application-palette.css"/> <link rel="stylesheet" href="../_static/stylesheets/application-fixes.css"/> <link rel="stylesheet" href="../_static/fonts/material-icons.css"/> <meta name="theme-color" content="#3f51b5"> <script src="../_static/javascripts/modernizr.js"></script> <title>statsmodels.discrete.discrete_model.ProbitResults.tvalues &#8212; statsmodels</title> <link rel="icon" type="image/png" sizes="32x32" href="../_static/icons/favicon-32x32.png"> <link rel="icon" type="image/png" sizes="16x16" href="../_static/icons/favicon-16x16.png"> <link rel="manifest" href="../_static/icons/site.webmanifest"> <link rel="mask-icon" href="../_static/icons/safari-pinned-tab.svg" color="#919191"> <meta name="msapplication-TileColor" content="#2b5797"> <meta name="msapplication-config" content="../_static/icons/browserconfig.xml"> <link rel="stylesheet" href="../_static/stylesheets/examples.css"> <link rel="stylesheet" href="../_static/stylesheets/deprecation.css"> <link rel="stylesheet" type="text/css" href="../_static/pygments.css" /> <link rel="stylesheet" type="text/css" href="../_static/material.css" /> <link rel="stylesheet" type="text/css" href="../_static/graphviz.css" /> <link rel="stylesheet" type="text/css" href="../_static/plot_directive.css" /> <script data-url_root="../" id="documentation_options" src="../_static/documentation_options.js"></script> <script src="../_static/jquery.js"></script> <script src="../_static/underscore.js"></script> <script src="../_static/doctools.js"></script> <script crossorigin="anonymous" integrity="sha256-Ae2Vz/4ePdIu6ZyI/5ZGsYnb+m0JlOmKPjt6XZ9JJkA=" src="https://cdnjs.cloudflare.com/ajax/libs/require.js/2.3.4/require.min.js"></script> <link rel="shortcut icon" href="../_static/favicon.ico"/> <link rel="author" title="About these documents" href="../about.html" /> <link rel="index" title="Index" href="../genindex.html" /> <link rel="search" title="Search" href="../search.html" /> <link rel="next" title="statsmodels.discrete.discrete_model.ProbitResults.use_t" href="statsmodels.discrete.discrete_model.ProbitResults.use_t.html" /> <link rel="prev" title="statsmodels.discrete.discrete_model.ProbitResults.resid_response" href="statsmodels.discrete.discrete_model.ProbitResults.resid_response.html" /> </head> <body dir=ltr data-md-color-primary=indigo data-md-color-accent=blue> <svg class="md-svg"> <defs data-children-count="0"> <svg xmlns="http://www.w3.org/2000/svg" width="416" height="448" viewBox="0 0 416 448" id="__github"><path fill="currentColor" d="M160 304q0 10-3.125 20.5t-10.75 19T128 352t-18.125-8.5-10.75-19T96 304t3.125-20.5 10.75-19T128 256t18.125 8.5 10.75 19T160 304zm160 0q0 10-3.125 20.5t-10.75 19T288 352t-18.125-8.5-10.75-19T256 304t3.125-20.5 10.75-19T288 256t18.125 8.5 10.75 19T320 304zm40 0q0-30-17.25-51T296 232q-10.25 0-48.75 5.25Q229.5 240 208 240t-39.25-2.75Q130.75 232 120 232q-29.5 0-46.75 21T56 304q0 22 8 38.375t20.25 25.75 30.5 15 35 7.375 37.25 1.75h42q20.5 0 37.25-1.75t35-7.375 30.5-15 20.25-25.75T360 304zm56-44q0 51.75-15.25 82.75-9.5 19.25-26.375 33.25t-35.25 21.5-42.5 11.875-42.875 5.5T212 416q-19.5 0-35.5-.75t-36.875-3.125-38.125-7.5-34.25-12.875T37 371.5t-21.5-28.75Q0 312 0 260q0-59.25 34-99-6.75-20.5-6.75-42.5 0-29 12.75-54.5 27 0 47.5 9.875t47.25 30.875Q171.5 96 212 96q37 0 70 8 26.25-20.5 46.75-30.25T376 64q12.75 25.5 12.75 54.5 0 21.75-6.75 42 34 40 34 99.5z"/></svg> </defs> </svg> <input class="md-toggle" data-md-toggle="drawer" type="checkbox" id="__drawer"> <input class="md-toggle" data-md-toggle="search" type="checkbox" id="__search"> <label class="md-overlay" data-md-component="overlay" for="__drawer"></label> <a href="#generated/statsmodels.discrete.discrete_model.ProbitResults.tvalues" tabindex="1" class="md-skip"> Skip to content </a> <header class="md-header" data-md-component="header"> <nav class="md-header-nav md-grid"> <div class="md-flex navheader"> <div class="md-flex__cell md-flex__cell--shrink"> <a href="../index.html" title="statsmodels" class="md-header-nav__button md-logo"> <img src="../_static/statsmodels-logo-v2-bw.svg" height="26" alt="statsmodels logo"> </a> </div> <div class="md-flex__cell md-flex__cell--shrink"> <label class="md-icon md-icon--menu md-header-nav__button" for="__drawer"></label> </div> <div class="md-flex__cell md-flex__cell--stretch"> <div class="md-flex__ellipsis md-header-nav__title" data-md-component="title"> <span class="md-header-nav__topic">statsmodels v0.13.2</span> <span class="md-header-nav__topic"> statsmodels.discrete.discrete_model.ProbitResults.tvalues </span> </div> </div> <div class="md-flex__cell md-flex__cell--shrink"> <label class="md-icon md-icon--search md-header-nav__button" for="__search"></label> <div class="md-search" data-md-component="search" role="dialog"> <label class="md-search__overlay" for="__search"></label> <div class="md-search__inner" role="search"> <form class="md-search__form" action="../search.html" method="get" name="search"> <input type="text" class="md-search__input" name="q" placeholder="Search" autocapitalize="off" autocomplete="off" spellcheck="false" data-md-component="query" data-md-state="active"> <label class="md-icon md-search__icon" for="__search"></label> <button type="reset" class="md-icon md-search__icon" data-md-component="reset" tabindex="-1"> &#xE5CD; </button> </form> <div class="md-search__output"> <div class="md-search__scrollwrap" data-md-scrollfix> <div class="md-search-result" data-md-component="result"> <div class="md-search-result__meta"> Type to start searching </div> <ol class="md-search-result__list"></ol> </div> </div> </div> </div> </div> </div> <div class="md-flex__cell md-flex__cell--shrink"> <div class="md-header-nav__source"> <a href="https://github.com/statsmodels/statsmodels" title="Go to repository" class="md-source" data-md-source="github"> <div class="md-source__icon"> <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 24 24" width="28" height="28"> <use xlink:href="#__github" width="24" height="24"></use> </svg> </div> <div class="md-source__repository"> statsmodels </div> </a> </div> </div> <script src="../_static/javascripts/version_dropdown.js"></script> <script> var json_loc = "../../versions-v2.json", target_loc = "../../", text = "Versions"; $( document ).ready( add_version_dropdown(json_loc, target_loc, text)); </script> </div> </nav> </header> <div class="md-container"> <nav class="md-tabs" data-md-component="tabs"> <div class="md-tabs__inner md-grid"> <ul class="md-tabs__list"> <li class="md-tabs__item"><a href="../user-guide.html" class="md-tabs__link">User Guide</a></li> <li class="md-tabs__item"><a href="../discretemod.html" class="md-tabs__link">Regression with Discrete Dependent Variable</a></li> <li class="md-tabs__item"><a href="statsmodels.discrete.discrete_model.ProbitResults.html" class="md-tabs__link">statsmodels.discrete.discrete_model.ProbitResults</a></li> </ul> </div> </nav> <main class="md-main"> <div class="md-main__inner md-grid" data-md-component="container"> <div class="md-sidebar md-sidebar--primary" data-md-component="navigation"> <div class="md-sidebar__scrollwrap"> <div class="md-sidebar__inner"> <nav class="md-nav md-nav--primary" data-md-level="0"> <label class="md-nav__title md-nav__title--site" for="__drawer"> <a href="../index.html" title="statsmodels" class="md-nav__button md-logo"> <img src="../_static/statsmodels-logo-v2-bw.svg" alt=" logo" width="48" height="48"> </a> <a href="../index.html" title="statsmodels">statsmodels v0.13.2</a> </label> <div class="md-nav__source"> <a href="https://github.com/statsmodels/statsmodels" title="Go to repository" class="md-source" data-md-source="github"> <div class="md-source__icon"> <svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 24 24" width="28" height="28"> <use xlink:href="#__github" width="24" height="24"></use> </svg> </div> <div class="md-source__repository"> statsmodels </div> </a> </div> <ul class="md-nav__list"> <li class="md-nav__item"> <a href="../install.html" class="md-nav__link">Installing statsmodels</a> </li> <li class="md-nav__item"> <a href="../gettingstarted.html" class="md-nav__link">Getting started</a> </li> <li class="md-nav__item"> <a href="../user-guide.html" class="md-nav__link">User Guide</a> <ul class="md-nav__list"> <li class="md-nav__item"> <a href="../user-guide.html#background" class="md-nav__link">Background</a> </li> <li class="md-nav__item"> <a href="../user-guide.html#regression-and-linear-models" class="md-nav__link">Regression and Linear Models</a> <ul class="md-nav__list"> <li class="md-nav__item"> <a href="../regression.html" class="md-nav__link">Linear Regression</a> </li> <li class="md-nav__item"> <a href="../glm.html" class="md-nav__link">Generalized Linear Models</a> </li> <li class="md-nav__item"> <a href="../gee.html" class="md-nav__link">Generalized Estimating Equations</a> </li> <li class="md-nav__item"> <a href="../gam.html" class="md-nav__link">Generalized Additive Models (GAM)</a> </li> <li class="md-nav__item"> <a href="../rlm.html" class="md-nav__link">Robust Linear Models</a> </li> <li class="md-nav__item"> <a href="../mixed_linear.html" class="md-nav__link">Linear Mixed Effects Models</a> </li> <li class="md-nav__item"> <a href="../discretemod.html" class="md-nav__link">Regression with Discrete Dependent Variable</a> </li> <li class="md-nav__item"> <a href="../mixed_glm.html" class="md-nav__link">Generalized Linear Mixed Effects Models</a> </li> <li class="md-nav__item"> <a href="../anova.html" class="md-nav__link">ANOVA</a> </li> <li class="md-nav__item"> <a href="../other_models.html" class="md-nav__link">Other Models <code class="xref py py-mod docutils literal notranslate"><span class="pre">othermod</span></code></a> </li></ul> </li> <li class="md-nav__item"> <a href="../user-guide.html#time-series-analysis" class="md-nav__link">Time Series Analysis</a> </li> <li class="md-nav__item"> <a href="../user-guide.html#other-models" class="md-nav__link">Other Models</a> </li> <li class="md-nav__item"> <a href="../user-guide.html#statistics-and-tools" class="md-nav__link">Statistics and Tools</a> </li> <li class="md-nav__item"> <a href="../user-guide.html#data-sets" class="md-nav__link">Data Sets</a> </li> <li class="md-nav__item"> <a href="../user-guide.html#sandbox" class="md-nav__link">Sandbox</a> </li></ul> </li> <li class="md-nav__item"> <a href="../examples/index.html" class="md-nav__link">Examples</a> </li> <li class="md-nav__item"> <a href="../api.html" class="md-nav__link">API Reference</a> </li> <li class="md-nav__item"> <a href="../about.html" class="md-nav__link">About statsmodels</a> </li> <li class="md-nav__item"> <a href="../dev/index.html" class="md-nav__link">Developer Page</a> </li> <li class="md-nav__item"> <a href="../release/index.html" class="md-nav__link">Release Notes</a> </li> </ul> </nav> </div> </div> </div> <div class="md-sidebar md-sidebar--secondary" data-md-component="toc"> <div class="md-sidebar__scrollwrap"> <div class="md-sidebar__inner"> <nav class="md-nav md-nav--secondary"> <ul class="md-nav__list" data-md-scrollfix=""> <li class="md-nav__item"><a class="md-nav__extra_link" href="../_sources/generated/statsmodels.discrete.discrete_model.ProbitResults.tvalues.rst.txt">Show Source</a> </li> <li id="searchbox" class="md-nav__item"></li> </ul> </nav> </div> </div> </div> <div class="md-content"> <article class="md-content__inner md-typeset" role="main"> <section id="statsmodels-discrete-discrete-model-probitresults-tvalues"> <h1 id="generated-statsmodels-discrete-discrete-model-probitresults-tvalues--page-root">statsmodels.discrete.discrete_model.ProbitResults.tvalues<a class="headerlink" href="#generated-statsmodels-discrete-discrete-model-probitresults-tvalues--page-root" title="Permalink to this headline">¶</a></h1> <dl class="py attribute"> <dt class="sig sig-object py" id="statsmodels.discrete.discrete_model.ProbitResults.tvalues"> <span class="sig-prename descclassname"><span class="pre">ProbitResults.</span></span><span class="sig-name descname"><span class="pre">tvalues</span></span><a class="headerlink" href="#statsmodels.discrete.discrete_model.ProbitResults.tvalues" title="Permalink to this definition">¶</a></dt> <dd><p>Return the t-statistic for a given parameter estimate.</p> </dd></dl> </section> </article> </div> </div> </main> </div> <footer class="md-footer"> <div class="md-footer-nav"> <nav class="md-footer-nav__inner md-grid"> <a href="statsmodels.discrete.discrete_model.ProbitResults.resid_response.html" title="statsmodels.discrete.discrete_model.ProbitResults.resid_response" class="md-flex md-footer-nav__link md-footer-nav__link--prev" rel="prev"> <div class="md-flex__cell md-flex__cell--shrink"> <i class="md-icon md-icon--arrow-back md-footer-nav__button"></i> </div> <div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title"> <span class="md-flex__ellipsis"> <span class="md-footer-nav__direction"> Previous </span> statsmodels.discrete.discrete_model.ProbitResults.resid_response </span> </div> </a> <a href="statsmodels.discrete.discrete_model.ProbitResults.use_t.html" title="statsmodels.discrete.discrete_model.ProbitResults.use_t" class="md-flex md-footer-nav__link md-footer-nav__link--next" rel="next"> <div class="md-flex__cell md-flex__cell--stretch md-footer-nav__title"><span class="md-flex__ellipsis"> <span class="md-footer-nav__direction"> Next </span> statsmodels.discrete.discrete_model.ProbitResults.use_t </span> </div> <div class="md-flex__cell md-flex__cell--shrink"><i class="md-icon md-icon--arrow-forward md-footer-nav__button"></i> </div> </a> </nav> </div> <div class="md-footer-meta md-typeset"> <div class="md-footer-meta__inner md-grid"> <div class="md-footer-copyright"> <div class="md-footer-copyright__highlight"> &#169; Copyright 2009-2019, Josef Perktold, Skipper Seabold, Jonathan Taylor, statsmodels-developers. </div> Last updated on Feb 08, 2022. <br/> Created using <a href="http://www.sphinx-doc.org/">Sphinx</a> 4.4.0. and <a href="https://github.com/bashtage/sphinx-material/">Material for Sphinx</a> </div> </div> </div> </footer> <script src="../_static/javascripts/application.js"></script> <script>app.initialize({version: "1.0.4", url: {base: ".."}})</script> </body> </html>
{ "content_hash": "6a167a3b89b051f734eee39f2f911911", "timestamp": "", "source": "github", "line_count": 497, "max_line_length": 999, "avg_line_length": 37.26156941649899, "alnum_prop": 0.5972244721637238, "repo_name": "statsmodels/statsmodels.github.io", "id": "205f5ce1abb760a6715197bb1abaf8ff5e46d8a2", "size": "18523", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "v0.13.2/generated/statsmodels.discrete.discrete_model.ProbitResults.tvalues.html", "mode": "33188", "license": "bsd-3-clause", "language": [], "symlink_target": "" }
package edu.getty.cdwa.cdwaLite; /** * A document containing one resourceViewSubjectTerm(@http://www.getty.edu/CDWA/CDWALite) element. * * This is a complex type. */ public interface ResourceViewSubjectTermDocument extends org.apache.xmlbeans.XmlObject { public static final org.apache.xmlbeans.SchemaType type = (org.apache.xmlbeans.SchemaType) org.apache.xmlbeans.XmlBeans.typeSystemForClassLoader(ResourceViewSubjectTermDocument.class.getClassLoader(), "schemaorg_apache_xmlbeans.system.s1F643FAF4399D1206A04583D585DB128").resolveHandle("resourceviewsubjectterm223cdoctype"); /** * Gets the "resourceViewSubjectTerm" element */ edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument.ResourceViewSubjectTerm getResourceViewSubjectTerm(); /** * Sets the "resourceViewSubjectTerm" element */ void setResourceViewSubjectTerm(edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument.ResourceViewSubjectTerm resourceViewSubjectTerm); /** * Appends and returns a new empty "resourceViewSubjectTerm" element */ edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument.ResourceViewSubjectTerm addNewResourceViewSubjectTerm(); /** * An XML resourceViewSubjectTerm(@http://www.getty.edu/CDWA/CDWALite). * * This is an atomic type that is a restriction of edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument$ResourceViewSubjectTerm. */ public interface ResourceViewSubjectTerm extends org.apache.xmlbeans.XmlString { public static final org.apache.xmlbeans.SchemaType type = (org.apache.xmlbeans.SchemaType) org.apache.xmlbeans.XmlBeans.typeSystemForClassLoader(ResourceViewSubjectTerm.class.getClassLoader(), "schemaorg_apache_xmlbeans.system.s1F643FAF4399D1206A04583D585DB128").resolveHandle("resourceviewsubjectterm758belemtype"); /** * Gets the "termsource" attribute */ java.lang.String getTermsource(); /** * Gets (as xml) the "termsource" attribute */ org.apache.xmlbeans.XmlString xgetTermsource(); /** * True if has "termsource" attribute */ boolean isSetTermsource(); /** * Sets the "termsource" attribute */ void setTermsource(java.lang.String termsource); /** * Sets (as xml) the "termsource" attribute */ void xsetTermsource(org.apache.xmlbeans.XmlString termsource); /** * Unsets the "termsource" attribute */ void unsetTermsource(); /** * Gets the "termsourceID" attribute */ java.lang.String getTermsourceID(); /** * Gets (as xml) the "termsourceID" attribute */ org.apache.xmlbeans.XmlString xgetTermsourceID(); /** * True if has "termsourceID" attribute */ boolean isSetTermsourceID(); /** * Sets the "termsourceID" attribute */ void setTermsourceID(java.lang.String termsourceID); /** * Sets (as xml) the "termsourceID" attribute */ void xsetTermsourceID(org.apache.xmlbeans.XmlString termsourceID); /** * Unsets the "termsourceID" attribute */ void unsetTermsourceID(); /** * Gets the "type" attribute */ java.lang.String getType(); /** * Gets (as xml) the "type" attribute */ org.apache.xmlbeans.XmlString xgetType(); /** * True if has "type" attribute */ boolean isSetType(); /** * Sets the "type" attribute */ void setType(java.lang.String type); /** * Sets (as xml) the "type" attribute */ void xsetType(org.apache.xmlbeans.XmlString type); /** * Unsets the "type" attribute */ void unsetType(); /** * A factory class with static methods for creating instances * of this type. */ public static final class Factory { public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument.ResourceViewSubjectTerm newInstance() { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument.ResourceViewSubjectTerm) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newInstance( type, null ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument.ResourceViewSubjectTerm newInstance(org.apache.xmlbeans.XmlOptions options) { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument.ResourceViewSubjectTerm) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newInstance( type, options ); } private Factory() { } // No instance of this class allowed } } /** * A factory class with static methods for creating instances * of this type. */ public static final class Factory { public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument newInstance() { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newInstance( type, null ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument newInstance(org.apache.xmlbeans.XmlOptions options) { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newInstance( type, options ); } /** @param xmlAsString the string value to parse */ public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(java.lang.String xmlAsString) throws org.apache.xmlbeans.XmlException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xmlAsString, type, null ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(java.lang.String xmlAsString, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xmlAsString, type, options ); } /** @param file the file from which to load an xml document */ public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(java.io.File file) throws org.apache.xmlbeans.XmlException, java.io.IOException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( file, type, null ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(java.io.File file, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( file, type, options ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(java.net.URL u) throws org.apache.xmlbeans.XmlException, java.io.IOException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( u, type, null ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(java.net.URL u, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( u, type, options ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(java.io.InputStream is) throws org.apache.xmlbeans.XmlException, java.io.IOException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( is, type, null ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(java.io.InputStream is, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( is, type, options ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(java.io.Reader r) throws org.apache.xmlbeans.XmlException, java.io.IOException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( r, type, null ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(java.io.Reader r, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, java.io.IOException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( r, type, options ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(javax.xml.stream.XMLStreamReader sr) throws org.apache.xmlbeans.XmlException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( sr, type, null ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(javax.xml.stream.XMLStreamReader sr, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( sr, type, options ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(org.w3c.dom.Node node) throws org.apache.xmlbeans.XmlException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( node, type, null ); } public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(org.w3c.dom.Node node, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( node, type, options ); } /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */ @Deprecated public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(org.apache.xmlbeans.xml.stream.XMLInputStream xis) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xis, type, null ); } /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */ @Deprecated public static edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument parse(org.apache.xmlbeans.xml.stream.XMLInputStream xis, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException { return (edu.getty.cdwa.cdwaLite.ResourceViewSubjectTermDocument) org.apache.xmlbeans.XmlBeans.getContextTypeLoader().parse( xis, type, options ); } /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */ @Deprecated public static org.apache.xmlbeans.xml.stream.XMLInputStream newValidatingXMLInputStream(org.apache.xmlbeans.xml.stream.XMLInputStream xis) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException { return org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newValidatingXMLInputStream( xis, type, null ); } /** @deprecated {@link org.apache.xmlbeans.xml.stream.XMLInputStream} */ @Deprecated public static org.apache.xmlbeans.xml.stream.XMLInputStream newValidatingXMLInputStream(org.apache.xmlbeans.xml.stream.XMLInputStream xis, org.apache.xmlbeans.XmlOptions options) throws org.apache.xmlbeans.XmlException, org.apache.xmlbeans.xml.stream.XMLStreamException { return org.apache.xmlbeans.XmlBeans.getContextTypeLoader().newValidatingXMLInputStream( xis, type, options ); } private Factory() { } // No instance of this class allowed } }
{ "content_hash": "56e7711d188205c2745d893dbb7187f7", "timestamp": "", "source": "github", "line_count": 226, "max_line_length": 279, "avg_line_length": 57.04424778761062, "alnum_prop": 0.7054762643499844, "repo_name": "moosbusch/xbCDWALite", "id": "5173455459f87c9a7adf5d1fe71d02970840bdf8", "size": "13505", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/edu/getty/cdwa/cdwaLite/ResourceViewSubjectTermDocument.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Java", "bytes": "2576914" } ], "symlink_target": "" }
import { useEffect, useRef, useState } from 'react'; import classNames from 'classnames'; export const useDropdown = _ref => { let { dropdownContentWidth, dropdownAnchorSide, callOnToggle, closeEvents, isExpanded, buttonId = 'button', inputId = 'input', menuId = 'menu', dropdownClass = 'k-HeaderNavDropdown' } = _ref; const dropdownRef = useRef(null); const dropdownContentRef = useRef(null); const dropdownButtonRef = useRef(null); const dropdownInputRef = useRef(null); const [isDropdownExpanded, setDropdownExpandedState] = useState(!!isExpanded); const handleButtonClick = () => { setDropdownExpandedState(currentValue => !currentValue); }; const handleInputChange = changeEvent => { setDropdownExpandedState(changeEvent.target.value.length > 0); }; const closeDropdown = () => { setDropdownExpandedState(false); }; const handleKeydown = e => { if (e.key === 'Escape') { closeDropdown(); } if (e.key === 'Tab') { // Wait 5ms for the activeElement to change setTimeout(() => { if (dropdownRef.current && !dropdownRef.current.contains(document.activeElement)) { closeDropdown(); } }, 5); } }; const handleClickOutside = e => { if (dropdownRef.current && !dropdownRef.current.contains(e.target)) { closeDropdown(); } }; useEffect(() => { callOnToggle({ isExpanded: isDropdownExpanded, expandBy: isDropdownExpanded ? buttonId : null }); if (!isDropdownExpanded) return; document.addEventListener('click', handleClickOutside); document.addEventListener('keydown', handleKeydown); if (closeEvents) { closeEvents.forEach(ev => { window.addEventListener(ev, closeDropdown); }); } return () => { document.removeEventListener('click', handleClickOutside); document.removeEventListener('keydown', handleKeydown); if (closeEvents) { closeEvents.forEach(ev => { window.removeEventListener(ev, closeDropdown); }); } }; }, [isDropdownExpanded]); const dropdownProps = { ref: dropdownRef, 'aria-live': 'polite', className: classNames(dropdownClass, { [dropdownClass + "--isExpanded"]: isDropdownExpanded }) }; const buttonProps = { ref: dropdownButtonRef, id: buttonId, 'aria-controls': menuId, isExpanded: isDropdownExpanded, onClick: handleButtonClick, className: dropdownClass + "__button" }; const inputProps = { ref: dropdownInputRef, id: inputId, isExpanded: isDropdownExpanded, onChange: handleInputChange, className: dropdownClass + "__input" }; const returnedWidth = dropdownContentWidth === NaN ? null : dropdownContentWidth; const menuProps = { ref: dropdownContentRef, id: menuId, className: classNames(dropdownClass + "__menu", dropdownClass + "__menu--is-" + (dropdownAnchorSide || 'left')), style: { width: returnedWidth }, 'aria-hidden': !isDropdownExpanded }; return { dropdownProps, buttonProps, menuProps, isDropdownExpanded, inputProps, openDropdown: () => setDropdownExpandedState(true), closeDropdown: () => setDropdownExpandedState(false) }; };
{ "content_hash": "2e852f7a2ca0a100b431a7dc34fbf364", "timestamp": "", "source": "github", "line_count": 121, "max_line_length": 116, "avg_line_length": 27.239669421487605, "alnum_prop": 0.6474514563106796, "repo_name": "KissKissBankBank/kitten", "id": "18d9e5384ea87365c7f1f8792b7463f92da602eb", "size": "3296", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/esm/components/navigation/header-nav/hooks/use-dropdown.js", "mode": "33188", "license": "mit", "language": [ { "name": "Dockerfile", "bytes": "187" }, { "name": "HTML", "bytes": "293" }, { "name": "JavaScript", "bytes": "5555901" }, { "name": "SCSS", "bytes": "73950" }, { "name": "Shell", "bytes": "1534" } ], "symlink_target": "" }
<!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>SKYLINKConnectionConfig Class Reference</title> <link rel="stylesheet" href="../css/style.css"> <meta name="viewport" content="initial-scale=1, maximum-scale=1.4"> <meta name="generator" content="appledoc 2.2.1 (build 1334)"> </head> <body class="appledoc"> <header> <div class="container" class="hide-in-xcode"> <h1 id="library-title"> <a href="../index.html">SKYLINK </a> </h1> <p id="developer-home"> <a href="../index.html">Temasys Communications</a> </p> </div> </header> <aside> <div class="container"> <nav> <ul id="header-buttons" role="toolbar"> <li><a href="../index.html">Index</a></li> <li><a href="../hierarchy.html">Hierarchy</a></li> <li id="on-this-page" role="navigation"> <label> On This Page <div class="chevron"> <div class="chevy chevron-left"></div> <div class="chevy chevron-right"></div> </div> <select id="jump-to"> <option value="top">Jump To&#133;</option> <option value="overview">Overview</option> <option value="tasks">Tasks</option> <optgroup label="Properties"> <option value="//api/name/captureSessionPreset">captureSessionPreset</option> <option value="//api/name/defaultCameraVideoFps">defaultCameraVideoFps</option> <option value="//api/name/defaultVideoDevice">defaultVideoDevice</option> <option value="//api/name/enableDNSPreSolving">enableDNSPreSolving</option> <option value="//api/name/enableIPv6Filter">enableIPv6Filter</option> <option value="//api/name/hasAudioAutoGainControl">hasAudioAutoGainControl</option> <option value="//api/name/hasAudioEchoCancellation">hasAudioEchoCancellation</option> <option value="//api/name/hasAudioHighPassFilter">hasAudioHighPassFilter</option> <option value="//api/name/hasAudioNoiseSuppression">hasAudioNoiseSuppression</option> <option value="//api/name/hasDataTransfer">hasDataTransfer</option> <option value="//api/name/hasFileTransfer">hasFileTransfer</option> <option value="//api/name/hasP2PMessaging">hasP2PMessaging</option> <option value="//api/name/isAllowHost">isAllowHost</option> <option value="//api/name/isAllowIceRestart">isAllowIceRestart</option> <option value="//api/name/isAllowStun">isAllowStun</option> <option value="//api/name/isAllowTurn">isAllowTurn</option> <option value="//api/name/isEnableDataChannel">isEnableDataChannel</option> <option value="//api/name/isMirrorLocalFrontCameraView">isMirrorLocalFrontCameraView</option> <option value="//api/name/isMultiTrackCreateEnable">isMultiTrackCreateEnable</option> <option value="//api/name/isReportVideoResolutionOnVideoChange">isReportVideoResolutionOnVideoChange</option> <option value="//api/name/localVideoQuality">localVideoQuality</option> <option value="//api/name/maxAudioBitrate">maxAudioBitrate</option> <option value="//api/name/maxDataBitrate">maxDataBitrate</option> <option value="//api/name/maxVideoBitrate">maxVideoBitrate</option> <option value="//api/name/maxVideoUser">maxVideoUser</option> <option value="//api/name/networkTransport">networkTransport</option> <option value="//api/name/preferredAudioCodec">preferredAudioCodec</option> <option value="//api/name/preferredTransport">preferredTransport</option> <option value="//api/name/preferredVideoCodec">preferredVideoCodec</option> <option value="//api/name/receiveAudio">receiveAudio</option> <option value="//api/name/receiveVideo">receiveVideo</option> <option value="//api/name/reconnectAttempts">reconnectAttempts</option> <option value="//api/name/reconnectionDelay">reconnectionDelay</option> <option value="//api/name/roomSize">roomSize</option> <option value="//api/name/sendAudio">sendAudio</option> <option value="//api/name/sendVideo">sendVideo</option> <option value="//api/name/videoResNumWaitMs">videoResNumWaitMs</option> </optgroup> <optgroup label="Instance Methods"> <option value="//api/name/getMaxRemotePeersConnectedWithAudioVideoConfig:">- getMaxRemotePeersConnectedWithAudioVideoConfig:</option> <option value="//api/name/getTimeoutWithEventType:">- getTimeoutWithEventType:</option> <option value="//api/name/setAdvancedOptionWithKey:value:">- setAdvancedOptionWithKey:value:</option> <option value="//api/name/setAudioVideoReceiveConfig:">- setAudioVideoReceiveConfig:</option> <option value="//api/name/setAudioVideoSendConfig:">- setAudioVideoSendConfig:</option> <option value="//api/name/setMaxRemotePeersConnected:audioVideoConfig:">- setMaxRemotePeersConnected:audioVideoConfig:</option> <option value="//api/name/setTimeout:skylinkAction:">- setTimeout:skylinkAction:</option> </optgroup> </select> </label> </li> </ul> </nav> </div> </aside> <article> <div id="overview_contents" class="container"> <div id="content"> <main role="main"> <h1 class="title">SKYLINKConnectionConfig Class Reference</h1> <div class="section section-specification"><table cellspacing="0"><tbody> <tr> <th>Inherits from</th> <td>NSObject</td> </tr><tr> <th>Declared in</th> <td>SKYLINKConnection.h<br />SKYLINKConnectionConfig.h</td> </tr> </tbody></table></div> <div class="section section-overview"> <a title="Overview" name="overview"></a> <h2 class="subtitle subtitle-overview">Overview</h2> <p>@class</p><p>The class representing the conversation configuration.</p> </div> <div class="section section-tasks"> <a title="Tasks" name="tasks"></a> <div class="task-list"> <div class="section-method"> <a name="//api/name/sendAudio" title="sendAudio"></a> <h3 class="method-title"><code><a href="#//api/name/sendAudio">&nbsp;&nbsp;sendAudio</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>enable/disable sending audio.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, readonly) BOOL sendAudio</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>Default value is NO.</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/receiveAudio" title="receiveAudio"></a> <h3 class="method-title"><code><a href="#//api/name/receiveAudio">&nbsp;&nbsp;receiveAudio</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>enable/disable receive audio.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, readonly) BOOL receiveAudio</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>No default value.</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/sendVideo" title="sendVideo"></a> <h3 class="method-title"><code><a href="#//api/name/sendVideo">&nbsp;&nbsp;sendVideo</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>enable/disable sending video.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, readonly) BOOL sendVideo</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>Default value is NO.</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/receiveVideo" title="receiveVideo"></a> <h3 class="method-title"><code><a href="#//api/name/receiveVideo">&nbsp;&nbsp;receiveVideo</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>enable/disable receiving video.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, readonly) BOOL receiveVideo</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>No default value.</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/isEnableDataChannel" title="isEnableDataChannel"></a> <h3 class="method-title"><code><a href="#//api/name/isEnableDataChannel">&nbsp;&nbsp;isEnableDataChannel</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Check if dataChennel is enabled</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, readonly) BOOL isEnableDataChannel</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>If <a href="#//api/name/hasP2PMessaging">hasP2PMessaging</a> or <a href="#//api/name/hasFileTransfer">hasFileTransfer</a> or <a href="#//api/name/hasDataTransfer">hasDataTransfer</a>, the value is true</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/hasP2PMessaging" title="hasP2PMessaging"></a> <h3 class="method-title"><code><a href="#//api/name/hasP2PMessaging">&nbsp;&nbsp;hasP2PMessaging</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>enable/disable messaging.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL hasP2PMessaging</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>Default value is NO.</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/hasFileTransfer" title="hasFileTransfer"></a> <h3 class="method-title"><code><a href="#//api/name/hasFileTransfer">&nbsp;&nbsp;hasFileTransfer</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>enable/disable file transfer.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL hasFileTransfer</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>Default value is NO.</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/hasDataTransfer" title="hasDataTransfer"></a> <h3 class="method-title"><code><a href="#//api/name/hasDataTransfer">&nbsp;&nbsp;hasDataTransfer</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>enable/disable data transfer.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL hasDataTransfer</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>Default value is NO.</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/isMultiTrackCreateEnable" title="isMultiTrackCreateEnable"></a> <h3 class="method-title"><code><a href="#//api/name/isMultiTrackCreateEnable">&nbsp;&nbsp;isMultiTrackCreateEnable</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>enable/disable multitrack support for creating.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL isMultiTrackCreateEnable</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>Default value is YES.</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/maxAudioBitrate" title="maxAudioBitrate"></a> <h3 class="method-title"><code><a href="#//api/name/maxAudioBitrate">&nbsp;&nbsp;maxAudioBitrate</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Used to limit remote peers audio media bitrate.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) NSInteger maxAudioBitrate</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>Default value is 0, meaning not bitrate limit.</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/maxVideoBitrate" title="maxVideoBitrate"></a> <h3 class="method-title"><code><a href="#//api/name/maxVideoBitrate">&nbsp;&nbsp;maxVideoBitrate</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Used to limit remote peers video media bitrate.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) NSInteger maxVideoBitrate</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>Default value is 512.</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/maxDataBitrate" title="maxDataBitrate"></a> <h3 class="method-title"><code><a href="#//api/name/maxDataBitrate">&nbsp;&nbsp;maxDataBitrate</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Used to limit remote peers data bitrate.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) NSInteger maxDataBitrate</code></div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>Default value is 0, meaning not bitrate limit.</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/defaultVideoDevice" title="defaultVideoDevice"></a> <h3 class="method-title"><code><a href="#//api/name/defaultVideoDevice">&nbsp;&nbsp;defaultVideoDevice</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Default camera device @description Get the default camera device, whether it&rsquo;s front or back</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) SKYLINKVideoDevice defaultVideoDevice</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/hasAudioAutoGainControl" title="hasAudioAutoGainControl"></a> <h3 class="method-title"><code><a href="#//api/name/hasAudioAutoGainControl">&nbsp;&nbsp;hasAudioAutoGainControl</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Check/set if audio auto gain control by WebRTC is enabled. @description Enabled by default</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL hasAudioAutoGainControl</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/hasAudioEchoCancellation" title="hasAudioEchoCancellation"></a> <h3 class="method-title"><code><a href="#//api/name/hasAudioEchoCancellation">&nbsp;&nbsp;hasAudioEchoCancellation</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Check/set if audio echo cancellation by WebRTC is enabled. @description Enabled by default</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL hasAudioEchoCancellation</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/hasAudioHighPassFilter" title="hasAudioHighPassFilter"></a> <h3 class="method-title"><code><a href="#//api/name/hasAudioHighPassFilter">&nbsp;&nbsp;hasAudioHighPassFilter</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Check/set if audio high pass filter by WebRTC is enabled. @description Enabled by default</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL hasAudioHighPassFilter</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/hasAudioNoiseSuppression" title="hasAudioNoiseSuppression"></a> <h3 class="method-title"><code><a href="#//api/name/hasAudioNoiseSuppression">&nbsp;&nbsp;hasAudioNoiseSuppression</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Check if audio noise suppression by WebRTC is enabled. @description Enabled by default</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL hasAudioNoiseSuppression</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/roomSize" title="roomSize"></a> <h3 class="method-title"><code><a href="#//api/name/roomSize">&nbsp;&nbsp;roomSize</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Set the room size when creating a new room @description The size of the new room, if not specified, the default size will be small.</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) SKYLINKRoomSize roomSize</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/isAllowTurn" title="isAllowTurn"></a> <h3 class="method-title"><code><a href="#//api/name/isAllowTurn">&nbsp;&nbsp;isAllowTurn</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Whether to allow the TURN server @description Default is YES</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL isAllowTurn</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/isAllowStun" title="isAllowStun"></a> <h3 class="method-title"><code><a href="#//api/name/isAllowStun">&nbsp;&nbsp;isAllowStun</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Whether to allow the TURN server @description Default is YES</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL isAllowStun</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/isAllowHost" title="isAllowHost"></a> <h3 class="method-title"><code><a href="#//api/name/isAllowHost">&nbsp;&nbsp;isAllowHost</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Whether to allow the HOST @description Default is YES</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL isAllowHost</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/enableDNSPreSolving" title="enableDNSPreSolving"></a> <h3 class="method-title"><code><a href="#//api/name/enableDNSPreSolving">&nbsp;&nbsp;enableDNSPreSolving</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Whether to apply the ICE filters @description Default is NO</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL enableDNSPreSolving</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/enableIPv6Filter" title="enableIPv6Filter"></a> <h3 class="method-title"><code><a href="#//api/name/enableIPv6Filter">&nbsp;&nbsp;enableIPv6Filter</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Whether to filer out all the IPv6 servers @description Default is NO</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL enableIPv6Filter</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/isMirrorLocalFrontCameraView" title="isMirrorLocalFrontCameraView"></a> <h3 class="method-title"><code><a href="#//api/name/isMirrorLocalFrontCameraView">&nbsp;&nbsp;isMirrorLocalFrontCameraView</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Mirror local front camera view @description Default is NO</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL isMirrorLocalFrontCameraView</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/defaultCameraVideoFps" title="defaultCameraVideoFps"></a> <h3 class="method-title"><code><a href="#//api/name/defaultCameraVideoFps">&nbsp;&nbsp;defaultCameraVideoFps</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Default values at which to obtain camera video fps when video device is started @description Default is DEFAULT_VIDEO_FPS</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) NSInteger defaultCameraVideoFps</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/captureSessionPreset" title="captureSessionPreset"></a> <h3 class="method-title"><code><a href="#//api/name/captureSessionPreset">&nbsp;&nbsp;captureSessionPreset</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Default values at which to obtain video, when video device is started @description Available values AVCaptureSessionPresetLow, AVCaptureSessionPreset640x480, AVCaptureSessionPreset352x288, AVCaptureSessionPreset1280x720, AVCaptureSessionPresetHigh, AVCaptureSessionPresetPhoto, AVCaptureSessionPreset1920x1080 Default is AVCaptureSessionPreset640x480</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, copy) AVCaptureSessionPreset _Nullable captureSessionPreset</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/videoResNumWaitMs" title="videoResNumWaitMs"></a> <h3 class="method-title"><code><a href="#//api/name/videoResNumWaitMs">&nbsp;&nbsp;videoResNumWaitMs</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Automatic video resolution @description ms to wait before checking again</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) NSInteger videoResNumWaitMs</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/isReportVideoResolutionOnVideoChange" title="isReportVideoResolutionOnVideoChange"></a> <h3 class="method-title"><code><a href="#//api/name/isReportVideoResolutionOnVideoChange">&nbsp;&nbsp;isReportVideoResolutionOnVideoChange</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Automatic video resolution @description Will report when video changes</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL isReportVideoResolutionOnVideoChange</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/isAllowIceRestart" title="isAllowIceRestart"></a> <h3 class="method-title"><code><a href="#//api/name/isAllowIceRestart">&nbsp;&nbsp;isAllowIceRestart</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Whether to allow the ICE server restart @description Default is NO</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) BOOL isAllowIceRestart</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/networkTransport" title="networkTransport"></a> <h3 class="method-title"><code><a href="#//api/name/networkTransport">&nbsp;&nbsp;networkTransport</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Custom transport values for ICE candidates @description If any invalid value is set, networkTransport will be set to empty</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) NetworkTransport networkTransport</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/preferredAudioCodec" title="preferredAudioCodec"></a> <h3 class="method-title"><code><a href="#//api/name/preferredAudioCodec">&nbsp;&nbsp;preferredAudioCodec</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Preferred audio codec used @description Default is OPUS</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) SKYLINKAudioCodec preferredAudioCodec</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/preferredVideoCodec" title="preferredVideoCodec"></a> <h3 class="method-title"><code><a href="#//api/name/preferredVideoCodec">&nbsp;&nbsp;preferredVideoCodec</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Preferred video codec info used @description Default is info with name kRTCVideoCodecVp8Name</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) SkylinkVideoCodec preferredVideoCodec</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/reconnectAttempts" title="reconnectAttempts"></a> <h3 class="method-title"><code><a href="#//api/name/reconnectAttempts">&nbsp;&nbsp;reconnectAttempts</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>xxx @description Default is -1 which is infinite, if you don&rsquo;t want to reconnect, set it to 0</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) NSInteger reconnectAttempts</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/reconnectionDelay" title="reconnectionDelay"></a> <h3 class="method-title"><code><a href="#//api/name/reconnectionDelay">&nbsp;&nbsp;reconnectionDelay</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>xxx @description This should be positive value, otherwise it will be set to 0</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) CGFloat reconnectionDelay</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/preferredTransport" title="preferredTransport"></a> <h3 class="method-title"><code><a href="#//api/name/preferredTransport">&nbsp;&nbsp;preferredTransport</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>xxx @description xxx</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) SocketIOTransport preferredTransport</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/maxVideoUser" title="maxVideoUser"></a> <h3 class="method-title"><code><a href="#//api/name/maxVideoUser">&nbsp;&nbsp;maxVideoUser</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>xxx @description xxx</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) NSInteger maxVideoUser</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/localVideoQuality" title="localVideoQuality"></a> <h3 class="method-title"><code><a href="#//api/name/localVideoQuality">&nbsp;&nbsp;localVideoQuality</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>set quality of local video from 1 to 5 @description default value is 3</p> </div> <div class="method-subsection method-declaration"><code>@property (nonatomic, assign) NSInteger localVideoQuality</code></div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/getTimeoutWithEventType:" title="getTimeoutWithEventType:"></a> <h3 class="method-title"><code><a href="#//api/name/getTimeoutWithEventType:">&ndash;&nbsp;getTimeoutWithEventType:</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Get the timeout value for an action</p> </div> <div class="method-subsection method-declaration"><code>- (CGFloat)getTimeoutWithEventType:(SkylinkAction)<em>skylinkAction</em></code></div> <div class="method-subsection arguments-section parameters"> <h4 class="method-subtitle parameter-title">Parameters</h4> <table class="argument-def parameter-def"> <tr> <th scope="row" class="argument-name"><code>skylinkAction</code></th> <td><p>A pre-defined action like send file request action</p></td> </tr> </table> </div> <div class="method-subsection return"> <h4 class="method-subtitle parameter-title">Return Value</h4> <p>The timeout limit</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/setTimeout:skylinkAction:" title="setTimeout:skylinkAction:"></a> <h3 class="method-title"><code><a href="#//api/name/setTimeout:skylinkAction:">&ndash;&nbsp;setTimeout:skylinkAction:</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Set the timeout value for an action</p> </div> <div class="method-subsection method-declaration"><code>- (void)setTimeout:(CGFloat)<em>timeout</em> skylinkAction:(SkylinkAction)<em>skylinkAction</em></code></div> <div class="method-subsection arguments-section parameters"> <h4 class="method-subtitle parameter-title">Parameters</h4> <table class="argument-def parameter-def"> <tr> <th scope="row" class="argument-name"><code>timeout</code></th> <td><p>The timeout limit</p></td> </tr> <tr> <th scope="row" class="argument-name"><code>skylinkAction</code></th> <td><p>A pre-defined action like send file request action</p></td> </tr> </table> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/setAudioVideoReceiveConfig:" title="setAudioVideoReceiveConfig:"></a> <h3 class="method-title"><code><a href="#//api/name/setAudioVideoReceiveConfig:">&ndash;&nbsp;setAudioVideoReceiveConfig:</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Set config for receive media</p> </div> <div class="method-subsection method-declaration"><code>- (void)setAudioVideoReceiveConfig:(AudioVideoConfig)<em>audioVideoConfig</em></code></div> <div class="method-subsection arguments-section parameters"> <h4 class="method-subtitle parameter-title">Parameters</h4> <table class="argument-def parameter-def"> <tr> <th scope="row" class="argument-name"><code>audioVideoConfig</code></th> <td><p>Configuration of receive media</p></td> </tr> </table> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/setAudioVideoSendConfig:" title="setAudioVideoSendConfig:"></a> <h3 class="method-title"><code><a href="#//api/name/setAudioVideoSendConfig:">&ndash;&nbsp;setAudioVideoSendConfig:</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Set config for send media</p> </div> <div class="method-subsection method-declaration"><code>- (void)setAudioVideoSendConfig:(AudioVideoConfig)<em>audioVideoConfig</em></code></div> <div class="method-subsection arguments-section parameters"> <h4 class="method-subtitle parameter-title">Parameters</h4> <table class="argument-def parameter-def"> <tr> <th scope="row" class="argument-name"><code>audioVideoConfig</code></th> <td><p>Configuration of send media</p></td> </tr> </table> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/getMaxRemotePeersConnectedWithAudioVideoConfig:" title="getMaxRemotePeersConnectedWithAudioVideoConfig:"></a> <h3 class="method-title"><code><a href="#//api/name/getMaxRemotePeersConnectedWithAudioVideoConfig:">&ndash;&nbsp;getMaxRemotePeersConnectedWithAudioVideoConfig:</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Get max allowed peers in a room by the config</p> </div> <div class="method-subsection method-declaration"><code>- (NSInteger)getMaxRemotePeersConnectedWithAudioVideoConfig:(AudioVideoConfig)<em>audioVideoConfig</em></code></div> <div class="method-subsection arguments-section parameters"> <h4 class="method-subtitle parameter-title">Parameters</h4> <table class="argument-def parameter-def"> <tr> <th scope="row" class="argument-name"><code>audioVideoConfig</code></th> <td><p>The config whether the room is audio or video, etc.</p></td> </tr> </table> </div> <div class="method-subsection return"> <h4 class="method-subtitle parameter-title">Return Value</h4> <p>The max peer count</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/setMaxRemotePeersConnected:audioVideoConfig:" title="setMaxRemotePeersConnected:audioVideoConfig:"></a> <h3 class="method-title"><code><a href="#//api/name/setMaxRemotePeersConnected:audioVideoConfig:">&ndash;&nbsp;setMaxRemotePeersConnected:audioVideoConfig:</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Set max allowed peers in a room by the config</p> </div> <div class="method-subsection method-declaration"><code>- (void)setMaxRemotePeersConnected:(NSInteger)<em>maxPeersConnected</em> audioVideoConfig:(AudioVideoConfig)<em>audioVideoConfig</em></code></div> <div class="method-subsection arguments-section parameters"> <h4 class="method-subtitle parameter-title">Parameters</h4> <table class="argument-def parameter-def"> <tr> <th scope="row" class="argument-name"><code>maxPeersConnected</code></th> <td><p>Max allowed peers in the room</p></td> </tr> <tr> <th scope="row" class="argument-name"><code>audioVideoConfig</code></th> <td><p>The config whether the room is audio or video, etc.</p></td> </tr> </table> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div><div class="section-method"> <a name="//api/name/setAdvancedOptionWithKey:value:" title="setAdvancedOptionWithKey:value:"></a> <h3 class="method-title"><code><a href="#//api/name/setAdvancedOptionWithKey:value:">&ndash;&nbsp;setAdvancedOptionWithKey:value:</a></code> </h3> <div class="method-info"> <div class="pointy-thing"></div> <div class="method-info-container"> <div class="method-subsection brief-description"> <p>Optional configuration for advanced users.</p> </div> <div class="method-subsection method-declaration"><code>- (void)setAdvancedOptionWithKey:(null_unspecified NSString *)<em>key</em> value:(null_unspecified id)<em>value</em></code></div> <div class="method-subsection arguments-section parameters"> <h4 class="method-subtitle parameter-title">Parameters</h4> <table class="argument-def parameter-def"> <tr> <th scope="row" class="argument-name"><code>key</code></th> <td><p>the key</p></td> </tr> <tr> <th scope="row" class="argument-name"><code>value</code></th> <td><p>the bool value</p></td> </tr> </table> </div> <div class="method-subsection discussion-section"> <h4 class="method-subtitle">Discussion</h4> <p>The key and associated settings values which you can get from Temasys support</p> </div> <div class="method-subsection declared-in-section"> <h4 class="method-subtitle">Declared In</h4> <p><code class="declared-in-ref">SKYLINKConnection.h</code></p> </div> </div> </div> </div> </div> </div> </main> <footer> <div class="footer-copyright"> <p class="copyright">Copyright &copy; 2021 Temasys Communications. All rights reserved. Updated: 2021-01-11</p> <p class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.2.1 (build 1334)</a>.</p> </div> </footer> </div> </div> </article> <script src="../js/script.js"></script> </body> </html>
{ "content_hash": "54ed7aa4f4d03cd41cb8d3138f5b3ce8", "timestamp": "", "source": "github", "line_count": 2243, "max_line_length": 212, "avg_line_length": 22.655818100757912, "alnum_prop": 0.645787826908318, "repo_name": "Temasys/SKYLINK-iOS", "id": "11e073903bd258fafd0d92ca14ca5296371e4793", "size": "50817", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "docs/html/Classes/SKYLINKConnectionConfig.html", "mode": "33188", "license": "mit", "language": [ { "name": "C", "bytes": "880" }, { "name": "JavaScript", "bytes": "3585" }, { "name": "Objective-C", "bytes": "206783" }, { "name": "Ruby", "bytes": "1931" } ], "symlink_target": "" }
<HTML><HEAD> <TITLE>Review for Hercules (1997)</TITLE> <LINK REL="STYLESHEET" TYPE="text/css" HREF="/ramr.css"> </HEAD> <BODY BGCOLOR="#FFFFFF" TEXT="#000000"> <H1 ALIGN="CENTER" CLASS="title"><A HREF="/Title?0119282">Hercules (1997)</A></H1><H3 ALIGN=CENTER>reviewed by<BR><A HREF="/ReviewsBy?John+Bauer">John Bauer</A></H3><HR WIDTH="40%" SIZE="4"> <PRE> HERCULES A film review by John Bauer Copyright 1997 John Bauer</PRE> <PRE>*** (out of 4)</PRE> <P>I've been spoiled by THE LION KING. With that film, Disney proved that they could make an animated feature that was as multi-layered as any film -- witty, moving, at times breathtaking to look at, and with a song score that at its best enhanced the emotional mood. ...Oh yeah, and kids liked it, too. No wonder it's the most popular film in the studio's history. It also set a standard that more and more seems unlikely to be matched. For as much as I appreciated the special merits and envelope-pushing spirit of POCAHONTAS and THE HUNCHBACK OF NOTRE DAME, neither came anywhere near the same level of achievement -- in part because the studio lost sight of its target audience of children in its quest for LION-sized grosses.</P> <P>Perhaps realizing that their reach was exceeding their grasp, Disney has crafted their latest opus, HERCULES, with more modest goals in mind. Rather than try to turn an adult literary classic like HUNCHBACK into kiddie fare, its subject is one children have been enthralled with for generations. Instead of using revisionist history to teach lessons in respect for other cultures and the environment, as in POCAHONTAS, the moral of HERCULES is a more straightforward (though still timely) message about the true nature of heroism. By retrenching from the outer reaches of ambition and maintaining a fairly light-hearted tone throughout, however, this latest contender for a place in every child's video collection feels a tad too safe.</P> <P>The suspicion that HERCULES may not be a giant-killer among movies is planted early on. The opening 15 minutes or so are the most uninvolving of any Disney animated film in recent memory. After a brief but mildly amusing setup by the 5-woman Greek chorus-cum-girl group, the scene shifts to Olympus, where Zeus is showing off his newborn son. What might have been an amusing look at life among the gods turns out to be a tedious exercise in story exposition. This is more akin to how Disney's imitators behave, those that haven't quite figured out that animated success lies less in how the film is drawn than in how the tale is told. It is disconcerting to see the standard-bearer doing this. Maybe they should've watched the opening of THE LION KING a few times for inspiration.</P> <P>Things improve as Herc becomes a teen, but are derailed again as he sings a trite song about finding his place in the world. Didn't Belle in BEAUTY AND THE BEAST sing one of those? Doesn't every Disney protagonist feel alone in the world? How about a song about being a hero instead? (Doesn't Hercules have any idols?) Once Hercules reaches heroic proportions (with the only intermittently amusing help of Phil, a satyr voiced by Danny DeVito), the film finally gets in gear, though it takes another uninspired transition ("Let's go to Thebes.") to get us there.</P> <P>As Hercules begins in earnest to prove himself by battling the forces of Hades, the film assumes a higher level of interest more customary for Disney. The songs are fresher (including a funny if all-too-brief take on fame by the chorus), the animation more intriguing (as when the screen fills with the menace of a multi-headed monster), the humor more pointed (sometimes literally). And we are introduced to a Disney female like no other, the sarcastic and jaded Meg, marvelously voiced by Susan Egan. Though others may prefer the devilish work of James Woods as Hades, for my money the tough but vulnerable Meg steals the show.</P> <P>By the time the final credits roll, HERCULES has managed to overcome its plodding beginning and occasional lapses to make you feel warm all over. Disney's admirable record for maintaining a level of quality that is never less than good is upheld. But unlike THE LION KING, it's easy to spot ways in which this film could have been a whole lot better. ...Oh yeah, the kids'll like it.</P> <PRE>June 29, 1997 <A HREF="mailto:<drifterusa@aol.com>"><drifterusa@aol.com></A></PRE> <HR><P CLASS=flush><SMALL>The review above was posted to the <A HREF="news:rec.arts.movies.reviews">rec.arts.movies.reviews</A> newsgroup (<A HREF="news:de.rec.film.kritiken">de.rec.film.kritiken</A> for German reviews).<BR> The Internet Movie Database accepts no responsibility for the contents of the review and has no editorial control. Unless stated otherwise, the copyright belongs to the author.<BR> Please direct comments/criticisms of the review to relevant newsgroups.<BR> Broken URLs inthe reviews are the responsibility of the author.<BR> The formatting of the review is likely to differ from the original due to ASCII to HTML conversion. </SMALL></P> <P ALIGN=CENTER>Related links: <A HREF="/Reviews/">index of all rec.arts.movies.reviews reviews</A></P> </P></BODY></HTML>
{ "content_hash": "2094c8494c8a82174effd79666ee4dda", "timestamp": "", "source": "github", "line_count": 80, "max_line_length": 190, "avg_line_length": 67.2375, "alnum_prop": 0.7503253392823945, "repo_name": "xianjunzhengbackup/code", "id": "0e74b4fddee9e430a54edf2a4e7573f92cae306b", "size": "5379", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "data science/machine_learning_for_the_web/chapter_4/movie/8051.html", "mode": "33261", "license": "mit", "language": [ { "name": "BitBake", "bytes": "113" }, { "name": "BlitzBasic", "bytes": "256" }, { "name": "CSS", "bytes": "49827" }, { "name": "HTML", "bytes": "157006325" }, { "name": "JavaScript", "bytes": "14029" }, { "name": "Jupyter Notebook", "bytes": "4875399" }, { "name": "Mako", "bytes": "2060" }, { "name": "Perl", "bytes": "716" }, { "name": "Python", "bytes": "874414" }, { "name": "R", "bytes": "454" }, { "name": "Shell", "bytes": "3984" } ], "symlink_target": "" }
using System; namespace CSharpDocumentation { [AttributeUsage(AttributeTargets.All, Inherited = false, AllowMultiple = false)] public class SummaryAttribute : Attribute { public string Description { get; private set; } public SummaryAttribute(string description) { Description = description; } } }
{ "content_hash": "03317752180cf7bf704e34c0c6e9ae4d", "timestamp": "", "source": "github", "line_count": 15, "max_line_length": 84, "avg_line_length": 24.066666666666666, "alnum_prop": 0.6565096952908587, "repo_name": "Wenzil/CSharpDocumentation", "id": "5e73264e8c9a54c64ad298fda245accf56fe72e9", "size": "363", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "SummaryAttribute.cs", "mode": "33188", "license": "mit", "language": [ { "name": "C#", "bytes": "20906" }, { "name": "XML", "bytes": "2886" } ], "symlink_target": "" }
package player; import java.util.ResourceBundle; import authoring.components.ComponentMaker; import game_data.Game; import game_data.GameData; import javafx.geometry.Pos; import javafx.scene.Scene; import javafx.scene.layout.BorderPane; import javafx.scene.layout.VBox; import javafx.stage.Stage; public class PlayerMenu { private ResourceBundle resources = ResourceBundle.getBundle("resources/Player"); private BorderPane root; private Stage stage; private Game game; private GameData data; private String gameFolderPath; public PlayerMenu(String gameFolderPath){ this.gameFolderPath = gameFolderPath; setupStage(); setupScene(); } public PlayerMenu(Stage stage, String gameFolderPath){ this.gameFolderPath = gameFolderPath; this.stage = stage; stage.setScene(createScene()); setupScene(); } private void setupData(){ game = new Game(); data = new GameData(); } private void load(String filename){ game = data.loadGame(filename); //TODO: Load info into menus } private void setupStage(){ stage = new Stage(); stage.setTitle(resources.getString("MainTitle")); stage.setScene(createScene()); stage.show(); } private Scene createScene(){ root = new BorderPane(); Scene scene = new Scene(root, 1000, 600); scene.getStylesheets().add(resources.getString("StylesheetPath")); return scene; } private void setupScene(){ ComponentMaker componentMaker = new ComponentMaker(resources); VBox menu = new VBox(8); menu.getChildren().addAll(componentMaker.makeButton("StartButton", e -> stage.setScene(new LoadMenu(stage, gameFolderPath).display()), true), componentMaker.makeButton("AchievementsButton", e -> stage.setScene(new AchievementsMenu(stage, gameFolderPath).display()), true), componentMaker.makeButton("OptionsButton", e -> stage.setScene(new OptionsMenu(stage, gameFolderPath).display()), true), componentMaker.makeButton("InfoButton", e -> stage.setScene(new InfoMenu(stage, gameFolderPath).display()), true), componentMaker.makeButton("ExitButton", e -> stage.close(), true)); root.setCenter(menu); menu.setAlignment(Pos.CENTER); menu.maxWidthProperty().bind(stage.widthProperty().multiply(0.3)); } }
{ "content_hash": "e9eff992c36b8133d821362e5b9a328e", "timestamp": "", "source": "github", "line_count": 74, "max_line_length": 143, "avg_line_length": 29.905405405405407, "alnum_prop": 0.7428829643018527, "repo_name": "JamesShackford/voogasalad_duwaldorf", "id": "0799b8fb92a1526e87d884cb01073963c5d87e20", "size": "2213", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/player/PlayerMenu.java", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "1506" }, { "name": "HTML", "bytes": "823" }, { "name": "Java", "bytes": "255980" } ], "symlink_target": "" }
<?xml version="1.0" encoding="UTF-8"?> <!-- Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. --><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <modelVersion>4.0.0</modelVersion> <parent> <groupId>org.apache.camel</groupId> <artifactId>camel-parent</artifactId> <version>2.6.0</version> <relativePath>../parent</relativePath> </parent> <artifactId>tooling</artifactId> <name>Camel :: Tooling</name> <description>Camel Tooling</description> <packaging>pom</packaging> <modules> <module>maven</module> <module>archetypes</module> <module>camel-manual</module> </modules> </project>
{ "content_hash": "a48d6d34d198e96d40c5f52348dd55c3", "timestamp": "", "source": "github", "line_count": 39, "max_line_length": 204, "avg_line_length": 38.92307692307692, "alnum_prop": 0.730566534914361, "repo_name": "kingargyle/turmeric-bot", "id": "20f3fd0fcb2eac8f8002f4887daa53c6c5f3d30d", "size": "1518", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "tooling/pom.xml", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "ActionScript", "bytes": "20202" }, { "name": "Batchfile", "bytes": "108" }, { "name": "CSS", "bytes": "220587" }, { "name": "FreeMarker", "bytes": "11350" }, { "name": "Groovy", "bytes": "2711" }, { "name": "HTML", "bytes": "308151" }, { "name": "Java", "bytes": "19316639" }, { "name": "JavaScript", "bytes": "4172468" }, { "name": "PHP", "bytes": "88860" }, { "name": "Protocol Buffer", "bytes": "578" }, { "name": "Ruby", "bytes": "4814" }, { "name": "Scala", "bytes": "185055" }, { "name": "Shell", "bytes": "351" }, { "name": "Tcl", "bytes": "2969" }, { "name": "XQuery", "bytes": "332" }, { "name": "XSLT", "bytes": "37282" } ], "symlink_target": "" }
function GeneralOptions(varargin) % handle input fig=varargin{3}; updatefunc=varargin{4}; % access data data=get(fig,'UserData'); % prompt user label={'Wavelength:','Velocity scale factor:','Velocity level offset:'}; default={data.wavelength, data.vscale, data.vlevel}; button=[]; options.root=fig; options.location='center'; answer=datadlg('General parameters',label,default,button,options); if isempty(answer) return end wavelength=sscanf(answer{1},'%g',1); vscale=sscanf(answer{2},'%g',1); vlevel=sscanf(answer{3},'%g',1); if isempty(wavelength) || isempty(vscale) GeneralOptions([],[],varargin{:}); return end % look for changes change=(data.wavelength~=wavelength)|(data.vscale~=vscale)|(data.vlevel~=vlevel); if change %data.update.experimentSTFT=true; %data.update.history=true; data.update.experimentVariable=true; data.wavelength=wavelength; data.vscale=vscale; data.vlevel=vlevel; set(fig,'UserData',data); feval(updatefunc,fig); end
{ "content_hash": "0bde8cd15a121e589bd9a9c5737f8d58", "timestamp": "", "source": "github", "line_count": 39, "max_line_length": 81, "avg_line_length": 25.512820512820515, "alnum_prop": 0.7175879396984924, "repo_name": "SMASHtoolbox/release", "id": "23c4842ecf4166efa6680d0aef209a41aa875d93", "size": "995", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "programs/SIRHEN/private/GeneralOptions.m", "mode": "33188", "license": "bsd-3-clause", "language": [ { "name": "HTML", "bytes": "179745" }, { "name": "M", "bytes": "3218" }, { "name": "MATLAB", "bytes": "3038943" }, { "name": "Objective-C", "bytes": "1241" } ], "symlink_target": "" }
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"> <html> <head> <script src="/js/jquery-1.4.2.min.js"></script> <script src="/js/helpers.js"></script> <script src="/js/analytics.js"></script> <script src="/js/aggregates.js"></script> <title>Hummingbird</title> <link rel="stylesheet" media="all" href="/css/main.css" /> </head> <body> <h1>Hummingbird</h1> <div id="pageviews_last_hour" class="hummingbird_graph" id="log"> <h2><span class="value"></span> Pageviews in the last hour</h2> <div class="axis_left"></div> <canvas width="760" height="216"></canvas> <div class="axis_right"></div> </div> <div style="clear: both;"></div> <div id="pageviews_last_day" class="hummingbird_graph" id="log"> <h2><span class="value"></span> Pageviews in the last day</h2> <div class="axis_left"></div> <canvas width="760" height="216"></canvas> <div class="axis_right"></div> </div> <div style="clear: both;"></div> <div id="pageviews_last_week" class="hummingbird_graph" id="log"> <h2><span class="value"></span> Pageviews in the last week</h2> <div class="axis_left"></div> <canvas width="760" height="216"></canvas> <div class="axis_right"></div> </div> </body> </html>
{ "content_hash": "70247269dc07b994d51597f9380d6094", "timestamp": "", "source": "github", "line_count": 55, "max_line_length": 67, "avg_line_length": 23.763636363636362, "alnum_prop": 0.6166794185156848, "repo_name": "ryana/sg-stats", "id": "1e231492f9b07d9da65aa27b6b3268ed3e9097ea", "size": "1307", "binary": false, "copies": "3", "ref": "refs/heads/master", "path": "public/aggregates.html", "mode": "33188", "license": "mit", "language": [ { "name": "JavaScript", "bytes": "184494" }, { "name": "Ruby", "bytes": "3008" } ], "symlink_target": "" }
import os, sys sys.path.append(os.path.abspath(os.path.join(os.path.dirname(__file__), '..'))) from flask.ext.script import Manager, Server from opendatabutton import app app.debug = True manager = Manager(app) # Turn on debugger by default and reloader manager.add_command("runserver", Server( use_debugger = True, use_reloader = True, port = 7000, host = '0.0.0.0') ) if __name__ == "__main__": manager.run()
{ "content_hash": "0e1dc04fb9e0a4ed163a0890f9092e00", "timestamp": "", "source": "github", "line_count": 19, "max_line_length": 79, "avg_line_length": 22.94736842105263, "alnum_prop": 0.6628440366972477, "repo_name": "wfyson/OpenDataButton", "id": "7613bed4d5b1268123ddad0bfa9b44b5cafaf0a9", "size": "451", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "server/manage.py", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "20608" }, { "name": "JavaScript", "bytes": "5013" }, { "name": "Python", "bytes": "6140" }, { "name": "Shell", "bytes": "98" } ], "symlink_target": "" }
namespace rlz_lib { // Cross-process mutex to guarantee serialization of RLZ key accesses. class LibMutex { public: LibMutex(); ~LibMutex(); bool failed() const { return !acquired_; } private: bool acquired_; HANDLE mutex_; }; } // namespace rlz_lib #endif // RLZ_WIN_LIB_LIB_MUTEX_H_
{ "content_hash": "416858b1d65238c3a4d5f351af4329e8", "timestamp": "", "source": "github", "line_count": 17, "max_line_length": 70, "avg_line_length": 17.823529411764707, "alnum_prop": 0.6732673267326733, "repo_name": "chromium/chromium", "id": "81b200282c92f372862bd2ab03fc4003f7032941", "size": "536", "binary": false, "copies": "6", "ref": "refs/heads/main", "path": "rlz/win/lib/lib_mutex.h", "mode": "33188", "license": "bsd-3-clause", "language": [], "symlink_target": "" }
<?xml version="1.0" encoding="UTF-8"?> <database defaultIdMethod="native" name="default" namespace="EasyTask\Bundle\WorkflowBundle\Model"> <table name="workflow"> <column name="id" type="INTEGER" primaryKey="true" required="true" autoIncrement="true" description="id, primary key" /> <column name="type" type="VARCHAR" required="true" description="type of the task" /> <column name="name" type="VARCHAR" required="true" description="name" /> <column name="description" type="LONGVARCHAR" required="false" description="description" /> <behavior name="timestampable" /> <index> <index-column name="type"/> </index> </table> <table name="workflow_node"> <column name="id" type="INTEGER" primaryKey="true" required="true" autoIncrement="true" description="id, primary key" /> <column name="workflow_id" type="INTEGER" required="true" description="workflow fk" /> <column name="name" type="VARCHAR" required="true" description="current state name" /> <column name="prev_id" type="VARCHAR" required="false" description="prev state" /> <column name="next_id" type="VARCHAR" required="false" description="next state" /> <column name="current" type="BOOLEAN" required="true" /> <column name="ended" type="BOOLEAN" required="false" default="false" /> <column name="completed_at" type="TIMESTAMP" required="false" description="date on node has been completed" /> <foreign-key foreignTable="workflow" skipSql="true"> <reference local="workflow_id" foreign="id"/> </foreign-key> <foreign-key foreignTable="workflow_node" skipSql="true" phpName="PreviousNode"> <reference local="prev_id" foreign="id"/> </foreign-key> <foreign-key foreignTable="workflow_node" skipSql="true" phpName="NextNode"> <reference local="next_id" foreign="id"/> </foreign-key> <behavior name="timestampable" /> </table> </database>
{ "content_hash": "d6d4c59dbb2b190db734c21398b02a7c", "timestamp": "", "source": "github", "line_count": 38, "max_line_length": 128, "avg_line_length": 53.71052631578947, "alnum_prop": 0.6428221460068594, "repo_name": "Nyxis/Rhea", "id": "9fced6d859e3b0b8e5407cfe483c363da7da23c3", "size": "2041", "binary": false, "copies": "1", "ref": "refs/heads/develop", "path": "src/EasyTask/Bundle/WorkflowBundle/Resources/config/schema/schema.xml", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "35517" }, { "name": "JavaScript", "bytes": "10720" }, { "name": "PHP", "bytes": "512802" }, { "name": "Ruby", "bytes": "3448" } ], "symlink_target": "" }
package com.intel.analytics.bigdl.python.api import java.util.{ArrayList => JArrayList, HashMap => JHashMap, List => JList, Map => JMap} import com.intel.analytics.bigdl._ import com.intel.analytics.bigdl.dataset.{Identity => DIdentity, Sample => JSample, _} import com.intel.analytics.bigdl.nn._ import com.intel.analytics.bigdl.nn.abstractnn._ import com.intel.analytics.bigdl.numeric._ import com.intel.analytics.bigdl.optim.{Optimizer, _} import com.intel.analytics.bigdl.tensor.{Storage, Tensor} import com.intel.analytics.bigdl.tensor.TensorNumericMath.TensorNumeric import com.intel.analytics.bigdl.utils.{Table, _} import com.intel.analytics.bigdl.visualization.{Summary, TrainSummary, ValidationSummary} import com.intel.analytics.bigdl.nn.Zeros import org.apache.spark.api.java.JavaRDD import org.apache.spark.rdd.RDD import java.lang.{Integer, Boolean => JBoolean} import java.nio.ByteOrder import com.intel.analytics.bigdl.nn.Graph._ import com.intel.analytics.bigdl.nn.tf.{Const, Fill, Shape, SplitAndSelect} import com.intel.analytics.bigdl.utils.tf.{TensorflowDataFormat, TensorflowSaver} import scala.collection.JavaConverters._ import scala.language.existentials import scala.reflect.ClassTag /** * [[com.intel.analytics.bigdl.dataset.Sample]] for python. * @param features features * @param label labels * @param featuresShape feature size * @param labelShape label size * @param bigdlType bigdl numeric type */ case class Sample(features: JList[Any], label: JList[Any], featuresShape: JList[Int], labelShape: JList[Int], bigdlType: String) case class JTensor(storage: JList[Any], shape: JList[Int], bigdlType: String) /** * [[ValidationResult]] for python * @param result result * @param totalNum total number * @param method method name */ case class TestResult(val result: Float, totalNum: Int, method: String) object PythonBigDL { def ofFloat(): PythonBigDL[Float] = new PythonBigDL[Float]() def ofDouble(): PythonBigDL[Double] = new PythonBigDL[Double]() } /** * Implementation of Python API for BigDL */ class PythonBigDL[T: ClassTag](implicit ev: TensorNumeric[T]) extends Serializable { private val typeName = { val cls = implicitly[ClassTag[T]].runtimeClass cls.getSimpleName } private def toTable(input: JList[JTensor]): Table = { input.asScala.foldLeft(new Table())((t, jtensor) => t.insert(toTensor(jtensor))) } def jTensorsToActivity(input: JList[JTensor], isTable: Boolean): Activity = { if (input.isEmpty) { throw new IllegalArgumentException("Empty input") } if(isTable) { toTable(input) } else { toTensor(input.iterator().next()) } } def activityToJTensors(outputActivity: Activity): JList[JTensor] = { if (outputActivity.isInstanceOf[Tensor[T]]) { List(toJTensor(outputActivity.toTensor)).asJava } else { outputActivity.toTable.getState().toList.map { pair => (pair._1.asInstanceOf[Int], toJTensor(pair._2.asInstanceOf[Tensor[T]])) }.sortWith(_._1 < _._1).map(pair => pair._2).asJava } } def toPySample(sample: JSample[T]): Sample = { val featureList = sample.feature().contiguous().storage().toArray[T].toList.asJava val labelList = sample.label().contiguous().storage().toArray[T].toList.asJava val cls = implicitly[ClassTag[T]].runtimeClass Sample(featureList.asInstanceOf[JList[Any]], labelList.asInstanceOf[JList[Any]], sample.feature().size().toList.asJava, sample.label().size().toList.asJava, cls.getSimpleName) } def toTensor(jTensor: JTensor): Tensor[T] = { if (jTensor == null) null else { Tensor(jTensor.storage.asScala.map(_.asInstanceOf[T]).toArray, jTensor.shape.asScala.toArray) } } def toJTensor(tensor: Tensor[T]): JTensor = { // clone here in case the the size of storage larger then the size of tensor. val cloneTensor = tensor.clone() JTensor(cloneTensor.storage().toList.map(_.asInstanceOf[Any]).asJava, cloneTensor.size().toList.asJava, typeName) } def testTensor(jTensor: JTensor): JTensor = { val tensor = toTensor(jTensor) toJTensor(tensor) } def toSample(record: Sample): JSample[T] = { require(record.bigdlType == this.typeName, s"record.bigdlType: ${record.bigdlType} == this.typeName: ${this.typeName}") val sample = this.typeName match { case "float" => val feature = Tensor[Float](Storage[Float]( record.features.asInstanceOf[JList[Double]].asScala.map(_.toFloat).toArray[Float]), 1, record.featuresShape.asScala.toArray[Int]) val label = Tensor[Float]( Storage(record.label.asInstanceOf[JList[Double]].asScala.map(_.toFloat).toArray[Float]), 1, record.labelShape.asScala.toArray[Int]) JSample[Float](feature, label) case "double" => val feature = Tensor[Double](Storage[Double]( record.features.asInstanceOf[JList[Double]].asScala.toArray[Double]), 1, record.featuresShape.asScala.toArray[Int]) val label = Tensor[Double]( Storage(record.label.asInstanceOf[JList[Double]].asScala.toArray[Double]), 1, record.labelShape.asScala.toArray[Int]) JSample[Double](feature, label) case t: String => throw new IllegalArgumentException(s"Not supported type: ${t}") } sample.asInstanceOf[JSample[T]] } private def batching(rdd: RDD[Sample], batchSize: Int) : DistributedDataSet[MiniBatch[T]] = { val recordRDD = rdd.map(toSample(_)) (DataSet.rdd(recordRDD) -> SampleToMiniBatch[T](batchSize)) .asInstanceOf[DistributedDataSet[MiniBatch[T]]] } def createSequential(): Sequential[T] = { Sequential[T]() } def createLinear(inputSize: Int, outputSize: Int, withBias: Boolean, wRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null, initWeight: JTensor = null, initBias: JTensor = null, initGradWeight: JTensor = null, initGradBias: JTensor = null): Linear[T] = { Linear[T](inputSize, outputSize, withBias, wRegularizer, bRegularizer, toTensor(initWeight), toTensor(initBias), toTensor(initGradWeight), toTensor(initGradBias)) } def createReLU(ip: Boolean = false): ReLU[T] = { ReLU[T](ip) } def createTanh(): Tanh[T] = { Tanh[T]() } def createTimeDistributed(layer: TensorModule[T]): TimeDistributed[T] = { TimeDistributed[T](layer) } def createRnnCell(inputSize: Int, hiddenSize: Int, activation: TensorModule[T], wRegularizer: Regularizer[T] = null, uRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null): RnnCell[T] = { RnnCell[T](inputSize, hiddenSize, activation, wRegularizer, uRegularizer, bRegularizer) } def createTimeDistributedCriterion(critrn: TensorCriterion[T], sizeAverage: Boolean = false): TimeDistributedCriterion[T] = { TimeDistributedCriterion[T](critrn, sizeAverage) } def createGRU( inputSize: Int, outputSize: Int, p: Double = 0, wRegularizer: Regularizer[T] = null, uRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null): GRU[T] = { GRU[T](inputSize, outputSize, p, wRegularizer, uRegularizer, bRegularizer) } def createLSTM( inputSize: Int, hiddenSize: Int, p: Double = 0, wRegularizer: Regularizer[T] = null, uRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null): LSTM[T] = { LSTM[T](inputSize, hiddenSize, p, wRegularizer, uRegularizer, bRegularizer) } def createLSTMPeephole( inputSize: Int, hiddenSize: Int, p: Double = 0, wRegularizer: Regularizer[T] = null, uRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null): LSTMPeephole[T] = { LSTMPeephole[T](inputSize, hiddenSize, p, wRegularizer, uRegularizer, bRegularizer) } def createRecurrent(): Recurrent[T] = { Recurrent[T]() } def createConvLSTMPeephole( inputSize: Int, outputSize: Int, kernelI: Int, kernelC: Int, stride: Int = 1, wRegularizer: Regularizer[T] = null, uRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null, withPeephole: Boolean = true): ConvLSTMPeephole[T] = { ConvLSTMPeephole[T](inputSize, outputSize, kernelI, kernelC, stride, wRegularizer, uRegularizer, bRegularizer, withPeephole) } def createEcho(): Echo[T] = { Echo[T]() } def createLogSoftMax(): LogSoftMax[T] = { LogSoftMax[T]() } def createSpatialMaxPooling(kW: Int, kH: Int, dW: Int, dH: Int, padW: Int = 0, padH: Int = 0, ceilMode: Boolean = false) : SpatialMaxPooling[T] = { val maxpooling = SpatialMaxPooling[T](kW, kH, dW, dH, padW, padH) if (ceilMode) maxpooling.ceil() else maxpooling } def createSpatialConvolution(nInputPlane: Int, nOutputPlane: Int, kernelW: Int, kernelH: Int, strideW: Int = 1, strideH: Int = 1, padW: Int = 0, padH: Int = 0, nGroup: Int = 1, propagateBack: Boolean = true, wRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null, initWeight: JTensor = null, initBias: JTensor = null, initGradWeight: JTensor = null, initGradBias: JTensor = null, withBias: Boolean = true ) : SpatialConvolution[T] = { SpatialConvolution[T](nInputPlane, nOutputPlane, kernelW, kernelH, strideW, strideH, padW, padH, nGroup, propagateBack, wRegularizer, bRegularizer, toTensor(initWeight), toTensor(initBias), toTensor(initGradWeight), toTensor(initGradBias), withBias ) } def createReshape(size: JList[Int], batchMode: JBoolean = null): Reshape[T] = { val mappedBatchMode = batchMode match { case JBoolean.TRUE => Some(true) case JBoolean.FALSE => Some(false) case _ => None } Reshape(size.asScala.toArray, mappedBatchMode) } def createConcat(dimension: Int): Concat[T] = { Concat[T](dimension) } def createSpatialAveragePooling(kW: Int, kH: Int, dW: Int = 1, dH: Int = 1, padW: Int = 0, padH: Int = 0, ceilMode: Boolean = false, countIncludePad: Boolean = true, divide: Boolean = true) : SpatialAveragePooling[T] = { SpatialAveragePooling[T](kW, kH, dW, dH, padW, padH, ceilMode, countIncludePad, divide) } def createSpatialBatchNormalization(nOutput: Int, eps: Double = 1e-5, momentum: Double = 0.1, affine: Boolean = true, initWeight: JTensor = null, initBias: JTensor = null, initGradWeight: JTensor = null, initGradBias: JTensor = null) : SpatialBatchNormalization[T] = { SpatialBatchNormalization[T](nOutput, eps, momentum, affine, toTensor(initWeight), toTensor(initBias), toTensor(initGradWeight), toTensor(initBias)) } def createSpatialCrossMapLRN(size: Int = 5, alpha: Double = 1.0, beta: Double = 0.75, k: Double = 1.0) : SpatialCrossMapLRN[T] = { SpatialCrossMapLRN[T](size, alpha, beta, k) } def createDropout(initP: Double = 0.5, inplace: Boolean = false, scale: Boolean = true) : Dropout[T] = { Dropout[T](initP, inplace, scale) } def createView(sizes: JList[Int], num_input_dims: Int = 0): View[T] = { View[T](sizes.asScala.toArray).setNumInputDims(num_input_dims) } def createAbs() : Abs[T] = { Abs[T]() } def createAdd(inputSize: Int) : Add[T] = { Add[T](inputSize) } def createAddConstant(constant_scalar: Double, inplace: Boolean = false) : AddConstant[T] = { AddConstant[T](constant_scalar, inplace) } def createBatchNormalization(nOutput: Int, eps: Double = 1e-5, momentum: Double = 0.1, affine: Boolean = true, initWeight: JTensor = null, initBias: JTensor = null, initGradWeight: JTensor = null, initGradBias: JTensor = null) : BatchNormalization[T] = { BatchNormalization[T](nOutput, eps, momentum, affine, toTensor(initWeight), toTensor(initBias), toTensor(initGradWeight), toTensor(initGradBias)) } def createBilinear(inputSize1: Int, inputSize2: Int, outputSize: Int, biasRes: Boolean = true, wRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null) : Bilinear[T] = { Bilinear[T](inputSize1, inputSize2, outputSize, biasRes, wRegularizer, bRegularizer) } def createBottle(module: AbstractModule[Activity, Activity, T], nInputDim: Int = 2, nOutputDim1: Int = Int.MaxValue) : Bottle[T] = { Bottle[T](module, nInputDim, nOutputDim1) } def createCAdd(size: JList[Int], bRegularizer: Regularizer[T] = null) : CAdd[T] = { CAdd[T](size.asScala.toArray, bRegularizer) } def createCAddTable(inplace: Boolean = false) : CAddTable[T] = { CAddTable[T](inplace) } def createCDivTable() : CDivTable[T] = { CDivTable[T]() } def createCMaxTable() : CMaxTable[T] = { CMaxTable[T]() } def createCMinTable() : CMinTable[T] = { CMinTable[T]() } def createCMul(size: JList[Int], wRegularizer: Regularizer[T] = null) : CMul[T] = { CMul[T](size.asScala.toArray, wRegularizer) } def createCMulTable() : CMulTable[T] = { CMulTable[T]() } def createCSubTable() : CSubTable[T] = { CSubTable[T]() } def createClamp(min: Int, max: Int) : Clamp[T] = { Clamp[T](min, max) } def createContiguous() : Contiguous[T] = { Contiguous[T]() } def createCosine(inputSize: Int, outputSize: Int) : Cosine[T] = { Cosine[T](inputSize, outputSize) } def createCosineDistance() : CosineDistance[T] = { CosineDistance[T]() } def createCosineDistanceCriterion(sizeAverage: Boolean = true) : CosineDistanceCriterion[T] = { CosineDistanceCriterion[T](sizeAverage) } def createDiceCoefficientCriterion(sizeAverage: Boolean = true, epsilon: Float = 1.0f) : DiceCoefficientCriterion[T] = { DiceCoefficientCriterion[T](sizeAverage, epsilon) } def createDotProduct() : DotProduct[T] = { DotProduct[T]() } def createELU(alpha: Double = 1.0, inplace: Boolean = false) : ELU[T] = { ELU[T](alpha, inplace) } def createEuclidean(inputSize: Int, outputSize: Int, fastBackward: Boolean = true) : Euclidean[T] = { Euclidean[T](inputSize, outputSize, fastBackward) } def createExp() : Exp[T] = { Exp[T]() } def createFlattenTable() : FlattenTable[T] = { FlattenTable[T]() } def createGradientReversal(lambda: Double = 1) : GradientReversal[T] = { GradientReversal[T](lambda) } def createHardShrink(lambda: Double = 0.5) : HardShrink[T] = { HardShrink[T](lambda) } def createHardTanh(minValue: Double = -1, maxValue: Double = 1, inplace: Boolean = false) : HardTanh[T] = { HardTanh[T](minValue, maxValue, inplace) } def createIndex(dimension: Int) : Index[T] = { Index[T](dimension) } def createInferReshape(size: JList[Int], batchMode: Boolean = false) : InferReshape[T] = { InferReshape[T](size.asScala.toArray, batchMode) } def createJoinTable(dimension: Int, nInputDims: Int) : JoinTable[T] = { JoinTable[T](dimension, nInputDims) } def createL1Cost() : L1Cost[T] = { L1Cost[T]() } def createL1Penalty(l1weight: Int, sizeAverage: Boolean = false, provideOutput: Boolean = true) : L1Penalty[T] = { L1Penalty[T](l1weight, sizeAverage, provideOutput) } def createLeakyReLU(negval: Double = 0.01, inplace: Boolean = false) : LeakyReLU[T] = { LeakyReLU[T](negval, inplace) } def createLog() : Log[T] = { Log[T]() } def createLogSigmoid() : LogSigmoid[T] = { LogSigmoid[T]() } def createLookupTable(nIndex: Int, nOutput: Int, paddingValue: Double = 0, maxNorm: Double = Double.MaxValue, normType: Double = 2.0, shouldScaleGradByFreq: Boolean = false, wRegularizer: Regularizer[T] = null) : LookupTable[T] = { LookupTable[T](nIndex, nOutput, paddingValue, maxNorm, normType, shouldScaleGradByFreq, wRegularizer) } def createMM(transA: Boolean = false, transB: Boolean = false) : MM[T] = { MM[T](transA, transB) } def createMV(trans: Boolean = false) : MV[T] = { MV[T](trans) } def createMapTable(module: AbstractModule[Activity, Activity, T] = null) : MapTable[T] = { MapTable[T](module) } def createMaskedSelect() : MaskedSelect[T] = { MaskedSelect[T]() } def createMax(dim: Int = 1, numInputDims: Int = Int.MinValue) : Max[T] = { Max[T](dim, numInputDims) } def createMean(dimension: Int = 1, nInputDims: Int = -1, squeeze: Boolean = true) : Mean[T] = { Mean[T](dimension, nInputDims, squeeze) } def createMin(dim: Int = 1, numInputDims: Int = Int.MinValue) : Min[T] = { Min[T](dim, numInputDims) } def createMixtureTable(dim: Int = Int.MaxValue) : MixtureTable[T] = { MixtureTable[T](dim) } def createMul() : Mul[T] = { Mul[T]() } def createMulConstant(scalar: Double, inplace: Boolean = false) : MulConstant[T] = { MulConstant[T](scalar, inplace) } def createNarrow(dimension: Int, offset: Int, length: Int = 1) : Narrow[T] = { Narrow[T](dimension, offset, length) } def createNarrowTable(offset: Int, length: Int = 1) : NarrowTable[T] = { NarrowTable[T](offset, length) } def createNormalize(p: Double, eps: Double = 1e-10) : Normalize[T] = { Normalize[T](p, eps) } def createPReLU(nOutputPlane: Int = 0) : PReLU[T] = { PReLU[T](nOutputPlane) } def createPadding(dim: Int, pad: Int, nInputDim: Int, value: Double = 0.0, nIndex: Int = 1) : Padding[T] = { Padding[T](dim, pad, nInputDim, value, nIndex) } def createPairwiseDistance(norm: Int = 2) : PairwiseDistance[T] = { PairwiseDistance[T](norm) } def createParallelTable() : ParallelTable[T] = { ParallelTable[T]() } def createPower(power: Double, scale: Double = 1, shift: Double = 0) : Power[T] = { Power[T](power, scale, shift) } def createRReLU(lower: Double = 1.0 / 8, upper: Double = 1.0 / 3, inplace: Boolean = false) : RReLU[T] = { RReLU[T](lower, upper, inplace) } def createReLU6(inplace: Boolean = false) : ReLU6[T] = { ReLU6[T](inplace) } def createReplicate(nFeatures: Int, dim: Int = 1, nDim: Int = Int.MaxValue) : Replicate[T] = { Replicate[T](nFeatures, dim, nDim) } def createRoiPooling(pooled_w: Int, pooled_h: Int, spatial_scale: Double) : RoiPooling[T] = { RoiPooling[T](pooled_w, pooled_h, ev.fromType(spatial_scale)) } def createScale(size: JList[Int]) : Scale[T] = { Scale[T](size.asScala.toArray) } def createSelect(dimension: Int, index: Int) : Select[T] = { Select[T](dimension, index) } def createSelectTable(dimension: Int) : SelectTable[T] = { SelectTable[T](dimension) } def createSigmoid() : Sigmoid[T] = { Sigmoid[T]() } def createSoftMax() : SoftMax[T] = { SoftMax[T]() } def createSoftMin() : SoftMin[T] = { SoftMin[T]() } def createSoftPlus(beta: Double = 1.0) : SoftPlus[T] = { SoftPlus[T](beta) } def createSoftShrink(lambda: Double = 0.5) : SoftShrink[T] = { SoftShrink[T](lambda) } def createSoftSign() : SoftSign[T] = { SoftSign[T]() } def createSpatialDilatedConvolution(nInputPlane: Int, nOutputPlane: Int, kW: Int, kH: Int, dW: Int = 1, dH: Int = 1, padW: Int = 0, padH: Int = 0, dilationW: Int = 1, dilationH: Int = 1, wRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null) : SpatialDilatedConvolution[T] = { SpatialDilatedConvolution[T](nInputPlane, nOutputPlane, kW, kH, dW, dH, padW, padH, dilationW, dilationH, wRegularizer, bRegularizer) } def createTemporalConvolution( inputFrameSize: Int, outputFrameSize: Int, kernelW: Int, strideW: Int = 1, propagateBack: Boolean = true, wRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null, initWeight: JTensor = null, initBias: JTensor = null, initGradWeight: JTensor = null, initGradBias: JTensor = null ) : TemporalConvolution[T] = { TemporalConvolution[T]( inputFrameSize, outputFrameSize, kernelW, strideW, propagateBack, wRegularizer, bRegularizer, toTensor(initWeight), toTensor(initBias), toTensor(initGradWeight), toTensor(initGradBias) ) } def createBinaryTreeLSTM( inputSize: Int, hiddenSize: Int, gateOutput: Boolean = true, withGraph: Boolean = true) : BinaryTreeLSTM[T] = { BinaryTreeLSTM[T]( inputSize, hiddenSize, gateOutput, withGraph) } def createSpatialFullConvolution(nInputPlane: Int, nOutputPlane: Int, kW: Int, kH: Int, dW: Int = 1, dH: Int = 1, padW: Int = 0, padH: Int = 0, adjW: Int = 0, adjH: Int = 0, nGroup: Int = 1, noBias: Boolean = false, wRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null) : SpatialFullConvolution[T] = { SpatialFullConvolution[T](nInputPlane, nOutputPlane, kW, kH, dW, dH, padW, padH, adjW, adjH, nGroup, noBias, wRegularizer, bRegularizer) } def createSpatialShareConvolution( nInputPlane: Int, nOutputPlane: Int, kernelW: Int, kernelH: Int, strideW: Int = 1, strideH: Int = 1, padW: Int = 0, padH: Int = 0, nGroup: Int = 1, propagateBack: Boolean = true, wRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null, initWeight: JTensor = null, initBias: JTensor = null, initGradWeight: JTensor = null, initGradBias: JTensor = null, withBias: Boolean = true) : SpatialShareConvolution[T] = { SpatialShareConvolution[T](nInputPlane, nOutputPlane, kernelW, kernelH, strideW, strideH, padW, padH, nGroup, propagateBack, wRegularizer, bRegularizer, toTensor(initWeight), toTensor(initBias), toTensor(initGradWeight), toTensor(initGradBias), withBias ) } def createSpatialZeroPadding(padLeft: Int, padRight: Int, padTop: Int, padBottom: Int) : SpatialZeroPadding[T] = { SpatialZeroPadding[T](padLeft, padRight, padTop, padBottom) } def createSplitTable(dimension: Int, nInputDims: Int = -1) : SplitTable[T] = { SplitTable[T](dimension, nInputDims) } def createSqrt() : Sqrt[T] = { Sqrt[T]() } def createSquare() : Square[T] = { Square[T]() } def createSqueeze(dim: Int = Int.MinValue, numInputDims: Int = Int.MinValue) : Squeeze[T] = { Squeeze[T](dim, numInputDims) } def createSum(dimension: Int = 1, nInputDims: Int = -1, sizeAverage: Boolean = false, squeeze: Boolean = true ) : Sum[T] = { Sum[T](dimension, nInputDims, sizeAverage, squeeze ) } def createTanhShrink() : TanhShrink[T] = { TanhShrink[T]() } def createThreshold(th: Double = 1e-6, v: Double = 0.0, ip: Boolean = false) : Threshold[T] = { Threshold[T](th, v, ip) } def createUnsqueeze(pos: Int, numInputDims: Int = Int.MinValue) : Unsqueeze[T] = { Unsqueeze[T](pos, numInputDims) } def createBCECriterion(weights: JTensor = null, sizeAverage: Boolean = true) : BCECriterion[T] = { BCECriterion[T](if (weights == null) null else toTensor(weights), sizeAverage) } def createBiRecurrent(merge: AbstractModule[Table, Tensor[T], T] = null) : BiRecurrent[T] = { BiRecurrent[T](merge) } def createConcatTable() : ConcatTable[T] = { ConcatTable[Activity, T]() } def createIdentity() : Identity[T] = { Identity[T]() } def createMultiLabelSoftMarginCriterion(weights: JTensor = null, sizeAverage: Boolean = true) : MultiLabelSoftMarginCriterion[T] = { MultiLabelSoftMarginCriterion[T](if (weights == null) null else toTensor(weights), sizeAverage) } def createMultiMarginCriterion(p: Int = 1, weights: JTensor = null, margin: Double = 1.0, sizeAverage: Boolean = true) : MultiMarginCriterion[T] = { MultiMarginCriterion[T](p, if (weights == null) null else toTensor(weights), margin, sizeAverage) } def createReverse(dimension: Int = 1, isInplace: Boolean = false) : Reverse[T] = { Reverse[T](dimension, isInplace) } def createTranspose(permutations: JList[JList[Int]]) : Transpose[T] = { Transpose[T](permutations.asScala.toArray.map { item => val itemArray = item.asScala.toArray (itemArray(0), itemArray(1)) }) } def createSpatialContrastiveNormalization(nInputPlane: Int = 1, kernel: JTensor = null, threshold: Double = 1e-4, thresval: Double = 1e-4) : SpatialContrastiveNormalization[T] = { SpatialContrastiveNormalization[T](nInputPlane, if (kernel == null) null else toTensor(kernel), threshold, thresval) } def createSpatialConvolutionMap(connTable: JTensor, kW: Int, kH: Int, dW: Int = 1, dH: Int = 1, padW: Int = 0, padH: Int = 0, wRegularizer: Regularizer[T] = null, bRegularizer: Regularizer[T] = null) : SpatialConvolutionMap[T] = { SpatialConvolutionMap[T](if (connTable == null) null else toTensor(connTable), kW, kH, dW, dH, padW, padH, wRegularizer, bRegularizer) } def createVolumetricConvolution(nInputPlane: Int, nOutputPlane: Int, kT: Int, kW: Int, kH: Int, dT: Int = 1, dW: Int = 1, dH: Int = 1, padT: Int = 0, padW: Int = 0, padH: Int = 0, withBias: Boolean = true) : VolumetricConvolution[T] = { VolumetricConvolution[T](nInputPlane, nOutputPlane, kT, kW, kH, dT, dW, dH, padT, padW, padH, withBias) } def createVolumetricMaxPooling(kT: Int, kW: Int, kH: Int, dT: Int, dW: Int, dH: Int, padT: Int = 0, padW: Int = 0, padH: Int = 0): VolumetricMaxPooling[T] = { VolumetricMaxPooling[T](kT, kW, kH, dT, dW, dH, padT, padW, padH) } def createSpatialDivisiveNormalization(nInputPlane: Int = 1, kernel: JTensor = null, threshold: Double = 1e-4, thresval: Double = 1e-4) : SpatialDivisiveNormalization[T] = { SpatialDivisiveNormalization[T](nInputPlane, if (kernel == null) null else toTensor(kernel), threshold, thresval) } def createSpatialSubtractiveNormalization(nInputPlane: Int = 1, kernel: JTensor = null) : SpatialSubtractiveNormalization[T] = { SpatialSubtractiveNormalization[T](nInputPlane, if (kernel == null) null else toTensor(kernel)) } def createSoftMarginCriterion(sizeAverage: Boolean = true) : SoftMarginCriterion[T] = { SoftMarginCriterion[T](sizeAverage) } // Optimizer def createPoly(power: Double, maxIteration: Int): SGD.Poly = { SGD.Poly(power, maxIteration) } def createStep(stepSize: Int, gamma: Double): SGD.Step = { SGD.Step(stepSize, gamma) } def createMultiStep(stepSizes: JList[Int], gamma: Double): SGD.MultiStep = { SGD.MultiStep(stepSizes.asScala.toArray, gamma) } def createExponential(decayStep: Int, decayRate: Double, stairCase: Boolean = false): SGD.Exponential = { SGD.Exponential(decayStep, decayRate, stairCase) } def createDefault(): SGD.Default = { SGD.Default() } def createPlateau(monitor: String, factor: Float = 0.1f, patience: Int = 10, mode: String = "min", epsilon: Float = 1e-4f, cooldown: Int = 0, minLr: Float = 0): SGD.Plateau = { SGD.Plateau(monitor, factor, patience, mode, epsilon, cooldown, minLr) } def createClassNLLCriterion(weights: JTensor = null, sizeAverage: Boolean = true) : ClassNLLCriterion[T] = { ClassNLLCriterion[T](if (weights == null) null else toTensor(weights), sizeAverage) } def createMSECriterion: MSECriterion[T] = { MSECriterion[T]() } def createAbsCriterion(sizeAverage: Boolean = true) : AbsCriterion[T] = { AbsCriterion[T](sizeAverage) } def createClassSimplexCriterion(nClasses: Int) : ClassSimplexCriterion[T] = { ClassSimplexCriterion[T](nClasses) } def createCrossEntropyCriterion(weights: JTensor = null, sizeAverage: Boolean = true): CrossEntropyCriterion[T] = { new CrossEntropyCriterion[T](if (null == weights) null else toTensor(weights), sizeAverage) } def createCosineEmbeddingCriterion(margin: Double = 0.0, sizeAverage: Boolean = true) : CosineEmbeddingCriterion[T] = { CosineEmbeddingCriterion[T](margin, sizeAverage) } def createDistKLDivCriterion(sizeAverage: Boolean = true) : DistKLDivCriterion[T] = { DistKLDivCriterion[T](sizeAverage) } def createHingeEmbeddingCriterion(margin: Double = 1, sizeAverage: Boolean = true) : HingeEmbeddingCriterion[T] = { HingeEmbeddingCriterion[T](margin, sizeAverage) } def createL1HingeEmbeddingCriterion(margin: Double = 1) : L1HingeEmbeddingCriterion[T] = { L1HingeEmbeddingCriterion[T](margin) } def createMarginCriterion(margin: Double = 1.0, sizeAverage: Boolean = true) : MarginCriterion[T] = { MarginCriterion[T](margin, sizeAverage) } def createMarginRankingCriterion(margin: Double = 1.0, sizeAverage: Boolean = true) : MarginRankingCriterion[T] = { MarginRankingCriterion[T](margin, sizeAverage) } def createMultiCriterion() : MultiCriterion[T] = { MultiCriterion[T]() } def createMultiLabelMarginCriterion(sizeAverage: Boolean = true) : MultiLabelMarginCriterion[T] = { MultiLabelMarginCriterion[T](sizeAverage) } def createParallelCriterion(repeatTarget: Boolean = false) : ParallelCriterion[T] = { ParallelCriterion[T](repeatTarget) } def createSmoothL1Criterion(sizeAverage: Boolean = true) : SmoothL1Criterion[T] = { SmoothL1Criterion[T](sizeAverage) } def createSmoothL1CriterionWithWeights(sigma: Double, num: Int = 0) : SmoothL1CriterionWithWeights[T] = { SmoothL1CriterionWithWeights[T](sigma, num) } def createSoftmaxWithCriterion(ignoreLabel: Integer = null, normalizeMode: String = "VALID") : SoftmaxWithCriterion[T] = { val normM = normalizeMode match { case "FULL" => NormMode.FULL case "VALID" => NormMode.VALID case "BATCH_SIZE" => NormMode.BATCH_SIZE case "NONE" => NormMode.NONE case n: String => throw new IllegalArgumentException(s"Only support 'FULL', " + s"'VALID', 'BATCH_SIZE' and 'NONE': $n") } val labelToIgnore = ignoreLabel match { case i: Integer => Some(i.toInt) case null => None } SoftmaxWithCriterion[T](labelToIgnore, normM) } def createPack(dimension: Int): Pack[T] = { Pack(dimension) } def setModelSeed(seed: Long): Unit = { RandomGenerator.RNG.setSeed(seed) } def modelTest(model: AbstractModule[Activity, Activity, T], valRDD: JavaRDD[Sample], batchSize: Int, valMethods: JList[ValidationMethod[T]]) : JList[TestResult] = { val resultArray = model.evaluate(valRDD.rdd.map(toSample(_)), valMethods.asScala.toArray, Some(batchSize)) val testResultArray = resultArray.map { result => TestResult(result._1.result()._1, result._1.result()._2, result._2.toString()) } testResultArray.toList.asJava } def loadBigDL(path: String): AbstractModule[Activity, Activity, T] = { Module.load[T](path) } def loadTorch(path: String): AbstractModule[Activity, Activity, T] = { Module.loadTorch[T](path) } def loadCaffe(model: AbstractModule[Activity, Activity, T], defPath: String, modelPath: String, matchAll: Boolean = true): AbstractModule[Activity, Activity, T] = { Module.loadCaffe[T](model, defPath, modelPath, matchAll) } def loadCaffeModel(defPath: String, modelPath: String): AbstractModule[Activity, Activity, T] = { Module.loadCaffeModel[T](defPath, modelPath) } def loadTF(path: String, inputs: JList[String], outputs: JList[String], byteOrder: String): AbstractModule[Activity, Activity, T] = { val order = byteOrder match { case "little_endian" => ByteOrder.LITTLE_ENDIAN case "big_endian" => ByteOrder.BIG_ENDIAN case _ => throw new IllegalArgumentException(s"No support byte order $byteOrder") } Module.loadTF[T](path, inputs.asScala, outputs.asScala, order) } def saveTF(model: AbstractModule[Activity, Activity, T], inputs: JList[Any], path: String, byteOrder: String, dataFormat: String): Unit = { val order = byteOrder.toLowerCase match { case "little_endian" => ByteOrder.LITTLE_ENDIAN case "big_endian" => ByteOrder.BIG_ENDIAN case _ => throw new IllegalArgumentException(s"Unknown byte order $byteOrder") } val format = dataFormat.toLowerCase match { case "nhwc" => TensorflowDataFormat.NHWC case "nchw" => TensorflowDataFormat.NCHW case _ => throw new IllegalArgumentException(s"Unknown format $dataFormat") } val scalaInputs = inputs.asScala.map { elem => val array = elem.asInstanceOf[JList[Any]] val name = array.get(0).asInstanceOf[String] val shape = array.get(1).asInstanceOf[JList[Int]] (name, shape.asScala) } model.saveTF(scalaInputs, path, order, format) } def modelPredictRDD(model: AbstractModule[Activity, Activity, T], dataRdd: JavaRDD[Sample]): JavaRDD[JTensor] = { val tensorRDD = model.predict(dataRdd.rdd.map(toSample(_))) val listRDD = tensorRDD.map{res => val tensor = res.asInstanceOf[Tensor[T]] val cloneTensor = tensor.clone() toJTensor(cloneTensor) } new JavaRDD[JTensor](listRDD) } def modelForward(model: AbstractModule[Activity, Activity, T], input: JList[JTensor], inputIsTable: Boolean): JList[JTensor] = { val inputActivity = jTensorsToActivity(input, inputIsTable) val outputActivity = model.forward(inputActivity) activityToJTensors(outputActivity) } def modelBackward(model: AbstractModule[Activity, Activity, T], input: JList[JTensor], inputIsTable: Boolean, gradOutput: JList[JTensor], gradOutputIsTable: Boolean): JList[JTensor] = { val inputActivity = jTensorsToActivity(input, inputIsTable) val gradOutputActivity = jTensorsToActivity(gradOutput, gradOutputIsTable) val outputActivity = model.backward(inputActivity, gradOutputActivity) activityToJTensors(outputActivity) } def modelSave(module: AbstractModule[Activity, Activity, T], path: String, overWrite: Boolean): Unit = { module.save(path, overWrite) } def saveCaffe(module: AbstractModule[Activity, Activity, T], prototxtPath: String, modelPath: String, useV2 : Boolean = true, overwrite : Boolean = false): Unit = { module.saveCaffe(prototxtPath, modelPath, useV2, overwrite) } def criterionForward(criterion: AbstractCriterion[Activity, Activity, T], input: JList[JTensor], inputIsTable: Boolean, target: JList[JTensor], targetIsTable: Boolean): T = { val inputActivity = jTensorsToActivity(input, inputIsTable) val targetActivity = jTensorsToActivity(target, targetIsTable) return criterion.forward(inputActivity, targetActivity) } def criterionBackward(criterion: AbstractCriterion[Activity, Activity, T], input: JList[JTensor], inputIsTable: Boolean, target: JList[JTensor], targetIsTable: Boolean): JList[JTensor] = { val inputActivity = jTensorsToActivity(input, inputIsTable) val targetActivity = jTensorsToActivity(target, targetIsTable) val outputActivity = criterion.backward(inputActivity, targetActivity) activityToJTensors(outputActivity) } def modelGetParameters(model: AbstractModule[Activity, Activity, T]) : JMap[Any, JMap[Any, JList[JList[Any]]]] = { model.getParametersTable().getState().mapValues { case name2Values: Table => name2Values.getState().mapValues { case t: Tensor[T] => val tensorClone = t.clone() val item = List(tensorClone.storage().toList.asJava.asInstanceOf[JList[Any]], tensorClone.size().toList.asJava.asInstanceOf[JList[Any]]).asJava item }.asJava }.asJava } def createMaxEpoch(max: Int): Trigger = { Trigger.maxEpoch(max) } def createEveryEpoch(): Trigger = { Trigger.everyEpoch } def createSeveralIteration(interval: Int): Trigger = { Trigger.severalIteration(interval) } def createMaxIteration(max: Int): Trigger = { Trigger.maxIteration(max) } def createMaxScore(max: Float): Trigger = { Trigger.maxScore(max) } def createMinLoss(min: Float): Trigger = { Trigger.minLoss(min) } def createTop1Accuracy(): ValidationMethod[T] = { new Top1Accuracy() } def createTreeNNAccuracy(): ValidationMethod[T] = { new TreeNNAccuracy() } def createTop5Accuracy(): ValidationMethod[T] = { new Top5Accuracy() } def createLoss(criterion: Criterion[T]): ValidationMethod[T] = { new Loss(criterion) } def createMAE(): ValidationMethod[T] = { new MAE() } def createSGD(learningRate: Double = 1e-3, learningRateDecay: Double = 0.0, weightDecay: Double = 0.0, momentum: Double = 0.0, dampening: Double = Double.MaxValue, nesterov: Boolean = false, leaningRateSchedule: SGD.LearningRateSchedule = SGD.Default(), learningRates: JTensor = null, weightDecays: JTensor = null): SGD[T] = { val p1 = if (learningRates == null) null else toTensor(learningRates) val p2 = if (weightDecays == null) null else toTensor(weightDecays) new SGD[T](learningRate, learningRateDecay, weightDecay, momentum, dampening, nesterov, leaningRateSchedule, p1, p2) } def createAdagrad(learningRate: Double = 1e-3, learningRateDecay: Double = 0.0, weightDecay: Double = 0.0): Adagrad[T] = { new Adagrad[T](learningRate, learningRateDecay, weightDecay) } def createLBFGS(maxIter: Int = 20, maxEval: Double = Double.MaxValue, tolFun: Double = 1e-5, tolX: Double = 1e-9, nCorrection: Int = 100, learningRate: Double = 1.0, verbose: Boolean = false, lineSearch: LineSearch[T] = null, lineSearchOptions: JMap[Any, Any] = null): LBFGS[T] = { val p1 = if (lineSearch == null) None else Option(lineSearch) val p2 = if (lineSearchOptions == null) None else Option(T(lineSearchOptions)) new LBFGS[T](maxIter, maxEval, tolFun, tolX, nCorrection, learningRate, verbose, p1, p2) } def createAdadelta(decayRate: Double = 0.9, Epsilon: Double = 1e-10): Adadelta[T] = { new Adadelta[T](decayRate, Epsilon) } def createAdam( learningRate: Double = 1e-3, learningRateDecay: Double = 0.0, beta1: Double = 0.9, beta2: Double = 0.999, Epsilon: Double = 1e-8): Adam[T] = { new Adam[T](learningRate, learningRateDecay, beta1, beta2, Epsilon) } def createAdamax( learningRate: Double = 0.002, beta1: Double = 0.9, beta2: Double = 0.999, Epsilon: Double = 1e-38): Adamax[T] = { new Adamax(learningRate, beta1, beta2, Epsilon) } def createRMSprop( learningRate: Double = 1e-2, learningRateDecay: Double = 0.0, decayRate: Double = 0.99, Epsilon: Double = 1e-8): RMSprop[T] = { new RMSprop[T](learningRate, learningRateDecay, decayRate, Epsilon) } def createOptimizer(model: AbstractModule[Activity, Activity, T], trainingRdd: JavaRDD[Sample], criterion: Criterion[T], optimMethod: OptimMethod[T], endTrigger: Trigger, batchSize: Int): Optimizer[T, MiniBatch[T]] = { val optimizer = new DistriOptimizer( _model = model, dataset = batching(trainingRdd, batchSize), criterion = criterion ).asInstanceOf[Optimizer[T, MiniBatch[T]]] // TODO: we should provide a more convenient way to create Table optimizer.setEndWhen(endTrigger) optimizer.setOptimMethod(optimMethod) // TODO: remove this optimizer.disableCheckSingleton() optimizer } def createL1L2Regularizer(l1: Double, l2: Double): L1L2Regularizer[T] = { L1L2Regularizer[T](l1, l2) } def createL1Regularizer(l1: Double): L1Regularizer[T] = { L1Regularizer[T](l1) } def createL2Regularizer(l2: Double): L2Regularizer[T] = { L2Regularizer[T](l2) } def setValidation(optimizer: Optimizer[T, MiniBatch[T]], batchSize: Int, trigger: Trigger, valRdd: JavaRDD[Sample], vMethods: JList[ValidationMethod[T]]): Unit = { optimizer.setValidation(trigger, batching(valRdd, batchSize.toInt), vMethods.asScala.toArray) } def setCheckPoint(optimizer: Optimizer[T, MiniBatch[T]], trigger: Trigger, checkPointPath: String, isOverwrite: Boolean): Unit = { optimizer.setCheckpoint(checkPointPath, trigger) if (isOverwrite) { optimizer.overWriteCheckpoint() } } def setTrainSummary(optimizer: Optimizer[T, MiniBatch[T]], summary: TrainSummary): Unit = { optimizer.setTrainSummary(summary) } def setValSummary(optimizer: Optimizer[T, MiniBatch[T]], summary: ValidationSummary): Unit = { optimizer.setValidationSummary(summary) } def summaryReadScalar(summary: Summary, tag: String): JList[JList[Any]] = { val result = summary.readScalar(tag) result.toList.map { item => List(item._1, item._2, item._3).asJava.asInstanceOf[JList[Any]] }.asJava } def summarySetTrigger( summary: TrainSummary, summaryName: String, trigger: Trigger): TrainSummary = { summary.setSummaryTrigger(summaryName, trigger) summary } def createTrainSummary(logDir: String, appName: String): TrainSummary = { new TrainSummary(logDir, appName) } def createValidationSummary(logDir: String, appName: String): ValidationSummary = { new ValidationSummary(logDir, appName) } def createModel(input: JList[ModuleNode[T]], output: JList[ModuleNode[T]]): Graph[T] = { Graph(input.asScala.toArray, output.asScala.toArray) } def createNode(module: AbstractModule[Activity, Activity, T], x: JList[ModuleNode[T]]): ModuleNode[T] = { if (null == x || x.isEmpty) { module.inputs() } else { module.inputs(x.asScala : _*) } } def createInput(): ModuleNode[T] = { Input() } def initEngine(): Unit = { Engine.init } def setWeights(model: AbstractModule[Activity, Activity, T], weights: JList[JTensor]): Unit = { val weightTensor = weights.asScala.toArray.map(toTensor(_)) model.setWeightsBias(weightTensor) } def getWeights(model: AbstractModule[Activity, Activity, T]): JList[JTensor] = { val weights = model.getWeightsBias() if (weights != null) { weights.map(toJTensor(_)).toList.asJava } else { null } } def updateParameters(model: AbstractModule[Activity, Activity, T], lr: Double): Unit = { model.updateParameters(ev.fromType(lr)) } def uniform(a: Double, b: Double, size: JList[Int]): JTensor = { val result = Tensor[T]().resize(size.asScala.toArray) result.apply1(i => ev.fromType(RandomGenerator.RNG.uniform(a, b))) toJTensor(result) } def createZeros(): Zeros.type = { Zeros } def createOnes(): Ones.type = { Ones } def createConstInitMethod(value: Double): ConstInitMethod = { ConstInitMethod(value) } def createRandomUniform(lower: Double, upper: Double): InitializationMethod = { RandomUniform(lower, upper) } def createRandomUniform(): InitializationMethod = { RandomUniform } def createRandomNormal(mean: Double, stdv: Double): RandomNormal = { RandomNormal(mean, stdv) } def createXavier(): Xavier.type = { Xavier } def createBilinearFiller(): BilinearFiller.type = { BilinearFiller } def setInitMethod(layer: Initializable, weightInitMethod: InitializationMethod, biasInitMethod: InitializationMethod): layer.type = { layer.setInitMethod(weightInitMethod, biasInitMethod) } }
{ "content_hash": "823c69b37e502097928cce6da5035f2c", "timestamp": "", "source": "github", "line_count": 1752, "max_line_length": 99, "avg_line_length": 28.734018264840184, "alnum_prop": 0.5819593977195979, "repo_name": "JerryYanWan/BigDL", "id": "4eb296f726fd51449347e4448904c06e378a3b4b", "size": "50943", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "spark/dl/src/main/scala/com/intel/analytics/bigdl/python/api/PythonBigDL.scala", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Java", "bytes": "6829" }, { "name": "Jupyter Notebook", "bytes": "2447" }, { "name": "Lua", "bytes": "1904" }, { "name": "Python", "bytes": "400553" }, { "name": "RobotFramework", "bytes": "10720" }, { "name": "Scala", "bytes": "3699187" }, { "name": "Shell", "bytes": "39557" } ], "symlink_target": "" }
class Models attr_accessor :file_lines, :filename, :last_access_line, :last_name def initialize filename @filename = filename get_all_models @filename puts @file_lines backup end def find_model model_name counter = 0 @file_lines.each do |line| if line.split("|")[0] == model_name @last_access_line = counter @last_name = model_name return line end counter += 1 end end def save verts, ind mod_line = @last_name + "|" counter = 0 verts.each do |v| if counter != 0 mod_line += ", " end mod_line += v.to_s counter += 1 end if ind != nil counter = 0 mod_line += "|" ind.each do |i| if counter != 0 mod_line += ", " end mod_line += i.to_s counter += 1 end end @file_lines[@last_access_line] = mod_line begin #File.open(@filename, "w") {} file = File.open(@filename, "w") @file_lines.each do |line| file.write(line + "\n") end rescue IOError => e #shit print "Error writing to file" ensure file.close unless file.nil? end puts @file_lines end def backup begin file = File.open(@filename + "_backup", "w+") @file_lines.each do |line| file.write(line + "\n") end rescue IOError => e print "Error writing backup" ensure file.close unless file.nil? end end def get_all_models filename @file_lines = Array.new File.foreach(filename) do |line| @file_lines.push line end @file_lines.each do |line| line.gsub! " ", "" line.gsub! "\t", "" line.gsub! "\n", "" line.gsub! "\r", "" end end end @models = Models.new "models.data" @vertices = Array.new @indices = Array.new def print_vertices puts puts "Vertices: " counter = 0 points = @vertices.each_slice(3).to_a points.each do |p| puts counter.to_s + ": " + p*", " counter += 1 end end def print_indices puts puts "Indices: " counter = 0 points = @indices.each_slice(3).to_a points.each do |p| puts p*", " counter += 1 end end def get_model model_name #Re-initialize the arrays @vertices = Array.new @indices = Array.new line = @models.find_model model_name split_line = line.split("|") #Vertices split_numbers = split_line[1].split(",") split_numbers.each do |num| @vertices.push(num.to_f) end print_vertices #indices split_numbers = split_line[2].split(",") split_numbers.each do |num| @indices.push(num.to_i) end print_indices end def input filename line_num = 0 lines = File.open(filename).read lines.each_line do |line| print "#{line_num += 1}: #{line}" end end def run system("rp5 run vertexPlanner.rb \"#{@vertices*"," + "|" + @indices*","}\"") puts $?.exitstatus end #============== MAIN LOOP ================= while (command = gets.chomp.split(" "))[0].upcase != 'EXIT' case command[0].upcase when "GETMODEL" if command[1] == nil command[1] = "bunny" end get_model(command[1]) when "READ" if command[1] == nil or command[2] == nil puts "Arguments missing!" next end input command[1] when "PRINTV" print_vertices when "PRINTI" print_indices when "TEST" get_model("bunny") run when "RUN" run when "SAVE" @models.save @vertices, @indices when "VADD" if command[1] == nil or command[2] == nil or command[3] == nil puts "Arguments missing!" next end @vertices.push command[1] @vertices.push command[2] @vertices.push command[3] when "VMOD" if command[1] == nil or command[2] == nil or command[3] == nil puts "Arguments missing!" next end if command[4] == nil @vertices[command[1].to_i * 3 + command[2].to_i] = command[3].to_f elsif command[3] == "+" @vertices[command[1].to_i * 3 + command[2].to_i] += command[4].to_f elsif command[3] == "-" @vertices[command[1].to_i * 3 + command[2].to_i] -= command[4].to_f end when "PULLV" @vertices = Array.new File.foreach("_displayer.v") do |line| nums = line.split(",") nums.each do |n| n.gsub! " ", "" n = n.to_f end nums.each do |n| @vertices.push n end end when "PULLI" @indices = Array.new File.foreach("_displayer.i") do |line| nums = line.split(",") nums.each do |n| n.gsub! " ", "" n = n.to_i end nums.each do |n| @indices.push n end end when "NAME" if command[1] != nil @models.name = command[1] end when "HELP" if command[1] == "--example" #Full usage example puts "Step 1: getModel {model_name}" puts "Line that starts with 'model_name' from 'models.data' is loaded -- vertices and indices" puts "Step 2: run" puts "Runs the displayer program" puts "Step 3: pull (pullv for vertices, pulli for indices)" puts "After saving verts and ind from the program, import them here" puts "Step 4: save" puts "Overwrite the old model with the new stuff" puts "Step 5: exit" puts "Done :)" elsif command[1] == "--model" puts "A model had 3 parts: Name, Vertices, Indices" puts puts "Models:" puts " getModel {Model_Name}" puts " newModel {Model_Name}" puts " run (opens Displayer)" puts puts "Name:" puts " name {new_name}" puts puts "Vertices:" puts " printv (print vertices)" puts " pullv (overwrites vertices with the ones from the Displayer)" puts " vmod {Vertex_Number} {0..2 => x..z} ['+', '-'] {Value}" puts " example: vmod 0 0 + 0.1" puts " (modifies one point of a vertex)" puts " vadd {X_Value} {Y_Value} {Z_Value}" puts " (adds a vertex)" puts puts "Indices:" puts " printi (print indices)" puts " pulli (overwrites indices with the ones from the Displayer)" puts " imod {Index_Number} {0..2} {Value}" puts " example: imod 3 1 5" puts " (modifies one point of an index)" puts " iadd {X_Value} {Y_Value} {Z_Value}" puts " (adds an index)" elsif command[1] == "--displayer" puts "Displayer: Window for drawing current model" puts puts "Vertex Selection:" puts " Select a vertex to move:" puts " '0', '1', '2'..." puts " '=' and '-' => add or subtract the selected vertex by 1" puts puts "Once the desired vertex is selected:" puts " Click and drag to place" puts " Press 'r' to remove it" puts puts "Press 's' to save progress" puts "Press 'q' to save and exit" puts "Press the 'x' in the corner to quit without saving" else puts "Try the following: " puts "help --example" puts "help --model" puts "help --displayer" end else puts "Command doesn't exist, consider checking your spelling?" end end
{ "content_hash": "ab82179a19b2d07cd449bc1933a57151", "timestamp": "", "source": "github", "line_count": 296, "max_line_length": 106, "avg_line_length": 28.06756756756757, "alnum_prop": 0.4812229176697159, "repo_name": "pikapak/math_utils", "id": "1a3bf043f0287e67b41701a1a6007e415cb89fb7", "size": "8371", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "ModelMaker/mainApp.rb", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Coq", "bytes": "1067" }, { "name": "Ruby", "bytes": "15084" }, { "name": "Shell", "bytes": "63" } ], "symlink_target": "" }
/* KallistiOS ##version## matrix3d.h (c)2000 Dan Potter and Jordan DeLong */ /** \file dc/matrix3d.h \brief 3D matrix operations. This file contains various 3D matrix math functionality for using the SH4's matrix transformation unit. \author Dan Potter \author Jordan DeLong */ #ifndef __KOS_MATRIX3D_H #define __KOS_MATRIX3D_H #include <sys/cdefs.h> __BEGIN_DECLS #include <dc/matrix.h> /** \brief Rotate around the X-axis. This function sets up a rotation matrix around the X-axis. \param r The angle to rotate, in radians. */ void mat_rotate_x(float r); /** \brief Rotate around the Y-axis. This function sets up a rotation matrix around the Y-axis. \param r The angle to rotate, in radians. */ void mat_rotate_y(float r); /** \brief Rotate around the Z-axis. This function sets up a rotation matrix around the Z-axis. \param r The angle to rotate, in radians. */ void mat_rotate_z(float r); /** \brief Rotate around all axes. This function sets up a rotation matrix around the X-axis, then around the Y, then around the Z. \param xr The angle to rotate around the X-axis, in radians. \param yr The angle to rotate around the Y-axis, in radians. \param zr The angle to rotate around the Z-axis, in radians. */ void mat_rotate(float xr, float yr, float zr); /** \brief Perform a 3D translation. This function sets up a translation matrix with the specified parameters. \param x The amount to translate in X. \param y The amount to translate in Y. \param z The amount to translate in Z. */ void mat_translate(float x, float y, float z); /** \brief Perform a 3D scale operation. This function sets up a scaling matrix with the specified parameters. \param x The ratio to scale in X. \param y The ratio to scale in Y. \param z The ratio to scale in Z. */ void mat_scale(float x, float y, float z); /** \brief Set up a perspective view frustum. This function sets up a perspective view frustum for basic 3D usage. \param xcenter Center of the X direction. \param ycenter Center of the Y direction. \param cot_fovy_2 1.0 / tan(view_angle / 2). \param znear Near Z-plane. \param zfar Far Z-plane. */ void mat_perspective(float xcenter, float ycenter, float cot_fovy_2, float znear, float zfar); /** \brief Set up a "camera". This function acts as the similarly named GL function to set up a "camera" by doing rotations/translations. \param eye The eye coordinate. \param center The center coordinate. \param up The up vector. */ void mat_lookat(const point_t * eye, const point_t * center, const vector_t * up); __END_DECLS #endif /* __KOS_MATRIX3D_H */
{ "content_hash": "1342a69a67474042c33db78908206173", "timestamp": "", "source": "github", "line_count": 109, "max_line_length": 82, "avg_line_length": 27.761467889908257, "alnum_prop": 0.6222736285525446, "repo_name": "DreamcastSDK/kos", "id": "22c1f7e4c32027d2a7f5cd4a096889ebde121aec", "size": "3026", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "dreamcast/include/dc/matrix3d.h", "mode": "33188", "license": "bsd-3-clause", "language": [ { "name": "Assembly", "bytes": "35429" }, { "name": "C", "bytes": "2544876" }, { "name": "C++", "bytes": "228626" }, { "name": "Makefile", "bytes": "6752" }, { "name": "Objective-C", "bytes": "12580" }, { "name": "Shell", "bytes": "5368" } ], "symlink_target": "" }
module Devise module Oauth2Providable module ExpirableToken extend ActiveSupport::Concern module ClassMethods def expires_according_to(config_name) cattr_accessor :default_lifetime self.default_lifetime = Rails.application.config.devise_oauth2_providable[config_name] belongs_to :user belongs_to :client, class_name: 'Devise::Oauth2Providable::Client' attr_accessible :user, :client after_initialize :init_token, on: :create, unless: :token? after_initialize :init_expires_at, on: :create, unless: :expires_at? validates :expires_at, presence: true validates :client, presence: true validates :token, presence: true, uniqueness: true default_scope where(:expires_at.gte => Time.now.utc) include LocalInstanceMethods end end module LocalInstanceMethods # number of seconds until the token expires def expires_in (expires_at - Time.now.utc).to_i end # forcefully expire the token def expired! self.expires_at = Time.now.utc self.save! end private def init_token self.token = Devise::Oauth2Providable.random_id end def init_expires_at self.expires_at = self.default_lifetime.from_now end end end end end
{ "content_hash": "99e087b47c41459044de8bc8ece6eb90", "timestamp": "", "source": "github", "line_count": 51, "max_line_length": 96, "avg_line_length": 27.980392156862745, "alnum_prop": 0.6159775753328661, "repo_name": "asux/devise-oauth2_providable-models-mongoid", "id": "f530f146061b80c1fa394e927e0103c597bb1fa4", "size": "1427", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "lib/devise/oauth2_providable/expirable_token.rb", "mode": "33188", "license": "mit", "language": [ { "name": "Ruby", "bytes": "6722" } ], "symlink_target": "" }
ACCEPTED #### According to International Plant Names Index #### Published in null #### Original name null ### Remarks null
{ "content_hash": "01ff6487426700f90120a1727cf611f4", "timestamp": "", "source": "github", "line_count": 13, "max_line_length": 31, "avg_line_length": 9.692307692307692, "alnum_prop": 0.7063492063492064, "repo_name": "mdoering/backbone", "id": "5f0e3137bec05da50cb8bb95a24f6051842c58cc", "size": "186", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "life/Plantae/Magnoliophyta/Magnoliopsida/Brassicales/Brassicaceae/Rorippa/Rorippa globosa/Cardamine globosa glabra/README.md", "mode": "33188", "license": "apache-2.0", "language": [], "symlink_target": "" }
import { Component, OnInit } from '@angular/core'; import { Router } from '@angular/router'; import { Hero } from "./hero"; import { HeroService } from './hero.service'; @Component({ moduleId: module.id, selector: 'my-heroes', templateUrl: './hero.component.html', styleUrls: ['./hero.component.css'] }) export class HeroesComponent implements OnInit { title = 'Tour of Heroes'; heroes: Hero[]; selectedHero: Hero; constructor( private router: Router, private heroService: HeroService ) {} ngOnInit(): void { this.getHeroes(); } getHeroes(): void { this.heroService.getHeroes().then(heroes => this.heroes = heroes); } onSelect(hero: Hero): void { this.selectedHero = hero; } gotoDetail(): void { this.router.navigate(['/detail', this.selectedHero.id]); } add(name: string): void { name = name.trim(); if (!name) { return; } this.heroService.create(name) .then(hero => { this.heroes.push(hero); this.selectedHero = null; }); } delete(hero: Hero): void { this.heroService .delete(hero.id) .then(() => { this.heroes = this.heroes.filter(h => h !== hero); if (this.selectedHero === hero) { this.selectedHero = null; } }); } }
{ "content_hash": "6473a9c055e826521cd085b9b27d62b7", "timestamp": "", "source": "github", "line_count": 57, "max_line_length": 77, "avg_line_length": 25.07017543859649, "alnum_prop": 0.5402379286214136, "repo_name": "IvanVoevodin/angular-tour-of-heroes", "id": "3ca9aac3f97045448f9c0b4f841d8777e474fd44", "size": "1429", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/app/hero.component.ts", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "4933" }, { "name": "HTML", "bytes": "3700" }, { "name": "JavaScript", "bytes": "13490" }, { "name": "TypeScript", "bytes": "27291" } ], "symlink_target": "" }
<?xml version="1.0" encoding="ascii"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <title>osclient2.neutron.v2.network.Resource</title> <link rel="stylesheet" href="epydoc.css" type="text/css" /> <script type="text/javascript" src="epydoc.js"></script> </head> <body bgcolor="white" text="black" link="blue" vlink="#204080" alink="#204080"> <!-- ==================== NAVIGATION BAR ==================== --> <table class="navbar" border="0" width="100%" cellpadding="0" bgcolor="#a0c0ff" cellspacing="0"> <tr valign="middle"> <!-- Home link --> <th>&nbsp;&nbsp;&nbsp;<a href="osclient2-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th> <!-- Tree link --> <th>&nbsp;&nbsp;&nbsp;<a href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th> <!-- Index link --> <th>&nbsp;&nbsp;&nbsp;<a href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th> <!-- Help link --> <th>&nbsp;&nbsp;&nbsp;<a href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th> <th class="navbar" width="100%"></th> </tr> </table> <table width="100%" cellpadding="0" cellspacing="0"> <tr valign="top"> <td width="100%"> <span class="breadcrumbs"> <a href="osclient2-module.html">Package&nbsp;osclient2</a> :: <a href="osclient2.neutron-module.html">Package&nbsp;neutron</a> :: <a href="osclient2.neutron.v2-module.html">Package&nbsp;v2</a> :: <a href="osclient2.neutron.v2.network-module.html">Module&nbsp;network</a> :: Class&nbsp;Resource </span> </td> <td> <table cellpadding="0" cellspacing="0"> <!-- hide/show private --> <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink" onclick="toggle_private();">hide&nbsp;private</a>]</span></td></tr> <tr><td align="right"><span class="options" >[<a href="frames.html" target="_top">frames</a >]&nbsp;|&nbsp;<a href="osclient2.neutron.v2.network.Resource-class.html" target="_top">no&nbsp;frames</a>]</span></td></tr> </table> </td> </tr> </table> <!-- ==================== CLASS DESCRIPTION ==================== --> <h1 class="epydoc">Class Resource</h1><p class="nomargin-top"><span class="codelink"><a href="osclient2.neutron.v2.network-pysrc.html#Resource">source&nbsp;code</a></span></p> <pre class="base-tree"> object --+ | <a href="osclient2.base.Resource-class.html">base.Resource</a> --+ | <strong class="uidshort">Resource</strong> </pre> <hr /> <p>Resource class for networks in Networking V2 API</p> <!-- ==================== INSTANCE METHODS ==================== --> <a name="section-InstanceMethods"></a> <table class="summary" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white"> <tr bgcolor="#70b0f0" class="table-header"> <td colspan="2" class="table-header"> <table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr valign="top"> <td align="left"><span class="table-header">Instance Methods</span></td> <td align="right" valign="top" ><span class="options">[<a href="#section-InstanceMethods" class="privatelink" onclick="toggle_private();" >hide private</a>]</span></td> </tr> </table> </td> </tr> <tr> <td width="15%" align="right" valign="top" class="summary"> <span class="summary-type">None</span> </td><td class="summary"> <table width="100%" cellpadding="0" cellspacing="0" border="0"> <tr> <td><span class="summary-sig"><a href="osclient2.neutron.v2.network.Resource-class.html#update" class="summary-sig-name">update</a>(<span class="summary-sig-arg">self</span>, <span class="summary-sig-arg">id</span>, <span class="summary-sig-arg">name</span>=<span class="summary-sig-default">None</span>, <span class="summary-sig-arg">is_shared</span>=<span class="summary-sig-default">None</span>, <span class="summary-sig-arg">is_enabled</span>=<span class="summary-sig-default">True</span>, <span class="summary-sig-arg">is_external</span>=<span class="summary-sig-default">None</span>, <span class="summary-sig-arg">is_port_security_enabled</span>=<span class="summary-sig-default">None</span>, <span class="summary-sig-arg">segments</span>=<span class="summary-sig-default">None</span>, <span class="summary-sig-arg">provider_physical_network</span>=<span class="summary-sig-default">None</span>, <span class="summary-sig-arg">provider_network_type</span>=<span class="summary-sig-default">None</span>, <span class="summary-sig-arg">provider_segmentation_id</span>=<span class="summary-sig-default">None</span>)</span><br /> Update properties of a network</td> <td align="right" valign="top"> <span class="codelink"><a href="osclient2.neutron.v2.network-pysrc.html#Resource.update">source&nbsp;code</a></span> </td> </tr> </table> </td> </tr> <tr> <td colspan="2" class="summary"> <p class="indent-wrapped-lines"><b>Inherited from <code><a href="osclient2.base.Resource-class.html">base.Resource</a></code></b>: <code><a href="osclient2.base.Resource-class.html#__eq__">__eq__</a></code>, <code><a href="osclient2.base.Resource-class.html#__getattr__">__getattr__</a></code>, <code><a href="osclient2.base.Resource-class.html#__init__">__init__</a></code>, <code><a href="osclient2.base.Resource-class.html#__ne__">__ne__</a></code>, <code><a href="osclient2.base.Resource-class.html#__repr__">__repr__</a></code>, <code><a href="osclient2.base.Resource-class.html#__str__">__str__</a></code>, <code><a href="osclient2.base.Resource-class.html#delete">delete</a></code>, <code><a href="osclient2.base.Resource-class.html#get_attrs">get_attrs</a></code>, <code><a href="osclient2.base.Resource-class.html#get_id">get_id</a></code>, <code><a href="osclient2.base.Resource-class.html#reload">reload</a></code>, <code><a href="osclient2.base.Resource-class.html#wait_for_finished">wait_for_finished</a></code> </p> <div class="private"> <p class="indent-wrapped-lines"><b>Inherited from <code><a href="osclient2.base.Resource-class.html">base.Resource</a></code></b> (private): <code><a href="osclient2.base.Resource-class.html#_clear_attrs" onclick="show_private();">_clear_attrs</a></code>, <code><a href="osclient2.base.Resource-class.html#_set_attrs" onclick="show_private();">_set_attrs</a></code> </p></div> <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>: <code>__delattr__</code>, <code>__format__</code>, <code>__getattribute__</code>, <code>__hash__</code>, <code>__new__</code>, <code>__reduce__</code>, <code>__reduce_ex__</code>, <code>__setattr__</code>, <code>__sizeof__</code>, <code>__subclasshook__</code> </p> </td> </tr> </table> <!-- ==================== CLASS VARIABLES ==================== --> <a name="section-ClassVariables"></a> <table class="summary" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white"> <tr bgcolor="#70b0f0" class="table-header"> <td colspan="2" class="table-header"> <table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr valign="top"> <td align="left"><span class="table-header">Class Variables</span></td> <td align="right" valign="top" ><span class="options">[<a href="#section-ClassVariables" class="privatelink" onclick="toggle_private();" >hide private</a>]</span></td> </tr> </table> </td> </tr> <tr class="private"> <td width="15%" align="right" valign="top" class="summary"> <span class="summary-type">&nbsp;</span> </td><td class="summary"> <a name="_stable_state"></a><span class="summary-name">_stable_state</span> = <code title="['ACTIVE', 'DOWN', 'INACTIVE', 'ERROR']"><code class="variable-group">[</code><code class="variable-quote">'</code><code class="variable-string">ACTIVE</code><code class="variable-quote">'</code><code class="variable-op">, </code><code class="variable-quote">'</code><code class="variable-string">DOWN</code><code class="variable-quote">'</code><code class="variable-op">, </code><code class="variable-quote">'</code><code class="variable-string">INACTIVE</code><code class="variable-quote">'</code><code class="variable-op">, </code><code class="variable-quote">'</code><code class="variable-string">ERROR</code><code class="variable-quote">'</code><code class="variable-group">]</code></code> </td> </tr> <tr> <td colspan="2" class="summary"> <div class="private"> <p class="indent-wrapped-lines"><b>Inherited from <code><a href="osclient2.base.Resource-class.html">base.Resource</a></code></b> (private): <code><a href="osclient2.base.Resource-class.html#_attrs" onclick="show_private();">_attrs</a></code>, <code><a href="osclient2.base.Resource-class.html#_id" onclick="show_private();">_id</a></code>, <code><a href="osclient2.base.Resource-class.html#_loaded" onclick="show_private();">_loaded</a></code>, <code><a href="osclient2.base.Resource-class.html#_state_attr" onclick="show_private();">_state_attr</a></code>, <code><a href="osclient2.base.Resource-class.html#_sub_manager_list" onclick="show_private();">_sub_manager_list</a></code> </p></div> </td> </tr> </table> <!-- ==================== PROPERTIES ==================== --> <a name="section-Properties"></a> <table class="summary" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white"> <tr bgcolor="#70b0f0" class="table-header"> <td colspan="2" class="table-header"> <table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr valign="top"> <td align="left"><span class="table-header">Properties</span></td> <td align="right" valign="top" ><span class="options">[<a href="#section-Properties" class="privatelink" onclick="toggle_private();" >hide private</a>]</span></td> </tr> </table> </td> </tr> <tr> <td colspan="2" class="summary"> <p class="indent-wrapped-lines"><b>Inherited from <code>object</code></b>: <code>__class__</code> </p> </td> </tr> </table> <!-- ==================== METHOD DETAILS ==================== --> <a name="section-MethodDetails"></a> <table class="details" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white"> <tr bgcolor="#70b0f0" class="table-header"> <td colspan="2" class="table-header"> <table border="0" cellpadding="0" cellspacing="0" width="100%"> <tr valign="top"> <td align="left"><span class="table-header">Method Details</span></td> <td align="right" valign="top" ><span class="options">[<a href="#section-MethodDetails" class="privatelink" onclick="toggle_private();" >hide private</a>]</span></td> </tr> </table> </td> </tr> </table> <a name="update"></a> <div> <table class="details" border="1" cellpadding="3" cellspacing="0" width="100%" bgcolor="white"> <tr><td> <table width="100%" cellpadding="0" cellspacing="0" border="0"> <tr valign="top"><td> <h3 class="epydoc"><span class="sig"><span class="sig-name">update</span>(<span class="sig-arg">self</span>, <span class="sig-arg">id</span>, <span class="sig-arg">name</span>=<span class="sig-default">None</span>, <span class="sig-arg">is_shared</span>=<span class="sig-default">None</span>, <span class="sig-arg">is_enabled</span>=<span class="sig-default">True</span>, <span class="sig-arg">is_external</span>=<span class="sig-default">None</span>, <span class="sig-arg">is_port_security_enabled</span>=<span class="sig-default">None</span>, <span class="sig-arg">segments</span>=<span class="sig-default">None</span>, <span class="sig-arg">provider_physical_network</span>=<span class="sig-default">None</span>, <span class="sig-arg">provider_network_type</span>=<span class="sig-default">None</span>, <span class="sig-arg">provider_segmentation_id</span>=<span class="sig-default">None</span>)</span> </h3> </td><td align="right" valign="top" ><span class="codelink"><a href="osclient2.neutron.v2.network-pysrc.html#Resource.update">source&nbsp;code</a></span>&nbsp; </td> </tr></table> <p>Update properties of a network</p> <dl class="fields"> <dt>Parameters:</dt> <dd><ul class="nomargin-top"> <li><strong class="pname"><code>name</code></strong> (str) - Network name</li> <li><strong class="pname"><code>is_shared</code></strong> (bool) - Whether the network is shared</li> <li><strong class="pname"><code>is_enabled</code></strong> (bool) - Whether the network is enabled</li> <li><strong class="pname"><code>is_external</code></strong> (bool) - Wehter the network is external</li> <li><strong class="pname"><code>is_port_security_enabled</code></strong> (bool) - Whether the network is secured</li> <li><strong class="pname"><code>segments</code></strong> (str) - Segments</li> <li><strong class="pname"><code>provider_physical_network</code></strong> (str) - (Provider) physical network</li> <li><strong class="pname"><code>provider_network_type</code></strong> (str) - (Provider) network type</li> <li><strong class="pname"><code>provider_segmentation_id</code></strong> (int) - (Provider) segmentation ID</li> </ul></dd> <dt>Returns: None</dt> <dt>Overrides: <a href="osclient2.base.Resource-class.html#update">base.Resource.update</a> </dt> </dl> </td></tr></table> </div> <br /> <!-- ==================== NAVIGATION BAR ==================== --> <table class="navbar" border="0" width="100%" cellpadding="0" bgcolor="#a0c0ff" cellspacing="0"> <tr valign="middle"> <!-- Home link --> <th>&nbsp;&nbsp;&nbsp;<a href="osclient2-module.html">Home</a>&nbsp;&nbsp;&nbsp;</th> <!-- Tree link --> <th>&nbsp;&nbsp;&nbsp;<a href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th> <!-- Index link --> <th>&nbsp;&nbsp;&nbsp;<a href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th> <!-- Help link --> <th>&nbsp;&nbsp;&nbsp;<a href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th> <th class="navbar" width="100%"></th> </tr> </table> <table border="0" cellpadding="0" cellspacing="0" width="100%%"> <tr> <td align="left" class="footer"> Generated by Epydoc 3.0.1 on Mon Feb 20 20:49:21 2017 </td> <td align="right" class="footer"> <a target="mainFrame" href="http://epydoc.sourceforge.net" >http://epydoc.sourceforge.net</a> </td> </tr> </table> <script type="text/javascript"> <!-- // Private objects are initially displayed (because if // javascript is turned off then we want them to be // visible); but by default, we want to hide them. So hide // them unless we have a cookie that says to show them. checkCookie(); // --> </script> </body> </html>
{ "content_hash": "26445ecaeb0e7d8b5e27653849678a82", "timestamp": "", "source": "github", "line_count": 321, "max_line_length": 793, "avg_line_length": 48.26479750778816, "alnum_prop": 0.6040792616020139, "repo_name": "yosshy/osclient2", "id": "6741e8a7c14b37ad0b4d3a945a912af93e0da8b7", "size": "15493", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "doc/osclient2.neutron.v2.network.Resource-class.html", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Python", "bytes": "397008" }, { "name": "Shell", "bytes": "398" } ], "symlink_target": "" }
export * from './component'; export * from './foundation'; export { cssClasses as iconCssClasses, strings as iconStrings } from './constants'; //# sourceMappingURL=index.js.map
{ "content_hash": "e35ff1d68f2e5e74730b87c11e0700ef", "timestamp": "", "source": "github", "line_count": 5, "max_line_length": 83, "avg_line_length": 35.4, "alnum_prop": 0.7344632768361582, "repo_name": "Chan4077/chan4077.github.io", "id": "8314d48494eee4c4f22b65a90445c40fdfc375f5", "size": "1301", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "node_modules/@material/textfield/icon/index.js", "mode": "33188", "license": "mit", "language": [ { "name": "HTML", "bytes": "605030" }, { "name": "JavaScript", "bytes": "56598" } ], "symlink_target": "" }
<!DOCTYPE html> <html> <head> <title>configDiff.js</title> <meta http-equiv="content-type" content="text/html; charset=UTF-8"> <meta name="viewport" content="width=device-width, target-densitydpi=160dpi, initial-scale=1.0; maximum-scale=1.0; user-scalable=0;"> <link rel="stylesheet" media="all" href="docco.css" /> </head> <body> <div id="container"> <div id="background"></div> <ul class="sections"> <li id="title"> <div class="annotation"> <h1>configDiff.js</h1> </div> </li> <li id="section-1"> <div class="annotation"> <div class="pilwrap "> <a class="pilcrow" href="#section-1">&#182;</a> </div> <p>This module computes the difference (“diff”) between two configurations. The diff is returned as an array of Action objects.</p> <p>Based on pervious work found at <a href="https://github.com/curran/overseer/blob/master/src/configDiff.js">https://github.com/curran/overseer/blob/master/src/configDiff.js</a></p> <p>Created by Curran Kelleher Feb 2015</p> </div> <div class="content"><div class='highlight'><pre>define([<span class="hljs-string">"lodash"</span>, <span class="hljs-string">"action"</span>], <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-params">(_, Action)</span> </span>{ <span class="hljs-keyword">return</span> <span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-title">configDiff</span><span class="hljs-params">(oldConfig, newConfig)</span></span>{ <span class="hljs-keyword">var</span> actions = [], newAliases = _.keys(newConfig), oldAliases = _.keys(oldConfig);</pre></div></div> </li> <li id="section-2"> <div class="annotation"> <div class="pilwrap "> <a class="pilcrow" href="#section-2">&#182;</a> </div> <p>Handle removed aliases.</p> </div> <div class="content"><div class='highlight'><pre> _.difference(oldAliases, newAliases).forEach(<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-params">(alias)</span> </span>{ actions.push(Action.destroy(alias)); });</pre></div></div> </li> <li id="section-3"> <div class="annotation"> <div class="pilwrap "> <a class="pilcrow" href="#section-3">&#182;</a> </div> <p>Handle updated aliases.</p> </div> <div class="content"><div class='highlight'><pre> newAliases.forEach(<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-params">(alias)</span> </span>{ <span class="hljs-keyword">var</span> oldModel = alias <span class="hljs-keyword">in</span> oldConfig ? oldConfig[alias].state || {} : <span class="hljs-literal">null</span>, newModel = newConfig[alias].state || {}, oldProperties = _.keys(oldModel), newProperties = _.keys(newModel);</pre></div></div> </li> <li id="section-4"> <div class="annotation"> <div class="pilwrap "> <a class="pilcrow" href="#section-4">&#182;</a> </div> <p>Handle added aliases.</p> </div> <div class="content"><div class='highlight'><pre> <span class="hljs-keyword">if</span>(!oldModel){ actions.push(Action.create(alias, newConfig[alias].plugin)); newProperties.forEach(<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-params">(property)</span> </span>{ actions.push(Action.set(alias, property, newModel[property])); }); } <span class="hljs-keyword">else</span> {</pre></div></div> </li> <li id="section-5"> <div class="annotation"> <div class="pilwrap "> <a class="pilcrow" href="#section-5">&#182;</a> </div> <p>Handle added properties.</p> </div> <div class="content"><div class='highlight'><pre> _.difference(newProperties, oldProperties).forEach(<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-params">(property)</span> </span>{ actions.push(Action.set(alias, property, newModel[property])); });</pre></div></div> </li> <li id="section-6"> <div class="annotation"> <div class="pilwrap "> <a class="pilcrow" href="#section-6">&#182;</a> </div> <p>Handle removed properties.</p> </div> <div class="content"><div class='highlight'><pre> _.difference(oldProperties, newProperties).forEach(<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-params">(property)</span> </span>{ actions.push(Action.unset(alias, property)); });</pre></div></div> </li> <li id="section-7"> <div class="annotation"> <div class="pilwrap "> <a class="pilcrow" href="#section-7">&#182;</a> </div> <p>Handle updated properties.</p> </div> <div class="content"><div class='highlight'><pre> _.intersection(newProperties, oldProperties).forEach(<span class="hljs-function"><span class="hljs-keyword">function</span> <span class="hljs-params">(property)</span> </span>{ <span class="hljs-keyword">if</span>(!_.isEqual(oldModel[property], newModel[property])){ actions.push(Action.set(alias, property, newModel[property])); } }); } }); <span class="hljs-keyword">return</span> actions; }; });</pre></div></div> </li> </ul> </div> </body> </html>
{ "content_hash": "e0a69cfece8c6ed1918df2c268512fb3", "timestamp": "", "source": "github", "line_count": 164, "max_line_length": 280, "avg_line_length": 39.30487804878049, "alnum_prop": 0.5240459199503568, "repo_name": "enjalot/visEditor", "id": "2bbbea8ccf2a8bfdc3b7aec30c6390669d10c740", "size": "6450", "binary": false, "copies": "1", "ref": "refs/heads/gh-pages", "path": "docs/configDiff.html", "mode": "33188", "license": "mit", "language": [ { "name": "HTML", "bytes": "1021" }, { "name": "JavaScript", "bytes": "66208" }, { "name": "Scala", "bytes": "1244" } ], "symlink_target": "" }
<?php add_action('wp_head', 'leeway_css_layout'); function leeway_css_layout() { // Get Theme Options from Database $theme_options = leeway_theme_options(); // Switch Sidebar to left if ( isset($theme_options['layout']) and $theme_options['layout'] == 'left-sidebar' ) : echo '<style type="text/css"> @media only screen and (min-width: 60em) { #content { float: right; padding-right: 0; padding-left: 0.5em; } #sidebar { float: left; } } </style>'; endif; }
{ "content_hash": "97559d4f50624af5b33feb773e199243", "timestamp": "", "source": "github", "line_count": 26, "max_line_length": 88, "avg_line_length": 20, "alnum_prop": 0.5961538461538461, "repo_name": "MarioHdpz/redmaceta", "id": "fb79732a5e093134a8dec3be464cd2b4c654546d", "size": "520", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "blog/wp-content/themes/leeway/inc/customizer/frontend/custom-layout.php", "mode": "33188", "license": "mit", "language": [ { "name": "ApacheConf", "bytes": "1197" }, { "name": "CSS", "bytes": "2487483" }, { "name": "HTML", "bytes": "150343" }, { "name": "JavaScript", "bytes": "3029210" }, { "name": "PHP", "bytes": "11780248" }, { "name": "Shell", "bytes": "8880" } ], "symlink_target": "" }
package org.apache.jackrabbit.oak.upgrade.version; import static com.google.common.collect.Iterables.concat; import static java.util.Collections.singleton; import static org.apache.jackrabbit.JcrConstants.JCR_SYSTEM; import static org.apache.jackrabbit.JcrConstants.JCR_VERSIONSTORAGE; import java.util.ArrayList; import java.util.List; import org.apache.jackrabbit.oak.spi.state.NodeBuilder; import org.apache.jackrabbit.oak.spi.state.NodeState; import com.google.common.base.Joiner; public class VersionHistoryUtil { public static String getVersionHistoryPath(String versionableUuid) { return Joiner.on('/').join(concat( singleton(""), getVersionHistoryPathSegments(versionableUuid), singleton(versionableUuid))); } /** * Constructs the version history path based on the versionable's UUID. * * @param root The root NodeState below which to look for the version. * @param versionableUuid The String representation of the versionable's UUID. * @return The NodeState corresponding to the version history, or {@code null} * if it does not exist. */ static NodeState getVersionHistoryNodeState(NodeState root, String versionableUuid) { NodeState historyParent = root; for (String segment : getVersionHistoryPathSegments(versionableUuid)) { historyParent = historyParent.getChildNode(segment); } return historyParent.getChildNode(versionableUuid); } static NodeBuilder getVersionHistoryBuilder(NodeBuilder root, String versionableUuid) { NodeBuilder history = root; for (String segment : getVersionHistoryPathSegments(versionableUuid)) { history = history.getChildNode(segment); } return history.getChildNode(versionableUuid); } private static List<String> getVersionHistoryPathSegments(String versionableUuid) { final List<String> segments = new ArrayList<String>(); segments.add(JCR_SYSTEM); segments.add(JCR_VERSIONSTORAGE); for (int i = 0; i < 3; i++) { segments.add(versionableUuid.substring(i * 2, i * 2 + 2)); } return segments; } }
{ "content_hash": "c458e805b96ed7384fd86c9bd83afbdc", "timestamp": "", "source": "github", "line_count": 60, "max_line_length": 91, "avg_line_length": 37.18333333333333, "alnum_prop": 0.6992380098610489, "repo_name": "tripodsan/jackrabbit-oak", "id": "a15d704467caa2830a4fcaa8963fc237d274dcf5", "size": "3033", "binary": false, "copies": "2", "ref": "refs/heads/trunk", "path": "oak-upgrade/src/main/java/org/apache/jackrabbit/oak/upgrade/version/VersionHistoryUtil.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "CSS", "bytes": "3451" }, { "name": "Groovy", "bytes": "103255" }, { "name": "Java", "bytes": "16120507" }, { "name": "JavaScript", "bytes": "42583" }, { "name": "Perl", "bytes": "7585" }, { "name": "Shell", "bytes": "17322" } ], "symlink_target": "" }
package zj.ui; import java.util.List; /** * Jquery easyui datagrid * Created by lzj on 2017/1/18. */ public class DataGrid { private int total; private List<Object> rows; public DataGrid() { } public DataGrid(int total, List<Object> rows) { this.total = total; this.rows = rows; } public int getTotal() { return total; } public void setTotal(int total) { this.total = total; } public List<Object> getRows() { return rows; } public void setRows(List<Object> rows) { this.rows = rows; } }
{ "content_hash": "c20f65aa3bad8a53394e6966a8bf2217", "timestamp": "", "source": "github", "line_count": 45, "max_line_length": 49, "avg_line_length": 14.666666666666666, "alnum_prop": 0.5227272727272727, "repo_name": "hqq2023623/easyui-demo", "id": "1fff830b8a61de971c1a36f33a50331d3e219d00", "size": "660", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/main/java/zj/ui/DataGrid.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "CSS", "bytes": "137371" }, { "name": "FreeMarker", "bytes": "18191" }, { "name": "Java", "bytes": "15848" }, { "name": "JavaScript", "bytes": "423839" } ], "symlink_target": "" }
class CDarkSendRelay { public: CTxIn vinMasternode; vector<unsigned char> vchSig; vector<unsigned char> vchSig2; int nBlockHeight; int nRelayType; CTxIn in; CTxOut out; CDarkSendRelay(); CDarkSendRelay(CTxIn& vinMasternodeIn, vector<unsigned char>& vchSigIn, int nBlockHeightIn, int nRelayTypeIn, CTxIn& in2, CTxOut& out2); ADD_SERIALIZE_METHODS; template <typename Stream, typename Operation> inline void SerializationOp(Stream& s, Operation ser_action, int nType, int nVersion) { READWRITE(vinMasternode); READWRITE(vchSig); READWRITE(vchSig2); READWRITE(nBlockHeight); READWRITE(nRelayType); READWRITE(in); READWRITE(out); } std::string ToString(); bool Sign(std::string strSharedKey); bool VerifyMessage(std::string strSharedKey); void Relay(); void RelayThroughNode(int nRank); }; #endif
{ "content_hash": "ae0485df2e7d13f5e9c86bf514577b89", "timestamp": "", "source": "github", "line_count": 38, "max_line_length": 140, "avg_line_length": 24.55263157894737, "alnum_prop": 0.6741693461950696, "repo_name": "axelxod/braincoin", "id": "e282de30c64b6846520abbfeba6c6980382fbcc6", "size": "1254", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/darksend-relay.h", "mode": "33188", "license": "mit", "language": [ { "name": "Assembly", "bytes": "7639" }, { "name": "C", "bytes": "1011702" }, { "name": "C++", "bytes": "4164153" }, { "name": "CSS", "bytes": "39900" }, { "name": "Groff", "bytes": "17909" }, { "name": "HTML", "bytes": "50621" }, { "name": "Java", "bytes": "2100" }, { "name": "M4", "bytes": "141704" }, { "name": "Makefile", "bytes": "87255" }, { "name": "Objective-C", "bytes": "2023" }, { "name": "Objective-C++", "bytes": "7233" }, { "name": "Protocol Buffer", "bytes": "2308" }, { "name": "Python", "bytes": "211181" }, { "name": "QMake", "bytes": "26228" }, { "name": "Shell", "bytes": "41562" } ], "symlink_target": "" }
<?php namespace Google\AdsApi\Dfp\v201702; /** * This file was generated from WSDL. DO NOT EDIT. */ class PackageService extends \Google\AdsApi\Common\AdsSoapClient { /** * @var array $classmap The defined classes */ private static $classmap = array ( 'ObjectValue' => 'Google\\AdsApi\\Dfp\\v201702\\ObjectValue', 'ApiError' => 'Google\\AdsApi\\Dfp\\v201702\\ApiError', 'ApiException' => 'Google\\AdsApi\\Dfp\\v201702\\ApiException', 'ApiVersionError' => 'Google\\AdsApi\\Dfp\\v201702\\ApiVersionError', 'ApplicationException' => 'Google\\AdsApi\\Dfp\\v201702\\ApplicationException', 'AuthenticationError' => 'Google\\AdsApi\\Dfp\\v201702\\AuthenticationError', 'AvailableBillingError' => 'Google\\AdsApi\\Dfp\\v201702\\AvailableBillingError', 'BillingError' => 'Google\\AdsApi\\Dfp\\v201702\\BillingError', 'BooleanValue' => 'Google\\AdsApi\\Dfp\\v201702\\BooleanValue', 'CollectionSizeError' => 'Google\\AdsApi\\Dfp\\v201702\\CollectionSizeError', 'CommonError' => 'Google\\AdsApi\\Dfp\\v201702\\CommonError', 'CreateProposalLineItemsFromPackages' => 'Google\\AdsApi\\Dfp\\v201702\\CreateProposalLineItemsFromPackages', 'CustomFieldValueError' => 'Google\\AdsApi\\Dfp\\v201702\\CustomFieldValueError', 'CustomTargetingError' => 'Google\\AdsApi\\Dfp\\v201702\\CustomTargetingError', 'Date' => 'Google\\AdsApi\\Dfp\\v201702\\Date', 'DateTime' => 'Google\\AdsApi\\Dfp\\v201702\\DateTime', 'DateTimeValue' => 'Google\\AdsApi\\Dfp\\v201702\\DateTimeValue', 'DateValue' => 'Google\\AdsApi\\Dfp\\v201702\\DateValue', 'DayPartTargetingError' => 'Google\\AdsApi\\Dfp\\v201702\\DayPartTargetingError', 'EntityChildrenLimitReachedError' => 'Google\\AdsApi\\Dfp\\v201702\\EntityChildrenLimitReachedError', 'EntityLimitReachedError' => 'Google\\AdsApi\\Dfp\\v201702\\EntityLimitReachedError', 'FeatureError' => 'Google\\AdsApi\\Dfp\\v201702\\FeatureError', 'FieldPathElement' => 'Google\\AdsApi\\Dfp\\v201702\\FieldPathElement', 'FrequencyCapError' => 'Google\\AdsApi\\Dfp\\v201702\\FrequencyCapError', 'GenericTargetingError' => 'Google\\AdsApi\\Dfp\\v201702\\GenericTargetingError', 'GeoTargetingError' => 'Google\\AdsApi\\Dfp\\v201702\\GeoTargetingError', 'InternalApiError' => 'Google\\AdsApi\\Dfp\\v201702\\InternalApiError', 'InventoryTargetingError' => 'Google\\AdsApi\\Dfp\\v201702\\InventoryTargetingError', 'LabelEntityAssociationError' => 'Google\\AdsApi\\Dfp\\v201702\\LabelEntityAssociationError', 'NotNullError' => 'Google\\AdsApi\\Dfp\\v201702\\NotNullError', 'NumberValue' => 'Google\\AdsApi\\Dfp\\v201702\\NumberValue', 'PackageAction' => 'Google\\AdsApi\\Dfp\\v201702\\PackageAction', 'PackageActionError' => 'Google\\AdsApi\\Dfp\\v201702\\PackageActionError', 'Package' => 'Google\\AdsApi\\Dfp\\v201702\\Package', 'PackageError' => 'Google\\AdsApi\\Dfp\\v201702\\PackageError', 'PackagePage' => 'Google\\AdsApi\\Dfp\\v201702\\PackagePage', 'ParseError' => 'Google\\AdsApi\\Dfp\\v201702\\ParseError', 'PermissionError' => 'Google\\AdsApi\\Dfp\\v201702\\PermissionError', 'PrecisionError' => 'Google\\AdsApi\\Dfp\\v201702\\PrecisionError', 'ProductError' => 'Google\\AdsApi\\Dfp\\v201702\\ProductError', 'ProposalError' => 'Google\\AdsApi\\Dfp\\v201702\\ProposalError', 'ProposalLineItemError' => 'Google\\AdsApi\\Dfp\\v201702\\ProposalLineItemError', 'PublisherQueryLanguageContextError' => 'Google\\AdsApi\\Dfp\\v201702\\PublisherQueryLanguageContextError', 'PublisherQueryLanguageSyntaxError' => 'Google\\AdsApi\\Dfp\\v201702\\PublisherQueryLanguageSyntaxError', 'QuotaError' => 'Google\\AdsApi\\Dfp\\v201702\\QuotaError', 'RangeError' => 'Google\\AdsApi\\Dfp\\v201702\\RangeError', 'RequiredCollectionError' => 'Google\\AdsApi\\Dfp\\v201702\\RequiredCollectionError', 'RequiredError' => 'Google\\AdsApi\\Dfp\\v201702\\RequiredError', 'RequiredNumberError' => 'Google\\AdsApi\\Dfp\\v201702\\RequiredNumberError', 'ReservationDetailsError' => 'Google\\AdsApi\\Dfp\\v201702\\ReservationDetailsError', 'ServerError' => 'Google\\AdsApi\\Dfp\\v201702\\ServerError', 'SetValue' => 'Google\\AdsApi\\Dfp\\v201702\\SetValue', 'SoapRequestHeader' => 'Google\\AdsApi\\Dfp\\v201702\\SoapRequestHeader', 'SoapResponseHeader' => 'Google\\AdsApi\\Dfp\\v201702\\SoapResponseHeader', 'Statement' => 'Google\\AdsApi\\Dfp\\v201702\\Statement', 'StatementError' => 'Google\\AdsApi\\Dfp\\v201702\\StatementError', 'StringLengthError' => 'Google\\AdsApi\\Dfp\\v201702\\StringLengthError', 'String_ValueMapEntry' => 'Google\\AdsApi\\Dfp\\v201702\\String_ValueMapEntry', 'TeamError' => 'Google\\AdsApi\\Dfp\\v201702\\TeamError', 'TechnologyTargetingError' => 'Google\\AdsApi\\Dfp\\v201702\\TechnologyTargetingError', 'TextValue' => 'Google\\AdsApi\\Dfp\\v201702\\TextValue', 'TimeZoneError' => 'Google\\AdsApi\\Dfp\\v201702\\TimeZoneError', 'UniqueError' => 'Google\\AdsApi\\Dfp\\v201702\\UniqueError', 'UpdateResult' => 'Google\\AdsApi\\Dfp\\v201702\\UpdateResult', 'UserDomainTargetingError' => 'Google\\AdsApi\\Dfp\\v201702\\UserDomainTargetingError', 'Value' => 'Google\\AdsApi\\Dfp\\v201702\\Value', 'createPackagesResponse' => 'Google\\AdsApi\\Dfp\\v201702\\createPackagesResponse', 'getPackagesByStatementResponse' => 'Google\\AdsApi\\Dfp\\v201702\\getPackagesByStatementResponse', 'performPackageActionResponse' => 'Google\\AdsApi\\Dfp\\v201702\\performPackageActionResponse', 'updatePackagesResponse' => 'Google\\AdsApi\\Dfp\\v201702\\updatePackagesResponse', ); /** * @param array $options A array of config values * @param string $wsdl The wsdl file to use */ public function __construct(array $options = array(), $wsdl = 'https://ads.google.com/apis/ads/publisher/v201702/PackageService?wsdl') { foreach (self::$classmap as $key => $value) { if (!isset($options['classmap'][$key])) { $options['classmap'][$key] = $value; } } $options = array_merge(array ( 'features' => 1, ), $options); parent::__construct($wsdl, $options); } /** * Creates new {@link Package} objects. * * For each package, the following fields are required: * <ul> * <li>{@link Package#proposalId}</li> * <li>{@link Package#productPackageId}</li> * <li>{@link Package#name}</li> * </ul> * * @param \Google\AdsApi\Dfp\v201702\Package[] $packages * @return \Google\AdsApi\Dfp\v201702\Package[] * @throws \Google\AdsApi\Dfp\v201702\ApiException */ public function createPackages(array $packages) { return $this->__soapCall('createPackages', array(array('packages' => $packages)))->getRval(); } /** * Gets a {@link PackagePage} of {@link Package} objects * that satisfy the given {@link Statement#query}. The following fields are supported for * filtering: * * <table> * <tr> * <th scope="col">PQL Property</th> <th scope="col">Object Property</th> * </tr> * <tr> * <td>{@code id}</td> * <td>{@link Package#id}</td> * </tr> * <tr> * <td>{@code name}</td> * <td>{@link Package#name}</td> * </tr> * <tr> * <td>{@code proposalId}</td> * <td>{@link Package#proposalId}</td> * </tr> * <tr> * <td>{@code productPackageId}</td> * <td>{@link Package#productPackageId}</td> * </tr> * <tr> * <td>{@code isArchived}</td> * <td>{@link Package#isArchived}</td> * </tr> * <tr> * <td>{@code lastModifiedDateTime}</td> * <td>{@link Package#lastModifiedDateTime}</td> * </tr> * </table> * * a set of packages * * @param \Google\AdsApi\Dfp\v201702\Statement $filterStatement * @return \Google\AdsApi\Dfp\v201702\PackagePage * @throws \Google\AdsApi\Dfp\v201702\ApiException */ public function getPackagesByStatement(\Google\AdsApi\Dfp\v201702\Statement $filterStatement) { return $this->__soapCall('getPackagesByStatement', array(array('filterStatement' => $filterStatement)))->getRval(); } /** * Performs actions on {@link Package} objects that match the given {@link Statement}. * * @param \Google\AdsApi\Dfp\v201702\PackageAction $packageAction * @param \Google\AdsApi\Dfp\v201702\Statement $filterStatement * @return \Google\AdsApi\Dfp\v201702\UpdateResult * @throws \Google\AdsApi\Dfp\v201702\ApiException */ public function performPackageAction(\Google\AdsApi\Dfp\v201702\PackageAction $packageAction, \Google\AdsApi\Dfp\v201702\Statement $filterStatement) { return $this->__soapCall('performPackageAction', array(array('packageAction' => $packageAction, 'filterStatement' => $filterStatement)))->getRval(); } /** * Updates the specified {@link Package} objects. * * @param \Google\AdsApi\Dfp\v201702\Package[] $packages * @return \Google\AdsApi\Dfp\v201702\Package[] * @throws \Google\AdsApi\Dfp\v201702\ApiException */ public function updatePackages(array $packages) { return $this->__soapCall('updatePackages', array(array('packages' => $packages)))->getRval(); } }
{ "content_hash": "65b236e0271056e339361b6490aeac7b", "timestamp": "", "source": "github", "line_count": 196, "max_line_length": 154, "avg_line_length": 48.464285714285715, "alnum_prop": 0.6569112538161912, "repo_name": "jeraldfeller/jbenterprises", "id": "be1390448d2f70b041443a2366e655a995f1e668", "size": "9499", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "google-adwords/vendor/googleads/googleads-php-lib/src/Google/AdsApi/Dfp/v201702/PackageService.php", "mode": "33188", "license": "mit", "language": [ { "name": "Batchfile", "bytes": "137" }, { "name": "CSS", "bytes": "4465774" }, { "name": "CoffeeScript", "bytes": "83631" }, { "name": "HTML", "bytes": "2549782" }, { "name": "JavaScript", "bytes": "17552996" }, { "name": "PHP", "bytes": "3092947" }, { "name": "Shell", "bytes": "444" } ], "symlink_target": "" }
const path = require('path'), puppeteer = require('puppeteer'); const fileUrl = (relPath) => { return 'file://' + path.resolve(process.cwd(), relPath); }; const bundlePage = async (url) => { const browser = await puppeteer.launch({args: ['--allow-file-access-from-files']}), page = await browser.newPage(), pageUrl = fileUrl(url); page.on('console', msg => { for (let i = 0; i < msg.args().length; ++i) { console.warn(`${i}: ${msg.args()[i]}`); } }); page.on('pageerror', msg => { console.error(msg); }); await page.goto(fileUrl('examples/bundlePage.html')); const xhtml = await page.evaluate(function (pageUrl) { return bundlePage(pageUrl); }, pageUrl); console.log(xhtml); browser.close(); }; const main = async () => { if (process.argv.length !== 3) { console.log('Usage: ' + path.basename(process.argv[1]) + ' PAGE_TO_INLINE'); console.log("Inlines resources of a given page into one big XHTML document"); process.exit(1); } const pageToInline = process.argv[2]; await bundlePage(pageToInline); }; (async () => { try { await main(); process.exit(0); } catch (e) { console.error(e); process.exit(1); } })();
{ "content_hash": "daac791488022334d92d6c0035552338", "timestamp": "", "source": "github", "line_count": 52, "max_line_length": 87, "avg_line_length": 25.365384615384617, "alnum_prop": 0.5549658832448825, "repo_name": "JustinShenk/party-pi", "id": "1ff0e9ef015e0004ce1c8d6eef1c58c9b698b3e4", "size": "1340", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "partypi/static/node_modules/inlineresources/examples/bundlePage.js", "mode": "33261", "license": "mit", "language": [ { "name": "CSS", "bytes": "7189" }, { "name": "HTML", "bytes": "31453" }, { "name": "JavaScript", "bytes": "212257" }, { "name": "Python", "bytes": "47381" } ], "symlink_target": "" }
using System; using System.Collections.Generic; using System.Linq; using System.Web; using System.Web.Mvc; namespace front_web.Controllers { public class HomeController : Controller { public ActionResult Index() { return View(); } } }
{ "content_hash": "8dcccb7c0ba3982cfe84ee0a5f7a74e2", "timestamp": "", "source": "github", "line_count": 16, "max_line_length": 44, "avg_line_length": 17.8125, "alnum_prop": 0.6385964912280702, "repo_name": "rogerio-iokoi/web-csharp-001", "id": "189b0a6f2cb9f4bf047d4955adfa8cd8ba17da8e", "size": "287", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "front-web/Controllers/HomeController.cs", "mode": "33188", "license": "mit", "language": [ { "name": "ASP", "bytes": "103" }, { "name": "C#", "bytes": "10552" }, { "name": "CSS", "bytes": "13188" }, { "name": "JavaScript", "bytes": "281" } ], "symlink_target": "" }
echo "Starting capture frontend" nginx -g 'daemon off;'
{ "content_hash": "481b9eb2df61889e7c19d9a0748663c5", "timestamp": "", "source": "github", "line_count": 3, "max_line_length": 32, "avg_line_length": 18.666666666666668, "alnum_prop": 0.75, "repo_name": "fstn/poc-angular4-springSecurity", "id": "c5cc4d45b1b6cad1c28abc2b68bdb5668528eeeb", "size": "67", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "docker-parent/frontend/init/entry-point.sh", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "CSS", "bytes": "997" }, { "name": "HTML", "bytes": "12629" }, { "name": "Java", "bytes": "30896" }, { "name": "JavaScript", "bytes": "41924" }, { "name": "Shell", "bytes": "67" }, { "name": "TypeScript", "bytes": "24287" } ], "symlink_target": "" }
package liquibase.parser.core.xml; import liquibase.parser.LiquibaseParser; import liquibase.parser.NamespaceDetails; import liquibase.parser.NamespaceDetailsFactory; import liquibase.serializer.LiquibaseSerializer; import liquibase.util.StreamUtil; import org.xml.sax.InputSource; import java.io.IOException; import java.io.InputStream; import liquibase.logging.LogFactory; import liquibase.logging.Logger; import liquibase.resource.ResourceAccessor; import liquibase.util.file.FilenameUtils; import org.xml.sax.SAXException; import org.xml.sax.ext.EntityResolver2; /** * Finds the Liquibase schema from the classpath rather than fetching it over the Internet. * Also resolve external entities using a resourceAccessor if it's provided */ public class LiquibaseEntityResolver implements EntityResolver2 { private LiquibaseParser parser; private LiquibaseSerializer serializer; private ResourceAccessor resourceAccessor; private String basePath; private Logger log=LogFactory.getLogger(); public LiquibaseEntityResolver(LiquibaseSerializer serializer) { this.serializer = serializer; } public LiquibaseEntityResolver(LiquibaseParser parser) { this.parser = parser; } /** * Use the resource accessor to resolve external entities * @param resourceAccessor Resource accessor to use * @param basePath Base path to use in the resourceAccessor */ public void useResoureAccessor(ResourceAccessor resourceAccessor,String basePath) { this.resourceAccessor=resourceAccessor; this.basePath=basePath; } @Override public InputSource resolveEntity(String name, String publicId, String baseURI, String systemId) throws SAXException, IOException { InputSource resolved=null; if(systemId!=null && systemId.toLowerCase().endsWith(".xsd")) { if (systemId.startsWith("http://www.liquibase.org/xml/ns/migrator/")) { systemId = systemId.replace("http://www.liquibase.org/xml/ns/migrator/", "http://www.liquibase.org/xml/ns/dbchangelog/"); } resolved=tryResolveLiquibaseSchema(systemId, publicId); } if(resolved==null && resourceAccessor!=null && basePath!=null && systemId!=null) { resolved=tryResolveFromResourceAccessor(systemId); } return resolved; } private InputSource tryResolveLiquibaseSchema(String systemId, String publicId) { if (systemId != null) { NamespaceDetails namespaceDetails; if (serializer != null) { namespaceDetails = NamespaceDetailsFactory.getInstance().getNamespaceDetails(serializer, systemId); } else { namespaceDetails = NamespaceDetailsFactory.getInstance().getNamespaceDetails(parser, systemId); } if (namespaceDetails == null) { return null; } String xsdFile = namespaceDetails.getLocalPath(systemId); if (xsdFile == null) { return null; } try { InputStream resourceAsStream = StreamUtil.singleInputStream(xsdFile, resourceAccessor); if (resourceAsStream == null) { if (Thread.currentThread().getContextClassLoader() != null) { resourceAsStream = Thread.currentThread().getContextClassLoader().getResourceAsStream(xsdFile); } if (resourceAsStream == null) { resourceAsStream = this.getClass().getClassLoader().getResourceAsStream(xsdFile); } } if (resourceAsStream == null) { return null; } InputSource source = new InputSource(resourceAsStream); source.setPublicId(publicId); source.setSystemId(systemId); return source; } catch (Exception ex) { return null; // We don't have the schema, try the network } } return null; } private InputSource tryResolveFromResourceAccessor(String systemId) { String path=FilenameUtils.concat(basePath, systemId); try { InputStream resourceAsStream = StreamUtil.singleInputStream(path, resourceAccessor); if (resourceAsStream == null) { return null; } return new InputSource(resourceAsStream); }catch(Exception ex) { return null; } } @Override public InputSource getExternalSubset(String name, String baseURI) throws SAXException, IOException { return null; } @Override public InputSource resolveEntity(String publicId, String systemId) throws SAXException, IOException { log.warning("Current XML parsers seems to not support EntityResolver2. External entities won't be correctly loaded"); return tryResolveLiquibaseSchema(systemId, publicId); } }
{ "content_hash": "ae28e876c5993274299e53efb9fca46a", "timestamp": "", "source": "github", "line_count": 129, "max_line_length": 136, "avg_line_length": 39.02325581395349, "alnum_prop": 0.6571315057608264, "repo_name": "adriens/liquibase", "id": "e7eb6d614e66b091353390c07ca7c326d0b8554e", "size": "5034", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "liquibase-core/src/main/java/liquibase/parser/core/xml/LiquibaseEntityResolver.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "CSS", "bytes": "1202" }, { "name": "Groovy", "bytes": "449643" }, { "name": "Java", "bytes": "3621090" }, { "name": "Puppet", "bytes": "5196" }, { "name": "Ruby", "bytes": "4959" }, { "name": "Shell", "bytes": "5870" } ], "symlink_target": "" }
package org.apache.flink.table.utils; import org.apache.flink.table.api.DataTypes; import org.apache.flink.table.api.TableSchema; import org.apache.flink.table.api.ValidationException; import org.junit.Rule; import org.junit.Test; import org.junit.rules.ExpectedException; import static org.junit.Assert.assertEquals; /** Tests for TableSchemaUtils. */ public class TableSchemaUtilsTest { @Rule public ExpectedException exceptionRule = ExpectedException.none(); @Test public void testBuilderWithGivenSchema() { TableSchema oriSchema = TableSchema.builder() .field("a", DataTypes.INT().notNull()) .field("b", DataTypes.STRING()) .field("c", DataTypes.INT(), "a + 1") .field("t", DataTypes.TIMESTAMP(3)) .primaryKey("ct1", new String[] {"a"}) .watermark("t", "t", DataTypes.TIMESTAMP(3)) .build(); TableSchema newSchema = TableSchemaUtils.builderWithGivenSchema(oriSchema).build(); assertEquals(oriSchema, newSchema); } @Test public void testDropConstraint() { TableSchema oriSchema = TableSchema.builder() .field("a", DataTypes.INT().notNull()) .field("b", DataTypes.STRING()) .field("c", DataTypes.INT(), "a + 1") .field("t", DataTypes.TIMESTAMP(3)) .primaryKey("ct1", new String[] {"a"}) .watermark("t", "t", DataTypes.TIMESTAMP(3)) .build(); TableSchema newSchema = TableSchemaUtils.dropConstraint(oriSchema, "ct1"); final String expected = "root\n" + " |-- a: INT NOT NULL\n" + " |-- b: STRING\n" + " |-- c: INT AS a + 1\n" + " |-- t: TIMESTAMP(3)\n" + " |-- WATERMARK FOR t AS t\n"; assertEquals(expected, newSchema.toString()); // Drop non-exist constraint. exceptionRule.expect(ValidationException.class); exceptionRule.expectMessage("Constraint ct2 to drop does not exist"); TableSchemaUtils.dropConstraint(oriSchema, "ct2"); } }
{ "content_hash": "e2365d6314496077dc2d4207afe1d7a8", "timestamp": "", "source": "github", "line_count": 57, "max_line_length": 85, "avg_line_length": 32.473684210526315, "alnum_prop": 0.6877363587250135, "repo_name": "hequn8128/flink", "id": "e96ddd94df69a4a41004331c94ca64a5a92999fd", "size": "2652", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "flink-table/flink-table-common/src/test/java/org/apache/flink/table/utils/TableSchemaUtilsTest.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Batchfile", "bytes": "4722" }, { "name": "CSS", "bytes": "58149" }, { "name": "Clojure", "bytes": "93247" }, { "name": "Dockerfile", "bytes": "12142" }, { "name": "FreeMarker", "bytes": "28662" }, { "name": "HTML", "bytes": "108850" }, { "name": "Java", "bytes": "53666624" }, { "name": "JavaScript", "bytes": "1829" }, { "name": "Makefile", "bytes": "5134" }, { "name": "Python", "bytes": "1132776" }, { "name": "Scala", "bytes": "13885013" }, { "name": "Shell", "bytes": "533455" }, { "name": "TSQL", "bytes": "123113" }, { "name": "TypeScript", "bytes": "249103" } ], "symlink_target": "" }
<html dir="LTR"> <head> <meta http-equiv="Content-Type" content="text/html; charset=Windows-1252" /> <meta name="vs_targetSchema" content="http://schemas.microsoft.com/intellisense/ie5" /> <title>LoggingEvent Properties</title> <xml> </xml> <link rel="stylesheet" type="text/css" href="MSDN.css" /> </head> <body id="bodyID" class="dtBODY"> <div id="nsbanner"> <div id="bannerrow1"> <table class="bannerparthead" cellspacing="0"> <tr id="hdr"> <td class="runninghead">Apache log4net™ SDK Documentation - Microsoft .NET Framework 4.0</td> <td class="product"> </td> </tr> </table> </div> <div id="TitleRow"> <h1 class="dtH1">LoggingEvent Properties</h1> </div> </div> <div id="nstext"> <p>The properties of the <b>LoggingEvent</b> class are listed below. For a complete list of <b>LoggingEvent</b> class members, see the <a href="log4net.Core.LoggingEventMembers.html">LoggingEvent Members</a> topic.</p> <h4 class="dtH4">Public Static (Shared) Properties</h4> <div class="tablediv"> <table class="dtTABLE" cellspacing="0"> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><img src="static.gif" /><a href="log4net.Core.LoggingEvent.StartTime.html">StartTime</a></td><td width="50%"> Gets the time when the current process started. </td></tr></table> </div> <h4 class="dtH4">Public Instance Properties</h4> <div class="tablediv"> <table class="dtTABLE" cellspacing="0"> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.Domain.html">Domain</a></td><td width="50%"> Gets the AppDomain friendly name. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.ExceptionObject.html">ExceptionObject</a></td><td width="50%"> Gets the exception object used to initialize this event. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.Fix.html">Fix</a></td><td width="50%"> The fixed fields in this event </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.Identity.html">Identity</a></td><td width="50%"> Gets the identity of the current thread principal. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.Level.html">Level</a></td><td width="50%"> Gets the <b>Level</b> of the logging event. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.LocationInformation.html">LocationInformation</a></td><td width="50%"> Gets the location information for this logging event. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.LoggerName.html">LoggerName</a></td><td width="50%"> Gets the name of the logger that logged the event. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.MessageObject.html">MessageObject</a></td><td width="50%"> Gets the message object used to initialize this event. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.Properties.html">Properties</a></td><td width="50%"> Additional event specific properties. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.RenderedMessage.html">RenderedMessage</a></td><td width="50%"> Gets the message, rendered through the <a href="log4net.Repository.ILoggerRepository.RendererMap.html">RendererMap</a>. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.Repository.html">Repository</a></td><td width="50%"> The <a href="log4net.Repository.ILoggerRepository.html">ILoggerRepository</a> that this event was created in. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.ThreadName.html">ThreadName</a></td><td width="50%"> Gets the name of the current thread. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.TimeStamp.html">TimeStamp</a></td><td width="50%"> Gets the time of the logging event. </td></tr> <tr VALIGN="top"><td width="50%"><img src="pubproperty.gif"></img><a href="log4net.Core.LoggingEvent.UserName.html">UserName</a></td><td width="50%"> Gets the name of the current user. </td></tr></table> </div> <h4 class="dtH4">See Also</h4> <p> <a href="log4net.Core.LoggingEvent.html">LoggingEvent Class</a> | <a href="log4net.Core.html">log4net.Core Namespace</a></p> <object type="application/x-oleobject" classid="clsid:1e2a7bd0-dab9-11d0-b93a-00c04fc99f9e" viewastext="true" style="display: none;"> <param name="Keyword" value="LoggingEvent class, properties"> </param> </object> <hr /> <div id="footer"><a href='http://logging.apache.org/log4net/'>Copyright 2004-2013 The Apache Software Foundation.</a><br></br>Apache log4net, Apache and log4net are trademarks of The Apache Software Foundation.</div> </div> </body> </html>
{ "content_hash": "5b6111d7e9eadffb91bb6ff75b9f805a", "timestamp": "", "source": "github", "line_count": 61, "max_line_length": 294, "avg_line_length": 88.54098360655738, "alnum_prop": 0.6682095908165154, "repo_name": "gersonkurz/manualisator", "id": "718f900000ab88a688e736d7a80958d88d798f79", "size": "5401", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "manualisator/log4net-1.2.13/doc/release/sdk/log4net.Core.LoggingEventProperties.html", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "C#", "bytes": "235121" }, { "name": "CSS", "bytes": "15869" }, { "name": "HTML", "bytes": "9723377" }, { "name": "JavaScript", "bytes": "5685" }, { "name": "NSIS", "bytes": "1916" }, { "name": "Shell", "bytes": "1041" } ], "symlink_target": "" }
package org.headsupdev.support.java; import java.io.*; import java.util.List; /** * A utility class that handles with the streaming data and resource management when executing commands. * * Created: 12/04/2013 * * @author Andrew Williams * @since 1.5 */ public class ExecUtil { public static final int EXECUTION_FAILED = -1; public static final int EXECUTION_INTERRUPTED = -2; /** * Execute the given command in the current application's working directory. * * @param commands The command to execute, where item 0 is the executable and the others are parameters * @return The return code of the command * @throws IOException If the command could not be executed */ public static int execute( List<String> commands ) throws IOException { return execute( commands, null ); } /** * Execute the given command in the specified working directory. * * @param commands The command to execute, where item 0 is the executable and the others are parameters * @param dir The working directory to execute in * @return The return code of the command * @throws IOException If the command could not be executed */ public static int execute( List<String> commands, File dir ) throws IOException { return execute( commands, dir, null, null ); } /** * Execute the given command in the specified working directory. * * @param commands The command to execute, where item 0 is the executable and the others are parameters * @param dir The working directory to execute in * @param output A writer for copying the standard output to * @param error A writer for copying the standard error to * @return The return code of the command * @throws IOException If the command could not be executed */ public static int execute( List<String> commands, File dir, Writer output, Writer error ) throws IOException { ExecConfig config = new ExecConfig( commands, dir, output, error ); return config.run(); } /** * Execute the given command in the current application's working directory. * Any exceptions encountered will be appended to the error writer. * * @param commands The command to execute, where item 0 is the executable and the others are parameters * @param output A writer for copying the standard output to * @param error A writer for copying the standard error to * @return The return code of the command */ public static int executeLoggingExceptions( List<String> commands, Writer output, Writer error ) { return executeLoggingExceptions( commands, null, output, error ); } /** * Execute the given command in the specified working directory. * Any exceptions encountered will be appended to the error writer. * * @param commands The command to execute, where item 0 is the executable and the others are parameters * @param dir The working directory to execute in * @param output A writer for copying the standard output to * @param error A writer for copying the standard error to * @return The return code of the command */ public static int executeLoggingExceptions( List<String> commands, File dir, Writer output, Writer error ) { ExecConfig config = new ExecConfig( commands, dir, output, error ); try { return config.run(); } catch ( IOException e ) { if ( error != null ) { e.printStackTrace( new PrintWriter( error ) ); } return ExecUtil.EXECUTION_FAILED; } } } class ExecConfig { private List<String> commands; private File dir; private Writer outWriter, errWriter; private StreamGobbler sout, serr; private Process process; public ExecConfig( List<String> commands, File dir, Writer output, Writer error ) { this.commands = commands; this.dir = dir; this.outWriter = output; this.errWriter = error; } public int run() throws IOException { int ret = ExecUtil.EXECUTION_FAILED; try { process = Runtime.getRuntime().exec( commands.toArray( new String[commands.size()] ), null, dir ); sout = new StreamGobbler( new InputStreamReader( process.getInputStream() ), outWriter ); serr = new StreamGobbler( new InputStreamReader( process.getErrorStream() ), errWriter ); serr.start(); sout.start(); ret = process.waitFor(); } catch ( InterruptedException e ) { // TODO use this hook when we cancel the process ret = ExecUtil.EXECUTION_INTERRUPTED; } finally { if ( process != null ) { // defensively try to close the gobblers waitForStreamGobblersToComplete(); IOUtil.close( process.getOutputStream() ); IOUtil.close( process.getErrorStream() ); IOUtil.close( process.getInputStream() ); process.destroy(); } } return ret; } private void waitForStreamGobblersToComplete() { // defensively try to close the gobblers // check that our gobblers are finished... while ( !isComplete( sout ) || !isComplete( serr ) ) { try { Thread.sleep( 500 ); } catch ( InterruptedException e ) { // we were just trying to tidy up... } } } private boolean isComplete( StreamGobbler gobbler ) { return ( gobbler == null || gobbler.isComplete() ); } } class StreamGobbler extends Thread { private Reader in; private Writer out; private boolean complete = false; public StreamGobbler( Reader in, Writer out ) { this.in = in; this.out = out; } public void run() { try { BufferedReader reader = new BufferedReader( in ); String line; while ( ( line = reader.readLine() ) != null ) { if ( out != null ) { out.write( line ); out.write( '\n' ); } } } catch ( IOException e ) { e.printStackTrace(); } complete = true; } public boolean isComplete() { return complete; } }
{ "content_hash": "8371a0b6b5ea271daf66daa64dfb8335", "timestamp": "", "source": "github", "line_count": 229, "max_line_length": 110, "avg_line_length": 29.353711790393014, "alnum_prop": 0.5920856887831003, "repo_name": "headsupdev/java-support", "id": "8e266db938059ef5732a95b12008868df212facc", "size": "7331", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/main/java/org/headsupdev/support/java/ExecUtil.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Java", "bytes": "72498" } ], "symlink_target": "" }
import { Injectable } from '@angular/core'; import { Headers, Http } from '@angular/http'; import 'rxjs/add/operator/toPromise'; import { AshaWorkerBasicDetailsModel } from '../model/asha-worker-basic-details-model'; import { AshaWorkersList, DummyAshaWorkerDetails } from './temporary/temp-data'; import { AshaWorkerPaymentRulesModel } from '../model/asha-worker-payment-rules-model'; import { JSONMessageModel } from '../model/json-message-model'; @Injectable() export class AshaWorkersDetailsService{ private url: string = "http://www.ashavizianagaram.in:81/ashaservices/webapi/"; private getAshaWorkerURLMethod: string ="getdetails/get_asha_worker_details"; private addAshaWorkerURLMethod: string = "getdetails/add_asha_worker_details"; private updatePaymentActivityRulesURLMethod: string = "ashaActivityRules/updateActivity" constructor(private http: Http){} addNewAshaWorker(ashaWorkers): Promise<AshaWorkerBasicDetailsModel>{ return this.http.post(this.url+this.addAshaWorkerURLMethod) .toPromise() .then } getAshaWorkersList(): Promise<AshaWorkerBasicDetailsModel[]>{ //return Promise.resolve(AshaWorkersList); return this.http.get(this.url+this.getAshaWorkerURLMethod) .toPromise() .then(response => response.json().awAshaDetailsModel as AshaWorkerBasicDetailsModel[]) .catch(this.handleError); } getDummyAshaWorkerDetails(): Promise<AshaWorkerBasicDetailsModel>{ return Promise.resolve(DummyAshaWorkerDetails); } private headers = new Headers({'Content-Type': 'application/json'}); //update the payment rules for rural, urban and help text updateAshaWorkerPaymentRules(ashaWorkerPaymentRulesModel: AshaWorkerPaymentRulesModel): Promise<JSONMessageModel>{ let body = JSON.stringify(ashaWorkerPaymentRulesModel); //headers = new Headers(); console.log("bodyy = "+ body); console.log("headers = "+ this.headers); return this.http.post(this.url + this.updatePaymentActivityRulesURLMethod,body, {headers: this.headers}) .toPromise() .then(response => response.json() as JSONMessageModel) .catch(this.handleError) } private handleError(error: any):Promise<any>{ console.error('An error occured', error); return Promise.reject(error.message || error); } }
{ "content_hash": "4e3eb12feaf98939abae7da5523932fa", "timestamp": "", "source": "github", "line_count": 63, "max_line_length": 130, "avg_line_length": 40.38095238095238, "alnum_prop": 0.675314465408805, "repo_name": "mnjkumar426/asha_front", "id": "e754f5a5f530fd6931a124e76f819edbbda1a9bd", "size": "2544", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": ".history/src/app/service/asha-workers-details.service_20170301103820.ts", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "116931" }, { "name": "HTML", "bytes": "21330469" }, { "name": "JavaScript", "bytes": "98708" }, { "name": "TypeScript", "bytes": "1428736" } ], "symlink_target": "" }
#ifndef DEV_H #define DEV_H /****************************************************************************** * EXPORT FUNCTION ******************************************************************************/ extern void sec_dev_dump_part(void); extern void sec_dev_find_parts(void); extern int sec_dev_read_rom_info(void); extern int sec_dev_read_secroimg(void); extern int sec_dev_read_secroimg_v5(unsigned int index); extern unsigned int sec_dev_read_image(char* part_name, char* buf, u64 off, unsigned int sz, unsigned int image_type); #endif // DEV_H
{ "content_hash": "8c165c826eff3c08e6e5cfd7b302351a", "timestamp": "", "source": "github", "line_count": 15, "max_line_length": 118, "avg_line_length": 37.333333333333336, "alnum_prop": 0.5285714285714286, "repo_name": "zhengdejin/X1_Code", "id": "3f953b021aaf73a9cf695a6eb66a41a38291d8ea", "size": "560", "binary": false, "copies": "113", "ref": "refs/heads/master", "path": "kernel-3.10/drivers/misc/mediatek/masp/asf/asf_inc/sec_dev.h", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "ASP", "bytes": "4528" }, { "name": "Assembly", "bytes": "10107915" }, { "name": "Awk", "bytes": "18681" }, { "name": "Batchfile", "bytes": "144" }, { "name": "C", "bytes": "519266172" }, { "name": "C++", "bytes": "11700846" }, { "name": "GDB", "bytes": "18113" }, { "name": "Lex", "bytes": "47705" }, { "name": "M4", "bytes": "3388" }, { "name": "Makefile", "bytes": "1619668" }, { "name": "Objective-C", "bytes": "2963724" }, { "name": "Perl", "bytes": "570279" }, { "name": "Perl 6", "bytes": "3727" }, { "name": "Python", "bytes": "92743" }, { "name": "Roff", "bytes": "55837" }, { "name": "Scilab", "bytes": "21433" }, { "name": "Shell", "bytes": "185922" }, { "name": "SourcePawn", "bytes": "2711" }, { "name": "UnrealScript", "bytes": "6113" }, { "name": "XS", "bytes": "1240" }, { "name": "Yacc", "bytes": "92226" } ], "symlink_target": "" }
import { IExtension } from './extension'; import { ILanguage } from '../language'; export interface IFileExtension extends IExtension { /** @interal */ checked?: boolean; filename?: boolean; // set to true if the extension represents the whole file name. languages?: ILanguage[]; // collection of languages associated to the icon. filenamesGlob?: string[]; // array of file names to generate with file extensions to associate to the icon. extensionsGlob?: string[]; // array of file extensions to generate with file names to associate to the icon. }
{ "content_hash": "2caf6e391b12651e0a5e367287592441", "timestamp": "", "source": "github", "line_count": 11, "max_line_length": 110, "avg_line_length": 51.18181818181818, "alnum_prop": 0.7317939609236235, "repo_name": "robertohuertasm/vscode-icons", "id": "98762e4de632286fe9fc059b3ece1eda433d7613", "size": "563", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/models/extensions/fileExtension.ts", "mode": "33188", "license": "mit", "language": [ { "name": "TypeScript", "bytes": "130579" } ], "symlink_target": "" }
import {mat4} from '../../math'; /** * Tw2Bone * * @property {Tw2GeometryBone} boneRes * @property {mat4} localTransform * @property {mat4} worldTransform * @property {mat4} offsetTransform * @class */ export class Tw2Bone { constructor() { this.boneRes = null; this.localTransform = mat4.create(); this.worldTransform = mat4.create(); this.offsetTransform = mat4.create(); } }
{ "content_hash": "184c9ba48a5663770bc02e47f0679650", "timestamp": "", "source": "github", "line_count": 21, "max_line_length": 45, "avg_line_length": 20.476190476190474, "alnum_prop": 0.6232558139534884, "repo_name": "ccpgames/ccpwgl", "id": "4a99cd24072106b8e2ef233af3687d85a265be07", "size": "430", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/core/model/Tw2Bone.js", "mode": "33188", "license": "mit", "language": [ { "name": "JavaScript", "bytes": "858386" } ], "symlink_target": "" }
/** */ package CIM15.IEC61970.Informative.InfGMLSupport; import org.eclipse.emf.common.notify.NotificationChain; import org.eclipse.emf.ecore.EClass; import org.eclipse.emf.ecore.InternalEObject; /** * <!-- begin-user-doc --> * A representation of the model object '<em><b>Gml Point Symbol</b></em>'. * <!-- end-user-doc --> * * <p> * The following features are supported: * <ul> * <li>{@link CIM15.IEC61970.Informative.InfGMLSupport.GmlPointSymbol#getGmlGraphic <em>Gml Graphic</em>}</li> * <li>{@link CIM15.IEC61970.Informative.InfGMLSupport.GmlPointSymbol#getGmlDiagramObject <em>Gml Diagram Object</em>}</li> * </ul> * </p> * * @generated */ public class GmlPointSymbol extends GmlSymbol { /** * The cached value of the '{@link #getGmlGraphic() <em>Gml Graphic</em>}' reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @see #getGmlGraphic() * @generated * @ordered */ protected GmlGraphic gmlGraphic; /** * The cached value of the '{@link #getGmlDiagramObject() <em>Gml Diagram Object</em>}' reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @see #getGmlDiagramObject() * @generated * @ordered */ protected GmlDiagramObject gmlDiagramObject; /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ protected GmlPointSymbol() { super(); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override protected EClass eStaticClass() { return InfGMLSupportPackage.Literals.GML_POINT_SYMBOL; } /** * Returns the value of the '<em><b>Gml Graphic</b></em>' reference. * It is bidirectional and its opposite is '{@link CIM15.IEC61970.Informative.InfGMLSupport.GmlGraphic#getGmlPointSymbols <em>Gml Point Symbols</em>}'. * <!-- begin-user-doc --> * <p> * If the meaning of the '<em>Gml Graphic</em>' reference isn't clear, * there really should be more of a description here... * </p> * <!-- end-user-doc --> * @return the value of the '<em>Gml Graphic</em>' reference. * @see #setGmlGraphic(GmlGraphic) * @see CIM15.IEC61970.Informative.InfGMLSupport.GmlGraphic#getGmlPointSymbols * @generated */ public GmlGraphic getGmlGraphic() { if (gmlGraphic != null && gmlGraphic.eIsProxy()) { InternalEObject oldGmlGraphic = (InternalEObject)gmlGraphic; gmlGraphic = (GmlGraphic)eResolveProxy(oldGmlGraphic); if (gmlGraphic != oldGmlGraphic) { } } return gmlGraphic; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public GmlGraphic basicGetGmlGraphic() { return gmlGraphic; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public NotificationChain basicSetGmlGraphic(GmlGraphic newGmlGraphic, NotificationChain msgs) { GmlGraphic oldGmlGraphic = gmlGraphic; gmlGraphic = newGmlGraphic; return msgs; } /** * Sets the value of the '{@link CIM15.IEC61970.Informative.InfGMLSupport.GmlPointSymbol#getGmlGraphic <em>Gml Graphic</em>}' reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @param value the new value of the '<em>Gml Graphic</em>' reference. * @see #getGmlGraphic() * @generated */ public void setGmlGraphic(GmlGraphic newGmlGraphic) { if (newGmlGraphic != gmlGraphic) { NotificationChain msgs = null; if (gmlGraphic != null) msgs = ((InternalEObject)gmlGraphic).eInverseRemove(this, InfGMLSupportPackage.GML_GRAPHIC__GML_POINT_SYMBOLS, GmlGraphic.class, msgs); if (newGmlGraphic != null) msgs = ((InternalEObject)newGmlGraphic).eInverseAdd(this, InfGMLSupportPackage.GML_GRAPHIC__GML_POINT_SYMBOLS, GmlGraphic.class, msgs); msgs = basicSetGmlGraphic(newGmlGraphic, msgs); if (msgs != null) msgs.dispatch(); } } /** * Returns the value of the '<em><b>Gml Diagram Object</b></em>' reference. * It is bidirectional and its opposite is '{@link CIM15.IEC61970.Informative.InfGMLSupport.GmlDiagramObject#getGmlPointSymbols <em>Gml Point Symbols</em>}'. * <!-- begin-user-doc --> * <p> * If the meaning of the '<em>Gml Diagram Object</em>' reference isn't clear, * there really should be more of a description here... * </p> * <!-- end-user-doc --> * @return the value of the '<em>Gml Diagram Object</em>' reference. * @see #setGmlDiagramObject(GmlDiagramObject) * @see CIM15.IEC61970.Informative.InfGMLSupport.GmlDiagramObject#getGmlPointSymbols * @generated */ public GmlDiagramObject getGmlDiagramObject() { if (gmlDiagramObject != null && gmlDiagramObject.eIsProxy()) { InternalEObject oldGmlDiagramObject = (InternalEObject)gmlDiagramObject; gmlDiagramObject = (GmlDiagramObject)eResolveProxy(oldGmlDiagramObject); if (gmlDiagramObject != oldGmlDiagramObject) { } } return gmlDiagramObject; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public GmlDiagramObject basicGetGmlDiagramObject() { return gmlDiagramObject; } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ public NotificationChain basicSetGmlDiagramObject(GmlDiagramObject newGmlDiagramObject, NotificationChain msgs) { GmlDiagramObject oldGmlDiagramObject = gmlDiagramObject; gmlDiagramObject = newGmlDiagramObject; return msgs; } /** * Sets the value of the '{@link CIM15.IEC61970.Informative.InfGMLSupport.GmlPointSymbol#getGmlDiagramObject <em>Gml Diagram Object</em>}' reference. * <!-- begin-user-doc --> * <!-- end-user-doc --> * @param value the new value of the '<em>Gml Diagram Object</em>' reference. * @see #getGmlDiagramObject() * @generated */ public void setGmlDiagramObject(GmlDiagramObject newGmlDiagramObject) { if (newGmlDiagramObject != gmlDiagramObject) { NotificationChain msgs = null; if (gmlDiagramObject != null) msgs = ((InternalEObject)gmlDiagramObject).eInverseRemove(this, InfGMLSupportPackage.GML_DIAGRAM_OBJECT__GML_POINT_SYMBOLS, GmlDiagramObject.class, msgs); if (newGmlDiagramObject != null) msgs = ((InternalEObject)newGmlDiagramObject).eInverseAdd(this, InfGMLSupportPackage.GML_DIAGRAM_OBJECT__GML_POINT_SYMBOLS, GmlDiagramObject.class, msgs); msgs = basicSetGmlDiagramObject(newGmlDiagramObject, msgs); if (msgs != null) msgs.dispatch(); } } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_GRAPHIC: if (gmlGraphic != null) msgs = ((InternalEObject)gmlGraphic).eInverseRemove(this, InfGMLSupportPackage.GML_GRAPHIC__GML_POINT_SYMBOLS, GmlGraphic.class, msgs); return basicSetGmlGraphic((GmlGraphic)otherEnd, msgs); case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_DIAGRAM_OBJECT: if (gmlDiagramObject != null) msgs = ((InternalEObject)gmlDiagramObject).eInverseRemove(this, InfGMLSupportPackage.GML_DIAGRAM_OBJECT__GML_POINT_SYMBOLS, GmlDiagramObject.class, msgs); return basicSetGmlDiagramObject((GmlDiagramObject)otherEnd, msgs); } return super.eInverseAdd(otherEnd, featureID, msgs); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { switch (featureID) { case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_GRAPHIC: return basicSetGmlGraphic(null, msgs); case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_DIAGRAM_OBJECT: return basicSetGmlDiagramObject(null, msgs); } return super.eInverseRemove(otherEnd, featureID, msgs); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_GRAPHIC: if (resolve) return getGmlGraphic(); return basicGetGmlGraphic(); case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_DIAGRAM_OBJECT: if (resolve) return getGmlDiagramObject(); return basicGetGmlDiagramObject(); } return super.eGet(featureID, resolve, coreType); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public void eSet(int featureID, Object newValue) { switch (featureID) { case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_GRAPHIC: setGmlGraphic((GmlGraphic)newValue); return; case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_DIAGRAM_OBJECT: setGmlDiagramObject((GmlDiagramObject)newValue); return; } super.eSet(featureID, newValue); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public void eUnset(int featureID) { switch (featureID) { case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_GRAPHIC: setGmlGraphic((GmlGraphic)null); return; case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_DIAGRAM_OBJECT: setGmlDiagramObject((GmlDiagramObject)null); return; } super.eUnset(featureID); } /** * <!-- begin-user-doc --> * <!-- end-user-doc --> * @generated */ @Override public boolean eIsSet(int featureID) { switch (featureID) { case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_GRAPHIC: return gmlGraphic != null; case InfGMLSupportPackage.GML_POINT_SYMBOL__GML_DIAGRAM_OBJECT: return gmlDiagramObject != null; } return super.eIsSet(featureID); } } // GmlPointSymbol
{ "content_hash": "418628b2321149adb0f8ebe6d87cc12f", "timestamp": "", "source": "github", "line_count": 299, "max_line_length": 159, "avg_line_length": 31.62876254180602, "alnum_prop": 0.6949349688061753, "repo_name": "SES-fortiss/SmartGridCoSimulation", "id": "2e24647db87106d900822d4e6af460e4a6a85e56", "size": "9457", "binary": false, "copies": "1", "ref": "refs/heads/development", "path": "core/cim15/src/CIM15/IEC61970/Informative/InfGMLSupport/GmlPointSymbol.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Batchfile", "bytes": "494" }, { "name": "C++", "bytes": "68972" }, { "name": "CSS", "bytes": "10495" }, { "name": "HTML", "bytes": "27854" }, { "name": "Java", "bytes": "23777284" }, { "name": "JavaScript", "bytes": "144441" }, { "name": "Processing", "bytes": "16761" }, { "name": "Shell", "bytes": "1069" }, { "name": "Solidity", "bytes": "18269" } ], "symlink_target": "" }
import Static from 'koa-static'; import Send from 'koa-send'; import Koa from 'koa'; import path from 'path'; import session from 'koa-session' import bodyParser from 'koa-bodyparser' const app = new Koa(); // import middleware from 'koa-webpack'; // x-response-time app.use(bodyParser()) app.use(async function (ctx, next) { const start = new Date(); await next(); const ms = new Date() - start; ctx.set('X-Response-Time', `${ms}ms`); }); // logger app.use(async function (ctx, next) { const start = new Date(); await next(); const ms = new Date() - start; console.log(`${ctx.method} ${ctx.url} - ${ms}`); }); // var webpack = require('webpack'); // var WebpackDevServer = require('webpack-dev-server'); // var config = require('./webpack.config'); // new WebpackDevServer(webpack(config), { // publicPath: config.output.publicPath, // // hot: true, // // historyApiFallback: true // }).listen(3000, 'localhost', function (err, result) { // if (err) { // console.log(err); // } // console.log('Listening at localhost:3000'); // }); import Webpack from 'webpack'; import config from './webpack.config.js'; import middleware from 'koa-webpack'; const compiler = Webpack(config); app.use(middleware({ compiler: compiler })) app.keys = ['davinci'] app.use( session( { key: 'koa:sess', maxAge: 86400000, overwrite: true, httpOnly: true, signed: true, rolling: false, }, app ) ) //Api router-------- import Router from './router/router'; app.use(Router.routes()); app.use(Static(path.join(__dirname, 'static'))); // app.use(Static(path.join(__dirname, 'static'))); // app.use(async (ctx) => { // await Send(ctx, '/static/index.html'); // }) app.use(async (ctx) => { await Send(ctx, '/static/Admin.html'); }) // app.use(async (ctx) => { // await Send(ctx, '/static/index.html'); // }) app.listen(3001);
{ "content_hash": "e7070a697b7583cc2fc169d30967f4fd", "timestamp": "", "source": "github", "line_count": 83, "max_line_length": 56, "avg_line_length": 23.240963855421686, "alnum_prop": 0.6158631415241057, "repo_name": "wangmengling/MaoMobxBlog", "id": "19cd033f00af0d1edb4d2341d376b8a759ed2622", "size": "1929", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "server.js", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "35238" }, { "name": "HTML", "bytes": "7253" }, { "name": "JavaScript", "bytes": "93743" } ], "symlink_target": "" }
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <!-- NewPage --> <html lang="en"> <head> <!-- Generated by javadoc (version 1.7.0_80) on Tue Feb 19 00:14:01 CET 2019 --> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"> <title>Uses of Class org.slf4j.MDC.MDCCloseable (SLF4J 1.7.26 API)</title> <meta name="date" content="2019-02-19"> <link rel="stylesheet" type="text/css" href="../../../stylesheet.css" title="Style"> </head> <body> <script type="text/javascript"><!-- if (location.href.indexOf('is-external=true') == -1) { parent.document.title="Uses of Class org.slf4j.MDC.MDCCloseable (SLF4J 1.7.26 API)"; } //--> </script> <noscript> <div>JavaScript is disabled on your browser.</div> </noscript> <!-- ========= START OF TOP NAVBAR ======= --> <div class="topNav"><a name="navbar_top"> <!-- --> </a><a href="#skip-navbar_top" title="Skip navigation links"></a><a name="navbar_top_firstrow"> <!-- --> </a> <ul class="navList" title="Navigation"> <li><a href="../../../overview-summary.html">Overview</a></li> <li><a href="../package-summary.html">Package</a></li> <li><a href="../../../org/slf4j/MDC.MDCCloseable.html" title="class in org.slf4j">Class</a></li> <li class="navBarCell1Rev">Use</li> <li><a href="../package-tree.html">Tree</a></li> <li><a href="../../../deprecated-list.html">Deprecated</a></li> <li><a href="../../../index-all.html">Index</a></li> <li><a href="../../../help-doc.html">Help</a></li> </ul> </div> <div class="subNav"> <ul class="navList"> <li>Prev</li> <li>Next</li> </ul> <ul class="navList"> <li><a href="../../../index.html?org/slf4j/class-use/MDC.MDCCloseable.html" target="_top">Frames</a></li> <li><a href="MDC.MDCCloseable.html" target="_top">No Frames</a></li> </ul> <ul class="navList" id="allclasses_navbar_top"> <li><a href="../../../allclasses-noframe.html">All Classes</a></li> </ul> <div> <script type="text/javascript"><!-- allClassesLink = document.getElementById("allclasses_navbar_top"); if(window==top) { allClassesLink.style.display = "block"; } else { allClassesLink.style.display = "none"; } //--> </script> </div> <a name="skip-navbar_top"> <!-- --> </a></div> <!-- ========= END OF TOP NAVBAR ========= --> <div class="header"> <h2 title="Uses of Class org.slf4j.MDC.MDCCloseable" class="title">Uses of Class<br>org.slf4j.MDC.MDCCloseable</h2> </div> <div class="classUseContainer"> <ul class="blockList"> <li class="blockList"> <table border="0" cellpadding="3" cellspacing="0" summary="Use table, listing packages, and an explanation"> <caption><span>Packages that use <a href="../../../org/slf4j/MDC.MDCCloseable.html" title="class in org.slf4j">MDC.MDCCloseable</a></span><span class="tabEnd">&nbsp;</span></caption> <tr> <th class="colFirst" scope="col">Package</th> <th class="colLast" scope="col">Description</th> </tr> <tbody> <tr class="altColor"> <td class="colFirst"><a href="#org.slf4j">org.slf4j</a></td> <td class="colLast"> <div class="block">Core logging interfaces.</div> </td> </tr> </tbody> </table> </li> <li class="blockList"> <ul class="blockList"> <li class="blockList"><a name="org.slf4j"> <!-- --> </a> <h3>Uses of <a href="../../../org/slf4j/MDC.MDCCloseable.html" title="class in org.slf4j">MDC.MDCCloseable</a> in <a href="../../../org/slf4j/package-summary.html">org.slf4j</a></h3> <table border="0" cellpadding="3" cellspacing="0" summary="Use table, listing methods, and an explanation"> <caption><span>Methods in <a href="../../../org/slf4j/package-summary.html">org.slf4j</a> that return <a href="../../../org/slf4j/MDC.MDCCloseable.html" title="class in org.slf4j">MDC.MDCCloseable</a></span><span class="tabEnd">&nbsp;</span></caption> <tr> <th class="colFirst" scope="col">Modifier and Type</th> <th class="colLast" scope="col">Method and Description</th> </tr> <tbody> <tr class="altColor"> <td class="colFirst"><code>static <a href="../../../org/slf4j/MDC.MDCCloseable.html" title="class in org.slf4j">MDC.MDCCloseable</a></code></td> <td class="colLast"><span class="strong">MDC.</span><code><strong><a href="../../../org/slf4j/MDC.html#putCloseable(java.lang.String,%20java.lang.String)">putCloseable</a></strong>(<a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;key, <a href="http://docs.oracle.com/javase/1.5.0/docs/api/java/lang/String.html?is-external=true" title="class or interface in java.lang">String</a>&nbsp;val)</code> <div class="block">Put a diagnostic context value (the <code>val</code> parameter) as identified with the <code>key</code> parameter into the current thread's diagnostic context map.</div> </td> </tr> </tbody> </table> </li> </ul> </li> </ul> </div> <!-- ======= START OF BOTTOM NAVBAR ====== --> <div class="bottomNav"><a name="navbar_bottom"> <!-- --> </a><a href="#skip-navbar_bottom" title="Skip navigation links"></a><a name="navbar_bottom_firstrow"> <!-- --> </a> <ul class="navList" title="Navigation"> <li><a href="../../../overview-summary.html">Overview</a></li> <li><a href="../package-summary.html">Package</a></li> <li><a href="../../../org/slf4j/MDC.MDCCloseable.html" title="class in org.slf4j">Class</a></li> <li class="navBarCell1Rev">Use</li> <li><a href="../package-tree.html">Tree</a></li> <li><a href="../../../deprecated-list.html">Deprecated</a></li> <li><a href="../../../index-all.html">Index</a></li> <li><a href="../../../help-doc.html">Help</a></li> </ul> </div> <div class="subNav"> <ul class="navList"> <li>Prev</li> <li>Next</li> </ul> <ul class="navList"> <li><a href="../../../index.html?org/slf4j/class-use/MDC.MDCCloseable.html" target="_top">Frames</a></li> <li><a href="MDC.MDCCloseable.html" target="_top">No Frames</a></li> </ul> <ul class="navList" id="allclasses_navbar_bottom"> <li><a href="../../../allclasses-noframe.html">All Classes</a></li> </ul> <div> <script type="text/javascript"><!-- allClassesLink = document.getElementById("allclasses_navbar_bottom"); if(window==top) { allClassesLink.style.display = "block"; } else { allClassesLink.style.display = "none"; } //--> </script> </div> <a name="skip-navbar_bottom"> <!-- --> </a></div> <!-- ======== END OF BOTTOM NAVBAR ======= --> <p class="legalCopy"><small>Copyright &#169; 2005&#x2013;2019 <a href="http://www.qos.ch">QOS.ch</a>. All rights reserved.</small></p> </body> </html>
{ "content_hash": "21030a5ebf1e19cda55d22c8c8a29311", "timestamp": "", "source": "github", "line_count": 163, "max_line_length": 335, "avg_line_length": 40.76687116564417, "alnum_prop": 0.6260346124905944, "repo_name": "JPAT-ROSEMARY/SCUBA", "id": "ecb84ca366a6ce93123cc5efff79542a748300ce", "size": "6645", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "org.jpat.scuba.external.slf4j/slf4j-1.7.26/site/apidocs/org/slf4j/class-use/MDC.MDCCloseable.html", "mode": "33188", "license": "mit", "language": [ { "name": "Batchfile", "bytes": "479" }, { "name": "CSS", "bytes": "184347" }, { "name": "Groovy", "bytes": "61577" }, { "name": "HTML", "bytes": "72563310" }, { "name": "Java", "bytes": "4674644" }, { "name": "JavaScript", "bytes": "155840" }, { "name": "PLSQL", "bytes": "4133" }, { "name": "PLpgSQL", "bytes": "4948" }, { "name": "Roff", "bytes": "505" }, { "name": "Scala", "bytes": "39880" }, { "name": "Shell", "bytes": "5051" }, { "name": "XSLT", "bytes": "16226" } ], "symlink_target": "" }
ACCEPTED #### According to International Plant Names Index #### Published in null #### Original name null ### Remarks null
{ "content_hash": "204028a0398b307bbd6eaa416afb1f28", "timestamp": "", "source": "github", "line_count": 13, "max_line_length": 31, "avg_line_length": 9.692307692307692, "alnum_prop": 0.7063492063492064, "repo_name": "mdoering/backbone", "id": "1f10ab6ed7e631dbd3ceb1aa68a0537e355462a7", "size": "179", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "life/Plantae/Magnoliophyta/Magnoliopsida/Vitales/Vitaceae/Tetrastigma/Tetrastigma crassipes/README.md", "mode": "33188", "license": "apache-2.0", "language": [], "symlink_target": "" }
/* * style::line * Styling for a line */ #ifndef SKUI_GRAPHICS_STYLE_LINE_H #define SKUI_GRAPHICS_STYLE_LINE_H #include "graphics/color.h++" #include "graphics/scalar.h++" namespace skui::graphics::style { struct line { scalar thickness = 0; graphics::color color = colors::transparent; }; } #endif
{ "content_hash": "5914bcb4ec7e97ff3141ea25a36b525a", "timestamp": "", "source": "github", "line_count": 24, "max_line_length": 48, "avg_line_length": 13.458333333333334, "alnum_prop": 0.6656346749226006, "repo_name": "skui-org/skui", "id": "63538542146f6c197c4b79a91fac686e06137b65", "size": "1476", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "graphics/style/line.h++", "mode": "33188", "license": "mit", "language": [ { "name": "C++", "bytes": "886658" }, { "name": "CMake", "bytes": "41767" }, { "name": "Shell", "bytes": "522" } ], "symlink_target": "" }
/** * */ package com.rng; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; @SpringBootApplication public class CoreApplication { public static void main(String[] args) { SpringApplication.run(CoreApplication.class, args); } }
{ "content_hash": "e72d03e70b8114bdb5dd596e4315034d", "timestamp": "", "source": "github", "line_count": 19, "max_line_length": 68, "avg_line_length": 16.31578947368421, "alnum_prop": 0.7774193548387097, "repo_name": "mariaantoanelam/Licenta", "id": "0cb3c24341b7176b68a2e37e93faa6ed7f932a4f", "size": "310", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "rng-core/src/test/java/com/rng/CoreApplication.java", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "31035" }, { "name": "HTML", "bytes": "134311" }, { "name": "Java", "bytes": "161404" }, { "name": "JavaScript", "bytes": "11470" }, { "name": "Python", "bytes": "4053763" } ], "symlink_target": "" }
ACCEPTED #### According to International Plant Names Index #### Published in null #### Original name null ### Remarks null
{ "content_hash": "8edb4b722234d225250401a1dbc6eba8", "timestamp": "", "source": "github", "line_count": 13, "max_line_length": 31, "avg_line_length": 9.692307692307692, "alnum_prop": 0.7063492063492064, "repo_name": "mdoering/backbone", "id": "45ccad0024bc1bd9dd9284f32478ea941eb4a232", "size": "177", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "life/Plantae/Magnoliophyta/Magnoliopsida/Lamiales/Scrophulariaceae/Myoporum/Myoporum pubescens/README.md", "mode": "33188", "license": "apache-2.0", "language": [], "symlink_target": "" }
from nose.tools import * import guardonce.once2guard as o2g import guardonce.guard2once as g2o def test_o2g2o(): _input = ''' #pragma once int main() { return 0; } ''' guard = 'MATCH_H' output = g2o.replace_guard(o2g.replace_pragma_once(_input, guard), guard) assert_multi_line_equal(_input, output) def test_g2o2g(): _input = ''' #ifndef MATCH_H #define MATCH_H int main() { return 0; } #endif ''' guard = 'MATCH_H' output = o2g.replace_pragma_once(g2o.replace_guard(_input, guard), guard) assert_multi_line_equal(_input, output)
{ "content_hash": "3697de8b747d2318ee47020138f996d2", "timestamp": "", "source": "github", "line_count": 29, "max_line_length": 77, "avg_line_length": 19.689655172413794, "alnum_prop": 0.658493870402802, "repo_name": "cgmb/guardonce", "id": "49e89b6304ed3d16df137b0e5694f1a330ee52ca", "size": "665", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "tests/test_reversible.py", "mode": "33188", "license": "mit", "language": [ { "name": "C", "bytes": "593" }, { "name": "Python", "bytes": "72724" } ], "symlink_target": "" }
require 'bigdecimal' require 'bigdecimal/util' require 'faraday' require 'uri' require 'redis' require 'json' require 'pp' require 'awesome_print' require 'byebug' class RateSource attr_reader :redis def initialize(redis) @redis = redis end def fetch u = URI.parse(api_url) url = u.scheme + "://" + u.host conn = Faraday.new(url: url) do |faraday| faraday.request :url_encoded faraday.response :logger faraday.adapter Faraday.default_adapter # Net::HTTP end resp = conn.get u.request_uri return post_process(resp.body) end def post_process(data) return data end def load(hash) hash.each do |key, val| redis.set key, val end end def fetch_and_load load fetch end def api_url; end end class PoloniexAPI < RateSource API_URL = 'https://poloniex.com/public?command=returnTicker' def api_url return API_URL end def post_process(data) h = JSON.parse(data) newhash = Hash.new # ignore non-BTC markets h.keep_if { |k,v| k.match(/^BTC_/) } h.each do |k,v| newkey = k # Poloniex lists rates inverted... newval = (1 / BigDecimal.new(v['last'])).round(12).to_s('12F') newhash[newkey] = newval end # Bitcoin in terms of Bitcoin newhash['BTC_BTC'] = '1' return newhash end end class BitcoinAverageAPI < RateSource API_URL = 'https://apiv2.bitcoinaverage.com/constants/exchangerates/global' def api_url return API_URL end def post_process(data) h = JSON.parse(data) newhash = Hash.new # remove precious metals and SDRs %w[ XAG XAU XDR XPD XPT ].each do |tick| h['rates'].delete(tick) end h['rates'].each do |k,v| newkey = "USD_#{k}" newval = v['rate'] newhash[newkey] = newval end return newhash end end
{ "content_hash": "d744bbfb09ae0393847c3d779beb4827", "timestamp": "", "source": "github", "line_count": 100, "max_line_length": 77, "avg_line_length": 18.48, "alnum_prop": 0.6293290043290043, "repo_name": "nmarley/rate-service", "id": "7f7c034aa2826478f8528a54e5642e37f1d53137", "size": "1848", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "lib/rate_source.rb", "mode": "33188", "license": "mit", "language": [ { "name": "Dockerfile", "bytes": "805" }, { "name": "Ruby", "bytes": "14568" }, { "name": "Shell", "bytes": "237" } ], "symlink_target": "" }
import { RGBAFormat, HalfFloatType, FloatType, UnsignedByteType, TriangleFanDrawMode, TriangleStripDrawMode, TrianglesDrawMode, LinearToneMapping, BackSide } from '../constants.js'; import { _Math } from '../math/Math.js'; import { DataTexture } from '../textures/DataTexture.js'; import { Frustum } from '../math/Frustum.js'; import { Matrix4 } from '../math/Matrix4.js'; import { ShaderLib } from './shaders/ShaderLib.js'; import { UniformsLib } from './shaders/UniformsLib.js'; import { cloneUniforms } from './shaders/UniformsUtils.js'; import { Vector2 } from '../math/Vector2.js'; import { Vector3 } from '../math/Vector3.js'; import { Vector4 } from '../math/Vector4.js'; import { WebGLAnimation } from './webgl/WebGLAnimation.js'; import { WebGLAttributes } from './webgl/WebGLAttributes.js'; import { WebGLBackground } from './webgl/WebGLBackground.js'; import { WebGLBufferRenderer } from './webgl/WebGLBufferRenderer.js'; import { WebGLCapabilities } from './webgl/WebGLCapabilities.js'; import { WebGLClipping } from './webgl/WebGLClipping.js'; import { WebGLExtensions } from './webgl/WebGLExtensions.js'; import { WebGLGeometries } from './webgl/WebGLGeometries.js'; import { WebGLIndexedBufferRenderer } from './webgl/WebGLIndexedBufferRenderer.js'; import { WebGLInfo } from './webgl/WebGLInfo.js'; import { WebGLMorphtargets } from './webgl/WebGLMorphtargets.js'; import { WebGLObjects } from './webgl/WebGLObjects.js'; import { WebGLPrograms } from './webgl/WebGLPrograms.js'; import { WebGLProperties } from './webgl/WebGLProperties.js'; import { WebGLRenderLists } from './webgl/WebGLRenderLists.js'; import { WebGLRenderStates } from './webgl/WebGLRenderStates.js'; import { WebGLShadowMap } from './webgl/WebGLShadowMap.js'; import { WebGLState } from './webgl/WebGLState.js'; import { WebGLTextures } from './webgl/WebGLTextures.js'; import { WebGLUniforms } from './webgl/WebGLUniforms.js'; import { WebGLUtils } from './webgl/WebGLUtils.js'; import { WebVRManager } from './webvr/WebVRManager.js'; import { WebXRManager } from './webvr/WebXRManager.js'; /** * @author supereggbert / http://www.paulbrunt.co.uk/ * @author mrdoob / http://mrdoob.com/ * @author alteredq / http://alteredqualia.com/ * @author szimek / https://github.com/szimek/ * @author tschw */ function WebGLRenderer( parameters ) { parameters = parameters || {}; var _canvas = parameters.canvas !== undefined ? parameters.canvas : document.createElementNS( 'http://www.w3.org/1999/xhtml', 'canvas' ), _context = parameters.context !== undefined ? parameters.context : null, _alpha = parameters.alpha !== undefined ? parameters.alpha : false, _depth = parameters.depth !== undefined ? parameters.depth : true, _stencil = parameters.stencil !== undefined ? parameters.stencil : true, _antialias = parameters.antialias !== undefined ? parameters.antialias : false, _premultipliedAlpha = parameters.premultipliedAlpha !== undefined ? parameters.premultipliedAlpha : true, _preserveDrawingBuffer = parameters.preserveDrawingBuffer !== undefined ? parameters.preserveDrawingBuffer : false, _powerPreference = parameters.powerPreference !== undefined ? parameters.powerPreference : 'default', _failIfMajorPerformanceCaveat = parameters.failIfMajorPerformanceCaveat !== undefined ? parameters.failIfMajorPerformanceCaveat : false; var currentRenderList = null; var currentRenderState = null; // public properties this.domElement = _canvas; // Debug configuration container this.debug = { /** * Enables error checking and reporting when shader programs are being compiled * @type {boolean} */ checkShaderErrors: true }; // clearing this.autoClear = true; this.autoClearColor = true; this.autoClearDepth = true; this.autoClearStencil = true; // scene graph this.sortObjects = true; // user-defined clipping this.clippingPlanes = []; this.localClippingEnabled = false; // physically based shading this.gammaFactor = 2.0; // for backwards compatibility this.gammaInput = false; this.gammaOutput = false; // physical lights this.physicallyCorrectLights = false; // tone mapping this.toneMapping = LinearToneMapping; this.toneMappingExposure = 1.0; this.toneMappingWhitePoint = 1.0; // morphs this.maxMorphTargets = 8; this.maxMorphNormals = 4; // internal properties var _this = this, _isContextLost = false, // internal state cache _framebuffer = null, _currentActiveCubeFace = 0, _currentActiveMipmapLevel = 0, _currentRenderTarget = null, _currentFramebuffer = null, _currentMaterialId = - 1, // geometry and program caching _currentGeometryProgram = { geometry: null, program: null, wireframe: false }, _currentCamera = null, _currentArrayCamera = null, _currentViewport = new Vector4(), _currentScissor = new Vector4(), _currentScissorTest = null, // _width = _canvas.width, _height = _canvas.height, _pixelRatio = 1, _viewport = new Vector4( 0, 0, _width, _height ), _scissor = new Vector4( 0, 0, _width, _height ), _scissorTest = false, // frustum _frustum = new Frustum(), // clipping _clipping = new WebGLClipping(), _clippingEnabled = false, _localClippingEnabled = false, // camera matrices cache _projScreenMatrix = new Matrix4(), _vector3 = new Vector3(); function getTargetPixelRatio() { return _currentRenderTarget === null ? _pixelRatio : 1; } // initialize var _gl; try { var contextAttributes = { alpha: _alpha, depth: _depth, stencil: _stencil, antialias: _antialias, premultipliedAlpha: _premultipliedAlpha, preserveDrawingBuffer: _preserveDrawingBuffer, powerPreference: _powerPreference, failIfMajorPerformanceCaveat: _failIfMajorPerformanceCaveat, xrCompatible: true }; // event listeners must be registered before WebGL context is created, see #12753 _canvas.addEventListener( 'webglcontextlost', onContextLost, false ); _canvas.addEventListener( 'webglcontextrestored', onContextRestore, false ); _gl = _context || _canvas.getContext( 'webgl', contextAttributes ) || _canvas.getContext( 'experimental-webgl', contextAttributes ); if ( _gl === null ) { if ( _canvas.getContext( 'webgl' ) !== null ) { throw new Error( 'Error creating WebGL context with your selected attributes.' ); } else { throw new Error( 'Error creating WebGL context.' ); } } // Some experimental-webgl implementations do not have getShaderPrecisionFormat if ( _gl.getShaderPrecisionFormat === undefined ) { _gl.getShaderPrecisionFormat = function () { return { 'rangeMin': 1, 'rangeMax': 1, 'precision': 1 }; }; } } catch ( error ) { console.error( 'THREE.WebGLRenderer: ' + error.message ); throw error; } var extensions, capabilities, state, info; var properties, textures, attributes, geometries, objects; var programCache, renderLists, renderStates; var background, morphtargets, bufferRenderer, indexedBufferRenderer; var utils; function initGLContext() { extensions = new WebGLExtensions( _gl ); capabilities = new WebGLCapabilities( _gl, extensions, parameters ); if ( ! capabilities.isWebGL2 ) { extensions.get( 'WEBGL_depth_texture' ); extensions.get( 'OES_texture_float' ); extensions.get( 'OES_texture_half_float' ); extensions.get( 'OES_texture_half_float_linear' ); extensions.get( 'OES_standard_derivatives' ); extensions.get( 'OES_element_index_uint' ); extensions.get( 'ANGLE_instanced_arrays' ); } extensions.get( 'OES_texture_float_linear' ); utils = new WebGLUtils( _gl, extensions, capabilities ); state = new WebGLState( _gl, extensions, utils, capabilities ); state.scissor( _currentScissor.copy( _scissor ).multiplyScalar( _pixelRatio ).floor() ); state.viewport( _currentViewport.copy( _viewport ).multiplyScalar( _pixelRatio ).floor() ); info = new WebGLInfo( _gl ); properties = new WebGLProperties(); textures = new WebGLTextures( _gl, extensions, state, properties, capabilities, utils, info ); attributes = new WebGLAttributes( _gl ); geometries = new WebGLGeometries( _gl, attributes, info ); objects = new WebGLObjects( geometries, info ); morphtargets = new WebGLMorphtargets( _gl ); programCache = new WebGLPrograms( _this, extensions, capabilities ); renderLists = new WebGLRenderLists(); renderStates = new WebGLRenderStates(); background = new WebGLBackground( _this, state, objects, _premultipliedAlpha ); bufferRenderer = new WebGLBufferRenderer( _gl, extensions, info, capabilities ); indexedBufferRenderer = new WebGLIndexedBufferRenderer( _gl, extensions, info, capabilities ); info.programs = programCache.programs; _this.capabilities = capabilities; _this.extensions = extensions; _this.properties = properties; _this.renderLists = renderLists; _this.state = state; _this.info = info; } initGLContext(); // vr var vr = ( typeof navigator !== 'undefined' && 'xr' in navigator && 'supportsSession' in navigator.xr ) ? new WebXRManager( _this, _gl ) : new WebVRManager( _this ); this.vr = vr; // shadow map var shadowMap = new WebGLShadowMap( _this, objects, capabilities.maxTextureSize ); this.shadowMap = shadowMap; // API this.getContext = function () { return _gl; }; this.getContextAttributes = function () { return _gl.getContextAttributes(); }; this.forceContextLoss = function () { var extension = extensions.get( 'WEBGL_lose_context' ); if ( extension ) extension.loseContext(); }; this.forceContextRestore = function () { var extension = extensions.get( 'WEBGL_lose_context' ); if ( extension ) extension.restoreContext(); }; this.getPixelRatio = function () { return _pixelRatio; }; this.setPixelRatio = function ( value ) { if ( value === undefined ) return; _pixelRatio = value; this.setSize( _width, _height, false ); }; this.getSize = function ( target ) { if ( target === undefined ) { console.warn( 'WebGLRenderer: .getsize() now requires a Vector2 as an argument' ); target = new Vector2(); } return target.set( _width, _height ); }; this.setSize = function ( width, height, updateStyle ) { if ( vr.isPresenting() ) { console.warn( 'THREE.WebGLRenderer: Can\'t change size while VR device is presenting.' ); return; } _width = width; _height = height; _canvas.width = Math.floor( width * _pixelRatio ); _canvas.height = Math.floor( height * _pixelRatio ); if ( updateStyle !== false ) { _canvas.style.width = width + 'px'; _canvas.style.height = height + 'px'; } this.setViewport( 0, 0, width, height ); }; this.getDrawingBufferSize = function ( target ) { if ( target === undefined ) { console.warn( 'WebGLRenderer: .getdrawingBufferSize() now requires a Vector2 as an argument' ); target = new Vector2(); } return target.set( _width * _pixelRatio, _height * _pixelRatio ).floor(); }; this.setDrawingBufferSize = function ( width, height, pixelRatio ) { _width = width; _height = height; _pixelRatio = pixelRatio; _canvas.width = Math.floor( width * pixelRatio ); _canvas.height = Math.floor( height * pixelRatio ); this.setViewport( 0, 0, width, height ); }; this.getCurrentViewport = function ( target ) { if ( target === undefined ) { console.warn( 'WebGLRenderer: .getCurrentViewport() now requires a Vector4 as an argument' ); target = new Vector4(); } return target.copy( _currentViewport ); }; this.getViewport = function ( target ) { return target.copy( _viewport ); }; this.setViewport = function ( x, y, width, height ) { if ( x.isVector4 ) { _viewport.set( x.x, x.y, x.z, x.w ); } else { _viewport.set( x, y, width, height ); } state.viewport( _currentViewport.copy( _viewport ).multiplyScalar( _pixelRatio ).floor() ); }; this.getScissor = function ( target ) { return target.copy( _scissor ); }; this.setScissor = function ( x, y, width, height ) { if ( x.isVector4 ) { _scissor.set( x.x, x.y, x.z, x.w ); } else { _scissor.set( x, y, width, height ); } state.scissor( _currentScissor.copy( _scissor ).multiplyScalar( _pixelRatio ).floor() ); }; this.getScissorTest = function () { return _scissorTest; }; this.setScissorTest = function ( boolean ) { state.setScissorTest( _scissorTest = boolean ); }; // Clearing this.getClearColor = function () { return background.getClearColor(); }; this.setClearColor = function () { background.setClearColor.apply( background, arguments ); }; this.getClearAlpha = function () { return background.getClearAlpha(); }; this.setClearAlpha = function () { background.setClearAlpha.apply( background, arguments ); }; this.clear = function ( color, depth, stencil ) { var bits = 0; if ( color === undefined || color ) bits |= _gl.COLOR_BUFFER_BIT; if ( depth === undefined || depth ) bits |= _gl.DEPTH_BUFFER_BIT; if ( stencil === undefined || stencil ) bits |= _gl.STENCIL_BUFFER_BIT; _gl.clear( bits ); }; this.clearColor = function () { this.clear( true, false, false ); }; this.clearDepth = function () { this.clear( false, true, false ); }; this.clearStencil = function () { this.clear( false, false, true ); }; // this.dispose = function () { _canvas.removeEventListener( 'webglcontextlost', onContextLost, false ); _canvas.removeEventListener( 'webglcontextrestored', onContextRestore, false ); renderLists.dispose(); renderStates.dispose(); properties.dispose(); objects.dispose(); vr.dispose(); animation.stop(); }; // Events function onContextLost( event ) { event.preventDefault(); console.log( 'THREE.WebGLRenderer: Context Lost.' ); _isContextLost = true; } function onContextRestore( /* event */ ) { console.log( 'THREE.WebGLRenderer: Context Restored.' ); _isContextLost = false; initGLContext(); } function onMaterialDispose( event ) { var material = event.target; material.removeEventListener( 'dispose', onMaterialDispose ); deallocateMaterial( material ); } // Buffer deallocation function deallocateMaterial( material ) { releaseMaterialProgramReference( material ); properties.remove( material ); } function releaseMaterialProgramReference( material ) { var programInfo = properties.get( material ).program; material.program = undefined; if ( programInfo !== undefined ) { programCache.releaseProgram( programInfo ); } } // Buffer rendering function renderObjectImmediate( object, program ) { object.render( function ( object ) { _this.renderBufferImmediate( object, program ); } ); } this.renderBufferImmediate = function ( object, program ) { state.initAttributes(); var buffers = properties.get( object ); if ( object.hasPositions && ! buffers.position ) buffers.position = _gl.createBuffer(); if ( object.hasNormals && ! buffers.normal ) buffers.normal = _gl.createBuffer(); if ( object.hasUvs && ! buffers.uv ) buffers.uv = _gl.createBuffer(); if ( object.hasColors && ! buffers.color ) buffers.color = _gl.createBuffer(); var programAttributes = program.getAttributes(); if ( object.hasPositions ) { _gl.bindBuffer( _gl.ARRAY_BUFFER, buffers.position ); _gl.bufferData( _gl.ARRAY_BUFFER, object.positionArray, _gl.DYNAMIC_DRAW ); state.enableAttribute( programAttributes.position ); _gl.vertexAttribPointer( programAttributes.position, 3, _gl.FLOAT, false, 0, 0 ); } if ( object.hasNormals ) { _gl.bindBuffer( _gl.ARRAY_BUFFER, buffers.normal ); _gl.bufferData( _gl.ARRAY_BUFFER, object.normalArray, _gl.DYNAMIC_DRAW ); state.enableAttribute( programAttributes.normal ); _gl.vertexAttribPointer( programAttributes.normal, 3, _gl.FLOAT, false, 0, 0 ); } if ( object.hasUvs ) { _gl.bindBuffer( _gl.ARRAY_BUFFER, buffers.uv ); _gl.bufferData( _gl.ARRAY_BUFFER, object.uvArray, _gl.DYNAMIC_DRAW ); state.enableAttribute( programAttributes.uv ); _gl.vertexAttribPointer( programAttributes.uv, 2, _gl.FLOAT, false, 0, 0 ); } if ( object.hasColors ) { _gl.bindBuffer( _gl.ARRAY_BUFFER, buffers.color ); _gl.bufferData( _gl.ARRAY_BUFFER, object.colorArray, _gl.DYNAMIC_DRAW ); state.enableAttribute( programAttributes.color ); _gl.vertexAttribPointer( programAttributes.color, 3, _gl.FLOAT, false, 0, 0 ); } state.disableUnusedAttributes(); _gl.drawArrays( _gl.TRIANGLES, 0, object.count ); object.count = 0; }; this.renderBufferDirect = function ( camera, fog, geometry, material, object, group ) { var frontFaceCW = ( object.isMesh && object.matrixWorld.determinant() < 0 ); state.setMaterial( material, frontFaceCW ); var program = setProgram( camera, fog, material, object ); var updateBuffers = false; if ( _currentGeometryProgram.geometry !== geometry.id || _currentGeometryProgram.program !== program.id || _currentGeometryProgram.wireframe !== ( material.wireframe === true ) ) { _currentGeometryProgram.geometry = geometry.id; _currentGeometryProgram.program = program.id; _currentGeometryProgram.wireframe = material.wireframe === true; updateBuffers = true; } if ( object.morphTargetInfluences ) { morphtargets.update( object, geometry, material, program ); updateBuffers = true; } // var index = geometry.index; var position = geometry.attributes.position; var rangeFactor = 1; if ( material.wireframe === true ) { index = geometries.getWireframeAttribute( geometry ); rangeFactor = 2; } var attribute; var renderer = bufferRenderer; if ( index !== null ) { attribute = attributes.get( index ); renderer = indexedBufferRenderer; renderer.setIndex( attribute ); } if ( updateBuffers ) { setupVertexAttributes( material, program, geometry ); if ( index !== null ) { _gl.bindBuffer( _gl.ELEMENT_ARRAY_BUFFER, attribute.buffer ); } } // var dataCount = Infinity; if ( index !== null ) { dataCount = index.count; } else if ( position !== undefined ) { dataCount = position.count; } var rangeStart = geometry.drawRange.start * rangeFactor; var rangeCount = geometry.drawRange.count * rangeFactor; var groupStart = group !== null ? group.start * rangeFactor : 0; var groupCount = group !== null ? group.count * rangeFactor : Infinity; var drawStart = Math.max( rangeStart, groupStart ); var drawEnd = Math.min( dataCount, rangeStart + rangeCount, groupStart + groupCount ) - 1; var drawCount = Math.max( 0, drawEnd - drawStart + 1 ); if ( drawCount === 0 ) return; // if ( object.isMesh ) { if ( material.wireframe === true ) { state.setLineWidth( material.wireframeLinewidth * getTargetPixelRatio() ); renderer.setMode( _gl.LINES ); } else { switch ( object.drawMode ) { case TrianglesDrawMode: renderer.setMode( _gl.TRIANGLES ); break; case TriangleStripDrawMode: renderer.setMode( _gl.TRIANGLE_STRIP ); break; case TriangleFanDrawMode: renderer.setMode( _gl.TRIANGLE_FAN ); break; } } } else if ( object.isLine ) { var lineWidth = material.linewidth; if ( lineWidth === undefined ) lineWidth = 1; // Not using Line*Material state.setLineWidth( lineWidth * getTargetPixelRatio() ); if ( object.isLineSegments ) { renderer.setMode( _gl.LINES ); } else if ( object.isLineLoop ) { renderer.setMode( _gl.LINE_LOOP ); } else { renderer.setMode( _gl.LINE_STRIP ); } } else if ( object.isPoints ) { renderer.setMode( _gl.POINTS ); } else if ( object.isSprite ) { renderer.setMode( _gl.TRIANGLES ); } if ( geometry && geometry.isInstancedBufferGeometry ) { if ( geometry.maxInstancedCount > 0 ) { renderer.renderInstances( geometry, drawStart, drawCount ); } } else { renderer.render( drawStart, drawCount ); } }; function setupVertexAttributes( material, program, geometry ) { if ( geometry && geometry.isInstancedBufferGeometry && ! capabilities.isWebGL2 ) { if ( extensions.get( 'ANGLE_instanced_arrays' ) === null ) { console.error( 'THREE.WebGLRenderer.setupVertexAttributes: using THREE.InstancedBufferGeometry but hardware does not support extension ANGLE_instanced_arrays.' ); return; } } state.initAttributes(); var geometryAttributes = geometry.attributes; var programAttributes = program.getAttributes(); var materialDefaultAttributeValues = material.defaultAttributeValues; for ( var name in programAttributes ) { var programAttribute = programAttributes[ name ]; if ( programAttribute >= 0 ) { var geometryAttribute = geometryAttributes[ name ]; if ( geometryAttribute !== undefined ) { var normalized = geometryAttribute.normalized; var size = geometryAttribute.itemSize; var attribute = attributes.get( geometryAttribute ); // TODO Attribute may not be available on context restore if ( attribute === undefined ) continue; var buffer = attribute.buffer; var type = attribute.type; var bytesPerElement = attribute.bytesPerElement; if ( geometryAttribute.isInterleavedBufferAttribute ) { var data = geometryAttribute.data; var stride = data.stride; var offset = geometryAttribute.offset; if ( data && data.isInstancedInterleavedBuffer ) { state.enableAttributeAndDivisor( programAttribute, data.meshPerAttribute ); if ( geometry.maxInstancedCount === undefined ) { geometry.maxInstancedCount = data.meshPerAttribute * data.count; } } else { state.enableAttribute( programAttribute ); } _gl.bindBuffer( _gl.ARRAY_BUFFER, buffer ); _gl.vertexAttribPointer( programAttribute, size, type, normalized, stride * bytesPerElement, offset * bytesPerElement ); } else { if ( geometryAttribute.isInstancedBufferAttribute ) { state.enableAttributeAndDivisor( programAttribute, geometryAttribute.meshPerAttribute ); if ( geometry.maxInstancedCount === undefined ) { geometry.maxInstancedCount = geometryAttribute.meshPerAttribute * geometryAttribute.count; } } else { state.enableAttribute( programAttribute ); } _gl.bindBuffer( _gl.ARRAY_BUFFER, buffer ); _gl.vertexAttribPointer( programAttribute, size, type, normalized, 0, 0 ); } } else if ( materialDefaultAttributeValues !== undefined ) { var value = materialDefaultAttributeValues[ name ]; if ( value !== undefined ) { switch ( value.length ) { case 2: _gl.vertexAttrib2fv( programAttribute, value ); break; case 3: _gl.vertexAttrib3fv( programAttribute, value ); break; case 4: _gl.vertexAttrib4fv( programAttribute, value ); break; default: _gl.vertexAttrib1fv( programAttribute, value ); } } } } } state.disableUnusedAttributes(); } // Compile this.compile = function ( scene, camera ) { currentRenderState = renderStates.get( scene, camera ); currentRenderState.init(); scene.traverse( function ( object ) { if ( object.isLight ) { currentRenderState.pushLight( object ); if ( object.castShadow ) { currentRenderState.pushShadow( object ); } } } ); currentRenderState.setupLights( camera ); scene.traverse( function ( object ) { if ( object.material ) { if ( Array.isArray( object.material ) ) { for ( var i = 0; i < object.material.length; i ++ ) { initMaterial( object.material[ i ], scene.fog, object ); } } else { initMaterial( object.material, scene.fog, object ); } } } ); }; // Animation Loop var onAnimationFrameCallback = null; function onAnimationFrame( time ) { if ( vr.isPresenting() ) return; if ( onAnimationFrameCallback ) onAnimationFrameCallback( time ); } var animation = new WebGLAnimation(); animation.setAnimationLoop( onAnimationFrame ); if ( typeof window !== 'undefined' ) animation.setContext( window ); this.setAnimationLoop = function ( callback ) { onAnimationFrameCallback = callback; vr.setAnimationLoop( callback ); animation.start(); }; // Rendering this.render = function ( scene, camera ) { var renderTarget, forceClear; if ( arguments[ 2 ] !== undefined ) { console.warn( 'THREE.WebGLRenderer.render(): the renderTarget argument has been removed. Use .setRenderTarget() instead.' ); renderTarget = arguments[ 2 ]; } if ( arguments[ 3 ] !== undefined ) { console.warn( 'THREE.WebGLRenderer.render(): the forceClear argument has been removed. Use .clear() instead.' ); forceClear = arguments[ 3 ]; } if ( ! ( camera && camera.isCamera ) ) { console.error( 'THREE.WebGLRenderer.render: camera is not an instance of THREE.Camera.' ); return; } if ( _isContextLost ) return; // reset caching for this frame _currentGeometryProgram.geometry = null; _currentGeometryProgram.program = null; _currentGeometryProgram.wireframe = false; _currentMaterialId = - 1; _currentCamera = null; // update scene graph if ( scene.autoUpdate === true ) scene.updateMatrixWorld(); // update camera matrices and frustum if ( camera.parent === null ) camera.updateMatrixWorld(); if ( vr.enabled ) { camera = vr.getCamera( camera ); } // currentRenderState = renderStates.get( scene, camera ); currentRenderState.init(); scene.onBeforeRender( _this, scene, camera, renderTarget || _currentRenderTarget ); _projScreenMatrix.multiplyMatrices( camera.projectionMatrix, camera.matrixWorldInverse ); _frustum.setFromMatrix( _projScreenMatrix ); _localClippingEnabled = this.localClippingEnabled; _clippingEnabled = _clipping.init( this.clippingPlanes, _localClippingEnabled, camera ); currentRenderList = renderLists.get( scene, camera ); currentRenderList.init(); projectObject( scene, camera, 0, _this.sortObjects ); if ( _this.sortObjects === true ) { currentRenderList.sort(); } // if ( _clippingEnabled ) _clipping.beginShadows(); var shadowsArray = currentRenderState.state.shadowsArray; shadowMap.render( shadowsArray, scene, camera ); currentRenderState.setupLights( camera ); if ( _clippingEnabled ) _clipping.endShadows(); // if ( this.info.autoReset ) this.info.reset(); if ( renderTarget !== undefined ) { this.setRenderTarget( renderTarget ); } // background.render( currentRenderList, scene, camera, forceClear ); // render scene var opaqueObjects = currentRenderList.opaque; var transparentObjects = currentRenderList.transparent; if ( scene.overrideMaterial ) { var overrideMaterial = scene.overrideMaterial; if ( opaqueObjects.length ) renderObjects( opaqueObjects, scene, camera, overrideMaterial ); if ( transparentObjects.length ) renderObjects( transparentObjects, scene, camera, overrideMaterial ); } else { // opaque pass (front-to-back order) if ( opaqueObjects.length ) renderObjects( opaqueObjects, scene, camera ); // transparent pass (back-to-front order) if ( transparentObjects.length ) renderObjects( transparentObjects, scene, camera ); } // scene.onAfterRender( _this, scene, camera ); // if ( _currentRenderTarget !== null ) { // Generate mipmap if we're using any kind of mipmap filtering textures.updateRenderTargetMipmap( _currentRenderTarget ); // resolve multisample renderbuffers to a single-sample texture if necessary textures.updateMultisampleRenderTarget( _currentRenderTarget ); } // Ensure depth buffer writing is enabled so it can be cleared on next render state.buffers.depth.setTest( true ); state.buffers.depth.setMask( true ); state.buffers.color.setMask( true ); state.setPolygonOffset( false ); if ( vr.enabled ) { vr.submitFrame(); } // _gl.finish(); currentRenderList = null; currentRenderState = null; }; function projectObject( object, camera, groupOrder, sortObjects ) { if ( object.visible === false ) return; var visible = object.layers.test( camera.layers ); if ( visible ) { if ( object.isGroup ) { groupOrder = object.renderOrder; } else if ( object.isLOD ) { if ( object.autoUpdate === true ) object.update( camera ); } else if ( object.isLight ) { currentRenderState.pushLight( object ); if ( object.castShadow ) { currentRenderState.pushShadow( object ); } } else if ( object.isSprite ) { if ( ! object.frustumCulled || _frustum.intersectsSprite( object ) ) { if ( sortObjects ) { _vector3.setFromMatrixPosition( object.matrixWorld ) .applyMatrix4( _projScreenMatrix ); } var geometry = objects.update( object ); var material = object.material; if ( material.visible ) { currentRenderList.push( object, geometry, material, groupOrder, _vector3.z, null ); } } } else if ( object.isImmediateRenderObject ) { if ( sortObjects ) { _vector3.setFromMatrixPosition( object.matrixWorld ) .applyMatrix4( _projScreenMatrix ); } currentRenderList.push( object, null, object.material, groupOrder, _vector3.z, null ); } else if ( object.isMesh || object.isLine || object.isPoints ) { if ( object.isSkinnedMesh ) { object.skeleton.update(); } if ( ! object.frustumCulled || _frustum.intersectsObject( object ) ) { if ( sortObjects ) { _vector3.setFromMatrixPosition( object.matrixWorld ) .applyMatrix4( _projScreenMatrix ); } var geometry = objects.update( object ); var material = object.material; if ( Array.isArray( material ) ) { var groups = geometry.groups; for ( var i = 0, l = groups.length; i < l; i ++ ) { var group = groups[ i ]; var groupMaterial = material[ group.materialIndex ]; if ( groupMaterial && groupMaterial.visible ) { currentRenderList.push( object, geometry, groupMaterial, groupOrder, _vector3.z, group ); } } } else if ( material.visible ) { currentRenderList.push( object, geometry, material, groupOrder, _vector3.z, null ); } } } } var children = object.children; for ( var i = 0, l = children.length; i < l; i ++ ) { projectObject( children[ i ], camera, groupOrder, sortObjects ); } } function renderObjects( renderList, scene, camera, overrideMaterial ) { for ( var i = 0, l = renderList.length; i < l; i ++ ) { var renderItem = renderList[ i ]; var object = renderItem.object; var geometry = renderItem.geometry; var material = overrideMaterial === undefined ? renderItem.material : overrideMaterial; var group = renderItem.group; if ( camera.isArrayCamera ) { _currentArrayCamera = camera; var cameras = camera.cameras; for ( var j = 0, jl = cameras.length; j < jl; j ++ ) { var camera2 = cameras[ j ]; if ( object.layers.test( camera2.layers ) ) { state.viewport( _currentViewport.copy( camera2.viewport ) ); currentRenderState.setupLights( camera2 ); renderObject( object, scene, camera2, geometry, material, group ); } } } else { _currentArrayCamera = null; renderObject( object, scene, camera, geometry, material, group ); } } } function renderObject( object, scene, camera, geometry, material, group ) { object.onBeforeRender( _this, scene, camera, geometry, material, group ); currentRenderState = renderStates.get( scene, _currentArrayCamera || camera ); object.modelViewMatrix.multiplyMatrices( camera.matrixWorldInverse, object.matrixWorld ); object.normalMatrix.getNormalMatrix( object.modelViewMatrix ); if ( object.isImmediateRenderObject ) { state.setMaterial( material ); var program = setProgram( camera, scene.fog, material, object ); _currentGeometryProgram.geometry = null; _currentGeometryProgram.program = null; _currentGeometryProgram.wireframe = false; renderObjectImmediate( object, program ); } else { _this.renderBufferDirect( camera, scene.fog, geometry, material, object, group ); } object.onAfterRender( _this, scene, camera, geometry, material, group ); currentRenderState = renderStates.get( scene, _currentArrayCamera || camera ); } function initMaterial( material, fog, object ) { var materialProperties = properties.get( material ); var lights = currentRenderState.state.lights; var shadowsArray = currentRenderState.state.shadowsArray; var lightsStateVersion = lights.state.version; var parameters = programCache.getParameters( material, lights.state, shadowsArray, fog, _clipping.numPlanes, _clipping.numIntersection, object ); var code = programCache.getProgramCode( material, parameters ); var program = materialProperties.program; var programChange = true; if ( program === undefined ) { // new material material.addEventListener( 'dispose', onMaterialDispose ); } else if ( program.code !== code ) { // changed glsl or parameters releaseMaterialProgramReference( material ); } else if ( materialProperties.lightsStateVersion !== lightsStateVersion ) { materialProperties.lightsStateVersion = lightsStateVersion; programChange = false; } else if ( parameters.shaderID !== undefined ) { // same glsl and uniform list return; } else { // only rebuild uniform list programChange = false; } if ( programChange ) { if ( parameters.shaderID ) { var shader = ShaderLib[ parameters.shaderID ]; materialProperties.shader = { name: material.type, uniforms: cloneUniforms( shader.uniforms ), vertexShader: shader.vertexShader, fragmentShader: shader.fragmentShader }; } else { materialProperties.shader = { name: material.type, uniforms: material.uniforms, vertexShader: material.vertexShader, fragmentShader: material.fragmentShader }; } material.onBeforeCompile( materialProperties.shader, _this ); // Computing code again as onBeforeCompile may have changed the shaders code = programCache.getProgramCode( material, parameters ); program = programCache.acquireProgram( material, materialProperties.shader, parameters, code ); materialProperties.program = program; material.program = program; } var programAttributes = program.getAttributes(); if ( material.morphTargets ) { material.numSupportedMorphTargets = 0; for ( var i = 0; i < _this.maxMorphTargets; i ++ ) { if ( programAttributes[ 'morphTarget' + i ] >= 0 ) { material.numSupportedMorphTargets ++; } } } if ( material.morphNormals ) { material.numSupportedMorphNormals = 0; for ( var i = 0; i < _this.maxMorphNormals; i ++ ) { if ( programAttributes[ 'morphNormal' + i ] >= 0 ) { material.numSupportedMorphNormals ++; } } } var uniforms = materialProperties.shader.uniforms; if ( ! material.isShaderMaterial && ! material.isRawShaderMaterial || material.clipping === true ) { materialProperties.numClippingPlanes = _clipping.numPlanes; materialProperties.numIntersection = _clipping.numIntersection; uniforms.clippingPlanes = _clipping.uniform; } materialProperties.fog = fog; // store the light setup it was created for materialProperties.lightsStateVersion = lightsStateVersion; if ( material.lights ) { // wire up the material to this renderer's lighting state uniforms.ambientLightColor.value = lights.state.ambient; uniforms.lightProbe.value = lights.state.probe; uniforms.directionalLights.value = lights.state.directional; uniforms.spotLights.value = lights.state.spot; uniforms.rectAreaLights.value = lights.state.rectArea; uniforms.pointLights.value = lights.state.point; uniforms.hemisphereLights.value = lights.state.hemi; uniforms.directionalShadowMap.value = lights.state.directionalShadowMap; uniforms.directionalShadowMatrix.value = lights.state.directionalShadowMatrix; uniforms.spotShadowMap.value = lights.state.spotShadowMap; uniforms.spotShadowMatrix.value = lights.state.spotShadowMatrix; uniforms.pointShadowMap.value = lights.state.pointShadowMap; uniforms.pointShadowMatrix.value = lights.state.pointShadowMatrix; // TODO (abelnation): add area lights shadow info to uniforms } var progUniforms = materialProperties.program.getUniforms(), uniformsList = WebGLUniforms.seqWithValue( progUniforms.seq, uniforms ); materialProperties.uniformsList = uniformsList; } function setProgram( camera, fog, material, object ) { textures.resetTextureUnits(); var materialProperties = properties.get( material ); var lights = currentRenderState.state.lights; if ( _clippingEnabled ) { if ( _localClippingEnabled || camera !== _currentCamera ) { var useCache = camera === _currentCamera && material.id === _currentMaterialId; // we might want to call this function with some ClippingGroup // object instead of the material, once it becomes feasible // (#8465, #8379) _clipping.setState( material.clippingPlanes, material.clipIntersection, material.clipShadows, camera, materialProperties, useCache ); } } if ( material.needsUpdate === false ) { if ( materialProperties.program === undefined ) { material.needsUpdate = true; } else if ( material.fog && materialProperties.fog !== fog ) { material.needsUpdate = true; } else if ( material.lights && materialProperties.lightsStateVersion !== lights.state.version ) { material.needsUpdate = true; } else if ( materialProperties.numClippingPlanes !== undefined && ( materialProperties.numClippingPlanes !== _clipping.numPlanes || materialProperties.numIntersection !== _clipping.numIntersection ) ) { material.needsUpdate = true; } } if ( material.needsUpdate ) { initMaterial( material, fog, object ); material.needsUpdate = false; } var refreshProgram = false; var refreshMaterial = false; var refreshLights = false; var program = materialProperties.program, p_uniforms = program.getUniforms(), m_uniforms = materialProperties.shader.uniforms; if ( state.useProgram( program.program ) ) { refreshProgram = true; refreshMaterial = true; refreshLights = true; } if ( material.id !== _currentMaterialId ) { _currentMaterialId = material.id; refreshMaterial = true; } if ( refreshProgram || _currentCamera !== camera ) { p_uniforms.setValue( _gl, 'projectionMatrix', camera.projectionMatrix ); if ( capabilities.logarithmicDepthBuffer ) { p_uniforms.setValue( _gl, 'logDepthBufFC', 2.0 / ( Math.log( camera.far + 1.0 ) / Math.LN2 ) ); } if ( _currentCamera !== camera ) { _currentCamera = camera; // lighting uniforms depend on the camera so enforce an update // now, in case this material supports lights - or later, when // the next material that does gets activated: refreshMaterial = true; // set to true on material change refreshLights = true; // remains set until update done } // load material specific uniforms // (shader material also gets them for the sake of genericity) if ( material.isShaderMaterial || material.isMeshPhongMaterial || material.isMeshStandardMaterial || material.envMap ) { var uCamPos = p_uniforms.map.cameraPosition; if ( uCamPos !== undefined ) { uCamPos.setValue( _gl, _vector3.setFromMatrixPosition( camera.matrixWorld ) ); } } if ( material.isMeshPhongMaterial || material.isMeshLambertMaterial || material.isMeshBasicMaterial || material.isMeshStandardMaterial || material.isShaderMaterial || material.skinning ) { p_uniforms.setValue( _gl, 'viewMatrix', camera.matrixWorldInverse ); } } // skinning uniforms must be set even if material didn't change // auto-setting of texture unit for bone texture must go before other textures // not sure why, but otherwise weird things happen if ( material.skinning ) { p_uniforms.setOptional( _gl, object, 'bindMatrix' ); p_uniforms.setOptional( _gl, object, 'bindMatrixInverse' ); var skeleton = object.skeleton; if ( skeleton ) { var bones = skeleton.bones; if ( capabilities.floatVertexTextures ) { if ( skeleton.boneTexture === undefined ) { // layout (1 matrix = 4 pixels) // RGBA RGBA RGBA RGBA (=> column1, column2, column3, column4) // with 8x8 pixel texture max 16 bones * 4 pixels = (8 * 8) // 16x16 pixel texture max 64 bones * 4 pixels = (16 * 16) // 32x32 pixel texture max 256 bones * 4 pixels = (32 * 32) // 64x64 pixel texture max 1024 bones * 4 pixels = (64 * 64) var size = Math.sqrt( bones.length * 4 ); // 4 pixels needed for 1 matrix size = _Math.ceilPowerOfTwo( size ); size = Math.max( size, 4 ); var boneMatrices = new Float32Array( size * size * 4 ); // 4 floats per RGBA pixel boneMatrices.set( skeleton.boneMatrices ); // copy current values var boneTexture = new DataTexture( boneMatrices, size, size, RGBAFormat, FloatType ); boneTexture.needsUpdate = true; skeleton.boneMatrices = boneMatrices; skeleton.boneTexture = boneTexture; skeleton.boneTextureSize = size; } p_uniforms.setValue( _gl, 'boneTexture', skeleton.boneTexture, textures ); p_uniforms.setValue( _gl, 'boneTextureSize', skeleton.boneTextureSize ); } else { p_uniforms.setOptional( _gl, skeleton, 'boneMatrices' ); } } } if ( refreshMaterial ) { p_uniforms.setValue( _gl, 'toneMappingExposure', _this.toneMappingExposure ); p_uniforms.setValue( _gl, 'toneMappingWhitePoint', _this.toneMappingWhitePoint ); if ( material.lights ) { // the current material requires lighting info // note: all lighting uniforms are always set correctly // they simply reference the renderer's state for their // values // // use the current material's .needsUpdate flags to set // the GL state when required markUniformsLightsNeedsUpdate( m_uniforms, refreshLights ); } // refresh uniforms common to several materials if ( fog && material.fog ) { refreshUniformsFog( m_uniforms, fog ); } if ( material.isMeshBasicMaterial ) { refreshUniformsCommon( m_uniforms, material ); } else if ( material.isMeshLambertMaterial ) { refreshUniformsCommon( m_uniforms, material ); refreshUniformsLambert( m_uniforms, material ); } else if ( material.isMeshPhongMaterial ) { refreshUniformsCommon( m_uniforms, material ); if ( material.isMeshToonMaterial ) { refreshUniformsToon( m_uniforms, material ); } else { refreshUniformsPhong( m_uniforms, material ); } } else if ( material.isMeshStandardMaterial ) { refreshUniformsCommon( m_uniforms, material ); if ( material.isMeshPhysicalMaterial ) { refreshUniformsPhysical( m_uniforms, material ); } else { refreshUniformsStandard( m_uniforms, material ); } } else if ( material.isMeshMatcapMaterial ) { refreshUniformsCommon( m_uniforms, material ); refreshUniformsMatcap( m_uniforms, material ); } else if ( material.isMeshDepthMaterial ) { refreshUniformsCommon( m_uniforms, material ); refreshUniformsDepth( m_uniforms, material ); } else if ( material.isMeshDistanceMaterial ) { refreshUniformsCommon( m_uniforms, material ); refreshUniformsDistance( m_uniforms, material ); } else if ( material.isMeshNormalMaterial ) { refreshUniformsCommon( m_uniforms, material ); refreshUniformsNormal( m_uniforms, material ); } else if ( material.isLineBasicMaterial ) { refreshUniformsLine( m_uniforms, material ); if ( material.isLineDashedMaterial ) { refreshUniformsDash( m_uniforms, material ); } } else if ( material.isPointsMaterial ) { refreshUniformsPoints( m_uniforms, material ); } else if ( material.isSpriteMaterial ) { refreshUniformsSprites( m_uniforms, material ); } else if ( material.isShadowMaterial ) { m_uniforms.color.value.copy( material.color ); m_uniforms.opacity.value = material.opacity; } // RectAreaLight Texture // TODO (mrdoob): Find a nicer implementation if ( m_uniforms.ltc_1 !== undefined ) m_uniforms.ltc_1.value = UniformsLib.LTC_1; if ( m_uniforms.ltc_2 !== undefined ) m_uniforms.ltc_2.value = UniformsLib.LTC_2; WebGLUniforms.upload( _gl, materialProperties.uniformsList, m_uniforms, textures ); } if ( material.isShaderMaterial && material.uniformsNeedUpdate === true ) { WebGLUniforms.upload( _gl, materialProperties.uniformsList, m_uniforms, textures ); material.uniformsNeedUpdate = false; } if ( material.isSpriteMaterial ) { p_uniforms.setValue( _gl, 'center', object.center ); } // common matrices p_uniforms.setValue( _gl, 'modelViewMatrix', object.modelViewMatrix ); p_uniforms.setValue( _gl, 'normalMatrix', object.normalMatrix ); p_uniforms.setValue( _gl, 'modelMatrix', object.matrixWorld ); return program; } // Uniforms (refresh uniforms objects) function refreshUniformsCommon( uniforms, material ) { uniforms.opacity.value = material.opacity; if ( material.color ) { uniforms.diffuse.value.copy( material.color ); } if ( material.emissive ) { uniforms.emissive.value.copy( material.emissive ).multiplyScalar( material.emissiveIntensity ); } if ( material.map ) { uniforms.map.value = material.map; } if ( material.alphaMap ) { uniforms.alphaMap.value = material.alphaMap; } if ( material.specularMap ) { uniforms.specularMap.value = material.specularMap; } if ( material.envMap ) { uniforms.envMap.value = material.envMap; // don't flip CubeTexture envMaps, flip everything else: // WebGLRenderTargetCube will be flipped for backwards compatibility // WebGLRenderTargetCube.texture will be flipped because it's a Texture and NOT a CubeTexture // this check must be handled differently, or removed entirely, if WebGLRenderTargetCube uses a CubeTexture in the future uniforms.flipEnvMap.value = material.envMap.isCubeTexture ? - 1 : 1; uniforms.reflectivity.value = material.reflectivity; uniforms.refractionRatio.value = material.refractionRatio; uniforms.maxMipLevel.value = properties.get( material.envMap ).__maxMipLevel; } if ( material.lightMap ) { uniforms.lightMap.value = material.lightMap; uniforms.lightMapIntensity.value = material.lightMapIntensity; } if ( material.aoMap ) { uniforms.aoMap.value = material.aoMap; uniforms.aoMapIntensity.value = material.aoMapIntensity; } // uv repeat and offset setting priorities // 1. color map // 2. specular map // 3. normal map // 4. bump map // 5. alpha map // 6. emissive map var uvScaleMap; if ( material.map ) { uvScaleMap = material.map; } else if ( material.specularMap ) { uvScaleMap = material.specularMap; } else if ( material.displacementMap ) { uvScaleMap = material.displacementMap; } else if ( material.normalMap ) { uvScaleMap = material.normalMap; } else if ( material.bumpMap ) { uvScaleMap = material.bumpMap; } else if ( material.roughnessMap ) { uvScaleMap = material.roughnessMap; } else if ( material.metalnessMap ) { uvScaleMap = material.metalnessMap; } else if ( material.alphaMap ) { uvScaleMap = material.alphaMap; } else if ( material.emissiveMap ) { uvScaleMap = material.emissiveMap; } if ( uvScaleMap !== undefined ) { // backwards compatibility if ( uvScaleMap.isWebGLRenderTarget ) { uvScaleMap = uvScaleMap.texture; } if ( uvScaleMap.matrixAutoUpdate === true ) { uvScaleMap.updateMatrix(); } uniforms.uvTransform.value.copy( uvScaleMap.matrix ); } } function refreshUniformsLine( uniforms, material ) { uniforms.diffuse.value.copy( material.color ); uniforms.opacity.value = material.opacity; } function refreshUniformsDash( uniforms, material ) { uniforms.dashSize.value = material.dashSize; uniforms.totalSize.value = material.dashSize + material.gapSize; uniforms.scale.value = material.scale; } function refreshUniformsPoints( uniforms, material ) { uniforms.diffuse.value.copy( material.color ); uniforms.opacity.value = material.opacity; uniforms.size.value = material.size * _pixelRatio; uniforms.scale.value = _height * 0.5; uniforms.map.value = material.map; if ( material.map !== null ) { if ( material.map.matrixAutoUpdate === true ) { material.map.updateMatrix(); } uniforms.uvTransform.value.copy( material.map.matrix ); } } function refreshUniformsSprites( uniforms, material ) { uniforms.diffuse.value.copy( material.color ); uniforms.opacity.value = material.opacity; uniforms.rotation.value = material.rotation; uniforms.map.value = material.map; if ( material.map !== null ) { if ( material.map.matrixAutoUpdate === true ) { material.map.updateMatrix(); } uniforms.uvTransform.value.copy( material.map.matrix ); } } function refreshUniformsFog( uniforms, fog ) { uniforms.fogColor.value.copy( fog.color ); if ( fog.isFog ) { uniforms.fogNear.value = fog.near; uniforms.fogFar.value = fog.far; } else if ( fog.isFogExp2 ) { uniforms.fogDensity.value = fog.density; } } function refreshUniformsLambert( uniforms, material ) { if ( material.emissiveMap ) { uniforms.emissiveMap.value = material.emissiveMap; } } function refreshUniformsPhong( uniforms, material ) { uniforms.specular.value.copy( material.specular ); uniforms.shininess.value = Math.max( material.shininess, 1e-4 ); // to prevent pow( 0.0, 0.0 ) if ( material.emissiveMap ) { uniforms.emissiveMap.value = material.emissiveMap; } if ( material.bumpMap ) { uniforms.bumpMap.value = material.bumpMap; uniforms.bumpScale.value = material.bumpScale; if ( material.side === BackSide ) uniforms.bumpScale.value *= - 1; } if ( material.normalMap ) { uniforms.normalMap.value = material.normalMap; uniforms.normalScale.value.copy( material.normalScale ); if ( material.side === BackSide ) uniforms.normalScale.value.negate(); } if ( material.displacementMap ) { uniforms.displacementMap.value = material.displacementMap; uniforms.displacementScale.value = material.displacementScale; uniforms.displacementBias.value = material.displacementBias; } } function refreshUniformsToon( uniforms, material ) { refreshUniformsPhong( uniforms, material ); if ( material.gradientMap ) { uniforms.gradientMap.value = material.gradientMap; } } function refreshUniformsStandard( uniforms, material ) { uniforms.roughness.value = material.roughness; uniforms.metalness.value = material.metalness; if ( material.roughnessMap ) { uniforms.roughnessMap.value = material.roughnessMap; } if ( material.metalnessMap ) { uniforms.metalnessMap.value = material.metalnessMap; } if ( material.emissiveMap ) { uniforms.emissiveMap.value = material.emissiveMap; } if ( material.bumpMap ) { uniforms.bumpMap.value = material.bumpMap; uniforms.bumpScale.value = material.bumpScale; if ( material.side === BackSide ) uniforms.bumpScale.value *= - 1; } if ( material.normalMap ) { uniforms.normalMap.value = material.normalMap; uniforms.normalScale.value.copy( material.normalScale ); if ( material.side === BackSide ) uniforms.normalScale.value.negate(); } if ( material.displacementMap ) { uniforms.displacementMap.value = material.displacementMap; uniforms.displacementScale.value = material.displacementScale; uniforms.displacementBias.value = material.displacementBias; } if ( material.envMap ) { //uniforms.envMap.value = material.envMap; // part of uniforms common uniforms.envMapIntensity.value = material.envMapIntensity; } } function refreshUniformsPhysical( uniforms, material ) { refreshUniformsStandard( uniforms, material ); uniforms.reflectivity.value = material.reflectivity; // also part of uniforms common uniforms.clearCoat.value = material.clearCoat; uniforms.clearCoatRoughness.value = material.clearCoatRoughness; if ( material.clearCoatNormalMap ) { uniforms.clearCoatNormalScale.value.copy( material.clearCoatNormalScale ); uniforms.clearCoatNormalMap.value = material.clearCoatNormalMap; if ( material.side === BackSide ) { uniforms.clearCoatNormalScale.value.negate(); } } } function refreshUniformsMatcap( uniforms, material ) { if ( material.matcap ) { uniforms.matcap.value = material.matcap; } if ( material.bumpMap ) { uniforms.bumpMap.value = material.bumpMap; uniforms.bumpScale.value = material.bumpScale; if ( material.side === BackSide ) uniforms.bumpScale.value *= - 1; } if ( material.normalMap ) { uniforms.normalMap.value = material.normalMap; uniforms.normalScale.value.copy( material.normalScale ); if ( material.side === BackSide ) uniforms.normalScale.value.negate(); } if ( material.displacementMap ) { uniforms.displacementMap.value = material.displacementMap; uniforms.displacementScale.value = material.displacementScale; uniforms.displacementBias.value = material.displacementBias; } } function refreshUniformsDepth( uniforms, material ) { if ( material.displacementMap ) { uniforms.displacementMap.value = material.displacementMap; uniforms.displacementScale.value = material.displacementScale; uniforms.displacementBias.value = material.displacementBias; } } function refreshUniformsDistance( uniforms, material ) { if ( material.displacementMap ) { uniforms.displacementMap.value = material.displacementMap; uniforms.displacementScale.value = material.displacementScale; uniforms.displacementBias.value = material.displacementBias; } uniforms.referencePosition.value.copy( material.referencePosition ); uniforms.nearDistance.value = material.nearDistance; uniforms.farDistance.value = material.farDistance; } function refreshUniformsNormal( uniforms, material ) { if ( material.bumpMap ) { uniforms.bumpMap.value = material.bumpMap; uniforms.bumpScale.value = material.bumpScale; if ( material.side === BackSide ) uniforms.bumpScale.value *= - 1; } if ( material.normalMap ) { uniforms.normalMap.value = material.normalMap; uniforms.normalScale.value.copy( material.normalScale ); if ( material.side === BackSide ) uniforms.normalScale.value.negate(); } if ( material.displacementMap ) { uniforms.displacementMap.value = material.displacementMap; uniforms.displacementScale.value = material.displacementScale; uniforms.displacementBias.value = material.displacementBias; } } // If uniforms are marked as clean, they don't need to be loaded to the GPU. function markUniformsLightsNeedsUpdate( uniforms, value ) { uniforms.ambientLightColor.needsUpdate = value; uniforms.lightProbe.needsUpdate = value; uniforms.directionalLights.needsUpdate = value; uniforms.pointLights.needsUpdate = value; uniforms.spotLights.needsUpdate = value; uniforms.rectAreaLights.needsUpdate = value; uniforms.hemisphereLights.needsUpdate = value; } // this.setFramebuffer = function ( value ) { if ( _framebuffer !== value ) _gl.bindFramebuffer( _gl.FRAMEBUFFER, value ); _framebuffer = value; }; this.getActiveCubeFace = function () { return _currentActiveCubeFace; }; this.getActiveMipmapLevel = function () { return _currentActiveMipmapLevel; }; this.getRenderTarget = function () { return _currentRenderTarget; }; this.setRenderTarget = function ( renderTarget, activeCubeFace, activeMipmapLevel ) { _currentRenderTarget = renderTarget; _currentActiveCubeFace = activeCubeFace; _currentActiveMipmapLevel = activeMipmapLevel; if ( renderTarget && properties.get( renderTarget ).__webglFramebuffer === undefined ) { textures.setupRenderTarget( renderTarget ); } var framebuffer = _framebuffer; var isCube = false; if ( renderTarget ) { var __webglFramebuffer = properties.get( renderTarget ).__webglFramebuffer; if ( renderTarget.isWebGLRenderTargetCube ) { framebuffer = __webglFramebuffer[ activeCubeFace || 0 ]; isCube = true; } else if ( renderTarget.isWebGLMultisampleRenderTarget ) { framebuffer = properties.get( renderTarget ).__webglMultisampledFramebuffer; } else { framebuffer = __webglFramebuffer; } _currentViewport.copy( renderTarget.viewport ); _currentScissor.copy( renderTarget.scissor ); _currentScissorTest = renderTarget.scissorTest; } else { _currentViewport.copy( _viewport ).multiplyScalar( _pixelRatio ).floor(); _currentScissor.copy( _scissor ).multiplyScalar( _pixelRatio ).floor(); _currentScissorTest = _scissorTest; } if ( _currentFramebuffer !== framebuffer ) { _gl.bindFramebuffer( _gl.FRAMEBUFFER, framebuffer ); _currentFramebuffer = framebuffer; } state.viewport( _currentViewport ); state.scissor( _currentScissor ); state.setScissorTest( _currentScissorTest ); if ( isCube ) { var textureProperties = properties.get( renderTarget.texture ); _gl.framebufferTexture2D( _gl.FRAMEBUFFER, _gl.COLOR_ATTACHMENT0, _gl.TEXTURE_CUBE_MAP_POSITIVE_X + ( activeCubeFace || 0 ), textureProperties.__webglTexture, activeMipmapLevel || 0 ); } }; this.readRenderTargetPixels = function ( renderTarget, x, y, width, height, buffer, activeCubeFaceIndex ) { if ( ! ( renderTarget && renderTarget.isWebGLRenderTarget ) ) { console.error( 'THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not THREE.WebGLRenderTarget.' ); return; } var framebuffer = properties.get( renderTarget ).__webglFramebuffer; if ( renderTarget.isWebGLRenderTargetCube && activeCubeFaceIndex !== undefined ) { framebuffer = framebuffer[ activeCubeFaceIndex ]; } if ( framebuffer ) { var restore = false; if ( framebuffer !== _currentFramebuffer ) { _gl.bindFramebuffer( _gl.FRAMEBUFFER, framebuffer ); restore = true; } try { var texture = renderTarget.texture; var textureFormat = texture.format; var textureType = texture.type; if ( textureFormat !== RGBAFormat && utils.convert( textureFormat ) !== _gl.getParameter( _gl.IMPLEMENTATION_COLOR_READ_FORMAT ) ) { console.error( 'THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in RGBA or implementation defined format.' ); return; } if ( textureType !== UnsignedByteType && utils.convert( textureType ) !== _gl.getParameter( _gl.IMPLEMENTATION_COLOR_READ_TYPE ) && // IE11, Edge and Chrome Mac < 52 (#9513) ! ( textureType === FloatType && ( capabilities.isWebGL2 || extensions.get( 'OES_texture_float' ) || extensions.get( 'WEBGL_color_buffer_float' ) ) ) && // Chrome Mac >= 52 and Firefox ! ( textureType === HalfFloatType && ( capabilities.isWebGL2 ? extensions.get( 'EXT_color_buffer_float' ) : extensions.get( 'EXT_color_buffer_half_float' ) ) ) ) { console.error( 'THREE.WebGLRenderer.readRenderTargetPixels: renderTarget is not in UnsignedByteType or implementation defined type.' ); return; } if ( _gl.checkFramebufferStatus( _gl.FRAMEBUFFER ) === _gl.FRAMEBUFFER_COMPLETE ) { // the following if statement ensures valid read requests (no out-of-bounds pixels, see #8604) if ( ( x >= 0 && x <= ( renderTarget.width - width ) ) && ( y >= 0 && y <= ( renderTarget.height - height ) ) ) { _gl.readPixels( x, y, width, height, utils.convert( textureFormat ), utils.convert( textureType ), buffer ); } } else { console.error( 'THREE.WebGLRenderer.readRenderTargetPixels: readPixels from renderTarget failed. Framebuffer not complete.' ); } } finally { if ( restore ) { _gl.bindFramebuffer( _gl.FRAMEBUFFER, _currentFramebuffer ); } } } }; this.copyFramebufferToTexture = function ( position, texture, level ) { var width = texture.image.width; var height = texture.image.height; var glFormat = utils.convert( texture.format ); textures.setTexture2D( texture, 0 ); _gl.copyTexImage2D( _gl.TEXTURE_2D, level || 0, glFormat, position.x, position.y, width, height, 0 ); }; this.copyTextureToTexture = function ( position, srcTexture, dstTexture, level ) { var width = srcTexture.image.width; var height = srcTexture.image.height; var glFormat = utils.convert( dstTexture.format ); var glType = utils.convert( dstTexture.type ); textures.setTexture2D( dstTexture, 0 ); if ( srcTexture.isDataTexture ) { _gl.texSubImage2D( _gl.TEXTURE_2D, level || 0, position.x, position.y, width, height, glFormat, glType, srcTexture.image.data ); } else { _gl.texSubImage2D( _gl.TEXTURE_2D, level || 0, position.x, position.y, glFormat, glType, srcTexture.image ); } }; if ( typeof __THREE_DEVTOOLS__ !== 'undefined' ) { __THREE_DEVTOOLS__.dispatchEvent( new CustomEvent( 'observe', { detail: this } ) ); // eslint-disable-line no-undef } } export { WebGLRenderer };
{ "content_hash": "3f427d95f76d54482a9afdfd7670b265", "timestamp": "", "source": "github", "line_count": 2610, "max_line_length": 189, "avg_line_length": 23.642528735632183, "alnum_prop": 0.6893383246633283, "repo_name": "sttz/three.js", "id": "a7f6aff413f1a91843c3cf8945ff50aaa1b134a9", "size": "61707", "binary": false, "copies": "1", "ref": "refs/heads/dev", "path": "src/renderers/WebGLRenderer.js", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "28686" }, { "name": "HTML", "bytes": "22455" }, { "name": "JavaScript", "bytes": "5738324" } ], "symlink_target": "" }
var ManagerConnect = require('./lib/connect'); var ManagerLauncher = require('./lib/launcher'); module.exports = { 'managerConnect': ['type', ManagerConnect], 'launcher:ManagerLauncher': ['type', ManagerLauncher] };
{ "content_hash": "3207bf11a7fc91ac62fc3b566b4a015e", "timestamp": "", "source": "github", "line_count": 7, "max_line_length": 57, "avg_line_length": 32, "alnum_prop": 0.7008928571428571, "repo_name": "bazilio91/karma-tdm-launcher", "id": "4fe45f4e70abbcddbe0a6b475e92ad1bfaf5b2a0", "size": "224", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "index.js", "mode": "33188", "license": "mit", "language": [ { "name": "JavaScript", "bytes": "4650" } ], "symlink_target": "" }
package org.apache.kafka.connect.runtime.rest; import com.fasterxml.jackson.jaxrs.json.JacksonJsonProvider; import org.apache.kafka.common.config.ConfigException; import org.apache.kafka.connect.errors.ConnectException; import org.apache.kafka.connect.health.ConnectClusterDetails; import org.apache.kafka.connect.rest.ConnectRestExtension; import org.apache.kafka.connect.rest.ConnectRestExtensionContext; import org.apache.kafka.connect.runtime.Herder; import org.apache.kafka.connect.runtime.WorkerConfig; import org.apache.kafka.connect.runtime.health.ConnectClusterDetailsImpl; import org.apache.kafka.connect.runtime.health.ConnectClusterStateImpl; import org.apache.kafka.connect.runtime.rest.errors.ConnectExceptionMapper; import org.apache.kafka.connect.runtime.rest.resources.ConnectorPluginsResource; import org.apache.kafka.connect.runtime.rest.resources.ConnectorsResource; import org.apache.kafka.connect.runtime.rest.resources.RootResource; import org.apache.kafka.connect.runtime.rest.util.SSLUtils; import org.eclipse.jetty.server.Connector; import org.eclipse.jetty.server.CustomRequestLog; import org.eclipse.jetty.server.Handler; import org.eclipse.jetty.server.Server; import org.eclipse.jetty.server.ServerConnector; import org.eclipse.jetty.server.Slf4jRequestLogWriter; import org.eclipse.jetty.server.handler.ContextHandlerCollection; import org.eclipse.jetty.server.handler.DefaultHandler; import org.eclipse.jetty.server.handler.RequestLogHandler; import org.eclipse.jetty.server.handler.StatisticsHandler; import org.eclipse.jetty.servlet.FilterHolder; import org.eclipse.jetty.servlet.ServletContextHandler; import org.eclipse.jetty.servlet.ServletHolder; import org.eclipse.jetty.servlets.CrossOriginFilter; import org.eclipse.jetty.util.ssl.SslContextFactory; import org.glassfish.jersey.server.ResourceConfig; import org.glassfish.jersey.server.ServerProperties; import org.glassfish.jersey.servlet.ServletContainer; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import javax.servlet.DispatcherType; import javax.ws.rs.core.UriBuilder; import java.io.IOException; import java.net.URI; import java.util.ArrayList; import java.util.Collections; import java.util.EnumSet; import java.util.List; import java.util.Locale; import java.util.regex.Matcher; import java.util.regex.Pattern; /** * Embedded server for the REST API that provides the control plane for Kafka Connect workers. */ public class RestServer { private static final Logger log = LoggerFactory.getLogger(RestServer.class); private static final Pattern LISTENER_PATTERN = Pattern.compile("^(.*)://\\[?([0-9a-zA-Z\\-%._:]*)\\]?:(-?[0-9]+)"); private static final long GRACEFUL_SHUTDOWN_TIMEOUT_MS = 60 * 1000; private static final String PROTOCOL_HTTP = "http"; private static final String PROTOCOL_HTTPS = "https"; private final WorkerConfig config; private ContextHandlerCollection handlers; private Server jettyServer; private List<ConnectRestExtension> connectRestExtensions = Collections.emptyList(); /** * Create a REST server for this herder using the specified configs. */ public RestServer(WorkerConfig config) { this.config = config; List<String> listeners = parseListeners(); jettyServer = new Server(); handlers = new ContextHandlerCollection(); createConnectors(listeners); } @SuppressWarnings("deprecation") List<String> parseListeners() { List<String> listeners = config.getList(WorkerConfig.LISTENERS_CONFIG); if (listeners == null || listeners.size() == 0) { String hostname = config.getString(WorkerConfig.REST_HOST_NAME_CONFIG); if (hostname == null) hostname = ""; listeners = Collections.singletonList(String.format("%s://%s:%d", PROTOCOL_HTTP, hostname, config.getInt(WorkerConfig.REST_PORT_CONFIG))); } return listeners; } /** * Adds Jetty connector for each configured listener */ public void createConnectors(List<String> listeners) { List<Connector> connectors = new ArrayList<>(); for (String listener : listeners) { if (!listener.isEmpty()) { Connector connector = createConnector(listener); connectors.add(connector); log.info("Added connector for " + listener); } } jettyServer.setConnectors(connectors.toArray(new Connector[connectors.size()])); } /** * Creates Jetty connector according to configuration */ public Connector createConnector(String listener) { Matcher listenerMatcher = LISTENER_PATTERN.matcher(listener); if (!listenerMatcher.matches()) throw new ConfigException("Listener doesn't have the right format (protocol://hostname:port)."); String protocol = listenerMatcher.group(1).toLowerCase(Locale.ENGLISH); if (!PROTOCOL_HTTP.equals(protocol) && !PROTOCOL_HTTPS.equals(protocol)) throw new ConfigException(String.format("Listener protocol must be either \"%s\" or \"%s\".", PROTOCOL_HTTP, PROTOCOL_HTTPS)); String hostname = listenerMatcher.group(2); int port = Integer.parseInt(listenerMatcher.group(3)); ServerConnector connector; if (PROTOCOL_HTTPS.equals(protocol)) { SslContextFactory ssl = SSLUtils.createServerSideSslContextFactory(config); connector = new ServerConnector(jettyServer, ssl); connector.setName(String.format("%s_%s%d", PROTOCOL_HTTPS, hostname, port)); } else { connector = new ServerConnector(jettyServer); connector.setName(String.format("%s_%s%d", PROTOCOL_HTTP, hostname, port)); } if (!hostname.isEmpty()) connector.setHost(hostname); connector.setPort(port); return connector; } public void initializeServer() { log.info("Initializing REST server"); /* Needed for graceful shutdown as per `setStopTimeout` documentation */ StatisticsHandler statsHandler = new StatisticsHandler(); statsHandler.setHandler(handlers); jettyServer.setHandler(statsHandler); jettyServer.setStopTimeout(GRACEFUL_SHUTDOWN_TIMEOUT_MS); jettyServer.setStopAtShutdown(true); try { jettyServer.start(); } catch (Exception e) { throw new ConnectException("Unable to initialize REST server", e); } log.info("REST server listening at " + jettyServer.getURI() + ", advertising URL " + advertisedUrl()); } public void initializeResources(Herder herder) { log.info("Initializing REST resources"); ResourceConfig resourceConfig = new ResourceConfig(); resourceConfig.register(new JacksonJsonProvider()); resourceConfig.register(new RootResource(herder)); resourceConfig.register(new ConnectorsResource(herder, config)); resourceConfig.register(new ConnectorPluginsResource(herder)); resourceConfig.register(ConnectExceptionMapper.class); resourceConfig.property(ServerProperties.WADL_FEATURE_DISABLE, true); registerRestExtensions(herder, resourceConfig); ServletContainer servletContainer = new ServletContainer(resourceConfig); ServletHolder servletHolder = new ServletHolder(servletContainer); ServletContextHandler context = new ServletContextHandler(ServletContextHandler.SESSIONS); context.setContextPath("/"); context.addServlet(servletHolder, "/*"); String allowedOrigins = config.getString(WorkerConfig.ACCESS_CONTROL_ALLOW_ORIGIN_CONFIG); if (allowedOrigins != null && !allowedOrigins.trim().isEmpty()) { FilterHolder filterHolder = new FilterHolder(new CrossOriginFilter()); filterHolder.setName("cross-origin"); filterHolder.setInitParameter(CrossOriginFilter.ALLOWED_ORIGINS_PARAM, allowedOrigins); String allowedMethods = config.getString(WorkerConfig.ACCESS_CONTROL_ALLOW_METHODS_CONFIG); if (allowedMethods != null && !allowedOrigins.trim().isEmpty()) { filterHolder.setInitParameter(CrossOriginFilter.ALLOWED_METHODS_PARAM, allowedMethods); } context.addFilter(filterHolder, "/*", EnumSet.of(DispatcherType.REQUEST)); } RequestLogHandler requestLogHandler = new RequestLogHandler(); Slf4jRequestLogWriter slf4jRequestLogWriter = new Slf4jRequestLogWriter(); slf4jRequestLogWriter.setLoggerName(RestServer.class.getCanonicalName()); CustomRequestLog requestLog = new CustomRequestLog(slf4jRequestLogWriter, CustomRequestLog.EXTENDED_NCSA_FORMAT + " %msT"); requestLogHandler.setRequestLog(requestLog); handlers.setHandlers(new Handler[]{context, new DefaultHandler(), requestLogHandler}); try { context.start(); } catch (Exception e) { throw new ConnectException("Unable to initialize REST resources", e); } log.info("REST resources initialized; server is started and ready to handle requests"); } public URI serverUrl() { return jettyServer.getURI(); } public void stop() { log.info("Stopping REST server"); try { for (ConnectRestExtension connectRestExtension : connectRestExtensions) { try { connectRestExtension.close(); } catch (IOException e) { log.warn("Error while invoking close on " + connectRestExtension.getClass(), e); } } jettyServer.stop(); jettyServer.join(); } catch (Exception e) { jettyServer.destroy(); throw new ConnectException("Unable to stop REST server", e); } log.info("REST server stopped"); } /** * Get the URL to advertise to other workers and clients. This uses the default connector from the embedded Jetty * server, unless overrides for advertised hostname and/or port are provided via configs. {@link #initializeServer()} * must be invoked successfully before calling this method. */ public URI advertisedUrl() { UriBuilder builder = UriBuilder.fromUri(jettyServer.getURI()); String advertisedSecurityProtocol = determineAdvertisedProtocol(); ServerConnector serverConnector = findConnector(advertisedSecurityProtocol); builder.scheme(advertisedSecurityProtocol); String advertisedHostname = config.getString(WorkerConfig.REST_ADVERTISED_HOST_NAME_CONFIG); if (advertisedHostname != null && !advertisedHostname.isEmpty()) builder.host(advertisedHostname); else if (serverConnector != null && serverConnector.getHost() != null && serverConnector.getHost().length() > 0) builder.host(serverConnector.getHost()); Integer advertisedPort = config.getInt(WorkerConfig.REST_ADVERTISED_PORT_CONFIG); if (advertisedPort != null) builder.port(advertisedPort); else if (serverConnector != null && serverConnector.getPort() > 0) builder.port(serverConnector.getPort()); log.info("Advertised URI: {}", builder.build()); return builder.build(); } String determineAdvertisedProtocol() { String advertisedSecurityProtocol = config.getString(WorkerConfig.REST_ADVERTISED_LISTENER_CONFIG); if (advertisedSecurityProtocol == null) { String listeners = (String) config.originals().get(WorkerConfig.LISTENERS_CONFIG); if (listeners == null) return PROTOCOL_HTTP; else listeners = listeners.toLowerCase(Locale.ENGLISH); if (listeners.contains(String.format("%s://", PROTOCOL_HTTP))) return PROTOCOL_HTTP; else if (listeners.contains(String.format("%s://", PROTOCOL_HTTPS))) return PROTOCOL_HTTPS; else return PROTOCOL_HTTP; } else { return advertisedSecurityProtocol.toLowerCase(Locale.ENGLISH); } } ServerConnector findConnector(String protocol) { for (Connector connector : jettyServer.getConnectors()) { if (connector.getName().startsWith(protocol)) return (ServerConnector) connector; } return null; } void registerRestExtensions(Herder herder, ResourceConfig resourceConfig) { connectRestExtensions = herder.plugins().newPlugins( config.getList(WorkerConfig.REST_EXTENSION_CLASSES_CONFIG), config, ConnectRestExtension.class); long herderRequestTimeoutMs = ConnectorsResource.REQUEST_TIMEOUT_MS; Integer rebalanceTimeoutMs = config.getRebalanceTimeout(); if (rebalanceTimeoutMs != null) { herderRequestTimeoutMs = Math.min(herderRequestTimeoutMs, rebalanceTimeoutMs.longValue()); } ConnectClusterDetails connectClusterDetails = new ConnectClusterDetailsImpl( herder.kafkaClusterId() ); ConnectRestExtensionContext connectRestExtensionContext = new ConnectRestExtensionContextImpl( new ConnectRestConfigurable(resourceConfig), new ConnectClusterStateImpl(herderRequestTimeoutMs, connectClusterDetails, herder) ); for (ConnectRestExtension connectRestExtension : connectRestExtensions) { connectRestExtension.register(connectRestExtensionContext); } } public static String urlJoin(String base, String path) { if (base.endsWith("/") && path.startsWith("/")) return base + path.substring(1); else return base + path; } }
{ "content_hash": "4d5045d52750472930f75650ea9ae443", "timestamp": "", "source": "github", "line_count": 340, "max_line_length": 150, "avg_line_length": 40.85294117647059, "alnum_prop": 0.689056875449964, "repo_name": "KevinLiLu/kafka", "id": "bab20f586282639b238552d700e83dbde24b84e4", "size": "14688", "binary": false, "copies": "1", "ref": "refs/heads/trunk", "path": "connect/runtime/src/main/java/org/apache/kafka/connect/runtime/rest/RestServer.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Batchfile", "bytes": "29277" }, { "name": "Dockerfile", "bytes": "6044" }, { "name": "HTML", "bytes": "3739" }, { "name": "Java", "bytes": "17318873" }, { "name": "Python", "bytes": "851864" }, { "name": "Scala", "bytes": "6380036" }, { "name": "Shell", "bytes": "91444" }, { "name": "XSLT", "bytes": "7116" } ], "symlink_target": "" }
class Pickle; namespace ui { /////////////////////////////////////////////////////////////////////////////// // // OSExchangeData // An object that holds interchange data to be sent out to OS services like // clipboard, drag and drop, etc. This object exposes an API that clients can // use to specify raw data and its high level type. This object takes care of // translating that into something the OS can understand. // /////////////////////////////////////////////////////////////////////////////// // NOTE: Support for html and file contents is required by TabContentViewWin. // TabContentsViewGtk uses a different class to handle drag support that does // not use OSExchangeData. As such, file contents and html support is only // compiled on windows. class UI_EXPORT OSExchangeData { public: // CustomFormats are used for non-standard data types. For example, bookmark // nodes are written using a CustomFormat. #if defined(USE_AURA) // Use the same type as the clipboard (why do we want two different // definitions of this on other platforms?). typedef Clipboard::FormatType CustomFormat; #elif defined(OS_WIN) typedef CLIPFORMAT CustomFormat; #elif defined(TOOLKIT_GTK) typedef GdkAtom CustomFormat; #else typedef void* CustomFormat; #endif // Enumeration of the known formats. enum Format { STRING = 1 << 0, URL = 1 << 1, FILE_NAME = 1 << 2, PICKLED_DATA = 1 << 3, #if defined(OS_WIN) FILE_CONTENTS = 1 << 4, #endif #if defined(OS_WIN) || defined(USE_AURA) HTML = 1 << 5, #endif }; // Encapsulates the info about a file to be downloaded. struct UI_EXPORT DownloadFileInfo { DownloadFileInfo(const FilePath& filename, DownloadFileProvider* downloader); ~DownloadFileInfo(); FilePath filename; scoped_refptr<DownloadFileProvider> downloader; }; // Encapsulates the info about a file. struct UI_EXPORT FileInfo { FileInfo(const FilePath& path, const FilePath& display_name); ~FileInfo(); // The path of the file. FilePath path; // The display name of the file. This field is optional. FilePath display_name; }; // Provider defines the platform specific part of OSExchangeData that // interacts with the native system. class UI_EXPORT Provider { public: Provider() {} virtual ~Provider() {} virtual void SetString(const string16& data) = 0; // virtual void SetURL(const GURL& url, const string16& title) = 0; virtual void SetFilename(const FilePath& path) = 0; virtual void SetFilenames( const std::vector<FileInfo>& file_names) = 0; virtual void SetPickledData(CustomFormat format, const Pickle& data) = 0; virtual bool GetString(string16* data) const = 0; // virtual bool GetURLAndTitle(GURL* url, string16* title) const = 0; virtual bool GetFilename(FilePath* path) const = 0; virtual bool GetFilenames( std::vector<FileInfo>* file_names) const = 0; virtual bool GetPickledData(CustomFormat format, Pickle* data) const = 0; virtual bool HasString() const = 0; virtual bool HasURL() const = 0; virtual bool HasFile() const = 0; virtual bool HasCustomFormat( OSExchangeData::CustomFormat format) const = 0; #if defined(OS_WIN) virtual void SetFileContents(const FilePath& filename, const std::string& file_contents) = 0; virtual bool GetFileContents(FilePath* filename, std::string* file_contents) const = 0; virtual bool HasFileContents() const = 0; virtual void SetDownloadFileInfo(const DownloadFileInfo& download) = 0; #endif //#if defined(OS_WIN) || defined(USE_AURA) // // virtual void SetHtml(const string16& html, const GURL& base_url) = 0; //// virtual bool GetHtml(string16* html, GURL* base_url) const = 0; // virtual bool HasHtml() const = 0; //#endif }; OSExchangeData(); // Creates an OSExchangeData with the specified provider. OSExchangeData // takes ownership of the supplied provider. explicit OSExchangeData(Provider* provider); ~OSExchangeData(); // Registers the specific string as a possible format for data. static CustomFormat RegisterCustomFormat(const std::string& type); // Returns the Provider, which actually stores and manages the data. const Provider& provider() const { return *provider_; } Provider& provider() { return *provider_; } // These functions add data to the OSExchangeData object of various Chrome // types. The OSExchangeData object takes care of translating the data into // a format suitable for exchange with the OS. // NOTE WELL: Typically, a data object like this will contain only one of the // following types of data. In cases where more data is held, the // order in which these functions are called is _important_! // ---> The order types are added to an OSExchangeData object controls // the order of enumeration in our IEnumFORMATETC implementation! // This comes into play when selecting the best (most preferable) // data type for insertion into a DropTarget. void SetString(const string16& data); // A URL can have an optional title in some exchange formats. // void SetURL(const GURL& url, const string16& title); // A full path to a file. void SetFilename(const FilePath& path); // Full path to one or more files. See also SetFilenames() in Provider. void SetFilenames( const std::vector<FileInfo>& file_names); // Adds pickled data of the specified format. void SetPickledData(CustomFormat format, const Pickle& data); // These functions retrieve data of the specified type. If data exists, the // functions return and the result is in the out parameter. If the data does // not exist, the out parameter is not touched. The out parameter cannot be // NULL. bool GetString(string16* data) const; // bool GetURLAndTitle(GURL* url, string16* title) const; // Return the path of a file, if available. bool GetFilename(FilePath* path) const; bool GetFilenames( std::vector<FileInfo>* file_names) const; bool GetPickledData(CustomFormat format, Pickle* data) const; // Test whether or not data of certain types is present, without actually // returning anything. bool HasString() const; bool HasURL() const; bool HasFile() const; bool HasCustomFormat(CustomFormat format) const; // Returns true if this OSExchangeData has data for ALL the formats in // |formats| and ALL the custom formats in |custom_formats|. bool HasAllFormats(int formats, const std::set<CustomFormat>& custom_formats) const; // Returns true if this OSExchangeData has data in any of the formats in // |formats| or any custom format in |custom_formats|. bool HasAnyFormat(int formats, const std::set<CustomFormat>& custom_formats) const; #if defined(OS_WIN) // Adds the bytes of a file (CFSTR_FILECONTENTS and CFSTR_FILEDESCRIPTOR). void SetFileContents(const FilePath& filename, const std::string& file_contents); bool GetFileContents(FilePath* filename, std::string* file_contents) const; // Adds a download file with full path (CF_HDROP). void SetDownloadFileInfo(const DownloadFileInfo& download); #endif #if defined(OS_WIN) || defined(USE_AURA) // Adds a snippet of HTML. |html| is just raw html but this sets both // text/html and CF_HTML. // void SetHtml(const string16& html, const GURL& base_url); // bool GetHtml(string16* html, GURL* base_url) const; #endif private: // Creates the platform specific Provider. static Provider* CreateProvider(); // Provides the actual data. scoped_ptr<Provider> provider_; DISALLOW_COPY_AND_ASSIGN(OSExchangeData); }; } // namespace ui #endif // UI_BASE_DRAGDROP_OS_EXCHANGE_DATA_H_
{ "content_hash": "4b291022aa42670f9e16dbb1be6311b4", "timestamp": "", "source": "github", "line_count": 207, "max_line_length": 79, "avg_line_length": 38.31884057971015, "alnum_prop": 0.680786686838124, "repo_name": "JoKaWare/WTL-DUI", "id": "0106826a3dd7f0fc3e3ab603c0713d95311b6348", "size": "8633", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "ui/base/dragdrop/os_exchange_data.h", "mode": "33188", "license": "bsd-3-clause", "language": [ { "name": "Assembly", "bytes": "15757" }, { "name": "C", "bytes": "6005744" }, { "name": "C++", "bytes": "20436057" }, { "name": "Java", "bytes": "24009" }, { "name": "Objective-C", "bytes": "105435" }, { "name": "Objective-C++", "bytes": "463565" }, { "name": "Python", "bytes": "349752" }, { "name": "Shell", "bytes": "2409" }, { "name": "nesC", "bytes": "8497" } ], "symlink_target": "" }
package org.onlab.packet; /** * Representation of an Ethertype. */ public class EthType { /** * A list of known ethertypes. Adding a fully defined enum here will * associated the ethertype with a textual representation and a parsing * class. */ public enum EtherType { ARP(0x806, "arp", org.onlab.packet.ARP.deserializer()), RARP(0x8035, "rarp", org.onlab.packet.ARP.deserializer()), IPV4(0x800, "ipv4", org.onlab.packet.IPv4.deserializer()), IPV6(0x86dd, "ipv6", org.onlab.packet.IPv6.deserializer()), LLDP(0x88cc, "lldp", org.onlab.packet.LLDP.deserializer()), VLAN(0x8100, "vlan", null), BDDP(0x8942, "bddp", org.onlab.packet.LLDP.deserializer()), MPLS_UNICAST(0x8847, "mpls_unicast", org.onlab.packet.MPLS.deserializer()), MPLS_MULTICAST(0x8848, "mpls_unicast", org.onlab.packet.MPLS.deserializer()), EAPOL(0x888e, "eapol", org.onlab.packet.EAPOL.deserializer()), UNKNOWN(0, "unknown", null); private final EthType etherType; private final String type; private final Deserializer<?> deserializer; /** * Constructs a new ethertype. * * @param ethType The actual ethertype * @param type it's textual representation * @param deserializer a parser for this ethertype */ EtherType(int ethType, String type, Deserializer<?> deserializer) { this.etherType = new EthType(ethType); this.type = type; this.deserializer = deserializer; } public EthType ethType() { return etherType; } @Override public String toString() { return type; } public Deserializer<?> deserializer() { return deserializer; } public static EtherType lookup(short etherType) { for (EtherType ethType : EtherType.values()) { if (ethType.ethType().toShort() == etherType) { return ethType; } } return UNKNOWN; } } private final short etherType; /** * Builds the EthType. * * @param etherType an integer representing an ethtype */ public EthType(int etherType) { this.etherType = (short) (etherType & 0xFFFF); } /** * Builds the EthType. * * @param etherType a short representing the ethtype */ public EthType(short etherType) { this.etherType = etherType; } /** * Returns the short value for this ethtype. * * @return a short value */ public short toShort() { return etherType; } /** * Looks up the ethertype by it's numerical representation * and returns it's textual format. * * @param etherType the short value of the ethertype * @return a textual representation */ public EtherType lookup(short etherType) { for (EtherType ethType : EtherType.values()) { if (ethType.ethType().toShort() == etherType) { return ethType; } } return null; } @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } EthType ethType = (EthType) o; if (etherType != ethType.etherType) { return false; } return true; } @Override public int hashCode() { return (int) etherType; } public String toString() { EtherType ethType = lookup(this.etherType); return (ethType == null ? String.format("0x%04x", etherType) : ethType.toString()); } }
{ "content_hash": "3b75057729e20b878acefa0a974a6d91", "timestamp": "", "source": "github", "line_count": 145, "max_line_length": 85, "avg_line_length": 26.53103448275862, "alnum_prop": 0.5625162464257863, "repo_name": "planoAccess/clonedONOS", "id": "b3b79e2cdffe7711cd34b0c395c4e9bd82f17596", "size": "4456", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "utils/misc/src/main/java/org/onlab/packet/EthType.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "CSS", "bytes": "163048" }, { "name": "HTML", "bytes": "487623" }, { "name": "Java", "bytes": "16142711" }, { "name": "JavaScript", "bytes": "3060983" }, { "name": "Protocol Buffer", "bytes": "3932" }, { "name": "Shell", "bytes": "2625" } ], "symlink_target": "" }
'use strict'; exports.config = { seleniumAddress: 'http://localhost:4444/wd/hub', specs: ['spec.js'] };
{ "content_hash": "6ad21a7a5ee88fac798b07ca9f7f4080", "timestamp": "", "source": "github", "line_count": 6, "max_line_length": 50, "avg_line_length": 18.166666666666668, "alnum_prop": 0.6422018348623854, "repo_name": "cbanbury/grunt-painless-protractor", "id": "7bcf1766ddd47cf9ede8ebab1aac592110fabc21", "size": "109", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "test/fixtures/conf.js", "mode": "33188", "license": "mit", "language": [ { "name": "JavaScript", "bytes": "9020" } ], "symlink_target": "" }
using content::BrowserThread; using content::PluginService; namespace component_updater { #if defined(WIDEVINE_CDM_AVAILABLE) && defined(WIDEVINE_CDM_IS_COMPONENT) namespace { // CRX hash. The extension id is: oimompecagnajdejgnnjijobebaeigek. const uint8_t kSha2Hash[] = {0xe8, 0xce, 0xcf, 0x42, 0x06, 0xd0, 0x93, 0x49, 0x6d, 0xd9, 0x89, 0xe1, 0x41, 0x04, 0x86, 0x4a, 0x8f, 0xbd, 0x86, 0x12, 0xb9, 0x58, 0x9b, 0xfb, 0x4f, 0xbb, 0x1b, 0xa9, 0xd3, 0x85, 0x37, 0xef}; // File name of the Widevine CDM component manifest on different platforms. const char kWidevineCdmManifestName[] = "WidevineCdm"; // File name of the Widevine CDM adapter version file. The CDM adapter shares // the same version number with Chromium version. const char kCdmAdapterVersionName[] = "CdmAdapterVersion"; // Name of the Widevine CDM OS in the component manifest. const char kWidevineCdmPlatform[] = #if defined(OS_MACOSX) "mac"; #elif defined(OS_WIN) "win"; #else // OS_LINUX, etc. TODO(viettrungluu): Separate out Chrome OS and Android? "linux"; #endif // Name of the Widevine CDM architecture in the component manifest. const char kWidevineCdmArch[] = #if defined(ARCH_CPU_X86) "x86"; #elif defined(ARCH_CPU_X86_64) "x64"; #else // TODO(viettrungluu): Support an ARM check? "???"; #endif // The CDM manifest includes several custom values, all beginning with "x-cdm-". // All values are strings. // All values that are lists are delimited by commas. No trailing commas. // For example, "1,2,4". const char kCdmValueDelimiter = ','; static_assert(kCdmValueDelimiter == kCdmSupportedCodecsValueDelimiter, "cdm delimiters must match"); // The following entries are required. // Interface versions are lists of integers (e.g. "1" or "1,2,4"). // These are checked in this file before registering the CDM. // All match the interface versions from content_decryption_module.h that the // CDM supports. // Matches CDM_MODULE_VERSION. const char kCdmModuleVersionsName[] = "x-cdm-module-versions"; // Matches supported ContentDecryptionModule_* version(s). const char kCdmInterfaceVersionsName[] = "x-cdm-interface-versions"; // Matches supported Host_* version(s). const char kCdmHostVersionsName[] = "x-cdm-host-versions"; // The codecs list is a list of simple codec names (e.g. "vp8,vorbis"). // The list is passed to other parts of Chrome. const char kCdmCodecsListName[] = "x-cdm-codecs"; // Widevine CDM is packaged as a multi-CRX. Widevine CDM binaries are located in // _platform_specific/<platform_arch> folder in the package. This function // returns the platform-specific subdirectory that is part of that multi-CRX. base::FilePath GetPlatformDirectory(const base::FilePath& base_path) { std::string platform_arch = kWidevineCdmPlatform; platform_arch += '_'; platform_arch += kWidevineCdmArch; return base_path.AppendASCII("_platform_specific").AppendASCII(platform_arch); } bool MakeWidevineCdmPluginInfo( const base::Version& version, const base::FilePath& path, const std::vector<base::string16>& additional_param_names, const std::vector<base::string16>& additional_param_values, content::PepperPluginInfo* plugin_info) { if (!version.IsValid() || version.components().size() != static_cast<size_t>(kWidevineCdmVersionNumComponents)) { return false; } plugin_info->is_internal = false; // Widevine CDM must run out of process. plugin_info->is_out_of_process = true; plugin_info->path = path; plugin_info->name = kWidevineCdmDisplayName; plugin_info->description = kWidevineCdmDescription + std::string(" (version: ") + version.GetString() + ")"; plugin_info->version = version.GetString(); content::WebPluginMimeType widevine_cdm_mime_type( kWidevineCdmPluginMimeType, kWidevineCdmPluginExtension, kWidevineCdmPluginMimeTypeDescription); widevine_cdm_mime_type.additional_param_names = additional_param_names; widevine_cdm_mime_type.additional_param_values = additional_param_values; plugin_info->mime_types.push_back(widevine_cdm_mime_type); plugin_info->permissions = kWidevineCdmPluginPermissions; return true; } typedef bool (*VersionCheckFunc)(int version); bool CheckForCompatibleVersion(const base::DictionaryValue& manifest, const std::string version_name, VersionCheckFunc version_check_func) { std::string versions_string; if (!manifest.GetString(version_name, &versions_string)) { DLOG(WARNING) << "Widevine CDM component manifest missing " << version_name; return false; } DLOG_IF(WARNING, versions_string.empty()) << "Widevine CDM component manifest has empty " << version_name; for (const base::StringPiece& ver_str : base::SplitStringPiece( versions_string, std::string(1, kCdmValueDelimiter), base::TRIM_WHITESPACE, base::SPLIT_WANT_ALL)) { int version = 0; if (base::StringToInt(ver_str, &version)) if (version_check_func(version)) return true; } DLOG(WARNING) << "Widevine CDM component manifest has no supported " << version_name << " in '" << versions_string << "'"; return false; } // Returns whether the CDM's API versions, as specified in the manifest, are // compatible with this Chrome binary. // Checks the module API, CDM interface API, and Host API. // This should never fail except in rare cases where the component has not been // updated recently or the user downgrades Chrome. bool IsCompatibleWithChrome(const base::DictionaryValue& manifest) { return CheckForCompatibleVersion(manifest, kCdmModuleVersionsName, media::IsSupportedCdmModuleVersion) && CheckForCompatibleVersion(manifest, kCdmInterfaceVersionsName, media::IsSupportedCdmInterfaceVersion) && CheckForCompatibleVersion(manifest, kCdmHostVersionsName, media::IsSupportedCdmHostVersion); } void GetAdditionalParams(const base::DictionaryValue& manifest, std::vector<base::string16>* additional_param_names, std::vector<base::string16>* additional_param_values) { base::string16 codecs; if (manifest.GetString(kCdmCodecsListName, &codecs)) { DLOG_IF(WARNING, codecs.empty()) << "Widevine CDM component manifest has empty codecs list"; additional_param_names->push_back( base::ASCIIToUTF16(kCdmSupportedCodecsParamName)); additional_param_values->push_back(codecs); } else { DLOG(WARNING) << "Widevine CDM component manifest is missing codecs"; } } void RegisterWidevineCdmWithChrome(const base::Version& cdm_version, const base::FilePath& adapter_install_path, scoped_ptr<base::DictionaryValue> manifest) { DCHECK_CURRENTLY_ON(BrowserThread::UI); std::vector<base::string16> additional_param_names; std::vector<base::string16> additional_param_values; GetAdditionalParams( *manifest, &additional_param_names, &additional_param_values); content::PepperPluginInfo plugin_info; if (!MakeWidevineCdmPluginInfo(cdm_version, adapter_install_path, additional_param_names, additional_param_values, &plugin_info)) { return; } // true = Add to beginning of list to override any existing registrations. PluginService::GetInstance()->RegisterInternalPlugin( plugin_info.ToWebPluginInfo(), true); // Tell the browser to refresh the plugin list. Then tell all renderers to // update their plugin list caches. PluginService::GetInstance()->RefreshPlugins(); PluginService::GetInstance()->PurgePluginListCache(NULL, false); } } // namespace class WidevineCdmComponentInstallerTraits : public ComponentInstallerTraits { public: WidevineCdmComponentInstallerTraits(); ~WidevineCdmComponentInstallerTraits() override {} private: // The following methods override ComponentInstallerTraits. bool CanAutoUpdate() const override; bool OnCustomInstall(const base::DictionaryValue& manifest, const base::FilePath& install_dir) override; bool VerifyInstallation( const base::DictionaryValue& manifest, const base::FilePath& install_dir) const override; void ComponentReady( const base::Version& version, const base::FilePath& path, scoped_ptr<base::DictionaryValue> manifest) override; base::FilePath GetBaseDirectory() const override; void GetHash(std::vector<uint8_t>* hash) const override; std::string GetName() const override; // Checks and updates CDM adapter if necessary to make sure the latest CDM // adapter is always used. // Note: The component is ready when CDM is present, but the CDM won't be // registered until the adapter is copied by this function (see // VerifyInstallation). void UpdateCdmAdapter(const base::Version& cdm_version, const base::FilePath& cdm_install_dir, scoped_ptr<base::DictionaryValue> manifest); DISALLOW_COPY_AND_ASSIGN(WidevineCdmComponentInstallerTraits); }; WidevineCdmComponentInstallerTraits::WidevineCdmComponentInstallerTraits() { } bool WidevineCdmComponentInstallerTraits::CanAutoUpdate() const { return true; } bool WidevineCdmComponentInstallerTraits::OnCustomInstall( const base::DictionaryValue& manifest, const base::FilePath& install_dir) { return true; } // Once the CDM is ready, check the CDM adapter. void WidevineCdmComponentInstallerTraits::ComponentReady( const base::Version& version, const base::FilePath& path, scoped_ptr<base::DictionaryValue> manifest) { if (!IsCompatibleWithChrome(*manifest)) { DLOG(WARNING) << "Installed Widevine CDM component is incompatible."; return; } BrowserThread::PostBlockingPoolTask( FROM_HERE, base::Bind(&WidevineCdmComponentInstallerTraits::UpdateCdmAdapter, base::Unretained(this), version, path, base::Passed(&manifest))); } bool WidevineCdmComponentInstallerTraits::VerifyInstallation( const base::DictionaryValue& manifest, const base::FilePath& install_dir) const { return IsCompatibleWithChrome(manifest) && base::PathExists(GetPlatformDirectory(install_dir) .AppendASCII(kWidevineCdmFileName)); } // The base directory on Windows looks like: // <profile>\AppData\Local\Google\Chrome\User Data\WidevineCdm\. base::FilePath WidevineCdmComponentInstallerTraits::GetBaseDirectory() const { base::FilePath result; PathService::Get(chrome::DIR_COMPONENT_WIDEVINE_CDM, &result); return result; } void WidevineCdmComponentInstallerTraits::GetHash( std::vector<uint8_t>* hash) const { hash->assign(kSha2Hash, kSha2Hash + arraysize(kSha2Hash)); } std::string WidevineCdmComponentInstallerTraits::GetName() const { return kWidevineCdmManifestName; } void WidevineCdmComponentInstallerTraits::UpdateCdmAdapter( const base::Version& cdm_version, const base::FilePath& cdm_install_dir, scoped_ptr<base::DictionaryValue> manifest) { const base::FilePath adapter_version_path = GetPlatformDirectory(cdm_install_dir).AppendASCII(kCdmAdapterVersionName); const base::FilePath adapter_install_path = GetPlatformDirectory(cdm_install_dir) .AppendASCII(kWidevineCdmAdapterFileName); const std::string chrome_version = chrome::VersionInfo().Version(); DCHECK(!chrome_version.empty()); std::string adapter_version; if (!base::ReadFileToString(adapter_version_path, &adapter_version) || adapter_version != chrome_version || !base::PathExists(adapter_install_path)) { int bytes_written = base::WriteFile( adapter_version_path, chrome_version.data(), chrome_version.size()); if (bytes_written < 0 || static_cast<size_t>(bytes_written) != chrome_version.size()) { DLOG(WARNING) << "Failed to write Widevine CDM adapter version file."; // Ignore version file writing failure and try to copy the CDM adapter. } base::FilePath adapter_source_path; PathService::Get(chrome::FILE_WIDEVINE_CDM_ADAPTER, &adapter_source_path); if (!base::CopyFile(adapter_source_path, adapter_install_path)) { DLOG(WARNING) << "Failed to copy Widevine CDM adapter."; return; } } BrowserThread::PostTask(content::BrowserThread::UI, FROM_HERE, base::Bind(&RegisterWidevineCdmWithChrome, cdm_version, adapter_install_path, base::Passed(&manifest))); } #endif // defined(WIDEVINE_CDM_AVAILABLE) && defined(WIDEVINE_CDM_IS_COMPONENT) void RegisterWidevineCdmComponent(ComponentUpdateService* cus) { #if defined(WIDEVINE_CDM_AVAILABLE) && defined(WIDEVINE_CDM_IS_COMPONENT) base::FilePath adapter_source_path; PathService::Get(chrome::FILE_WIDEVINE_CDM_ADAPTER, &adapter_source_path); if (!base::PathExists(adapter_source_path)) return; scoped_ptr<ComponentInstallerTraits> traits( new WidevineCdmComponentInstallerTraits); // |cus| will take ownership of |installer| during installer->Register(cus). DefaultComponentInstaller* installer = new DefaultComponentInstaller(traits.Pass()); installer->Register(cus, base::Closure()); #endif // defined(WIDEVINE_CDM_AVAILABLE) && defined(WIDEVINE_CDM_IS_COMPONENT) } } // namespace component_updater
{ "content_hash": "be676069b1e0a8ddee883dd280c0b224", "timestamp": "", "source": "github", "line_count": 342, "max_line_length": 80, "avg_line_length": 40.812865497076025, "alnum_prop": 0.6869895400487176, "repo_name": "lihui7115/ChromiumGStreamerBackend", "id": "3552617e1bd3a06722b50ffecc5084ab424f857d", "size": "15371", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "chrome/browser/component_updater/widevine_cdm_component_installer.cc", "mode": "33188", "license": "bsd-3-clause", "language": [ { "name": "AppleScript", "bytes": "6973" }, { "name": "Arduino", "bytes": "464" }, { "name": "Assembly", "bytes": "37073" }, { "name": "Batchfile", "bytes": "8451" }, { "name": "C", "bytes": "9508834" }, { "name": "C++", "bytes": "242598549" }, { "name": "CSS", "bytes": "943747" }, { "name": "DM", "bytes": "60" }, { "name": "Groff", "bytes": "2494" }, { "name": "HTML", "bytes": "27281878" }, { "name": "Java", "bytes": "14561064" }, { "name": "JavaScript", "bytes": "20540839" }, { "name": "Makefile", "bytes": "70864" }, { "name": "Objective-C", "bytes": "1745880" }, { "name": "Objective-C++", "bytes": "10008668" }, { "name": "PHP", "bytes": "97817" }, { "name": "PLpgSQL", "bytes": "178732" }, { "name": "Perl", "bytes": "63937" }, { "name": "Protocol Buffer", "bytes": "482954" }, { "name": "Python", "bytes": "8626890" }, { "name": "Shell", "bytes": "481888" }, { "name": "Standard ML", "bytes": "5106" }, { "name": "XSLT", "bytes": "418" }, { "name": "nesC", "bytes": "18347" } ], "symlink_target": "" }
<?php namespace Github\Tests; use Github\Client; use Github\Exception\InvalidArgumentException; use Github\Exception\BadMethodCallException; class ClientTest extends \PHPUnit_Framework_TestCase { /** * @test */ public function shouldNotHaveToPassHttpClientToConstructor() { $client = new Client(); $this->assertInstanceOf('Github\HttpClient\HttpClient', $client->getHttpClient()); } /** * @test */ public function shouldPassHttpClientInterfaceToConstructor() { $client = new Client($this->getHttpClientMock()); $this->assertInstanceOf('Github\HttpClient\HttpClientInterface', $client->getHttpClient()); } /** * @test * @dataProvider getAuthenticationFullData */ public function shouldAuthenticateUsingAllGivenParameters($login, $password, $method) { $httpClient = $this->getHttpClientMock(); $httpClient->expects($this->once()) ->method('authenticate') ->with($login, $password, $method); $client = new Client($httpClient); $client->authenticate($login, $password, $method); } public function getAuthenticationFullData() { return array( array('login', 'password', Client::AUTH_HTTP_PASSWORD), array('token', null, Client::AUTH_HTTP_TOKEN), array('token', null, Client::AUTH_URL_TOKEN), array('client_id', 'client_secret', Client::AUTH_URL_CLIENT_ID), ); } /** * @test * @dataProvider getAuthenticationPartialData */ public function shouldAuthenticateUsingGivenParameters($token, $method) { $httpClient = $this->getHttpClientMock(); $httpClient->expects($this->once()) ->method('authenticate') ->with($token, null, $method); $client = new Client($httpClient); $client->authenticate($token, $method); } public function getAuthenticationPartialData() { return array( array('token', Client::AUTH_HTTP_TOKEN), array('token', Client::AUTH_URL_TOKEN), ); } /** * @test * @expectedException InvalidArgumentException */ public function shouldThrowExceptionWhenAuthenticatingWithoutMethodSet() { $httpClient = $this->getHttpClientMock(array('addListener')); $client = new Client($httpClient); $client->authenticate('login', null, null); } /** * @test */ public function shouldClearHeadersLazy() { $httpClient = $this->getHttpClientMock(array('clearHeaders')); $httpClient->expects($this->once())->method('clearHeaders'); $client = new Client($httpClient); $client->clearHeaders(); } /** * @test */ public function shouldSetHeadersLaizly() { $headers = array('header1', 'header2'); $httpClient = $this->getHttpClientMock(); $httpClient->expects($this->once())->method('setHeaders')->with($headers); $client = new Client($httpClient); $client->setHeaders($headers); } /** * @test * @dataProvider getApiClassesProvider */ public function shouldGetApiInstance($apiName, $class) { $client = new Client(); $this->assertInstanceOf($class, $client->api($apiName)); } /** * @test * @dataProvider getApiClassesProvider */ public function shouldGetMagicApiInstance($apiName, $class) { $client = new Client(); $this->assertInstanceOf($class, $client->$apiName()); } /** * @test * @expectedException InvalidArgumentException */ public function shouldNotGetApiInstance() { $client = new Client(); $client->api('do_not_exist'); } /** * @test * @expectedException BadMethodCallException */ public function shouldNotGetMagicApiInstance() { $client = new Client(); $client->doNotExist(); } public function getApiClassesProvider() { return array( array('user', 'Github\Api\User'), array('users', 'Github\Api\User'), array('me', 'Github\Api\CurrentUser'), array('current_user', 'Github\Api\CurrentUser'), array('currentUser', 'Github\Api\CurrentUser'), array('git', 'Github\Api\GitData'), array('git_data', 'Github\Api\GitData'), array('gitData', 'Github\Api\GitData'), array('gist', 'Github\Api\Gists'), array('gists', 'Github\Api\Gists'), array('issue', 'Github\Api\Issue'), array('issues', 'Github\Api\Issue'), array('markdown', 'Github\Api\Markdown'), array('organization', 'Github\Api\Organization'), array('organizations', 'Github\Api\Organization'), array('repo', 'Github\Api\Repo'), array('repos', 'Github\Api\Repo'), array('repository', 'Github\Api\Repo'), array('repositories', 'Github\Api\Repo'), array('pr', 'Github\Api\PullRequest'), array('pullRequest', 'Github\Api\PullRequest'), array('pull_request', 'Github\Api\PullRequest'), array('pullRequests', 'Github\Api\PullRequest'), array('pull_requests', 'Github\Api\PullRequest'), array('authorization', 'Github\Api\Authorizations'), array('authorizations', 'Github\Api\Authorizations'), array('meta', 'Github\Api\Meta') ); } public function getHttpClientMock(array $methods = array()) { $methods = array_merge( array('get', 'post', 'patch', 'put', 'delete', 'request', 'setOption', 'setHeaders', 'authenticate'), $methods ); return $this->getMock('Github\HttpClient\HttpClientInterface', $methods); } }
{ "content_hash": "0e2236a74391a13de661f76ee68e6348", "timestamp": "", "source": "github", "line_count": 211, "max_line_length": 113, "avg_line_length": 28.14691943127962, "alnum_prop": 0.5830947971038896, "repo_name": "Nek-/php-github-api", "id": "04b3a7103979dfe581dd483663a39a4fc31ccff1", "size": "5939", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "test/Github/Tests/ClientTest.php", "mode": "33188", "license": "mit", "language": [ { "name": "PHP", "bytes": "382541" } ], "symlink_target": "" }
<?php namespace AppBundle\ControlRoomLog; use Sensio\Bundle\FrameworkExtraBundle\Configuration\Route; use Symfony\Bundle\FrameworkBundle\Controller\Controller; use Symfony\Component\HttpFoundation\Request; use Doctrine\ORM\EntityManager; use AppBundle\Form\Type\LoginForm; class SecurityController extends Controller { /** * @Route("/login", name="login") */ public function loginAction(Request $request) { $authenticationUtils = $this->get('security.authentication_utils'); // get the login error if there is one $error = $authenticationUtils->getLastAuthenticationError(); // last username entered by the user $lastUsername = $authenticationUtils->getLastUsername(); $form = $this->createForm(LoginForm::class, [ '_username' => $lastUsername, ]); return $this->render( 'login.html.twig', array( // last username entered by the user 'form' => $form->createView(), 'error' => $error ) ); } /** * @Route("/login_check", name="security_login_check") */ public function loginCheckAction() { // will never be executed } /** * @Route("/audit", name="audit") */ public function AuditLogAction() { $em = $this->getDoctrine()->getManager(); $auditLogs = $em->getRepository('AppBundle\Entity\AuditLog')->findAll(); if (!$auditLogs) { $auditLogs = null; } return $this->render('auditLogs.html.twig', array('auditLogs' => $auditLogs)); } }
{ "content_hash": "d22e222caedaa1ae7090efdf01483f0f", "timestamp": "", "source": "github", "line_count": 66, "max_line_length": 86, "avg_line_length": 25.954545454545453, "alnum_prop": 0.5685931115002919, "repo_name": "bartleyni/eventcontrol", "id": "123bcdeb5c3dcd8b88282aa1c08c5f96f7936343", "size": "1713", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/AppBundle/ControlRoomLog/SecurityController.php", "mode": "33188", "license": "mit", "language": [ { "name": "HTML", "bytes": "245404" }, { "name": "JavaScript", "bytes": "3054" }, { "name": "PHP", "bytes": "465823" } ], "symlink_target": "" }
using Gherkin.Util; using System; using System.Collections.Generic; using System.Diagnostics; using System.Linq; using System.Text; using System.Threading.Tasks; namespace Gherkin.Util.Geometric { /// <summary> /// Defines the key of a polyline /// </summary> class KeyInfo { public int Index { get; set; } // index of the key public double Dist2 { get; set; } // squared distance of the key to a segment public KeyInfo(int index = 0, double dist2 = 0) { Index = index; Dist2 = dist2; } } /// <summary> /// Defines a sub polyline /// </summary> class SubPoly { public int First { get; set; } // index of the first point public int Last { get; set; } // index of the last point public SubPoly(int first = 0, int last = 0) { First = first; Last = last; } }; /// <summary> /// Defines a sub polyline including its key /// </summary> class SubPolyAlt : IComparable { public int First { get; set; } // index of the first point public int Last { get; set; } // index of the last point public KeyInfo KeyInfo { get; set; } // key of this sub poly public SubPolyAlt(int first = 0, int last = 0) { First = first; Last = last; } public int CompareTo(object obj) { SubPolyAlt other = obj as SubPolyAlt; if (other == null) return -1; if (KeyInfo.Dist2 < other.KeyInfo.Dist2) return -1; else if (KeyInfo.Dist2 < other.KeyInfo.Dist2) return 1; else return 0; } } /// <summary> /// Simplification of a 2D-polyline /// More information: /// https://github.com/imshz/simplify-net /// http://psimpl.sourceforge.net/index.html /// http://psimpl.sf.net /// https://www.codeproject.com/articles/114797/polyline-simplification /// </summary> public class PolylineSimplication { /// <summary> /// Simplification by using Douglas-Peucker algorithm /// </summary> /// <param name="points"></param> /// <param name="tolerance"></param> /// <returns></returns> public static List<GPoint> SimplifyByDouglasPeucker(GPoint[] points, double tolerance) { if (points.Length < 3) return points.ToList(); double tol2 = tolerance * tolerance; // squared distance tolerance int pointCount = points.Length; bool[] keys = new bool[pointCount]; keys[0] = true; // the first point is always a key keys[pointCount - 1] = true; // the last point is always a key Stack<SubPoly> stack = new Stack<SubPoly>(); // LIFO job-queue containing sub-polylines SubPoly subPoly = new SubPoly(0, pointCount - 1); stack.Push(subPoly); // add complete poly while (stack.Count > 0) { subPoly = stack.Pop(); // take a sub poly and remove it KeyInfo keyInfo = FindKey(points, subPoly.First, subPoly.Last); if ((keyInfo.Index > 0) && (tol2 < keyInfo.Dist2)) { // store the key if valid keys[keyInfo.Index] = true; // split the polyline at the key and recurse stack.Push(new SubPoly(keyInfo.Index, subPoly.Last)); stack.Push(new SubPoly(subPoly.First, keyInfo.Index)); } } return ExtractPoints(points, keys); } /// <summary> /// Simplification by using Douglas-Peucker algorithm /// </summary> /// <param name="points"></param> /// <param name="tolerance"></param> /// <returns></returns> public static List<GPoint> SimplifyByDouglasPeuckerAnother(GPoint[] points, double tolerance) { if (points == null || points.Length == 0) return new List<GPoint>(); double sqTolerance = tolerance * tolerance; var len = points.Length; var markers = new int?[len]; int? first = 0; int? last = len - 1; int? index = 0; var stack = new List<int?>(); var newPoints = new List<GPoint>(); markers[first.Value] = markers[last.Value] = 1; while (last != null) { var maxSqDist = 0.0d; for (int? i = first + 1; i < last; i++) { var sqDist = points[i.Value].SquareDistance2Segment(points[first.Value], points[last.Value]); if (sqDist > maxSqDist) { index = i; maxSqDist = sqDist; } } if (maxSqDist > sqTolerance) { markers[index.Value] = 1; stack.AddRange(new[] { first, index, index, last }); } if (stack.Count > 0) { last = stack[stack.Count - 1]; stack.RemoveAt(stack.Count - 1); } else last = null; if (stack.Count > 0) { first = stack[stack.Count - 1]; stack.RemoveAt(stack.Count - 1); } else first = null; } for (var i = 0; i < len; i++) { if (markers[i] != null) newPoints.Add(points[i]); } return newPoints; } /// <summary> /// Simplification by using Douglas-Peucker variant algorithm /// </summary> /// <param name="points">input points</param> /// <param name="maxPoints">the maximum number of points of the simplified polyline</param> /// <returns>simplified polyline</returns> public static List<GPoint> SimplifyByDouglasPeuckerN(GPoint[] points, int maxPoints) { int pointCount = points.Length; if (maxPoints >= pointCount) { return points.ToList(); } if (maxPoints == 2) { return new List<GPoint> { points.First(), points.Last() }; } bool[] keys = SimplifyByDouglasPeuckerNHelp(points, maxPoints); return ExtractPoints(points, keys); } /// <summary> /// Simplification by using Douglas-Peucker variant algorithm /// </summary> /// <param name="points">input points</param> /// <param name="maxPoints">the maximum number of points of the simplified polyline</param> /// <returns>simplified polyline</returns> private static bool[] SimplifyByDouglasPeuckerNHelp(GPoint[] points, int maxPoints) { int pointCount = points.Length; bool[] keys = new bool[pointCount]; keys[0] = true; // the first point is always a key keys[pointCount - 1] = true; // the last point is always a key int keyCount = 2; PriorityQueue<SubPolyAlt> queue = new PriorityQueue<SubPolyAlt>(); SubPolyAlt subPoly = new SubPolyAlt(0, pointCount - 1); subPoly.KeyInfo = FindKey(points, subPoly.First, subPoly.Last); queue.Push(subPoly); // add complete poly while (!queue.IsEmpty()) { subPoly = queue.Top(); // take a sub poly queue.Pop(); // store the key keys[subPoly.KeyInfo.Index] = true; // check point count tolerance keyCount++; if (keyCount == maxPoints) { break; } // split the polyline at the key and recurse SubPolyAlt left = new SubPolyAlt(subPoly.First, subPoly.KeyInfo.Index); left.KeyInfo = FindKey(points, left.First, left.Last); if (left.KeyInfo.Index > 0) { queue.Push(left); } SubPolyAlt right = new SubPolyAlt(subPoly.KeyInfo.Index, subPoly.Last); right.KeyInfo = FindKey(points, right.First, right.Last); if (right.KeyInfo.Index > 0) { queue.Push(right); } } return keys; } private static List<GPoint> ExtractPoints(GPoint[] points, bool[] keys) { List<GPoint> newPoints = new List<GPoint>(); for (int i = 0; i < keys.Length; i++) { if (keys[i]) newPoints.Add(points[i]); } return newPoints; } /// <summary> /// Finds the key for the given sub polyline. /// Finds the point in the range [first, last] that is furthest away from the /// segment (first, last). This point is called the key. /// </summary> /// <param name="points">polyline points</param> /// <param name="first">the first polyline point</param> /// <param name="last">the last polyline point</param> /// <returns>the index of the key and its distance, or last when a key could not be found</returns> private static KeyInfo FindKey(GPoint[] points, int first, int last) { KeyInfo keyInfo = new KeyInfo(); for (int current = first + 1; current < last; current++) { double sqDist = points[current].SquareDistance2Segment(points[first], points[last]); if (sqDist < keyInfo.Dist2) { continue; } // update maximum squared distance and the point it belongs to keyInfo.Index = current; keyInfo.Dist2 = sqDist; } return keyInfo; } /// <summary> /// Simplifying by using point weight, which is curve distance between points. /// </summary> /// <param name="points"></param> /// <param name="weightTolerance">minimum distance difference of two points</param> /// <returns></returns> public static List<GPoint> SimplifyByWeight(GPoint[] points, double weightTolerance) { if (points == null || points.Length == 0) return new List<GPoint>(); List<GPoint> newPoints = new List<GPoint>(); newPoints.Add(points[0]); GPoint keyPoint = points[0]; for (int i = 1; i < points.Length - 1; i++) { if (points[i].W - keyPoint.W > weightTolerance) { newPoints.Add(points[i]); keyPoint = points[i]; } } newPoints.Add(points.Last()); return newPoints; } /// <summary> /// Simplifying by using slope direction changing. /// </summary> /// <param name="points"></param> /// <param name="yTolerance">y value is considered zero within the tolerance </param> /// <returns></returns> public static List<GPoint> SimplifyHeadingChange(GPoint[] points, double yTolerance) { if (points.Length < 2) { return points.ToList(); } List<GPoint> newPoints = new List<GPoint>(); newPoints.Add(points[0]); for (int i = 1; i < points.Length - 1; i++) { int predir = Direction(points[i - 1], points[i], yTolerance); int nextdir = Direction(points[i], points[i + 1], yTolerance); if (predir != nextdir) { newPoints.Add(points[i]); } } newPoints.Add(points.Last()); return newPoints; } private static int Direction(GPoint from, GPoint to, double yTolerance) { double yDiff = to.Y - from.Y; return (Math.Abs(yDiff) < yTolerance) ? 0 : Math.Sign(yDiff); } /// <summary> /// Remove points where |p.Y| < yTolerance /// </summary> /// <param name="points">Points original list of points</param> /// <param name="yTolerance">y value tolerance</param> /// <returns></returns> public static List<GPoint> SimplifyByYTolerance(GPoint[] points, double yTolerance) { List<GPoint> newPoints = new List<GPoint>(); if ((points == null) || (points.Length == 0)) return newPoints; for (int i = 0; i < points.Length; i++) { if (Math.Abs(points[i].Y) > yTolerance) { newPoints.Add(points[i]); } } return newPoints; } /// <summary> /// 一定区間の抽出 /// </summary> /// <param name="points">Points original list of points</param> /// <param name="yTolerance">y value tolerance</param> /// <returns></returns> public static List<GPoint> ExtractSameRanges(GPoint[] points, double yTolerance) { List<GPoint> newPoints = new List<GPoint>(); if (points == null) return newPoints; int index = 0; while (index < points.Length - 1) { if (Math.Abs(points[index + 1].Y - points[index].Y) <= yTolerance) { newPoints.Add(points[index]); newPoints.Add(points[index + 1]); index += 2; } else { index++; } } return newPoints; } /// <summary> /// Simplifiy points so that the result is not more than maxPoints + 2. /// Remark: First and last points will be kept always /// </summary> /// <param name="points">input points</param> /// <param name="maxPoints">maxium points of remaining</param> /// <returns></returns> public static List<GPoint> SimplifyPointsN(GPoint[] points, int maxPoints) { List<GPoint> newPoints = new List<GPoint>(); int TOTAL = points.Length; if (TOTAL <= maxPoints) { newPoints.AddRange(points); return newPoints; } float interval = TOTAL / (float)maxPoints; int lastIndex = -1; for (float i = 0; i < TOTAL - 1; i += interval) { int index = (int)i; if (index != lastIndex) { newPoints.Add(points[index]); lastIndex = index; } } newPoints.Add(points.Last()); return newPoints; } /// <summary> /// Simplification by Radial Distance /// </summary> /// <param name="points"></param> /// <param name="tolerance"></param> /// <returns></returns> public static List<GPoint> SimplifyByRadialDistance(GPoint[] points, double tolerance) { double sqTolerance = tolerance * tolerance; var prevPoint = points[0]; var newPoints = new List<GPoint> { prevPoint }; GPoint point = null; for (var i = 1; i < points.Length; i++) { point = points[i]; if (point.SquareDistance(prevPoint) > sqTolerance) { newPoints.Add(point); prevPoint = point; } } if (point != null && !prevPoint.Equals(point)) newPoints.Add(point); return newPoints; } } }
{ "content_hash": "aa440747aaea87f5c086db9d82259fb7", "timestamp": "", "source": "github", "line_count": 473, "max_line_length": 113, "avg_line_length": 34.64482029598309, "alnum_prop": 0.4887410752425703, "repo_name": "bzquan/GherkinEditor", "id": "46ce7d7619757f7c46929064e0835e595514978b", "size": "16403", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "GherkinEditor/GherkinEditor/Util/Geometric/PolylineSimplication.cs", "mode": "33188", "license": "mit", "language": [ { "name": "Batchfile", "bytes": "120" }, { "name": "C#", "bytes": "12232320" }, { "name": "C++", "bytes": "206263" }, { "name": "Gherkin", "bytes": "1417" }, { "name": "HTML", "bytes": "663287" }, { "name": "PowerShell", "bytes": "124" }, { "name": "Smalltalk", "bytes": "211316" } ], "symlink_target": "" }
<?php namespace Tekkl\Bundle\AppBundle\Helper\Spreadsheet; use PhpOffice\PhpSpreadsheet; class Spreadsheet implements SpreadsheetInterface { protected $header = null; protected $rows = []; protected $worksheetNumber = 0; protected $skipValidation = false; protected $inputEncoding = 'UTF-8'; protected $outputEncoding = 'UTF-8'; protected $has_header = false; protected $headerStyle = [ 'bold' => false, 'italic' => false ]; protected $autoFilter = false; protected $fixedRows = 0; protected $fixedCols = 0; /** * {@inheritdoc} */ public function writeToFile($filePath, $includeHeader = true){ throw new \RuntimeException('Please use one of the concrete Spreadsheet implementations to export to a file'); } /** * {@inheritdoc} */ public function getSpreadsheetFromFile($filePath){ $reader = PhpSpreadsheet\IOFactory::createReaderForFile($filePath); $reader->setSheetIndex($this->worksheetNumber); $spreadsheet = $reader->load($filePath); return $spreadsheet; } /** * {@inheritdoc} */ public function getWorksheetFromFile($filePath, $worksheetNumber = 0){ $spreadsheet = $this->getSpreadsheetFromFile($filePath); $worksheet = $spreadsheet->getSheet($worksheetNumber); return $worksheet; } /** * {@inheritdoc} */ public function addRowsFromFile($filePath, $hasHeader = false){ $worksheet = $this->getWorksheetFromFile($filePath, $this->worksheetNumber); foreach ($worksheet->getRowIterator() as $row) { $newRow = []; $cellIterator = $row->getCellIterator(); $cellIterator->setIterateOnlyExistingCells(FALSE); foreach ($cellIterator as $cell) { $newRow[] = $cell->getValue(); } $this->addRow($newRow); } if($hasHeader){ $this->useFirstRowAsHeader(); } } /** * Reset the data hold in this object */ public function reset($includeHeader = true){ $this->rows = []; if($includeHeader){ $this->header = null; $this->has_header = false; } } /** * {@inheritdoc} */ public function skipValidation($bool = true){ $this->skipValidation = $bool; } /** * {@inheritdoc} */ public function useFirstRowAsHeader(){ if(!is_array($this->rows) || count($this->rows) == 0){ throw new \Exception('No Data for Header loaded. Import CSV Data first', 500); } $this->header = array_shift($this->rows); $this->has_header = true; } /** * {@inheritdoc} */ public function setWorksheetNumber($number){ $this->worksheetNumber = $number; } /** * {@inheritdoc} */ public function setHeader($header){ if (!is_array($header)) { throw new \Exception('Passed Argument must be an Array', 500); } $this->validateRow($header, true); $schema = $this->getRowSchema($header); foreach($this->rows as &$row){ $row = $this->changeRowIndices($row, $schema); } $this->header = $header; $this->has_header = true; } /** * {@inheritdoc} */ public function getRows($ignoreHeader = true, $useHeaderValuesAsIndices = false){ $rows = $this->rows; if(!$ignoreHeader && !empty($this->header)){ $rows = array_merge([$this->header], $rows); } if($useHeaderValuesAsIndices){ if(empty($this->header)){ throw new \RuntimeException('No header defined to provide Index Values'); } $newRows = []; foreach($rows as $row){ $newRow = []; foreach($row as $index => $col){ $newRow[$this->header[$index]] = $col; } $newRows[] = $newRow; } $rows = $newRows; } return $rows; } /** * {@inheritdoc} */ public function removeFirstRow(){ array_shift($this->rows); } /** * {@inheritdoc} */ public function addRows($rows){ if (!is_array($rows)) { throw new \Exception('Passed Argument must be an Array', 500); } foreach ($rows as $row) { $this->addRow($row); } } /** * {@inheritdoc} */ public function addRow($row){ if (!is_array($row)) { throw new \Exception('Passed Argument must be an Array', 500); } $this->validateRow($row); $this->rows[] = $row; } public function getList($ignoreHeader = true){ $list = []; $rows = $this->getRows($ignoreHeader); foreach($rows as $row){ $list[] = array_values($row); } return $list; } /** * {@inheritdoc} */ public function getAssocList($ignoreHeader = true, $useHeaderValuesAsIndex = true){ $assocList = []; if($useHeaderValuesAsIndex){ foreach($this->rows as $row){ $assoc = []; foreach($row as $i => $column){ if($useHeaderValues){ } $assoc[$this->header[$i]] = $column; } $assocList[] = $assoc; } if(!$ignoreHeader && isset($this->header)){ $header = []; foreach($this->header as $column){ $header[$column] = $column; } $assocList = array_merge([$header], $assocList); } }else{ $assocList = $this->rows; if(!$ignoreHeader && isset($this->header)){ $assocList = array_merge([$this->header], $assocList); } } return $assocList; } /** * Returns a PhpOffice Spreadsheet from data * @param array $rows * @return $spreadsheet */ public function createSpreadsheetFromRows($rows){ $spreadsheet = $this->createEmptySpreadsheet(); $sheet = $spreadsheet->getActiveSheet(); $currentRow = 1; foreach($rows as $rowData){ $columnLetter = 'A'; $currentColumn = 1; foreach ($rowData as $rowDatum) { if ($rowDatum != '') { // Convert encoding if necessary if ($this->outputEncoding !== 'UTF-8') { $rowDatum = StringHelper::convertEncoding($rowDatum, 'UTF-8', $this->outputEncoding); } $cell = $sheet->getCell($columnLetter . $currentRow); $cell->setValue($rowDatum); if($currentRow == 1 && $this->has_header){ if($this->headerStyle['bold']){ $cell->getStyle()->getFont()->setBold(true); } if($this->headerStyle['italic']){ $cell->getStyle()->getFont()->setItalic(true); } } } if(($currentColumn - 1) == $this->fixedCols && ($currentRow - 1) == $this->fixedRows){ $sheet->freezePane($columnLetter . $currentRow); } ++$columnLetter; ++$currentColumn; } ++$currentRow; } if($this->autoFilter){ $sheet->setAutoFilter($sheet->calculateWorksheetDimension()); } return $spreadsheet; } protected function formatCells(&$cells, $target = 'UTF-8'){ foreach($cells as &$cell){ $encoding = mb_detect_encoding($string); $cell = iconv($encoding, $target, $cell); } } protected function validateRows(){ foreach ($this->rows as $row) { $this->validateRow($row); } return true; } protected function validateRow($row, $countOnly = false){ if ($this->skipValidation) return true; if (!is_null($this->header)) { $reference = $this->header; $refType = 'header'; } elseif (count($this->rows) > 1) { $reference = $this->rows[0]; $refType = 'row'; } else { return true; } if (count($row) !== count($reference)) { switch ($refType) { case 'header': throw new \Exception('The row does not match the format of the header'); break; case 'row': throw new \Exception('The row does not match the format of the other rows already in the CSV'); break; } } if($countOnly) return true; foreach ($reference as $key => $column) { if (!array_key_exists($key, $row)) { switch ($refType) { case 'header': throw new \Exception('The row does not match the format of the header'); break; case 'row': throw new \Exception('The row does not match the format of the other rows already in the CSV'); break; } } } return true; } protected function changeIndices($schema){ foreach($this->getRows() as &$row){ $row = $this->changeRowIndices($schema); } } protected function changeRowIndices($row, $schema){ if (!is_null($this->header)) { $reference = $this->header; } elseif (count($this->rows) > 1) { $reference = $this->rows[0]; } else { return $row; } $i = 0; $newRow = []; foreach($row as $value){ $newRow[$schema[$i]['index']] = $value; $i++; } return $newRow; } protected function getRowSchema($row, $useValuesAsIndex = false){ $schema = []; foreach($row as $index => $value){ if($useValuesAsIndex){ $schema[] = ['index' => $value, 'value' => $value]; }else{ $schema[] = ['index' => $index, 'value' => $value]; } } return $schema; } protected function createEmptySpreadsheet(){ $spreadsheet = new PhpSpreadsheet\Spreadsheet; $spreadsheet->createSheet(); $spreadsheet->setActiveSheetIndex(0); return $spreadsheet; } public function activateAutoFilter($bool = true){ $this->autoFilter = $bool; } public function styleHeader($bold = false, $italic = false){ $this->headerStyle = [ 'bold' => $bold, 'italic' => $italic ]; } public function fixRows($rows){ $this->fixedRows = $rows; } public function fixColumns($columns){ $this->fixedCols = $columns; } }
{ "content_hash": "1bdc32d6b1618dc115b075a8ed475c17", "timestamp": "", "source": "github", "line_count": 375, "max_line_length": 112, "avg_line_length": 23.741333333333333, "alnum_prop": 0.6204650117937773, "repo_name": "Tekkl/tekkl-core", "id": "9ac6ea367780afe00af1e90634e162241bd6858b", "size": "9143", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "engine/Tekkl/Bundle/AppBundle/Helper/Spreadsheet/Spreadsheet.php", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "38700" }, { "name": "HTML", "bytes": "105784" }, { "name": "JavaScript", "bytes": "31641" }, { "name": "PHP", "bytes": "658185" }, { "name": "Shell", "bytes": "6970" }, { "name": "TypeScript", "bytes": "575107" } ], "symlink_target": "" }
package com.yff.web; import java.io.IOException; import java.io.PrintWriter; import java.util.Map; import javax.annotation.Resource; import javax.servlet.http.HttpServletRequest; import javax.servlet.http.HttpServletResponse; import javax.servlet.http.HttpSession; import org.springframework.stereotype.Controller; import org.springframework.ui.ModelMap; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMethod; import org.springframework.web.bind.annotation.RequestParam; import com.yff.entity.User; import com.yff.service.ArticleService; import com.yff.service.UserService; import com.yff.util.UserException; @Controller @RequestMapping("/user") public class UserController { @Resource(name = "userService") private UserService userService; @Resource(name = "articleService") private ArticleService articleService; @RequestMapping(value = "/login", method = RequestMethod.POST) public String login(@RequestParam("username") String username, @RequestParam("password")String password, ModelMap map, HttpSession session) {// User user = userService.getUserByUserName(username);//根据username获得用户 if (user == null) { throw new UserException("用户名不存在"); } else { if (!password.equals(user.getPassWord())) { throw new UserException("用户密码不正确"); } } session.setAttribute("loginUser", user); session.setAttribute("userName", username); if ("admin".equals(username)) { // req.setAttribute("userList", userManager.getAllUser()); map.put("userList", userService.getAllUser());//map自動将获取的数据放到request里 return "/getAllUser"; } else { map.put("articleList", articleService.getAllArticle(username)); return "/getAllArticle"; } } @RequestMapping("/getAllUser") public String getAllUser(HttpServletRequest request) { request.setAttribute("userList", userService.getAllUser()); return "/getAllUser"; } @RequestMapping("/getUser") public String getUser(String id, HttpServletRequest request) { request.setAttribute("user", userService.getUser(id)); return "/editUser"; } @RequestMapping("/toAddUser") public String toAddUser() { return "/addUser"; } @RequestMapping("/addUser") public String addUser(User user) { userService.addUser(user); return "redirect:/user/getAllUser"; } @RequestMapping("/delUser") public void delUser(String id, HttpServletResponse response) { String result = "{\"result\":\"error\"}"; if (userService.delUser(id)) { result = "{\"result\":\"success\"}"; } response.setContentType("application/json"); try { PrintWriter out = response.getWriter(); out.write(result); } catch (IOException e) { e.printStackTrace(); } } @RequestMapping("/updateUser") public String updateUser(User user, HttpServletRequest request) { if (userService.updateUser(user)) { user = userService.getUser(user.getId()); request.setAttribute("user", user); return "redirect:/user/getAllUser"; } else { return "/error"; } } }
{ "content_hash": "4949320a818164f9e0723b3fc8ae8a72", "timestamp": "", "source": "github", "line_count": 116, "max_line_length": 105, "avg_line_length": 26.07758620689655, "alnum_prop": 0.7345454545454545, "repo_name": "yffanny/blogdemo", "id": "78ccf58122577a0b36fd17f1516e081162d338dd", "size": "3085", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/com/yff/web/UserController.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Java", "bytes": "22458" } ], "symlink_target": "" }
import { moduleForModel, test } from 'ember-qunit'; moduleForModel('annotation', 'Unit | Serializer | Annotation', { needs: [ 'serializer:annotation', 'model:reference', 'model:meta', 'model:narrative', 'model:resource', 'model:extension' ] }); test('it serializes records', function(assert) { const record = this.subject(), serializeRecord = record.serialize(); assert.ok(serializeRecord); });
{ "content_hash": "b2a14070df11fd0e2069ac1f6b2781a1", "timestamp": "", "source": "github", "line_count": 19, "max_line_length": 64, "avg_line_length": 22.789473684210527, "alnum_prop": 0.6628175519630485, "repo_name": "davekago/ember-fhir", "id": "359de3db4a2b4b923e2fdf732a7783239982f664", "size": "433", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "tests/unit/serializers/annotation-test.js", "mode": "33188", "license": "mit", "language": [ { "name": "HTML", "bytes": "1703" }, { "name": "JavaScript", "bytes": "990500" } ], "symlink_target": "" }
<?php namespace Dima\MainBundle\Tests\Controller; use Symfony\Bundle\FrameworkBundle\Test\WebTestCase; class DefaultControllerTest extends WebTestCase { public function testIndex() { $client = static::createClient(); $crawler = $client->request('GET', '/hello/Fabien'); $this->assertTrue($crawler->filter('html:contains("Hello Fabien")')->count() > 0); } }
{ "content_hash": "9584d3e29a0b510c1dbea6a6ac13e304", "timestamp": "", "source": "github", "line_count": 17, "max_line_length": 90, "avg_line_length": 23.41176470588235, "alnum_prop": 0.6733668341708543, "repo_name": "Dima007/GuestBook_register", "id": "4976e81d2ef4cc3d11f57a4b7681eb7922721d21", "size": "398", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "src/Dima/MainBundle/Tests/Controller/DefaultControllerTest.php", "mode": "33261", "license": "mit", "language": [ { "name": "CSS", "bytes": "144322" }, { "name": "JavaScript", "bytes": "56478" }, { "name": "PHP", "bytes": "49927" }, { "name": "Perl", "bytes": "26" }, { "name": "Shell", "bytes": "213" } ], "symlink_target": "" }
module BoletoSimples class Installment < BaseModel end end
{ "content_hash": "1748a06f123d27c1193c473072482cbf", "timestamp": "", "source": "github", "line_count": 4, "max_line_length": 31, "avg_line_length": 15.75, "alnum_prop": 0.7936507936507936, "repo_name": "BoletoSimples/boletosimples-ruby", "id": "13adf6c7ec0931fbe394a1bd0c482c40a1b11fd0", "size": "94", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "lib/boletosimples/resources/installment.rb", "mode": "33188", "license": "mit", "language": [ { "name": "Ruby", "bytes": "46477" } ], "symlink_target": "" }
<?xml version="1.0" encoding="utf-8"?> <resources> <string name="hello">Hello World, Click Me!</string> <string name="app_name">OKHOSTING.School.UI.Droid</string> </resources>
{ "content_hash": "7d2da3f1fe5e759e728168a7befa837b", "timestamp": "", "source": "github", "line_count": 5, "max_line_length": 59, "avg_line_length": 35.8, "alnum_prop": 0.6983240223463687, "repo_name": "okhosting/OKHOSTING.ORM", "id": "ef0c7abff2875ec91729a41f613aede33947bd2d", "size": "181", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "examples/OKHOSTING.School/OKHOSTING.School.UI/OKHOSTING.School.UI.Droid/Resources/values/Strings.xml", "mode": "33188", "license": "mit", "language": [ { "name": "ASP", "bytes": "1340" }, { "name": "C#", "bytes": "546523" }, { "name": "PowerShell", "bytes": "29712" } ], "symlink_target": "" }
class GfRenderContext; class GfTexture; class GfBuffer; // Barriers struct GfTextureBarrier { const GfTexture* m_texture = nullptr; GfTextureViewConfig m_viewConfig; TextureUsageFlags::Mask m_oldUsage; TextureUsageFlags::Mask m_newUsage; }; struct GfTextureBarrierArray { GfTextureBarrier* m_array; u32 m_size = 0; u32 m_capacity = 0; }; struct GfBufferBarrier { const GfBuffer* m_buffer = nullptr; u32 m_offset = 0; u32 m_size; BufferUsageFlags::Mask m_oldUsage; BufferUsageFlags::Mask m_newUsage; }; struct GfBufferBarrierArray { GfBufferBarrier* m_array; u32 m_size = 0; u32 m_capacity = 0; }; // Semaphores class GfSemaphore { GF_DECLARE_PLATFORM_INTERFACE(GfSemaphore); public: GfSemaphore(); void create(const GfRenderContext& ctx); void destroy(const GfRenderContext& ctx); }; #endif
{ "content_hash": "89db8db1ba48fa679a8d67064b54e259", "timestamp": "", "source": "github", "line_count": 51, "max_line_length": 44, "avg_line_length": 16.137254901960784, "alnum_prop": 0.7448359659781288, "repo_name": "alapontgr/Engine", "id": "e65f077258dddc580215f3b947ee7bb85595fb9c", "size": "1430", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "Engine/Src/Common/GfRender/GraphicResources/GfRenderSync.h", "mode": "33188", "license": "mit", "language": [ { "name": "Batchfile", "bytes": "1017" }, { "name": "C", "bytes": "293959" }, { "name": "C++", "bytes": "2490199" }, { "name": "CMake", "bytes": "2703" }, { "name": "Lua", "bytes": "6500" }, { "name": "Objective-C", "bytes": "39974" } ], "symlink_target": "" }
package net.siufung.bzgzpt.persistence.collect.service.impl; import java.util.List; import java.util.Map; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import cn.jbinfo.platform.core.basic.exception.ServiceException; import net.siufung.bzgzpt.persistence.collect.dao.IAba31SummaryDao; import net.siufung.bzgzpt.persistence.collect.domain.Aba31Summary; import net.siufung.bzgzpt.persistence.collect.service.IAba31SummaryService; import javax.annotation.Resource; /** * 对Aba31Summary实体进行CRUD操作 */ @Service("Aba31SummaryServiceImpl") @Transactional public class Aba31SummaryServiceImpl implements IAba31SummaryService{ @Resource private IAba31SummaryDao aba31SummaryDao; @Override public Aba31Summary get(Aba31Summary paramT) throws ServiceException { // TODO Auto-generated method stub return null; } @Override public Aba31Summary getById(String id) throws ServiceException { // TODO Auto-generated method stub return null; } @Override public List<Aba31Summary> findList(Aba31Summary paramT) throws ServiceException { // TODO Auto-generated method stub return null; } @Override public void insert(Aba31Summary paramT) throws ServiceException { // TODO Auto-generated method stub } @Override public void delete(Aba31Summary paramT) throws ServiceException { // TODO Auto-generated method stub } @Override public void save(Aba31Summary aba31Summary) { // TODO Auto-generated method stub } @Override public void deleteById(Long id) { // TODO Auto-generated method stub } @Override public void update(Aba31Summary aba31Summary) { // TODO Auto-generated method stub } @Override public Aba31Summary getById(Long id) { // TODO Auto-generated method stub return null; } @Override public Aba31Summary getByModel(Aba31Summary aba31Summary) { // TODO Auto-generated method stub return null; } @Override public List<Aba31Summary> searchList(Map<String,Object> map) { // TODO Auto-generated method stub return aba31SummaryDao.searchList(map); } @Override public List<Map<String, Object>> searchSpecialCareList(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchSpecialCareList(map); } public List<Map<String, Object>> searchSpecCByDistrict(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchSpecCByDistrict(map); } public List<Map<String, Object>> searchSpecCByStreet(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchSpecCByStreet(map); } @Override public List<Map<String, Object>> searchOffWorkList(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchOffWorkList(map); } @Override public List<Map<String, Object>> searchPensionCareList(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchPensionCareList(map); } @Override public List<Map<String, Object>> searchMedicallCareList(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchMedicallCareList(map); } @Override public List<Map<String, Object>> searchOWByStreet(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchOWByStreet(map); } @Override public List<Map<String, Object>> searchOWByDistrict(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchOWByDistrict(map); } @Override public List<Map<String, Object>> searchPCareByDistrict(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchPCareByDistrict(map); } @Override public List<Map<String, Object>> searchPCareByStreet(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchPCareByStreet(map); } public List<Map<String, Object>> searchMCByDistrict(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchMCByDistrict(map); } public List<Map<String, Object>> searchMCByStreet(Map map) { // TODO Auto-generated method stub return aba31SummaryDao.searchMCByStreet(map); } }
{ "content_hash": "3fd83ec89f52352b28f6e9173957df2e", "timestamp": "", "source": "github", "line_count": 154, "max_line_length": 82, "avg_line_length": 26.435064935064936, "alnum_prop": 0.7715549005158437, "repo_name": "1461862234/kzf", "id": "e936a7b59bb61511ba985d4b3002afeeb202aa05", "size": "4085", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "BZGZPT/bzgzpt-persistence/src/main/java/net/siufung/bzgzpt/persistence/collect/service/impl/Aba31SummaryServiceImpl.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "CSS", "bytes": "1050430" }, { "name": "FreeMarker", "bytes": "71863" }, { "name": "HTML", "bytes": "15182" }, { "name": "Java", "bytes": "2609924" }, { "name": "JavaScript", "bytes": "4050259" }, { "name": "SQLPL", "bytes": "1044" } ], "symlink_target": "" }
<!DOCTYPE html> <html> <head> <meta http-equiv="content-type" content="text/html;charset=UTF-8" /> <meta charset="utf-8" /> <title>Oliver Yarbrough</title> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" /> <link rel="apple-touch-icon" href="pages/ico/60.png"> <link rel="apple-touch-icon" sizes="76x76" href="pages/ico/76.png"> <link rel="apple-touch-icon" sizes="120x120" href="pages/ico/120.png"> <link rel="apple-touch-icon" sizes="152x152" href="pages/ico/152.png"> <link rel="icon" type="image/png" href="assets/images/OY_favicon_blk.gif"> <meta name="apple-mobile-web-app-capable" content="yes"> <meta name="apple-touch-fullscreen" content="yes"> <meta name="apple-mobile-web-app-status-bar-style" content="default"> <meta content="" name="description" /> <meta content="" name="author" /> <!-- BEGIN PLUGINS --> <link href="assets/plugins/pace/pace-theme-flash.css" rel="stylesheet" type="text/css" /> <link href="assets/plugins/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css" /> <link href="assets/plugins/font-awesome/css/font-awesome.css" rel="stylesheet" type="text/css" /> <link href="assets/plugins/swiper/css/swiper.css" rel="stylesheet" type="text/css" media="screen" /> <!-- END PLUGINS --> <!-- BEGIN PAGES CSS --> <link class="main-stylesheet" href="pages/css/pages.css" rel="stylesheet" type="text/css" /> <link href="pages/css/pages-icons.css" rel="stylesheet" type="text/css" /> <!-- BEGIN PAGES CSS --> </head> <body> <!-- BEGIN HEADER --> <div class="navbar navbar-inverse navbar-fixed-top" role="navigation"> <div class="container"> <!--<button type="button" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse"> <span class="sr-only">Toggle navigation</span> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </button>--> <div class="collapse navbar-collapse"> <ul class="nav navbar-nav pull-right"> <li><a href="about.html"><b>About</b></a></li> <li style="padding-top:12px;">|</li> <li><a href="index.html#subscribe"><b>Subscribe</b></a></li> <!--<li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown">Dropdown <b class="caret"></b></a> <ul class="dropdown-menu"> <li><a href="#">Action</a></li> <li><a href="#">Another action</a></li> <li class="divider"></li> <li><a href="#">Separated link</a></li> <li class="divider"></li> <li><a href="#">One more separated link</a></li> </ul> </li>--> </ul> </div> </div> </div> <nav style="margin-top:40px;" class="header bg-header transparent-dark " data-pages="header" data-pages-header="autoresize" data-pages-resize-class="dark"> <div class="container relative"> <!-- BEGIN LEFT CONTENT --> <div class="pull-left"> <!-- .header-inner Allows to vertically Align elements to the Center--> <div class="header-inner"> <!-- BEGIN LOGO --> <a href="index.html"><img src="assets/images/OY-logo.png" width="170" height="40" data-src-retina="assets/images/OY-logo.png" class="logo" alt=""></a> <a href="index.html"><img src="assets/images/OY-logo.png" width="170" height="40" data-src-retina="assets/images/OY-logo.png" class="alt" alt=""></a> </div> </div> <!-- BEGIN HEADER TOGGLE FOR MOBILE & TABLET --> <div class="pull-right"> <div class="header-inner"> <a href="#" class="search-toggle visible-sm-inline visible-xs-inline p-r-5" data-toggle="search"><i class="fs-14 pg-search"></i></a> <div class="visible-sm-inline visible-xs-inline menu-toggler pull-right p-l-5" data-pages="header-toggle" data-pages-element="#header"> <div class="one"></div> <div class="two"></div> <div class="three"></div> </div> </div> </div> <!-- END HEADER TOGGLE FOR MOBILE & TABLET --> <!-- BEGIN RIGHT CONTENT --> <div class="menu-content mobile-dark pull-right clearfix" data-pages-direction="slideRight" id="header"> <!-- BEGIN HEADER CLOSE TOGGLE FOR MOBILE --> <div class="pull-right"> <a href="#" class="padding-10 visible-xs-inline visible-sm-inline pull-right m-t-75 m-b-10 m-r-10" data-pages="header-toggle" data-pages-element="#header"> <i class=" pg-close_line"></i> </a> </div> <!-- END HEADER CLOSE TOGGLE FOR MOBILE --> <!-- BEGIN MENU ITEMS --> <div class="header-inner"> <ul class="menu"> <!--<li class="classic multiline"> <a href="javascript:;" data-text="Coaching">Coaching <i class="pg-arrow_minimize m-l-5"></i></a> <nav class="classic"> <!--<span class="arrow"></span> <ul> <li> <a href="#" target="_blank">Business Development</a> </li> <li> <a href="#" target="_blank">Client Development</a> </li> <li> <a href="#" target="_blank">Marketing Strategy</a> </li> <li> <a href="#" target="_blank">Project Management</a> </li> </ul> </nav> </li>--> <li > <a href="index.html#speaking">Speaking</a> </li> <li> <a href="#">Publications</a> </li> <li> <a href="#">Programs</a> </li> <li> <a href="index.html#event">Events</a> </li> <!--<li> <a href="#"><i class="fa fa-shopping-cart"></i></a> </li>--> <li> <a href="#">Blog</a> </li> <li> <a href="#">Contact</a> </li> </ul> <a href="#" class="search-toggle hidden-xs hidden-sm" data-toggle="search"><i class="fs-14 pg-search"></i></a> </div> <!-- END MENU ITEMS --> </div> </div> </nav> <!-- END HEADER --> <div class="m-t-100"> <!-- START CONTACT SECTION --> <section class="container container-fixed-lg p-t-85 p-b-100 sm-p-b-30 sm-m-b-30"> <div class="row"> <div class="col-md-5"> <div class="row"> <div class="col-sm-6 col-md-12"> <img src="assets/images/OY_favicon_blk.gif"/> </div> <div class="col-sm-6 col-md-12"> <br class="visible-md visible-xs"> <h5 class="block-title hint-text m-b-0">Oliver Yarbrough</h5> <address class="text-master m-t-5">Stranthvale Place, 90 North <br> Church street, Po Box 10374 APO <br> Atlanta, Georgia</address><br/><br/> <p class="hint-text no-margin"><span class="fs-12 font-montserrat bold all-caps p-r-10">Tel</span> <span class="fs-14">(404) 300-9832</span></p> <p class="hint-text"><span class="fs-12 font-montserrat bold all-caps p-r-10">Fax</span> <span class="fs-14">(877) 412-7766</span></p> </div> </div> </div> <div class="col-md-7"> <br class=" visible-xs"> <br class="visible-xs"> <h4 class="sm-m-t-20">Contact me and stay connected!</h4> <form class="" role="form"> <div class="row"> <div class="col-sm-6"> <div class="form-group form-group-default required"> <label class="control-label">Full name</label> <input type="text" name="name" class="form-control input-sm" required> </div> </div> <div class="col-sm-6"> <div class="form-group form-group-default required"> <label class="control-label">Email</label> <input type="email" name="email" class="form-control input-sm" required> </div> </div> </div> <div class="form-group form-group-default required"> <label class="control-label">Message</label> <textarea class="form-control" style="height:100px" placeholder="Type your message"></textarea> </div> <p class="pull-left small hint-text m-t-5 font-arial sm-m-t-10">I hereby certify that the information above is true and accurate. </p> <button class="btn btn-white font-montserrat all-caps fs-11 pull-right sm-m-t-10">Send request</button> <div class="clearfix"></div> </form> </div> </div> </section> <!-- END CONTACT SECION --> <!-- START GOOGLE MAP --> <section class="container-fluid no-padding no-overflow"> <!-- Map --> <div id="google-map" class="full-width demo-map gradient-overlay no-overflow"></div> </section> <!-- END GOOGLE MAP --> </div> <!-- START CONTENT SECTION --> <section class="p-b-55 p-t-75 xs-p-b-20 bg-master-darker "> <div class="container"> <div class="row text-center"> <div class="hidden-inner p-b-10"> <img src="assets/images/OY_logo_new_wht.png"/> </div> <div class="hidden-inner p-b-10"> <a href="index.html#speaking" class="link text-white" style="padding: 0px 0px 0px 10px">Speaking</a> <a href="#" class="link text-white" style="padding: 0px 0px 0px 10px">Publications</a> <a href="#" class="link text-white" style="padding: 0px 0px 0px 10px">Programs</a> <a href="index.html#event" class="link text-white" style="padding: 0px 0px 0px 10px">Events</a> <a href="#" class="link text-white" style="padding: 0px 0px 0px 10px">Blog</a> <a href="about.html" class="link text-white" style="padding: 0px 0px 0px 10px">About</a> <a href="#" class="link text-white" style="padding: 0px 0px 0px 10px">Subscribe</a> <a href="contact.html" class="link text-white" style="padding: 0px 0px 0px 10px">Contact</a> </div> </div> <div class="row text-center" > <a href="" class="facebook" title="Facebook" target="blank"><i id="purpcolor" id="link" class=" fa fa-facebook-square fa-2x"></i></a> <a href="" class="twitter" title="Twitter" target="blank"><i id="purpcolor" class="fa fa-twitter-square fa-2x"></i></a> <a href="" class="googleplus" title="GooglePlus" target="blank"><i id="purpcolor" class="fa fa-google-plus-square fa-2x"></i></a> <a href="" class="linkedin" title="LinkedIn" target="blank"><i id="purpcolor" class="fa fa-linkedin-square fa-2x"></i></a> <a href="" class="youtube" title="Youtube" target="blank"><i id="purpcolor" class="fa fa-youtube-square fa-2x"></i></a> <a href="" class="snapchat" title="Snapchat" target="blank"><i id="purpcolor" class="fa fa-snapchat-square fa-2x"></i></a> <a href="" class="pinterest" title="Pinterest" target="blank"><i id="purpcolor" class="fa fa-pinterest-square fa-2x"></i></a> <a href="" class="reddit" title="Reddit" target="blank"><i id="purpcolor" class="fa fa-reddit-square fa-2x"></i></a> <a href="" class="tumblr" title="Tumblr" target="blank"><i id="purpcolor" class="fa fa-tumblr-square fa-2x"></i></a> <a href="" class="flickr" title="Flickr" target="blank"><i id="purpcolor" class="fa fa-flickr fa-2x"></i></a> </div> <div class="row text-center p-t-30"><a href="#top"><i style="color:#626262" class="fa fa-arrow-circle-up fa-3x p-b-0 align-right" ></i></a> <p class="small hint-text p-t-0 text-white text-center ">Top</p> </div> </div> </section> <!-- END CONTENT SECTION --> <!-- BEGIN FOOTER <section class="p-b-55 p-t-75 xs-p-b-20 bg-master-darker "> <div class="container"> <div class="row"> <div class="col-sm-4 col-xs-12 xs-m-b-40"> <img src="assets/images/logo_white.png" width="152" height="21" data-src-retina="assets/images/logo_white_2x.png" class="alt" alt=""> </div> <div class="col-sm-2 col-xs-6 xs-m-b-20"> <h6 class="font-montserrat text-uppercase fs-14 text-white p-b-10">Company </h6> <ul class="no-style"> <li class="m-b-5 no-padding"><a href="#" class="link text-white ">Design</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Features</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Team</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Work Station</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Privacy</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Legal</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Jobs</a></li> </ul> </div> <div class="col-sm-2 col-xs-6 xs-m-b-20"> <h6 class="font-montserrat text-uppercase fs-14 text-white p-b-10">Work </h6> <ul class="no-style"> <li class="m-b-5 no-padding"><a href="#" class="link text-white ">Apps</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white ">Popular</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white ">Web-Arch</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Pages</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Frontend</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Charity</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Marketplaces</a></li> </ul> </div> <div class="col-sm-2 col-xs-6 xs-m-b-20"> <h6 class="font-montserrat text-uppercase fs-14 text-white p-b-10">Clients </h6> <ul class="no-style"> <li class="m-b-5 no-padding"><a href="#" class="link text-white ">Our team</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Our location</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Contact Us</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">About Us</a></li> </ul> </div> <div class="col-sm-2 col-xs-6 xs-m-b-20"> <h6 class="font-montserrat text-uppercase fs-14 text-white p-b-10">Pages </h6> <ul class="no-style"> <li class="m-b-5 no-padding"><a href="#" class="link text-white ">Pages</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Home</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Tour</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Versions</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Dropdown</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Pricing Page</a></li> <li class="m-b-5 no-padding"><a href="#" class="link text-white">Blog</a></li> </ul> </div> </div> <p class="fs-12 hint-text p-t-10 text-white">Copyright &copy; 2014. All Rights Reserved </p> </div> </section> END FOOTER --> <!-- START FOOTER --> <section class="p-t-25 p-b-25"> <div class="container"> <div class="row"> <div class="col-sm-8"> <a href="index.html"><img src="assets/images/OY-logo_blk.png" style="width:150px;height:25px;"class="logo inline m-r-50" alt=""></a> <div class="m-t-10 inline"> <ul class="no-style fs-11 no-padding font-arial"> <li class="inline no-padding"><a href="#" class=" text-master p-r-15 b-r b-grey">Contact</a></li> <li class="inline no-padding"><a href="#" class=" text-master p-l-15 p-r-15 b-r b-grey">Privacy Policy</a></li> <li class="inline no-padding"><a href="#" class=" text-master p-l-15 p-r-15 b-r b-grey">Terms and Conditions</a></li> <li class="inline no-padding"><a href="#" class=" text-master p-l-15 p-r-15 b-r b-grey">My Account</a></li> <li class="inline no-padding"><a href="#" class=" text-master p-l-15 p-r-15 xs-m-t-10">Site Map</a></li> </ul> </div> </div> <div class="col-sm-4 text-right sm-text-left font-arial hidden-inner"> <p class="fs-11 m-t-10">Copyright &copy; 2017 Oliver Yarbrough. All Rights Reserved.</p> </div> </div> </div> </section> <!-- END FOOTER --> <!-- START OVERLAY --> <div class="overlay hide" data-pages="search"> <!-- BEGIN Overlay Content !--> <div class="overlay-content full-height has-results"> <!-- END Overlay Header !--> <div class="container relative full-height"> <!-- BEGIN Overlay Header !--> <div class="container-fluid"> <!-- BEGIN Overlay Close !--> <a href="#" class="close-icon-light overlay-close text-black fs-16 top-right"> <i class="pg-close_line"></i> </a> <!-- END Overlay Close !--> </div> <div class="container-fluid"> <div class="inline-block bottom-right m-b-30"> <div class="checkbox right"> <input id="checkboxn" type="checkbox" value="1" checked="checked"> <label for="checkboxn">Search within page</label> </div> </div> </div> <div class="container-xs-height full-height"> <div class="col-xs-height col-middle text-center"> <!-- BEGIN Overlay Controls !--> <input id="overlay-search" class="no-border overlay-search bg-transparent col-sm-6 col-sm-offset-4" placeholder="Search..." autocomplete="off" spellcheck="false"> <br> <div class="inline-block bottom-left m-l-10 m-b-30 hidden-xs"> <p class="fs-14"><i class="fa fa-search m-r-10"></i> Press enter to search</p> </div> <!-- END Overlay Controls !--> </div> </div> </div> </div> <!-- END Overlay Content !--> </div> <!-- END OVERLAY --> <!-- BEGIN CORE FRAMEWORK --> <script src="assets/plugins/pace/pace.min.js" type="text/javascript"></script> <script type="text/javascript" src="pages/js/pages.image.loader.js"></script> <script type="text/javascript" src="assets/plugins/jquery/jquery-1.11.1.min.js"></script> <script type="text/javascript" src="assets/plugins/bootstrap/js/bootstrap.min.js"></script> <!-- BEGIN SWIPER DEPENDENCIES --> <script type="text/javascript" src="assets/plugins/swiper/js/swiper.jquery.min.js"></script> <script type="text/javascript" src="assets/plugins/jquery-validation/js/jquery.validate.min.js"></script> <script src="http://maps.googleapis.com/maps/api/js?v=3.exp"></script> <!-- BEGIN RETINA IMAGE LOADER --> <script type="text/javascript" src="assets/plugins/jquery-unveil/jquery.unveil.min.js"></script> <!-- END VENDOR JS --> <!-- BEGIN PAGES FRONTEND LIB --> <script type="text/javascript" src="pages/js/pages.frontend.js"></script> <!-- END PAGES LIB --> <!-- BEGIN YOUR CUSTOM JS --> <script type="text/javascript" src="assets/js/custom.js"></script> <script type="text/javascript" src="assets/js/contact.js"></script> <script type="text/javascript" src="assets/js/google_map.js"></script> </body> </html>
{ "content_hash": "7f5eff4ef3093736d27b1f929079b3f0", "timestamp": "", "source": "github", "line_count": 384, "max_line_length": 178, "avg_line_length": 51.291666666666664, "alnum_prop": 0.5640231519090171, "repo_name": "spotlessmanagementinc/spotlessmanagementinc.github.io", "id": "28597142000ac012e17f3c39a18003efbcb5adf6", "size": "19696", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "getting_started/contact.original.html", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "CSS", "bytes": "1788741" }, { "name": "HTML", "bytes": "2036141" }, { "name": "JavaScript", "bytes": "1613565" }, { "name": "PHP", "bytes": "379910" } ], "symlink_target": "" }
package instance // import "google.golang.org/genproto/googleapis/spanner/admin/instance/v1" import proto "github.com/golang/protobuf/proto" import fmt "fmt" import math "math" import empty "github.com/golang/protobuf/ptypes/empty" import timestamp "github.com/golang/protobuf/ptypes/timestamp" import _ "google.golang.org/genproto/googleapis/api/annotations" import v1 "google.golang.org/genproto/googleapis/iam/v1" import longrunning "google.golang.org/genproto/googleapis/longrunning" import field_mask "google.golang.org/genproto/protobuf/field_mask" import ( context "golang.org/x/net/context" grpc "google.golang.org/grpc" ) // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal var _ = fmt.Errorf var _ = math.Inf // This is a compile-time assertion to ensure that this generated file // is compatible with the proto package it is being compiled against. // A compilation error at this line likely means your copy of the // proto package needs to be updated. const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package // Indicates the current state of the instance. type Instance_State int32 const ( // Not specified. Instance_STATE_UNSPECIFIED Instance_State = 0 // The instance is still being created. Resources may not be // available yet, and operations such as database creation may not // work. Instance_CREATING Instance_State = 1 // The instance is fully created and ready to do work such as // creating databases. Instance_READY Instance_State = 2 ) var Instance_State_name = map[int32]string{ 0: "STATE_UNSPECIFIED", 1: "CREATING", 2: "READY", } var Instance_State_value = map[string]int32{ "STATE_UNSPECIFIED": 0, "CREATING": 1, "READY": 2, } func (x Instance_State) String() string { return proto.EnumName(Instance_State_name, int32(x)) } func (Instance_State) EnumDescriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{1, 0} } // A possible configuration for a Cloud Spanner instance. Configurations // define the geographic placement of nodes and their replication. type InstanceConfig struct { // A unique identifier for the instance configuration. Values // are of the form // `projects/<project>/instanceConfigs/[a-z][-a-z0-9]*` Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` // The name of this instance configuration as it appears in UIs. DisplayName string `protobuf:"bytes,2,opt,name=display_name,json=displayName" json:"display_name,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *InstanceConfig) Reset() { *m = InstanceConfig{} } func (m *InstanceConfig) String() string { return proto.CompactTextString(m) } func (*InstanceConfig) ProtoMessage() {} func (*InstanceConfig) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{0} } func (m *InstanceConfig) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_InstanceConfig.Unmarshal(m, b) } func (m *InstanceConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_InstanceConfig.Marshal(b, m, deterministic) } func (dst *InstanceConfig) XXX_Merge(src proto.Message) { xxx_messageInfo_InstanceConfig.Merge(dst, src) } func (m *InstanceConfig) XXX_Size() int { return xxx_messageInfo_InstanceConfig.Size(m) } func (m *InstanceConfig) XXX_DiscardUnknown() { xxx_messageInfo_InstanceConfig.DiscardUnknown(m) } var xxx_messageInfo_InstanceConfig proto.InternalMessageInfo func (m *InstanceConfig) GetName() string { if m != nil { return m.Name } return "" } func (m *InstanceConfig) GetDisplayName() string { if m != nil { return m.DisplayName } return "" } // An isolated set of Cloud Spanner resources on which databases can be hosted. type Instance struct { // Required. A unique identifier for the instance, which cannot be changed // after the instance is created. Values are of the form // `projects/<project>/instances/[a-z][-a-z0-9]*[a-z0-9]`. The final // segment of the name must be between 6 and 30 characters in length. Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` // Required. The name of the instance's configuration. Values are of the form // `projects/<project>/instanceConfigs/<configuration>`. See // also [InstanceConfig][google.spanner.admin.instance.v1.InstanceConfig] and // [ListInstanceConfigs][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigs]. Config string `protobuf:"bytes,2,opt,name=config" json:"config,omitempty"` // Required. The descriptive name for this instance as it appears in UIs. // Must be unique per project and between 4 and 30 characters in length. DisplayName string `protobuf:"bytes,3,opt,name=display_name,json=displayName" json:"display_name,omitempty"` // Required. The number of nodes allocated to this instance. This may be zero // in API responses for instances that are not yet in state `READY`. // // See [the documentation](https://cloud.google.com/spanner/docs/instances#node_count) // for more information about nodes. NodeCount int32 `protobuf:"varint,5,opt,name=node_count,json=nodeCount" json:"node_count,omitempty"` // Output only. The current instance state. For // [CreateInstance][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstance], the state must be // either omitted or set to `CREATING`. For // [UpdateInstance][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstance], the state must be // either omitted or set to `READY`. State Instance_State `protobuf:"varint,6,opt,name=state,enum=google.spanner.admin.instance.v1.Instance_State" json:"state,omitempty"` // Cloud Labels are a flexible and lightweight mechanism for organizing cloud // resources into groups that reflect a customer's organizational needs and // deployment strategies. Cloud Labels can be used to filter collections of // resources. They can be used to control how resource metrics are aggregated. // And they can be used as arguments to policy management rules (e.g. route, // firewall, load balancing, etc.). // // * Label keys must be between 1 and 63 characters long and must conform to // the following regular expression: `[a-z]([-a-z0-9]*[a-z0-9])?`. // * Label values must be between 0 and 63 characters long and must conform // to the regular expression `([a-z]([-a-z0-9]*[a-z0-9])?)?`. // * No more than 64 labels can be associated with a given resource. // // See https://goo.gl/xmQnxf for more information on and examples of labels. // // If you plan to use labels in your own code, please note that additional // characters may be allowed in the future. And so you are advised to use an // internal label representation, such as JSON, which doesn't rely upon // specific characters being disallowed. For example, representing labels // as the string: name + "_" + value would prove problematic if we were to // allow "_" in a future release. Labels map[string]string `protobuf:"bytes,7,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *Instance) Reset() { *m = Instance{} } func (m *Instance) String() string { return proto.CompactTextString(m) } func (*Instance) ProtoMessage() {} func (*Instance) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{1} } func (m *Instance) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_Instance.Unmarshal(m, b) } func (m *Instance) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_Instance.Marshal(b, m, deterministic) } func (dst *Instance) XXX_Merge(src proto.Message) { xxx_messageInfo_Instance.Merge(dst, src) } func (m *Instance) XXX_Size() int { return xxx_messageInfo_Instance.Size(m) } func (m *Instance) XXX_DiscardUnknown() { xxx_messageInfo_Instance.DiscardUnknown(m) } var xxx_messageInfo_Instance proto.InternalMessageInfo func (m *Instance) GetName() string { if m != nil { return m.Name } return "" } func (m *Instance) GetConfig() string { if m != nil { return m.Config } return "" } func (m *Instance) GetDisplayName() string { if m != nil { return m.DisplayName } return "" } func (m *Instance) GetNodeCount() int32 { if m != nil { return m.NodeCount } return 0 } func (m *Instance) GetState() Instance_State { if m != nil { return m.State } return Instance_STATE_UNSPECIFIED } func (m *Instance) GetLabels() map[string]string { if m != nil { return m.Labels } return nil } // The request for [ListInstanceConfigs][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigs]. type ListInstanceConfigsRequest struct { // Required. The name of the project for which a list of supported instance // configurations is requested. Values are of the form // `projects/<project>`. Parent string `protobuf:"bytes,1,opt,name=parent" json:"parent,omitempty"` // Number of instance configurations to be returned in the response. If 0 or // less, defaults to the server's maximum allowed page size. PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize" json:"page_size,omitempty"` // If non-empty, `page_token` should contain a // [next_page_token][google.spanner.admin.instance.v1.ListInstanceConfigsResponse.next_page_token] // from a previous [ListInstanceConfigsResponse][google.spanner.admin.instance.v1.ListInstanceConfigsResponse]. PageToken string `protobuf:"bytes,3,opt,name=page_token,json=pageToken" json:"page_token,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *ListInstanceConfigsRequest) Reset() { *m = ListInstanceConfigsRequest{} } func (m *ListInstanceConfigsRequest) String() string { return proto.CompactTextString(m) } func (*ListInstanceConfigsRequest) ProtoMessage() {} func (*ListInstanceConfigsRequest) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{2} } func (m *ListInstanceConfigsRequest) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_ListInstanceConfigsRequest.Unmarshal(m, b) } func (m *ListInstanceConfigsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_ListInstanceConfigsRequest.Marshal(b, m, deterministic) } func (dst *ListInstanceConfigsRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_ListInstanceConfigsRequest.Merge(dst, src) } func (m *ListInstanceConfigsRequest) XXX_Size() int { return xxx_messageInfo_ListInstanceConfigsRequest.Size(m) } func (m *ListInstanceConfigsRequest) XXX_DiscardUnknown() { xxx_messageInfo_ListInstanceConfigsRequest.DiscardUnknown(m) } var xxx_messageInfo_ListInstanceConfigsRequest proto.InternalMessageInfo func (m *ListInstanceConfigsRequest) GetParent() string { if m != nil { return m.Parent } return "" } func (m *ListInstanceConfigsRequest) GetPageSize() int32 { if m != nil { return m.PageSize } return 0 } func (m *ListInstanceConfigsRequest) GetPageToken() string { if m != nil { return m.PageToken } return "" } // The response for [ListInstanceConfigs][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigs]. type ListInstanceConfigsResponse struct { // The list of requested instance configurations. InstanceConfigs []*InstanceConfig `protobuf:"bytes,1,rep,name=instance_configs,json=instanceConfigs" json:"instance_configs,omitempty"` // `next_page_token` can be sent in a subsequent // [ListInstanceConfigs][google.spanner.admin.instance.v1.InstanceAdmin.ListInstanceConfigs] call to // fetch more of the matching instance configurations. NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken" json:"next_page_token,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *ListInstanceConfigsResponse) Reset() { *m = ListInstanceConfigsResponse{} } func (m *ListInstanceConfigsResponse) String() string { return proto.CompactTextString(m) } func (*ListInstanceConfigsResponse) ProtoMessage() {} func (*ListInstanceConfigsResponse) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{3} } func (m *ListInstanceConfigsResponse) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_ListInstanceConfigsResponse.Unmarshal(m, b) } func (m *ListInstanceConfigsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_ListInstanceConfigsResponse.Marshal(b, m, deterministic) } func (dst *ListInstanceConfigsResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_ListInstanceConfigsResponse.Merge(dst, src) } func (m *ListInstanceConfigsResponse) XXX_Size() int { return xxx_messageInfo_ListInstanceConfigsResponse.Size(m) } func (m *ListInstanceConfigsResponse) XXX_DiscardUnknown() { xxx_messageInfo_ListInstanceConfigsResponse.DiscardUnknown(m) } var xxx_messageInfo_ListInstanceConfigsResponse proto.InternalMessageInfo func (m *ListInstanceConfigsResponse) GetInstanceConfigs() []*InstanceConfig { if m != nil { return m.InstanceConfigs } return nil } func (m *ListInstanceConfigsResponse) GetNextPageToken() string { if m != nil { return m.NextPageToken } return "" } // The request for // [GetInstanceConfigRequest][google.spanner.admin.instance.v1.InstanceAdmin.GetInstanceConfig]. type GetInstanceConfigRequest struct { // Required. The name of the requested instance configuration. Values are of // the form `projects/<project>/instanceConfigs/<config>`. Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *GetInstanceConfigRequest) Reset() { *m = GetInstanceConfigRequest{} } func (m *GetInstanceConfigRequest) String() string { return proto.CompactTextString(m) } func (*GetInstanceConfigRequest) ProtoMessage() {} func (*GetInstanceConfigRequest) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{4} } func (m *GetInstanceConfigRequest) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_GetInstanceConfigRequest.Unmarshal(m, b) } func (m *GetInstanceConfigRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_GetInstanceConfigRequest.Marshal(b, m, deterministic) } func (dst *GetInstanceConfigRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_GetInstanceConfigRequest.Merge(dst, src) } func (m *GetInstanceConfigRequest) XXX_Size() int { return xxx_messageInfo_GetInstanceConfigRequest.Size(m) } func (m *GetInstanceConfigRequest) XXX_DiscardUnknown() { xxx_messageInfo_GetInstanceConfigRequest.DiscardUnknown(m) } var xxx_messageInfo_GetInstanceConfigRequest proto.InternalMessageInfo func (m *GetInstanceConfigRequest) GetName() string { if m != nil { return m.Name } return "" } // The request for [GetInstance][google.spanner.admin.instance.v1.InstanceAdmin.GetInstance]. type GetInstanceRequest struct { // Required. The name of the requested instance. Values are of the form // `projects/<project>/instances/<instance>`. Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *GetInstanceRequest) Reset() { *m = GetInstanceRequest{} } func (m *GetInstanceRequest) String() string { return proto.CompactTextString(m) } func (*GetInstanceRequest) ProtoMessage() {} func (*GetInstanceRequest) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{5} } func (m *GetInstanceRequest) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_GetInstanceRequest.Unmarshal(m, b) } func (m *GetInstanceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_GetInstanceRequest.Marshal(b, m, deterministic) } func (dst *GetInstanceRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_GetInstanceRequest.Merge(dst, src) } func (m *GetInstanceRequest) XXX_Size() int { return xxx_messageInfo_GetInstanceRequest.Size(m) } func (m *GetInstanceRequest) XXX_DiscardUnknown() { xxx_messageInfo_GetInstanceRequest.DiscardUnknown(m) } var xxx_messageInfo_GetInstanceRequest proto.InternalMessageInfo func (m *GetInstanceRequest) GetName() string { if m != nil { return m.Name } return "" } // The request for [CreateInstance][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstance]. type CreateInstanceRequest struct { // Required. The name of the project in which to create the instance. Values // are of the form `projects/<project>`. Parent string `protobuf:"bytes,1,opt,name=parent" json:"parent,omitempty"` // Required. The ID of the instance to create. Valid identifiers are of the // form `[a-z][-a-z0-9]*[a-z0-9]` and must be between 6 and 30 characters in // length. InstanceId string `protobuf:"bytes,2,opt,name=instance_id,json=instanceId" json:"instance_id,omitempty"` // Required. The instance to create. The name may be omitted, but if // specified must be `<parent>/instances/<instance_id>`. Instance *Instance `protobuf:"bytes,3,opt,name=instance" json:"instance,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *CreateInstanceRequest) Reset() { *m = CreateInstanceRequest{} } func (m *CreateInstanceRequest) String() string { return proto.CompactTextString(m) } func (*CreateInstanceRequest) ProtoMessage() {} func (*CreateInstanceRequest) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{6} } func (m *CreateInstanceRequest) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_CreateInstanceRequest.Unmarshal(m, b) } func (m *CreateInstanceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_CreateInstanceRequest.Marshal(b, m, deterministic) } func (dst *CreateInstanceRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_CreateInstanceRequest.Merge(dst, src) } func (m *CreateInstanceRequest) XXX_Size() int { return xxx_messageInfo_CreateInstanceRequest.Size(m) } func (m *CreateInstanceRequest) XXX_DiscardUnknown() { xxx_messageInfo_CreateInstanceRequest.DiscardUnknown(m) } var xxx_messageInfo_CreateInstanceRequest proto.InternalMessageInfo func (m *CreateInstanceRequest) GetParent() string { if m != nil { return m.Parent } return "" } func (m *CreateInstanceRequest) GetInstanceId() string { if m != nil { return m.InstanceId } return "" } func (m *CreateInstanceRequest) GetInstance() *Instance { if m != nil { return m.Instance } return nil } // The request for [ListInstances][google.spanner.admin.instance.v1.InstanceAdmin.ListInstances]. type ListInstancesRequest struct { // Required. The name of the project for which a list of instances is // requested. Values are of the form `projects/<project>`. Parent string `protobuf:"bytes,1,opt,name=parent" json:"parent,omitempty"` // Number of instances to be returned in the response. If 0 or less, defaults // to the server's maximum allowed page size. PageSize int32 `protobuf:"varint,2,opt,name=page_size,json=pageSize" json:"page_size,omitempty"` // If non-empty, `page_token` should contain a // [next_page_token][google.spanner.admin.instance.v1.ListInstancesResponse.next_page_token] from a // previous [ListInstancesResponse][google.spanner.admin.instance.v1.ListInstancesResponse]. PageToken string `protobuf:"bytes,3,opt,name=page_token,json=pageToken" json:"page_token,omitempty"` // An expression for filtering the results of the request. Filter rules are // case insensitive. The fields eligible for filtering are: // // * `name` // * `display_name` // * `labels.key` where key is the name of a label // // Some examples of using filters are: // // * `name:*` --> The instance has a name. // * `name:Howl` --> The instance's name contains the string "howl". // * `name:HOWL` --> Equivalent to above. // * `NAME:howl` --> Equivalent to above. // * `labels.env:*` --> The instance has the label "env". // * `labels.env:dev` --> The instance has the label "env" and the value of // the label contains the string "dev". // * `name:howl labels.env:dev` --> The instance's name contains "howl" and // it has the label "env" with its value // containing "dev". Filter string `protobuf:"bytes,4,opt,name=filter" json:"filter,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *ListInstancesRequest) Reset() { *m = ListInstancesRequest{} } func (m *ListInstancesRequest) String() string { return proto.CompactTextString(m) } func (*ListInstancesRequest) ProtoMessage() {} func (*ListInstancesRequest) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{7} } func (m *ListInstancesRequest) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_ListInstancesRequest.Unmarshal(m, b) } func (m *ListInstancesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_ListInstancesRequest.Marshal(b, m, deterministic) } func (dst *ListInstancesRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_ListInstancesRequest.Merge(dst, src) } func (m *ListInstancesRequest) XXX_Size() int { return xxx_messageInfo_ListInstancesRequest.Size(m) } func (m *ListInstancesRequest) XXX_DiscardUnknown() { xxx_messageInfo_ListInstancesRequest.DiscardUnknown(m) } var xxx_messageInfo_ListInstancesRequest proto.InternalMessageInfo func (m *ListInstancesRequest) GetParent() string { if m != nil { return m.Parent } return "" } func (m *ListInstancesRequest) GetPageSize() int32 { if m != nil { return m.PageSize } return 0 } func (m *ListInstancesRequest) GetPageToken() string { if m != nil { return m.PageToken } return "" } func (m *ListInstancesRequest) GetFilter() string { if m != nil { return m.Filter } return "" } // The response for [ListInstances][google.spanner.admin.instance.v1.InstanceAdmin.ListInstances]. type ListInstancesResponse struct { // The list of requested instances. Instances []*Instance `protobuf:"bytes,1,rep,name=instances" json:"instances,omitempty"` // `next_page_token` can be sent in a subsequent // [ListInstances][google.spanner.admin.instance.v1.InstanceAdmin.ListInstances] call to fetch more // of the matching instances. NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken" json:"next_page_token,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *ListInstancesResponse) Reset() { *m = ListInstancesResponse{} } func (m *ListInstancesResponse) String() string { return proto.CompactTextString(m) } func (*ListInstancesResponse) ProtoMessage() {} func (*ListInstancesResponse) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{8} } func (m *ListInstancesResponse) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_ListInstancesResponse.Unmarshal(m, b) } func (m *ListInstancesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_ListInstancesResponse.Marshal(b, m, deterministic) } func (dst *ListInstancesResponse) XXX_Merge(src proto.Message) { xxx_messageInfo_ListInstancesResponse.Merge(dst, src) } func (m *ListInstancesResponse) XXX_Size() int { return xxx_messageInfo_ListInstancesResponse.Size(m) } func (m *ListInstancesResponse) XXX_DiscardUnknown() { xxx_messageInfo_ListInstancesResponse.DiscardUnknown(m) } var xxx_messageInfo_ListInstancesResponse proto.InternalMessageInfo func (m *ListInstancesResponse) GetInstances() []*Instance { if m != nil { return m.Instances } return nil } func (m *ListInstancesResponse) GetNextPageToken() string { if m != nil { return m.NextPageToken } return "" } // The request for [UpdateInstance][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstance]. type UpdateInstanceRequest struct { // Required. The instance to update, which must always include the instance // name. Otherwise, only fields mentioned in [][google.spanner.admin.instance.v1.UpdateInstanceRequest.field_mask] need be included. Instance *Instance `protobuf:"bytes,1,opt,name=instance" json:"instance,omitempty"` // Required. A mask specifying which fields in [][google.spanner.admin.instance.v1.UpdateInstanceRequest.instance] should be updated. // The field mask must always be specified; this prevents any future fields in // [][google.spanner.admin.instance.v1.Instance] from being erased accidentally by clients that do not know // about them. FieldMask *field_mask.FieldMask `protobuf:"bytes,2,opt,name=field_mask,json=fieldMask" json:"field_mask,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *UpdateInstanceRequest) Reset() { *m = UpdateInstanceRequest{} } func (m *UpdateInstanceRequest) String() string { return proto.CompactTextString(m) } func (*UpdateInstanceRequest) ProtoMessage() {} func (*UpdateInstanceRequest) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{9} } func (m *UpdateInstanceRequest) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_UpdateInstanceRequest.Unmarshal(m, b) } func (m *UpdateInstanceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_UpdateInstanceRequest.Marshal(b, m, deterministic) } func (dst *UpdateInstanceRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_UpdateInstanceRequest.Merge(dst, src) } func (m *UpdateInstanceRequest) XXX_Size() int { return xxx_messageInfo_UpdateInstanceRequest.Size(m) } func (m *UpdateInstanceRequest) XXX_DiscardUnknown() { xxx_messageInfo_UpdateInstanceRequest.DiscardUnknown(m) } var xxx_messageInfo_UpdateInstanceRequest proto.InternalMessageInfo func (m *UpdateInstanceRequest) GetInstance() *Instance { if m != nil { return m.Instance } return nil } func (m *UpdateInstanceRequest) GetFieldMask() *field_mask.FieldMask { if m != nil { return m.FieldMask } return nil } // The request for [DeleteInstance][google.spanner.admin.instance.v1.InstanceAdmin.DeleteInstance]. type DeleteInstanceRequest struct { // Required. The name of the instance to be deleted. Values are of the form // `projects/<project>/instances/<instance>` Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *DeleteInstanceRequest) Reset() { *m = DeleteInstanceRequest{} } func (m *DeleteInstanceRequest) String() string { return proto.CompactTextString(m) } func (*DeleteInstanceRequest) ProtoMessage() {} func (*DeleteInstanceRequest) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{10} } func (m *DeleteInstanceRequest) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_DeleteInstanceRequest.Unmarshal(m, b) } func (m *DeleteInstanceRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_DeleteInstanceRequest.Marshal(b, m, deterministic) } func (dst *DeleteInstanceRequest) XXX_Merge(src proto.Message) { xxx_messageInfo_DeleteInstanceRequest.Merge(dst, src) } func (m *DeleteInstanceRequest) XXX_Size() int { return xxx_messageInfo_DeleteInstanceRequest.Size(m) } func (m *DeleteInstanceRequest) XXX_DiscardUnknown() { xxx_messageInfo_DeleteInstanceRequest.DiscardUnknown(m) } var xxx_messageInfo_DeleteInstanceRequest proto.InternalMessageInfo func (m *DeleteInstanceRequest) GetName() string { if m != nil { return m.Name } return "" } // Metadata type for the operation returned by // [CreateInstance][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstance]. type CreateInstanceMetadata struct { // The instance being created. Instance *Instance `protobuf:"bytes,1,opt,name=instance" json:"instance,omitempty"` // The time at which the // [CreateInstance][google.spanner.admin.instance.v1.InstanceAdmin.CreateInstance] request was // received. StartTime *timestamp.Timestamp `protobuf:"bytes,2,opt,name=start_time,json=startTime" json:"start_time,omitempty"` // The time at which this operation was cancelled. If set, this operation is // in the process of undoing itself (which is guaranteed to succeed) and // cannot be cancelled again. CancelTime *timestamp.Timestamp `protobuf:"bytes,3,opt,name=cancel_time,json=cancelTime" json:"cancel_time,omitempty"` // The time at which this operation failed or was completed successfully. EndTime *timestamp.Timestamp `protobuf:"bytes,4,opt,name=end_time,json=endTime" json:"end_time,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *CreateInstanceMetadata) Reset() { *m = CreateInstanceMetadata{} } func (m *CreateInstanceMetadata) String() string { return proto.CompactTextString(m) } func (*CreateInstanceMetadata) ProtoMessage() {} func (*CreateInstanceMetadata) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{11} } func (m *CreateInstanceMetadata) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_CreateInstanceMetadata.Unmarshal(m, b) } func (m *CreateInstanceMetadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_CreateInstanceMetadata.Marshal(b, m, deterministic) } func (dst *CreateInstanceMetadata) XXX_Merge(src proto.Message) { xxx_messageInfo_CreateInstanceMetadata.Merge(dst, src) } func (m *CreateInstanceMetadata) XXX_Size() int { return xxx_messageInfo_CreateInstanceMetadata.Size(m) } func (m *CreateInstanceMetadata) XXX_DiscardUnknown() { xxx_messageInfo_CreateInstanceMetadata.DiscardUnknown(m) } var xxx_messageInfo_CreateInstanceMetadata proto.InternalMessageInfo func (m *CreateInstanceMetadata) GetInstance() *Instance { if m != nil { return m.Instance } return nil } func (m *CreateInstanceMetadata) GetStartTime() *timestamp.Timestamp { if m != nil { return m.StartTime } return nil } func (m *CreateInstanceMetadata) GetCancelTime() *timestamp.Timestamp { if m != nil { return m.CancelTime } return nil } func (m *CreateInstanceMetadata) GetEndTime() *timestamp.Timestamp { if m != nil { return m.EndTime } return nil } // Metadata type for the operation returned by // [UpdateInstance][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstance]. type UpdateInstanceMetadata struct { // The desired end state of the update. Instance *Instance `protobuf:"bytes,1,opt,name=instance" json:"instance,omitempty"` // The time at which [UpdateInstance][google.spanner.admin.instance.v1.InstanceAdmin.UpdateInstance] // request was received. StartTime *timestamp.Timestamp `protobuf:"bytes,2,opt,name=start_time,json=startTime" json:"start_time,omitempty"` // The time at which this operation was cancelled. If set, this operation is // in the process of undoing itself (which is guaranteed to succeed) and // cannot be cancelled again. CancelTime *timestamp.Timestamp `protobuf:"bytes,3,opt,name=cancel_time,json=cancelTime" json:"cancel_time,omitempty"` // The time at which this operation failed or was completed successfully. EndTime *timestamp.Timestamp `protobuf:"bytes,4,opt,name=end_time,json=endTime" json:"end_time,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` } func (m *UpdateInstanceMetadata) Reset() { *m = UpdateInstanceMetadata{} } func (m *UpdateInstanceMetadata) String() string { return proto.CompactTextString(m) } func (*UpdateInstanceMetadata) ProtoMessage() {} func (*UpdateInstanceMetadata) Descriptor() ([]byte, []int) { return fileDescriptor_spanner_instance_admin_5b5a46734047df3a, []int{12} } func (m *UpdateInstanceMetadata) XXX_Unmarshal(b []byte) error { return xxx_messageInfo_UpdateInstanceMetadata.Unmarshal(m, b) } func (m *UpdateInstanceMetadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { return xxx_messageInfo_UpdateInstanceMetadata.Marshal(b, m, deterministic) } func (dst *UpdateInstanceMetadata) XXX_Merge(src proto.Message) { xxx_messageInfo_UpdateInstanceMetadata.Merge(dst, src) } func (m *UpdateInstanceMetadata) XXX_Size() int { return xxx_messageInfo_UpdateInstanceMetadata.Size(m) } func (m *UpdateInstanceMetadata) XXX_DiscardUnknown() { xxx_messageInfo_UpdateInstanceMetadata.DiscardUnknown(m) } var xxx_messageInfo_UpdateInstanceMetadata proto.InternalMessageInfo func (m *UpdateInstanceMetadata) GetInstance() *Instance { if m != nil { return m.Instance } return nil } func (m *UpdateInstanceMetadata) GetStartTime() *timestamp.Timestamp { if m != nil { return m.StartTime } return nil } func (m *UpdateInstanceMetadata) GetCancelTime() *timestamp.Timestamp { if m != nil { return m.CancelTime } return nil } func (m *UpdateInstanceMetadata) GetEndTime() *timestamp.Timestamp { if m != nil { return m.EndTime } return nil } func init() { proto.RegisterType((*InstanceConfig)(nil), "google.spanner.admin.instance.v1.InstanceConfig") proto.RegisterType((*Instance)(nil), "google.spanner.admin.instance.v1.Instance") proto.RegisterMapType((map[string]string)(nil), "google.spanner.admin.instance.v1.Instance.LabelsEntry") proto.RegisterType((*ListInstanceConfigsRequest)(nil), "google.spanner.admin.instance.v1.ListInstanceConfigsRequest") proto.RegisterType((*ListInstanceConfigsResponse)(nil), "google.spanner.admin.instance.v1.ListInstanceConfigsResponse") proto.RegisterType((*GetInstanceConfigRequest)(nil), "google.spanner.admin.instance.v1.GetInstanceConfigRequest") proto.RegisterType((*GetInstanceRequest)(nil), "google.spanner.admin.instance.v1.GetInstanceRequest") proto.RegisterType((*CreateInstanceRequest)(nil), "google.spanner.admin.instance.v1.CreateInstanceRequest") proto.RegisterType((*ListInstancesRequest)(nil), "google.spanner.admin.instance.v1.ListInstancesRequest") proto.RegisterType((*ListInstancesResponse)(nil), "google.spanner.admin.instance.v1.ListInstancesResponse") proto.RegisterType((*UpdateInstanceRequest)(nil), "google.spanner.admin.instance.v1.UpdateInstanceRequest") proto.RegisterType((*DeleteInstanceRequest)(nil), "google.spanner.admin.instance.v1.DeleteInstanceRequest") proto.RegisterType((*CreateInstanceMetadata)(nil), "google.spanner.admin.instance.v1.CreateInstanceMetadata") proto.RegisterType((*UpdateInstanceMetadata)(nil), "google.spanner.admin.instance.v1.UpdateInstanceMetadata") proto.RegisterEnum("google.spanner.admin.instance.v1.Instance_State", Instance_State_name, Instance_State_value) } // Reference imports to suppress errors if they are not otherwise used. var _ context.Context var _ grpc.ClientConn // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. const _ = grpc.SupportPackageIsVersion4 // InstanceAdminClient is the client API for InstanceAdmin service. // // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. type InstanceAdminClient interface { // Lists the supported instance configurations for a given project. ListInstanceConfigs(ctx context.Context, in *ListInstanceConfigsRequest, opts ...grpc.CallOption) (*ListInstanceConfigsResponse, error) // Gets information about a particular instance configuration. GetInstanceConfig(ctx context.Context, in *GetInstanceConfigRequest, opts ...grpc.CallOption) (*InstanceConfig, error) // Lists all instances in the given project. ListInstances(ctx context.Context, in *ListInstancesRequest, opts ...grpc.CallOption) (*ListInstancesResponse, error) // Gets information about a particular instance. GetInstance(ctx context.Context, in *GetInstanceRequest, opts ...grpc.CallOption) (*Instance, error) // Creates an instance and begins preparing it to begin serving. The // returned [long-running operation][google.longrunning.Operation] // can be used to track the progress of preparing the new // instance. The instance name is assigned by the caller. If the // named instance already exists, `CreateInstance` returns // `ALREADY_EXISTS`. // // Immediately upon completion of this request: // // * The instance is readable via the API, with all requested attributes // but no allocated resources. Its state is `CREATING`. // // Until completion of the returned operation: // // * Cancelling the operation renders the instance immediately unreadable // via the API. // * The instance can be deleted. // * All other attempts to modify the instance are rejected. // // Upon completion of the returned operation: // // * Billing for all successfully-allocated resources begins (some types // may have lower than the requested levels). // * Databases can be created in the instance. // * The instance's allocated resource levels are readable via the API. // * The instance's state becomes `READY`. // // The returned [long-running operation][google.longrunning.Operation] will // have a name of the format `<instance_name>/operations/<operation_id>` and // can be used to track creation of the instance. The // [metadata][google.longrunning.Operation.metadata] field type is // [CreateInstanceMetadata][google.spanner.admin.instance.v1.CreateInstanceMetadata]. // The [response][google.longrunning.Operation.response] field type is // [Instance][google.spanner.admin.instance.v1.Instance], if successful. CreateInstance(ctx context.Context, in *CreateInstanceRequest, opts ...grpc.CallOption) (*longrunning.Operation, error) // Updates an instance, and begins allocating or releasing resources // as requested. The returned [long-running // operation][google.longrunning.Operation] can be used to track the // progress of updating the instance. If the named instance does not // exist, returns `NOT_FOUND`. // // Immediately upon completion of this request: // // * For resource types for which a decrease in the instance's allocation // has been requested, billing is based on the newly-requested level. // // Until completion of the returned operation: // // * Cancelling the operation sets its metadata's // [cancel_time][google.spanner.admin.instance.v1.UpdateInstanceMetadata.cancel_time], and begins // restoring resources to their pre-request values. The operation // is guaranteed to succeed at undoing all resource changes, // after which point it terminates with a `CANCELLED` status. // * All other attempts to modify the instance are rejected. // * Reading the instance via the API continues to give the pre-request // resource levels. // // Upon completion of the returned operation: // // * Billing begins for all successfully-allocated resources (some types // may have lower than the requested levels). // * All newly-reserved resources are available for serving the instance's // tables. // * The instance's new resource levels are readable via the API. // // The returned [long-running operation][google.longrunning.Operation] will // have a name of the format `<instance_name>/operations/<operation_id>` and // can be used to track the instance modification. The // [metadata][google.longrunning.Operation.metadata] field type is // [UpdateInstanceMetadata][google.spanner.admin.instance.v1.UpdateInstanceMetadata]. // The [response][google.longrunning.Operation.response] field type is // [Instance][google.spanner.admin.instance.v1.Instance], if successful. // // Authorization requires `spanner.instances.update` permission on // resource [name][google.spanner.admin.instance.v1.Instance.name]. UpdateInstance(ctx context.Context, in *UpdateInstanceRequest, opts ...grpc.CallOption) (*longrunning.Operation, error) // Deletes an instance. // // Immediately upon completion of the request: // // * Billing ceases for all of the instance's reserved resources. // // Soon afterward: // // * The instance and *all of its databases* immediately and // irrevocably disappear from the API. All data in the databases // is permanently deleted. DeleteInstance(ctx context.Context, in *DeleteInstanceRequest, opts ...grpc.CallOption) (*empty.Empty, error) // Sets the access control policy on an instance resource. Replaces any // existing policy. // // Authorization requires `spanner.instances.setIamPolicy` on // [resource][google.iam.v1.SetIamPolicyRequest.resource]. SetIamPolicy(ctx context.Context, in *v1.SetIamPolicyRequest, opts ...grpc.CallOption) (*v1.Policy, error) // Gets the access control policy for an instance resource. Returns an empty // policy if an instance exists but does not have a policy set. // // Authorization requires `spanner.instances.getIamPolicy` on // [resource][google.iam.v1.GetIamPolicyRequest.resource]. GetIamPolicy(ctx context.Context, in *v1.GetIamPolicyRequest, opts ...grpc.CallOption) (*v1.Policy, error) // Returns permissions that the caller has on the specified instance resource. // // Attempting this RPC on a non-existent Cloud Spanner instance resource will // result in a NOT_FOUND error if the user has `spanner.instances.list` // permission on the containing Google Cloud Project. Otherwise returns an // empty set of permissions. TestIamPermissions(ctx context.Context, in *v1.TestIamPermissionsRequest, opts ...grpc.CallOption) (*v1.TestIamPermissionsResponse, error) } type instanceAdminClient struct { cc *grpc.ClientConn } func NewInstanceAdminClient(cc *grpc.ClientConn) InstanceAdminClient { return &instanceAdminClient{cc} } func (c *instanceAdminClient) ListInstanceConfigs(ctx context.Context, in *ListInstanceConfigsRequest, opts ...grpc.CallOption) (*ListInstanceConfigsResponse, error) { out := new(ListInstanceConfigsResponse) err := c.cc.Invoke(ctx, "/google.spanner.admin.instance.v1.InstanceAdmin/ListInstanceConfigs", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *instanceAdminClient) GetInstanceConfig(ctx context.Context, in *GetInstanceConfigRequest, opts ...grpc.CallOption) (*InstanceConfig, error) { out := new(InstanceConfig) err := c.cc.Invoke(ctx, "/google.spanner.admin.instance.v1.InstanceAdmin/GetInstanceConfig", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *instanceAdminClient) ListInstances(ctx context.Context, in *ListInstancesRequest, opts ...grpc.CallOption) (*ListInstancesResponse, error) { out := new(ListInstancesResponse) err := c.cc.Invoke(ctx, "/google.spanner.admin.instance.v1.InstanceAdmin/ListInstances", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *instanceAdminClient) GetInstance(ctx context.Context, in *GetInstanceRequest, opts ...grpc.CallOption) (*Instance, error) { out := new(Instance) err := c.cc.Invoke(ctx, "/google.spanner.admin.instance.v1.InstanceAdmin/GetInstance", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *instanceAdminClient) CreateInstance(ctx context.Context, in *CreateInstanceRequest, opts ...grpc.CallOption) (*longrunning.Operation, error) { out := new(longrunning.Operation) err := c.cc.Invoke(ctx, "/google.spanner.admin.instance.v1.InstanceAdmin/CreateInstance", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *instanceAdminClient) UpdateInstance(ctx context.Context, in *UpdateInstanceRequest, opts ...grpc.CallOption) (*longrunning.Operation, error) { out := new(longrunning.Operation) err := c.cc.Invoke(ctx, "/google.spanner.admin.instance.v1.InstanceAdmin/UpdateInstance", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *instanceAdminClient) DeleteInstance(ctx context.Context, in *DeleteInstanceRequest, opts ...grpc.CallOption) (*empty.Empty, error) { out := new(empty.Empty) err := c.cc.Invoke(ctx, "/google.spanner.admin.instance.v1.InstanceAdmin/DeleteInstance", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *instanceAdminClient) SetIamPolicy(ctx context.Context, in *v1.SetIamPolicyRequest, opts ...grpc.CallOption) (*v1.Policy, error) { out := new(v1.Policy) err := c.cc.Invoke(ctx, "/google.spanner.admin.instance.v1.InstanceAdmin/SetIamPolicy", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *instanceAdminClient) GetIamPolicy(ctx context.Context, in *v1.GetIamPolicyRequest, opts ...grpc.CallOption) (*v1.Policy, error) { out := new(v1.Policy) err := c.cc.Invoke(ctx, "/google.spanner.admin.instance.v1.InstanceAdmin/GetIamPolicy", in, out, opts...) if err != nil { return nil, err } return out, nil } func (c *instanceAdminClient) TestIamPermissions(ctx context.Context, in *v1.TestIamPermissionsRequest, opts ...grpc.CallOption) (*v1.TestIamPermissionsResponse, error) { out := new(v1.TestIamPermissionsResponse) err := c.cc.Invoke(ctx, "/google.spanner.admin.instance.v1.InstanceAdmin/TestIamPermissions", in, out, opts...) if err != nil { return nil, err } return out, nil } // Server API for InstanceAdmin service type InstanceAdminServer interface { // Lists the supported instance configurations for a given project. ListInstanceConfigs(context.Context, *ListInstanceConfigsRequest) (*ListInstanceConfigsResponse, error) // Gets information about a particular instance configuration. GetInstanceConfig(context.Context, *GetInstanceConfigRequest) (*InstanceConfig, error) // Lists all instances in the given project. ListInstances(context.Context, *ListInstancesRequest) (*ListInstancesResponse, error) // Gets information about a particular instance. GetInstance(context.Context, *GetInstanceRequest) (*Instance, error) // Creates an instance and begins preparing it to begin serving. The // returned [long-running operation][google.longrunning.Operation] // can be used to track the progress of preparing the new // instance. The instance name is assigned by the caller. If the // named instance already exists, `CreateInstance` returns // `ALREADY_EXISTS`. // // Immediately upon completion of this request: // // * The instance is readable via the API, with all requested attributes // but no allocated resources. Its state is `CREATING`. // // Until completion of the returned operation: // // * Cancelling the operation renders the instance immediately unreadable // via the API. // * The instance can be deleted. // * All other attempts to modify the instance are rejected. // // Upon completion of the returned operation: // // * Billing for all successfully-allocated resources begins (some types // may have lower than the requested levels). // * Databases can be created in the instance. // * The instance's allocated resource levels are readable via the API. // * The instance's state becomes `READY`. // // The returned [long-running operation][google.longrunning.Operation] will // have a name of the format `<instance_name>/operations/<operation_id>` and // can be used to track creation of the instance. The // [metadata][google.longrunning.Operation.metadata] field type is // [CreateInstanceMetadata][google.spanner.admin.instance.v1.CreateInstanceMetadata]. // The [response][google.longrunning.Operation.response] field type is // [Instance][google.spanner.admin.instance.v1.Instance], if successful. CreateInstance(context.Context, *CreateInstanceRequest) (*longrunning.Operation, error) // Updates an instance, and begins allocating or releasing resources // as requested. The returned [long-running // operation][google.longrunning.Operation] can be used to track the // progress of updating the instance. If the named instance does not // exist, returns `NOT_FOUND`. // // Immediately upon completion of this request: // // * For resource types for which a decrease in the instance's allocation // has been requested, billing is based on the newly-requested level. // // Until completion of the returned operation: // // * Cancelling the operation sets its metadata's // [cancel_time][google.spanner.admin.instance.v1.UpdateInstanceMetadata.cancel_time], and begins // restoring resources to their pre-request values. The operation // is guaranteed to succeed at undoing all resource changes, // after which point it terminates with a `CANCELLED` status. // * All other attempts to modify the instance are rejected. // * Reading the instance via the API continues to give the pre-request // resource levels. // // Upon completion of the returned operation: // // * Billing begins for all successfully-allocated resources (some types // may have lower than the requested levels). // * All newly-reserved resources are available for serving the instance's // tables. // * The instance's new resource levels are readable via the API. // // The returned [long-running operation][google.longrunning.Operation] will // have a name of the format `<instance_name>/operations/<operation_id>` and // can be used to track the instance modification. The // [metadata][google.longrunning.Operation.metadata] field type is // [UpdateInstanceMetadata][google.spanner.admin.instance.v1.UpdateInstanceMetadata]. // The [response][google.longrunning.Operation.response] field type is // [Instance][google.spanner.admin.instance.v1.Instance], if successful. // // Authorization requires `spanner.instances.update` permission on // resource [name][google.spanner.admin.instance.v1.Instance.name]. UpdateInstance(context.Context, *UpdateInstanceRequest) (*longrunning.Operation, error) // Deletes an instance. // // Immediately upon completion of the request: // // * Billing ceases for all of the instance's reserved resources. // // Soon afterward: // // * The instance and *all of its databases* immediately and // irrevocably disappear from the API. All data in the databases // is permanently deleted. DeleteInstance(context.Context, *DeleteInstanceRequest) (*empty.Empty, error) // Sets the access control policy on an instance resource. Replaces any // existing policy. // // Authorization requires `spanner.instances.setIamPolicy` on // [resource][google.iam.v1.SetIamPolicyRequest.resource]. SetIamPolicy(context.Context, *v1.SetIamPolicyRequest) (*v1.Policy, error) // Gets the access control policy for an instance resource. Returns an empty // policy if an instance exists but does not have a policy set. // // Authorization requires `spanner.instances.getIamPolicy` on // [resource][google.iam.v1.GetIamPolicyRequest.resource]. GetIamPolicy(context.Context, *v1.GetIamPolicyRequest) (*v1.Policy, error) // Returns permissions that the caller has on the specified instance resource. // // Attempting this RPC on a non-existent Cloud Spanner instance resource will // result in a NOT_FOUND error if the user has `spanner.instances.list` // permission on the containing Google Cloud Project. Otherwise returns an // empty set of permissions. TestIamPermissions(context.Context, *v1.TestIamPermissionsRequest) (*v1.TestIamPermissionsResponse, error) } func RegisterInstanceAdminServer(s *grpc.Server, srv InstanceAdminServer) { s.RegisterService(&_InstanceAdmin_serviceDesc, srv) } func _InstanceAdmin_ListInstanceConfigs_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ListInstanceConfigsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(InstanceAdminServer).ListInstanceConfigs(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/google.spanner.admin.instance.v1.InstanceAdmin/ListInstanceConfigs", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(InstanceAdminServer).ListInstanceConfigs(ctx, req.(*ListInstanceConfigsRequest)) } return interceptor(ctx, in, info, handler) } func _InstanceAdmin_GetInstanceConfig_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(GetInstanceConfigRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(InstanceAdminServer).GetInstanceConfig(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/google.spanner.admin.instance.v1.InstanceAdmin/GetInstanceConfig", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(InstanceAdminServer).GetInstanceConfig(ctx, req.(*GetInstanceConfigRequest)) } return interceptor(ctx, in, info, handler) } func _InstanceAdmin_ListInstances_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(ListInstancesRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(InstanceAdminServer).ListInstances(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/google.spanner.admin.instance.v1.InstanceAdmin/ListInstances", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(InstanceAdminServer).ListInstances(ctx, req.(*ListInstancesRequest)) } return interceptor(ctx, in, info, handler) } func _InstanceAdmin_GetInstance_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(GetInstanceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(InstanceAdminServer).GetInstance(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/google.spanner.admin.instance.v1.InstanceAdmin/GetInstance", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(InstanceAdminServer).GetInstance(ctx, req.(*GetInstanceRequest)) } return interceptor(ctx, in, info, handler) } func _InstanceAdmin_CreateInstance_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(CreateInstanceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(InstanceAdminServer).CreateInstance(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/google.spanner.admin.instance.v1.InstanceAdmin/CreateInstance", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(InstanceAdminServer).CreateInstance(ctx, req.(*CreateInstanceRequest)) } return interceptor(ctx, in, info, handler) } func _InstanceAdmin_UpdateInstance_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(UpdateInstanceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(InstanceAdminServer).UpdateInstance(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/google.spanner.admin.instance.v1.InstanceAdmin/UpdateInstance", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(InstanceAdminServer).UpdateInstance(ctx, req.(*UpdateInstanceRequest)) } return interceptor(ctx, in, info, handler) } func _InstanceAdmin_DeleteInstance_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(DeleteInstanceRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(InstanceAdminServer).DeleteInstance(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/google.spanner.admin.instance.v1.InstanceAdmin/DeleteInstance", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(InstanceAdminServer).DeleteInstance(ctx, req.(*DeleteInstanceRequest)) } return interceptor(ctx, in, info, handler) } func _InstanceAdmin_SetIamPolicy_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(v1.SetIamPolicyRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(InstanceAdminServer).SetIamPolicy(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/google.spanner.admin.instance.v1.InstanceAdmin/SetIamPolicy", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(InstanceAdminServer).SetIamPolicy(ctx, req.(*v1.SetIamPolicyRequest)) } return interceptor(ctx, in, info, handler) } func _InstanceAdmin_GetIamPolicy_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(v1.GetIamPolicyRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(InstanceAdminServer).GetIamPolicy(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/google.spanner.admin.instance.v1.InstanceAdmin/GetIamPolicy", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(InstanceAdminServer).GetIamPolicy(ctx, req.(*v1.GetIamPolicyRequest)) } return interceptor(ctx, in, info, handler) } func _InstanceAdmin_TestIamPermissions_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { in := new(v1.TestIamPermissionsRequest) if err := dec(in); err != nil { return nil, err } if interceptor == nil { return srv.(InstanceAdminServer).TestIamPermissions(ctx, in) } info := &grpc.UnaryServerInfo{ Server: srv, FullMethod: "/google.spanner.admin.instance.v1.InstanceAdmin/TestIamPermissions", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { return srv.(InstanceAdminServer).TestIamPermissions(ctx, req.(*v1.TestIamPermissionsRequest)) } return interceptor(ctx, in, info, handler) } var _InstanceAdmin_serviceDesc = grpc.ServiceDesc{ ServiceName: "google.spanner.admin.instance.v1.InstanceAdmin", HandlerType: (*InstanceAdminServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "ListInstanceConfigs", Handler: _InstanceAdmin_ListInstanceConfigs_Handler, }, { MethodName: "GetInstanceConfig", Handler: _InstanceAdmin_GetInstanceConfig_Handler, }, { MethodName: "ListInstances", Handler: _InstanceAdmin_ListInstances_Handler, }, { MethodName: "GetInstance", Handler: _InstanceAdmin_GetInstance_Handler, }, { MethodName: "CreateInstance", Handler: _InstanceAdmin_CreateInstance_Handler, }, { MethodName: "UpdateInstance", Handler: _InstanceAdmin_UpdateInstance_Handler, }, { MethodName: "DeleteInstance", Handler: _InstanceAdmin_DeleteInstance_Handler, }, { MethodName: "SetIamPolicy", Handler: _InstanceAdmin_SetIamPolicy_Handler, }, { MethodName: "GetIamPolicy", Handler: _InstanceAdmin_GetIamPolicy_Handler, }, { MethodName: "TestIamPermissions", Handler: _InstanceAdmin_TestIamPermissions_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "google/spanner/admin/instance/v1/spanner_instance_admin.proto", } func init() { proto.RegisterFile("google/spanner/admin/instance/v1/spanner_instance_admin.proto", fileDescriptor_spanner_instance_admin_5b5a46734047df3a) } var fileDescriptor_spanner_instance_admin_5b5a46734047df3a = []byte{ // 1210 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x57, 0x4f, 0x6f, 0x1b, 0x45, 0x14, 0x67, 0x92, 0x3a, 0x8d, 0x9f, 0xd3, 0x34, 0x1d, 0x9a, 0xca, 0xb8, 0x94, 0xa6, 0x5b, 0x54, 0x5c, 0x83, 0x76, 0x89, 0xa1, 0xff, 0x52, 0x72, 0x48, 0x5d, 0xc7, 0xb5, 0xd4, 0x86, 0x68, 0xed, 0x56, 0x02, 0x22, 0x59, 0x53, 0x7b, 0x62, 0x2d, 0xd9, 0x9d, 0x5d, 0x76, 0xc6, 0x15, 0x29, 0xea, 0xa5, 0xe2, 0x00, 0x12, 0x12, 0x07, 0x24, 0x84, 0x7a, 0x41, 0xe2, 0x08, 0x12, 0x07, 0xbe, 0x02, 0x37, 0xae, 0x7c, 0x00, 0x2e, 0x88, 0xcf, 0x81, 0x66, 0x76, 0xc7, 0xf5, 0xae, 0xed, 0xd8, 0xae, 0xe8, 0x89, 0xdb, 0xce, 0xbc, 0xdf, 0x7b, 0xef, 0x37, 0xbf, 0x37, 0xfb, 0xde, 0x2e, 0x6c, 0x76, 0x7d, 0xbf, 0xeb, 0x52, 0x8b, 0x07, 0x84, 0x31, 0x1a, 0x5a, 0xa4, 0xe3, 0x39, 0xcc, 0x72, 0x18, 0x17, 0x84, 0xb5, 0xa9, 0xf5, 0x68, 0x5d, 0x5b, 0x5a, 0x7a, 0xaf, 0xa5, 0x20, 0x66, 0x10, 0xfa, 0xc2, 0xc7, 0x6b, 0x91, 0xbb, 0x19, 0x83, 0xcc, 0xc8, 0xa6, 0xa1, 0xe6, 0xa3, 0xf5, 0xc2, 0xeb, 0x71, 0x02, 0x12, 0x38, 0x16, 0x61, 0xcc, 0x17, 0x44, 0x38, 0x3e, 0xe3, 0x91, 0x7f, 0xe1, 0x8d, 0xd8, 0xea, 0x10, 0x4f, 0xe6, 0x72, 0x88, 0xd7, 0x0a, 0x7c, 0xd7, 0x69, 0x1f, 0xc6, 0xf6, 0x42, 0xd2, 0x9e, 0xb0, 0x5d, 0x8c, 0x6d, 0xae, 0xcf, 0xba, 0x61, 0x8f, 0x31, 0x87, 0x75, 0x2d, 0x3f, 0xa0, 0x61, 0x22, 0xc1, 0xd9, 0x18, 0xa4, 0x56, 0x0f, 0x7b, 0xfb, 0x16, 0xf5, 0x02, 0xa1, 0x23, 0xac, 0xa5, 0x8d, 0xfb, 0x0e, 0x75, 0x3b, 0x2d, 0x8f, 0xf0, 0x83, 0x18, 0x71, 0x3e, 0x8d, 0x10, 0x8e, 0x47, 0xb9, 0x20, 0x5e, 0x10, 0x01, 0x8c, 0x1a, 0x2c, 0xd7, 0xe3, 0xd3, 0x56, 0x7c, 0xb6, 0xef, 0x74, 0x31, 0x86, 0x63, 0x8c, 0x78, 0x34, 0x8f, 0xd6, 0x50, 0x31, 0x6b, 0xab, 0x67, 0x7c, 0x01, 0x96, 0x3a, 0x0e, 0x0f, 0x5c, 0x72, 0xd8, 0x52, 0xb6, 0x39, 0x65, 0xcb, 0xc5, 0x7b, 0x3b, 0xc4, 0xa3, 0xc6, 0x97, 0xf3, 0xb0, 0xa8, 0x23, 0x8d, 0x8c, 0x71, 0x06, 0x16, 0xda, 0x2a, 0x43, 0xec, 0x1d, 0xaf, 0x86, 0x62, 0xcf, 0x0f, 0xc5, 0xc6, 0xe7, 0x00, 0x98, 0xdf, 0xa1, 0xad, 0xb6, 0xdf, 0x63, 0x22, 0x9f, 0x59, 0x43, 0xc5, 0x8c, 0x9d, 0x95, 0x3b, 0x15, 0xb9, 0x81, 0xb7, 0x21, 0xc3, 0x05, 0x11, 0x34, 0xbf, 0xb0, 0x86, 0x8a, 0xcb, 0xe5, 0x77, 0xcd, 0x49, 0x45, 0x35, 0x35, 0x51, 0xb3, 0x21, 0xfd, 0xec, 0xc8, 0x1d, 0xef, 0xc0, 0x82, 0x4b, 0x1e, 0x52, 0x97, 0xe7, 0x8f, 0xaf, 0xcd, 0x17, 0x73, 0xe5, 0xab, 0x33, 0x04, 0xba, 0xab, 0x1c, 0xab, 0x4c, 0x84, 0x87, 0x76, 0x1c, 0xa5, 0x70, 0x03, 0x72, 0x03, 0xdb, 0x78, 0x05, 0xe6, 0x0f, 0xe8, 0x61, 0xac, 0x89, 0x7c, 0xc4, 0xa7, 0x21, 0xf3, 0x88, 0xb8, 0x3d, 0xad, 0x67, 0xb4, 0xd8, 0x98, 0xbb, 0x8e, 0x8c, 0x6b, 0x90, 0x51, 0xd4, 0xf0, 0x2a, 0x9c, 0x6a, 0x34, 0xb7, 0x9a, 0xd5, 0xd6, 0xfd, 0x9d, 0xc6, 0x6e, 0xb5, 0x52, 0xdf, 0xae, 0x57, 0x6f, 0xaf, 0xbc, 0x82, 0x97, 0x60, 0xb1, 0x62, 0x57, 0xb7, 0x9a, 0xf5, 0x9d, 0xda, 0x0a, 0xc2, 0x59, 0xc8, 0xd8, 0xd5, 0xad, 0xdb, 0x1f, 0xad, 0xcc, 0x19, 0x01, 0x14, 0xee, 0x3a, 0x5c, 0x24, 0x6b, 0xca, 0x6d, 0xfa, 0x59, 0x8f, 0x72, 0x21, 0x6b, 0x10, 0x90, 0x90, 0x32, 0x11, 0xb3, 0x88, 0x57, 0xf8, 0x2c, 0x64, 0x03, 0xd2, 0xa5, 0x2d, 0xee, 0x3c, 0x8e, 0xc8, 0x64, 0xec, 0x45, 0xb9, 0xd1, 0x70, 0x1e, 0x2b, 0xf5, 0x95, 0x51, 0xf8, 0x07, 0x94, 0xc5, 0xe5, 0x51, 0xf0, 0xa6, 0xdc, 0x30, 0x7e, 0x42, 0x70, 0x76, 0x64, 0x4a, 0x1e, 0xf8, 0x8c, 0x53, 0xfc, 0x09, 0xac, 0xf4, 0x5f, 0xbd, 0xa8, 0xe4, 0x3c, 0x8f, 0x94, 0xbe, 0x33, 0x14, 0x2a, 0x0a, 0x6a, 0x9f, 0x74, 0x92, 0x49, 0xf0, 0x25, 0x38, 0xc9, 0xe8, 0xe7, 0xa2, 0x35, 0x40, 0x30, 0xd2, 0xf2, 0x84, 0xdc, 0xde, 0xed, 0x93, 0x34, 0x21, 0x5f, 0xa3, 0x29, 0x8a, 0x5a, 0x94, 0x11, 0x97, 0xd5, 0x28, 0x02, 0x1e, 0xc0, 0x1f, 0x85, 0xfc, 0x01, 0xc1, 0x6a, 0x25, 0xa4, 0x44, 0xd0, 0x34, 0x7a, 0x9c, 0xd8, 0xe7, 0x21, 0xd7, 0x17, 0xc4, 0xe9, 0xc4, 0x7c, 0x41, 0x6f, 0xd5, 0x3b, 0x78, 0x1b, 0x16, 0xf5, 0x4a, 0xc9, 0x9d, 0x2b, 0x97, 0xa6, 0x57, 0xca, 0xee, 0xfb, 0x1a, 0x4f, 0x11, 0x9c, 0x1e, 0xac, 0xcc, 0xcb, 0xbc, 0x06, 0x32, 0xe6, 0xbe, 0xe3, 0x0a, 0x1a, 0xe6, 0x8f, 0x45, 0x31, 0xa3, 0x95, 0xf1, 0x35, 0x82, 0xd5, 0x14, 0x89, 0xf8, 0x62, 0xdc, 0x81, 0xac, 0xa6, 0xaa, 0x6f, 0xc4, 0x2c, 0xe7, 0x7c, 0xee, 0x3c, 0xf5, 0x2d, 0x78, 0x86, 0x60, 0xf5, 0x7e, 0xd0, 0x19, 0x51, 0xab, 0x41, 0xc9, 0xd1, 0x8b, 0x4b, 0x8e, 0x6f, 0x00, 0x3c, 0xef, 0xc1, 0x8a, 0x44, 0xae, 0x5c, 0xd0, 0x91, 0x74, 0x13, 0x36, 0xb7, 0x25, 0xe4, 0x1e, 0xe1, 0x07, 0x76, 0x76, 0x5f, 0x3f, 0x1a, 0x6f, 0xc3, 0xea, 0x6d, 0xea, 0xd2, 0x61, 0x6e, 0xa3, 0x6e, 0xdd, 0xb7, 0x73, 0x70, 0x26, 0x79, 0xeb, 0xee, 0x51, 0x41, 0x3a, 0x44, 0x90, 0xff, 0xf2, 0x28, 0x5c, 0x90, 0x50, 0xb4, 0xe4, 0xc8, 0x18, 0x7b, 0x94, 0xa6, 0x9e, 0x27, 0x76, 0x56, 0xa1, 0xe5, 0x1a, 0xdf, 0x84, 0x5c, 0x5b, 0xc6, 0x70, 0x23, 0xdf, 0xf9, 0x89, 0xbe, 0x10, 0xc1, 0x95, 0xf3, 0x15, 0x58, 0xa4, 0xac, 0x13, 0x79, 0x1e, 0x9b, 0xe8, 0x79, 0x9c, 0xb2, 0x8e, 0x5c, 0x29, 0x45, 0x92, 0xb5, 0xfd, 0x9f, 0x2b, 0x52, 0xfe, 0x67, 0x09, 0x4e, 0xe8, 0x53, 0x6c, 0xc9, 0xf3, 0xe1, 0xdf, 0x11, 0xbc, 0x3a, 0xa2, 0x55, 0xe3, 0x0f, 0x26, 0xcb, 0x31, 0x7e, 0xa8, 0x14, 0x36, 0x5f, 0xd0, 0x3b, 0x6a, 0x03, 0x86, 0xf5, 0xf4, 0xcf, 0xbf, 0xbf, 0x9b, 0xbb, 0x8c, 0xdf, 0x92, 0x1f, 0x48, 0x5f, 0x44, 0x9d, 0x68, 0x33, 0x08, 0xfd, 0x4f, 0x69, 0x5b, 0x70, 0xab, 0xf4, 0xc4, 0x4a, 0xf7, 0xfc, 0xdf, 0x10, 0x9c, 0x1a, 0x6a, 0xe6, 0x78, 0x63, 0x32, 0x8b, 0x71, 0x13, 0xa0, 0x30, 0xf3, 0x20, 0x4a, 0x91, 0x96, 0xaf, 0xe4, 0x00, 0xe5, 0x34, 0x63, 0xab, 0xf4, 0x04, 0xff, 0x82, 0xe0, 0x44, 0xa2, 0x0d, 0xe2, 0xab, 0xb3, 0xc9, 0xd6, 0x97, 0xfb, 0xda, 0xcc, 0x7e, 0xb1, 0xd0, 0x97, 0x15, 0xe7, 0x8b, 0xf8, 0xc2, 0x24, 0xa1, 0x39, 0x7e, 0x86, 0x20, 0x37, 0xa0, 0x16, 0x7e, 0x7f, 0x26, 0x71, 0x35, 0xd3, 0x19, 0xde, 0xb2, 0x14, 0xb9, 0x71, 0x82, 0x2a, 0x29, 0xbf, 0x47, 0xb0, 0x9c, 0xec, 0x7d, 0x78, 0x0a, 0x4d, 0x46, 0xce, 0xe8, 0xc2, 0x39, 0xed, 0x38, 0xf0, 0x11, 0x6e, 0x7e, 0xa8, 0x3f, 0xc2, 0x8d, 0x77, 0x14, 0xab, 0x4b, 0xc6, 0x64, 0xc9, 0x36, 0x50, 0x09, 0xff, 0x88, 0x60, 0x39, 0xd9, 0x82, 0xa6, 0x21, 0x36, 0x72, 0x20, 0x4d, 0x22, 0x76, 0x45, 0x11, 0xb3, 0xca, 0x25, 0x45, 0xac, 0x1f, 0xee, 0x28, 0xdd, 0x24, 0xc3, 0x6f, 0x10, 0x2c, 0x27, 0x87, 0xcc, 0x34, 0x0c, 0x47, 0x8e, 0xa5, 0xc2, 0x99, 0xa1, 0x1e, 0x54, 0x95, 0xbf, 0x26, 0xba, 0x92, 0xa5, 0x29, 0x2a, 0xf9, 0x15, 0x82, 0xa5, 0x06, 0x15, 0x75, 0xe2, 0xed, 0xaa, 0x1f, 0x23, 0x6c, 0xe8, 0x98, 0x0e, 0xf1, 0x64, 0xe6, 0x41, 0xa3, 0xce, 0xbb, 0x9a, 0xc2, 0x44, 0x56, 0x63, 0x53, 0xa5, 0xbd, 0x66, 0x94, 0x55, 0xda, 0x90, 0x72, 0xbf, 0x17, 0xb6, 0xc7, 0x8b, 0xc1, 0x07, 0x22, 0x4b, 0x65, 0x24, 0x95, 0xda, 0x51, 0x54, 0x6a, 0x2f, 0x8d, 0x4a, 0x37, 0x45, 0xe5, 0x57, 0x04, 0xb8, 0x49, 0xb9, 0xda, 0xa4, 0xa1, 0xe7, 0x70, 0x2e, 0xff, 0x07, 0x71, 0x31, 0x95, 0x6c, 0x18, 0xa2, 0x69, 0x5d, 0x9e, 0x02, 0x19, 0xf7, 0x84, 0x8a, 0xa2, 0xba, 0x69, 0x5c, 0x9f, 0x8e, 0xaa, 0x18, 0x8a, 0xb4, 0x81, 0x4a, 0xb7, 0xfe, 0x42, 0xf0, 0x66, 0xdb, 0xf7, 0x26, 0x5e, 0xa4, 0x5b, 0xaf, 0x35, 0x22, 0x53, 0x62, 0x2a, 0xed, 0xca, 0xeb, 0xb3, 0x8b, 0x3e, 0xbe, 0x13, 0xbb, 0x77, 0x7d, 0x97, 0xb0, 0xae, 0xe9, 0x87, 0x5d, 0xab, 0x4b, 0x99, 0xba, 0x5c, 0x56, 0x64, 0x22, 0x81, 0xc3, 0xc7, 0xff, 0xe8, 0xdf, 0xd4, 0xcf, 0x3f, 0xcf, 0x5d, 0xaa, 0x45, 0xa1, 0x2a, 0xae, 0xdf, 0xeb, 0x98, 0x71, 0x52, 0x53, 0x65, 0x7b, 0xfe, 0xc7, 0xf6, 0x60, 0xfd, 0x0f, 0x0d, 0xdc, 0x53, 0xc0, 0xbd, 0x18, 0xb8, 0xa7, 0x80, 0x7b, 0x1a, 0xb8, 0xf7, 0x60, 0xfd, 0xe1, 0x82, 0xa2, 0xf1, 0xde, 0xbf, 0x01, 0x00, 0x00, 0xff, 0xff, 0x23, 0xcc, 0x85, 0xa9, 0x6e, 0x10, 0x00, 0x00, }
{ "content_hash": "b9ef2d638a77c79eb512a827561e84d8", "timestamp": "", "source": "github", "line_count": 1550, "max_line_length": 178, "avg_line_length": 44.29677419354839, "alnum_prop": 0.7313137197786193, "repo_name": "emicklei/landskape", "id": "1708a83653b1de88f343e816b4b26d046436f2ef", "size": "68783", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "vendor/google.golang.org/genproto/googleapis/spanner/admin/instance/v1/spanner_instance_admin.pb.go", "mode": "33188", "license": "mit", "language": [ { "name": "Go", "bytes": "44704" }, { "name": "Makefile", "bytes": "480" } ], "symlink_target": "" }
from django.contrib import admin from Portal.models import Brand class BrandAdmin(admin.ModelAdmin): list_display = ('name', 'parts_count') search_fields = ('name',) fields = ('name',) def parts_count(self, obj): return obj.parts.count() parts_count.short_description = '# of Parts' admin.site.register(Brand, BrandAdmin)
{ "content_hash": "86ac750a1ee5b1006b787cffd893f34d", "timestamp": "", "source": "github", "line_count": 15, "max_line_length": 46, "avg_line_length": 23.8, "alnum_prop": 0.6722689075630253, "repo_name": "karlpablo/Portal", "id": "103eb46206a1241b7172ea5dd5d436a54a9111d7", "size": "357", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "admin/Brand.py", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "CSS", "bytes": "11407" }, { "name": "HTML", "bytes": "7996" }, { "name": "JavaScript", "bytes": "1407" }, { "name": "Python", "bytes": "13916" } ], "symlink_target": "" }
node_name "shop_on_rails_demo_node" cookbook_path '/chef/cookbooks' role_path "/chef/roles" file_cache_path "/tmp/chef" json_attribs "/chef/solo.json" solo true
{ "content_hash": "bf8ed9a1d8fac60fca6c5c9c0d1b9d48", "timestamp": "", "source": "github", "line_count": 6, "max_line_length": 35, "avg_line_length": 27.666666666666668, "alnum_prop": 0.7228915662650602, "repo_name": "shoponrails/shop_on_rails_kitchen", "id": "0ab59125a5a0e6dd4cb7b6c75ccc5e7c9a38eec9", "size": "166", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "solo.rb", "mode": "33188", "license": "mit", "language": [ { "name": "C", "bytes": "6704" }, { "name": "Ruby", "bytes": "30883" }, { "name": "Shell", "bytes": "409" } ], "symlink_target": "" }
/* MACHINE GENERATED FILE, DO NOT EDIT */ package org.lwjgl.opengl; import org.lwjgl.*; import java.nio.*; public final class KHRRobustness { /** * Returned by GetGraphicsResetStatus: */ public static final int GL_GUILTY_CONTEXT_RESET = 0x8253, GL_INNOCENT_CONTEXT_RESET = 0x8254, GL_UNKNOWN_CONTEXT_RESET = 0x8255; /** * Accepted by the &lt;value&gt; parameter of GetBooleanv, GetIntegerv, * and GetFloatv: */ public static final int GL_CONTEXT_ROBUST_ACCESS = 0x90F3, GL_RESET_NOTIFICATION_STRATEGY = 0x8256; /** * Returned by GetIntegerv and related simple queries when &lt;value&gt; is * RESET_NOTIFICATION_STRATEGY: */ public static final int GL_LOSE_CONTEXT_ON_RESET = 0x8252, GL_NO_RESET_NOTIFICATION = 0x8261; /** * Returned by GetError: */ public static final int GL_CONTEXT_LOST = 0x507; private KHRRobustness() {} public static int glGetGraphicsResetStatus() { return GL45.glGetGraphicsResetStatus(); } public static void glReadnPixels(int x, int y, int width, int height, int format, int type, ByteBuffer pixels) { GL45.glReadnPixels(x, y, width, height, format, type, pixels); } public static void glReadnPixels(int x, int y, int width, int height, int format, int type, DoubleBuffer pixels) { GL45.glReadnPixels(x, y, width, height, format, type, pixels); } public static void glReadnPixels(int x, int y, int width, int height, int format, int type, FloatBuffer pixels) { GL45.glReadnPixels(x, y, width, height, format, type, pixels); } public static void glReadnPixels(int x, int y, int width, int height, int format, int type, IntBuffer pixels) { GL45.glReadnPixels(x, y, width, height, format, type, pixels); } public static void glReadnPixels(int x, int y, int width, int height, int format, int type, ShortBuffer pixels) { GL45.glReadnPixels(x, y, width, height, format, type, pixels); } public static void glReadnPixels(int x, int y, int width, int height, int format, int type, int pixels_bufSize, long pixels_buffer_offset) { GL45.glReadnPixels(x, y, width, height, format, type, pixels_bufSize, pixels_buffer_offset); } public static void glGetnUniform(int program, int location, FloatBuffer params) { GL45.glGetnUniform(program, location, params); } public static void glGetnUniform(int program, int location, IntBuffer params) { GL45.glGetnUniform(program, location, params); } public static void glGetnUniformu(int program, int location, IntBuffer params) { GL45.glGetnUniformu(program, location, params); } }
{ "content_hash": "9f1945315ceab059baf50b8ac9609fc5", "timestamp": "", "source": "github", "line_count": 72, "max_line_length": 141, "avg_line_length": 35.93055555555556, "alnum_prop": 0.7139543873212215, "repo_name": "ThePlexianNetwork/Grumy", "id": "2e4e38e52edf0368bae0d2bbaa7c4f6038042975", "size": "2587", "binary": false, "copies": "4", "ref": "refs/heads/development", "path": "lib/lwjgl/jar/src/generated/org/lwjgl/opengl/KHRRobustness.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "C", "bytes": "2271672" }, { "name": "C++", "bytes": "3076" }, { "name": "GLSL", "bytes": "4415" }, { "name": "Java", "bytes": "9012727" }, { "name": "Objective-C", "bytes": "87796" }, { "name": "Shell", "bytes": "155" } ], "symlink_target": "" }
/** * Autogenerated by Thrift * * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING * @generated */ package test.fixtures.module2; import com.facebook.swift.codec.*; import com.google.common.collect.*; import java.util.*; @SwiftGenerated public final class Constants { private Constants() {} public static final test.fixtures.module2.Struct C2 = new test.fixtures.module2.Struct.Builder().setFirst(test.fixtures.module0.Constants.C0).setSecond(test.fixtures.module1.Constants.C1).build(); public static final test.fixtures.module2.Struct C3 = test.fixtures.module2.Constants.C2; public static final test.fixtures.module2.Struct C4 = test.fixtures.module2.Constants.C2; }
{ "content_hash": "dd56e39ca733908a4afaf87b2a85913f", "timestamp": "", "source": "github", "line_count": 23, "max_line_length": 200, "avg_line_length": 31.043478260869566, "alnum_prop": 0.7563025210084033, "repo_name": "facebook/fbthrift", "id": "c4bbf0920ea08d4bdc0edbd30df9a3cbc6de7ac9", "size": "714", "binary": false, "copies": "1", "ref": "refs/heads/main", "path": "thrift/compiler/test/fixtures/qualified/gen-java/test/fixtures/module2/Constants.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "C", "bytes": "15608" }, { "name": "C++", "bytes": "10658844" }, { "name": "CMake", "bytes": "147347" }, { "name": "CSS", "bytes": "4028" }, { "name": "Cython", "bytes": "339005" }, { "name": "Emacs Lisp", "bytes": "11229" }, { "name": "Go", "bytes": "447092" }, { "name": "Hack", "bytes": "313122" }, { "name": "Java", "bytes": "1990062" }, { "name": "JavaScript", "bytes": "38872" }, { "name": "Mustache", "bytes": "1269560" }, { "name": "Python", "bytes": "1623026" }, { "name": "Ruby", "bytes": "6111" }, { "name": "Rust", "bytes": "283392" }, { "name": "Shell", "bytes": "6615" }, { "name": "Thrift", "bytes": "1859041" }, { "name": "Vim Script", "bytes": "2887" } ], "symlink_target": "" }
package org.apache.xerces.impl; import java.util.Enumeration; import java.util.NoSuchElementException; /** * Commonly used constants. * * @xerces.internal * * @author Andy Clark, IBM * * @version $Id$ */ public final class Constants { // // Constants // // Schema Types: public static final String NS_XMLSCHEMA = "http://www.w3.org/2001/XMLSchema".intern(); public static final String NS_DTD = "http://www.w3.org/TR/REC-xml".intern(); // sax features /** SAX feature prefix ("http://xml.org/sax/features/"). */ public static final String SAX_FEATURE_PREFIX = "http://xml.org/sax/features/"; /** Namespaces feature ("namespaces"). */ public static final String NAMESPACES_FEATURE = "namespaces"; /** Namespace prefixes feature ("namespace-prefixes"). */ public static final String NAMESPACE_PREFIXES_FEATURE = "namespace-prefixes"; /** String interning feature ("string-interning"). */ public static final String STRING_INTERNING_FEATURE = "string-interning"; /** Validation feature ("validation"). */ public static final String VALIDATION_FEATURE = "validation"; /** External general entities feature ("external-general-entities "). */ public static final String EXTERNAL_GENERAL_ENTITIES_FEATURE = "external-general-entities"; /** External parameter entities feature ("external-parameter-entities "). */ public static final String EXTERNAL_PARAMETER_ENTITIES_FEATURE = "external-parameter-entities"; /** Lexical handler parameter entities feature ("lexical-handler/parameter-entities"). */ public static final String LEXICAL_HANDLER_PARAMETER_ENTITIES_FEATURE = "lexical-handler/parameter-entities"; /** Is standalone feature ("is-standalone"). */ public static final String IS_STANDALONE_FEATURE = "is-standalone"; /** Resolve DTD URIs feature ("resolve-dtd-uris"). */ public static final String RESOLVE_DTD_URIS_FEATURE = "resolve-dtd-uris"; /** Use Attributes2 feature ("use-attributes2"). */ public static final String USE_ATTRIBUTES2_FEATURE = "use-attributes2"; /** Use Locator2 feature ("use-locator2"). */ public static final String USE_LOCATOR2_FEATURE = "use-locator2"; /** Use EntityResolver2 feature ("use-entity-resolver2"). */ public static final String USE_ENTITY_RESOLVER2_FEATURE = "use-entity-resolver2"; /** Unicode normalization checking feature ("unicode-normalization-checking"). */ public static final String UNICODE_NORMALIZATION_CHECKING_FEATURE = "unicode-normalization-checking"; /** xmlns URIs feature ("xmlns-uris"). */ public static final String XMLNS_URIS_FEATURE = "xmlns-uris"; /** XML 1.1 feature ("xml-1.1"). */ public static final String XML_11_FEATURE = "xml-1.1"; /** Allow unparsed entity and notation declaration events to be sent after the end DTD event ("allow-dtd-events-after-endDTD") */ public static final String ALLOW_DTD_EVENTS_AFTER_ENDDTD_FEATURE = "allow-dtd-events-after-endDTD"; // sax properties /** SAX property prefix ("http://xml.org/sax/properties/"). */ public static final String SAX_PROPERTY_PREFIX = "http://xml.org/sax/properties/"; /** Declaration handler property ("declaration-handler"). */ public static final String DECLARATION_HANDLER_PROPERTY = "declaration-handler"; /** Lexical handler property ("lexical-handler"). */ public static final String LEXICAL_HANDLER_PROPERTY = "lexical-handler"; /** DOM node property ("dom-node"). */ public static final String DOM_NODE_PROPERTY = "dom-node"; /** XML string property ("xml-string"). */ public static final String XML_STRING_PROPERTY = "xml-string"; /** Document XML version property ("document-xml-version"). */ public static final String DOCUMENT_XML_VERSION_PROPERTY = "document-xml-version"; // // JAXP properties // /** JAXP property prefix ("http://java.sun.com/xml/jaxp/properties/"). */ public static final String JAXP_PROPERTY_PREFIX = "http://java.sun.com/xml/jaxp/properties/"; /** JAXP property prefix ("http://java.sun.com/xml/jaxp/properties/"). */ public static final String JAXP_ORACLE_PROPERTY_PREFIX = "http://www.oracle.com/xml/jaxp/properties/"; /** JAXP property prefix ("http://javax.xml.XMLConstants/property/"). */ public static final String JAXP_JAVAX_PROPERTY_PREFIX = "http://javax.xml.XMLConstants/property/"; /** JAXP schemaSource property: when used internally may include DTD sources (DOM) */ public static final String SCHEMA_SOURCE = "schemaSource"; /** JAXP schemaSource language: when used internally may include DTD namespace (DOM) */ public static final String SCHEMA_LANGUAGE = "schemaLanguage"; /** JAXP property: restrict access to external DTDs by protocol */ public static final String ACCESS_EXTERNAL_DTD = "accessExternalDTD"; /** JAXP property: restrict access to external schemas by protocol */ public static final String ACCESS_EXTERNAL_SCHEMA = "accessExternalSchema"; /** JAXP property: limit the value of maxOccurs attribute in XML schema */ public static final String MAX_OCCUR_LIMIT = "maxOccurLimit"; /** JAXP property: limit the maximum size of any general entities */ public static final String MAX_GENERAL_ENTITY_SIZE_LIMIT = "maxGeneralEntitySizeLimit"; /** JAXP property: limit the maximum size of any parameter entities */ public static final String MAX_PARAMETER_ENTITY_SIZE_LIMIT = "maxParameterEntitySizeLimit"; /** JAXP property: limit the total size of all entities that include general and parameter entities */ public static final String MAX_TOTAL_ENTITY_SIZE_LIMIT = "totalEntitySizeLimit"; /** JAXP property: limit the maximum element depth */ public static final String MAX_ELEMENT_DEPTH = "maxElementDepth"; // // DOM features // /** Comments feature ("include-comments"). */ public static final String INCLUDE_COMMENTS_FEATURE = "include-comments"; /** Create cdata nodes feature ("create-cdata-nodes"). */ public static final String CREATE_CDATA_NODES_FEATURE = "create-cdata-nodes"; /** Feature id: load as infoset. */ public static final String LOAD_AS_INFOSET = "load-as-infoset"; // // Constants: DOM Level 3 feature ids // public static final String DOM_CANONICAL_FORM = "canonical-form"; public static final String DOM_CDATA_SECTIONS ="cdata-sections"; public static final String DOM_COMMENTS = "comments"; // REVISIT: this feature seems to have no effect for Xerces public static final String DOM_CHARSET_OVERRIDES_XML_ENCODING = "charset-overrides-xml-encoding"; public static final String DOM_DATATYPE_NORMALIZATION = "datatype-normalization"; public static final String DOM_ENTITIES = "entities"; public static final String DOM_INFOSET = "infoset"; public static final String DOM_NAMESPACES = "namespaces"; public static final String DOM_NAMESPACE_DECLARATIONS = "namespace-declarations"; public static final String DOM_SUPPORTED_MEDIATYPES_ONLY = "supported-media-types-only"; public static final String DOM_VALIDATE_IF_SCHEMA = "validate-if-schema"; public static final String DOM_VALIDATE = "validate"; public static final String DOM_ELEMENT_CONTENT_WHITESPACE = "element-content-whitespace"; // DOM Level 3 features defined in Core: public static final String DOM_DISCARD_DEFAULT_CONTENT = "discard-default-content"; public static final String DOM_NORMALIZE_CHARACTERS = "normalize-characters"; public static final String DOM_CHECK_CHAR_NORMALIZATION = "check-character-normalization"; public static final String DOM_WELLFORMED = "well-formed"; public static final String DOM_SPLIT_CDATA = "split-cdata-sections"; // Load and Save public static final String DOM_FORMAT_PRETTY_PRINT = "format-pretty-print"; public static final String DOM_XMLDECL = "xml-declaration"; public static final String DOM_UNKNOWNCHARS = "unknown-characters"; public static final String DOM_CERTIFIED = "certified"; public static final String DOM_DISALLOW_DOCTYPE = "disallow-doctype"; public static final String DOM_IGNORE_UNKNOWN_CHARACTER_DENORMALIZATIONS = "ignore-unknown-character-denormalizations"; // DOM Properties public static final String DOM_RESOURCE_RESOLVER = "resource-resolver"; public static final String DOM_ERROR_HANDLER = "error-handler"; public static final String DOM_SCHEMA_TYPE = "schema-type"; public static final String DOM_SCHEMA_LOCATION = "schema-location"; // XSModel public static final String DOM_PSVI = "psvi"; // xerces features /** Xerces features prefix ("http://apache.org/xml/features/"). */ public static final String XERCES_FEATURE_PREFIX = "http://apache.org/xml/features/"; /** Schema validation feature ("validation/schema"). */ public static final String SCHEMA_VALIDATION_FEATURE = "validation/schema"; /** Expose schema normalized values */ public static final String SCHEMA_NORMALIZED_VALUE = "validation/schema/normalized-value"; /** Send schema default value via characters() */ public static final String SCHEMA_ELEMENT_DEFAULT = "validation/schema/element-default"; /** Schema full constraint checking ("validation/schema-full-checking"). */ public static final String SCHEMA_FULL_CHECKING = "validation/schema-full-checking"; /** Augment Post-Schema-Validation-Infoset */ public static final String SCHEMA_AUGMENT_PSVI = "validation/schema/augment-psvi"; /** Dynamic validation feature ("validation/dynamic"). */ public static final String DYNAMIC_VALIDATION_FEATURE = "validation/dynamic"; /** Warn on duplicate attribute declaration feature ("validation/warn-on-duplicate-attdef"). */ public static final String WARN_ON_DUPLICATE_ATTDEF_FEATURE = "validation/warn-on-duplicate-attdef"; /** Warn on undeclared element feature ("validation/warn-on-undeclared-elemdef"). */ public static final String WARN_ON_UNDECLARED_ELEMDEF_FEATURE = "validation/warn-on-undeclared-elemdef"; /** Warn on duplicate entity declaration feature ("warn-on-duplicate-entitydef"). */ public static final String WARN_ON_DUPLICATE_ENTITYDEF_FEATURE = "warn-on-duplicate-entitydef"; /** Allow Java encoding names feature ("allow-java-encodings"). */ public static final String ALLOW_JAVA_ENCODINGS_FEATURE = "allow-java-encodings"; /** Disallow DOCTYPE declaration feature ("disallow-doctype-decl"). */ public static final String DISALLOW_DOCTYPE_DECL_FEATURE = "disallow-doctype-decl"; /** Continue after fatal error feature ("continue-after-fatal-error"). */ public static final String CONTINUE_AFTER_FATAL_ERROR_FEATURE = "continue-after-fatal-error"; /** Load dtd grammar when nonvalidating feature ("nonvalidating/load-dtd-grammar"). */ public static final String LOAD_DTD_GRAMMAR_FEATURE = "nonvalidating/load-dtd-grammar"; /** Load external dtd when nonvalidating feature ("nonvalidating/load-external-dtd"). */ public static final String LOAD_EXTERNAL_DTD_FEATURE = "nonvalidating/load-external-dtd"; /** Defer node expansion feature ("dom/defer-node-expansion"). */ public static final String DEFER_NODE_EXPANSION_FEATURE = "dom/defer-node-expansion"; /** Create entity reference nodes feature ("dom/create-entity-ref-nodes"). */ public static final String CREATE_ENTITY_REF_NODES_FEATURE = "dom/create-entity-ref-nodes"; /** Include ignorable whitespace feature ("dom/include-ignorable-whitespace"). */ public static final String INCLUDE_IGNORABLE_WHITESPACE = "dom/include-ignorable-whitespace"; /** Default attribute values feature ("validation/default-attribute-values"). */ public static final String DEFAULT_ATTRIBUTE_VALUES_FEATURE = "validation/default-attribute-values"; /** Validate content models feature ("validation/validate-content-models"). */ public static final String VALIDATE_CONTENT_MODELS_FEATURE = "validation/validate-content-models"; /** Validate datatypes feature ("validation/validate-datatypes"). */ public static final String VALIDATE_DATATYPES_FEATURE = "validation/validate-datatypes"; /** Balance syntax trees feature ("validation/balance-syntax-trees"). */ public static final String BALANCE_SYNTAX_TREES = "validation/balance-syntax-trees"; /** Notify character references feature (scanner/notify-char-refs"). */ public static final String NOTIFY_CHAR_REFS_FEATURE = "scanner/notify-char-refs"; /** Notify built-in (&amp;amp;, etc.) references feature (scanner/notify-builtin-refs"). */ public static final String NOTIFY_BUILTIN_REFS_FEATURE = "scanner/notify-builtin-refs"; /** Standard URI conformant feature ("standard-uri-conformant"). */ public static final String STANDARD_URI_CONFORMANT_FEATURE = "standard-uri-conformant"; /** Generate synthetic annotations feature ("generate-synthetic-annotations"). */ public static final String GENERATE_SYNTHETIC_ANNOTATIONS_FEATURE = "generate-synthetic-annotations"; /** Validate annotations feature ("validate-annotations"). */ public static final String VALIDATE_ANNOTATIONS_FEATURE = "validate-annotations"; /** Honour all schemaLocations feature ("honour-all-schemaLocations"). */ public static final String HONOUR_ALL_SCHEMALOCATIONS_FEATURE = "honour-all-schemaLocations"; /** Namespace growth feature ("namespace-growth"). */ public static final String NAMESPACE_GROWTH_FEATURE = "namespace-growth"; /** Tolerate duplicates feature ("internal/tolerate-duplicates"). */ public static final String TOLERATE_DUPLICATES_FEATURE = "internal/tolerate-duplicates"; /** String interned feature ("internal/strings-interned"). */ public static final String STRINGS_INTERNED_FEATURE = "internal/strings-interned"; /** XInclude processing feature ("xinclude"). */ public static final String XINCLUDE_FEATURE = "xinclude"; /** XInclude fixup base URIs feature ("xinclude/fixup-base-uris"). */ public static final String XINCLUDE_FIXUP_BASE_URIS_FEATURE = "xinclude/fixup-base-uris"; /** XInclude fixup language feature ("xinclude/fixup-language"). */ public static final String XINCLUDE_FIXUP_LANGUAGE_FEATURE = "xinclude/fixup-language"; /** * Feature to ignore xsi:type attributes on elements during validation, * until a global element declaration is found. ("validation/schema/ignore-xsi-type-until-elemdecl") * If this feature is on when validating a document, then beginning at the validation root * element, xsi:type attributes are ignored until a global element declaration is * found for an element. Once a global element declaration has been found, xsi:type * attributes will start being processed for the sub-tree beginning at the element for * which the declaration was found. * * Suppose an element A has two element children, B and C. * * If a global element declaration is found for A, xsi:type attributes on A, B and C, * and all of B and C's descendents, will be processed. * * If no global element declaration is found for A or B, but one is found for C, * then xsi:type attributes will be ignored on A and B (and any descendents of B, * until a global element declaration is found), but xsi:type attributes will be * processed for C and all of C's descendents. * * Once xsi:type attributes stop being ignored for a subtree, they do not start * being ignored again, even if more elements are encountered for which no global * element declaration can be found. */ public static final String IGNORE_XSI_TYPE_FEATURE = "validation/schema/ignore-xsi-type-until-elemdecl"; /** Perform checking of ID/IDREFs ("validation/id-idref-checking") */ public static final String ID_IDREF_CHECKING_FEATURE = "validation/id-idref-checking"; /** Feature to ignore errors caused by identity constraints ("validation/identity-constraint-checking") */ public static final String IDC_CHECKING_FEATURE = "validation/identity-constraint-checking"; /** Feature to ignore errors caused by unparsed entities ("validation/unparsed-entity-checking") */ public static final String UNPARSED_ENTITY_CHECKING_FEATURE = "validation/unparsed-entity-checking"; /** * Internal feature. When set to true the schema validator will only use * schema components from the grammar pool provided. */ public static final String USE_GRAMMAR_POOL_ONLY_FEATURE = "internal/validation/schema/use-grammar-pool-only"; /** Internal performance related feature: * false - the parser settings (features/properties) have not changed between 2 parses * true - the parser settings have changed between 2 parses * NOTE: this feature should only be set by the parser configuration. */ public static final String PARSER_SETTINGS = "internal/parser-settings"; // xerces properties /** Xerces properties prefix ("http://apache.org/xml/properties/"). */ public static final String XERCES_PROPERTY_PREFIX = "http://apache.org/xml/properties/"; /** Current element node property ("dom/current-element-node"). */ public static final String CURRENT_ELEMENT_NODE_PROPERTY = "dom/current-element-node"; /** Document class name property ("dom/document-class-name"). */ public static final String DOCUMENT_CLASS_NAME_PROPERTY = "dom/document-class-name"; /** Symbol table property ("internal/symbol-table"). */ public static final String SYMBOL_TABLE_PROPERTY = "internal/symbol-table"; /** Error reporter property ("internal/error-reporter"). */ public static final String ERROR_REPORTER_PROPERTY = "internal/error-reporter"; /** Error handler property ("internal/error-handler"). */ public static final String ERROR_HANDLER_PROPERTY = "internal/error-handler"; /** XInclude handler property ("internal/xinclude-handler"). */ public static final String XINCLUDE_HANDLER_PROPERTY = "internal/xinclude-handler"; /** XPointer handler property ("internal/xpointer-handler"). */ public static final String XPOINTER_HANDLER_PROPERTY = "internal/xpointer-handler"; /** Entity manager property ("internal/entity-manager"). */ public static final String ENTITY_MANAGER_PROPERTY = "internal/entity-manager"; /** Input buffer size property ("input-buffer-size"). */ public static final String BUFFER_SIZE_PROPERTY = "input-buffer-size"; /** Security manager property ("security-manager"). */ public static final String SECURITY_MANAGER_PROPERTY = "security-manager"; /** Locale property ("locale"). */ public static final String LOCALE_PROPERTY = "locale"; /** Entity resolver property ("internal/entity-resolver"). */ public static final String ENTITY_RESOLVER_PROPERTY = "internal/entity-resolver"; /** Grammar pool property ("internal/grammar-pool"). */ public static final String XMLGRAMMAR_POOL_PROPERTY = "internal/grammar-pool"; /** Datatype validator factory ("internal/datatype-validator-factory"). */ public static final String DATATYPE_VALIDATOR_FACTORY_PROPERTY = "internal/datatype-validator-factory"; /** Document scanner property ("internal/document-scanner"). */ public static final String DOCUMENT_SCANNER_PROPERTY = "internal/document-scanner"; /** DTD scanner property ("internal/dtd-scanner"). */ public static final String DTD_SCANNER_PROPERTY = "internal/dtd-scanner"; /** DTD processor property ("internal/dtd-processor"). */ public static final String DTD_PROCESSOR_PROPERTY = "internal/dtd-processor"; /** Validator property ("internal/validator"). */ public static final String VALIDATOR_PROPERTY = "internal/validator"; /** Validator property ("internal/validator/dtd"). */ public static final String DTD_VALIDATOR_PROPERTY = "internal/validator/dtd"; /** Validator property ("internal/validator/schema"). */ public static final String SCHEMA_VALIDATOR_PROPERTY = "internal/validator/schema"; /** No namespace schema location property ("schema/external-schemaLocation"). */ public static final String SCHEMA_LOCATION = "schema/external-schemaLocation"; /** Schema location property ("schema/external-noNamespaceSchemaLocation"). */ public static final String SCHEMA_NONS_LOCATION = "schema/external-noNamespaceSchemaLocation"; /** Namespace binder property ("internal/namespace-binder"). */ public static final String NAMESPACE_BINDER_PROPERTY = "internal/namespace-binder"; /** Namespace context property ("internal/namespace-context"). */ public static final String NAMESPACE_CONTEXT_PROPERTY = "internal/namespace-context"; /** Validation manager property ("internal/validation-manager"). */ public static final String VALIDATION_MANAGER_PROPERTY = "internal/validation-manager"; /** Schema type for the root element in a document ("validation/schema/root-type-definition"). */ public static final String ROOT_TYPE_DEFINITION_PROPERTY = "validation/schema/root-type-definition"; /** Schema element declaration for the root element in a document ("validation/schema/root-element-declaration"). */ public static final String ROOT_ELEMENT_DECLARATION_PROPERTY = "validation/schema/root-element-declaration"; /** Schema element declaration for the root element in a document ("internal/validation/schema/dv-factory"). */ public static final String SCHEMA_DV_FACTORY_PROPERTY = "internal/validation/schema/dv-factory"; /** Limit the number of entity expansions */ public static final String ENTITY_EXPANSION_LIMIT_PROPERTY = "entity-expansion-limit"; public static final String ENTITY_EXPANSION_LIMIT_PROPERTY2 = "entityExpansionLimit"; /** Limit the number of attributes an element can have */ public static final String ELEMENT_ATTRIBUTE_LIMIT_PROPERTY = "elementAttributeLimit"; // general constants /** Element PSVI is stored in augmentations using string "ELEMENT_PSVI" */ public final static String ELEMENT_PSVI = "ELEMENT_PSVI"; /** Attribute PSVI is stored in augmentations using string "ATTRIBUTE_PSVI" */ public final static String ATTRIBUTE_PSVI = "ATTRIBUTE_PSVI"; /** * Boolean indicating whether an attribute is declared in the DTD is stored * in augmentations using the string "ATTRIBUTE_DECLARED". The absence of this * augmentation indicates that the attribute was not declared in the DTD. */ public final static String ATTRIBUTE_DECLARED = "ATTRIBUTE_DECLARED"; /** * Boolean indicating whether an entity referenced in the document has * not been read is stored in augmentations using the string "ENTITY_SKIPPED". * The absence of this augmentation indicates that the entity had a * declaration and was expanded. */ public final static String ENTITY_SKIPPED = "ENTITY_SKIPPED"; /** * Boolean indicating whether a character is a probable white space * character (ch <= 0x20) that was the replacement text of a character * reference is stored in augmentations using the string "CHAR_REF_PROBABLE_WS". * The absence of this augmentation indicates that the character is not * probable white space and/or was not included from a character reference. */ public final static String CHAR_REF_PROBABLE_WS = "CHAR_REF_PROBABLE_WS"; // XML version constants public final static short XML_VERSION_ERROR = -1; public final static short XML_VERSION_1_0 = 1; public final static short XML_VERSION_1_1 = 2; // Constant to enable Schema 1.1 support public final static boolean SCHEMA_1_1_SUPPORT = false; public final static short SCHEMA_VERSION_1_0 = 1; public final static short SCHEMA_VERSION_1_0_EXTENDED = 2; // private /** SAX features. */ private static final String[] fgSAXFeatures = { NAMESPACES_FEATURE, NAMESPACE_PREFIXES_FEATURE, STRING_INTERNING_FEATURE, VALIDATION_FEATURE, EXTERNAL_GENERAL_ENTITIES_FEATURE, EXTERNAL_PARAMETER_ENTITIES_FEATURE, }; /** SAX properties. */ private static final String[] fgSAXProperties = { DECLARATION_HANDLER_PROPERTY, LEXICAL_HANDLER_PROPERTY, DOM_NODE_PROPERTY, XML_STRING_PROPERTY, }; /** Xerces features. */ private static final String[] fgXercesFeatures = { SCHEMA_VALIDATION_FEATURE, SCHEMA_FULL_CHECKING, DYNAMIC_VALIDATION_FEATURE, WARN_ON_DUPLICATE_ATTDEF_FEATURE, WARN_ON_UNDECLARED_ELEMDEF_FEATURE, ALLOW_JAVA_ENCODINGS_FEATURE, CONTINUE_AFTER_FATAL_ERROR_FEATURE, LOAD_DTD_GRAMMAR_FEATURE, LOAD_EXTERNAL_DTD_FEATURE, //DEFER_NODE_EXPANSION_FEATURE, CREATE_ENTITY_REF_NODES_FEATURE, INCLUDE_IGNORABLE_WHITESPACE, //GRAMMAR_ACCESS_FEATURE, DEFAULT_ATTRIBUTE_VALUES_FEATURE, VALIDATE_CONTENT_MODELS_FEATURE, VALIDATE_DATATYPES_FEATURE, BALANCE_SYNTAX_TREES, NOTIFY_CHAR_REFS_FEATURE, NOTIFY_BUILTIN_REFS_FEATURE, DISALLOW_DOCTYPE_DECL_FEATURE, STANDARD_URI_CONFORMANT_FEATURE, GENERATE_SYNTHETIC_ANNOTATIONS_FEATURE, VALIDATE_ANNOTATIONS_FEATURE, HONOUR_ALL_SCHEMALOCATIONS_FEATURE, XINCLUDE_FEATURE, XINCLUDE_FIXUP_BASE_URIS_FEATURE, XINCLUDE_FIXUP_LANGUAGE_FEATURE, IGNORE_XSI_TYPE_FEATURE, ID_IDREF_CHECKING_FEATURE, IDC_CHECKING_FEATURE, UNPARSED_ENTITY_CHECKING_FEATURE, NAMESPACE_GROWTH_FEATURE, TOLERATE_DUPLICATES_FEATURE, STRINGS_INTERNED_FEATURE, }; /** Xerces properties. */ private static final String[] fgXercesProperties = { CURRENT_ELEMENT_NODE_PROPERTY, DOCUMENT_CLASS_NAME_PROPERTY, SYMBOL_TABLE_PROPERTY, ERROR_HANDLER_PROPERTY, ERROR_REPORTER_PROPERTY, ENTITY_MANAGER_PROPERTY, ENTITY_RESOLVER_PROPERTY, XMLGRAMMAR_POOL_PROPERTY, DATATYPE_VALIDATOR_FACTORY_PROPERTY, DOCUMENT_SCANNER_PROPERTY, DTD_SCANNER_PROPERTY, VALIDATOR_PROPERTY, SCHEMA_LOCATION, SCHEMA_NONS_LOCATION, VALIDATION_MANAGER_PROPERTY, BUFFER_SIZE_PROPERTY, SECURITY_MANAGER_PROPERTY, LOCALE_PROPERTY, ROOT_TYPE_DEFINITION_PROPERTY, ROOT_ELEMENT_DECLARATION_PROPERTY, SCHEMA_DV_FACTORY_PROPERTY, ENTITY_EXPANSION_LIMIT_PROPERTY, ENTITY_EXPANSION_LIMIT_PROPERTY2 }; /** Empty enumeration. */ private static final Enumeration fgEmptyEnumeration = new ArrayEnumeration(new Object[] {}); // // Constructors // /** This class cannot be instantiated. */ private Constants() {} // // Public methods // // sax /** Returns an enumeration of the SAX features. */ public static Enumeration getSAXFeatures() { return fgSAXFeatures.length > 0 ? new ArrayEnumeration(fgSAXFeatures) : fgEmptyEnumeration; } // getSAXFeatures():Enumeration /** Returns an enumeration of the SAX properties. */ public static Enumeration getSAXProperties() { return fgSAXProperties.length > 0 ? new ArrayEnumeration(fgSAXProperties) : fgEmptyEnumeration; } // getSAXProperties():Enumeration // xerces /** Returns an enumeration of the Xerces features. */ public static Enumeration getXercesFeatures() { return fgXercesFeatures.length > 0 ? new ArrayEnumeration(fgXercesFeatures) : fgEmptyEnumeration; } // getXercesFeatures():Enumeration /** Returns an enumeration of the Xerces properties. */ public static Enumeration getXercesProperties() { return fgXercesProperties.length > 0 ? new ArrayEnumeration(fgXercesProperties) : fgEmptyEnumeration; } // getXercesProperties():Enumeration // // Classes // /** * An array enumeration. * * @author Andy Clark, IBM */ static class ArrayEnumeration implements Enumeration { // // Data // /** Array. */ private Object[] array; /** Index. */ private int index; // // Constructors // /** Constructs an array enumeration. */ public ArrayEnumeration(Object[] array) { this.array = array; } // <init>(Object[]) // // Enumeration methods // /** * Tests if this enumeration contains more elements. * * @return <code>true</code> if this enumeration contains more elements; * <code>false</code> otherwise. * @since JDK1.0 */ public boolean hasMoreElements() { return index < array.length; } // hasMoreElement():boolean /** * Returns the next element of this enumeration. * * @return the next element of this enumeration. * @exception NoSuchElementException if no more elements exist. * @since JDK1.0 */ public Object nextElement() { if (index < array.length) { return array[index++]; } throw new NoSuchElementException(); } // nextElement():Object } // class ArrayEnumeration // // MAIN // /** Prints all of the constants to standard output. */ public static void main(String[] argv) { print("SAX features:", SAX_FEATURE_PREFIX, fgSAXFeatures); print("SAX properties:", SAX_PROPERTY_PREFIX, fgSAXProperties); print("Xerces features:", XERCES_FEATURE_PREFIX, fgXercesFeatures); print("Xerces properties:", XERCES_PROPERTY_PREFIX, fgXercesProperties); } // main(String[]) /** Prints a list of features/properties. */ private static void print(String header, String prefix, Object[] array) { System.out.print(header); if (array.length > 0) { System.out.println(); for (int i = 0; i < array.length; i++) { System.out.print(" "); System.out.print(prefix); System.out.println(array[i]); } } else { System.out.println(" none."); } } // print(String,String,Object[]) } // class Constants
{ "content_hash": "e0a8990d799bc01c8201ce1a718a201b", "timestamp": "", "source": "github", "line_count": 715, "max_line_length": 133, "avg_line_length": 44.31608391608392, "alnum_prop": 0.6722211702329104, "repo_name": "ronsigal/xerces", "id": "0268a6641f7b56e0983bf279f5aa3a145593e131", "size": "32490", "binary": false, "copies": "1", "ref": "refs/heads/jboss-2.11.0.SP", "path": "src/org/apache/xerces/impl/Constants.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Batchfile", "bytes": "2183" }, { "name": "CSS", "bytes": "2394" }, { "name": "HTML", "bytes": "291055" }, { "name": "Java", "bytes": "9196447" }, { "name": "Shell", "bytes": "2449" }, { "name": "XSLT", "bytes": "23366" } ], "symlink_target": "" }
using UnityEngine; using UnityEditor; namespace Klak.Wiring { [CanEditMultipleObjects] [CustomEditor(typeof(MousePositionInput))] public class MousePositionInputEditor : Editor { SerializedProperty _interpolator; SerializedProperty _xEvent; SerializedProperty _yEvent; void OnEnable() { _interpolator = serializedObject.FindProperty("_interpolator"); _xEvent = serializedObject.FindProperty("_xEvent"); _yEvent = serializedObject.FindProperty("_yEvent"); } public override void OnInspectorGUI() { serializedObject.Update(); EditorGUILayout.PropertyField(_interpolator); EditorGUILayout.Space(); EditorGUILayout.PropertyField(_xEvent); EditorGUILayout.PropertyField(_yEvent); serializedObject.ApplyModifiedProperties(); } } }
{ "content_hash": "f20ad229787b7edf5f4202f4268daa29", "timestamp": "", "source": "github", "line_count": 35, "max_line_length": 75, "avg_line_length": 27.62857142857143, "alnum_prop": 0.6132368148914168, "repo_name": "atomicguy/codejam", "id": "5f9547b3c5499b7c5f8b907f2166e961febe2e55", "size": "2165", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "MagentaMidiUnity/Assets/Klak/Wiring/Editor/Input/MousePositionInputEditor.cs", "mode": "33261", "license": "mit", "language": [ { "name": "C#", "bytes": "742611" }, { "name": "GLSL", "bytes": "103343" } ], "symlink_target": "" }
package org.qi4j.ide.plugin.idea.common.psi.search; import com.intellij.openapi.module.Module; import com.intellij.openapi.project.Project; import com.intellij.openapi.roots.ProjectRootManager; import com.intellij.openapi.vfs.VirtualFile; import com.intellij.psi.PsiElement; import com.intellij.psi.search.GlobalSearchScope; import org.jetbrains.annotations.NotNull; import org.jetbrains.annotations.Nullable; import static com.intellij.openapi.module.ModuleUtil.findModuleForPsiElement; import static org.qi4j.ide.plugin.idea.common.vfs.VirtualFileUtil.getVirtualFile; /** * @author edward.yakop@gmail.com * @since 0.1 */ public class GlobalSearchScopeUtil { /** * Determine search scope given a psi element. * * @param psiElement context. * @return Search scope given psi class. * @since 0.1 */ @Nullable public static GlobalSearchScope determineSearchScope( @NotNull PsiElement psiElement ) { VirtualFile classVirtualFile = getVirtualFile( psiElement ); if( classVirtualFile == null ) { return null; } Module module = findModuleForPsiElement( psiElement ); if( module == null ) { return null; } Project project = psiElement.getProject(); ProjectRootManager projectRootManager = ProjectRootManager.getInstance( project ); boolean includeTestClasses = projectRootManager.getFileIndex().isInTestSourceContent( classVirtualFile ); return module.getModuleWithDependenciesAndLibrariesScope( includeTestClasses ); } }
{ "content_hash": "ea1a57b6d51ae0bf2e52fb8e6b9e41f5", "timestamp": "", "source": "github", "line_count": 50, "max_line_length": 113, "avg_line_length": 31.88, "alnum_prop": 0.7208281053952321, "repo_name": "ramtej/Qi4j.Repo.4.Sync", "id": "f0437e2b7629d64bbfea686a82de4419db5209e8", "size": "2175", "binary": false, "copies": "3", "ref": "refs/heads/develop", "path": "tools/qidea/src/main/java/org/qi4j/ide/plugin/idea/common/psi/search/GlobalSearchScopeUtil.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "CSS", "bytes": "44634" }, { "name": "Groovy", "bytes": "14940" }, { "name": "HTML", "bytes": "73839" }, { "name": "Java", "bytes": "6871146" }, { "name": "JavaScript", "bytes": "17052" }, { "name": "Python", "bytes": "4879" }, { "name": "Ruby", "bytes": "81" }, { "name": "Scala", "bytes": "2917" }, { "name": "Shell", "bytes": "4516" }, { "name": "XSLT", "bytes": "53394" } ], "symlink_target": "" }
<!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.7"/> <title>Pratice Scheduler: C:/Users/Alexandre/Programmation/C++/Practice Scheduler/PracticeScheduler Directory Reference</title> <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="navtree.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="resize.js"></script> <script type="text/javascript" src="navtree.js"></script> <script type="text/javascript"> $(document).ready(initResizable); $(window).load(resizeHeight); </script> <link href="search/search.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="search/search.js"></script> <script type="text/javascript"> $(document).ready(function() { searchBox.OnSelectItem(0); }); </script> <link href="doxygen.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td style="padding-left: 0.5em;"> <div id="projectname">Pratice Scheduler &#160;<span id="projectnumber">0.1</span> </div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.8.7 --> <script type="text/javascript"> var searchBox = new SearchBox("searchBox", "search",false,'Search'); </script> <div id="navrow1" class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main&#160;Page</span></a></li> <li><a href="pages.html"><span>Related&#160;Pages</span></a></li> <li><a href="annotated.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> <li> <div id="MSearchBox" class="MSearchBoxInactive"> <span class="left"> <img id="MSearchSelect" src="search/mag_sel.png" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" alt=""/> <input type="text" id="MSearchField" value="Search" accesskey="S" onfocus="searchBox.OnSearchFieldFocus(true)" onblur="searchBox.OnSearchFieldFocus(false)" onkeyup="searchBox.OnSearchFieldChange(event)"/> </span><span class="right"> <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a> </span> </div> </li> </ul> </div> </div><!-- top --> <div id="side-nav" class="ui-resizable side-nav-resizable"> <div id="nav-tree"> <div id="nav-tree-contents"> <div id="nav-sync" class="sync"></div> </div> </div> <div id="splitbar" style="-moz-user-select:none;" class="ui-resizable-handle"> </div> </div> <script type="text/javascript"> $(document).ready(function(){initNavTree('dir_7b1f42ac4f727f110dae484b796ae82a.html','');}); </script> <div id="doc-content"> <!-- window showing the filter options --> <div id="MSearchSelectWindow" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" onkeydown="return searchBox.OnSearchSelectKey(event)"> <a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Pages</a></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 class="header"> <div class="headertitle"> <div class="title">PracticeScheduler Directory Reference</div> </div> </div><!--header--> <div class="contents"> <table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="subdirs"></a> Directories</h2></td></tr> <tr class="memitem:dir_3638442e9d8bf14561dd79d517ec05a1"><td class="memItemLeft" align="right" valign="top">directory &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="dir_3638442e9d8bf14561dd79d517ec05a1.html">model</a></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:dir_639758b52ab2c6b16006bd3e3babcfcb"><td class="memItemLeft" align="right" valign="top">directory &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="dir_639758b52ab2c6b16006bd3e3babcfcb.html">test</a></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:dir_4ee6e77cf56dcfc98c770801d9f9708a"><td class="memItemLeft" align="right" valign="top">directory &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="dir_4ee6e77cf56dcfc98c770801d9f9708a.html">Util</a></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr> <tr class="memitem:dir_4cb4278a94113e34656138a566feff50"><td class="memItemLeft" align="right" valign="top">directory &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="dir_4cb4278a94113e34656138a566feff50.html">view</a></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr> </table><table class="memberdecls"> <tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="files"></a> Files</h2></td></tr> <tr class="memitem:main_8cpp"><td class="memItemLeft" align="right" valign="top">file &#160;</td><td class="memItemRight" valign="bottom"><b>main.cpp</b></td></tr> <tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr> </table> </div><!-- contents --> </div><!-- doc-content --> <!-- start footer part --> <div id="nav-path" class="navpath"><!-- id is needed for treeview function! --> <ul> <li class="navelem"><a class="el" href="dir_7b1f42ac4f727f110dae484b796ae82a.html">PracticeScheduler</a></li> <li class="footer">Generated on Wed May 7 2014 00:18:19 for Pratice Scheduler by <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.8.7 </li> </ul> </div> </body> </html>
{ "content_hash": "810967ad3cdb35cedff6e79b22226a40", "timestamp": "", "source": "github", "line_count": 132, "max_line_length": 546, "avg_line_length": 52.34090909090909, "alnum_prop": 0.6757852077001013, "repo_name": "Alex0216/PracticeScheduler", "id": "ce58e1810c2a3ff9cae0e076b4f67b5918f4e12d", "size": "6909", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "Doc/html/dir_7b1f42ac4f727f110dae484b796ae82a.html", "mode": "33188", "license": "mit", "language": [ { "name": "C++", "bytes": "50606" }, { "name": "CSS", "bytes": "33023" }, { "name": "IDL", "bytes": "1368" }, { "name": "JavaScript", "bytes": "76145" }, { "name": "Shell", "bytes": "618" }, { "name": "TeX", "bytes": "88153" } ], "symlink_target": "" }
<?xml version="1.0" encoding="utf-8"?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <title>The Pomodoro Technique and My Little Pomodoro</title> <meta name="description" content="Get started quickly with My Little Pomodoro."> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <link href="../css/mlp.css" rel="stylesheet" type="text/css" media="all" /> </head> <body> <div id="navbar"> <a id="navleft" href="../MyLittlePomodoroHelp.html">My Little Pomodoro Help</a> <a id="navright" href="index"></a> </div> <h2>The Pomodoro Technique and My Little Pomodoro</h2> <p>The Pomodoro Technique is a time management method developed by Francesco Cirillo in the 1980s. It uses a 25 minute work period, called a "pomodoro", followed by breaks.</p> <h3>There are five basic steps to using the technique:</h3> <ol class="instructions"> <li>Choose a task to be accomplished, and write it on a piece of paper. <li>Set the timer to 25 minutes.</li> <li>Work on the task until the timer rings, then put a mark next to the task.</li> <li>Take a short break, between 3-5 minutes.</li> <li>Every 4 Pomodoros, take a long break (15-30 minutes).</li> </ol> <p><b>My Little Pomodoro</b> aims to be the Pomodoro timer, and the paper and pen used for recording tasks, that you use while working. And just in case the 25/5/15 minute split does not work for you, My Little Pomodoro lets you adjust these timer lengths.</p> </body> </html>
{ "content_hash": "d3439e8f7b2daf4009a7545a3f07b9f2", "timestamp": "", "source": "github", "line_count": 33, "max_line_length": 262, "avg_line_length": 48.303030303030305, "alnum_prop": 0.7026348808030113, "repo_name": "klw0/my-little-pomodoro", "id": "f06cbfbdbc967c57cd300b95d1b8e65909ea4d74", "size": "1594", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "MyLittlePomodoro.help/Contents/Resources/English.lproj/html/the-pomodoro-technique.html", "mode": "33188", "license": "bsd-3-clause", "language": [ { "name": "AppleScript", "bytes": "1294" }, { "name": "C", "bytes": "16885" }, { "name": "Objective-C", "bytes": "596425" }, { "name": "Python", "bytes": "17730" } ], "symlink_target": "" }
require 'spec_helper' describe "article_pages", type: :feature, dbscope: :example, js: true do let(:site) { cms_site } let!(:part) { create :cms_part_free, html: '<div id="part" class="part"><br><br><br>free html part<br><br><br></div>' } let(:layout_html) do <<~HTML.freeze <html> <head> <meta name="viewport" content="width=device-width,initial-scale=1.0,user-scalable=yes,minimum-scale=1.0,maximum-scale=2.0"> </head> <body> <br><br><br> {{ part "#{part.filename.sub(/\..*/, '')}" }} <div id="main" class="page"> {{ yield }} </div> </body> </html> HTML end let!(:layout) { create :cms_layout, html: layout_html } let!(:node) { create(:article_node_page, cur_site: site, layout_id: layout.id) } let!(:node2) { create :article_node_page, cur_site: site, group_ids: [cms_group.id] } let!(:selectable_page1) { create :article_page, cur_site: site, cur_node: node2, state: "public" } let!(:selectable_page2) { create :article_page, cur_site: site, cur_node: node2, state: "public" } let!(:selectable_page3) { create :article_page, cur_site: site, cur_node: node2, state: "public" } let!(:selectable_page4) { create :article_page, cur_site: site, cur_node: node2, state: "closed" } let!(:form) { create :cms_form, cur_site: site, state: 'public', sub_type: 'entry', html: nil } let!(:column1) do create( :cms_column_text_field, cur_site: site, cur_form: form, required: "optional", order: 1, input_type: 'text', max_length: 80 ) end let!(:column2) do create(:cms_column_date_field, cur_site: site, cur_form: form, required: "optional", order: 2) end let!(:column3) do create(:cms_column_url_field2, cur_site: site, cur_form: form, required: "optional", order: 3, html_tag: '') end let!(:column4) do create(:cms_column_text_area, cur_site: site, cur_form: form, required: "optional", order: 4) end let!(:column5) do create(:cms_column_select, cur_site: site, cur_form: form, required: "optional", order: 5) end let!(:column6) do create(:cms_column_radio_button, cur_site: site, cur_form: form, required: "optional", order: 6) end let!(:column7) do create(:cms_column_check_box, cur_site: site, cur_form: form, required: "optional", order: 7) end let!(:column8) do create(:cms_column_file_upload, cur_site: site, cur_form: form, required: "optional", order: 8, file_type: "image") end let!(:column9) do create(:cms_column_free, cur_site: site, cur_form: form, required: "optional", order: 9) end let!(:column10) do create(:cms_column_headline, cur_site: site, cur_form: form, required: "optional", order: 10) end let!(:column11) do create(:cms_column_list, cur_site: site, cur_form: form, required: "optional", order: 11) end let!(:column12) do create(:cms_column_table, cur_site: site, cur_form: form, required: "optional", order: 12) end let!(:column13) do create(:cms_column_youtube, cur_site: site, cur_form: form, required: "optional", order: 13) end let!(:column14) do create(:cms_column_select_page, cur_site: site, cur_form: form, required: "optional", order: 14, node_ids: [node2.id]) end before do site.set(auto_keywords: 'enabled', auto_description: 'enabled') node.st_form_ids = [ form.id ] node.save! login_cms_user end describe "add column with entry form on preview editing" do shared_examples "what add column with entry form is" do let!(:item) { create(:article_page, cur_site: site, cur_node: node, layout: layout, form: form, state: state) } let(:column1_value1) { unique_id } let(:column2_date1) { Date.new(rand(2000..2050), 1, 1) } let(:column2_value1) { I18n.l(column2_date1, format: :picker) } let(:column3_label1) { unique_id } let(:column3_url1) { "/#{unique_id}/" } let(:column4_value1) { Array.new(2) { unique_id }.join("\n") } let(:column5_value1) { column5.select_options.sample } let(:column6_value1) { column6.select_options.sample } let(:column7_value1) { column7.select_options.sample } let(:column8_image_text1) { unique_id } let(:column9_value1) { unique_id } # let(:column10_head1) { %w(h1 h2 h3 h4 h5).sample } let(:column10_head1) { %w(h1 h2).sample } let(:column10_text1) { unique_id } let(:column11_list1) { unique_id } let(:column12_height1) { rand(2..100) } let(:column12_width1) { rand(2..100) } let(:column12_caption1) { unique_id } let(:column13_youtube_id1) { unique_id } let(:column13_url1) { "https://www.youtube.com/watch?v=#{column13_youtube_id1}" } let(:column14_page1) { [ selectable_page1, selectable_page2, selectable_page3 ].sample } it do visit cms_preview_path(site: site, path: item.preview_path) # start preview editing wait_event_to_fire "ss:inplaceModeChanged" do within "#ss-preview" do within ".ss-preview-wrap-column-edit-mode" do click_on I18n.t("cms.inplace_edit") end end end # #1: cms_column_text_field wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column1.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-textfield" do fill_in "item[column_values][][in_wrap][value]", with: column1_value1 end click_on state == "public" ? I18n.t("cms.buttons.save_as_branch") : I18n.t("ss.buttons.save") expect(page).to have_css("#errorSyntaxChecker", text: I18n.t("errors.template.no_errors")) expect(page).to have_css("#errorFormChecker", text: I18n.t("errors.template.no_errors")) expect(page).to have_css("#errorLinkChecker", text: I18n.t("errors.template.check_links")) end end if state == "public" expect(page).to have_css(".ss-preview-notice-wrap", text: I18n.t("workflow.notice.created_branch_page")) else expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') end item.reload if state == "public" expect(item.branches.count).to eq 1 now_editing_item = item.branches.first else now_editing_item = item end expect(now_editing_item.column_values.count).to eq 1 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value1 = column_values[0] expect(column_value1.column_id).to eq column1.id expect(column_value1.value).to eq column1_value1 expect(column_value1.order).to eq 0 # #2: cms_column_date_field wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column2.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-datefield" do fill_in "item[column_values][][in_wrap][date]", with: column2_value1 end click_on I18n.t("ss.buttons.save") end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 2 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value2 = column_values.last expect(column_value2.column_id).to eq column2.id expect(column_value2.date).to eq column2_date1.in_time_zone expect(column_value2.order).to eq 1 # #3: cms_column_url_field2 wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column3.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-urlfield2" do fill_in "item[column_values][][in_wrap][link_label]", with: column3_label1 fill_in "item[column_values][][in_wrap][link_url]", with: column3_url1 end click_on I18n.t("ss.buttons.save") expect(page).to have_css("#errorSyntaxChecker", text: I18n.t("errors.template.no_errors")) expect(page).to have_css("#errorLinkChecker", text: I18n.t("errors.template.check_links")) end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 3 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value3 = column_values.last expect(column_value3.column_id).to eq column3.id expect(column_value3.link_label).to eq column3_label1 expect(column_value3.link_url).to eq column3_url1 expect(column_value3.order).to eq 2 # #4: cms_column_text_area wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column4.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-textarea" do fill_in "item[column_values][][in_wrap][value]", with: column4_value1 end click_on I18n.t("ss.buttons.save") expect(page).to have_css("#errorSyntaxChecker", text: I18n.t("errors.template.no_errors")) expect(page).to have_css("#errorLinkChecker", text: I18n.t("errors.template.check_links")) end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 4 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value4 = column_values.last expect(column_value4.column_id).to eq column4.id expect(column_value4.value).to eq column4_value1.gsub("\n", "\r\n") expect(column_value4.order).to eq 3 # #5: cms_column_select wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column5.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-select" do select column5_value1, from: "item[column_values][][in_wrap][value]" end click_on I18n.t("ss.buttons.save") end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 5 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value5 = column_values.last expect(column_value5.column_id).to eq column5.id expect(column_value5.value).to eq column5_value1 expect(column_value5.order).to eq 4 # #6: cms_column_radio_button wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column6.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-radiobutton" do first(:field, type: "radio", with: column6_value1).click end click_on I18n.t("ss.buttons.save") end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 6 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value6 = column_values.last expect(column_value6.column_id).to eq column6.id expect(column_value6.value).to eq column6_value1 expect(column_value6.order).to eq 5 # #7: cms_column_check_box wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column7.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-checkbox" do first(:field, name: "item[column_values][][in_wrap][values][]", with: column7_value1).click end click_on I18n.t("ss.buttons.save") end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 7 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value7 = column_values.last expect(column_value7.column_id).to eq column7.id expect(column_value7.values).to eq [ column7_value1 ] expect(column_value7.order).to eq 6 # #8: cms_column_file_upload wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column8.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-fileupload" do fill_in "item[column_values][][in_wrap][file_label]", with: column8_image_text1 click_on I18n.t("ss.links.upload") end end wait_for_cbox do attach_file 'item[in_files][]', "#{Rails.root}/spec/fixtures/ss/file/keyvisual.gif" click_on I18n.t('ss.buttons.attach') end within 'form#item-form' do within ".column-value-cms-column-fileupload" do expect(page).to have_content("keyvisual.gif") end click_on I18n.t("ss.buttons.save") expect(page).to have_css("#errorSyntaxChecker", text: I18n.t("errors.template.no_errors")) expect(page).to have_css("#errorLinkChecker", text: I18n.t("errors.template.check_links")) end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 8 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value8 = column_values.last expect(column_value8.column_id).to eq column8.id expect(column_value8.file_label).to eq column8_image_text1 expect(column_value8.file.name).to eq 'keyvisual.gif' expect(column_value8.file.owner_item_id).to eq now_editing_item.id expect(column_value8.order).to eq 7 # #9: cms_column_free wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column9.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-free" do fill_in_ckeditor "item[column_values][][in_wrap][value]", with: column9_value1 click_on I18n.t("ss.links.upload") end end wait_for_cbox do attach_file 'item[in_files][]', "#{Rails.root}/spec/fixtures/ss/file/keyvisual.gif" click_on I18n.t('ss.buttons.attach') end within "#item-form" do within ".column-value-cms-column-free" do expect(page).to have_content("keyvisual.gif") wait_for_ckeditor_event "item[column_values][][in_wrap][value]", "afterInsertHtml" do click_on I18n.t("sns.image_paste") end end click_on I18n.t("ss.buttons.ignore_alerts_and_save") end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 9 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value9 = column_values.last expect(column_value9.column_id).to eq column9.id expect(column_value9.value).to include column9_value1 expect(column_value9.file_ids).to have(1).items column9_file1 = column_value9.files.first expect(column9_file1.name).to eq "keyvisual.gif" expect(column9_file1.owner_item_id).to eq now_editing_item.id expect(column_value9.value).to include column9_file1.url expect(column_value9.order).to eq 8 # #10: cms_column_headline wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column10.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-headline" do select column10_head1, from: "item[column_values][][in_wrap][head]" fill_in "item[column_values][][in_wrap][text]", with: column10_text1 end click_on I18n.t("ss.buttons.save") expect(page).to have_css("#errorSyntaxChecker", text: I18n.t("errors.template.no_errors")) expect(page).to have_css("#errorLinkChecker", text: I18n.t("errors.template.check_links")) end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 10 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value10 = column_values.last expect(column_value10.column_id).to eq column10.id expect(column_value10.head).to eq column10_head1 expect(column_value10.text).to eq column10_text1 expect(column_value10.order).to eq 9 # #11: cms_column_list wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column11.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-list" do fill_in "item[column_values][][in_wrap][lists][]", with: column11_list1 end click_on I18n.t("ss.buttons.save") expect(page).to have_css("#errorSyntaxChecker", text: I18n.t("errors.template.no_errors")) expect(page).to have_css("#errorLinkChecker", text: I18n.t("errors.template.check_links")) end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 11 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value11 = column_values.last expect(column_value11.column_id).to eq column11.id expect(column_value11.lists).to include column11_list1 expect(column_value11.order).to eq 10 # #12: cms_column_table wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column12.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-table" do find("input.height").set(column12_height1) find("input.width").set(column12_width1) find("input.caption").set(column12_caption1) click_on I18n.t("cms.column_table.create") end click_on I18n.t("ss.buttons.save") expect(page).to have_css("#errorSyntaxChecker", text: I18n.t("errors.template.no_errors")) expect(page).to have_css("#errorLinkChecker", text: I18n.t("errors.template.check_links")) end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 12 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value12 = column_values.last expect(column_value12.column_id).to eq column12.id expect(column_value12.order).to eq 11 # #13: cms_column_youtube wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column13.name end end end within_frame page.first("#ss-preview-dialog-frame") do within "#item-form" do within ".column-value-cms-column-youtube" do fill_in "item[column_values][][in_wrap][url]", with: column13_url1 end click_on I18n.t("ss.buttons.save") expect(page).to have_css("#errorSyntaxChecker", text: I18n.t("errors.template.no_errors")) expect(page).to have_css("#errorLinkChecker", text: I18n.t("errors.template.check_links")) end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 13 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value13 = column_values.last expect(column_value13.column_id).to eq column13.id expect(column_value13.youtube_id).to eq column13_youtube_id1 expect(column_value13.order).to eq 12 # #14: cms_column_select_page wait_event_to_fire("ss:inplaceEditFrameInitialized") do within_frame page.first("#ss-preview-form-palette") do within ".column-value-palette" do click_on column14.name end end end within_frame page.first("#ss-preview-dialog-frame") do click_on I18n.t("cms.apis.pages.index") wait_for_cbox do expect(page).to have_css(".list-item", text: selectable_page1.name) expect(page).to have_css(".list-item", text: selectable_page2.name) expect(page).to have_css(".list-item", text: selectable_page3.name) expect(page).to have_no_css(".list-item", text: selectable_page4.name) click_on column14_page1.name end within 'form#item-form' do within ".column-value-cms-column-selectpage " do expect(page).to have_css(".ajax-selected", text: column14_page1.name) end click_on I18n.t("ss.buttons.save") end end expect(page).to have_css("#ss-notice", text: I18n.t("ss.notice.saved")) page.execute_script('$("#ss-notice").remove();') now_editing_item.reload expect(now_editing_item.column_values.count).to eq 14 column_values = now_editing_item.column_values.order_by(order: 1, name: 1).to_a column_value14 = column_values.last expect(column_value14.column_id).to eq column14.id expect(column_value14.page_id).to eq column14_page1.id expect(column_value14.order).to eq 13 end end context "with public page" do let(:state) { "public" } it_behaves_like "what add column with entry form is" end context "with closed page" do let(:state) { "closed" } it_behaves_like "what add column with entry form is" end end end
{ "content_hash": "c579fd72abd8fa6af8a50c4c586da87c", "timestamp": "", "source": "github", "line_count": 599, "max_line_length": 131, "avg_line_length": 43.27545909849749, "alnum_prop": 0.6036185479515469, "repo_name": "ShinjiTanimoto/shirasagi", "id": "72df4a6e7a1c69a8a1d7789c2a80756bcbcd8e01", "size": "25922", "binary": false, "copies": "3", "ref": "refs/heads/master", "path": "spec/features/article/pages/preview_editing/add_column_with_entry_form_spec.rb", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "82226" }, { "name": "HTML", "bytes": "3233606" }, { "name": "JavaScript", "bytes": "11964294" }, { "name": "Ruby", "bytes": "12347112" }, { "name": "SCSS", "bytes": "525875" }, { "name": "Shell", "bytes": "20130" } ], "symlink_target": "" }
//------------------------------------------------------------------------------ // <auto-generated> // Ce code a été généré par un outil. // Version du runtime :4.0.30319.42000 // // Les modifications apportées à ce fichier peuvent provoquer un comportement incorrect et seront perdues si // le code est régénéré. // </auto-generated> //------------------------------------------------------------------------------ namespace DataCloner.GUI.Properties { [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()] [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "14.0.0.0")] internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase { private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings()))); public static Settings Default { get { return defaultInstance; } } [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Configuration.DefaultSettingValueAttribute("0")] public short DatabaseConfigId { get { return ((short)(this["DatabaseConfigId"])); } set { this["DatabaseConfigId"] = value; } } [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Configuration.DefaultSettingValueAttribute("")] public string SourceEnvir { get { return ((string)(this["SourceEnvir"])); } set { this["SourceEnvir"] = value; } } [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Configuration.DefaultSettingValueAttribute("")] public string DestinationEnvir { get { return ((string)(this["DestinationEnvir"])); } set { this["DestinationEnvir"] = value; } } [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Configuration.DefaultSettingValueAttribute("False")] public bool IsSimulation { get { return ((bool)(this["IsSimulation"])); } set { this["IsSimulation"] = value; } } [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Configuration.DefaultSettingValueAttribute("0")] public short ServerSource { get { return ((short)(this["ServerSource"])); } set { this["ServerSource"] = value; } } [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Configuration.DefaultSettingValueAttribute("")] public string DatabaseSource { get { return ((string)(this["DatabaseSource"])); } set { this["DatabaseSource"] = value; } } [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Configuration.DefaultSettingValueAttribute("")] public string SchemaSource { get { return ((string)(this["SchemaSource"])); } set { this["SchemaSource"] = value; } } [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Configuration.DefaultSettingValueAttribute("")] public string TableSource { get { return ((string)(this["TableSource"])); } set { this["TableSource"] = value; } } [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Configuration.DefaultSettingValueAttribute("")] public string ColumnSource { get { return ((string)(this["ColumnSource"])); } set { this["ColumnSource"] = value; } } [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Configuration.DefaultSettingValueAttribute("False")] public bool DoOptimisation { get { return ((bool)(this["DoOptimisation"])); } set { this["DoOptimisation"] = value; } } [global::System.Configuration.UserScopedSettingAttribute()] [global::System.Diagnostics.DebuggerNonUserCodeAttribute()] [global::System.Configuration.DefaultSettingValueAttribute("0")] public short DefaultAppId { get { return ((short)(this["DefaultAppId"])); } set { this["DefaultAppId"] = value; } } } }
{ "content_hash": "63244fa89ef4ee852e6008876af4e2a1", "timestamp": "", "source": "github", "line_count": 158, "max_line_length": 151, "avg_line_length": 37.18987341772152, "alnum_prop": 0.5542886317222601, "repo_name": "naster01/DataCloner", "id": "a7b0fcefdf33030935104e26b909728681520cda", "size": "5889", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "archive/DataCloner.GUI/Properties/Settings.Designer.cs", "mode": "33188", "license": "mit", "language": [ { "name": "Batchfile", "bytes": "3635" }, { "name": "C#", "bytes": "1317908" }, { "name": "PLpgSQL", "bytes": "3569371" } ], "symlink_target": "" }
title: Marathon Recipes --- # Marathon Recipes Below are some common patterns for specifying Marathon apps. ## Docker See the detailed docs on <a href="{{ site.baseurl }}/docs/native-docker.html">Docker Containers</a>. ### Simple Docker Example ```json { "id": "simple-docker", "container": { "docker": { "image": "busybox" } }, "cmd": "echo hello from docker", "cpus": 0.2, "mem": 32.0, "instances": 2 } ``` ### Docker with entry point ```json { "id": "simple-docker", "container": { "docker": { "image": "mesosphere/inky" } }, "args": ["hello", "from", "docker"], "cpus": 0.2, "mem": 32.0, "instances": 2 } ``` where the "mesosphere/inky" Dockerfile is defined as: ```Dockerfile FROM busybox LABEL maintainer="support@mesosphere.io" CMD ["inky"] ENTRYPOINT ["echo"] ``` ### Start a private docker registry The following JSON file will make a private Docker registry available in your cluster. ```json { "id": "/docker/registry", "instances": 1, "cpus": 0.5, "mem": 1024.0, "disk": 128, "networks": [ { "mode": "container/bridge" } ], "container": { "docker": { "type": "DOCKER", "image": "registry:latest", "parameters": [], }, "portMappings": [ { "containerPort": 5000, "hostPort": 0, "protocol": "tcp", "servicePort": 5000 } ], "volumes": [ { "hostPath": "/local/path/to/store/packages", "containerPath": "/storage", "mode": "RW" } ] }, "env": { "SETTINGS_FLAVOR": "local", "STORAGE_PATH": "/storage" }, "ports": [0] } ``` ## Health Checks See the detailed docs on <a href="{{ site.baseurl }}/docs/health-checks.html">Health Checks</a>. ### HTTP health checks ```json { "id": "toggle", "cmd": "python toggle.py $PORT0", "cpus": 0.2, "disk": 0.0, "healthChecks": [ { "protocol": "HTTP", "path": "/health", "portIndex": 0, "gracePeriodSeconds": 5, "intervalSeconds": 10, "timeoutSeconds": 10, "maxConsecutiveFailures": 3 } ], "instances": 2, "mem": 32.0, "ports": [0], "uris": ["http://downloads.mesosphere.com/misc/toggle.tgz"] } ``` ### TCP health checks ```json { "id": "toggle", "cmd": "python toggle.py $PORT0", "cpus": 0.2, "disk": 0.0, "healthChecks": [ { "protocol": "TCP", "portIndex": 0, "gracePeriodSeconds": 5, "intervalSeconds": 10, "timeoutSeconds": 10, "maxConsecutiveFailures": 3 } ], "instances": 2, "mem": 32.0, "ports": [0], "uris": ["http://downloads.mesosphere.com/misc/toggle.tgz"] } ``` ### Command (executor) health checks Command health checks are executed on the slave where the task is running. To enable this feature for marathon versions prior to `0.7.4`, start Marathon with the `--executor_health_checks` flag (not required/allowed since `0.7.4`). Requires Mesos version `0.20.0` or later. ```json { "id": "toggle", "cmd": "python toggle.py $PORT0", "cpus": 0.2, "disk": 0.0, "healthChecks": [ { "protocol": "COMMAND", "command": { "value": "curl -f http://$HOST:$PORT0/" }, "gracePeriodSeconds": 5, "intervalSeconds": 10, "timeoutSeconds": 10, "maxConsecutiveFailures": 3 } ], "instances": 2, "mem": 32.0, "ports": [0], "uris": ["http://downloads.mesosphere.com/misc/toggle.tgz"] } ``` ## Constraining task placement / static partitioning Usually, Marathon decides where to start your application tasks without your input. This allows your infrastructure to scale easily, since all resources are treated equally. However, there are times when you want to separate some machines from the common pool and schedule only certain tasks on them. For example: * Some nodes in your cluster have publicly reachable network addresses and you only want to start tasks there that make use of public addresses. * Some nodes in your cluster have special hardware, such as very fast SSDs or GPUs, that you want to reserve for tasks that need this hardware. See the detailed docs on <a href="{{ site.baseurl }}/docs/constraints.html">constraints</a>. ### Using roles You can configure some of your Mesos agents to only offer their resources to a specific Mesos role. Only Mesos frameworks (such as Marathon) that are configured for this specific Mesos role will get offers for these resources. In this way, you can prevent accidental usage of these resources by other Mesos frameworks. 1. Configure Marathon: `--mesos_role yourrole` 2. Configure the Mesos master: `--roles=<...other roles...>,yourrole` 3. Configuring the Mesos agents whose resource offers you want to restrict. Either use the `--default_role yourrole` flag to assign all that agent's resources to your role or use the `--resources` flag to assign individual resources to that role (such as a certain port range). See [the Mesos command line documentation](http://mesos.apache.org/documentation/latest/configuration/) for details. ### Preventing Accidental Use of Special Roles inside Marathon With the base setup, that is, with no command-line parameters specified, all Marathon applications will by default use all resources either assigned to the unspecific "*" role or the role you specified with `--mesos_role`. To ensure that only special tasks are run on nodes you specify, you can use a separate Marathon instance for those tasks. You can also configure Marathon to ignore your special roles for apps by default, then explicitly configure the exceptions: 1. Configure Marathon to ignore the special resources by default: `--default_accepted_resource_roles '*'` (make sure that you quote the "*" correctly) 2. Configure an app to run on top of resources of your special role: ```javascript { "id": "/my.special.app", "acceptedResourceRoles": [ "yourrole" ] // ... more config ... } ``` ### Limitations of Static Partitioning with Roles * One framework can currently only be assigned to one role. So if you have multiple types of special nodes, you need to have separate frameworks for them. * You must reconfigure your Mesos master and some of your agents in order to use this functionality. ### Using constraints You can use constraints to restrict where to run the tasks for your apps. See [constraints]({ site.baseurl }}/docs/constraints.html) for details. The advantage of using constraints to restrict where tasks run is that you only have to provide appropriate attributes on the Mesos agents. The disadvantages are that nothing prevents another framework from scheduling tasks on these agents and consuming all the resources your special tasks need. To avoid this, you need to configure Marathon so that all non-special apps are constrained *not* to use the special nodes. ## Running a Single Instance Application Often, multiple instances of legacy applications cannot be run concurrently. The `MARATHON_SINGLE_INSTANCE_APP` label allows you to prevent users from scaling such an application beyond a single instance. 1. In your application definition, set the label `MARATHON_SINGLE_INSTANCE_APP` to true: ```json "labels":{ "MARATHON_SINGLE_INSTANCE_APP": "true", } ``` 1. Specify the following `upgradeStrategy`, which permits Marathon to kill all instances: ```json "upgradeStrategy":{ "minimumHealthCapacity": 0, "maximumOverCapacity": 0 } ```
{ "content_hash": "bcaea7e2c1544f98e19faff6a8a5e395", "timestamp": "", "source": "github", "line_count": 265, "max_line_length": 395, "avg_line_length": 28.260377358490565, "alnum_prop": 0.6728535184937909, "repo_name": "janisz/marathon", "id": "e24a31e7f88135064e454db48f8103eb51df295e", "size": "7493", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "docs/docs/recipes.md", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Clojure", "bytes": "59270" }, { "name": "Groovy", "bytes": "14820" }, { "name": "HTML", "bytes": "502" }, { "name": "Java", "bytes": "778" }, { "name": "Makefile", "bytes": "3144" }, { "name": "Python", "bytes": "230532" }, { "name": "Ruby", "bytes": "772" }, { "name": "Scala", "bytes": "4478462" }, { "name": "Shell", "bytes": "47376" } ], "symlink_target": "" }
<?php namespace PC\PresentationBundle\DependencyInjection; use Symfony\Component\DependencyInjection\ContainerBuilder; use Symfony\Component\Config\FileLocator; use Symfony\Component\HttpKernel\DependencyInjection\Extension; use Symfony\Component\DependencyInjection\Loader; /** * This is the class that loads and manages your bundle configuration * * To learn more see {@link http://symfony.com/doc/current/cookbook/bundles/extension.html} */ class PCPresentationExtension extends Extension { /** * {@inheritDoc} */ public function load(array $configs, ContainerBuilder $container) { $configuration = new Configuration(); $config = $this->processConfiguration($configuration, $configs); $loader = new Loader\YamlFileLoader($container, new FileLocator(__DIR__.'/../Resources/config')); $loader->load('services.yml'); } }
{ "content_hash": "c00aae12131d172f1ce3782dfe91ec82", "timestamp": "", "source": "github", "line_count": 28, "max_line_length": 105, "avg_line_length": 31.678571428571427, "alnum_prop": 0.7294250281848929, "repo_name": "guillaume-sainthillier/presentation_com", "id": "bcb2ca25ffb235166c08868a1191173c8b121da8", "size": "887", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/PC/PresentationBundle/DependencyInjection/PCPresentationExtension.php", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "317044" }, { "name": "JavaScript", "bytes": "702391" }, { "name": "PHP", "bytes": "44041" }, { "name": "Shell", "bytes": "182" } ], "symlink_target": "" }
<nav id="mainNav" class="navbar navbar-default navbar-fixed-top"> <div class="container-fluid"> <!-- Brand and toggle get grouped for better mobile display --> <div class="navbar-header"> <button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1"> <span class="sr-only">Toggle navigation</span> <span class="icon-bar"></span> <span class="icon-bar"></span> <span class="icon-bar"></span> </button> <a class="navbar-brand page-scroll" href="#page-top">Morning Co.</a> </div> <!-- Collect the nav links, forms, and other content for toggling --> <div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1"> <ul class="nav navbar-nav navbar-right"> <li> <a class="page-scroll" href="#about">About</a> </li> <li> <a class="page-scroll" href="#services">Services</a> </li> <li> <a class="page-scroll" href="#portfolio">Partners</a> </li> <li> <a class="page-scroll" href="#contact">Contact</a> </li> </ul> </div> <!-- /.navbar-collapse --> </div> <!-- /.container-fluid --> </nav>
{ "content_hash": "8e67587e43d37a31281156d7d1a15a21", "timestamp": "", "source": "github", "line_count": 34, "max_line_length": 133, "avg_line_length": 42.6764705882353, "alnum_prop": 0.49276361130255, "repo_name": "imyme6yo/imyme6yo.github.io", "id": "c620396b06ec7e62e619d43ee777890cd12409b0", "size": "1451", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "_includes/nav.html", "mode": "33261", "license": "apache-2.0", "language": [ { "name": "CSS", "bytes": "128556" }, { "name": "HTML", "bytes": "19220" }, { "name": "JavaScript", "bytes": "5055" } ], "symlink_target": "" }
http://www.futaba-kikaku.jp/ # Installation # Todo # authors * Hideya Ochiai * Hiroyuki Ikegami
{ "content_hash": "afa0d6cb8c7ef8b3f04ae7a22f2c3e7f", "timestamp": "", "source": "github", "line_count": 11, "max_line_length": 28, "avg_line_length": 9.181818181818182, "alnum_prop": 0.7029702970297029, "repo_name": "ikegam/SPC1-to-IEEE1888", "id": "d5952adf21ab7de60822a4b7f0a779baea36bcf8", "size": "164", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "README.md", "mode": "33188", "license": "bsd-3-clause", "language": [ { "name": "C", "bytes": "36945" } ], "symlink_target": "" }
namespace GraphTransformerHelpers { void RegisterGraphTransformers(onnxruntime::InferenceSession* lotusSession) { // Register Lotus graph transformers // we were able to combine all of the winml/dml/ort work except for 2 transformers. // these 2 are tracked by : // Bug 22973884 : Fix issues with BatchNorm + Add and BatchNorm + Mul handling implicit inputs, and move from Winml to ORT // std::unique_ptr<onnxruntime::RuleBasedGraphTransformer> rule_transformer = std::make_unique<onnxruntime::RuleBasedGraphTransformer>("WinmlRuleTransformer"); ORT_THROW_IF_ERROR(rule_transformer->Register(std::make_unique<onnxruntime::BatchNormalizationMulFusion>())); ORT_THROW_IF_ERROR(rule_transformer->Register(std::make_unique<onnxruntime::BatchNormalizationAddFusion>())); ORT_THROW_IF_ERROR(lotusSession->RegisterGraphTransformer(std::move(rule_transformer), onnxruntime::TransformerLevel::Level1)); } }
{ "content_hash": "7b7ac9a28e0307a1fca1a533492c51e5", "timestamp": "", "source": "github", "line_count": 17, "max_line_length": 130, "avg_line_length": 62.294117647058826, "alnum_prop": 0.6817752596789424, "repo_name": "microsoft/onnxruntime", "id": "2bf5b24071263147d3c851d823e82f6e53e7479c", "size": "1825", "binary": false, "copies": "1", "ref": "refs/heads/main", "path": "onnxruntime/core/providers/dml/GraphTransformers/GraphTransformerHelpers.cc", "mode": "33188", "license": "mit", "language": [ { "name": "Assembly", "bytes": "1763425" }, { "name": "Batchfile", "bytes": "17040" }, { "name": "C", "bytes": "955390" }, { "name": "C#", "bytes": "2304597" }, { "name": "C++", "bytes": "39435305" }, { "name": "CMake", "bytes": "514764" }, { "name": "CSS", "bytes": "138431" }, { "name": "Cuda", "bytes": "1104338" }, { "name": "Dockerfile", "bytes": "8089" }, { "name": "HLSL", "bytes": "11234" }, { "name": "HTML", "bytes": "5933" }, { "name": "Java", "bytes": "418665" }, { "name": "JavaScript", "bytes": "212575" }, { "name": "Jupyter Notebook", "bytes": "218327" }, { "name": "Kotlin", "bytes": "4653" }, { "name": "Liquid", "bytes": "5457" }, { "name": "NASL", "bytes": "2628" }, { "name": "Objective-C", "bytes": "151027" }, { "name": "Objective-C++", "bytes": "107084" }, { "name": "Pascal", "bytes": "9597" }, { "name": "PowerShell", "bytes": "16419" }, { "name": "Python", "bytes": "5041661" }, { "name": "Roff", "bytes": "27539" }, { "name": "Ruby", "bytes": "3545" }, { "name": "Shell", "bytes": "116513" }, { "name": "Swift", "bytes": "115" }, { "name": "TypeScript", "bytes": "973087" } ], "symlink_target": "" }
<?php /** * @see Zend_Db_Adapter_Abstract */ require_once 'Zend/Db/Adapter/Abstract.php'; /** * @see Zend_Db_Expr */ require_once 'Zend/Db/Expr.php'; /** * Class for SQL SELECT generation and results. * * @category Zend * @package Zend_Db * @subpackage Select * @copyright Copyright (c) 2005-2011 Zend Technologies USA Inc. (http://www.zend.com) * @license http://framework.zend.com/license/new-bsd New BSD License */ class Zend_Db_Select { const DISTINCT = 'distinct'; const COLUMNS = 'columns'; const FROM = 'from'; const UNION = 'union'; const WHERE = 'where'; const GROUP = 'group'; const HAVING = 'having'; const ORDER = 'order'; const LIMIT_COUNT = 'limitcount'; const LIMIT_OFFSET = 'limitoffset'; const FOR_UPDATE = 'forupdate'; const INNER_JOIN = 'inner join'; const LEFT_JOIN = 'left join'; const RIGHT_JOIN = 'right join'; const FULL_JOIN = 'full join'; const CROSS_JOIN = 'cross join'; const NATURAL_JOIN = 'natural join'; const SQL_WILDCARD = '*'; const SQL_SELECT = 'SELECT'; const SQL_UNION = 'UNION'; const SQL_UNION_ALL = 'UNION ALL'; const SQL_FROM = 'FROM'; const SQL_WHERE = 'WHERE'; const SQL_DISTINCT = 'DISTINCT'; const SQL_GROUP_BY = 'GROUP BY'; const SQL_ORDER_BY = 'ORDER BY'; const SQL_HAVING = 'HAVING'; const SQL_FOR_UPDATE = 'FOR UPDATE'; const SQL_AND = 'AND'; const SQL_AS = 'AS'; const SQL_OR = 'OR'; const SQL_ON = 'ON'; const SQL_ASC = 'ASC'; const SQL_DESC = 'DESC'; /** * Bind variables for query * * @var array */ protected $_bind = array(); /** * Zend_Db_Adapter_Abstract object. * * @var Zend_Db_Adapter_Abstract */ protected $_adapter; /** * The initial values for the $_parts array. * NOTE: It is important for the 'FOR_UPDATE' part to be last to ensure * meximum compatibility with database adapters. * * @var array */ protected static $_partsInit = array( self::DISTINCT => false, self::COLUMNS => array(), self::UNION => array(), self::FROM => array(), self::WHERE => array(), self::GROUP => array(), self::HAVING => array(), self::ORDER => array(), self::LIMIT_COUNT => null, self::LIMIT_OFFSET => null, self::FOR_UPDATE => false ); /** * Specify legal join types. * * @var array */ protected static $_joinTypes = array( self::INNER_JOIN, self::LEFT_JOIN, self::RIGHT_JOIN, self::FULL_JOIN, self::CROSS_JOIN, self::NATURAL_JOIN, ); /** * Specify legal union types. * * @var array */ protected static $_unionTypes = array( self::SQL_UNION, self::SQL_UNION_ALL ); /** * The component parts of a SELECT statement. * Initialized to the $_partsInit array in the constructor. * * @var array */ protected $_parts = array(); /** * Tracks which columns are being select from each table and join. * * @var array */ protected $_tableCols = array(); /** * Class constructor * * @param Zend_Db_Adapter_Abstract $adapter */ public function __construct(Zend_Db_Adapter_Abstract $adapter) { $this->_adapter = $adapter; $this->_parts = self::$_partsInit; } /** * Get bind variables * * @return array */ public function getBind() { return $this->_bind; } /** * Set bind variables * * @param mixed $bind * @return Zend_Db_Select */ public function bind($bind) { $this->_bind = $bind; return $this; } /** * Makes the query SELECT DISTINCT. * * @param bool $flag Whether or not the SELECT is DISTINCT (default true). * @return Zend_Db_Select This Zend_Db_Select object. */ public function distinct($flag = true) { $this->_parts[self::DISTINCT] = (bool) $flag; return $this; } /** * Adds a FROM table and optional columns to the query. * * The first parameter $name can be a simple string, in which case the * correlation name is generated automatically. If you want to specify * the correlation name, the first parameter must be an associative * array in which the key is the correlation name, and the value is * the physical table name. For example, array('alias' => 'table'). * The correlation name is prepended to all columns fetched for this * table. * * The second parameter can be a single string or Zend_Db_Expr object, * or else an array of strings or Zend_Db_Expr objects. * * The first parameter can be null or an empty string, in which case * no correlation name is generated or prepended to the columns named * in the second parameter. * * @param array|string|Zend_Db_Expr $name The table name or an associative array * relating correlation name to table name. * @param array|string|Zend_Db_Expr $cols The columns to select from this table. * @param string $schema The schema name to specify, if any. * @return Zend_Db_Select This Zend_Db_Select object. */ public function from($name, $cols = '*', $schema = null) { return $this->_join(self::FROM, $name, null, $cols, $schema); } /** * Specifies the columns used in the FROM clause. * * The parameter can be a single string or Zend_Db_Expr object, * or else an array of strings or Zend_Db_Expr objects. * * @param array|string|Zend_Db_Expr $cols The columns to select from this table. * @param string $correlationName Correlation name of target table. OPTIONAL * @return Zend_Db_Select This Zend_Db_Select object. */ public function columns($cols = '*', $correlationName = null) { if ($correlationName === null && count($this->_parts[self::FROM])) { $correlationNameKeys = array_keys($this->_parts[self::FROM]); $correlationName = current($correlationNameKeys); } if (!array_key_exists($correlationName, $this->_parts[self::FROM])) { /** * @see Zend_Db_Select_Exception */ require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception("No table has been specified for the FROM clause"); } $this->_tableCols($correlationName, $cols); return $this; } /** * Adds a UNION clause to the query. * * The first parameter has to be an array of Zend_Db_Select or * sql query strings. * * <code> * $sql1 = $db->select(); * $sql2 = "SELECT ..."; * $select = $db->select() * ->union(array($sql1, $sql2)) * ->order("id"); * </code> * * @param array $select Array of select clauses for the union. * @return Zend_Db_Select This Zend_Db_Select object. */ public function union($select = array(), $type = self::SQL_UNION) { if (!is_array($select)) { require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception( "union() only accepts an array of Zend_Db_Select instances of sql query strings." ); } if (!in_array($type, self::$_unionTypes)) { require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception("Invalid union type '{$type}'"); } foreach ($select as $target) { $this->_parts[self::UNION][] = array($target, $type); } return $this; } /** * Adds a JOIN table and columns to the query. * * The $name and $cols parameters follow the same logic * as described in the from() method. * * @param array|string|Zend_Db_Expr $name The table name. * @param string $cond Join on this condition. * @param array|string $cols The columns to select from the joined table. * @param string $schema The database name to specify, if any. * @return Zend_Db_Select This Zend_Db_Select object. */ public function join($name, $cond, $cols = self::SQL_WILDCARD, $schema = null) { return $this->joinInner($name, $cond, $cols, $schema); } /** * Add an INNER JOIN table and colums to the query * Rows in both tables are matched according to the expression * in the $cond argument. The result set is comprised * of all cases where rows from the left table match * rows from the right table. * * The $name and $cols parameters follow the same logic * as described in the from() method. * * @param array|string|Zend_Db_Expr $name The table name. * @param string $cond Join on this condition. * @param array|string $cols The columns to select from the joined table. * @param string $schema The database name to specify, if any. * @return Zend_Db_Select This Zend_Db_Select object. */ public function joinInner($name, $cond, $cols = self::SQL_WILDCARD, $schema = null) { return $this->_join(self::INNER_JOIN, $name, $cond, $cols, $schema); } /** * Add a LEFT OUTER JOIN table and colums to the query * All rows from the left operand table are included, * matching rows from the right operand table included, * and the columns from the right operand table are filled * with NULLs if no row exists matching the left table. * * The $name and $cols parameters follow the same logic * as described in the from() method. * * @param array|string|Zend_Db_Expr $name The table name. * @param string $cond Join on this condition. * @param array|string $cols The columns to select from the joined table. * @param string $schema The database name to specify, if any. * @return Zend_Db_Select This Zend_Db_Select object. */ public function joinLeft($name, $cond, $cols = self::SQL_WILDCARD, $schema = null) { return $this->_join(self::LEFT_JOIN, $name, $cond, $cols, $schema); } /** * Add a RIGHT OUTER JOIN table and colums to the query. * Right outer join is the complement of left outer join. * All rows from the right operand table are included, * matching rows from the left operand table included, * and the columns from the left operand table are filled * with NULLs if no row exists matching the right table. * * The $name and $cols parameters follow the same logic * as described in the from() method. * * @param array|string|Zend_Db_Expr $name The table name. * @param string $cond Join on this condition. * @param array|string $cols The columns to select from the joined table. * @param string $schema The database name to specify, if any. * @return Zend_Db_Select This Zend_Db_Select object. */ public function joinRight($name, $cond, $cols = self::SQL_WILDCARD, $schema = null) { return $this->_join(self::RIGHT_JOIN, $name, $cond, $cols, $schema); } /** * Add a FULL OUTER JOIN table and colums to the query. * A full outer join is like combining a left outer join * and a right outer join. All rows from both tables are * included, paired with each other on the same row of the * result set if they satisfy the join condition, and otherwise * paired with NULLs in place of columns from the other table. * * The $name and $cols parameters follow the same logic * as described in the from() method. * * @param array|string|Zend_Db_Expr $name The table name. * @param string $cond Join on this condition. * @param array|string $cols The columns to select from the joined table. * @param string $schema The database name to specify, if any. * @return Zend_Db_Select This Zend_Db_Select object. */ public function joinFull($name, $cond, $cols = self::SQL_WILDCARD, $schema = null) { return $this->_join(self::FULL_JOIN, $name, $cond, $cols, $schema); } /** * Add a CROSS JOIN table and colums to the query. * A cross join is a cartesian product; there is no join condition. * * The $name and $cols parameters follow the same logic * as described in the from() method. * * @param array|string|Zend_Db_Expr $name The table name. * @param array|string $cols The columns to select from the joined table. * @param string $schema The database name to specify, if any. * @return Zend_Db_Select This Zend_Db_Select object. */ public function joinCross($name, $cols = self::SQL_WILDCARD, $schema = null) { return $this->_join(self::CROSS_JOIN, $name, null, $cols, $schema); } /** * Add a NATURAL JOIN table and colums to the query. * A natural join assumes an equi-join across any column(s) * that appear with the same name in both tables. * Only natural inner joins are supported by this API, * even though SQL permits natural outer joins as well. * * The $name and $cols parameters follow the same logic * as described in the from() method. * * @param array|string|Zend_Db_Expr $name The table name. * @param array|string $cols The columns to select from the joined table. * @param string $schema The database name to specify, if any. * @return Zend_Db_Select This Zend_Db_Select object. */ public function joinNatural($name, $cols = self::SQL_WILDCARD, $schema = null) { return $this->_join(self::NATURAL_JOIN, $name, null, $cols, $schema); } /** * Adds a WHERE condition to the query by AND. * * If a value is passed as the second param, it will be quoted * and replaced into the condition wherever a question-mark * appears. Array values are quoted and comma-separated. * * <code> * // simplest but non-secure * $select->where("id = $id"); * * // secure (ID is quoted but matched anyway) * $select->where('id = ?', $id); * * // alternatively, with named binding * $select->where('id = :id'); * </code> * * Note that it is more correct to use named bindings in your * queries for values other than strings. When you use named * bindings, don't forget to pass the values when actually * making a query: * * <code> * $db->fetchAll($select, array('id' => 5)); * </code> * * @param string $cond The WHERE condition. * @param mixed $value OPTIONAL The value to quote into the condition. * @param int $type OPTIONAL The type of the given value * @return Zend_Db_Select This Zend_Db_Select object. */ public function where($cond, $value = null, $type = null) { $this->_parts[self::WHERE][] = $this->_where($cond, $value, $type, true); return $this; } /** * Adds a WHERE condition to the query by OR. * * Otherwise identical to where(). * * @param string $cond The WHERE condition. * @param mixed $value OPTIONAL The value to quote into the condition. * @param int $type OPTIONAL The type of the given value * @return Zend_Db_Select This Zend_Db_Select object. * * @see where() */ public function orWhere($cond, $value = null, $type = null) { $this->_parts[self::WHERE][] = $this->_where($cond, $value, $type, false); return $this; } /** * Adds grouping to the query. * * @param array|string $spec The column(s) to group by. * @return Zend_Db_Select This Zend_Db_Select object. */ public function group($spec) { if (!is_array($spec)) { $spec = array($spec); } foreach ($spec as $val) { if (preg_match('/\(.*\)/', (string) $val)) { $val = new Zend_Db_Expr($val); } $this->_parts[self::GROUP][] = $val; } return $this; } /** * Adds a HAVING condition to the query by AND. * * If a value is passed as the second param, it will be quoted * and replaced into the condition wherever a question-mark * appears. See {@link where()} for an example * * @param string $cond The HAVING condition. * @param mixed $value OPTIONAL The value to quote into the condition. * @param int $type OPTIONAL The type of the given value * @return Zend_Db_Select This Zend_Db_Select object. */ public function having($cond, $value = null, $type = null) { if ($value !== null) { $cond = $this->_adapter->quoteInto($cond, $value, $type); } if ($this->_parts[self::HAVING]) { $this->_parts[self::HAVING][] = self::SQL_AND . " ($cond)"; } else { $this->_parts[self::HAVING][] = "($cond)"; } return $this; } /** * Adds a HAVING condition to the query by OR. * * Otherwise identical to orHaving(). * * @param string $cond The HAVING condition. * @param mixed $value OPTIONAL The value to quote into the condition. * @param int $type OPTIONAL The type of the given value * @return Zend_Db_Select This Zend_Db_Select object. * * @see having() */ public function orHaving($cond, $value = null, $type = null) { if ($value !== null) { $cond = $this->_adapter->quoteInto($cond, $value, $type); } if ($this->_parts[self::HAVING]) { $this->_parts[self::HAVING][] = self::SQL_OR . " ($cond)"; } else { $this->_parts[self::HAVING][] = "($cond)"; } return $this; } /** * Adds a row order to the query. * * @param mixed $spec The column(s) and direction to order by. * @return Zend_Db_Select This Zend_Db_Select object. */ public function order($spec) { if (!is_array($spec)) { $spec = array($spec); } // force 'ASC' or 'DESC' on each order spec, default is ASC. foreach ($spec as $val) { if ($val instanceof Zend_Db_Expr) { $expr = $val->__toString(); if (empty($expr)) { continue; } $this->_parts[self::ORDER][] = $val; } else { if (empty($val)) { continue; } $direction = self::SQL_ASC; if (preg_match('/(.*\W)(' . self::SQL_ASC . '|' . self::SQL_DESC . ')\b/si', $val, $matches)) { $val = trim($matches[1]); $direction = $matches[2]; } if (preg_match('/\(.*\)/', $val)) { $val = new Zend_Db_Expr($val); } $this->_parts[self::ORDER][] = array($val, $direction); } } return $this; } /** * Sets a limit count and offset to the query. * * @param int $count OPTIONAL The number of rows to return. * @param int $offset OPTIONAL Start returning after this many rows. * @return Zend_Db_Select This Zend_Db_Select object. */ public function limit($count = null, $offset = null) { $this->_parts[self::LIMIT_COUNT] = (int) $count; $this->_parts[self::LIMIT_OFFSET] = (int) $offset; return $this; } /** * Sets the limit and count by page number. * * @param int $page Limit results to this page number. * @param int $rowCount Use this many rows per page. * @return Zend_Db_Select This Zend_Db_Select object. */ public function limitPage($page, $rowCount) { $page = ($page > 0) ? $page : 1; $rowCount = ($rowCount > 0) ? $rowCount : 1; $this->_parts[self::LIMIT_COUNT] = (int) $rowCount; $this->_parts[self::LIMIT_OFFSET] = (int) $rowCount * ($page - 1); return $this; } /** * Makes the query SELECT FOR UPDATE. * * @param bool $flag Whether or not the SELECT is FOR UPDATE (default true). * @return Zend_Db_Select This Zend_Db_Select object. */ public function forUpdate($flag = true) { $this->_parts[self::FOR_UPDATE] = (bool) $flag; return $this; } /** * Get part of the structured information for the currect query. * * @param string $part * @return mixed * @throws Zend_Db_Select_Exception */ public function getPart($part) { $part = strtolower($part); if (!array_key_exists($part, $this->_parts)) { require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception("Invalid Select part '$part'"); } return $this->_parts[$part]; } /** * Executes the current select object and returns the result * * @param integer $fetchMode OPTIONAL * @param mixed $bind An array of data to bind to the placeholders. * @return PDO_Statement|Zend_Db_Statement */ public function query($fetchMode = null, $bind = array()) { if (!empty($bind)) { $this->bind($bind); } $stmt = $this->_adapter->query($this); if ($fetchMode == null) { $fetchMode = $this->_adapter->getFetchMode(); } $stmt->setFetchMode($fetchMode); return $stmt; } /** * Converts this object to an SQL SELECT string. * * @return string|null This object as a SELECT string. (or null if a string cannot be produced.) */ public function assemble() { $sql = self::SQL_SELECT; foreach (array_keys(self::$_partsInit) as $part) { $method = '_render' . ucfirst($part); if (method_exists($this, $method)) { $sql = $this->$method($sql); } } return $sql; } /** * Clear parts of the Select object, or an individual part. * * @param string $part OPTIONAL * @return Zend_Db_Select */ public function reset($part = null) { if ($part == null) { $this->_parts = self::$_partsInit; } else if (array_key_exists($part, self::$_partsInit)) { $this->_parts[$part] = self::$_partsInit[$part]; } return $this; } /** * Gets the Zend_Db_Adapter_Abstract for this * particular Zend_Db_Select object. * * @return Zend_Db_Adapter_Abstract */ public function getAdapter() { return $this->_adapter; } /** * Populate the {@link $_parts} 'join' key * * Does the dirty work of populating the join key. * * The $name and $cols parameters follow the same logic * as described in the from() method. * * @param null|string $type Type of join; inner, left, and null are currently supported * @param array|string|Zend_Db_Expr $name Table name * @param string $cond Join on this condition * @param array|string $cols The columns to select from the joined table * @param string $schema The database name to specify, if any. * @return Zend_Db_Select This Zend_Db_Select object * @throws Zend_Db_Select_Exception */ protected function _join($type, $name, $cond, $cols, $schema = null) { if (!in_array($type, self::$_joinTypes) && $type != self::FROM) { /** * @see Zend_Db_Select_Exception */ require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception("Invalid join type '$type'"); } if (count($this->_parts[self::UNION])) { require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception("Invalid use of table with " . self::SQL_UNION); } if (empty($name)) { $correlationName = $tableName = ''; } else if (is_array($name)) { // Must be array($correlationName => $tableName) or array($ident, ...) foreach ($name as $_correlationName => $_tableName) { if (is_string($_correlationName)) { // We assume the key is the correlation name and value is the table name $tableName = $_tableName; $correlationName = $_correlationName; } else { // We assume just an array of identifiers, with no correlation name $tableName = $_tableName; $correlationName = $this->_uniqueCorrelation($tableName); } break; } } else if ($name instanceof Zend_Db_Expr|| $name instanceof Zend_Db_Select) { $tableName = $name; $correlationName = $this->_uniqueCorrelation('t'); } else if (preg_match('/^(.+)\s+AS\s+(.+)$/i', $name, $m)) { $tableName = $m[1]; $correlationName = $m[2]; } else { $tableName = $name; $correlationName = $this->_uniqueCorrelation($tableName); } // Schema from table name overrides schema argument if (!is_object($tableName) && false !== strpos($tableName, '.')) { list($schema, $tableName) = explode('.', $tableName); } $lastFromCorrelationName = null; if (!empty($correlationName)) { if (array_key_exists($correlationName, $this->_parts[self::FROM])) { /** * @see Zend_Db_Select_Exception */ require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception("You cannot define a correlation name '$correlationName' more than once"); } if ($type == self::FROM) { // append this from after the last from joinType $tmpFromParts = $this->_parts[self::FROM]; $this->_parts[self::FROM] = array(); // move all the froms onto the stack while ($tmpFromParts) { $currentCorrelationName = key($tmpFromParts); if ($tmpFromParts[$currentCorrelationName]['joinType'] != self::FROM) { break; } $lastFromCorrelationName = $currentCorrelationName; $this->_parts[self::FROM][$currentCorrelationName] = array_shift($tmpFromParts); } } else { $tmpFromParts = array(); } $this->_parts[self::FROM][$correlationName] = array( 'joinType' => $type, 'schema' => $schema, 'tableName' => $tableName, 'joinCondition' => $cond ); while ($tmpFromParts) { $currentCorrelationName = key($tmpFromParts); $this->_parts[self::FROM][$currentCorrelationName] = array_shift($tmpFromParts); } } // add to the columns from this joined table if ($type == self::FROM && $lastFromCorrelationName == null) { $lastFromCorrelationName = true; } $this->_tableCols($correlationName, $cols, $lastFromCorrelationName); return $this; } /** * Handle JOIN... USING... syntax * * This is functionality identical to the existing JOIN methods, however * the join condition can be passed as a single column name. This method * then completes the ON condition by using the same field for the FROM * table and the JOIN table. * * <code> * $select = $db->select()->from('table1') * ->joinUsing('table2', 'column1'); * * // SELECT * FROM table1 JOIN table2 ON table1.column1 = table2.column2 * </code> * * These joins are called by the developer simply by adding 'Using' to the * method name. E.g. * * joinUsing * * joinInnerUsing * * joinFullUsing * * joinRightUsing * * joinLeftUsing * * @return Zend_Db_Select This Zend_Db_Select object. */ public function _joinUsing($type, $name, $cond, $cols = '*', $schema = null) { if (empty($this->_parts[self::FROM])) { require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception("You can only perform a joinUsing after specifying a FROM table"); } $join = $this->_adapter->quoteIdentifier(key($this->_parts[self::FROM]), true); $from = $this->_adapter->quoteIdentifier($this->_uniqueCorrelation($name), true); $cond1 = $from . '.' . $cond; $cond2 = $join . '.' . $cond; $cond = $cond1 . ' = ' . $cond2; return $this->_join($type, $name, $cond, $cols, $schema); } /** * Generate a unique correlation name * * @param string|array $name A qualified identifier. * @return string A unique correlation name. */ private function _uniqueCorrelation($name) { if (is_array($name)) { $c = end($name); } else { // Extract just the last name of a qualified table name $dot = strrpos($name,'.'); $c = ($dot === false) ? $name : substr($name, $dot+1); } for ($i = 2; array_key_exists($c, $this->_parts[self::FROM]); ++$i) { $c = $name . '_' . (string) $i; } return $c; } /** * Adds to the internal table-to-column mapping array. * * @param string $tbl The table/join the columns come from. * @param array|string $cols The list of columns; preferably as * an array, but possibly as a string containing one column. * @param bool|string True if it should be prepended, a correlation name if it should be inserted * @return void */ protected function _tableCols($correlationName, $cols, $afterCorrelationName = null) { if (!is_array($cols)) { $cols = array($cols); } if ($correlationName == null) { $correlationName = ''; } $columnValues = array(); foreach (array_filter($cols) as $alias => $col) { $currentCorrelationName = $correlationName; if (is_string($col)) { // Check for a column matching "<column> AS <alias>" and extract the alias name if (preg_match('/^(.+)\s+' . self::SQL_AS . '\s+(.+)$/i', $col, $m)) { $col = $m[1]; $alias = $m[2]; } // Check for columns that look like functions and convert to Zend_Db_Expr if (preg_match('/\(.*\)/', $col)) { $col = new Zend_Db_Expr($col); } elseif (preg_match('/(.+)\.(.+)/', $col, $m)) { $currentCorrelationName = $m[1]; $col = $m[2]; } } $columnValues[] = array($currentCorrelationName, $col, is_string($alias) ? $alias : null); } if ($columnValues) { // should we attempt to prepend or insert these values? if ($afterCorrelationName === true || is_string($afterCorrelationName)) { $tmpColumns = $this->_parts[self::COLUMNS]; $this->_parts[self::COLUMNS] = array(); } else { $tmpColumns = array(); } // find the correlation name to insert after if (is_string($afterCorrelationName)) { while ($tmpColumns) { $this->_parts[self::COLUMNS][] = $currentColumn = array_shift($tmpColumns); if ($currentColumn[0] == $afterCorrelationName) { break; } } } // apply current values to current stack foreach ($columnValues as $columnValue) { array_push($this->_parts[self::COLUMNS], $columnValue); } // finish ensuring that all previous values are applied (if they exist) while ($tmpColumns) { array_push($this->_parts[self::COLUMNS], array_shift($tmpColumns)); } } } /** * Internal function for creating the where clause * * @param string $condition * @param mixed $value optional * @param string $type optional * @param boolean $bool true = AND, false = OR * @return string clause */ protected function _where($condition, $value = null, $type = null, $bool = true) { if (count($this->_parts[self::UNION])) { require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception("Invalid use of where clause with " . self::SQL_UNION); } if ($value !== null) { $condition = $this->_adapter->quoteInto($condition, $value, $type); } $cond = ""; if ($this->_parts[self::WHERE]) { if ($bool === true) { $cond = self::SQL_AND . ' '; } else { $cond = self::SQL_OR . ' '; } } return $cond . "($condition)"; } /** * @return array */ protected function _getDummyTable() { return array(); } /** * Return a quoted schema name * * @param string $schema The schema name OPTIONAL * @return string|null */ protected function _getQuotedSchema($schema = null) { if ($schema === null) { return null; } return $this->_adapter->quoteIdentifier($schema, true) . '.'; } /** * Return a quoted table name * * @param string $tableName The table name * @param string $correlationName The correlation name OPTIONAL * @return string */ protected function _getQuotedTable($tableName, $correlationName = null) { return $this->_adapter->quoteTableAs($tableName, $correlationName, true); } /** * Render DISTINCT clause * * @param string $sql SQL query * @return string */ protected function _renderDistinct($sql) { if ($this->_parts[self::DISTINCT]) { $sql .= ' ' . self::SQL_DISTINCT; } return $sql; } /** * Render DISTINCT clause * * @param string $sql SQL query * @return string|null */ protected function _renderColumns($sql) { if (!count($this->_parts[self::COLUMNS])) { return null; } $columns = array(); foreach ($this->_parts[self::COLUMNS] as $columnEntry) { list($correlationName, $column, $alias) = $columnEntry; if ($column instanceof Zend_Db_Expr) { $columns[] = $this->_adapter->quoteColumnAs($column, $alias, true); } else { if ($column == self::SQL_WILDCARD) { $column = new Zend_Db_Expr(self::SQL_WILDCARD); $alias = null; } if (empty($correlationName)) { $columns[] = $this->_adapter->quoteColumnAs($column, $alias, true); } else { $columns[] = $this->_adapter->quoteColumnAs(array($correlationName, $column), $alias, true); } } } return $sql .= ' ' . implode(', ', $columns); } /** * Render FROM clause * * @param string $sql SQL query * @return string */ protected function _renderFrom($sql) { /* * If no table specified, use RDBMS-dependent solution * for table-less query. e.g. DUAL in Oracle. */ if (empty($this->_parts[self::FROM])) { $this->_parts[self::FROM] = $this->_getDummyTable(); } $from = array(); foreach ($this->_parts[self::FROM] as $correlationName => $table) { $tmp = ''; $joinType = ($table['joinType'] == self::FROM) ? self::INNER_JOIN : $table['joinType']; // Add join clause (if applicable) if (! empty($from)) { $tmp .= ' ' . strtoupper($joinType) . ' '; } $tmp .= $this->_getQuotedSchema($table['schema']); $tmp .= $this->_getQuotedTable($table['tableName'], $correlationName); // Add join conditions (if applicable) if (!empty($from) && ! empty($table['joinCondition'])) { $tmp .= ' ' . self::SQL_ON . ' ' . $table['joinCondition']; } // Add the table name and condition add to the list $from[] = $tmp; } // Add the list of all joins if (!empty($from)) { $sql .= ' ' . self::SQL_FROM . ' ' . implode("\n", $from); } return $sql; } /** * Render UNION query * * @param string $sql SQL query * @return string */ protected function _renderUnion($sql) { if ($this->_parts[self::UNION]) { $parts = count($this->_parts[self::UNION]); foreach ($this->_parts[self::UNION] as $cnt => $union) { list($target, $type) = $union; if ($target instanceof Zend_Db_Select) { $target = $target->assemble(); } $sql .= $target; if ($cnt < $parts - 1) { $sql .= ' ' . $type . ' '; } } } return $sql; } /** * Render WHERE clause * * @param string $sql SQL query * @return string */ protected function _renderWhere($sql) { if ($this->_parts[self::FROM] && $this->_parts[self::WHERE]) { $sql .= ' ' . self::SQL_WHERE . ' ' . implode(' ', $this->_parts[self::WHERE]); } return $sql; } /** * Render GROUP clause * * @param string $sql SQL query * @return string */ protected function _renderGroup($sql) { if ($this->_parts[self::FROM] && $this->_parts[self::GROUP]) { $group = array(); foreach ($this->_parts[self::GROUP] as $term) { $group[] = $this->_adapter->quoteIdentifier($term, true); } $sql .= ' ' . self::SQL_GROUP_BY . ' ' . implode(",\n\t", $group); } return $sql; } /** * Render HAVING clause * * @param string $sql SQL query * @return string */ protected function _renderHaving($sql) { if ($this->_parts[self::FROM] && $this->_parts[self::HAVING]) { $sql .= ' ' . self::SQL_HAVING . ' ' . implode(' ', $this->_parts[self::HAVING]); } return $sql; } /** * Render ORDER clause * * @param string $sql SQL query * @return string */ protected function _renderOrder($sql) { if ($this->_parts[self::ORDER]) { $order = array(); foreach ($this->_parts[self::ORDER] as $term) { if (is_array($term)) { if(is_numeric($term[0]) && strval(intval($term[0])) == $term[0]) { $order[] = (int)trim($term[0]) . ' ' . $term[1]; } else { $order[] = $this->_adapter->quoteIdentifier($term[0], true) . ' ' . $term[1]; } } else if (is_numeric($term) && strval(intval($term)) == $term) { $order[] = (int)trim($term); } else { $order[] = $this->_adapter->quoteIdentifier($term, true); } } $sql .= ' ' . self::SQL_ORDER_BY . ' ' . implode(', ', $order); } return $sql; } /** * Render LIMIT OFFSET clause * * @param string $sql SQL query * @return string */ protected function _renderLimitoffset($sql) { $count = 0; $offset = 0; if (!empty($this->_parts[self::LIMIT_OFFSET])) { $offset = (int) $this->_parts[self::LIMIT_OFFSET]; $count = PHP_INT_MAX; } if (!empty($this->_parts[self::LIMIT_COUNT])) { $count = (int) $this->_parts[self::LIMIT_COUNT]; } /* * Add limits clause */ if ($count > 0) { $sql = trim($this->_adapter->limit($sql, $count, $offset)); } return $sql; } /** * Render FOR UPDATE clause * * @param string $sql SQL query * @return string */ protected function _renderForupdate($sql) { if ($this->_parts[self::FOR_UPDATE]) { $sql .= ' ' . self::SQL_FOR_UPDATE; } return $sql; } /** * Turn magic function calls into non-magic function calls * for joinUsing syntax * * @param string $method * @param array $args OPTIONAL Zend_Db_Table_Select query modifier * @return Zend_Db_Select * @throws Zend_Db_Select_Exception If an invalid method is called. */ public function __call($method, array $args) { $matches = array(); /** * Recognize methods for Has-Many cases: * findParent<Class>() * findParent<Class>By<Rule>() * Use the non-greedy pattern repeat modifier e.g. \w+? */ if (preg_match('/^join([a-zA-Z]*?)Using$/', $method, $matches)) { $type = strtolower($matches[1]); if ($type) { $type .= ' join'; if (!in_array($type, self::$_joinTypes)) { require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception("Unrecognized method '$method()'"); } if (in_array($type, array(self::CROSS_JOIN, self::NATURAL_JOIN))) { require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception("Cannot perform a joinUsing with method '$method()'"); } } else { $type = self::INNER_JOIN; } array_unshift($args, $type); return call_user_func_array(array($this, '_joinUsing'), $args); } require_once 'Zend/Db/Select/Exception.php'; throw new Zend_Db_Select_Exception("Unrecognized method '$method()'"); } /** * Implements magic method. * * @return string This object as a SELECT string. */ public function __toString() { try { $sql = $this->assemble(); } catch (Exception $e) { trigger_error($e->getMessage(), E_USER_WARNING); $sql = ''; } return (string)$sql; } }
{ "content_hash": "6e20b64567d2fd8929be5fc742e9be93", "timestamp": "", "source": "github", "line_count": 1332, "max_line_length": 125, "avg_line_length": 32.75, "alnum_prop": 0.5316461499667606, "repo_name": "codeactual/hashmark", "id": "7cdbb9c6a6c465f52b6130cb6725acf0671b96f9", "size": "44387", "binary": false, "copies": "5", "ref": "refs/heads/master", "path": "Zend/Db/Select.php", "mode": "33188", "license": "mit", "language": [ { "name": "PHP", "bytes": "1356959" }, { "name": "Shell", "bytes": "1106" } ], "symlink_target": "" }
package com.wavefront.api.agent; import com.google.common.base.Preconditions; import com.fasterxml.jackson.annotation.JsonIgnoreProperties; import java.util.UUID; /** * Represents an SSH target to connect to. * * @author Clement Pang (clement@sunnylabs.com) */ @JsonIgnoreProperties(ignoreUnknown = true) public class SshTargetDTO { public UUID id; public String host; public int port = 22; public String hostKey; public String user; public String publicKey; public void validate(AgentConfiguration config) { Preconditions.checkNotNull(id, "id cannot be null for host"); Preconditions.checkNotNull(host, "host cannot be null"); Preconditions.checkState(port > 0, "port must be greater than 0"); Preconditions.checkNotNull(publicKey, "publicKey cannot be null"); if (user == null) user = config.defaultUsername; if (publicKey == null) publicKey = config.defaultPublicKey; } @Override public boolean equals(Object o) { if (this == o) return true; if (o == null || getClass() != o.getClass()) return false; SshTargetDTO sshTargetDTO = (SshTargetDTO) o; if (port != sshTargetDTO.port) return false; if (host != null ? !host.equals(sshTargetDTO.host) : sshTargetDTO.host != null) return false; if (hostKey != null ? !hostKey.equals(sshTargetDTO.hostKey) : sshTargetDTO.hostKey != null) return false; if (!id.equals(sshTargetDTO.id)) return false; if (publicKey != null ? !publicKey.equals(sshTargetDTO.publicKey) : sshTargetDTO.publicKey != null) return false; if (user != null ? !user.equals(sshTargetDTO.user) : sshTargetDTO.user != null) return false; return true; } @Override public int hashCode() { int result = id.hashCode(); result = 31 * result + (host != null ? host.hashCode() : 0); result = 31 * result + port; result = 31 * result + (hostKey != null ? hostKey.hashCode() : 0); result = 31 * result + (user != null ? user.hashCode() : 0); result = 31 * result + (publicKey != null ? publicKey.hashCode() : 0); return result; } }
{ "content_hash": "41104f9fc4a1d23d5f6954b0699b0d5a", "timestamp": "", "source": "github", "line_count": 61, "max_line_length": 103, "avg_line_length": 34.114754098360656, "alnum_prop": 0.6809226333493513, "repo_name": "moribellamy/java", "id": "ad3d43096259b3ce75e036f32b7eb4a82ad2b477", "size": "2081", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "java-lib/src/main/java/com/wavefront/api/agent/SshTargetDTO.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "ANTLR", "bytes": "1392" }, { "name": "Java", "bytes": "334918" }, { "name": "Python", "bytes": "37122" }, { "name": "Shell", "bytes": "9203" } ], "symlink_target": "" }
package org.batfish.datamodel; import static com.google.common.base.Preconditions.checkArgument; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonProperty; import com.github.benmanes.caffeine.cache.Caffeine; import com.github.benmanes.caffeine.cache.LoadingCache; import com.google.common.base.MoreObjects; import java.io.ObjectStreamException; import javax.annotation.Nonnull; import javax.annotation.Nullable; import javax.annotation.ParametersAreNonnullByDefault; import org.batfish.datamodel.visitors.ReceivedFromVisitor; /** * Information indicating that a {@link BgpRoute} was received from a BGP unnumbered session on a * given interface. */ @ParametersAreNonnullByDefault public final class ReceivedFromInterface implements ReceivedFrom { @Override public <T> T accept(ReceivedFromVisitor<T> visitor) { return visitor.visitReceivedFromInterface(this); } public static @Nonnull ReceivedFromInterface of(String iface, Ip linkLocalIp) { checkArgument(LINK_LOCAL_IPS.containsIp(linkLocalIp), "%s is not a link-local IP", linkLocalIp); ReceivedFromInterface ret = CACHE.get(new ReceivedFromInterface(iface, linkLocalIp)); assert ret != null; return ret; } @JsonProperty(PROP_INTERFACE) public @Nonnull String getInterface() { return _interface; } @JsonProperty(PROP_LINK_LOCAL_IP) public @Nonnull Ip getLinkLocalIp() { return _linkLocalIp; } @Override public boolean equals(@Nullable Object obj) { if (this == obj) { return true; } else if (!(obj instanceof ReceivedFromInterface)) { return false; } ReceivedFromInterface other = (ReceivedFromInterface) obj; return _interface.equals(other._interface) && _linkLocalIp.equals(other._linkLocalIp); } @Override public int hashCode() { return _interface.hashCode() * 31 + _linkLocalIp.hashCode(); } @Override public String toString() { return MoreObjects.toStringHelper(this) .add(PROP_INTERFACE, _interface) .add(PROP_LINK_LOCAL_IP, _linkLocalIp) .toString(); } @JsonCreator private static @Nonnull ReceivedFromInterface create( @JsonProperty(PROP_INTERFACE) @Nullable String iface, @JsonProperty(PROP_LINK_LOCAL_IP) @Nullable Ip linkLocalIp) { checkArgument(iface != null, "Missing %s", PROP_INTERFACE); checkArgument(linkLocalIp != null, "Missing %s", PROP_LINK_LOCAL_IP); return of(iface, linkLocalIp); } private ReceivedFromInterface(String iface, Ip linkLocalIp) { _interface = iface; _linkLocalIp = linkLocalIp; } private static final Prefix LINK_LOCAL_IPS = Prefix.strict("169.254.0.0/16"); private static final String PROP_INTERFACE = "interface"; private static final String PROP_LINK_LOCAL_IP = "linkLocalIp"; // Soft values: let it be garbage collected in times of pressure. // Maximum size 2^20: Just some upper bound on cache size, well less than GiB. // (16 bytes for int+ip (excluding interned string space), would be 16 MiB total). private static final LoadingCache<ReceivedFromInterface, ReceivedFromInterface> CACHE = Caffeine.newBuilder().softValues().maximumSize(1 << 20).build(r -> r); private final @Nonnull String _interface; private final @Nonnull Ip _linkLocalIp; /** Cache after deserialization. */ private Object readResolve() throws ObjectStreamException { return CACHE.get(this); } }
{ "content_hash": "46933add4267912f0ae6560a32188182", "timestamp": "", "source": "github", "line_count": 101, "max_line_length": 100, "avg_line_length": 34.06930693069307, "alnum_prop": 0.7369950595757048, "repo_name": "arifogel/batfish", "id": "0d91ce3638ae6f85685c41992b30e6d793f59d53", "size": "3441", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "projects/batfish-common-protocol/src/main/java/org/batfish/datamodel/ReceivedFromInterface.java", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "ANTLR", "bytes": "1999103" }, { "name": "HCL", "bytes": "49266" }, { "name": "Java", "bytes": "25862751" }, { "name": "Python", "bytes": "11181" }, { "name": "Shell", "bytes": "6502" }, { "name": "Starlark", "bytes": "214539" } ], "symlink_target": "" }
/** * Created at 3:26:14 AM Jan 11, 2011 */ using System; using System.Collections.Generic; using System.Diagnostics; using SharpBox2D.Collision; using SharpBox2D.Common; using SharpBox2D.Dynamics.Contacts; namespace SharpBox2D.Pooling.Normal { /** * Provides object pooling for all objects used in the engine. Objects retrieved from here should * only be used temporarily, and then pushed back (with the exception of arrays). * * @author Daniel Murphy */ internal class ContactStack<CType> : MutableStack<Contact> where CType : Contact { private IWorldPool pool; public ContactStack(IWorldPool pool, Func<IWorldPool, CType> factoryM, int argInitSize) : base(argInitSize, () => factoryM(pool)) { this.pool = pool; } protected override Contact newInstance() { return FactoryMethod(); } protected override Contact[] newArray(int size) { return new Contact[size]; } } internal class Vec2Stack : OrderedStack<Vec2> { public Vec2Stack(int argStackSize, int argContainerSize) : base(argStackSize, argContainerSize) { } protected override Vec2 newInstance() { return new Vec2(); } } internal class Vec3Stack : OrderedStack<Vec3> { public Vec3Stack(int argStackSize, int argContainerSize) : base(argStackSize, argContainerSize) { } protected override Vec3 newInstance() { return new Vec3(); } } internal class Ma22Stack : OrderedStack<Mat22> { public Ma22Stack(int argStackSize, int argContainerSize) : base(argStackSize, argContainerSize) { } protected override Mat22 newInstance() { return new Mat22(); } } internal class AABBStack : OrderedStack<AABB> { public AABBStack(int argStackSize, int argContainerSize) : base(argStackSize, argContainerSize) { } protected override AABB newInstance() { return new AABB(); } } internal class RotStack : OrderedStack<Rot> { public RotStack(int argStackSize, int argContainerSize) : base(argStackSize, argContainerSize) { } protected override Rot newInstance() { return new Rot(); } } internal class Ma33Stack : OrderedStack<Mat33> { public Ma33Stack(int argStackSize, int argContainerSize) : base(argStackSize, argContainerSize) { } protected override Mat33 newInstance() { return new Mat33(); } } public class DefaultWorldPool : IWorldPool { private OrderedStack<Vec2> vecs; private OrderedStack<Vec3> vec3s; private OrderedStack<Mat22> mats; private OrderedStack<Mat33> mat33s; private OrderedStack<AABB> aabbs; private OrderedStack<Rot> rots; private Dictionary<int, float[]> afloats = new Dictionary<int, float[]>(); private Dictionary<int, int[]> aints = new Dictionary<int, int[]>(); private Dictionary<int, Vec2[]> avecs = new Dictionary<int, Vec2[]>(); private IWorldPool world; public DefaultWorldPool() { } private ContactStack<PolygonContact> pcstack; private ContactStack<CircleContact> ccstack; private ContactStack<PolygonAndCircleContact> cpstack; private ContactStack<EdgeAndCircleContact> ecstack; private ContactStack<EdgeAndPolygonContact> epstack; private ContactStack<ChainAndCircleContact> chcstack; private ContactStack<ChainAndPolygonContact> chpstack; private Collision.Collision collision; private TimeOfImpact toi; private Distance dist; public DefaultWorldPool(int argSize, int argContainerSize) { world = this; pcstack = new ContactStack<PolygonContact>(world, pool => new PolygonContact(pool), Settings.CONTACT_STACK_INIT_SIZE); ccstack = new ContactStack<CircleContact>(world, pool => new CircleContact(pool), Settings.CONTACT_STACK_INIT_SIZE); cpstack = new ContactStack<PolygonAndCircleContact>(world, pool => new PolygonAndCircleContact(pool), Settings.CONTACT_STACK_INIT_SIZE); ecstack = new ContactStack<EdgeAndCircleContact>(world, pool => new EdgeAndCircleContact(pool), Settings.CONTACT_STACK_INIT_SIZE); epstack = new ContactStack<EdgeAndPolygonContact>(world, pool => new EdgeAndPolygonContact(pool), Settings.CONTACT_STACK_INIT_SIZE); chcstack = new ContactStack<ChainAndCircleContact>(world, pool => new ChainAndCircleContact(pool), Settings.CONTACT_STACK_INIT_SIZE); chpstack = new ContactStack<ChainAndPolygonContact>(world, pool => new ChainAndPolygonContact(pool), Settings.CONTACT_STACK_INIT_SIZE); vecs = new Vec2Stack(argSize, argContainerSize); vec3s = new Vec3Stack(argSize, argContainerSize); mats = new Ma22Stack(argSize, argContainerSize); aabbs = new AABBStack(argSize, argContainerSize); rots = new RotStack(argSize, argContainerSize); mat33s = new Ma33Stack(argSize, argContainerSize); dist = new Distance(); collision = new Collision.Collision(this); toi = new TimeOfImpact(this); } public IDynamicStack<Contact> getPolyContactStack() { return pcstack; } public IDynamicStack<Contact> getCircleContactStack() { return ccstack; } public IDynamicStack<Contact> getPolyCircleContactStack() { return cpstack; } public IDynamicStack<Contact> getEdgeCircleContactStack() { return ecstack; } public IDynamicStack<Contact> getEdgePolyContactStack() { return epstack; } public IDynamicStack<Contact> getChainCircleContactStack() { return chcstack; } public IDynamicStack<Contact> getChainPolyContactStack() { return chpstack; } public Vec2 popVec2() { return vecs.pop(); } public Vec2[] popVec2(int argNum) { return vecs.pop(argNum); } public void pushVec2(int argNum) { vecs.push(argNum); } public Vec3 popVec3() { return vec3s.pop(); } public Vec3[] popVec3(int argNum) { return vec3s.pop(argNum); } public void pushVec3(int argNum) { vec3s.push(argNum); } public Mat22 popMat22() { return mats.pop(); } public Mat22[] popMat22(int argNum) { return mats.pop(argNum); } public void pushMat22(int argNum) { mats.push(argNum); } public Mat33 popMat33() { return mat33s.pop(); } public void pushMat33(int argNum) { mat33s.push(argNum); } public AABB popAABB() { return aabbs.pop(); } public AABB[] popAABB(int argNum) { return aabbs.pop(argNum); } public void pushAABB(int argNum) { aabbs.push(argNum); } public Rot popRot() { return rots.pop(); } public void pushRot(int num) { rots.push(num); } public Collision.Collision getCollision() { return collision; } public TimeOfImpact getTimeOfImpact() { return toi; } public Distance getDistance() { return dist; } public float[] getFloatArray(int argLength) { if (!afloats.ContainsKey(argLength)) { afloats.Add(argLength, new float[argLength]); } Debug.Assert(afloats[argLength].Length == argLength, "Array not built with correct length"); return afloats[argLength]; } public int[] getIntArray(int argLength) { if (!aints.ContainsKey(argLength)) { aints.Add(argLength, new int[argLength]); } Debug.Assert(aints[argLength].Length == argLength, "Array not built with correct length"); return aints[argLength]; } public Vec2[] getVec2Array(int argLength) { if (!avecs.ContainsKey(argLength)) { Vec2[] ray = new Vec2[argLength]; for (int i = 0; i < argLength; i++) { ray[i] = new Vec2(); } avecs.Add(argLength, ray); } Debug.Assert(avecs[argLength].Length == argLength, "Array not built with correct length"); return avecs[argLength]; } } }
{ "content_hash": "5c5d3d7fbd2308a01c9128238ec11c48", "timestamp": "", "source": "github", "line_count": 349, "max_line_length": 137, "avg_line_length": 26.988538681948423, "alnum_prop": 0.5650281346215097, "repo_name": "gordonmcshane/sharpbox2d", "id": "ca88be4c54b0aa7846f6ddcd374a7c64d63c34ff", "size": "10942", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "SharpBox2D/Pooling/Normal/DefaultWorldPool.cs", "mode": "33188", "license": "bsd-2-clause", "language": [ { "name": "C#", "bytes": "1642166" } ], "symlink_target": "" }
from mock import Mock, patch from pylons import tmpl_context as c from allura.tests.unit.factories import create_project, create_app_config def fake_app_patch(test_case): project = create_project('myproject') app_config = create_app_config(project, 'my_app') app = Mock() app.__version__ = '0' app.config = app_config app.url = '/-app-/' return patch.object(c, 'app', app, create=True) def project_app_loading_patch(test_case): test_case.fake_app = Mock() test_case.project_app_instance_function = Mock() test_case.project_app_instance_function.return_value = test_case.fake_app return patch('allura.model.project.Project.app_instance', test_case.project_app_instance_function) def disable_notifications_patch(test_case): return patch('allura.model.notification.Notification.post') def fake_redirect_patch(test_case): return patch('allura.controllers.discuss.redirect') def fake_request_patch(test_case): return patch('allura.controllers.discuss.request')
{ "content_hash": "c338d650c39049707233dbd2af882d5d", "timestamp": "", "source": "github", "line_count": 35, "max_line_length": 77, "avg_line_length": 29.742857142857144, "alnum_prop": 0.7098943323727186, "repo_name": "apache/incubator-allura", "id": "41cb4035cadaf0babc3e4eec126b83200c181416", "size": "1911", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "Allura/allura/tests/unit/patches.py", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "CSS", "bytes": "155606" }, { "name": "JavaScript", "bytes": "697175" }, { "name": "Puppet", "bytes": "6882" }, { "name": "Python", "bytes": "3667166" }, { "name": "Ruby", "bytes": "5739" }, { "name": "Shell", "bytes": "31675" }, { "name": "XSLT", "bytes": "3357" } ], "symlink_target": "" }
namespace supjson { class parse_error : public std::runtime_error { std::string what_; public: explicit parse_error(size_t line, size_t column, const std::string& what_arg); virtual const char* what() const throw(); }; class missing_key : public std::runtime_error { std::string key_; public: missing_key(std::string const& key); std::string const& which_key() const; }; class bad_cast : public std::bad_cast { std::string json_; public: bad_cast(std::string const& js); virtual const char* what() const throw(); }; class bad_visit : public std::runtime_error { public: bad_visit(size_t tag); }; class end_of_file : public std::runtime_error { public: end_of_file(); }; } #endif
{ "content_hash": "ba6527344599598e8c4143b9fa228101", "timestamp": "", "source": "github", "line_count": 39, "max_line_length": 82, "avg_line_length": 18.76923076923077, "alnum_prop": 0.6543715846994536, "repo_name": "lisqlql/supjson", "id": "6e677239106263b5d4fa83da389e13b30ddac7bf", "size": "850", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "src/exceptions.hpp", "mode": "33188", "license": "mit", "language": [ { "name": "C++", "bytes": "28212" }, { "name": "Makefile", "bytes": "1742" } ], "symlink_target": "" }
<?php /** * Created by PhpStorm. * User: ntezi * Date: 13/03/2016 * Time: 09:18 */ namespace backend\models; use common\models\AuthAssignment; use Yii; use common\models\User as BaseUser; class User extends BaseUser { public static function findIdentity($id) { return static::findOne(['id' => $id]); } public function isSuperAdmin() { $role = AuthAssignment::findOne(['item_name' => ['SuperAdmin','Admin'], 'user_id' => $this->id]); if(!empty($role)){ return true; } else{ return false; } } }
{ "content_hash": "8ef87e08a21e56428bd8929630adde3e", "timestamp": "", "source": "github", "line_count": 37, "max_line_length": 105, "avg_line_length": 16.27027027027027, "alnum_prop": 0.5614617940199336, "repo_name": "yatye/yatye", "id": "0b51da370993962df86d8b5ae1f34901f4dbd62f", "size": "602", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "backend/models/User.php", "mode": "33261", "license": "bsd-3-clause", "language": [ { "name": "Batchfile", "bytes": "1546" }, { "name": "CSS", "bytes": "479619" }, { "name": "HTML", "bytes": "28128" }, { "name": "JavaScript", "bytes": "144408" }, { "name": "PHP", "bytes": "2045834" }, { "name": "Shell", "bytes": "3105" } ], "symlink_target": "" }
angular .module('app') .config(function($routeProvider) { $routeProvider .when('/users', { template: '<user-list users="$ctrl.users" on-delete="$ctrl.delete"></user-list>', controller: 'listController', controllerAs: '$ctrl' }) .when('/users/:id', { template: '<user-form user="$ctrl.user" on-update="$ctrl.update" back-to="/users"></user-form>', controller: 'formController', controllerAs: '$ctrl' }) .when('/users-create', { template: '<user-form user="$ctrl.user" on-update="$ctrl.create" back-to="/users"></user-form>', controller: 'formController', controllerAs: '$ctrl' }) .otherwise({ redirectTo: '/users' }) ; });
{ "content_hash": "8f55561a42d8976f96488ae272d34b8f", "timestamp": "", "source": "github", "line_count": 23, "max_line_length": 104, "avg_line_length": 33.73913043478261, "alnum_prop": 0.5425257731958762, "repo_name": "DScheglov/user-list-frontend", "id": "674e6bed00b740e49fc2b4789d086887000b0689", "size": "787", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/routes.js", "mode": "33261", "license": "mit", "language": [ { "name": "CSS", "bytes": "342" }, { "name": "HTML", "bytes": "2838" }, { "name": "JavaScript", "bytes": "8810" }, { "name": "Makefile", "bytes": "270" } ], "symlink_target": "" }
<?php namespace test\e\g; class g { }
{ "content_hash": "55b2fb2f67bb50b9af8cf6e812f4e4db", "timestamp": "", "source": "github", "line_count": 3, "max_line_length": 19, "avg_line_length": 12.333333333333334, "alnum_prop": 0.6486486486486487, "repo_name": "darrelljefferson/themcset.com", "id": "8c31c22c8b00bffd9a38d5b96324d93dfaccc2d1", "size": "37", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "bin/test/e/g/g.php", "mode": "33188", "license": "mit", "language": [ { "name": "ApacheConf", "bytes": "1099" }, { "name": "Batchfile", "bytes": "21" }, { "name": "CSS", "bytes": "889639" }, { "name": "HTML", "bytes": "17830980" }, { "name": "Java", "bytes": "58853" }, { "name": "JavaScript", "bytes": "2251931" }, { "name": "PHP", "bytes": "13665910" }, { "name": "Shell", "bytes": "7918" }, { "name": "Smarty", "bytes": "2149" } ], "symlink_target": "" }
<!DOCTYPE html> <html> <head> <title>Y Axis</title> <script src="https://d3js.org/d3.v4.min.js"></script> </head> <body> <svg width="960" height="500"></svg> <script> const xValue = d => d.sepalLength; const yValue = d => d.petalLength; const margin = {top: 50, right: 30, bottom: 50, left: 30}; const svg = d3.select("svg"); const width = +svg.attr("width"); const height = +svg.attr("height"); const innerWidth = width - margin.left - margin.right; const innerHeight = height - margin.top - margin.bottom; const xScale = d3.scaleLinear().range([0, innerWidth]); const yScale = d3.scaleLinear().range([innerHeight, 0]); const yAxis = d3.axisLeft().scale(yScale); const g = svg.append("g") .attr("transform", `translate(${margin.left}, ${margin.top})`); const yAxisG = g.append("g"); function render(data){ xScale.domain(d3.extent(data, xValue)); yScale.domain(d3.extent(data, yValue)); yAxis(yAxisG); const circles = g.selectAll("circle").data(data); circles.exit().remove(); circles .enter().append("circle") .attr("r", 5) .merge(circles) .attr("cx", d => xScale(xValue(d))) .attr("cy", d => yScale(yValue(d))); } function type(d){ d.sepalLength = +d.sepalLength; d.sepalWidth = +d.sepalWidth; d.petalLength = +d.petalLength; d.petalWidth = +d.petalWidth; return d; } d3.csv("iris.csv", type, render); </script> </body> </html>
{ "content_hash": "4a108002a35013217c37b141c71a036b", "timestamp": "", "source": "github", "line_count": 55, "max_line_length": 73, "avg_line_length": 30.636363636363637, "alnum_prop": 0.5347181008902078, "repo_name": "curran/d3-in-motion", "id": "bad903251656cef11e6e022114e4f8d1c4b00d39", "size": "1685", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "archive/units/unit-02/module-05/example-02/index.html", "mode": "33188", "license": "mit", "language": [ { "name": "HTML", "bytes": "238919" }, { "name": "JavaScript", "bytes": "1832" }, { "name": "Shell", "bytes": "218" } ], "symlink_target": "" }
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("FooTestImpl1")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("FooTestImpl1")] [assembly: AssemblyCopyright("Copyright © 2015")] [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("e244aefa-d498-4ecf-b1d1-8e1cf73a4854")] // 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")]
{ "content_hash": "5a83cf2cbdbf97f9fc4e36a2ea986f2d", "timestamp": "", "source": "github", "line_count": 36, "max_line_length": 84, "avg_line_length": 38.80555555555556, "alnum_prop": 0.7451682176091625, "repo_name": "KevinHu-au/Blog", "id": "2963049117530eeec9133fd1829da0a24a04c37e", "size": "1400", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "TestingMultipleImplementations/FooTestImpl1/Properties/AssemblyInfo.cs", "mode": "33188", "license": "mit", "language": [ { "name": "ASP", "bytes": "99" }, { "name": "Batchfile", "bytes": "14399" }, { "name": "C#", "bytes": "676729" }, { "name": "CSS", "bytes": "423005" }, { "name": "HTML", "bytes": "21713" }, { "name": "Java", "bytes": "733237" }, { "name": "JavaScript", "bytes": "1658631" } ], "symlink_target": "" }
<html> <head> </head> <body> <form method="POST" action="/rest/login"><input type="hidden" name="l" value="1" /> <input type="hidden" name="a" value="FORM" /> <input type="text" name="u" value="1" /> <input type="l" name="p" value="1" /> <input type="submit" name="submit" value="Login" /></form> </body> </html>
{ "content_hash": "f746690c95c293aa94139f7f897d0b59", "timestamp": "", "source": "github", "line_count": 10, "max_line_length": 75, "avg_line_length": 31.4, "alnum_prop": 0.6114649681528662, "repo_name": "sakai-mirror/k2", "id": "93bb2d514833a816233b4432386d0e17c2403ba8", "size": "314", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "kernel/src/test/java/org/sakaiproject/kernel/rest/test/testlogin.html", "mode": "33188", "license": "apache-2.0", "language": [ { "name": "Java", "bytes": "2630113" }, { "name": "JavaScript", "bytes": "67965" }, { "name": "Shell", "bytes": "997" } ], "symlink_target": "" }
<!DOCTYPE html> <html lang="en"> <head> <meta charset="utf-8"> <title>Phaser Class: Text</title> <!--[if lt IE 9]> <script src="//html5shiv.googlecode.com/svn/trunk/html5.js"></script> <![endif]--> <link type="text/css" rel="stylesheet" href="styles/default.css"> <link type="text/css" rel="stylesheet" href="styles/sunlight.default.css"> <link type="text/css" rel="stylesheet" href="styles/site.cerulean.css"> </head> <body> <div class="container-fluid"> <div class="navbar navbar-fixed-top navbar-inverse"> <div style="position: absolute; width: 143px; height: 31px; right: 10px; top: 10px; z-index: 1050"><a href="http://phaser.io"><img src="img/phaser.png" border="0" /></a></div> <div class="navbar-inner"> <a class="brand" href="index.html">Phaser API</a> <ul class="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 class="class-depth-0"> <a href="Phaser.html">Phaser</a> </li> <li class="class-depth-0"> <a href="PIXI.html">PIXI</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 class="class-depth-1"> <a href="Phaser.Animation.html">Animation</a> </li> <li class="class-depth-1"> <a href="Phaser.AnimationManager.html">AnimationManager</a> </li> <li class="class-depth-1"> <a href="Phaser.AnimationParser.html">AnimationParser</a> </li> <li class="class-depth-1"> <a href="Phaser.ArraySet.html">ArraySet</a> </li> <li class="class-depth-1"> <a href="Phaser.ArrayUtils.html">ArrayUtils</a> </li> <li class="class-depth-1"> <a href="Phaser.AudioSprite.html">AudioSprite</a> </li> <li class="class-depth-1"> <a href="Phaser.BitmapData.html">BitmapData</a> </li> <li class="class-depth-1"> <a href="Phaser.BitmapText.html">BitmapText</a> </li> <li class="class-depth-1"> <a href="Phaser.Button.html">Button</a> </li> <li class="class-depth-1"> <a href="Phaser.Cache.html">Cache</a> </li> <li class="class-depth-1"> <a href="Phaser.Camera.html">Camera</a> </li> <li class="class-depth-1"> <a href="Phaser.Canvas.html">Canvas</a> </li> <li class="class-depth-1"> <a href="Phaser.Circle.html">Circle</a> </li> <li class="class-depth-1"> <a href="Phaser.Color.html">Color</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.Angle.html">Angle</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.Animation.html">Animation</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.AutoCull.html">AutoCull</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.Bounds.html">Bounds</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.BringToTop.html">BringToTop</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.Core.html">Core</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.Crop.html">Crop</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.Delta.html">Delta</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.Destroy.html">Destroy</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.FixedToCamera.html">FixedToCamera</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.Health.html">Health</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.InCamera.html">InCamera</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.InputEnabled.html">InputEnabled</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.InWorld.html">InWorld</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.LifeSpan.html">LifeSpan</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.LoadTexture.html">LoadTexture</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.Overlap.html">Overlap</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.PhysicsBody.html">PhysicsBody</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.Reset.html">Reset</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.ScaleMinMax.html">ScaleMinMax</a> </li> <li class="class-depth-2"> <a href="Phaser.Component.Smoothed.html">Smoothed</a> </li> <li class="class-depth-1"> <a href="Phaser.Create.html">Create</a> </li> <li class="class-depth-1"> <a href="Phaser.Creature.html">Creature</a> </li> <li class="class-depth-1"> <a href="Phaser.Device.html">Device</a> </li> <li class="class-depth-1"> <a href="Phaser.DeviceButton.html">DeviceButton</a> </li> <li class="class-depth-1"> <a href="Phaser.DOM.html">DOM</a> </li> <li class="class-depth-1"> <a href="Phaser.Easing.html">Easing</a> </li> <li class="class-depth-2"> <a href="Phaser.Easing.Back.html">Back</a> </li> <li class="class-depth-2"> <a href="Phaser.Easing.Bounce.html">Bounce</a> </li> <li class="class-depth-2"> <a href="Phaser.Easing.Circular.html">Circular</a> </li> <li class="class-depth-2"> <a href="Phaser.Easing.Cubic.html">Cubic</a> </li> <li class="class-depth-2"> <a href="Phaser.Easing.Elastic.html">Elastic</a> </li> <li class="class-depth-2"> <a href="Phaser.Easing.Exponential.html">Exponential</a> </li> <li class="class-depth-2"> <a href="Phaser.Easing.Linear.html">Linear</a> </li> <li class="class-depth-2"> <a href="Phaser.Easing.Quadratic.html">Quadratic</a> </li> <li class="class-depth-2"> <a href="Phaser.Easing.Quartic.html">Quartic</a> </li> <li class="class-depth-2"> <a href="Phaser.Easing.Quintic.html">Quintic</a> </li> <li class="class-depth-2"> <a href="Phaser.Easing.Sinusoidal.html">Sinusoidal</a> </li> <li class="class-depth-1"> <a href="Phaser.Ellipse.html">Ellipse</a> </li> <li class="class-depth-1"> <a href="Phaser.Events.html">Events</a> </li> <li class="class-depth-1"> <a href="Phaser.Filter.html">Filter</a> </li> <li class="class-depth-1"> <a href="Phaser.FlexGrid.html">FlexGrid</a> </li> <li class="class-depth-1"> <a href="Phaser.FlexLayer.html">FlexLayer</a> </li> <li class="class-depth-1"> <a href="Phaser.Frame.html">Frame</a> </li> <li class="class-depth-1"> <a href="Phaser.FrameData.html">FrameData</a> </li> <li class="class-depth-1"> <a href="Phaser.Game.html">Game</a> </li> <li class="class-depth-1"> <a href="Phaser.GameObjectCreator.html">GameObjectCreator</a> </li> <li class="class-depth-1"> <a href="Phaser.GameObjectFactory.html">GameObjectFactory</a> </li> <li class="class-depth-1"> <a href="Phaser.Gamepad.html">Gamepad</a> </li> <li class="class-depth-1"> <a href="Phaser.Graphics.html">Graphics</a> </li> <li class="class-depth-1"> <a href="Phaser.Group.html">Group</a> </li> <li class="class-depth-1"> <a href="Phaser.Image.html">Image</a> </li> <li class="class-depth-1"> <a href="Phaser.ImageCollection.html">ImageCollection</a> </li> <li class="class-depth-1"> <a href="Phaser.Input.html">Input</a> </li> <li class="class-depth-1"> <a href="Phaser.InputHandler.html">InputHandler</a> </li> <li class="class-depth-1"> <a href="Phaser.Key.html">Key</a> </li> <li class="class-depth-1"> <a href="Phaser.Keyboard.html">Keyboard</a> </li> <li class="class-depth-1"> <a href="Phaser.Line.html">Line</a> </li> <li class="class-depth-1"> <a href="Phaser.LinkedList.html">LinkedList</a> </li> <li class="class-depth-1"> <a href="Phaser.Loader.html">Loader</a> </li> <li class="class-depth-1"> <a href="Phaser.LoaderParser.html">LoaderParser</a> </li> <li class="class-depth-1"> <a href="Phaser.Math.html">Math</a> </li> <li class="class-depth-1"> <a href="Phaser.Matrix.html">Matrix</a> </li> <li class="class-depth-1"> <a href="Phaser.Mouse.html">Mouse</a> </li> <li class="class-depth-1"> <a href="Phaser.MSPointer.html">MSPointer</a> </li> <li class="class-depth-1"> <a href="Phaser.Net.html">Net</a> </li> <li class="class-depth-1"> <a href="Phaser.Particle.html">Particle</a> </li> <li class="class-depth-1"> <a href="Phaser.Particles.html">Particles</a> </li> <li class="class-depth-2"> <a href="Phaser.Particles.Arcade.html">Arcade</a> </li> <li class="class-depth-3"> <a href="Phaser.Particles.Arcade.Emitter.html">Emitter</a> </li> <li class="class-depth-1"> <a href="Phaser.Physics.html">Physics</a> </li> <li class="class-depth-2"> <a href="Phaser.Physics.Arcade.html">Arcade</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.Arcade.Body.html">Body</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.Arcade.html#TilemapCollision">TilemapCollision</a> </li> <li class="class-depth-2"> <a href="Phaser.Physics.Ninja.html">Ninja</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.Ninja.AABB.html">AABB</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.Ninja.Body.html">Body</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.Ninja.Circle.html">Circle</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.Ninja.Tile.html">Tile</a> </li> <li class="class-depth-2"> <a href="Phaser.Physics.P2.html">P2</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.Body.html">Body</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.BodyDebug.html">BodyDebug</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.CollisionGroup.html">CollisionGroup</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.ContactMaterial.html">ContactMaterial</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.DistanceConstraint.html">DistanceConstraint</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.FixtureList.html">FixtureList</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.GearConstraint.html">GearConstraint</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.InversePointProxy.html">InversePointProxy</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.LockConstraint.html">LockConstraint</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.Material.html">Material</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.PointProxy.html">PointProxy</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.PrismaticConstraint.html">PrismaticConstraint</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.RevoluteConstraint.html">RevoluteConstraint</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.RotationalSpring.html">RotationalSpring</a> </li> <li class="class-depth-3"> <a href="Phaser.Physics.P2.Spring.html">Spring</a> </li> <li class="class-depth-1"> <a href="Phaser.Plugin.html">Plugin</a> </li> <li class="class-depth-1"> <a href="Phaser.PluginManager.html">PluginManager</a> </li> <li class="class-depth-1"> <a href="Phaser.Point.html">Point</a> </li> <li class="class-depth-1"> <a href="Phaser.Pointer.html">Pointer</a> </li> <li class="class-depth-1"> <a href="Phaser.Polygon.html">Polygon</a> </li> <li class="class-depth-1"> <a href="Phaser.QuadTree.html">QuadTree</a> </li> <li class="class-depth-1"> <a href="Phaser.RandomDataGenerator.html">RandomDataGenerator</a> </li> <li class="class-depth-1"> <a href="Phaser.Rectangle.html">Rectangle</a> </li> <li class="class-depth-1"> <a href="Phaser.RenderTexture.html">RenderTexture</a> </li> <li class="class-depth-1"> <a href="Phaser.RequestAnimationFrame.html">RequestAnimationFrame</a> </li> <li class="class-depth-1"> <a href="Phaser.RetroFont.html">RetroFont</a> </li> <li class="class-depth-1"> <a href="Phaser.Rope.html">Rope</a> </li> <li class="class-depth-1"> <a href="Phaser.RoundedRectangle.html">RoundedRectangle</a> </li> <li class="class-depth-1"> <a href="Phaser.ScaleManager.html">ScaleManager</a> </li> <li class="class-depth-1"> <a href="Phaser.Signal.html">Signal</a> </li> <li class="class-depth-1"> <a href="Phaser.SignalBinding.html">SignalBinding</a> </li> <li class="class-depth-1"> <a href="Phaser.SinglePad.html">SinglePad</a> </li> <li class="class-depth-1"> <a href="Phaser.Sound.html">Sound</a> </li> <li class="class-depth-1"> <a href="Phaser.SoundManager.html">SoundManager</a> </li> <li class="class-depth-1"> <a href="Phaser.Sprite.html">Sprite</a> </li> <li class="class-depth-1"> <a href="Phaser.SpriteBatch.html">SpriteBatch</a> </li> <li class="class-depth-1"> <a href="Phaser.Stage.html">Stage</a> </li> <li class="class-depth-1"> <a href="Phaser.State.html">State</a> </li> <li class="class-depth-1"> <a href="Phaser.StateManager.html">StateManager</a> </li> <li class="class-depth-1"> <a href="Phaser.Text.html">Text</a> </li> <li class="class-depth-1"> <a href="Phaser.Tile.html">Tile</a> </li> <li class="class-depth-1"> <a href="Phaser.Tilemap.html">Tilemap</a> </li> <li class="class-depth-1"> <a href="Phaser.TilemapLayer.html">TilemapLayer</a> </li> <li class="class-depth-1"> <a href="Phaser.TilemapParser.html">TilemapParser</a> </li> <li class="class-depth-1"> <a href="Phaser.Tileset.html">Tileset</a> </li> <li class="class-depth-1"> <a href="Phaser.TileSprite.html">TileSprite</a> </li> <li class="class-depth-1"> <a href="Phaser.Time.html">Time</a> </li> <li class="class-depth-1"> <a href="Phaser.Timer.html">Timer</a> </li> <li class="class-depth-1"> <a href="Phaser.TimerEvent.html">TimerEvent</a> </li> <li class="class-depth-1"> <a href="Phaser.Touch.html">Touch</a> </li> <li class="class-depth-1"> <a href="Phaser.Tween.html">Tween</a> </li> <li class="class-depth-1"> <a href="Phaser.TweenData.html">TweenData</a> </li> <li class="class-depth-1"> <a href="Phaser.TweenManager.html">TweenManager</a> </li> <li class="class-depth-1"> <a href="Phaser.Utils.html">Utils</a> </li> <li class="class-depth-2"> <a href="Phaser.Utils.Debug.html">Debug</a> </li> <li class="class-depth-1"> <a href="Phaser.Video.html">Video</a> </li> <li class="class-depth-1"> <a href="Phaser.World.html">World</a> </li> <li class="class-depth-1"> <a href="PIXI.AbstractFilter.html">AbstractFilter</a> </li> <li class="class-depth-1"> <a href="PIXI.BaseTexture.html">BaseTexture</a> </li> <li class="class-depth-1"> <a href="PIXI.CanvasBuffer.html">CanvasBuffer</a> </li> <li class="class-depth-1"> <a href="PIXI.CanvasGraphics.html">CanvasGraphics</a> </li> <li class="class-depth-1"> <a href="PIXI.CanvasMaskManager.html">CanvasMaskManager</a> </li> <li class="class-depth-1"> <a href="PIXI.CanvasRenderer.html">CanvasRenderer</a> </li> <li class="class-depth-1"> <a href="PIXI.CanvasTinter.html">CanvasTinter</a> </li> <li class="class-depth-1"> <a href="PIXI.ComplexPrimitiveShader.html">ComplexPrimitiveShader</a> </li> <li class="class-depth-1"> <a href="PIXI.DisplayObject.html">DisplayObject</a> </li> <li class="class-depth-1"> <a href="PIXI.DisplayObjectContainer.html">DisplayObjectContainer</a> </li> <li class="class-depth-1"> <a href="PIXI.Event.html">Event</a> </li> <li class="class-depth-1"> <a href="PIXI.EventTarget.html">EventTarget</a> </li> <li class="class-depth-1"> <a href="PIXI.FilterTexture.html">FilterTexture</a> </li> <li class="class-depth-1"> <a href="PIXI.Graphics.html">Graphics</a> </li> <li class="class-depth-1"> <a href="PIXI.GraphicsData.html">GraphicsData</a> </li> <li class="class-depth-1"> <a href="PIXI.PIXI.html">PIXI</a> </li> <li class="class-depth-1"> <a href="PIXI.PixiFastShader.html">PixiFastShader</a> </li> <li class="class-depth-1"> <a href="PIXI.PixiShader.html">PixiShader</a> </li> <li class="class-depth-1"> <a href="PIXI.PolyK.html">PolyK</a> </li> <li class="class-depth-1"> <a href="PIXI.PrimitiveShader.html">PrimitiveShader</a> </li> <li class="class-depth-1"> <a href="PIXI.RenderTexture.html">RenderTexture</a> </li> <li class="class-depth-1"> <a href="PIXI.Rope.html">Rope</a> </li> <li class="class-depth-1"> <a href="PIXI.Sprite.html">Sprite</a> </li> <li class="class-depth-1"> <a href="PIXI.SpriteBatch.html">SpriteBatch</a> </li> <li class="class-depth-1"> <a href="PIXI.Stage.html">Stage</a> </li> <li class="class-depth-1"> <a href="PIXI.Strip.html">Strip</a> </li> <li class="class-depth-1"> <a href="PIXI.StripShader.html">StripShader</a> </li> <li class="class-depth-1"> <a href="PIXI.Texture.html">Texture</a> </li> <li class="class-depth-1"> <a href="PIXI.TilingSprite.html">TilingSprite</a> </li> <li class="class-depth-1"> <a href="PIXI.WebGLBlendModeManager.html">WebGLBlendModeManager</a> </li> <li class="class-depth-1"> <a href="PIXI.WebGLFastSpriteBatch.html">WebGLFastSpriteBatch</a> </li> <li class="class-depth-1"> <a href="PIXI.WebGLFilterManager.html">WebGLFilterManager</a> </li> <li class="class-depth-1"> <a href="PIXI.WebGLRenderer.html">WebGLRenderer</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 class="class-depth-0"> <a href="global.html#AUTO">AUTO</a> </li> <li class="class-depth-0"> <a href="global.html#BITMAPDATA">BITMAPDATA</a> </li> <li class="class-depth-0"> <a href="global.html#BITMAPTEXT">BITMAPTEXT</a> </li> <li class="class-depth-0"> <a href="global.html#blendModes">blendModes</a> </li> <li class="class-depth-0"> <a href="global.html#BUTTON">BUTTON</a> </li> <li class="class-depth-0"> <a href="global.html#CANVAS">CANVAS</a> </li> <li class="class-depth-0"> <a href="global.html#CANVAS_FILTER">CANVAS_FILTER</a> </li> <li class="class-depth-0"> <a href="global.html#CIRCLE">CIRCLE</a> </li> <li class="class-depth-0"> <a href="global.html#CREATURE">CREATURE</a> </li> <li class="class-depth-0"> <a href="global.html#DOWN">DOWN</a> </li> <li class="class-depth-0"> <a href="global.html#ELLIPSE">ELLIPSE</a> </li> <li class="class-depth-0"> <a href="global.html#EMITTER">EMITTER</a> </li> <li class="class-depth-0"> <a href="global.html#GAMES">GAMES</a> </li> <li class="class-depth-0"> <a href="global.html#GRAPHICS">GRAPHICS</a> </li> <li class="class-depth-0"> <a href="global.html#GROUP">GROUP</a> </li> <li class="class-depth-0"> <a href="global.html#HEADLESS">HEADLESS</a> </li> <li class="class-depth-0"> <a href="global.html#IMAGE">IMAGE</a> </li> <li class="class-depth-0"> <a href="global.html#LEFT">LEFT</a> </li> <li class="class-depth-0"> <a href="global.html#LINE">LINE</a> </li> <li class="class-depth-0"> <a href="global.html#MATRIX">MATRIX</a> </li> <li class="class-depth-0"> <a href="global.html#NONE">NONE</a> </li> <li class="class-depth-0"> <a href="global.html#POINT">POINT</a> </li> <li class="class-depth-0"> <a href="global.html#POINTER">POINTER</a> </li> <li class="class-depth-0"> <a href="global.html#POLYGON">POLYGON</a> </li> <li class="class-depth-0"> <a href="global.html#RECTANGLE">RECTANGLE</a> </li> <li class="class-depth-0"> <a href="global.html#RENDERTEXTURE">RENDERTEXTURE</a> </li> <li class="class-depth-0"> <a href="global.html#RETROFONT">RETROFONT</a> </li> <li class="class-depth-0"> <a href="global.html#RIGHT">RIGHT</a> </li> <li class="class-depth-0"> <a href="global.html#ROPE">ROPE</a> </li> <li class="class-depth-0"> <a href="global.html#ROUNDEDRECTANGLE">ROUNDEDRECTANGLE</a> </li> <li class="class-depth-0"> <a href="global.html#scaleModes">scaleModes</a> </li> <li class="class-depth-0"> <a href="global.html#SPRITE">SPRITE</a> </li> <li class="class-depth-0"> <a href="global.html#SPRITEBATCH">SPRITEBATCH</a> </li> <li class="class-depth-0"> <a href="global.html#TEXT">TEXT</a> </li> <li class="class-depth-0"> <a href="global.html#TILEMAP">TILEMAP</a> </li> <li class="class-depth-0"> <a href="global.html#TILEMAPLAYER">TILEMAPLAYER</a> </li> <li class="class-depth-0"> <a href="global.html#TILESPRITE">TILESPRITE</a> </li> <li class="class-depth-0"> <a href="global.html#UP">UP</a> </li> <li class="class-depth-0"> <a href="global.html#VERSION">VERSION</a> </li> <li class="class-depth-0"> <a href="global.html#VIDEO">VIDEO</a> </li> <li class="class-depth-0"> <a href="global.html#WEBGL">WEBGL</a> </li> <li class="class-depth-0"> <a href="global.html#WEBGL_FILTER">WEBGL_FILTER</a> </li> </ul> </li> <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown">Core<b class="caret"></b></a> <ul class="dropdown-menu "> <li class="class-depth-1"><a href="Phaser.Game.html">Game</a></li> <li class="class-depth-1"><a href="Phaser.Group.html">Group</a></li> <li class="class-depth-1"><a href="Phaser.World.html">World</a></li> <li class="class-depth-1"><a href="Phaser.Loader.html">Loader</a></li> <li class="class-depth-1"><a href="Phaser.Cache.html">Cache</a></li> <li class="class-depth-1"><a href="Phaser.Time.html">Time</a></li> <li class="class-depth-1"><a href="Phaser.Camera.html">Camera</a></li> <li class="class-depth-1"><a href="Phaser.StateManager.html">State Manager</a></li> <li class="class-depth-1"><a href="Phaser.TweenManager.html">Tween Manager</a></li> <li class="class-depth-1"><a href="Phaser.SoundManager.html">Sound Manager</a></li> <li class="class-depth-1"><a href="Phaser.Input.html">Input Manager</a></li> <li class="class-depth-1"><a href="Phaser.ScaleManager.html">Scale Manager</a></li> </ul> </li> <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown">Game Objects<b class="caret"></b></a> <ul class="dropdown-menu "> <li class="class-depth-1"><a href="Phaser.GameObjectFactory.html">Factory (game.add)</a></li> <li class="class-depth-1"><a href="Phaser.GameObjectCreator.html">Creator (game.make)</a></li> <li class="class-depth-1"><a href="Phaser.Sprite.html">Sprite</a></li> <li class="class-depth-1"><a href="Phaser.Image.html">Image</a></li> <li class="class-depth-1"><a href="Phaser.Sound.html">Sound</a></li> <li class="class-depth-1"><a href="Phaser.Video.html">Video</a></li> <li class="class-depth-1"><a href="Phaser.Particles.Arcade.Emitter.html">Particle Emitter</a></li> <li class="class-depth-1"><a href="Phaser.Particle.html">Particle</a></li> <li class="class-depth-1"><a href="Phaser.Text.html">Text</a></li> <li class="class-depth-1"><a href="Phaser.Tween.html">Tween</a></li> <li class="class-depth-1"><a href="Phaser.BitmapText.html">BitmapText</a></li> <li class="class-depth-1"><a href="Phaser.Tilemap.html">Tilemap</a></li> <li class="class-depth-1"><a href="Phaser.BitmapData.html">BitmapData</a></li> <li class="class-depth-1"><a href="Phaser.RetroFont.html">RetroFont</a></li> <li class="class-depth-1"><a href="Phaser.Button.html">Button</a></li> <li class="class-depth-1"><a href="Phaser.Animation.html">Animation</a></li> <li class="class-depth-1"><a href="Phaser.Graphics.html">Graphics</a></li> <li class="class-depth-1"><a href="Phaser.RenderTexture.html">RenderTexture</a></li> <li class="class-depth-1"><a href="Phaser.TileSprite.html">TileSprite</a></li> </ul> </li> <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown">Geometry<b class="caret"></b></a> <ul class="dropdown-menu "> <li class="class-depth-1"><a href="Phaser.Circle.html">Circle</a></li> <li class="class-depth-1"><a href="Phaser.Ellipse.html">Ellipse</a></li> <li class="class-depth-1"><a href="Phaser.Line.html">Line</a></li> <li class="class-depth-1"><a href="Phaser.Matrix.html">Matrix</a></li> <li class="class-depth-1"><a href="Phaser.Point.html">Point</a></li> <li class="class-depth-1"><a href="Phaser.Polygon.html">Polygon</a></li> <li class="class-depth-1"><a href="Phaser.Rectangle.html">Rectangle</a></li> <li class="class-depth-1"><a href="Phaser.RoundedRectangle.html">Rounded Rectangle</a></li> </ul> </li> <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown">Physics<b class="caret"></b></a> <ul class="dropdown-menu "> <li class="class-depth-1"><a href="Phaser.Physics.Arcade.html">Arcade Physics</a></li> <li class="class-depth-2"><a href="Phaser.Physics.Arcade.Body.html">Body</a></li> <li class="class-depth-1"><a href="Phaser.Physics.P2.html">P2 Physics</a></li> <li class="class-depth-2"><a href="Phaser.Physics.P2.Body.html">Body</a></li> <li class="class-depth-2"><a href="Phaser.Physics.P2.Spring.html">Spring</a></li> <li class="class-depth-2"><a href="Phaser.Physics.P2.CollisionGroup.html">CollisionGroup</a></li> <li class="class-depth-2"><a href="Phaser.Physics.P2.ContactMaterial.html">ContactMaterial</a></li> <li class="class-depth-1"><a href="Phaser.Physics.Ninja.html">Ninja Physics</a></li> <li class="class-depth-2"><a href="Phaser.Physics.Body.html">Body</a></li> </ul> </li> <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown">Input<b class="caret"></b></a> <ul class="dropdown-menu "> <li class="class-depth-1"><a href="Phaser.InputHandler.html">Input Handler</a></li> <li class="class-depth-1"><a href="Phaser.Pointer.html">Pointer</a></li> <li class="class-depth-1"><a href="Phaser.DeviceButton.html">Device Button</a></li> <li class="class-depth-1"><a href="Phaser.Mouse.html">Mouse</a></li> <li class="class-depth-1"><a href="Phaser.Keyboard.html">Keyboard</a></li> <li class="class-depth-1"><a href="Phaser.Key.html">Key</a></li> <li class="class-depth-1"><a href="Phaser.Gamepad.html">Gamepad</a></li> </ul> </li> <li class="dropdown"> <a href="#" class="dropdown-toggle" data-toggle="dropdown">Community<b class="caret"></b></a> <ul class="dropdown-menu "> <li class="class-depth-1"><a href="http://phaser.io">Phaser Web Site</a></li> <li class="class-depth-1"><a href="https://github.com/photonstorm/phaser">Phaser Github</a></li> <li class="class-depth-1"><a href="http://phaser.io/examples">Phaser Examples</a></li> <li class="class-depth-1"><a href="https://github.com/photonstorm/phaser-plugins">Phaser Plugins</a></li> <li class="class-depth-1"><a href="http://www.html5gamedevs.com/forum/14-phaser/">Forum</a></li> <li class="class-depth-1"><a href="http://stackoverflow.com/questions/tagged/phaser-framework">Stack Overflow</a></li> <li class="class-depth-1"><a href="http://phaser.io/learn">Tutorials</a></li> <li class="class-depth-1"><a href="https://confirmsubscription.com/h/r/369DE48E3E86AF1E">Newsletter</a></li> <li class="class-depth-1"><a href="http://phaser.io/community/twitter">Twitter</a></li> <li class="class-depth-1"><a href="http://phaser.io/community/irc">IRC</a></li> <li class="class-depth-1"><a href="https://www.codeandweb.com/texturepacker/phaser">Texture Packer</a></li> </ul> </li> </ul> </div> </div> <div class="row-fluid"> <div class="span8"> <div id="main"> <!--<h1 class="page-title">Class: Text</h1>--> <section> <header> <h2> <span class="ancestors"><a href="Phaser.html">Phaser</a>.</span> Text </h2> </header> <article> <div class="container-overview"> <dt> <h4 class="name " id="Text"><span class="type-signature"></span>new Text<span class="signature">(game, x, y, text, <span class="optional">style</span>)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Create a new game object for displaying Text.</p> <p>This uses a local hidden Canvas object and renders the type into it. It then makes a texture from this for rendering to the view. Because of this you can only display fonts that are currently loaded and available to the browser: fonts must be pre-loaded.</p> <p>See <a href="http://www.jordanm.co.uk/tinytype">this compatibility table</a> for the available default fonts across mobile browsers.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>game</code></td> <td class="type"> <span class="param-type"><a href="Phaser.Game.html">Phaser.Game</a></span> </td> <td class="attributes"> </td> <td class="description last"><p>Current game instance.</p></td> </tr> <tr> <td class="name"><code>x</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> </td> <td class="description last"><p>X position of the new text object.</p></td> </tr> <tr> <td class="name"><code>y</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> </td> <td class="description last"><p>Y position of the new text object.</p></td> </tr> <tr> <td class="name"><code>text</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> </td> <td class="description last"><p>The actual text that will be written.</p></td> </tr> <tr> <td class="name"><code>style</code></td> <td class="type"> <span class="param-type">object</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="description last"><p>The style properties to be set on the Text.</p> <h6>Properties</h6> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th>Default</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>font</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'bold 20pt Arial' </td> <td class="description last"><p>The style and size of the font.</p></td> </tr> <tr> <td class="name"><code>fontStyle</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> (from font) </td> <td class="description last"><p>The style of the font (eg. 'italic'): overrides the value in <code>style.font</code>.</p></td> </tr> <tr> <td class="name"><code>fontVariant</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> (from font) </td> <td class="description last"><p>The variant of the font (eg. 'small-caps'): overrides the value in <code>style.font</code>.</p></td> </tr> <tr> <td class="name"><code>fontWeight</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> (from font) </td> <td class="description last"><p>The weight of the font (eg. 'bold'): overrides the value in <code>style.font</code>.</p></td> </tr> <tr> <td class="name"><code>fontSize</code></td> <td class="type"> <span class="param-type">string</span> | <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> (from font) </td> <td class="description last"><p>The size of the font (eg. 32 or '32px'): overrides the value in <code>style.font</code>.</p></td> </tr> <tr> <td class="name"><code>backgroundColor</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> null </td> <td class="description last"><p>A canvas fillstyle that will be used as the background for the whole Text object. Set to <code>null</code> to disable.</p></td> </tr> <tr> <td class="name"><code>fill</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'black' </td> <td class="description last"><p>A canvas fillstyle that will be used on the text eg 'red', '#00FF00'.</p></td> </tr> <tr> <td class="name"><code>align</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'left' </td> <td class="description last"><p>Horizontal alignment of each line in multiline text. Can be: 'left', 'center' or 'right'. Does not affect single lines of text (see <code>textBounds</code> and <code>boundsAlignH</code> for that).</p></td> </tr> <tr> <td class="name"><code>boundsAlignH</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'left' </td> <td class="description last"><p>Horizontal alignment of the text within the <code>textBounds</code>. Can be: 'left', 'center' or 'right'.</p></td> </tr> <tr> <td class="name"><code>boundsAlignV</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'top' </td> <td class="description last"><p>Vertical alignment of the text within the <code>textBounds</code>. Can be: 'top', 'middle' or 'bottom'.</p></td> </tr> <tr> <td class="name"><code>stroke</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'black' </td> <td class="description last"><p>A canvas stroke style that will be used on the text stroke eg 'blue', '#FCFF00'.</p></td> </tr> <tr> <td class="name"><code>strokeThickness</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 0 </td> <td class="description last"><p>A number that represents the thickness of the stroke. Default is 0 (no stroke).</p></td> </tr> <tr> <td class="name"><code>wordWrap</code></td> <td class="type"> <span class="param-type">boolean</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> false </td> <td class="description last"><p>Indicates if word wrap should be used.</p></td> </tr> <tr> <td class="name"><code>wordWrapWidth</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 100 </td> <td class="description last"><p>The width in pixels at which text will wrap.</p></td> </tr> <tr> <td class="name"><code>tabs</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 0 </td> <td class="description last"><p>The size (in pixels) of the tabs, for when text includes tab characters. 0 disables. Can be an array of varying tab sizes, one per tab stop.</p></td> </tr> </tbody> </table> </td> </tr> </tbody> </table> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-39">line 39</a> </dt> </dl> </dd> </div> <h3 class="subsection-title">Extends</h3> <ul> <li><a href="Phaser.Sprite.html">Phaser.Sprite</a></li> </ul> <h3 class="subsection-title">Members</h3> <dl> <dt> <h4 class="name " id="align"><span class="type-signature"></span>align<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>Controls the horizontal alignment for multiline text. Can be: 'left', 'center' or 'right'. Does not affect single lines of text. For that please see <code>setTextBounds</code>.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1462">line 1462</a> </dt> </dl> </dd> <dt> <h4 class="name " id="alive"><span class="type-signature"></span>alive<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>A useful flag to control if the Game Object is alive or dead.</p> <p>This is set automatically by the Health components <code>damage</code> method should the object run out of health. Or you can toggle it via your game code.</p> <p>This property is mostly just provided to be used by your game - it doesn't effect rendering or logic updates. However you can use <code>Group.getFirstAlive</code> in conjunction with this property for fast object pooling and recycling.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.LifeSpan.html#alive">Phaser.Component.LifeSpan#alive</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>true</li></ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_LifeSpan.js.html">gameobjects/components/LifeSpan.js</a>, <a href="src_gameobjects_components_LifeSpan.js.html#sunlight-1-line-50">line 50</a> </dt> </dl> </dd> <dt> <h4 class="name " id="alpha"><span class="type-signature"></span>alpha<span class="type-signature"> :Number</span></h4> </dt> <dd> <div class="description"> <p>The opacity of the object.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#alpha">PIXI.DisplayObject#alpha</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-65">line 65</a> </dt> </dl> </dd> <dt> <h4 class="name " id="anchor"><span class="type-signature"></span>anchor<span class="type-signature"> :Point</span></h4> </dt> <dd> <div class="description"> <p>The anchor sets the origin point of the texture. The default is 0,0 this means the texture's origin is the top left Setting than anchor to 0.5,0.5 means the textures origin is centered Setting the anchor to 1,1 would mean the textures origin points will be the bottom right corner</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.Sprite.html#anchor">PIXI.Sprite#anchor</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_Sprite.js.html">pixi/display/Sprite.js</a>, <a href="src_pixi_display_Sprite.js.html#sunlight-1-line-22">line 22</a> </dt> </dl> </dd> <dt> <h4 class="name " id="angle"><span class="type-signature"></span>angle<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The angle property is the rotation of the Game Object in <em>degrees</em> from its original orientation.</p> <p>Values from 0 to 180 represent clockwise rotation; values from 0 to -180 represent counterclockwise rotation.</p> <p>Values outside this range are added to or subtracted from 360 to obtain a value within the range. For example, the statement player.angle = 450 is the same as player.angle = 90.</p> <p>If you wish to work in radians instead of degrees you can use the property <code>rotation</code> instead. Working in radians is slightly faster as it doesn't have to perform any calculations.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Angle.html#angle">Phaser.Component.Angle#angle</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Angle.js.html">gameobjects/components/Angle.js</a>, <a href="src_gameobjects_components_Angle.js.html#sunlight-1-line-29">line 29</a> </dt> </dl> </dd> <dt> <h4 class="name " id="animations"><span class="type-signature"></span>animations<span class="type-signature"> :<a href="Phaser.AnimationManager.html">Phaser.AnimationManager</a></span></h4> </dt> <dd> <div class="description"> <p>If the Game Object is enabled for animation (such as a Phaser.Sprite) this is a reference to its AnimationManager instance. Through it you can create, play, pause and stop animations.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#animations">Phaser.Component.Core#animations</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-184">line 184</a> </dt> <dt class="tag-see">See:</dt> <dd class="tag-see"> <ul> <li><a href="Phaser.AnimationManager.html">Phaser.AnimationManager</a></li> </ul> </dd> </dl> </dd> <dt> <h4 class="name " id="autoCull"><span class="type-signature"></span>autoCull<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>A Game Object with <code>autoCull</code> set to true will check its bounds against the World Camera every frame. If it is not intersecting the Camera bounds at any point then it has its <code>renderable</code> property set to <code>false</code>. This keeps the Game Object alive and still processing updates, but forces it to skip the render step entirely.</p> <p>This is a relatively expensive operation, especially if enabled on hundreds of Game Objects. So enable it only if you know it's required, or you have tested performance and find it acceptable.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.AutoCull.html#autoCull">Phaser.Component.AutoCull#autoCull</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>false</li></ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_AutoCull.js.html">gameobjects/components/AutoCull.js</a>, <a href="src_gameobjects_components_AutoCull.js.html#sunlight-1-line-28">line 28</a> </dt> </dl> </dd> <dt> <h4 class="name " id="autoRound"><span class="type-signature"></span>autoRound<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>Should the linePositionX and Y values be automatically rounded before rendering the Text? You may wish to enable this if you want to remove the effect of sub-pixel aliasing from text.</p> </div> <dl class="details"> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>false</li></ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-99">line 99</a> </dt> </dl> </dd> <dt> <h4 class="name " id="blendMode"><span class="type-signature"></span>blendMode<span class="type-signature"> :Number</span></h4> </dt> <dd> <div class="description"> <p>The blend mode to be applied to the sprite. Set to PIXI.blendModes.NORMAL to remove any blend mode.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.Sprite.html#blendMode">PIXI.Sprite#blendMode</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>PIXI.blendModes.NORMAL;</li></ul></dd> <dt class="tag-source">Source - <a href="src_pixi_display_Sprite.js.html">pixi/display/Sprite.js</a>, <a href="src_pixi_display_Sprite.js.html#sunlight-1-line-87">line 87</a> </dt> </dl> </dd> <dt> <h4 class="name " id="body"><span class="type-signature"></span>body<span class="type-signature"> :<a href="Phaser.Physics.Arcade.Body.html">Phaser.Physics.Arcade.Body</a>|<a href="Phaser.Physics.P2.Body.html">Phaser.Physics.P2.Body</a>|<a href="Phaser.Physics.Ninja.Body.html">Phaser.Physics.Ninja.Body</a>|null</span></h4> </dt> <dd> <div class="description"> <p><code>body</code> is the Game Objects physics body. Once a Game Object is enabled for physics you access all associated properties and methods via it.</p> <p>By default Game Objects won't add themselves to any physics system and their <code>body</code> property will be <code>null</code>.</p> <p>To enable this Game Object for physics you need to call <code>game.physics.enable(object, system)</code> where <code>object</code> is this object and <code>system</code> is the Physics system you are using. If none is given it defaults to <code>Phaser.Physics.Arcade</code>.</p> <p>You can alternatively call <code>game.physics.arcade.enable(object)</code>, or add this Game Object to a physics enabled Group.</p> <p>Important: Enabling a Game Object for P2 or Ninja physics will automatically set its <code>anchor</code> property to 0.5, so the physics body is centered on the Game Object.</p> <p>If you need a different result then adjust or re-create the Body shape offsets manually or reset the anchor after enabling physics.</p> </div> <h5>Type:</h5> <ul> <li> <span class="param-type"><a href="Phaser.Physics.Arcade.Body.html">Phaser.Physics.Arcade.Body</a></span> | <span class="param-type"><a href="Phaser.Physics.P2.Body.html">Phaser.Physics.P2.Body</a></span> | <span class="param-type"><a href="Phaser.Physics.Ninja.Body.html">Phaser.Physics.Ninja.Body</a></span> | <span class="param-type">null</span> </li> </ul> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.PhysicsBody.html#body">Phaser.Component.PhysicsBody#body</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>null</li></ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_PhysicsBody.js.html">gameobjects/components/PhysicsBody.js</a>, <a href="src_gameobjects_components_PhysicsBody.js.html#sunlight-1-line-91">line 91</a> </dt> </dl> </dd> <dt> <h4 class="name " id="bottom"><span class="type-signature">&lt;readonly> </span>bottom<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The sum of the y and height properties. This is the same as <code>y + height - offsetY</code>.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Bounds.html#bottom">Phaser.Component.Bounds#bottom</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Bounds.js.html">gameobjects/components/Bounds.js</a>, <a href="src_gameobjects_components_Bounds.js.html#sunlight-1-line-110">line 110</a> </dt> </dl> </dd> <dt> <h4 class="name " id="boundsAlignH"><span class="type-signature"></span>boundsAlignH<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>Horizontal alignment of the text within the <code>textBounds</code>. Can be: 'left', 'center' or 'right'.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1538">line 1538</a> </dt> </dl> </dd> <dt> <h4 class="name " id="boundsAlignV"><span class="type-signature"></span>boundsAlignV<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>Vertical alignment of the text within the <code>textBounds</code>. Can be: 'top', 'middle' or 'bottom'.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1561">line 1561</a> </dt> </dl> </dd> <dt> <h4 class="name " id="cacheAsBitmap"><span class="type-signature"></span>cacheAsBitmap<span class="type-signature"> :Boolean</span></h4> </dt> <dd> <div class="description"> <p>Set if this display object is cached as a bitmap. This basically takes a snap shot of the display object as it is at that moment. It can provide a performance benefit for complex static displayObjects. To remove simply set this property to 'null'</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#cacheAsBitmap">PIXI.DisplayObject#cacheAsBitmap</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-366">line 366</a> </dt> </dl> </dd> <dt> <h4 class="name " id="cameraOffset"><span class="type-signature"></span>cameraOffset<span class="type-signature"> :<a href="Phaser.Point.html">Phaser.Point</a></span></h4> </dt> <dd> <div class="description"> <p>The x/y coordinate offset applied to the top-left of the camera that this Game Object will be drawn at if <code>fixedToCamera</code> is true.</p> <p>The values are relative to the top-left of the camera view and in addition to any parent of the Game Object on the display list.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.FixedToCamera.html#cameraOffset">Phaser.Component.FixedToCamera#cameraOffset</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_FixedToCamera.js.html">gameobjects/components/FixedToCamera.js</a>, <a href="src_gameobjects_components_FixedToCamera.js.html#sunlight-1-line-86">line 86</a> </dt> </dl> </dd> <dt> <h4 class="name " id="canvas"><span class="type-signature"></span>canvas<span class="type-signature"> :HTMLCanvasElement</span></h4> </dt> <dd> <div class="description"> <p>The canvas element that the text is rendered.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-76">line 76</a> </dt> </dl> </dd> <dt> <h4 class="name " id="checkWorldBounds"><span class="type-signature"></span>checkWorldBounds<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>If this is set to <code>true</code> the Game Object checks if it is within the World bounds each frame. </p> <p>When it is no longer intersecting the world bounds it dispatches the <code>onOutOfBounds</code> event.</p> <p>If it was <em>previously</em> out of bounds but is now intersecting the world bounds again it dispatches the <code>onEnterBounds</code> event.</p> <p>It also optionally kills the Game Object if <code>outOfBoundsKill</code> is <code>true</code>.</p> <p>When <code>checkWorldBounds</code> is enabled it forces the Game Object to calculate its full bounds every frame.</p> <p>This is a relatively expensive operation, especially if enabled on hundreds of Game Objects. So enable it only if you know it's required, or you have tested performance and find it acceptable.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.InWorld.html#checkWorldBounds">Phaser.Component.InWorld#checkWorldBounds</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>false</li></ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_InWorld.js.html">gameobjects/components/InWorld.js</a>, <a href="src_gameobjects_components_InWorld.js.html#sunlight-1-line-92">line 92</a> </dt> </dl> </dd> <dt> <h4 class="name " id="children"><span class="type-signature">&lt;readonly> </span>children<span class="type-signature"> :Array.&lt;<a href="global.html#DisplayObject">DisplayObject</a>></span></h4> </dt> <dd> <div class="description"> <p>[read-only] The array of children of this container.</p> </div> <h5>Type:</h5> <ul> <li> <span class="param-type">Array.&lt;<a href="global.html#DisplayObject">DisplayObject</a>></span> </li> </ul> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#children">PIXI.DisplayObjectContainer#children</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-17">line 17</a> </dt> </dl> </dd> <dt> <h4 class="name " id="colors"><span class="type-signature"></span>colors<span class="type-signature"> :array</span></h4> </dt> <dd> <div class="description"> <p>An array of the color values as specified by <a href="Phaser.Text.html#addColor">addColor</a>.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-86">line 86</a> </dt> </dl> </dd> <dt> <h4 class="name " id="components"><span class="type-signature">&lt;internal> </span>components<span class="type-signature"> :object</span></h4> </dt> <dd> <div class="description"> <p>The components this Game Object has installed.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#components">Phaser.Component.Core#components</a> </li></dd> <dt class="important tag-deprecated">Internal:</dt> <dd class="tag-deprecated"><ul> <li>This member is <em>internal (protected)</em> and may be modified or removed in the future.</li> </ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-160">line 160</a> </dt> </dl> </dd> <dt> <h4 class="name " id="context"><span class="type-signature"></span>context<span class="type-signature"> :HTMLCanvasElement</span></h4> </dt> <dd> <div class="description"> <p>The context of the canvas element that the text is rendered to.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-81">line 81</a> </dt> </dl> </dd> <dt> <h4 class="name " id="cropRect"><span class="type-signature"></span>cropRect<span class="type-signature"> :<a href="Phaser.Rectangle.html">Phaser.Rectangle</a></span></h4> </dt> <dd> <div class="description"> <p>The Rectangle used to crop the texture this Game Object uses. Set this property via <code>crop</code>. If you modify this property directly you must call <code>updateCrop</code> in order to have the change take effect.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Crop.html#cropRect">Phaser.Component.Crop#cropRect</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>null</li></ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Crop.js.html">gameobjects/components/Crop.js</a>, <a href="src_gameobjects_components_Crop.js.html#sunlight-1-line-24">line 24</a> </dt> </dl> </dd> <dt> <h4 class="name " id="cssFont"><span class="type-signature"></span>cssFont<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>Change the font used.</p> <p>This is equivalent of the <code>font</code> property specified to <a href="Phaser.Text.html#setStyle">setStyle</a>, except that unlike using <code>setStyle</code> this will not change any current font fill/color settings.</p> <p>The CSS font string can also be individually altered with the <code>font</code>, <code>fontSize</code>, <code>fontWeight</code>, <code>fontStyle</code>, and <code>fontVariant</code> properties.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1274">line 1274</a> </dt> </dl> </dd> <dt> <h4 class="name " id="damage"><span class="type-signature"></span>damage<span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Damages the Game Object. This removes the given amount of health from the <code>health</code> property.</p> <p>If health is taken below or is equal to zero then the <code>kill</code> method is called.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Health.html#damage">Phaser.Component.Health#damage</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Health.js.html">gameobjects/components/Health.js</a>, <a href="src_gameobjects_components_Health.js.html#sunlight-1-line-46">line 46</a> </dt> </dl> </dd> <dt> <h4 class="name " id="debug"><span class="type-signature"></span>debug<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>A debug flag designed for use with <code>Game.enableStep</code>.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#debug">Phaser.Component.Core#debug</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>false</li></ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-209">line 209</a> </dt> </dl> </dd> <dt> <h4 class="name " id="deltaX"><span class="type-signature">&lt;readonly> </span>deltaX<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>Returns the delta x value. The difference between world.x now and in the previous frame.</p> <p>The value will be positive if the Game Object has moved to the right or negative if to the left.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Delta.html#deltaX">Phaser.Component.Delta#deltaX</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Delta.js.html">gameobjects/components/Delta.js</a>, <a href="src_gameobjects_components_Delta.js.html#sunlight-1-line-24">line 24</a> </dt> </dl> </dd> <dt> <h4 class="name " id="deltaY"><span class="type-signature">&lt;readonly> </span>deltaY<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>Returns the delta y value. The difference between world.y now and in the previous frame.</p> <p>The value will be positive if the Game Object has moved down or negative if up.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Delta.html#deltaY">Phaser.Component.Delta#deltaY</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Delta.js.html">gameobjects/components/Delta.js</a>, <a href="src_gameobjects_components_Delta.js.html#sunlight-1-line-42">line 42</a> </dt> </dl> </dd> <dt> <h4 class="name " id="deltaZ"><span class="type-signature">&lt;readonly> </span>deltaZ<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>Returns the delta z value. The difference between rotation now and in the previous frame. The delta value.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Delta.html#deltaZ">Phaser.Component.Delta#deltaZ</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Delta.js.html">gameobjects/components/Delta.js</a>, <a href="src_gameobjects_components_Delta.js.html#sunlight-1-line-58">line 58</a> </dt> </dl> </dd> <dt> <h4 class="name " id="destroyPhase"><span class="type-signature">&lt;readonly> </span>destroyPhase<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>As a Game Object runs through its destroy method this flag is set to true, and can be checked in any sub-systems or plugins it is being destroyed from.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Destroy.html#destroyPhase">Phaser.Component.Destroy#destroyPhase</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Destroy.js.html">gameobjects/components/Destroy.js</a>, <a href="src_gameobjects_components_Destroy.js.html#sunlight-1-line-22">line 22</a> </dt> </dl> </dd> <dt> <h4 class="name " id="events"><span class="type-signature"></span>events<span class="type-signature"> :<a href="Phaser.Events.html">Phaser.Events</a></span></h4> </dt> <dd> <div class="description"> <p>All Phaser Game Objects have an Events class which contains all of the events that are dispatched when certain things happen to this Game Object, or any of its components.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#events">Phaser.Component.Core#events</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-176">line 176</a> </dt> <dt class="tag-see">See:</dt> <dd class="tag-see"> <ul> <li><a href="Phaser.Events.html">Phaser.Events</a></li> </ul> </dd> </dl> </dd> <dt> <h4 class="name " id="exists"><span class="type-signature"></span>exists<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>Controls if this Game Object is processed by the core game loop. If this Game Object has a physics body it also controls if its physics body is updated or not. When <code>exists</code> is set to <code>false</code> it will remove its physics body from the physics world if it has one. It also toggles the <code>visible</code> property to false as well.</p> <p>Setting <code>exists</code> to true will add its physics body back in to the physics world, if it has one. It will also set the <code>visible</code> property to <code>true</code>.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#exists">Phaser.Component.Core#exists</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-275">line 275</a> </dt> </dl> </dd> <dt> <h4 class="name " id="fill"><span class="type-signature"></span>fill<span class="type-signature"> :object</span></h4> </dt> <dd> <div class="description"> <p>A canvas fillstyle that will be used on the text eg 'red', '#00FF00'.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1440">line 1440</a> </dt> </dl> </dd> <dt> <h4 class="name " id="filterArea"><span class="type-signature"></span>filterArea<span class="type-signature"> :Rectangle</span></h4> </dt> <dd> <div class="description"> <p>The area the filter is applied to like the hitArea this is used as more of an optimisation rather than figuring out the dimensions of the displayObject each frame you can set this rectangle</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#filterArea">PIXI.DisplayObject#filterArea</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-183">line 183</a> </dt> </dl> </dd> <dt> <h4 class="name " id="filters"><span class="type-signature"></span>filters<span class="type-signature"> :Array.&lt;Filter></span></h4> </dt> <dd> <div class="description"> <p>Sets the filters for the displayObject. IMPORTANT: This is a webGL only feature and will be ignored by the canvas renderer. To remove filters simply set this property to 'null'</p> </div> <h5>Type:</h5> <ul> <li> <span class="param-type">Array.&lt;Filter></span> </li> </ul> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#filters">PIXI.DisplayObject#filters</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-328">line 328</a> </dt> </dl> </dd> <dt> <h4 class="name " id="fixedToCamera"><span class="type-signature"></span>fixedToCamera<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>A Game Object that is &quot;fixed&quot; to the camera uses its x/y coordinates as offsets from the top left of the camera during rendering.</p> <p>The values are adjusted at the rendering stage, overriding the Game Objects actual world position.</p> <p>The end result is that the Game Object will appear to be 'fixed' to the camera, regardless of where in the game world the camera is viewing. This is useful if for example this Game Object is a UI item that you wish to be visible at all times regardless where in the world the camera is.</p> <p>The offsets are stored in the <code>cameraOffset</code> property.</p> <p>Note that the <code>cameraOffset</code> values are in addition to any parent of this Game Object on the display list.</p> <p>Be careful not to set <code>fixedToCamera</code> on Game Objects which are in Groups that already have <code>fixedToCamera</code> enabled on them.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.FixedToCamera.html#fixedToCamera">Phaser.Component.FixedToCamera#fixedToCamera</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_FixedToCamera.js.html">gameobjects/components/FixedToCamera.js</a>, <a href="src_gameobjects_components_FixedToCamera.js.html#sunlight-1-line-56">line 56</a> </dt> </dl> </dd> <dt> <h4 class="name " id="font"><span class="type-signature"></span>font<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>Change the font family that the text will be rendered in, such as 'Arial'.</p> <p>Multiple CSS font families and generic fallbacks can be specified as long as <a href="http://www.w3.org/TR/CSS2/fonts.html#propdef-font-family">CSS font-family rules</a> are followed.</p> <p>To change the entire font string use <a href="Phaser.Text.html#cssFont">cssFont</a> instead: eg. <code>text.cssFont = 'bold 20pt Arial'</code>.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1300">line 1300</a> </dt> </dl> </dd> <dt> <h4 class="name " id="fontSize"><span class="type-signature"></span>fontSize<span class="type-signature"> :number|string</span></h4> </dt> <dd> <div class="description"> <p>The size of the font.</p> <p>If the font size is specified in pixels (eg. <code>32</code> or <code>'32px</code>') then a number (ie. <code>32</code>) representing the font size in pixels is returned; otherwise the value with CSS unit is returned as a string (eg. <code>'12pt'</code>).</p> </div> <h5>Type:</h5> <ul> <li> <span class="param-type">number</span> | <span class="param-type">string</span> </li> </ul> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1335">line 1335</a> </dt> </dl> </dd> <dt> <h4 class="name " id="fontStyle"><span class="type-signature"></span>fontStyle<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>The style of the font: 'normal', 'italic', 'oblique'</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1398">line 1398</a> </dt> </dl> </dd> <dt> <h4 class="name " id="fontVariant"><span class="type-signature"></span>fontVariant<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>The variant the font: 'normal', 'small-caps'</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1419">line 1419</a> </dt> </dl> </dd> <dt> <h4 class="name " id="fontWeight"><span class="type-signature"></span>fontWeight<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>The weight of the font: 'normal', 'bold', or <a href="http://www.w3.org/TR/CSS2/fonts.html#propdef-font-weight">a valid CSS font weight</a>.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1377">line 1377</a> </dt> </dl> </dd> <dt> <h4 class="name " id="frame"><span class="type-signature"></span>frame<span class="type-signature"> :integer</span></h4> </dt> <dd> <div class="description"> <p>Gets or sets the current frame index of the texture being used to render this Game Object.</p> <p>To change the frame set <code>frame</code> to the index of the new frame in the sprite sheet you wish this Game Object to use, for example: <code>player.frame = 4</code>.</p> <p>If the frame index given doesn't exist it will revert to the first frame found in the texture.</p> <p>If you are using a texture atlas then you should use the <code>frameName</code> property instead.</p> <p>If you wish to fully replace the texture being used see <code>loadTexture</code>.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.LoadTexture.html#frame">Phaser.Component.LoadTexture#frame</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_LoadTexture.js.html">gameobjects/components/LoadTexture.js</a>, <a href="src_gameobjects_components_LoadTexture.js.html#sunlight-1-line-218">line 218</a> </dt> </dl> </dd> <dt> <h4 class="name " id="frameName"><span class="type-signature"></span>frameName<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>Gets or sets the current frame name of the texture being used to render this Game Object.</p> <p>To change the frame set <code>frameName</code> to the name of the new frame in the texture atlas you wish this Game Object to use, for example: <code>player.frameName = &quot;idle&quot;</code>.</p> <p>If the frame name given doesn't exist it will revert to the first frame found in the texture and throw a console warning.</p> <p>If you are using a sprite sheet then you should use the <code>frame</code> property instead.</p> <p>If you wish to fully replace the texture being used see <code>loadTexture</code>.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.LoadTexture.html#frameName">Phaser.Component.LoadTexture#frameName</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_LoadTexture.js.html">gameobjects/components/LoadTexture.js</a>, <a href="src_gameobjects_components_LoadTexture.js.html#sunlight-1-line-243">line 243</a> </dt> </dl> </dd> <dt> <h4 class="name " id="fresh"><span class="type-signature">&lt;readonly> </span>fresh<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>A Game Object is considered <code>fresh</code> if it has just been created or reset and is yet to receive a renderer transform update. This property is mostly used internally by the physics systems, but is exposed for the use of plugins.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#fresh">Phaser.Component.Core#fresh</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-239">line 239</a> </dt> </dl> </dd> <dt> <h4 class="name " id="game"><span class="type-signature"></span>game<span class="type-signature"> :<a href="Phaser.Game.html">Phaser.Game</a></span></h4> </dt> <dd> <div class="description"> <p>A reference to the currently running Game.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#game">Phaser.Component.Core#game</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-145">line 145</a> </dt> </dl> </dd> <dt> <h4 class="name " id="heal"><span class="type-signature"></span>heal<span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Heal the Game Object. This adds the given amount of health to the <code>health</code> property.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Health.html#heal">Phaser.Component.Health#heal</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Health.js.html">gameobjects/components/Health.js</a>, <a href="src_gameobjects_components_Health.js.html#sunlight-1-line-69">line 69</a> </dt> </dl> </dd> <dt> <h4 class="name " id="health"><span class="type-signature"></span>health<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The Game Objects health value. This is a handy property for setting and manipulating health on a Game Object.</p> <p>It can be used in combination with the <code>damage</code> method or modified directly.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Health.html#health">Phaser.Component.Health#health</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>1</li></ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Health.js.html">gameobjects/components/Health.js</a>, <a href="src_gameobjects_components_Health.js.html#sunlight-1-line-26">line 26</a> </dt> </dl> </dd> <dt> <h4 class="name " id="height"><span class="type-signature"></span>height<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The height of the Text. Setting this will modify the scale to achieve the value requested.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1856">line 1856</a> </dt> </dl> </dd> <dt> <h4 class="name " id="hitArea"><span class="type-signature"></span>hitArea<span class="type-signature"> :Rectangle|Circle|Ellipse|Polygon</span></h4> </dt> <dd> <div class="description"> <p>This is the defined area that will pick up mouse / touch events. It is null by default. Setting it is a neat way of optimising the hitTest function that the interactionManager will use (as it will not need to hit test all the children)</p> </div> <h5>Type:</h5> <ul> <li> <span class="param-type">Rectangle</span> | <span class="param-type">Circle</span> | <span class="param-type">Ellipse</span> | <span class="param-type">Polygon</span> </li> </ul> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#hitArea">PIXI.DisplayObject#hitArea</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-81">line 81</a> </dt> </dl> </dd> <dt> <h4 class="name " id="inCamera"><span class="type-signature">&lt;readonly> </span>inCamera<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>Checks if this Game Objects bounds intersects with the Game Cameras bounds.</p> <p>It will be <code>true</code> if they intersect, or <code>false</code> if the Game Object is fully outside of the Cameras bounds.</p> <p>An object outside the bounds can be considered for camera culling if it has the AutoCull component.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.InCamera.html#inCamera">Phaser.Component.InCamera#inCamera</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_InCamera.js.html">gameobjects/components/InCamera.js</a>, <a href="src_gameobjects_components_InCamera.js.html#sunlight-1-line-26">line 26</a> </dt> </dl> </dd> <dt> <h4 class="name " id="inCamera"><span class="type-signature">&lt;readonly> </span>inCamera<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>Checks if the Game Objects bounds intersect with the Game Camera bounds. Returns <code>true</code> if they do, otherwise <code>false</code> if fully outside of the Cameras bounds.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.AutoCull.html#inCamera">Phaser.Component.AutoCull#inCamera</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_AutoCull.js.html">gameobjects/components/AutoCull.js</a>, <a href="src_gameobjects_components_AutoCull.js.html#sunlight-1-line-37">line 37</a> </dt> </dl> </dd> <dt> <h4 class="name " id="input"><span class="type-signature"></span>input<span class="type-signature"> :<a href="Phaser.InputHandler.html">Phaser.InputHandler</a>|null</span></h4> </dt> <dd> <div class="description"> <p>The Input Handler for this Game Object.</p> <p>By default it is disabled. If you wish this Game Object to process input events you should enable it with: <code>inputEnabled = true</code>.</p> <p>After you have done this, this property will be a reference to the Phaser InputHandler.</p> </div> <h5>Type:</h5> <ul> <li> <span class="param-type"><a href="Phaser.InputHandler.html">Phaser.InputHandler</a></span> | <span class="param-type">null</span> </li> </ul> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.InputEnabled.html#input">Phaser.Component.InputEnabled#input</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_InputEnabled.js.html">gameobjects/components/InputEnabled.js</a>, <a href="src_gameobjects_components_InputEnabled.js.html#sunlight-1-line-24">line 24</a> </dt> </dl> </dd> <dt> <h4 class="name " id="inputEnabled"><span class="type-signature"></span>inputEnabled<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>By default a Game Object won't process any input events. By setting <code>inputEnabled</code> to true a Phaser.InputHandler is created for this Game Object and it will then start to process click / touch events and more.</p> <p>You can then access the Input Handler via <code>this.input</code>.</p> <p>Note that Input related events are dispatched from <code>this.events</code>, i.e.: <code>events.onInputDown</code>.</p> <p>If you set this property to false it will stop the Input Handler from processing any more input events.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.InputEnabled.html#inputEnabled">Phaser.Component.InputEnabled#inputEnabled</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_InputEnabled.js.html">gameobjects/components/InputEnabled.js</a>, <a href="src_gameobjects_components_InputEnabled.js.html#sunlight-1-line-38">line 38</a> </dt> </dl> </dd> <dt> <h4 class="name " id="inWorld"><span class="type-signature">&lt;readonly> </span>inWorld<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>Checks if the Game Objects bounds are within, or intersect at any point with the Game World bounds.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.InWorld.html#inWorld">Phaser.Component.InWorld#inWorld</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_InWorld.js.html">gameobjects/components/InWorld.js</a>, <a href="src_gameobjects_components_InWorld.js.html#sunlight-1-line-114">line 114</a> </dt> </dl> </dd> <dt> <h4 class="name " id="key"><span class="type-signature"></span>key<span class="type-signature"> :string|<a href="Phaser.RenderTexture.html">Phaser.RenderTexture</a>|<a href="Phaser.BitmapData.html">Phaser.BitmapData</a>|<a href="Phaser.Video.html">Phaser.Video</a>|<a href="PIXI.Texture.html">PIXI.Texture</a></span></h4> </dt> <dd> <div class="description"> <p>The key of the image or texture used by this Game Object during rendering. If it is a string it's the string used to retrieve the texture from the Phaser Image Cache. It can also be an instance of a RenderTexture, BitmapData, Video or PIXI.Texture. If a Game Object is created without a key it is automatically assigned the key <code>__default</code> which is a 32x32 transparent PNG stored within the Cache. If a Game Object is given a key which doesn't exist in the Image Cache it is re-assigned the key <code>__missing</code> which is a 32x32 PNG of a green box with a line through it.</p> </div> <h5>Type:</h5> <ul> <li> <span class="param-type">string</span> | <span class="param-type"><a href="Phaser.RenderTexture.html">Phaser.RenderTexture</a></span> | <span class="param-type"><a href="Phaser.BitmapData.html">Phaser.BitmapData</a></span> | <span class="param-type"><a href="Phaser.Video.html">Phaser.Video</a></span> | <span class="param-type"><a href="PIXI.Texture.html">PIXI.Texture</a></span> </li> </ul> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#key">Phaser.Component.Core#key</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-194">line 194</a> </dt> </dl> </dd> <dt> <h4 class="name " id="left"><span class="type-signature">&lt;readonly> </span>left<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The left coordinate of the Game Object. This is the same as <code>x - offsetX</code>.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Bounds.html#left">Phaser.Component.Bounds#left</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Bounds.js.html">gameobjects/components/Bounds.js</a>, <a href="src_gameobjects_components_Bounds.js.html#sunlight-1-line-59">line 59</a> </dt> </dl> </dd> <dt> <h4 class="name " id="lifespan"><span class="type-signature"></span>lifespan<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The lifespan allows you to give a Game Object a lifespan in milliseconds.</p> <p>Once the Game Object is 'born' you can set this to a positive value.</p> <p>It is automatically decremented by the millisecond equivalent of <code>game.time.physicsElapsed</code> each frame. When it reaches zero it will call the <code>kill</code> method.</p> <p>Very handy for particles, bullets, collectibles, or any other short-lived entity.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.LifeSpan.html#lifespan">Phaser.Component.LifeSpan#lifespan</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>0</li></ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_LifeSpan.js.html">gameobjects/components/LifeSpan.js</a>, <a href="src_gameobjects_components_LifeSpan.js.html#sunlight-1-line-65">line 65</a> </dt> </dl> </dd> <dt> <h4 class="name " id="lineSpacing"><span class="type-signature"></span>lineSpacing<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>Additional spacing (in pixels) between each line of text if multi-line.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1672">line 1672</a> </dt> </dl> </dd> <dt> <h4 class="name " id="mask"><span class="type-signature"></span>mask<span class="type-signature"> :<a href="PIXI.Graphics.html">PIXI.Graphics</a></span></h4> </dt> <dd> <div class="description"> <p>Sets a mask for the displayObject. A mask is an object that limits the visibility of an object to the shape of the mask applied to it. In PIXI a regular mask must be a PIXI.Graphics object. This allows for much faster masking in canvas as it utilises shape clipping. To remove a mask, set this property to null.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#mask">PIXI.DisplayObject#mask</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-303">line 303</a> </dt> </dl> </dd> <dt> <h4 class="name " id="maxHealth"><span class="type-signature"></span>maxHealth<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The Game Objects maximum health value. This works in combination with the <code>heal</code> method to ensure the health value never exceeds the maximum.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Health.html#maxHealth">Phaser.Component.Health#maxHealth</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>100</li></ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Health.js.html">gameobjects/components/Health.js</a>, <a href="src_gameobjects_components_Health.js.html#sunlight-1-line-35">line 35</a> </dt> </dl> </dd> <dt> <h4 class="name " id="name"><span class="type-signature"></span>name<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>A user defined name given to this Game Object. This value isn't ever used internally by Phaser, it is meant as a game level property.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#name">Phaser.Component.Core#name</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-153">line 153</a> </dt> </dl> </dd> <dt> <h4 class="name " id="offsetX"><span class="type-signature">&lt;readonly> </span>offsetX<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The amount the Game Object is visually offset from its x coordinate. This is the same as <code>width * anchor.x</code>. It will only be &gt; 0 if anchor.x is not equal to zero.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Bounds.html#offsetX">Phaser.Component.Bounds#offsetX</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Bounds.js.html">gameobjects/components/Bounds.js</a>, <a href="src_gameobjects_components_Bounds.js.html#sunlight-1-line-24">line 24</a> </dt> </dl> </dd> <dt> <h4 class="name " id="offsetY"><span class="type-signature">&lt;readonly> </span>offsetY<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The amount the Game Object is visually offset from its y coordinate. This is the same as <code>height * anchor.y</code>. It will only be &gt; 0 if anchor.y is not equal to zero.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Bounds.html#offsetY">Phaser.Component.Bounds#offsetY</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Bounds.js.html">gameobjects/components/Bounds.js</a>, <a href="src_gameobjects_components_Bounds.js.html#sunlight-1-line-42">line 42</a> </dt> </dl> </dd> <dt> <h4 class="name " id="outOfBoundsKill"><span class="type-signature"></span>outOfBoundsKill<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>If this and the <code>checkWorldBounds</code> property are both set to <code>true</code> then the <code>kill</code> method is called as soon as <code>inWorld</code> returns false.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.InWorld.html#outOfBoundsKill">Phaser.Component.InWorld#outOfBoundsKill</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>false</li></ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_InWorld.js.html">gameobjects/components/InWorld.js</a>, <a href="src_gameobjects_components_InWorld.js.html#sunlight-1-line-100">line 100</a> </dt> </dl> </dd> <dt> <h4 class="name " id="padding"><span class="type-signature"></span>padding<span class="type-signature"> :<a href="Phaser.Point.html">Phaser.Point</a></span></h4> </dt> <dd> <div class="description"> <p>Specify a padding value which is added to the line width and height when calculating the Text size. ALlows you to add extra spacing if Phaser is unable to accurately determine the true font dimensions.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-63">line 63</a> </dt> </dl> </dd> <dt> <h4 class="name " id="parent"><span class="type-signature">&lt;readonly> </span>parent<span class="type-signature"> :<a href="PIXI.DisplayObjectContainer.html">PIXI.DisplayObjectContainer</a></span></h4> </dt> <dd> <div class="description"> <p>[read-only] The display object container that contains this display object.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#parent">PIXI.DisplayObject#parent</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-98">line 98</a> </dt> </dl> </dd> <dt> <h4 class="name " id="pendingDestroy"><span class="type-signature"></span>pendingDestroy<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>A Game Object is that is pendingDestroy is flagged to have its destroy method called on the next logic update. You can set it directly to allow you to flag an object to be destroyed on its next update.</p> <p>This is extremely useful if you wish to destroy an object from within one of its own callbacks such as with Buttons or other Input events.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#pendingDestroy">Phaser.Component.Core#pendingDestroy</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-250">line 250</a> </dt> </dl> </dd> <dt> <h4 class="name " id="physicsType"><span class="type-signature">&lt;readonly> </span>physicsType<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The const physics body type of this object.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-56">line 56</a> </dt> </dl> </dd> <dt> <h4 class="name " id="pivot"><span class="type-signature"></span>pivot<span class="type-signature"> :Point</span></h4> </dt> <dd> <div class="description"> <p>The pivot point of the displayObject that it rotates around</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#pivot">PIXI.DisplayObject#pivot</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-49">line 49</a> </dt> </dl> </dd> <dt> <h4 class="name " id="position"><span class="type-signature"></span>position<span class="type-signature"> :Point</span></h4> </dt> <dd> <div class="description"> <p>The coordinate of the object relative to the local coordinates of the parent.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#position">PIXI.DisplayObject#position</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-14">line 14</a> </dt> </dl> </dd> <dt> <h4 class="name " id="previousPosition"><span class="type-signature">&lt;readonly> </span>previousPosition<span class="type-signature"> :<a href="Phaser.Point.html">Phaser.Point</a></span></h4> </dt> <dd> <div class="description"> <p>The position the Game Object was located in the previous frame.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#previousPosition">Phaser.Component.Core#previousPosition</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-216">line 216</a> </dt> </dl> </dd> <dt> <h4 class="name " id="previousRotation"><span class="type-signature">&lt;readonly> </span>previousRotation<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The rotation the Game Object was in set to in the previous frame. Value is in radians.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#previousRotation">Phaser.Component.Core#previousRotation</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-223">line 223</a> </dt> </dl> </dd> <dt> <h4 class="name " id="renderable"><span class="type-signature"></span>renderable<span class="type-signature"> :Boolean</span></h4> </dt> <dd> <div class="description"> <p>Can this object be rendered</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#renderable">PIXI.DisplayObject#renderable</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-90">line 90</a> </dt> </dl> </dd> <dt> <h4 class="name " id="renderOrderID"><span class="type-signature">&lt;readonly> </span>renderOrderID<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The render order ID is used internally by the renderer and Input Manager and should not be modified. This property is mostly used internally by the renderers, but is exposed for the use of plugins.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#renderOrderID">Phaser.Component.Core#renderOrderID</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-231">line 231</a> </dt> </dl> </dd> <dt> <h4 class="name " id="resolution"><span class="type-signature"></span>resolution<span class="type-signature"> :integer</span></h4> </dt> <dd> <div class="description"> <p>The resolution of the canvas the text is rendered to. This defaults to match the resolution of the renderer, but can be changed on a per Text object basis.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1487">line 1487</a> </dt> </dl> </dd> <dt> <h4 class="name " id="right"><span class="type-signature">&lt;readonly> </span>right<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The right coordinate of the Game Object. This is the same as <code>x + width - offsetX</code>.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Bounds.html#right">Phaser.Component.Bounds#right</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Bounds.js.html">gameobjects/components/Bounds.js</a>, <a href="src_gameobjects_components_Bounds.js.html#sunlight-1-line-76">line 76</a> </dt> </dl> </dd> <dt> <h4 class="name " id="rotation"><span class="type-signature"></span>rotation<span class="type-signature"> :Number</span></h4> </dt> <dd> <div class="description"> <p>The rotation of the object in radians.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#rotation">PIXI.DisplayObject#rotation</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-57">line 57</a> </dt> </dl> </dd> <dt> <h4 class="name " id="scale"><span class="type-signature"></span>scale<span class="type-signature"> :Point</span></h4> </dt> <dd> <div class="description"> <p>The scale factor of the object.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#scale">PIXI.DisplayObject#scale</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-22">line 22</a> </dt> </dl> </dd> <dt> <h4 class="name " id="scaleMax"><span class="type-signature"></span>scaleMax<span class="type-signature"> :<a href="Phaser.Point.html">Phaser.Point</a></span></h4> </dt> <dd> <div class="description"> <p>The maximum scale this Game Object will scale up to. </p> <p>It allows you to prevent a parent from scaling this Game Object higher than the given value.</p> <p>Set it to <code>null</code> to remove the limit.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.ScaleMinMax.html#scaleMax">Phaser.Component.ScaleMinMax#scaleMax</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_ScaleMinMax.js.html">gameobjects/components/ScaleMinMax.js</a>, <a href="src_gameobjects_components_ScaleMinMax.js.html#sunlight-1-line-46">line 46</a> </dt> </dl> </dd> <dt> <h4 class="name " id="scaleMin"><span class="type-signature"></span>scaleMin<span class="type-signature"> :<a href="Phaser.Point.html">Phaser.Point</a></span></h4> </dt> <dd> <div class="description"> <p>The minimum scale this Game Object will scale down to.</p> <p>It allows you to prevent a parent from scaling this Game Object lower than the given value.</p> <p>Set it to <code>null</code> to remove the limit.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.ScaleMinMax.html#scaleMin">Phaser.Component.ScaleMinMax#scaleMin</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_ScaleMinMax.js.html">gameobjects/components/ScaleMinMax.js</a>, <a href="src_gameobjects_components_ScaleMinMax.js.html#sunlight-1-line-36">line 36</a> </dt> </dl> </dd> <dt> <h4 class="name " id="shader"><span class="type-signature"></span>shader<span class="type-signature"> :<a href="PIXI.AbstractFilter.html">PIXI.AbstractFilter</a></span></h4> </dt> <dd> <div class="description"> <p>The shader that will be used to render the texture to the stage. Set to null to remove a current shader.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.Sprite.html#shader">PIXI.Sprite#shader</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>null</li></ul></dd> <dt class="tag-source">Source - <a href="src_pixi_display_Sprite.js.html">pixi/display/Sprite.js</a>, <a href="src_pixi_display_Sprite.js.html#sunlight-1-line-96">line 96</a> </dt> </dl> </dd> <dt> <h4 class="name " id="shadowBlur"><span class="type-signature"></span>shadowBlur<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The shadowBlur value. Make the shadow softer by applying a Gaussian blur to it. A number from 0 (no blur) up to approx. 10 (depending on scene).</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1765">line 1765</a> </dt> </dl> </dd> <dt> <h4 class="name " id="shadowColor"><span class="type-signature"></span>shadowColor<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>The color of the shadow, as given in CSS rgba format. Set the alpha component to 0 to disable the shadow.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1743">line 1743</a> </dt> </dl> </dd> <dt> <h4 class="name " id="shadowFill"><span class="type-signature"></span>shadowFill<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>Sets if the drop shadow is applied to the Text fill.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1809">line 1809</a> </dt> </dl> </dd> <dt> <h4 class="name " id="shadowOffsetX"><span class="type-signature"></span>shadowOffsetX<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The shadowOffsetX value in pixels. This is how far offset horizontally the shadow effect will be.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1699">line 1699</a> </dt> </dl> </dd> <dt> <h4 class="name " id="shadowOffsetY"><span class="type-signature"></span>shadowOffsetY<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The shadowOffsetY value in pixels. This is how far offset vertically the shadow effect will be.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1721">line 1721</a> </dt> </dl> </dd> <dt> <h4 class="name " id="shadowStroke"><span class="type-signature"></span>shadowStroke<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>Sets if the drop shadow is applied to the Text stroke.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1787">line 1787</a> </dt> </dl> </dd> <dt> <h4 class="name " id="smoothed"><span class="type-signature"></span>smoothed<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>Enable or disable texture smoothing for this Game Object.</p> <p>It only takes effect if the Game Object is using an image based texture.</p> <p>Smoothing is enabled by default.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Smoothed.html#smoothed">Phaser.Component.Smoothed#smoothed</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Smoothed.js.html">gameobjects/components/Smoothed.js</a>, <a href="src_gameobjects_components_Smoothed.js.html#sunlight-1-line-25">line 25</a> </dt> </dl> </dd> <dt> <h4 class="name " id="stage"><span class="type-signature">&lt;readonly> </span>stage<span class="type-signature"> :<a href="PIXI.Stage.html">PIXI.Stage</a></span></h4> </dt> <dd> <div class="description"> <p>[read-only] The stage the display object is connected to, or undefined if it is not connected to the stage.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#stage">PIXI.DisplayObject#stage</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-107">line 107</a> </dt> </dl> </dd> <dt> <h4 class="name " id="stroke"><span class="type-signature"></span>stroke<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>A canvas fillstyle that will be used on the text stroke eg 'blue', '#FCFF00'.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1584">line 1584</a> </dt> </dl> </dd> <dt> <h4 class="name " id="strokeColors"><span class="type-signature"></span>strokeColors<span class="type-signature"> :array</span></h4> </dt> <dd> <div class="description"> <p>An array of the stroke color values as specified by <a href="Phaser.Text.html#addStrokeColor">addStrokeColor</a>.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-91">line 91</a> </dt> </dl> </dd> <dt> <h4 class="name " id="strokeThickness"><span class="type-signature"></span>strokeThickness<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>A number that represents the thickness of the stroke. Default is 0 (no stroke)</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1606">line 1606</a> </dt> </dl> </dd> <dt> <h4 class="name " id="tabs"><span class="type-signature"></span>tabs<span class="type-signature"> :integer|array</span></h4> </dt> <dd> <div class="description"> <p>The size (in pixels) of the tabs, for when text includes tab characters. 0 disables. Can be an integer or an array of varying tab sizes, one tab per element. For example if you set tabs to 100 then when Text encounters a tab it will jump ahead 100 pixels. If you set tabs to be <code>[100,200]</code> then it will set the first tab at 100px and the second at 200px.</p> </div> <h5>Type:</h5> <ul> <li> <span class="param-type">integer</span> | <span class="param-type">array</span> </li> </ul> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1511">line 1511</a> </dt> </dl> </dd> <dt> <h4 class="name " id="text"><span class="type-signature"></span>text<span class="type-signature"> :string</span></h4> </dt> <dd> <div class="description"> <p>The text to be displayed by this Text object. Use a \n to insert a carriage return and split the text. The text will be rendered with any style currently set.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1243">line 1243</a> </dt> </dl> </dd> <dt> <h4 class="name " id="textBounds"><span class="type-signature">&lt;readonly> </span>textBounds<span class="type-signature"> :<a href="Phaser.Rectangle.html">Phaser.Rectangle</a></span></h4> </dt> <dd> <div class="description"> <p>The textBounds property allows you to specify a rectangular region upon which text alignment is based. See <code>Text.setTextBounds</code> for more details.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-71">line 71</a> </dt> </dl> </dd> <dt> <h4 class="name " id="texture"><span class="type-signature"></span>texture<span class="type-signature"> :<a href="PIXI.Texture.html">PIXI.Texture</a></span></h4> </dt> <dd> <div class="description"> <p>The texture that the sprite is using</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.Sprite.html#texture">PIXI.Sprite#texture</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_Sprite.js.html">pixi/display/Sprite.js</a>, <a href="src_pixi_display_Sprite.js.html#sunlight-1-line-33">line 33</a> </dt> </dl> </dd> <dt> <h4 class="name " id="tint"><span class="type-signature"></span>tint<span class="type-signature"> :Number</span></h4> </dt> <dd> <div class="description"> <p>The tint applied to the sprite. This is a hex value. A value of 0xFFFFFF will remove any tint effect.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.Sprite.html#tint">PIXI.Sprite#tint</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>0xFFFFFF</li></ul></dd> <dt class="tag-source">Source - <a href="src_pixi_display_Sprite.js.html">pixi/display/Sprite.js</a>, <a href="src_pixi_display_Sprite.js.html#sunlight-1-line-59">line 59</a> </dt> </dl> </dd> <dt> <h4 class="name " id="tintedTexture"><span class="type-signature"></span>tintedTexture<span class="type-signature"> :Canvas</span></h4> </dt> <dd> <div class="description"> <p>A canvas that contains the tinted version of the Sprite (in Canvas mode, WebGL doesn't populate this)</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.Sprite.html#tintedTexture">PIXI.Sprite#tintedTexture</a> </li></dd> <dt class="tag-default">Default Value:</dt> <dd class="tag-default"><ul class="dummy"><li>null</li></ul></dd> <dt class="tag-source">Source - <a href="src_pixi_display_Sprite.js.html">pixi/display/Sprite.js</a>, <a href="src_pixi_display_Sprite.js.html#sunlight-1-line-78">line 78</a> </dt> </dl> </dd> <dt> <h4 class="name " id="top"><span class="type-signature">&lt;readonly> </span>top<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The y coordinate of the Game Object. This is the same as <code>y - offsetY</code>.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Bounds.html#top">Phaser.Component.Bounds#top</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Bounds.js.html">gameobjects/components/Bounds.js</a>, <a href="src_gameobjects_components_Bounds.js.html#sunlight-1-line-93">line 93</a> </dt> </dl> </dd> <dt> <h4 class="name " id="transformCallback"><span class="type-signature"></span>transformCallback<span class="type-signature"> :function</span></h4> </dt> <dd> <div class="description"> <p>The transform callback is an optional callback that if set will be called at the end of the updateTransform method and sent two parameters: This Display Objects worldTransform matrix and its parents transform matrix. Both are PIXI.Matrix object types. The matrix are passed by reference and can be modified directly without needing to return them. This ability allows you to check any of the matrix values and perform actions such as clamping scale or limiting rotation, regardless of the parent transforms.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#transformCallback">PIXI.DisplayObject#transformCallback</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-30">line 30</a> </dt> </dl> </dd> <dt> <h4 class="name " id="transformCallback"><span class="type-signature"></span>transformCallback<span class="type-signature"> :function</span></h4> </dt> <dd> <div class="description"> <p>The callback that will apply any scale limiting to the worldTransform.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.ScaleMinMax.html#transformCallback">Phaser.Component.ScaleMinMax#transformCallback</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_ScaleMinMax.js.html">gameobjects/components/ScaleMinMax.js</a>, <a href="src_gameobjects_components_ScaleMinMax.js.html#sunlight-1-line-20">line 20</a> </dt> </dl> </dd> <dt> <h4 class="name " id="transformCallbackContext"><span class="type-signature"></span>transformCallbackContext<span class="type-signature"> :object</span></h4> </dt> <dd> <div class="description"> <p>The context under which <code>transformCallback</code> is called.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.ScaleMinMax.html#transformCallbackContext">Phaser.Component.ScaleMinMax#transformCallbackContext</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_ScaleMinMax.js.html">gameobjects/components/ScaleMinMax.js</a>, <a href="src_gameobjects_components_ScaleMinMax.js.html#sunlight-1-line-26">line 26</a> </dt> </dl> </dd> <dt> <h4 class="name " id="transformCallbackContext"><span class="type-signature"></span>transformCallbackContext<span class="type-signature"> :Object</span></h4> </dt> <dd> <div class="description"> <p>The context under which the transformCallback is invoked.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#transformCallbackContext">PIXI.DisplayObject#transformCallbackContext</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-41">line 41</a> </dt> </dl> </dd> <dt> <h4 class="name " id="type"><span class="type-signature"></span>type<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The const type of this object.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-50">line 50</a> </dt> </dl> </dd> <dt> <h4 class="name " id="visible"><span class="type-signature"></span>visible<span class="type-signature"> :Boolean</span></h4> </dt> <dd> <div class="description"> <p>The visibility of the object.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#visible">PIXI.DisplayObject#visible</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-73">line 73</a> </dt> </dl> </dd> <dt> <h4 class="name " id="width"><span class="type-signature"></span>width<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The width of the Text. Setting this will modify the scale to achieve the value requested.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1831">line 1831</a> </dt> </dl> </dd> <dt> <h4 class="name " id="wordWrap"><span class="type-signature"></span>wordWrap<span class="type-signature"> :boolean</span></h4> </dt> <dd> <div class="description"> <p>Indicates if word wrap should be used.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1628">line 1628</a> </dt> </dl> </dd> <dt> <h4 class="name " id="wordWrapWidth"><span class="type-signature"></span>wordWrapWidth<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The width at which text will wrap.</p> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1650">line 1650</a> </dt> </dl> </dd> <dt> <h4 class="name " id="world"><span class="type-signature"></span>world<span class="type-signature"> :<a href="Phaser.Point.html">Phaser.Point</a></span></h4> </dt> <dd> <div class="description"> <p>The world coordinates of this Game Object in pixels. Depending on where in the display list this Game Object is placed this value can differ from <code>position</code>, which contains the x/y coordinates relative to the Game Objects parent.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#world">Phaser.Component.Core#world</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-202">line 202</a> </dt> </dl> </dd> <dt> <h4 class="name " id="worldAlpha"><span class="type-signature">&lt;readonly> </span>worldAlpha<span class="type-signature"> :Number</span></h4> </dt> <dd> <div class="description"> <p>[read-only] The multiplied alpha of the displayObject</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#worldAlpha">PIXI.DisplayObject#worldAlpha</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-116">line 116</a> </dt> </dl> </dd> <dt> <h4 class="name " id="worldPosition"><span class="type-signature">&lt;readonly> </span>worldPosition<span class="type-signature"> :Point</span></h4> </dt> <dd> <div class="description"> <p>The position of the Display Object based on the world transform. This value is updated at the end of updateTransform and takes all parent transforms into account.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#worldPosition">PIXI.DisplayObject#worldPosition</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-135">line 135</a> </dt> </dl> </dd> <dt> <h4 class="name " id="worldRotation"><span class="type-signature">&lt;readonly> </span>worldRotation<span class="type-signature"> :Number</span></h4> </dt> <dd> <div class="description"> <p>The rotation of the Display Object, in radians, based on the world transform. This value is updated at the end of updateTransform and takes all parent transforms into account.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#worldRotation">PIXI.DisplayObject#worldRotation</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-155">line 155</a> </dt> </dl> </dd> <dt> <h4 class="name " id="worldScale"><span class="type-signature">&lt;readonly> </span>worldScale<span class="type-signature"> :Point</span></h4> </dt> <dd> <div class="description"> <p>The scale of the Display Object based on the world transform. This value is updated at the end of updateTransform and takes all parent transforms into account.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#worldScale">PIXI.DisplayObject#worldScale</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-145">line 145</a> </dt> </dl> </dd> <dt> <h4 class="name " id="worldVisible"><span class="type-signature"></span>worldVisible<span class="type-signature"> :Boolean</span></h4> </dt> <dd> <div class="description"> <p>[read-only] Indicates if the sprite is globally visible.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#worldVisible">PIXI.DisplayObject#worldVisible</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-279">line 279</a> </dt> </dl> </dd> <dt> <h4 class="name " id="x"><span class="type-signature"></span>x<span class="type-signature"> :Number</span></h4> </dt> <dd> <div class="description"> <p>The position of the displayObject on the x axis relative to the local coordinates of the parent.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#x">PIXI.DisplayObject#x</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-726">line 726</a> </dt> </dl> </dd> <dt> <h4 class="name " id="x"><span class="type-signature"></span>x<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The position of the Game Object on the x axis relative to the local coordinates of the parent.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.PhysicsBody.html#x">Phaser.Component.PhysicsBody#x</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_PhysicsBody.js.html">gameobjects/components/PhysicsBody.js</a>, <a href="src_gameobjects_components_PhysicsBody.js.html#sunlight-1-line-98">line 98</a> </dt> </dl> </dd> <dt> <h4 class="name " id="y"><span class="type-signature"></span>y<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The position of the Game Object on the y axis relative to the local coordinates of the parent.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.PhysicsBody.html#y">Phaser.Component.PhysicsBody#y</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_PhysicsBody.js.html">gameobjects/components/PhysicsBody.js</a>, <a href="src_gameobjects_components_PhysicsBody.js.html#sunlight-1-line-124">line 124</a> </dt> </dl> </dd> <dt> <h4 class="name " id="y"><span class="type-signature"></span>y<span class="type-signature"> :Number</span></h4> </dt> <dd> <div class="description"> <p>The position of the displayObject on the y axis relative to the local coordinates of the parent.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#y">PIXI.DisplayObject#y</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-744">line 744</a> </dt> </dl> </dd> <dt> <h4 class="name " id="z"><span class="type-signature"></span>z<span class="type-signature"> :number</span></h4> </dt> <dd> <div class="description"> <p>The z depth of this Game Object within its parent Group. No two objects in a Group can have the same z value. This value is adjusted automatically whenever the Group hierarchy changes.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#z">Phaser.Component.Core#z</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-168">line 168</a> </dt> </dl> </dd> </dl> <h3 class="subsection-title">Methods</h3> <dl> <dt> <h4 class="name " id="addChild"><span class="type-signature"></span>addChild<span class="signature">(child)</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Adds a child to the container.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>child</code></td> <td class="type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> </td> <td class="description last"><p>The DisplayObject to add to the container</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>The child that was added.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#addChild">PIXI.DisplayObjectContainer#addChild</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-91">line 91</a> </dt> </dl> </dd> <dt> <h4 class="name " id="addChildAt"><span class="type-signature"></span>addChildAt<span class="signature">(child, index)</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Adds a child to the container at a specified index. If the index is out of bounds an error will be thrown</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>child</code></td> <td class="type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> </td> <td class="description last"><p>The child to add</p></td> </tr> <tr> <td class="name"><code>index</code></td> <td class="type"> <span class="param-type">Number</span> </td> <td class="description last"><p>The index to place the child in</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>The child that was added.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#addChildAt">PIXI.DisplayObjectContainer#addChildAt</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-103">line 103</a> </dt> </dl> </dd> <dt> <h4 class="name " id="addColor"><span class="type-signature"></span>addColor<span class="signature">(color, position)</span><span class="type-signature"> &rarr; {<a href="Phaser.Text.html">Phaser.Text</a>}</span></h4> </dt> <dd> <div class="description"> <p>Set specific colors for certain characters within the Text.</p> <p>It works by taking a color value, which is a typical HTML string such as <code>#ff0000</code> or <code>rgb(255,0,0)</code> and a position. The position value is the index of the character in the Text string to start applying this color to. Once set the color remains in use until either another color or the end of the string is encountered. For example if the Text was <code>Photon Storm</code> and you did <code>Text.addColor('#ffff00', 6)</code> it would color in the word <code>Storm</code> in yellow.</p> <p>If you wish to change the stroke color see addStrokeColor instead.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>color</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="description last"><p>A canvas fillstyle that will be used on the text eg <code>red</code>, <code>#00FF00</code>, <code>rgba()</code>.</p></td> </tr> <tr> <td class="name"><code>position</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="description last"><p>The index of the character in the string to start applying this color value from.</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="Phaser.Text.html">Phaser.Text</a></span> - </div> <div class="returns-desc param-desc"> <p>This Text instance.</p> </div> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-662">line 662</a> </dt> </dl> </dd> <dt> <h4 class="name " id="addStrokeColor"><span class="type-signature"></span>addStrokeColor<span class="signature">(color, position)</span><span class="type-signature"> &rarr; {<a href="Phaser.Text.html">Phaser.Text</a>}</span></h4> </dt> <dd> <div class="description"> <p>Set specific stroke colors for certain characters within the Text.</p> <p>It works by taking a color value, which is a typical HTML string such as <code>#ff0000</code> or <code>rgb(255,0,0)</code> and a position. The position value is the index of the character in the Text string to start applying this color to. Once set the color remains in use until either another color or the end of the string is encountered. For example if the Text was <code>Photon Storm</code> and you did <code>Text.addColor('#ffff00', 6)</code> it would color in the word <code>Storm</code> in yellow.</p> <p>This has no effect if stroke is disabled or has a thickness of 0.</p> <p>If you wish to change the text fill color see addColor instead.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>color</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="description last"><p>A canvas fillstyle that will be used on the text stroke eg <code>red</code>, <code>#00FF00</code>, <code>rgba()</code>.</p></td> </tr> <tr> <td class="name"><code>position</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="description last"><p>The index of the character in the string to start applying this color value from.</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="Phaser.Text.html">Phaser.Text</a></span> - </div> <div class="returns-desc param-desc"> <p>This Text instance.</p> </div> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-686">line 686</a> </dt> </dl> </dd> <dt> <h4 class="name " id="bringToTop"><span class="type-signature"></span>bringToTop<span class="signature">()</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Brings this Game Object to the top of its parents display list. Visually this means it will render over the top of any old child in the same Group.</p> <p>If this Game Object hasn't been added to a custom Group then this method will bring it to the top of the Game World, because the World is the root Group from which all Game Objects descend.</p> </div> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>This instance.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.BringToTop.html#bringToTop">Phaser.Component.BringToTop#bringToTop</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_BringToTop.js.html">gameobjects/components/BringToTop.js</a>, <a href="src_gameobjects_components_BringToTop.js.html#sunlight-1-line-24">line 24</a> </dt> </dl> </dd> <dt> <h4 class="name " id="clearColors"><span class="type-signature"></span>clearColors<span class="signature">()</span><span class="type-signature"> &rarr; {<a href="Phaser.Text.html">Phaser.Text</a>}</span></h4> </dt> <dd> <div class="description"> <p>Clears any text fill or stroke colors that were set by <code>addColor</code> or <code>addStrokeColor</code>.</p> </div> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="Phaser.Text.html">Phaser.Text</a></span> - </div> <div class="returns-desc param-desc"> <p>This Text instance.</p> </div> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-646">line 646</a> </dt> </dl> </dd> <dt> <h4 class="name " id="crop"><span class="type-signature"></span>crop<span class="signature">(rect, <span class="optional">copy</span>)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Crop allows you to crop the texture being used to display this Game Object. Setting a crop rectangle modifies the core texture frame. The Game Object width and height properties will be adjusted accordingly.</p> <p>Cropping takes place from the top-left and can be modified in real-time either by providing an updated rectangle object to this method, or by modifying <code>cropRect</code> property directly and then calling <code>updateCrop</code>.</p> <p>The rectangle object given to this method can be either a <code>Phaser.Rectangle</code> or any other object so long as it has public <code>x</code>, <code>y</code>, <code>width</code>, <code>height</code>, <code>right</code> and <code>bottom</code> properties.</p> <p>A reference to the rectangle is stored in <code>cropRect</code> unless the <code>copy</code> parameter is <code>true</code>, in which case the values are duplicated to a local object.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th>Default</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>rect</code></td> <td class="type"> <span class="param-type"><a href="Phaser.Rectangle.html">Phaser.Rectangle</a></span> </td> <td class="attributes"> </td> <td class="default"> </td> <td class="description last"><p>The Rectangle used during cropping. Pass null or no parameters to clear a previously set crop rectangle.</p></td> </tr> <tr> <td class="name"><code>copy</code></td> <td class="type"> <span class="param-type">boolean</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> false </td> <td class="description last"><p>If false <code>cropRect</code> will be stored as a reference to the given rect. If true it will copy the rect values into a local Phaser Rectangle object stored in cropRect.</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Crop.html#crop">Phaser.Component.Crop#crop</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Crop.js.html">gameobjects/components/Crop.js</a>, <a href="src_gameobjects_components_Crop.js.html#sunlight-1-line-49">line 49</a> </dt> </dl> </dd> <dt> <h4 class="name " id="destroy"><span class="type-signature"></span>destroy<span class="signature">(<span class="optional">destroyChildren</span>)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Destroy this Text object, removing it from the group it belongs to.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th>Default</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>destroyChildren</code></td> <td class="type"> <span class="param-type">boolean</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> true </td> <td class="description last"><p>Should every child of this object have its destroy method called?</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-184">line 184</a> </dt> </dl> </dd> <dt> <h4 class="name " id="generateTexture"><span class="type-signature"></span>generateTexture<span class="signature">(resolution, scaleMode, renderer)</span><span class="type-signature"> &rarr; {<a href="PIXI.Texture.html">PIXI.Texture</a>}</span></h4> </dt> <dd> <div class="description"> <p>Useful function that returns a texture of the displayObject object that can then be used to create sprites This can be quite useful if your displayObject is static / complicated and needs to be reused multiple times.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>resolution</code></td> <td class="type"> <span class="param-type">Number</span> </td> <td class="description last"><p>The resolution of the texture being generated</p></td> </tr> <tr> <td class="name"><code>scaleMode</code></td> <td class="type"> <span class="param-type">Number</span> </td> <td class="description last"><p>See {{#crossLink &quot;PIXI/scaleModes:property&quot;}}PIXI.scaleModes{{/crossLink}} for possible values</p></td> </tr> <tr> <td class="name"><code>renderer</code></td> <td class="type"> <span class="param-type"><a href="PIXI.CanvasRenderer.html">PIXI.CanvasRenderer</a></span> | <span class="param-type"><a href="PIXI.WebGLRenderer.html">PIXI.WebGLRenderer</a></span> </td> <td class="description last"><p>The renderer used to generate the texture.</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.Texture.html">PIXI.Texture</a></span> - </div> <div class="returns-desc param-desc"> <p>a texture of the graphics object</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#generateTexture">PIXI.DisplayObject#generateTexture</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-549">line 549</a> </dt> </dl> </dd> <dt> <h4 class="name " id="getBounds"><span class="type-signature"></span>getBounds<span class="signature">(matrix)</span><span class="type-signature"> &rarr; {<a href="Phaser.Rectangle.html">Phaser.Rectangle</a>}</span></h4> </dt> <dd> <div class="description"> <p>Returns the bounds of the Text as a rectangle. The bounds calculation takes the worldTransform into account.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>matrix</code></td> <td class="type"> <span class="param-type"><a href="Phaser.Matrix.html">Phaser.Matrix</a></span> </td> <td class="description last"><p>The transformation matrix of the Text.</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="Phaser.Rectangle.html">Phaser.Rectangle</a></span> - </div> <div class="returns-desc param-desc"> <p>The framing rectangle</p> </div> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-1223">line 1223</a> </dt> </dl> </dd> <dt> <h4 class="name " id="getChildAt"><span class="type-signature"></span>getChildAt<span class="signature">(index)</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Returns the child at the specified index</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>index</code></td> <td class="type"> <span class="param-type">Number</span> </td> <td class="description last"><p>The index to get the child from</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>The child at the given index, if any.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#getChildAt">PIXI.DisplayObjectContainer#getChildAt</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-194">line 194</a> </dt> </dl> </dd> <dt> <h4 class="name " id="getChildIndex"><span class="type-signature"></span>getChildIndex<span class="signature">(child)</span><span class="type-signature"> &rarr; {Number}</span></h4> </dt> <dd> <div class="description"> <p>Returns the index position of a child DisplayObject instance</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>child</code></td> <td class="type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> </td> <td class="description last"><p>The DisplayObject instance to identify</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type">Number</span> - </div> <div class="returns-desc param-desc"> <p>The index position of the child display object to identify</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#getChildIndex">PIXI.DisplayObjectContainer#getChildIndex</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-159">line 159</a> </dt> </dl> </dd> <dt> <h4 class="name " id="getLocalBounds"><span class="type-signature"></span>getLocalBounds<span class="signature">()</span><span class="type-signature"> &rarr; {Rectangle}</span></h4> </dt> <dd> <div class="description"> <p>Retrieves the non-global local bounds of the displayObjectContainer as a rectangle. The calculation takes all visible children into consideration.</p> </div> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type">Rectangle</span> - </div> <div class="returns-desc param-desc"> <p>The rectangular bounding area</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#getLocalBounds">PIXI.DisplayObjectContainer#getLocalBounds</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-367">line 367</a> </dt> </dl> </dd> <dt> <h4 class="name " id="kill"><span class="type-signature"></span>kill<span class="signature">()</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Kills a Game Object. A killed Game Object has its <code>alive</code>, <code>exists</code> and <code>visible</code> properties all set to false.</p> <p>It will dispatch the <code>onKilled</code> event. You can listen to <code>events.onKilled</code> for the signal.</p> <p>Note that killing a Game Object is a way for you to quickly recycle it in an object pool, it doesn't destroy the object or free it up from memory.</p> <p>If you don't need this Game Object any more you should call <code>destroy</code> instead.</p> </div> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>This instance.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.LifeSpan.html#kill">Phaser.Component.LifeSpan#kill</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_LifeSpan.js.html">gameobjects/components/LifeSpan.js</a>, <a href="src_gameobjects_components_LifeSpan.js.html#sunlight-1-line-113">line 113</a> </dt> </dl> </dd> <dt> <h4 class="name " id="loadTexture"><span class="type-signature"></span>loadTexture<span class="signature">(key, <span class="optional">frame</span>, <span class="optional">stopAnimation</span>)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Changes the base texture the Game Object is using. The old texture is removed and the new one is referenced or fetched from the Cache.</p> <p>If your Game Object is using a frame from a texture atlas and you just wish to change to another frame, then see the <code>frame</code> or <code>frameName</code> properties instead.</p> <p>You should only use <code>loadTexture</code> if you want to replace the base texture entirely.</p> <p>Calling this method causes a WebGL texture update, so use sparingly or in low-intensity portions of your game, or if you know the new texture is already on the GPU.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th>Default</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>key</code></td> <td class="type"> <span class="param-type">string</span> | <span class="param-type"><a href="Phaser.RenderTexture.html">Phaser.RenderTexture</a></span> | <span class="param-type"><a href="Phaser.BitmapData.html">Phaser.BitmapData</a></span> | <span class="param-type"><a href="Phaser.Video.html">Phaser.Video</a></span> | <span class="param-type"><a href="PIXI.Texture.html">PIXI.Texture</a></span> </td> <td class="attributes"> </td> <td class="default"> </td> <td class="description last"><p>This is the image or texture used by the Sprite during rendering. It can be a string which is a reference to the Cache Image entry, or an instance of a RenderTexture, BitmapData, Video or PIXI.Texture.</p></td> </tr> <tr> <td class="name"><code>frame</code></td> <td class="type"> <span class="param-type">string</span> | <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> </td> <td class="description last"><p>If this Sprite is using part of a sprite sheet or texture atlas you can specify the exact frame to use by giving a string or numeric index.</p></td> </tr> <tr> <td class="name"><code>stopAnimation</code></td> <td class="type"> <span class="param-type">boolean</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> true </td> <td class="description last"><p>If an animation is already playing on this Sprite you can choose to stop it or let it carry on playing.</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.LoadTexture.html#loadTexture">Phaser.Component.LoadTexture#loadTexture</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_LoadTexture.js.html">gameobjects/components/LoadTexture.js</a>, <a href="src_gameobjects_components_LoadTexture.js.html#sunlight-1-line-42">line 42</a> </dt> </dl> </dd> <dt> <h4 class="name " id="moveDown"><span class="type-signature"></span>moveDown<span class="signature">()</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Moves this Game Object down one place in its parents display list. This call has no effect if the Game Object is already at the bottom of the display list.</p> <p>If this Game Object hasn't been added to a custom Group then this method will move it one object down within the Game World, because the World is the root Group from which all Game Objects descend.</p> </div> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>This instance.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.BringToTop.html#moveDown">Phaser.Component.BringToTop#moveDown</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_BringToTop.js.html">gameobjects/components/BringToTop.js</a>, <a href="src_gameobjects_components_BringToTop.js.html#sunlight-1-line-87">line 87</a> </dt> </dl> </dd> <dt> <h4 class="name " id="moveUp"><span class="type-signature"></span>moveUp<span class="signature">()</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Moves this Game Object up one place in its parents display list. This call has no effect if the Game Object is already at the top of the display list.</p> <p>If this Game Object hasn't been added to a custom Group then this method will move it one object up within the Game World, because the World is the root Group from which all Game Objects descend.</p> </div> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>This instance.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.BringToTop.html#moveUp">Phaser.Component.BringToTop#moveUp</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_BringToTop.js.html">gameobjects/components/BringToTop.js</a>, <a href="src_gameobjects_components_BringToTop.js.html#sunlight-1-line-66">line 66</a> </dt> </dl> </dd> <dt> <h4 class="name " id="overlap"><span class="type-signature"></span>overlap<span class="signature">(displayObject)</span><span class="type-signature"> &rarr; {boolean}</span></h4> </dt> <dd> <div class="description"> <p>Checks to see if the bounds of this Game Object overlaps with the bounds of the given Display Object, which can be a Sprite, Image, TileSprite or anything that extends those such as Button or provides a <code>getBounds</code> method and result.</p> <p>This check ignores the <code>hitArea</code> property if set and runs a <code>getBounds</code> comparison on both objects to determine the result.</p> <p>Therefore it's relatively expensive to use in large quantities, i.e. with lots of Sprites at a high frequency. It should be fine for low-volume testing where physics isn't required.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>displayObject</code></td> <td class="type"> <span class="param-type"><a href="Phaser.Sprite.html">Phaser.Sprite</a></span> | <span class="param-type"><a href="Phaser.Image.html">Phaser.Image</a></span> | <span class="param-type"><a href="Phaser.TileSprite.html">Phaser.TileSprite</a></span> | <span class="param-type"><a href="Phaser.Button.html">Phaser.Button</a></span> | <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> </td> <td class="description last"><p>The display object to check against.</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type">boolean</span> - </div> <div class="returns-desc param-desc"> <p>True if the bounds of this Game Object intersects at any point with the bounds of the given display object.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Overlap.html#overlap">Phaser.Component.Overlap#overlap</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Overlap.js.html">gameobjects/components/Overlap.js</a>, <a href="src_gameobjects_components_Overlap.js.html#sunlight-1-line-29">line 29</a> </dt> </dl> </dd> <dt> <h4 class="name " id="parseList"><span class="type-signature"></span>parseList<span class="signature">(list)</span><span class="type-signature"> &rarr; {<a href="Phaser.Text.html">Phaser.Text</a>}</span></h4> </dt> <dd> <div class="description"> <p>Converts the given array into a tab delimited string and then updates this Text object. This is mostly used when you want to display external data using tab stops.</p> <p>The array can be either single or multi dimensional depending on the result you need:</p> <p><code>[ 'a', 'b', 'c' ]</code> would convert in to <code>&quot;a\tb\tc&quot;</code>.</p> <p>Where as:</p> <p><code>[ [ 'a', 'b', 'c' ], [ 'd', 'e', 'f'] ]</code></p> <p>would convert in to: <code>&quot;a\tb\tc\nd\te\tf&quot;</code></p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>list</code></td> <td class="type"> <span class="param-type">array</span> </td> <td class="description last"><p>The array of data to convert into a string.</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="Phaser.Text.html">Phaser.Text</a></span> - </div> <div class="returns-desc param-desc"> <p>This Text instance.</p> </div> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-880">line 880</a> </dt> </dl> </dd> <dt> <h4 class="name " id="play"><span class="type-signature"></span>play<span class="signature">(name, <span class="optional">frameRate</span>, <span class="optional">loop</span>, <span class="optional">killOnComplete</span>)</span><span class="type-signature"> &rarr; {<a href="Phaser.Animation.html">Phaser.Animation</a>}</span></h4> </dt> <dd> <div class="description"> <p>Plays an Animation.</p> <p>The animation should have previously been created via <code>animations.add</code>.</p> <p>If the animation is already playing calling this again won't do anything. If you need to reset an already running animation do so directly on the Animation object itself or via <code>AnimationManager.stop</code>.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th>Default</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>name</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> </td> <td class="default"> </td> <td class="description last"><p>The name of the animation to be played, e.g. &quot;fire&quot;, &quot;walk&quot;, &quot;jump&quot;. Must have been previously created via 'AnimationManager.add'.</p></td> </tr> <tr> <td class="name"><code>frameRate</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> null </td> <td class="description last"><p>The framerate to play the animation at. The speed is given in frames per second. If not provided the previously set frameRate of the Animation is used.</p></td> </tr> <tr> <td class="name"><code>loop</code></td> <td class="type"> <span class="param-type">boolean</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> false </td> <td class="description last"><p>Should the animation be looped after playback. If not provided the previously set loop value of the Animation is used.</p></td> </tr> <tr> <td class="name"><code>killOnComplete</code></td> <td class="type"> <span class="param-type">boolean</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> false </td> <td class="description last"><p>If set to true when the animation completes (only happens if loop=false) the parent Sprite will be killed.</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="Phaser.Animation.html">Phaser.Animation</a></span> - </div> <div class="returns-desc param-desc"> <p>A reference to playing Animation.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Animation.html#play">Phaser.Component.Animation#play</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Animation.js.html">gameobjects/components/Animation.js</a>, <a href="src_gameobjects_components_Animation.js.html#sunlight-1-line-31">line 31</a> </dt> </dl> </dd> <dt> <h4 class="name " id="postUpdate"><span class="type-signature">&lt;internal> </span>postUpdate<span class="signature">()</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Internal method called by the World postUpdate cycle.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Core.html#postUpdate">Phaser.Component.Core#postUpdate</a> </li></dd> <dt class="important tag-deprecated">Internal:</dt> <dd class="tag-deprecated"><ul> <li>This member is <em>internal (protected)</em> and may be modified or removed in the future.</li> </ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Core.js.html">gameobjects/components/Core.js</a>, <a href="src_gameobjects_components_Core.js.html#sunlight-1-line-329">line 329</a> </dt> </dl> </dd> <dt> <h4 class="name " id="preUpdate"><span class="type-signature">&lt;internal> </span>preUpdate<span class="signature">()</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Automatically called by World.preUpdate.</p> </div> <dl class="details"> <dt class="important tag-deprecated">Internal:</dt> <dd class="tag-deprecated"><ul> <li>This member is <em>internal (protected)</em> and may be modified or removed in the future.</li> </ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-157">line 157</a> </dt> </dl> </dd> <dt> <h4 class="name " id="removeChild"><span class="type-signature"></span>removeChild<span class="signature">(child)</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Removes a child from the container.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>child</code></td> <td class="type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> </td> <td class="description last"><p>The DisplayObject to remove</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>The child that was removed.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#removeChild">PIXI.DisplayObjectContainer#removeChild</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-211">line 211</a> </dt> </dl> </dd> <dt> <h4 class="name " id="removeChildAt"><span class="type-signature"></span>removeChildAt<span class="signature">(index)</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Removes a child from the specified index position.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>index</code></td> <td class="type"> <span class="param-type">Number</span> </td> <td class="description last"><p>The index to get the child from</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>The child that was removed.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#removeChildAt">PIXI.DisplayObjectContainer#removeChildAt</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-226">line 226</a> </dt> </dl> </dd> <dt> <h4 class="name " id="removeChildren"><span class="type-signature"></span>removeChildren<span class="signature">(beginIndex, endIndex)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Removes all children from this container that are within the begin and end indexes.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>beginIndex</code></td> <td class="type"> <span class="param-type">Number</span> </td> <td class="description last"><p>The beginning position. Default value is 0.</p></td> </tr> <tr> <td class="name"><code>endIndex</code></td> <td class="type"> <span class="param-type">Number</span> </td> <td class="description last"><p>The ending position. Default value is size of the container.</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#removeChildren">PIXI.DisplayObjectContainer#removeChildren</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-244">line 244</a> </dt> </dl> </dd> <dt> <h4 class="name " id="removeStageReference"><span class="type-signature"></span>removeStageReference<span class="signature">()</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Removes the current stage reference from the container and all of its children.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#removeStageReference">PIXI.DisplayObjectContainer#removeStageReference</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-407">line 407</a> </dt> </dl> </dd> <dt> <h4 class="name " id="reset"><span class="type-signature"></span>reset<span class="signature">(x, y, <span class="optional">health</span>)</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Resets the Game Object.</p> <p>This moves the Game Object to the given x/y world coordinates and sets <code>fresh</code>, <code>exists</code>, <code>visible</code> and <code>renderable</code> to true.</p> <p>If this Game Object has the LifeSpan component it will also set <code>alive</code> to true and <code>health</code> to the given value.</p> <p>If this Game Object has a Physics Body it will reset the Body.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th>Default</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>x</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> </td> <td class="default"> </td> <td class="description last"><p>The x coordinate (in world space) to position the Game Object at.</p></td> </tr> <tr> <td class="name"><code>y</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> </td> <td class="default"> </td> <td class="description last"><p>The y coordinate (in world space) to position the Game Object at.</p></td> </tr> <tr> <td class="name"><code>health</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 1 </td> <td class="description last"><p>The health to give the Game Object if it has the Health component.</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>This instance.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Reset.html#reset">Phaser.Component.Reset#reset</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Reset.js.html">gameobjects/components/Reset.js</a>, <a href="src_gameobjects_components_Reset.js.html#sunlight-1-line-30">line 30</a> </dt> </dl> </dd> <dt> <h4 class="name " id="resetFrame"><span class="type-signature"></span>resetFrame<span class="signature">()</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Resets the texture frame dimensions that the Game Object uses for rendering.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.LoadTexture.html#resetFrame">Phaser.Component.LoadTexture#resetFrame</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_LoadTexture.js.html">gameobjects/components/LoadTexture.js</a>, <a href="src_gameobjects_components_LoadTexture.js.html#sunlight-1-line-196">line 196</a> </dt> </dl> </dd> <dt> <h4 class="name " id="resizeFrame"><span class="type-signature"></span>resizeFrame<span class="signature">(parent, width, height)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Resizes the Frame dimensions that the Game Object uses for rendering.</p> <p>You shouldn't normally need to ever call this, but in the case of special texture types such as Video or BitmapData it can be useful to adjust the dimensions directly in this way.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>parent</code></td> <td class="type"> <span class="param-type">object</span> </td> <td class="description last"><p>The parent texture object that caused the resize, i.e. a Phaser.Video object.</p></td> </tr> <tr> <td class="name"><code>width</code></td> <td class="type"> <span class="param-type">integer</span> </td> <td class="description last"><p>The new width of the texture.</p></td> </tr> <tr> <td class="name"><code>height</code></td> <td class="type"> <span class="param-type">integer</span> </td> <td class="description last"><p>The new height of the texture.</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.LoadTexture.html#resizeFrame">Phaser.Component.LoadTexture#resizeFrame</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_LoadTexture.js.html">gameobjects/components/LoadTexture.js</a>, <a href="src_gameobjects_components_LoadTexture.js.html#sunlight-1-line-184">line 184</a> </dt> </dl> </dd> <dt> <h4 class="name " id="revive"><span class="type-signature"></span>revive<span class="signature">(<span class="optional">health</span>)</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Brings a 'dead' Game Object back to life, optionally resetting its health value in the process.</p> <p>A resurrected Game Object has its <code>alive</code>, <code>exists</code> and <code>visible</code> properties all set to true.</p> <p>It will dispatch the <code>onRevived</code> event. Listen to <code>events.onRevived</code> for the signal.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th>Default</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>health</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 1 </td> <td class="description last"><p>The health to give the Game Object. Only set if the GameObject has the Health component.</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>This instance.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.LifeSpan.html#revive">Phaser.Component.LifeSpan#revive</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_LifeSpan.js.html">gameobjects/components/LifeSpan.js</a>, <a href="src_gameobjects_components_LifeSpan.js.html#sunlight-1-line-78">line 78</a> </dt> </dl> </dd> <dt> <h4 class="name " id="sendToBack"><span class="type-signature"></span>sendToBack<span class="signature">()</span><span class="type-signature"> &rarr; {<a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a>}</span></h4> </dt> <dd> <div class="description"> <p>Sends this Game Object to the bottom of its parents display list. Visually this means it will render below all other children in the same Group.</p> <p>If this Game Object hasn't been added to a custom Group then this method will send it to the bottom of the Game World, because the World is the root Group from which all Game Objects descend.</p> </div> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> - </div> <div class="returns-desc param-desc"> <p>This instance.</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.BringToTop.html#sendToBack">Phaser.Component.BringToTop#sendToBack</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_BringToTop.js.html">gameobjects/components/BringToTop.js</a>, <a href="src_gameobjects_components_BringToTop.js.html#sunlight-1-line-45">line 45</a> </dt> </dl> </dd> <dt> <h4 class="name " id="setChildIndex"><span class="type-signature"></span>setChildIndex<span class="signature">(child, index)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Changes the position of an existing child in the display object container</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>child</code></td> <td class="type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> </td> <td class="description last"><p>The child DisplayObject instance for which you want to change the index number</p></td> </tr> <tr> <td class="name"><code>index</code></td> <td class="type"> <span class="param-type">Number</span> </td> <td class="description last"><p>The resulting index number for the child display object</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#setChildIndex">PIXI.DisplayObjectContainer#setChildIndex</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-176">line 176</a> </dt> </dl> </dd> <dt> <h4 class="name " id="setFrame"><span class="type-signature"></span>setFrame<span class="signature">(frame)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Sets the texture frame the Game Object uses for rendering.</p> <p>This is primarily an internal method used by <code>loadTexture</code>, but is exposed for the use of plugins and custom classes.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>frame</code></td> <td class="type"> <span class="param-type"><a href="Phaser.Frame.html">Phaser.Frame</a></span> </td> <td class="description last"><p>The Frame to be used by the texture.</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.LoadTexture.html#setFrame">Phaser.Component.LoadTexture#setFrame</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_LoadTexture.js.html">gameobjects/components/LoadTexture.js</a>, <a href="src_gameobjects_components_LoadTexture.js.html#sunlight-1-line-119">line 119</a> </dt> </dl> </dd> <dt> <h4 class="name " id="setScaleMinMax"><span class="type-signature"></span>setScaleMinMax<span class="signature">(minX, minY, maxX, maxY)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Sets the scaleMin and scaleMax values. These values are used to limit how far this Game Object will scale based on its parent.</p> <p>For example if this Game Object has a <code>minScale</code> value of 1 and its parent has a <code>scale</code> value of 0.5, the 0.5 will be ignored and the scale value of 1 will be used, as the parents scale is lower than the minimum scale this Game Object should adhere to.</p> <p>By setting these values you can carefully control how Game Objects deal with responsive scaling.</p> <p>If only one parameter is given then that value will be used for both scaleMin and scaleMax: <code>setScaleMinMax(1)</code> = scaleMin.x, scaleMin.y, scaleMax.x and scaleMax.y all = 1</p> <p>If only two parameters are given the first is set as scaleMin.x and y and the second as scaleMax.x and y: <code>setScaleMinMax(0.5, 2)</code> = scaleMin.x and y = 0.5 and scaleMax.x and y = 2</p> <p>If you wish to set <code>scaleMin</code> with different values for x and y then either modify Game Object.scaleMin directly, or pass <code>null</code> for the <code>maxX</code> and <code>maxY</code> parameters.</p> <p>Call <code>setScaleMinMax(null)</code> to clear all previously set values.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>minX</code></td> <td class="type"> <span class="param-type">number</span> | <span class="param-type">null</span> </td> <td class="description last"><p>The minimum horizontal scale value this Game Object can scale down to.</p></td> </tr> <tr> <td class="name"><code>minY</code></td> <td class="type"> <span class="param-type">number</span> | <span class="param-type">null</span> </td> <td class="description last"><p>The minimum vertical scale value this Game Object can scale down to.</p></td> </tr> <tr> <td class="name"><code>maxX</code></td> <td class="type"> <span class="param-type">number</span> | <span class="param-type">null</span> </td> <td class="description last"><p>The maximum horizontal scale value this Game Object can scale up to.</p></td> </tr> <tr> <td class="name"><code>maxY</code></td> <td class="type"> <span class="param-type">number</span> | <span class="param-type">null</span> </td> <td class="description last"><p>The maximum vertical scale value this Game Object can scale up to.</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.ScaleMinMax.html#setScaleMinMax">Phaser.Component.ScaleMinMax#setScaleMinMax</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_ScaleMinMax.js.html">gameobjects/components/ScaleMinMax.js</a>, <a href="src_gameobjects_components_ScaleMinMax.js.html#sunlight-1-line-110">line 110</a> </dt> </dl> </dd> <dt> <h4 class="name " id="setShadow"><span class="type-signature"></span>setShadow<span class="signature">(<span class="optional">x</span>, <span class="optional">y</span>, <span class="optional">color</span>, <span class="optional">blur</span>, <span class="optional">shadowStroke</span>, <span class="optional">shadowFill</span>)</span><span class="type-signature"> &rarr; {<a href="Phaser.Text.html">Phaser.Text</a>}</span></h4> </dt> <dd> <div class="description"> <p>Sets a drop shadow effect on the Text. You can specify the horizontal and vertical distance of the drop shadow with the <code>x</code> and <code>y</code> parameters. The color controls the shade of the shadow (default is black) and can be either an <code>rgba</code> or <code>hex</code> value. The blur is the strength of the shadow. A value of zero means a hard shadow, a value of 10 means a very soft shadow. To remove a shadow already in place you can call this method with no parameters set.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th>Default</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>x</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 0 </td> <td class="description last"><p>The shadowOffsetX value in pixels. This is how far offset horizontally the shadow effect will be.</p></td> </tr> <tr> <td class="name"><code>y</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 0 </td> <td class="description last"><p>The shadowOffsetY value in pixels. This is how far offset vertically the shadow effect will be.</p></td> </tr> <tr> <td class="name"><code>color</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'rgba(0,0,0,1)' </td> <td class="description last"><p>The color of the shadow, as given in CSS rgba or hex format. Set the alpha component to 0 to disable the shadow.</p></td> </tr> <tr> <td class="name"><code>blur</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 0 </td> <td class="description last"><p>The shadowBlur value. Make the shadow softer by applying a Gaussian blur to it. A number from 0 (no blur) up to approx. 10 (depending on scene).</p></td> </tr> <tr> <td class="name"><code>shadowStroke</code></td> <td class="type"> <span class="param-type">boolean</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> true </td> <td class="description last"><p>Apply the drop shadow to the Text stroke (if set).</p></td> </tr> <tr> <td class="name"><code>shadowFill</code></td> <td class="type"> <span class="param-type">boolean</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> true </td> <td class="description last"><p>Apply the drop shadow to the Text fill (if set).</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="Phaser.Text.html">Phaser.Text</a></span> - </div> <div class="returns-desc param-desc"> <p>This Text instance.</p> </div> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-208">line 208</a> </dt> </dl> </dd> <dt> <h4 class="name " id="setStageReference"><span class="type-signature"></span>setStageReference<span class="signature">(stage)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Sets the containers Stage reference. This is the Stage that this object, and all of its children, is connected to.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>stage</code></td> <td class="type"> <span class="param-type"><a href="PIXI.Stage.html">PIXI.Stage</a></span> </td> <td class="description last"><p>the stage that the container will have as its current stage reference</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#setStageReference">PIXI.DisplayObjectContainer#setStageReference</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-391">line 391</a> </dt> </dl> </dd> <dt> <h4 class="name " id="setStyle"><span class="type-signature"></span>setStyle<span class="signature">(<span class="optional">style</span>)</span><span class="type-signature"> &rarr; {<a href="Phaser.Text.html">Phaser.Text</a>}</span></h4> </dt> <dd> <div class="description"> <p>Set the style of the text by passing a single style object to it.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>style</code></td> <td class="type"> <span class="param-type">object</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="description last"><p>The style properties to be set on the Text.</p> <h6>Properties</h6> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th>Default</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>font</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'bold 20pt Arial' </td> <td class="description last"><p>The style and size of the font.</p></td> </tr> <tr> <td class="name"><code>fontStyle</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> (from font) </td> <td class="description last"><p>The style of the font (eg. 'italic'): overrides the value in <code>style.font</code>.</p></td> </tr> <tr> <td class="name"><code>fontVariant</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> (from font) </td> <td class="description last"><p>The variant of the font (eg. 'small-caps'): overrides the value in <code>style.font</code>.</p></td> </tr> <tr> <td class="name"><code>fontWeight</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> (from font) </td> <td class="description last"><p>The weight of the font (eg. 'bold'): overrides the value in <code>style.font</code>.</p></td> </tr> <tr> <td class="name"><code>fontSize</code></td> <td class="type"> <span class="param-type">string</span> | <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> (from font) </td> <td class="description last"><p>The size of the font (eg. 32 or '32px'): overrides the value in <code>style.font</code>.</p></td> </tr> <tr> <td class="name"><code>backgroundColor</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> null </td> <td class="description last"><p>A canvas fillstyle that will be used as the background for the whole Text object. Set to <code>null</code> to disable.</p></td> </tr> <tr> <td class="name"><code>fill</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'black' </td> <td class="description last"><p>A canvas fillstyle that will be used on the text eg 'red', '#00FF00'.</p></td> </tr> <tr> <td class="name"><code>align</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'left' </td> <td class="description last"><p>Horizontal alignment of each line in multiline text. Can be: 'left', 'center' or 'right'. Does not affect single lines of text (see <code>textBounds</code> and <code>boundsAlignH</code> for that).</p></td> </tr> <tr> <td class="name"><code>boundsAlignH</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'left' </td> <td class="description last"><p>Horizontal alignment of the text within the <code>textBounds</code>. Can be: 'left', 'center' or 'right'.</p></td> </tr> <tr> <td class="name"><code>boundsAlignV</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'top' </td> <td class="description last"><p>Vertical alignment of the text within the <code>textBounds</code>. Can be: 'top', 'middle' or 'bottom'.</p></td> </tr> <tr> <td class="name"><code>stroke</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 'black' </td> <td class="description last"><p>A canvas stroke style that will be used on the text stroke eg 'blue', '#FCFF00'.</p></td> </tr> <tr> <td class="name"><code>strokeThickness</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 0 </td> <td class="description last"><p>A number that represents the thickness of the stroke. Default is 0 (no stroke).</p></td> </tr> <tr> <td class="name"><code>wordWrap</code></td> <td class="type"> <span class="param-type">boolean</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> false </td> <td class="description last"><p>Indicates if word wrap should be used.</p></td> </tr> <tr> <td class="name"><code>wordWrapWidth</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 100 </td> <td class="description last"><p>The width in pixels at which text will wrap.</p></td> </tr> <tr> <td class="name"><code>tabs</code></td> <td class="type"> <span class="param-type">number</span> | <span class="param-type">array</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="default"> 0 </td> <td class="description last"><p>The size (in pixels) of the tabs, for when text includes tab characters. 0 disables. Can be an array of varying tab sizes, one per tab stop.</p></td> </tr> </tbody> </table> </td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="Phaser.Text.html">Phaser.Text</a></span> - </div> <div class="returns-desc param-desc"> <p>This Text instance.</p> </div> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-244">line 244</a> </dt> </dl> </dd> <dt> <h4 class="name " id="setText"><span class="type-signature"></span>setText<span class="signature">(<span class="optional">text</span>)</span><span class="type-signature"> &rarr; {<a href="Phaser.Text.html">Phaser.Text</a>}</span></h4> </dt> <dd> <div class="description"> <p>The text to be displayed by this Text object. Use a \n to insert a carriage return and split the text. The text will be rendered with any style currently set.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>text</code></td> <td class="type"> <span class="param-type">string</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="description last"><p>The text to be displayed. Set to an empty string to clear text that is already present.</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="Phaser.Text.html">Phaser.Text</a></span> - </div> <div class="returns-desc param-desc"> <p>This Text instance.</p> </div> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-862">line 862</a> </dt> </dl> </dd> <dt> <h4 class="name " id="setTextBounds"><span class="type-signature"></span>setTextBounds<span class="signature">(<span class="optional">x</span>, <span class="optional">y</span>, <span class="optional">width</span>, <span class="optional">height</span>)</span><span class="type-signature"> &rarr; {<a href="Phaser.Text.html">Phaser.Text</a>}</span></h4> </dt> <dd> <div class="description"> <p>The Text Bounds is a rectangular region that you control the dimensions of into which the Text object itself is positioned, regardless of the number of lines in the text, the font size or any other attribute.</p> <p>Alignment is controlled via the properties <code>boundsAlignH</code> and <code>boundsAlignV</code> within the Text.style object, or can be directly set through the setters <code>Text.boundsAlignH</code> and <code>Text.boundsAlignV</code>. Bounds alignment is independent of text alignment.</p> <p>For example: If your game is 800x600 in size and you set the text bounds to be 0,0,800,600 then by setting boundsAlignH to 'center' and boundsAlignV to 'bottom' the text will render in the center and at the bottom of your game window, regardless of how many lines of text there may be. Even if you adjust the text content or change the style it will remain at the bottom center of the text bounds.</p> <p>This is especially powerful when you need to align text against specific coordinates in your game, but the actual text dimensions may vary based on font (say for multi-lingual games).</p> <p>If <code>Text.wordWrapWidth</code> is greater than the width of the text bounds it is clamped to match the bounds width.</p> <p>Call this method with no arguments given to reset an existing textBounds.</p> <p>It works by calculating the final position based on the Text.canvas size, which is modified as the text is updated. Some fonts have additional padding around them which you can mitigate by tweaking the Text.padding property. It then adjusts the <code>pivot</code> property based on the given bounds and canvas size. This means if you need to set the pivot property directly in your game then you either cannot use <code>setTextBounds</code> or you must place the Text object inside another DisplayObject on which you set the pivot.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>x</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="description last"><p>The x coordinate of the Text Bounds region.</p></td> </tr> <tr> <td class="name"><code>y</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="description last"><p>The y coordinate of the Text Bounds region.</p></td> </tr> <tr> <td class="name"><code>width</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="description last"><p>The width of the Text Bounds region.</p></td> </tr> <tr> <td class="name"><code>height</code></td> <td class="type"> <span class="param-type">number</span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="description last"><p>The height of the Text Bounds region.</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type"><a href="Phaser.Text.html">Phaser.Text</a></span> - </div> <div class="returns-desc param-desc"> <p>This Text instance.</p> </div> </div> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-941">line 941</a> </dt> </dl> </dd> <dt> <h4 class="name " id="setTexture"><span class="type-signature"></span>setTexture<span class="signature">(texture)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Sets the texture of the sprite</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>texture</code></td> <td class="type"> <span class="param-type"><a href="PIXI.Texture.html">PIXI.Texture</a></span> </td> <td class="description last"><p>The PIXI texture that is displayed by the sprite</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.Sprite.html#setTexture">PIXI.Sprite#setTexture</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_Sprite.js.html">pixi/display/Sprite.js</a>, <a href="src_pixi_display_Sprite.js.html#sunlight-1-line-156">line 156</a> </dt> </dl> </dd> <dt> <h4 class="name " id="swapChildren"><span class="type-signature"></span>swapChildren<span class="signature">(child, child2)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Swaps the position of 2 Display Objects within this container.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>child</code></td> <td class="type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> </td> <td class="description last"><p>-</p></td> </tr> <tr> <td class="name"><code>child2</code></td> <td class="type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> </td> <td class="description last"><p>-</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObjectContainer.html#swapChildren">PIXI.DisplayObjectContainer#swapChildren</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObjectContainer.js.html">pixi/display/DisplayObjectContainer.js</a>, <a href="src_pixi_display_DisplayObjectContainer.js.html#sunlight-1-line-134">line 134</a> </dt> </dl> </dd> <dt> <h4 class="name " id="toGlobal"><span class="type-signature"></span>toGlobal<span class="signature">(position)</span><span class="type-signature"> &rarr; {Point}</span></h4> </dt> <dd> <div class="description"> <p>Calculates the global position of the display object</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>position</code></td> <td class="type"> <span class="param-type">Point</span> </td> <td class="description last"><p>The world origin to calculate from</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type">Point</span> - </div> <div class="returns-desc param-desc"> <p>A point object representing the position of this object</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#toGlobal">PIXI.DisplayObject#toGlobal</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-583">line 583</a> </dt> </dl> </dd> <dt> <h4 class="name " id="toLocal"><span class="type-signature"></span>toLocal<span class="signature">(position, <span class="optional">from</span>)</span><span class="type-signature"> &rarr; {Point}</span></h4> </dt> <dd> <div class="description"> <p>Calculates the local position of the display object relative to another point</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th>Argument</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>position</code></td> <td class="type"> <span class="param-type">Point</span> </td> <td class="attributes"> </td> <td class="description last"><p>The world origin to calculate from</p></td> </tr> <tr> <td class="name"><code>from</code></td> <td class="type"> <span class="param-type"><a href="PIXI.DisplayObject.html">PIXI.DisplayObject</a></span> </td> <td class="attributes"> &lt;optional><br> </td> <td class="description last"><p>The DisplayObject to calculate the global position from</p></td> </tr> </tbody> </table> <h5>Returns:</h5> <div class="returns"> <div class="returns-type"> <span class="param-type">Point</span> - </div> <div class="returns-desc param-desc"> <p>A point object representing the position of this object</p> </div> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#toLocal">PIXI.DisplayObject#toLocal</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-597">line 597</a> </dt> </dl> </dd> <dt> <h4 class="name " id="update"><span class="type-signature">&lt;internal> </span>update<span class="signature">()</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Override this function to handle any special update requirements.</p> </div> <dl class="details"> <dt class="important tag-deprecated">Internal:</dt> <dd class="tag-deprecated"><ul> <li>This member is <em>internal (protected)</em> and may be modified or removed in the future.</li> </ul></dd> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-174">line 174</a> </dt> </dl> </dd> <dt> <h4 class="name " id="updateCache"><span class="type-signature"></span>updateCache<span class="signature">()</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Generates and updates the cached sprite for this object.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="PIXI.DisplayObject.html#updateCache">PIXI.DisplayObject#updateCache</a> </li></dd> <dt class="tag-source">Source - <a href="src_pixi_display_DisplayObject.js.html">pixi/display/DisplayObject.js</a>, <a href="src_pixi_display_DisplayObject.js.html#sunlight-1-line-573">line 573</a> </dt> </dl> </dd> <dt> <h4 class="name " id="updateCrop"><span class="type-signature"></span>updateCrop<span class="signature">()</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>If you have set a crop rectangle on this Game Object via <code>crop</code> and since modified the <code>cropRect</code> property, or the rectangle it references, then you need to update the crop frame by calling this method.</p> </div> <dl class="details"> <dt class="inherited-from">Inherited From:</dt> <dd class="inherited-from"><ul class="dummy"><li> <a href="Phaser.Component.Crop.html#updateCrop">Phaser.Component.Crop#updateCrop</a> </li></dd> <dt class="tag-source">Source - <a href="src_gameobjects_components_Crop.js.html">gameobjects/components/Crop.js</a>, <a href="src_gameobjects_components_Crop.js.html#sunlight-1-line-86">line 86</a> </dt> </dl> </dd> <dt> <h4 class="name " id="updateShadow"><span class="type-signature"></span>updateShadow<span class="signature">(state)</span><span class="type-signature"></span></h4> </dt> <dd> <div class="description"> <p>Sets the Shadow on the Text.context based on the Style settings, or disables it if not enabled. This is called automatically by Text.updateText.</p> </div> <h5>Parameters:</h5> <table class="params table table-striped"> <thead> <tr> <th>Name</th> <th>Type</th> <th class="last">Description</th> </tr> </thead> <tbody> <tr> <td class="name"><code>state</code></td> <td class="type"> <span class="param-type">boolean</span> </td> <td class="description last"><p>If true the shadow will be set to the Style values, otherwise it will be set to zero.</p></td> </tr> </tbody> </table> <dl class="details"> <dt class="tag-source">Source - <a href="src_gameobjects_Text.js.html">gameobjects/Text.js</a>, <a href="src_gameobjects_Text.js.html#sunlight-1-line-579">line 579</a> </dt> </dl> </dd> </dl> </article> </section> </div> <div class="clearfix"></div> <footer> <span class="copyright"> Phaser Copyright © 2012-2015 Photon Storm Ltd. </span> <br /> <span class="jsdoc-message"> Documentation generated by <a href="https://github.com/jsdoc3/jsdoc">JSDoc 3.3.0-alpha10</a> on Wed Jul 22 2015 14:55:20 GMT+0100 (GMT Daylight Time) using the <a href="https://github.com/terryweiss/docstrap">DocStrap template</a>. </span> </footer> </div> <div class="span3"> <div id="toc"></div> </div> <br clear="both"> </div> </div> <script src="scripts/sunlight.js"></script> <script src="scripts/sunlight.javascript.js"></script> <script src="scripts/sunlight-plugin.doclinks.js"></script> <script src="scripts/sunlight-plugin.linenumbers.js"></script> <script src="scripts/sunlight-plugin.menu.js"></script> <script src="scripts/jquery.min.js"></script> <script src="scripts/jquery.scrollTo.js"></script> <script src="scripts/jquery.localScroll.js"></script> <script src="scripts/bootstrap-dropdown.js"></script> <script src="scripts/toc.js"></script> <script> Sunlight.highlightAll({lineNumbers:true, showMenu: true, enableDoclinks :true}); </script> <script> $( function () { $( "#toc" ).toc( { anchorName : function(i, heading, prefix) { return $(heading).attr("id") || ( prefix + i ); }, selectors : "h1,h2,h3,h4", showAndHide : false, scrollTo : 60 } ); $( "#toc>ul" ).addClass( "nav nav-pills nav-stacked" ); $( "#main span[id^='toc']" ).addClass( "toc-shim" ); } ); </script> </body> </html>
{ "content_hash": "b767d6393e8b9ba8279ea17e0ecdf86d", "timestamp": "", "source": "github", "line_count": 16945, "max_line_length": 417, "avg_line_length": 17.148775449985248, "alnum_prop": 0.5052755466540026, "repo_name": "NoahYarian/phaser", "id": "10d18bebaa4216634e0a495c723c2ee235e26dd3", "size": "290587", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "docs/Phaser.Text.html", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "197804" }, { "name": "HTML", "bytes": "164005" }, { "name": "JavaScript", "bytes": "12429659" }, { "name": "PHP", "bytes": "87785" } ], "symlink_target": "" }
{% extends "base.html" %} {% block title %}YUI Async Calls to Server Examples{% endblock %} {% block body %} <div class="container-fluid"> <div class="row-fluid"> <div class="span12"> <script type="text/javascript" src="{{ static('yui_2.9.0/yuiloader-dom-event/yuiloader-dom-event.js') }}"></script> <script type="text/javascript" src="{{ static('yui_2.9.0/connection/connection-min.js') }}"></script> <script type="text/javascript" src="{{ static('yui_2.9.0/json/json-min.js') }}"></script> <script src="{{ static('prettify/prettify.js') }}" type="text/javascript"></script> <h2>YUI Async Calls to Server Examples</h2> <hr> <h4>Examples of sending information to a server script with JavaScript. </h4> <hr> <div id="example"> <h4>Example 1:</h4> <!-- pymessage example 1, onclick calls pyrequest function --> <label>Python button:</label> <button id="python" type="button" onclick="pyrequest();">Click Me!</button> <p id="pymessage"></p> <hr /> <!-- bbxmessage example 2, onclick calls bbxrequest function --> <h4>Example 2:</h4> <label>BBx button:</label> <button id="bbx" type="button" onclick="bbxrequest();">Click Me!</button> <p id="bbxmessage"></p> <hr /> <h4>Example 3:</h4> <!-- pymessage form example 3, onclick calls pyrequestform function --> <div>Python form example:</div> <form id="pyform"> <label>Agent:</label> <input type="text" name="agent" /> <input type="submit" name="pyformsubmit" value="Submit" /> </form> <hr /> <h4>Example 4:</h4> <!-- pymessage json example 4, onclick calls pyjsonrequest function --> <label>Python JSON button:</label> <button id="pyjson" type="button" onclick="pyjsonrequest();">Click Me!</button> <p id="pyjsonmessage"></p> <br /> </div> <hr> <div id="pyserver"> <h3>Python server:</h3> You can use the Python example from anywhere that you have python available including the G: drive. Just start up the native python cgi server using the instructions below, and load <a href="http://localhost:8000/yuiasync.html">http://localhost:8000/yuiasync.html</a> in the browser. </div> <div> <h5>Unix/Linux/OSX:</h5> Change to wherever this directory is mounted in your terminal(/mnt/dc03/Knowledge Base/Web Development/JavaScript)<br /> <pre class="prettyprint"> $ python -m CGIHTTPServer Serving HTTP on 0.0.0.0 port 8000</pre> </div> <div> <h5>Windows:</h5> Change to G:\Knowledge Base\Web Development\JavaScript<br /> <pre class="prettyprint"> $ c:\path\to\python.exe -m CGIHTTPServer Serving HTTP on 0.0.0.0 port 8000</pre> </div> <div id="code"> <h3>Code:</h3> <h5>JavaScript POST request</h5> <pre class="prettyprint"> var pypostdata = 'agent=5271'; // callback object for pyrequest var pycallback = { // successful call function (just means the call to the server succeeded) success: function(o){ document.getElementById('pymessage').innerHTML = o.responseText; YAHOO.util.Dom.addClass('pymessage', 'msg'); }, // failure function will be called for failed server call failure: function(o){ document.getElementById('pymessage').innerHTML = "Ooops, failure."; YAHOO.util.Dom.addClass('pymessage', 'msg'); } } // function that actually performs the call, uses YUI connection manager var pyrequest = function() { YAHOO.util.Connect.asyncRequest('POST' , '/cgi-bin/pymessage.py' , pycallback , pypostdata); };</pre> <h5>Python - very basic cgi return</h5> <pre class="prettyprint"> #!/usr/bin/env python import cgi if __name__ == "__main__": fs = cgi.FieldStorage() msg = "The agent is " + fs.getfirst('agent', '') print "Content-Type: text/html" print print msg</pre> <h5>JavaScript GET request</h5> <pre class="prettyprint"> var bbxcallback = { // successful call function (just means the call to the server succeeded) success: function(o){ document.getElementById('bbxmessage').innerHTML = o.responseText; YAHOO.util.Dom.addClass('bbxmessage', 'msg'); }, // failure function will be called for failed server call failure: function(o){ document.getElementById('bbxmessage').innerHTML = "Ooops, failure."; YAHOO.util.Dom.addClass('bbxmessage', 'msg'); } } // function that actually performs the call, uses YUI connection manager var bbxrequest = function() { YAHOO.util.Connect.asyncRequest('GET' , '/cgi-bin/bbw.sh?pgm=BBX.MESSAGE&agent=5271' , bbxcallback); };</pre> <h5>BBX - very basic cgi return</h5> <pre class="prettyprint"> REM BBX.MESSAGE REM REM CALL "utcgi.wbb",ENV$,CGI$,ERRMSG$ LET AGENT$=FIELD(CGI$,"agent") LET MSG$="The agent is "+AGENT$ CALL "SUBR.SEND.HTML",MSG$,1 RELEASE</pre> <h3>JSON example</h3> <h5>JavaScript POST with a JSON return</h5> <pre class="prettyprint"> Javascript var pyjsoncallback = { // successful call function (just means the call to the server succeeded) success: function(o) { try { messages = YAHOO.lang.JSON.parse(o.responseText); document.getElementById('pyjsonmessage').innerHTML = messages.msg; YAHOO.util.Dom.addClass('pyjsonmessage', 'msg'); } catch (x) { document.getElementById('pyjsonmessage').innerHTML = 'JSON parse failed!'; YAHOO.util.Dom.addClass('pyjsonmessage', 'msg'); } }, // failure function will be called for failed server call failure: function(o) { msg = "Failure: " + o.msg; alert(msg); } }; // function that uses pyform data to call, uses YUI connection manager var pyjsonrequest = function(event) { var pypostdata = 'agent=4444'; YAHOO.util.Connect.asyncRequest('POST' , '/cgi-bin/pyjsonmessage.py' , pyjsoncallback , pypostdata) }; YAHOO.util.Event.on("pyjsonform", "submit", pyjsoncallback);</pre> <h5>Python returning JSON</h5> <pre class="prettyprint"> #!/usr/bin/env python import cgi import json if __name__ == "__main__": fs = cgi.FieldStorage() agent = fs.getfirst('agent', '') ret = {'msg': 'The agent is {0}'.format(agent)} print "Content-Type: application/json" print print json.dumps(ret)</pre> </div> <!-- Example 1 --> <!-- pymessage, call to python script pymessage.py with method POST --> <script type="text/javascript"> // data for posting to the site in urlencoded format var pypostdata = 'agent=5271'; // callback object for pyrequest var pycallback = { // successful call function (just means the call to the server succeeded) success: function(o){ document.getElementById('pymessage').innerHTML = o.responseText; YAHOO.util.Dom.addClass('pymessage', 'msg'); }, // failure function will be called for failed server call failure: function(o){ document.getElementById('pymessage').innerHTML = "Ooops, failure."; YAHOO.util.Dom.addClass('pymessage', 'msg'); } } // function that actually performs the call, uses YUI connection manager var pyrequest = function() { YAHOO.util.Connect.asyncRequest('POST' , '/cgi-bin/pymessage.py' , pycallback , pypostdata); }; </script> <!-- Example 2 --> <!-- bbxmessage, call to BBx script BBX.MESSGE with method GET --> <script type="text/javascript"> // callback object for bbxrequest var bbxcallback = { // successful call function (just means the call to the server succeeded) success: function(o){ document.getElementById('bbxmessage').innerHTML = o.responseText; YAHOO.util.Dom.addClass('bbxmessage', 'msg'); }, // failure function will be called for failed server call failure: function(o){ document.getElementById('bbxmessage').innerHTML = "Ooops, failure."; YAHOO.util.Dom.addClass('bbxmessage', 'msg'); } } // function that actually performs the call, uses YUI connection manager var bbxrequest = function() { YAHOO.util.Connect.asyncRequest('GET' , '/cgi-bin/bbw.sh?pgm=BBX.MESSAGE&agent=5271' , bbxcallback); }; <!-- Example 3 --> <!-- pyformcallback, call to pymessage.py using a form --> // pyformrequest callback object var pyformcallback = { // successful call function (just means the call to the server succeeded) success: function(o) { alert(o.responseText); }, // failure function will be called for failed server call failure: function(o) { msg = "Failure: " + o.responseText; alert(msg); } }; // function that uses pyform data to call, uses YUI connection manager var pyformrequest = function(event) { YAHOO.util.Event.preventDefault(event); YAHOO.util.Connect.setForm('pyform'); YAHOO.util.Connect.asyncRequest('POST' , '/cgi-bin/pymessage.py' , pyformcallback) }; YAHOO.util.Event.on("pyform", "submit", pyformrequest); <!-- Example 4 --> <!-- pyjsoncallback, call to pymessage.py using JSON --> // pyjsonrequest callback object var pyjsoncallback = { // successful call function (just means the call to the server succeeded) success: function(o) { try { messages = YAHOO.lang.JSON.parse(o.responseText); document.getElementById('pyjsonmessage').innerHTML = messages.msg; YAHOO.util.Dom.addClass('pyjsonmessage', 'msg'); } catch (x) { document.getElementById('pyjsonmessage').innerHTML = 'JSON parse failed!'; YAHOO.util.Dom.addClass('pyjsonmessage', 'msg'); } }, // failure function will be called for failed server call failure: function(o) { msg = "Failure: " + o.msg; alert(msg); } }; // function that uses pyform data to call, uses YUI connection manager var pyjsonrequest = function(event) { var pypostdata = 'agent=4444'; YAHOO.util.Connect.asyncRequest('POST' , '/cgi-bin/pyjsonmessage.py' , pyjsoncallback , pypostdata) }; YAHOO.util.Event.on("pyjsonform", "submit", pyjsoncallback); $(document).ready(function(){prettyPrint();}) </script> {% endblock %}
{ "content_hash": "8eb5091938503bfe4216c2710e609b71", "timestamp": "", "source": "github", "line_count": 297, "max_line_length": 175, "avg_line_length": 39.158249158249156, "alnum_prop": 0.5684436801375753, "repo_name": "chauncey/there-be-docs", "id": "b9d0090d4ee5b3f75068b5b38d25fd2ce009e216", "size": "11630", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "templates/yuiasync.html", "mode": "33188", "license": "mit", "language": [ { "name": "CSS", "bytes": "436813" }, { "name": "HTML", "bytes": "10639963" }, { "name": "JavaScript", "bytes": "8661843" }, { "name": "Python", "bytes": "4581" } ], "symlink_target": "" }
.tagger-piece, .tagger-piece .remove:active, .tagger-piece .remove:hover { text-decoration: none } .tagger-piece { cursor: default; opacity: .75; background-color: #777; display: inline-block; text-align: center; font-weight: 400; font-size: 12px; color: #fff !important; height: 20px; line-height: 20px; padding: 0 20px 0 5px; position: relative; margin: 5px 10px } .tagger-piece:before { content: " "; width: 0; height: 0; position: absolute; top: 0; left: -20px; border: 10px solid transparent; border-right-color: #777 } .tagger-piece:hover { opacity: 1; -webkit-transform: scale(1.05); -moz-transform: scale(1.05); -ms-transform: scale(1.05); transform: scale(1.05) } .tagger-piece .remove { cursor: pointer; color: #fff; position: absolute; top: 0; right: 0; bottom: 0; display: inline-block; width: 17px; -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box } .tagger-piece-LightPink { background-color: #ed5736 } .tagger-piece-LightPink:before { border-right-color: #ed5736 } .tagger-piece-conifer { background-color: #21a675 } .tagger-piece-conifer:before { border-right-color: #21a675 } .tagger-piece-sauce { background-color: #815476 } .tagger-piece-sauce:before { border-right-color: #815476 } .tagger-piece-RedGold { background-color: #f2be45 } .tagger-piece-RedGold:before { border-right-color: #f2be45 } .tagger-piece-ultramarine { background-color: #4c8dae } .tagger-piece-ultramarine:before { border-right-color: #4c8dae } .tagger-piece-swarthy { background-color: #665757 } .tagger-piece-swarthy:before { border-right-color: #665757 } .tagger-piece-ink { background-color: #50616d } .tagger-piece-ink:before { border-right-color: #50616d } .tagger-piece-amber { background-color: #ca6924 } .tagger-piece-amber:before { border-right-color: #ca6924 }
{ "content_hash": "276a40cfebae01adc858c4384c1a607c", "timestamp": "", "source": "github", "line_count": 116, "max_line_length": 74, "avg_line_length": 17.525862068965516, "alnum_prop": 0.6487948844072798, "repo_name": "gavin66/blog", "id": "1ae6f7bf2dddfcc6b6735cf300237e0934d92f5e", "size": "2033", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "public/vendor/tagger-master/dist/tagger.min.css", "mode": "33188", "license": "mit", "language": [ { "name": "ApacheConf", "bytes": "356" }, { "name": "CSS", "bytes": "395826" }, { "name": "JavaScript", "bytes": "196797" }, { "name": "PHP", "bytes": "252906" } ], "symlink_target": "" }
<?xml version="1.0" ?><!DOCTYPE TS><TS language="de" version="2.0"> <defaultcodec>UTF-8</defaultcodec> <context> <name>AboutDialog</name> <message> <location filename="../forms/aboutdialog.ui" line="+14"/> <source>About Nadecoin</source> <translation>Über Nadecoin</translation> </message> <message> <location line="+39"/> <source>&lt;b&gt;Nadecoin&lt;/b&gt; version</source> <translation>&lt;b&gt;Nadecoin&lt;/b&gt;-Version</translation> </message> <message> <location line="+57"/> <source> This is experimental software. Distributed under the MIT/X11 software license, see the accompanying file COPYING or http://www.opensource.org/licenses/mit-license.php. This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit (http://www.openssl.org/) and cryptographic software written by Eric Young (eay@cryptsoft.com) and UPnP software written by Thomas Bernard.</source> <translation> Dies ist experimentelle Software. Veröffentlicht unter der MIT/X11-Softwarelizenz, siehe beiligende Datei COPYING oder http://www.opensource.org/licenses/mit-license.php. Dieses Produkt enthält Software, die vom OpenSSL-Projekt zur Verwendung im OpenSSL-Toolkit (http://www.openssl.org/) entwickelt wurde, sowie kryptographische Software geschrieben von Eric Young (eay@cryptsoft.com) und UPnP-Software geschrieben von Thomas Bernard.</translation> </message> <message> <location filename="../aboutdialog.cpp" line="+14"/> <source>Copyright</source> <translation>Copyright</translation> </message> <message> <location line="+0"/> <source>The Nadecoin developers</source> <translation>Die Nadecoinentwickler</translation> </message> </context> <context> <name>AddressBookPage</name> <message> <location filename="../forms/addressbookpage.ui" line="+14"/> <source>Address Book</source> <translation>Adressbuch</translation> </message> <message> <location line="+19"/> <source>Double-click to edit address or label</source> <translation>Doppelklicken, um die Adresse oder die Bezeichnung zu bearbeiten</translation> </message> <message> <location line="+27"/> <source>Create a new address</source> <translation>Eine neue Adresse erstellen</translation> </message> <message> <location line="+14"/> <source>Copy the currently selected address to the system clipboard</source> <translation>Ausgewählte Adresse in die Zwischenablage kopieren</translation> </message> <message> <location line="-11"/> <source>&amp;New Address</source> <translation>&amp;Neue Adresse</translation> </message> <message> <location filename="../addressbookpage.cpp" line="+63"/> <source>These are your Nadecoin addresses for receiving payments. You may want to give a different one to each sender so you can keep track of who is paying you.</source> <translation>Dies sind Ihre Nadecoin-Adressen zum Empfangen von Zahlungen. Es steht Ihnen frei, jedem Absender eine Andere mitzuteilen, um einen besseren Überblick über eingehende Zahlungen zu erhalten.</translation> </message> <message> <location filename="../forms/addressbookpage.ui" line="+14"/> <source>&amp;Copy Address</source> <translation>Adresse &amp;kopieren</translation> </message> <message> <location line="+11"/> <source>Show &amp;QR Code</source> <translation>&amp;QR-Code anzeigen</translation> </message> <message> <location line="+11"/> <source>Sign a message to prove you own a Nadecoin address</source> <translation>Eine Nachricht signieren, um den Besitz einer Nadecoin-Adresse zu beweisen</translation> </message> <message> <location line="+3"/> <source>Sign &amp;Message</source> <translation>Nachricht &amp;signieren</translation> </message> <message> <location line="+25"/> <source>Delete the currently selected address from the list</source> <translation>Die ausgewählte Adresse aus der Liste entfernen.</translation> </message> <message> <location line="+27"/> <source>Export the data in the current tab to a file</source> <translation>Daten der aktuellen Ansicht in eine Datei exportieren</translation> </message> <message> <location line="+3"/> <source>&amp;Export</source> <translation>E&amp;xportieren</translation> </message> <message> <location line="-44"/> <source>Verify a message to ensure it was signed with a specified Nadecoin address</source> <translation>Eine Nachricht verifizieren, um sicherzustellen, dass diese mit einer angegebenen Nadecoin-Adresse signiert wurde</translation> </message> <message> <location line="+3"/> <source>&amp;Verify Message</source> <translation>Nachricht &amp;verifizieren</translation> </message> <message> <location line="+14"/> <source>&amp;Delete</source> <translation>&amp;Löschen</translation> </message> <message> <location filename="../addressbookpage.cpp" line="-5"/> <source>These are your Nadecoin addresses for sending payments. Always check the amount and the receiving address before sending coins.</source> <translation>Dies sind Ihre Nadecoin-Adressen zum Tätigen von Überweisungen. Bitte prüfen Sie den Betrag und die Empfangsadresse, bevor Sie Nadecoins überweisen.</translation> </message> <message> <location line="+13"/> <source>Copy &amp;Label</source> <translation>&amp;Bezeichnung kopieren</translation> </message> <message> <location line="+1"/> <source>&amp;Edit</source> <translation>&amp;Editieren</translation> </message> <message> <location line="+1"/> <source>Send &amp;Coins</source> <translation>Nadecoins &amp;überweisen</translation> </message> <message> <location line="+260"/> <source>Export Address Book Data</source> <translation>Adressbuch exportieren</translation> </message> <message> <location line="+1"/> <source>Comma separated file (*.csv)</source> <translation>Kommagetrennte-Datei (*.csv)</translation> </message> <message> <location line="+13"/> <source>Error exporting</source> <translation>Fehler beim Exportieren</translation> </message> <message> <location line="+0"/> <source>Could not write to file %1.</source> <translation>Konnte nicht in Datei %1 schreiben.</translation> </message> </context> <context> <name>AddressTableModel</name> <message> <location filename="../addresstablemodel.cpp" line="+144"/> <source>Label</source> <translation>Bezeichnung</translation> </message> <message> <location line="+0"/> <source>Address</source> <translation>Adresse</translation> </message> <message> <location line="+36"/> <source>(no label)</source> <translation>(keine Bezeichnung)</translation> </message> </context> <context> <name>AskPassphraseDialog</name> <message> <location filename="../forms/askpassphrasedialog.ui" line="+26"/> <source>Passphrase Dialog</source> <translation>Passphrasendialog</translation> </message> <message> <location line="+21"/> <source>Enter passphrase</source> <translation>Passphrase eingeben</translation> </message> <message> <location line="+14"/> <source>New passphrase</source> <translation>Neue Passphrase</translation> </message> <message> <location line="+14"/> <source>Repeat new passphrase</source> <translation>Neue Passphrase wiederholen</translation> </message> <message> <location filename="../askpassphrasedialog.cpp" line="+33"/> <source>Enter the new passphrase to the wallet.&lt;br/&gt;Please use a passphrase of &lt;b&gt;10 or more random characters&lt;/b&gt;, or &lt;b&gt;eight or more words&lt;/b&gt;.</source> <translation>Geben Sie die neue Passphrase für die Brieftasche ein.&lt;br&gt;Bitte benutzen Sie eine Passphrase bestehend aus &lt;b&gt;10 oder mehr zufälligen Zeichen&lt;/b&gt; oder &lt;b&gt;8 oder mehr Wörtern&lt;/b&gt;.</translation> </message> <message> <location line="+1"/> <source>Encrypt wallet</source> <translation>Brieftasche verschlüsseln</translation> </message> <message> <location line="+3"/> <source>This operation needs your wallet passphrase to unlock the wallet.</source> <translation>Dieser Vorgang benötigt Ihre Passphrase, um die Brieftasche zu entsperren.</translation> </message> <message> <location line="+5"/> <source>Unlock wallet</source> <translation>Brieftasche entsperren</translation> </message> <message> <location line="+3"/> <source>This operation needs your wallet passphrase to decrypt the wallet.</source> <translation>Dieser Vorgang benötigt Ihre Passphrase, um die Brieftasche zu entschlüsseln.</translation> </message> <message> <location line="+5"/> <source>Decrypt wallet</source> <translation>Brieftasche entschlüsseln</translation> </message> <message> <location line="+3"/> <source>Change passphrase</source> <translation>Passphrase ändern</translation> </message> <message> <location line="+1"/> <source>Enter the old and new passphrase to the wallet.</source> <translation>Geben Sie die alte und neue Passphrase der Brieftasche ein.</translation> </message> <message> <location line="+46"/> <source>Confirm wallet encryption</source> <translation>Verschlüsselung der Brieftasche bestätigen</translation> </message> <message> <location line="+1"/> <source>Warning: If you encrypt your wallet and lose your passphrase, you will &lt;b&gt;LOSE ALL OF YOUR ZETACOINS&lt;/b&gt;!</source> <translation>Warnung: Wenn Sie Ihre Brieftasche verschlüsseln und Ihre Passphrase verlieren, werden Sie &lt;b&gt;alle Ihre Nadecoins verlieren&lt;/b&gt;!</translation> </message> <message> <location line="+0"/> <source>Are you sure you wish to encrypt your wallet?</source> <translation>Sind Sie sich sicher, dass Sie Ihre Brieftasche verschlüsseln möchten?</translation> </message> <message> <location line="+15"/> <source>IMPORTANT: Any previous backups you have made of your wallet file should be replaced with the newly generated, encrypted wallet file. For security reasons, previous backups of the unencrypted wallet file will become useless as soon as you start using the new, encrypted wallet.</source> <translation>WICHTIG: Alle vorherigen Sicherungen Ihrer Brieftasche sollten durch die neu erzeugte, verschlüsselte Brieftasche ersetzt werden. Aus Sicherheitsgründen werden vorherige Sicherungen der unverschlüsselten Brieftasche nutzlos, sobald Sie die neue, verschlüsselte Brieftasche verwenden.</translation> </message> <message> <location line="+100"/> <location line="+24"/> <source>Warning: The Caps Lock key is on!</source> <translation>Warnung: Die Feststelltaste ist aktiviert!</translation> </message> <message> <location line="-130"/> <location line="+58"/> <source>Wallet encrypted</source> <translation>Brieftasche verschlüsselt</translation> </message> <message> <location line="-56"/> <source>Nadecoin will close now to finish the encryption process. Remember that encrypting your wallet cannot fully protect your nadecoins from being stolen by malware infecting your computer.</source> <translation>Nadecoin wird jetzt beendet, um den Verschlüsselungsprozess abzuschließen. Bitte beachten Sie, dass die Verschlüsselung Ihrer Brieftasche nicht vollständig vor Diebstahl Ihrer Nadecoins durch Schadsoftware schützt, die Ihren Computer befällt.</translation> </message> <message> <location line="+13"/> <location line="+7"/> <location line="+42"/> <location line="+6"/> <source>Wallet encryption failed</source> <translation>Verschlüsselung der Brieftasche fehlgeschlagen</translation> </message> <message> <location line="-54"/> <source>Wallet encryption failed due to an internal error. Your wallet was not encrypted.</source> <translation>Die Verschlüsselung der Brieftasche ist aufgrund eines internen Fehlers fehlgeschlagen. Ihre Brieftasche wurde nicht verschlüsselt.</translation> </message> <message> <location line="+7"/> <location line="+48"/> <source>The supplied passphrases do not match.</source> <translation>Die eingegebenen Passphrasen stimmen nicht überein.</translation> </message> <message> <location line="-37"/> <source>Wallet unlock failed</source> <translation>Entsperrung der Brieftasche fehlgeschlagen</translation> </message> <message> <location line="+1"/> <location line="+11"/> <location line="+19"/> <source>The passphrase entered for the wallet decryption was incorrect.</source> <translation>Die eingegebene Passphrase zum Entschlüsseln der Brieftasche war nicht korrekt.</translation> </message> <message> <location line="-20"/> <source>Wallet decryption failed</source> <translation>Entschlüsselung der Brieftasche fehlgeschlagen</translation> </message> <message> <location line="+14"/> <source>Wallet passphrase was successfully changed.</source> <translation>Die Passphrase der Brieftasche wurde erfolgreich geändert.</translation> </message> </context> <context> <name>BitcoinGUI</name> <message> <location filename="../bitcoingui.cpp" line="+233"/> <source>Sign &amp;message...</source> <translation>Nachricht s&amp;ignieren...</translation> </message> <message> <location line="+280"/> <source>Synchronizing with network...</source> <translation>Synchronisiere mit Netzwerk...</translation> </message> <message> <location line="-349"/> <source>&amp;Overview</source> <translation>&amp;Übersicht</translation> </message> <message> <location line="+1"/> <source>Show general overview of wallet</source> <translation>Allgemeine Übersicht der Brieftasche anzeigen</translation> </message> <message> <location line="+20"/> <source>&amp;Transactions</source> <translation>&amp;Transaktionen</translation> </message> <message> <location line="+1"/> <source>Browse transaction history</source> <translation>Transaktionsverlauf durchsehen</translation> </message> <message> <location line="+7"/> <source>Edit the list of stored addresses and labels</source> <translation>Liste der gespeicherten Zahlungsadressen und Bezeichnungen bearbeiten</translation> </message> <message> <location line="-14"/> <source>Show the list of addresses for receiving payments</source> <translation>Liste der Empfangsadressen anzeigen</translation> </message> <message> <location line="+31"/> <source>E&amp;xit</source> <translation>&amp;Beenden</translation> </message> <message> <location line="+1"/> <source>Quit application</source> <translation>Anwendung beenden</translation> </message> <message> <location line="+4"/> <source>Show information about Nadecoin</source> <translation>Informationen über Nadecoin anzeigen</translation> </message> <message> <location line="+2"/> <source>About &amp;Qt</source> <translation>Über &amp;Qt</translation> </message> <message> <location line="+1"/> <source>Show information about Qt</source> <translation>Informationen über Qt anzeigen</translation> </message> <message> <location line="+2"/> <source>&amp;Options...</source> <translation>&amp;Konfiguration...</translation> </message> <message> <location line="+6"/> <source>&amp;Encrypt Wallet...</source> <translation>Brieftasche &amp;verschlüsseln...</translation> </message> <message> <location line="+3"/> <source>&amp;Backup Wallet...</source> <translation>Brieftasche &amp;sichern...</translation> </message> <message> <location line="+2"/> <source>&amp;Change Passphrase...</source> <translation>Passphrase &amp;ändern...</translation> </message> <message> <location line="+285"/> <source>Importing blocks from disk...</source> <translation>Importiere Blöcke von Laufwerk...</translation> </message> <message> <location line="+3"/> <source>Reindexing blocks on disk...</source> <translation>Reindiziere Blöcke auf Laufwerk...</translation> </message> <message> <location line="-347"/> <source>Send coins to a Nadecoin address</source> <translation>Nadecoins an eine Nadecoin-Adresse überweisen</translation> </message> <message> <location line="+49"/> <source>Modify configuration options for Nadecoin</source> <translation>Die Konfiguration des Clients bearbeiten</translation> </message> <message> <location line="+9"/> <source>Backup wallet to another location</source> <translation>Eine Sicherungskopie der Brieftasche erstellen und abspeichern</translation> </message> <message> <location line="+2"/> <source>Change the passphrase used for wallet encryption</source> <translation>Ändert die Passphrase, die für die Verschlüsselung der Brieftasche benutzt wird</translation> </message> <message> <location line="+6"/> <source>&amp;Debug window</source> <translation>&amp;Debugfenster</translation> </message> <message> <location line="+1"/> <source>Open debugging and diagnostic console</source> <translation>Debugging- und Diagnosekonsole öffnen</translation> </message> <message> <location line="-4"/> <source>&amp;Verify message...</source> <translation>Nachricht &amp;verifizieren...</translation> </message> <message> <location line="-165"/> <location line="+530"/> <source>Nadecoin</source> <translation>Nadecoin</translation> </message> <message> <location line="-530"/> <source>Wallet</source> <translation>Brieftasche</translation> </message> <message> <location line="+101"/> <source>&amp;Send</source> <translation>Überweisen</translation> </message> <message> <location line="+7"/> <source>&amp;Receive</source> <translation>&amp;Empfangen</translation> </message> <message> <location line="+14"/> <source>&amp;Addresses</source> <translation>&amp;Adressen</translation> </message> <message> <location line="+22"/> <source>&amp;About Nadecoin</source> <translation>&amp;Über Nadecoin</translation> </message> <message> <location line="+9"/> <source>&amp;Show / Hide</source> <translation>&amp;Anzeigen / Verstecken</translation> </message> <message> <location line="+1"/> <source>Show or hide the main Window</source> <translation>Das Hauptfenster anzeigen oder verstecken</translation> </message> <message> <location line="+3"/> <source>Encrypt the private keys that belong to your wallet</source> <translation>Verschlüsselt die zu Ihrer Brieftasche gehörenden privaten Schlüssel</translation> </message> <message> <location line="+7"/> <source>Sign messages with your Nadecoin addresses to prove you own them</source> <translation>Nachrichten signieren, um den Besitz Ihrer Nadecoin-Adressen zu beweisen</translation> </message> <message> <location line="+2"/> <source>Verify messages to ensure they were signed with specified Nadecoin addresses</source> <translation>Nachrichten verifizieren, um sicherzustellen, dass diese mit den angegebenen Nadecoin-Adressen signiert wurden</translation> </message> <message> <location line="+28"/> <source>&amp;File</source> <translation>&amp;Datei</translation> </message> <message> <location line="+7"/> <source>&amp;Settings</source> <translation>&amp;Einstellungen</translation> </message> <message> <location line="+6"/> <source>&amp;Help</source> <translation>&amp;Hilfe</translation> </message> <message> <location line="+9"/> <source>Tabs toolbar</source> <translation>Registerkartenleiste</translation> </message> <message> <location line="+17"/> <location line="+10"/> <source>[testnet]</source> <translation>[Testnetz]</translation> </message> <message> <location line="+47"/> <source>Nadecoin client</source> <translation>Nadecoin-Client</translation> </message> <message numerus="yes"> <location line="+141"/> <source>%n active connection(s) to Nadecoin network</source> <translation><numerusform>%n aktive Verbindung zum Nadecoin-Netzwerk</numerusform><numerusform>%n aktive Verbindungen zum Nadecoin-Netzwerk</numerusform></translation> </message> <message> <location line="+22"/> <source>No block source available...</source> <translation>Keine Blockquelle verfügbar...</translation> </message> <message> <location line="+12"/> <source>Processed %1 of %2 (estimated) blocks of transaction history.</source> <translation>%1 von (geschätzten) %2 Blöcken des Transaktionsverlaufs verarbeitet.</translation> </message> <message> <location line="+4"/> <source>Processed %1 blocks of transaction history.</source> <translation>%1 Blöcke des Transaktionsverlaufs verarbeitet.</translation> </message> <message numerus="yes"> <location line="+20"/> <source>%n hour(s)</source> <translation><numerusform>%n Stunde</numerusform><numerusform>%n Stunden</numerusform></translation> </message> <message numerus="yes"> <location line="+4"/> <source>%n day(s)</source> <translation><numerusform>%n Tag</numerusform><numerusform>%n Tage</numerusform></translation> </message> <message numerus="yes"> <location line="+4"/> <source>%n week(s)</source> <translation><numerusform>%n Woche</numerusform><numerusform>%n Wochen</numerusform></translation> </message> <message> <location line="+4"/> <source>%1 behind</source> <translation>%1 im Rückstand</translation> </message> <message> <location line="+14"/> <source>Last received block was generated %1 ago.</source> <translation>Der letzte empfangene Block ist %1 alt.</translation> </message> <message> <location line="+2"/> <source>Transactions after this will not yet be visible.</source> <translation>Transaktionen hiernach werden noch nicht angezeigt.</translation> </message> <message> <location line="+22"/> <source>Error</source> <translation>Fehler</translation> </message> <message> <location line="+3"/> <source>Warning</source> <translation>Warnung</translation> </message> <message> <location line="+3"/> <source>Information</source> <translation>Hinweis</translation> </message> <message> <location line="+70"/> <source>This transaction is over the size limit. You can still send it for a fee of %1, which goes to the nodes that process your transaction and helps to support the network. Do you want to pay the fee?</source> <translation>Die Transaktion übersteigt das Größenlimit. Sie können sie trotzdem senden, wenn Sie eine zusätzliche Transaktionsgebühr in Höhe von %1 zahlen. Diese wird an die Knoten verteilt, die Ihre Transaktion bearbeiten und unterstützt damit das Nadecoin-Netzwerk. Möchten Sie die Gebühr bezahlen?</translation> </message> <message> <location line="-140"/> <source>Up to date</source> <translation>Auf aktuellem Stand</translation> </message> <message> <location line="+31"/> <source>Catching up...</source> <translation>Hole auf...</translation> </message> <message> <location line="+113"/> <source>Confirm transaction fee</source> <translation>Transaktionsgebühr bestätigen</translation> </message> <message> <location line="+8"/> <source>Sent transaction</source> <translation>Gesendete Transaktion</translation> </message> <message> <location line="+0"/> <source>Incoming transaction</source> <translation>Eingehende Transaktion</translation> </message> <message> <location line="+1"/> <source>Date: %1 Amount: %2 Type: %3 Address: %4 </source> <translation>Datum: %1 Betrag: %2 Typ: %3 Adresse: %4</translation> </message> <message> <location line="+33"/> <location line="+23"/> <source>URI handling</source> <translation>URI Verarbeitung</translation> </message> <message> <location line="-23"/> <location line="+23"/> <source>URI can not be parsed! This can be caused by an invalid Nadecoin address or malformed URI parameters.</source> <translation>URI kann nicht analysiert werden! Dies kann durch eine ungültige Nadecoin-Adresse oder fehlerhafte URI-Parameter verursacht werden.</translation> </message> <message> <location line="+17"/> <source>Wallet is &lt;b&gt;encrypted&lt;/b&gt; and currently &lt;b&gt;unlocked&lt;/b&gt;</source> <translation>Brieftasche ist &lt;b&gt;verschlüsselt&lt;/b&gt; und aktuell &lt;b&gt;entsperrt&lt;/b&gt;</translation> </message> <message> <location line="+8"/> <source>Wallet is &lt;b&gt;encrypted&lt;/b&gt; and currently &lt;b&gt;locked&lt;/b&gt;</source> <translation>Brieftasche ist &lt;b&gt;verschlüsselt&lt;/b&gt; und aktuell &lt;b&gt;gesperrt&lt;/b&gt;</translation> </message> <message> <location filename="../bitcoin.cpp" line="+111"/> <source>A fatal error occurred. Nadecoin can no longer continue safely and will quit.</source> <translation>Ein schwerer Fehler ist aufgetreten. Nadecoin kann nicht stabil weiter ausgeführt werden und wird beendet.</translation> </message> </context> <context> <name>ClientModel</name> <message> <location filename="../clientmodel.cpp" line="+104"/> <source>Network Alert</source> <translation>Netzwerkalarm</translation> </message> </context> <context> <name>EditAddressDialog</name> <message> <location filename="../forms/editaddressdialog.ui" line="+14"/> <source>Edit Address</source> <translation>Adresse bearbeiten</translation> </message> <message> <location line="+11"/> <source>&amp;Label</source> <translation>&amp;Bezeichnung</translation> </message> <message> <location line="+10"/> <source>The label associated with this address book entry</source> <translation>Die Bezeichnung dieses Adressbuchseintrags</translation> </message> <message> <location line="+7"/> <source>&amp;Address</source> <translation>&amp;Adresse</translation> </message> <message> <location line="+10"/> <source>The address associated with this address book entry. This can only be modified for sending addresses.</source> <translation>Die Adresse des Adressbucheintrags. Diese kann nur für Zahlungsadressen bearbeitet werden.</translation> </message> <message> <location filename="../editaddressdialog.cpp" line="+21"/> <source>New receiving address</source> <translation>Neue Empfangsadresse</translation> </message> <message> <location line="+4"/> <source>New sending address</source> <translation>Neue Zahlungsadresse</translation> </message> <message> <location line="+3"/> <source>Edit receiving address</source> <translation>Empfangsadresse bearbeiten</translation> </message> <message> <location line="+4"/> <source>Edit sending address</source> <translation>Zahlungsadresse bearbeiten</translation> </message> <message> <location line="+76"/> <source>The entered address &quot;%1&quot; is already in the address book.</source> <translation>Die eingegebene Adresse &quot;%1&quot; befindet sich bereits im Adressbuch.</translation> </message> <message> <location line="-5"/> <source>The entered address &quot;%1&quot; is not a valid Nadecoin address.</source> <translation>Die eingegebene Adresse &quot;%1&quot; ist keine gültige Nadecoin-Adresse.</translation> </message> <message> <location line="+10"/> <source>Could not unlock wallet.</source> <translation>Die Brieftasche konnte nicht entsperrt werden.</translation> </message> <message> <location line="+5"/> <source>New key generation failed.</source> <translation>Generierung eines neuen Schlüssels fehlgeschlagen.</translation> </message> </context> <context> <name>GUIUtil::HelpMessageBox</name> <message> <location filename="../guiutil.cpp" line="+424"/> <location line="+12"/> <source>Nadecoin-Qt</source> <translation>Nadecoin-Qt</translation> </message> <message> <location line="-12"/> <source>version</source> <translation>Version</translation> </message> <message> <location line="+2"/> <source>Usage:</source> <translation>Benutzung:</translation> </message> <message> <location line="+1"/> <source>command-line options</source> <translation>Kommandozeilenoptionen</translation> </message> <message> <location line="+4"/> <source>UI options</source> <translation>UI-Optionen</translation> </message> <message> <location line="+1"/> <source>Set language, for example &quot;de_DE&quot; (default: system locale)</source> <translation>Sprache festlegen, z.B. &quot;de_DE&quot; (Standard: System Locale)</translation> </message> <message> <location line="+1"/> <source>Start minimized</source> <translation>Minimiert starten</translation> </message> <message> <location line="+1"/> <source>Show splash screen on startup (default: 1)</source> <translation>Startbildschirm beim Starten anzeigen (Standard: 1)</translation> </message> </context> <context> <name>OptionsDialog</name> <message> <location filename="../forms/optionsdialog.ui" line="+14"/> <source>Options</source> <translation>Erweiterte Einstellungen</translation> </message> <message> <location line="+16"/> <source>&amp;Main</source> <translation>&amp;Allgemein</translation> </message> <message> <location line="+6"/> <source>Optional transaction fee per kB that helps make sure your transactions are processed quickly. Most transactions are 1 kB.</source> <translation>Optionale Transaktionsgebühr pro KB, die sicherstellt, dass Ihre Transaktionen schnell bearbeitet werden. Die meisten Transaktionen sind 1 kB groß.</translation> </message> <message> <location line="+15"/> <source>Pay transaction &amp;fee</source> <translation>Transaktions&amp;gebühr bezahlen</translation> </message> <message> <location line="+31"/> <source>Automatically start Nadecoin after logging in to the system.</source> <translation>Nadecoin nach der Anmeldung am System automatisch ausführen.</translation> </message> <message> <location line="+3"/> <source>&amp;Start Nadecoin on system login</source> <translation>&amp;Starte Nadecoin nach Systemanmeldung</translation> </message> <message> <location line="+35"/> <source>Reset all client options to default.</source> <translation>Setzt die Clientkonfiguration auf Standardwerte zurück.</translation> </message> <message> <location line="+3"/> <source>&amp;Reset Options</source> <translation>Konfiguration &amp;zurücksetzen</translation> </message> <message> <location line="+13"/> <source>&amp;Network</source> <translation>&amp;Netzwerk</translation> </message> <message> <location line="+6"/> <source>Automatically open the Nadecoin client port on the router. This only works when your router supports UPnP and it is enabled.</source> <translation>Automatisch den Nadecoin-Clientport auf dem Router öffnen. Dies funktioniert nur, wenn Ihr Router UPnP unterstützt und dies aktiviert ist.</translation> </message> <message> <location line="+3"/> <source>Map port using &amp;UPnP</source> <translation>Portweiterleitung via &amp;UPnP</translation> </message> <message> <location line="+7"/> <source>Connect to the Nadecoin network through a SOCKS proxy (e.g. when connecting through Tor).</source> <translation>Über einen SOCKS-Proxy mit dem Nadecoin-Netzwerk verbinden (z.B. beim Verbinden über Tor).</translation> </message> <message> <location line="+3"/> <source>&amp;Connect through SOCKS proxy:</source> <translation>Über einen SOCKS-Proxy &amp;verbinden:</translation> </message> <message> <location line="+9"/> <source>Proxy &amp;IP:</source> <translation>Proxy-&amp;IP:</translation> </message> <message> <location line="+19"/> <source>IP address of the proxy (e.g. 127.0.0.1)</source> <translation>IP-Adresse des Proxies (z.B. 127.0.0.1)</translation> </message> <message> <location line="+7"/> <source>&amp;Port:</source> <translation>&amp;Port:</translation> </message> <message> <location line="+19"/> <source>Port of the proxy (e.g. 9050)</source> <translation>Port des Proxies (z.B. 9050)</translation> </message> <message> <location line="+7"/> <source>SOCKS &amp;Version:</source> <translation>SOCKS-&amp;Version:</translation> </message> <message> <location line="+13"/> <source>SOCKS version of the proxy (e.g. 5)</source> <translation>SOCKS-Version des Proxies (z.B. 5)</translation> </message> <message> <location line="+36"/> <source>&amp;Window</source> <translation>&amp;Programmfenster</translation> </message> <message> <location line="+6"/> <source>Show only a tray icon after minimizing the window.</source> <translation>Nur ein Symbol im Infobereich anzeigen, nachdem das Programmfenster minimiert wurde.</translation> </message> <message> <location line="+3"/> <source>&amp;Minimize to the tray instead of the taskbar</source> <translation>In den Infobereich anstatt in die Taskleiste &amp;minimieren</translation> </message> <message> <location line="+7"/> <source>Minimize instead of exit the application when the window is closed. When this option is enabled, the application will be closed only after selecting Quit in the menu.</source> <translation>Minimiert die Anwendung anstatt sie zu beenden wenn das Fenster geschlossen wird. Wenn dies aktiviert ist, müssen Sie das Programm über &quot;Beenden&quot; im Menü schließen.</translation> </message> <message> <location line="+3"/> <source>M&amp;inimize on close</source> <translation>Beim Schließen m&amp;inimieren</translation> </message> <message> <location line="+21"/> <source>&amp;Display</source> <translation>&amp;Anzeige</translation> </message> <message> <location line="+8"/> <source>User Interface &amp;language:</source> <translation>&amp;Sprache der Benutzeroberfläche:</translation> </message> <message> <location line="+13"/> <source>The user interface language can be set here. This setting will take effect after restarting Nadecoin.</source> <translation>Legt die Sprache der Benutzeroberfläche fest. Diese Einstellung wird erst nach einem Neustart von Nadecoin aktiv.</translation> </message> <message> <location line="+11"/> <source>&amp;Unit to show amounts in:</source> <translation>&amp;Einheit der Beträge:</translation> </message> <message> <location line="+13"/> <source>Choose the default subdivision unit to show in the interface and when sending coins.</source> <translation>Wählen Sie die Standarduntereinheit, die in der Benutzeroberfläche und beim Überweisen von Nadecoins angezeigt werden soll.</translation> </message> <message> <location line="+9"/> <source>Whether to show Nadecoin addresses in the transaction list or not.</source> <translation>Legt fest, ob Nadecoin-Adressen in der Transaktionsliste angezeigt werden.</translation> </message> <message> <location line="+3"/> <source>&amp;Display addresses in transaction list</source> <translation>Adressen in der Transaktionsliste &amp;anzeigen</translation> </message> <message> <location line="+71"/> <source>&amp;OK</source> <translation>&amp;OK</translation> </message> <message> <location line="+7"/> <source>&amp;Cancel</source> <translation>&amp;Abbrechen</translation> </message> <message> <location line="+10"/> <source>&amp;Apply</source> <translation>&amp;Übernehmen</translation> </message> <message> <location filename="../optionsdialog.cpp" line="+53"/> <source>default</source> <translation>Standard</translation> </message> <message> <location line="+130"/> <source>Confirm options reset</source> <translation>Zurücksetzen der Konfiguration bestätigen</translation> </message> <message> <location line="+1"/> <source>Some settings may require a client restart to take effect.</source> <translation>Einige Einstellungen benötigen möglicherweise einen Clientneustart, um aktiv zu werden.</translation> </message> <message> <location line="+0"/> <source>Do you want to proceed?</source> <translation>Wollen Sie fortfahren?</translation> </message> <message> <location line="+42"/> <location line="+9"/> <source>Warning</source> <translation>Warnung</translation> </message> <message> <location line="-9"/> <location line="+9"/> <source>This setting will take effect after restarting Nadecoin.</source> <translation>Diese Einstellung wird erst nach einem Neustart von Nadecoin aktiv.</translation> </message> <message> <location line="+29"/> <source>The supplied proxy address is invalid.</source> <translation>Die eingegebene Proxyadresse ist ungültig.</translation> </message> </context> <context> <name>OverviewPage</name> <message> <location filename="../forms/overviewpage.ui" line="+14"/> <source>Form</source> <translation>Formular</translation> </message> <message> <location line="+50"/> <location line="+166"/> <source>The displayed information may be out of date. Your wallet automatically synchronizes with the Nadecoin network after a connection is established, but this process has not completed yet.</source> <translation>Die angezeigten Informationen sind möglicherweise nicht mehr aktuell. Ihre Brieftasche wird automatisch synchronisiert, nachdem eine Verbindung zum Nadecoin-Netzwerk hergestellt wurde. Dieser Prozess ist jedoch derzeit noch nicht abgeschlossen.</translation> </message> <message> <location line="-124"/> <source>Balance:</source> <translation>Kontostand:</translation> </message> <message> <location line="+29"/> <source>Unconfirmed:</source> <translation>Unbestätigt:</translation> </message> <message> <location line="-78"/> <source>Wallet</source> <translation>Brieftasche</translation> </message> <message> <location line="+107"/> <source>Immature:</source> <translation>Unreif:</translation> </message> <message> <location line="+13"/> <source>Mined balance that has not yet matured</source> <translation>Erarbeiteter Betrag der noch nicht gereift ist</translation> </message> <message> <location line="+46"/> <source>&lt;b&gt;Recent transactions&lt;/b&gt;</source> <translation>&lt;b&gt;Letzte Transaktionen&lt;/b&gt;</translation> </message> <message> <location line="-101"/> <source>Your current balance</source> <translation>Ihr aktueller Kontostand</translation> </message> <message> <location line="+29"/> <source>Total of transactions that have yet to be confirmed, and do not yet count toward the current balance</source> <translation>Betrag aus unbestätigten Transaktionen, der noch nicht im aktuellen Kontostand enthalten ist</translation> </message> <message> <location filename="../overviewpage.cpp" line="+116"/> <location line="+1"/> <source>out of sync</source> <translation>nicht synchron</translation> </message> </context> <context> <name>PaymentServer</name> <message> <location filename="../paymentserver.cpp" line="+107"/> <source>Cannot start nadecoin: click-to-pay handler</source> <translation>&quot;nadecoin: Klicken-zum-Bezahlen&quot;-Handler konnte nicht gestartet werden</translation> </message> </context> <context> <name>QRCodeDialog</name> <message> <location filename="../forms/qrcodedialog.ui" line="+14"/> <source>QR Code Dialog</source> <translation>QR-Code-Dialog</translation> </message> <message> <location line="+59"/> <source>Request Payment</source> <translation>Zahlung anfordern</translation> </message> <message> <location line="+56"/> <source>Amount:</source> <translation>Betrag:</translation> </message> <message> <location line="-44"/> <source>Label:</source> <translation>Bezeichnung:</translation> </message> <message> <location line="+19"/> <source>Message:</source> <translation>Nachricht:</translation> </message> <message> <location line="+71"/> <source>&amp;Save As...</source> <translation>&amp;Speichern unter...</translation> </message> <message> <location filename="../qrcodedialog.cpp" line="+62"/> <source>Error encoding URI into QR Code.</source> <translation>Fehler beim Kodieren der URI in den QR-Code.</translation> </message> <message> <location line="+40"/> <source>The entered amount is invalid, please check.</source> <translation>Der eingegebene Betrag ist ungültig, bitte überprüfen.</translation> </message> <message> <location line="+23"/> <source>Resulting URI too long, try to reduce the text for label / message.</source> <translation>Resultierende URI zu lang, bitte den Text für Bezeichnung / Nachricht kürzen.</translation> </message> <message> <location line="+25"/> <source>Save QR Code</source> <translation>QR-Code abspeichern</translation> </message> <message> <location line="+0"/> <source>PNG Images (*.png)</source> <translation>PNG-Bild (*.png)</translation> </message> </context> <context> <name>RPCConsole</name> <message> <location filename="../forms/rpcconsole.ui" line="+46"/> <source>Client name</source> <translation>Clientname</translation> </message> <message> <location line="+10"/> <location line="+23"/> <location line="+26"/> <location line="+23"/> <location line="+23"/> <location line="+36"/> <location line="+53"/> <location line="+23"/> <location line="+23"/> <location filename="../rpcconsole.cpp" line="+339"/> <source>N/A</source> <translation>n.v.</translation> </message> <message> <location line="-217"/> <source>Client version</source> <translation>Clientversion</translation> </message> <message> <location line="-45"/> <source>&amp;Information</source> <translation>&amp;Information</translation> </message> <message> <location line="+68"/> <source>Using OpenSSL version</source> <translation>Verwendete OpenSSL-Version</translation> </message> <message> <location line="+49"/> <source>Startup time</source> <translation>Startzeit</translation> </message> <message> <location line="+29"/> <source>Network</source> <translation>Netzwerk</translation> </message> <message> <location line="+7"/> <source>Number of connections</source> <translation>Anzahl Verbindungen</translation> </message> <message> <location line="+23"/> <source>On testnet</source> <translation>Im Testnetz</translation> </message> <message> <location line="+23"/> <source>Block chain</source> <translation>Blockkette</translation> </message> <message> <location line="+7"/> <source>Current number of blocks</source> <translation>Aktuelle Anzahl Blöcke</translation> </message> <message> <location line="+23"/> <source>Estimated total blocks</source> <translation>Geschätzte Gesamtzahl Blöcke</translation> </message> <message> <location line="+23"/> <source>Last block time</source> <translation>Letzte Blockzeit</translation> </message> <message> <location line="+52"/> <source>&amp;Open</source> <translation>&amp;Öffnen</translation> </message> <message> <location line="+16"/> <source>Command-line options</source> <translation>Kommandozeilenoptionen</translation> </message> <message> <location line="+7"/> <source>Show the Nadecoin-Qt help message to get a list with possible Nadecoin command-line options.</source> <translation>Zeige die Nadecoin-Qt-Hilfsnachricht, um eine Liste mit möglichen Kommandozeilenoptionen zu erhalten.</translation> </message> <message> <location line="+3"/> <source>&amp;Show</source> <translation>&amp;Anzeigen</translation> </message> <message> <location line="+24"/> <source>&amp;Console</source> <translation>&amp;Konsole</translation> </message> <message> <location line="-260"/> <source>Build date</source> <translation>Erstellungsdatum</translation> </message> <message> <location line="-104"/> <source>Nadecoin - Debug window</source> <translation>Nadecoin - Debugfenster</translation> </message> <message> <location line="+25"/> <source>Nadecoin Core</source> <translation>Nadecoin-Kern</translation> </message> <message> <location line="+279"/> <source>Debug log file</source> <translation>Debugprotokolldatei</translation> </message> <message> <location line="+7"/> <source>Open the Nadecoin debug log file from the current data directory. This can take a few seconds for large log files.</source> <translation>Öffnet die Nadecoin-Debugprotokolldatei aus dem aktuellen Datenverzeichnis. Dies kann bei großen Protokolldateien einige Sekunden dauern.</translation> </message> <message> <location line="+102"/> <source>Clear console</source> <translation>Konsole zurücksetzen</translation> </message> <message> <location filename="../rpcconsole.cpp" line="-30"/> <source>Welcome to the Nadecoin RPC console.</source> <translation>Willkommen in der Nadecoin-RPC-Konsole.</translation> </message> <message> <location line="+1"/> <source>Use up and down arrows to navigate history, and &lt;b&gt;Ctrl-L&lt;/b&gt; to clear screen.</source> <translation>Pfeiltaste hoch und runter, um die Historie durchzublättern und &lt;b&gt;Strg-L&lt;/b&gt;, um die Konsole zurückzusetzen.</translation> </message> <message> <location line="+1"/> <source>Type &lt;b&gt;help&lt;/b&gt; for an overview of available commands.</source> <translation>Bitte &lt;b&gt;help&lt;/b&gt; eingeben, um eine Übersicht verfügbarer Befehle zu erhalten.</translation> </message> </context> <context> <name>SendCoinsDialog</name> <message> <location filename="../forms/sendcoinsdialog.ui" line="+14"/> <location filename="../sendcoinsdialog.cpp" line="+124"/> <location line="+5"/> <location line="+5"/> <location line="+5"/> <location line="+6"/> <location line="+5"/> <location line="+5"/> <source>Send Coins</source> <translation>Nadecoins überweisen</translation> </message> <message> <location line="+50"/> <source>Send to multiple recipients at once</source> <translation>In einer Transaktion an mehrere Empfänger auf einmal überweisen</translation> </message> <message> <location line="+3"/> <source>Add &amp;Recipient</source> <translation>Empfänger &amp;hinzufügen</translation> </message> <message> <location line="+20"/> <source>Remove all transaction fields</source> <translation>Alle Überweisungsfelder zurücksetzen</translation> </message> <message> <location line="+3"/> <source>Clear &amp;All</source> <translation>&amp;Zurücksetzen</translation> </message> <message> <location line="+22"/> <source>Balance:</source> <translation>Kontostand:</translation> </message> <message> <location line="+10"/> <source>123.456 BTC</source> <translation>123.456 BTC</translation> </message> <message> <location line="+31"/> <source>Confirm the send action</source> <translation>Überweisung bestätigen</translation> </message> <message> <location line="+3"/> <source>S&amp;end</source> <translation>&amp;Überweisen</translation> </message> <message> <location filename="../sendcoinsdialog.cpp" line="-59"/> <source>&lt;b&gt;%1&lt;/b&gt; to %2 (%3)</source> <translation>&lt;b&gt;%1&lt;/b&gt; an %2 (%3)</translation> </message> <message> <location line="+5"/> <source>Confirm send coins</source> <translation>Überweisung bestätigen</translation> </message> <message> <location line="+1"/> <source>Are you sure you want to send %1?</source> <translation>Sind Sie sich sicher, dass Sie die folgende Überweisung ausführen möchten?&lt;br&gt;%1</translation> </message> <message> <location line="+0"/> <source> and </source> <translation> und </translation> </message> <message> <location line="+23"/> <source>The recipient address is not valid, please recheck.</source> <translation>Die Zahlungsadresse ist ungültig, bitte nochmals überprüfen.</translation> </message> <message> <location line="+5"/> <source>The amount to pay must be larger than 0.</source> <translation>Der zu zahlende Betrag muss größer als 0 sein.</translation> </message> <message> <location line="+5"/> <source>The amount exceeds your balance.</source> <translation>Der angegebene Betrag übersteigt Ihren Kontostand.</translation> </message> <message> <location line="+5"/> <source>The total exceeds your balance when the %1 transaction fee is included.</source> <translation>Der angegebene Betrag übersteigt aufgrund der Transaktionsgebühr in Höhe von %1 Ihren Kontostand.</translation> </message> <message> <location line="+6"/> <source>Duplicate address found, can only send to each address once per send operation.</source> <translation>Doppelte Adresse gefunden, pro Überweisung kann an jede Adresse nur einmalig etwas überwiesen werden.</translation> </message> <message> <location line="+5"/> <source>Error: Transaction creation failed!</source> <translation>Fehler: Transaktionserstellung fehlgeschlagen!</translation> </message> <message> <location line="+5"/> <source>Error: The transaction was rejected. This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here.</source> <translation>Fehler: Die Transaktion wurde abgelehnt. Dies kann passieren, wenn einige Nadecoins aus Ihrer Brieftasche bereits ausgegeben wurden. Beispielsweise weil Sie eine Kopie Ihrer wallet.dat genutzt, die Nadecoins dort ausgegeben haben und dies daher in der derzeit aktiven Brieftasche nicht vermerkt ist.</translation> </message> </context> <context> <name>SendCoinsEntry</name> <message> <location filename="../forms/sendcoinsentry.ui" line="+14"/> <source>Form</source> <translation>Formular</translation> </message> <message> <location line="+15"/> <source>A&amp;mount:</source> <translation>&amp;Betrag:</translation> </message> <message> <location line="+13"/> <source>Pay &amp;To:</source> <translation>&amp;Empfänger:</translation> </message> <message> <location line="+34"/> <source>The address to send the payment to (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> <translation>Die Zahlungsadresse der Überweisung (z.B. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> </message> <message> <location line="+60"/> <location filename="../sendcoinsentry.cpp" line="+26"/> <source>Enter a label for this address to add it to your address book</source> <translation>Adressbezeichnung eingeben (diese wird zusammen mit der Adresse dem Adressbuch hinzugefügt)</translation> </message> <message> <location line="-78"/> <source>&amp;Label:</source> <translation>&amp;Bezeichnung:</translation> </message> <message> <location line="+28"/> <source>Choose address from address book</source> <translation>Adresse aus Adressbuch wählen</translation> </message> <message> <location line="+10"/> <source>Alt+A</source> <translation>Alt+A</translation> </message> <message> <location line="+7"/> <source>Paste address from clipboard</source> <translation>Adresse aus der Zwischenablage einfügen</translation> </message> <message> <location line="+10"/> <source>Alt+P</source> <translation>Alt+P</translation> </message> <message> <location line="+7"/> <source>Remove this recipient</source> <translation>Diesen Empfänger entfernen</translation> </message> <message> <location filename="../sendcoinsentry.cpp" line="+1"/> <source>Enter a Nadecoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> <translation>Nadecoin-Adresse eingeben (z.B. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> </message> </context> <context> <name>SignVerifyMessageDialog</name> <message> <location filename="../forms/signverifymessagedialog.ui" line="+14"/> <source>Signatures - Sign / Verify a Message</source> <translation>Signaturen - eine Nachricht signieren / verifizieren</translation> </message> <message> <location line="+13"/> <source>&amp;Sign Message</source> <translation>Nachricht &amp;signieren</translation> </message> <message> <location line="+6"/> <source>You can sign messages with your addresses to prove you own them. Be careful not to sign anything vague, as phishing attacks may try to trick you into signing your identity over to them. Only sign fully-detailed statements you agree to.</source> <translation>Sie können Nachrichten mit Ihren Adressen signieren, um den Besitz dieser Adressen zu beweisen. Bitte nutzen Sie diese Funktion mit Vorsicht und nehmen Sie sich vor Phishingangriffen in Acht. Signieren Sie nur Nachrichten, mit denen Sie vollständig einverstanden sind.</translation> </message> <message> <location line="+18"/> <source>The address to sign the message with (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> <translation>Die Adresse mit der die Nachricht signiert wird (z.B. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> </message> <message> <location line="+10"/> <location line="+213"/> <source>Choose an address from the address book</source> <translation>Eine Adresse aus dem Adressbuch wählen</translation> </message> <message> <location line="-203"/> <location line="+213"/> <source>Alt+A</source> <translation>Alt+A</translation> </message> <message> <location line="-203"/> <source>Paste address from clipboard</source> <translation>Adresse aus der Zwischenablage einfügen</translation> </message> <message> <location line="+10"/> <source>Alt+P</source> <translation>Alt+P</translation> </message> <message> <location line="+12"/> <source>Enter the message you want to sign here</source> <translation>Zu signierende Nachricht hier eingeben</translation> </message> <message> <location line="+7"/> <source>Signature</source> <translation>Signatur</translation> </message> <message> <location line="+27"/> <source>Copy the current signature to the system clipboard</source> <translation>Aktuelle Signatur in die Zwischenablage kopieren</translation> </message> <message> <location line="+21"/> <source>Sign the message to prove you own this Nadecoin address</source> <translation>Die Nachricht signieren, um den Besitz dieser Nadecoin-Adresse zu beweisen</translation> </message> <message> <location line="+3"/> <source>Sign &amp;Message</source> <translation>&amp;Nachricht signieren</translation> </message> <message> <location line="+14"/> <source>Reset all sign message fields</source> <translation>Alle &quot;Nachricht signieren&quot;-Felder zurücksetzen</translation> </message> <message> <location line="+3"/> <location line="+146"/> <source>Clear &amp;All</source> <translation>&amp;Zurücksetzen</translation> </message> <message> <location line="-87"/> <source>&amp;Verify Message</source> <translation>Nachricht &amp;verifizieren</translation> </message> <message> <location line="+6"/> <source>Enter the signing address, message (ensure you copy line breaks, spaces, tabs, etc. exactly) and signature below to verify the message. Be careful not to read more into the signature than what is in the signed message itself, to avoid being tricked by a man-in-the-middle attack.</source> <translation>Geben Sie die signierende Adresse, Nachricht (achten Sie darauf Zeilenumbrüche, Leerzeichen, Tabulatoren usw. exakt zu kopieren) und Signatur unten ein, um die Nachricht zu verifizieren. Vorsicht, interpretieren Sie nicht mehr in die Signatur, als in der signierten Nachricht selber enthalten ist, um nicht von einerm Man-in-the-middle-Angriff hinters Licht geführt zu werden.</translation> </message> <message> <location line="+21"/> <source>The address the message was signed with (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> <translation>Die Adresse mit der die Nachricht signiert wurde (z.B. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> </message> <message> <location line="+40"/> <source>Verify the message to ensure it was signed with the specified Nadecoin address</source> <translation>Die Nachricht verifizieren, um sicherzustellen, dass diese mit der angegebenen Nadecoin-Adresse signiert wurde</translation> </message> <message> <location line="+3"/> <source>Verify &amp;Message</source> <translation>&amp;Nachricht verifizieren</translation> </message> <message> <location line="+14"/> <source>Reset all verify message fields</source> <translation>Alle &quot;Nachricht verifizieren&quot;-Felder zurücksetzen</translation> </message> <message> <location filename="../signverifymessagedialog.cpp" line="+27"/> <location line="+3"/> <source>Enter a Nadecoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</source> <translation>Nadecoin-Adresse eingeben (z.B. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)</translation> </message> <message> <location line="-2"/> <source>Click &quot;Sign Message&quot; to generate signature</source> <translation>Auf &quot;Nachricht signieren&quot; klicken, um die Signatur zu erzeugen</translation> </message> <message> <location line="+3"/> <source>Enter Nadecoin signature</source> <translation>Nadecoin-Signatur eingeben</translation> </message> <message> <location line="+82"/> <location line="+81"/> <source>The entered address is invalid.</source> <translation>Die eingegebene Adresse ist ungültig.</translation> </message> <message> <location line="-81"/> <location line="+8"/> <location line="+73"/> <location line="+8"/> <source>Please check the address and try again.</source> <translation>Bitte überprüfen Sie die Adresse und versuchen Sie es erneut.</translation> </message> <message> <location line="-81"/> <location line="+81"/> <source>The entered address does not refer to a key.</source> <translation>Die eingegebene Adresse verweist nicht auf einen Schlüssel.</translation> </message> <message> <location line="-73"/> <source>Wallet unlock was cancelled.</source> <translation>Entsperrung der Brieftasche wurde abgebrochen.</translation> </message> <message> <location line="+8"/> <source>Private key for the entered address is not available.</source> <translation>Privater Schlüssel zur eingegebenen Adresse ist nicht verfügbar.</translation> </message> <message> <location line="+12"/> <source>Message signing failed.</source> <translation>Signierung der Nachricht fehlgeschlagen.</translation> </message> <message> <location line="+5"/> <source>Message signed.</source> <translation>Nachricht signiert.</translation> </message> <message> <location line="+59"/> <source>The signature could not be decoded.</source> <translation>Die Signatur konnte nicht dekodiert werden.</translation> </message> <message> <location line="+0"/> <location line="+13"/> <source>Please check the signature and try again.</source> <translation>Bitte überprüfen Sie die Signatur und versuchen Sie es erneut.</translation> </message> <message> <location line="+0"/> <source>The signature did not match the message digest.</source> <translation>Die Signatur entspricht nicht dem Message Digest.</translation> </message> <message> <location line="+7"/> <source>Message verification failed.</source> <translation>Verifikation der Nachricht fehlgeschlagen.</translation> </message> <message> <location line="+5"/> <source>Message verified.</source> <translation>Nachricht verifiziert.</translation> </message> </context> <context> <name>SplashScreen</name> <message> <location filename="../splashscreen.cpp" line="+25"/> <source>The Nadecoin developers</source> <translation>Die Nadecoinentwickler</translation> </message> <message> <location line="+1"/> <source>[testnet]</source> <translation>[Testnetz]</translation> </message> </context> <context> <name>TransactionDesc</name> <message> <location filename="../transactiondesc.cpp" line="+20"/> <source>Open until %1</source> <translation>Offen bis %1</translation> </message> <message> <location line="+6"/> <source>%1/offline</source> <translation>%1/offline</translation> </message> <message> <location line="+2"/> <source>%1/unconfirmed</source> <translation>%1/unbestätigt</translation> </message> <message> <location line="+2"/> <source>%1 confirmations</source> <translation>%1 Bestätigungen</translation> </message> <message> <location line="+18"/> <source>Status</source> <translation>Status</translation> </message> <message numerus="yes"> <location line="+7"/> <source>, broadcast through %n node(s)</source> <translation><numerusform>, über %n Knoten übertragen</numerusform><numerusform>, über %n Knoten übertragen</numerusform></translation> </message> <message> <location line="+4"/> <source>Date</source> <translation>Datum</translation> </message> <message> <location line="+7"/> <source>Source</source> <translation>Quelle</translation> </message> <message> <location line="+0"/> <source>Generated</source> <translation>Generiert</translation> </message> <message> <location line="+5"/> <location line="+17"/> <source>From</source> <translation>Von</translation> </message> <message> <location line="+1"/> <location line="+22"/> <location line="+58"/> <source>To</source> <translation>An</translation> </message> <message> <location line="-77"/> <location line="+2"/> <source>own address</source> <translation>eigene Adresse</translation> </message> <message> <location line="-2"/> <source>label</source> <translation>Bezeichnung</translation> </message> <message> <location line="+37"/> <location line="+12"/> <location line="+45"/> <location line="+17"/> <location line="+30"/> <source>Credit</source> <translation>Gutschrift</translation> </message> <message numerus="yes"> <location line="-102"/> <source>matures in %n more block(s)</source> <translation><numerusform>reift noch %n weiteren Block</numerusform><numerusform>reift noch %n weitere Blöcke</numerusform></translation> </message> <message> <location line="+2"/> <source>not accepted</source> <translation>nicht angenommen</translation> </message> <message> <location line="+44"/> <location line="+8"/> <location line="+15"/> <location line="+30"/> <source>Debit</source> <translation>Belastung</translation> </message> <message> <location line="-39"/> <source>Transaction fee</source> <translation>Transaktionsgebühr</translation> </message> <message> <location line="+16"/> <source>Net amount</source> <translation>Nettobetrag</translation> </message> <message> <location line="+6"/> <source>Message</source> <translation>Nachricht signieren</translation> </message> <message> <location line="+2"/> <source>Comment</source> <translation>Kommentar</translation> </message> <message> <location line="+2"/> <source>Transaction ID</source> <translation>Transaktions-ID</translation> </message> <message> <location line="+3"/> <source>Generated coins must mature 120 blocks before they can be spent. When you generated this block, it was broadcast to the network to be added to the block chain. If it fails to get into the chain, its state will change to &quot;not accepted&quot; and it won&apos;t be spendable. This may occasionally happen if another node generates a block within a few seconds of yours.</source> <translation>Generierte Nadecoins müssen 120 Blöcke lang reifen, bevor sie ausgegeben werden können. Als Sie diesen Block generierten, wurde er an das Netzwerk übertragen, um ihn der Blockkette hinzuzufügen. Falls dies fehlschlägt wird der Status in &quot;nicht angenommen&quot; geändert und der Betrag wird nicht verfügbar werden. Das kann gelegentlich passieren, wenn ein anderer Knoten einen Block fast zeitgleich generiert.</translation> </message> <message> <location line="+7"/> <source>Debug information</source> <translation>Debuginformationen</translation> </message> <message> <location line="+8"/> <source>Transaction</source> <translation>Transaktion</translation> </message> <message> <location line="+3"/> <source>Inputs</source> <translation>Eingaben</translation> </message> <message> <location line="+23"/> <source>Amount</source> <translation>Betrag</translation> </message> <message> <location line="+1"/> <source>true</source> <translation>wahr</translation> </message> <message> <location line="+0"/> <source>false</source> <translation>falsch</translation> </message> <message> <location line="-209"/> <source>, has not been successfully broadcast yet</source> <translation>, wurde noch nicht erfolgreich übertragen</translation> </message> <message numerus="yes"> <location line="-35"/> <source>Open for %n more block(s)</source> <translation><numerusform>Offen für %n weiteren Block</numerusform><numerusform>Offen für %n weitere Blöcke</numerusform></translation> </message> <message> <location line="+70"/> <source>unknown</source> <translation>unbekannt</translation> </message> </context> <context> <name>TransactionDescDialog</name> <message> <location filename="../forms/transactiondescdialog.ui" line="+14"/> <source>Transaction details</source> <translation>Transaktionsdetails</translation> </message> <message> <location line="+6"/> <source>This pane shows a detailed description of the transaction</source> <translation>Dieser Bereich zeigt eine detaillierte Beschreibung der Transaktion an</translation> </message> </context> <context> <name>TransactionTableModel</name> <message> <location filename="../transactiontablemodel.cpp" line="+225"/> <source>Date</source> <translation>Datum</translation> </message> <message> <location line="+0"/> <source>Type</source> <translation>Typ</translation> </message> <message> <location line="+0"/> <source>Address</source> <translation>Adresse</translation> </message> <message> <location line="+0"/> <source>Amount</source> <translation>Betrag</translation> </message> <message numerus="yes"> <location line="+57"/> <source>Open for %n more block(s)</source> <translation><numerusform>Offen für %n weiteren Block</numerusform><numerusform>Offen für %n weitere Blöcke</numerusform></translation> </message> <message> <location line="+3"/> <source>Open until %1</source> <translation>Offen bis %1</translation> </message> <message> <location line="+3"/> <source>Offline (%1 confirmations)</source> <translation>Offline (%1 Bestätigungen)</translation> </message> <message> <location line="+3"/> <source>Unconfirmed (%1 of %2 confirmations)</source> <translation>Unbestätigt (%1 von %2 Bestätigungen)</translation> </message> <message> <location line="+3"/> <source>Confirmed (%1 confirmations)</source> <translation>Bestätigt (%1 Bestätigungen)</translation> </message> <message numerus="yes"> <location line="+8"/> <source>Mined balance will be available when it matures in %n more block(s)</source> <translation><numerusform>Erarbeiteter Betrag wird verfügbar sein, nachdem er noch %n weiteren Block reift</numerusform><numerusform>Erarbeiteter Betrag wird verfügbar sein, nachdem er noch %n weitere Blöcke reift</numerusform></translation> </message> <message> <location line="+5"/> <source>This block was not received by any other nodes and will probably not be accepted!</source> <translation>Dieser Block wurde von keinem anderen Knoten empfangen und wird wahrscheinlich nicht angenommen werden!</translation> </message> <message> <location line="+3"/> <source>Generated but not accepted</source> <translation>Generiert, jedoch nicht angenommen</translation> </message> <message> <location line="+43"/> <source>Received with</source> <translation>Empfangen über</translation> </message> <message> <location line="+2"/> <source>Received from</source> <translation>Empfangen von</translation> </message> <message> <location line="+3"/> <source>Sent to</source> <translation>Überwiesen an</translation> </message> <message> <location line="+2"/> <source>Payment to yourself</source> <translation>Eigenüberweisung</translation> </message> <message> <location line="+2"/> <source>Mined</source> <translation>Erarbeitet</translation> </message> <message> <location line="+38"/> <source>(n/a)</source> <translation>(k.A.)</translation> </message> <message> <location line="+199"/> <source>Transaction status. Hover over this field to show number of confirmations.</source> <translation>Transaktionsstatus. Fahren Sie mit der Maus über dieses Feld, um die Anzahl der Bestätigungen zu sehen.</translation> </message> <message> <location line="+2"/> <source>Date and time that the transaction was received.</source> <translation>Datum und Uhrzeit als die Transaktion empfangen wurde.</translation> </message> <message> <location line="+2"/> <source>Type of transaction.</source> <translation>Art der Transaktion</translation> </message> <message> <location line="+2"/> <source>Destination address of transaction.</source> <translation>Zieladresse der Transaktion</translation> </message> <message> <location line="+2"/> <source>Amount removed from or added to balance.</source> <translation>Der Betrag, der dem Kontostand abgezogen oder hinzugefügt wurde.</translation> </message> </context> <context> <name>TransactionView</name> <message> <location filename="../transactionview.cpp" line="+52"/> <location line="+16"/> <source>All</source> <translation>Alle</translation> </message> <message> <location line="-15"/> <source>Today</source> <translation>Heute</translation> </message> <message> <location line="+1"/> <source>This week</source> <translation>Diese Woche</translation> </message> <message> <location line="+1"/> <source>This month</source> <translation>Diesen Monat</translation> </message> <message> <location line="+1"/> <source>Last month</source> <translation>Letzten Monat</translation> </message> <message> <location line="+1"/> <source>This year</source> <translation>Dieses Jahr</translation> </message> <message> <location line="+1"/> <source>Range...</source> <translation>Zeitraum...</translation> </message> <message> <location line="+11"/> <source>Received with</source> <translation>Empfangen über</translation> </message> <message> <location line="+2"/> <source>Sent to</source> <translation>Überwiesen an</translation> </message> <message> <location line="+2"/> <source>To yourself</source> <translation>Eigenüberweisung</translation> </message> <message> <location line="+1"/> <source>Mined</source> <translation>Erarbeitet</translation> </message> <message> <location line="+1"/> <source>Other</source> <translation>Andere</translation> </message> <message> <location line="+7"/> <source>Enter address or label to search</source> <translation>Zu suchende Adresse oder Bezeichnung eingeben</translation> </message> <message> <location line="+7"/> <source>Min amount</source> <translation>Minimaler Betrag</translation> </message> <message> <location line="+34"/> <source>Copy address</source> <translation>Adresse kopieren</translation> </message> <message> <location line="+1"/> <source>Copy label</source> <translation>Bezeichnung kopieren</translation> </message> <message> <location line="+1"/> <source>Copy amount</source> <translation>Betrag kopieren</translation> </message> <message> <location line="+1"/> <source>Copy transaction ID</source> <translation>Transaktions-ID kopieren</translation> </message> <message> <location line="+1"/> <source>Edit label</source> <translation>Bezeichnung bearbeiten</translation> </message> <message> <location line="+1"/> <source>Show transaction details</source> <translation>Transaktionsdetails anzeigen</translation> </message> <message> <location line="+139"/> <source>Export Transaction Data</source> <translation>Transaktionen exportieren</translation> </message> <message> <location line="+1"/> <source>Comma separated file (*.csv)</source> <translation>Kommagetrennte-Datei (*.csv)</translation> </message> <message> <location line="+8"/> <source>Confirmed</source> <translation>Bestätigt</translation> </message> <message> <location line="+1"/> <source>Date</source> <translation>Datum</translation> </message> <message> <location line="+1"/> <source>Type</source> <translation>Typ</translation> </message> <message> <location line="+1"/> <source>Label</source> <translation>Bezeichnung</translation> </message> <message> <location line="+1"/> <source>Address</source> <translation>Adresse</translation> </message> <message> <location line="+1"/> <source>Amount</source> <translation>Betrag</translation> </message> <message> <location line="+1"/> <source>ID</source> <translation>ID</translation> </message> <message> <location line="+4"/> <source>Error exporting</source> <translation>Fehler beim Exportieren</translation> </message> <message> <location line="+0"/> <source>Could not write to file %1.</source> <translation>Konnte nicht in Datei %1 schreiben.</translation> </message> <message> <location line="+100"/> <source>Range:</source> <translation>Zeitraum:</translation> </message> <message> <location line="+8"/> <source>to</source> <translation>bis</translation> </message> </context> <context> <name>WalletModel</name> <message> <location filename="../walletmodel.cpp" line="+193"/> <source>Send Coins</source> <translation>Nadecoins überweisen</translation> </message> </context> <context> <name>WalletView</name> <message> <location filename="../walletview.cpp" line="+42"/> <source>&amp;Export</source> <translation>E&amp;xportieren</translation> </message> <message> <location line="+1"/> <source>Export the data in the current tab to a file</source> <translation>Daten der aktuellen Ansicht in eine Datei exportieren</translation> </message> <message> <location line="+193"/> <source>Backup Wallet</source> <translation>Brieftasche sichern</translation> </message> <message> <location line="+0"/> <source>Wallet Data (*.dat)</source> <translation>Brieftaschendaten (*.dat)</translation> </message> <message> <location line="+3"/> <source>Backup Failed</source> <translation>Sicherung fehlgeschlagen</translation> </message> <message> <location line="+0"/> <source>There was an error trying to save the wallet data to the new location.</source> <translation>Beim Speichern der Brieftaschendaten an die neue Position ist ein Fehler aufgetreten.</translation> </message> <message> <location line="+4"/> <source>Backup Successful</source> <translation>Sicherung erfolgreich</translation> </message> <message> <location line="+0"/> <source>The wallet data was successfully saved to the new location.</source> <translation>Speichern der Brieftaschendaten an die neue Position war erfolgreich.</translation> </message> </context> <context> <name>bitcoin-core</name> <message> <location filename="../bitcoinstrings.cpp" line="+94"/> <source>Nadecoin version</source> <translation>Nadecoin-Version</translation> </message> <message> <location line="+102"/> <source>Usage:</source> <translation>Benutzung:</translation> </message> <message> <location line="-29"/> <source>Send command to -server or nadecoind</source> <translation>Befehl an -server oder nadecoind senden</translation> </message> <message> <location line="-23"/> <source>List commands</source> <translation>Befehle auflisten</translation> </message> <message> <location line="-12"/> <source>Get help for a command</source> <translation>Hilfe zu einem Befehl erhalten</translation> </message> <message> <location line="+24"/> <source>Options:</source> <translation>Optionen:</translation> </message> <message> <location line="+24"/> <source>Specify configuration file (default: nadecoin.conf)</source> <translation>Konfigurationsdatei festlegen (Standard: nadecoin.conf)</translation> </message> <message> <location line="+3"/> <source>Specify pid file (default: nadecoind.pid)</source> <translation>PID-Datei festlegen (Standard: nadecoind.pid)</translation> </message> <message> <location line="-1"/> <source>Specify data directory</source> <translation>Datenverzeichnis festlegen</translation> </message> <message> <location line="-9"/> <source>Set database cache size in megabytes (default: 25)</source> <translation>Größe des Datenbankcaches in MB festlegen (Standard: 25)</translation> </message> <message> <location line="-28"/> <source>Listen for connections on &lt;port&gt; (default: 8333 or testnet: 18333)</source> <translation>&lt;port&gt; nach Verbindungen abhören (Standard: 8333 oder Testnetz: 18333)</translation> </message> <message> <location line="+5"/> <source>Maintain at most &lt;n&gt; connections to peers (default: 125)</source> <translation>Maximal &lt;n&gt; Verbindungen zu Gegenstellen aufrechterhalten (Standard: 125)</translation> </message> <message> <location line="-48"/> <source>Connect to a node to retrieve peer addresses, and disconnect</source> <translation>Mit dem Knoten verbinden um Adressen von Gegenstellen abzufragen, danach trennen</translation> </message> <message> <location line="+82"/> <source>Specify your own public address</source> <translation>Die eigene öffentliche Adresse angeben</translation> </message> <message> <location line="+3"/> <source>Threshold for disconnecting misbehaving peers (default: 100)</source> <translation>Schwellenwert, um Verbindungen zu sich nicht konform verhaltenden Gegenstellen zu beenden (Standard: 100)</translation> </message> <message> <location line="-134"/> <source>Number of seconds to keep misbehaving peers from reconnecting (default: 86400)</source> <translation>Anzahl Sekunden, während denen sich nicht konform verhaltenden Gegenstellen die Wiederverbindung verweigert wird (Standard: 86400)</translation> </message> <message> <location line="-29"/> <source>An error occurred while setting up the RPC port %u for listening on IPv4: %s</source> <translation>Beim Einrichten des abzuhörenden RPC-Ports %u für IPv4 ist ein Fehler aufgetreten: %s</translation> </message> <message> <location line="+27"/> <source>Listen for JSON-RPC connections on &lt;port&gt; (default: 8332 or testnet: 18332)</source> <translation>&lt;port&gt; nach JSON-RPC-Verbindungen abhören (Standard: 8332 oder Testnetz: 18332)</translation> </message> <message> <location line="+37"/> <source>Accept command line and JSON-RPC commands</source> <translation>Kommandozeilenbefehle und JSON-RPC-Befehle annehmen</translation> </message> <message> <location line="+76"/> <source>Run in the background as a daemon and accept commands</source> <translation>Als Hintergrunddienst starten und Befehle annehmen</translation> </message> <message> <location line="+37"/> <source>Use the test network</source> <translation>Das Testnetz verwenden</translation> </message> <message> <location line="-112"/> <source>Accept connections from outside (default: 1 if no -proxy or -connect)</source> <translation>Eingehende Verbindungen annehmen (Standard: 1, wenn nicht -proxy oder -connect)</translation> </message> <message> <location line="-80"/> <source>%s, you must set a rpcpassword in the configuration file: %s It is recommended you use the following random password: rpcuser=nadecoinrpc rpcpassword=%s (you do not need to remember this password) The username and password MUST NOT be the same. If the file does not exist, create it with owner-readable-only file permissions. It is also recommended to set alertnotify so you are notified of problems; for example: alertnotify=echo %%s | mail -s &quot;Nadecoin Alert&quot; admin@foo.com </source> <translation>%s, Sie müssen den Wert rpcpasswort in dieser Konfigurationsdatei angeben: %s Es wird empfohlen das folgende Zufallspasswort zu verwenden: rpcuser=nadecoinrpc rpcpassword=%s (Sie müssen sich dieses Passwort nicht merken!) Der Benutzername und das Passwort dürfen NICHT identisch sein. Falls die Konfigurationsdatei nicht existiert, erzeugen Sie diese bitte mit Leserechten nur für den Dateibesitzer. Es wird ebenfalls empfohlen alertnotify anzugeben, um im Problemfall benachrichtig zu werden; zum Beispiel: alertnotify=echo %%s | mail -s \&quot;Nadecoin Alert\&quot; admin@foo.com </translation> </message> <message> <location line="+17"/> <source>An error occurred while setting up the RPC port %u for listening on IPv6, falling back to IPv4: %s</source> <translation>Beim Einrichten des abzuhörenden RPC-Ports %u für IPv6 ist ein Fehler aufgetreten, es wird auf IPv4 zurückgegriffen: %s</translation> </message> <message> <location line="+3"/> <source>Bind to given address and always listen on it. Use [host]:port notation for IPv6</source> <translation>An die angegebene Adresse binden und immer abhören. Für IPv6 [Host]:Port-Schreibweise verwenden</translation> </message> <message> <location line="+3"/> <source>Cannot obtain a lock on data directory %s. Nadecoin is probably already running.</source> <translation>Datenverzeichnis %s kann nicht gesperrt werden. Evtl. wurde Nadecoin bereits gestartet.</translation> </message> <message> <location line="+3"/> <source>Error: The transaction was rejected! This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here.</source> <translation>Fehler: Die Transaktion wurde abgelehnt! Dies kann passieren, wenn einige Nadecoins aus Ihrer Brieftasche bereits ausgegeben wurden. Beispielsweise weil Sie eine Kopie Ihrer wallet.dat genutzt, die Nadecoins dort ausgegeben haben und dies daher in der derzeit aktiven Brieftasche nicht vermerkt ist.</translation> </message> <message> <location line="+4"/> <source>Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds!</source> <translation>Fehler: Diese Transaktion benötigt aufgrund ihres Betrags, ihrer Komplexität oder der Nutzung kürzlich erhaltener Zahlungen eine Transaktionsgebühr in Höhe von mindestens %s!</translation> </message> <message> <location line="+3"/> <source>Execute command when a relevant alert is received (%s in cmd is replaced by message)</source> <translation>Kommando ausführen wenn ein relevanter Alarm empfangen wird (%s im Kommando wird durch die Nachricht ersetzt)</translation> </message> <message> <location line="+3"/> <source>Execute command when a wallet transaction changes (%s in cmd is replaced by TxID)</source> <translation>Kommando ausführen wenn sich eine Transaktion der Briefrasche verändert (%s im Kommando wird durch die TxID ersetzt)</translation> </message> <message> <location line="+11"/> <source>Set maximum size of high-priority/low-fee transactions in bytes (default: 27000)</source> <translation>Maximale Größe von &quot;high-priority/low-fee&quot;-Transaktionen in Byte festlegen (Standard: 27000)</translation> </message> <message> <location line="+6"/> <source>This is a pre-release test build - use at your own risk - do not use for mining or merchant applications</source> <translation>Dies ist eine Vorab-Testversion - Verwendung auf eigene Gefahr - nicht für Mining- oder Handelsanwendungen nutzen!</translation> </message> <message> <location line="+5"/> <source>Warning: -paytxfee is set very high! This is the transaction fee you will pay if you send a transaction.</source> <translation>Warnung: -paytxfee ist auf einen sehr hohen Wert festgelegt! Dies ist die Gebühr die beim Senden einer Transaktion fällig wird.</translation> </message> <message> <location line="+3"/> <source>Warning: Displayed transactions may not be correct! You may need to upgrade, or other nodes may need to upgrade.</source> <translation>Warnung: Angezeigte Transaktionen sind evtl. nicht korrekt! Sie oder die anderen Knoten müssen unter Umständen (den Client) aktualisieren.</translation> </message> <message> <location line="+3"/> <source>Warning: Please check that your computer&apos;s date and time are correct! If your clock is wrong Nadecoin will not work properly.</source> <translation>Warnung: Bitte korrigieren Sie die Datums- und Uhrzeiteinstellungen Ihres Computers, da Nadecoin ansonsten nicht ordnungsgemäß funktionieren wird!</translation> </message> <message> <location line="+3"/> <source>Warning: error reading wallet.dat! All keys read correctly, but transaction data or address book entries might be missing or incorrect.</source> <translation>Warnung: Lesen von wallet.dat fehlgeschlagen! Alle Schlüssel wurden korrekt gelesen, Transaktionsdaten bzw. Adressbucheinträge fehlen aber möglicherweise oder sind inkorrekt.</translation> </message> <message> <location line="+3"/> <source>Warning: wallet.dat corrupt, data salvaged! Original wallet.dat saved as wallet.{timestamp}.bak in %s; if your balance or transactions are incorrect you should restore from a backup.</source> <translation>Warnung: wallet.dat beschädigt, Rettung erfolgreich! Original wallet.dat wurde als wallet.{Zeitstempel}.dat in %s gespeichert. Falls Ihr Kontostand oder Transaktionen nicht korrekt sind, sollten Sie von einer Datensicherung wiederherstellen.</translation> </message> <message> <location line="+14"/> <source>Attempt to recover private keys from a corrupt wallet.dat</source> <translation>Versucht private Schlüssel aus einer beschädigten wallet.dat wiederherzustellen</translation> </message> <message> <location line="+2"/> <source>Block creation options:</source> <translation>Blockerzeugungsoptionen:</translation> </message> <message> <location line="+5"/> <source>Connect only to the specified node(s)</source> <translation>Nur mit dem/den angegebenen Knoten verbinden</translation> </message> <message> <location line="+3"/> <source>Corrupted block database detected</source> <translation>Beschädigte Blockdatenbank erkannt</translation> </message> <message> <location line="+1"/> <source>Discover own IP address (default: 1 when listening and no -externalip)</source> <translation>Eigene IP-Adresse erkennen (Standard: 1, wenn abgehört wird und nicht -externalip)</translation> </message> <message> <location line="+1"/> <source>Do you want to rebuild the block database now?</source> <translation>Möchten Sie die Blockdatenbank nun neu aufbauen?</translation> </message> <message> <location line="+2"/> <source>Error initializing block database</source> <translation>Fehler beim Initialisieren der Blockdatenbank</translation> </message> <message> <location line="+1"/> <source>Error initializing wallet database environment %s!</source> <translation>Fehler beim Initialisieren der Brieftaschen-Datenbankumgebung %s!</translation> </message> <message> <location line="+1"/> <source>Error loading block database</source> <translation>Fehler beim Laden der Blockdatenbank</translation> </message> <message> <location line="+4"/> <source>Error opening block database</source> <translation>Fehler beim Öffnen der Blockdatenbank</translation> </message> <message> <location line="+2"/> <source>Error: Disk space is low!</source> <translation>Fehler: Zu wenig freier Laufwerksspeicherplatz!</translation> </message> <message> <location line="+1"/> <source>Error: Wallet locked, unable to create transaction!</source> <translation>Fehler: Brieftasche gesperrt, Transaktion kann nicht erstellt werden!</translation> </message> <message> <location line="+1"/> <source>Error: system error: </source> <translation>Fehler: Systemfehler: </translation> </message> <message> <location line="+1"/> <source>Failed to listen on any port. Use -listen=0 if you want this.</source> <translation>Fehler, es konnte kein Port abgehört werden. Wenn dies so gewünscht wird -listen=0 verwenden.</translation> </message> <message> <location line="+1"/> <source>Failed to read block info</source> <translation>Lesen der Blockinformationen fehlgeschlagen</translation> </message> <message> <location line="+1"/> <source>Failed to read block</source> <translation>Lesen des Blocks fehlgeschlagen</translation> </message> <message> <location line="+1"/> <source>Failed to sync block index</source> <translation>Synchronisation des Blockindex fehlgeschlagen</translation> </message> <message> <location line="+1"/> <source>Failed to write block index</source> <translation>Schreiben des Blockindex fehlgeschlagen</translation> </message> <message> <location line="+1"/> <source>Failed to write block info</source> <translation>Schreiben der Blockinformationen fehlgeschlagen</translation> </message> <message> <location line="+1"/> <source>Failed to write block</source> <translation>Schreiben des Blocks fehlgeschlagen</translation> </message> <message> <location line="+1"/> <source>Failed to write file info</source> <translation>Schreiben der Dateiinformationen fehlgeschlagen</translation> </message> <message> <location line="+1"/> <source>Failed to write to coin database</source> <translation>Schreiben in die Münzendatenbank fehlgeschlagen</translation> </message> <message> <location line="+1"/> <source>Failed to write transaction index</source> <translation>Schreiben des Transaktionsindex fehlgeschlagen</translation> </message> <message> <location line="+1"/> <source>Failed to write undo data</source> <translation>Schreiben der Rücksetzdaten fehlgeschlagen</translation> </message> <message> <location line="+2"/> <source>Find peers using DNS lookup (default: 1 unless -connect)</source> <translation>Gegenstellen via DNS-Namensauflösung finden (Standard: 1, außer bei -connect)</translation> </message> <message> <location line="+1"/> <source>Generate coins (default: 0)</source> <translation>Nadecoins generieren (Standard: 0)</translation> </message> <message> <location line="+2"/> <source>How many blocks to check at startup (default: 288, 0 = all)</source> <translation>Wieviele Blöcke sollen beim Starten geprüft werden (Standard: 288, 0 = alle)</translation> </message> <message> <location line="+1"/> <source>How thorough the block verification is (0-4, default: 3)</source> <translation>Wie gründlich soll die Blockprüfung sein (0-4, Standard: 3)</translation> </message> <message> <location line="+19"/> <source>Not enough file descriptors available.</source> <translation>Nicht genügend File-Deskriptoren verfügbar.</translation> </message> <message> <location line="+8"/> <source>Rebuild block chain index from current blk000??.dat files</source> <translation>Blockkettenindex aus aktuellen Dateien blk000??.dat wiederaufbauen</translation> </message> <message> <location line="+16"/> <source>Set the number of threads to service RPC calls (default: 4)</source> <translation>Maximale Anzahl an Threads zur Verarbeitung von RPC-Anfragen festlegen (Standard: 4)</translation> </message> <message> <location line="+26"/> <source>Verifying blocks...</source> <translation>Verifiziere Blöcke...</translation> </message> <message> <location line="+1"/> <source>Verifying wallet...</source> <translation>Verifiziere Brieftasche...</translation> </message> <message> <location line="-69"/> <source>Imports blocks from external blk000??.dat file</source> <translation>Blöcke aus externer Datei blk000??.dat importieren</translation> </message> <message> <location line="-76"/> <source>Set the number of script verification threads (up to 16, 0 = auto, &lt;0 = leave that many cores free, default: 0)</source> <translation>Maximale Anzahl an Skript-Verifizierungs-Threads festlegen (bis zu 16, 0 = automatisch, &lt;0 = soviele Kerne frei lassen, Standard: 0)</translation> </message> <message> <location line="+77"/> <source>Information</source> <translation>Hinweis</translation> </message> <message> <location line="+3"/> <source>Invalid -tor address: &apos;%s&apos;</source> <translation>Ungültige Adresse in -tor: &apos;%s&apos;</translation> </message> <message> <location line="+1"/> <source>Invalid amount for -minrelaytxfee=&lt;amount&gt;: &apos;%s&apos;</source> <translation>Ungültiger Betrag für -minrelaytxfee=&lt;amount&gt;: &apos;%s&apos;</translation> </message> <message> <location line="+1"/> <source>Invalid amount for -mintxfee=&lt;amount&gt;: &apos;%s&apos;</source> <translation>Ungültiger Betrag für -mintxfee=&lt;amount&gt;: &apos;%s&apos;</translation> </message> <message> <location line="+8"/> <source>Maintain a full transaction index (default: 0)</source> <translation>Einen vollständigen Transaktionsindex pflegen (Standard: 0)</translation> </message> <message> <location line="+2"/> <source>Maximum per-connection receive buffer, &lt;n&gt;*1000 bytes (default: 5000)</source> <translation>Maximale Größe, &lt;n&gt; * 1000 Byte, des Empfangspuffers pro Verbindung (Standard: 5000)</translation> </message> <message> <location line="+1"/> <source>Maximum per-connection send buffer, &lt;n&gt;*1000 bytes (default: 1000)</source> <translation>Maximale Größe, &lt;n&gt; * 1000 Byte, des Sendepuffers pro Verbindung (Standard: 1000)</translation> </message> <message> <location line="+2"/> <source>Only accept block chain matching built-in checkpoints (default: 1)</source> <translation>Blockkette nur akzeptieren, wenn sie mit den integrierten Prüfpunkten übereinstimmt (Standard: 1)</translation> </message> <message> <location line="+1"/> <source>Only connect to nodes in network &lt;net&gt; (IPv4, IPv6 or Tor)</source> <translation>Verbinde nur zu Knoten des Netztyps &lt;net&gt; (IPv4, IPv6 oder Tor)</translation> </message> <message> <location line="+2"/> <source>Output extra debugging information. Implies all other -debug* options</source> <translation>Ausgabe zusätzlicher Debugginginformationen. Beinhaltet alle anderen &quot;-debug*&quot;-Parameter</translation> </message> <message> <location line="+1"/> <source>Output extra network debugging information</source> <translation>Ausgabe zusätzlicher Netzwerk-Debugginginformationen</translation> </message> <message> <location line="+2"/> <source>Prepend debug output with timestamp</source> <translation>Der Debugausgabe einen Zeitstempel voranstellen</translation> </message> <message> <location line="+5"/> <source>SSL options: (see the Bitcoin Wiki for SSL setup instructions)</source> <translation>SSL-Optionen: (siehe Bitcoin-Wiki für SSL-Installationsanweisungen)</translation> </message> <message> <location line="+1"/> <source>Select the version of socks proxy to use (4-5, default: 5)</source> <translation>SOCKS-Version des Proxies festlegen (4-5, Standard: 5)</translation> </message> <message> <location line="+3"/> <source>Send trace/debug info to console instead of debug.log file</source> <translation>Rückverfolgungs- und Debuginformationen an die Konsole senden anstatt sie in die Datei debug.log zu schreiben</translation> </message> <message> <location line="+1"/> <source>Send trace/debug info to debugger</source> <translation>Rückverfolgungs- und Debuginformationen an den Debugger senden</translation> </message> <message> <location line="+5"/> <source>Set maximum block size in bytes (default: 250000)</source> <translation>Maximale Blockgröße in Byte festlegen (Standard: 250000)</translation> </message> <message> <location line="+1"/> <source>Set minimum block size in bytes (default: 0)</source> <translation>Minimale Blockgröße in Byte festlegen (Standard: 0)</translation> </message> <message> <location line="+2"/> <source>Shrink debug.log file on client startup (default: 1 when no -debug)</source> <translation>Verkleinere Datei debug.log beim Start des Clients (Standard: 1, wenn kein -debug)</translation> </message> <message> <location line="+1"/> <source>Signing transaction failed</source> <translation>Signierung der Transaktion fehlgeschlagen</translation> </message> <message> <location line="+2"/> <source>Specify connection timeout in milliseconds (default: 5000)</source> <translation>Verbindungstimeout in Millisekunden festlegen (Standard: 5000)</translation> </message> <message> <location line="+4"/> <source>System error: </source> <translation>Systemfehler: </translation> </message> <message> <location line="+4"/> <source>Transaction amount too small</source> <translation>Transaktionsbetrag zu gering</translation> </message> <message> <location line="+1"/> <source>Transaction amounts must be positive</source> <translation>Transaktionsbeträge müssen positiv sein</translation> </message> <message> <location line="+1"/> <source>Transaction too large</source> <translation>Transaktion zu groß</translation> </message> <message> <location line="+7"/> <source>Use UPnP to map the listening port (default: 0)</source> <translation>UPnP verwenden, um die Portweiterleitung einzurichten (Standard: 0)</translation> </message> <message> <location line="+1"/> <source>Use UPnP to map the listening port (default: 1 when listening)</source> <translation>UPnP verwenden, um die Portweiterleitung einzurichten (Standard: 1, wenn abgehört wird)</translation> </message> <message> <location line="+1"/> <source>Use proxy to reach tor hidden services (default: same as -proxy)</source> <translation>Proxy verwenden, um versteckte Tor-Dienste zu erreichen (Standard: identisch mit -proxy)</translation> </message> <message> <location line="+2"/> <source>Username for JSON-RPC connections</source> <translation>Benutzername für JSON-RPC-Verbindungen</translation> </message> <message> <location line="+4"/> <source>Warning</source> <translation>Warnung</translation> </message> <message> <location line="+1"/> <source>Warning: This version is obsolete, upgrade required!</source> <translation>Warnung: Diese Version is veraltet, Aktualisierung erforderlich!</translation> </message> <message> <location line="+1"/> <source>You need to rebuild the databases using -reindex to change -txindex</source> <translation>Sie müssen die Datenbank mit Hilfe von -reindex neu aufbauen, um -txindex zu verändern.</translation> </message> <message> <location line="+1"/> <source>wallet.dat corrupt, salvage failed</source> <translation>wallet.dat beschädigt, Rettung fehlgeschlagen</translation> </message> <message> <location line="-50"/> <source>Password for JSON-RPC connections</source> <translation>Passwort für JSON-RPC-Verbindungen</translation> </message> <message> <location line="-67"/> <source>Allow JSON-RPC connections from specified IP address</source> <translation>JSON-RPC-Verbindungen von der angegebenen IP-Adresse erlauben</translation> </message> <message> <location line="+76"/> <source>Send commands to node running on &lt;ip&gt; (default: 127.0.0.1)</source> <translation>Sende Befehle an Knoten &lt;ip&gt; (Standard: 127.0.0.1)</translation> </message> <message> <location line="-120"/> <source>Execute command when the best block changes (%s in cmd is replaced by block hash)</source> <translation>Kommando ausführen wenn der beste Block wechselt (%s im Kommando wird durch den Hash des Blocks ersetzt)</translation> </message> <message> <location line="+147"/> <source>Upgrade wallet to latest format</source> <translation>Brieftasche auf das neueste Format aktualisieren</translation> </message> <message> <location line="-21"/> <source>Set key pool size to &lt;n&gt; (default: 100)</source> <translation>Größe des Schlüsselpools festlegen auf &lt;n&gt; (Standard: 100)</translation> </message> <message> <location line="-12"/> <source>Rescan the block chain for missing wallet transactions</source> <translation>Blockkette erneut nach fehlenden Transaktionen der Brieftasche durchsuchen</translation> </message> <message> <location line="+35"/> <source>Use OpenSSL (https) for JSON-RPC connections</source> <translation>OpenSSL (https) für JSON-RPC-Verbindungen verwenden</translation> </message> <message> <location line="-26"/> <source>Server certificate file (default: server.cert)</source> <translation>Serverzertifikat (Standard: server.cert)</translation> </message> <message> <location line="+1"/> <source>Server private key (default: server.pem)</source> <translation>Privater Serverschlüssel (Standard: server.pem)</translation> </message> <message> <location line="-151"/> <source>Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)</source> <translation>Akzeptierte Chiffren (Standard: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)</translation> </message> <message> <location line="+165"/> <source>This help message</source> <translation>Dieser Hilfetext</translation> </message> <message> <location line="+6"/> <source>Unable to bind to %s on this computer (bind returned error %d, %s)</source> <translation>Kann auf diesem Computer nicht an %s binden (von bind zurückgegebener Fehler %d, %s)</translation> </message> <message> <location line="-91"/> <source>Connect through socks proxy</source> <translation>Verbindung über SOCKS-Proxy herstellen</translation> </message> <message> <location line="-10"/> <source>Allow DNS lookups for -addnode, -seednode and -connect</source> <translation>Erlaube DNS-Namensauflösung für -addnode, -seednode und -connect</translation> </message> <message> <location line="+55"/> <source>Loading addresses...</source> <translation>Lade Adressen...</translation> </message> <message> <location line="-35"/> <source>Error loading wallet.dat: Wallet corrupted</source> <translation>Fehler beim Laden von wallet.dat: Brieftasche beschädigt</translation> </message> <message> <location line="+1"/> <source>Error loading wallet.dat: Wallet requires newer version of Nadecoin</source> <translation>Fehler beim Laden von wallet.dat: Brieftasche benötigt neuere Version von Nadecoin</translation> </message> <message> <location line="+93"/> <source>Wallet needed to be rewritten: restart Nadecoin to complete</source> <translation>Brieftasche musste neu geschrieben werden: Starten Sie Nadecoin zur Fertigstellung neu</translation> </message> <message> <location line="-95"/> <source>Error loading wallet.dat</source> <translation>Fehler beim Laden von wallet.dat (Brieftasche)</translation> </message> <message> <location line="+28"/> <source>Invalid -proxy address: &apos;%s&apos;</source> <translation>Ungültige Adresse in -proxy: &apos;%s&apos;</translation> </message> <message> <location line="+56"/> <source>Unknown network specified in -onlynet: &apos;%s&apos;</source> <translation>Unbekannter Netztyp in -onlynet angegeben: &apos;%s&apos;</translation> </message> <message> <location line="-1"/> <source>Unknown -socks proxy version requested: %i</source> <translation>Unbekannte Proxyversion in -socks angefordert: %i</translation> </message> <message> <location line="-96"/> <source>Cannot resolve -bind address: &apos;%s&apos;</source> <translation>Kann Adresse in -bind nicht auflösen: &apos;%s&apos;</translation> </message> <message> <location line="+1"/> <source>Cannot resolve -externalip address: &apos;%s&apos;</source> <translation>Kann Adresse in -externalip nicht auflösen: &apos;%s&apos;</translation> </message> <message> <location line="+44"/> <source>Invalid amount for -paytxfee=&lt;amount&gt;: &apos;%s&apos;</source> <translation>Ungültiger Betrag für -paytxfee=&lt;amount&gt;: &apos;%s&apos;</translation> </message> <message> <location line="+1"/> <source>Invalid amount</source> <translation>Ungültiger Betrag</translation> </message> <message> <location line="-6"/> <source>Insufficient funds</source> <translation>Unzureichender Kontostand</translation> </message> <message> <location line="+10"/> <source>Loading block index...</source> <translation>Lade Blockindex...</translation> </message> <message> <location line="-57"/> <source>Add a node to connect to and attempt to keep the connection open</source> <translation>Mit dem Knoten verbinden und versuchen die Verbindung aufrecht zu halten</translation> </message> <message> <location line="-25"/> <source>Unable to bind to %s on this computer. Nadecoin is probably already running.</source> <translation>Kann auf diesem Computer nicht an %s binden. Evtl. wurde Nadecoin bereits gestartet.</translation> </message> <message> <location line="+64"/> <source>Fee per KB to add to transactions you send</source> <translation>Gebühr pro KB, die gesendeten Transaktionen hinzugefügt wird</translation> </message> <message> <location line="+19"/> <source>Loading wallet...</source> <translation>Lade Brieftasche...</translation> </message> <message> <location line="-52"/> <source>Cannot downgrade wallet</source> <translation>Brieftasche kann nicht auf eine ältere Version herabgestuft werden</translation> </message> <message> <location line="+3"/> <source>Cannot write default address</source> <translation>Standardadresse kann nicht geschrieben werden</translation> </message> <message> <location line="+64"/> <source>Rescanning...</source> <translation>Durchsuche erneut...</translation> </message> <message> <location line="-57"/> <source>Done loading</source> <translation>Laden abgeschlossen</translation> </message> <message> <location line="+82"/> <source>To use the %s option</source> <translation>Zur Nutzung der %s Option</translation> </message> <message> <location line="-74"/> <source>Error</source> <translation>Fehler</translation> </message> <message> <location line="-31"/> <source>You must set rpcpassword=&lt;password&gt; in the configuration file: %s If the file does not exist, create it with owner-readable-only file permissions.</source> <translation>Sie müssen den Wert rpcpassword=&lt;passwort&gt; in der Konfigurationsdatei angeben: %s Falls die Konfigurationsdatei nicht existiert, erzeugen Sie diese bitte mit Leserechten nur für den Dateibesitzer.</translation> </message> </context> </TS>
{ "content_hash": "d0c4c9e95626373418d4f51e39ba1c67", "timestamp": "", "source": "github", "line_count": 2937, "max_line_length": 449, "avg_line_length": 40.887980932924755, "alnum_prop": 0.6434448071414296, "repo_name": "excellentsloth/Nadecoin", "id": "69ba088429549e24692a914f2aacf1ae99666f6c", "size": "120427", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/qt/locale/bitcoin_de.ts", "mode": "33188", "license": "mit", "language": [ { "name": "C", "bytes": "31251" }, { "name": "C++", "bytes": "12964919" }, { "name": "CSS", "bytes": "1127" }, { "name": "HTML", "bytes": "50615" }, { "name": "Makefile", "bytes": "99042" }, { "name": "NSIS", "bytes": "6070" }, { "name": "Objective-C", "bytes": "858" }, { "name": "Objective-C++", "bytes": "5711" }, { "name": "Python", "bytes": "3773" }, { "name": "QMake", "bytes": "13838" }, { "name": "Shell", "bytes": "8172" } ], "symlink_target": "" }
using Microsoft.AspNetCore.Mvc; using WithAreas.Core.Interfaces; using WithAreas.Core.Model; namespace WithAreas.Areas.Pirates.Controllers { [Area("Pirates")] public class HomeController : Controller { private readonly IRepository<Pirate> _pirateRepository; public HomeController(IRepository<Pirate> pirateRepository) { _pirateRepository = pirateRepository; } public IActionResult Index() { var entities = _pirateRepository.List(); return View(entities); } public IActionResult Details(int id) { var entity = _pirateRepository.GetById(id); return View(entity); } public IActionResult Add() { var entity = new Pirate() { Name = "Random Pirate" }; _pirateRepository.Add(entity); return RedirectToAction("Index"); } } }
{ "content_hash": "8891d0c2a4dcf42534b63a4d786f2564", "timestamp": "", "source": "github", "line_count": 40, "max_line_length": 67, "avg_line_length": 24.475, "alnum_prop": 0.5720122574055159, "repo_name": "ardalis/OrganizingAspNetCore", "id": "2f97f767945b165ce4ce3d22d74a659f18dbecef", "size": "981", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/WithAreas/Areas/Pirates/Controllers/HomeController.cs", "mode": "33188", "license": "mit", "language": [ { "name": "C#", "bytes": "54221" }, { "name": "CSS", "bytes": "3099" }, { "name": "HTML", "bytes": "33878" }, { "name": "JavaScript", "bytes": "1421" } ], "symlink_target": "" }