identifier
stringlengths
42
383
collection
stringclasses
1 value
open_type
stringclasses
1 value
license
stringlengths
0
1.81k
date
float64
1.99k
2.02k
title
stringlengths
0
100
creator
stringlengths
1
39
language
stringclasses
157 values
language_type
stringclasses
2 values
word_count
int64
1
20k
token_count
int64
4
1.32M
text
stringlengths
5
1.53M
__index_level_0__
int64
0
57.5k
https://github.com/MAPC/dpw-permits/blob/master/app/serializers/plan_serializer.rb
Github Open Source
Open Source
MIT
2,018
dpw-permits
MAPC
Ruby
Code
18
58
class PlanSerializer < ActiveModel::Serializer attributes :id, :name, :plan_type, :city, :published, :color, :timeframes, :user_id has_many :timeframes belongs_to :user end
43,632
https://github.com/Pseudo-Lab/Motion-of-Action/blob/master/tabnet/configs/random_search.py
Github Open Source
Open Source
MIT
2,021
Motion-of-Action
Pseudo-Lab
Python
Code
240
787
import os import json from typing import Dict from pprint import pprint import numpy as np import pandas as pd from configs.tabnet import config class SearchOption: def __init__(self, opt, type_): type_ = type_.lower() assert pd.api.types.is_list_like(opt) assert type_ in ["choice", "range"] self._opt = np.array(opt) self._type = type_ if self._type == "range": assert len(self._opt) == 2 assert self._opt[0] < self._opt[1] @property def opt(self): return self._opt @property def type(self): return self._type class RandomParams: def __init__(self): self._range_dict = {} self._counter = 0 def __call__(self, conf, make_d_a_same=True): for k, search_range in self._range_dict.items(): if k in ['name', 'seed', 'device', 'data_dir', 'log_dir', 'bkup_dir', 'sub_dir']: continue # check unknown keys if not hasattr(conf, k): raise AttributeError(f"type {type(conf)} does not have attribute {k}.") if search_range.type == "choice": new_value = np.random.choice(search_range.opt) elif search_range.type == "range": min_, max_ = search_range.opt new_value = np.random.random() # 0 ~ 1 new_value = new_value * (max_ - min_) + min_ else: raise NotImplementedError if isinstance(new_value, np.integer): new_value = int(new_value) # inplace setattr(conf, k, new_value) if make_d_a_same: # n_a <- n_d setattr(conf, 'n_a', getattr(conf, 'n_d')) self.save_config(conf) self._counter += 1 def save_config(self, conf: config): d = {k: getattr(conf, k) for k in dir(conf) if not k.startswith('__')} filename = f"selected_params_{self._counter:02d}.json" save_path = os.path.join(conf.log_dir, filename) with open(save_path, 'w') as fp: json.dump(d, fp) # check with open(save_path, 'r') as fp: pprint(json.load(fp)) def set(self, param_name, opt, type_): self._range_dict[param_name] = SearchOption(opt, type_) if __name__ == "__main__": rp = RandomParams() rp.set("n_d", [8, 16, 32], 'choice') c = config() for _ in range(3): rp(c)
5,209
https://github.com/jv232/Study-Buddy/blob/master/app/build/generated/not_namespaced_r_class_sources/debug/processDebugResources/r/com/intekhab/studybuddy/R.java
Github Open Source
Open Source
MIT
null
Study-Buddy
jv232
Java
Code
20,000
66,233
/* AUTO-GENERATED FILE. DO NOT MODIFY. * * This class was automatically generated by the * aapt tool from the resource data it found. It * should not be modified by hand. */ package com.intekhab.studybuddy; public final class R { public static final class anim { public static final int abc_fade_in=0x7f010000; public static final int abc_fade_out=0x7f010001; public static final int abc_grow_fade_in_from_bottom=0x7f010002; public static final int abc_popup_enter=0x7f010003; public static final int abc_popup_exit=0x7f010004; public static final int abc_shrink_fade_out_from_bottom=0x7f010005; public static final int abc_slide_in_bottom=0x7f010006; public static final int abc_slide_in_top=0x7f010007; public static final int abc_slide_out_bottom=0x7f010008; public static final int abc_slide_out_top=0x7f010009; public static final int design_bottom_sheet_slide_in=0x7f01000a; public static final int design_bottom_sheet_slide_out=0x7f01000b; public static final int design_snackbar_in=0x7f01000c; public static final int design_snackbar_out=0x7f01000d; public static final int tooltip_enter=0x7f01000e; public static final int tooltip_exit=0x7f01000f; } public static final class animator { public static final int design_appbar_state_list_animator=0x7f020000; } public static final class attr { /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int SwipeFlingStyle=0x7f030000; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionBarDivider=0x7f030001; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionBarItemBackground=0x7f030002; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionBarPopupTheme=0x7f030003; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>wrap_content</td><td>0</td><td></td></tr> * </table> */ public static final int actionBarSize=0x7f030004; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionBarSplitStyle=0x7f030005; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionBarStyle=0x7f030006; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionBarTabBarStyle=0x7f030007; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionBarTabStyle=0x7f030008; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionBarTabTextStyle=0x7f030009; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionBarTheme=0x7f03000a; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionBarWidgetTheme=0x7f03000b; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionButtonStyle=0x7f03000c; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionDropDownStyle=0x7f03000d; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionLayout=0x7f03000e; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionMenuTextAppearance=0x7f03000f; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int actionMenuTextColor=0x7f030010; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModeBackground=0x7f030011; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModeCloseButtonStyle=0x7f030012; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModeCloseDrawable=0x7f030013; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModeCopyDrawable=0x7f030014; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModeCutDrawable=0x7f030015; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModeFindDrawable=0x7f030016; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModePasteDrawable=0x7f030017; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModePopupWindowStyle=0x7f030018; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModeSelectAllDrawable=0x7f030019; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModeShareDrawable=0x7f03001a; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModeSplitBackground=0x7f03001b; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModeStyle=0x7f03001c; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionModeWebSearchDrawable=0x7f03001d; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionOverflowButtonStyle=0x7f03001e; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int actionOverflowMenuStyle=0x7f03001f; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int actionProviderClass=0x7f030020; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int actionViewClass=0x7f030021; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int activityChooserViewStyle=0x7f030022; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int alertDialogButtonGroupStyle=0x7f030023; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int alertDialogCenterButtons=0x7f030024; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int alertDialogStyle=0x7f030025; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int alertDialogTheme=0x7f030026; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int allowStacking=0x7f030027; /** * <p>May be a floating point value, such as "<code>1.2</code>". */ public static final int alpha=0x7f030028; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>ALT</td><td>2</td><td></td></tr> * <tr><td>CTRL</td><td>1000</td><td></td></tr> * <tr><td>FUNCTION</td><td>8</td><td></td></tr> * <tr><td>META</td><td>10000</td><td></td></tr> * <tr><td>SHIFT</td><td>1</td><td></td></tr> * <tr><td>SYM</td><td>4</td><td></td></tr> * </table> */ public static final int alphabeticModifiers=0x7f030029; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int arrowHeadLength=0x7f03002a; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int arrowShaftLength=0x7f03002b; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int autoCompleteTextViewStyle=0x7f03002c; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int autoSizeMaxTextSize=0x7f03002d; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int autoSizeMinTextSize=0x7f03002e; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int autoSizePresetSizes=0x7f03002f; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int autoSizeStepGranularity=0x7f030030; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>none</td><td>0</td><td></td></tr> * <tr><td>uniform</td><td>1</td><td></td></tr> * </table> */ public static final int autoSizeTextType=0x7f030031; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int background=0x7f030032; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int backgroundSplit=0x7f030033; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int backgroundStacked=0x7f030034; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int backgroundTint=0x7f030035; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>multiply</td><td>e</td><td></td></tr> * <tr><td>screen</td><td>f</td><td></td></tr> * <tr><td>src_atop</td><td>9</td><td></td></tr> * <tr><td>src_in</td><td>5</td><td></td></tr> * <tr><td>src_over</td><td>3</td><td></td></tr> * </table> */ public static final int backgroundTintMode=0x7f030036; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int barLength=0x7f030037; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int behavior_autoHide=0x7f030038; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int behavior_hideable=0x7f030039; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int behavior_overlapTop=0x7f03003a; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>auto</td><td>ffffffff</td><td></td></tr> * </table> */ public static final int behavior_peekHeight=0x7f03003b; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int behavior_skipCollapsed=0x7f03003c; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int borderWidth=0x7f03003d; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int borderlessButtonStyle=0x7f03003e; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int bottomSheetDialogTheme=0x7f03003f; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int bottomSheetStyle=0x7f030040; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int buttonBarButtonStyle=0x7f030041; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int buttonBarNegativeButtonStyle=0x7f030042; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int buttonBarNeutralButtonStyle=0x7f030043; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int buttonBarPositiveButtonStyle=0x7f030044; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int buttonBarStyle=0x7f030045; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>bottom</td><td>50</td><td></td></tr> * <tr><td>top</td><td>30</td><td></td></tr> * </table> */ public static final int buttonGravity=0x7f030046; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int buttonPanelSideLayout=0x7f030047; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>icon_only</td><td>2</td><td></td></tr> * <tr><td>standard</td><td>0</td><td></td></tr> * <tr><td>wide</td><td>1</td><td></td></tr> * </table> */ public static final int buttonSize=0x7f030048; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int buttonStyle=0x7f030049; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int buttonStyleSmall=0x7f03004a; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int buttonTint=0x7f03004b; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>multiply</td><td>e</td><td></td></tr> * <tr><td>screen</td><td>f</td><td></td></tr> * <tr><td>src_atop</td><td>9</td><td></td></tr> * <tr><td>src_in</td><td>5</td><td></td></tr> * <tr><td>src_over</td><td>3</td><td></td></tr> * </table> */ public static final int buttonTintMode=0x7f03004c; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int cardBackgroundColor=0x7f03004d; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int cardCornerRadius=0x7f03004e; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int cardElevation=0x7f03004f; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int cardMaxElevation=0x7f030050; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int cardPreventCornerOverlap=0x7f030051; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int cardUseCompatPadding=0x7f030052; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int checkboxStyle=0x7f030053; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int checkedTextViewStyle=0x7f030054; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int circleCrop=0x7f030055; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int closeIcon=0x7f030056; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int closeItemLayout=0x7f030057; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int collapseContentDescription=0x7f030058; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int collapseIcon=0x7f030059; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>bottom</td><td>50</td><td></td></tr> * <tr><td>center</td><td>11</td><td></td></tr> * <tr><td>center_horizontal</td><td>1</td><td></td></tr> * <tr><td>center_vertical</td><td>10</td><td></td></tr> * <tr><td>end</td><td>800005</td><td></td></tr> * <tr><td>fill_vertical</td><td>70</td><td></td></tr> * <tr><td>left</td><td>3</td><td></td></tr> * <tr><td>right</td><td>5</td><td></td></tr> * <tr><td>start</td><td>800003</td><td></td></tr> * <tr><td>top</td><td>30</td><td></td></tr> * </table> */ public static final int collapsedTitleGravity=0x7f03005a; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int collapsedTitleTextAppearance=0x7f03005b; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int color=0x7f03005c; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int colorAccent=0x7f03005d; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int colorBackgroundFloating=0x7f03005e; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int colorButtonNormal=0x7f03005f; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int colorControlActivated=0x7f030060; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int colorControlHighlight=0x7f030061; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int colorControlNormal=0x7f030062; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int colorError=0x7f030063; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int colorPrimary=0x7f030064; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int colorPrimaryDark=0x7f030065; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>auto</td><td>2</td><td></td></tr> * <tr><td>dark</td><td>0</td><td></td></tr> * <tr><td>light</td><td>1</td><td></td></tr> * </table> */ public static final int colorScheme=0x7f030066; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int colorSwitchThumbNormal=0x7f030067; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int commitIcon=0x7f030068; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int constraintSet=0x7f030069; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int contentDescription=0x7f03006a; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int contentInsetEnd=0x7f03006b; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int contentInsetEndWithActions=0x7f03006c; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int contentInsetLeft=0x7f03006d; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int contentInsetRight=0x7f03006e; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int contentInsetStart=0x7f03006f; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int contentInsetStartWithNavigation=0x7f030070; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int contentPadding=0x7f030071; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int contentPaddingBottom=0x7f030072; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int contentPaddingLeft=0x7f030073; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int contentPaddingRight=0x7f030074; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int contentPaddingTop=0x7f030075; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int contentScrim=0x7f030076; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int controlBackground=0x7f030077; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int counterEnabled=0x7f030078; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int counterMaxLength=0x7f030079; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int counterOverflowTextAppearance=0x7f03007a; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int counterTextAppearance=0x7f03007b; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int customNavigationLayout=0x7f03007c; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int defaultQueryHint=0x7f03007d; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int dialogPreferredPadding=0x7f03007e; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int dialogTheme=0x7f03007f; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>disableHome</td><td>20</td><td></td></tr> * <tr><td>homeAsUp</td><td>4</td><td></td></tr> * <tr><td>none</td><td>0</td><td></td></tr> * <tr><td>showCustom</td><td>10</td><td></td></tr> * <tr><td>showHome</td><td>2</td><td></td></tr> * <tr><td>showTitle</td><td>8</td><td></td></tr> * <tr><td>useLogo</td><td>1</td><td></td></tr> * </table> */ public static final int displayOptions=0x7f030080; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int divider=0x7f030081; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int dividerHorizontal=0x7f030082; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int dividerPadding=0x7f030083; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int dividerVertical=0x7f030084; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int drawableSize=0x7f030085; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int drawerArrowStyle=0x7f030086; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int dropDownListViewStyle=0x7f030087; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int dropdownListPreferredItemHeight=0x7f030088; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int editTextBackground=0x7f030089; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int editTextColor=0x7f03008a; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int editTextStyle=0x7f03008b; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int elevation=0x7f03008c; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int errorEnabled=0x7f03008d; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int errorTextAppearance=0x7f03008e; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int expandActivityOverflowButtonDrawable=0x7f03008f; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int expanded=0x7f030090; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>bottom</td><td>50</td><td></td></tr> * <tr><td>center</td><td>11</td><td></td></tr> * <tr><td>center_horizontal</td><td>1</td><td></td></tr> * <tr><td>center_vertical</td><td>10</td><td></td></tr> * <tr><td>end</td><td>800005</td><td></td></tr> * <tr><td>fill_vertical</td><td>70</td><td></td></tr> * <tr><td>left</td><td>3</td><td></td></tr> * <tr><td>right</td><td>5</td><td></td></tr> * <tr><td>start</td><td>800003</td><td></td></tr> * <tr><td>top</td><td>30</td><td></td></tr> * </table> */ public static final int expandedTitleGravity=0x7f030091; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int expandedTitleMargin=0x7f030092; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int expandedTitleMarginBottom=0x7f030093; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int expandedTitleMarginEnd=0x7f030094; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int expandedTitleMarginStart=0x7f030095; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int expandedTitleMarginTop=0x7f030096; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int expandedTitleTextAppearance=0x7f030097; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>auto</td><td>ffffffff</td><td></td></tr> * <tr><td>mini</td><td>1</td><td></td></tr> * <tr><td>normal</td><td>0</td><td></td></tr> * </table> */ public static final int fabSize=0x7f030098; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int fastScrollEnabled=0x7f030099; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int fastScrollHorizontalThumbDrawable=0x7f03009a; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int fastScrollHorizontalTrackDrawable=0x7f03009b; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int fastScrollVerticalThumbDrawable=0x7f03009c; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int fastScrollVerticalTrackDrawable=0x7f03009d; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int font=0x7f03009e; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int fontFamily=0x7f03009f; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int fontProviderAuthority=0x7f0300a0; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int fontProviderCerts=0x7f0300a1; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>async</td><td>1</td><td></td></tr> * <tr><td>blocking</td><td>0</td><td></td></tr> * </table> */ public static final int fontProviderFetchStrategy=0x7f0300a2; /** * <p>May be an integer value, such as "<code>100</code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>forever</td><td>ffffffff</td><td></td></tr> * </table> */ public static final int fontProviderFetchTimeout=0x7f0300a3; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int fontProviderPackage=0x7f0300a4; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int fontProviderQuery=0x7f0300a5; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>italic</td><td>1</td><td></td></tr> * <tr><td>normal</td><td>0</td><td></td></tr> * </table> */ public static final int fontStyle=0x7f0300a6; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int fontWeight=0x7f0300a7; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int foregroundInsidePadding=0x7f0300a8; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int gapBetweenBars=0x7f0300a9; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int goIcon=0x7f0300aa; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int headerLayout=0x7f0300ab; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int height=0x7f0300ac; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int hideOnContentScroll=0x7f0300ad; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int hintAnimationEnabled=0x7f0300ae; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int hintEnabled=0x7f0300af; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int hintTextAppearance=0x7f0300b0; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int homeAsUpIndicator=0x7f0300b1; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int homeLayout=0x7f0300b2; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int icon=0x7f0300b3; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int iconTint=0x7f0300b4; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>add</td><td>10</td><td></td></tr> * <tr><td>multiply</td><td>e</td><td></td></tr> * <tr><td>screen</td><td>f</td><td></td></tr> * <tr><td>src_atop</td><td>9</td><td></td></tr> * <tr><td>src_in</td><td>5</td><td></td></tr> * <tr><td>src_over</td><td>3</td><td></td></tr> * </table> */ public static final int iconTintMode=0x7f0300b5; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int iconifiedByDefault=0x7f0300b6; /** * <p>May be a floating point value, such as "<code>1.2</code>". */ public static final int imageAspectRatio=0x7f0300b7; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>adjust_height</td><td>2</td><td></td></tr> * <tr><td>adjust_width</td><td>1</td><td></td></tr> * <tr><td>none</td><td>0</td><td></td></tr> * </table> */ public static final int imageAspectRatioAdjust=0x7f0300b8; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int imageButtonStyle=0x7f0300b9; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int indeterminateProgressStyle=0x7f0300ba; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int initialActivityCount=0x7f0300bb; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int insetForeground=0x7f0300bc; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int isLightTheme=0x7f0300bd; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int itemBackground=0x7f0300be; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int itemIconTint=0x7f0300bf; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int itemPadding=0x7f0300c0; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int itemTextAppearance=0x7f0300c1; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int itemTextColor=0x7f0300c2; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int keylines=0x7f0300c3; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int layout=0x7f0300c4; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int layoutManager=0x7f0300c5; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int layout_anchor=0x7f0300c6; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>bottom</td><td>50</td><td></td></tr> * <tr><td>center</td><td>11</td><td></td></tr> * <tr><td>center_horizontal</td><td>1</td><td></td></tr> * <tr><td>center_vertical</td><td>10</td><td></td></tr> * <tr><td>clip_horizontal</td><td>8</td><td></td></tr> * <tr><td>clip_vertical</td><td>80</td><td></td></tr> * <tr><td>end</td><td>800005</td><td></td></tr> * <tr><td>fill</td><td>77</td><td></td></tr> * <tr><td>fill_horizontal</td><td>7</td><td></td></tr> * <tr><td>fill_vertical</td><td>70</td><td></td></tr> * <tr><td>left</td><td>3</td><td></td></tr> * <tr><td>right</td><td>5</td><td></td></tr> * <tr><td>start</td><td>800003</td><td></td></tr> * <tr><td>top</td><td>30</td><td></td></tr> * </table> */ public static final int layout_anchorGravity=0x7f0300c7; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int layout_behavior=0x7f0300c8; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>none</td><td>0</td><td></td></tr> * <tr><td>parallax</td><td>2</td><td></td></tr> * <tr><td>pin</td><td>1</td><td></td></tr> * </table> */ public static final int layout_collapseMode=0x7f0300c9; /** * <p>May be a floating point value, such as "<code>1.2</code>". */ public static final int layout_collapseParallaxMultiplier=0x7f0300ca; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int layout_constraintBaseline_creator=0x7f0300cb; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintBaseline_toBaselineOf=0x7f0300cc; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int layout_constraintBottom_creator=0x7f0300cd; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintBottom_toBottomOf=0x7f0300ce; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintBottom_toTopOf=0x7f0300cf; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int layout_constraintDimensionRatio=0x7f0300d0; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintEnd_toEndOf=0x7f0300d1; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintEnd_toStartOf=0x7f0300d2; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_constraintGuide_begin=0x7f0300d3; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_constraintGuide_end=0x7f0300d4; /** * <p>May be a floating point value, such as "<code>1.2</code>". */ public static final int layout_constraintGuide_percent=0x7f0300d5; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>spread</td><td>0</td><td></td></tr> * <tr><td>wrap</td><td>1</td><td></td></tr> * </table> */ public static final int layout_constraintHeight_default=0x7f0300d6; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_constraintHeight_max=0x7f0300d7; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_constraintHeight_min=0x7f0300d8; /** * <p>May be a floating point value, such as "<code>1.2</code>". */ public static final int layout_constraintHorizontal_bias=0x7f0300d9; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>packed</td><td>2</td><td></td></tr> * <tr><td>spread</td><td>0</td><td></td></tr> * <tr><td>spread_inside</td><td>1</td><td></td></tr> * </table> */ public static final int layout_constraintHorizontal_chainStyle=0x7f0300da; /** * <p>May be a floating point value, such as "<code>1.2</code>". */ public static final int layout_constraintHorizontal_weight=0x7f0300db; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int layout_constraintLeft_creator=0x7f0300dc; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintLeft_toLeftOf=0x7f0300dd; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintLeft_toRightOf=0x7f0300de; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int layout_constraintRight_creator=0x7f0300df; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintRight_toLeftOf=0x7f0300e0; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintRight_toRightOf=0x7f0300e1; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintStart_toEndOf=0x7f0300e2; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintStart_toStartOf=0x7f0300e3; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int layout_constraintTop_creator=0x7f0300e4; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintTop_toBottomOf=0x7f0300e5; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>parent</td><td>0</td><td></td></tr> * </table> */ public static final int layout_constraintTop_toTopOf=0x7f0300e6; /** * <p>May be a floating point value, such as "<code>1.2</code>". */ public static final int layout_constraintVertical_bias=0x7f0300e7; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>packed</td><td>2</td><td></td></tr> * <tr><td>spread</td><td>0</td><td></td></tr> * <tr><td>spread_inside</td><td>1</td><td></td></tr> * </table> */ public static final int layout_constraintVertical_chainStyle=0x7f0300e8; /** * <p>May be a floating point value, such as "<code>1.2</code>". */ public static final int layout_constraintVertical_weight=0x7f0300e9; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>spread</td><td>0</td><td></td></tr> * <tr><td>wrap</td><td>1</td><td></td></tr> * </table> */ public static final int layout_constraintWidth_default=0x7f0300ea; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_constraintWidth_max=0x7f0300eb; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_constraintWidth_min=0x7f0300ec; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>all</td><td>77</td><td></td></tr> * <tr><td>bottom</td><td>50</td><td></td></tr> * <tr><td>end</td><td>800005</td><td></td></tr> * <tr><td>left</td><td>3</td><td></td></tr> * <tr><td>none</td><td>0</td><td></td></tr> * <tr><td>right</td><td>3</td><td></td></tr> * <tr><td>start</td><td>800003</td><td></td></tr> * <tr><td>top</td><td>30</td><td></td></tr> * </table> */ public static final int layout_dodgeInsetEdges=0x7f0300ed; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_editor_absoluteX=0x7f0300ee; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_editor_absoluteY=0x7f0300ef; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_goneMarginBottom=0x7f0300f0; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_goneMarginEnd=0x7f0300f1; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_goneMarginLeft=0x7f0300f2; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_goneMarginRight=0x7f0300f3; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_goneMarginStart=0x7f0300f4; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int layout_goneMarginTop=0x7f0300f5; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>bottom</td><td>50</td><td></td></tr> * <tr><td>end</td><td>800005</td><td></td></tr> * <tr><td>left</td><td>3</td><td></td></tr> * <tr><td>none</td><td>0</td><td></td></tr> * <tr><td>right</td><td>3</td><td></td></tr> * <tr><td>start</td><td>800003</td><td></td></tr> * <tr><td>top</td><td>30</td><td></td></tr> * </table> */ public static final int layout_insetEdge=0x7f0300f6; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int layout_keyline=0x7f0300f7; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>all</td><td>2</td><td></td></tr> * <tr><td>basic</td><td>4</td><td></td></tr> * <tr><td>chains</td><td>8</td><td></td></tr> * <tr><td>none</td><td>1</td><td></td></tr> * </table> */ public static final int layout_optimizationLevel=0x7f0300f8; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>enterAlways</td><td>4</td><td></td></tr> * <tr><td>enterAlwaysCollapsed</td><td>8</td><td></td></tr> * <tr><td>exitUntilCollapsed</td><td>2</td><td></td></tr> * <tr><td>scroll</td><td>1</td><td></td></tr> * <tr><td>snap</td><td>10</td><td></td></tr> * </table> */ public static final int layout_scrollFlags=0x7f0300f9; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int layout_scrollInterpolator=0x7f0300fa; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int listChoiceBackgroundIndicator=0x7f0300fb; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int listDividerAlertDialog=0x7f0300fc; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int listItemLayout=0x7f0300fd; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int listLayout=0x7f0300fe; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int listMenuViewStyle=0x7f0300ff; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int listPopupWindowStyle=0x7f030100; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int listPreferredItemHeight=0x7f030101; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int listPreferredItemHeightLarge=0x7f030102; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int listPreferredItemHeightSmall=0x7f030103; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int listPreferredItemPaddingLeft=0x7f030104; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int listPreferredItemPaddingRight=0x7f030105; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int logo=0x7f030106; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int logoDescription=0x7f030107; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int maxActionInlineWidth=0x7f030108; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int maxButtonHeight=0x7f030109; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int max_visible=0x7f03010a; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int measureWithLargestChild=0x7f03010b; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int menu=0x7f03010c; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int min_adapter_stack=0x7f03010d; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int multiChoiceItemLayout=0x7f03010e; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int navigationContentDescription=0x7f03010f; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int navigationIcon=0x7f030110; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>listMode</td><td>1</td><td></td></tr> * <tr><td>normal</td><td>0</td><td></td></tr> * <tr><td>tabMode</td><td>2</td><td></td></tr> * </table> */ public static final int navigationMode=0x7f030111; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>ALT</td><td>2</td><td></td></tr> * <tr><td>CTRL</td><td>1000</td><td></td></tr> * <tr><td>FUNCTION</td><td>8</td><td></td></tr> * <tr><td>META</td><td>10000</td><td></td></tr> * <tr><td>SHIFT</td><td>1</td><td></td></tr> * <tr><td>SYM</td><td>4</td><td></td></tr> * </table> */ public static final int numericModifiers=0x7f030112; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int overlapAnchor=0x7f030113; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int paddingBottomNoButtons=0x7f030114; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int paddingEnd=0x7f030115; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int paddingStart=0x7f030116; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int paddingTopNoTitle=0x7f030117; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int panelBackground=0x7f030118; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int panelMenuListTheme=0x7f030119; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int panelMenuListWidth=0x7f03011a; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int passwordToggleContentDescription=0x7f03011b; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int passwordToggleDrawable=0x7f03011c; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int passwordToggleEnabled=0x7f03011d; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int passwordToggleTint=0x7f03011e; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>multiply</td><td>e</td><td></td></tr> * <tr><td>screen</td><td>f</td><td></td></tr> * <tr><td>src_atop</td><td>9</td><td></td></tr> * <tr><td>src_in</td><td>5</td><td></td></tr> * <tr><td>src_over</td><td>3</td><td></td></tr> * </table> */ public static final int passwordToggleTintMode=0x7f03011f; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int popupMenuStyle=0x7f030120; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int popupTheme=0x7f030121; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int popupWindowStyle=0x7f030122; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int preserveIconSpacing=0x7f030123; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int pressedTranslationZ=0x7f030124; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int progressBarPadding=0x7f030125; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int progressBarStyle=0x7f030126; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int queryBackground=0x7f030127; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int queryHint=0x7f030128; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int radioButtonStyle=0x7f030129; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int ratingBarStyle=0x7f03012a; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int ratingBarStyleIndicator=0x7f03012b; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int ratingBarStyleSmall=0x7f03012c; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int reverseLayout=0x7f03012d; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int rippleColor=0x7f03012e; /** * <p>May be a floating point value, such as "<code>1.2</code>". */ public static final int rotation_degrees=0x7f03012f; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int scopeUris=0x7f030130; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int scrimAnimationDuration=0x7f030131; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int scrimVisibleHeightTrigger=0x7f030132; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int searchHintIcon=0x7f030133; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int searchIcon=0x7f030134; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int searchViewStyle=0x7f030135; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int seekBarStyle=0x7f030136; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int selectableItemBackground=0x7f030137; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int selectableItemBackgroundBorderless=0x7f030138; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>always</td><td>2</td><td></td></tr> * <tr><td>collapseActionView</td><td>8</td><td></td></tr> * <tr><td>ifRoom</td><td>1</td><td></td></tr> * <tr><td>never</td><td>0</td><td></td></tr> * <tr><td>withText</td><td>4</td><td></td></tr> * </table> */ public static final int showAsAction=0x7f030139; /** * <p>Must be one or more (separated by '|') of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>beginning</td><td>1</td><td></td></tr> * <tr><td>end</td><td>4</td><td></td></tr> * <tr><td>middle</td><td>2</td><td></td></tr> * <tr><td>none</td><td>0</td><td></td></tr> * </table> */ public static final int showDividers=0x7f03013a; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int showText=0x7f03013b; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int showTitle=0x7f03013c; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int singleChoiceItemLayout=0x7f03013d; /** * <p>May be an integer value, such as "<code>100</code>". */ public static final int spanCount=0x7f03013e; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int spinBars=0x7f03013f; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int spinnerDropDownItemStyle=0x7f030140; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int spinnerStyle=0x7f030141; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int splitTrack=0x7f030142; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int srcCompat=0x7f030143; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int stackFromEnd=0x7f030144; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int state_above_anchor=0x7f030145; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int state_collapsed=0x7f030146; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int state_collapsible=0x7f030147; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int statusBarBackground=0x7f030148; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int statusBarScrim=0x7f030149; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int subMenuArrow=0x7f03014a; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int submitBackground=0x7f03014b; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int subtitle=0x7f03014c; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int subtitleTextAppearance=0x7f03014d; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int subtitleTextColor=0x7f03014e; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int subtitleTextStyle=0x7f03014f; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int suggestionRowLayout=0x7f030150; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int switchMinWidth=0x7f030151; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int switchPadding=0x7f030152; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int switchStyle=0x7f030153; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int switchTextAppearance=0x7f030154; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int tabBackground=0x7f030155; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int tabContentStart=0x7f030156; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>center</td><td>1</td><td></td></tr> * <tr><td>fill</td><td>0</td><td></td></tr> * </table> */ public static final int tabGravity=0x7f030157; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int tabIndicatorColor=0x7f030158; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int tabIndicatorHeight=0x7f030159; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int tabMaxWidth=0x7f03015a; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int tabMinWidth=0x7f03015b; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>fixed</td><td>1</td><td></td></tr> * <tr><td>scrollable</td><td>0</td><td></td></tr> * </table> */ public static final int tabMode=0x7f03015c; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int tabPadding=0x7f03015d; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int tabPaddingBottom=0x7f03015e; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int tabPaddingEnd=0x7f03015f; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int tabPaddingStart=0x7f030160; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int tabPaddingTop=0x7f030161; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int tabSelectedTextColor=0x7f030162; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int tabTextAppearance=0x7f030163; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int tabTextColor=0x7f030164; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int textAllCaps=0x7f030165; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int textAppearanceLargePopupMenu=0x7f030166; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int textAppearanceListItem=0x7f030167; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int textAppearanceListItemSecondary=0x7f030168; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int textAppearanceListItemSmall=0x7f030169; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int textAppearancePopupMenuHeader=0x7f03016a; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int textAppearanceSearchResultSubtitle=0x7f03016b; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int textAppearanceSearchResultTitle=0x7f03016c; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int textAppearanceSmallPopupMenu=0x7f03016d; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int textColorAlertDialogListItem=0x7f03016e; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int textColorError=0x7f03016f; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int textColorSearchUrl=0x7f030170; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int theme=0x7f030171; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int thickness=0x7f030172; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int thumbTextPadding=0x7f030173; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int thumbTint=0x7f030174; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>add</td><td>10</td><td></td></tr> * <tr><td>multiply</td><td>e</td><td></td></tr> * <tr><td>screen</td><td>f</td><td></td></tr> * <tr><td>src_atop</td><td>9</td><td></td></tr> * <tr><td>src_in</td><td>5</td><td></td></tr> * <tr><td>src_over</td><td>3</td><td></td></tr> * </table> */ public static final int thumbTintMode=0x7f030175; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int tickMark=0x7f030176; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int tickMarkTint=0x7f030177; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>add</td><td>10</td><td></td></tr> * <tr><td>multiply</td><td>e</td><td></td></tr> * <tr><td>screen</td><td>f</td><td></td></tr> * <tr><td>src_atop</td><td>9</td><td></td></tr> * <tr><td>src_in</td><td>5</td><td></td></tr> * <tr><td>src_over</td><td>3</td><td></td></tr> * </table> */ public static final int tickMarkTintMode=0x7f030178; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int tint=0x7f030179; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>multiply</td><td>e</td><td></td></tr> * <tr><td>screen</td><td>f</td><td></td></tr> * <tr><td>src_atop</td><td>9</td><td></td></tr> * <tr><td>src_in</td><td>5</td><td></td></tr> * <tr><td>src_over</td><td>3</td><td></td></tr> * </table> */ public static final int tintMode=0x7f03017a; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int title=0x7f03017b; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int titleEnabled=0x7f03017c; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int titleMargin=0x7f03017d; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int titleMarginBottom=0x7f03017e; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int titleMarginEnd=0x7f03017f; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int titleMarginStart=0x7f030180; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int titleMarginTop=0x7f030181; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). */ public static final int titleMargins=0x7f030182; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int titleTextAppearance=0x7f030183; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int titleTextColor=0x7f030184; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int titleTextStyle=0x7f030185; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int toolbarId=0x7f030186; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int toolbarNavigationButtonStyle=0x7f030187; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int toolbarStyle=0x7f030188; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int tooltipForegroundColor=0x7f030189; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int tooltipFrameBackground=0x7f03018a; /** * <p>May be a string value, using '\\;' to escape characters such as * '\\n' or '\\uxxxx' for a unicode character; */ public static final int tooltipText=0x7f03018b; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int track=0x7f03018c; /** * <p>May be a color value, in the form of "<code>#<i>rgb</i></code>", * "<code>#<i>argb</i></code>", "<code>#<i>rrggbb</i></code>", or * "<code>#<i>aarrggbb</i></code>". */ public static final int trackTint=0x7f03018d; /** * <p>Must be one of the following constant values.</p> * <table> * <colgroup align="left" /> * <colgroup align="left" /> * <colgroup align="left" /> * <tr><th>Constant</th><th>Value</th><th>Description</th></tr> * <tr><td>add</td><td>10</td><td></td></tr> * <tr><td>multiply</td><td>e</td><td></td></tr> * <tr><td>screen</td><td>f</td><td></td></tr> * <tr><td>src_atop</td><td>9</td><td></td></tr> * <tr><td>src_in</td><td>5</td><td></td></tr> * <tr><td>src_over</td><td>3</td><td></td></tr> * </table> */ public static final int trackTintMode=0x7f03018e; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int useCompatPadding=0x7f03018f; /** * <p>May be a reference to another resource, in the form * "<code>@[+][<i>package</i>:]<i>type</i>/<i>name</i></code>" or a theme * attribute in the form * "<code>?[<i>package</i>:]<i>type</i>/<i>name</i></code>". */ public static final int voiceIcon=0x7f030190; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int windowActionBar=0x7f030191; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int windowActionBarOverlay=0x7f030192; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int windowActionModeOverlay=0x7f030193; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). * <p>May be a fractional value, which is a floating point number appended with * either % or %p, such as "<code>14.5%</code>". * The % suffix always means a percentage of the base size; * the optional %p suffix provides a size relative to some parent container. */ public static final int windowFixedHeightMajor=0x7f030194; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). * <p>May be a fractional value, which is a floating point number appended with * either % or %p, such as "<code>14.5%</code>". * The % suffix always means a percentage of the base size; * the optional %p suffix provides a size relative to some parent container. */ public static final int windowFixedHeightMinor=0x7f030195; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). * <p>May be a fractional value, which is a floating point number appended with * either % or %p, such as "<code>14.5%</code>". * The % suffix always means a percentage of the base size; * the optional %p suffix provides a size relative to some parent container. */ public static final int windowFixedWidthMajor=0x7f030196; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). * <p>May be a fractional value, which is a floating point number appended with * either % or %p, such as "<code>14.5%</code>". * The % suffix always means a percentage of the base size; * the optional %p suffix provides a size relative to some parent container. */ public static final int windowFixedWidthMinor=0x7f030197; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). * <p>May be a fractional value, which is a floating point number appended with * either % or %p, such as "<code>14.5%</code>". * The % suffix always means a percentage of the base size; * the optional %p suffix provides a size relative to some parent container. */ public static final int windowMinWidthMajor=0x7f030198; /** * <p>May be a dimension value, which is a floating point number appended with a * unit such as "<code>14.5sp</code>". * Available units are: px (pixels), dp (density-independent pixels), * sp (scaled pixels based on preferred font size), in (inches), and * mm (millimeters). * <p>May be a fractional value, which is a floating point number appended with * either % or %p, such as "<code>14.5%</code>". * The % suffix always means a percentage of the base size; * the optional %p suffix provides a size relative to some parent container. */ public static final int windowMinWidthMinor=0x7f030199; /** * <p>May be a boolean value, such as "<code>true</code>" or * "<code>false</code>". */ public static final int windowNoTitle=0x7f03019a; } public static final class bool { public static final int abc_action_bar_embed_tabs=0x7f040000; public static final int abc_allow_stacked_button_bar=0x7f040001; public static final int abc_config_actionMenuItemAllCaps=0x7f040002; public static final int abc_config_closeDialogWhenTouchOutside=0x7f040003; public static final int abc_config_showMenuShortcutsWhenKeyboardPresent=0x7f040004; } public static final class color { public static final int abc_background_cache_hint_selector_material_dark=0x7f050000; public static final int abc_background_cache_hint_selector_material_light=0x7f050001; public static final int abc_btn_colored_borderless_text_material=0x7f050002; public static final int abc_btn_colored_text_material=0x7f050003; public static final int abc_color_highlight_material=0x7f050004; public static final int abc_hint_foreground_material_dark=0x7f050005; public static final int abc_hint_foreground_material_light=0x7f050006; public static final int abc_input_method_navigation_guard=0x7f050007; public static final int abc_primary_text_disable_only_material_dark=0x7f050008; public static final int abc_primary_text_disable_only_material_light=0x7f050009; public static final int abc_primary_text_material_dark=0x7f05000a; public static final int abc_primary_text_material_light=0x7f05000b; public static final int abc_search_url_text=0x7f05000c; public static final int abc_search_url_text_normal=0x7f05000d; public static final int abc_search_url_text_pressed=0x7f05000e; public static final int abc_search_url_text_selected=0x7f05000f; public static final int abc_secondary_text_material_dark=0x7f050010; public static final int abc_secondary_text_material_light=0x7f050011; public static final int abc_tint_btn_checkable=0x7f050012; public static final int abc_tint_default=0x7f050013; public static final int abc_tint_edittext=0x7f050014; public static final int abc_tint_seek_thumb=0x7f050015; public static final int abc_tint_spinner=0x7f050016; public static final int abc_tint_switch_track=0x7f050017; public static final int accent_material_dark=0x7f050018; public static final int accent_material_light=0x7f050019; public static final int background_floating_material_dark=0x7f05001a; public static final int background_floating_material_light=0x7f05001b; public static final int background_material_dark=0x7f05001c; public static final int background_material_light=0x7f05001d; public static final int bright_foreground_disabled_material_dark=0x7f05001e; public static final int bright_foreground_disabled_material_light=0x7f05001f; public static final int bright_foreground_inverse_material_dark=0x7f050020; public static final int bright_foreground_inverse_material_light=0x7f050021; public static final int bright_foreground_material_dark=0x7f050022; public static final int bright_foreground_material_light=0x7f050023; public static final int button_material_dark=0x7f050024; public static final int button_material_light=0x7f050025; public static final int cardview_dark_background=0x7f050026; public static final int cardview_light_background=0x7f050027; public static final int cardview_shadow_end_color=0x7f050028; public static final int cardview_shadow_start_color=0x7f050029; public static final int colorAccent=0x7f05002a; public static final int colorPrimary=0x7f05002b; public static final int colorPrimaryDark=0x7f05002c; public static final int common_google_signin_btn_text_dark=0x7f05002d; public static final int common_google_signin_btn_text_dark_default=0x7f05002e; public static final int common_google_signin_btn_text_dark_disabled=0x7f05002f; public static final int common_google_signin_btn_text_dark_focused=0x7f050030; public static final int common_google_signin_btn_text_dark_pressed=0x7f050031; public static final int common_google_signin_btn_text_light=0x7f050032; public static final int common_google_signin_btn_text_light_default=0x7f050033; public static final int common_google_signin_btn_text_light_disabled=0x7f050034; public static final int common_google_signin_btn_text_light_focused=0x7f050035; public static final int common_google_signin_btn_text_light_pressed=0x7f050036; public static final int common_google_signin_btn_tint=0x7f050037; public static final int design_bottom_navigation_shadow_color=0x7f050038; public static final int design_error=0x7f050039; public static final int design_fab_shadow_end_color=0x7f05003a; public static final int design_fab_shadow_mid_color=0x7f05003b; public static final int design_fab_shadow_start_color=0x7f05003c; public static final int design_fab_stroke_end_inner_color=0x7f05003d; public static final int design_fab_stroke_end_outer_color=0x7f05003e; public static final int design_fab_stroke_top_inner_color=0x7f05003f; public static final int design_fab_stroke_top_outer_color=0x7f050040; public static final int design_snackbar_background_color=0x7f050041; public static final int design_tint_password_toggle=0x7f050042; public static final int dim_foreground_disabled_material_dark=0x7f050043; public static final int dim_foreground_disabled_material_light=0x7f050044; public static final int dim_foreground_material_dark=0x7f050045; public static final int dim_foreground_material_light=0x7f050046; public static final int error_color_material=0x7f050047; public static final int foreground_material_dark=0x7f050048; public static final int foreground_material_light=0x7f050049; public static final int highlighted_text_material_dark=0x7f05004a; public static final int highlighted_text_material_light=0x7f05004b; public static final int material_blue_grey_800=0x7f05004c; public static final int material_blue_grey_900=0x7f05004d; public static final int material_blue_grey_950=0x7f05004e; public static final int material_deep_teal_200=0x7f05004f; public static final int material_deep_teal_500=0x7f050050; public static final int material_grey_100=0x7f050051; public static final int material_grey_300=0x7f050052; public static final int material_grey_50=0x7f050053; public static final int material_grey_600=0x7f050054; public static final int material_grey_800=0x7f050055; public static final int material_grey_850=0x7f050056; public static final int material_grey_900=0x7f050057; public static final int notification_action_color_filter=0x7f050058; public static final int notification_icon_bg_color=0x7f050059; public static final int notification_material_background_media_default_color=0x7f05005a; public static final int primary_dark_material_dark=0x7f05005b; public static final int primary_dark_material_light=0x7f05005c; public static final int primary_material_dark=0x7f05005d; public static final int primary_material_light=0x7f05005e; public static final int primary_text_default_material_dark=0x7f05005f; public static final int primary_text_default_material_light=0x7f050060; public static final int primary_text_disabled_material_dark=0x7f050061; public static final int primary_text_disabled_material_light=0x7f050062; public static final int ripple_material_dark=0x7f050063; public static final int ripple_material_light=0x7f050064; public static final int secondary_text_default_material_dark=0x7f050065; public static final int secondary_text_default_material_light=0x7f050066; public static final int secondary_text_disabled_material_dark=0x7f050067; public static final int secondary_text_disabled_material_light=0x7f050068; public static final int switch_thumb_disabled_material_dark=0x7f050069; public static final int switch_thumb_disabled_material_light=0x7f05006a; public static final int switch_thumb_material_dark=0x7f05006b; public static final int switch_thumb_material_light=0x7f05006c; public static final int switch_thumb_normal_material_dark=0x7f05006d; public static final int switch_thumb_normal_material_light=0x7f05006e; public static final int tooltip_background_dark=0x7f05006f; public static final int tooltip_background_light=0x7f050070; } public static final class dimen { public static final int abc_action_bar_content_inset_material=0x7f060000; public static final int abc_action_bar_content_inset_with_nav=0x7f060001; public static final int abc_action_bar_default_height_material=0x7f060002; public static final int abc_action_bar_default_padding_end_material=0x7f060003; public static final int abc_action_bar_default_padding_start_material=0x7f060004; public static final int abc_action_bar_elevation_material=0x7f060005; public static final int abc_action_bar_icon_vertical_padding_material=0x7f060006; public static final int abc_action_bar_overflow_padding_end_material=0x7f060007; public static final int abc_action_bar_overflow_padding_start_material=0x7f060008; public static final int abc_action_bar_progress_bar_size=0x7f060009; public static final int abc_action_bar_stacked_max_height=0x7f06000a; public static final int abc_action_bar_stacked_tab_max_width=0x7f06000b; public static final int abc_action_bar_subtitle_bottom_margin_material=0x7f06000c; public static final int abc_action_bar_subtitle_top_margin_material=0x7f06000d; public static final int abc_action_button_min_height_material=0x7f06000e; public static final int abc_action_button_min_width_material=0x7f06000f; public static final int abc_action_button_min_width_overflow_material=0x7f060010; public static final int abc_alert_dialog_button_bar_height=0x7f060011; public static final int abc_button_inset_horizontal_material=0x7f060012; public static final int abc_button_inset_vertical_material=0x7f060013; public static final int abc_button_padding_horizontal_material=0x7f060014; public static final int abc_button_padding_vertical_material=0x7f060015; public static final int abc_cascading_menus_min_smallest_width=0x7f060016; public static final int abc_config_prefDialogWidth=0x7f060017; public static final int abc_control_corner_material=0x7f060018; public static final int abc_control_inset_material=0x7f060019; public static final int abc_control_padding_material=0x7f06001a; public static final int abc_dialog_fixed_height_major=0x7f06001b; public static final int abc_dialog_fixed_height_minor=0x7f06001c; public static final int abc_dialog_fixed_width_major=0x7f06001d; public static final int abc_dialog_fixed_width_minor=0x7f06001e; public static final int abc_dialog_list_padding_bottom_no_buttons=0x7f06001f; public static final int abc_dialog_list_padding_top_no_title=0x7f060020; public static final int abc_dialog_min_width_major=0x7f060021; public static final int abc_dialog_min_width_minor=0x7f060022; public static final int abc_dialog_padding_material=0x7f060023; public static final int abc_dialog_padding_top_material=0x7f060024; public static final int abc_dialog_title_divider_material=0x7f060025; public static final int abc_disabled_alpha_material_dark=0x7f060026; public static final int abc_disabled_alpha_material_light=0x7f060027; public static final int abc_dropdownitem_icon_width=0x7f060028; public static final int abc_dropdownitem_text_padding_left=0x7f060029; public static final int abc_dropdownitem_text_padding_right=0x7f06002a; public static final int abc_edit_text_inset_bottom_material=0x7f06002b; public static final int abc_edit_text_inset_horizontal_material=0x7f06002c; public static final int abc_edit_text_inset_top_material=0x7f06002d; public static final int abc_floating_window_z=0x7f06002e; public static final int abc_list_item_padding_horizontal_material=0x7f06002f; public static final int abc_panel_menu_list_width=0x7f060030; public static final int abc_progress_bar_height_material=0x7f060031; public static final int abc_search_view_preferred_height=0x7f060032; public static final int abc_search_view_preferred_width=0x7f060033; public static final int abc_seekbar_track_background_height_material=0x7f060034; public static final int abc_seekbar_track_progress_height_material=0x7f060035; public static final int abc_select_dialog_padding_start_material=0x7f060036; public static final int abc_switch_padding=0x7f060037; public static final int abc_text_size_body_1_material=0x7f060038; public static final int abc_text_size_body_2_material=0x7f060039; public static final int abc_text_size_button_material=0x7f06003a; public static final int abc_text_size_caption_material=0x7f06003b; public static final int abc_text_size_display_1_material=0x7f06003c; public static final int abc_text_size_display_2_material=0x7f06003d; public static final int abc_text_size_display_3_material=0x7f06003e; public static final int abc_text_size_display_4_material=0x7f06003f; public static final int abc_text_size_headline_material=0x7f060040; public static final int abc_text_size_large_material=0x7f060041; public static final int abc_text_size_medium_material=0x7f060042; public static final int abc_text_size_menu_header_material=0x7f060043; public static final int abc_text_size_menu_material=0x7f060044; public static final int abc_text_size_small_material=0x7f060045; public static final int abc_text_size_subhead_material=0x7f060046; public static final int abc_text_size_subtitle_material_toolbar=0x7f060047; public static final int abc_text_size_title_material=0x7f060048; public static final int abc_text_size_title_material_toolbar=0x7f060049; public static final int cardview_compat_inset_shadow=0x7f06004a; public static final int cardview_default_elevation=0x7f06004b; public static final int cardview_default_radius=0x7f06004c; public static final int compat_button_inset_horizontal_material=0x7f06004d; public static final int compat_button_inset_vertical_material=0x7f06004e; public static final int compat_button_padding_horizontal_material=0x7f06004f; public static final int compat_button_padding_vertical_material=0x7f060050; public static final int compat_control_corner_material=0x7f060051; public static final int design_appbar_elevation=0x7f060052; public static final int design_bottom_navigation_active_item_max_width=0x7f060053; public static final int design_bottom_navigation_active_text_size=0x7f060054; public static final int design_bottom_navigation_elevation=0x7f060055; public static final int design_bottom_navigation_height=0x7f060056; public static final int design_bottom_navigation_item_max_width=0x7f060057; public static final int design_bottom_navigation_item_min_width=0x7f060058; public static final int design_bottom_navigation_margin=0x7f060059; public static final int design_bottom_navigation_shadow_height=0x7f06005a; public static final int design_bottom_navigation_text_size=0x7f06005b; public static final int design_bottom_sheet_modal_elevation=0x7f06005c; public static final int design_bottom_sheet_peek_height_min=0x7f06005d; public static final int design_fab_border_width=0x7f06005e; public static final int design_fab_elevation=0x7f06005f; public static final int design_fab_image_size=0x7f060060; public static final int design_fab_size_mini=0x7f060061; public static final int design_fab_size_normal=0x7f060062; public static final int design_fab_translation_z_pressed=0x7f060063; public static final int design_navigation_elevation=0x7f060064; public static final int design_navigation_icon_padding=0x7f060065; public static final int design_navigation_icon_size=0x7f060066; public static final int design_navigation_max_width=0x7f060067; public static final int design_navigation_padding_bottom=0x7f060068; public static final int design_navigation_separator_vertical_padding=0x7f060069; public static final int design_snackbar_action_inline_max_width=0x7f06006a; public static final int design_snackbar_background_corner_radius=0x7f06006b; public static final int design_snackbar_elevation=0x7f06006c; public static final int design_snackbar_extra_spacing_horizontal=0x7f06006d; public static final int design_snackbar_max_width=0x7f06006e; public static final int design_snackbar_min_width=0x7f06006f; public static final int design_snackbar_padding_horizontal=0x7f060070; public static final int design_snackbar_padding_vertical=0x7f060071; public static final int design_snackbar_padding_vertical_2lines=0x7f060072; public static final int design_snackbar_text_size=0x7f060073; public static final int design_tab_max_width=0x7f060074; public static final int design_tab_scrollable_min_width=0x7f060075; public static final int design_tab_text_size=0x7f060076; public static final int design_tab_text_size_2line=0x7f060077; public static final int disabled_alpha_material_dark=0x7f060078; public static final int disabled_alpha_material_light=0x7f060079; public static final int fastscroll_default_thickness=0x7f06007a; public static final int fastscroll_margin=0x7f06007b; public static final int fastscroll_minimum_range=0x7f06007c; public static final int highlight_alpha_material_colored=0x7f06007d; public static final int highlight_alpha_material_dark=0x7f06007e; public static final int highlight_alpha_material_light=0x7f06007f; public static final int hint_alpha_material_dark=0x7f060080; public static final int hint_alpha_material_light=0x7f060081; public static final int hint_pressed_alpha_material_dark=0x7f060082; public static final int hint_pressed_alpha_material_light=0x7f060083; public static final int item_touch_helper_max_drag_scroll_per_frame=0x7f060084; public static final int item_touch_helper_swipe_escape_max_velocity=0x7f060085; public static final int item_touch_helper_swipe_escape_velocity=0x7f060086; public static final int notification_action_icon_size=0x7f060087; public static final int notification_action_text_size=0x7f060088; public static final int notification_big_circle_margin=0x7f060089; public static final int notification_content_margin_start=0x7f06008a; public static final int notification_large_icon_height=0x7f06008b; public static final int notification_large_icon_width=0x7f06008c; public static final int notification_main_column_padding_top=0x7f06008d; public static final int notification_media_narrow_margin=0x7f06008e; public static final int notification_right_icon_size=0x7f06008f; public static final int notification_right_side_padding_top=0x7f060090; public static final int notification_small_icon_background_padding=0x7f060091; public static final int notification_small_icon_size_as_large=0x7f060092; public static final int notification_subtext_size=0x7f060093; public static final int notification_top_pad=0x7f060094; public static final int notification_top_pad_large_text=0x7f060095; public static final int tooltip_corner_radius=0x7f060096; public static final int tooltip_horizontal_padding=0x7f060097; public static final int tooltip_margin=0x7f060098; public static final int tooltip_precise_anchor_extra_offset=0x7f060099; public static final int tooltip_precise_anchor_threshold=0x7f06009a; public static final int tooltip_vertical_padding=0x7f06009b; public static final int tooltip_y_offset_non_touch=0x7f06009c; public static final int tooltip_y_offset_touch=0x7f06009d; } public static final class drawable { public static final int abc_ab_share_pack_mtrl_alpha=0x7f070006; public static final int abc_action_bar_item_background_material=0x7f070007; public static final int abc_btn_borderless_material=0x7f070008; public static final int abc_btn_check_material=0x7f070009; public static final int abc_btn_check_to_on_mtrl_000=0x7f07000a; public static final int abc_btn_check_to_on_mtrl_015=0x7f07000b; public static final int abc_btn_colored_material=0x7f07000c; public static final int abc_btn_default_mtrl_shape=0x7f07000d; public static final int abc_btn_radio_material=0x7f07000e; public static final int abc_btn_radio_to_on_mtrl_000=0x7f07000f; public static final int abc_btn_radio_to_on_mtrl_015=0x7f070010; public static final int abc_btn_switch_to_on_mtrl_00001=0x7f070011; public static final int abc_btn_switch_to_on_mtrl_00012=0x7f070012; public static final int abc_cab_background_internal_bg=0x7f070013; public static final int abc_cab_background_top_material=0x7f070014; public static final int abc_cab_background_top_mtrl_alpha=0x7f070015; public static final int abc_control_background_material=0x7f070016; public static final int abc_dialog_material_background=0x7f070017; public static final int abc_edit_text_material=0x7f070018; public static final int abc_ic_ab_back_material=0x7f070019; public static final int abc_ic_arrow_drop_right_black_24dp=0x7f07001a; public static final int abc_ic_clear_material=0x7f07001b; public static final int abc_ic_commit_search_api_mtrl_alpha=0x7f07001c; public static final int abc_ic_go_search_api_material=0x7f07001d; public static final int abc_ic_menu_copy_mtrl_am_alpha=0x7f07001e; public static final int abc_ic_menu_cut_mtrl_alpha=0x7f07001f; public static final int abc_ic_menu_overflow_material=0x7f070020; public static final int abc_ic_menu_paste_mtrl_am_alpha=0x7f070021; public static final int abc_ic_menu_selectall_mtrl_alpha=0x7f070022; public static final int abc_ic_menu_share_mtrl_alpha=0x7f070023; public static final int abc_ic_search_api_material=0x7f070024; public static final int abc_ic_star_black_16dp=0x7f070025; public static final int abc_ic_star_black_36dp=0x7f070026; public static final int abc_ic_star_black_48dp=0x7f070027; public static final int abc_ic_star_half_black_16dp=0x7f070028; public static final int abc_ic_star_half_black_36dp=0x7f070029; public static final int abc_ic_star_half_black_48dp=0x7f07002a; public static final int abc_ic_voice_search_api_material=0x7f07002b; public static final int abc_item_background_holo_dark=0x7f07002c; public static final int abc_item_background_holo_light=0x7f07002d; public static final int abc_list_divider_mtrl_alpha=0x7f07002e; public static final int abc_list_focused_holo=0x7f07002f; public static final int abc_list_longpressed_holo=0x7f070030; public static final int abc_list_pressed_holo_dark=0x7f070031; public static final int abc_list_pressed_holo_light=0x7f070032; public static final int abc_list_selector_background_transition_holo_dark=0x7f070033; public static final int abc_list_selector_background_transition_holo_light=0x7f070034; public static final int abc_list_selector_disabled_holo_dark=0x7f070035; public static final int abc_list_selector_disabled_holo_light=0x7f070036; public static final int abc_list_selector_holo_dark=0x7f070037; public static final int abc_list_selector_holo_light=0x7f070038; public static final int abc_menu_hardkey_panel_mtrl_mult=0x7f070039; public static final int abc_popup_background_mtrl_mult=0x7f07003a; public static final int abc_ratingbar_indicator_material=0x7f07003b; public static final int abc_ratingbar_material=0x7f07003c; public static final int abc_ratingbar_small_material=0x7f07003d; public static final int abc_scrubber_control_off_mtrl_alpha=0x7f07003e; public static final int abc_scrubber_control_to_pressed_mtrl_000=0x7f07003f; public static final int abc_scrubber_control_to_pressed_mtrl_005=0x7f070040; public static final int abc_scrubber_primary_mtrl_alpha=0x7f070041; public static final int abc_scrubber_track_mtrl_alpha=0x7f070042; public static final int abc_seekbar_thumb_material=0x7f070043; public static final int abc_seekbar_tick_mark_material=0x7f070044; public static final int abc_seekbar_track_material=0x7f070045; public static final int abc_spinner_mtrl_am_alpha=0x7f070046; public static final int abc_spinner_textfield_background_material=0x7f070047; public static final int abc_switch_thumb_material=0x7f070048; public static final int abc_switch_track_mtrl_alpha=0x7f070049; public static final int abc_tab_indicator_material=0x7f07004a; public static final int abc_tab_indicator_mtrl_alpha=0x7f07004b; public static final int abc_text_cursor_material=0x7f07004c; public static final int abc_text_select_handle_left_mtrl_dark=0x7f07004d; public static final int abc_text_select_handle_left_mtrl_light=0x7f07004e; public static final int abc_text_select_handle_middle_mtrl_dark=0x7f07004f; public static final int abc_text_select_handle_middle_mtrl_light=0x7f070050; public static final int abc_text_select_handle_right_mtrl_dark=0x7f070051; public static final int abc_text_select_handle_right_mtrl_light=0x7f070052; public static final int abc_textfield_activated_mtrl_alpha=0x7f070053; public static final int abc_textfield_default_mtrl_alpha=0x7f070054; public static final int abc_textfield_search_activated_mtrl_alpha=0x7f070055; public static final int abc_textfield_search_default_mtrl_alpha=0x7f070056; public static final int abc_textfield_search_material=0x7f070057; public static final int abc_vector_test=0x7f070058; public static final int avd_hide_password=0x7f070059; public static final int avd_show_password=0x7f07005a; public static final int common_full_open_on_phone=0x7f07005b; public static final int common_google_signin_btn_icon_dark=0x7f07005c; public static final int common_google_signin_btn_icon_dark_focused=0x7f07005d; public static final int common_google_signin_btn_icon_dark_normal=0x7f07005e; public static final int common_google_signin_btn_icon_dark_normal_background=0x7f07005f; public static final int common_google_signin_btn_icon_disabled=0x7f070060; public static final int common_google_signin_btn_icon_light=0x7f070061; public static final int common_google_signin_btn_icon_light_focused=0x7f070062; public static final int common_google_signin_btn_icon_light_normal=0x7f070063; public static final int common_google_signin_btn_icon_light_normal_background=0x7f070064; public static final int common_google_signin_btn_text_dark=0x7f070065; public static final int common_google_signin_btn_text_dark_focused=0x7f070066; public static final int common_google_signin_btn_text_dark_normal=0x7f070067; public static final int common_google_signin_btn_text_dark_normal_background=0x7f070068; public static final int common_google_signin_btn_text_disabled=0x7f070069; public static final int common_google_signin_btn_text_light=0x7f07006a; public static final int common_google_signin_btn_text_light_focused=0x7f07006b; public static final int common_google_signin_btn_text_light_normal=0x7f07006c; public static final int common_google_signin_btn_text_light_normal_background=0x7f07006d; public static final int design_bottom_navigation_item_background=0x7f07006e; public static final int design_fab_background=0x7f07006f; public static final int design_ic_visibility=0x7f070070; public static final int design_ic_visibility_off=0x7f070071; public static final int design_password_eye=0x7f070072; public static final int design_snackbar_background=0x7f070073; public static final int googleg_disabled_color_18=0x7f070074; public static final int googleg_standard_color_18=0x7f070075; public static final int ic_launcher_background=0x7f070076; public static final int navigation_empty_icon=0x7f070077; public static final int notification_action_background=0x7f070078; public static final int notification_bg=0x7f070079; public static final int notification_bg_low=0x7f07007a; public static final int notification_bg_low_normal=0x7f07007b; public static final int notification_bg_low_pressed=0x7f07007c; public static final int notification_bg_normal=0x7f07007d; public static final int notification_bg_normal_pressed=0x7f07007e; public static final int notification_icon_background=0x7f07007f; public static final int notification_template_icon_bg=0x7f070080; public static final int notification_template_icon_low_bg=0x7f070081; public static final int notification_tile_bg=0x7f070082; public static final int notify_panel_notification_icon_bg=0x7f070083; public static final int tooltip_frame_dark=0x7f070084; public static final int tooltip_frame_light=0x7f070085; } public static final class id { public static final int ALT=0x7f080000; public static final int CTRL=0x7f080001; public static final int FUNCTION=0x7f080002; public static final int META=0x7f080003; public static final int MatchImage=0x7f080004; public static final int MatchName=0x7f080005; public static final int Matchid=0x7f080006; public static final int SHIFT=0x7f080007; public static final int SYM=0x7f080008; public static final int action0=0x7f080009; public static final int action_bar=0x7f08000a; public static final int action_bar_activity_content=0x7f08000b; public static final int action_bar_container=0x7f08000c; public static final int action_bar_root=0x7f08000d; public static final int action_bar_spinner=0x7f08000e; public static final int action_bar_subtitle=0x7f08000f; public static final int action_bar_title=0x7f080010; public static final int action_container=0x7f080011; public static final int action_context_bar=0x7f080012; public static final int action_divider=0x7f080013; public static final int action_image=0x7f080014; public static final int action_menu_divider=0x7f080015; public static final int action_menu_presenter=0x7f080016; public static final int action_mode_bar=0x7f080017; public static final int action_mode_bar_stub=0x7f080018; public static final int action_mode_close_button=0x7f080019; public static final int action_text=0x7f08001a; public static final int actions=0x7f08001b; public static final int activity_chooser_view_content=0x7f08001c; public static final int add=0x7f08001d; public static final int adjust_height=0x7f08001e; public static final int adjust_width=0x7f08001f; public static final int alertTitle=0x7f080020; public static final int all=0x7f080021; public static final int always=0x7f080022; public static final int async=0x7f080023; public static final int auto=0x7f080024; public static final int back=0x7f080025; public static final int basic=0x7f080026; public static final int beginning=0x7f080027; public static final int blocking=0x7f080028; public static final int bottom=0x7f080029; public static final int buttonPanel=0x7f08002a; public static final int cancel_action=0x7f08002b; public static final int cardView=0x7f08002c; public static final int center=0x7f08002d; public static final int center_horizontal=0x7f08002e; public static final int center_vertical=0x7f08002f; public static final int chains=0x7f080030; public static final int checkbox=0x7f080031; public static final int chronometer=0x7f080032; public static final int clip_horizontal=0x7f080033; public static final int clip_vertical=0x7f080034; public static final int collapseActionView=0x7f080035; public static final int confirm=0x7f080036; public static final int container=0x7f080037; public static final int contentPanel=0x7f080038; public static final int coordinator=0x7f080039; public static final int custom=0x7f08003a; public static final int customPanel=0x7f08003b; public static final int dark=0x7f08003c; public static final int decor_content_parent=0x7f08003d; public static final int default_activity_button=0x7f08003e; public static final int design_bottom_sheet=0x7f08003f; public static final int design_menu_item_action_area=0x7f080040; public static final int design_menu_item_action_area_stub=0x7f080041; public static final int design_menu_item_text=0x7f080042; public static final int design_navigation_view=0x7f080043; public static final int disableHome=0x7f080044; public static final int edit_query=0x7f080045; public static final int email=0x7f080046; public static final int end=0x7f080047; public static final int end_padder=0x7f080048; public static final int enterAlways=0x7f080049; public static final int enterAlwaysCollapsed=0x7f08004a; public static final int exitUntilCollapsed=0x7f08004b; public static final int expand_activities_button=0x7f08004c; public static final int expanded_menu=0x7f08004d; public static final int fill=0x7f08004e; public static final int fill_horizontal=0x7f08004f; public static final int fill_vertical=0x7f080050; public static final int fixed=0x7f080051; public static final int forever=0x7f080052; public static final int frame=0x7f080053; public static final int ghost_view=0x7f080054; public static final int home=0x7f080055; public static final int homeAsUp=0x7f080056; public static final int icon=0x7f080057; public static final int icon_group=0x7f080058; public static final int icon_only=0x7f080059; public static final int ifRoom=0x7f08005a; public static final int image=0x7f08005b; public static final int info=0x7f08005c; public static final int italic=0x7f08005d; public static final int item_touch_helper_previous_elevation=0x7f08005e; public static final int largeLabel=0x7f08005f; public static final int left=0x7f080060; public static final int light=0x7f080061; public static final int line1=0x7f080062; public static final int line3=0x7f080063; public static final int listMode=0x7f080064; public static final int list_item=0x7f080065; public static final int login=0x7f080066; public static final int masked=0x7f080067; public static final int media_actions=0x7f080068; public static final int message=0x7f080069; public static final int middle=0x7f08006a; public static final int mini=0x7f08006b; public static final int multiply=0x7f08006c; public static final int name=0x7f08006d; public static final int navigation_header_container=0x7f08006e; public static final int never=0x7f08006f; public static final int none=0x7f080070; public static final int normal=0x7f080071; public static final int notification_background=0x7f080072; public static final int notification_main_column=0x7f080073; public static final int notification_main_column_container=0x7f080074; public static final int packed=0x7f080075; public static final int parallax=0x7f080076; public static final int parent=0x7f080077; public static final int parentPanel=0x7f080078; public static final int parent_matrix=0x7f080079; public static final int password=0x7f08007a; public static final int phone=0x7f08007b; public static final int pin=0x7f08007c; public static final int profileImage=0x7f08007d; public static final int progress_circular=0x7f08007e; public static final int progress_horizontal=0x7f08007f; public static final int radio=0x7f080080; public static final int radioGroup=0x7f080081; public static final int recyclerView=0x7f080082; public static final int register=0x7f080083; public static final int right=0x7f080084; public static final int right_icon=0x7f080085; public static final int right_side=0x7f080086; public static final int save_image_matrix=0x7f080087; public static final int save_non_transition_alpha=0x7f080088; public static final int save_scale_type=0x7f080089; public static final int screen=0x7f08008a; public static final int scroll=0x7f08008b; public static final int scrollIndicatorDown=0x7f08008c; public static final int scrollIndicatorUp=0x7f08008d; public static final int scrollView=0x7f08008e; public static final int scrollable=0x7f08008f; public static final int search_badge=0x7f080090; public static final int search_bar=0x7f080091; public static final int search_button=0x7f080092; public static final int search_close_btn=0x7f080093; public static final int search_edit_frame=0x7f080094; public static final int search_go_btn=0x7f080095; public static final int search_mag_icon=0x7f080096; public static final int search_plate=0x7f080097; public static final int search_src_text=0x7f080098; public static final int search_voice_btn=0x7f080099; public static final int select_dialog_listview=0x7f08009a; public static final int send=0x7f08009b; public static final int sendLayout=0x7f08009c; public static final int shortcut=0x7f08009d; public static final int showCustom=0x7f08009e; public static final int showHome=0x7f08009f; public static final int showTitle=0x7f0800a0; public static final int smallLabel=0x7f0800a1; public static final int snackbar_action=0x7f0800a2; public static final int snackbar_text=0x7f0800a3; public static final int snap=0x7f0800a4; public static final int spacer=0x7f0800a5; public static final int split_action_bar=0x7f0800a6; public static final int spread=0x7f0800a7; public static final int spread_inside=0x7f0800a8; public static final int src_atop=0x7f0800a9; public static final int src_in=0x7f0800aa; public static final int src_over=0x7f0800ab; public static final int standard=0x7f0800ac; public static final int start=0x7f0800ad; public static final int status_bar_latest_event_content=0x7f0800ae; public static final int submenuarrow=0x7f0800af; public static final int submit_area=0x7f0800b0; public static final int tabMode=0x7f0800b1; public static final int text=0x7f0800b2; public static final int text2=0x7f0800b3; public static final int textSpacerNoButtons=0x7f0800b4; public static final int textSpacerNoTitle=0x7f0800b5; public static final int text_input_password_toggle=0x7f0800b6; public static final int textinput_counter=0x7f0800b7; public static final int textinput_error=0x7f0800b8; public static final int time=0x7f0800b9; public static final int title=0x7f0800ba; public static final int titleDividerNoCustom=0x7f0800bb; public static final int title_template=0x7f0800bc; public static final int top=0x7f0800bd; public static final int topPanel=0x7f0800be; public static final int touch_outside=0x7f0800bf; public static final int transition_current_scene=0x7f0800c0; public static final int transition_layout_save=0x7f0800c1; public static final int transition_position=0x7f0800c2; public static final int transition_scene_layoutid_cache=0x7f0800c3; public static final int transition_transform=0x7f0800c4; public static final int uniform=0x7f0800c5; public static final int up=0x7f0800c6; public static final int useLogo=0x7f0800c7; public static final int view_offset_helper=0x7f0800c8; public static final int visible=0x7f0800c9; public static final int wide=0x7f0800ca; public static final int withText=0x7f0800cb; public static final int wrap=0x7f0800cc; public static final int wrap_content=0x7f0800cd; } public static final class integer { public static final int abc_config_activityDefaultDur=0x7f090000; public static final int abc_config_activityShortDur=0x7f090001; public static final int app_bar_elevation_anim_duration=0x7f090002; public static final int bottom_sheet_slide_duration=0x7f090003; public static final int cancel_button_image_alpha=0x7f090004; public static final int config_tooltipAnimTime=0x7f090005; public static final int design_snackbar_text_max_lines=0x7f090006; public static final int google_play_services_version=0x7f090007; public static final int hide_password_duration=0x7f090008; public static final int show_password_duration=0x7f090009; public static final int status_bar_notification_info_maxnum=0x7f09000a; } public static final class layout { public static final int abc_action_bar_title_item=0x7f0a0000; public static final int abc_action_bar_up_container=0x7f0a0001; public static final int abc_action_bar_view_list_nav_layout=0x7f0a0002; public static final int abc_action_menu_item_layout=0x7f0a0003; public static final int abc_action_menu_layout=0x7f0a0004; public static final int abc_action_mode_bar=0x7f0a0005; public static final int abc_action_mode_close_item_material=0x7f0a0006; public static final int abc_activity_chooser_view=0x7f0a0007; public static final int abc_activity_chooser_view_list_item=0x7f0a0008; public static final int abc_alert_dialog_button_bar_material=0x7f0a0009; public static final int abc_alert_dialog_material=0x7f0a000a; public static final int abc_alert_dialog_title_material=0x7f0a000b; public static final int abc_dialog_title_material=0x7f0a000c; public static final int abc_expanded_menu_layout=0x7f0a000d; public static final int abc_list_menu_item_checkbox=0x7f0a000e; public static final int abc_list_menu_item_icon=0x7f0a000f; public static final int abc_list_menu_item_layout=0x7f0a0010; public static final int abc_list_menu_item_radio=0x7f0a0011; public static final int abc_popup_menu_header_item_layout=0x7f0a0012; public static final int abc_popup_menu_item_layout=0x7f0a0013; public static final int abc_screen_content_include=0x7f0a0014; public static final int abc_screen_simple=0x7f0a0015; public static final int abc_screen_simple_overlay_action_mode=0x7f0a0016; public static final int abc_screen_toolbar=0x7f0a0017; public static final int abc_search_dropdown_item_icons_2line=0x7f0a0018; public static final int abc_search_view=0x7f0a0019; public static final int abc_select_dialog_material=0x7f0a001a; public static final int activity_chat=0x7f0a001b; public static final int activity_choose_login_registration=0x7f0a001c; public static final int activity_login=0x7f0a001d; public static final int activity_main=0x7f0a001e; public static final int activity_matches=0x7f0a001f; public static final int activity_registration=0x7f0a0020; public static final int activity_settings=0x7f0a0021; public static final int design_bottom_navigation_item=0x7f0a0022; public static final int design_bottom_sheet_dialog=0x7f0a0023; public static final int design_layout_snackbar=0x7f0a0024; public static final int design_layout_snackbar_include=0x7f0a0025; public static final int design_layout_tab_icon=0x7f0a0026; public static final int design_layout_tab_text=0x7f0a0027; public static final int design_menu_item_action_area=0x7f0a0028; public static final int design_navigation_item=0x7f0a0029; public static final int design_navigation_item_header=0x7f0a002a; public static final int design_navigation_item_separator=0x7f0a002b; public static final int design_navigation_item_subheader=0x7f0a002c; public static final int design_navigation_menu=0x7f0a002d; public static final int design_navigation_menu_item=0x7f0a002e; public static final int design_text_input_password_icon=0x7f0a002f; public static final int item=0x7f0a0030; public static final int item_chat=0x7f0a0031; public static final int item_matches=0x7f0a0032; public static final int notification_action=0x7f0a0033; public static final int notification_action_tombstone=0x7f0a0034; public static final int notification_media_action=0x7f0a0035; public static final int notification_media_cancel_action=0x7f0a0036; public static final int notification_template_big_media=0x7f0a0037; public static final int notification_template_big_media_custom=0x7f0a0038; public static final int notification_template_big_media_narrow=0x7f0a0039; public static final int notification_template_big_media_narrow_custom=0x7f0a003a; public static final int notification_template_custom_big=0x7f0a003b; public static final int notification_template_icon_group=0x7f0a003c; public static final int notification_template_lines_media=0x7f0a003d; public static final int notification_template_media=0x7f0a003e; public static final int notification_template_media_custom=0x7f0a003f; public static final int notification_template_part_chronometer=0x7f0a0040; public static final int notification_template_part_time=0x7f0a0041; public static final int select_dialog_item_material=0x7f0a0042; public static final int select_dialog_multichoice_material=0x7f0a0043; public static final int select_dialog_singlechoice_material=0x7f0a0044; public static final int support_simple_spinner_dropdown_item=0x7f0a0045; public static final int tooltip=0x7f0a0046; } public static final class mipmap { public static final int ic_launcher=0x7f0b0000; public static final int ic_launcher_round=0x7f0b0001; public static final int study_buddy_launcher=0x7f0b0002; public static final int study_buddy_launcher_foreground=0x7f0b0003; public static final int study_buddy_launcher_round=0x7f0b0004; } public static final class string { public static final int abc_action_bar_home_description=0x7f0c0000; public static final int abc_action_bar_home_description_format=0x7f0c0001; public static final int abc_action_bar_home_subtitle_description_format=0x7f0c0002; public static final int abc_action_bar_up_description=0x7f0c0003; public static final int abc_action_menu_overflow_description=0x7f0c0004; public static final int abc_action_mode_done=0x7f0c0005; public static final int abc_activity_chooser_view_see_all=0x7f0c0006; public static final int abc_activitychooserview_choose_application=0x7f0c0007; public static final int abc_capital_off=0x7f0c0008; public static final int abc_capital_on=0x7f0c0009; public static final int abc_font_family_body_1_material=0x7f0c000a; public static final int abc_font_family_body_2_material=0x7f0c000b; public static final int abc_font_family_button_material=0x7f0c000c; public static final int abc_font_family_caption_material=0x7f0c000d; public static final int abc_font_family_display_1_material=0x7f0c000e; public static final int abc_font_family_display_2_material=0x7f0c000f; public static final int abc_font_family_display_3_material=0x7f0c0010; public static final int abc_font_family_display_4_material=0x7f0c0011; public static final int abc_font_family_headline_material=0x7f0c0012; public static final int abc_font_family_menu_material=0x7f0c0013; public static final int abc_font_family_subhead_material=0x7f0c0014; public static final int abc_font_family_title_material=0x7f0c0015; public static final int abc_search_hint=0x7f0c0016; public static final int abc_searchview_description_clear=0x7f0c0017; public static final int abc_searchview_description_query=0x7f0c0018; public static final int abc_searchview_description_search=0x7f0c0019; public static final int abc_searchview_description_submit=0x7f0c001a; public static final int abc_searchview_description_voice=0x7f0c001b; public static final int abc_shareactionprovider_share_with=0x7f0c001c; public static final int abc_shareactionprovider_share_with_application=0x7f0c001d; public static final int abc_toolbar_collapse_description=0x7f0c001e; public static final int app_name=0x7f0c001f; public static final int appbar_scrolling_view_behavior=0x7f0c0020; public static final int bottom_sheet_behavior=0x7f0c0021; public static final int character_counter_pattern=0x7f0c0022; public static final int common_google_play_services_enable_button=0x7f0c0023; public static final int common_google_play_services_enable_text=0x7f0c0024; public static final int common_google_play_services_enable_title=0x7f0c0025; public static final int common_google_play_services_install_button=0x7f0c0026; public static final int common_google_play_services_install_text=0x7f0c0027; public static final int common_google_play_services_install_title=0x7f0c0028; public static final int common_google_play_services_notification_channel_name=0x7f0c0029; public static final int common_google_play_services_notification_ticker=0x7f0c002a; public static final int common_google_play_services_unknown_issue=0x7f0c002b; public static final int common_google_play_services_unsupported_text=0x7f0c002c; public static final int common_google_play_services_update_button=0x7f0c002d; public static final int common_google_play_services_update_text=0x7f0c002e; public static final int common_google_play_services_update_title=0x7f0c002f; public static final int common_google_play_services_updating_text=0x7f0c0030; public static final int common_google_play_services_wear_update_text=0x7f0c0031; public static final int common_open_on_phone=0x7f0c0032; public static final int common_signin_button_text=0x7f0c0033; public static final int common_signin_button_text_long=0x7f0c0034; public static final int default_web_client_id=0x7f0c0035; public static final int firebase_database_url=0x7f0c0036; public static final int gcm_defaultSenderId=0x7f0c0037; public static final int google_api_key=0x7f0c0038; public static final int google_app_id=0x7f0c0039; public static final int google_crash_reporting_api_key=0x7f0c003a; public static final int google_storage_bucket=0x7f0c003b; public static final int password_toggle_content_description=0x7f0c003c; public static final int path_password_eye=0x7f0c003d; public static final int path_password_eye_mask_strike_through=0x7f0c003e; public static final int path_password_eye_mask_visible=0x7f0c003f; public static final int path_password_strike_through=0x7f0c0040; public static final int project_id=0x7f0c0041; public static final int search_menu_title=0x7f0c0042; public static final int status_bar_notification_info_overflow=0x7f0c0043; } public static final class style { public static final int AlertDialog_AppCompat=0x7f0d0000; public static final int AlertDialog_AppCompat_Light=0x7f0d0001; public static final int Animation_AppCompat_Dialog=0x7f0d0002; public static final int Animation_AppCompat_DropDownUp=0x7f0d0003; public static final int Animation_AppCompat_Tooltip=0x7f0d0004; public static final int Animation_Design_BottomSheetDialog=0x7f0d0005; public static final int AppTheme=0x7f0d0006; public static final int Base_AlertDialog_AppCompat=0x7f0d0007; public static final int Base_AlertDialog_AppCompat_Light=0x7f0d0008; public static final int Base_Animation_AppCompat_Dialog=0x7f0d0009; public static final int Base_Animation_AppCompat_DropDownUp=0x7f0d000a; public static final int Base_Animation_AppCompat_Tooltip=0x7f0d000b; public static final int Base_CardView=0x7f0d000c; public static final int Base_DialogWindowTitle_AppCompat=0x7f0d000d; public static final int Base_DialogWindowTitleBackground_AppCompat=0x7f0d000e; public static final int Base_TextAppearance_AppCompat=0x7f0d000f; public static final int Base_TextAppearance_AppCompat_Body1=0x7f0d0010; public static final int Base_TextAppearance_AppCompat_Body2=0x7f0d0011; public static final int Base_TextAppearance_AppCompat_Button=0x7f0d0012; public static final int Base_TextAppearance_AppCompat_Caption=0x7f0d0013; public static final int Base_TextAppearance_AppCompat_Display1=0x7f0d0014; public static final int Base_TextAppearance_AppCompat_Display2=0x7f0d0015; public static final int Base_TextAppearance_AppCompat_Display3=0x7f0d0016; public static final int Base_TextAppearance_AppCompat_Display4=0x7f0d0017; public static final int Base_TextAppearance_AppCompat_Headline=0x7f0d0018; public static final int Base_TextAppearance_AppCompat_Inverse=0x7f0d0019; public static final int Base_TextAppearance_AppCompat_Large=0x7f0d001a; public static final int Base_TextAppearance_AppCompat_Large_Inverse=0x7f0d001b; public static final int Base_TextAppearance_AppCompat_Light_Widget_PopupMenu_Large=0x7f0d001c; public static final int Base_TextAppearance_AppCompat_Light_Widget_PopupMenu_Small=0x7f0d001d; public static final int Base_TextAppearance_AppCompat_Medium=0x7f0d001e; public static final int Base_TextAppearance_AppCompat_Medium_Inverse=0x7f0d001f; public static final int Base_TextAppearance_AppCompat_Menu=0x7f0d0020; public static final int Base_TextAppearance_AppCompat_SearchResult=0x7f0d0021; public static final int Base_TextAppearance_AppCompat_SearchResult_Subtitle=0x7f0d0022; public static final int Base_TextAppearance_AppCompat_SearchResult_Title=0x7f0d0023; public static final int Base_TextAppearance_AppCompat_Small=0x7f0d0024; public static final int Base_TextAppearance_AppCompat_Small_Inverse=0x7f0d0025; public static final int Base_TextAppearance_AppCompat_Subhead=0x7f0d0026; public static final int Base_TextAppearance_AppCompat_Subhead_Inverse=0x7f0d0027; public static final int Base_TextAppearance_AppCompat_Title=0x7f0d0028; public static final int Base_TextAppearance_AppCompat_Title_Inverse=0x7f0d0029; public static final int Base_TextAppearance_AppCompat_Tooltip=0x7f0d002a; public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Menu=0x7f0d002b; public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Subtitle=0x7f0d002c; public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Subtitle_Inverse=0x7f0d002d; public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Title=0x7f0d002e; public static final int Base_TextAppearance_AppCompat_Widget_ActionBar_Title_Inverse=0x7f0d002f; public static final int Base_TextAppearance_AppCompat_Widget_ActionMode_Subtitle=0x7f0d0030; public static final int Base_TextAppearance_AppCompat_Widget_ActionMode_Title=0x7f0d0031; public static final int Base_TextAppearance_AppCompat_Widget_Button=0x7f0d0032; public static final int Base_TextAppearance_AppCompat_Widget_Button_Borderless_Colored=0x7f0d0033; public static final int Base_TextAppearance_AppCompat_Widget_Button_Colored=0x7f0d0034; public static final int Base_TextAppearance_AppCompat_Widget_Button_Inverse=0x7f0d0035; public static final int Base_TextAppearance_AppCompat_Widget_DropDownItem=0x7f0d0036; public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Header=0x7f0d0037; public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Large=0x7f0d0038; public static final int Base_TextAppearance_AppCompat_Widget_PopupMenu_Small=0x7f0d0039; public static final int Base_TextAppearance_AppCompat_Widget_Switch=0x7f0d003a; public static final int Base_TextAppearance_AppCompat_Widget_TextView_SpinnerItem=0x7f0d003b; public static final int Base_TextAppearance_Widget_AppCompat_ExpandedMenu_Item=0x7f0d003c; public static final int Base_TextAppearance_Widget_AppCompat_Toolbar_Subtitle=0x7f0d003d; public static final int Base_TextAppearance_Widget_AppCompat_Toolbar_Title=0x7f0d003e; public static final int Base_Theme_AppCompat=0x7f0d003f; public static final int Base_Theme_AppCompat_CompactMenu=0x7f0d0040; public static final int Base_Theme_AppCompat_Dialog=0x7f0d0041; public static final int Base_Theme_AppCompat_Dialog_Alert=0x7f0d0042; public static final int Base_Theme_AppCompat_Dialog_FixedSize=0x7f0d0043; public static final int Base_Theme_AppCompat_Dialog_MinWidth=0x7f0d0044; public static final int Base_Theme_AppCompat_DialogWhenLarge=0x7f0d0045; public static final int Base_Theme_AppCompat_Light=0x7f0d0046; public static final int Base_Theme_AppCompat_Light_DarkActionBar=0x7f0d0047; public static final int Base_Theme_AppCompat_Light_Dialog=0x7f0d0048; public static final int Base_Theme_AppCompat_Light_Dialog_Alert=0x7f0d0049; public static final int Base_Theme_AppCompat_Light_Dialog_FixedSize=0x7f0d004a; public static final int Base_Theme_AppCompat_Light_Dialog_MinWidth=0x7f0d004b; public static final int Base_Theme_AppCompat_Light_DialogWhenLarge=0x7f0d004c; public static final int Base_ThemeOverlay_AppCompat=0x7f0d004d; public static final int Base_ThemeOverlay_AppCompat_ActionBar=0x7f0d004e; public static final int Base_ThemeOverlay_AppCompat_Dark=0x7f0d004f; public static final int Base_ThemeOverlay_AppCompat_Dark_ActionBar=0x7f0d0050; public static final int Base_ThemeOverlay_AppCompat_Dialog=0x7f0d0051; public static final int Base_ThemeOverlay_AppCompat_Dialog_Alert=0x7f0d0052; public static final int Base_ThemeOverlay_AppCompat_Light=0x7f0d0053; public static final int Base_V11_Theme_AppCompat_Dialog=0x7f0d0054; public static final int Base_V11_Theme_AppCompat_Light_Dialog=0x7f0d0055; public static final int Base_V11_ThemeOverlay_AppCompat_Dialog=0x7f0d0056; public static final int Base_V12_Widget_AppCompat_AutoCompleteTextView=0x7f0d0057; public static final int Base_V12_Widget_AppCompat_EditText=0x7f0d0058; public static final int Base_V14_Widget_Design_AppBarLayout=0x7f0d0059; public static final int Base_V21_Theme_AppCompat=0x7f0d005a; public static final int Base_V21_Theme_AppCompat_Dialog=0x7f0d005b; public static final int Base_V21_Theme_AppCompat_Light=0x7f0d005c; public static final int Base_V21_Theme_AppCompat_Light_Dialog=0x7f0d005d; public static final int Base_V21_ThemeOverlay_AppCompat_Dialog=0x7f0d005e; public static final int Base_V21_Widget_Design_AppBarLayout=0x7f0d005f; public static final int Base_V22_Theme_AppCompat=0x7f0d0060; public static final int Base_V22_Theme_AppCompat_Light=0x7f0d0061; public static final int Base_V23_Theme_AppCompat=0x7f0d0062; public static final int Base_V23_Theme_AppCompat_Light=0x7f0d0063; public static final int Base_V26_Theme_AppCompat=0x7f0d0064; public static final int Base_V26_Theme_AppCompat_Light=0x7f0d0065; public static final int Base_V26_Widget_AppCompat_Toolbar=0x7f0d0066; public static final int Base_V26_Widget_Design_AppBarLayout=0x7f0d0067; public static final int Base_V7_Theme_AppCompat=0x7f0d0068; public static final int Base_V7_Theme_AppCompat_Dialog=0x7f0d0069; public static final int Base_V7_Theme_AppCompat_Light=0x7f0d006a; public static final int Base_V7_Theme_AppCompat_Light_Dialog=0x7f0d006b; public static final int Base_V7_ThemeOverlay_AppCompat_Dialog=0x7f0d006c; public static final int Base_V7_Widget_AppCompat_AutoCompleteTextView=0x7f0d006d; public static final int Base_V7_Widget_AppCompat_EditText=0x7f0d006e; public static final int Base_V7_Widget_AppCompat_Toolbar=0x7f0d006f; public static final int Base_Widget_AppCompat_ActionBar=0x7f0d0070; public static final int Base_Widget_AppCompat_ActionBar_Solid=0x7f0d0071; public static final int Base_Widget_AppCompat_ActionBar_TabBar=0x7f0d0072; public static final int Base_Widget_AppCompat_ActionBar_TabText=0x7f0d0073; public static final int Base_Widget_AppCompat_ActionBar_TabView=0x7f0d0074; public static final int Base_Widget_AppCompat_ActionButton=0x7f0d0075; public static final int Base_Widget_AppCompat_ActionButton_CloseMode=0x7f0d0076; public static final int Base_Widget_AppCompat_ActionButton_Overflow=0x7f0d0077; public static final int Base_Widget_AppCompat_ActionMode=0x7f0d0078; public static final int Base_Widget_AppCompat_ActivityChooserView=0x7f0d0079; public static final int Base_Widget_AppCompat_AutoCompleteTextView=0x7f0d007a; public static final int Base_Widget_AppCompat_Button=0x7f0d007b; public static final int Base_Widget_AppCompat_Button_Borderless=0x7f0d007c; public static final int Base_Widget_AppCompat_Button_Borderless_Colored=0x7f0d007d; public static final int Base_Widget_AppCompat_Button_ButtonBar_AlertDialog=0x7f0d007e; public static final int Base_Widget_AppCompat_Button_Colored=0x7f0d007f; public static final int Base_Widget_AppCompat_Button_Small=0x7f0d0080; public static final int Base_Widget_AppCompat_ButtonBar=0x7f0d0081; public static final int Base_Widget_AppCompat_ButtonBar_AlertDialog=0x7f0d0082; public static final int Base_Widget_AppCompat_CompoundButton_CheckBox=0x7f0d0083; public static final int Base_Widget_AppCompat_CompoundButton_RadioButton=0x7f0d0084; public static final int Base_Widget_AppCompat_CompoundButton_Switch=0x7f0d0085; public static final int Base_Widget_AppCompat_DrawerArrowToggle=0x7f0d0086; public static final int Base_Widget_AppCompat_DrawerArrowToggle_Common=0x7f0d0087; public static final int Base_Widget_AppCompat_DropDownItem_Spinner=0x7f0d0088; public static final int Base_Widget_AppCompat_EditText=0x7f0d0089; public static final int Base_Widget_AppCompat_ImageButton=0x7f0d008a; public static final int Base_Widget_AppCompat_Light_ActionBar=0x7f0d008b; public static final int Base_Widget_AppCompat_Light_ActionBar_Solid=0x7f0d008c; public static final int Base_Widget_AppCompat_Light_ActionBar_TabBar=0x7f0d008d; public static final int Base_Widget_AppCompat_Light_ActionBar_TabText=0x7f0d008e; public static final int Base_Widget_AppCompat_Light_ActionBar_TabText_Inverse=0x7f0d008f; public static final int Base_Widget_AppCompat_Light_ActionBar_TabView=0x7f0d0090; public static final int Base_Widget_AppCompat_Light_PopupMenu=0x7f0d0091; public static final int Base_Widget_AppCompat_Light_PopupMenu_Overflow=0x7f0d0092; public static final int Base_Widget_AppCompat_ListMenuView=0x7f0d0093; public static final int Base_Widget_AppCompat_ListPopupWindow=0x7f0d0094; public static final int Base_Widget_AppCompat_ListView=0x7f0d0095; public static final int Base_Widget_AppCompat_ListView_DropDown=0x7f0d0096; public static final int Base_Widget_AppCompat_ListView_Menu=0x7f0d0097; public static final int Base_Widget_AppCompat_PopupMenu=0x7f0d0098; public static final int Base_Widget_AppCompat_PopupMenu_Overflow=0x7f0d0099; public static final int Base_Widget_AppCompat_PopupWindow=0x7f0d009a; public static final int Base_Widget_AppCompat_ProgressBar=0x7f0d009b; public static final int Base_Widget_AppCompat_ProgressBar_Horizontal=0x7f0d009c; public static final int Base_Widget_AppCompat_RatingBar=0x7f0d009d; public static final int Base_Widget_AppCompat_RatingBar_Indicator=0x7f0d009e; public static final int Base_Widget_AppCompat_RatingBar_Small=0x7f0d009f; public static final int Base_Widget_AppCompat_SearchView=0x7f0d00a0; public static final int Base_Widget_AppCompat_SearchView_ActionBar=0x7f0d00a1; public static final int Base_Widget_AppCompat_SeekBar=0x7f0d00a2; public static final int Base_Widget_AppCompat_SeekBar_Discrete=0x7f0d00a3; public static final int Base_Widget_AppCompat_Spinner=0x7f0d00a4; public static final int Base_Widget_AppCompat_Spinner_Underlined=0x7f0d00a5; public static final int Base_Widget_AppCompat_TextView_SpinnerItem=0x7f0d00a6; public static final int Base_Widget_AppCompat_Toolbar=0x7f0d00a7; public static final int Base_Widget_AppCompat_Toolbar_Button_Navigation=0x7f0d00a8; public static final int Base_Widget_Design_AppBarLayout=0x7f0d00a9; public static final int Base_Widget_Design_TabLayout=0x7f0d00aa; public static final int CardView=0x7f0d00ab; public static final int CardView_Dark=0x7f0d00ac; public static final int CardView_Light=0x7f0d00ad; public static final int Platform_AppCompat=0x7f0d00ae; public static final int Platform_AppCompat_Light=0x7f0d00af; public static final int Platform_ThemeOverlay_AppCompat=0x7f0d00b0; public static final int Platform_ThemeOverlay_AppCompat_Dark=0x7f0d00b1; public static final int Platform_ThemeOverlay_AppCompat_Light=0x7f0d00b2; public static final int Platform_V11_AppCompat=0x7f0d00b3; public static final int Platform_V11_AppCompat_Light=0x7f0d00b4; public static final int Platform_V14_AppCompat=0x7f0d00b5; public static final int Platform_V14_AppCompat_Light=0x7f0d00b6; public static final int Platform_V21_AppCompat=0x7f0d00b7; public static final int Platform_V21_AppCompat_Light=0x7f0d00b8; public static final int Platform_V25_AppCompat=0x7f0d00b9; public static final int Platform_V25_AppCompat_Light=0x7f0d00ba; public static final int Platform_Widget_AppCompat_Spinner=0x7f0d00bb; public static final int RtlOverlay_DialogWindowTitle_AppCompat=0x7f0d00bc; public static final int RtlOverlay_Widget_AppCompat_ActionBar_TitleItem=0x7f0d00bd; public static final int RtlOverlay_Widget_AppCompat_DialogTitle_Icon=0x7f0d00be; public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem=0x7f0d00bf; public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_InternalGroup=0x7f0d00c0; public static final int RtlOverlay_Widget_AppCompat_PopupMenuItem_Text=0x7f0d00c1; public static final int RtlOverlay_Widget_AppCompat_Search_DropDown=0x7f0d00c2; public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Icon1=0x7f0d00c3; public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Icon2=0x7f0d00c4; public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Query=0x7f0d00c5; public static final int RtlOverlay_Widget_AppCompat_Search_DropDown_Text=0x7f0d00c6; public static final int RtlOverlay_Widget_AppCompat_SearchView_MagIcon=0x7f0d00c7; public static final int RtlUnderlay_Widget_AppCompat_ActionButton=0x7f0d00c8; public static final int RtlUnderlay_Widget_AppCompat_ActionButton_Overflow=0x7f0d00c9; public static final int SwipeFling=0x7f0d00ca; public static final int TextAppearance_AppCompat=0x7f0d00cb; public static final int TextAppearance_AppCompat_Body1=0x7f0d00cc; public static final int TextAppearance_AppCompat_Body2=0x7f0d00cd; public static final int TextAppearance_AppCompat_Button=0x7f0d00ce; public static final int TextAppearance_AppCompat_Caption=0x7f0d00cf; public static final int TextAppearance_AppCompat_Display1=0x7f0d00d0; public static final int TextAppearance_AppCompat_Display2=0x7f0d00d1; public static final int TextAppearance_AppCompat_Display3=0x7f0d00d2; public static final int TextAppearance_AppCompat_Display4=0x7f0d00d3; public static final int TextAppearance_AppCompat_Headline=0x7f0d00d4; public static final int TextAppearance_AppCompat_Inverse=0x7f0d00d5; public static final int TextAppearance_AppCompat_Large=0x7f0d00d6; public static final int TextAppearance_AppCompat_Large_Inverse=0x7f0d00d7; public static final int TextAppearance_AppCompat_Light_SearchResult_Subtitle=0x7f0d00d8; public static final int TextAppearance_AppCompat_Light_SearchResult_Title=0x7f0d00d9; public static final int TextAppearance_AppCompat_Light_Widget_PopupMenu_Large=0x7f0d00da; public static final int TextAppearance_AppCompat_Light_Widget_PopupMenu_Small=0x7f0d00db;
5,853
https://github.com/peacetrue/peacetrue-task/blob/master/peacetrue-task-service-api/src/main/java/com/github/peacetrue/task/service/TaskGetDTO.java
Github Open Source
Open Source
Apache-2.0
2,020
peacetrue-task
peacetrue
Java
Code
28
97
package com.github.peacetrue.task.service; import lombok.AllArgsConstructor; import lombok.Data; import lombok.NoArgsConstructor; import java.io.Serializable; /** * @author xiayx */ @Data @NoArgsConstructor @AllArgsConstructor public class TaskGetDTO<T> implements Serializable { private T id; }
4,836
https://github.com/mirage/ocaml-tuntap/blob/master/test/set_ipv4_test.ml
Github Open Source
Open Source
ISC
2,023
ocaml-tuntap
mirage
OCaml
Code
111
445
open Tuntap open OUnit2 open Ipaddr let test_setipv4 ipv4 netmask _ctx = let ipv4 = V4.of_string_exn ipv4 in let netmask = V4.Prefix.make netmask ipv4 in let fd, devname = opentap ~devname:"tap0" () in set_ipv4 ~netmask devname ipv4; let iface_addr = List.hd @@ v4_of_ifname devname in assert_equal ~msg:(Printf.sprintf "%s %s" (V4.to_string ipv4) (V4.Prefix.to_string netmask)) ~printer:(fun cidr -> Printf.sprintf "%s" (V4.Prefix.to_string cidr)) netmask iface_addr; Unix.close fd let suite = "Test IPv4" >::: ["test_classA" >:: test_setipv4 "10.0.0.1" 8; "test_classB" >:: test_setipv4 "172.16.0.1" 16; "test_classC" >:: test_setipv4 "192.168.0.1" 24; "test_wrongclassA" >:: test_setipv4 "10.11.12.1" 24; "test_wrongclassB" >:: test_setipv4 "172.16.0.1" 24; "test_wrongclassC" >:: test_setipv4 "192.168.1.2" 8; "test_noclass" >:: test_setipv4 "192.168.1.2" 23; ] let _ = run_test_tt_main suite
1,073
https://github.com/xunzhaotech/jerry-serv/blob/master/.nuxt/router.js
Github Open Source
Open Source
MIT
2,019
jerry-serv
xunzhaotech
JavaScript
Code
801
2,818
import Vue from 'vue' import Router from 'vue-router' Vue.use(Router) const _665b254c = () => import('../pages/login.vue' /* webpackChunkName: "pages/login" */).then(m => m.default || m) const _dcebdd8e = () => import('../pages/system/auth.vue' /* webpackChunkName: "pages/system/auth" */).then(m => m.default || m) const _44dcfc40 = () => import('../pages/error-page/error-page.vue' /* webpackChunkName: "pages/error-page/error-page" */).then(m => m.default || m) const _03639646 = () => import('../pages/topic/list.vue' /* webpackChunkName: "pages/topic/list" */).then(m => m.default || m) const _7ce750c8 = () => import('../pages/form/preview.vue' /* webpackChunkName: "pages/form/preview" */).then(m => m.default || m) const _2c479d07 = () => import('../pages/system/role.vue' /* webpackChunkName: "pages/system/role" */).then(m => m.default || m) const _014ae23f = () => import('../pages/extended/swiper.vue' /* webpackChunkName: "pages/extended/swiper" */).then(m => m.default || m) const _023ad900 = () => import('../pages/tables/editable-table.vue' /* webpackChunkName: "pages/tables/editable-table" */).then(m => m.default || m) const _e093405c = () => import('../pages/article/type.vue' /* webpackChunkName: "pages/article/type" */).then(m => m.default || m) const _2c4955dc = () => import('../pages/system/user.vue' /* webpackChunkName: "pages/system/user" */).then(m => m.default || m) const _e8eb059e = () => import('../pages/article/tags.vue' /* webpackChunkName: "pages/article/tags" */).then(m => m.default || m) const _40d3db84 = () => import('../pages/form/work-flow.vue' /* webpackChunkName: "pages/form/work-flow" */).then(m => m.default || m) const _5dfe7132 = () => import('../pages/topic/add.vue' /* webpackChunkName: "pages/topic/add" */).then(m => m.default || m) const _e010cd0e = () => import('../pages/error-page/500.vue' /* webpackChunkName: "pages/error-page/500" */).then(m => m.default || m) const _178356a2 = () => import('../pages/article/edit.vue' /* webpackChunkName: "pages/article/edit" */).then(m => m.default || m) const _670fe355 = () => import('../pages/release/info.vue' /* webpackChunkName: "pages/release/info" */).then(m => m.default || m) const _5b3ba4bb = () => import('../pages/error-page/403.vue' /* webpackChunkName: "pages/error-page/403" */).then(m => m.default || m) const _5b49bc3c = () => import('../pages/error-page/404.vue' /* webpackChunkName: "pages/error-page/404" */).then(m => m.default || m) const _787ef56c = () => import('../pages/extended/nav.vue' /* webpackChunkName: "pages/extended/nav" */).then(m => m.default || m) const _dbc5087a = () => import('../pages/system/log.vue' /* webpackChunkName: "pages/system/log" */).then(m => m.default || m) const _dd878c94 = () => import('../pages/release/activity.vue' /* webpackChunkName: "pages/release/activity" */).then(m => m.default || m) const _0d965c49 = () => import('../pages/topic/edit.vue' /* webpackChunkName: "pages/topic/edit" */).then(m => m.default || m) const _083b2f36 = () => import('../pages/article/list.vue' /* webpackChunkName: "pages/article/list" */).then(m => m.default || m) const _8c25f5b2 = () => import('../pages/article/publish.vue' /* webpackChunkName: "pages/article/publish" */).then(m => m.default || m) const _032aca43 = () => import('../pages/index.vue' /* webpackChunkName: "pages/index" */).then(m => m.default || m) if (process.client) { window.history.scrollRestoration = 'manual' } const scrollBehavior = function (to, from, savedPosition) { // if the returned position is falsy or an empty object, // will retain current scroll position. let position = false // if no children detected if (to.matched.length < 2) { // scroll to the top of the page position = { x: 0, y: 0 } } else if (to.matched.some((r) => r.components.default.options.scrollToTop)) { // if one of the children has scrollToTop option set to true position = { x: 0, y: 0 } } // savedPosition is only available for popstate navigations (back button) if (savedPosition) { position = savedPosition } return new Promise(resolve => { // wait for the out transition to complete (if necessary) window.$nuxt.$once('triggerScroll', () => { // coords will be used if no selector is provided, // or if the selector didn't match any element. if (to.hash) { let hash = to.hash // CSS.escape() is not supported with IE and Edge. if (typeof window.CSS !== 'undefined' && typeof window.CSS.escape !== 'undefined') { hash = '#' + window.CSS.escape(hash.substr(1)) } try { if (document.querySelector(hash)) { // scroll to anchor by returning the selector position = { selector: hash } } } catch (e) { console.warn('Failed to save scroll position. Please add CSS.escape() polyfill (https://github.com/mathiasbynens/CSS.escape).') } } resolve(position) }) }) } export function createRouter () { return new Router({ mode: 'history', base: '/', linkActiveClass: 'nuxt-link-active', linkExactActiveClass: 'nuxt-link-exact-active', scrollBehavior, routes: [ { path: "/login", component: _665b254c, name: "login" }, { path: "/system/auth", component: _dcebdd8e, name: "system-auth" }, { path: "/error-page/error-page", component: _44dcfc40, name: "error-page-error-page" }, { path: "/topic/list", component: _03639646, name: "topic-list" }, { path: "/form/preview", component: _7ce750c8, name: "form-preview" }, { path: "/system/role", component: _2c479d07, name: "system-role" }, { path: "/extended/swiper", component: _014ae23f, name: "extended-swiper" }, { path: "/tables/editable-table", component: _023ad900, name: "tables-editable-table" }, { path: "/article/type", component: _e093405c, name: "article-type" }, { path: "/system/user", component: _2c4955dc, name: "system-user" }, { path: "/article/tags", component: _e8eb059e, name: "article-tags" }, { path: "/form/work-flow", component: _40d3db84, name: "form-work-flow" }, { path: "/topic/add", component: _5dfe7132, name: "topic-add" }, { path: "/error-page/500", component: _e010cd0e, name: "error-page-500" }, { path: "/article/edit", component: _178356a2, name: "article-edit" }, { path: "/release/info", component: _670fe355, name: "release-info" }, { path: "/error-page/403", component: _5b3ba4bb, name: "error-page-403" }, { path: "/error-page/404", component: _5b49bc3c, name: "error-page-404" }, { path: "/extended/nav", component: _787ef56c, name: "extended-nav" }, { path: "/system/log", component: _dbc5087a, name: "system-log" }, { path: "/release/activity", component: _dd878c94, name: "release-activity" }, { path: "/topic/edit", component: _0d965c49, name: "topic-edit" }, { path: "/article/list", component: _083b2f36, name: "article-list" }, { path: "/article/publish", component: _8c25f5b2, name: "article-publish" }, { path: "/", component: _032aca43, name: "index" } ], fallback: false }) }
39,366
https://github.com/absiddique4584/online-shop/blob/master/resources/views/admin/profile/manage.blade.php
Github Open Source
Open Source
MIT
null
online-shop
absiddique4584
PHP
Code
472
2,243
@extends('admin.components.layout') @section('title') Manage Profile | Online Shop @endsection @section('content') @if(auth()->user()->is_admin===0) <div><h1>You Don't Have Excess In This Section</h1> <h4>Only Admin Can Excess and Create,Edit,Delete</h4> </div> @endif @if(auth()->user()->is_admin===1) <div class="content-header"> <!-- leftside content header --> <div class="leftside-content-header"> <ul class="breadcrumbs"> <li><i class="fa fa-home" aria-hidden="true"></i><a href="{{route('home')}}">Dashboard</a></li> <li><a href="{{route('profiles.manage')}}">Profile</a></li> </ul> </div> </div><br/> <!-- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= --> <div class="row animated shake"> <div class="col-sm-10 col-sm-offset-1"> @includeIf('message.message') <br/> <div class="panel b-primary bt-md"> <div class="panel-content"> <br> <!------------------------------------------------> <form style="display: none;" class="form-horizontal create_section" method="POST" action="{{ route('profiles.store') }}" enctype="multipart/form-data"> @csrf <!--------------> <div class="form-group"> <label for="name" class="col-sm-3 control-label">Name</label> <div class="col-sm-9"> <input type="text" class="form-control" id="name" name="name" value="{{ old('name') }}" required placeholder="Profile Name"> </div> </div> <!--------------> <!--------------> <div class="form-group"> <label for="address" class="col-sm-3 control-label">Address</label> <div class="col-sm-9"> <input type="text" class="form-control" id="address" name="address" value="{{ old('address') }}" required placeholder="Permanent Address"> </div> </div> <!--------------> <!--------------> <div class="form-group"> <label for="phone" class="col-sm-3 control-label">Phone</label> <div class="col-sm-9"> <input type="text" class="form-control" id="phone" name="phone" value="{{ old('phone') }}" required placeholder="Phone Number"> </div> </div> <!--------------> <!--------------> <div class="form-group"> <label for="website_address" class="col-sm-3 control-label">Website</label> <div class="col-sm-9"> <input type="text" class="form-control" id="website_address" name="website_address" value="{{ old('website_address') }}" required placeholder="Website Address"> </div> </div> <!--------------> <!--------------> <div class="form-group"> <label for="email" class="col-sm-3 control-label">Email</label> <div class="col-sm-9"> <input type="text" class="form-control" id="email" name="email" value="{{ old('email') }}" required placeholder="Email Address"> </div> </div> <!--------------> <!--------------> <div class="row"> <div class="col-md-12"> <div class="col-md-10"> <div class="form-group"> <label style="margin-left: 40px;" for="image" class="col-sm-3 control-label">Image</label> <input style="display:none; " type="file" class="" id="image" data-id="image" onChange="previewImage(this)" name="image" value="{{ old('image') }}" required > <input type="button" data-id="image" class="btn btn-info fileClick" value="Select Image"/> <br> <a href=""class="image"> <img style="height: 80px; margin-left: 230px; " src="" id="preview_image" alt=""/> </a> </div> </div> <!--------------> <div class="col-md-2"> <button type="submit" class="btn btn-primary">Update Profile</button> </div> </div> </div> <hr> </form> <!------------------------------------------------> <div class="row"> <div class="col-sm-6"><h3>About Yourself</h3></div> <div class="col-md-6 "> <div class="radio radio-custom radio-inline radio-primary pull-right"> <input type="radio" id="create" name="create" value="1"> <label for="create">Create New Profile</label> </div> <br> <div class="radio radio-custom radio-inline radio-danger pull-right" style="margin-right: 7px;"> <input type="radio" id="exit" name="create" value="0"> <label for="exit">Exit From Create</label> </div> </div> </div> <hr style="margin-top: 0;"/> <div class="row"> @foreach($profiles as $row) <div > <b class="col-sm-4 " style="color: deeppink;">NAME :</b> <h5 class="col-sm-8">{{ $row->name }}. <!----------------------------------------> <button type="button" class="" data-toggle="modal" data-target="#primary-modal"><i class="fa fa-pencil-square"></i></button> <!-- Modal --> <div class="modal fade" id="primary-modal" tabindex="-1" role="dialog" aria-labelledby="modal-primary-label"> <div class="modal-dialog" role="document"> <div class="modal-content"> <div class="modal-header state modal-primary"> <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button> <h4 class="modal-title" id="modal-primary-label"><i class="fa fa-user"></i>Edit Name</h4> </div> <div class="modal-body"> <label for="name">Name</label> <input class="name" style="width: 400px;" type="text" data-id ="{{ $row->id }}" id="name" name="name" value="{{$row->name}}"> </div> <div class="modal-footer"> <button type="submit" class="btn btn-primary" >Save</button> </div> </div> </div> </div> <!----------------------------------------> </h5> </div> <div> <b class="col-sm-4" style="color: deeppink;" >ADDRESS :</b> <h5 class="col-sm-8">{{ $row->address }}</h5> </div> <div> <b class="col-sm-4" style="color: deeppink;" >PHONE :</b> <h5 class="col-sm-8">{{ $row->phone }}</h5> </div> <div> <b class="col-sm-4" style="color: deeppink;" >WEBSITE ADDRESS :</b> <h5 class="col-sm-8">{{ $row->website_address }}</h5> </div> <div> <b class="col-sm-4" style="color: deeppink;" >EMAIL :</b> <h5 class="col-sm-8">{{ $row->email }}</h5> </div> <div> <b class="col-sm-4" style="color: deeppink;" >IMAGE :</b> <h5 class="col-sm-8"><img style="width: 170px; height: 170px; border: 1px solid #333333;" src="{{asset('uploads/profile/'.$row->image)}}" alt=""></h5> </div> @endforeach </div> </div> </div> </div> </div> @endif @endsection
1,017
https://github.com/pklazy/flatbuffers/blob/master/tests/MyGame/Example/ArrayStruct.py
Github Open Source
Open Source
Apache-2.0
2,021
flatbuffers
pklazy
Python
Code
420
1,704
# automatically generated by the FlatBuffers compiler, do not modify # namespace: Example import flatbuffers from flatbuffers.compat import import_numpy np = import_numpy() class ArrayStruct(object): __slots__ = ['_tab'] # ArrayStruct def Init(self, buf, pos): self._tab = flatbuffers.table.Table(buf, pos) # ArrayStruct def A(self): return self._tab.Get(flatbuffers.number_types.Float32Flags, self._tab.Pos + flatbuffers.number_types.UOffsetTFlags.py_type(0)) # ArrayStruct def B(self): return [self._tab.Get(flatbuffers.number_types.Int32Flags, self._tab.Pos + flatbuffers.number_types.UOffsetTFlags.py_type(4 + i * 4)) for i in range(15)] # ArrayStruct def BLength(self): o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(4)) if o != 0: return self._tab.VectorLen(o) return 0 # ArrayStruct def BIsNone(self): o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(4)) return o == 0 # ArrayStruct def C(self): return self._tab.Get(flatbuffers.number_types.Int8Flags, self._tab.Pos + flatbuffers.number_types.UOffsetTFlags.py_type(64)) # ArrayStruct def D(self, obj, i): obj.Init(self._tab.Bytes, self._tab.Pos + 72 + i * 32) return obj # ArrayStruct def DLength(self): o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(72)) if o != 0: return self._tab.VectorLen(o) return 0 # ArrayStruct def DIsNone(self): o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(72)) return o == 0 # ArrayStruct def E(self): return self._tab.Get(flatbuffers.number_types.Int32Flags, self._tab.Pos + flatbuffers.number_types.UOffsetTFlags.py_type(136)) # ArrayStruct def F(self): return [self._tab.Get(flatbuffers.number_types.Int64Flags, self._tab.Pos + flatbuffers.number_types.UOffsetTFlags.py_type(144 + i * 8)) for i in range(2)] # ArrayStruct def FLength(self): o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(144)) if o != 0: return self._tab.VectorLen(o) return 0 # ArrayStruct def FIsNone(self): o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(144)) return o == 0 def CreateArrayStruct(builder, a, b, c, d_a, d_b, d_c, d_d, e, f): builder.Prep(8, 160) for _idx0 in range(2 , 0, -1): builder.PrependInt64(f[_idx0-1]) builder.Pad(4) builder.PrependInt32(e) for _idx0 in range(2 , 0, -1): builder.Prep(8, 32) for _idx1 in range(2 , 0, -1): builder.PrependInt64(d_d[_idx0-1][_idx1-1]) builder.Pad(5) for _idx1 in range(2 , 0, -1): builder.PrependInt8(d_c[_idx0-1][_idx1-1]) builder.PrependInt8(d_b[_idx0-1]) for _idx1 in range(2 , 0, -1): builder.PrependInt32(d_a[_idx0-1][_idx1-1]) builder.Pad(7) builder.PrependInt8(c) for _idx0 in range(15 , 0, -1): builder.PrependInt32(b[_idx0-1]) builder.PrependFloat32(a) return builder.Offset() import MyGame.Example.NestedStruct try: from typing import List except: pass class ArrayStructT(object): # ArrayStructT def __init__(self): self.a = 0.0 # type: float self.b = None # type: List[int] self.c = 0 # type: int self.d = None # type: List[MyGame.Example.NestedStruct.NestedStructT] self.e = 0 # type: int self.f = None # type: List[int] @classmethod def InitFromBuf(cls, buf, pos): arrayStruct = ArrayStruct() arrayStruct.Init(buf, pos) return cls.InitFromObj(arrayStruct) @classmethod def InitFromObj(cls, arrayStruct): x = ArrayStructT() x._UnPack(arrayStruct) return x # ArrayStructT def _UnPack(self, arrayStruct): if arrayStruct is None: return self.a = arrayStruct.A() if not arrayStruct.BIsNone(): if np is None: self.b = [] for i in range(arrayStruct.BLength()): self.b.append(arrayStruct.B(i)) else: self.b = arrayStruct.BAsNumpy() self.c = arrayStruct.C() if not arrayStruct.DIsNone(): self.d = [] for i in range(arrayStruct.DLength()): self.d.append(arrayStruct.D(i)) self.e = arrayStruct.E() if not arrayStruct.FIsNone(): if np is None: self.f = [] for i in range(arrayStruct.FLength()): self.f.append(arrayStruct.F(i)) else: self.f = arrayStruct.FAsNumpy() # ArrayStructT def Pack(self, builder): return CreateArrayStruct(builder, self.a, self.b, self.c, self.d.a, self.d.b, self.d.c, self.d.d, self.e, self.f)
41,020
https://github.com/lrun1124/Dota2-Api/blob/master/lib/dota2-api.js
Github Open Source
Open Source
MIT
2,021
Dota2-Api
lrun1124
JavaScript
Code
288
868
'use strict'; var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }(); var _lodash = require('lodash.pick'); var _lodash2 = _interopRequireDefault(_lodash); var _url = require('url'); var _url2 = _interopRequireDefault(_url); var _registeredApiMethods = require('./registeredApiMethods'); var _registeredApiMethods2 = _interopRequireDefault(_registeredApiMethods); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } /*! * dota2-api - lib/dota2-api.js * * Copyright(c) 2014 Liucw <liucw.mail@gmail.com> * MIT Licensed */ require('es6-promise').polyfill(); require('es6-object-assign').polyfill(); require('isomorphic-fetch'); var API_URL = 'https://api.steampowered.com/'; var AVAILABLE_IDS = [570, 816, 205790]; var Dota2Api = function () { function Dota2Api(key) { var ID = arguments.length <= 1 || arguments[1] === undefined ? AVAILABLE_IDS[0] : arguments[1]; _classCallCheck(this, Dota2Api); if (!key) { throw new TypeError('required key (Get key from http://steamcommunity.com/dev/apikey)'); } this.key = key; this.ID = AVAILABLE_IDS.indexOf(ID) === -1 ? AVAILABLE_IDS[0] : ID; } _createClass(Dota2Api, [{ key: '_request', value: function _request(path, validOptionKeys) { var options = arguments.length <= 2 || arguments[2] === undefined ? {} : arguments[2]; var filteredOptions = (0, _lodash2.default)(options, validOptionKeys); filteredOptions.key = this.key; var uri = _url2.default.format({ pathname: API_URL + path, query: filteredOptions }); return fetch(uri).then(this._parseResponse); } }, { key: '_parseResponse', value: function _parseResponse(response) { if (!response.ok) { throw new Error(response.statusText); } return response.json(); } }], [{ key: 'create', value: function create(key, ID) { return new Dota2Api(key, ID); } }]); return Dota2Api; }(); Object.assign(Dota2Api.prototype, _registeredApiMethods2.default); module.exports = Dota2Api;
14,135
https://github.com/alejandroEGT/proyecto-inclusion5.0/blob/master/public/js/invitado/funciones.js
Github Open Source
Open Source
MIT
null
proyecto-inclusion5.0
alejandroEGT
JavaScript
Code
12
42
function schoolUser(){ window.location = "/formUsuarioInstitucion"; } function userOnly(){ window.location = "/formUsuario"; }
12,732
https://github.com/troels/compute-runtime/blob/master/level_zero/tools/test/unit_tests/sources/sysman/linux/pmt/test_pmt.cpp
Github Open Source
Open Source
Intel, MIT
2,022
compute-runtime
troels
C++
Code
799
5,340
/* * Copyright (C) 2021 Intel Corporation * * SPDX-License-Identifier: MIT * */ #include "level_zero/tools/test/unit_tests/sources/sysman/linux/mock_sysman_fixture.h" #include "mock_pmt.h" using ::testing::_; using ::testing::Matcher; using ::testing::Return; namespace L0 { namespace ult { static int fakeFileDescriptor = 123; class ZesPmtFixtureMultiDevice : public SysmanMultiDeviceFixture { protected: std::vector<ze_device_handle_t> deviceHandles; std::unique_ptr<Mock<PmtFsAccess>> pTestFsAccess; std::map<uint32_t, L0::PlatformMonitoringTech *> mapOfSubDeviceIdToPmtObject; void SetUp() override { SysmanMultiDeviceFixture::SetUp(); uint32_t subDeviceCount = 0; Device::fromHandle(device->toHandle())->getSubDevices(&subDeviceCount, nullptr); if (subDeviceCount == 0) { deviceHandles.resize(1, device->toHandle()); } else { deviceHandles.resize(subDeviceCount, nullptr); Device::fromHandle(device->toHandle())->getSubDevices(&subDeviceCount, deviceHandles.data()); } pTestFsAccess = std::make_unique<NiceMock<Mock<PmtFsAccess>>>(); ON_CALL(*pTestFsAccess.get(), read(_, Matcher<std::string &>(_))) .WillByDefault(::testing::Invoke(pTestFsAccess.get(), &Mock<PmtFsAccess>::getValString)); ON_CALL(*pTestFsAccess.get(), read(_, Matcher<uint64_t &>(_))) .WillByDefault(::testing::Invoke(pTestFsAccess.get(), &Mock<PmtFsAccess>::getValUnsignedLong)); ON_CALL(*pTestFsAccess.get(), listDirectory(_, _)) .WillByDefault(::testing::Invoke(pTestFsAccess.get(), &Mock<PmtFsAccess>::listDirectorySuccess)); ON_CALL(*pTestFsAccess.get(), getRealPath(_, _)) .WillByDefault(::testing::Invoke(pTestFsAccess.get(), &Mock<PmtFsAccess>::getRealPathSuccess)); ON_CALL(*pTestFsAccess.get(), fileExists(_)) .WillByDefault(::testing::Invoke(pTestFsAccess.get(), &Mock<PmtFsAccess>::isFileExists)); PlatformMonitoringTech::create(deviceHandles, pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt, mapOfSubDeviceIdToPmtObject); } void TearDown() override { SysmanMultiDeviceFixture::TearDown(); for (auto &subDeviceIdToPmtEntry : mapOfSubDeviceIdToPmtObject) { delete subDeviceIdToPmtEntry.second; } } }; TEST_F(ZesPmtFixtureMultiDevice, GivenValidDeviceHandlesWhenCreatingPMTHandlesThenValidPmtHandlesForAllSubdevicesWillBeCreated) {} TEST_F(ZesPmtFixtureMultiDevice, GivenValidDeviceHandlesWhenenumerateRootTelemIndexThenCheckForErrorIflistDirectoryFails) { EXPECT_CALL(*pTestFsAccess.get(), listDirectory(_, _)) .WillOnce(Return(ZE_RESULT_ERROR_NOT_AVAILABLE)); EXPECT_EQ(ZE_RESULT_ERROR_NOT_AVAILABLE, PlatformMonitoringTech::enumerateRootTelemIndex(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt)); } TEST_F(ZesPmtFixtureMultiDevice, GivenValidDeviceHandlesWhenenumerateRootTelemIndexThenCheckForErrorIfgetRealPathFails) { EXPECT_CALL(*pTestFsAccess.get(), getRealPath(_, _)) .WillRepeatedly(Return(ZE_RESULT_ERROR_NOT_AVAILABLE)); EXPECT_EQ(ZE_RESULT_ERROR_DEPENDENCY_UNAVAILABLE, PlatformMonitoringTech::enumerateRootTelemIndex(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt)); } TEST_F(ZesPmtFixtureMultiDevice, GivenWhenenumerateRootTelemIndexThenCheckForErrorIfgetRealPathSuccessButNoTelemetryNodeAndGPUDeviceShareRootPciPort) { EXPECT_CALL(*pTestFsAccess.get(), getRealPath(_, _)) .Times(5) .WillRepeatedly(::testing::DoAll(::testing::SetArgReferee<1>("/sys/devices/pci0000:89/0000:89:02.0/0000:8e:00.0/0000:8b:02.0/0000:8e:00.1/pmt_telemetry.1.auto/intel_pmt/telem1"), Return(ZE_RESULT_SUCCESS))); EXPECT_EQ(ZE_RESULT_ERROR_DEPENDENCY_UNAVAILABLE, PlatformMonitoringTech::enumerateRootTelemIndex(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt)); } TEST_F(ZesPmtFixtureMultiDevice, GivenTelemDirectoryContainNowTelemEntryWhenenumerateRootTelemIndexThenCheckForError) { ON_CALL(*pTestFsAccess.get(), listDirectory(_, _)) .WillByDefault(::testing::Invoke(pTestFsAccess.get(), &Mock<PmtFsAccess>::listDirectoryNoTelemNode)); EXPECT_EQ(ZE_RESULT_ERROR_DEPENDENCY_UNAVAILABLE, PlatformMonitoringTech::enumerateRootTelemIndex(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt)); } TEST_F(ZesPmtFixtureMultiDevice, GivenValidDeviceHandlesWhenCreatingPMTHandlesThenCheckForErrorThatCouldHappenDuringWhileValidatingTelemNode) { EXPECT_CALL(*pTestFsAccess.get(), getRealPath(_, _)) .WillRepeatedly(Return(ZE_RESULT_ERROR_NOT_AVAILABLE)); PlatformMonitoringTech::enumerateRootTelemIndex(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt); auto pPmt = std::make_unique<PublicPlatformMonitoringTech>(pTestFsAccess.get(), 1, 0); EXPECT_EQ(pPmt->init(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt), ZE_RESULT_ERROR_DEPENDENCY_UNAVAILABLE); } TEST_F(ZesPmtFixtureMultiDevice, GivenValidDeviceHandlesWhenCreatingPMTHandlesThenCheckForErrorThatCouldHappenDuringGUIDRead) { EXPECT_CALL(*pTestFsAccess.get(), read(_, Matcher<std::string &>(_))) .WillOnce(Return(ZE_RESULT_ERROR_NOT_AVAILABLE)); PlatformMonitoringTech::enumerateRootTelemIndex(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt); auto pPmt = std::make_unique<PublicPlatformMonitoringTech>(pTestFsAccess.get(), 1, 0); EXPECT_EQ(pPmt->init(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt), ZE_RESULT_ERROR_NOT_AVAILABLE); } TEST_F(ZesPmtFixtureMultiDevice, GivenValidDeviceHandlesWhenCreatingPMTHandlesThenCheckForErrorIfGUIDReadValueIsNotSupported) { EXPECT_CALL(*pTestFsAccess.get(), read(_, Matcher<std::string &>(_))) .WillOnce(::testing::DoAll(::testing::SetArgReferee<1>(""), Return(ZE_RESULT_SUCCESS))); PlatformMonitoringTech::enumerateRootTelemIndex(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt); auto pPmt = std::make_unique<PublicPlatformMonitoringTech>(pTestFsAccess.get(), 1, 0); EXPECT_EQ(pPmt->init(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt), ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); } TEST_F(ZesPmtFixtureMultiDevice, GivenValidDeviceHandlesWhenCreatingPMTHandlesThenCheckForErrorThatCouldHappenDuringSizeRead) { EXPECT_CALL(*pTestFsAccess.get(), read(_, Matcher<uint64_t &>(_))) .WillOnce(Return(ZE_RESULT_ERROR_NOT_AVAILABLE)); PlatformMonitoringTech::enumerateRootTelemIndex(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt); auto pPmt = std::make_unique<PublicPlatformMonitoringTech>(pTestFsAccess.get(), 1, 0); EXPECT_EQ(pPmt->init(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt), ZE_RESULT_ERROR_NOT_AVAILABLE); } TEST_F(ZesPmtFixtureMultiDevice, GivenValidDeviceHandlesWhenCreatingPMTHandlesThenCheckForErrorThatCouldHappenDuringbaseOffsetRead) { EXPECT_CALL(*pTestFsAccess.get(), read(_, Matcher<uint64_t &>(_))) .WillOnce(Return(ZE_RESULT_SUCCESS)) .WillOnce(Return(ZE_RESULT_ERROR_NOT_AVAILABLE)); PlatformMonitoringTech::enumerateRootTelemIndex(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt); auto pPmt = std::make_unique<PublicPlatformMonitoringTech>(pTestFsAccess.get(), 1, 0); EXPECT_EQ(pPmt->init(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt), ZE_RESULT_ERROR_NOT_AVAILABLE); } TEST_F(ZesPmtFixtureMultiDevice, GivenSomeKeyWhenCallingreadValueWithUint64TypeThenCheckForErrorBranches) { auto pPmt = std::make_unique<PublicPlatformMonitoringTech>(pTestFsAccess.get(), 0, 0); pPmt->mappedMemory = nullptr; uint64_t val = 0; EXPECT_EQ(ZE_RESULT_ERROR_DEPENDENCY_UNAVAILABLE, pPmt->readValue("SOMETHING", val)); uint32_t maxIndex = 10u; pPmt->mappedMemory = new char[maxIndex]; EXPECT_EQ(ZE_RESULT_ERROR_UNSUPPORTED_FEATURE, pPmt->readValue("SOMETHING", val)); delete pPmt->mappedMemory; } inline static int openMock(const char *pathname, int flags, ...) { if (strcmp(pathname, "/sys/class/intel_pmt/telem2/telem") == 0) { return fakeFileDescriptor; } if (strcmp(pathname, "/sys/class/intel_pmt/telem3/telem") == 0) { return fakeFileDescriptor; } return -1; } inline static int openMockReturnFailure(const char *pathname, int flags, ...) { return -1; } inline static int closeMock(int fd) { if (fd == fakeFileDescriptor) { return 0; } return -1; } inline static int closeMockReturnFailure(int fd) { return -1; } inline static void *mmapMockReturnFailure(void *addr, size_t length, int prot, int flags, int fd, off_t offset) noexcept { return MAP_FAILED; } inline static void *mmapMock(void *addr, size_t length, int prot, int flags, int fd, off_t offset) noexcept { void *ptr = nullptr; if (fd == fakeFileDescriptor) { ptr = alignedMalloc(length, MemoryConstants::pageSize64k); return ptr; } return MAP_FAILED; } inline static int munmapMock(void *addr, size_t length) noexcept { alignedFree(addr); return 0; } inline static int munmapMockDoNothing(void *addr, size_t length) noexcept { return 0; } TEST_F(ZesPmtFixtureMultiDevice, GivenValidSyscallsWhenDoingPMTInitThenPMTInitSucceed) { auto pPmt = std::make_unique<PublicPlatformMonitoringTech>(pTestFsAccess.get(), 1, 0); pPmt->openFunction = openMock; pPmt->mmapFunction = mmapMock; pPmt->munmapFunction = munmapMock; pPmt->closeFunction = closeMock; EXPECT_EQ(pPmt->init(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt), ZE_RESULT_SUCCESS); } TEST_F(ZesPmtFixtureMultiDevice, GivenValidSyscallsWhenDoingPMTInitAndOpenSysCallFailsThenPMTInitFails) { auto pPmt = std::make_unique<PublicPlatformMonitoringTech>(pTestFsAccess.get(), 1, 0); pPmt->openFunction = openMockReturnFailure; pPmt->mmapFunction = mmapMock; pPmt->munmapFunction = munmapMock; pPmt->closeFunction = closeMock; EXPECT_EQ(pPmt->init(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt), ZE_RESULT_ERROR_DEPENDENCY_UNAVAILABLE); } TEST_F(ZesPmtFixtureMultiDevice, GivenValidSyscallsWhenDoingPMTInitAndmmapSysCallFailsThenPMTInitFails) { auto pPmt = std::make_unique<PublicPlatformMonitoringTech>(pTestFsAccess.get(), 1, 0); pPmt->openFunction = openMock; pPmt->mmapFunction = mmapMockReturnFailure; pPmt->munmapFunction = munmapMockDoNothing; pPmt->closeFunction = closeMock; EXPECT_EQ(pPmt->init(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt), ZE_RESULT_ERROR_DEPENDENCY_UNAVAILABLE); } TEST_F(ZesPmtFixtureMultiDevice, GivenValidSyscallsWhenDoingPMTInitAndcloseSysCallFailsThenPMTInitFails) { auto pPmt = std::make_unique<PublicPlatformMonitoringTech>(pTestFsAccess.get(), 1, 0); pPmt->openFunction = openMock; pPmt->mmapFunction = mmapMock; pPmt->munmapFunction = munmapMock; pPmt->closeFunction = closeMockReturnFailure; EXPECT_EQ(pPmt->init(pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt), ZE_RESULT_ERROR_UNSUPPORTED_FEATURE); } TEST_F(ZesPmtFixtureMultiDevice, GivenValidSyscallsWhenDoingPMTInitThenPMTmapOfSubDeviceIdToPmtObjectWouldContainValidEntries) { std::map<uint32_t, L0::PlatformMonitoringTech *> mapOfSubDeviceIdToPmtObject; for (const auto &deviceHandle : deviceHandles) { ze_device_properties_t deviceProperties = {ZE_STRUCTURE_TYPE_DEVICE_PROPERTIES}; Device::fromHandle(deviceHandle)->getProperties(&deviceProperties); auto pPmt = new PublicPlatformMonitoringTech(pTestFsAccess.get(), deviceProperties.flags & ZE_DEVICE_PROPERTY_FLAG_SUBDEVICE, deviceProperties.subdeviceId); UNRECOVERABLE_IF(nullptr == pPmt); pPmt->openFunction = openMock; pPmt->mmapFunction = mmapMock; pPmt->munmapFunction = munmapMock; pPmt->closeFunction = closeMock; PublicPlatformMonitoringTech::doInitPmtObject(pTestFsAccess.get(), deviceProperties.subdeviceId, pPmt, rootPciPathOfGpuDeviceInPmt, mapOfSubDeviceIdToPmtObject); auto subDeviceIdToPmtEntry = mapOfSubDeviceIdToPmtObject.find(deviceProperties.subdeviceId); EXPECT_EQ(subDeviceIdToPmtEntry->second, pPmt); delete pPmt; } } TEST_F(ZesPmtFixtureMultiDevice, GivenOpenSyscallFailWhenDoingPMTInitThenPMTmapOfSubDeviceIdToPmtObjectWouldBeEmpty) { std::map<uint32_t, L0::PlatformMonitoringTech *> mapOfSubDeviceIdToPmtObject; for (const auto &deviceHandle : deviceHandles) { ze_device_properties_t deviceProperties = {ZE_STRUCTURE_TYPE_DEVICE_PROPERTIES}; Device::fromHandle(deviceHandle)->getProperties(&deviceProperties); auto pPmt = new PublicPlatformMonitoringTech(pTestFsAccess.get(), deviceProperties.flags & ZE_DEVICE_PROPERTY_FLAG_SUBDEVICE, deviceProperties.subdeviceId); UNRECOVERABLE_IF(nullptr == pPmt); pPmt->openFunction = openMockReturnFailure; pPmt->mmapFunction = mmapMock; pPmt->munmapFunction = munmapMock; pPmt->closeFunction = closeMock; PublicPlatformMonitoringTech::doInitPmtObject(pTestFsAccess.get(), deviceProperties.subdeviceId, pPmt, rootPciPathOfGpuDeviceInPmt, mapOfSubDeviceIdToPmtObject); EXPECT_TRUE(mapOfSubDeviceIdToPmtObject.empty()); } } TEST_F(ZesPmtFixtureMultiDevice, GivenNoPMTHandleInmapOfSubDeviceIdToPmtObjectWhenCallingreleasePmtObjectThenMapWouldGetEmpty) { auto mapOriginal = pLinuxSysmanImp->mapOfSubDeviceIdToPmtObject; for (const auto &deviceHandle : deviceHandles) { ze_device_properties_t deviceProperties = {ZE_STRUCTURE_TYPE_DEVICE_PROPERTIES}; Device::fromHandle(deviceHandle)->getProperties(&deviceProperties); pLinuxSysmanImp->mapOfSubDeviceIdToPmtObject.emplace(deviceProperties.subdeviceId, nullptr); } pLinuxSysmanImp->releasePmtObject(); EXPECT_TRUE(pLinuxSysmanImp->mapOfSubDeviceIdToPmtObject.empty()); pLinuxSysmanImp->mapOfSubDeviceIdToPmtObject = mapOriginal; } class ZesPmtFixtureNoSubDevice : public SysmanDeviceFixture { protected: std::vector<ze_device_handle_t> deviceHandles; std::unique_ptr<Mock<PmtFsAccess>> pTestFsAccess; std::map<uint32_t, L0::PlatformMonitoringTech *> mapOfSubDeviceIdToPmtObject; void SetUp() override { SysmanDeviceFixture::SetUp(); uint32_t subDeviceCount = 0; Device::fromHandle(device->toHandle())->getSubDevices(&subDeviceCount, nullptr); if (subDeviceCount == 0) { deviceHandles.resize(1, device->toHandle()); } else { deviceHandles.resize(subDeviceCount, nullptr); Device::fromHandle(device->toHandle())->getSubDevices(&subDeviceCount, deviceHandles.data()); } pTestFsAccess = std::make_unique<NiceMock<Mock<PmtFsAccess>>>(); ON_CALL(*pTestFsAccess.get(), read(_, Matcher<std::string &>(_))) .WillByDefault(::testing::Invoke(pTestFsAccess.get(), &Mock<PmtFsAccess>::getValString)); ON_CALL(*pTestFsAccess.get(), read(_, Matcher<uint64_t &>(_))) .WillByDefault(::testing::Invoke(pTestFsAccess.get(), &Mock<PmtFsAccess>::getValUnsignedLong)); ON_CALL(*pTestFsAccess.get(), listDirectory(_, _)) .WillByDefault(::testing::Invoke(pTestFsAccess.get(), &Mock<PmtFsAccess>::listDirectorySuccess)); ON_CALL(*pTestFsAccess.get(), getRealPath(_, _)) .WillByDefault(::testing::Invoke(pTestFsAccess.get(), &Mock<PmtFsAccess>::getRealPathSuccess)); ON_CALL(*pTestFsAccess.get(), fileExists(_)) .WillByDefault(::testing::Invoke(pTestFsAccess.get(), &Mock<PmtFsAccess>::isFileExists)); PlatformMonitoringTech::create(deviceHandles, pTestFsAccess.get(), rootPciPathOfGpuDeviceInPmt, mapOfSubDeviceIdToPmtObject); } void TearDown() override { SysmanDeviceFixture::TearDown(); for (auto &subDeviceIdToPmtEntry : mapOfSubDeviceIdToPmtObject) { delete subDeviceIdToPmtEntry.second; } } }; TEST_F(ZesPmtFixtureNoSubDevice, GivenValidDeviceHandlesWhenCreatingPMTHandlesThenValidPmtHandlesForAllSubdevicesWillBeCreated) {} } // namespace ult } // namespace L0
26,040
https://github.com/macpete/Halide/blob/master/test/error/wrong_type.cpp
Github Open Source
Open Source
BSD-3-Clause, MIT, Apache-2.0
2,020
Halide
macpete
C++
Code
33
102
#include "Halide.h" using namespace Halide; #ifdef NDEBUG #error "wrong_type requires assertions" #endif int main(int argc, char **argv) { Func f; Var x; f(x) = x; Buffer<float> im = f.realize(100); printf("Success!\n"); return 0; }
43,577
https://github.com/noinarisak/homebrew-cask/blob/master/Casks/reunion.rb
Github Open Source
Open Source
BSD-2-Clause
2,019
homebrew-cask
noinarisak
Ruby
Code
19
183
cask 'reunion' do version '12.0.0.181218' sha256 '6c4946169eb2f57d3726615265b29a6483ddfbccf19e610f832c5fadba8fd1e6' url "https://store.leisterpro.com/updates/reunion#{version.major}/Reunion-#{version.dots_to_hyphens}.zip" appcast "https://store.leisterpro.com/updates/reunion#{version.major}/appcast.xml" name 'Reunion' homepage 'http://www.leisterpro.com/' app "Reunion #{version.major}.app" end
25,564
https://github.com/kentik/kentik-deps/blob/master/pkg/netflow/netflow1/packet.go
Github Open Source
Open Source
Apache-2.0
2,022
kentik-deps
kentik
Go
Code
721
1,692
package netflow1 import ( "fmt" "io" "log" "net" "time" "github.com/kentik/kentik-deps/pkg/netflow/read" ) const ( // Version word in the Packet Header Version uint16 = 0x0001 ) // Packet is a NetFlow v1 packet type Packet struct { Header PacketHeader Records []*FlowRecord } func (p *Packet) Unmarshal(r io.Reader) error { if err := p.Header.Unmarshal(r); err != nil { return err } p.Records = make([]*FlowRecord, p.Header.Count) for i := range p.Records { p.Records[i] = new(FlowRecord) if err := p.Records[i].Unmarshal(r); err != nil { return err } } return nil } // PacketHeader is a NetFlow v1 packet type PacketHeader struct { Version uint16 Count uint16 SysUptime time.Duration // 32 bit milliseconds Unix time.Time // 32 bit seconds + 32 bit nanoseconds } func (h PacketHeader) String() string { return fmt.Sprintf("v=%d, count=%d, uptime=%s, time=%s", h.Version, h.Count, time.Duration(h.SysUptime)*time.Second, h.Unix) } func (h *PacketHeader) Unmarshal(r io.Reader) error { if err := read.Uint16(&h.Version, r); err != nil { return err } if err := read.Uint16(&h.Count, r); err != nil { return err } // The spec says at most 24 flows in one packet, but reality disagrees. if h.Count < 1 || h.Count > 32 { return fmt.Errorf("protocol error: %d flows out of bounds", h.Count) } var u uint32 if err := read.Uint32(&u, r); err != nil { return err } h.SysUptime = time.Duration(u) var t uint64 if err := read.Uint64(&t, r); err != nil { return err } h.Unix = time.Unix(int64(t>>32), int64(t&0xffffffff)) log.Println(h) return nil } // FlowRecord is a NetFlow v1 Flow Record type FlowRecord struct { // SrcAddr is the Source IP address SrcAddr net.IP // 0-3 // DstAddr is the Destination IP address DstAddr net.IP // 4-7 // NextHop is the IP address of next hop router NextHop net.IP // 8-11 // Input is the SNMP index of input interface Input uint16 // 12-13 // Output is the SNMP index of output interface Output uint16 // 14-15 // Packets is the number of packets in the flow Packets uint32 // 16-19 // Octets is the number of bytes in the flow Bytes uint32 // 20-23 // First is the SysUptime at start of flow First uint32 // 24-27 // Last is the SysUptime at end of flow Last uint32 // 28-31 // SrcPort is the TCP/UDP source port number or equivalent SrcPort uint16 // 32-33 // DstPort is the TCP/UDP destination port number or equivalent DstPort uint16 // 34-35 // Pad1 are unused bytes Pad1 uint16 // 36-37 // Protocol number (IP) Protocol uint8 // 38 // ToS is the IP type of service ToS uint8 // 39 // Flags are cumulative OR TCP flags Flags uint8 // 40 // Pad2 are unused bytes Pad2 uint8 // Pad3 are unused bytes Pad3 uint16 // Reservered are reserved (unused) bytes Reserved uint32 } func (r FlowRecord) String() string { return fmt.Sprintf("%s:%d -> %s:%d", r.SrcAddr, r.SrcPort, r.DstAddr, r.DstPort) } func (r *FlowRecord) Unmarshal(h io.Reader) error { r.SrcAddr = make(net.IP, 4) if _, err := h.Read(r.SrcAddr); err != nil { return err } r.DstAddr = make(net.IP, 4) if _, err := h.Read(r.DstAddr); err != nil { return err } r.NextHop = make(net.IP, 4) if _, err := h.Read(r.NextHop); err != nil { return err } if err := read.Uint16(&r.Input, h); err != nil { return err } if err := read.Uint16(&r.Output, h); err != nil { return err } if err := read.Uint32(&r.Packets, h); err != nil { return err } if err := read.Uint32(&r.Bytes, h); err != nil { return err } if err := read.Uint32(&r.First, h); err != nil { return err } if err := read.Uint32(&r.Last, h); err != nil { return err } if err := read.Uint16(&r.SrcPort, h); err != nil { return err } if err := read.Uint16(&r.DstPort, h); err != nil { return err } if err := read.Uint16(&r.Pad1, h); err != nil { return err } if err := read.Uint8(&r.Protocol, h); err != nil { return err } if err := read.Uint8(&r.ToS, h); err != nil { return err } if err := read.Uint8(&r.Flags, h); err != nil { return err } if err := read.Uint8(&r.Pad2, h); err != nil { return err } if err := read.Uint16(&r.Pad3, h); err != nil { return err } if err := read.Uint32(&r.Reserved, h); err != nil { return err } return nil } func (f FlowRecord) SampleInterval() int { return 1 }
42,903
https://github.com/enfoTek/tomato.linksys.e2000.nvram-mod/blob/master/tools-src/gnu/gcc/gcc/testsuite/gcc.c-torture/execute/widechar-2.c
Github Open Source
Open Source
FSFAP
2,022
tomato.linksys.e2000.nvram-mod
enfoTek
C
Code
30
89
#include <stddef.h> const wchar_t ws[] = L"foo"; int main (void) { if (ws[0] != L'f' || ws[1] != L'o' || ws[2] != L'o' || ws[3] != L'\0') abort(); exit(0); }
30,471
https://github.com/everest-engineering/axon-crypto-shredding-extension/blob/master/src/test/java/engineering/everest/axon/cryptoshredding/encryption/DefaultDefaultAesEncrypterDecrypterFactoryTest.java
Github Open Source
Open Source
Apache-2.0
2,022
axon-crypto-shredding-extension
everest-engineering
Java
Code
44
338
package engineering.everest.axon.cryptoshredding.encryption; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import org.junit.jupiter.api.extension.ExtendWith; import org.mockito.junit.jupiter.MockitoExtension; import static org.junit.jupiter.api.Assertions.assertNotEquals; @ExtendWith(MockitoExtension.class) class DefaultDefaultAesEncrypterDecrypterFactoryTest { private DefaultAesEncrypterDecrypterFactory defaultAesEncrypterDecrypterFactory; @BeforeEach void setUp() { defaultAesEncrypterDecrypterFactory = new DefaultAesEncrypterDecrypterFactory(); } @Test void createEncrypterReturnsNewInstances() { assertNotEquals(defaultAesEncrypterDecrypterFactory.createEncrypter(), defaultAesEncrypterDecrypterFactory.createEncrypter()); } @Test void createDecrypterReturnsNewInstances() { assertNotEquals(defaultAesEncrypterDecrypterFactory.createDecrypter(), defaultAesEncrypterDecrypterFactory.createDecrypter()); } }
3,437
https://github.com/liratanak/lodata/blob/master/tests/Laravel/Models/Repository.php
Github Open Source
Open Source
MIT
null
lodata
liratanak
PHP
Code
38
152
<?php declare(strict_types=1); namespace Flat3\Lodata\Tests\Laravel\Models; use Flat3\Lodata\Attributes\LodataFunction; use Flat3\Lodata\Interfaces\RepositoryInterface; class Repository implements RepositoryInterface { public function getClass(): string { return Airport::class; } #[LodataFunction (bind: "airport")] public function code(Airport $airport, ?string $suffix): string { return $airport->code.($suffix ?: ''); } }
18,829
https://github.com/Bogdan12344321/chrome-extension-react/blob/master/src/jsx/component/bypasslist/PopularRule.jsx
Github Open Source
Open Source
LicenseRef-scancode-generic-cla, MIT
2,020
chrome-extension-react
Bogdan12344321
JavaScript
Code
128
478
import PropType from 'prop-types'; import React, { Component } from 'react'; import Checkbox from '../checkbox'; import ErrorBoundary from '../../hoc/errorboundary'; class PopularRule extends Component { constructor(props) { super(props); const background = chrome.extension.getBackgroundPage(); this.app = background.app; // properties const { defaultName } = props; this.defaultName = defaultName; this.bypasslist = this.app.util.bypasslist; this.region = this.app.util.regionlist.getSelectedRegion(); this.state = { checked: this.bypasslist.isRuleEnabled(defaultName) }; // Bindings this.onChange = this.onChange.bind(this); } onChange({ target: { checked } }) { if (checked) { this.bypasslist.enablePopularRule(this.defaultName); } else { this.bypasslist.disablePopularRule(this.defaultName); } this.setState({ checked: this.bypasslist.isRuleEnabled(this.defaultName) }); } render() { const { checked } = this.state; return ( <li className="list-group-item col-xs-4 popular-rule"> <label htmlFor={this.defaultName} className="noselect col-xs-8 popular-rule-name" > { this.defaultName } </label> <Checkbox id={this.defaultName} className="col-xs-2" checked={checked} disabled={!this.region} onChange={this.onChange} /> </li> ); } } PopularRule.propTypes = { defaultName: PropType.string.isRequired, }; export default PopularRule;
40,008
https://github.com/werselio/pipeline/blob/master/cdap-proto/src/main/java/co/cask/cdap/proto/codec/NamespacedEntityIdCodec.java
Github Open Source
Open Source
Apache-2.0
2,018
pipeline
werselio
Java
Code
207
655
/* * Copyright © 2016 Cask Data, Inc. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not * use this file except in compliance with the License. You may obtain a copy of * the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the * License for the specific language governing permissions and limitations under * the License. */ package co.cask.cdap.proto.codec; import co.cask.cdap.proto.Id; import co.cask.cdap.proto.id.NamespacedEntityId; import com.google.gson.JsonDeserializationContext; import com.google.gson.JsonElement; import com.google.gson.JsonParseException; import com.google.gson.JsonSerializationContext; import java.lang.reflect.Type; /** * Codec for {@link co.cask.cdap.proto.id.NamespacedEntityId}. Currently only supports * {@link co.cask.cdap.proto.id.ApplicationId}, {@link co.cask.cdap.proto.id.ArtifactId}, * {@link co.cask.cdap.proto.id.ProgramId}, {@link co.cask.cdap.proto.id.DatasetId}, * {@link co.cask.cdap.proto.id.StreamId} and {@link co.cask.cdap.proto.id.StreamViewId}. * * Currently just delegates to {@link NamespacedEntityIdCodec} while phasing out {@link Id} usages. */ public class NamespacedEntityIdCodec extends AbstractSpecificationCodec<NamespacedEntityId> { private NamespacedIdCodec namespacedIdCodec; public NamespacedEntityIdCodec() { this.namespacedIdCodec = new NamespacedIdCodec(); } @Override public JsonElement serialize(NamespacedEntityId src, Type typeOfSrc, JsonSerializationContext context) { return namespacedIdCodec.serialize((Id.NamespacedId) src.toId(), typeOfSrc, context); } @Override public NamespacedEntityId deserialize(JsonElement json, Type typeOfT, JsonDeserializationContext context) throws JsonParseException { return (NamespacedEntityId) namespacedIdCodec.deserialize(json, typeOfT, context).toEntityId(); } }
2,972
https://github.com/shunfei/indexr/blob/master/indexr-common/src/main/java/io/indexr/util/UTF8JsonDeserializer.java
Github Open Source
Open Source
Apache-2.0
2,022
indexr
shunfei
Java
Code
1,227
3,489
package io.indexr.util; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import java.io.UnsupportedEncodingException; import java.nio.ByteBuffer; /** * A fast json deserializer which parse json in utf-8 encoding bytes directly. * Using this class to avoid the pay-off of transforming into utf-16 (i.e. java String), and generating lots of intermediate objects. * It supports multiple json objects, seperated by comma, and each object can only contains one layer. e.g. * <pre> * {"name": "Flow", "score": 4.3}, {"title": "You know \"nothing\"! Jon Snow."} * </pre> */ public class UTF8JsonDeserializer { private static final Logger logger = LoggerFactory.getLogger(UTF8JsonDeserializer.class); private static final byte CURLY_BRACE_LEFT = '{'; private static final byte CURLY_BRACE_RIGHT = '}'; private static final byte DOUBLE_QUOTE = '"'; private static final byte COLON = ':'; private static final byte COMMA = ','; private static final byte BLANK = ' '; private static final byte BACKSLASH = '\\'; private static final byte STATE_BEGIN = 0; private static final byte STATE_NEXT_KEY = 1; private static final byte STATE_IN_KEY = 2; private static final byte STATE_KEY_FINISH = 3; private static final byte STATE_NEXT_VALUE = 4; private static final byte STATE_IN_VALUE = 5; private static final byte STATE_VALUE_FINISH = 6; private static final byte STATE_FINISH = 7; // NOTE: Those should keep in sync with io.indexr.segment.SQLType public static final int INVALID = -1; public static final int INT = 1; public static final int BIGINT = 2; public static final int FLOAT = 3; public static final int DOUBLE = 4; public static final int VARCHAR = 5; public static final int DATE = 6; public static final int TIME = 7; public static final int DATETIME = 8; private final boolean numberEmptyAsZero; private ByteBuffer valueBuffer; public UTF8JsonDeserializer(boolean numberEmptyAsZero) { this.numberEmptyAsZero = numberEmptyAsZero; this.valueBuffer = ByteBuffer.allocate(1 << 16); } public UTF8JsonDeserializer() { this(false); } public boolean parse(byte[] data, Listener listener) { return parse(data, 0, data.length, listener); } public boolean parse(byte[] data, int offset, int len, Listener listener) { byte state = STATE_BEGIN; boolean escape = false; boolean couldBeString = false; int valueType = 0; valueBuffer.clear(); int objectOffset = 0; int to = offset + len; int pos = offset; for (; pos < to; pos++) { byte b = data[pos]; switch (state) { case STATE_BEGIN: switch (b) { case BLANK: break; case CURLY_BRACE_LEFT: state = STATE_NEXT_KEY; objectOffset = pos; listener.onStartJson(objectOffset); break; default: logErrorJson("expecting {", data, offset, len, pos); return false; } break; case STATE_NEXT_KEY: switch (b) { case BLANK: break; case DOUBLE_QUOTE: valueBuffer.clear(); state = STATE_IN_KEY; break; case CURLY_BRACE_RIGHT: state = STATE_FINISH; listener.onFinishJson(objectOffset, pos - objectOffset + 1); break; default: logErrorJson("expecting \" or }", data, offset, len, pos); return false; } break; case STATE_IN_KEY: switch (b) { case BACKSLASH: if (escape) { valueBuffer.put(b); escape = false; } else { escape = true; } break; case DOUBLE_QUOTE: if (escape) { valueBuffer.put(b); escape = false; } else { valueBuffer.flip(); state = STATE_KEY_FINISH; valueType = listener.onKey(valueBuffer, valueBuffer.limit()); } break; default: if (escape) { logErrorJson("illegal character after", data, offset, len, pos); return false; } else { valueBuffer.put(b); } break; } break; case STATE_KEY_FINISH: switch (b) { case BLANK: break; case COLON: state = STATE_NEXT_VALUE; break; default: logErrorJson("expecting :", data, offset, len, pos); return false; } break; case STATE_NEXT_VALUE: switch (b) { case BLANK: break; case DOUBLE_QUOTE: valueBuffer.clear(); couldBeString = true; // Enable {"number": "100"} //if (isNumber(valueType)) { // logErrorJson("expecting number", data, offset, len, pos); // return false; //} state = STATE_IN_VALUE; break; case CURLY_BRACE_LEFT: logErrorJson("multi-layer is not supported", data, offset, len, pos); return false; default: valueBuffer.clear(); valueBuffer.put(b); couldBeString = false; state = STATE_IN_VALUE; break; } break; case STATE_IN_VALUE: switch (b) { case BACKSLASH: if (escape) { valueBuffer.put(b); escape = false; } else { escape = true; } break; case DOUBLE_QUOTE: if (escape) { valueBuffer.put(b); escape = false; } else { valueBuffer.flip(); state = STATE_VALUE_FINISH; if (valueType == INVALID) { // Do nothing. } else if (isNumber(valueType)) { if (!onNumber(valueType, valueBuffer, listener)) { logErrorJson("illegal number", data, offset, len, pos - valueBuffer.limit()); return false; } } else { if (!listener.onStringValue(valueBuffer, valueBuffer.remaining())) { logErrorJson("illegal string", data, offset, len, pos - valueBuffer.limit()); return false; } } } break; case COMMA: if (escape) { logErrorJson("illegal character", data, offset, len, pos); return false; } else { if (valueType == INVALID) { if (couldBeString) { valueBuffer.put(b); } else { state = STATE_NEXT_KEY; } } else if (isNumber(valueType)) { valueBuffer.flip(); state = STATE_NEXT_KEY; if (!onNumber(valueType, valueBuffer, listener)) { logErrorJson("not a number", data, offset, len, pos - valueBuffer.limit()); return false; } } else { valueBuffer.put(b); } } break; case CURLY_BRACE_RIGHT: if (escape) { logErrorJson("illegal character", data, offset, len, pos); return false; } else { if (valueType == INVALID) { if (couldBeString) { valueBuffer.put(b); } else { state = STATE_FINISH; listener.onFinishJson(objectOffset, pos - objectOffset + 1); } } else if (isNumber(valueType)) { valueBuffer.flip(); state = STATE_FINISH; if (!onNumber(valueType, valueBuffer, listener)) { logErrorJson("not a number", data, offset, len, pos - valueBuffer.limit()); return false; } listener.onFinishJson(objectOffset, pos - objectOffset + 1); } else { valueBuffer.put(b); } } break; default: if (escape) { logErrorJson("illegal character", data, offset, len, pos); return false; } else { valueBuffer.put(b); } break; } break; case STATE_VALUE_FINISH: switch (b) { case BLANK: break; case COMMA: state = STATE_NEXT_KEY; break; case CURLY_BRACE_RIGHT: state = STATE_FINISH; listener.onFinishJson(objectOffset, pos - objectOffset + 1); break; default: logErrorJson("expecting ,", data, offset, len, pos); return false; } break; case STATE_FINISH: switch (b) { case BLANK: break; case COMMA: state = STATE_BEGIN; break; default: logErrorJson("expecting EOF", data, offset, len, pos); return false; } break; default: logErrorJson("illegal state: " + state, data, offset, len, pos); return false; } } if (state != STATE_FINISH) { logErrorJson("incomplete json", data, offset, len, pos); return false; } return true; } private static boolean basicNumberCheck(ByteBuffer buffer) { byte firstByte = buffer.get(0); return (firstByte >= '0' && firstByte <= '9') || firstByte == '+' || firstByte == '-' || firstByte == '.'; } private boolean onNumber(int type, ByteBuffer buffer, Listener listener) { try { boolean isEmpty = buffer.remaining() == 0; if (isEmpty) { if (!numberEmptyAsZero) { return false; } switch (type) { case INT: return listener.onIntValue(0); case BIGINT: return listener.onLongValue(0); case FLOAT: return listener.onFloatValue(0); case DOUBLE: return listener.onDoubleValue(0); case DATE: return listener.onLongValue(0); case TIME: return listener.onIntValue(0); case DATETIME: return listener.onLongValue(0); default: throw new IllegalStateException("illegal type " + type); } } if (!basicNumberCheck(buffer)) { return false; } switch (type) { case INT: return listener.onIntValue((int) UTF8Util.parseLong(buffer.array(), buffer.position(), buffer.remaining())); case BIGINT: return listener.onLongValue(UTF8Util.parseLong(buffer.array(), buffer.position(), buffer.remaining())); case FLOAT: return listener.onFloatValue(UTF8Util.parseFloat(buffer.array(), buffer.position(), buffer.remaining())); case DOUBLE: return listener.onDoubleValue(UTF8Util.parseDouble(buffer.array(), buffer.position(), buffer.remaining())); case DATE: return listener.onLongValue(DateTimeUtil.parseDate(buffer.array(), buffer.position(), buffer.remaining())); case TIME: return listener.onIntValue(DateTimeUtil.parseTime(buffer.array(), buffer.position(), buffer.remaining())); case DATETIME: return listener.onLongValue(DateTimeUtil.parseDateTime(buffer.array(), buffer.position(), buffer.remaining())); default: throw new IllegalStateException("illegal type " + type); } } catch (NumberFormatException e) { // HACK!!! return false; } } private static void logErrorJson(String format, byte[] data, int offset, int len, int pos) { try { logger.warn("{}, json: {}, error pos: {}", format, new String(data, offset, len, UTF8Util.UTF8_NAME), new String(data, pos, (offset + len) - pos, UTF8Util.UTF8_NAME)); } catch (UnsupportedEncodingException e) { // Should not happen. } } public static interface Listener { void onStartJson(int offset); void onFinishJson(int offset, int len); /** * Found a key, return the value type. * Return <code>-1</code> means you don't care this key-value pair, which will not cause onXXValue fired. */ int onKey(ByteBuffer key, int size); /** * Found a string value, corresponding to last key. */ boolean onStringValue(ByteBuffer value, int size); boolean onIntValue(int value); boolean onLongValue(long value); boolean onFloatValue(float value); boolean onDoubleValue(double value); } private static boolean isNumber(int type) { return type != VARCHAR; } }
25,139
https://github.com/lpatiny/jsGraph/blob/master/src/mixins/graph.mixin.errorbars.js
Github Open Source
Open Source
MIT
2,016
jsGraph
lpatiny
JavaScript
Code
1,566
3,232
import * as util from '../graph.util' var ErrorBarMixin = { doErrorDraw: function( orientation, error, originVal, originPx, xpx, ypx ) { if ( !( error instanceof Array ) )  { error = [ error ]; } var functionName = orientation == 'y' ? 'getY' : 'getX'; var bars = orientation == 'y' ? [ 'top', 'bottom' ] : [ 'left', 'right' ]; var j; if ( isNaN( xpx ) ||  isNaN( ypx ) ) { return; } for ( var i = 0, l = error.length; i < l; i++ ) { if ( error[ i ] instanceof Array ) { // TOP j = bars[ 0 ]; this.errorstyles[ i ].paths[ j ] += " M " + xpx + " " + ypx; this.errorstyles[ i ].paths[ j ] += this.makeError( orientation, i, this[ functionName ]( originVal + error[ i ][ 0 ] ), originPx, j ); j = bars[ 1 ]; this.errorstyles[ i ].paths[ j ] += " M " + xpx + " " + ypx; this.errorstyles[ i ].paths[ j ] += this.makeError( orientation, i, this[ functionName ]( originVal - error[ i ][ 1 ] ), originPx, j ); } else { j = bars[ 0 ]; this.errorstyles[ i ].paths[ j ] += " M " + xpx + " " + ypx; this.errorstyles[ i ].paths[ j ] += this.makeError( orientation, i, this[ functionName ]( originVal + error[ i ] ), originPx, j ); j = bars[ 1 ]; this.errorstyles[ i ].paths[ j ] += " M " + xpx + " " + ypx; this.errorstyles[ i ].paths[ j ] += this.makeError( orientation, i, this[ functionName ]( originVal - error[ i ] ), originPx, j ); } } }, makeError: function( orientation, level, coord, origin, quadOrientation ) { var method; switch ( this.errorstyles[ level ].type ) { case 'bar': method = "makeBar"; break; case 'box': method = "makeBox"; break; } return this[ method + orientation.toUpperCase() ]( coord, origin, this.errorstyles[ level ][ quadOrientation ] ); }, makeBarY: function( coordY, origin, style ) { if ( !coordY ||  !style ) { return; } var width = !util.isNumeric( style.width ) ? 10 : style.width; return " V " + coordY + " m -" + ( width / 2 ) + " 0 h " + ( width ) + " m -" + ( width / 2 ) + " 0 V " + origin + " "; }, makeBoxY: function( coordY, origin, style ) { if ( !coordY ||  !style ) { return; } return " m 5 0 V " + coordY + " h -10 V " + origin + " m 5 0 "; }, makeBarX: function( coordX, origin, style ) { if ( !coordX ||  !style ) { return; } var height = !util.isNumeric( style.width ) ? 10 : style.width; return " H " + coordX + " m 0 -" + ( height / 2 ) + " v " + ( height ) + " m 0 -" + ( height / 2 ) + " H " + origin + " "; }, makeBoxX: function( coordX, origin, style ) { if ( !coordX ||  !style ) { return; } return " v 5 H " + coordX + " v -10 H " + origin + " v 5 "; }, check: function( index, valY, valX ) { var dx, dy; if ( ( this.getType() == Graph.SERIE_LINE ||  this.getType() == Graph.SERIE_SCATTER ) ) { if ( !( dx = this.data[ index * 2 ] ) ||  !( dy = this.data[ index * 2 + 1 ] ) ) { // return; } } if ( dx === undefined ) { return; } for ( var i = 0, l = valY.length; i < l; i++ ) { if ( Array.isArray( valY[ i ] ) ) { if ( !isNaN( valY[ i ][ 0 ] ) ) { this._checkY( dy + valY[ i ][ 0 ] ); } if ( !isNaN( valY[ i ][ 1 ] ) ) { this._checkY( dy - valY[ i ][ 1 ] ); } } else { if ( !isNaN( valY[ i ] ) ) { this._checkY( dy + valY[ i ] ); this._checkY( dy - valY[ i ] ); } } } for ( var i = 0, l = valX.length; i < l; i++ ) { if ( Array.isArray( valX[ i ] ) ) { if ( !isNaN( valX[ i ][ 0 ] ) ) { this._checkX( dx - valX[ i ][ 0 ] ); } if ( !isNaN( valX[ i ][ 1 ] ) ) { this._checkX( dx + valX[ i ][ 1 ] ); } } else { if ( !isNaN( valY[ i ] ) ) { this._checkX( dx - valX[ i ] ); this._checkX( dx + valX[ i ] ); } } } }, /** * Sets the data error values */ setDataError: function( error, noCheck ) { this.error = error; if ( !noCheck ) { for ( let i = 0, l = this.error.length; i < l; i++ ) { if ( this.error[ i ] ) { this.check( i, this.error[ i ][ 0 ], this.error[ i ][ 1 ] ); } } } this.dataHasChanged(); this.graph.updateDataMinMaxAxes(); return this; }, /** * * @example serie.setErrorStyle( [ { type: 'bar', x: {} }, { type: 'box', top: { strokeColor: 'green', fillColor: 'olive' }, bottom: { strokeColor: 'red', fillColor: "#800000" } } ] ); */ setErrorStyle: function( errorstyles ) { var self = this; errorstyles = errorstyles ||  [ 'box', 'bar' ]; // Ensure array if ( !Array.isArray( errorstyles ) ) { errorstyles = [ errorstyles ]; } var styles = []; var pairs = [ [ 'y', 'top', 'bottom' ], [ 'x', 'left', 'right' ] ]; function makePath( style ) { style.dom = document.createElementNS( self.graph.ns, 'path' ); style.dom.setAttribute( 'fill', style.fillColor || 'none' ); style.dom.setAttribute( 'stroke', style.strokeColor || 'black' ); style.dom.setAttribute( 'stroke-opacity', style.strokeOpacity || 1 ); style.dom.setAttribute( 'fill-opacity', style.fillOpacity || 1 ); style.dom.setAttribute( 'stroke-width', style.strokeWidth || 1 ); self.groupMain.appendChild( style.dom ); } for ( var i = 0; i < errorstyles.length; i++ ) { // i is bar or box styles[ i ] = {}; if ( typeof errorstyles[ i ] == "string" ) { errorstyles[ i ] = { type: errorstyles[ i ], y: {} }; } styles[ i ].type = errorstyles[ i ].type; for ( var j = 0, l = pairs.length; j < l; j++ ) { if ( errorstyles[ i ].all ) { errorstyles[ i ][ pairs[ j ][ 1 ] ] = util.extend( true, {}, errorstyles[ i ].all ); errorstyles[ i ][ pairs[ j ][ 2 ] ] = util.extend( true, {}, errorstyles[ i ].all ); } if ( errorstyles[ i ][ pairs[ j ][ 0 ] ] ) { //.x, .y errorstyles[ i ][ pairs[ j ][ 1 ] ] = util.extend( true, {}, errorstyles[ i ][ pairs[ j ][ 0 ] ] ); errorstyles[ i ][ pairs[ j ][ 2 ] ] = util.extend( true, {}, errorstyles[ i ][ pairs[ j ][ 0 ] ] ); } for ( var k = 1; k <= 2; k++ ) { if ( errorstyles[ i ][ pairs[ j ][ k ] ] ) { styles[ i ][ pairs[ j ][ k ] ] = errorstyles[ i ][ pairs[ j ][ k ] ]; makePath( styles[ i ][ pairs[ j ][ k ] ] ); } } } } /* // None is defined if( ! errorstyles[ i ].top && ! errorstyles[ i ].bottom ) { styles[ i ].top = errorstyles[ i ]; styles[ i ].top.dom = document.createElementNS( this.graph.ns, 'path' ); styles[ i ].bottom = errorstyles[ i ]; styles[ i ].bottom.dom = document.createElementNS( this.graph.ns, 'path' ); } else if( errrostyles[ i ].top ) { styles[ i ].bottom = null; // No bottom displayed styles[ i ].top = errrostyles[ i ].top; styles[ i ].top.dom = document.createElementNS( this.graph.ns, 'path' ); } else { styles[ i ].bottom = errorstyles[ i ].bottom; styles[ i ].bottom.dom = document.createElementNS( this.graph.ns, 'path' ); styles[ i ].top = null; } */ this.errorstyles = styles; return this; }, errorDrawInit: function() { var error; // var pathError = "M 0 0 "; if ( this.errorstyles ) { for ( var i = 0, l = this.errorstyles.length; i < l; i++ ) { this.errorstyles[ i ].paths = { top: "", bottom: "", left: "", right: "" }; } } }, errorAddPoint: function( j, dataX, dataY, xpx, ypx ) { var error; if ( this.error && ( error = this.error[ j / 2 ] ) ) { // pathError += "M " + xpx + " " + ypx; if ( error[ 0 ] ) { this.doErrorDraw( 'y', error[ 0 ], dataY, ypx, xpx, ypx ); } if ( error[ 1 ] ) { this.doErrorDraw( 'x', error[ 1 ], dataX, xpx, xpx, ypx ); } } }, errorAddPointBarChart: function( j, posY, xpx, ypx ) { var error; if ( this.error && ( error = this.error[ j ] ) ) { this.doErrorDraw( 'y', error, posY, ypx, xpx, ypx ); } }, errorDraw: function()  { if ( this.error && this.errorstyles ) { for ( var i = 0, l = this.errorstyles.length; i < l; i++ ) { for ( var j in this.errorstyles[ i ].paths ) { if ( this.errorstyles[ i ][ j ] && this.errorstyles[ i ][ j ].dom ) { this.errorstyles[ i ][ j ].dom.setAttribute( 'd', this.errorstyles[ i ].paths[ j ] ); } } } } } }; export default ErrorBarMixin;
18,644
https://github.com/kkcookies99/UAST/blob/master/Dataset/Leetcode/test/9/503.py
Github Open Source
Open Source
MIT
null
UAST
kkcookies99
Python
Code
35
114
class Solution(object): def XXX(self, x): """ :type x: int :rtype: bool """ length = len(str(x)) if length == 1: return True result=[str(x)[i]==str(x)[length-1-i] for i in range(length/2)] # print result if list(set(result))==[True]: return True return False
4,413
https://github.com/TheGrandCoding/discord-bo/blob/master/DiscordBot/Classes/HTMLHelpers/Objects/Label.cs
Github Open Source
Open Source
MIT
null
discord-bo
TheGrandCoding
C#
Code
37
92
using System; using System.Collections.Generic; using System.Text; namespace DiscordBot.Classes.HTMLHelpers.Objects { public class Label : DOMBase { public Label(string text, string id = null, string cls = null) : base("label", id, cls) { RawText = text; } } }
30,357
https://github.com/mattools/MeshViewer/blob/master/meshViewer/+mv/+gui/MeshViewerMainFrame.m
Github Open Source
Open Source
BSD-2-Clause
2,023
MeshViewer
mattools
MATLAB
Code
1,250
4,208
classdef MeshViewerMainFrame < handle %MESHVIEWERMAINFRAME Contains a figure that displays one or several meshes % % Class MeshViewerMainFrame % % Example % MeshViewerMainFrame % % See also % % ------ % Author: David Legland % e-mail: david.legland@inra.fr % Created: 2018-05-24, using Matlab 9.4.0.813654 (R2018a) % Copyright 2018 INRA - BIA-BIBS. %% Properties properties % reference to the main GUI instance Gui; % list of handles to the various gui items Handles; % the scene displayed by obj frame % Contains a collection of meshes. Scene; SceneRenderer; % % % the set of mouse listeners. % % Stored as an array of svui.app.Shape instances % mouseListeners = []; % % % the currently selected tool % currentTool = []; % % the set of selected meshes, stored as an index array SelectedMeshIndices = []; end % end properties %% Constructor methods function obj = MeshViewerMainFrame(gui, scene) obj.Gui = gui; obj.Scene = scene; % create default figure fig = figure(... 'MenuBar', 'none', ... 'NumberTitle', 'off', ... 'NextPlot', 'new', ... 'Name', 'Mesh Viewer'); % create main figure menu setupMenu(fig); setupLayout(fig); % create scene renderer obj.SceneRenderer = mv.gui.SceneRenderer(scene, obj.Handles.MainAxis); obj.Handles.Figure = fig; % updateDisplay(obj); refreshDisplay(obj.SceneRenderer); updateMeshList(obj); updateTitle(obj); % setup listeners associated to the figure set(fig, ... 'CloseRequestFcn', @obj.close, ... 'ResizeFcn', @obj.onFigureResized); % % setup mouse listeners associated to the figure % set(fig, 'WindowButtonDownFcn', @obj.processMouseButtonPressed); % set(fig, 'WindowButtonUpFcn', @obj.processMouseButtonReleased); % set(fig, 'WindowButtonMotionFcn', @obj.processMouseMoved); % % % setup mouse listener for display of mouse coordinates % tool = svui.Gui.tools.ShowCursorPositionTool(obj, 'showMousePosition'); % addMouseListener(obj, tool); % % tool = svui.Gui.tools.SelectionTool(obj, 'selection'); % addMouseListener(obj, tool); % obj.currentTool = tool; set(fig, 'UserData', obj); function setupMenu(hf) % File Menu Definition fileMenu = uimenu(hf, 'Label', '&Files'); addPlugin(fileMenu, mv.plugins.file.CreateNewSceneFrame(), 'New Empty Scene'); addPlugin(fileMenu, mv.plugins.file.OpenFileOFF(), 'Open OFF File...'); addPlugin(fileMenu, mv.plugins.file.OpenFilePLY(), 'Open PLY File...'); addPlugin(fileMenu, mv.plugins.file.OpenMeshAsStructure(), 'Open MeshViewer Mesh File...'); importMeshesMenu = uimenu(fileMenu, 'Label', 'Import'); addPlugin(importMeshesMenu, mv.plugins.file.ImportMeshFromStruct(), 'Mesh struct from Workspace'); addPlugin(importMeshesMenu, mv.plugins.file.ImportMeshVFFromWorkspace(), 'Vertices+Faces from Workspace'); demoMeshesMenu = uimenu(fileMenu, 'Label', 'Sample Meshes'); addPlugin(demoMeshesMenu, mv.plugins.file.CreateTetrahedron(), 'Tetrahedron'); addPlugin(demoMeshesMenu, mv.plugins.file.CreateCube(), 'Cube'); addPlugin(demoMeshesMenu, mv.plugins.file.CreateOctahedron(), 'Octahedron'); addPlugin(demoMeshesMenu, mv.plugins.file.CreateIcosahedron(), 'Icosahedron'); addPlugin(demoMeshesMenu, mv.plugins.file.CreateDodecahedron(), 'Dodecahedron'); addPlugin(demoMeshesMenu, mv.plugins.file.CreateRhombododecahedron(), 'RhomboDodecahedron', true); addPlugin(demoMeshesMenu, mv.plugins.file.CreateTetrakaidecahedron(), 'Tetrakaidecahedron'); addPlugin(demoMeshesMenu, mv.plugins.file.CreateSoccerBall(), 'Soccer Ball'); % uimenu(fileMenu, 'Label', 'Save', 'Separator', 'on'); addPlugin(fileMenu, mv.plugins.file.SaveMeshAsStructure(), 'Save as .mat File...', true); addPlugin(fileMenu, mv.plugins.file.CloseCurrentFrame(), 'Close', true); % addPlugin(fileMenu, mv.plugins.file.Quit(), 'Quit'); % Edit Menu Definition editMenu = uimenu(hf, 'Label', '&Edit'); addPlugin(editMenu, mv.plugins.edit.RenameMesh(), 'Rename'); addPlugin(editMenu, mv.plugins.edit.DuplicateMesh(), 'Duplicate', true); addPlugin(editMenu, mv.plugins.edit.RemoveMesh(), 'Delete'); addPlugin(editMenu, mv.plugins.edit.SelectAll(), 'Select All', true); addPlugin(editMenu, mv.plugins.edit.SelectNone(), 'Select None'); addPlugin(editMenu, mv.plugins.edit.SelectInverse(), 'Inverse Selection'); addPlugin(editMenu, mv.plugins.edit.SetSelectionFaceColor(), 'Set Face Color', true); addPlugin(editMenu, mv.plugins.edit.SetFaceOpacity(), 'Set Face Opacity'); addPlugin(editMenu, mv.plugins.edit.SetEdgeStyle(), 'Set Edge Style'); addPlugin(editMenu, mv.plugins.edit.PrintMeshList(), 'Print Mesh List'); addPlugin(editMenu, mv.plugins.edit.PrintMeshInfo(), 'Mesh Info', true); % Edit Menu Definition viewMenu = uimenu(hf, 'Label', '&View'); addPlugin(viewMenu, mv.plugins.view.ToggleLight(), 'Toggle Light'); addPlugin(viewMenu, mv.plugins.view.ToggleAxisLinesDisplay(), 'Toggle Axis Lines Display'); addPlugin(viewMenu, mv.plugins.view.PrintAxisProperties(), 'Print Axis Properties', true); % Process Menu Definition processMenu = uimenu(hf, 'Label', '&Process'); addPlugin(processMenu, mv.plugins.process.RecenterMesh(), 'Recenter'); transformMenu = uimenu(processMenu, 'Label', 'Transform'); addPlugin(transformMenu, mv.plugins.process.TranslateMesh(), 'Translate...'); addPlugin(transformMenu, mv.plugins.process.RotateMeshMainAxes(), 'Rotate...'); addPlugin(transformMenu, mv.plugins.process.UniformScalingMesh(), 'Scale...'); addPlugin(transformMenu, mv.plugins.process.FlipMesh(), 'Flip...'); addPlugin(processMenu, mv.plugins.process.TriangulateMesh(), 'Triangulate...', true); addPlugin(processMenu, mv.plugins.process.SmoothMesh(), 'Smooth'); addPlugin(processMenu, mv.plugins.process.SubdivideMesh(), 'Subdivide'); simplifyMenu = uimenu(processMenu, 'Label', 'Simplify'); addPlugin(simplifyMenu, mv.plugins.process.SimplifyMeshByReducePatch(), 'Reduce Patch'); addPlugin(simplifyMenu, mv.plugins.process.SimplifyMeshByVertexClustering(), 'Vertex Clustering'); addPlugin(processMenu, mv.plugins.process.IntersectPlaneMesh(), 'Intersect With Plane'); addPlugin(processMenu, mv.plugins.process.EnsureManifoldMesh(), 'Ensure Manifold Mesh'); addPlugin(processMenu, mv.plugins.process.CheckMeshAdjacentFaces(), 'Check Adjacent Faces', true); % Analyze Menu Definition analyzeMenu = uimenu(hf, 'Label', '&Analyze'); addPlugin(analyzeMenu, mv.plugins.analyze.ComputeMeshVolume(), 'Volume'); addPlugin(analyzeMenu, mv.plugins.analyze.ComputeMeshArea(), 'Surface Area'); addPlugin(analyzeMenu, mv.plugins.analyze.ComputeMeshMeanBreadth(), 'Mean Breadth'); addPlugin(analyzeMenu, mv.plugins.analyze.PlotMeshVertexDegreeHistogram(), 'Vertex Degree Histogram', true); end % end of setupMenu function function item = addPlugin(menu, plugin, label, varargin) % creates new item if verLessThan('matlab', '8.4') item = uimenu(menu, 'Label', label, ... 'Callback', @(src, evt) plugin.run(obj, src, evt)); else item = uimenu(menu, 'Label', label, ... 'MenuSelectedFcn', @(src, evt) plugin.run(obj, src, evt)); end % eventually add separator above item if ~isempty(varargin) var = varargin{1}; if islogical(var) set(item, 'Separator', 'On'); end end end function setupLayout(hf) % compute background color of most widgets bgColor = get(0, 'defaultUicontrolBackgroundColor'); if ispc bgColor = 'White'; end set(hf, 'defaultUicontrolBackgroundColor', bgColor); % vertical layout for putting status bar on bottom mainPanel = uix.VBox('Parent', hf, ... 'Units', 'normalized', ... 'Position', [0 0 1 1]); % horizontal panel: main view middle, options left and right horzPanel = uix.HBoxFlex('Parent', mainPanel); % panel for doc info docInfoPanel = uix.VBoxFlex('Parent', horzPanel); % create a default uittree treePanel = uipanel(... 'Parent', docInfoPanel, ... 'Position', [0 0 1 1], ... 'BorderType', 'none', ... 'BorderWidth', 0); obj.Handles.ShapeList = uicontrol(... 'Style', 'listbox', ... 'Parent', treePanel, ... 'Units', 'normalized', ... 'Position', [0 0 1 1], ... 'Max', 2, 'Min', 0, ... % to allow empty selection 'Callback', @obj.onMeshListModified); displayOptionsPanel = uitable(... 'parent', docInfoPanel, ... 'Position', [0 0 1 1] ); docInfoPanel.Heights = [-2 -1]; obj.Handles.DocInfoPanel = docInfoPanel; obj.Handles.DisplayOptionsPanel = displayOptionsPanel; % panel for scene display displayPanel = uix.VBox('Parent', horzPanel); % use a container to prevent layout changes during 3D rotate container = uicontainer('Parent', displayPanel); ax = axes('parent', container, ... 'ActivePositionProperty', 'outerposition', ... 'Units', 'normalized', ... 'Position', [0 0 1 1], ... 'XLim', [-1 1], ... 'YLim', [-1 1], ... 'ZLim', [-1 1], ... 'DataAspectRatio', [1 1 1], ... 'XTick', [], ... 'YTick', [], ... 'ZTick', [], ... 'Box', 'off'); axis(ax, 'equal'); axis(ax, [-1 1 -1 1 -1 1]); % keep widgets handles obj.Handles.MainAxis = ax; horzPanel.Widths = [180 -1]; % info panel for cursor position and value obj.Handles.StatusBar = uicontrol(... 'Parent', mainPanel, ... 'Style', 'text', ... 'String', ' x= y= I=', ... 'HorizontalAlignment', 'left'); % set up relative sizes of layouts mainPanel.Heights = [-1 20]; end end end % end constructors %% General methods methods function addNewMesh(obj, mesh, meshName) % adds a new mesh to the scene, and update displays % add new mesh to the scene mh = createMeshHandle(obj.Scene, mesh, meshName); obj.Scene.addMeshHandle(mh); % update display updateDisplay(obj); updateMeshList(obj); end end %% Management of selection methods function handleList = selectedMeshHandleList(obj) % returns the list of selected mesh handles handleList = {}; inds = obj.SelectedMeshIndices; if isempty(inds) return; end handleList = obj.Scene.MeshHandleList; if length(handleList) < max(inds) error('Wrong index for mesh handle selection'); end handleList = handleList(inds); end function setSelectedMeshIndices(obj, indices) obj.SelectedMeshIndices = indices; set(obj.Handles.ShapeList, 'Max', 2, 'Min', 0, 'Value', indices); end end %% Widget callbacks methods function updateDisplay(obj) % refresh document display: clear axis, draw each shape, udpate axis disp('update Display'); refreshDisplay(obj.SceneRenderer); end function updateMeshSelectionDisplay(obj) %#ok<MANU> % update the selected state of each shape % % extract the list of handles in current axis % ax = obj.Handles.MainAxis; % children = get(ax, 'Children'); % % % iterate over children % for i = 1:length(children) % % Extract shape referenced by current handle, if any % shape = get(children(i), 'UserData'); % % % update selection state of current shape % if any(shape == obj.selectedMeshIndices) % set(children(i), 'Selected', 'on'); % else % set(children(i), 'Selected', 'off'); % end % end end function updateTitle(obj) % set up title of the figure, containing name of doc title = 'MeshViewer'; % title = sprintf('%s - MeshViewer', obj.doc.name); set(obj.Handles.Figure, 'Name', title); end function updateMeshList(obj) % Refresh the shape tree when a shape is added or removed disp('update shape list'); nMeshes = length(obj.Scene.MeshHandleList); shapeNames = cell(nMeshes, 1); inds = []; for i = 1:nMeshes mh = obj.Scene.MeshHandleList{i}; % create name for current shape name = mh.Name; if isempty(mh.Name) name = ['(' 'Mesh struct' ')']; end shapeNames{i} = name; end set(obj.Handles.ShapeList, ... 'String', shapeNames, ... 'Min', 0, 'Max', nMeshes+2, ... 'Value', inds); end end %% Widget callbacks methods function onMeshListModified(obj, varargin) % when user click on panel containing list of mesh handles, % determines which names are selected and updates index of mesh % handles accordingly disp('mesh selection list updated'); inds = get(obj.Handles.ShapeList, 'Value'); obj.SelectedMeshIndices = inds; end end %% Figure management methods function close(obj, varargin) % disp('Close shape viewer frame'); delete(obj.Handles.Figure); end function onFigureResized(obj, varargin) % updateMeshSelectionDisplay(obj); end end end % end classdef
49,623
https://github.com/SoulForMachine/GLSlayer/blob/master/source/opengl/GLFramebuffer.cpp
Github Open Source
Open Source
MIT
null
GLSlayer
SoulForMachine
C++
Code
400
1,797
#include <cassert> #include <malloc.h> #include <cstdlib> #include "GLTexture.h" #include "GLFramebuffer.h" // =================== Renderbuffer ================== #define STATE_MACHINE_HACK \ if(_id != _glState->renderbuffer) \ { \ glBindRenderbuffer(_target, _id); \ _glState->renderbuffer = _id; \ } namespace gls::internals { bool GLRenderbuffer::Create(GLState* gl_state, sizei samples, PixelFormat internal_format, sizei width, sizei height) { if (_id) return false; _glState = gl_state; glGenRenderbuffers(1, &_id); if (!_id) return false; glBindRenderbuffer(GL_RENDERBUFFER, _id); _glState->renderbuffer = _id; _resType = ResourceType::Renderbuffer; _target = GL_RENDERBUFFER; glRenderbufferStorageMultisample(GL_RENDERBUFFER, samples, GetGLEnum(internal_format), width, height); return true; } void GLRenderbuffer::Destroy() { if (_id) { if (_id == _glState->renderbuffer) { glBindRenderbuffer(GL_RENDERBUFFER, 0); _glState->renderbuffer = 0; } glDeleteRenderbuffers(1, &_id); _id = 0; } } // =================== Framebuffer ================== #undef STATE_MACHINE_HACK #define STATE_MACHINE_HACK \ if(_id != _glState->drawFbuf) \ { \ glBindFramebuffer(_target, _id); \ _glState->drawFbuf = _id; \ } bool GLFramebuffer::Create(GLState* gl_state) { if (_id) return false; _glState = gl_state; glGenFramebuffers(1, &_id); if (!_id) return false; _target = GL_DRAW_FRAMEBUFFER; _resType = ResourceType::Framebuffer; glBindFramebuffer(_target, _id); _glState->drawFbuf = _id; return true; } bool GLFramebuffer::CreateWithoutAttachments(GLState* gl_state, const FramebufferParams& params) { if (Create(gl_state)) { glFramebufferParameteri(_target, GL_FRAMEBUFFER_DEFAULT_WIDTH, params.width); glFramebufferParameteri(_target, GL_FRAMEBUFFER_DEFAULT_HEIGHT, params.height); glFramebufferParameteri(_target, GL_FRAMEBUFFER_DEFAULT_LAYERS, params.layers); glFramebufferParameteri(_target, GL_FRAMEBUFFER_DEFAULT_SAMPLES, params.samples); glFramebufferParameteri(_target, GL_FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS, params.fixedSampleLocations); return true; } return false; } void GLFramebuffer::Destroy() { if (_id) { if (_id == _glState->drawFbuf) { glBindFramebuffer(GL_DRAW_FRAMEBUFFER, 0); _glState->drawFbuf = 0; } if (_id == _glState->readFbuf) { glBindFramebuffer(GL_READ_FRAMEBUFFER, 0); _glState->readFbuf = 0; } glDeleteFramebuffers(1, &_id); _id = 0; } } void GLFramebuffer::AttachTexture(AttachmentBuffer attachment, ITexture* texture, int level) { assert(_id); STATE_MACHINE_HACK glFramebufferTexture(_target, GetGLEnum(attachment), dyn_cast_ptr<GLTexture*>(texture)->GetID(), level); } void GLFramebuffer::AttachTextureLayer(AttachmentBuffer attachment, ITexture* texture, int level, int layer) { assert(_id); STATE_MACHINE_HACK glFramebufferTextureLayer(_target, GetGLEnum(attachment), dyn_cast_ptr<GLTexture*>(texture)->GetID(), level, layer); } void GLFramebuffer::AttachTextureFace(AttachmentBuffer attachment, ITexture* texture, int level, CubeFace face) { assert(_id); STATE_MACHINE_HACK glFramebufferTexture2D(_target, GetGLEnum(attachment), GetGLEnum(face), dyn_cast_ptr<GLTexture*>(texture)->GetID(), level); } void GLFramebuffer::AttachRenderbuffer(AttachmentBuffer attachment, IRenderbuffer* renderbuffer) { assert(_id); STATE_MACHINE_HACK glFramebufferRenderbuffer(_target, GetGLEnum(attachment), GL_RENDERBUFFER, dyn_cast_ptr<GLRenderbuffer*>(renderbuffer)->GetID()); } FramebufferStatus GLFramebuffer::CheckStatus() { assert(_id); STATE_MACHINE_HACK GLenum status = glCheckFramebufferStatus(_target); return GetFromGLEnum<FramebufferStatus>(status); } void GLFramebuffer::InvalidateFramebuffer(int num_attachments, const AttachmentBuffer* attachments) { assert(_id); STATE_MACHINE_HACK if (num_attachments < 1 || num_attachments > 16) { assert(false); return; } GLenum* attach_enums = (GLenum*)alloca(sizeof(GLenum) * num_attachments); for (int i = 0; i < num_attachments; ++i) attach_enums[i] = GetGLEnum(attachments[i]); glInvalidateFramebuffer(_target, num_attachments, attach_enums); } void GLFramebuffer::InvalidateSubFramebuffer(int num_attachments, const AttachmentBuffer* attachments, int x, int y, int width, int height) { assert(_id); STATE_MACHINE_HACK if (num_attachments < 1 || num_attachments > 16) { assert(false); return; } GLenum* attach_enums = (GLenum*)alloca(sizeof(GLenum) * num_attachments); for (int i = 0; i < num_attachments; ++i) attach_enums[i] = GetGLEnum(attachments[i]); glInvalidateSubFramebuffer(_target, num_attachments, attach_enums, x, y, width, height); } } // namespace gls::internals
46,202
https://github.com/3846masa/remark-crossref/blob/master/src/definitions.ts
Github Open Source
Open Source
MIT
2,020
remark-crossref
3846masa
TypeScript
Code
39
97
import * as mdast from 'mdast'; declare module 'mdast' { export interface CrossReferenceLabel extends mdast.Literal { type: 'crossReferenceLabel'; label: string; options: { [key: string]: any }; } export interface CrossReference extends mdast.Literal { type: 'crossReference'; identifiers: string[]; } }
10,471
https://github.com/FatkullinT/Artice/blob/master/src/Artice.Core/Models/Audio.cs
Github Open Source
Open Source
MIT
2,022
Artice
FatkullinT
C#
Code
11
27
namespace Artice.Core.Models { public class Audio : Attachment { } }
28,830
https://github.com/qinghuizhao/fblualib/blob/master/fblualib/python/CMakeLists.txt
Github Open Source
Open Source
BSD-3-Clause
2,017
fblualib
qinghuizhao
CMake
Code
240
1,237
# Copyright (c) 2014, Facebook, Inc. # All rights reserved. # # This source code is licensed under the BSD-style license found in the # LICENSE file in the root directory of this source tree. An additional grant # of patent rights can be found in the PATENTS file in the same directory. # CMAKE_MINIMUM_REQUIRED(VERSION 2.8.7 FATAL_ERROR) ENABLE_TESTING() # Torch messes this up SET(SAVED_CMAKE_INSTALL_PREFIX ${CMAKE_INSTALL_PREFIX}) SET(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake" "${CMAKE_MODULE_PATH}") ADD_DEFINITIONS(-DNO_FOLLY) ADD_DEFINITIONS(-DNO_THRIFT) ADD_DEFINITIONS(-DNDEBUG) INCLUDE(MultiLevelIncludes) MLI_SET_DEPTH(1) FIND_PACKAGE(Glog REQUIRED) FIND_PACKAGE(Torch REQUIRED) SET(CMAKE_PREFIX_PATH ${Torch_INSTALL_PREFIX}) FIND_PACKAGE(THPP REQUIRED) FIND_PACKAGE(Boost REQUIRED COMPONENTS thread) FIND_PACKAGE(PythonInterp 2.7) if(APPLE) find_program(PYTHON_CONFIG_EXECUTABLE python-config) if (NOT PYTHON_CONFIG_EXECUTABLE) message(SEND_ERROR "python-config executable not found, but python is required.") endif() # using "python-config --prefix" so that cmake always uses the python that is # in the user's path, this is a fix for homebrew on Mac: # https://cmake.org/Bug/view.php?id=14809 execute_process(COMMAND ${PYTHON_CONFIG_EXECUTABLE} --prefix OUTPUT_VARIABLE python_prefix OUTPUT_STRIP_TRAILING_WHITESPACE) set(PYTHON_INCLUDE_DIR ${python_prefix}/include/python${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}) set(PYTHON_LIBRARY ${python_prefix}/lib/libpython${PYTHON_VERSION_MAJOR}.${PYTHON_VERSION_MINOR}${CMAKE_SHARED_LIBRARY_SUFFIX}) endif() FIND_PACKAGE(PythonLibs ${PYTHON_VERSION_STRING} REQUIRED) IF (PYTHONLIBS_VERSION_STRING VERSION_GREATER "3" AND PYTHONLIBS_VERSION_STRING VERSION_GREATER "2") MESSAGE(FATAL_ERROR "Python Version should be < 3.0, but found python version: ${PYTHONLIBS_VERSION_STRING}") ENDIF (PYTHONLIBS_VERSION_STRING VERSION_GREATER "3" AND PYTHONLIBS_VERSION_STRING VERSION_GREATER "2") FIND_PACKAGE(NumPy REQUIRED) FIND_LIBRARY(lib_luaT luaT HINTS ${Torch_INSTALL_LIB}) IF(NOT lib_luaT) MESSAGE(FATAL_ERROR "libluaT not found") ENDIF() INCLUDE_DIRECTORIES( ${GLOG_INCLUDE_DIR} ${THPP_INCLUDE_DIR} ${PYTHON_INCLUDE_DIRS} ${NUMPY_INCLUDE_DIRS} ${Boost_INCLUDE_DIRS} ) SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++14") SET(src Debug.cpp Lib.cpp LuaToPython.cpp NumpyArrayAllocator.cpp PythonToLua.cpp Ref.cpp Storage.cpp Utils.cpp ) ADD_LIBRARY(lua_module MODULE ${src}) SET_TARGET_PROPERTIES(lua_module PROPERTIES PREFIX "" OUTPUT_NAME "lib" COMPILE_DEFINITIONS "LUAOPEN=luaopen_fb_python_lib") TARGET_LINK_LIBRARIES(lua_module dl luajit TH ${lib_luaT} ${Boost_THREAD_LIBRARIES} ${GLOG_LIBRARIES} ${THPP_LIBRARIES} ${PYTHON_LIBRARIES} ) SET(CMAKE_INSTALL_PREFIX ${SAVED_CMAKE_INSTALL_PREFIX}) INSTALL(TARGETS lua_module DESTINATION "${ROCKS_LIBDIR}/fb/python") INSTALL(DIRECTORY "fb" DESTINATION "${ROCKS_LUADIR}" FILES_MATCHING PATTERN "*.lua")
49,516
https://github.com/vanrez-nez/creative-code-starter/blob/master/src/scripts/utils.js
Github Open Source
Open Source
MIT
2,019
creative-code-starter
vanrez-nez
JavaScript
Code
32
102
export function GetShader(name) { const vertEl = document.getElementById(`vertex-${name}`); const fragEl = document.getElementById(`fragment-${name}`); if (!vertEl || !fragEl) { throw `Error: couldn't load shader: ${name}`; } return { vertex: vertEl.textContent, fragment: fragEl.textContent, }; }
22,064
https://github.com/NCIP/psc/blob/master/utility/osgimosis/src/test/java/edu/northwestern/bioinformatics/studycalendar/utility/osgimosis/EncapsulatedCollectionTest.java
Github Open Source
Open Source
BSD-3-Clause
2,021
psc
NCIP
Java
Code
439
1,711
/*L * Copyright Northwestern University. * * Distributed under the OSI-approved BSD 3-Clause License. * See http://ncip.github.io/psc/LICENSE.txt for details. */ package edu.northwestern.bioinformatics.studycalendar.utility.osgimosis; import edu.northwestern.bioinformatics.studycalendar.utility.osgimosis.people.DefaultPerson; import edu.northwestern.bioinformatics.studycalendar.utility.osgimosis.people.Person; import java.util.Arrays; import java.util.Iterator; import java.util.LinkedList; import java.util.List; /** * @author Rhett Sutphin */ public class EncapsulatedCollectionTest extends EncapsulatedCollectionTestCase { private List<Object> farCollection; private EncapsulatedCollection<Person> encapsulated; private DefaultPerson nearPolo, nearAlexander, nearVespucci; @Override public void setUp() throws Exception { super.setUp(); farCollection = new LinkedList<Object>(Arrays.asList( farPerson("Polo"), farPerson("Alexander") )); encapsulated = new EncapsulatedCollection<Person>(farCollection, membrane, defaultClassLoader()); nearPolo = new DefaultPerson("Polo", "traveler"); nearAlexander = new DefaultPerson("Alexander", "traveler"); nearVespucci = new DefaultPerson("Vespucci", "traveler"); } public void testSizeIsCorrect() throws Exception { assertEquals(2, encapsulated.size()); } public void testIsNotEmpty() throws Exception { assertFalse(encapsulated.isEmpty()); } public void testContainsEquivalentPerson() throws Exception { assertTrue(encapsulated.contains(nearPolo)); } public void testDoesNotContainUnknownPerson() throws Exception { assertFalse(encapsulated.contains(nearVespucci)); } public void testCanIterate() throws Exception { Iterator<Person> nearIterator = encapsulated.iterator(); assertTrue(nearIterator.hasNext()); assertEquals("Polo", nearIterator.next().getName()); assertTrue(nearIterator.hasNext()); assertEquals("Alexander", nearIterator.next().getName()); assertFalse(nearIterator.hasNext()); } public void testToObjectArray() throws Exception { Object[] array = encapsulated.toArray(); assertEquals("Wrong number of elements", farCollection.size(), array.length); assertTrue("First element is wrong type", array[0] instanceof Person); assertEquals("First element is wrong person", "Polo", ((Person) array[0]).getName()); assertTrue("Second element is wrong type", array[1] instanceof Person); assertEquals("Second element is wrong person", "Alexander", ((Person) array[1]).getName()); } @SuppressWarnings({ "ToArrayCallWithZeroLengthArrayArgument" }) public void testToTypedEmptyArray() throws Exception { Person[] array = encapsulated.toArray(new Person[0]); assertEquals("Wrong number of elements", farCollection.size(), array.length); assertEquals("First element is wrong person", "Polo", array[0].getName()); assertEquals("Second element is wrong person", "Alexander", array[1].getName()); } public void testToTypedSizedArray() throws Exception { Person[] expected = new Person[2]; Person[] actual = encapsulated.toArray(expected); assertSame("Input array not reused", expected, actual); assertEquals("First element is wrong person", "Polo", actual[0].getName()); assertEquals("Second element is wrong person", "Alexander", actual[1].getName()); } public void testAdd() throws Exception { encapsulated.add(nearVespucci); assertEquals(3, encapsulated.size()); Object newFarObj = farCollection.get(2); assertTrue("New item not proxied", newFarObj.getClass().getName().contains("Enhancer")); assertEquals("New item in wrong CL", loaderA, newFarObj.getClass().getClassLoader().getParent()); assertSame("New item not recoverable", nearVespucci, getEncapsulatedItem(2)); assertSame("New item not recoverable from membrane", nearVespucci, membrane.farToNear(newFarObj)); assertSame("New item not recoverable from membrane", newFarObj, membrane.traverse(nearVespucci, loaderA)); assertTrue("Collection does not contain new item", encapsulated.contains(nearVespucci)); } public void testRemoveWhenExists() throws Exception { assertTrue(encapsulated.remove(nearPolo)); assertEquals(1, encapsulated.size()); assertEquals("Alexander", encapsulated.iterator().next().getName()); } public void testRemoveWhenDoesNotExist() throws Exception { assertFalse(encapsulated.remove(nearVespucci)); } public void testContainsAllWhenDoes() throws Exception { assertTrue(encapsulated.containsAll(Arrays.asList(nearAlexander, nearPolo))); } public void testContainsAllWhenDoesNot() throws Exception { assertFalse(encapsulated.containsAll(Arrays.asList(nearAlexander, nearVespucci))); } public void testAddAll() throws Exception { assertTrue(encapsulated.addAll(Arrays.asList(nearVespucci))); assertEquals(3, encapsulated.size()); assertTrue(encapsulated.contains(nearVespucci)); } public void testRemoveAllWithNoOverlap() throws Exception { assertFalse(encapsulated.removeAll(Arrays.asList(nearVespucci))); assertEquals(2, encapsulated.size()); } public void testRemoveAllWithOverlap() throws Exception { assertTrue(encapsulated.removeAll(Arrays.asList(nearVespucci, nearPolo))); assertEquals(1, encapsulated.size()); assertTrue(encapsulated.contains(nearAlexander)); } public void testRetainAllWithNoOverlap() throws Exception { assertTrue(encapsulated.retainAll(Arrays.asList(nearVespucci))); assertTrue(encapsulated.isEmpty()); } public void testRetainAllWithOverlap() throws Exception { assertTrue(encapsulated.retainAll(Arrays.asList(nearVespucci, nearPolo))); assertEquals(1, encapsulated.size()); assertTrue(encapsulated.contains(nearPolo)); } private Person getEncapsulatedItem(int index) { Iterator<Person> it = encapsulated.iterator(); while (index > 0) { assertTrue("Insufficient elements in collection", it.hasNext()); it.next(); index--; } return it.next(); } }
2,708
https://github.com/trongcuong1710/FoodyCrawler/blob/master/FoodyCrawler/Model/PlacesList.swift
Github Open Source
Open Source
MIT
null
FoodyCrawler
trongcuong1710
Swift
Code
55
137
// // PlacesList.swift // FoodyCrawler // // Created by Cole Doan on 10/18/17. // Copyright © 2017 Trong Cuong Doan. All rights reserved. // import Foundation import Freddy struct PlacesList: JSONDecodable { let total: Int var items = [PlaceItem]() init(json: JSON) throws { total = try json.getInt(at: "Total") items = try json.decodedArray(at: "Items") } }
34,949
https://github.com/JLimperg/lean4/blob/master/tests/playground/hashable.lean
Github Open Source
Open Source
Apache-2.0
2,022
lean4
JLimperg
Lean
Code
382
765
set_option trace.Elab.Deriving.hashable true inductive SimpleInd | A | B deriving Hashable theorem «inductive fields have different base hashes» : ∀ x, hash x = match x with | SimpleInd.A => 0 | SimpleInd.B => 1 := λ x => rfl mutual inductive Foo : Type → Type | A : Int → (3 = 3) → String → Foo Int | B : Bar → Foo String deriving Hashable inductive Bar | C | D : Foo String → Bar deriving Hashable end #eval hash (Foo.A 3 rfl "bla") #eval hash (Foo.B $ Bar.D $ Foo.B Bar.C) inductive ManyConstructors | A | B | C | D | E | F | G | H | I | J | K | L | M | N | O | P | Q | R | S | T | U | V | W | X | Y | Z deriving Hashable theorem «Each constructor is hashed as a different number to make mixing better» : ∀ x, hash x = match x with | ManyConstructors.A => 0 | ManyConstructors.B => 1 | ManyConstructors.C => 2 | ManyConstructors.D => 3 | ManyConstructors.E => 4 | ManyConstructors.F => 5 | ManyConstructors.G => 6 | ManyConstructors.H => 7 | ManyConstructors.I => 8 | ManyConstructors.J => 9 | ManyConstructors.K => 10 | ManyConstructors.L => 11 | ManyConstructors.M => 12 | ManyConstructors.N => 13 | ManyConstructors.O => 14 | ManyConstructors.P => 15 | ManyConstructors.Q => 16 | ManyConstructors.R => 17 | ManyConstructors.S => 18 | ManyConstructors.T => 19 | ManyConstructors.U => 20 | ManyConstructors.V => 21 | ManyConstructors.W => 22 | ManyConstructors.X => 23 | ManyConstructors.Y => 24 | ManyConstructors.Z => 25 := λ x => rfl structure Person := FirstName : String LastName : String Age : Nat deriving Hashable structure Company := Name : String CEO : Person NumberOfEmployees : Nat deriving Hashable -- structures hash just fine #eval hash { Name := "Microsoft" CEO := { FirstName := "Satya", LastName := "Nadella", Age := 53 } NumberOfEmployees := 165000 : Company } -- 10875484723257753924 -- syntax(name := tst) "tst" : command -- @[commandElab «tst»] def elab_tst : CommandElab := fun stx => do -- let declNames := #[`Foo, `Bar] -- let declNames := #[`Foo] -- discard $ mkHashableHandler declNames -- pure ()
25,491
https://github.com/bitJun/vue-tb/blob/master/partner/resources/assets/js/components/common/MyUpload.vue
Github Open Source
Open Source
MIT
2,018
vue-tb
bitJun
Vue
Code
98
300
<script> import Upload from 'iview/src/components/upload/upload.vue'; export default { name: 'MyUpload', mixins: [ Upload ], props: { maxCount: { type: Number }, onExceededCount: { type: Function, default () { return {}; } } }, methods: { uploadFiles (files) { let postFiles = Array.prototype.slice.call(files); const check = (this.fileList.length + postFiles.length) <= this.maxCount && this.maxCount > 0; if (!check) { this.onExceededCount(files); const n = this.maxCount - this.fileList.length; if(n > 0) { postFiles = postFiles.slice(0, n); } else { return; } } if (!this.multiple) postFiles = postFiles.slice(0, 1); if (postFiles.length === 0) return; postFiles.forEach(file => { this.upload(file); }); }, }, }; </script>
19,221
https://github.com/dengdads/Adyeshach-1/blob/master/src/main/kotlin/ink/ptms/adyeshach/common/entity/type/AdyMinecartFurnace.kt
Github Open Source
Open Source
MIT
null
Adyeshach-1
dengdads
Kotlin
Code
61
238
package ink.ptms.adyeshach.common.entity.type import ink.ptms.adyeshach.common.entity.EntityTypes /** * @author sky * @date 2020/8/4 23:15 */ class AdyMinecartFurnace : AdyMinecart(EntityTypes.MINECART_FURNACE) { init { /* 1.16,1.15,1.14 13 ->Has fuel 1.13,1.12,1.11,1.10 12 ->Has fuel 1.9 11 ->Has fuel */ registerMeta(at(11400 to 13, 11000 to 12, 10900 to 11), "hasFuel", false) } fun isHasFuel(): Boolean { return getMetadata("hasFuel") } fun setFuel(hasFuel: Boolean) { setMetadata("hasFuel", hasFuel) } }
24,293
https://github.com/rds13/dotfiles/blob/master/bin/git-copy-to-remote
Github Open Source
Open Source
MIT
2,018
dotfiles
rds13
Shell
Code
53
100
#!/bin/bash # # Copy all branches from remote origin to specified remote # if [[ $# -ne 1 ]] ; then exit else remote=$1 fi for branch in `git branch -a | grep "remotes/origin" | grep -v HEAD | grep -v master`; do git branch --track ${branch##*/} $branch done git push $remote --all
12,425
https://github.com/Google-Patika-dev-Casual-Game-Bootcapms/galaxy-destroyer/blob/master/Assets/Game/UserInterface/Splash/Logo.cs
Github Open Source
Open Source
MIT
2,022
galaxy-destroyer
Google-Patika-dev-Casual-Game-Bootcapms
C#
Code
91
345
namespace SpaceShooterProject.UserInterface { using UnityEngine; using UnityEngine.UI; using DG.Tweening; using System; public class Logo : MonoBehaviour, ICanvasElement { [SerializeField] private Image image; public void Activate() { } public void Deactivate() { } public void Init() { var imageRect = image.GetComponent<RectTransform>(); } public void SetScreenSize(Vector2 vector2) { image.GetComponent<RectTransform>().sizeDelta = new Vector2(); } public void PlayFadeInAnimation(float duration) { if (image == null) { return; } image.DOColor(new Color(image.color.r, image.color.g, image.color.b, 1), duration).SetEase(Ease.InOutSine); } public void PlayFadeOutAnimation(float duration) { if (image == null) { return; } image.DOColor(new Color(image.color.r, image.color.g, image.color.b, 0), duration).SetEase(Ease.InOutSine); } } }
19,925
https://github.com/mnabila/dotfiles/blob/master/fish/.config/fish/conf.d/paste_url.fish
Github Open Source
Open Source
MIT
2,023
dotfiles
mnabila
Fish
Code
32
80
function fish_clipboard_paste set -l data if not type -q xclip # Return if `xclip` failed. return 1 end set data (xclip -o) if test -n "$data" commandline -i -- "\"$data\"" end end
44,949
https://github.com/lngka/nightspots/blob/master/app/controllers/server.goingCountByID.js
Github Open Source
Open Source
MIT
null
nightspots
lngka
JavaScript
Code
186
544
"use strict"; const path = require("path"); const Business = require(path.join(process.cwd(), "app/models/business.js")); module.exports = function(yelpID, callback) { if (!yelpID || typeof yelpID !== "string") { var err = new Error("Invalid/Missing yelpID: get going count without yelpID impossible"); return callback(err, null); } else { Business.findOne({"yelpID": yelpID}, "goingCount yelpID", function(err, doc) { if (err) return callback(err, null); if (doc) { return callback(null, doc); } else { // create if not found var goingCount = fakeGoingCount(); var newBusiness = new Business({ "yelpID": yelpID, "goingCount": goingCount, "going": [] }); // save and find again newBusiness.save(function(err) { if (err) return callback(err, null); Business.findOne({"yelpID": yelpID}, "goingCount yelpID", function(err, doc) { return callback(err, doc); }); }); } }); } }; function fakeGoingCount() { var firstRoll = Math.random().toFixed(2) * 100; var secondRoll = 0; if (firstRoll < 40) { return secondRoll; } if (firstRoll < 60) { secondRoll = Math.random().toFixed(2) * 10; return Math.floor(secondRoll); } if (firstRoll < 80) { secondRoll = Math.random().toFixed(2) * 20; return Math.floor(secondRoll); } if (firstRoll < 90) { secondRoll = Math.random().toFixed(2) * 50; return Math.floor(secondRoll); } if (firstRoll < 100) { secondRoll = Math.random().toFixed(2) * 100; return Math.floor(secondRoll); } }
22,935
https://github.com/jedwards1211/imagefun/blob/master/src/util/pipeline.js
Github Open Source
Open Source
MIT
null
imagefun
jedwards1211
JavaScript
Code
18
43
/** * @prettier */ import { flow } from 'lodash/fp' export const pipeline = (input, ...args) => flow(...args)(input)
42,126
https://github.com/gicmo/CaManager/blob/master/src/main/java/de/lmu/bio/calcium/model/CaNeuron.java
Github Open Source
Open Source
BSD-3-Clause
2,019
CaManager
gicmo
Java
Code
294
817
package de.lmu.bio.calcium.model; import java.util.ArrayList; import java.util.Collections; import java.util.Comparator; import java.util.Enumeration; public class CaNeuron extends CaGroup { private String age; private String comment; private String region; private String commonFilePrefix; private String sex; private String condition; private String subregion; private String litter; private String experiment; public CaNeuron(String name) { super(name); } public String getName() { return (String) getUserObject(); } public void setName(String value) { setUserObject(value); } public String getExperiment() { return experiment; } public void setExperiment(String experiment) { this.experiment = experiment; } public String getAge() { return age; } public void setAge(String age) { this.age = age; } public String getComment() { return comment; } public void setComment(String comment) { this.comment = comment; } @Override public boolean allowImages() { return true; } public String getRegion() { return region; } public void setRegion(String region) { this.region = region; } public String getSex() { return sex; } public void setSex(String sex) { this.sex = sex; } public String getCondition() { return condition; } public void setCondition(String condition) { this.condition = condition; } public String getSubregion() { return subregion; } public void setSubregion(String subregion) { this.subregion = subregion; } public String getLitter() { return litter; } public void setLitter(String litter) { this.litter = litter; } public String getCommonFilePrefix() { return commonFilePrefix; } public void setCommonFilePrefix(String commonFilePrefix) { this.commonFilePrefix = commonFilePrefix; } public ArrayList<CaImage> getImages(boolean ascending) { ArrayList<CaImage> imgList = new ArrayList<CaImage>(); Enumeration en = this.breadthFirstEnumeration(); Object o; while (en.hasMoreElements()) { o = en.nextElement(); if (!(o instanceof CaImage)) { continue; } CaImage image = (CaImage) o; imgList.add(image); } final int descending = ascending ? -1 : 1; Collections.sort(imgList, new Comparator<CaImage>() { @Override public int compare(CaImage a, CaImage b) { long dta = a.getMTime(); long dtb = b.getMTime(); return descending * (int) (dtb - dta); } }); return imgList; } }
40,229
https://github.com/Roleren/ORFik/blob/master/man/save.experiment.Rd
Github Open Source
Open Source
MIT
2,023
ORFik
Roleren
R
Code
89
406
% Generated by roxygen2: do not edit by hand % Please edit documentation in R/experiment_IO.R \name{save.experiment} \alias{save.experiment} \title{Save \code{\link{experiment}} to disc} \usage{ save.experiment(df, file) } \arguments{ \item{df}{an ORFik \code{\link{experiment}}} \item{file}{name of file to save df as} } \value{ NULL (experiment save only) } \description{ Save \code{\link{experiment}} to disc } \examples{ df <- ORFik.template.experiment() ## Save with: #save.experiment(df, file = "path/to/save/experiment.csv") ## Identical (.csv not needed, can be added): #save.experiment(df, file = "path/to/save/experiment") } \seealso{ Other ORFik_experiment: \code{\link{ORFik.template.experiment.zf}()}, \code{\link{ORFik.template.experiment}()}, \code{\link{bamVarName}()}, \code{\link{create.experiment}()}, \code{\link{experiment-class}}, \code{\link{filepath}()}, \code{\link{libraryTypes}()}, \code{\link{organism,experiment-method}}, \code{\link{outputLibs}()}, \code{\link{read.experiment}()}, \code{\link{validateExperiments}()} } \concept{ORFik_experiment}
46,803
https://github.com/ZeroCho/DefinitelyTyped/blob/master/types/ember__test-helpers/dom/trigger-event.d.ts
Github Open Source
Open Source
MIT
2,022
DefinitelyTyped
ZeroCho
TypeScript
Code
16
40
import { Target } from '@ember/test-helpers'; export default function triggerEvent(target: Target, eventType: string, options?: object): Promise<void>;
2,245
https://github.com/LoganPletcher/Year-2/blob/master/Graphics/tutorials/RenderingGeomApplication.h
Github Open Source
Open Source
MIT
null
Year-2
LoganPletcher
C
Code
60
192
#pragma once #include "BaseApplication.h" #include <glm/vec4.hpp> // forward declared to reduce dependencies class Camera; class RenderingGeomApplication : public BaseApplication { public: RenderingGeomApplication(); virtual ~RenderingGeomApplication(); virtual bool startup(); virtual void shutdown(); virtual bool update(float deltaTime); virtual void draw(); private: Camera* m_camera; struct Vertex { glm::vec4 position; glm::vec4 colour; }; unsigned int m_vao, m_vbo, m_ibo; unsigned int m_indexCount; unsigned int m_program; };
28,097
https://github.com/DistributedCollective/oracle-based-amm/blob/master/solidity/contracts/helpers/TestChainlinkPriceOracle.sol
Github Open Source
Open Source
Apache-2.0
2,021
oracle-based-amm
DistributedCollective
Solidity
Code
61
171
pragma solidity 0.4.26; import "../utility/interfaces/IConsumerPriceOracle.sol"; /* Chainlink price oracle mock */ contract TestChainlinkPriceOracle is IConsumerPriceOracle { int256 private answer; uint256 private timestamp; function setAnswer(int256 _answer) public { answer = _answer; } function setTimestamp(uint256 _timestamp) public { timestamp = _timestamp; } function latestAnswer() external view returns (int256) { return answer; } function latestTimestamp() external view returns (uint256) { return timestamp; } }
21,985
https://github.com/khongten001/oblivion-netbeans-plugin/blob/master/Oblivion/src/org/fundacionjala/oblivion/apex/editor/preferences/FormatOptions.java
Github Open Source
Open Source
MIT
2,017
oblivion-netbeans-plugin
khongten001
Java
Code
168
674
/* * Copyright (c) Fundacion Jala. All rights reserved. * Licensed under the MIT license. See LICENSE file in the project root for full license information. */ package org.fundacionjala.oblivion.apex.editor.preferences; import java.util.HashMap; import java.util.Map; import java.util.prefs.Preferences; import static org.fundacionjala.oblivion.apex.editor.preferences.BracesValueOptions.*; import static org.fundacionjala.oblivion.apex.editor.preferences.OrderingValueOptions.*; /** * This class manages the formatting options for the current project. * * @author Amir Aranibar */ public final class FormatOptions implements IFormatOptions { private static final FormatOptions INSTANCE = new FormatOptions(); private Map<String, String> defaultValues; /** * Singleton * * @return the single instance of this class */ public static FormatOptions getInstance() { return INSTANCE; } public FormatOptions() { createDefaultValues(); } @Override public void setOptionValue(Preferences preferences, String key, String value) { preferences.put(key, value); } @Override public String getOptionValue(Preferences preferences, String key) { if (defaultValues.containsKey(key)) { return preferences.get(key, defaultValues.get(key)); } return preferences.get(key, "undefined"); } /** * Initialize the default options. * */ private void createDefaultValues() { defaultValues = new HashMap<>(); defaultValues.put(PreferencesFormatOptions.BRACES_IN_CLASS_DECLARATION.name(), SAME_LINE); defaultValues.put(PreferencesFormatOptions.BRACES_IN_METHOD_DECLARATION.name(), SAME_LINE); defaultValues.put(PreferencesFormatOptions.BRACES_IN_OTHER_DECLARATION.name(), SAME_LINE); defaultValues.put(PreferencesFormatOptions.SORT_MEMBERS_BY_VISIBILITY.name(), VISIBLE_MEMBERS); defaultValues.put(PreferencesFormatOptions.MEMBERS_SORT_ORDER.name(), MEMBERS_SORT_ORDER_LIST); defaultValues.put(PreferencesFormatOptions.MEMBERS_VISIBILITY.name(), VISIBILITY_LIST); defaultValues.put(PreferencesFormatOptions.CHECK_SORT_MEMBERS_IN_GROUPS_ALPHABETICALLY.name(), CHECK_SORT_MEMBERS_IN_GROUPS_ALPHABETICALLY); } }
9,609
https://github.com/bradly/simple_deploy/blob/master/lib/simple_deploy/stack/execute.rb
Github Open Source
Open Source
MIT
2,020
simple_deploy
bradly
Ruby
Code
33
116
require 'simple_deploy/stack/ssh' module SimpleDeploy class Stack class Execute def initialize(args) @config = SimpleDeploy.config @args = args end def execute(args) ssh.execute args end private def ssh @ssh ||= SimpleDeploy::Stack::SSH.new @args end end end end
20,989
https://github.com/confluentinc/kafka-tutorials/blob/master/_includes/tutorials/fk-joins/kstreams/markup/dev/make-music-interest-schema.adoc
Github Open Source
Open Source
Apache-2.0
2,023
kafka-tutorials
confluentinc
AsciiDoc
Code
23
95
And finally, create another Avro schema file at `src/main/avro/music-interest.avsc` for the result of the join: +++++ <pre class="snippet"><code class="avro">{% include_raw tutorials/fk-joins/kstreams/code/src/main/avro/music-interest.avsc %}</code></pre> +++++
27,480
https://github.com/wastoresh/azure-powershell/blob/master/src/Websites/Websites/Cmdlets/WebApps/NewAzureRmWebAppContainerPSSession.cs
Github Open Source
Open Source
MIT, Apache-2.0
2,020
azure-powershell
wastoresh
C#
Code
233
626
// ---------------------------------------------------------------------------------- // // Copyright Microsoft Corporation // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // http://www.apache.org/licenses/LICENSE-2.0 // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. // ---------------------------------------------------------------------------------- using System.Management.Automation; using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters; using Microsoft.WindowsAzure.Commands.Utilities.Common; namespace Microsoft.Azure.Commands.WebApps.Cmdlets.WebApps { /// <summary> /// this commandlet will create remote ps session with site /// </summary> [Cmdlet("New", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "WebAppContainerPSSession", DefaultParameterSetName = ParameterSet1Name, SupportsShouldProcess = true)] [OutputType(typeof(System.Management.Automation.Runspaces.PSSession))] public class NewAzureRmWebAppContainerPSSession : WebAppBaseCmdlet { [Parameter(ParameterSetName = ParameterSet1Name, Position = 1, Mandatory = false, HelpMessage = "The name of the web app slot.", ValueFromPipelineByPropertyName = true)] [ResourceNameCompleter("Microsoft.Web/sites/slots", "ResourceGroupName", "Name")] [ValidateNotNullOrEmpty] public string SlotName { get; set; } [Parameter(Mandatory = false, HelpMessage = "Create the PowerShell session without prompting for confirmation.")] public SwitchParameter Force { get; set; } public override void ExecuteCmdlet() { if (ParameterSetName == ParameterSet2Name) { string rg, name, slot; Utilities.CmdletHelpers.TryParseWebAppMetadataFromResourceId(WebApp.Id, out rg, out name, out slot); ResourceGroupName = rg; Name = name; SlotName = slot; } if (this.Force.IsPresent || ShouldProcess(Properties.Resources.EnterContainerPSSessionConfirmation)) { WebsitesClient.RunWebAppContainerPSSessionScript(this, ResourceGroupName, Name, SlotName, true); } } } }
36,034
https://github.com/BilkentCompGen/sirfast/blob/master/run.sh
Github Open Source
Open Source
BSD-3-Clause
null
sirfast
BilkentCompGen
Shell
Code
139
360
#!/bin/bash # Build Hashtable ./sirfast --index ../reference/build37.fa --ws 10 # Single End Mode with first read format (-f 1), 1k read slice (-t 1000) ./sirfast --search ../reference/build37.fa --seq ../reference/read_form1 -e 0 -f 1 -t 1000 -o out_se_form1.sam -u out_se_form1.unmap # Mate Pair Mode with first read format (-f 1), 1k read slice (-t 1000) ./sirfast --search ../reference/build37.fa --mp --seq ../reference/read_form1 -e 0 -f 1 -t 1000 --min 200 --max 600 -o out_pe_form1.sam -u out_pe_form1.unmap # Single End Mode with second read format (-f 1), 1k read slice (-t 1000) ./sirfast --search ../reference/build37.fa --seq ../reference/read_form2 -e 0 -f 2 -t 1000 -o out_se_form2.sam -u out_se_form2.unmap # Mate Pair Mode with second read format (-f 1), 1k read slice (-t 1000) ./sirfast --search ../reference/build37.fa --mp --seq ../reference/read_form2 -e 0 -f 2 -t 1000 --min 200 --max 600 -o out_pe_form2.sam -u out_pe_form2.unmap
28,504
https://github.com/rizkygin/testdashboardtourguide/blob/master/database/seeds/TrxReedemTableSeeder.php
Github Open Source
Open Source
MIT
null
testdashboardtourguide
rizkygin
PHP
Code
71
240
<?php use Illuminate\Database\Seeder; use Faker\Factory as Faker; class TrxReedemTableSeeder extends Seeder { /** * Run the database seeds. * * @return void */ public function run() { $faker = Faker::create(); for($i=1; $i<70; $i++){ $user_id = $faker->numberBetween($min = 21, $max = 50); $reward_id = $faker->numberBetween($min = 1, $max = 20); $created_at = $faker->dateTimeThisYear($max = 'now', $timezone = null); DB::table('trx_reedem')->insert([ 'user_id' => $user_id, 'reward_id' => $reward_id, 'created_at' => $created_at, ]); } } }
18,777
https://github.com/eurecom-s3/invscov/blob/master/daikon/tests/sources/java6170/test/Grader.java
Github Open Source
Open Source
Apache-2.0
2,022
invscov
eurecom-s3
Java
Code
559
1,648
package java6170.test; import junit.framework.*; import junit.extensions.*; import java.util.*; import java.io.*; public class Grader implements TestRunListener { private PrintStream _out = System.out; private Map _classToTest = new LinkedHashMap(); // class -> test -> points private Map _classToPoints = new LinkedHashMap(); // class -> <points, total> private boolean _gotFail = false; public void init(String[] args) { for (int i = 0; i < args.length; i++) { if (args[i].equals("--help")) printUsage(); else if (args[i].startsWith("-")) printUsage("Unrecognized option: "+args[i]); else { try { loadPoints(new FileReader(args[i])); } catch (IOException e) { printUsage(e.toString()); } } } } private void loadPoints(Reader in) throws IOException { BufferedReader reader = new BufferedReader(in); while (true) { String line = reader.readLine(); if (line == null) break; loadLine(line); } } private void loadLine(String line) { if (line.startsWith("#")) return; // skip comments StringTokenizer tokens = new StringTokenizer(line); if (tokens.countTokens() == 0) return; // skip blanks if (tokens.countTokens() != 3) printLineUsage(line); String classname = tokens.nextToken(); String testname = tokens.nextToken(); float points = 0; try { points = Float.parseFloat(tokens.nextToken()); } catch (NumberFormatException e) { printLineUsage(line); } if (points < 0) printLineUsage(line); if (testname.equals("base")) { ClassPoints cp = new ClassPoints(); cp.points = points; cp.total = points; setClassPoints(classname, cp); } else { setTestPoints(classname, testname, points); } } /** Set the points for test testname in class classname to points. */ private void setTestPoints(String classname, String testname, float points) { Map testToPoints = (Map)_classToTest.get(classname); if (testToPoints == null) { testToPoints = new LinkedHashMap(); _classToTest.put(classname, testToPoints); } testToPoints.put(testname, new Float(points)); } /** Get the points for test testname in class classname. If no specific value set for that test, returns default for that class. If no default for that class, return null. */ private Float getTestPoints(String classname, String testname) { Map testToPoints = (Map)_classToTest.get(classname); if (testToPoints == null) return null; Float points = (Float)testToPoints.get(testname); if (points == null) return (Float)testToPoints.get("default"); return points; } private void printLineUsage(String line) { throw new IllegalArgumentException("Grader: line format is:\n<classname> (<testname>|default|base) <points: positive float>\nbad line: "+line); } private void printUsage() { printUsage(null); } private void printUsage(String why) { StringBuffer buf = new StringBuffer(); if (why != null) buf.append(why).append('\n'); buf.append("Usage: Grader [options] <gradeFile>*\n"); buf.append("--help: print this help message\n"); buf.append("gradeFile: each line gives point value for a test:\n"); buf.append("# comment line\n"); buf.append("<classname> <testname> <points>\n"); buf.append("<classname> default <points>\n"); buf.append("<classname> base <points>\n"); buf.append("default: default points for tests in that class\n"); buf.append("base: starting number of points for that class\n"); buf.append("points: positive float\n"); throw new IllegalArgumentException(buf.toString()); } public void startRun(TestResult result) { } public void startTest(Test test) { _gotFail = false; } public void addFailure(Test test, AssertionFailedError t) { _gotFail = true; } public void addError(Test test, Throwable t) { _gotFail = true; } public void endTest(Test test) { if (!(test instanceof TestCase)) return; TestCase tcase = (TestCase)test; String classname = tcase.getClass().getName(); String testname = tcase.name(); Float points = getTestPoints(classname, testname); if (points == null) throw new IllegalStateException ("Grader: unrecognized test: "+classname+" "+testname); ClassPoints cp = getClassPoints(classname); cp.total += points.floatValue(); if (!_gotFail) cp.points += points.floatValue(); setClassPoints(classname, cp); } public void endRun(TestResult result) { _out.println("GRADES"); Iterator classnames = _classToPoints.keySet().iterator(); while (classnames.hasNext()) { String classname = (String)classnames.next(); ClassPoints cp = getClassPoints(classname); _out.println(classname+": "+cp.points+"/"+cp.total); } } private ClassPoints getClassPoints(String classname) { ClassPoints cp = (ClassPoints)_classToPoints.get(classname); if (cp == null) { cp = new ClassPoints(); setClassPoints(classname, cp); } return cp; } private void setClassPoints(String classname, ClassPoints cp) { _classToPoints.put(classname, cp); } private static class ClassPoints { float points = 0; float total = 0; } }
41,785
https://github.com/DerekKeeler/hexlogjs/blob/master/src/types/int8.js
Github Open Source
Open Source
ISC
2,018
hexlogjs
DerekKeeler
JavaScript
Code
15
55
module.exports = { name: 'int8', bytes: 1, method: (bufName, varName, offset) => `${bufName}.writeInt8(${varName}, ${offset});`, };
35,598
https://github.com/ailnitskiy/CombineX/blob/master/Sources/CombineX/Publishers/D/SwitchToLatest.swift
Github Open Source
Open Source
MIT
2,022
CombineX
ailnitskiy
Swift
Code
1,452
3,601
#if !COCOAPODS import CXUtility #endif extension Publisher where Failure == Output.Failure, Output: Publisher { /// Republishes elements sent by the most recently received publisher. /// /// This operator works with an upstream publisher of publishers, flattening /// the stream of elements to appear as if they were coming from a single /// stream of elements. It switches the inner publisher as new ones arrive /// but keeps the outer publisher constant for downstream subscribers. /// /// For example, given the type /// `AnyPublisher<URLSession.DataTaskPublisher, NSError>`, calling /// `switchToLatest()` results in the type /// `SwitchToLatest<(Data, URLResponse), URLError>`. The downstream /// subscriber sees a continuous stream of `(Data, URLResponse)` elements /// from what looks like a single `DataTaskPublisher` even though the /// elements are coming from different upstream publishers. /// /// When this operator receives a new publisher from the upstream publisher, /// it cancels its previous subscription. Use this feature to prevent /// earlier publishers from performing unnecessary work, such as creating /// network request publishers from frequently updating user interface /// publishers. /// /// The following example updates a ``PassthroughSubject`` with a new value /// every `0.1` seconds. A ``Publisher/map(_:)-99evh`` operator receives the /// new value and uses it to create a new `DataTaskPublisher`. By using the /// `switchToLatest()` operator, the downstream sink subscriber receives the /// `(Data, URLResponse)` output type from the data task publishers, rather /// than the `DataTaskPublisher` type produced by the ``Publisher.map(_:)`` /// operator. Furthermore, creating each new data task publisher cancels the /// previous data task publisher. /// /// let subject = PassthroughSubject<Int, Never>() /// cancellable = subject /// .setFailureType(to: URLError.self) /// .map() { index -> URLSession.DataTaskPublisher in /// let url = URL(string: "https://example.org/get?index=\(index)")! /// return URLSession.shared.dataTaskPublisher(for: url) /// } /// .switchToLatest() /// .sink(receiveCompletion: { print("Complete: \($0)") }, /// receiveValue: { (data, response) in /// guard let url = response.url else { print("Bad response."); return } /// print("URL: \(url)") /// }) /// /// for index in 1...5 { /// DispatchQueue.main.asyncAfter(deadline: .now() + TimeInterval(index/10)) { /// subject.send(index) /// } /// } /// /// // Prints "URL: https://example.org/get?index=5" /// /// The exact behavior of this example depends on the value of `asyncAfter` /// and the speed of the network connection. If the delay value is longer, /// or the network connection is fast, the earlier data tasks may complete /// before `switchToLatest()` can cancel them. If this happens, the output /// includes multiple URLs whose tasks complete before cancellation. public func switchToLatest() -> Publishers.SwitchToLatest<Output, Self> { return .init(upstream: self) } } extension Publisher where Output: Publisher, Output.Failure == Never { /// Republishes elements sent by the most recently received publisher. /// /// This operator works with an upstream publisher of publishers, flattening /// the stream of elements to appear as if they were coming from a single /// stream of elements. It switches the inner publisher as new ones arrive /// but keeps the outer publisher constant for downstream subscribers. /// /// When this operator receives a new publisher from the upstream publisher, /// it cancels its previous subscription. Use this feature to prevent /// earlier publishers from performing unnecessary work, such as creating /// network request publishers from frequently updating user interface /// publishers. public func switchToLatest() -> Publishers.SwitchToLatest<Publishers.SetFailureType<Output, Failure>, Publishers.Map<Self, Publishers.SetFailureType<Output, Failure>>> { return map { $0.setFailureType(to: Failure.self) } .switchToLatest() } } extension Publisher where Failure == Never, Output: Publisher { /// Republishes elements sent by the most recently received publisher. /// /// This operator works with an upstream publisher of publishers, flattening /// the stream of elements to appear as if they were coming from a single /// stream of elements. It switches the inner publisher as new ones arrive /// but keeps the outer publisher constant for downstream subscribers. /// /// When this operator receives a new publisher from the upstream publisher, /// it cancels its previous subscription. Use this feature to prevent /// earlier publishers from performing unnecessary work, such as creating /// network request publishers from frequently updating user interface /// publishers. public func switchToLatest() -> Publishers.SwitchToLatest<Output, Publishers.SetFailureType<Self, Output.Failure>> { return setFailureType(to: Output.Failure.self) .switchToLatest() } } extension Publisher where Failure == Never, Output: Publisher, Output.Failure == Never { /// Republishes elements sent by the most recently received publisher. /// /// This operator works with an upstream publisher of publishers, flattening the stream of elements to appear as if they were coming from a single stream of elements. It switches the inner publisher as new ones arrive but keeps the outer publisher constant for downstream subscribers. /// /// When this operator receives a new publisher from the upstream publisher, it cancels its previous subscription. Use this feature to prevent earlier publishers from performing unnecessary work, such as creating network request publishers from frequently updating user interface publishers. public func switchToLatest() -> Publishers.SwitchToLatest<Output, Self> { return .init(upstream: self) } } extension Publishers { /// A publisher that “flattens” nested publishers. /// /// Given a publisher that publishes Publishers, the `SwitchToLatest` publisher produces a /// sequence of events from only the most recent one. /// /// For example, given the type `Publisher<Publisher<Data, NSError>, Never>`, calling /// `switchToLatest()` will result in the type `Publisher<Data, NSError>`. The /// downstream subscriber sees a continuous stream of values even though they may be coming from /// different upstream publishers. public struct SwitchToLatest<P: Publisher, Upstream>: Publisher where P == Upstream.Output, Upstream: Publisher, P.Failure == Upstream.Failure { public typealias Output = P.Output public typealias Failure = P.Failure /// The publisher from which this publisher receives elements. public let upstream: Upstream /// Creates a publisher that “flattens” nested publishers. /// /// - Parameter upstream: The publisher from which this publisher receives elements. public init(upstream: Upstream) { self.upstream = upstream } public func receive<S: Subscriber>(subscriber: S) where P.Output == S.Input, Upstream.Failure == S.Failure { let s = Inner(sub: subscriber) self.upstream.subscribe(s) } } } extension Publishers.SwitchToLatest { private final class Inner<S>: Subscription, Subscriber, CustomStringConvertible, CustomDebugStringConvertible where S: Subscriber, S.Input == P.Output, S.Failure == P.Failure { typealias Input = Upstream.Output typealias Failure = Upstream.Failure typealias Pub = Publishers.SwitchToLatest<P, Upstream> typealias Sub = S // for upstream let upLock = Lock() var upState: RelayState = .waiting // for downstream let downLock = Lock() let sub: Sub var downState: DemandState = .waiting var child: Child? init(sub: Sub) { self.sub = sub } deinit { upLock.cleanupLock() downLock.cleanupLock() } // MARK: Subscription func request(_ demand: Subscribers.Demand) { self.downLock.lock() switch self.downState { case .waiting: self.downState = .demanding(demand) let child = self.child self.downLock.unlock() child?.request(demand) case .demanding(let old): let new = old + demand self.downState = .demanding(new) let child = self.child self.downLock.unlock() child?.request(demand) default: self.downLock.unlock() } } func cancel() { self.downLock.lock() guard self.downState.complete() else { self.downLock.unlock() return } let child = self.child self.child = nil self.downLock.unlock() child?.cancel() self.upLock.withLockGet(self.upState.complete())?.cancel() } // MARK: Subscriber func receive(subscription: Subscription) { guard self.upLock.withLockGet(self.upState.relay(subscription)) else { subscription.cancel() return } self.sub.receive(subscription: self) subscription.request(.unlimited) } func receive(_ input: Input) -> Subscribers.Demand { guard self.upLock.withLockGet(self.upState.isRelaying) else { return .none } let new = Child(parent: self) self.downLock.lock() if self.downState.isCompleted { self.downLock.unlock() return .none } let old = self.child let demand = self.downState.demand self.child = new self.downLock.unlock() old?.cancel() input.subscribe(new) if let demand = demand { new.request(demand) } return .none } func receive(completion: Subscribers.Completion<Failure>) { guard let subscription = self.upLock.withLockGet(self.upState.complete()) else { return } subscription.cancel() switch completion { case .finished: self.downLock.lock() if self.child == nil { guard self.downState.complete() else { self.downLock.unlock() return } self.downLock.unlock() self.sub.receive(completion: .finished) } else { self.downLock.unlock() } case .failure(let error): self.downLock.lock() guard self.downState.complete() else { self.downLock.unlock() return } let child = self.child self.child = nil self.downLock.unlock() child?.cancel() self.sub.receive(completion: .failure(error)) } } // MARK: ChildSubsciber private func receive(_ input: P.Output, from child: Child) -> Subscribers.Demand { self.downLock.lock() guard let old = self.downState.demand, old > 0 else { self.downLock.unlock() return .none } _ = self.downState.sub(.max(1)) self.downLock.unlock() let more = self.sub.receive(input) self.downLock.lock() _ = self.downState.add(more) self.downLock.unlock() return more } private func receive(completion: Subscribers.Completion<P.Failure>, from child: Child) { self.downLock.lock() guard self.downState.isDemanding else { self.downLock.unlock() return } if self.child === child { self.child = nil } switch completion { case .finished: if self.upLock.withLockGet(self.upState.isCompleted) { self.downState = .completed self.downLock.unlock() self.sub.receive(completion: .finished) } else { self.downLock.unlock() } case .failure(let error): self.downState = .completed self.downLock.unlock() self.sub.receive(completion: .failure(error)) self.upLock.withLockGet(self.upState.complete())?.cancel() } } var description: String { return "SwitchToLatest" } var debugDescription: String { return "SwitchToLatest" } final class Child: Subscriber { typealias Input = P.Output typealias Failure = P.Failure let parent: Inner let subscription = LockedAtomic<Subscription?>(nil) init(parent: Inner) { self.parent = parent } func receive(subscription: Subscription) { if self.subscription.setIfNil(subscription) { subscription.request(.max(1)) } else { subscription.cancel() } } func receive(_ input: P.Output) -> Subscribers.Demand { guard self.subscription.load() != nil else { return .none } return self.parent.receive(input, from: self) } func receive(completion: Subscribers.Completion<P.Failure>) { guard let subscription = self.subscription.exchange(nil) else { return } subscription.cancel() self.parent.receive(completion: completion, from: self) } func cancel() { self.subscription.exchange(nil)?.cancel() } func request(_ demand: Subscribers.Demand) { self.subscription.load()?.request(demand) } } } }
11,940
https://github.com/cryptopatron/web-app/blob/master/src/pages/creator-page/components/support-panel/stream.tsx
Github Open Source
Open Source
BSD-3-Clause
null
web-app
cryptopatron
TypeScript
Code
348
1,134
import { useState, useEffect } from 'react' import ListboxComponent from '../../../../components/listbox'; import { tokens, n_month_names } from './payment_options'; const minimum = 5 //minimum amount in stream export default function StreamComponent({ addPayment, tokens, network, setIsOpen }) { const [amount, setAmount] = useState(5); const [currency, setCurrency] = useState(tokens[0]); const [nMonths, setNMonths] = useState(n_month_names[0]); const getAmount = (value) => { if (value) { const num = parseFloat(value) if (num >= minimum) { setAmount(num) } else { setAmount(minimum) } } else { setAmount(minimum) } } const incrementAmount = () => { const value = amount + 1 setAmount(value) } const decrementAmount = () => { const value = amount > minimum ? amount - 1 : minimum setAmount(value) } // returns an array of unixes when the // subscription payments go through function get_payment_schedule(month_string) { let schedule: number[] = []; const months_to_expiry = get_n_months(month_string); const today = new Date(); for (let i = 0; i < months_to_expiry; i++) { const pay_date = new Date( today.getFullYear() + Math.floor(i / 12), today.getMonth() + i % 12, today.getDate() ) schedule.push(Math.floor((pay_date.getTime()) / 1000)) } return schedule } function get_n_months(month_string) { return parseInt(month_string.split(" ")[0]) } useEffect(() => { const subscription = { amount_per: amount, currency_name: currency.value, payment_schedule: get_payment_schedule(nMonths.value) } addPayment(subscription) }, [amount, nMonths, currency]) return ( <div className="flex flex-col justify-center items-center text-center w-full"> <div className="font-light text-xs mt-2 mb-1">Support with monthly donations</div> {/* Input Amount/Currency */} <div className="flex flex-row justify-center items-center h-8 my-2"> <div className="mx-1"> <button className=" px-3 py-1 text-gray-500 bg-graywhite-100 hover:text-gray-700 hover:bg-gray-200 focus:outline-none rounded-l-md" onClick={() => { decrementAmount() }}>-</button> <input type="text" className=" px-3 py-1 h-8 w-20 text-center focus:outline-none bg-graywhite-100 mx-auto" value={amount} onChange={(e) => getAmount(e.target.value)} /> <button className=" px-3 py-1 text-gray-500 bg-graywhite-100 hover:bg-gray-200 hover:text-gray-700 focus:outline-none rounded-r-md" onClick={() => { incrementAmount() }}>+</button> </div> <div className="w-20"> <ListboxComponent content={currency} setContent={setCurrency} ListboxContent={tokens} /> </div> </div> {/* Input Length of Subscription */} <div className="flex flex-row justify-center items-center"> <div className="text-md mx-1">for</div> <div className="w-28 h-8 mx-2 "> <ListboxComponent content={nMonths} setContent={setNMonths} ListboxContent={n_month_names} /> </div> </div> {/* Help */} <div className="flex mt-1 flex-grow items-end self-stretch justify-center"> {/*<div className="text-gray-400 text-xs font-light">Have you heard of stream?</div>*/} <button onClick={() => setIsOpen(true)}> <div className="text-primary-light text-sm font-light">Help</div> </button> </div> </div> ) }
44,039
https://github.com/commercionetwork/commercio-sdk.dart/blob/master/lib/kyc/reward_pool_deposit_helper.dart
Github Open Source
Open Source
MIT
2,021
commercio-sdk.dart
commercionetwork
Dart
Code
49
139
import 'package:commerciosdk/export.dart'; /// Allows to easily create a DepositRewardPool and perform common related operations class RewardPoolDepositHelper { /// Creates a RewardPoolDeposit from the given [wallet], /// and deposit [amount]. static RewardPoolDeposit fromWallet({ required Wallet wallet, required List<StdCoin> amount, }) { return RewardPoolDeposit( depositAmount: amount, depositorDid: wallet.bech32Address, ); } }
2,966
https://github.com/moutainhigh/xtoon-boot/blob/master/src/main/java/com/xtoon/boot/application/AccountService.java
Github Open Source
Open Source
Apache-2.0
2,022
xtoon-boot
moutainhigh
Java
Code
89
314
package com.xtoon.boot.application; import com.xtoon.boot.domain.model.user.Account; import com.xtoon.boot.domain.model.user.types.AccountId; import com.xtoon.boot.domain.model.user.types.AccountName; import com.xtoon.boot.domain.model.user.types.Mobile; /** * 用户Service * * @author haoxin * @date 2021-02-09 **/ public interface AccountService { /** * 通过账号登录 * * @param accountName * @param password * @return */ Account login(AccountName accountName, String password); /** * 通过手机号登录 * * @param mobile * @return */ Account login(Mobile mobile); /** * 登出 * * @param accountId */ void logout(AccountId accountId); /** * 修改密码 * * @param account * @param oldPasswordStr * @param newPasswordStr */ void changePassword(Account account, String oldPasswordStr, String newPasswordStr); }
34,273
https://github.com/ArteonToken/monorepo/blob/master/contracts/exchange/interfaces/IArtOnlineListingERC1155.sol
Github Open Source
Open Source
MIT
null
monorepo
ArteonToken
Solidity
Code
24
77
// SPDX-License-Identifier: MIT pragma solidity 0.8.11; import './IArtOnlineListing.sol'; interface IArtOnlineListingERC1155 is IArtOnlineListing { function id() external returns (uint256); function supportsInterface(bytes4) external returns (bool); }
35,211
https://github.com/WhyPenguins/XenkoVoxelGI/blob/master/FirstPersonShooter_VoxelGI.Game/EmissionToggler.cs
Github Open Source
Open Source
MIT
2,022
XenkoVoxelGI
WhyPenguins
C#
Code
94
354
// Copyright (c) Xenko contributors (https://xenko.com) and Silicon Studio Corp. (https://www.siliconstudio.co.jp) // Distributed under the MIT license. See the LICENSE.md file in the project root for more information. using System.Collections.Generic; using System.Linq; using Xenko.Core.Mathematics; using Xenko.Engine; using Xenko.Engine.Events; using Xenko.Input; using FirstPersonShooter_VoxelGI.Core; using Xenko.Rendering; using Xenko.Rendering.Materials; namespace FirstPersonShooter_VoxelGI.Player { public class EmissionToggler : SyncScript { public List<Keys> ToggleEmission { get; } = new List<Keys>(); public int materialIndex; float swapIntensity = 0.0f; public override void Update() { if (ToggleEmission.Any(key => Input.IsKeyPressed(key))) { float newSwapIntensity = Entity.Get<ModelComponent>().GetMaterial(materialIndex).Passes[0].Parameters.Get(MaterialKeys.EmissiveIntensity); Entity.Get<ModelComponent>().GetMaterial(materialIndex).Passes[0].Parameters.Set(MaterialKeys.EmissiveIntensity, swapIntensity); swapIntensity = newSwapIntensity; } } } }
45,655
https://github.com/armadhika/Program-Akademik/blob/master/app/Http/Controllers/PilihpbbController.php
Github Open Source
Open Source
MIT
null
Program-Akademik
armadhika
PHP
Code
143
750
<?php namespace App\Http\Controllers; use Alert; use App\Pembimbing; use App\Dosen; use Illuminate\Http\Request; use Illuminate\Support\Facades\DB; use App\Mail\NotifPembimbingPkl; use Illuminate\Support\Facades\Mail; class PilihpbbController extends Controller { public function index(Request $request) { $pbb = Pembimbing::daftar(); return view('akademik.daftarpbb',compact('pbb')); } public function cari(Request $request) { $pbb = Pembimbing::daftar_cari($request->cari); // dd($pbb); return view('akademik.daftarpbb',compact('pbb')); } public function store(Request $request) { $cek = Pembimbing::where('nim',$request->nim)->first(); if(!is_null($cek)){ Alert::warning('Peringatan','<h4>Mahasiswa sudah mendapat pembimbing '.$request->kategori.'</h4>')->toHtml(); return back(); } Pembimbing::create($request->all()); return redirect('/pilihpbb_ta_pkl')->with('success','Data berhasil di simpan!'); } public function update(Request $request,Pembimbing $pembimbing) { Pembimbing::find($request->kdpem)->update($request->all()); return redirect()->back()->with('success',"Data berhasil di ubah!"); } public function edit(Request $request) { $pem = Pembimbing::d_edit(); foreach($pem as $g); $pbb = Dosen::where('prodidosen', $g->prodimhs)->get(); return view('akademik.modal.editpbb_pilih',compact('g','pbb')); } public function destroy(Pembimbing $pilihpbb_ta_pkl) { Pembimbing::destroy($pilihpbb_ta_pkl->kdpem); return redirect('/pilihpbb_ta_pkl')->with('success',"Data $pilihpbb_ta_pkl->nmhhs berhasil di hapus!"); } // Email public function email(Pembimbing $pilihpbb_ta_pkl) { Mail::send(new NotifPembimbingPkl ($pilihpbb_ta_pkl)); // Cek kegagalan if (Mail::failures()) { return redirect('/pilihpbb_ta_pkl')->with('warning', 'Gagal mengirim Email'); } return redirect('/pilihpbb_ta_pkl')->with('success', 'Email berhasil dikirim!'); } }
8,215
https://github.com/tacobarry/swars-quiz/blob/master/src/app/people/card/card.component.ts
Github Open Source
Open Source
MIT
null
swars-quiz
tacobarry
TypeScript
Code
129
489
import { Component, OnInit, Input } from '@angular/core'; import { BsModalService } from 'ngx-bootstrap/modal'; import { BsModalRef } from 'ngx-bootstrap/modal/bs-modal-ref.service'; import { ImageService } from '../image.service'; import { ModalAnswerQuestionComponent } from '../../shared/modals/modal-answer-question/modal-answer-question.component'; import { Person } from '../../shared/models/person'; import { ModalDetailsComponent } from '../../shared/modals/modal-details/modal-details.component'; @Component({ selector: 'app-card', templateUrl: './card.component.html', styleUrls: ['./card.component.css'] }) export class CardComponent implements OnInit { @Input() person: Person; private picture: string; bsModalRef: BsModalRef; constructor(private modalService: BsModalService) {} ngOnInit() { this.picture = `/assets/images/people/${ ImageService.getImageByName(this.person.name) }`.trim(); } answerQuestion() { const initialState = { title: 'Qual o nome do Personagem?', picture: this.picture, person: this.person }; this.bsModalRef = this.modalService.show(ModalAnswerQuestionComponent, {initialState}); this.bsModalRef.content.closeBtnName = 'Fechar'; } showDetailModal() { this.person.seeDetails = true; const initialState = { title: 'Detalhes', picture: this.picture, person: this.person }; this.bsModalRef = this.modalService.show(ModalDetailsComponent, {initialState}); this.bsModalRef.content.closeBtnName = 'Fechar'; //console.log(person) } }
5,527
https://github.com/alxmrs/arcs/blob/master/javatests/arcs/core/host/SimpleSchedulerProviderTest.kt
Github Open Source
Open Source
BSD-3-Clause, WTFPL, Apache-2.0
2,021
arcs
alxmrs
Kotlin
Code
297
1,097
/* * Copyright 2020 Google LLC. * * This code may only be used under the BSD style license found at * http://polymer.github.io/LICENSE.txt * * Code distributed by Google as part of this project is also subject to an additional IP rights * grant found at * http://polymer.github.io/PATENTS.txt */ package arcs.core.host import arcs.core.testutil.runTest import arcs.core.util.Scheduler import arcs.core.util.testutil.LogRule import com.google.common.truth.Truth.assertThat import com.google.common.truth.Truth.assertWithMessage import java.util.concurrent.Executors import kotlin.test.assertFailsWith import kotlinx.coroutines.CompletableDeferred import kotlinx.coroutines.asCoroutineDispatcher import kotlinx.coroutines.withContext import org.junit.Rule import org.junit.Test import org.junit.runner.RunWith import org.junit.runners.JUnit4 @RunWith(JUnit4::class) class SimpleSchedulerProviderTest { @get:Rule val log = LogRule() @Test fun one_thread_multipleSchedulers() = runTest { val coroutineContext = Executors.newSingleThreadExecutor().asCoroutineDispatcher() val schedulerProvider = SimpleSchedulerProvider(coroutineContext) val schedulerA = schedulerProvider("a") val schedulerB = schedulerProvider("b") val schedulerC = schedulerProvider("c") // All should be separate instances. assertThat(schedulerA).isNotEqualTo(schedulerB) assertThat(schedulerA).isNotEqualTo(schedulerC) assertThat(schedulerB).isNotEqualTo(schedulerC) val schedulerAThread = CompletableDeferred<Thread>() val schedulerBThread = CompletableDeferred<Thread>() val schedulerCThread = CompletableDeferred<Thread>() // All three run on the same thread. schedulerA.schedule( SimpleProc("a") { schedulerAThread.complete(Thread.currentThread()) } ) schedulerB.schedule( SimpleProc("b") { schedulerBThread.complete(Thread.currentThread()) } ) schedulerC.schedule( SimpleProc("c") { schedulerCThread.complete(Thread.currentThread()) } ) assertThat(schedulerAThread.await()).isEqualTo(schedulerBThread.await()) assertThat(schedulerBThread.await()).isEqualTo(schedulerCThread.await()) schedulerProvider.cancelAll() } @Test fun throwing_from_a_task_failsTheParentContext() = runTest { val e = assertFailsWith<IllegalStateException> { withContext(coroutineContext) { val schedulerProvider = SimpleSchedulerProvider(coroutineContext) val scheduler = schedulerProvider("a") scheduler.schedule( SimpleProc("test") { throw IllegalStateException("Washington DC is not a state.") } ) scheduler.waitForIdle() } } assertThat(e).hasMessageThat().contains("Washington DC is not a state.") } @Test fun canceling_thenReInvoking_givesNewScheduler() = runTest { val coroutineContext = Executors.newSingleThreadExecutor().asCoroutineDispatcher() val schedulerProvider = SimpleSchedulerProvider(coroutineContext) val scheduler = schedulerProvider("a") // Cancel the scheduler, and wait until its job has completed before trying to create // another scheduler with the same arcId. scheduler.cancel() scheduler.awaitCompletion() val newScheduler = schedulerProvider("a") assertWithMessage( "After canceling the original scheduler, we should get a new one, even with the " + "same arcId." ).that(newScheduler).isNotEqualTo(scheduler) schedulerProvider.cancelAll() } private class SimpleProc( val name: String, block: () -> Unit ) : Scheduler.Task.Processor(block) { override fun toString() = "SimpleProc($name)" } }
8,161
https://github.com/tonussi/teia/blob/master/src/model/AmigoDestacado.java
Github Open Source
Open Source
MIT
null
teia
tonussi
Java
Code
20
74
package model; import view.VetorComposto; public class AmigoDestacado extends Amigo { public AmigoDestacado(Info info, VetorComposto vetorComposto) { super(info, vetorComposto); } }
7,372
https://github.com/dajvido/NAJ-homework/blob/master/Lesson6/js/ee.js
Github Open Source
Open Source
MIT
null
NAJ-homework
dajvido
JavaScript
Code
96
337
(function (global) { var EE; if (!global.UAM) { global.UAM = {}; } EE = function () { this.listeners = {}; }; EE.prototype.on = function (eventName, listener, context) { var listenerData, me = this; if (!this.listeners[eventName]) { this.listeners[eventName] = []; } listenerData = { fn: listener, ctx: context || window }; this.listeners[eventName].push(listenerData); return function () { var ind = me.listeners[eventName].indexOf(listenerData); if (ind > -1) { me.listeners[eventName].splice(ind, 1); } }; }; EE.prototype.emit = function (eventName) { var args, listeners = this.listeners[eventName] || []; args = Array.prototype.slice.call(arguments, 1); listeners.forEach(function (listData) { listData.fn.apply(listData.ctx, args); }); }; global.UAM.EventEmitter = EE; }(window));
4,182
https://github.com/HakurouKen/DoubanFM-Simplify/blob/master/template/button-template.js
Github Open Source
Open Source
MIT
2,014
DoubanFM-Simplify
HakurouKen
JavaScript
Code
2
14
<span id="toggleView">切换</span>
19,350
https://github.com/EitanGayor/augur/blob/master/tests-unit/input/arguments-2-tainted/test.js
Github Open Source
Open Source
UPL-1.0
2,022
augur
EitanGayor
JavaScript
Code
29
57
const a = 2; // unused named argument // accessing tainted argument and returning it function f(x) { let firstArg = arguments[0]; return firstArg; } const z = f(a);
50,233
https://github.com/sethvincent/common-shakeify/blob/master/example/app.js
Github Open Source
Open Source
MIT
2,022
common-shakeify
sethvincent
JavaScript
Code
5
18
var message = require('./xyz').getMessage() console.log(message)
8,420
https://github.com/bluewaysw/pcgeos/blob/master/Driver/Printer/PrintCom/Job/jobStartCanonRGB.asm
Github Open Source
Open Source
Apache-2.0
2,023
pcgeos
bluewaysw
Assembly
Code
1,024
2,959
COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Copyright (c) GlobalPC 1999 -- All Rights Reserved PROJECT: PC GEOS MODULE: Printer Drivers FILE: jobStartCanonRGB.asm AUTHOR: Joon Song, 9 Jan 1999 ROUTINES: Name Description ---- ----------- PrintStartJob Setup done at start of print job REVISION HISTORY: Name Date Description ---- ---- ----------- Joon 1/99 Initial revision from jobStartDotMatrix.asm DESCRIPTION: $Id$ %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ COMMENT @%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% PrintStartJob %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% SYNOPSIS: Do pre-job initialization CALLED BY: GLOBAL PASS: bp - segment of locked PState dx:si - Job Parameters block RETURN: carry - set if some communication problem DESTROYED: nothing PSEUDO CODE/STRATEGY: KNOWN BUGS/SIDE EFFECTS/IDEAS: none REVISION HISTORY: Name Date Description ---- ---- ----------- Joon 1/99 Initial version from jobStartDotMatrix.asm %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%@ PrintStartJob proc far uses ax,bx,cx,dx,si,di,es .enter mov es, bp ;point at PState. mov bx, es:PS_deviceInfo ;get the device specific info. call MemLock mov ds, ax ;segment into ds. mov al, ds:PI_type ;get the printer smarts field. mov ah, ds:PI_smarts ;get the printer smarts field. mov {word}es:PS_printerType,ax ;set both in PState. mov ax, ds:PI_customEntry ;get address of any custom routine. call MemUnlock tst ax ;see if a custom routine exists. jz useStandard ;if not, skip to use standard init. jmp ax ;else jmp to the custom routine. ;(It had better jump back here to ;somwhere in this routine or else ;things will get ugly on return). useStandard: call PrintResetPrinterAndWait ;init the printer hardware LONG jc done ;load the paper path variables from the Job Parameters block mov al, es:[PS_jobParams].[JP_printerData].[PUID_paperInput] clr ah call PrintSetPaperPath LONG jc done ; initialize some info in the PState clr ax mov es:[PS_cursorPos].P_x, ax ; set to 0,0 text mov es:[PS_cursorPos].P_y, ax ; set init codes (assuming graphic printing) mov si, offset pr_codes_InitPrinter call SendCodeOut LONG jc done ; set print resolution - usually 360x360 except mono-low-res ; and mono-mid-res (180x180) mov si, offset pr_codes_SetPrintResolution call SendCodeOut LONG jc done mov ax, HI_RES_RASTER_X_RES mov bx, HI_RES_RASTER_Y_RES clr dx ; dx = clear = 360 DPI mov cl, es:[PS_printerType] andnf cl, mask PT_COLOR cmp cl, BMF_MONO jne setRes cmp es:[PS_mode], PM_GRAPHICS_HI_RES je setRes mov ax, LOW_RES_MONO_X_RES mov bx, LOW_RES_MONO_Y_RES inc dx ; dx <- set = 180 DPI setRes: mov cl, bh call PrintStreamWriteByte ; write vertRes.high mov cl, bl call PrintStreamWriteByte ; write vertRes.low mov cl, ah call PrintStreamWriteByte ; write horizRes.high mov cl, al call PrintStreamWriteByte ; write horizRes.low ; set print method ; ; Print quality defaults to standard. If the media type is not ; plain, envelope, or banner paper, print quality is set high. ; (This rule is a must for proper print control using dither ; [fast] halftoning). mov si, offset pr_codes_SetPrintingMethod call SendCodeOut LONG jc done mov al, es:[PS_jobParams].[JP_printerData].[CPUID_mediaType] ;; mov cl, CANON_BJC_PRINT_QUALITY_DRAFT ;; cmp es:[PS_mode], PM_GRAPHICS_LOW_RES ;; je setQuality mov cl, CANON_BJC_PRINT_QUALITY_STANDARD ; quality = standard ;; setQuality: cmp al, CANON_BJC_MEDIA_TYPE_BANNER_PAPER ja invalidMedia ; use zero as default if media invalid je gotQuality ; banner paper uses standard quality cmp al, CANON_BJC_MEDIA_TYPE_PLAIN_PAPER je gotQuality ; so does plain paper cmp al, CANON_BJC_MEDIA_TYPE_ENVELOPES je gotQuality ; and envelope paper cmp al, CANON_BJC_MEDIA_TYPE_OTHER je gotQuality ; and other paper (why not?) mov cl, CANON_BJC_PRINT_QUALITY_HIGH ; but, everyone else gotQuality: ; uses high quality clr ah mov si, ax ; si <- offset into media table ornf cl, cs:[printMediaTable][si] ; media goes in upper nibble invalidMedia: call PrintStreamWriteByte ; set page margins (all values specified in multiples of 1/60") mov si, offset pr_codes_SetPageMargins call SendCodeOut jc done BranchIfBannerMode bannerMode mov ax, es:[PS_customHeight] ; write page length sub ax, PR_MARGIN_TOP + PR_MARGIN_BOTTOM call PSJConvertAndOutputLength jmp leftMargin ; In banner mode, we must ensure that the page length set here ; results in a total raster count that is a multiple of 8. So, ; we pick a constant length that just happens to have this property. ; We also store the raster count per page at this point. bannerMode: mov ax, BANNER_MODE_HI_RES_PAGE_LENGTH ; assume 360 DPI mov bx, BANNER_MODE_HI_RES_RASTER_COUNT tst dx ; printing 360 DPI? jz setBannerMargin ; branch if so mov ax, BANNER_MODE_LOW_RES_PAGE_LENGTH ; nope, use 180 DPI mov bx, BANNER_MODE_LOW_RES_RASTER_COUNT setBannerMargin: mov es:[PS_jobParams].[JP_printerData].[CPUID_rasterCount], bx mov cl, ah call PrintStreamWriteByte ; - high byte mov cl, al call PrintStreamWriteByte ; - low byt leftMargin: clr ax ; write zero left margin mov cl, ah call PrintStreamWriteByte ; - high byte mov cl, al call PrintStreamWriteByte ; - low byte mov ax, es:[PS_customWidth] ; write right margin sub ax, PR_MARGIN_LEFT + PR_MARGIN_RIGHT call PSJConvertAndOutputLength mov ax, PR_LEFT_MARGIN_OFFSET ; write offset mov cl, ah call PrintStreamWriteByte ; - high byte mov cl, al call PrintStreamWriteByte ; - low byte ; Set print media loading. This command may set banner mode, ; so it must be the last control command sent before raster data, ; as the printer will ignore any further controls until the ; reset command (ESC @) is sent. mov si, offset pr_codes_SetPrintMediaLoading call SendCodeOut jc done mov cl, (CANON_BJC_PRINTER_MODEL_ID shl 4) \ or CANON_BJC_MEDIA_SOURCE_ASF1 call PrintStreamWriteByte ; write Model_ID mov al, es:[PS_jobParams].[JP_printerData].[CPUID_mediaType] mov cl, 4 shl al, cl ; media goes in upper nibble mov cl, al call PrintStreamWriteByte ; write media type ; initialize color library call CMYKColorLibInitialize clc done: .leave ret ; Each Media Type passed in the SetPrintMediaLoading command has a matching ; Print Media constant passed in the SetPrintingMethod command. The Media ; Type is set in the job printer data, while the Print Media is looked up ; in this table. All values are shifted into the upper nibble as per the ; command format. printMediaTable byte CANON_BJC_PRINT_MEDIA_PLAIN_PAPER shl 4, \ 0, \ CANON_BJC_PRINT_MEDIA_TRANSPARENCIES shl 4, \ CANON_BJC_PRINT_MEDIA_BACK_PRINT_FILM shl 4, \ 0, \ 0, \ CANON_BJC_PRINT_MEDIA_GLOSSY_PAPER shl 4, \ CANON_BJC_PRINT_MEDIA_HIGH_GLOSS_FILM shl 4, \ CANON_BJC_PRINT_MEDIA_ENVELOPES shl 4, \ CANON_BJC_PRINT_MEDIA_OTHER shl 4, \ 0, \ CANON_BJC_PRINT_MEDIA_HIGH_RES_PAPER shl 4, \ CANON_BJC_PRINT_MEDIA_GLOSSY_CARDS shl 4, \ CANON_BJC_PRINT_MEDIA_BANNER_PAPER shl 4 PrintStartJob endp ; ; Utility routine to convert a length in ax in points (1/72") to ; a multiple of 1/60" and write it to the device. ; PSJConvertAndOutputLength proc near clr dx mov cx, 5 ; pts (1/72") -> 1/60" mul cx mov cx, 6 div cx mov cl, ah call PrintStreamWriteByte ; write high byte mov cl, al call PrintStreamWriteByte ; write low byte ret PSJConvertAndOutputLength endp
35,441
https://github.com/xapicohort/team-adaptive-learning/blob/master/includes/TinCanPHP-master/tests/PersonTest.php
Github Open Source
Open Source
MIT
2,020
team-adaptive-learning
xapicohort
PHP
Code
285
1,010
<?php /* Copyright 2014 Rustici Software Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. */ namespace TinCanTest; use TinCan\Person; class PersonTest extends \PHPUnit_Framework_TestCase { use TestCompareWithSignatureTrait; public function testInstantiation() { $obj = new Person(); $this->assertInstanceOf('TinCan\Person', $obj); $this->assertAttributeEmpty('name', $obj, 'name empty'); $this->assertAttributeEmpty('mbox', $obj, 'mbox empty'); $this->assertAttributeEmpty('mbox_sha1sum', $obj, 'mbox_sha1sum empty'); $this->assertAttributeEmpty('openid', $obj, 'openid empty'); $this->assertAttributeEmpty('account', $obj, 'account empty'); } public function testFromJSONInvalidNull() { $this->setExpectedException('TinCan\JSONParseErrorException'); $obj = Person::fromJSON(null); } public function testFromJSONInvalidEmptyString() { $this->setExpectedException('TinCan\JSONParseErrorException'); $obj = Person::fromJSON(''); } public function testFromJSONInvalidMalformed() { $this->setExpectedException('TinCan\JSONParseErrorException'); $obj = Person::fromJSON('{name:"some value"}'); } // TODO: need to loop possible configs public function testFromJSONInstantiations() { $obj = Person::fromJSON('{"mbox":["' . COMMON_MBOX . '","'.COMMON_MBOX.'"]}'); $this->assertInstanceOf('TinCan\Person', $obj); $this->assertSame(array(COMMON_MBOX, COMMON_MBOX), $obj->getMbox(), 'mbox value'); } // TODO: need to loop versions public function testAsVersion() { $obj = new Person( [ 'mbox' => array(COMMON_MBOX), 'account' => array( array( 'name' => COMMON_ACCT_NAME, 'homePage' => COMMON_ACCT_HOMEPAGE ) ) ] ); $versioned = $obj->asVersion('1.0.0'); $this->assertEquals( [ 'objectType' => 'Person', 'mbox' => array(COMMON_MBOX), 'account' => array( array( 'name' => COMMON_ACCT_NAME, 'homePage' => COMMON_ACCT_HOMEPAGE ) ) ], $versioned, "mbox only: 1.0.0" ); } public function testSetMbox() { $obj = new Person(); $obj->setMbox(array(COMMON_MBOX)); $this->assertSame(array(COMMON_MBOX), $obj->getMbox()); // // make sure it doesn't add mailto when null // $obj->setMbox(null); $this->assertAttributeEmpty('mbox', $obj); } public function testGetMbox_sha1sum() { $obj = new Person(['mbox_sha1sum' => array(COMMON_MBOX_SHA1)]); $this->assertSame($obj->getMbox_sha1sum(), array(COMMON_MBOX_SHA1), 'original sha1'); } }
40,177
https://github.com/markorusic/wp2-blog/blob/master/resources/js/admin/modules/data-table.js
Github Open Source
Open Source
MIT
2,020
wp2-blog
markorusic
JavaScript
Code
626
2,329
import debounce from 'lodash/debounce' import get from 'lodash/get' import templateRender from '../../shared/template-render' import http from '../../shared/http-service' import dataPagination from '../../shared/data-pagination' const crudAction = { edit: 'edit', delete: 'delete', create: 'create' } let props = { title: '', baseUrl: null, searchBy: null, crudActions: Object.values(crudAction), actions: [], columns: [] } let state = { pageSize: 10, sort: '' } const $dom = { root: null, search: null, table: null, pagination: null } const view = { renderContainer() { const html = ` <div id="${props.title}-data-table" class="container py-2"> <div class="card-header"> <div class="flex-sp-between"> <h4 class="bold uc-first">${props.title}</h4> ${templateRender.if( props.crudActions.includes(crudAction.create), `<span> <a class="btn btn-success btn-sm" href="${props.baseUrl}/create"> <i class="fa fa-plus" aria-hidden="true"></i> Create </a> </span>` )} </div> ${templateRender.if( props.searchBy, `<div class="mt-1"> <input type="text" class="resource-table-search form-control" placeholder="Search" data-resource-search > </div>` )} </div> <table class="table resource-table" data-resource-table> </table> <div data-resource-pagination></div> ` $('body main').html(html) return $(`#${props.title}-data-table`) }, renderLoader() { const height = 53 * (state.pageSize + 1) $dom.table.html(` <div class="flex-center" style="height: ${height}px;"> <div class="spinner-border text-primary" role="status"> <span class="sr-only">Loading...</span> </div> </div> `) }, renderTable({ content = [], pagination = {} }) { const showEdit = props.crudActions.includes(crudAction.edit) const showDelete = props.crudActions.includes(crudAction.delete) const tableHtml = ` <thead> <tr> <th>#</th> ${templateRender.list( props.columns, ({ name, displayName = name, sortable = false }) => ` <th class="uc-first clickable" data-sort="${name}"> <span>${displayName}<span> ${templateRender.if( sortable, '<span><i class="fa fa-sort" aria-hidden="true"></i></span>' )} </th> ` )} ${templateRender.if(showEdit || showDelete, '<th>Actions</th>')} </tr> </thead> <tbody> ${templateRender.list( content, (item, index) => ` <tr data-id="${item.id}"> <td>${(pagination.current_page - 1) * pagination.per_page + index + 1}</td> ${templateRender.list(props.columns, ({ name, type }) => templateRender.switch(type, { default: `<td data-name="${name}">${get( item, name )}</td>`, photo: ` <td data-name="main_photo"> <img src="${get( item, name )}" alt="Photo not found" class="table-img"> </td>` }) )} ${templateRender.if( showEdit || showDelete || props.actions.length > 0, `<td class="flex resource-actions"> ${templateRender.list( props.actions, action => ` <a class="btn btn-${action.type} mr-2 btn-sm" href="${action.link(item)}" > <i class="fa fa-${ action.icon }" aria-hidden="true"></i> ${action.title || ''} </a> ` )} ${templateRender.if( showEdit, ` <a class="btn btn-primary white-txt mr-2 btn-sm" href="${props.baseUrl}/${item.id}/edit" > <i class="fa fa-pencil" aria-hidden="true"></i> </a> ` )} ${templateRender.if( showDelete, ` <a class="btn btn-danger white-txt btn-sm" data-delete="${props.baseUrl}/${item.id}" > <i class="fa fa-trash-o text-white" aria-hidden="true"></i> </a> ` )} </td>` )} </tr>` )} </tbody> ` $dom.table.html(tableHtml) dataPagination.init($dom.pagination, { pagination, onPageChange: handlePageChange }) }, renderErrorTable() { $dom.pagination.html('') $dom.table.html(` <div class="alert alert-warning mt-3 text-center" role="alert"> Error happend while loading ${props.title}. </div>`) } } const cacheDom = () => { $dom.root = view.renderContainer() $dom.search = $dom.root.find('[data-resource-search]') $dom.table = $dom.root.find('[data-resource-table]') $dom.pagination = $dom.root.find('[data-resource-pagination]') } const bindSearchEvent = () => { $dom.search.on('keyup', debounce(handleSearch, 400)) } const bindTableEvents = () => { $dom.table.find('[data-sort]').on('click', handleSort) $dom.table.find('[data-delete]').on('click', handleRecordDelete) } // Load data procedure const loadData = ({ page = 1, size = 10, ...rest } = {}) => { view.renderLoader() return http .get(props.baseUrl, { params: { page, size, ...rest } }) .then(res => res.data) .then(({ data, current_page, per_page, total }) => { view.renderTable({ content: data, pagination: { current_page, per_page, total } }) bindTableEvents() }) .catch(err => { console.log(err) view.renderErrorTable(err) }) } // Event handlers const handleSearch = event => { const { value } = event.target loadData({ order: state.sort, [props.searchBy]: value }) } const handleSort = event => { const { sort } = $(event.currentTarget).data() const [sortParam, sortOrder] = state.sort.split(',') const order = sortParam !== sort ? 'desc' : sortOrder === 'desc' ? 'asc' : 'desc' state.sort = `${sort},${order}` loadData({ order: state.sort, page: $dom.pagination.find('.active').data().page, [props.searchBy]: $dom.search.val() }) } const handleRecordDelete = event => { const $el = $(event.currentTarget) const endpoint = $el.data().delete if (!endpoint || !confirm('Are you sure?')) { return null } http.delete(endpoint) .then(() => { return loadData({ order: state.sort, page: get($dom.pagination.find('.active').data(), 'page', 0), [props.searchBy]: $dom.search.val() }) }) .catch(error => { console.log(error) alert('Error occured during delete!') }) } const handlePageChange = page => { loadData({ page, order: state.sort, [props.searchBy]: $dom.search.val() }) } const dataTable = { crudAction, init(configProps) { props = { ...props, ...configProps } $(() => { cacheDom() loadData().then(bindSearchEvent) }) } } export default dataTable
26,689
https://github.com/tiram819/badges-and-schedules-onl01-seng-pt-030220/blob/master/conference_badges.rb
Github Open Source
Open Source
LicenseRef-scancode-unknown-license-reference, LicenseRef-scancode-public-domain
2,020
badges-and-schedules-onl01-seng-pt-030220
tiram819
Ruby
Code
53
195
def badge_maker(speaker) return "Hello, my name is #{speaker}." end attendees = ["Edsger", "Ada", "Charles", "Alan", "Grace", "Linus", "Matz"] def batch_badge_creator(attendees) attendees.collect {|speaker| badge_maker(speaker)} end def assign_rooms(attendees) attendees.each_with_index.map {|speaker, index| "Hello, #{speaker}! You'll be assigned to room #{index+1}!"} end def printer(speakers) batch_badge_creator(speakers).each do |badge| puts badge end assign_rooms(speakers).each do |assignment| puts assignment end end
46,699
https://github.com/tomasz-herman/PseudoAssemblerEmulator/blob/master/src/main/java/com/hermant/program/instruction/PushRegisterInstruction.java
Github Open Source
Open Source
MIT
2,020
PseudoAssemblerEmulator
tomasz-herman
Java
Code
47
160
package com.hermant.program.instruction; import com.hermant.machine.Machine; public class PushRegisterInstruction extends Instruction { @Override public final void run(Machine m){ setInstructionPointer(m.getInstructionPointer()); m.getStack().push(m.getRegister().get(reg1)); } @Override public final byte code() { return PUSH_REGISTER; } @Override public final int instLength() { return 2; } @Override public final String instCode() { return "PUSH_REGISTER"; } }
16,691
https://github.com/ITdevVN/Sales-Management-Webapp/blob/master/app/Http/Controllers/DynamicPDFController.php
Github Open Source
Open Source
MIT
2,019
Sales-Management-Webapp
ITdevVN
PHP
Code
417
2,447
<?php namespace App\Http\Controllers; use Illuminate\Http\Request; use DB; use PDF; use Session; class DynamicPDFController extends Controller { function xuatPDFTatCa(Request $request){ $pdf = \App::make('dompdf.wrapper'); $pdf->loadHTML($request->session()->get('tableData')); return $pdf->stream(); } function setSession(Request $request){ Session::put('tableData', $request->tableData); return 1; } //Phần thống kê báo cáo function baoCaoDoanhThuCuoiNgay(Request $request){ $listField=DB::select('call baoCaoDoanhThuCuoiNgay()'); $tongDoanhThu=DB::select('call tongDoanhThuCuoiNgay()'); date_default_timezone_set('Asia/Ho_Chi_Minh'); $date = date('m/d/Y h:i:s a', time()); $output=' <!DOCTYPE html> <html> <head> <style> table, td, th { border: 1px solid black; } h2 { text-align:center; } table { border-collapse: collapse; width: 100%; } th { height: 50px; } *{ font-family: DejaVu Sans; } tr:nth-child(even) {background: #CCC} tr:nth-child(odd) {background: #FFF} th{ background-color: #2E94DA; } </style> </head> <body> <p>Ngày tạo: '.$date.'</p> <h2>BÁO CÁO CUỐI NGÀY VỀ BÁN HÀNG</h2> <table> <tr> <th>Mã hóa đơn</th> <th>Thời gian thanh toán</th> <th>Số lượng sản phẩm</th> <th>Doanh thu</th> </tr>'; for ($i=0;$i<count($listField);$i++){ $output .='<tr> <td>'.$listField[$i]->ma_hoa_don.'</td> <td>'.$listField[$i]->time_thanh_toan.'</td> <td>'.$listField[$i]->so_luong_san_pham.'</td> <td>'.number_format($listField[$i]->doanh_thu).'</td> </tr>'; } $output .='</table>'; $output .=' <br/> Tổng doanh thu: '.number_format($tongDoanhThu[0]->tongDoanhThu).' </body> </html>'; $pdf = \App::make('dompdf.wrapper'); $pdf->loadHTML($output); return $pdf->stream(); } function baoCaoDoanhSo(Request $request){ if ($request->loai=="khachhang"){ $listField=DB::select('call baoCaoDoanhSoKhachHang(?,?)',array($request->tungay,$request->denngay)); $tongDoanhThu=DB::select('call tongDoanhSoKhachHang(?,?)',array($request->tungay,$request->denngay)); date_default_timezone_set('Asia/Ho_Chi_Minh'); $date = date('m/d/Y h:i:s a', time()); $output=' <!DOCTYPE html> <html> <head> <style> table, td, th { border: 1px solid black; } h2 { text-align:center; } table { border-collapse: collapse; width: 100%; } th { height: 50px; } *{ font-family: DejaVu Sans; } tr:nth-child(even) {background: #CCC} tr:nth-child(odd) {background: #FFF} th{ background-color: #2E94DA; } </style> </head> <body> <p>Ngày tạo: '.$date.'</p> <h2>BÁO CÁO DOANH SỐ KHÁCH HÀNG TỪ '.$request->tungay.' đến '.$request->denngay.'</h2> <table> <tr> <th>MKH</th> <th>Họ tên</th> <th>CMND</th> <th>Điện thoại</th> <th>Địa chỉ</th> <th>Giới tính</th> <th>Ngày sinh</th> <th>Loại</th> <th>Doanh số</th> </tr>'; for ($i=0;$i<count($listField);$i++){ $output .='<tr> <td>'.$listField[$i]->ma_khach_hang.'</td> <td>'.$listField[$i]->ho_ten.'</td> <td>'.$listField[$i]->cmnd.'</td> <td>'.$listField[$i]->dien_thoai.'</td> <td>'.$listField[$i]->dia_chi.'</td> <td>'.$listField[$i]->gioi_tinh.'</td> <td>'.$listField[$i]->ngay_sinh.'</td> <td>'.$listField[$i]->ten_loai.'</td> <td>'.number_format($listField[$i]->doanhso).'</td> </tr>'; } $output .='</table>'; $output .=' <br/> Tổng doanh thu: '.number_format($tongDoanhThu[0]->tongDoanhThu).' </body> </html>'; $pdf = \App::make('dompdf.wrapper'); $pdf->loadHTML($output); return $pdf->stream(); } if ($request->loai=="nhanvien"){ $listField=DB::select('call baoCaoDoanhSoNhanVien(?,?)',array($request->tungay,$request->denngay)); $tongDoanhThu=DB::select('call tongDoanhSoNhanVien(?,?)',array($request->tungay,$request->denngay)); date_default_timezone_set('Asia/Ho_Chi_Minh'); $date = date('m/d/Y h:i:s a', time()); $output=' <!DOCTYPE html> <html> <head> <style> table, td, th { border: 1px solid black; } h2 { text-align:center; } table { border-collapse: collapse; width: 100%; } th { height: 50px; } *{ font-family: DejaVu Sans; } tr:nth-child(even) {background: #CCC} tr:nth-child(odd) {background: #FFF} th{ background-color: #2E94DA; } </style> </head> <body> <p>Ngày tạo: '.$date.'</p> <h2>BÁO CÁO DOANH SỐ BÁN HÀNG CỦA NHÂN VIÊN TỪ '.$request->tungay.' đến '.$request->denngay.'</h2> <table> <tr> <th>MKH</th> <th>Họ tên</th> <th>CMND</th> <th>Điện thoại</th> <th>Địa chỉ</th> <th>Giới tính</th> <th>Ngày sinh</th> <th>Doanh số</th> </tr>'; for ($i=0;$i<count($listField);$i++){ $output .='<tr> <td>'.$listField[$i]->ma_nhan_vien.'</td> <td>'.$listField[$i]->ho_ten.'</td> <td>'.$listField[$i]->cmnd.'</td> <td>'.$listField[$i]->dien_thoai.'</td> <td>'.$listField[$i]->dia_chi.'</td> <td>'.$listField[$i]->gioi_tinh.'</td> <td>'.$listField[$i]->ngay_sinh.'</td> <td>'.number_format($listField[$i]->doanhso).'</td> </tr>'; } $output .='</table>'; $output .=' <br/> Tổng doanh thu: '.number_format($tongDoanhThu[0]->tongDoanhThu).' </body> </html>'; $pdf = \App::make('dompdf.wrapper'); $pdf->loadHTML($output); return $pdf->stream(); } //if tiếp theo } }
32,986
https://github.com/doyaGu/C0501Q_HWJL01/blob/master/sdk/doc/html/ite__usbkbd_8h.js
Github Open Source
Open Source
MIT
2,021
C0501Q_HWJL01
doyaGu
JavaScript
Code
20
164
var ite__usbkbd_8h = [ [ "usb_kbd_cb", "ite__usbkbd_8h.html#ab44bbed4551c1b6389b8f3cf56d26f83", null ], [ "iteUsbKbdRegister", "ite__usbkbd_8h.html#a2dee46613fd9e0a02bf5e6a53982f775", null ], [ "iteUsbKbdSetCb", "ite__usbkbd_8h.html#a5dcb09565ceda7b02ba1ee5198c3c8a7", null ] ];
14,712
https://github.com/youboyTizzyT/Guard-bunker-project/blob/master/project1.2/src/com/company/test.java
Github Open Source
Open Source
Unlicense
2,018
Guard-bunker-project
youboyTizzyT
Java
Code
142
683
package com.company; import com.company.util.aaa; import io.netty.bootstrap.ServerBootstrap; import io.netty.channel.ChannelFuture; import io.netty.channel.ChannelInitializer; import io.netty.channel.EventLoopGroup; import io.netty.channel.nio.NioEventLoopGroup; import io.netty.channel.socket.SocketChannel; import io.netty.channel.socket.nio.NioServerSocketChannel; import io.netty.handler.codec.http.HttpObjectAggregator; import io.netty.handler.codec.http.HttpRequestDecoder; import io.netty.handler.codec.http.HttpResponseEncoder; import io.netty.handler.codec.string.StringDecoder; import io.netty.handler.codec.string.StringEncoder; import io.netty.handler.stream.ChunkedWriteHandler; /** * Created by weicong on 17-8-3. */ public class test { private static final String DEFAULT_URL = "/"; public void run(final int port) throws Exception { EventLoopGroup bossGroup = new NioEventLoopGroup(); EventLoopGroup workerGroup = new NioEventLoopGroup(); try { ServerBootstrap b = new ServerBootstrap(); b.group(bossGroup, workerGroup) .channel(NioServerSocketChannel.class) .childHandler(new ChannelInitializer<SocketChannel>() { protected void initChannel(SocketChannel ch) throws Exception { // ch.pipeline().addLast(new HttpRequestDecoder()); // 请求消息解码器 // ch.pipeline().addLast(new HttpObjectAggregator(65536));// 目的是将多个消息转换为单一的request或者response对象 // ch.pipeline().addLast(new HttpResponseEncoder());//响应解码器 // ch.pipeline().addLast(new ChunkedWriteHandler());//目的是支持异步大文件传输() // 业务逻辑 ch.pipeline().addLast(new StringDecoder()); ch.pipeline().addLast(new StringEncoder()); ch.pipeline().addLast(new aaa()); } }); ChannelFuture future = b.bind(port).sync(); future.channel().closeFuture().sync(); } catch (Exception e) { e.printStackTrace(); } finally { bossGroup.shutdownGracefully(); workerGroup.shutdownGracefully(); } } public static void main(String[] args) throws Exception { new test().run(8088); } }
16,938
https://github.com/emacslisp/spring-project/blob/master/lab/spring-tutorial-77/src/main/java/com/lab/spring/Car.java
Github Open Source
Open Source
Apache-2.0
null
spring-project
emacslisp
Java
Code
17
54
package com.lab.spring; import org.springframework.stereotype.Component; @Component public class Car { public void start() { System.out.println("Car starting"); } }
48,956
https://github.com/lonely7345/gobblin/blob/master/gobblin-core/src/test/java/gobblin/source/extractor/filebased/TokenizedFileDownloaderTest.java
Github Open Source
Open Source
BSD-3-Clause, xpp, Apache-2.0, MIT
2,017
gobblin
lonely7345
Java
Code
161
486
/* * Copyright (C) 2014-2016 LinkedIn Corp. All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); you may not use * this file except in compliance with the License. You may obtain a copy of the * License at http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software distributed * under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. */ package gobblin.source.extractor.filebased; import java.io.ByteArrayInputStream; import java.io.InputStream; import java.io.UnsupportedEncodingException; import org.testng.Assert; import org.testng.annotations.Test; import com.google.common.base.Joiner; /** * Test for {@link TokenizedFileDownloader}. */ public class TokenizedFileDownloaderTest { @Test public void testRecordIterator() throws UnsupportedEncodingException { String charset = "UTF-8"; String delimiter = "\n\r"; String record1 = "record1"; String record2 = "record2\n"; String record3 = "record3\r"; InputStream inputStream = new ByteArrayInputStream(Joiner.on(delimiter).join(record1, record2, record3).getBytes(charset)); TokenizedFileDownloader.RecordIterator recordIterator = new TokenizedFileDownloader.RecordIterator(inputStream, delimiter, charset); Assert.assertTrue(recordIterator.hasNext()); Assert.assertEquals(recordIterator.next(), record1); Assert.assertTrue(recordIterator.hasNext()); Assert.assertEquals(recordIterator.next(), record2); Assert.assertTrue(recordIterator.hasNext()); Assert.assertEquals(recordIterator.next(), record3); Assert.assertFalse(recordIterator.hasNext()); } }
37,392
https://github.com/cocoa520/lalalala/blob/master/iOSFiles/iOSFiles/UI/controller/alertController/IMBAlertViewController.m
Github Open Source
Open Source
MIT
2,018
lalalala
cocoa520
Objective-C
Code
513
2,735
// // IMBAlertViewController.m // iOSFiles // // Created by smz on 18/3/28. // Copyright © 2018年 iMobie. All rights reserved. // #import "IMBAlertViewController.h" #import "IMBCommonDefine.h" #import "IMBAnimation.h" #import "IMBDriveEntity.h" #import "IMBImageAndTextFieldCell.h" #import "IMBiCloudDriverViewController.h" @implementation IMBAlertViewController @synthesize delegete = _delegete; #pragma mark - 窗口下拉和收回 //窗口下拉 - (void)loadAlertView:(NSView *)view alertView:(IMBBorderRectAndColorView *)alertView { // [alertView setBackground:[NSColor whiteColor]]; NSRect rect = [alertView frame]; [alertView setWantsLayer:YES]; [alertView setFrame:NSMakeRect(ceil((NSMaxX(self.view.bounds) - NSWidth(rect)) / 2), NSMaxY(self.view.bounds), NSWidth(rect), NSHeight(rect))]; if (![self.view.subviews containsObject:alertView]) { [self.view addSubview:alertView]; } [NSAnimationContext runAnimationGroup:^(NSAnimationContext *context) { context.duration = 0.45f; NSRect newRect = alertView.frame; newRect.origin.y = NSMaxY(view.bounds) - NSHeight(alertView.frame) + 10; [alertView.animator setFrame:newRect]; // [alertView.layer addAnimation:[IMBAnimation moveY:0.5 X:[NSNumber numberWithInt:0] Y:[NSNumber numberWithInt:-alertView.bounds.size.height + 10] repeatCount:0] forKey:@"moveY"]; } completionHandler:^{ // [alertView.layer removeAnimationForKey:@"moveY"]; // [alertView setFrame:NSMakeRect(ceil((NSMaxX(view.bounds) - NSWidth(alertView.frame)) / 2), NSMaxY(view.bounds) - NSHeight(alertView.frame) + 10, NSWidth(alertView.frame), NSHeight(alertView.frame))]; }]; } //窗口收回 - (void)unloadAlertView:(IMBBorderRectAndColorView *)alertView { dispatch_async(dispatch_get_main_queue(), ^{ [NSAnimationContext runAnimationGroup:^(NSAnimationContext *context) { [alertView.layer addAnimation:[IMBAnimation moveY:0.5 X:[NSNumber numberWithInt:0] Y:[NSNumber numberWithInt:alertView.frame.size.height] repeatCount:1] forKey:@"moveY"]; } completionHandler:^{ [alertView.layer removeAnimationForKey:@"moveY"]; [alertView setFrame:NSMakeRect(ceil((NSMaxX(_mainView.bounds) - alertView.frame.size.width) / 2), NSMaxY(_mainView.bounds), alertView.frame.size.width, alertView.frame.size.height)]; [alertView removeFromSuperview]; [self.view removeFromSuperview]; [_mainView setHidden:YES]; }]; }); } #pragma mark - 传输失败的详情-弹框 - (void)showSelectFolderAlertViewWithSuperView:(NSView *)superView WithFolderArray:(NSMutableArray *)folderArray { if (_folderArray != nil) { [_folderArray release]; _folderArray = nil; } [superView setWantsLayer:YES]; _folderArray = [[NSMutableArray alloc] initWithArray:folderArray]; _mainView = superView; [self.view setFrameSize:NSMakeSize(NSWidth(superView.frame), NSHeight(superView.frame))]; [superView addSubview:self.view]; [self loadAlertView:superView alertView:_selectFolderAlertView]; [_selectFolderAlertDetailView setBackgroundColor:[NSColor clearColor]]; [_selectFolderAlertDetailView setFocusRingType:NSFocusRingTypeNone]; [_selectFolderAlertDetailView reloadData]; [_selectFolderAlertView setBackground:[NSColor whiteColor]]; [_backgroundBorderView setBackgroundColor:[NSColor clearColor]]; [_backgroundBorderView setIsDrawFrame:YES]; [_selectFolderAlertView setNeedsDisplay:YES]; [_selectFolderAlertTitle setStringValue:CustomLocalizedString(@"MoveFileWindowTitle", nil)]; [_selectFolderAlertTitle setTextColor:COLOR_TEXT_ORDINARY]; //按钮样式 [_selectFolderAlertOKBtn setIsNoGridient:YES]; [_selectFolderAlertOKBtn setNormalFillColor:COLOR_OKBTN_NORMAL WithEnterFillColor:COLOR_OKBTN_ENTER WithDownFillColor:COLOR_OKBTN_DOWN]; [_selectFolderAlertOKBtn setButtonTitle:CustomLocalizedString(@"Button_Ok", nil) withNormalTitleColor:COLOR_View_NORMAL withEnterTitleColor:COLOR_View_NORMAL withDownTitleColor:COLOR_View_NORMAL withForbiddenTitleColor:COLOR_View_NORMAL withTitleSize:14.0 WithLightAnimation:NO]; [_selectFolderAlertOKBtn setTarget:self]; [_selectFolderAlertOKBtn setAction:@selector(clickOKSelectFolderAlertView:)]; [_selectFolderAlertCancelBtn setIsNoGridient:YES]; [_selectFolderAlertCancelBtn setNormalFillColor:COLOR_CANCELBTN_NORMAL WithEnterFillColor:COLOR_CANCELBTN_ENTER WithDownFillColor:COLOR_CANCELBTN_DOWN]; [_selectFolderAlertCancelBtn setButtonTitle:CustomLocalizedString(@"Button_Cancel", nil) withNormalTitleColor:COLOR_TEXT_ORDINARY withEnterTitleColor:COLOR_TEXT_ORDINARY withDownTitleColor:COLOR_TEXT_ORDINARY withForbiddenTitleColor:COLOR_TEXT_ORDINARY withTitleSize:14.0 WithLightAnimation:NO]; [_selectFolderAlertCancelBtn setButtonBorder:YES withNormalBorderColor:COLOR_BTNBORDER_NORMAL withEnterBorderColor:COLOR_BTNBORDER_ENTER withDownBorderColor:COLOR_BTNBORDER_DOWN withForbiddenBorderColor:COLOR_BTNBORDER_NORMAL withBorderLineWidth:1]; [_selectFolderAlertCancelBtn setTarget:self]; [_selectFolderAlertCancelBtn setAction:@selector(cancelSelectFolderAlertView:)]; } #pragma mark - 点击OK进行传输 - (void)clickOKSelectFolderAlertView:(id)sender { if (_curEntity) { [self unloadAlertView:_selectFolderAlertView]; [_delegete startMoveTransferWith:_curEntity]; } } #pragma mark - 关闭 selectFolderAlertView - (void)cancelSelectFolderAlertView:(id)sender { [self unloadAlertView:_selectFolderAlertView]; } #pragma mark - tableViewDataSource -(NSInteger)numberOfRowsInTableView:(NSTableView *)tableView { if (_folderArray.count > 0) { return _folderArray.count; } return 0; } - (id)tableView:(NSTableView *)tableView objectValueForTableColumn:(NSTableColumn *)tableColumn row:(NSInteger)row { return @""; } - (void)tableView:(NSTableView *)tableView willDisplayCell:(id)cell forTableColumn:(NSTableColumn *)tableColumn row:(NSInteger)row { if ([[tableColumn identifier] isEqualToString:@"ImageText"]) { IMBImageAndTextFieldCell *curCell = (IMBImageAndTextFieldCell *)cell; id item = [_folderArray objectAtIndex:row]; if ([item isKindOfClass:[IMBDriveEntity class]]) { IMBDriveEntity *fileEntity = (IMBDriveEntity *)item; [curCell setImageSize:NSMakeSize(24, 18)]; curCell.image = fileEntity.image; curCell.imageText = fileEntity.fileName; [curCell setIsDataImage:YES]; curCell.marginX = 12; }else { SimpleNode *node = (SimpleNode *)item; [curCell setImageSize:NSMakeSize(24, 18)]; curCell.image = node.image; curCell.imageText = node.fileName; [curCell setIsDataImage:YES]; curCell.marginX = 12; } } } - (CGFloat)tableView:(NSTableView *)tableView heightOfRow:(NSInteger)row { return 40; } - (void)tableViewSelectionDidChange:(NSNotification *)notification { NSInteger row = [notification.object selectedRow]; if (_folderArray.count <= 0 || _folderArray == nil) { return ; } if (row < 0 || row >= _folderArray.count) { row = 0; } _curEntity = [_folderArray objectAtIndex:row]; } #pragma mark - 单个按钮的警告框 - (void)showAlertText:(NSString *)alertText WithButtonTitle:(NSString *)buttonTitle WithSuperView:(NSView *)superView { _mainView = superView; [superView setWantsLayer:YES]; [self.view setFrameSize:NSMakeSize(NSWidth(superView.frame), NSHeight(superView.frame))]; [superView addSubview:self.view]; [self loadAlertView:superView alertView:_warningAlertView]; [_warnAlertImage setImage:[StringHelper imageNamed:@"alert_icon"]]; //文本样式 [_warningTextField setStringValue:alertText]; [_warningTextField setTextColor:COLOR_TEXT_ORDINARY]; //按钮样式 [_okBtn setIsNoGridient:YES]; [_okBtn setNormalFillColor:COLOR_OKBTN_NORMAL WithEnterFillColor:COLOR_OKBTN_ENTER WithDownFillColor:COLOR_OKBTN_DOWN]; [_okBtn setButtonTitle:buttonTitle withNormalTitleColor:COLOR_View_NORMAL withEnterTitleColor:COLOR_View_NORMAL withDownTitleColor:COLOR_View_NORMAL withForbiddenTitleColor:COLOR_View_NORMAL withTitleSize:14.0 WithLightAnimation:NO]; [_okBtn setTarget:self]; [_okBtn setAction:@selector(okBtnOperation:)]; } - (void)okBtnOperation:(id)sender { [self unloadAlertView:_warningAlertView]; } @end
24,634
https://github.com/teawithsand/crypka/blob/master/rng_stl_test.go
Github Open Source
Open Source
MIT
null
crypka
teawithsand
Go
Code
56
330
package crypka_test import ( "testing" "github.com/teawithsand/crypka" "github.com/teawithsand/crypka/crypkatest" ) func TestRNG_STLCrypto(t *testing.T) { tester := crypkatest.RNGTester{ Algo: &crypka.CryptoRNGAlgo{}, } tester.Test(t) } func TestRNG_STLMath(t *testing.T) { tester := crypkatest.RNGTester{ Algo: &crypka.MathRNGAlgo{}, } tester.Test(t) } func BenchmarkRNG_STLCrypto(b *testing.B) { tester := crypkatest.RNGTester{ Algo: &crypka.CryptoRNGAlgo{}, } tester.Benchmark(b) } func BenchmarkRNG_STLMath(b *testing.B) { tester := crypkatest.RNGTester{ Algo: &crypka.MathRNGAlgo{}, } tester.Benchmark(b) }
19,468
https://github.com/BioSin/netology-nodejs/blob/master/5-http/index.js
Github Open Source
Open Source
MIT
null
netology-nodejs
BioSin
JavaScript
Code
319
950
const http = require('http'); const url = require('url'); const PORT = process.env.PORT || 3000; class Product { constructor(id, name, count) { this.id = id; this.name = name; this.count = count; } toString() { return { id: this.id, name: this.name, count: this.count } } } class Warehouse { constructor(products = []) { this.products = products; } add(productId, count) { let product = this.products[productId - 1]; if(!product) { return false; } product.count = parseInt(product.count) + parseInt(count); return product; } deleteProduct(productId, count) { let product = this.products[productId - 1]; if(!product) { return false; } product.count = parseInt(product.count) - parseInt(count); return product; } register(name, count) { let product = new Product(this._generateId(), name, count); this.products.push(product); return product; } leftOver() { return this.products .map(el => el.toString()); } _generateId() { return this.products.length + 1; } } class Api { static register(wh, name, count) { let product = wh.register(name, count); if(!product) { return {data: 'Invalid data', code: 400}; } return { data: product.toString(), code: 200 }; } static add(wh, id, count) { let product = wh.add(id, count); if(!product) { return {data: 'Invalid data', code: 400}; } return { data: product.toString(), code: 200 }; } static deleteProduct(wh, id, count) { let product = wh.deleteProduct(id, count); if(!product) { return {data: 'Invalid data', code: 400}; } return { data: product.toString(), code: 200 }; } static leftOver(wh) { return { data: wh.leftOver(), code: 200 } } } const store = new Warehouse(); const validateParams = (data, params) => { let valid = true; params.forEach(el => { valid = !!data[el] || false; }); return valid; }; const handler = (req, res) => { const { query, pathname } = url.parse(req.url, true); let response; switch(pathname) { case '/register': response = Api.register(store, query.name, query.count); break; case '/add': response = Api.add(store, query.id, query.count); break; case '/delete': response = Api.deleteProduct(store, query.id, query.count); break; case '/left-over': response = Api.leftOver(store); break; default: break; } res.writeHead(response.code, { 'Content-Type': 'application/json' }); res.end(JSON.stringify(response.data)); }; http .createServer() .on('request', handler) .on('error', console.log) .listen(PORT);
40,055
https://github.com/simplifier-ag/cordova-plugin-local-notifications/blob/master/src/android/notification/receiver/AbstractNotificationReceiver.java
Github Open Source
Open Source
Apache-2.0
2,022
cordova-plugin-local-notifications
simplifier-ag
Java
Code
498
1,390
package de.appplant.cordova.plugin.notification.receiver; import android.content.BroadcastReceiver; import android.content.Context; import android.os.PowerManager; import android.util.Log; import org.json.JSONException; import org.json.JSONObject; import java.util.Calendar; import de.appplant.cordova.plugin.notification.Manager; import de.appplant.cordova.plugin.notification.Notification; import de.appplant.cordova.plugin.notification.Options; import de.appplant.cordova.plugin.notification.Request; import de.appplant.cordova.plugin.notification.util.LaunchUtils; import static android.content.Context.POWER_SERVICE; import static android.os.Build.VERSION.SDK_INT; import static android.os.Build.VERSION_CODES.O; import static android.os.Build.VERSION_CODES.P; import static java.util.Calendar.MINUTE; /** * The base class for any receiver that is trying to display a notification. */ abstract public class AbstractNotificationReceiver extends BroadcastReceiver { private final String TAG = "AbstractNotification"; /** * Perform a notification. All notification logic is here. * Determines whether to dispatch events, autoLaunch the app, use fullScreenIntents, etc. * @param notification reference to the notification to be fired */ public void performNotification(Notification notification) { Context context = notification.getContext(); Options options = notification.getOptions(); Manager manager = Manager.getInstance(context); PowerManager pm = (PowerManager) context.getSystemService(POWER_SERVICE); boolean autoLaunch = options.isAutoLaunchingApp() && SDK_INT <= P && !options.useFullScreenIntent(); int badge = options.getBadgeNumber(); if (badge > 0) { manager.setBadge(badge); } if (options.shallWakeUp()) { wakeUp(notification); } if (autoLaunch) { LaunchUtils.launchApp(context); } // Show notification if we should (triggerInApp is false) // or if we can't trigger in the app due to: // 1. No autoLaunch configured/supported and app is not running. // 2. Any SDK >= Oreo is asleep (must be triggered here) boolean didShowNotification = false; if (!options.triggerInApp() || (!autoLaunch && !checkAppRunning()) ) { didShowNotification = true; notification.show(); } // run trigger function if triggerInApp() is true // and we did not send a notification. if (options.triggerInApp() && !didShowNotification) { // wake up even if we didn't set it to if (!options.shallWakeUp()) { wakeUp(notification); } dispatchAppEvent("trigger", notification); } if (!options.isInfiniteTrigger()) return; Calendar cal = Calendar.getInstance(); cal.add(MINUTE, 1); Request req = new Request( getOptionsWithBaseDate(options, cal.getTimeInMillis()), cal.getTime() ); manager.schedule(req, this.getClass()); } /** * Clone options with base date attached to trigger. * Used so that persisted objects know the last execution time. * @param baseDateMillis base date represented in milliseconds * @return new Options object with base time set in requestBaseDate. */ private Options getOptionsWithBaseDate(Options options, long baseDateMillis) { JSONObject optionsDict = options.getDict(); try { JSONObject triggerDict = optionsDict.getJSONObject("trigger"); triggerDict.put("requestBaseDate", baseDateMillis); optionsDict.remove("trigger"); optionsDict.put("trigger", triggerDict); } catch (JSONException e) { Log.e(TAG, "Unexpected error adding requestBaseDate to JSON structure: " + e.toString()); } return new Options(optionsDict); } /** * Send the application an event using our notification * @param key key for our event in the app * @param notification reference to the notification */ abstract public void dispatchAppEvent(String key, Notification notification); /** * Check if the application is running. * Should be developed in local class, which has access to things needed for this. * @return whether or not app is running */ abstract public boolean checkAppRunning(); /** * Wakeup the device. * * @param notification The notification used to wakeup the device. * contains context and timeout. */ private void wakeUp(Notification notification) { Context context = notification.getContext(); Options options = notification.getOptions(); String wakeLockTag = context.getApplicationInfo().name + ":LocalNotification"; PowerManager pm = (PowerManager) context.getSystemService(POWER_SERVICE); if (pm == null) return; int level = PowerManager.FULL_WAKE_LOCK | PowerManager.ACQUIRE_CAUSES_WAKEUP | PowerManager.ON_AFTER_RELEASE; PowerManager.WakeLock wakeLock = pm.newWakeLock(level, wakeLockTag); wakeLock.setReferenceCounted(false); wakeLock.acquire(options.getWakeLockTimeout()); } }
34,953
https://github.com/mgsky1/SMU-IT-College-Website/blob/master/admin/delSelectedNews.php
Github Open Source
Open Source
Apache-2.0
null
SMU-IT-College-Website
mgsky1
PHP
Code
15
71
<?php require_once("PHP_Script/News/listNews.php")?> <?php $list = new NewsManage(); $list->_construct(); foreach($_POST['news'] as $i) { $list->delNews($i); } ?>
4,648
https://github.com/mschneider85/rkr/blob/master/app/assets/stylesheets/components/_flash-message.scss
Github Open Source
Open Source
MIT
null
rkr
mschneider85
SCSS
Code
62
256
.flash.alert { background-color: rgba(255, 255, 255, 0.9); color: #555; border-radius: 10px; padding: 12px 36px 10px; margin: 10px; font-size: 12px; > .element { display: table-cell; width: 100%; vertical-align: middle; } span { font-weight: bold; text-transform: uppercase; } &.alert-error { @include thin-border(#f5aca6); } &.alert-success { @include thin-border(#a6ca8a); } &.alert-alert { @include thin-border(#f2c779); } &.alert-notice { @include thin-border(#8ed9f6); } } .flash-close { color: $understatement-color; }
1,682
https://github.com/kcowolf/GenImageTool/blob/master/test/test4.h
Github Open Source
Open Source
MIT
2,022
GenImageTool
kcowolf
C
Code
61
329
/* Autogenerated by GenImageTool */ #ifndef TEST4_H #define TEST4_H #include <genesis.h> extern const uint16_t GFX_PAL_1[16]; extern const uint16_t GFX_PAL_2[16]; extern const uint16_t GFX_PAL_3[16]; extern const uint16_t GFX_PAL_4[16]; #define GFX_TILESET_1_TILE_COUNT 1 extern const uint32_t GFX_TILESET_1[GFX_TILESET_1_TILE_COUNT][8]; #define GFX_TILESET_2_TILE_COUNT 4 extern const uint32_t GFX_TILESET_2[GFX_TILESET_2_TILE_COUNT][8]; #define GFX_TILEMAP_1_TILE_WIDTH 2 #define GFX_TILEMAP_1_TILE_HEIGHT 2 #define GFX_TILEMAP_1_PIXEL_WIDTH 16 #define GFX_TILEMAP_1_PIXEL_HEIGHT 16 #define GFX_TILEMAP_1_TILE_COUNT 4 extern const uint16_t GFX_TILEMAP_1[GFX_TILEMAP_1_TILE_COUNT]; #endif
24,911
https://github.com/namirinz/Intern-Pose-Estimation/blob/master/src/utils/data_utils.py
Github Open Source
Open Source
MIT
null
Intern-Pose-Estimation
namirinz
Python
Code
172
476
"""Contain function doing about data.""" import json import os import numpy as np from typing import Dict def get_json(filename: str) -> Dict[str, np.ndarray]: """Open filename.json and return as a dictionary object. Args: filename (str): Json file name to be used. Returns: Dictionary loaded from json file. """ with open(filename, 'r') as json_file: dict_ = json.load(json_file) return dict_ def get_parent_folder(raw_path: str) -> str: """Get class name (parent directories of this file) from full raw_path. Args: raw_path (str): Raw full path name. Returns: A string class name (parent directories of this file) of full path. example: 'projects/folder1/folder2/item.py' -> 'folder2' """ return os.path.basename(os.path.dirname(raw_path)) def get_save_pathname( raw_path: str, classname: str, target_path: str, ) -> str: """Get full path name to be save after being resize. Args: raw_path (str): Raw path name. classname (str): parent directories of raw path. target_path (str): Target path name to be save. Returns: A string full path name to be save. example: 'target_path/classname/item_resize.jpg' """ filename_without_ext, ext = os.path.splitext(os.path.basename(raw_path)) filename_save = filename_without_ext + '_resize' + ext save_path = os.path.join(target_path, classname, filename_save) return save_path
40,279
https://github.com/raphaelmun/Xen/blob/master/XenScript/Actor/IActor.cs
Github Open Source
Open Source
MIT
2,020
Xen
raphaelmun
C#
Code
46
109
using Microsoft.Xna.Framework; using Xen2D; namespace XenScript { /// <summary> /// Represents an object that participates in the game world. Accepts commands issued from a director. /// </summary> /// /// <example> /// Units, switches, environment /// </example> public interface IActor : ICommandExecutor, IEntity, IUpdateableEx { } }
38,506
https://github.com/jamashita/publikum/blob/master/packages/validation/src/Decorator/BooleanValidation.ts
Github Open Source
Open Source
MIT
null
publikum
jamashita
TypeScript
Code
42
93
import { BooleanValidationRule } from '../BooleanValidationRule'; import { addRule } from './Validate'; export const BooleanValidation = (): ParameterDecorator => { const v: BooleanValidationRule = BooleanValidationRule.of(); return (target: object, key: string | symbol, index: number) => { addRule(target, key, index, v); }; };
27,685
https://github.com/LiveRamp/cascading_ext/blob/master/src/main/java/com/liveramp/cascading_tools/combine/LimitedCombineSequenceFileInputFormat.java
Github Open Source
Open Source
Apache-2.0
2,019
cascading_ext
LiveRamp
Java
Code
129
573
package com.liveramp.cascading_tools.combine; import java.io.IOException; import org.apache.hadoop.classification.InterfaceAudience; import org.apache.hadoop.classification.InterfaceStability; import org.apache.hadoop.conf.Configuration; import org.apache.hadoop.mapred.InputSplit; import org.apache.hadoop.mapred.JobConf; import org.apache.hadoop.mapred.RecordReader; import org.apache.hadoop.mapred.Reporter; import org.apache.hadoop.mapred.SequenceFileInputFormat; import org.apache.hadoop.mapred.lib.CombineFileInputFormat; import org.apache.hadoop.mapred.lib.CombineFileRecordReader; import org.apache.hadoop.mapred.lib.CombineFileRecordReaderWrapper; import org.apache.hadoop.mapred.lib.CombineFileSplit; @InterfaceAudience.Public @InterfaceStability.Stable public class LimitedCombineSequenceFileInputFormat<K,V> extends LimitedCombineFileInputFormatMapred<K,V> { @SuppressWarnings({ "rawtypes", "unchecked" }) public RecordReader<K,V> getRecordReader(InputSplit split, JobConf conf, Reporter reporter) throws IOException { return new CombineFileRecordReader(conf, (CombineFileSplit)split, reporter, SequenceFileRecordReaderWrapper.class); } /** * A record reader that may be passed to <code>CombineFileRecordReader</code> * so that it can be used in a <code>CombineFileInputFormat</code>-equivalent * for <code>SequenceFileInputFormat</code>. * * @see CombineFileRecordReader * @see CombineFileInputFormat * @see SequenceFileInputFormat */ private static class SequenceFileRecordReaderWrapper<K,V> extends CombineFileRecordReaderWrapper<K,V> { // this constructor signature is required by CombineFileRecordReader public SequenceFileRecordReaderWrapper(CombineFileSplit split, Configuration conf, Reporter reporter, Integer idx) throws IOException { super(new SequenceFileInputFormat<K,V>(), split, conf, reporter, idx); } } }
18,688
https://github.com/EliranGooner/zeitouni/blob/master/src/components/navbar-new.js
Github Open Source
Open Source
MIT
null
zeitouni
EliranGooner
JavaScript
Code
315
1,014
import AniLink from "gatsby-plugin-transition-link/AniLink" import React, { useState, useEffect } from "react" import "./navbar-new.scss" import { stack as Menu } from "react-burger-menu" import Navbar from "./navbar" import NavbarSmall from "./navbar-small" import NavbarMedium from "./navbar-medium" import sizeMe from "react-sizeme" const NavbarNew = props => { const [path, setPath] = useState(null) useEffect(() => { if (typeof window !== "undefined") { const getCurrentPath = () => { const url = typeof window !== "undefined" ? window.location.href : "" const parts = url.split("/") const finalSegment = parts.pop() || parts.pop() const pathArr = ["projects", "about", "avi", "articles", "contact"] let urlPath pathArr.forEach(pathElement => { if (finalSegment.indexOf(pathElement) >= 0) { urlPath = pathElement } }) if (urlPath === "#" || !pathArr.includes(urlPath)) { setPath("item-home") } else { setPath(`item-${urlPath}`) } } getCurrentPath() } }) const { width } = props.size let ToRenderChildNavbar if (width > 1100) { ToRenderChildNavbar = Navbar } else if (1100 > width && width > 420) { ToRenderChildNavbar = NavbarMedium } else { ToRenderChildNavbar = NavbarSmall } const addMenuHighlight = item => { if (path === item) { setTimeout(() => { return "current-path" }, 1500) } else { return null } } const showSettings = event => { event.preventDefault() } return ( <div id="outer-container"> <ToRenderChildNavbar /> <Menu right disableAutoFocus pageWrapId={"page-wrap"} outerContainerId={"outer-container"} > <AniLink cover direction="right" bg="#808080" to="/" className={"item-home" === path ? "current-path" : null} > בית </AniLink> <AniLink cover direction="right" bg="#808080" to="/projects/" className={"item-projects" === path ? "current-path" : null} > פרויקטים </AniLink> <AniLink cover direction="right" bg="#808080" to="/about/" className={"item-about" === path ? "current-path" : null} > עלינו </AniLink> <AniLink cover direction="right" bg="#808080" to="/avi/" className={"item-avi" === path ? "current-path" : null} > אבי זיתוני </AniLink> <AniLink cover direction="right" bg="#808080" to="/articles/" className={"item-articles" === path ? "current-path" : null} > מהתקשורת </AniLink> <AniLink cover direction="right" bg="#808080" to="/contact/" className={"item-contact" === path ? "current-path" : null} > צרו קשר </AniLink> <a onClick={showSettings} className="menu-item--small" href=""></a> </Menu> <main id="page-wrap"></main> </div> ) } export default sizeMe({ monitorWidth: true })(NavbarNew)
5,468
https://github.com/tazjel/monitor/blob/master/modules/collection.py
Github Open Source
Open Source
LicenseRef-scancode-public-domain
2,013
monitor
tazjel
Python
Code
162
1,048
#!/usr/bin/env python import subprocess import cStringIO import urllib, os from HTMLParser import HTMLParser from gluon import current from appsettings import settings class Collection: @staticmethod def get_graph(action, plugin, typegraph, host, timespan, path_rrd, time_zone, start, end, plugin_instance=None): action=str(action) plugin=str(plugin) typegraph=str(typegraph) host=str(host) timespan=str(timespan) path_rrd=os.path.split(path_rrd)[0] start=str(start) end=str(end) time_zone=time_zone[0] PERL=settings.perl_file COLLECTION=settings.collection_file if plugin_instance==None: plugin_instance = None else: plugin_instance = str(plugin_instance) p=None if plugin_instance==None: p=subprocess.Popen(["env", "TZ="+time_zone, PERL, COLLECTION,\ "action="+action,\ "plugin="+plugin,\ "type="+typegraph,\ "host="+host,\ "timespan="+timespan,\ "start="+start,\ "end="+end,\ "path_rrd="+path_rrd]\ ,stdout=subprocess.PIPE, stderr=subprocess.PIPE) else: p=subprocess.Popen(["env", "TZ="+time_zone, PERL, COLLECTION,\ "action="+action,\ "plugin="+plugin,\ "type="+typegraph,\ "plugin_instance="+plugin_instance,\ "host="+host,\ "timespan="+timespan,\ "start="+start,\ "end="+end, "path_rrd="+path_rrd]\ ,stdout=subprocess.PIPE, stderr=subprocess.PIPE) stdout, stderr=p.communicate() status = p.poll() return cStringIO.StringIO(stdout) @staticmethod def get_plugins(path_rrd): path_rrd=path_rrd r=[] d=urllib.unquote(path_rrd) #regex = re.compile(expression) file_listing=os.listdir(d) for f in file_listing: ff=os.path.join(d,f) if os.path.isdir(ff): r.append(f.split('-')[0]) result=list(set(r)) result.sort() return result @staticmethod def action_collection(path_rrd, plugin, timespan, action): host=os.path.split(path_rrd)[1] plugin=plugin timespan=timespan action=action PERL=settings.perl_file COLLECTION=settings.collection_file p=subprocess.Popen([PERL, COLLECTION,\ "action="+action,\ "plugin="+plugin,\ "host="+host,\ "timespan="+timespan, "path_rrd="+os.path.split(path_rrd)[0]]\ ,stdout=subprocess.PIPE, stderr=subprocess.PIPE) stdout, stderr=p.communicate() status = p.poll() class ImgParse(HTMLParser): def __init__(self): HTMLParser.__init__(self) self.result = [] def handle_starttag(self, tag, attrs): if tag=="img": self.result.append((dict(attrs)["src"])) parse=ImgParse() parse.feed(stdout) return parse.result
31,807
https://github.com/codetorex/godot/blob/master/thirdparty/freetype/src/base/ftgxval.c
Github Open Source
Open Source
CC-BY-3.0, Apache-2.0, MIT
2,022
godot
codetorex
C
Code
324
944
/**************************************************************************** * * ftgxval.c * * FreeType API for validating TrueTypeGX/AAT tables (body). * * Copyright (C) 2004-2020 by * Masatake YAMATO, Redhat K.K, * David Turner, Robert Wilhelm, and Werner Lemberg. * * This file is part of the FreeType project, and may only be used, * modified, and distributed under the terms of the FreeType project * license, LICENSE.TXT. By continuing to use, modify, or distribute * this file you indicate that you have read the license and * understand and accept it fully. * */ /**************************************************************************** * * gxvalid is derived from both gxlayout module and otvalid module. * Development of gxlayout is supported by the Information-technology * Promotion Agency(IPA), Japan. * */ #include <ft2build.h> #include FT_INTERNAL_DEBUG_H #include FT_INTERNAL_OBJECTS_H #include FT_SERVICE_GX_VALIDATE_H /* documentation is in ftgxval.h */ FT_EXPORT_DEF( FT_Error ) FT_TrueTypeGX_Validate( FT_Face face, FT_UInt validation_flags, FT_Bytes tables[FT_VALIDATE_GX_LENGTH], FT_UInt table_length ) { FT_Service_GXvalidate service; FT_Error error; if ( !face ) { error = FT_THROW( Invalid_Face_Handle ); goto Exit; } if ( !tables ) { error = FT_THROW( Invalid_Argument ); goto Exit; } FT_FACE_FIND_GLOBAL_SERVICE( face, service, GX_VALIDATE ); if ( service ) error = service->validate( face, validation_flags, tables, table_length ); else error = FT_THROW( Unimplemented_Feature ); Exit: return error; } FT_EXPORT_DEF( void ) FT_TrueTypeGX_Free( FT_Face face, FT_Bytes table ) { FT_Memory memory; if ( !face ) return; memory = FT_FACE_MEMORY( face ); FT_FREE( table ); } FT_EXPORT_DEF( FT_Error ) FT_ClassicKern_Validate( FT_Face face, FT_UInt validation_flags, FT_Bytes *ckern_table ) { FT_Service_CKERNvalidate service; FT_Error error; if ( !face ) { error = FT_THROW( Invalid_Face_Handle ); goto Exit; } if ( !ckern_table ) { error = FT_THROW( Invalid_Argument ); goto Exit; } FT_FACE_FIND_GLOBAL_SERVICE( face, service, CLASSICKERN_VALIDATE ); if ( service ) error = service->validate( face, validation_flags, ckern_table ); else error = FT_THROW( Unimplemented_Feature ); Exit: return error; } FT_EXPORT_DEF( void ) FT_ClassicKern_Free( FT_Face face, FT_Bytes table ) { FT_Memory memory; if ( !face ) return; memory = FT_FACE_MEMORY( face ); FT_FREE( table ); } /* END */
25,848
https://github.com/mrut2pac/IQFeed.CSharpApiClient/blob/master/src/IQFeed.CSharpApiClient/Lookup/Historical/Messages/IntervalMessage.cs
Github Open Source
Open Source
MIT
2,019
IQFeed.CSharpApiClient
mrut2pac
C#
Code
327
966
using System; using System.Globalization; using IQFeed.CSharpApiClient.Extensions; namespace IQFeed.CSharpApiClient.Lookup.Historical.Messages { public class IntervalMessage : IIntervalMessage { public const string IntervalDateTimeFormat = "yyyy-MM-dd HH:mm:ss"; public IntervalMessage(DateTime timestamp, float high, float low, float open, float close, long totalVolume, int periodVolume, int numberOfTrades, string requestId = null) { RequestId = requestId; Timestamp = timestamp; High = high; Low = low; Open = open; Close = close; TotalVolume = totalVolume; PeriodVolume = periodVolume; NumberOfTrades = numberOfTrades; } public string RequestId { get; } public DateTime Timestamp { get; } public float High { get; } public float Low { get; } public float Open { get; } public float Close { get; } public long TotalVolume { get; } public int PeriodVolume { get; } public int NumberOfTrades { get; } public static IntervalMessage Parse(string message) { var values = message.SplitFeedMessage(); return new IntervalMessage( DateTime.ParseExact(values[0], IntervalDateTimeFormat, CultureInfo.InvariantCulture), float.Parse(values[1], CultureInfo.InvariantCulture), float.Parse(values[2], CultureInfo.InvariantCulture), float.Parse(values[3], CultureInfo.InvariantCulture), float.Parse(values[4], CultureInfo.InvariantCulture), long.Parse(values[5], CultureInfo.InvariantCulture), int.Parse(values[6], CultureInfo.InvariantCulture), int.Parse(values[7], CultureInfo.InvariantCulture)); } public static IntervalMessage ParseWithRequestId(string message) { var values = message.SplitFeedMessage(); var requestId = values[0]; return new IntervalMessage( DateTime.ParseExact(values[1], IntervalDateTimeFormat, CultureInfo.InvariantCulture), float.Parse(values[2], CultureInfo.InvariantCulture), float.Parse(values[3], CultureInfo.InvariantCulture), float.Parse(values[4], CultureInfo.InvariantCulture), float.Parse(values[5], CultureInfo.InvariantCulture), long.Parse(values[6], CultureInfo.InvariantCulture), int.Parse(values[7], CultureInfo.InvariantCulture), int.Parse(values[8], CultureInfo.InvariantCulture), requestId); } public override bool Equals(object obj) { return obj is IntervalMessage message && RequestId == message.RequestId && Timestamp == message.Timestamp && High == message.High && Low == message.Low && Open == message.Open && Close == message.Close && TotalVolume == message.TotalVolume && PeriodVolume == message.PeriodVolume && NumberOfTrades == message.NumberOfTrades; } public override int GetHashCode() { unchecked { var hash = 17; hash = hash * 29 + RequestId != null ? RequestId.GetHashCode() : 0; hash = hash * 29 + Timestamp.GetHashCode(); hash = hash * 29 + High.GetHashCode(); hash = hash * 29 + Low.GetHashCode(); hash = hash * 29 + Open.GetHashCode(); hash = hash * 29 + Close.GetHashCode(); hash = hash * 29 + TotalVolume.GetHashCode(); hash = hash * 29 + PeriodVolume.GetHashCode(); hash = hash * 29 + NumberOfTrades.GetHashCode(); return hash; } } } }
50,028
https://github.com/cqiang102/google_flutter_demo/blob/master/lib/main.dart
Github Open Source
Open Source
MIT
null
google_flutter_demo
cqiang102
Dart
Code
78
300
import 'package:flutter/material.dart'; import 'package:flutter_localizations/flutter_localizations.dart'; import 'package:google_flutter_demo/home_page.dart'; void main() { runApp(const MyApp()); } class MyApp extends StatelessWidget { const MyApp({Key? key}) : super(key: key); // This widget is the root of your application. @override Widget build(BuildContext context) { return MaterialApp( title: 'Flutter Demo', localizationsDelegates: [ GlobalMaterialLocalizations.delegate, GlobalWidgetsLocalizations.delegate, GlobalCupertinoLocalizations.delegate, ], supportedLocales: [ Locale.fromSubtags(languageCode: 'zh'), Locale.fromSubtags(languageCode: 'en'), // Locale('zh', 'CH'), // Chinese, // Locale('en', 'US'), // English, ], debugShowCheckedModeBanner: false, theme: ThemeData( primarySwatch: Colors.blue, ), home: const HomePage(), ); } }
30,110
https://github.com/meghanasherigar/AppFinalProj/blob/master/node_modules/ngx-ui-loader/lib/core/ngx-ui-loader.interfaces.d.ts
Github Open Source
Open Source
MIT
null
AppFinalProj
meghanasherigar
TypeScript
Code
40
103
export interface Task { [taskId: string]: number; } export interface Loader { loaderId: string; foreground: Task; background: Task; isMaster?: boolean; isBound: boolean; } export interface Loaders { [loaderId: string]: Loader; } export interface ShowEvent { loaderId: string; isShow: boolean; }
2,503
https://github.com/fnuecke/Circuity/blob/master/src/main/java/li/cil/circuity/server/processor/mips/package-info.java
Github Open Source
Open Source
CC0-1.0, MIT, LicenseRef-scancode-public-domain
2,017
Circuity
fnuecke
Java
Code
8
64
@ParametersAreNonnullByDefault @MethodsReturnNonnullByDefault package li.cil.circuity.server.processor.mips; import mcp.MethodsReturnNonnullByDefault; import javax.annotation.ParametersAreNonnullByDefault;
17,016
https://github.com/lucasvale/ProjetoWeb/blob/master/codedelivery/app/Http/Controllers/ProductionController.php
Github Open Source
Open Source
MIT
2,016
ProjetoWeb
lucasvale
PHP
Code
111
628
<?php namespace CodeDelivery\Http\Controllers; use CodeDelivery\Repositories\CategoryRepository; use CodeDelivery\Repositories\ProductRepository; use CodeDelivery\Http\Requests\AdminProductRequest; use Illuminate\Support\Facades\DB; use Intervention\Image\Facades\Image; use Illuminate\Http\Request; class ProductionController extends Controller { private $repository; private $categoryRepository; public function __construct(ProductRepository $repository, CategoryRepository $categoryRepository) { $this->repository=$repository; $this->categoryRepository=$categoryRepository; } public function index(){ $products = $this->repository->paginate(); return view('admin.barkery.producao.producao',compact('products')); } public function create(){ $categories=DB::table('categories')->pluck('name','id'); return view('admin.products.create',compact('categories')); } public function store(AdminProductRequest $request){ $data = $request->all(); $this->repository->create($data); return redirect()->route('admin.products.index')->onlyInput('name'); } public function edit($id){ $product = $this->repository->find($id); //$categories=$this->categoryRepository->lists('id'); $categories=DB::table('categories')->pluck('name','id'); return view('admin.products.edit',compact('product','categories')); } public function update(Request $request,$id){ if($request->hasFile('photo')){ $data = $request->all(); $image = $request->file('photo'); $filename= time().'.' . $image->getClientOriginalExtension(); Image::make($image)->resize(300,300)->save(public_path('/uploads/products/'.$filename)); $data['photo']=$filename; } $this->repository->update($data,$id); return redirect()->route('admin.products.index'); } public function destroy($id){ $this->repository->delete($id); return redirect()->route('admin.products.index'); } public function description($id){ $product = $this->repository->find($id); return view('admin.products.description',compact('product')); } }
44,433
https://github.com/rizwan3d/XF_FoodApp/blob/master/XF_FoodApp/XF_FoodApp/Models/Food.cs
Github Open Source
Open Source
MIT
2,019
XF_FoodApp
rizwan3d
C#
Code
36
84
using System; using System.Collections.Generic; using System.Text; namespace XF_FoodApp.Models { public class Food { public string Image_Food { get; set; } public string Title_Food { get; set; } public string Price_Food { get; set; } } }
28,139
https://github.com/MaciejGrodecki/LicenseManager/blob/master/tests/LicenseManager.Tests/Services/LicenseTypeServiceTests.cs
Github Open Source
Open Source
Net-SNMP, Xnet
null
LicenseManager
MaciejGrodecki
C#
Code
317
1,897
using System; using System.Collections.Generic; using System.Threading.Tasks; using AutoMapper; using FluentAssertions; using LicenseManager.Core.Domain; using LicenseManager.Core.Repositories; using LicenseManager.Infrastructure.DTO; using LicenseManager.Infrastructure.Services; using Moq; using Xunit; namespace LicenseManager.Tests.Services { public class LicenseTypeServiceTests { private readonly Mock<ILicenseTypeRepository> _licenseTypeRepositoryMock; private readonly Mock<IMapper> _mapperMock; private readonly ILicenseTypeService _licenseTypeService; private readonly LicenseType _licenseType = new LicenseType(Guid.NewGuid(), "OEM"); private readonly ISet<LicenseType> _licenseTypes = new HashSet<LicenseType>(); private readonly LicenseTypeDto _licenseTypeDto; private readonly ISet<LicenseTypeDto> _licenseTypesDto = new HashSet<LicenseTypeDto>(); public LicenseTypeServiceTests() { _licenseTypeRepositoryMock = new Mock<ILicenseTypeRepository>(); _mapperMock = new Mock<IMapper>(); _licenseTypeService = new LicenseTypeService(_licenseTypeRepositoryMock.Object, _mapperMock.Object); _licenseTypeDto = new LicenseTypeDto{ LicenseTypeId = _licenseType.LicenseTypeId, Name = _licenseType.Name }; _licenseTypes.Add(_licenseType); _licenseTypesDto.Add(_licenseTypeDto); } [Fact] public async Task When_invoking_browse_async_it_should_invoke_browse_async_on_repository() { //Arrange _mapperMock.Setup(x => x.Map<IEnumerable<LicenseTypeDto>>(_licenseTypes)).Returns(_licenseTypesDto); _licenseTypeRepositoryMock.Setup(x => x.BrowseAsync()).ReturnsAsync(_licenseTypes); //Act var exististingLicenseTypesDto = await _licenseTypeService.BrowseAsync(); //Assert _licenseTypeRepositoryMock.Verify( x => x.BrowseAsync(), Times.Once()); _licenseTypesDto.Should().NotBeNull(); _licenseTypesDto.Count.Should().Be(1); } [Fact] public async Task When_invoke_get_async_with_licenseTypeId_parameter_it_should_invoke_get_async_on_licenseType_repository() { //Arrange _mapperMock.Setup(x => x.Map<LicenseTypeDto>(_licenseType)).Returns(_licenseTypeDto); _licenseTypeRepositoryMock.Setup(x => x.GetAsync(_licenseType.LicenseTypeId)).ReturnsAsync(_licenseType); //Act var existingLicenseTypeDto = await _licenseTypeService.GetAsync(_licenseType.LicenseTypeId); //Assert _licenseTypeRepositoryMock.Verify(x => x.GetAsync(_licenseType.LicenseTypeId), Times.Once()); _licenseTypeDto.Should().NotBeNull(); _licenseTypeDto.Name.ShouldAllBeEquivalentTo(_licenseType.Name); } [Fact] public async Task When_invoke_get_async_with_licenseTypeId_parameter_and_license_type_do_not_exists_it_should_invoke_get_async_on_licenseType_repository() { //Arrange _licenseTypeRepositoryMock.Setup(x => x.GetAsync(_licenseType.LicenseTypeId)).ReturnsAsync(() => null); //Act await _licenseTypeService.GetAsync(_licenseType.LicenseTypeId); //Assert _licenseTypeRepositoryMock.Verify(x => x.GetAsync(_licenseType.LicenseTypeId), Times.Once()); } [Fact] public async Task When_invoke_get_async_with_name_parameter_it_should_invoke_get_async_on_room_repository() { //Arrange _mapperMock.Setup(x => x.Map<LicenseTypeDto>(_licenseType)).Returns(_licenseTypeDto); _licenseTypeRepositoryMock.Setup(x => x.GetAsync(_licenseType.Name)).ReturnsAsync(_licenseType); //Act var existingLicenseTypeDto = await _licenseTypeService.GetAsync(_licenseType.Name); //Assert _licenseTypeRepositoryMock.Verify(x => x.GetAsync(_licenseType.Name), Times.Once()); _licenseTypeDto.Should().NotBeNull(); _licenseTypeDto.Name.ShouldBeEquivalentTo(_licenseType.Name); } [Fact] public async Task When_invoke_get_async_with_name_parameter_and_license_type_do_not_exists_it_should_invoke_get_async_on_licenseType_repository() { //Arrange _licenseTypeRepositoryMock.Setup(x => x.GetAsync(_licenseType.Name)).ReturnsAsync(() => null); //Act await _licenseTypeService.GetAsync(_licenseType.Name); //Assert _licenseTypeRepositoryMock.Verify(x => x.GetAsync(_licenseType.Name), Times.Once()); } [Fact] public async Task Add_licenseType_async_should_invoke_add_licenseType_async_on_licenseType_repository() { //Act await _licenseTypeService.AddAsync("OEM"); //Assert _licenseTypeRepositoryMock.Verify(x => x.AddAsync(It.IsAny<LicenseType>()), Times.Once()); } [Fact] public async Task Add_licenseType_async_and_licenseType_with_name_already_exists_should_not_invoke_add_licenseType_async_on_licenseType_repository() { //Arrange _licenseTypeRepositoryMock.Setup(x => x.GetAsync(_licenseType.Name)).ReturnsAsync((_licenseType)); //Act await Assert.ThrowsAsync<LicenseManagerException>(async () => await _licenseTypeService.AddAsync(_licenseType.Name)); //Assert _licenseTypeRepositoryMock.Verify(x => x.GetAsync(_licenseType.Name), Times.Once()); _licenseTypeRepositoryMock.Verify(x => x.AddAsync(_licenseType), Times.Never()); } [Fact] public async Task Remove_licenseType_async_should_invoke_remove_licenseType_async_on_licenseType_repository() { //Arrange _licenseTypeRepositoryMock.Setup(x => x.GetAsync(_licenseType.LicenseTypeId)).ReturnsAsync(_licenseType); //Act await _licenseTypeService.RemoveAsync(_licenseType.LicenseTypeId); //Assert _licenseTypeRepositoryMock.Verify(x => x.GetAsync(_licenseType.LicenseTypeId), Times.Once()); _licenseTypeRepositoryMock.Verify(x => x.RemoveAsync(_licenseType), Times.Once()); } [Fact] public async Task Remove_licenseType_async_and_licenseType_does_not_exists_should_not_invoke_remove_licenseType_async_on_licenseType_repository() { //Arrange _licenseTypeRepositoryMock.Setup(x => x.GetAsync(_licenseType.LicenseTypeId)).ReturnsAsync(() => null); //Act await Assert.ThrowsAsync<LicenseManagerException>(async () => await _licenseTypeService.RemoveAsync(_licenseType.LicenseTypeId)); //Assert _licenseTypeRepositoryMock.Verify(x => x.GetAsync(_licenseType.LicenseTypeId), Times.Once()); _licenseTypeRepositoryMock.Verify(x => x.RemoveAsync(_licenseType), Times.Never()); } } }
11,069
https://github.com/urids/XSCALAMPI/blob/master/ompi/mca/btl/openib/btl_openib_ini.h
Github Open Source
Open Source
BSD-3-Clause-Open-MPI
2,019
XSCALAMPI
urids
C
Code
153
559
/* * Copyright (c) 2006-2013 Cisco Systems, Inc. All rights reserved. * Copyright (c) 2008 Mellanox Technologies. All rights reserved. * $COPYRIGHT$ * * Additional copyrights may follow * * $HEADER$ * * @file */ #ifndef MCA_PTL_IB_PARAMS_H #define MCA_PTL_IB_PARAMS_H #include "btl_openib.h" /* * Struct to hold the settable values that may be specified in the INI * file */ typedef struct ompi_btl_openib_ini_values_t { uint32_t mtu; bool mtu_set; uint32_t use_eager_rdma; bool use_eager_rdma_set; char *receive_queues; int32_t max_inline_data; bool max_inline_data_set; bool rdmacm_reject_causes_connect_error; bool rdmacm_reject_causes_connect_error_set; bool ignore_device; bool ignore_device_set; } ompi_btl_openib_ini_values_t; BEGIN_C_DECLS /** * Read in the INI files containing device params */ int ompi_btl_openib_ini_init(void); /** * Query the read-in params for a given device */ int ompi_btl_openib_ini_query(uint32_t vendor_id, uint32_t vendor_part_id, ompi_btl_openib_ini_values_t *values); /** * Shut down / release all internal state */ int ompi_btl_openib_ini_finalize(void); /** * string to int convertors with dec/hex autodetection */ int ompi_btl_openib_ini_intify(char *string); int ompi_btl_openib_ini_intify_list(char *str, uint32_t **values, int *len); END_C_DECLS #endif
47,372
https://github.com/Abc-Arbitrage/Zebus/blob/master/src/Abc.Zebus.Testing/TestBus.cs
Github Open Source
Open Source
MIT
2,023
Zebus
Abc-Arbitrage
C#
Code
1,059
3,499
using System; using System.Collections.Concurrent; using System.Collections.Generic; using System.Linq; using System.Threading.Tasks; using Abc.Zebus.Serialization; using Abc.Zebus.Testing.Comparison; using Abc.Zebus.Util; using Abc.Zebus.Util.Extensions; namespace Abc.Zebus.Testing { public class TestBus : IBus, IInternalBus { private readonly ConcurrentDictionary<HandlerKey, Func<IMessage, object?>> _handlers = new ConcurrentDictionary<HandlerKey, Func<IMessage, object?>>(); private readonly MessageComparer _messageComparer = new MessageComparer(); private readonly Dictionary<PeerId, List<IMessage>> _messagesByPeerId = new Dictionary<PeerId, List<IMessage>>(); private readonly Dictionary<ICommand, Peer?> _peerByCommand = new Dictionary<ICommand, Peer?>(); private readonly List<IEvent> _events = new List<IEvent>(); private readonly List<ICommand> _commands = new List<ICommand>(); private readonly HashSet<Subscription> _subscriptions = new HashSet<Subscription>(); public TestBus() { MessageSerializer = new MessageSerializer(); HandlerExecutor = new DefaultHandlerExecutor(); } public event Action Starting = delegate { }; public event Action Started = delegate { }; public event Action Stopping = delegate { }; public event Action Stopped = delegate { }; public IEnumerable<ICommand> Commands { get { lock (_commands) { return _commands.ToList(); } } } public IEnumerable<IEvent> Events { get { lock (_events) { return _events.ToList(); } } } public int MessageCount => _commands.Count + _events.Count; public HashSet<Subscription> Subscriptions { get { lock (_subscriptions) { return new HashSet<Subscription>(_subscriptions); } } } public int LastReplyCode { get; set; } public string? LastReplyMessage { get; set; } public object? LastReplyResponse { get; set; } public IHandlerExecutor HandlerExecutor { get; set; } public IMessageSerializer MessageSerializer { get; set; } public bool IsStarted { get; private set; } public bool IsStopped { get; private set; } public PeerId PeerId { get; private set; } public string Environment { get; private set; } = string.Empty; public bool IsRunning { get; private set; } public IEnumerable<IMessage> Messages => Events.Cast<IMessage>().Concat(Commands); public void Publish(IEvent message) { Publish(message, null); } public void Publish(IEvent message, PeerId targetPeer) { Publish(message, (PeerId?)targetPeer); } private void Publish(IEvent message, PeerId? targetPeer) { if (MessageSerializer.TryClone(message, out var clone)) message = (IEvent)clone; lock (_events) { _events.Add(message); if (targetPeer != null) _messagesByPeerId.GetValueOrAdd(targetPeer.Value, p => new List<IMessage>()).Add(message); } if (_handlers.TryGetValue(new HandlerKey(message.GetType(), default), out var handler)) handler.Invoke(message); } public Task<CommandResult> Send(ICommand message) { return Send(message, null); } public Task<CommandResult> Send(ICommand message, Peer? peer) { if (MessageSerializer.TryClone(message, out var clone)) message = (ICommand)clone; lock (_commands) { _commands.Add(message); if (peer != null) _messagesByPeerId.GetValueOrAdd(peer.Id, p => new List<IMessage>()).Add(message); _peerByCommand[message] = peer; } Func<IMessage, object?>? handler; if (peer != null) _handlers.TryGetValue(new HandlerKey(message.GetType(), peer.Id), out handler); else handler = null; // TODO why do we fall back in all cases? if (handler == null) _handlers.TryGetValue(new HandlerKey(message.GetType(), default), out handler); return HandlerExecutor.Execute(message, handler); } public async Task<IDisposable> SubscribeAsync(SubscriptionRequest request) { request.MarkAsSubmitted(0, IsRunning); if (request.Batch != null) await request.Batch.WhenSubmittedAsync().ConfigureAwait(false); await AddSubscriptionsAsync(request).ConfigureAwait(false); return new DisposableAction(() => RemoveSubscriptions(request)); } public async Task<IDisposable> SubscribeAsync(SubscriptionRequest request, Action<IMessage> handler) { request.MarkAsSubmitted(0, IsRunning); if (request.Batch != null) await request.Batch.WhenSubmittedAsync().ConfigureAwait(false); var handlerKeys = request.Subscriptions.Select(x => new HandlerKey(x.MessageTypeId.GetMessageType()!, default)).ToList(); foreach (var handlerKey in handlerKeys) { _handlers[handlerKey] = x => { handler(x); return null; }; } await AddSubscriptionsAsync(request).ConfigureAwait(false); return new DisposableAction(() => { RemoveSubscriptions(request); _handlers.RemoveRange(handlerKeys); }); } private async Task AddSubscriptionsAsync(SubscriptionRequest request) { if (request.Batch != null) { var batchSubscriptions = request.Batch.TryConsumeBatchSubscriptions(); if (batchSubscriptions != null) { AddSubscriptions(batchSubscriptions); request.Batch.NotifyRegistrationCompleted(null); } else { await request.Batch.WhenRegistrationCompletedAsync().ConfigureAwait(false); } } else { AddSubscriptions(request.Subscriptions); } void AddSubscriptions(IEnumerable<Subscription> subscriptions) { lock (_subscriptions) { _subscriptions.AddRange(subscriptions); } } } private void RemoveSubscriptions(SubscriptionRequest request) { lock (_subscriptions) { _subscriptions.RemoveRange(request.Subscriptions); } } public void Reply(int errorCode) { LastReplyCode = errorCode; LastReplyMessage = null; } public void Reply(int errorCode, string? message) { LastReplyCode = errorCode; LastReplyMessage = message; } public void Reply(IMessage? response) { LastReplyResponse = response; } public void Configure(PeerId peerId, string environment = "Test") { PeerId = peerId; Environment = environment; } public void Start() { Starting(); IsStarted = true; IsRunning = true; Started(); } public void Stop() { Stopping(); IsStopped = true; IsRunning = false; Stopped(); } public void AddHandler<TMessage>(Func<TMessage, object?> handler) where TMessage : IMessage { _handlers[new HandlerKey(typeof(TMessage), default)] = x => handler((TMessage)x); } public void AddSuccessfulHandler<TMessage>() where TMessage : IMessage { _handlers[new HandlerKey(typeof(TMessage), default)] = x => true; } public void AddHandlerForPeer<TMessage>(PeerId peerId, Func<TMessage, object?> handler) where TMessage : IMessage { _handlers[new HandlerKey(typeof(TMessage), peerId)] = x => handler((TMessage)x); } public void AddHandlerForPeer<TMessage>(PeerId peerId, Action<TMessage> handler) where TMessage : IMessage { _handlers[new HandlerKey(typeof(TMessage), peerId)] = x => { handler((TMessage)x); return null; }; } public void AddHandler<TMessage>(Action<TMessage> handler) where TMessage : IMessage { _handlers[new HandlerKey(typeof(TMessage), default)] = x => { handler((TMessage)x); return null; }; } public void AddHandlerThatThrowsDomainException<TMessage>(DomainException ex) where TMessage : IMessage { _handlers[new HandlerKey(typeof(TMessage), default)] = _ => throw ex; } public void AddHandlerThatThrowsMessageProcessingException<TMessage>(MessageProcessingException ex) where TMessage : IMessage { _handlers[new HandlerKey(typeof(TMessage), default)] = _ => throw ex; } public void AddHandlerThatThrows<TMessage>(Exception? ex = null) where TMessage : IMessage { _handlers[new HandlerKey(typeof(TMessage), default)] = _ => throw (ex ?? new Exception()); } public void Expect(IEnumerable<IMessage> expectedMessages) { _messageComparer.CheckExpectations(Messages, expectedMessages, false); } public void Expect(params IMessage[] expectedMessages) { _messageComparer.CheckExpectations(Messages, expectedMessages, false); } public void ExpectExactly(params IMessage[] expectedMessages) { _messageComparer.CheckExpectations(Messages, expectedMessages, true); } public void ExpectExactly(PeerId peerId, params IMessage[] expectedMessages) { var messages = _messagesByPeerId.GetValueOrDefault(peerId, p => new List<IMessage>()); _messageComparer.CheckExpectations(messages, expectedMessages, true); } public void ExpectNothing() { _messageComparer.CheckExpectations(Messages, new List<object>(), true); } public IList<PeerId> GetContactedPeerIds() { return _messagesByPeerId.Keys.ToList(); } public Peer? GetRecipientPeer(ICommand command) { return _peerByCommand[command]; } /// <summary> /// Executes handler synchronously (simulate locally handled messages). /// </summary> public class DefaultHandlerExecutor : IHandlerExecutor { public Task<CommandResult> Execute(ICommand command, Func<IMessage, object?>? handler) { var taskCompletionSource = new TaskCompletionSource<CommandResult>(); try { var result = handler?.Invoke(command); taskCompletionSource.SetResult(new CommandResult(0, null, result)); } catch (MessageProcessingException ex) { taskCompletionSource.SetResult(new CommandResult(ex.ErrorCode, ex.Message, null)); } catch (Exception) { taskCompletionSource.SetResult(new CommandResult(1, null, null)); } return taskCompletionSource.Task; } } /// <summary> /// Executes handler asynchronously (simulate remotely handled messages or messages handled in /// a different dispatch queue). /// </summary> public class AsyncHandlerExecutor : IHandlerExecutor { public Task<CommandResult> Execute(ICommand command, Func<IMessage, object?>? handler) { return Task.Run(() => { try { var response = handler?.Invoke(command); return new CommandResult(0, null, response); } catch (MessageProcessingException ex) { return new CommandResult(ex.ErrorCode, ex.Message, null); } catch (Exception ex) { return new CommandResult(1, ex.Message, null); } }); } } /// <summary> /// Never executes handler (simulate down peer). /// </summary> public class DoNotReplyHandlerExecutor : IHandlerExecutor { public Task<CommandResult> Execute(ICommand command, Func<IMessage, object?>? handler) { return new TaskCompletionSource<CommandResult>().Task; } } public interface IHandlerExecutor { Task<CommandResult> Execute(ICommand command, Func<IMessage, object?>? handler); } private class HandlerKey : Tuple<Type, PeerId> { public HandlerKey(Type type, PeerId peerId) : base(type, peerId) { } } public IDisposable InjectSubscription(Subscription subscription) => this.Subscribe(subscription); public void Dispose() { Stop(); } public void ClearMessages() { lock (_commands) { _commands.Clear(); _peerByCommand.Clear(); _messagesByPeerId.Clear(); } lock (_events) { _events.Clear(); } } } }
18,102
https://github.com/Vitalinsh/Fruit_recognizer_application/blob/master/server/drafts/server2.py
Github Open Source
Open Source
MIT
2,018
Fruit_recognizer_application
Vitalinsh
Python
Code
142
492
import subprocess import os from flask import Flask, request, Response import jsonpickle import numpy as np import cv2 import tensorflow as tf from models.recognizer import FruitRecognizer global graph graph = tf.get_default_graph() base_dir = os.path.abspath(os.path.dirname(__file__)) model_path = os.path.join(base_dir, 'models', "saved_models", "model1_vgg16_architecture.json") weights_path = os.path.join(base_dir, 'models', "saved_models", "model1_vgg16_best1_weights.hdf5") version = subprocess.check_output(["git", "describe"]).strip() print(version) reco = FruitRecognizer(model_path=model_path, weights_path=weights_path) app = Flask(__name__) # route http posts to this method @app.route('/api/recognize_fruit', methods=['POST']) def test(): r = request # convert string of image data to uint8 nparr = np.fromstring(r.data, np.uint8) # decode image img = cv2.imdecode(nparr, cv2.IMREAD_COLOR) # do some fancy processing here.... with graph.as_default(): res = reco.predict(img) # build a response dict to send back to client response = {'message': 'Your fruit is {}'.format(res)} # encode response using jsonpickle response_pickled = jsonpickle.encode(response) return Response(response=response_pickled, status=200, mimetype="application/json") # start flask app app.run(host="0.0.0.0", port=5000, debug=False) # app.run(host='0.0.0.0', debug=False, threaded=False)
51,054