\r\n\r\n#include \"../DebugNew.h\"\r\n\r\nnamespace Urho3D\r\n{\r\n\r\nconst StringHash StringHash::ZERO;\r\n\r\nStringHash::StringHash(const char* str) noexcept :\r\n value_(Calculate(str))\r\n{\r\n}\r\n\r\nStringHash::StringHash(const String& str) noexcept :\r\n value_(Calculate(str.CString()))\r\n{\r\n}\r\n\r\nunsigned StringHash::Calculate(const char* str, unsigned hash)\r\n{\r\n if (!str)\r\n return hash;\r\n\r\n while (*str)\r\n {\r\n // Perform the actual hashing as case-insensitive\r\n char c = *str;\r\n hash = SDBMHash(hash, (unsigned char)tolower(c));\r\n ++str;\r\n }\r\n\r\n return hash;\r\n}\r\n\r\nString StringHash::ToString() const\r\n{\r\n char tempBuffer[CONVERSION_BUFFER_LENGTH];\r\n sprintf(tempBuffer, \"%08X\", value_);\r\n return String(tempBuffer);\r\n}\r\n\r\n}\r\n", "meta": {"content_hash": "0fcd3d919b139550937694076bcb75e2", "timestamp": "", "source": "github", "line_count": 49, "max_line_length": 62, "avg_line_length": 18.122448979591837, "alnum_prop": 0.6081081081081081, "repo_name": "victorholt/Urho3D", "id": "7a30f2e214ef14ac1b11dffc3f48ea0c807b8192", "size": "2037", "binary": false, "copies": "6", "ref": "refs/heads/master", "path": "Source/Urho3D/Math/StringHash.cpp", "mode": "33188", "license": "mit", "language": [{"name": "AngelScript", "bytes": "1435828"}, {"name": "Batchfile", "bytes": "16483"}, {"name": "C++", "bytes": "8325877"}, {"name": "CMake", "bytes": "446542"}, {"name": "GLSL", "bytes": "154112"}, {"name": "HLSL", "bytes": "178063"}, {"name": "HTML", "bytes": "1375"}, {"name": "Java", "bytes": "78624"}, {"name": "Lua", "bytes": "568614"}, {"name": "MAXScript", "bytes": "94704"}, {"name": "Objective-C", "bytes": "6539"}, {"name": "Ruby", "bytes": "65069"}, {"name": "Shell", "bytes": "27373"}]}}
{"text": "\ufeff//\t\tThis file was generated by St4mpede.Poco 2016-06-08 22:18:52\n\n\n/* \t\t\t\nReading xml C:\\DATA\\PROJEKT\\St4mpede\\St4mpede\\St4mpede\\RdbSchema\\St4mpede.RdbSchema.xml.\nRead database with tables: Customer, Project, User.\nIncluded classes are:\nName=Customer\nName=Project\nName=User\nWriting the output file C:\\DATA\\PROJEKT\\St4mpede\\St4mpede\\St4mpede\\Poco\\PocoGenerator.xml.\nWriting 3 classes in C:\\DATA\\PROJEKT\\St4mpede\\St4mpede\\St4mpede\\..\\..\\TheDAL\\Poco.\n*/\n\n//\n//\n//\n//\n//\n//\n//\n//\n", "meta": {"content_hash": "928c42c20fba38c6343e5ad8317a1a9f", "timestamp": "", "source": "github", "line_count": 22, "max_line_length": 90, "avg_line_length": 21.727272727272727, "alnum_prop": 0.7364016736401674, "repo_name": "LosManos/St4mpede", "id": "d431056b37b6b1b0534e5cbceb4481788390d7fb", "size": "480", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "St4mpede/St4mpede/St4mpede.Poco.cs", "mode": "33188", "license": "apache-2.0", "language": [{"name": "C#", "bytes": "111411"}]}}
{"text": "\n\n \n \n \n classical-realizability: Not compatible\n \n \n \n \n \n \n \n \n \n \n \n
\n
\n
\n
\n
\u00ab Up\n
\n classical-realizability\n \n 8.7.0\n Not compatible\n \n
\n
(2020-07-19 14:21:56 UTC)
\n
Context
\n
# Packages matching: installed\n# Name # Installed # Synopsis\nbase-bigarray base\nbase-num base Num library distributed with the OCaml compiler\nbase-threads base\nbase-unix base\ncamlp5 7.12 Preprocessor-pretty-printer of OCaml\nconf-findutils 1 Virtual package relying on findutils\ncoq 8.5.1 Formal proof management system.\nnum 0 The Num library for arbitrary-precision integer and rational arithmetic\nocaml 4.05.0 The OCaml compiler (virtual package)\nocaml-base-compiler 4.05.0 Official 4.05.0 release\nocaml-config 1 OCaml Switch Configuration\n# opam file:\nopam-version: "2.0"\nmaintainer: "Hugo.Herbelin@inria.fr"\nhomepage: "https://github.com/coq-contribs/classical-realizability"\nlicense: "BSD"\nbuild: [make "-j%{jobs}%"]\ninstall: [make "install"]\nremove: ["rm" "-R" "%{lib}%/coq/user-contrib/ClassicalRealizability"]\ndepends: [\n "ocaml"\n "coq" {>= "8.7" & < "8.8~"}\n]\ntags: [ "keyword: classical realizability" "keyword: Krivine's realizability" "keyword: primitive datatype" "keyword: non determinism" "keyword: quote" "keyword: axiom of countable choice" "keyword: real numbers" "category: Mathematics/Logic/Foundations" ]\nauthors: [ "Lionel Rieg <lionel.rieg@ens-lyon.org>" ]\nbug-reports: "https://github.com/coq-contribs/classical-realizability/issues"\ndev-repo: "git+https://github.com/coq-contribs/classical-realizability.git"\nsynopsis: "Krivine's classical realizability"\ndescription: """\nThe aim of this Coq library is to provide a framework for checking\nproofs in Krivine's classical realizability for second-order Peano arithmetic.\nIt is designed to be as extensible as the original theory by Krivine and to\nsupport on-the-fly extensions by new instructions with their evaluation\nrules."""\nflags: light-uninstall\nurl {\n src:\n "https://github.com/coq-contribs/classical-realizability/archive/v8.7.0.tar.gz"\n checksum: "md5=6299c2ee7d52c1535eece3376983263c"\n}\n
\n
Lint
\n
\n - Command
\n true
\n - Return code
\n - 0
\n
\n
Dry install
\n
Dry install with the current Coq version:
\n
\n - Command
\n opam install -y --show-action coq-classical-realizability.8.7.0 coq.8.5.1
\n - Return code
\n - 5120
\n - Output
\n [NOTE] Package coq is already installed (current version is 8.5.1).\nThe following dependencies couldn't be met:\n - coq-classical-realizability -> coq >= 8.7\nYour request can't be satisfied:\n - No available version of coq satisfies the constraints\nNo solution found, exiting\n
\n
\n
Dry install without Coq/switch base, to test if the problem was incompatibility with the current Coq/OCaml version:
\n
\n - Command
\n opam remove -y coq; opam install -y --show-action --unlock-base coq-classical-realizability.8.7.0
\n - Return code
\n - 0
\n
\n
Install dependencies
\n
\n - Command
\n true
\n - Return code
\n - 0
\n - Duration
\n - 0 s
\n
\n
Install
\n
\n - Command
\n true
\n - Return code
\n - 0
\n - Duration
\n - 0 s
\n
\n
Installation size
\n
No files were installed.
\n
Uninstall
\n
\n - Command
\n true
\n - Return code
\n - 0
\n - Missing removes
\n - \n none\n
\n - Wrong removes
\n - \n none\n
\n
\n
\n
\n
\n
\n \n
\n \n \n \n\n", "meta": {"content_hash": "6953417c96203c08c70ca885216d50c6", "timestamp": "", "source": "github", "line_count": 168, "max_line_length": 340, "avg_line_length": 43.81547619047619, "alnum_prop": 0.5651406058959381, "repo_name": "coq-bench/coq-bench.github.io", "id": "7a2fb7424f897c58b824ccbe499d4bd7f93f33f2", "size": "7363", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "clean/Linux-x86_64-4.05.0-2.0.6/released/8.5.1/classical-realizability/8.7.0.html", "mode": "33188", "license": "mit", "language": []}}
{"text": "import React from 'react'\nimport '!style!css!react-loading-bar/dist/index.css'\nexport default function Loading() {\n return (\n \n \n Loading...\n
\n )\n}\n", "meta": {"content_hash": "79f42d9ca7021bd62d432c1472260f62", "timestamp": "", "source": "github", "line_count": 10, "max_line_length": 68, "avg_line_length": 27.9, "alnum_prop": 0.6415770609318996, "repo_name": "moimikey/react-boilerplate", "id": "0c6503845d209715b51d2b93dbf7650d78360700", "size": "279", "binary": false, "copies": "1", "ref": "refs/heads/redux", "path": "src/app/components/Loading.js", "mode": "33188", "license": "mit", "language": [{"name": "CSS", "bytes": "4797"}, {"name": "HTML", "bytes": "3946"}, {"name": "JavaScript", "bytes": "29033"}]}}
{"text": "from __future__ import unicode_literals\nfrom django.conf import settings\nfrom django.contrib.contenttypes import generic\nfrom django.contrib.contenttypes.models import ContentType\nfrom django.db import models\nfrom django.dispatch.dispatcher import receiver\nfrom model_utils.models import TimeStampedModel\nfrom registration.signals import user_registered\n\n_all = [\"Asset\", \"Profile\", \"user_registered_callback\"]\n__author__ = \"pmeier82\"\n\n\n# PROFILE\n\nclass Profile(models.Model):\n \"\"\"user profile model\"\"\"\n\n class Meta:\n app_label = \"base\"\n\n user = models.OneToOneField(\n settings.AUTH_USER_MODEL,\n unique=True)\n title = models.CharField(\n max_length=255,\n default=\"\",\n )\n affiliation = models.CharField(\n max_length=255,\n default=\"\",\n )\n research_area = models.TextField(\n default=\"\"\n )\n # TODO: build a meaningful profile\n\n # special\n def __str__(self):\n return self.user.username\n\n def __unicode__(self):\n return unicode(self.__str__())\n\n\ndef user_registered_callback(user, request, **kwargs):\n profile, is_new = Profile.objects.get_or_create(user=user)\n profile.title = request.POST.get(\"title\", \"test\")\n profile.save()\n\n\nuser_registered.connect(user_registered_callback)\n\n# ASSET\n\ndef UPLOAD_TO_HANDLER(obj, fname):\n folder = getattr(obj, \"kind\", \"default\")\n return \"{}/{}\".format(folder, fname)\n\n\nclass Asset(TimeStampedModel):\n \"\"\"generic file asset model\"\"\"\n\n class Meta:\n app_label = \"base\"\n\n UPLOAD_TO = \"default\"\n\n # fields\n name = models.CharField(max_length=255, unique=False)\n data_orig_name = models.CharField(max_length=255, unique=False)\n data = models.FileField(upload_to=UPLOAD_TO_HANDLER)\n kind = models.CharField(max_length=255, unique=False, null=False, default=UPLOAD_TO)\n\n # generic foreign key\n content_type = models.ForeignKey(ContentType, null=True)\n object_id = models.PositiveIntegerField(null=True)\n content_object = generic.GenericForeignKey()\n\n # special methods\n def __unicode__(self):\n return unicode(\"{}: {}\".format(self.__class__.__name__, self.name))\n\n # django special methods\n @models.permalink\n def get_absolute_url(self):\n return \"asset:serve\", (self.pk,), {}\n\n @models.permalink\n def get_delete_url(self):\n return \"asset:delete\", (self.pk,), {}\n\n # interface\n def save(self, *args, **kwargs):\n super(Asset, self).save(*args, **kwargs)\n\n def delete(self, *args, **kwargs):\n super(Asset, self).delete(*args, **kwargs)\n\n\n@receiver(models.signals.pre_delete, sender=Asset)\ndef asset_file_delete(sender, instance, **kwargs):\n instance.data.delete()\n\n\nif __name__ == \"__main__\":\n pass\n", "meta": {"content_hash": "85f7dee85ba6de3d5a267ea68a913604", "timestamp": "", "source": "github", "line_count": 107, "max_line_length": 88, "avg_line_length": 25.757009345794394, "alnum_prop": 0.6556603773584906, "repo_name": "pmeier82/spike_gnode", "id": "2411abbf4b4c2c62fd144aaa9261d587c405219b", "size": "2781", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "base/models.py", "mode": "33188", "license": "bsd-3-clause", "language": [{"name": "CSS", "bytes": "11360"}, {"name": "HTML", "bytes": "56070"}, {"name": "JavaScript", "bytes": "734"}, {"name": "Nginx", "bytes": "4758"}, {"name": "Python", "bytes": "37001"}, {"name": "Shell", "bytes": "2475"}]}}
{"text": "\npackage org.eclipse.lsp4j;\n\nimport java.util.List;\nimport org.eclipse.lsp4j.Position;\nimport org.eclipse.lsp4j.TextDocumentIdentifier;\nimport org.eclipse.lsp4j.WorkDoneProgressAndPartialResultParams;\nimport org.eclipse.lsp4j.jsonrpc.validation.NonNull;\nimport org.eclipse.lsp4j.util.Preconditions;\nimport org.eclipse.xtext.xbase.lib.Pure;\nimport org.eclipse.xtext.xbase.lib.util.ToStringBuilder;\n\n/**\n * A parameter literal used in selection range requests.\n * \n * Since 3.15.0\n */\n@SuppressWarnings(\"all\")\npublic class SelectionRangeParams extends WorkDoneProgressAndPartialResultParams {\n /**\n * The text document.\n */\n @NonNull\n private TextDocumentIdentifier textDocument;\n \n /**\n * The positions inside the text document.\n */\n @NonNull\n private List positions;\n \n public SelectionRangeParams() {\n }\n \n public SelectionRangeParams(@NonNull final TextDocumentIdentifier textDocument, @NonNull final List positions) {\n this.textDocument = Preconditions.checkNotNull(textDocument, \"textDocument\");\n this.positions = Preconditions.>checkNotNull(positions, \"positions\");\n }\n \n /**\n * The text document.\n */\n @Pure\n @NonNull\n public TextDocumentIdentifier getTextDocument() {\n return this.textDocument;\n }\n \n /**\n * The text document.\n */\n public void setTextDocument(@NonNull final TextDocumentIdentifier textDocument) {\n this.textDocument = Preconditions.checkNotNull(textDocument, \"textDocument\");\n }\n \n /**\n * The positions inside the text document.\n */\n @Pure\n @NonNull\n public List getPositions() {\n return this.positions;\n }\n \n /**\n * The positions inside the text document.\n */\n public void setPositions(@NonNull final List positions) {\n this.positions = Preconditions.checkNotNull(positions, \"positions\");\n }\n \n @Override\n @Pure\n public String toString() {\n ToStringBuilder b = new ToStringBuilder(this);\n b.add(\"textDocument\", this.textDocument);\n b.add(\"positions\", this.positions);\n b.add(\"workDoneToken\", getWorkDoneToken());\n b.add(\"partialResultToken\", getPartialResultToken());\n return b.toString();\n }\n \n @Override\n @Pure\n public boolean equals(final Object obj) {\n if (this == obj)\n return true;\n if (obj == null)\n return false;\n if (getClass() != obj.getClass())\n return false;\n if (!super.equals(obj))\n return false;\n SelectionRangeParams other = (SelectionRangeParams) obj;\n if (this.textDocument == null) {\n if (other.textDocument != null)\n return false;\n } else if (!this.textDocument.equals(other.textDocument))\n return false;\n if (this.positions == null) {\n if (other.positions != null)\n return false;\n } else if (!this.positions.equals(other.positions))\n return false;\n return true;\n }\n \n @Override\n @Pure\n public int hashCode() {\n final int prime = 31;\n int result = super.hashCode();\n result = prime * result + ((this.textDocument== null) ? 0 : this.textDocument.hashCode());\n return prime * result + ((this.positions== null) ? 0 : this.positions.hashCode());\n }\n}\n", "meta": {"content_hash": "1fc19c21c3959ccaf37336d3bc383346", "timestamp": "", "source": "github", "line_count": 116, "max_line_length": 124, "avg_line_length": 27.396551724137932, "alnum_prop": 0.6913152926368785, "repo_name": "smarr/SOMns-vscode", "id": "ca95621514251184457f1372dec09436068539dd", "size": "3598", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "server/org.eclipse.lsp4j-gen/org/eclipse/lsp4j/SelectionRangeParams.java", "mode": "33188", "license": "mit", "language": [{"name": "ANTLR", "bytes": "12820"}, {"name": "Java", "bytes": "1782848"}, {"name": "Shell", "bytes": "182"}, {"name": "Slash", "bytes": "241"}, {"name": "TypeScript", "bytes": "26804"}, {"name": "Vim Script", "bytes": "3730"}, {"name": "Xtend", "bytes": "197426"}]}}
{"text": "package com.github.mortido.extra.behavioral.nullObject;\n\npublic class NullUser extends User {\n @Override\n public String getName() {\n return \"User doesn't exist\";\n }\n\n @Override\n public int getId() {\n return -1;\n }\n}\n", "meta": {"content_hash": "13680e8fb0ec1fd4f5088b9f8c0ac55a", "timestamp": "", "source": "github", "line_count": 13, "max_line_length": 55, "avg_line_length": 19.076923076923077, "alnum_prop": 0.625, "repo_name": "mortido/DesignPatterns-Java", "id": "56cf92ed5e528869f70fcc4d8bd985ba8f3b2836", "size": "248", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/com/github/mortido/extra/behavioral/nullObject/NullUser.java", "mode": "33188", "license": "mit", "language": [{"name": "Java", "bytes": "72591"}]}}
{"text": "import { Arr, Optional } from '@ephox/katamari';\nimport { SugarElement } from '@ephox/sugar';\n\nimport * as Structs from '../api/Structs';\nimport * as GridRow from '../model/GridRow';\nimport { CellElement, CompElm } from '../util/TableTypes';\n\ntype Subst = () => SugarElement;\n\n// substitution: () -> item\nconst merge = (grid: Structs.RowCells[], bounds: Structs.Bounds, comparator: CompElm, substitution: Subst): Structs.RowCells[] => {\n const rows = GridRow.extractGridDetails(grid).rows;\n // Mutating. Do we care about the efficiency gain?\n if (rows.length === 0) {\n return grid;\n }\n for (let i = bounds.startRow; i <= bounds.finishRow; i++) {\n for (let j = bounds.startCol; j <= bounds.finishCol; j++) {\n // We can probably simplify this again now that we aren't reusing merge.\n const row = rows[i];\n const isLocked = GridRow.getCell(row, j).isLocked;\n GridRow.mutateCell(row, j, Structs.elementnew(substitution(), false, isLocked));\n }\n }\n return grid;\n};\n\n// substitution: () -> item\nconst unmerge = (grid: Structs.RowCells[], target: SugarElement, comparator: CompElm, substitution: Subst): Structs.RowCells[] => {\n const rows = GridRow.extractGridDetails(grid).rows;\n // Mutating. Do we care about the efficiency gain?\n let first = true;\n // tslint:disable-next-line:prefer-for-of\n for (let i = 0; i < rows.length; i++) {\n for (let j = 0; j < GridRow.cellLength(rows[0]); j++) {\n const row = rows[i];\n const currentCell = GridRow.getCell(row, j);\n const currentCellElm = currentCell.element;\n const isToReplace = comparator(currentCellElm, target);\n\n if (isToReplace && !first) {\n GridRow.mutateCell(row, j, Structs.elementnew(substitution(), true, currentCell.isLocked));\n } else if (isToReplace) {\n first = false;\n }\n }\n }\n return grid;\n};\n\nconst uniqueCells = (row: Structs.ElementNew[], comparator: CompElm): Structs.ElementNew[] => {\n return Arr.foldl(row, (rest, cell) => {\n return Arr.exists(rest, (currentCell) => {\n return comparator(currentCell.element, cell.element);\n }) ? rest : rest.concat([ cell ]);\n }, [] as Structs.ElementNew[]);\n};\n\nconst splitCols = (grid: Structs.RowCells[], index: number, comparator: CompElm, substitution: Subst): Structs.RowCells[] => {\n // We don't need to split rows if we're inserting at the first or last row of the old table\n if (index > 0 && index < grid[0].cells.length) {\n Arr.each(grid, (row) => {\n const prevCell = row.cells[index - 1];\n let offset = 0;\n const substitute = substitution();\n\n while (row.cells.length > index + offset && comparator(prevCell.element, row.cells[index + offset].element)) {\n GridRow.mutateCell(row, index + offset, Structs.elementnew(substitute, true, row.cells[index + offset].isLocked));\n offset++;\n }\n });\n }\n\n return grid;\n};\n\nconst splitRows = (grid: Structs.RowCells[], index: number, comparator: CompElm, substitution: Subst): Structs.RowCells[] => {\n // We don't need to split rows if we're inserting at the first or last row of the old table\n const rows = GridRow.extractGridDetails(grid).rows;\n if (index > 0 && index < rows.length) {\n const rowPrevCells = rows[index - 1].cells;\n const cells = uniqueCells(rowPrevCells, comparator);\n Arr.each(cells, (cell) => {\n // only make a sub when we have to\n let replacement = Optional.none>();\n for (let i = index; i < rows.length; i++) {\n for (let j = 0; j < GridRow.cellLength(rows[0]); j++) {\n const row = rows[i];\n const current = GridRow.getCell(row, j);\n const isToReplace = comparator(current.element, cell.element);\n\n if (isToReplace) {\n if (replacement.isNone()) {\n replacement = Optional.some(substitution());\n }\n replacement.each((sub) => {\n GridRow.mutateCell(row, j, Structs.elementnew(sub, true, current.isLocked));\n });\n }\n }\n }\n });\n }\n\n return grid;\n};\n\nexport {\n merge,\n unmerge,\n splitCols,\n splitRows\n};\n", "meta": {"content_hash": "ca65adc511ae0aedbdd6e75bf700d63b", "timestamp": "", "source": "github", "line_count": 113, "max_line_length": 144, "avg_line_length": 37.13274336283186, "alnum_prop": 0.6348903717826502, "repo_name": "tinymce/tinymce", "id": "98e0abc2909ea0a3267c1a8d7d87f92f13e3584d", "size": "4196", "binary": false, "copies": "1", "ref": "refs/heads/develop", "path": "modules/snooker/src/main/ts/ephox/snooker/operate/MergingOperations.ts", "mode": "33188", "license": "mit", "language": [{"name": "CSS", "bytes": "9733"}, {"name": "HTML", "bytes": "183264"}, {"name": "JavaScript", "bytes": "117530"}, {"name": "Less", "bytes": "182379"}, {"name": "TypeScript", "bytes": "11764279"}]}}
{"text": "\n\n", "meta": {"content_hash": "6b3dadea3ba647025bc678e04d6487e0", "timestamp": "", "source": "github", "line_count": 2, "max_line_length": 54, "avg_line_length": 47.0, "alnum_prop": 0.648936170212766, "repo_name": "RBMHTechnology/ttt", "id": "af62bb6ae91ead9584202716b1b01ca7703b5c03", "size": "94", "binary": false, "copies": "4", "ref": "refs/heads/master", "path": "ttt-ttv/src/main/resources/com/skynav/ttv/app/config.xml", "mode": "33188", "license": "bsd-2-clause", "language": [{"name": "CSS", "bytes": "22996"}, {"name": "HTML", "bytes": "2348"}, {"name": "Java", "bytes": "2833329"}, {"name": "Shell", "bytes": "2808"}, {"name": "XSLT", "bytes": "5232"}]}}
{"text": "from __future__ import print_function\nfrom __future__ import unicode_literals\nfrom __future__ import division\n\nimport json\n\nfrom django.conf import settings\nfrom django.contrib.gis.geos import Polygon\nfrom django.core.urlresolvers import reverse\nfrom django.db import transaction\nfrom django.db.models import Q\nfrom django.http import HttpResponseRedirect, HttpResponseForbidden, Http404\nfrom django.shortcuts import get_object_or_404\nfrom django.utils.timezone import now\n\nfrom libs.data import merge\nfrom libs.formatters import humanize_bytes\nfrom libs.pdf_maps import create_event_map_pdf\nfrom libs.sql import get_group_tree_count\n\nfrom apps.core.helpers import (user_is_group_admin,\n user_is_eligible_to_become_trusted_mapper)\nfrom apps.core.decorators import group_request\nfrom apps.core.models import Group\n\nfrom apps.mail.views import notify_group_mapping_approved\n\nfrom apps.users.models import Follow, TrustedMapper\nfrom apps.users.forms import GroupSettingsForm\n\nfrom apps.survey.models import Territory, Survey, Blockface\nfrom apps.survey.layer_context import (get_context_for_territory_layer,\n get_context_for_territory_admin_layer)\n\nfrom apps.event.models import Event, EventRegistration\nfrom apps.event.event_list import EventList\n\nGROUP_EVENTS_ID = 'group-events'\nGROUP_EDIT_EVENTS_TAB_ID = 'events'\n\n\ndef group_list_page(request):\n # TODO: pagination\n groups = Group.objects.filter(is_active=True).order_by('name')\n group_ids = Follow.objects.filter(user_id=request.user.id) \\\n .values_list('group_id', flat=True)\n user_is_following = [group.id in group_ids for group in groups]\n\n group_infos = zip(groups, user_is_following)\n return {\n 'groups': group_infos,\n 'groups_count': len(group_infos),\n }\n\n\n@group_request\ndef _group_events(request):\n qs = Event.objects.filter(group=request.group, is_private=False)\n user_can_edit_group = user_is_group_admin(request.user,\n request.group)\n extra_context = {'user_can_edit_group': user_can_edit_group,\n 'group_slug': request.group.slug}\n return qs, extra_context\n\n\ngroup_detail_events = EventList(\n _group_events,\n name=\"group_detail_events\",\n template_path='groups/partials/detail_event_list.html')\n\n\ngroup_edit_events = EventList(\n _group_events,\n name=\"group_edit_events\",\n template_path='groups/partials/edit_event_list.html')\n\n\ndef group_detail(request):\n user = request.user\n group = request.group\n\n if not user_is_group_admin(user, group) and not request.group.is_active:\n raise Http404('Must be a group admin to view an inactive group')\n\n event_list = (group_detail_events\n .configure(chunk_size=2,\n active_filter=EventList.Filters.CURRENT,\n filterset_name=EventList.chronoFilters)\n .as_context(request, group_slug=group.slug))\n user_is_following = Follow.objects.filter(user_id=request.user.id,\n group=group).exists()\n\n show_mapper_request = user_is_eligible_to_become_trusted_mapper(user,\n group)\n\n follow_count = Follow.objects.filter(group=group).count()\n tree_count = get_group_tree_count(group)\n\n group_blocks = Territory.objects \\\n .filter(group=group) \\\n .values_list('blockface_id', flat=True)\n\n group_blocks_count = group_blocks.count()\n\n if group_blocks_count > 0:\n completed_blocks = Survey.objects \\\n .filter(blockface_id__in=group_blocks) \\\n .distinct('blockface')\n block_percent = \"{:.1%}\".format(\n float(completed_blocks.count()) / float(group_blocks.count()))\n else:\n block_percent = \"0.0%\"\n\n events_held = Event.objects.filter(group=group, ends_at__lt=now())\n num_events_held = events_held.count()\n\n num_event_attendees = EventRegistration.objects \\\n .filter(event__in=events_held) \\\n .filter(did_attend=True) \\\n .count()\n\n return {\n 'group': group,\n 'event_list': event_list,\n 'user_is_following': user_is_following,\n 'edit_url': reverse('group_edit', kwargs={'group_slug': group.slug}),\n 'show_mapper_request': show_mapper_request,\n 'counts': {\n 'tree': tree_count,\n 'block': block_percent,\n 'event': num_events_held,\n 'attendees': num_event_attendees,\n 'follows': follow_count\n },\n 'group_events_id': GROUP_EVENTS_ID,\n 'layer': get_context_for_territory_layer(request, request.group.id),\n 'territory_bounds': _group_territory_bounds(request.group),\n 'render_follow_button_without_count': request.POST.get(\n 'render_follow_button_without_count', False)\n }\n\n\ndef redirect_to_group_detail(request):\n return HttpResponseRedirect(\n reverse('group_detail', kwargs={\n 'group_slug': request.group.slug\n }))\n\n\ndef _group_territory_bounds(group):\n blockfaces = Blockface.objects \\\n .filter(territory__group=group) \\\n .collect()\n\n if blockfaces:\n return list(blockfaces.extent)\n else:\n return None\n\n\ndef edit_group(request, form=None):\n group = request.group\n if not form:\n form = GroupSettingsForm(instance=request.group, label_suffix='')\n event_list = (group_edit_events\n .configure(chunk_size=2,\n active_filter=EventList.Filters.CURRENT,\n filterset_name=EventList.chronoFilters)\n .as_context(request, group_slug=group.slug))\n pending_mappers = TrustedMapper.objects.filter(group=request.group,\n is_approved__isnull=True)\n all_mappers = TrustedMapper.objects.filter(group=request.group,\n is_approved__isnull=False)\n return {\n 'group': group,\n 'event_list': event_list,\n 'form': form,\n 'group_slug': group.slug,\n 'max_image_size': humanize_bytes(\n settings.MAX_GROUP_IMAGE_SIZE_IN_BYTES, 0),\n 'pending_mappers': pending_mappers,\n 'all_mappers': all_mappers,\n 'group_edit_events_tab_id': GROUP_EDIT_EVENTS_TAB_ID,\n }\n\n\ndef update_group_settings(request):\n form = GroupSettingsForm(request.POST, request.FILES,\n instance=request.group)\n if form.is_valid():\n form.save()\n return HttpResponseRedirect(request.group.get_absolute_url())\n else:\n return edit_group(request, form=form)\n\n\ndef follow_group(request):\n Follow.objects.get_or_create(user_id=request.user.id, group=request.group)\n return group_detail(request)\n\n\ndef unfollow_group(request):\n Follow.objects.filter(user_id=request.user.id, group=request.group) \\\n .delete()\n return group_detail(request)\n\n\ndef start_group_map_print_job(request):\n # TODO: implement\n pass\n\n\ndef give_user_mapping_priveleges(request, username):\n mapper_context = _grant_mapping_access(request.group, username,\n is_approved=True)\n mail_context = notify_group_mapping_approved(request, request.group,\n username)\n return merge(mapper_context, mail_context)\n\n\ndef remove_user_mapping_priveleges(request, username):\n return _grant_mapping_access(request.group, username, is_approved=False)\n\n\ndef _grant_mapping_access(group, username, is_approved):\n mapper, created = TrustedMapper.objects.update_or_create(\n group=group,\n user__username=username,\n defaults={'is_approved': is_approved})\n return {\n 'mapper': mapper\n }\n\n\ndef request_mapper_status(request):\n user, group = request.user, request.group\n if not user_is_eligible_to_become_trusted_mapper(user, group):\n return HttpResponseForbidden()\n mapper, created = TrustedMapper.objects.update_or_create(\n group=group, user=user)\n return {\n 'success': True\n }\n\n\ndef group_unmapped_territory_geojson(request, group_id):\n # Get unmapped blockfaces\n blockfaces = Blockface.objects.filter(is_available=True)\n\n my_territory_q = Q(territory__group_id=group_id)\n\n if request.body:\n # Get potentially selectable blockfaces in polygon\n # (those in my territory or unclaimed)\n point_list = json.loads(request.body)\n point_list.append(point_list[0]) # Close the polygon\n polygon = Polygon((point_list))\n\n no_reservations_q = \\\n Q(blockfacereservation__isnull=True) \\\n | Q(blockfacereservation__canceled_at__isnull=False) \\\n | Q(blockfacereservation__expires_at__lt=now())\n nobodys_territory_q = Q(territory__group_id=None)\n unclaimed_q = no_reservations_q & nobodys_territory_q\n\n blockfaces = blockfaces \\\n .filter(geom__within=polygon) \\\n .filter(my_territory_q | unclaimed_q) \\\n .distinct()\n\n # Return just blockface data\n # (skipping expensive queries to make tiler URLs)\n return _make_blockface_data_result(blockfaces)\n\n else:\n # Get all blockfaces in group's territory\n blockfaces = blockfaces.filter(my_territory_q)\n return _make_blockface_and_tiler_urls_result(\n request, blockfaces, group_id)\n\n\ndef group_update_territory(request, group_id):\n group = get_object_or_404(Group, id=group_id)\n\n _update_territory(group, request)\n\n # Recreate PDF maps to show updated group territory\n _update_event_maps(request, group)\n\n result_blockfaces = Blockface.objects.filter(territory__group=group)\n return _make_blockface_and_tiler_urls_result(\n request, result_blockfaces, group_id)\n\n\n@transaction.atomic\ndef _update_territory(group, request):\n new_block_ids = set([int(id) for id in json.loads(request.body)])\n old_block_ids = set(Territory.objects\n .filter(group=group)\n .values_list('blockface_id', flat=True))\n ids_to_add = new_block_ids - old_block_ids\n ids_to_kill = old_block_ids - new_block_ids\n # Make sure no unavailable or already-assigned blocks slipped in\n filtered_ids_to_add = Blockface.objects \\\n .filter(id__in=ids_to_add) \\\n .filter(is_available=True) \\\n .filter(territory=None) \\\n .values_list('id', flat=True)\n new_territory = [Territory(group=group, blockface_id=id)\n for id in filtered_ids_to_add]\n Territory.objects.bulk_create(new_territory)\n Territory.objects \\\n .filter(blockface_id__in=ids_to_kill) \\\n .delete()\n\n\ndef _update_event_maps(request, group):\n events = Event.objects \\\n .filter(group_id=group.id, begins_at__gt=now()) \\\n .select_related('group')\n for event in events:\n create_event_map_pdf(request, event)\n\n\ndef _make_blockface_and_tiler_urls_result(request, blockfaces, group_id):\n result = {\n 'blockDataList': _make_blockface_data_result(blockfaces),\n 'tilerUrls': get_context_for_territory_admin_layer(request, group_id)\n }\n return result\n\n\ndef _make_blockface_data_result(blockfaces):\n block_data_list = [{'id': bf.id, 'geojson': bf.geom.json}\n for bf in blockfaces]\n return block_data_list\n", "meta": {"content_hash": "245a3f944cd4eac948a49263f01aee37", "timestamp": "", "source": "github", "line_count": 336, "max_line_length": 78, "avg_line_length": 34.25595238095238, "alnum_prop": 0.635881841876629, "repo_name": "RickMohr/nyc-trees", "id": "0430d00d3c50a470409f54b8f021ae97848c2ee7", "size": "11534", "binary": false, "copies": "1", "ref": "refs/heads/develop", "path": "src/nyc_trees/apps/users/views/group.py", "mode": "33188", "license": "apache-2.0", "language": [{"name": "CSS", "bytes": "171372"}, {"name": "CartoCSS", "bytes": "878"}, {"name": "HTML", "bytes": "157969"}, {"name": "JavaScript", "bytes": "286316"}, {"name": "Makefile", "bytes": "1524"}, {"name": "PLpgSQL", "bytes": "3210"}, {"name": "Python", "bytes": "404021"}, {"name": "Shell", "bytes": "23399"}]}}
{"text": "function configure() {\n # List n-application using most space\n # @param $1|size number of biggest application to list\n # @return void\n function du-app() {\n size=\"${1:-10}\"\n dpkg-query --show --showformat=\"\\${Package;-50}\\t\\${Installed-Size}\\n\" \\\n | sort -k 2 -n \\\n | grep -v deinstall \\\n | awk '{printf \"%.1f MB \\t %s\\n\", $2/(1024), $1}' \\\n | tail -n \"$size\"\n }\n\n # human-readable sizes\n function df() { \n command df \\\n --human-readable \\\n --print-type \\\n --exclude-type squashfs \\\n --exclude-type tmpfs \\\n --exclude-type devtmpfs \\\n \"$@\"\n }\n\n # show sizes in MB\n function free() { command free -m; }\n}\nconfigure\n", "meta": {"content_hash": "73da57189a7a28882b91e1fe9a32a92a", "timestamp": "", "source": "github", "line_count": 28, "max_line_length": 80, "avg_line_length": 27.357142857142858, "alnum_prop": 0.49216710182767626, "repo_name": "edouard-lopez/dotfiles", "id": "4d9fd2c0bf074292bae2b10a9a53a4d841befd56", "size": "787", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "includes/posix/monitoring.bash", "mode": "33188", "license": "mit", "language": [{"name": "Python", "bytes": "63"}, {"name": "Shell", "bytes": "38660"}, {"name": "Vim Script", "bytes": "5525"}]}}
{"text": "\npackage org.ops4j.pax.exam.sample2.model;\n\nimport javax.persistence.Entity;\nimport javax.persistence.GeneratedValue;\nimport javax.persistence.GenerationType;\nimport javax.persistence.Id;\nimport javax.persistence.Lob;\nimport javax.persistence.ManyToOne;\nimport javax.persistence.Table;\n\n@Entity\n@Table(name = \"rating\")\npublic class Rating {\n\n @Id\n @GeneratedValue(strategy = GenerationType.AUTO)\n private int id;\n\n private int stars;\n\n @Lob\n private String comment;\n\n @ManyToOne\n private User user;\n @ManyToOne\n private Movie movie;\n\n /**\n * @return the id\n */\n public int getId() {\n return id;\n }\n\n /**\n * @param id\n * the id to set\n */\n public void setId(int id) {\n this.id = id;\n }\n\n /**\n * @return the stars\n */\n public int getStars() {\n return stars;\n }\n\n /**\n * @param stars\n * the stars to set\n */\n public void setStars(int stars) {\n this.stars = stars;\n }\n\n /**\n * @return the comment\n */\n public String getComment() {\n return comment;\n }\n\n /**\n * @param comment\n * the comment to set\n */\n public void setComment(String comment) {\n this.comment = comment;\n }\n\n /**\n * @return the user\n */\n public User getUser() {\n return user;\n }\n\n /**\n * @param user\n * the user to set\n */\n public void setUser(User user) {\n this.user = user;\n }\n\n /**\n * @return the movie\n */\n public Movie getMovie() {\n return movie;\n }\n\n /**\n * @param movie\n * the movie to set\n */\n public void setMovie(Movie movie) {\n this.movie = movie;\n }\n}\n", "meta": {"content_hash": "4901789fd2534feffdc9e9d6efb0ceb9", "timestamp": "", "source": "github", "line_count": 104, "max_line_length": 51, "avg_line_length": 17.009615384615383, "alnum_prop": 0.5313736574335783, "repo_name": "bimargulies/org.ops4j.pax.exam2", "id": "0188ac1c47c0896fbf7d103e1a14246e8d489d25", "size": "2379", "binary": false, "copies": "4", "ref": "refs/heads/master", "path": "samples/pax-exam-sample2-model/src/main/java/org/ops4j/pax/exam/sample2/model/Rating.java", "mode": "33188", "license": "apache-2.0", "language": [{"name": "Java", "bytes": "1271799"}, {"name": "Shell", "bytes": "198"}]}}
{"text": "\n//\n// MODULE: JdbcDebug.cpp\n//\n#include \"org_apache_trafodion_jdbc_t2_JdbcDebug.h\"\n#include \"Debug.h\"\n\n/*\n * Class: org_apache_trafodion_jdbc_t2_JdbcDebug\n * Method: getDebugHandle\n * Signature: (I)I\n */\nJNIEXPORT jlong JNICALL Java_org_apache_trafodion_jdbc_t2_JdbcDebug_getDebugHandle(JNIEnv *jenv, jclass jcls,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t jlong method_name_handle)\n{\n\tjlong handle = 0;\n#if defined(_BENCHMARK)\n\thandle = (jlong) new Benchmark((const char *) method_name_handle);\n#endif /* _BENCHMARK */\n\treturn(handle);\n}\n\n/*\n * Class: org_apache_trafodion_jdbc_t2_JdbcDebug\n * Method: getMethodNameHandle\n * Signature: (Ljava/lang/String;)I\n */\nJNIEXPORT jlong JNICALL Java_org_apache_trafodion_jdbc_t2_JdbcDebug_getMethodNameHandle(JNIEnv *jenv, jclass jcls,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t jstring method_name)\n{\n\tjlong rc = 0;\n#if defined(_DEBUG) || defined(_BENCHMARK)\n\tif (method_name) rc = (jlong) jenv->GetStringUTFChars(method_name,NULL);\n\tif (rc==0) rc = (jlong) \"Unknown\";\n#endif /* _DEBUG || _BENCHMARK */\n\treturn(rc);\n}\n\n/*\n * Class: org_apache_trafodion_jdbc_t2_JdbcDebug\n * Method: methodEntry\n * Signature: (III)V\n */\nJNIEXPORT void JNICALL Java_org_apache_trafodion_jdbc_t2_JdbcDebug_methodEntry(JNIEnv *jenv, jclass jcls,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t jlong debug_handle,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t jint debug_level,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t jlong method_name_handle)\n{\n#if defined(_DEBUG)\n\tDebugFunctionEntry((const char *) method_name_handle, debug_level, NULL , NULL, 0);\n#endif /* _DEBUG */\n#if defined(_BENCHMARK)\n\t((Benchmark *) debug_handle)->Entry();\n#endif /* _BENCHMARK */\n}\n\n/*\n * Class: org_apache_trafodion_jdbc_t2_JdbcDebug\n * Method: methodReturn\n * Signature: (ILjava/lang/String;)V\n */\nJNIEXPORT void JNICALL Java_org_apache_trafodion_jdbc_t2_JdbcDebug_methodReturn(JNIEnv *jenv, jclass jcls,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tjlong debug_handle,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tjstring comment)\n{\n#if defined(_DEBUG)\n\tconst char *commentStr;\n\tif (comment) commentStr = jenv->GetStringUTFChars(comment,NULL);\n\telse commentStr = NULL;\n\tDebugFunctionReturn(\"JAVA\", commentStr, false, \"RETURNING\", NULL, 0);\n\tif (commentStr) jenv->ReleaseStringUTFChars(comment,commentStr);\n#endif /* _DEBUG */\n}\n\n/*\n * Class: org_apache_trafodion_jdbc_t2_JdbcDebug\n * Method: methodExit\n * Signature: (I)V\n */\nJNIEXPORT void JNICALL Java_org_apache_trafodion_jdbc_t2_JdbcDebug_methodExit(JNIEnv *jenv, jclass jcls,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t jlong debug_handle)\n{\n#if defined(_DEBUG)\n\tDebugFunctionReturn(\"JAVA\", NULL, true, \"EXITING\", NULL, 0);\n#endif /* _DEBUG */\n\n#if defined(_BENCHMARK)\n\t((Benchmark *) debug_handle)->Exit();\n#endif /* _BENCHMARK */\n}\n\n/*\n * Class: org_apache_trafodion_jdbc_t2_JdbcDebug\n * Method: traceOut\n * Signature: (IILjava/lang/String;)V\n */\nJNIEXPORT void JNICALL Java_org_apache_trafodion_jdbc_t2_JdbcDebug_traceOut(JNIEnv *jenv, jclass jcls,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tjlong debug_handle,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tjint debug_level,\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tjstring comment)\n{\n#if defined(_DEBUG)\n\tconst char *commentStr;\n\tif (comment) commentStr = jenv->GetStringUTFChars(comment,NULL);\n\telse commentStr = NULL;\n\tif (DebugActive(debug_level,NULL,0)) DebugOutput(commentStr , NULL, 0);\n\tif (commentStr) jenv->ReleaseStringUTFChars(comment,commentStr);\n#endif /* _DEBUG */\n}\n", "meta": {"content_hash": "1abd718dce3bc752ab0955f9348f9b61", "timestamp": "", "source": "github", "line_count": 109, "max_line_length": 114, "avg_line_length": 29.853211009174313, "alnum_prop": 0.6717885679164106, "repo_name": "mashengchen/incubator-trafodion", "id": "25ae2a001185445481545ef9e80b702621cbfedb", "size": "4264", "binary": false, "copies": "3", "ref": "refs/heads/master", "path": "core/conn/jdbc_type2/native/JdbcDebug.cpp", "mode": "33188", "license": "apache-2.0", "language": [{"name": "1C Enterprise", "bytes": "27762"}, {"name": "Awk", "bytes": "20971"}, {"name": "Batchfile", "bytes": "27013"}, {"name": "C", "bytes": "18877152"}, {"name": "C++", "bytes": "68786466"}, {"name": "CSS", "bytes": "99092"}, {"name": "GDB", "bytes": "62692"}, {"name": "Groff", "bytes": "46673"}, {"name": "HTML", "bytes": "4618"}, {"name": "Inno Setup", "bytes": "14579"}, {"name": "Java", "bytes": "12232679"}, {"name": "JavaScript", "bytes": "883279"}, {"name": "LLVM", "bytes": "42952"}, {"name": "Makefile", "bytes": "321639"}, {"name": "Objective-C", "bytes": "637659"}, {"name": "PHP", "bytes": "8438"}, {"name": "PLpgSQL", "bytes": "197622"}, {"name": "Perl", "bytes": "549860"}, {"name": "Protocol Buffer", "bytes": "121282"}, {"name": "Python", "bytes": "330201"}, {"name": "QMake", "bytes": "3622"}, {"name": "Ruby", "bytes": "8053"}, {"name": "SQLPL", "bytes": "60330"}, {"name": "Shell", "bytes": "1999068"}, {"name": "Tcl", "bytes": "2763"}, {"name": "XSLT", "bytes": "6100"}, {"name": "Yacc", "bytes": "1368077"}]}}
{"text": "\npackage com.alibaba.dubbo.common.serialize.support.java;\n\nimport java.io.IOException;\nimport java.io.InputStream;\nimport java.io.OutputStream;\n\nimport com.alibaba.dubbo.common.URL;\nimport com.alibaba.dubbo.common.serialize.ObjectInput;\nimport com.alibaba.dubbo.common.serialize.ObjectOutput;\nimport com.alibaba.dubbo.common.serialize.Serialization;\n\n/**\n * @author ding.lid\n */\npublic class CompactedJavaSerialization implements Serialization {\n\n public byte getContentTypeId() {\n return 4;\n }\n\n public String getContentType() {\n return \"x-application/compactedjava\";\n }\n\n public ObjectOutput serialize(URL url, OutputStream out) throws IOException {\n return new JavaObjectOutput(out, true);\n }\n\n public ObjectInput deserialize(URL url, InputStream is) throws IOException {\n return new JavaObjectInput(is, true);\n }\n\n}", "meta": {"content_hash": "51165a6abb524dd739da671e283beb68", "timestamp": "", "source": "github", "line_count": 34, "max_line_length": 81, "avg_line_length": 25.61764705882353, "alnum_prop": 0.7416762342135477, "repo_name": "kaven12/dubboo", "id": "f0a0f0a249f804c6984b2925e343fb0702f0600c", "size": "1480", "binary": false, "copies": "20", "ref": "refs/heads/master", "path": "dubbo-common/src/main/java/com/alibaba/dubbo/common/serialize/support/java/CompactedJavaSerialization.java", "mode": "33188", "license": "apache-2.0", "language": [{"name": "Batchfile", "bytes": "3343"}, {"name": "CSS", "bytes": "18582"}, {"name": "Java", "bytes": "5237817"}, {"name": "JavaScript", "bytes": "63151"}, {"name": "Lex", "bytes": "2077"}, {"name": "Shell", "bytes": "7011"}, {"name": "Thrift", "bytes": "668"}]}}
{"text": "package com.jxd.android.bookinventtory.bean;\n\nimport io.realm.RealmModel;\nimport io.realm.RealmObject;\nimport io.realm.annotations.RealmClass;\n\n/**\n * \u56fe\u4e66\u76d8\u70b9\n * Created by Administrator on 2017/10/17.\n */\n@RealmClass\npublic class ShelfBookScanBean implements RealmModel {\n\n private String title;\n private String barcode;\n private String shelfno;\n private String updatetime;\n private String uid;\n private String callno;\n private int inshelf;\n private String status;\n private String machine_mac;\n\n /**\n * \u76d8\u70b9\u72b6\u6001\n */\n private String scanStatus;\n\n public String getTitle() {\n return title;\n }\n\n public void setTitle(String title) {\n this.title = title;\n }\n\n public String getBarcode() {\n return barcode;\n }\n\n public void setBarcode(String barcode) {\n this.barcode = barcode;\n }\n\n public String getShelfno() {\n return shelfno;\n }\n\n public void setShelfno(String shelfno) {\n this.shelfno = shelfno;\n }\n\n public String getUpdatetime() {\n return updatetime;\n }\n\n public void setUpdatetime(String updatetime) {\n this.updatetime = updatetime;\n }\n\n public String getUid() {\n return uid;\n }\n\n public void setUid(String uid) {\n this.uid = uid;\n }\n\n public String getCallno() {\n return callno;\n }\n\n public void setCallno(String callno) {\n this.callno = callno;\n }\n\n public int getInshelf() {\n return inshelf;\n }\n\n public void setInshelf(int inshelf) {\n this.inshelf = inshelf;\n }\n\n public String getMachine_mac() {\n return machine_mac;\n }\n\n public void setMachine_mac(String machine_mac) {\n this.machine_mac = machine_mac;\n }\n\n public String getStatus() {\n return status;\n }\n\n public void setStatus(String status) {\n this.status = status;\n }\n\n public String getScanStatus() {\n return scanStatus;\n }\n\n public void setScanStatus(String scanStatus) {\n this.scanStatus = scanStatus;\n }\n\n public void transfor(BookBean bookBean){\n this.setBarcode( bookBean.getBarcode() );\n this.setCallno(bookBean.getCallno());\n this.setInshelf(bookBean.getInshelf());\n this.setMachine_mac(bookBean.getMachine_mac());\n this.setTitle(bookBean.getTitle());\n this.setUid(bookBean.getUid());\n this.setShelfno(bookBean.getShelfno());\n this.setStatus( bookBean.getStatus() );\n this.setUpdatetime(bookBean.getUpdatetime());\n }\n\n @Override\n public int hashCode() {\n return super.hashCode();\n }\n\n @Override\n public boolean equals(Object obj) {\n return super.equals(obj);\n }\n}\n", "meta": {"content_hash": "1cc8e2853ac762829180de45eeec8132", "timestamp": "", "source": "github", "line_count": 130, "max_line_length": 55, "avg_line_length": 21.0, "alnum_prop": 0.6201465201465202, "repo_name": "jxdong1013/bookinventory", "id": "577e0a27b8901851282783433ef072283019b34b", "size": "2746", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/android/bookinventory/app/src/main/java/com/jxd/android/bookinventtory/bean/ShelfBookScanBean.java", "mode": "33188", "license": "apache-2.0", "language": [{"name": "ASP", "bytes": "98"}, {"name": "C#", "bytes": "199875"}, {"name": "CSS", "bytes": "21629"}, {"name": "HTML", "bytes": "6682"}, {"name": "Java", "bytes": "261073"}, {"name": "JavaScript", "bytes": "438316"}, {"name": "PowerShell", "bytes": "112665"}]}}
{"text": "\n\n#include \"../../inc/MarlinConfig.h\"\n\n#if HAS_M206_COMMAND\n\n#include \"../gcode.h\"\n#include \"../../module/motion.h\"\n#include \"../../lcd/marlinui.h\"\n#include \"../../libs/buzzer.h\"\n#include \"../../MarlinCore.h\"\n\nvoid M206_report() {\n SERIAL_ECHOLNPAIR_P(\n LIST_N(DOUBLE(LINEAR_AXES),\n PSTR(\"M206 X\"), home_offset.x,\n SP_Y_STR, home_offset.y,\n SP_Z_STR, home_offset.z,\n SP_I_STR, home_offset.i,\n SP_J_STR, home_offset.j,\n SP_K_STR, home_offset.k,\n )\n );\n}\n\n/**\n * M206: Set Additional Homing Offset (X Y Z). SCARA aliases T=X, P=Y\n *\n * *** @thinkyhead: I recommend deprecating M206 for SCARA in favor of M665.\n * *** M206 for SCARA will remain enabled in 1.1.x for compatibility.\n * *** In the 2.0 release, it will simply be disabled by default.\n */\nvoid GcodeSuite::M206() {\n LOOP_LINEAR_AXES(i)\n if (parser.seen(AXIS_CHAR(i)))\n set_home_offset((AxisEnum)i, parser.value_linear_units());\n\n #if ENABLED(MORGAN_SCARA)\n if (parser.seen('T')) set_home_offset(A_AXIS, parser.value_float()); // Theta\n if (parser.seen('P')) set_home_offset(B_AXIS, parser.value_float()); // Psi\n #endif\n\n if (!parser.seen(LINEAR_AXIS_GANG(\"X\", \"Y\", \"Z\", \"I\", \"J\", \"K\")))\n M206_report();\n else\n report_current_position();\n}\n\n/**\n * M428: Set home_offset based on the distance between the\n * current_position and the nearest \"reference point.\"\n * If an axis is past center its endstop position\n * is the reference-point. Otherwise it uses 0. This allows\n * the Z offset to be set near the bed when using a max endstop.\n *\n * M428 can't be used more than 2cm away from 0 or an endstop.\n *\n * Use M206 to set these values directly.\n */\nvoid GcodeSuite::M428() {\n if (homing_needed_error()) return;\n\n xyz_float_t diff;\n LOOP_LINEAR_AXES(i) {\n diff[i] = base_home_pos((AxisEnum)i) - current_position[i];\n if (!WITHIN(diff[i], -20, 20) && home_dir((AxisEnum)i) > 0)\n diff[i] = -current_position[i];\n if (!WITHIN(diff[i], -20, 20)) {\n SERIAL_ERROR_MSG(STR_ERR_M428_TOO_FAR);\n LCD_ALERTMESSAGEPGM_P(PSTR(\"Err: Too far!\"));\n BUZZ(200, 40);\n return;\n }\n }\n\n LOOP_LINEAR_AXES(i) set_home_offset((AxisEnum)i, diff[i]);\n report_current_position();\n LCD_MESSAGEPGM(MSG_HOME_OFFSETS_APPLIED);\n BUZZ(100, 659);\n BUZZ(100, 698);\n}\n\n#endif // HAS_M206_COMMAND\n", "meta": {"content_hash": "d5f7b1a89aaf43eebda85cc3e0a7bc6e", "timestamp": "", "source": "github", "line_count": 83, "max_line_length": 82, "avg_line_length": 28.771084337349397, "alnum_prop": 0.6134840871021775, "repo_name": "limtbk/3dprinting", "id": "51f3e7c14c049e582236c468f1a1c40acf5e4c5a", "size": "3249", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "Firmware/src/Marlin/src/gcode/geometry/M206_M428.cpp", "mode": "33188", "license": "apache-2.0", "language": [{"name": "C", "bytes": "16427042"}, {"name": "C++", "bytes": "1508812"}, {"name": "Makefile", "bytes": "58317"}, {"name": "Objective-C", "bytes": "195319"}, {"name": "Processing", "bytes": "407203"}, {"name": "Python", "bytes": "11892"}, {"name": "Scilab", "bytes": "10211"}]}}
{"text": "/*\n\n A helper function to diagram all routes in a `fluid.express` instance.\n\n */\n\n\"use strict\";\nvar fluid = fluid || require(\"infusion\");\n\nfluid.registerNamespace(\"fluid.test.express\");\n\n/**\n *\n * Diagram all routes within an express instance.\n *\n * @param {Object} expressComponent - A `fluid.express` component.\n * @return {Object} A JSON Object representing all routes within a `fluid.express` instance.\n *\n */\nfluid.test.express.diagramAllRoutes = function (expressComponent) {\n return fluid.test.express.diagramOneLevel(expressComponent, expressComponent.router._router);\n};\n\n/**\n *\n * Diagram the routes for a single component. To preserve the routing order of the stack, each level's children\n * are represented in a `children` Array.\n *\n * @param {Object} component - A `fluid.express.middleware` component.\n * @param {Object} router - The router instance within the component (if there is one).\n * @return {Object} A JSON Object representing the routes from this level down as well as the method and path for this level.\n */\nfluid.test.express.diagramOneLevel = function (component, router) {\n var thisLevel = fluid.filterKeys(component.options, [\"method\", \"path\"]);\n thisLevel.typeName = component.typeName;\n\n if (router) {\n thisLevel.children = fluid.transform(router.stack, function (layer) {\n // This is a `fluid.express.router` instance\n if (layer.handle && layer.handle.that) {\n return fluid.test.express.diagramOneLevel(layer.handle.that, layer.handle.that.router);\n }\n // This is a `fluid.express.middleware` instance\n else if (layer.route) {\n var wrapper = fluid.filterKeys(layer.route, [\"path\", \"methods\"]);\n wrapper.children = fluid.transform(layer.route.stack, function (middlewareLayer) {\n return fluid.test.express.diagramOneLevel(middlewareLayer.handle.that, middlewareLayer.handle.that.router);\n });\n return wrapper;\n }\n // This is something outside of our scope (i.e. native middleware).\n else {\n return \"Native middleware '\" + (layer.name || \"unknown\") + \"'\";\n }\n });\n }\n\n return thisLevel;\n};\n", "meta": {"content_hash": "1e7085b56a339027cd32730d523f680f", "timestamp": "", "source": "github", "line_count": 59, "max_line_length": 127, "avg_line_length": 38.389830508474574, "alnum_prop": 0.6512141280353201, "repo_name": "GPII/gpii-express", "id": "34a60008e12253be09206b56a5d1c3b76b4d7c29", "size": "2265", "binary": false, "copies": "2", "ref": "refs/heads/main", "path": "tests/js/lib/diagramAllRoutes.js", "mode": "33188", "license": "bsd-3-clause", "language": [{"name": "HTML", "bytes": "214"}, {"name": "JavaScript", "bytes": "208501"}]}}
{"text": "package com.lru.memory.disk.cache;\n\n/**\n *\n * @author sathayeg\n */\npublic interface DirLocate {\n public String getPathToFile(String key) throws Exception;\n public boolean isDiskPersistent();\n}\n", "meta": {"content_hash": "3f8be3bb0d892f5fdc57eeeaa392bc41", "timestamp": "", "source": "github", "line_count": 10, "max_line_length": 61, "avg_line_length": 20.0, "alnum_prop": 0.72, "repo_name": "gaurangsathaye/JavaSimpleCache", "id": "00f1f658cb5c38b6e518eccef7f979c9316fdd38", "size": "200", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "src/main/java/com/lru/memory/disk/cache/DirLocate.java", "mode": "33188", "license": "apache-2.0", "language": []}}
{"text": "\n\n\n\t\n\n\n\u041a\u043b\u0430\u0441\u0438\u0444\u0438\u043a\u0430\u0446\u0438\u0458\u0430\n\n\n\n\n\n\n\n\n\n
\n\n
\n \n \n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\u0412\u0438\u0434\u043e\u0432\u0438\u0442\u0435 \u043d\u0430 \u0440\u0430\u043a \u0441\u0435 \u043a\u043b\u0430\u0441\u0438\u0444\u0438\u0446\u0438\u0440\u0430\u0430\u0442 \u0441\u043f\u043e\u0440\u0435\u0434 \u0432\u0438\u0434\u043e\u0442 \u043d\u0430 \u043a\u043b\u0435\u0442\u043a\u0438 \u043a\u043e\u0438 \u043d\u0430\u043b\u0438\u043a\u0443\u0432\u0430\u0430\u0442 \u043d\u0430 \u0442\u0443\u043c\u043e\u0440, \u0438 \u0441\u043f\u043e\u0440\u0435\u0434 \u0442\u043e\u0430, \n\t\u043d\u0430 \u0442\u043a\u0438\u0432\u043e\u0442\u043e \u0437\u0430 \u043a\u043e\u0435 \u0441\u0435 \u043f\u0440\u0435\u0442\u043f\u043e\u0441\u0442\u0430\u0432\u0443\u0432\u0430 \u0434\u0435\u043a\u0430 \u0435 \u0437\u0430\u0447\u0435\u0442\u043e\u043a \u043d\u0430 \u0442\u0443\u043c\u043e\u0440\u043e\u0442. \u041f\u043e\u0434\u043e\u043b\u0443 \u0435 \u0445\u0438\u0441\u0442\u043e\u043b\u043e\u0433\u0438\u0458\u0430\u0442\u0430 \u0438 \u043c\u0435\u0441\u0442\u043e\u043f\u043e\u043b\u043e\u0436\u0431\u0430\u0442\u0430 \u043d\u0430 \u0432\u0438\u0434\u043e\u0432\u0438\u0442\u0435 \u0440\u0430\u043a. \u041f\u0440\u0438\u043c\u0435\u0440\u0438 \u0437\u0430 \u043d\u0435\u043a\u043e\u043b\u043a\u0443 \n\t\u043e\u043f\u0448\u0442\u0438 \u043a\u0430\u0442\u0435\u0433\u043e\u0440\u0438\u0438 \u0441\u0435: \u041a\u0430\u0440\u0446\u0438\u043d\u043e\u043c: \u041c\u0430\u043b\u0438\u0433\u043d\u0438 \u0442\u0443\u043c\u043e\u0440\u0438 \u043a\u043e\u0438 \u043f\u043e\u0442\u0435\u043a\u043d\u0443\u0432\u0430\u0430\u0442 \u043e\u0434 \u0435\u043f\u0438\u0442\u0435\u043b\u043d\u0438 \u043a\u043b\u0435\u0442\u043a\u0438. \u0412\u043e \u043e\u0432\u0430\u0430 \u0433\u0440\u0443\u043f\u0430 \u043f\u0440\u0438\u043f\u0430\u0453\u0430\u0430\u0442 \u043d\u0430\u0458\u0447\u0435\u0441\u0442\u0438\u0442\u0435 \u0432\u0438\u0434\u043e\u0432\u0438 \u043d\u0430 \u0440\u0430\u043a, \n\t\u0432\u043a\u043b\u0443\u0447\u0443\u0432\u0430\u0458\u045c\u0438 \u0433\u0438 \u0440\u0430\u043a\u043e\u0442 \u043d\u0430 \u0434\u043e\u0458\u043a\u0430\u0442\u0430, \u043f\u0440\u043e\u0441\u0442\u0430\u0442\u0430\u0442\u0430, \u0431\u0435\u043b\u0438\u0442\u0435 \u0434\u0440\u043e\u0431\u043e\u0432\u0438 \u0438 \u0434\u0435\u0431\u0435\u043b\u043e\u0442\u043e \u0446\u0440\u0435\u0432\u043e. \u0421\u0430\u0440\u043a\u043e\u043c: \u041c\u0430\u043b\u0438\u0433\u043d\u0438 \u0442\u0443\u043c\u043e\u0440\u0438 \u043a\u043e\u0438 \u043f\u043e\u0442\u0435\u043a\u043d\u0443\u0432\u0430\u0430\u0442 \u043e\u0434 \u0441\u0432\u0440\u0437\u043d\u0438\u0442\u0435 \u0442\u043a\u0438\u0432\u0430,\n\t \u0438\u043b\u0438 \u043c\u0435\u0437\u0435\u043d\u0445\u0438\u043c\u0430\u043b\u043d\u0438\u0442\u0435 \u043a\u043b\u0435\u0442\u043a\u0438. \u041b\u0438\u043c\u0444\u043e\u043c \u0438 \u043b\u0435\u0443\u043a\u0435\u043c\u0438\u0458\u0430: \u041c\u0430\u043b\u0438\u0433\u043d\u043e\u043c\u0438 \u043a\u043e\u0438 \u043f\u043e\u0442\u0435\u043a\u043d\u0443\u0432\u0430\u0430\u0442 \u043e\u0434 \u0445\u0435\u043c\u0430\u0442\u043e\u043f\u043e\u0435\u0442\u0441\u043a\u0438\u0442\u0435 (\u043a\u0440\u0432\u043e\u0442\u0432\u043e\u0440\u043d\u0438\u0442\u0435) \u043a\u043b\u0435\u0442\u043a\u0438 \u0411\u0430\u043a\u0442\u0435\u0440\u0438\u0441\u043a\u0438 \u0440\u0430\u043a: \n\t \u0422\u0443\u043c\u043e\u0440\u0438 \u043a\u043e\u0438 \u043f\u043e\u0442\u0435\u043a\u043d\u0443\u0432\u0430\u0430\u0442 \u043e\u0434 \u0442\u043e\u0442\u0438\u043f\u043e\u0442\u0435\u043d\u0442\u043d\u0438\u0442\u0435 \u043a\u043b\u0435\u0442\u043a\u0438. \u041a\u0430\u0458 \u0432\u043e\u0437\u0440\u0430\u0441\u043d\u0438\u0442\u0435 \u043d\u0430\u0458\u0447\u0435\u0441\u0442\u043e \u043c\u043e\u0436\u0435 \u0434\u0430 \u0441\u0435 \u043d\u0430\u0458\u0434\u0435 \u0432\u043e \u0442\u0435\u0441\u0442\u0438\u0441\u0438\u0442\u0435 \u0438 \u0458\u0430\u0458\u0447\u043d\u0438\u0446\u0438\u0442\u0435, \u0434\u043e\u0434\u0435\u043a\u0430 \u043a\u0430\u0458 \u0444\u0435\u0442\u0443\u0441\u0438\u0442\u0435, \n\t \u0431\u0435\u0431\u0438\u045a\u0430\u0442\u0430 \u0438 \u043c\u0430\u043b\u0438\u0442\u0435 \u0434\u0435\u0446\u0430 \u043d\u0430\u0458\u0447\u0435\u0441\u0442\u043e \u0441\u0435 \u043d\u0430\u043e\u0453\u0430\u0430\u0442 \u0432\u043e \u0441\u0440\u0435\u0434\u0438\u0448\u043d\u0438\u043e\u0442 \u0434\u0435\u043b \u043d\u0430 \u0442\u0435\u043b\u043e\u0442\u043e, \u043d\u0430 \u0432\u0440\u0432\u043e\u0442 \u043d\u0430 \u043e\u043f\u0430\u0448\u043d\u0430\u0442\u0430 \u043a\u043e\u0441\u043a\u0430, \u0430 \u043a\u0430\u0458 \u043a\u043e\u045a\u0438\u0442\u0435 \u0432\u043e \u043e\u0441\u043d\u043e\u0432\u0430\u0442\u0430 \u043d\u0430 \u0447\u0435\u0440\u0435\u043f\u043e\u0442. \n\t \u0411\u043b\u0430\u0441\u0442\u0435\u043d \u0442\u0443\u043c\u043e\u0440 \u0438\u043b\u0438 \u0431\u043b\u0430\u0441\u0442\u043e\u043c: \u0422\u0443\u043c\u043e\u0440 (\u043e\u0431\u0438\u0447\u043d\u043e \u043c\u0430\u043b\u0438\u0433\u043d\u0435\u043d) \u043a\u043e\u0458 \u043d\u0430\u043b\u0438\u043a\u0443\u0432\u0430 \u043d\u0430 \u043d\u0435\u0437\u0440\u0435\u043b\u043e \u0438\u043b\u0438 \u0435\u043c\u0431\u0440\u0438\u043e\u043d\u0441\u043a\u043e \u0442\u043a\u0438\u0432\u043e. \u041e\u0432\u0438\u0435 \u0442\u0443\u043c\u043e\u0440\u0438 \u0441\u0435 \u043d\u0430\u0458\u0447\u0435\u0441\u0442\u0438 \u043a\u0430\u0458 \u0434\u0435\u0446\u0430\u0442\u0430. \n \u0442\u0443\u043c\u043e\u0440\u0438 (\u0432\u0438\u0434\u043e\u0432\u0438 \u0440\u0430\u043a) \u043e\u0431\u0438\u0447\u043d\u043e \u0441\u0435 \u0438\u043c\u0435\u043d\u0443\u0432\u0430\u0430\u0442 \u043a\u043e\u0440\u0438\u0441\u0442\u0435\u0458\u045c\u0438 \u2013\u043a\u0430\u0440\u0446\u0438\u043d\u043e\u043c, -\u0441\u0430\u0440\u043a\u043e\u043c \u0438\u043b\u0438 \u2013\u0431\u043b\u0430\u0441\u0442\u043e\u043c \u043a\u0430\u043a\u043e \u0441\u0443\u0444\u0438\u043a\u0441, \u0438 \u043b\u0430\u0442\u0438\u043d\u0441\u043a\u0438\u043e\u0442 \u0438\u043b\u0438 \u0433\u0440\u0447\u043a\u0438\u043e\u0442 \u0437\u0431\u043e\u0440 \u0437\u0430 \u043e\u0440\u0433\u0430\u043d\u043e\u0442\n \u043e\u0434 \u043a\u043e\u0458 \u043f\u043e\u0442\u0435\u043a\u043d\u0443\u0432\u0430\u0430\u0442 \u043a\u0430\u043a\u043e \u043a\u043e\u0440\u0435\u043d \u043d\u0430 \u0438\u043c\u0435\u0442\u043e. \u041d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440, \u0440\u0430\u043a\u043e\u0442 \u043d\u0430 \u0446\u0440\u043d\u0438\u043e\u0442 \u0434\u0440\u043e\u0431 \u0441\u0435 \u043d\u0430\u0440\u0435\u043a\u0443\u0432\u0430 \u0445\u0435\u043f\u0430\u0442\u043e\u043a\u0430\u0440\u0446\u0438\u043d\u043e\u043c, \u0440\u0430\u043a\u043e\u0442 \u043d\u0430 \u043c\u0430\u0441\u043d\u0438\u0442\u0435 \u043a\u043b\u0435\u0442\u043a\u0438- \u043b\u0438\u043f\u043e\u0441\u0430\u0440\u043a\u043e\u043c\n \u0438\u0442\u043d. \u0411\u0435\u043d\u0438\u0433\u043d\u0438\u0442\u0435 \u0442\u0443\u043c\u043e\u0440\u0438 (\u043a\u043e\u0438 \u043d\u0435 \u0441\u0435 \u0440\u0430\u043a) \u0441\u0435 \u0438\u043c\u0435\u043d\u0443\u0432\u0430\u0430\u0442 \u043a\u043e\u0440\u0438\u0441\u0442\u0435\u0458\u045c\u0438 \u2013\u043e\u043c \u043a\u0430\u043a\u043e \u0441\u0443\u0444\u0438\u043a\u0441, \u0438 \u0438\u043c\u0435\u0442\u043e \u043d\u0430 \u043e\u0440\u0433\u0430\u043d\u043e\u0442 \u043a\u0430\u043a\u043e \u043a\u043e\u0440\u0435\u043d. \u041d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440, \u0431\u0435\u043d\u0438\u0433\u043d\u0435\u043d \u0442\u0443\u043c\u043e\u0440 \n \u043d\u0430 \u043c\u0430\u0437\u043d\u0430\u0442\u0430 \u043c\u0443\u0441\u043a\u0443\u043b\u0430\u0442\u0443\u0440\u0430 \u043d\u0430 \u043c\u0430\u0442\u043a\u0430\u0442\u0430 \u0441\u0435 \u043d\u0430\u0440\u0435\u043a\u0443\u0432\u0430 \u043b\u0435\u0438\u043e\u043c\u0438\u043e\u043c (\u043f\u043e\u0447\u0435\u0441\u0442 \u0438\u0437\u0440\u0430\u0437 \u0437\u0430 \u043e\u0432\u043e\u0458 \u0432\u0438\u0434 \u0442\u0443\u043c\u043e\u0440 \u0435 \u0444\u0438\u0431\u0440\u043e\u0438\u0434). \u0417\u0430 \u0436\u0430\u043b, \n\t\u0438 \u043d\u0435\u043a\u043e\u0438 \u0432\u0438\u0434\u043e\u0432\u0438 \u0440\u0430\u043a \u0433\u043e \u043a\u043e\u0440\u0438\u0441\u0442\u0430\u0442 \u0441\u0443\u0444\u0438\u043a\u0441\u043e\u0442 \u2013\u043e\u043c, \u043a\u0430\u043a\u043e \u0448\u0442\u043e \u0435 \u0441\u043b\u0443\u0447\u0430\u0458\u043e\u0442 \u0441\u043e \u043c\u0435\u043b\u0430\u043d\u043e\u043c \u0438 \u0441\u0435\u043c\u0438\u043d\u043e\u043c\n\t\t
\n\n\n\t \n\n\n\n\n\n", "meta": {"content_hash": "5fe8f5d153cd27a362025ba442a3f87d", "timestamp": "", "source": "github", "line_count": 92, "max_line_length": 140, "avg_line_length": 45.84782608695652, "alnum_prop": 0.7159791370317686, "repo_name": "majaradichevich/majaradichevich.github.io", "id": "7ed025a1c9e8db3faad7a92693291f6f197a9621", "size": "5642", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "klasifikacija.html", "mode": "33188", "license": "mit", "language": [{"name": "CSS", "bytes": "6042"}, {"name": "HTML", "bytes": "185244"}, {"name": "JavaScript", "bytes": "11231"}]}}
{"text": "Installing XFramework Generator
\n\nYou don't need to download the source code from the repo, create all the necessary files for the web app, writing two thousands line of code just to create a Hello world!
app. XFramework Generator can make everything for you.
\n\nXF Generator has a number of dependencies such as:
\n\n\n\nTo install first two of them on Mac OS X or Windows computers you just need to download a package from nodejs.org/download/. For other platforms see the readme.
\n\nAfter installing node.js and npm go to terminal and install Yeoman writing npm install -g yo
(with sudo
if necessary).
\n\nAlmost there! After these steps you need to install XF Generator with npm install -g generator-xf
.
", "meta": {"content_hash": "7ec5a698f2b1bcd09b1e097b90fbd031", "timestamp": "", "source": "github", "line_count": 17, "max_line_length": 257, "avg_line_length": 60.705882352941174, "alnum_prop": 0.7199612403100775, "repo_name": "epam/xframework", "id": "4127893e601400216714eb907402287b68e38251", "size": "1032", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "docs/data/installing_xframework_generator.html", "mode": "33188", "license": "bsd-3-clause", "language": [{"name": "CSS", "bytes": "275950"}, {"name": "JavaScript", "bytes": "730289"}]}}
{"text": "namespace Azure.ResourceManager.EdgeOrder.Models\n{\n /// Represents subscription registered features. \n public partial class CustomerSubscriptionRegisteredFeatures\n {\n /// Initializes a new instance of CustomerSubscriptionRegisteredFeatures. \n public CustomerSubscriptionRegisteredFeatures()\n {\n }\n\n /// Name of subscription registered feature. \n public string Name { get; set; }\n /// State of subscription registered feature. \n public string State { get; set; }\n }\n}\n", "meta": {"content_hash": "ac471d3f33987dd6c7e35e349847293a", "timestamp": "", "source": "github", "line_count": 16, "max_line_length": 102, "avg_line_length": 38.4375, "alnum_prop": 0.6813008130081301, "repo_name": "Azure/azure-sdk-for-net", "id": "1888fb1a8203597c021c5a97aa4c2106984a672a", "size": "753", "binary": false, "copies": "1", "ref": "refs/heads/main", "path": "sdk/edgeorder/Azure.ResourceManager.EdgeOrder/src/Generated/Models/CustomerSubscriptionRegisteredFeatures.cs", "mode": "33188", "license": "mit", "language": []}}
{"text": "\n\n\n\n\n\nUses of Interface org.wildfly.swarm.config.messaging.activemq.server.BindingsDirectoryPathConsumer (BOM: * : All 2.3.1.Final-SNAPSHOT API)\n\n\n\n\n\n\n\n\n\n\n\n
\n
\n\n\n
\n
Thorntail API, 2.3.1.Final-SNAPSHOT
\n
\n\n\n\n\n\n\n\n\n
\n
\n\n\n
\n
Thorntail API, 2.3.1.Final-SNAPSHOT
\n
\n\n\nCopyright © 2019 JBoss by Red Hat. All rights reserved.
\n\n\n", "meta": {"content_hash": "9d4a959a17bfed5d67d358e525d7f8e4", "timestamp": "", "source": "github", "line_count": 206, "max_line_length": 793, "avg_line_length": 64.10194174757281, "alnum_prop": 0.6843619840969329, "repo_name": "wildfly-swarm/wildfly-swarm-javadocs", "id": "1e14ac35a7c49488433c20a72a70ed6f7111d9be", "size": "13205", "binary": false, "copies": "1", "ref": "refs/heads/gh-pages", "path": "2.3.1.Final-SNAPSHOT/apidocs/org/wildfly/swarm/config/messaging/activemq/server/class-use/BindingsDirectoryPathConsumer.html", "mode": "33188", "license": "apache-2.0", "language": []}}
{"text": "\n\nimport ReactSharedInternals from 'shared/ReactSharedInternals';\nimport type {Transition} from './ReactFiberTracingMarkerComponent.new';\n\nconst {ReactCurrentBatchConfig} = ReactSharedInternals;\n\nexport const NoTransition = null;\n\nexport function requestCurrentTransition(): Transition | null {\n return ReactCurrentBatchConfig.transition;\n}\n", "meta": {"content_hash": "dace65b4e7262d44f7cf8c5ddcea517a", "timestamp": "", "source": "github", "line_count": 12, "max_line_length": 71, "avg_line_length": 28.5, "alnum_prop": 0.8216374269005848, "repo_name": "camsong/react", "id": "d63b99a1862ef22435389d30a9298476688a7c25", "size": "542", "binary": false, "copies": "2", "ref": "refs/heads/main", "path": "packages/react-reconciler/src/ReactFiberTransition.js", "mode": "33188", "license": "mit", "language": [{"name": "C", "bytes": "5225"}, {"name": "C++", "bytes": "44278"}, {"name": "CSS", "bytes": "64729"}, {"name": "CoffeeScript", "bytes": "16826"}, {"name": "HTML", "bytes": "119964"}, {"name": "JavaScript", "bytes": "6161428"}, {"name": "Makefile", "bytes": "189"}, {"name": "Python", "bytes": "259"}, {"name": "Shell", "bytes": "2306"}, {"name": "TypeScript", "bytes": "20868"}]}}
{"text": "\n\n/*!\n * Copyright (c) 2019 by Contributors\n * \\file moments-inl.h\n * \\brief Moments operator\n * \\author Hao Jin\n*/\n\n#ifndef MXNET_OPERATOR_NN_MOMENTS_INL_H_\n#define MXNET_OPERATOR_NN_MOMENTS_INL_H_\n\n#include \n#include \"../tensor/broadcast_reduce_op.h\"\n\nnamespace mxnet {\nnamespace op {\n\nstruct MomentsParam : public dmlc::Parameter {\n dmlc::optional axes;\n bool keepdims;\n DMLC_DECLARE_PARAMETER(MomentsParam) {\n DMLC_DECLARE_FIELD(axes).set_default(dmlc::optional())\n .describe(\"Array of ints. Axes along which to compute mean and variance.\");\n DMLC_DECLARE_FIELD(keepdims).set_default(false)\n .describe(\"produce moments with the same dimensionality as the input.\");\n }\n};\n\ninline bool MomentsShape(const nnvm::NodeAttrs& attrs,\n mxnet::ShapeVector* in_attrs,\n mxnet::ShapeVector* out_attrs) {\n const MomentsParam& param = nnvm::get(attrs.parsed);\n CHECK_EQ(in_attrs->size(), 1U);\n CHECK_EQ(out_attrs->size(), 2U);\n\n mxnet::TShape out_shape =\n ReduceAxesShapeImpl((*in_attrs)[0], param.axes, param.keepdims, false);\n if (!param.axes.has_value() || param.axes.value().ndim() == 0) {\n LOG(FATAL) << \"Empty axes is not supported, if you would like to do global moments, \"\n << \"please pass all axes to axes argument\";\n }\n SHAPE_ASSIGN_CHECK(*out_attrs, 0, out_shape);\n SHAPE_ASSIGN_CHECK(*out_attrs, 1, out_shape);\n return true;\n}\n\ninline bool MomentsType(const nnvm::NodeAttrs& attrs,\n std::vector* in_attrs,\n std::vector* out_attrs) {\n CHECK_EQ(in_attrs->size(), 1U);\n CHECK_EQ(out_attrs->size(), 2U);\n\n TYPE_ASSIGN_CHECK(*out_attrs, 0, in_attrs->at(0));\n TYPE_ASSIGN_CHECK(*out_attrs, 1, in_attrs->at(0));\n TYPE_ASSIGN_CHECK(*in_attrs, 0, out_attrs->at(0));\n TYPE_ASSIGN_CHECK(*in_attrs, 0, out_attrs->at(1));\n return out_attrs->at(0) != -1 && out_attrs->at(1) != -1;\n}\n\nstruct VarBroadcastKernel {\n template\n MSHADOW_XINLINE static void Map(int i,\n DType *out,\n const DType *data,\n const DType *mean,\n mshadow::Shape<6> data_shape,\n mshadow::Shape<6> mean_shape) {\n size_t data_idx = i;\n size_t mean_idx = i;\n size_t data_stride = 1;\n size_t mean_stride = 1;\n for (int axis = 5; axis >= 0; --axis) {\n size_t axis_idx = data_idx % data_shape[axis];\n mean_idx -= axis_idx * data_stride;\n if (mean_shape[axis] != 1) {\n mean_idx += axis_idx * mean_stride;\n }\n data_idx /= data_shape[axis];\n data_stride *= data_shape[axis];\n mean_stride *= mean_shape[axis];\n }\n DType res = (data[i] - mean[mean_idx]);\n out[i] = res * res;\n }\n};\n\ntemplate\ninline void MomentsForwardImpl(const OpContext& ctx,\n const std::vector& inputs,\n const std::vector& req,\n const std::vector& outputs,\n const dmlc::optional& axes,\n const bool keepdims) {\n using namespace mshadow;\n using namespace mshadow_op;\n using namespace mxnet_op;\n\n Stream *s = ctx.get_stream();\n\n const TBlob& data = inputs[0];\n const TBlob& mean = outputs[0];\n const TBlob& var = outputs[1];\n\n mxnet::TShape small;\n if (keepdims) {\n small = outputs[0].shape_;\n } else {\n small = ReduceAxesShapeImpl(inputs[0].shape_, axes, true, false);\n }\n\n ReduceAxesComputeImpl(ctx, {data}, {req[0]}, {mean}, small);\n MSHADOW_TYPE_SWITCH(data.type_flag_, DType, {\n Shape<6> data_shape, mean_shape;\n for (int i = 0; i < 6; ++i) {\n data_shape[i] = (i < data.shape_.ndim()) ? data.shape_[i] : 1;\n mean_shape[i] = (i < small.ndim()) ? small[i] : 1;\n }\n Tensor temp_data =\n ctx.requested[0].get_space_typed(Shape1(data.shape_.Size()), s);;\n Kernel::Launch(s, data.shape_.Size(), temp_data.dptr_,\n data.dptr(), mean.dptr(), data_shape, mean_shape);\n ReduceAxesComputeImpl(\n ctx, {TBlob(temp_data).reshape(data.shape_)}, {kWriteTo}, {var}, small);\n });\n}\n\ntemplate\ninline void MomentsForward(const nnvm::NodeAttrs& attrs,\n const OpContext& ctx,\n const std::vector& inputs,\n const std::vector& req,\n const std::vector& outputs) {\n using namespace mshadow;\n using namespace mshadow_op;\n using namespace mxnet_op;\n\n CHECK_EQ(inputs.size(), 1U);\n CHECK_EQ(outputs.size(), 2U);\n\n const MomentsParam& param = nnvm::get(attrs.parsed);\n\n MomentsForwardImpl(ctx, inputs, req, outputs, param.axes, param.keepdims);\n}\n\ntemplate\nstruct VarBackwardKernel {\n template\n MSHADOW_XINLINE static void Map(int i,\n DType *igrad,\n const DType *ograd,\n const DType *data,\n const DType *mean,\n mshadow::Shape<6> data_shape,\n mshadow::Shape<6> mean_shape,\n const float N,\n const float ddof = 0.0f) {\n size_t data_idx = i;\n size_t mean_idx = i;\n size_t data_stride = 1;\n size_t mean_stride = 1;\n for (int axis = 5; axis >= 0; --axis) {\n size_t axis_idx = data_idx % data_shape[axis];\n mean_idx -= axis_idx * data_stride;\n if (mean_shape[axis] != 1) {\n mean_idx += axis_idx * mean_stride;\n }\n data_idx /= data_shape[axis];\n data_stride *= data_shape[axis];\n mean_stride *= mean_shape[axis];\n }\n KERNEL_ASSIGN(igrad[i], req, ograd[mean_idx] * (data[i] - mean[mean_idx]) * 2 / (N - ddof));\n }\n};\n\ntemplate\ninline void MomentsBackwardImpl(const nnvm::NodeAttrs& attrs,\n const OpContext& ctx,\n const std::vector& inputs,\n const std::vector& req,\n const std::vector& outputs,\n const dmlc::optional& axes) {\n using namespace mshadow;\n using namespace mshadow::expr;\n using namespace mshadow_op;\n using namespace mxnet_op;\n\n Stream *s = ctx.get_stream();\n\n const TBlob& mean_grad = inputs[0];\n const TBlob& var_grad = inputs[1];\n const TBlob& data = inputs[2];\n const TBlob& mean = inputs[3];\n const TBlob& var = inputs[4];\n const TBlob& data_grad = outputs[0];\n\n mxnet::TShape small = ReduceAxesShapeImpl(data.shape_, axes, true, false);\n BroadcastComputeImpl(attrs, ctx, {mean_grad}, req, outputs, small);\n MSHADOW_TYPE_SWITCH(outputs[0].type_flag_, DType, {\n Tensor igrad = outputs[0].FlatTo1D(s);\n igrad /= scalar(outputs[0].Size()/inputs[0].Size());\n });\n\n Shape<6> data_shape, var_shape;\n float N = data_grad.Size() / var.Size();\n for (int i = 0; i < 6; ++i) {\n data_shape[i] = (i < data.shape_.ndim()) ? data.shape_[i] : 1;\n var_shape[i] = (i < small.ndim()) ? small[i] : 1;\n }\n MSHADOW_TYPE_SWITCH(data_grad.type_flag_, DType, {\n Kernel, xpu>::Launch(\n s, data_grad.shape_.Size(), data_grad.dptr(), var_grad.dptr(),\n data.dptr(), mean.dptr(), data_shape, var_shape, N);\n });\n}\n\ntemplate\ninline void MomentsBackward(const nnvm::NodeAttrs& attrs,\n const OpContext& ctx,\n const std::vector& inputs,\n const std::vector& req,\n const std::vector& outputs) {\n using namespace mshadow;\n using namespace mshadow_op;\n using namespace mxnet_op;\n\n CHECK_EQ(inputs.size(), 5U);\n CHECK_EQ(outputs.size(), 1U);\n\n const MomentsParam& param = nnvm::get(attrs.parsed);\n\n MomentsBackwardImpl(attrs, ctx, inputs, req, outputs, param.axes);\n}\n\n} // namespace op\n} // namespace mxnet\n#endif // MXNET_OPERATOR_NN_MOMENTS_INL_H_\n", "meta": {"content_hash": "1379c25c73b10bf4cbf94d1e3e5177af", "timestamp": "", "source": "github", "line_count": 237, "max_line_length": 96, "avg_line_length": 36.08438818565401, "alnum_prop": 0.5748362956033677, "repo_name": "reminisce/mxnet", "id": "6a9bdc54b9059e922e80bdd01e6bde06bf84326b", "size": "9359", "binary": false, "copies": "6", "ref": "refs/heads/master", "path": "src/operator/nn/moments-inl.h", "mode": "33188", "license": "apache-2.0", "language": [{"name": "ANTLR", "bytes": "1731"}, {"name": "Batchfile", "bytes": "13130"}, {"name": "C", "bytes": "215572"}, {"name": "C++", "bytes": "7680259"}, {"name": "CMake", "bytes": "99958"}, {"name": "Clojure", "bytes": "622688"}, {"name": "Cuda", "bytes": "970884"}, {"name": "Dockerfile", "bytes": "85151"}, {"name": "Groovy", "bytes": "122800"}, {"name": "HTML", "bytes": "40277"}, {"name": "Java", "bytes": "205196"}, {"name": "Julia", "bytes": "436326"}, {"name": "Jupyter Notebook", "bytes": "3660387"}, {"name": "MATLAB", "bytes": "34903"}, {"name": "Makefile", "bytes": "201597"}, {"name": "Perl", "bytes": "1550163"}, {"name": "Perl 6", "bytes": "7280"}, {"name": "PowerShell", "bytes": "13786"}, {"name": "Python", "bytes": "7842403"}, {"name": "R", "bytes": "357807"}, {"name": "Scala", "bytes": "1305036"}, {"name": "Shell", "bytes": "427407"}, {"name": "Smalltalk", "bytes": "3497"}]}}
{"text": "class DeviceSettingListener < AsakusaSatellite::Hook::Listener\n render_on :account_setting_item, :partial => \"device_setting\"\nend\n\n", "meta": {"content_hash": "46ad3aa3b2c9fc525d06733f4de789d0", "timestamp": "", "source": "github", "line_count": 4, "max_line_length": 63, "avg_line_length": 33.0, "alnum_prop": 0.7803030303030303, "repo_name": "mallowlabs/AsakusaSatellite", "id": "fc863576a1861c4131cf2c1c604d62a735622fb0", "size": "132", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "plugins/as_device_setting/lib/device_setting_listener.rb", "mode": "33188", "license": "mit", "language": [{"name": "CSS", "bytes": "4295"}, {"name": "JavaScript", "bytes": "70132"}, {"name": "Ruby", "bytes": "176805"}, {"name": "Shell", "bytes": "1621"}]}}
{"text": "require_relative '../../spec_helper'\n\nVALID_UUID_REGEX = /^[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i\nUUID_STRING1 = 'de305d54-75b4-431b-adb2-eb6b9e546014'\nUUID_STRING2 = 'de305d54-75b4-431b-adb2-eb6b9e546020'\nUUID_PACKED_STRING1 = \"\\xde\\x30\\x5d\\x54\\x75\\xb4\\x43\\x1b\\xad\\xb2\\xeb\\x6b\\x9e\\x54\\x60\\x14\"\nUUID_PACKED_STRING2 = \"\\xde\\x30\\x5d\\x54\\x75\\xb4\\x43\\x1b\\xad\\xb2\\xeb\\x6b\\x9e\\x54\\x60\\x20\"\n\nRSpec.describe Lobster::Uuid do\n\n describe '::DEFAULT' do\n subject { Lobster::Uuid::DEFAULT }\n\n it 'is all zeroes' do\n expect(subject).to eq(\"\\x0\" * 16)\n end\n\n it 'is frozen' do\n is_expected.to be_frozen\n end\n end\n \n describe '#new' do\n context 'with a valid value' do\n subject(:uuid) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n\n describe 'the value' do\n subject { uuid.value }\n\n it 'is stored' do\n is_expected.to eq UUID_PACKED_STRING1\n end\n end\n end\n\n context 'with an invalid value' do\n it 'rejects a malformed string' do\n expect { Lobster::Uuid.new('foobar') }.to raise_error(ArgumentError)\n end\n end\n\n end\n\n context '.generate' do\n subject(:uuid) { Lobster::Uuid.generate }\n\n describe 'the value' do\n subject { uuid.value }\n\n # The chances of a randomly generated empty UUID is virtually impossible.\n # Besides, the UUID standards don't allow generated UUID to be all zeroes.\n it 'is random' do\n is_expected.not_to eq(\"\\x0\" * 16)\n end\n end\n\n describe 'the string' do\n subject { uuid.to_s }\n\n it 'is valid' do\n is_expected.to match VALID_UUID_REGEX\n end\n end\n end\n\n describe '.parse' do\n\n context 'with a valid UUID' do\n subject { Lobster::Uuid.parse(UUID_STRING1) }\n\n it 'parses correctly' do\n expect(subject.to_s).to eq(UUID_STRING1)\n end\n end\n\n context 'with a malformed string' do\n it 'returns nil' do\n expect(Lobster::Uuid.parse('foobar')).to be_nil\n end\n end\n\n context 'with an invalid argument' do\n it 'rejects a non-string' do\n expect { Lobster::Uuid.parse(5) }.to raise_error(ArgumentError)\n end\n end\n end\n\n describe '#value' do\n subject(:uuid) { Lobster::Uuid.new(UUID_PACKED_STRING1).value }\n\n it 'is a string' do\n is_expected.to be_a(String)\n end\n\n it 'is frozen' do\n is_expected.to be_frozen\n end\n\n describe '.length' do\n subject { uuid.length }\n\n it 'is 16 bytes' do\n is_expected.to be 16\n end\n end\n end\n\n describe '#eql?' do\n subject(:uuid) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n subject { uuid.eql?(other) }\n\n context 'with two identical UUIDs' do\n let(:other) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n\n it 'returns true' do\n is_expected.to eq true\n end\n end\n\n context 'with two different UUIDs' do\n let(:other) { Lobster::Uuid.new(UUID_PACKED_STRING2) }\n\n it 'returns false' do\n is_expected.to eq false\n end\n end\n\n context 'without a UUID' do\n let(:other) { 'foobar' }\n\n it 'returns false' do\n is_expected.to eq false\n end\n end\n end\n\n describe '#==' do\n subject { first == second }\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n\n context 'with equal UUIDs' do\n let(:second) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n it 'is true' do\n is_expected.to be true\n end\n end\n\n context 'with the same instance' do\n let(:second) { first }\n it 'is true' do\n is_expected.to be true\n end\n end\n\n context 'with unequal UUIDs' do\n let(:second) { Lobster::Uuid.new(UUID_PACKED_STRING2) }\n it 'is false' do\n is_expected.to be false\n end\n end\n\n context 'with nil' do\n let(:second) { nil }\n it 'is false' do\n is_expected.to be false\n end\n end\n\n context 'with a malformed string' do\n let(:second) { 'foobar' }\n it 'is false' do\n is_expected.to be false\n end\n end\n\n context 'with a non-string' do\n let(:second) { 5 }\n it 'is false' do\n is_expected.to be false\n end\n end\n\n context 'with identical value' do\n let(:second) { first.value }\n it 'is true' do\n is_expected.to be true\n end\n end\n\n context 'with identical string' do\n let(:second) { first.to_s }\n it 'is true' do\n is_expected.to be true\n end\n end\n end\n\n describe '#<=>' do\n subject { first <=> second }\n\n context 'with an equal UUID' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n let(:second) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n it 'is 0' do\n is_expected.to eq 0\n end\n end\n\n context 'with the same instance' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n let(:second) { first }\n it 'is 0' do\n is_expected.to eq 0\n end\n end\n\n context 'with a lesser UUID' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING2) }\n let(:second) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n it 'is 1' do\n is_expected.to eq 1\n end\n end\n\n context 'with a greater UUID' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n let(:second) { Lobster::Uuid.new(UUID_PACKED_STRING2) }\n it 'is -1' do\n is_expected.to eq(-1)\n end\n end\n\n context 'with nil' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n let(:second) { nil }\n it 'is nil' do\n is_expected.to be_nil\n end\n end\n\n context 'with a number' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n let(:second) { 500 }\n it 'is nil' do\n is_expected.to be_nil\n end\n end\n\n context 'with an identical value' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n let(:second) { UUID_PACKED_STRING1 }\n it 'is 0' do\n is_expected.to eq 0\n end\n end\n\n context 'with a lesser value' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING2) }\n let(:second) { UUID_PACKED_STRING1 }\n it 'is 1' do\n is_expected.to eq 1\n end\n end\n\n context 'with a greater value' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n let(:second) { UUID_PACKED_STRING2 }\n it 'is -1' do\n is_expected.to eq(-1)\n end\n end\n\n context 'with an equal string' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n let(:second) { UUID_STRING1 }\n it 'is 0' do\n is_expected.to eq 0\n end\n end\n\n context 'with a lesser string' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING2) }\n let(:second) { UUID_STRING1 }\n it 'is 1' do\n is_expected.to eq 1\n end\n end\n\n context 'with a greater string' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1) }\n let(:second) { UUID_STRING2 }\n it 'is -1' do\n is_expected.to eq(-1)\n end\n end\n\n context 'with an invalid string' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING2) }\n let(:second) { 'foobar' }\n it 'is nil' do\n is_expected.to be_nil\n end\n end\n end\n\n describe '#hash' do\n subject { Lobster::Uuid.new(UUID_PACKED_STRING1).hash }\n\n it 'is a Fixnum' do\n is_expected.to be_a(Fixnum)\n end\n\n context 'with identical UUIDs' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1).hash }\n let(:second) { Lobster::Uuid.new(UUID_PACKED_STRING1).hash }\n\n it 'returns identical values' do\n expect(first).to eq(second)\n end\n end\n\n context 'with different UUIDs' do\n let(:first) { Lobster::Uuid.new(UUID_PACKED_STRING1).hash }\n let(:second) { Lobster::Uuid.new(UUID_PACKED_STRING2).hash }\n\n it 'returns different values' do\n expect(first).to_not eq(second)\n end\n end\n end\n\n describe '#to_s' do\n subject { Lobster::Uuid.new(UUID_PACKED_STRING1).to_s }\n\n it 'is a String' do\n is_expected.to be_a String\n end\n\n it 'is a valid UUID string' do\n is_expected.to match(VALID_UUID_REGEX)\n end\n\n it 'equals the initial value' do\n is_expected.to eq(UUID_STRING1)\n end\n\n context 'with bytes less than 16' do\n subject { Lobster::Uuid.new(\"\\x05\\x30\\x5d\\x54\\x75\\x02\\x43\\x1b\\xad\\xb2\\xeb\\x6b\\x9e\\x54\\x60\\x00\").to_s }\n\n it 'pads with zeroes' do\n is_expected.to eq('05305d54-7502-431b-adb2-eb6b9e546000')\n end\n end\n end\n\nend\n", "meta": {"content_hash": "1642c878d4fcdc5ebd2a9e8b8905586d", "timestamp": "", "source": "github", "line_count": 357, "max_line_length": 108, "avg_line_length": 23.946778711484594, "alnum_prop": 0.5853316177330682, "repo_name": "gachapon/lobster-common", "id": "ed5b0f0b607bf7c015be4f064dfa501f5129bfd2", "size": "8549", "binary": false, "copies": "1", "ref": "refs/heads/dev", "path": "spec/lib/lobster/uuid_spec.rb", "mode": "33188", "license": "mit", "language": [{"name": "Ruby", "bytes": "44314"}]}}
{"text": "package com.asksunny.schema.parser;\r\n\r\nimport java.util.HashMap;\r\nimport java.util.Map;\r\nimport java.util.Set;\r\n\r\npublic class KeywordDictionary extends HashMap {\r\n\r\n\t/**\r\n\t * \r\n\t */\r\n\tprivate static final long serialVersionUID = 1L;\r\n\r\n\tpublic KeywordDictionary() {\r\n\t\tthis.put(\"CREATE\", Keyword.CREATE);\r\n\t\tthis.put(\"TABLE\", Keyword.TABLE);\r\n\t\tthis.put(\"NOT\", Keyword.NOT);\r\n\t\tthis.put(\"NULL\", Keyword.NULL);\r\n\t\tthis.put(\"PRIMARY\", Keyword.PRIMARY);\r\n\t\tthis.put(\"KEY\", Keyword.KEY);\r\n\t\tthis.put(\"VARCHAR\", Keyword.VARCHAR);\r\n\t\tthis.put(\"NUMBER\", Keyword.NUMBER);\r\n\t\tthis.put(\"INT\", Keyword.INT);\r\n\t\tthis.put(\"BIGINT\", Keyword.BIGINT);\r\n\t\tthis.put(\"INTEGER\", Keyword.INTEGER);\r\n\t\tthis.put(\"DOUBLE\", Keyword.DOUBLE);\r\n\t\tthis.put(\"VARCHAR2\", Keyword.VARCHAR);\r\n\t\tthis.put(\"BINARY\", Keyword.BINARY);\r\n\t\tthis.put(\"LONG\", Keyword.LONG);\r\n\t\tthis.put(\"DATE\", Keyword.DATE);\r\n\t\tthis.put(\"TIME\", Keyword.TIME);\r\n\t\tthis.put(\"TIMESTAMP\", Keyword.TIMESTAMP);\r\n\t\tthis.put(\"ALTER\", Keyword.ALTER);\r\n\t\tthis.put(\"ADD\", Keyword.ADD);\r\n\t\tthis.put(\"CHAR\", Keyword.CHAR);\r\n\t\tthis.put(\"CONSTRAINT\", Keyword.CONSTRAINT);\r\n\t\tthis.put(\"FOREIGN\", Keyword.FOREIGN);\r\n\t\tthis.put(\"REFERENCES\", Keyword.REFERENCES);\r\n\t\tthis.put(\"UNIQUE\", Keyword.UNIQUE);\r\n\t\tthis.put(\"INDEX\", Keyword.INDEX);\r\n\t\tthis.put(\"BYTE\", Keyword.BYTE);\r\n\t\tthis.put(\"NOPARALLELCREATE\", Keyword.CREATE);\r\n\t\tthis.put(\"NOPARALLEL\", Keyword.NOPARALLEL);\r\n\t\tthis.put(\"PARALLEL\", Keyword.PARALLEL);\r\n\t\tthis.put(\"*\", Keyword.ASTERISK);\r\n\t\tthis.put(\"IMAGE\", Keyword.IMAGE);\r\n\t\tthis.put(\"TEXT\", Keyword.TEXT);\r\n\t\tthis.put(\"IDENTITY\", Keyword.IDENTITY);\r\n\t\tthis.put(\"AUTOINCREMENT\", Keyword.IDENTITY);\r\n\t\tthis.put(\"AUTO_INCREMENT\", Keyword.IDENTITY);\r\n\t\tthis.put(\"DEFAULT\", Keyword.DEFAULT);\r\n\t\tthis.put(\"COLUMN_FORMAT\", Keyword.FORMAT);\r\n\t\tthis.put(\"FORMAT\", Keyword.FORMAT);\t\t\r\n\t}\r\n\t\r\n\t\r\n\t\r\n\r\n\t@Override\r\n\tpublic Keyword get(Object key) {\r\n\t\t\r\n\t\treturn super.get(key.toString().toUpperCase());\r\n\t}\r\n\r\n\t@Override\r\n\tpublic Keyword put(String key, Keyword value) {\r\n\t\treturn super.put(key.toUpperCase(), value);\r\n\t}\r\n\r\n\t@Override\r\n\tpublic void putAll(Map extends String, ? extends Keyword> m) {\r\n\t\tSet extends String> keys = m.keySet();\r\n\t\tfor (String string : keys) {\r\n\t\t\tsuper.put(string.toUpperCase(), m.get(string));\r\n\t\t}\r\n\t}\r\n\r\n\t@Override\r\n\tpublic boolean containsKey(Object key) {\r\n\t\t\r\n\t\treturn super.containsKey(key.toString().toUpperCase());\r\n\t}\r\n\r\n}\r\n", "meta": {"content_hash": "17e0844e355090632f0e6aef8dd4ab5e", "timestamp": "", "source": "github", "line_count": 84, "max_line_length": 65, "avg_line_length": 28.75, "alnum_prop": 0.6650103519668737, "repo_name": "devsunny/jscaffold", "id": "0e5042958a41441b8acf16b22b7e71f333e3239b", "size": "2415", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/main/java/com/asksunny/schema/parser/KeywordDictionary.java", "mode": "33188", "license": "mit", "language": [{"name": "FreeMarker", "bytes": "37206"}, {"name": "Java", "bytes": "312644"}]}}
{"text": "\n#include \"arm_math.h\"\n\n/** \n * @ingroup groupMath \n */\n\n/** \n * @defgroup offset Vector Offset \n * \n * Adds a constant offset to each element of a vector. \n * \n * \n * pDst[n] = pSrc[n] + offset, 0 <= n < blockSize. \n *
\n * \n * There are separate functions for floating-point, Q7, Q15, and Q31 data types. \n */\n\n/** \n * @addtogroup offset \n * @{ \n */\n\n/** \n * @brief Adds a constant offset to a floating-point vector. \n * @param[in] *pSrc points to the input vector \n * @param[in] offset is the offset to be added \n * @param[out] *pDst points to the output vector \n * @param[in] blockSize number of samples in the vector \n * @return none. \n */\n\n\nvoid arm_offset_f32(\n float32_t * pSrc,\n float32_t offset,\n float32_t * pDst,\n uint32_t blockSize)\n{\n uint32_t blkCnt; /* loop counter */\n\n#ifndef ARM_MATH_CM0\n\n/* Run the below code for Cortex-M4 and Cortex-M3 */\n float32_t in1, in2, in3, in4;\n\n /*loop Unrolling */\n blkCnt = blockSize >> 2u;\n\n /* First part of the processing with loop unrolling. Compute 4 outputs at a time. \n ** a second loop below computes the remaining 1 to 3 samples. */\n while(blkCnt > 0u)\n {\n /* C = A + offset */\n /* Add offset and then store the results in the destination buffer. */\n /* read samples from source */\n in1 = *pSrc;\n in2 = *(pSrc + 1);\n\n /* add offset to input */\n in1 = in1 + offset;\n\n /* read samples from source */\n in3 = *(pSrc + 2);\n\n /* add offset to input */\n in2 = in2 + offset;\n\n /* read samples from source */\n in4 = *(pSrc + 3);\n\n /* add offset to input */\n in3 = in3 + offset;\n\n /* store result to destination */\n *pDst = in1;\n\n /* add offset to input */\n in4 = in4 + offset;\n\n /* store result to destination */\n *(pDst + 1) = in2;\n\n /* store result to destination */\n *(pDst + 2) = in3;\n\n /* store result to destination */\n *(pDst + 3) = in4;\n\n /* update pointers to process next samples */\n pSrc += 4u;\n pDst += 4u;\n\n /* Decrement the loop counter */\n blkCnt--;\n }\n\n /* If the blockSize is not a multiple of 4, compute any remaining output samples here. \n ** No loop unrolling is used. */\n blkCnt = blockSize % 0x4u;\n\n#else\n\n /* Run the below code for Cortex-M0 */\n\n /* Initialize blkCnt with number of samples */\n blkCnt = blockSize;\n\n#endif /* #ifndef ARM_MATH_CM0 */\n\n while(blkCnt > 0u)\n {\n /* C = A + offset */\n /* Add offset and then store the result in the destination buffer. */\n *pDst++ = (*pSrc++) + offset;\n\n /* Decrement the loop counter */\n blkCnt--;\n }\n}\n\n/** \n * @} end of offset group \n */\n", "meta": {"content_hash": "f2b978d8b36fff3a0eae28c44484593c", "timestamp": "", "source": "github", "line_count": 125, "max_line_length": 96, "avg_line_length": 22.592, "alnum_prop": 0.5439093484419264, "repo_name": "jys0305/highspeedlogger", "id": "d7ca663bbddb46767e61f4c926942e9b5892f6e8", "size": "3945", "binary": false, "copies": "56", "ref": "refs/heads/master", "path": "sw/libs/STM32F4xx_DSP_StdPeriph_Lib_V1.1.0/Libraries/CMSIS/DSP_Lib/Source/BasicMathFunctions/arm_offset_f32.c", "mode": "33188", "license": "mit", "language": [{"name": "Assembly", "bytes": "280928"}, {"name": "C", "bytes": "21114329"}, {"name": "C++", "bytes": "100991"}, {"name": "HTML", "bytes": "455966"}, {"name": "LSL", "bytes": "47664"}, {"name": "Makefile", "bytes": "4331"}, {"name": "Objective-C", "bytes": "1718"}]}}
{"text": "\n\npackage javassist.bytecode.stackmap;\n\nimport javassist.bytecode.*;\nimport java.util.HashMap;\nimport java.util.ArrayList;\n\n/**\n * A basic block is a sequence of bytecode that does not contain jump/branch\n * instructions except at the last bytecode.\n * Since Java7 or later does not allow JSR, this class throws an exception when\n * it finds JSR.\n */\npublic class BasicBlock {\n static class JsrBytecode extends BadBytecode {\n JsrBytecode() { super(\"JSR\"); }\n }\n\n protected int position, length;\n protected int incoming; // the number of incoming branches.\n protected BasicBlock[] exit; // null if the block is a leaf.\n protected boolean stop; // true if the block ends with an unconditional jump. \n protected Catch toCatch;\n\n protected BasicBlock(int pos) {\n position = pos;\n length = 0;\n incoming = 0;\n }\n\n public static BasicBlock find(BasicBlock[] blocks, int pos)\n throws BadBytecode\n {\n for (int i = 0; i < blocks.length; i++) {\n int iPos = blocks[i].position;\n if (iPos <= pos && pos < iPos + blocks[i].length)\n return blocks[i];\n }\n\n throw new BadBytecode(\"no basic block at \" + pos);\n }\n\n public static class Catch {\n public Catch next;\n public BasicBlock body;\n public int typeIndex;\n Catch(BasicBlock b, int i, Catch c) {\n body = b;\n typeIndex = i;\n next = c;\n }\n }\n\n public String toString() {\n StringBuffer sbuf = new StringBuffer();\n String cname = this.getClass().getName();\n int i = cname.lastIndexOf('.');\n sbuf.append(i < 0 ? cname : cname.substring(i + 1));\n sbuf.append(\"[\");\n toString2(sbuf);\n sbuf.append(\"]\");\n return sbuf.toString();\n }\n\n protected void toString2(StringBuffer sbuf) {\n sbuf.append(\"pos=\").append(position).append(\", len=\")\n .append(length).append(\", in=\").append(incoming)\n .append(\", exit{\");\n if (exit != null) {\n for (int i = 0; i < exit.length; i++)\n sbuf.append(exit[i].position).append(\",\");\n }\n\n sbuf.append(\"}, {\");\n Catch th = toCatch;\n while (th != null) {\n sbuf.append(\"(\").append(th.body.position).append(\", \")\n .append(th.typeIndex).append(\"), \");\n th = th.next;\n }\n\n sbuf.append(\"}\");\n }\n\n static class Mark implements Comparable {\n int position;\n BasicBlock block;\n BasicBlock[] jump;\n boolean alwaysJmp; // true if an unconditional branch.\n int size; // 0 unless the mark indicates RETURN etc. \n Catch catcher;\n\n Mark(int p) {\n position = p;\n block = null;\n jump = null;\n alwaysJmp = false;\n size = 0;\n catcher = null;\n }\n\n public int compareTo(Object obj) {\n if (obj instanceof Mark) {\n int pos = ((Mark)obj).position;\n return position - pos;\n }\n\n return -1;\n }\n\n void setJump(BasicBlock[] bb, int s, boolean always) {\n jump = bb;\n size = s;\n alwaysJmp = always;\n }\n }\n\n public static class Maker {\n /* Override these two methods if a subclass of BasicBlock must be\n * instantiated.\n */\n protected BasicBlock makeBlock(int pos) {\n return new BasicBlock(pos);\n }\n\n protected BasicBlock[] makeArray(int size) {\n return new BasicBlock[size];\n }\n\n private BasicBlock[] makeArray(BasicBlock b) {\n BasicBlock[] array = makeArray(1);\n array[0] = b;\n return array;\n }\n\n private BasicBlock[] makeArray(BasicBlock b1, BasicBlock b2) {\n BasicBlock[] array = makeArray(2);\n array[0] = b1;\n array[1] = b2;\n return array;\n }\n\n public BasicBlock[] make(MethodInfo minfo) throws BadBytecode {\n CodeAttribute ca = minfo.getCodeAttribute();\n if (ca == null)\n return null;\n\n CodeIterator ci = ca.iterator();\n return make(ci, 0, ci.getCodeLength(), ca.getExceptionTable());\n }\n\n public BasicBlock[] make(CodeIterator ci, int begin, int end,\n ExceptionTable et)\n throws BadBytecode\n {\n HashMap marks = makeMarks(ci, begin, end, et);\n BasicBlock[] bb = makeBlocks(marks);\n addCatchers(bb, et);\n return bb;\n }\n\n /* Branch target\n */\n private Mark makeMark(HashMap table, int pos) {\n return makeMark0(table, pos, true, true);\n }\n\n /* Branch instruction.\n * size > 0\n */\n private Mark makeMark(HashMap table, int pos, BasicBlock[] jump,\n int size, boolean always) {\n Mark m = makeMark0(table, pos, false, false);\n m.setJump(jump, size, always);\n return m;\n }\n\n private Mark makeMark0(HashMap table, int pos,\n boolean isBlockBegin, boolean isTarget) {\n Integer p = new Integer(pos);\n Mark m = (Mark)table.get(p);\n if (m == null) {\n m = new Mark(pos);\n table.put(p, m);\n }\n\n if (isBlockBegin) {\n if (m.block == null)\n m.block = makeBlock(pos);\n\n if (isTarget)\n m.block.incoming++;\n }\n\n return m;\n }\n\n private HashMap makeMarks(CodeIterator ci, int begin, int end,\n ExceptionTable et)\n throws BadBytecode\n {\n ci.begin();\n ci.move(begin);\n HashMap marks = new HashMap();\n while (ci.hasNext()) {\n int index = ci.next();\n if (index >= end)\n break;\n\n int op = ci.byteAt(index);\n if ((Opcode.IFEQ <= op && op <= Opcode.IF_ACMPNE)\n || op == Opcode.IFNULL || op == Opcode.IFNONNULL) {\n Mark to = makeMark(marks, index + ci.s16bitAt(index + 1));\n Mark next = makeMark(marks, index + 3);\n makeMark(marks, index, makeArray(to.block, next.block), 3, false);\n }\n else if (Opcode.GOTO <= op && op <= Opcode.LOOKUPSWITCH)\n switch (op) {\n case Opcode.GOTO :\n makeGoto(marks, index, index + ci.s16bitAt(index + 1), 3);\n break;\n case Opcode.JSR :\n makeJsr(marks, index, index + ci.s16bitAt(index + 1), 3);\n break;\n case Opcode.RET :\n makeMark(marks, index, null, 2, true);\n break;\n case Opcode.TABLESWITCH : {\n int pos = (index & ~3) + 4;\n int low = ci.s32bitAt(pos + 4);\n int high = ci.s32bitAt(pos + 8);\n int ncases = high - low + 1;\n BasicBlock[] to = makeArray(ncases + 1);\n to[0] = makeMark(marks, index + ci.s32bitAt(pos)).block; // default branch target\n int p = pos + 12;\n int n = p + ncases * 4;\n int k = 1;\n while (p < n) {\n to[k++] = makeMark(marks, index + ci.s32bitAt(p)).block;\n p += 4;\n }\n makeMark(marks, index, to, n - index, true);\n break; }\n case Opcode.LOOKUPSWITCH : {\n int pos = (index & ~3) + 4;\n int ncases = ci.s32bitAt(pos + 4);\n BasicBlock[] to = makeArray(ncases + 1);\n to[0] = makeMark(marks, index + ci.s32bitAt(pos)).block; // default branch target\n int p = pos + 8 + 4;\n int n = p + ncases * 8 - 4;\n int k = 1;\n while (p < n) {\n to[k++] = makeMark(marks, index + ci.s32bitAt(p)).block;\n p += 8;\n }\n makeMark(marks, index, to, n - index, true);\n break; }\n }\n else if ((Opcode.IRETURN <= op && op <= Opcode.RETURN) || op == Opcode.ATHROW)\n makeMark(marks, index, null, 1, true);\n else if (op == Opcode.GOTO_W)\n makeGoto(marks, index, index + ci.s32bitAt(index + 1), 5);\n else if (op == Opcode.JSR_W)\n makeJsr(marks, index, index + ci.s32bitAt(index + 1), 5);\n else if (op == Opcode.WIDE && ci.byteAt(index + 1) == Opcode.RET)\n makeMark(marks, index, null, 4, true);\n }\n\n if (et != null) {\n int i = et.size();\n while (--i >= 0) {\n makeMark0(marks, et.startPc(i), true, false);\n makeMark(marks, et.handlerPc(i));\n }\n }\n\n return marks;\n }\n\n private void makeGoto(HashMap marks, int pos, int target, int size) {\n Mark to = makeMark(marks, target);\n BasicBlock[] jumps = makeArray(to.block);\n makeMark(marks, pos, jumps, size, true);\n }\n\n /*\n * We could ignore JSR since Java 7 or later does not allow it.\n * See The JVM Spec. Sec. 4.10.2.5.\n */\n protected void makeJsr(HashMap marks, int pos, int target, int size) throws BadBytecode {\n /*\n Mark to = makeMark(marks, target);\n Mark next = makeMark(marks, pos + size);\n BasicBlock[] jumps = makeArray(to.block, next.block);\n makeMark(marks, pos, jumps, size, false);\n */\n throw new JsrBytecode();\n }\n\n private BasicBlock[] makeBlocks(HashMap markTable) {\n Mark[] marks = (Mark[])markTable.values()\n .toArray(new Mark[markTable.size()]);\n java.util.Arrays.sort(marks);\n ArrayList blocks = new ArrayList();\n int i = 0;\n BasicBlock prev;\n if (marks.length > 0 && marks[0].position == 0 && marks[0].block != null)\n prev = getBBlock(marks[i++]);\n else\n prev = makeBlock(0);\n\n blocks.add(prev);\n while (i < marks.length) {\n Mark m = marks[i++];\n BasicBlock bb = getBBlock(m);\n if (bb == null) {\n // the mark indicates a branch instruction\n if (prev.length > 0) {\n // the previous mark already has exits.\n prev = makeBlock(prev.position + prev.length);\n blocks.add(prev);\n }\n\n prev.length = m.position + m.size - prev.position;\n prev.exit = m.jump;\n prev.stop = m.alwaysJmp;\n }\n else {\n // the mark indicates a branch target\n if (prev.length == 0) {\n prev.length = m.position - prev.position;\n bb.incoming++;\n prev.exit = makeArray(bb);\n }\n else {\n // the previous mark already has exits.\n int prevPos = prev.position;\n if (prevPos + prev.length < m.position) {\n prev = makeBlock(prevPos + prev.length);\n prev.length = m.position - prevPos;\n // the incoming flow from dead code is not counted\n // bb.incoming++;\n prev.exit = makeArray(bb);\n }\n }\n\n blocks.add(bb);\n prev = bb;\n }\n }\n\n return (BasicBlock[])blocks.toArray(makeArray(blocks.size()));\n }\n\n private static BasicBlock getBBlock(Mark m) {\n BasicBlock b = m.block;\n if (b != null && m.size > 0) {\n b.exit = m.jump;\n b.length = m.size;\n b.stop = m.alwaysJmp;\n }\n\n return b;\n }\n\n private void addCatchers(BasicBlock[] blocks, ExceptionTable et)\n throws BadBytecode\n {\n if (et == null)\n return;\n\n int i = et.size();\n while (--i >= 0) {\n BasicBlock handler = find(blocks, et.handlerPc(i));\n int start = et.startPc(i);\n int end = et.endPc(i);\n int type = et.catchType(i);\n handler.incoming--;\n for (int k = 0; k < blocks.length; k++) {\n BasicBlock bb = blocks[k];\n int iPos = bb.position;\n if (start <= iPos && iPos < end) {\n bb.toCatch = new Catch(handler, type, bb.toCatch);\n handler.incoming++;\n }\n }\n }\n }\n }\n}\n", "meta": {"content_hash": "f1a0cceb83de5d2bb6046c9fcb64b93d", "timestamp": "", "source": "github", "line_count": 391, "max_line_length": 107, "avg_line_length": 35.18414322250639, "alnum_prop": 0.4474085919895326, "repo_name": "oneliang/third-party-lib", "id": "6213e22a64b2b627e9be31e387205d826fb1866d", "size": "14461", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "javassist/javassist/bytecode/stackmap/BasicBlock.java", "mode": "33188", "license": "apache-2.0", "language": [{"name": "HTML", "bytes": "31084"}, {"name": "Java", "bytes": "14382753"}]}}
{"text": "/* System calls. */\n#define SEND\t\t 1\t/* function code for sending messages */\n#define RECEIVE\t\t 2\t/* function code for receiving messages */\n#define BOTH\t\t 3\t/* function code for SEND + RECEIVE */\n#define ANY (NR_PROCS+100)\t/* receive(ANY, buf) accepts from any source */\n\n/* Task numbers, function codes and reply codes. */\n\n#define TTY -NR_TASKS\t/* terminal I/O class */\n#\tdefine TTY_READ\t 3\t/* fcn code for reading from tty */\n#\tdefine TTY_WRITE 4\t/* fcn code for writing to tty */\n#\tdefine TTY_IOCTL 5\t/* fcn code for ioctl */\n#\tdefine TTY_SETPGRP 6\t/* fcn code for setpgrp */\n#\tdefine TTY_OPEN 7\t/* fcn code for opening tty */\n#\tdefine TTY_CLOSE 8\t/* fcn code for closing tty */\n#\tdefine SUSPEND\t -998\t/* used in interrupts when tty has no data */\n\n#ifdef AM_KERNEL\n#define\tAMOEBA\n#endif\n\n#ifdef AMOEBA\n\n/* There are AM_NTASK copies of the amoeba kernel task.\n * If you change AM_NTASKS be sure to adjust kernel/table.c and fs/table.c\n */\n#define AM_NTASKS\t 4\t/* number of kernel tasks of this class */\n\n#define\tAMINT_CLASS\t (TTY+1)\t/* Amoeba event handler */\n#define AMOEBA_CLASS \t (AMINT_CLASS+AM_NTASKS) /* transaction handlers */\n#\tdefine ETHER_ARRIV 1\t/* fcn code for packet arrival */\n#\tdefine AM_TRANS 2\t/* amoeba transaction */\t\t\n#\tdefine AM_GETREQ 3\t/* amoeba getrequest */\n#\tdefine AM_PUTREP 4\t/* amoeba putrep */\n#\tdefine AM_REVIVE 6\t/* used by kernel task to revive luser task */\n#\tdefine AM_TIMEOUT 8\t/* used to talk to clock task */\n#\tdefine AM_PUTSIG 9\t/* when the luser hits the DEL ! */\n#\tdefine AM_TASK_DIED 10 /* sent if task died during a transaction */\n\n#else\t/* if AMOEBA not defined */\n\n#define\tAMOEBA_CLASS\tTTY\n\n#endif /* AMOEBA */\n\n/*\n * New class definitions should go here and should be defined relative\n * to AMOEBA_CLASS (ie. as AMOEBA_CLASS+n, for the nth task added).\n */\n\n#define IDLE (AMOEBA_CLASS+1)\t/* task to run when there's nothing to run */\n\n#define PRINTER -7\t\t/* printer I/O class */\n/* The printer uses the same commands as TTY. */\n\n#define WINCHESTER -6\t/* winchester (hard) disk class */\n#define FLOPPY -5\t/* floppy disk class */\n#\tdefine DISK_READ 3\t/* fcn code to DISK (must equal TTY_READ) */\n#\tdefine DISK_WRITE 4\t/* fcn code to DISK (must equal TTY_WRITE) */\n#\tdefine DISK_IOCTL 5\t/* fcn code for setting up RAM disk */\n#\tdefine SCATTERED_IO 6\t/* fcn code for multiple reads/writes */\n#\tdefine OPTIONAL_IO 16\t/* modifier to DISK_* codes within vector */\n\n#define MEM -4\t/* /dev/ram, /dev/(k)mem and /dev/null class */\n#\tdefine RAM_DEV 0\t/* minor device for /dev/ram */\n#\tdefine MEM_DEV 1\t/* minor device for /dev/mem */\n#\tdefine KMEM_DEV 2\t/* minor device for /dev/kmem */\n#\tdefine NULL_DEV 3\t/* minor device for /dev/null */\n#if (CHIP == INTEL)\n#\tdefine PORT_DEV 4\t/* minor device for /dev/port */\n#endif\n\n#define CLOCK -3\t/* clock class */\n#\tdefine SET_ALARM 1\t/* fcn code to CLOCK, set up alarm */\n#\tdefine GET_TIME\t 3\t/* fcn code to CLOCK, get real time */\n#\tdefine SET_TIME\t 4\t/* fcn code to CLOCK, set real time */\n#\tdefine REAL_TIME 1\t/* reply from CLOCK: here is real time */\n\n#define SYSTASK -2\t/* internal functions */\n#\tdefine SYS_XIT 1\t/* fcn code for sys_xit(parent, proc) */\n#\tdefine SYS_GETSP 2\t/* fcn code for sys_sp(proc, &new_sp) */\n#\tdefine SYS_SIG 3\t/* fcn code for sys_sig(proc, sig) */\n#\tdefine SYS_FORK 4\t/* fcn code for sys_fork(parent, child) */\n#\tdefine SYS_NEWMAP 5\t/* fcn code for sys_newmap(procno, map_ptr) */\n#\tdefine SYS_COPY 6\t/* fcn code for sys_copy(ptr) */\n#\tdefine SYS_EXEC 7\t/* fcn code for sys_exec(procno, new_sp) */\n#\tdefine SYS_TIMES 8\t/* fcn code for sys_times(procno, bufptr) */\n#\tdefine SYS_ABORT 9\t/* fcn code for sys_abort() */\n#\tdefine SYS_FRESH 10\t/* fcn code for sys_fresh() (Atari only) */\n#\tdefine SYS_KILL 11\t/* fcn code for sys_kill(proc, sig) */\n#\tdefine SYS_GBOOT 12\t/* fcn code for sys_gboot(procno, bootptr) */\n#\tdefine SYS_UMAP 13\t/* fcn code for sys_umap(procno, etc) */\n#\tdefine SYS_MEM 14\t/* fcn code for sys_mem() */\n#\tdefine SYS_TRACE 15\t/* fcn code for sys_trace(req,pid,addr,data) */\n\n#define HARDWARE -1\t/* used as source on interrupt generated msgs*/\n\n/* Names of message fields for messages to CLOCK task. */\n#define DELTA_TICKS m6_l1\t/* alarm interval in clock ticks */\n#define FUNC_TO_CALL m6_f1\t/* pointer to function to call */\n#define NEW_TIME m6_l1\t/* value to set clock to (SET_TIME) */\n#define CLOCK_PROC_NR m6_i1\t/* which proc (or task) wants the alarm? */\n#define SECONDS_LEFT m6_l1\t/* how many seconds were remaining */\n\n/* Names of message fields used for messages to block and character tasks. */\n#define DEVICE m2_i1\t/* major-minor device */\n#define PROC_NR m2_i2\t/* which (proc) wants I/O? */\n#define COUNT m2_i3\t/* how many bytes to transfer */\n#define POSITION m2_l1\t/* file offset */\n#define ADDRESS m2_p1\t/* core buffer address */\n\n/* Names of message fields for messages to TTY task. */\n#define TTY_LINE m2_i1\t/* message parameter: terminal line */\n#define TTY_REQUEST m2_i3\t/* message parameter: ioctl request code */\n#define TTY_SPEK m2_l1\t/* message parameter: ioctl speed, erasing */\n#define TTY_FLAGS m2_l2\t/* message parameter: ioctl tty mode */\n#define TTY_PGRP m2_i3 /* message parameter: process group */\n\n/* Names of messages fields used in reply messages from tasks. */\n#define REP_PROC_NR m2_i1\t/* # of proc on whose behalf I/O was done */\n#define REP_STATUS m2_i2\t/* bytes transferred or error number */\n\n/* Names of fields for copy message to SYSTASK. */\n#define SRC_SPACE m5_c1\t/* T or D space (stack is also D) */\n#define SRC_PROC_NR m5_i1\t/* process to copy from */\n#define SRC_BUFFER m5_l1\t/* virtual address where data come from */\n#define DST_SPACE m5_c2\t/* T or D space (stack is also D) */\n#define DST_PROC_NR m5_i2\t/* process to copy to */\n#define DST_BUFFER m5_l2\t/* virtual address where data go to */\n#define COPY_BYTES m5_l3\t/* number of bytes to copy */\n\n/* Field names for accounting, SYSTASK and miscellaneous. */\n#define USER_TIME m4_l1\t/* user time consumed by process */\n#define SYSTEM_TIME m4_l2\t/* system time consumed by process */\n#define CHILD_UTIME m4_l3\t/* user time consumed by process' children */\n#define CHILD_STIME m4_l4\t/* sys time consumed by process' children */\n\n#define PROC1 m1_i1\t/* indicates a process */\n#define PROC2 m1_i2\t/* indicates a process */\n#define PID m1_i3\t/* process id passed from MM to kernel */\n#define STACK_PTR m1_p1\t/* used for stack ptr in sys_exec, sys_getsp */\n#define PR m6_i1\t/* process number for sys_sig */\n#define SIGNUM m6_i2\t/* signal number for sys_sig */\n#define FUNC m6_f1\t/* function pointer for sys_sig */\n#define MEM_PTR m1_p1\t/* tells where memory map is for sys_newmap */\n#define CANCEL 0 /* general request to force a task to cancel */\n#define SIG_MAP m1_i2\t/* used by kernel for passing signal bit map */\n\n#ifdef AMOEBA\n\n/* Names of message fields for amoeba tasks */\n#define\tAM_OP\t\tm2_i1\t/* one of the above operators */\n#define\tAM_PROC_NR\tm2_i2\t/* process # of proc doing operation */\n#define\tAM_COUNT\tm2_i3\t/* size of buffer for operation */\n#define\tAM_ADDRESS\tm2_p1\t/* address of buffer for operation */\n\n/* For communication between MM and AMOEBA_CLASS kernel tasks */\n#define\tAM_STATUS\tm2_i3\t/* same use as REP_STATUS but for amoeba */\n#define\tAM_FREE_IT\tm2_l1\t/* 1=not a getreq, 0=is a getreq */\n\n/* Special for passing a physical address from the ethernet driver */\n#define\tAM_PADDR\tm2_l1\t/* to the transaction layer */\n\n#endif /* AMOEBA */\n\n#define HARD_INT 2\t/* fcn code for all hardware interrupts */\n", "meta": {"content_hash": "f9df1ef6dac46637021009afd24c97de", "timestamp": "", "source": "github", "line_count": 166, "max_line_length": 79, "avg_line_length": 47.506024096385545, "alnum_prop": 0.6505199086989601, "repo_name": "macminix/MacMinix", "id": "2096f8ba765448daed32f1f58c71692b6eaa5fdd", "size": "7886", "binary": false, "copies": "3", "ref": "refs/heads/master", "path": "include/minix/com.h", "mode": "33188", "license": "bsd-3-clause", "language": [{"name": "Assembly", "bytes": "360566"}, {"name": "C", "bytes": "3820041"}, {"name": "C++", "bytes": "18889"}, {"name": "IDL", "bytes": "54"}, {"name": "Smalltalk", "bytes": "3572"}]}}
{"text": "\n\n - \n \n \n \n \n
\n\n", "meta": {"content_hash": "0c5c532741b17d9555e504f006cb4d6f", "timestamp": "", "source": "github", "line_count": 9, "max_line_length": 69, "avg_line_length": 37.77777777777778, "alnum_prop": 0.6176470588235294, "repo_name": "coderwjq/ZhaZhaShop", "id": "18d9057e931dc1eec93e181d35fb48d50721ab45", "size": "340", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "shop/src/main/res/drawable/bg_tv_indicator.xml", "mode": "33188", "license": "apache-2.0", "language": [{"name": "Java", "bytes": "942134"}]}}
{"text": "\ufeff#region Mr. Advice MVVM\n// // Mr. Advice MVVM\n// // A simple MVVM package using Mr. Advice aspect weaver\n// // https://github.com/ArxOne/MrAdvice.MVVM\n// // Released under MIT license http://opensource.org/licenses/mit-license.php\n#endregion\n\nnamespace ArxOne.MrAdvice.MVVM.Properties\n{\n /// \n /// Marks a simple auto property to be bound to a DependencyProperty\n /// Note: use , this class will be deprecated soon\n /// \n public class DependencyProperty : Dependency\n {\n }\n}\n", "meta": {"content_hash": "e6f968f6bcaa02164d63a014a40698b9", "timestamp": "", "source": "github", "line_count": 17, "max_line_length": 79, "avg_line_length": 31.764705882352942, "alnum_prop": 0.6888888888888889, "repo_name": "ArxOne/MrAdvice.MVVM", "id": "44988b339a9dae3106bd24bb29f525eac790a6ff", "size": "542", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "MrAdvice.MVVM/MVVM/Properties/DependencyProperty.cs", "mode": "33188", "license": "mit", "language": [{"name": "C#", "bytes": "174074"}]}}
{"text": "package org.ringojs.util;\n\nimport org.mozilla.javascript.Context;\nimport org.mozilla.javascript.Scriptable;\nimport org.mozilla.javascript.ContextFactory;\nimport org.mozilla.javascript.debug.DebugFrame;\nimport org.mozilla.javascript.debug.DebuggableScript;\nimport org.mozilla.javascript.debug.Debugger;\n\nimport java.util.logging.Level;\nimport java.util.logging.Logger;\n\n/**\n * A base class for Debuggers and Profilers implemented in Javascript.\n * This allows to exclude the debugger/profiler module and all modules\n * it uses to be excluded from debugging/profiling.\n */\npublic abstract class DebuggerBase implements Debugger {\n\n String debuggerScript;\n int debuggerScriptDepth = 0;\n final Logger log = Logger.getLogger(DebuggerBase.class.getName());\n\n public abstract DebuggerBase createDebugger();\n\n public abstract Object createContextData();\n\n public abstract void handleCompilationDone(Context cx, DebuggableScript fnOrScript, String source);\n\n public abstract DebugFrame getScriptFrame(Context cx, DebuggableScript fnOrScript);\n\n public void attach() {\n attach(createContextData());\n }\n\n public void setDebuggerScript(String path) {\n debuggerScript = path;\n }\n\n public void install() {\n ContextFactory factory = Context.getCurrentContext().getFactory();\n factory.addListener(new ContextFactory.Listener() {\n public void contextCreated(Context cx) {\n DebuggerBase debugger = createDebugger();\n if (debugger != null) {\n debugger.attach(createContextData());\n }\n }\n public void contextReleased(Context cx) {\n }\n });\n }\n\n public void attach(Object contextData) {\n Context cx = Context.getCurrentContext();\n cx.setDebugger(this, contextData);\n cx.setOptimizationLevel(-1);\n cx.setGeneratingDebug(true);\n }\n\n public void detach() {\n Context cx = Context.getCurrentContext();\n cx.setDebugger(null, null);\n }\n\n public Object getContextData() {\n return Context.getCurrentContext().getDebuggerContextData();\n }\n\n public synchronized void suspend() {\n try {\n wait();\n } catch (InterruptedException ir) {\n Thread.currentThread().interrupt();\n }\n }\n\n public synchronized void resume() {\n notify();\n }\n\n public DebugFrame getFrame(Context cx, DebuggableScript fnOrScript) {\n String path = fnOrScript.getSourceName();\n if (log.isLoggable(Level.FINE)) {\n log.fine(\"Getting Frame for \" + path +\n \", debugger script depth is \" + debuggerScriptDepth);\n }\n if (debuggerScriptDepth > 0 || path.equals(debuggerScript)) {\n return new DebuggerScriptFrame();\n } else {\n return getScriptFrame(cx, fnOrScript);\n }\n }\n\n /**\n * Get a string representation for the given script\n * @param script a function or script\n * @return the file and/or function name of the script\n */\n static String getScriptName(DebuggableScript script) {\n if (script.isFunction()) {\n return script.getSourceName() + \": \" + script.getFunctionName();\n } else {\n return script.getSourceName();\n }\n }\n\n class DebuggerScriptFrame implements DebugFrame {\n\n public void onEnter(Context cx, Scriptable activation, Scriptable thisObj, Object[] args) {\n log.fine(\"Entering debugger script frame\");\n debuggerScriptDepth ++;\n }\n\n public void onExit(Context cx, boolean byThrow, Object resultOrException) {\n log.fine(\"Exiting debugger script frame\");\n debuggerScriptDepth --;\n }\n\n public void onLineChange(Context cx, int lineNumber) {}\n\n public void onExceptionThrown(Context cx, Throwable ex) {}\n\n public void onDebuggerStatement(Context cx) {}\n }\n\n}\n", "meta": {"content_hash": "7bc72a3b9cca751d9857aa4ea38a39f2", "timestamp": "", "source": "github", "line_count": 127, "max_line_length": 103, "avg_line_length": 31.275590551181104, "alnum_prop": 0.6467774420946626, "repo_name": "ringo/ringojs", "id": "28b86371965cce8c9e11aa1af139908c3c679f4d", "size": "3972", "binary": false, "copies": "1", "ref": "refs/heads/main", "path": "src/org/ringojs/util/DebuggerBase.java", "mode": "33188", "license": "apache-2.0", "language": [{"name": "Batchfile", "bytes": "141"}, {"name": "CSS", "bytes": "613"}, {"name": "Dockerfile", "bytes": "1007"}, {"name": "HTML", "bytes": "2026"}, {"name": "Java", "bytes": "363438"}, {"name": "JavaScript", "bytes": "913850"}, {"name": "Shell", "bytes": "2989"}]}}
{"text": "\n\n \n \n \n \n Facecat\n\n \n \n\n \n \n \n \n \n \n \n \n\n\n
\n\n\n\n % if 'error' in locals():\n
An error happend while processing your request.
\n % end\n
\n
Upload a picture It's more fun if it's the picture of someone.
\n\n
\n\n
\n\n\n
\n\n \n \n \n\n\n \n\n\n", "meta": {"content_hash": "0ff5431891cb2864bd51ef0adfd0e451", "timestamp": "", "source": "github", "line_count": 110, "max_line_length": 129, "avg_line_length": 36.68181818181818, "alnum_prop": 0.5241635687732342, "repo_name": "NicolasLM/python-runabove", "id": "c289353c9893e03aa4228b58f31f19256ca86a72", "size": "4035", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "examples/facecat/views/index.html", "mode": "33188", "license": "mit", "language": []}}
{"text": "\ufeffnamespace AH.ModuleController.UI.DIET.Forms\n{\n partial class frmPatientListDietAssign\n {\n /// \n /// Required designer variable.\n /// \n private System.ComponentModel.IContainer components = null;\n\n /// \n /// Clean up any resources being used.\n /// \n /// true if managed resources should be disposed; otherwise, false.\n protected override void Dispose(bool disposing)\n {\n if (disposing && (components != null))\n {\n components.Dispose();\n }\n base.Dispose(disposing);\n }\n\n #region Windows Form Designer generated code\n\n /// \n /// Required method for Designer support - do not modify\n /// the contents of this method with the code editor.\n /// \n private void InitializeComponent()\n {\n System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();\n System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();\n System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();\n System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();\n System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle();\n System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle();\n this.groupBox4 = new System.Windows.Forms.GroupBox();\n this.btnShow = new System.Windows.Forms.Button();\n this.smartLabel4 = new AtiqsControlLibrary.SmartLabel();\n this.cboReceivingNurseStation = new AtiqsControlLibrary.SmartComboBox();\n this.dgvDietList = new AtiqsControlLibrary.SmartDataGridView();\n this.dgvPatientList = new AtiqsControlLibrary.SmartDataGridView();\n this.txtAdmissionID = new System.Windows.Forms.TextBox();\n this.txtDeitID = new System.Windows.Forms.TextBox();\n this.pnlMain.SuspendLayout();\n this.pnlTop.SuspendLayout();\n this.groupBox4.SuspendLayout();\n ((System.ComponentModel.ISupportInitialize)(this.dgvDietList)).BeginInit();\n ((System.ComponentModel.ISupportInitialize)(this.dgvPatientList)).BeginInit();\n this.SuspendLayout();\n // \n // btnTopClose\n // \n this.btnTopClose.Location = new System.Drawing.Point(1128, 12);\n // \n // frmLabel\n // \n this.frmLabel.Location = new System.Drawing.Point(393, 9);\n this.frmLabel.Size = new System.Drawing.Size(406, 33);\n this.frmLabel.Text = \"Assign Diet For Admitted Patient \";\n // \n // pnlMain\n // \n this.pnlMain.Controls.Add(this.dgvDietList);\n this.pnlMain.Controls.Add(this.groupBox4);\n this.pnlMain.Controls.Add(this.dgvPatientList);\n this.pnlMain.Location = new System.Drawing.Point(0, 58);\n this.pnlMain.Size = new System.Drawing.Size(1260, 606);\n // \n // pnlTop\n // \n this.pnlTop.Controls.Add(this.txtDeitID);\n this.pnlTop.Controls.Add(this.txtAdmissionID);\n this.pnlTop.Size = new System.Drawing.Size(1260, 58);\n this.pnlTop.Controls.SetChildIndex(this.frmLabel, 0);\n this.pnlTop.Controls.SetChildIndex(this.btnTopClose, 0);\n this.pnlTop.Controls.SetChildIndex(this.txtAdmissionID, 0);\n this.pnlTop.Controls.SetChildIndex(this.txtDeitID, 0);\n // \n // btnEdit\n // \n this.btnEdit.Location = new System.Drawing.Point(110, 673);\n this.btnEdit.Size = new System.Drawing.Size(19, 27);\n this.btnEdit.Visible = false;\n // \n // btnSave\n // \n this.btnSave.Location = new System.Drawing.Point(135, 681);\n this.btnSave.Size = new System.Drawing.Size(33, 17);\n this.btnSave.Visible = false;\n // \n // btnDelete\n // \n this.btnDelete.Location = new System.Drawing.Point(50, 673);\n this.btnDelete.Size = new System.Drawing.Size(21, 27);\n this.btnDelete.Visible = false;\n // \n // btnNew\n // \n this.btnNew.Location = new System.Drawing.Point(1026, 670);\n this.btnNew.Click += new System.EventHandler(this.btnNew_Click);\n // \n // btnClose\n // \n this.btnClose.Location = new System.Drawing.Point(1140, 670);\n this.btnClose.TabIndex = 3;\n // \n // btnPrint\n // \n this.btnPrint.Location = new System.Drawing.Point(77, 673);\n this.btnPrint.Size = new System.Drawing.Size(27, 27);\n this.btnPrint.Visible = false;\n // \n // groupBox1\n // \n this.groupBox1.Location = new System.Drawing.Point(0, 709);\n this.groupBox1.Size = new System.Drawing.Size(1260, 25);\n // \n // groupBox4\n // \n this.groupBox4.BackColor = System.Drawing.Color.PaleTurquoise;\n this.groupBox4.Controls.Add(this.btnShow);\n this.groupBox4.Controls.Add(this.smartLabel4);\n this.groupBox4.Controls.Add(this.cboReceivingNurseStation);\n this.groupBox4.Font = new System.Drawing.Font(\"Microsoft Sans Serif\", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\n this.groupBox4.ForeColor = System.Drawing.Color.DarkBlue;\n this.groupBox4.Location = new System.Drawing.Point(3, 2);\n this.groupBox4.Name = \"groupBox4\";\n this.groupBox4.Size = new System.Drawing.Size(1256, 104);\n this.groupBox4.TabIndex = 5;\n this.groupBox4.TabStop = false;\n this.groupBox4.MouseHover += new System.EventHandler(this.groupBox4_MouseHover);\n // \n // btnShow\n // \n this.btnShow.BackColor = System.Drawing.Color.DarkSalmon;\n this.btnShow.Location = new System.Drawing.Point(540, 40);\n this.btnShow.Name = \"btnShow\";\n this.btnShow.Size = new System.Drawing.Size(238, 30);\n this.btnShow.TabIndex = 158;\n this.btnShow.Text = \"Click Patient List to Add Diet\";\n this.btnShow.UseVisualStyleBackColor = false;\n this.btnShow.Click += new System.EventHandler(this.btnShow_Click);\n // \n // smartLabel4\n // \n this.smartLabel4.AutoSize = true;\n this.smartLabel4.BackColor = System.Drawing.Color.PaleTurquoise;\n this.smartLabel4.Font = new System.Drawing.Font(\"Times New Roman\", 9.75F, System.Drawing.FontStyle.Bold);\n this.smartLabel4.Location = new System.Drawing.Point(42, 46);\n this.smartLabel4.Name = \"smartLabel4\";\n this.smartLabel4.Size = new System.Drawing.Size(120, 15);\n this.smartLabel4.TabIndex = 157;\n this.smartLabel4.Text = \"Select Nurse Station\";\n // \n // cboReceivingNurseStation\n // \n this.cboReceivingNurseStation.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;\n this.cboReceivingNurseStation.Font = new System.Drawing.Font(\"Microsoft Sans Serif\", 11F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\n this.cboReceivingNurseStation.ForeColor = System.Drawing.Color.Blue;\n this.cboReceivingNurseStation.FormattingEnabled = true;\n this.cboReceivingNurseStation.Items.AddRange(new object[] {\n \"1\",\n \"2\"});\n this.cboReceivingNurseStation.Location = new System.Drawing.Point(168, 43);\n this.cboReceivingNurseStation.Name = \"cboReceivingNurseStation\";\n this.cboReceivingNurseStation.Size = new System.Drawing.Size(356, 26);\n this.cboReceivingNurseStation.TabIndex = 156;\n // \n // dgvDietList\n // \n this.dgvDietList.AllowUserToAddRows = false;\n this.dgvDietList.AllowUserToDeleteRows = false;\n this.dgvDietList.AllowUserToOrderColumns = true;\n this.dgvDietList.AllowUserToResizeColumns = false;\n this.dgvDietList.AllowUserToResizeRows = false;\n this.dgvDietList.BackgroundColor = System.Drawing.Color.White;\n this.dgvDietList.ColumnHeadersBorderStyle = System.Windows.Forms.DataGridViewHeaderBorderStyle.Single;\n dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;\n dataGridViewCellStyle1.BackColor = System.Drawing.Color.LightGreen;\n dataGridViewCellStyle1.Font = new System.Drawing.Font(\"Tahoma\", 8F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\n dataGridViewCellStyle1.ForeColor = System.Drawing.Color.Black;\n dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText;\n this.dgvDietList.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1;\n this.dgvDietList.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;\n dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;\n dataGridViewCellStyle2.BackColor = System.Drawing.Color.White;\n dataGridViewCellStyle2.Font = new System.Drawing.Font(\"Tahoma\", 8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\n dataGridViewCellStyle2.ForeColor = System.Drawing.Color.Black;\n dataGridViewCellStyle2.SelectionBackColor = System.Drawing.Color.Lavender;\n dataGridViewCellStyle2.SelectionForeColor = System.Drawing.Color.Crimson;\n dataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.False;\n this.dgvDietList.DefaultCellStyle = dataGridViewCellStyle2;\n this.dgvDietList.Location = new System.Drawing.Point(865, 75);\n this.dgvDietList.MultiSelect = false;\n this.dgvDietList.Name = \"dgvDietList\";\n this.dgvDietList.RowHeadersVisible = false;\n dataGridViewCellStyle3.BackColor = System.Drawing.Color.White;\n this.dgvDietList.RowsDefaultCellStyle = dataGridViewCellStyle3;\n this.dgvDietList.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;\n this.dgvDietList.Size = new System.Drawing.Size(272, 395);\n this.dgvDietList.TabIndex = 159;\n this.dgvDietList.CellMouseDoubleClick += new System.Windows.Forms.DataGridViewCellMouseEventHandler(this.dgvDietList_CellMouseDoubleClick);\n // \n // dgvPatientList\n // \n this.dgvPatientList.AllowUserToAddRows = false;\n this.dgvPatientList.AllowUserToDeleteRows = false;\n this.dgvPatientList.AllowUserToOrderColumns = true;\n this.dgvPatientList.AllowUserToResizeColumns = false;\n this.dgvPatientList.AllowUserToResizeRows = false;\n this.dgvPatientList.BackgroundColor = System.Drawing.Color.White;\n this.dgvPatientList.ColumnHeadersBorderStyle = System.Windows.Forms.DataGridViewHeaderBorderStyle.Single;\n dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;\n dataGridViewCellStyle4.BackColor = System.Drawing.Color.LightGreen;\n dataGridViewCellStyle4.Font = new System.Drawing.Font(\"Tahoma\", 8F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\n dataGridViewCellStyle4.ForeColor = System.Drawing.Color.Black;\n dataGridViewCellStyle4.SelectionForeColor = System.Drawing.SystemColors.HighlightText;\n this.dgvPatientList.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle4;\n this.dgvPatientList.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;\n dataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;\n dataGridViewCellStyle5.BackColor = System.Drawing.Color.White;\n dataGridViewCellStyle5.Font = new System.Drawing.Font(\"Tahoma\", 8F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));\n dataGridViewCellStyle5.ForeColor = System.Drawing.Color.Black;\n dataGridViewCellStyle5.SelectionBackColor = System.Drawing.Color.Lavender;\n dataGridViewCellStyle5.SelectionForeColor = System.Drawing.Color.Crimson;\n dataGridViewCellStyle5.WrapMode = System.Windows.Forms.DataGridViewTriState.False;\n this.dgvPatientList.DefaultCellStyle = dataGridViewCellStyle5;\n this.dgvPatientList.Location = new System.Drawing.Point(2, 106);\n this.dgvPatientList.MultiSelect = false;\n this.dgvPatientList.Name = \"dgvPatientList\";\n this.dgvPatientList.RowHeadersVisible = false;\n dataGridViewCellStyle6.BackColor = System.Drawing.Color.White;\n this.dgvPatientList.RowsDefaultCellStyle = dataGridViewCellStyle6;\n this.dgvPatientList.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;\n this.dgvPatientList.Size = new System.Drawing.Size(1253, 497);\n this.dgvPatientList.TabIndex = 6;\n this.dgvPatientList.CellClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvPatientList_CellClick);\n // \n // txtAdmissionID\n // \n this.txtAdmissionID.Location = new System.Drawing.Point(916, 9);\n this.txtAdmissionID.Name = \"txtAdmissionID\";\n this.txtAdmissionID.Size = new System.Drawing.Size(100, 20);\n this.txtAdmissionID.TabIndex = 161;\n this.txtAdmissionID.Visible = false;\n // \n // txtDeitID\n // \n this.txtDeitID.Location = new System.Drawing.Point(1022, 7);\n this.txtDeitID.Name = \"txtDeitID\";\n this.txtDeitID.Size = new System.Drawing.Size(100, 20);\n this.txtDeitID.TabIndex = 162;\n this.txtDeitID.Visible = false;\n // \n // frmPatientListDietAssign\n // \n this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);\n this.ClientSize = new System.Drawing.Size(1260, 734);\n this.isEnterTabAllow = true;\n this.Name = \"frmPatientListDietAssign\";\n this.Load += new System.EventHandler(this.frmPatientList_Load);\n this.pnlMain.ResumeLayout(false);\n this.pnlTop.ResumeLayout(false);\n this.pnlTop.PerformLayout();\n this.groupBox4.ResumeLayout(false);\n this.groupBox4.PerformLayout();\n ((System.ComponentModel.ISupportInitialize)(this.dgvDietList)).EndInit();\n ((System.ComponentModel.ISupportInitialize)(this.dgvPatientList)).EndInit();\n this.ResumeLayout(false);\n\n }\n\n #endregion\n\n private System.Windows.Forms.GroupBox groupBox4;\n private AtiqsControlLibrary.SmartDataGridView dgvPatientList;\n private AtiqsControlLibrary.SmartLabel smartLabel4;\n private AtiqsControlLibrary.SmartComboBox cboReceivingNurseStation;\n private System.Windows.Forms.Button btnShow;\n public System.Windows.Forms.TextBox txtAdmissionID;\n public System.Windows.Forms.TextBox txtDeitID;\n private AtiqsControlLibrary.SmartDataGridView dgvDietList;\n\n }\n}\n", "meta": {"content_hash": "7577a20e44e72cb7e2da2aed635be20c", "timestamp": "", "source": "github", "line_count": 286, "max_line_length": 184, "avg_line_length": 56.45454545454545, "alnum_prop": 0.6495726495726496, "repo_name": "atiq-shumon/DotNetProjects", "id": "63424a60f594df942497663d5c4bfb6bbaeb0f9a", "size": "16148", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "Hospital_ERP_VS13-WCF_WF/AH.ModuleController/UI/DIET/Forms/frmPatientListDietAssign.Designer.cs", "mode": "33188", "license": "apache-2.0", "language": [{"name": "ASP", "bytes": "1059021"}, {"name": "C#", "bytes": "39389238"}, {"name": "CSS", "bytes": "683218"}, {"name": "HTML", "bytes": "44772"}, {"name": "JavaScript", "bytes": "1343054"}, {"name": "PLpgSQL", "bytes": "340074"}, {"name": "Pascal", "bytes": "81971"}, {"name": "PowerShell", "bytes": "175142"}, {"name": "Puppet", "bytes": "2111"}, {"name": "Smalltalk", "bytes": "9"}, {"name": "XSLT", "bytes": "12347"}]}}
{"text": "\npackage org.medipi.clinical.dao;\n\nimport java.util.List;\nimport org.medipi.clinical.entities.PatientGroup;\nimport org.springframework.stereotype.Repository;\n\n/**\n * Implementation of Data Access Object for Patient\n * @author rick@robinsonhq.com\n */\n@Repository\npublic class PatientGroupDAOImpl extends GenericDAOImpl implements PatientGroupDAO {\n @Override\n public List getAllGroups() {\n return this.getEntityManager().createNamedQuery(\"PatientGroup.findAll\", PatientGroup.class)\n .getResultList();\n }\n}", "meta": {"content_hash": "3bf94388278a7d76abcb340256e75471", "timestamp": "", "source": "github", "line_count": 19, "max_line_length": 99, "avg_line_length": 29.63157894736842, "alnum_prop": 0.7602131438721137, "repo_name": "Samuel789/MediPi", "id": "33522f5a6540bd8fb6f89dd443207ac049bb383a", "size": "1167", "binary": false, "copies": "2", "ref": "refs/heads/master", "path": "Clinician/MediPiClinical/src/main/java/org/medipi/clinical/dao/PatientGroupDAOImpl.java", "mode": "33188", "license": "apache-2.0", "language": [{"name": "Batchfile", "bytes": "10012"}, {"name": "CSS", "bytes": "847678"}, {"name": "HTML", "bytes": "4238145"}, {"name": "Java", "bytes": "1942198"}, {"name": "JavaScript", "bytes": "2308166"}, {"name": "PHP", "bytes": "1684"}, {"name": "Python", "bytes": "66091"}, {"name": "Ruby", "bytes": "1183"}, {"name": "Shell", "bytes": "17053"}]}}
{"text": "package enums;\n\npublic enum GameStatusType {\n\tGAME_WAITING,\n\tGAME_READY,\n\tGAME_PAUSE,\n\tGAME_RUNNING,\n\tGAME_END\n}\n", "meta": {"content_hash": "f493082fa8f2d360462e63e43976d837", "timestamp": "", "source": "github", "line_count": 9, "max_line_length": 28, "avg_line_length": 12.555555555555555, "alnum_prop": 0.7345132743362832, "repo_name": "ptutak/Warcaby", "id": "b49884d68c81fb001a43a5b878b7d5aac2c17e36", "size": "701", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "src/enums/GameStatusType.java", "mode": "33188", "license": "apache-2.0", "language": [{"name": "Java", "bytes": "103900"}]}}
{"text": "package com.taotao.model;\n\nimport java.util.Date;\n\n/**\n * TITLE:\u5e7f\u544a\u7684model\n * USER:TAOTK\n * DATA:2016/9/14\n * TIME:10:48\n * COMPANY:www.51pjia.com\n */\npublic class PjPoster {\n\n private Integer id; //int(11) NOT NULL,\n private Integer category_id;// int(11) DEFAULT NULL,\n private String category_name; //varchar(32) DEFAULT NULL,\n private Integer poster_sort; //int(11) DEFAULT NULL,\n private String poster_url; //varchar(50) DEFAULT NULL,\n private String poster_size; //varchar(32) DEFAULT NULL,\n private Date create_time;//datetime DEFAULT NULL,\n private Integer poster_status; //int(11) DEFAULT NULL,\n private Integer poster_address;\n private String categoryName;\n private String poster_small_url;//\u5c0f\u56fe\u7247\n\n public String getPoster_small_url() {\n return poster_small_url;\n }\n public void setPoster_small_url(String poster_small_url) {\n this.poster_small_url = poster_small_url;\n }\n public String getCategoryName() {\n return categoryName;\n }\n\n public void setCategoryName(String categoryName) {\n this.categoryName = categoryName;\n }\n\n public Integer getPoster_address() {\n return poster_address;\n }\n\n public void setPoster_address(Integer poster_address) {\n this.poster_address = poster_address;\n }\n\n public Integer getId() {\n return id;\n }\n\n public void setId(Integer id) {\n this.id = id;\n }\n\n public Integer getCategory_id() {\n return category_id;\n }\n\n public void setCategory_id(Integer category_id) {\n this.category_id = category_id;\n }\n\n public String getCategory_name() {\n return category_name;\n }\n\n public void setCategory_name(String category_name) {\n this.category_name = category_name;\n }\n\n public Integer getPoster_sort() {\n return poster_sort;\n }\n\n public void setPoster_sort(Integer poster_sort) {\n this.poster_sort = poster_sort;\n }\n\n public String getPoster_url() {\n return poster_url;\n }\n\n public void setPoster_url(String poster_url) {\n this.poster_url = poster_url;\n }\n\n public String getPoster_size() {\n return poster_size;\n }\n\n public void setPoster_size(String poster_size) {\n this.poster_size = poster_size;\n }\n\n public Date getCreate_time() {\n return create_time;\n }\n\n public void setCreate_time(Date create_time) {\n this.create_time = create_time;\n }\n\n public Integer getPoster_status() {\n return poster_status;\n }\n\n public void setPoster_status(Integer poster_status) {\n this.poster_status = poster_status;\n }\n\n\n @Override\n public String toString() {\n return \"PjPoster{\" +\n \"id=\" + id +\n \", category_id=\" + category_id +\n \", category_name='\" + category_name + '\\'' +\n \", poster_sort=\" + poster_sort +\n \", poster_url='\" + poster_url + '\\'' +\n \", poster_size='\" + poster_size + '\\'' +\n \", create_time=\" + create_time +\n \", poster_status=\" + poster_status +\n \", poster_address=\" + poster_address +\n \", categoryName='\" + categoryName + '\\'' +\n \", poster_small_url='\" + poster_small_url + '\\'' +\n '}';\n }\n}\n", "meta": {"content_hash": "7ab49f595d4875b5c338cb3b1ae66c93", "timestamp": "", "source": "github", "line_count": 129, "max_line_length": 66, "avg_line_length": 25.88372093023256, "alnum_prop": 0.5882000598981731, "repo_name": "17755332301/Tao-", "id": "c90f72f6b45864fc59a103913265bc15df0b29bc", "size": "3351", "binary": false, "copies": "1", "ref": "refs/heads/master", "path": "taotao-web/src/main/java/com/taotao/model/PjPoster.java", "mode": "33188", "license": "apache-2.0", "language": [{"name": "ASP", "bytes": "31784"}, {"name": "C#", "bytes": "16030"}, {"name": "CSS", "bytes": "625671"}, {"name": "HTML", "bytes": "558187"}, {"name": "Java", "bytes": "280551"}, {"name": "JavaScript", "bytes": "4548934"}, {"name": "PHP", "bytes": "32951"}]}}