query
stringlengths
9
14.6k
document
stringlengths
8
5.39M
metadata
dict
negatives
listlengths
0
30
negative_scores
listlengths
0
30
document_score
stringlengths
5
10
document_rank
stringclasses
2 values
Update parses the fields object.
static update(fields, value) { if (typeof value === 'number') { fields.position = value; } else if (typeof value === 'string') { fields.insertString = value; } else if (typeof value === 'object' && value.d !== undefined) { fields.delNum = value.d; } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "updateFieldItems() {\n this.fieldItems = this.getFieldItems();\n this.fullQueryFields = this.getFullQueryFields();\n this.availableFieldItemsForFieldMapping = this.getAvailableFieldItemsForFieldMapping();\n this.availableFieldItemsForMocking = this.getAvailableFieldItemsForMocking();\n ...
[ "0.6534012", "0.6243479", "0.5951857", "0.5935676", "0.5812142", "0.5785142", "0.57144314", "0.5676728", "0.5634616", "0.5613708", "0.5613708", "0.5613708", "0.5552826", "0.5552008", "0.5514293", "0.5502407", "0.54850435", "0.54850435", "0.54824096", "0.5462734", "0.5454468",...
0.6384207
1
Function overwrites the snapshot with the newly formed text.
replaceText(newText) { this.snapshot = newText; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function updateDrawingTextOfAPeer(oldTextObj, newTextObj) {\n oldTextObj.setText(newTextObj.text);\n}", "onInsert(position, text) {\n const previous = this.snapshot.replace(/\\r\\n/g, '\\n');\n if (this.flagMap && this.flags.some(flag => text.includes(flag))) {\n for (let i = 0; i < this.flags.leng...
[ "0.6025381", "0.56691813", "0.5602115", "0.55739015", "0.5545175", "0.5539405", "0.55192924", "0.5517494", "0.550185", "0.54993063", "0.5446492", "0.54442877", "0.5383629", "0.53786916", "0.53777283", "0.5361774", "0.5358236", "0.5357532", "0.5346836", "0.5329003", "0.5317956...
0.7279022
0
Emits `modifiers` in the standard order. Modifiers in `implicitModifiers` will not be emitted.
emitModifiers(modifiers, implicitModifiers = []) { if (modifiers.length === 0) { return; } Modifier_1.ModifierOrder.forEach(m => { if (modifiers.includes(m) && !implicitModifiers.includes(m)) { this.emit(m).emit(' '); } }); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function jsonModifiers (modifiers) {\n return modifiers.map(function(modifier) {\n return {\n name: modifier.name(),\n description: modifier.description(),\n className: modifier.className(),\n markup: handlebars.compile( modifier.markup(...
[ "0.5912751", "0.5778478", "0.55389726", "0.55016446", "0.54435825", "0.53924644", "0.5315401", "0.5092283", "0.504987", "0.5005653", "0.49956205", "0.49798614", "0.48853672", "0.48853672", "0.48853672", "0.48853672", "0.48853672", "0.48853672", "0.48853672", "0.48853672", "0....
0.85751927
0
Emit type variables with their bounds. This should only be used when declaring type variables; everywhere else bounds are omitted.
emitTypeVariables(typeVariables) { if (typeVariables.length === 0) { return; } this.emit('<'); let index = 0; typeVariables.forEach(typeVariable => { if (index > 0) { this.emit(', '); } let code = typeVariable.name; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "static typeVariable(name, ...bounds) {\n return new TypeVariable(name, bounds);\n }", "function createVariableGuards(node) {\n var genericTypes = arguments.length <= 1 || arguments[1] === undefined ? [] : arguments[1];\n\n var guards = [];\n node.declarations.forEach(function (declaration) {\n...
[ "0.6681532", "0.55085516", "0.54282314", "0.54008746", "0.5322509", "0.5320002", "0.5071769", "0.49101838", "0.48459303", "0.48416767", "0.4645778", "0.46300855", "0.46205974", "0.4618851", "0.4618851", "0.46162865", "0.45846063", "0.4572573", "0.45611298", "0.45323926", "0.4...
0.6783847
0
Emits `s` with indentation as required. It's important that all code that writes to [CodeWriter.out] does it through here, since we emit indentation lazily in order to avoid unnecessary trailing whitespace.
emit(s) { let first = true; s.split('\n').forEach(line => { // Emit a newline character. Make sure blank lines in KDoc & comments look good. if (!first) { if ((this.javaDoc || this.comment) && this.trailingNewline) { this.emitIndentation(); ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "out(s, level){\n\t\tfor (var i = 0; i < level; i++){\n\t\t\ts = rtl.toString(this._indent)+rtl.toString(s);\n\t\t}\n\t\treturn s;\n\t}", "stringifyIndent() {\n this.output += ' '.repeat (this.depth * this.indent);\n}", "stringifyIndent() {\n this.output += ' '.repeat (this.depth * this.indent);\n}", "funct...
[ "0.6667539", "0.6158071", "0.6158071", "0.5879539", "0.5879539", "0.58450633", "0.57234466", "0.5607331", "0.5572616", "0.5371858", "0.5318621", "0.5281525", "0.5184307", "0.5157073", "0.5130015", "0.510696", "0.509826", "0.50598997", "0.5036286", "0.4992665", "0.49786776", ...
0.68163574
0
Returns the symbols that are required to be imported for this code. If there were any simple name collisions, that symbol's first use is imported; which may cause compilation issues.
requiredImports() { const imported = []; this.referencedSymbols.forEach(sym => { if (sym instanceof SymbolSpecs_1.Imported) { imported.push(sym); } }); return imported; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function symbols() {\n\t\treturn Object.keys(exports).sort();\n\t}", "function symbols() {\n\t\treturn Object.keys(exports).sort();\n\t}", "function symbols() {\n\t\treturn Object.keys(exports).sort();\n\t}", "function symbols() {\n\t\treturn Object.keys(exports).sort();\n\t}", "function symbols() {\n ...
[ "0.7059442", "0.7059442", "0.7059442", "0.7059442", "0.704018", "0.5961855", "0.5707616", "0.56363344", "0.5622107", "0.5522771", "0.5473754", "0.54508", "0.5431058", "0.53702337", "0.53340536", "0.53340536", "0.53162295", "0.5254533", "0.5244134", "0.5192388", "0.51802367", ...
0.7978662
0
If output path is `sub/foo.ts` and importPath is `./foo`, we want to return `../foo`. Note that technically ! is supposed to be usable as a hint to do/not do this, but we don't look for that yet.
function maybeRelativePath(outputPath, importPath) { if (!importPath.startsWith('./')) { return importPath; } // Ideally we'd use a path library to do this const dirs = outputPath.split('').filter(l => l === '/').length; if (dirs === 0) { return importPath; } const a = new Ar...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function fixImportPath(fromDir, path, info) {\n const outPath = getOutPath(getFullPath(join(fromDir, path)), info);\n const isNested = outPath.indexOf(\"/\") >= 0;\n const fromEntryDir = fromDir === Path.dirname(info.entry);\n // Assumes flat folder structure\n if (isNested && fromEntryDir) {\n ...
[ "0.6514784", "0.6327105", "0.5859314", "0.5735037", "0.5733865", "0.5690174", "0.56680703", "0.5635415", "0.5604915", "0.5585074", "0.5525361", "0.55141187", "0.54733807", "0.5448557", "0.54134655", "0.53751564", "0.5330948", "0.5330948", "0.5330948", "0.5330948", "0.5330948"...
0.8131097
0
doc function beepInit() Call beepInit() to initializes rawbeep. You need to initialize rawbeep through a touch or click event on mobile platforms to make sound work. Calling beepInit() is optional on desktop devices because rawbeep initializes when you call beep() for the first time.
function beepInit() { if (!beep.audioCtx) { beep.audioCtx = new (window.AudioContext || window.webkitAudioContext)(); beep([[4186.01, 0.005]], 0.01); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "beep() {\n // start beep\n }", "static beep(success){\n var soundID = Platform.select({\n ios: (success == false)? 1257: 1256,\n android: (success == false)? 25: 24\n });\n\n this.PlaySysSound(soundID);\n \n }", "function normalBeep() {\n beep (...
[ "0.73872435", "0.7211924", "0.71799994", "0.7097395", "0.697549", "0.69430953", "0.69175655", "0.6816581", "0.68097293", "0.68096566", "0.6584571", "0.6580773", "0.65557945", "0.6510595", "0.64820915", "0.6458715", "0.6452189", "0.6449786", "0.6436654", "0.64269197", "0.63844...
0.8797269
0
doc function beep([notes, [volume]]) The main function and a tribute to the BEEP statement from former times. Just call "beep()" and it makes a beep sound. Arguments notes Optional. A string with multiple parts of notes, duration and variables. Parts are separated using at least one space. Notes are written as: C D E F...
function beep(notes, volume, type) { if (!beep.audioCtx) beepInit(); var audioCtx = beep.audioCtx; var bpm = 240; notes = beepCompile(notes); if (!notes) notes = [[400, 1]]; if (!type) type = 'square'; if (!volume) volume = 0.5; var timeStart = audioCtx.currentTime; var timeCurrent = timeStart; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function normalBeep() {\n beep (220, 100)\n}", "function beep (frequency, time) {\n CppBeeper.beep (frequency, time)\n}", "beep() {\n // start beep\n }", "function beep(duration, frequency, volume, type, callback) {\n var oscillator = audioCtx.createOscillator();\n var gainNode = audioC...
[ "0.75375354", "0.7285341", "0.72125983", "0.71992505", "0.71567124", "0.7100814", "0.7018089", "0.6999471", "0.6975535", "0.6905477", "0.69029224", "0.68767357", "0.686869", "0.68338513", "0.6828719", "0.6822924", "0.67625946", "0.67562306", "0.67505926", "0.66931784", "0.662...
0.81018543
0
doc function sound(frequency, [duration, [volume]]) The sound function is a tribute to the SOUND statement from former times. The arguments are compatible to QBasic. However, volume did not exist back then in QBasic. Arguments frequency The tone frequency in Hertz. duration Optional. Tone duration in seconds. volume Op...
function sound(frequency, duration, volume) { if (!duration) duration = 1; beep([[frequency, duration]], volume); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function playSound(freq) {\r\n var context = new AudioContext();\r\n o=context.createOscillator();\r\n g=context.createGain();\r\n o.type='sine';\r\n o.connect(g);\r\n o.frequency.value=notes[3][freq];\r\n g.connect(context.destination);\r\n o.start(0);\r\n g.gain.exponentialRampToValueA...
[ "0.68460995", "0.668164", "0.65302867", "0.650658", "0.6477767", "0.647723", "0.63827395", "0.6376316", "0.63667184", "0.6343149", "0.6339486", "0.6329454", "0.6302388", "0.6286587", "0.62621695", "0.6260958", "0.6257145", "0.62529564", "0.6250309", "0.62478137", "0.6230308",...
0.84140354
0
!doc function beepCompile(string) Converts a string of notes to an array of frequencies. If you pass another argument than a string it will be returned unchanged. Arguments string A string with multiple parts of notes, duration and variables. See beep() for note syntax. Usage See beep() for note syntax. If you plan to ...
function beepCompile(s) { // Return value unchanged if it is not a string // This is useful if the string is already processed and passed to this function a second time if (typeof s != "string") return s; // Remove comments starting with "#" s = s.replace(/[ ]#[ ].*/g, ''); // Remove extra whitespaces s = s...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function beep (frequency, time) {\n CppBeeper.beep (frequency, time)\n}", "function beep(notes, volume, type) {\n\tif (!beep.audioCtx)\n\t\tbeepInit();\n\tvar audioCtx = beep.audioCtx;\n\n\tvar bpm = 240;\n\n\tnotes = beepCompile(notes);\n\t\n\tif (!notes)\n\t\tnotes = [[400, 1]];\n\n\tif (!type)\n\t\ttype = ...
[ "0.67614067", "0.65825427", "0.6187535", "0.6178385", "0.6052378", "0.59919643", "0.5967966", "0.58377945", "0.58141977", "0.5792334", "0.57485366", "0.5744594", "0.57215965", "0.5713102", "0.5704845", "0.5699016", "0.5688351", "0.566088", "0.56073236", "0.5598035", "0.558630...
0.8014604
0
Draw a flower function call block
function installDrawAFlower(blockly, generator, gensym) { // Create a fake "draw a square" function so it can be made available to users // without being shown in the workspace. blockly.Blocks.draw_a_flower = { // Draw a square. init: function init() { this.setHSV(94, 0.84, 0.60); this.appendD...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "drawFish(){\n \tstroke(245, 114, 0);\n strokeWeight(1);\n \tfill(245, 114, 0);\n\t\t ellipse(this.x,this.y,30,30);\n triangle(this.x+5, this.y, this.x+30, this.y+15, this.x+30, this.y-15);\n // triangle(30, 75, 58, 20, 86, 75);\n\t}", "draw() {}", "draw() {}", "draw() {}", "draw() {}"...
[ "0.6582849", "0.64756125", "0.64756125", "0.64756125", "0.64756125", "0.6418141", "0.6418141", "0.63492554", "0.6329095", "0.63058513", "0.63058513", "0.63058513", "0.6274638", "0.6270623", "0.6266451", "0.62493664", "0.62385845", "0.6180461", "0.61741406", "0.61654335", "0.6...
0.6501403
1
Draw upper wave function call block
function installDrawUpperWave(blockly, generator, gensym) { // Create a fake "draw a square" function so it can be made available to users // without being shown in the workspace. blockly.Blocks.draw_upper_wave = { // Draw a square. init: function init() { this.setHSV(94, 0.84, 0.60); this.app...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function inB(s) { s.draw(80 - 60, 320 + 60, 0.1, {callback: function(){ inB2(s) }}); }", "render() {\n this.context.clearRect(0, 0, this.canvasWidth, this.canvasHeight);\n this.drawWave(this.sinGetX.bind(this), \"#ff0000\");\n this.drawWave(this.sinGetX.bind(this), \"#440000\", -0.3);\n this.drawWave...
[ "0.67273414", "0.6582459", "0.6524932", "0.6374201", "0.625987", "0.6217534", "0.6143864", "0.6143864", "0.6143864", "0.6143864", "0.6132459", "0.60696536", "0.60696536", "0.605563", "0.605563", "0.605563", "0.6030279", "0.60234475", "0.6017049", "0.59997773", "0.59802264", ...
0.6798571
0
Draw lower wave function call block
function installDrawLowerWave(blockly, generator, gensym) { // Create a fake "draw a square" function so it can be made available to users // without being shown in the workspace. blockly.Blocks.draw_lower_wave = { // Draw a square. init: function init() { this.setHSV(94, 0.84, 0.60); this.app...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "render() {\n this.context.clearRect(0, 0, this.canvasWidth, this.canvasHeight);\n this.drawWave(this.sinGetX.bind(this), \"#ff0000\");\n this.drawWave(this.sinGetX.bind(this), \"#440000\", -0.3);\n this.drawWave(this.sinGetX.bind(this), \"green\", 10);\n this.drawWave(this.sinGetX.bind(this), \"#004...
[ "0.6618812", "0.6598934", "0.62959903", "0.6198571", "0.61929923", "0.6111532", "0.6108221", "0.6097362", "0.60814875", "0.60583854", "0.60508406", "0.6043661", "0.5980721", "0.5940479", "0.59307986", "0.59207267", "0.5891665", "0.5856113", "0.58493423", "0.58493423", "0.5849...
0.6671095
0
Checks whether a function is wrapped by a `forwardRef`.
function isForwardRef(fn) { return typeof fn === 'function' && fn.hasOwnProperty(__forward_ref__) && fn.__forward_ref__ === forwardRef; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isForwardRef(fn) {\n return typeof fn === 'function' && fn.hasOwnProperty(__forward_ref__) && fn.__forward_ref__ === forwardRef;\n}", "function isForwardRef(fn) {\n return typeof fn === 'function' && fn.hasOwnProperty(__forward_ref__) && fn.__forward_ref__ === forwardRef;\n }", "isFunctio...
[ "0.7158187", "0.70808333", "0.63431895", "0.62139684", "0.6144644", "0.60674787", "0.60666907", "0.605559", "0.60170406", "0.5979841", "0.5971457", "0.59705514", "0.5934367", "0.5934367", "0.5904318", "0.58803433", "0.5810156", "0.5796692", "0.5770168", "0.57154965", "0.57090...
0.71995187
1
Assert that `_injectImplementation` is not `fn`. This is useful, to prevent infinite recursion.
function assertInjectImplementationNotEqual(fn) { ngDevMode && assertNotEqual(_injectImplementation, fn, 'Calling ɵɵinject would cause infinite recursion'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function assertInjectImplementationNotEqual(fn) {\n ngDevMode && assertNotEqual(_injectImplementation, fn, 'Calling ɵɵinject would cause infinite recursion');\n }", "function assertInjectImplementationNotEqual(fn) {\n ngDevMode && assertNotEqual(_injectImplementation, fn, 'Calling ɵɵinject would cau...
[ "0.78611577", "0.7806556", "0.60406524", "0.5599231", "0.5595236", "0.54572475", "0.53817517", "0.5374155", "0.5309031", "0.5260847", "0.5124173", "0.49535757", "0.49159217", "0.48927712", "0.48927712", "0.48927712", "0.48894885", "0.48853523", "0.48791724", "0.4871311", "0.4...
0.782491
1
Returns whether the `renderer` is a `ProceduralRenderer3`
function isProceduralRenderer(renderer) { return !!(renderer.listen); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isProceduralRenderer(renderer) {\n return !!renderer.listen;\n}", "function isProceduralRenderer(renderer) {\n return !!renderer.listen;\n }", "function isProceduralRenderer(renderer){return!!renderer.listen;}", "function ProceduralRenderer3() {}", "function ProceduralRenderer3() {}",...
[ "0.7018298", "0.70136756", "0.6941848", "0.5795599", "0.5795599", "0.5795599", "0.5746116", "0.5746116", "0.5724883", "0.57151616", "0.5683907", "0.5445263", "0.5400034", "0.52765495", "0.5207623", "0.5169285", "0.5161734", "0.51451945", "0.5056662", "0.50436395", "0.5008731"...
0.7052509
1
Returns a boolean for whether the view is attached to the change detection tree. Note: This determines whether a view should be checked, not whether it's inserted into a container. For that, you'll want `viewAttachedToContainer` below.
function viewAttachedToChangeDetector(view) { return (view[FLAGS] & 128 /* Attached */) === 128 /* Attached */; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function viewAttachedToChangeDetector(view) {\n return (view[FLAGS] & 128\n /* Attached */\n ) === 128\n /* Attached */\n ;\n }", "function viewAttachedToChangeDetector(view) {\n return (view[FLAGS] & 128\n /* Attached */\n ) === 128\n /* Attached */\n ;\n}", "funct...
[ "0.757685", "0.75659734", "0.73520553", "0.7259761", "0.7259761", "0.72091126", "0.7121184", "0.707049", "0.707049", "0.707049", "0.707049", "0.707049", "0.707049", "0.707049", "0.6999034", "0.6980464", "0.658844", "0.6507464", "0.6507464", "0.6507464", "0.64266855", "0.640...
0.7804441
0
When host binding is executing this points to the directive index. `TView.data[getCurrentDirectiveIndex()]` is `DirectiveDef` `LView[getCurrentDirectiveIndex()]` is directive instance.
function getCurrentDirectiveIndex() { return instructionState.lFrame.currentDirectiveIndex; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getCurrentDirectiveIndex() {\n return instructionState.lFrame.currentDirectiveIndex;\n }", "function getCurrentDirectiveIndex() {\n return instructionState.lFrame.currentDirectiveIndex;\n}", "function getCurrentDirectiveDef(tData) {\n var currentDirectiveIndex = instructionState.lF...
[ "0.69033015", "0.6698648", "0.6168035", "0.5965782", "0.5925842", "0.5925842", "0.5925842", "0.5925842", "0.5925842", "0.5925842", "0.5839707", "0.58258843", "0.57961434", "0.57284063", "0.57284063", "0.5714591", "0.5650111", "0.56283295", "0.5602839", "0.5602839", "0.5602839...
0.6713261
1
Returns a `TNode` of the location where the current `LView` is declared at.
function getDeclarationTNode(lView) { const tView = lView[TVIEW]; // Return the declaration parent for embedded views if (tView.type === 2 /* Embedded */) { ngDevMode && assertDefined(tView.declTNode, 'Embedded TNodes should have declaration parents.'); return tView.declTNode; } // C...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getDeclarationTNode(lView) {\n var tView = lView[TVIEW]; // Return the declaration parent for embedded views\n\n if (tView.type === 2\n /* Embedded */\n ) {\n ngDevMode && assertDefined(tView.declTNode, 'Embedded TNodes should have declaration parents.');\n ...
[ "0.683489", "0.6774007", "0.6497072", "0.63826394", "0.63826394", "0.6337814", "0.6298934", "0.626372", "0.62557495", "0.62557495", "0.62557495", "0.62557495", "0.62557495", "0.62557495", "0.6214911", "0.62025774", "0.62025774", "0.62025774", "0.62025774", "0.62025774", "0.62...
0.6894143
0
Allocates next free LFrame. This function tries to reuse the `LFrame`s to lower memory pressure.
function allocLFrame() { const currentLFrame = instructionState.lFrame; const childLFrame = currentLFrame === null ? null : currentLFrame.child; const newLFrame = childLFrame === null ? createLFrame(currentLFrame) : childLFrame; return newLFrame; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function allocLFrame() {\n var currentLFrame = instructionState.lFrame;\n var childLFrame = currentLFrame === null ? null : currentLFrame.child;\n var newLFrame = childLFrame === null ? createLFrame(currentLFrame) : childLFrame;\n return newLFrame;\n }", "function allocLFrame() {...
[ "0.7744828", "0.76901436", "0.55391836", "0.55391836", "0.55391836", "0.55391836", "0.55391836", "0.55391836", "0.5528147", "0.5491212", "0.507974", "0.48614985", "0.47582194", "0.475089", "0.47101545", "0.469263", "0.46828693", "0.4646949", "0.46381626", "0.46040773", "0.460...
0.77458256
0
A lightweight version of leave which is used with DI. This function only resets `currentTNode` and `LView` as those are the only properties used with DI (`enterDI()`). NOTE: This function is reexported as `leaveDI`. However `leaveDI` has return type of `void` where as `leaveViewLight` has `LFrame`. This is so that `lea...
function leaveViewLight() { const oldLFrame = instructionState.lFrame; instructionState.lFrame = oldLFrame.parent; oldLFrame.currentTNode = null; oldLFrame.lView = null; return oldLFrame; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function leaveViewLight() {\n var oldLFrame = instructionState.lFrame;\n instructionState.lFrame = oldLFrame.parent;\n oldLFrame.currentTNode = null;\n oldLFrame.lView = null;\n return oldLFrame;\n }", "function leaveViewLight() {\n var oldLFrame = instructionState.lFrame...
[ "0.7632408", "0.7608863", "0.72009933", "0.7172402", "0.7168459", "0.7168459", "0.7168459", "0.7168459", "0.7168459", "0.7168459", "0.6328795", "0.6002946", "0.6002946", "0.57612634", "0.5411978", "0.5317222", "0.5271711", "0.5271711", "0.5271711", "0.5271711", "0.5271711", ...
0.7647155
0
Sets the namespace used to create elements to `null`, which forces element creation to use `createElement` rather than `createElementNS`.
function namespaceHTMLInternal() { instructionState.lFrame.currentNamespace = null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function createElementNsOptional(namespace, tagName) {\n if (namespace === \"\") {\n return document.createElement(tagName);\n } else {\n return document.createElementNS(namespace, tagName);\n }\n }", "function namespaceHTMLInternal() {\n instructionState.lFrame.currentNamespace = null;\n}",...
[ "0.6689017", "0.5964431", "0.5883693", "0.5813893", "0.57095146", "0.5566552", "0.55450296", "0.5516616", "0.5516616", "0.5490972", "0.5459593", "0.54065686", "0.54065686", "0.539859", "0.53241223", "0.52163255", "0.5149875", "0.5141672", "0.5141672", "0.5141672", "0.5133184"...
0.59856766
1
Test whether the given value is a marker that indicates that the following attribute values in a `TAttributes` array are only the names of attributes, and not namevalue pairs.
function isNameOnlyAttributeMarker(marker) { return marker === 3 /* Bindings */ || marker === 4 /* Template */ || marker === 6 /* I18n */; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isNameOnlyAttributeMarker(marker) {\n return marker === 3\n /* Bindings */\n || marker === 4\n /* Template */\n || marker === 6\n /* I18n */\n ;\n}", "function isNameOnlyAttributeMarker(marker) {\n return marker === 3\n /* Bindings */\n || marker === 4\n /* Template */...
[ "0.6884195", "0.6693419", "0.607586", "0.58694017", "0.57315975", "0.562673", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "0.5607278", "...
0.67645484
1
Makes a type or an injection token public to the DI system by adding it to an injector's bloom filter.
function diPublicInInjector(injectorIndex, tView, token) { bloomAdd(injectorIndex, tView, token); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function diPublicInInjector(injectorIndex, tView, token) {\n bloomAdd(injectorIndex, tView, token);\n}", "function diPublicInInjector(injectorIndex, tView, token) {\n bloomAdd(injectorIndex, tView, token);\n }", "function bloomAdd(injectorIndex, tView, type) {\n ngDevMode && assertEqual(tVi...
[ "0.70339906", "0.70083565", "0.68793", "0.68430114", "0.68430114", "0.68430114", "0.68430114", "0.68430114", "0.67789793", "0.6754487", "0.6726331", "0.66453177", "0.65670353", "0.6518109", "0.6518109", "0.6518109", "0.6452603", "0.6452603", "0.6452603", "0.60802674", "0.5712...
0.70815396
0
Get an index of an `value` in a sorted `array`. NOTE: This uses binary search algorithm for fast removals.
function arrayIndexOfSorted(array, value) { return _arrayIndexOfSorted(array, value, 0); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function arrayIndexOfSorted(array, value) {\n return _arrayIndexOfSorted(array, value, 0);\n }", "function arrayIndexOfSorted(array, value) {\n return _arrayIndexOfSorted(array, value, 0);\n }", "function arrayIndexOfSorted(array, value) {\n return _arrayIndexOfSorted(array, value, 0);\n}", ...
[ "0.83458877", "0.83458877", "0.8310085", "0.8304184", "0.78028536", "0.76365936", "0.76103", "0.7592347", "0.7592347", "0.7592347", "0.7592347", "0.7592347", "0.7592347", "0.7592347", "0.75579965", "0.75451636", "0.750858", "0.7502304", "0.7502304", "0.7492434", "0.7489351", ...
0.8382016
1
INTERNAL: Get an index of an `value` in a sorted `array` by grouping search by `shift`. NOTE: This uses binary search algorithm for fast removals.
function _arrayIndexOfSorted(array, value, shift) { ngDevMode && assertEqual(Array.isArray(array), true, 'Expecting an array'); let start = 0; let end = array.length >> shift; while (end !== start) { const middle = start + ((end - start) >> 1); // find the middle. const current = array[m...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function _arrayIndexOfSorted(array, value, shift) {\n ngDevMode && assertEqual(Array.isArray(array), true, 'Expecting an array');\n var start = 0;\n var end = array.length >> shift;\n\n while (end !== start) {\n var middle = start + (end - start >> 1); // find the middle.\n\n ...
[ "0.82239175", "0.8206025", "0.8205723", "0.8205723", "0.6728696", "0.6563067", "0.64553", "0.6449891", "0.6449891", "0.6434205", "0.64059687", "0.64059687", "0.64059687", "0.64059687", "0.64059687", "0.64059687", "0.64059687", "0.6329604", "0.6328672", "0.6227031", "0.6138029...
0.82596636
1
Attaches a given InjectFlag to a given decorator using monkeypatching. Since DI decorators can be used in providers `deps` array (when provider is configured using `useFactory`) without initialization (e.g. `Host`) and as an instance (e.g. `new Host()`), we attach the flag to make it available both as a static property...
function attachInjectFlag(decorator, flag) { decorator[DI_DECORATOR_FLAG] = flag; decorator.prototype[DI_DECORATOR_FLAG] = flag; return decorator; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function attachInjectFlag(decorator, flag) {\n decorator[DI_DECORATOR_FLAG] = flag;\n decorator.prototype[DI_DECORATOR_FLAG] = flag;\n return decorator;\n }", "add(cb, flag = 'injection') {\n let cachingArr = this.injection;\n if (flag === 'before') cachingArr = this.before;\n ...
[ "0.82113075", "0.5450354", "0.51877636", "0.50632244", "0.50632244", "0.50632244", "0.50632244", "0.50632244", "0.50612754", "0.5037068", "0.4988903", "0.49739867", "0.49739867", "0.49739867", "0.49739867", "0.48381472", "0.48381472", "0.48381472", "0.48381472", "0.48381472", ...
0.82635015
1
Reads monkeypatched property that contains InjectFlag attached to a decorator.
function getInjectFlag(token) { return token[DI_DECORATOR_FLAG]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getPropertyInject(target, useCache) {\n return getClassExtendedMetadata(constant_1.INJECT_TAG, target, undefined, useCache);\n}", "function getInjectFlag(token) {\n return token[DI_DECORATOR_FLAG];\n }", "function attachInjectFlag(decorator, flag) {\n decorator[DI_DECORATOR_FLAG]...
[ "0.610865", "0.6055051", "0.5962504", "0.585285", "0.585285", "0.585285", "0.585285", "0.585285", "0.560531", "0.5529511", "0.5529511", "0.5529511", "0.5399087", "0.5388869", "0.5360751", "0.5360751", "0.5360751", "0.5360751", "0.5360751", "0.5360751", "0.534668", "0.523964...
0.6123218
1
Unsafely promote a string to a TrustedHTML, falling back to strings when Trusted Types are not available.
function trustedHTMLFromString(html) { var _a; return ((_a = getPolicy()) === null || _a === void 0 ? void 0 : _a.createHTML(html)) || html; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function trustedHTMLFromString(html) {\n var _a;\n\n return ((_a = getPolicy()) === null || _a === void 0 ? void 0 : _a.createHTML(html)) || html;\n}", "function trustedHTMLFromString(html) {\n var _a;\n\n return ((_a = getPolicy()) === null || _a === void 0 ? void 0 : _a.createHTML(html)) || htm...
[ "0.7299434", "0.7278371", "0.72463274", "0.70482033", "0.69763166", "0.69763166", "0.69763166", "0.69763166", "0.6939334", "0.64875185", "0.610737", "0.6096749", "0.59044033", "0.5831479", "0.5820501", "0.58169013", "0.578541", "0.57773834", "0.57293534", "0.5720159", "0.5698...
0.7301081
1
When IE11 comes across an unknown namespaced attribute e.g. 'xlink:foo' it adds 'xmlns:ns1' attribute to declare ns1 namespace and prefixes the attribute with 'ns1' (e.g. 'ns1:xlink:foo'). This is undesirable since we don't want to allow any of these custom attributes. This method strips them all.
stripCustomNsAttrs(el) { const elAttrs = el.attributes; // loop backwards so that we can support removals. for (let i = elAttrs.length - 1; 0 < i; i--) { const attrib = elAttrs.item(i); const attrName = attrib.name; if (attrName === 'xmlns:ns1' || attrName.ind...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function stripCustomNsAttrs(node) {\n\t\t if (node.nodeType === window.Node.ELEMENT_NODE) {\n\t\t var attrs = node.attributes;\n\t\t for (var i = 0, l = attrs.length; i < l; i++) {\n\t\t var attrNode = attrs[i];\n\t\t var attrName = attrNode.name.toLowerCase();\n\t\t if (attrName ...
[ "0.7434523", "0.7374574", "0.73635036", "0.7358818", "0.73063606", "0.72705984", "0.7222453", "0.7222453", "0.7222453", "0.7222453", "0.7222453", "0.7222453", "0.61473", "0.5896878", "0.58909833", "0.5869326", "0.5864358", "0.57829523", "0.56533456", "0.55719334", "0.5560039"...
0.7720532
1
Sanitizes an opening element tag (if valid) and returns whether the element's contents should be traversed. Element content must always be traversed (even if the element itself is not valid/safe), unless the element is one of `SKIP_TRAVERSING_CONTENT_IF_INVALID_ELEMENTS`.
startElement(element) { const tagName = element.nodeName.toLowerCase(); if (!VALID_ELEMENTS.hasOwnProperty(tagName)) { this.sanitizedSomething = true; return !SKIP_TRAVERSING_CONTENT_IF_INVALID_ELEMENTS.hasOwnProperty(tagName); } this.buf.push('<'); this.b...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isTag(input){\n\treturn input.startsWith(\"<\");\n}", "function valid(data, options) {\n if (options === void 0) { options = { lowerCaseTagName: false, comment: false }; }\n var stack = html_1.base_parse(data, options);\n return Boolean(stack.length === 1);\n}", "function isSimpleTag(content,...
[ "0.5540781", "0.5399245", "0.5388054", "0.536116", "0.5322363", "0.52132386", "0.51884985", "0.5141216", "0.51172006", "0.5115566", "0.5115299", "0.51069397", "0.51069397", "0.51069397", "0.51069397", "0.51069397", "0.51069397", "0.51069397", "0.50968087", "0.5078102", "0.503...
0.64041466
1
Locates the component within the given LView and returns the matching index
function findViaComponent(lView, componentInstance) { const componentIndices = lView[TVIEW].components; if (componentIndices) { for (let i = 0; i < componentIndices.length; i++) { const elementComponentIndex = componentIndices[i]; const componentView = getComponentLViewByIndex(el...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function findViaComponent(lView, componentInstance) {\n var componentIndices = lView[TVIEW].components;\n\n if (componentIndices) {\n for (var i = 0; i < componentIndices.length; i++) {\n var elementComponentIndex = componentIndices[i];\n var componentView = getComponentLViewByIndex(elementComponent...
[ "0.7569643", "0.7565394", "0.7565394", "0.7565394", "0.75606656", "0.7315872", "0.7214066", "0.694944", "0.6930487", "0.6930487", "0.6930487", "0.6927687", "0.69184965", "0.69184965", "0.69184965", "0.69184965", "0.69184965", "0.69184965", "0.6909739", "0.6645245", "0.6200203...
0.7603493
1
Locates the directive within the given LView and returns the matching index
function findViaDirective(lView, directiveInstance) { // if a directive is monkey patched then it will (by default) // have a reference to the LView of the current view. The // element bound to the directive being search lives somewhere // in the view data. We loop through the nodes and check their ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function findViaDirective(lView, directiveInstance) {\n // if a directive is monkey patched then it will (by default)\n // have a reference to the LView of the current view. The\n // element bound to the directive being search lives somewhere\n // in the view data. We loop through the nodes and check their\n ...
[ "0.73428875", "0.7335774", "0.7335774", "0.7335774", "0.72102416", "0.7176323", "0.6850216", "0.6845069", "0.68075866", "0.6804077", "0.6758733", "0.6758733", "0.6758733", "0.6758733", "0.6758733", "0.6758733", "0.66727287", "0.66284215", "0.66284215", "0.66284215", "0.647322...
0.7373879
1
Gets the next `LContainer` that is a sibling of the given container.
function getNextLContainer(container) { return getNearestLContainer(container[NEXT]); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getNextLContainer(container) {\n return getNearestLContainer(container[NEXT]);\n}", "function getNextLContainer(container) {\n return getNearestLContainer(container[NEXT]);\n }", "nextSibling() {\n var siblings = this._containers.top(); // If we're at the root of the tree or if the par...
[ "0.7531254", "0.7473794", "0.72235066", "0.6658874", "0.64616394", "0.6253783", "0.6194534", "0.61834097", "0.61792463", "0.61792463", "0.6179226", "0.61618054", "0.6072083", "0.5984619", "0.5976637", "0.5976637", "0.59486693", "0.593231", "0.592508", "0.5892575", "0.58718747...
0.75324917
1
Returns the first native node for a given LView, starting from the provided TNode. Native nodes are returned in the order in which those appear in the native tree (DOM).
function getFirstNativeNode(lView, tNode) { if (tNode !== null) { ngDevMode && assertTNodeType(tNode, 3 /* AnyRNode */ | 12 /* AnyContainer */ | 32 /* Icu */ | 16 /* Projection */); const tNodeType = tNode.type; if (tNodeType & 3 /* AnyRNode */) { return getNativeByTN...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getFirstNativeNode(lView, tNode) {\n if (tNode !== null) {\n ngDevMode &&\n assertTNodeType(tNode, 3 /* AnyRNode */ | 12 /* AnyContainer */ | 32 /* Icu */ | 16 /* Projection */);\n const tNodeType = tNode.type;\n if (tNodeType & 3 /* AnyRNode */) {\n return ge...
[ "0.82368565", "0.8135038", "0.81205785", "0.7607017", "0.7583196", "0.7531638", "0.7527807", "0.7527807", "0.7527807", "0.7527807", "0.7527807", "0.7527807", "0.7497019", "0.7497019", "0.7497019", "0.7497019", "0.7497019", "0.7497019", "0.7476882", "0.70215625", "0.7020267", ...
0.8206646
1
Search the `TAttributes` to see if it contains `cssClassToMatch` (case insensitive)
function isCssClassMatching(attrs, cssClassToMatch, isProjectionMode) { // TODO(misko): The fact that this function needs to know about `isProjectionMode` seems suspect. // It is strange to me that sometimes the class information comes in form of `class` attribute // and sometimes in form of `AttributeMarke...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isCssClassMatching(attrs, cssClassToMatch, isProjectionMode) {\n // TODO(misko): The fact that this function needs to know about `isProjectionMode` seems suspect.\n // It is strange to me that sometimes the class information comes in form of `class` attribute\n // and sometimes in for...
[ "0.6924405", "0.69238263", "0.5736434", "0.56782126", "0.5629138", "0.56103325", "0.55534613", "0.555137", "0.5521425", "0.54853255", "0.54842377", "0.5468482", "0.5401467", "0.5368473", "0.53226054", "0.5293785", "0.52707076", "0.52700853", "0.52663815", "0.52586013", "0.525...
0.69711804
0
Checks whether the `tNode` represents an inline template (e.g. `ngFor`).
function isInlineTemplate(tNode) { return tNode.type === 4 /* Container */ && tNode.value !== NG_TEMPLATE_SELECTOR; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isInlineTemplate(tNode) {\n return tNode.type === 4\n /* Container */\n && tNode.value !== NG_TEMPLATE_SELECTOR;\n}", "function isInlineTemplate(tNode) {\n return tNode.type === 4\n /* Container */\n && tNode.value !== NG_TEMPLATE_SELECTOR;\n }", "function isInline(node) {...
[ "0.8707874", "0.8588419", "0.69565886", "0.66424865", "0.66129535", "0.63772595", "0.6287281", "0.6174462", "0.6114026", "0.6048735", "0.59950554", "0.59368587", "0.5887312", "0.5878282", "0.5878282", "0.5768593", "0.5670774", "0.56597257", "0.56597257", "0.56597257", "0.5659...
0.8700027
1
Function that checks whether a given tNode matches tagbased selector and has a valid type. Matching can be performed in 2 modes: projection mode (when we project nodes) and regular directive matching mode: in the "directive matching" mode we do _not_ take TContainer's tagName into account if it is different from NG_TEM...
function hasTagAndTypeMatch(tNode, currentSelector, isProjectionMode) { const tagNameToCompare = tNode.type === 4 /* Container */ && !isProjectionMode ? NG_TEMPLATE_SELECTOR : tNode.value; return currentSelector === tagNameToCompare; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function hasTagAndTypeMatch(tNode, currentSelector, isProjectionMode) {\n var tagNameToCompare = tNode.type === 4\n /* Container */\n && !isProjectionMode ? NG_TEMPLATE_SELECTOR : tNode.value;\n return currentSelector === tagNameToCompare;\n}", "function hasTagAndTypeMatch(tNode, currentSelector, isProjectio...
[ "0.7632177", "0.75492305", "0.7531701", "0.74750555", "0.74750555", "0.7390657", "0.6920528", "0.66981006", "0.66981006", "0.66981006", "0.66981006", "0.66981006", "0.66981006", "0.6635837", "0.6548035", "0.65277565", "0.65122795", "0.649565", "0.649565", "0.5845688", "0.5725...
0.7612005
1
Examines the attribute's definition array for a node to find the index of the attribute that matches the given `name`. NOTE: This will not match namespaced attributes. Attribute matching depends upon `isInlineTemplate` and `isProjectionMode`. The following table summarizes which types of attributes we attempt to match:...
function findAttrIndexInNode(name, attrs, isInlineTemplate, isProjectionMode) { if (attrs === null) return -1; let i = 0; if (isProjectionMode || !isInlineTemplate) { let bindingsMode = false; while (i < attrs.length) { const maybeAttrName = attrs[i]; if (mayb...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function findAttrIndexInNode(name, attrs, isInlineTemplate, isProjectionMode) {\n if (attrs === null) return -1;\n var i = 0;\n\n if (isProjectionMode || !isInlineTemplate) {\n var bindingsMode = false;\n\n while (i < attrs.length) {\n var maybeAttrName = attrs[i];...
[ "0.7563244", "0.7512398", "0.75044227", "0.67099", "0.67099", "0.6705701", "0.67051387", "0.6014463", "0.5898705", "0.5857334", "0.5784562", "0.5760583", "0.5705454", "0.5614995", "0.5429376", "0.5311061", "0.523333", "0.51067793", "0.5098847", "0.5098847", "0.5098847", "0....
0.7538815
1
Patch a `debug` property getter on top of the existing object. NOTE: always call this method with `ngDevMode && attachDebugObject(...)`
function attachDebugGetter(obj, debugGetter) { if (ngDevMode) { Object.defineProperty(obj, 'debug', { get: debugGetter, enumerable: false }); } else { throw new Error('This method should be guarded with `ngDevMode` so that it can be tree shaken in production!'); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function attachDebugGetter(obj, debugGetter) {\n if (ngDevMode) {\n Object.defineProperty(obj, 'debug', {\n get: debugGetter,\n enumerable: false\n });\n } else {\n throw new Error('This method should be guarded with `ngDevMode` so that it can be tree shaken in production!');\n }\n}", "func...
[ "0.81470597", "0.81369", "0.656858", "0.6497863", "0.60919875", "0.59488237", "0.59287566", "0.591673", "0.57891804", "0.56648034", "0.56344205", "0.56344205", "0.5626319", "0.5626319", "0.5626319", "0.5626319", "0.5626319", "0.5626319", "0.5626319", "0.5626319", "0.5626319",...
0.81439257
1
Return a human debug version of the set of `NodeInjector`s which will be consulted when resolving tokens from this `TNode`. When debugging applications, it is often difficult to determine which `NodeInjector`s will be consulted. This method shows a list of `DebugNode`s representing the `TNode`s which will be consulted ...
debugNodeInjectorPath(lView) { const path = []; let injectorIndex = getInjectorIndex(this, lView); if (injectorIndex === -1) { // Looks like the current `TNode` does not have `NodeInjector` associated with it => look for // parent NodeInjector. const parentLoc...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "debugNodeInjectorPath(lView) {\n const path = [];\n let injectorIndex = getInjectorIndex(this, lView);\n ngDevMode && assertNodeInjector(lView, injectorIndex);\n while (injectorIndex !== -1) {\n const tNode = lView[TVIEW].data[injectorIndex + 8 /* TNODE */];\n path...
[ "0.7396323", "0.6490038", "0.6465843", "0.646554", "0.646554", "0.646554", "0.646554", "0.646554", "0.646554", "0.6434089", "0.6434089", "0.6434089", "0.6434089", "0.6434089", "0.6434089", "0.62599003", "0.55745274", "0.5172946", "0.510511", "0.50638795", "0.50357485", "0.5...
0.76372296
0
Flags associated with the `LView` unpacked into a more readable state.
get flags() { const flags = this._raw_lView[FLAGS]; return { __raw__flags__: flags, initPhaseState: flags & 3 /* InitPhaseStateMask */, creationMode: !!(flags & 4 /* CreationMode */), firstViewPass: !!(flags & 8 /* FirstLViewPass */), checkAlwa...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getRenderFlags(view) {\n return view[FLAGS] & 1 /* CreationMode */ ? 1 /* Create */ | 2 /* Update */ :\n 2 /* Update */;\n}", "function getRenderFlags(view) {\n return isCreationMode(view) ? 1 /* Create */ : 2 /* Update */;\n}", "function getRenderFlags(view) {\n return isCreationMode(...
[ "0.6011887", "0.5541419", "0.5541419", "0.5541419", "0.5524304", "0.5524304", "0.5524304", "0.5524304", "0.5524304", "0.5524304", "0.5502157", "0.55007285", "0.5362738", "0.53588164", "0.52889466", "0.52889466", "0.52889466", "0.52889466", "0.52889466", "0.52889466", "0.52795...
0.6836515
0
The tree of nodes associated with the current `LView`. The nodes have been normalized into a tree structure with relevant details pulled out for readability.
get nodes() { const lView = this._raw_lView; const tNode = lView[TVIEW].firstChild; return toDebugNodes(tNode, lView); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "renderTree() {\n\t\tlet svg = d3.select(\"body\")\n\t\t\t.append(\"svg\")\n\t\t\t.attr(\"width\", 1200)\n\t\t\t.attr(\"height\", 1200);\n\n\t\tsvg.selectAll(\"line\")\n\t\t\t.data(this.nodesList.slice(1, this.nodesList.length))\n\t\t\t.enter()\n\t\t\t.append(\"line\")\n\t\t\t.attr(\"x1\", d => d.parentNode.level*2...
[ "0.6602369", "0.65062165", "0.63839954", "0.6263388", "0.6255479", "0.62250626", "0.6209725", "0.6180887", "0.6052877", "0.6051165", "0.6024942", "0.6016691", "0.6016691", "0.5991836", "0.59878606", "0.5967099", "0.593366", "0.59263456", "0.5919528", "0.59193546", "0.59099454...
0.737049
0
Normalized view of child views (and containers) attached at this location.
get childViews() { const childViews = []; let child = this.childHead; while (child) { childViews.push(child); child = child.next; } return childViews; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "parentSize() {\n if (!this.parent) {\n console.warn('HView#parentSize; no parent!');\n return [0, 0];\n }\n if (this.parent.elemId === 0) {\n return ELEM.windowSize();\n }\n else {\n return ELEM.getSize(this.parent.elemId);\n }\n }", "[positionViews]() {\n\t\tconst self = t...
[ "0.59711164", "0.586081", "0.58470887", "0.56396973", "0.56026703", "0.5542596", "0.5531044", "0.5517751", "0.55013597", "0.5487979", "0.54772353", "0.54772353", "0.54772353", "0.5464571", "0.5462021", "0.5444406", "0.5444406", "0.54271454", "0.5423531", "0.54184604", "0.5404...
0.674455
0
Convert a number at `idx` location in `array` into binary representation.
function binary(array, idx) { const value = array[idx]; // If not a number we print 8 `?` to retain alignment but let user know that it was called on // wrong type. if (typeof value !== 'number') return '????????'; // We prefix 0s so that we have constant length number const text = '0000...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function binary(array, idx) {\n var value = array[idx]; // If not a number we print 8 `?` to retain alignment but let user know that it was called on\n // wrong type.\n\n if (typeof value !== 'number') return '????????'; // We prefix 0s so that we have constant length number\n\n var text = '00000000' + value.t...
[ "0.7402888", "0.73338723", "0.67516756", "0.6711929", "0.65928787", "0.655195", "0.655195", "0.655195", "0.655195", "0.655195", "0.6250875", "0.5709631", "0.55961794", "0.54054457", "0.53187406", "0.5312778", "0.5312778", "0.5221945", "0.5188778", "0.51226807", "0.5119927", ...
0.74821174
0
Invoke `HostBindingsFunction`s for view. This methods executes `TView.hostBindingOpCodes`. It is used to execute the `HostBindingsFunction`s associated with the current `LView`.
function processHostBindingOpCodes(tView, lView) { const hostBindingOpCodes = tView.hostBindingOpCodes; if (hostBindingOpCodes === null) return; try { for (let i = 0; i < hostBindingOpCodes.length; i++) { const opCode = hostBindingOpCodes[i]; if (opCode < 0) { ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function processHostBindingOpCodes(tView, lView) {\n var hostBindingOpCodes = tView.hostBindingOpCodes;\n if (hostBindingOpCodes === null) return;\n\n try {\n for (var i = 0; i < hostBindingOpCodes.length; i++) {\n var opCode = hostBindingOpCodes[i];\n\n if (opCode < 0) {\n // Negative numbe...
[ "0.69916046", "0.6928523", "0.661413", "0.6254976", "0.62092805", "0.62092805", "0.6039183", "0.60041165", "0.5990189", "0.5968269", "0.5968269", "0.5968269", "0.5968269", "0.5968269", "0.5968269", "0.5536473", "0.5413769", "0.5413769", "0.5306777", "0.52594763", "0.52594763"...
0.7014512
0
Syncs an LView instance with its blueprint if they have gotten out of sync. Typically, blueprints and their view instances should always be in sync, so the loop here will be skipped. However, consider this case of two components sidebyside: App template: ``` ``` The following will happen: 1. App template begins process...
function syncViewWithBlueprint(tView, lView) { for (let i = lView.length; i < tView.blueprint.length; i++) { lView.push(tView.blueprint[i]); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function syncViewWithBlueprint(tView, lView) {\n for (var i = lView.length; i < tView.blueprint.length; i++) {\n lView.push(tView.blueprint[i]);\n }\n }", "function syncViewWithBlueprint(tView, lView) {\n for (var i = lView.length; i < tView.blueprint.length; i++) {\n lView.push(t...
[ "0.69647586", "0.6931713", "0.6928827", "0.6643549", "0.6643549", "0.6643549", "0.6643549", "0.64778876", "0.64778876", "0.64778876", "0.64778876", "0.64778876", "0.64778876", "0.64333624", "0.6391827", "0.6318664", "0.6318664", "0.6318664", "0.6318664", "0.6318664", "0.63186...
0.6996723
1
Updates a text binding at a given index in a given LView.
function textBindingInternal(lView, index, value) { ngDevMode && assertString(value, 'Value should be a string'); ngDevMode && assertNotSame(value, NO_CHANGE, 'value should not be NO_CHANGE'); ngDevMode && assertIndexInRange(lView, index); const element = getNativeByIndex(index, lView); ngDevMode &&...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function textBindingInternal(lView, index, value) {\n ngDevMode && assertString(value, 'Value should be a string');\n ngDevMode && assertNotSame(value, NO_CHANGE, 'value should not be NO_CHANGE');\n ngDevMode && assertIndexInRange(lView, index);\n var element = getNativeByIndex(index, lView);\n ngDevMode && a...
[ "0.7498503", "0.7330799", "0.70746195", "0.68226916", "0.67641234", "0.67641234", "0.6617709", "0.6408778", "0.62630266", "0.5957896", "0.5954828", "0.59349465", "0.592804", "0.5904706", "0.5885887", "0.5885887", "0.5885887", "0.5885887", "0.5885887", "0.5885887", "0.5881842"...
0.75041366
1
Flag indicating that this injector was previously destroyed.
get destroyed() { return this._destroyed; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "ngOnDestroy() {\n this._destroyed = true;\n this._completeExit();\n }", "getIsDestroyed(){return this.__isDestroyed}", "ngOnDestroy() {\n this._destroyed = true;\n this._clearFromModals();\n this._completeExit();\n }", "destroy() {\n this.assertNotDestroyed();\...
[ "0.68289024", "0.6700079", "0.6638904", "0.65034837", "0.65034837", "0.65034837", "0.65034837", "0.65034837", "0.65034837", "0.6281281", "0.6276721", "0.62127256", "0.6135023", "0.6088599", "0.6088599", "0.60481703", "0.60015476", "0.5973711", "0.5959178", "0.5924712", "0.592...
0.7324665
1
Destroy the injector and release references to every instance or provider associated with it. Also calls the `OnDestroy` lifecycle hooks of every instance that was created for which a hook was found.
destroy() { this.assertNotDestroyed(); // Set destroyed = true first, in case lifecycle hooks re-enter destroy(). this._destroyed = true; try { // Call all the lifecycle hooks. this.onDestroy.forEach(service => service.ngOnDestroy()); } finally { ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "destroy() {\n this._pluginsManager.beforeAppDestroy(this);\n for (let module of this._modulesOrder) {\n module.destroy();\n }\n }", "destroy() {\n if (this._destroyed) {\n throw new Error('The platform has already been destroyed!');\n }\n this._m...
[ "0.67392784", "0.65807134", "0.65807134", "0.65807134", "0.65807134", "0.65807134", "0.650319", "0.650319", "0.650319", "0.650319", "0.650319", "0.650319", "0.647019", "0.643648", "0.643648", "0.6406423", "0.6223986", "0.6217932", "0.6217932", "0.6217932", "0.6217932", "0.6...
0.7658458
1
Process a `SingleProvider` and add it.
processProvider(provider, ngModuleType, providers) { // Determine the token from the provider. Either it's its own token, or has a {provide: ...} // property. provider = resolveForwardRef(provider); let token = isTypeProvider(provider) ? provider : resolveForwardRef(provider && provider....
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "async addInformationProvider(infoProvider) {\n console.log(\"Adding information provider details: \");\n console.log(infoProvider);\n return await this.connection.manager.transaction(async (transactionalEntityManager) => {\n infoProvider = await transactionalEntityManager.save(infoP...
[ "0.55863774", "0.5427248", "0.5415222", "0.5353885", "0.52301365", "0.5165896", "0.5162834", "0.51569605", "0.5134556", "0.5048545", "0.5048545", "0.5048545", "0.5042608", "0.5042608", "0.5042608", "0.5031131", "0.5005211", "0.49888036", "0.49888036", "0.49888036", "0.4988803...
0.70445627
1
Retrieves all root components associated with a DOM element, directive or component instance. Root components are those which have been bootstrapped by Angular.
function getRootComponents(elementOrDir) { return [...getRootContext(elementOrDir).components]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getRootComponents(elementOrDir) {\n return _toConsumableArray(getRootContext(elementOrDir).components);\n }", "function getRootComponents(elementOrDir) {\n return Object(C_Users_Abid_Loqmen_Desktop_NGforce_thesis_node_modules_babel_runtime_helpers_esm_toConsumableArray__WEBPACK_IMPORTED_MOD...
[ "0.6841169", "0.66332614", "0.63850415", "0.621937", "0.6148413", "0.6148413", "0.612196", "0.60411596", "0.58882415", "0.56661147", "0.56661147", "0.56661147", "0.56661147", "0.56661147", "0.56661147", "0.55847085", "0.55847085", "0.55241716", "0.5493599", "0.5445187", "0.54...
0.700902
1
Retrieves the host element of a component or directive instance. The host element is the DOM element that matched the selector of the directive.
function getHostElement(componentOrDirective) { return getLContext(componentOrDirective).native; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getHostElement(componentOrDirective) {\n return getLContext(componentOrDirective).native;\n}", "function getHostElement(componentOrDirective) {\n return getLContext(componentOrDirective)[\"native\"];\n }", "_getHostElement() {\n return this._elementRef.nativeElement;\n }", "_g...
[ "0.7666752", "0.7611567", "0.7201406", "0.7201406", "0.71414524", "0.71414524", "0.71414524", "0.7070262", "0.7070262", "0.7070262", "0.7070262", "0.7070262", "0.7070262", "0.7070262", "0.7070262", "0.6959949", "0.67329395", "0.6722263", "0.6661265", "0.6498949", "0.64714247"...
0.7678937
1
Publishes the given function to `window.ng` so that it can be used from the browser console when an application is not in production.
function publishGlobalUtil(name, fn) { if (typeof COMPILED === 'undefined' || !COMPILED) { // Note: we can't export `ng` when using closure enhanced optimization as: // - closure declares globals itself for minified names, which sometimes clobber our `ng` global // - we can't declare a closu...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function publishGlobalUtil(name, fn) {\n if (typeof COMPILED === 'undefined' || !COMPILED) {\n // Note: we can't export `ng` when using closure enhanced optimization as:\n // - closure declares globals itself for minified names, which sometimes clobber our `ng` global\n // - we can't declare a closure ex...
[ "0.69634944", "0.6931366", "0.68681425", "0.68681425", "0.68681425", "0.68194515", "0.66745055", "0.5901059", "0.5867306", "0.57491887", "0.55633086", "0.5333495", "0.5333495", "0.5330459", "0.53113157", "0.53037745", "0.5279863", "0.5274032", "0.5258852", "0.5247035", "0.523...
0.6964501
1
Creates a wrapped value.
static wrap(value) { return new WrappedValue(value); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function wrappedValue(x) {\n return {\n value: x\n };\n}", "_wrap( value, ttl, asClone = true ){\n\t\tlet oReturn;\n\t\tif (!this.options.useClones) {\n\t\t\tasClone = false;\n\t\t}\n\t\t// define the time to live\n\t\tlet now = Date.now();\n\t\tlet livetime = 0;\n\n\t\tlet ttlMultiplicator = 1000;\...
[ "0.80016375", "0.7126427", "0.63639295", "0.6170604", "0.6170604", "0.6170604", "0.6170604", "0.6170604", "0.61607623", "0.6132742", "0.6083848", "0.60825074", "0.6017059", "0.5990013", "0.59472704", "0.59396267", "0.5921593", "0.59113795", "0.5798484", "0.57747304", "0.57747...
0.8403251
1
Returns the underlying value of a wrapped value. Returns the given `value` when it is not wrapped.
static unwrap(value) { return WrappedValue.isWrapped(value) ? value.wrapped : value; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "static wrap(value) {\n return new WrappedValue(value);\n }", "static wrap(value) {\n return new WrappedValue(value);\n }", "static wrap(value) {\n return new WrappedValue(value);\n }", "static wrap(value) {\n return new WrappedValue(value);\n }", "static wrap(value) ...
[ "0.76056767", "0.76056767", "0.76056767", "0.76056767", "0.76056767", "0.70712525", "0.63831735", "0.63831735", "0.63831735", "0.63831735", "0.63831735", "0.61586326", "0.6127237", "0.6127237", "0.60948026", "0.60497427", "0.6045846", "0.5999823", "0.5937563", "0.5903777", "0...
0.8034091
1
Returns true if `value` is a wrapped value.
static isWrapped(value) { return value instanceof WrappedValue; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function is(value) {\n var candidate = value;\n return Is.objectLiteral(value) && MarkupKind.is(candidate.kind) && Is.string(candidate.value);\n }", "function is(value) {\r\n var candidate = value;\r\n return Is.objectLiteral(value) && MarkupKind.is(candidate.kind) && Is.string(can...
[ "0.68027186", "0.6769095", "0.6769095", "0.6769095", "0.6769095", "0.67429453", "0.67429453", "0.6712746", "0.6712746", "0.6712746", "0.6581207", "0.6581207", "0.6581207", "0.6581207", "0.6581207", "0.6581207", "0.6581207", "0.6581207", "0.6581207", "0.6581207", "0.6581207", ...
0.8614894
1
Updates 2 bindings if changed, then returns whether either was updated.
function bindingUpdated2(lView, bindingIndex, exp1, exp2) { const different = bindingUpdated(lView, bindingIndex, exp1); return bindingUpdated(lView, bindingIndex + 1, exp2) || different; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function bindingUpdated2(lView,bindingIndex,exp1,exp2){var different=bindingUpdated(lView,bindingIndex,exp1);return bindingUpdated(lView,bindingIndex+1,exp2)||different;}", "function bindingUpdated2(lView, bindingIndex, exp1, exp2) {\n var different = bindingUpdated(lView, bindingIndex, exp1);\n return bin...
[ "0.6516444", "0.6466891", "0.6466891", "0.6466891", "0.6449578", "0.6446333", "0.6401727", "0.63319963", "0.63156366", "0.6299303", "0.6299303", "0.6299303", "0.6299303", "0.6299303", "0.6299303", "0.6224057", "0.6158073", "0.6158073", "0.6142971", "0.60727906", "0.5907073", ...
0.6528667
1
Updates 3 bindings if changed, then returns whether any was updated.
function bindingUpdated3(lView, bindingIndex, exp1, exp2, exp3) { const different = bindingUpdated2(lView, bindingIndex, exp1, exp2); return bindingUpdated(lView, bindingIndex + 2, exp3) || different; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function bindingUpdated3(lView, bindingIndex, exp1, exp2, exp3) {\n var different = bindingUpdated2(lView, bindingIndex, exp1, exp2);\n return bindingUpdated(lView, bindingIndex + 2, exp3) || different;\n }", "function bindingUpdated3(lView, bindingIndex, exp1, exp2, exp3) {\n var different =...
[ "0.6819097", "0.6815386", "0.6800612", "0.6800612", "0.6800612", "0.6776135", "0.6641674", "0.63564914", "0.63564914", "0.63564914", "0.63564914", "0.63564914", "0.63564914", "0.6340753", "0.6339681", "0.6227575", "0.6215081", "0.61455446", "0.61455446", "0.60367066", "0.6036...
0.6869638
1
Updates 4 bindings if changed, then returns whether any was updated.
function bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4) { const different = bindingUpdated2(lView, bindingIndex, exp1, exp2); return bindingUpdated2(lView, bindingIndex + 2, exp3, exp4) || different; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4) {\n var different = bindingUpdated2(lView, bindingIndex, exp1, exp2);\n return bindingUpdated2(lView, bindingIndex + 2, exp3, exp4) || different;\n}", "function bindingUpdated4(lView, bindingIndex, exp1, exp2, exp3, exp4) {\n var differen...
[ "0.6790506", "0.6786419", "0.6786419", "0.6786419", "0.6752918", "0.67470604", "0.6621485", "0.6528608", "0.6528608", "0.6528608", "0.6528608", "0.6528608", "0.6528608", "0.6520114", "0.65179914", "0.6517863", "0.6517863", "0.6517863", "0.6517863", "0.6517863", "0.6517863", ...
0.68579584
1
Throws an error indicating that a factory function could not be generated by the compiler for a particular class. This instruction allows the actual error message to be optimized away when ngDevMode is turned off, saving bytes of generated code while still providing a good experience in dev mode. The name of the class ...
function ɵɵinvalidFactory() { const msg = ngDevMode ? `This constructor was not compatible with Dependency Injection.` : 'invalid'; throw new Error(msg); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ɵɵinvalidFactory() {\n var msg = ngDevMode ? \"This constructor was not compatible with Dependency Injection.\" : 'invalid';\n throw new Error(msg);\n }", "function ɵɵinvalidFactory() {\n var msg = ngDevMode ? \"This constructor was not compatible with Dependency Injection.\" : 'inva...
[ "0.6368929", "0.6336451", "0.5784367", "0.5728013", "0.5674312", "0.5674312", "0.5674312", "0.5674312", "0.5674312", "0.5674312", "0.56335866", "0.55882317", "0.537447", "0.53726196", "0.5341093", "0.5333285", "0.528706", "0.5281267", "0.52735513", "0.52269965", "0.521469", ...
0.6375494
0
Determine if the argument is a Subscribable
function isSubscribable(obj) { return !!obj && typeof obj.subscribe === 'function'; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isSubscribable(obj) {\n return !!obj && typeof obj.subscribe === 'function';\n }", "get canSubscribe()\n\t{\n\t\treturn true;\n\t}", "isSubscribed(event) {\n if (this.connection) {\n return this.connection.isSubscribed(event)\n }\n return Promise.reject({cod...
[ "0.77315044", "0.63681734", "0.6046731", "0.60193187", "0.5843574", "0.57874763", "0.5507095", "0.5481534", "0.5406139", "0.53221995", "0.5290935", "0.52774423", "0.5274462", "0.5269891", "0.526871", "0.526871", "0.526871", "0.526871", "0.526871", "0.526871", "0.526871", "0...
0.7735375
0
Marks `TStyleValue`s as duplicates if another style binding in the list has the same `TStyleValue`. NOTE: this function is intended to be called twice once with `isPrevDir` set to `true` and once with it set to `false` to search both the previous as well as next items in the list. No duplicate case ``` [style.color] [s...
function markDuplicates(tData, tStylingKey, index, isPrevDir, isClassBinding) { const tStylingAtIndex = tData[index + 1]; const isMap = tStylingKey === null; let cursor = isPrevDir ? getTStylingRangePrev(tStylingAtIndex) : getTStylingRangeNext(tStylingAtIndex); let foundDuplicate = false; // We keep...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function markDuplicates(tData, tStylingKey, index, isPrevDir, isClassBinding) {\n var tStylingAtIndex = tData[index + 1];\n var isMap = tStylingKey === null;\n var cursor = isPrevDir ? getTStylingRangePrev(tStylingAtIndex) : getTStylingRangeNext(tStylingAtIndex);\n var foundDuplicate = ...
[ "0.73861885", "0.7379688", "0.5969522", "0.5774845", "0.5752236", "0.5516276", "0.5516276", "0.5516276", "0.5516276", "0.5516276", "0.5516276", "0.55123025", "0.55071694", "0.5347547", "0.5347547", "0.5338531", "0.530802", "0.53079057", "0.5260229", "0.52146393", "0.5198084",...
0.7415528
0
Retrieves the last parsed `key` of style.
function getLastParsedKey(text) { return text.substring(parserState.key, parserState.keyEnd); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getLastParsedKey(text) {\n return text.substring(parserState.key, parserState.keyEnd);\n }", "function getLastParsedKey(text) {\n return text.substring(parserState.key, parserState.keyEnd);\n}", "function fetchStyles(key) {\n return storeFetch(stylesCache, key)\n }", "function getCS...
[ "0.6392544", "0.6321323", "0.60703486", "0.60257316", "0.5918792", "0.5887514", "0.56862", "0.5616713", "0.55998784", "0.55998784", "0.5541551", "0.55251086", "0.5508434", "0.5508434", "0.5508434", "0.5508434", "0.5508434", "0.5508434", "0.53843105", "0.536418", "0.531271", ...
0.6343023
1
Retrieves the last parsed `value` of style.
function getLastParsedValue(text) { return text.substring(parserState.value, parserState.valueEnd); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getLastParsedValue(text) {\n return text.substring(parserState.value, parserState.valueEnd);\n }", "function getLastParsedValue(text) {\n return text.substring(parserState.value, parserState.valueEnd);\n}", "function getStyleValue(node, styleName) {\n // Word uses non-standard names fo...
[ "0.65244013", "0.64320904", "0.63300955", "0.59910184", "0.5972679", "0.5915969", "0.5903731", "0.5822483", "0.57957685", "0.5663453", "0.559974", "0.559974", "0.559974", "0.559974", "0.55367756", "0.55367756", "0.55367756", "0.55367756", "0.55367756", "0.55367756", "0.552996...
0.64514196
1
Update class bindings using an object literal or classstring on an element. This instruction is meant to apply styling via the `[class]="exp"` template bindings. When classes are applied to the element they will then be updated with respect to any styles/classes set via `classProp`. If any classes are set to falsy then...
function ɵɵclassMap(classes) { checkStylingMap(keyValueArraySet, classStringParser, classes, true); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function ɵɵclassMap(classes) {\n var index = getSelectedIndex();\n var lView = getLView();\n var stylingContext = getStylingContext(index, lView);\n var directiveStylingIndex = getActiveDirectiveStylingIndex$1();\n if (directiveStylingIndex) {\n var args = [stylingContext, classes, directiveS...
[ "0.70286363", "0.62283844", "0.6144398", "0.6116643", "0.6089702", "0.6089424", "0.598307", "0.598307", "0.5952777", "0.5952777", "0.5907488", "0.58595604", "0.58478415", "0.5739478", "0.5692522", "0.5674856", "0.5671802", "0.5668458", "0.5668458", "0.5660291", "0.564883", ...
0.6252234
1
Determines when the binding is in `hostBindings` section
function isInHostBindings(tView, bindingIndex) { // All host bindings are placed after the expando section. return bindingIndex >= tView.expandoStartIndex; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function isInHostBindings(tView, bindingIndex) {\n // All host bindings are placed after the expando section.\n return bindingIndex >= tView.expandoStartIndex;\n}", "function isInHostBindings(tView, bindingIndex) {\n // All host bindings are placed after the expando section.\n return bindingIndex...
[ "0.73194116", "0.72901255", "0.5938419", "0.58878726", "0.58878726", "0.5838623", "0.57374555", "0.5726027", "0.570107", "0.5681433", "0.5681433", "0.5681433", "0.5649044", "0.56262606", "0.5616914", "0.55832356", "0.55790955", "0.55538124", "0.5553639", "0.5553639", "0.55312...
0.7349613
0
Adds static styling information to the binding if applicable. The linked list of styles not only stores the list and keys, but also stores static styling information on some of the keys. This function determines if the key should contain the styling information and computes it. See `TStylingStatic` for more details.
function wrapInStaticStylingKey(tData, tNode, stylingKey, isClassBased) { const hostDirectiveDef = getCurrentDirectiveDef(tData); let residual = isClassBased ? tNode.residualClasses : tNode.residualStyles; if (hostDirectiveDef === null) { // We are in template node. // If template node alrea...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function wrapInStaticStylingKey(tData, tNode, stylingKey, isClassBased) {\n var hostDirectiveDef = getCurrentDirectiveDef(tData);\n var residual = isClassBased ? tNode.residualClasses : tNode.residualStyles;\n\n if (hostDirectiveDef === null) {\n // We are in template node.\n ...
[ "0.6907133", "0.6884226", "0.6499127", "0.642555", "0.6315429", "0.6315429", "0.6315429", "0.6315429", "0.6315429", "0.6315429", "0.61286163", "0.5693635", "0.56073254", "0.5595244", "0.5595244", "0.5595244", "0.5595244", "0.5595244", "0.5595244", "0.55938166", "0.5505361", ...
0.69616085
0
Collect the static styling information with lower priority than `hostDirectiveDef`. (This is opposite of residual styling.)
function collectStylingFromDirectives(hostDirectiveDef, tData, tNode, stylingKey, isClassBased) { // We need to loop because there can be directives which have `hostAttrs` but don't have // `hostBindings` so this loop catches up to the current directive.. let currentDirective = null; const directiveEnd ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function collectStylingFromDirectives(hostDirectiveDef, tData, tNode, stylingKey, isClassBased) {\n // We need to loop because there can be directives which have `hostAttrs` but don't have\n // `hostBindings` so this loop catches up to the current directive..\n var currentDirective = null;\n ...
[ "0.6630937", "0.65525305", "0.6230798", "0.6201635", "0.6130631", "0.6130631", "0.6130631", "0.6130631", "0.6130631", "0.6130631", "0.60914975", "0.59432906", "0.5769798", "0.5767844", "0.57487637", "0.5722303", "0.5722303", "0.5722303", "0.5722303", "0.5701133", "0.5701117",...
0.66011643
1
Finds the locale data for a given locale.
function findLocaleData(locale) { const normalizedLocale = normalizeLocale(locale); let match = getLocaleData(normalizedLocale); if (match) { return match; } // let's try to find a parent locale const parentLocale = normalizedLocale.split('-')[0]; match = getLocaleData(parentLocale);...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function findLocaleData(locale) {\n var normalizedLocale = normalizeLocale(locale);\n var match = getLocaleData(normalizedLocale);\n\n if (match) {\n return match;\n } // let's try to find a parent locale\n\n\n var parentLocale = normalizedLocale.split('-')[0];\n match = getLocaleData(parentLocale);\n\n ...
[ "0.82356983", "0.8191185", "0.8136956", "0.8136956", "0.8136956", "0.8136956", "0.80153924", "0.6671215", "0.6597577", "0.65553385", "0.6496288", "0.6496288", "0.6496288", "0.6496288", "0.6496288", "0.6496288", "0.6459184", "0.6278594", "0.6187894", "0.60493785", "0.60493785"...
0.82525915
0
Retrieves the default currency code for the given locale. The default is defined as the first currency which is still in use.
function getLocaleCurrencyCode(locale) { const data = findLocaleData(locale); return data[LocaleDataIndex.CurrencyCode] || null; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getLocaleCurrencyCode(locale) {\n var data = findLocaleData(locale);\n return data[LocaleDataIndex.CurrencyCode] || null;\n }", "function getLocaleCurrencyCode(locale) {\n var data = findLocaleData(locale);\n return data[LocaleDataIndex.CurrencyCode] || null;\n}", "function getLoc...
[ "0.7260417", "0.71462744", "0.6930074", "0.6847429", "0.68331033", "0.6760714", "0.6760714", "0.6760714", "0.6760714", "0.6760714", "0.6758314", "0.6730109", "0.66649956", "0.6657939", "0.66301805", "0.66301805", "0.66301805", "0.6623729", "0.6623729", "0.6623729", "0.6587595...
0.71590227
1
Helper function to get the given `normalizedLocale` from `LOCALE_DATA` or from the global `ng.common.locale`.
function getLocaleData(normalizedLocale) { if (!(normalizedLocale in LOCALE_DATA)) { LOCALE_DATA[normalizedLocale] = _global.ng && _global.ng.common && _global.ng.common.locales && _global.ng.common.locales[normalizedLocale]; } return LOCALE_DATA[normalizedLocale]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getLocaleData(normalizedLocale) {\n if (!(normalizedLocale in LOCALE_DATA)) {\n LOCALE_DATA[normalizedLocale] = _global.ng && _global.ng.common && _global.ng.common.locales && _global.ng.common.locales[normalizedLocale];\n }\n\n return LOCALE_DATA[normalizedLocale];\n }"...
[ "0.7563007", "0.75438714", "0.6879552", "0.68579495", "0.68579495", "0.68579495", "0.68579495", "0.63511664", "0.6313776", "0.6252447", "0.6252447", "0.6252447", "0.6252447", "0.6252447", "0.6252447", "0.62465304", "0.6220062", "0.58897626", "0.58833313", "0.5883041", "0.5871...
0.76311266
0
Helper function to remove all the locale data from `LOCALE_DATA`.
function unregisterAllLocaleData() { LOCALE_DATA = {}; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function unregisterAllLocaleData() {\n LOCALE_DATA = {};\n}", "function unregisterAllLocaleData() {\n LOCALE_DATA = {};\n }", "function clean() {\n\treturn del([paths.locale.dest + paths.locale.potName]);\n}", "function cleanTranslations(data) {\r\n var translation = \"\";\r\n var sliceInd...
[ "0.79368514", "0.7852593", "0.64358485", "0.62518847", "0.6172685", "0.6109031", "0.602918", "0.602918", "0.602918", "0.59392124", "0.5622831", "0.55782557", "0.55218023", "0.5447549", "0.5446605", "0.5444276", "0.5441436", "0.5309785", "0.5280346", "0.52695197", "0.5243532",...
0.7944744
0
Returns the canonical form of a locale name lowercase with `_` replaced with ``.
function normalizeLocale(locale) { return locale.toLowerCase().replace(/_/g, '-'); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function normalize(name) {\n return name.replace(/[- _]+/g, '').toLowerCase();\n }", "function normalize(name) {\n return name.replace(/[- _]+/g, '').toLowerCase();\n }", "function normalizeLocale(locale) {\n return locale.toLowerCase().replace(/_/g, '-');\n }", "function norm...
[ "0.75626075", "0.75626075", "0.7557488", "0.75334024", "0.69759", "0.68836313", "0.68060154", "0.6656072", "0.66386217", "0.6623995", "0.6593526", "0.6591488", "0.653802", "0.6499552", "0.64838785", "0.6470634", "0.6470634", "0.64566696", "0.64504033", "0.6444169", "0.6441153...
0.7588741
0
Sets the locale id that will be used for translations and ICU expressions. This is the ivy version of `LOCALE_ID` that was defined as an injection token for the view engine but is now defined as a global value.
function setLocaleId(localeId) { assertDefined(localeId, `Expected localeId to be defined`); if (typeof localeId === 'string') { LOCALE_ID = localeId.toLowerCase().replace(/_/g, '-'); } }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function setLocaleId(localeId) {\n assertDefined(localeId, \"Expected localeId to be defined\");\n\n if (typeof localeId === 'string') {\n LOCALE_ID = localeId.toLowerCase().replace(/_/g, '-');\n }\n }", "function setLocaleId(localeId) {\n assertDefined(localeId, \"Expected lo...
[ "0.7506865", "0.74835664", "0.7456184", "0.74230397", "0.6784188", "0.6784188", "0.6784188", "0.6784188", "0.6784188", "0.6784188", "0.67725194", "0.6768154", "0.66772705", "0.61965746", "0.5860908", "0.585842", "0.58171356", "0.5566156", "0.54657173", "0.5408517", "0.5375303...
0.7498932
1
Gets the locale id that will be used for translations and ICU expressions. This is the ivy version of `LOCALE_ID` that was defined as an injection token for the view engine but is now defined as a global value.
function getLocaleId() { return LOCALE_ID; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getLocaleId() {\n return LOCALE_ID;\n}", "function getLocaleId() {\n return LOCALE_ID$1;\n}", "function getLocaleId() {\n return LOCALE_ID;\n }", "function getLocaleId(locale){return findLocaleData(locale)[0/* LocaleId */];}", "function getGlobalLocale() {\n if (typeof ngI18nClo...
[ "0.81547743", "0.8094365", "0.8067423", "0.7057078", "0.70196956", "0.70196956", "0.70196956", "0.70196956", "0.70196956", "0.6987737", "0.6987737", "0.6987737", "0.6987737", "0.6987737", "0.6987737", "0.694663", "0.6927254", "0.69245684", "0.67949444", "0.67044693", "0.66643...
0.81239605
1
Apply OpCodes associated with tearing ICU case. This involves tearing down existing case and than building up a new case.
function applyIcuSwitchCaseRemove(tView, tIcu, lView) { let activeCaseIndex = getCurrentICUCaseIndex(tIcu, lView); if (activeCaseIndex !== null) { const removeCodes = tIcu.remove[activeCaseIndex]; for (let i = 0; i < removeCodes.length; i++) { const nodeOrIcuIndex = removeCodes[i]; ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function applyIcuSwitchCaseRemove(tView, tIcu, lView) {\n var activeCaseIndex = getCurrentICUCaseIndex(tIcu, lView);\n\n if (activeCaseIndex !== null) {\n var removeCodes = tIcu.remove[activeCaseIndex];\n\n for (var i = 0; i < removeCodes.length; i++) {\n var nodeOrIcuInd...
[ "0.5717625", "0.5644009", "0.51251096", "0.50449073", "0.5002955", "0.49999785", "0.49951267", "0.49628642", "0.4955001", "0.4954435", "0.4908184", "0.49067655", "0.48877627", "0.48642558", "0.48497197", "0.4845394", "0.4833899", "0.48337406", "0.48281914", "0.48279208", "0.4...
0.5722606
1
Converts `I18nUpdateOpCodes` array into a human readable format. This function is attached to the `I18nUpdateOpCodes.debug` property if `ngDevMode` is enabled. This function provides a human readable view of the opcodes. This is useful when debugging the application as well as writing more readable tests.
function i18nUpdateOpCodesToString(opcodes) { const parser = new OpCodeParser(opcodes || (Array.isArray(this) ? this : [])); let lines = []; function consumeOpCode(value) { const ref = value >>> 2 /* SHIFT_REF */; const opCode = value & 3 /* MASK_OPCODE */; switch (opCode) { ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function i18nUpdateOpCodesToString(opcodes) {\n var parser = new OpCodeParser(opcodes || (Array.isArray(this) ? this : []));\n var lines = [];\n\n function consumeOpCode(value) {\n var ref = value >>> 2\n /* SHIFT_REF */\n ;\n var opCode = value & 3\n /* MASK_OPCODE */\n ;\n\n switch (opCod...
[ "0.76982826", "0.7678048", "0.63670444", "0.5993241", "0.5993241", "0.5993241", "0.5993241", "0.5993241", "0.5993241", "0.5835858", "0.5804103", "0.5804103", "0.5804103", "0.5804103", "0.5804103", "0.5804103", "0.58034074", "0.5742771", "0.57091147", "0.5451047", "0.5451047",...
0.7753628
1
Converts `I18nRemoveOpCodes` array into a human readable format. This function is attached to the `I18nRemoveOpCodes.debug` if `ngDevMode` is enabled. This function provides a human readable view of the opcodes. This is useful when debugging the application as well as writing more readable tests.
function i18nRemoveOpCodesToString(opcodes) { const removeCodes = opcodes || (Array.isArray(this) ? this : []); let lines = []; for (let i = 0; i < removeCodes.length; i++) { const nodeOrIcuIndex = removeCodes[i]; if (nodeOrIcuIndex > 0) { // Positive numbers are `RNode`s. ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function i18nRemoveOpCodesToString(opcodes) {\n var removeCodes = opcodes || (Array.isArray(this) ? this : []);\n var lines = [];\n\n for (var i = 0; i < removeCodes.length; i++) {\n var nodeOrIcuIndex = removeCodes[i];\n\n if (nodeOrIcuIndex > 0) {\n // Positive numbers are `RNode`s.\n lines.pu...
[ "0.8165118", "0.8164244", "0.67298007", "0.6693702", "0.6693702", "0.6693702", "0.6693702", "0.6693702", "0.6693702", "0.6673321", "0.6165316", "0.6165316", "0.6165316", "0.6165316", "0.6165316", "0.6165316", "0.6114416", "0.60625225", "0.5178964", "0.49855056", "0.4966109", ...
0.821975
1
Count the number of bindings in the given `opCodes`. It could be possible to speed this up, by passing the number of bindings found back from `generateBindingUpdateOpCodes()` to `i18nAttributesFirstPass()` but this would then require more complexity in the code and/or transient objects to be created. Since this functio...
function countBindings(opCodes) { let count = 0; for (let i = 0; i < opCodes.length; i++) { const opCode = opCodes[i]; // Bindings are negative numbers. if (typeof opCode === 'number' && opCode < 0) { count++; } } return count; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function lookupCount(state, bindings, key) {\n if(key in bindings) {\n var arr = bindings[key], r = 0\n for(var i=0, n=arr.length; i<n; ++i) {\n r += state[virtualKeyCode(arr[i])]\n }\n return r\n }\n var kc = virtualKeyCode(key)\n if(kc >= 0) {\n return state[kc]\n }\n return 0\n}", "f...
[ "0.5003594", "0.46740708", "0.46645734", "0.4648621", "0.46299556", "0.46021134", "0.45422864", "0.45399842", "0.44309038", "0.44309038", "0.44309038", "0.44309038", "0.44249117", "0.4351523", "0.4351523", "0.4351523", "0.4351523", "0.4351523", "0.4351523", "0.4237962", "0.42...
0.7218382
1
Returns the index of item in the array, but only in the begin to end range.
function indexOf(item, arr, begin, end) { for (let i = begin; i < end; i++) { if (arr[i] === item) return i; } return -1; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function indexOf(item, arr, begin, end) {\n for (var i = begin; i < end; i++) {\n if (arr[i] === item) return i;\n }\n\n return -1;\n }", "function indexOf(item, arr, begin, end) {\n for (var i = begin; i < end; i++) {\n if (arr[i] === item) return i;\n }\n\n return -1;\n...
[ "0.7635754", "0.7580673", "0.75520176", "0.75520176", "0.75520176", "0.7120106", "0.68016183", "0.6642472", "0.65324837", "0.6428712", "0.6428712", "0.6428712", "0.6428712", "0.6369323", "0.63687295", "0.6347178", "0.6347178", "0.6290085", "0.6290085", "0.62745845", "0.615580...
0.7652124
1
Maps an array of factories into an array of values.
function multiResolve(factories, result) { for (let i = 0; i < factories.length; i++) { const factory = factories[i]; result.push(factory()); } return result; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function multiResolve(factories, result) {\n for (var i = 0; i < factories.length; i++) {\n var factory = factories[i];\n result.push(factory());\n }\n\n return result;\n }", "function multiResolve(factories,result){for(var i=0;i<factories.length;i++){var factory=facto...
[ "0.6207832", "0.62013274", "0.61914504", "0.6173574", "0.6173574", "0.6173574", "0.60479915", "0.6027646", "0.59521294", "0.58377445", "0.58113104", "0.57643884", "0.5725838", "0.57226425", "0.5696337", "0.56922656", "0.5650708", "0.5636979", "0.56046623", "0.55995005", "0.55...
0.6255931
1
Unwraps `ElementRef` and return the `nativeElement`.
function unwrapElementRef(value) { return value instanceof ElementRef ? value.nativeElement : value; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function unwrapElementRef(value) {\n return value instanceof ElementRef ? value.nativeElement : value;\n }", "get nativeElement() {\n var _a;\n return (_a = this.view) === null || _a === void 0 ? void 0 : _a.nativeElement;\n }", "_getHostElement() {\n return this._elementRef...
[ "0.8052644", "0.7445984", "0.70427334", "0.70427334", "0.6960646", "0.6960646", "0.6960646", "0.6960646", "0.6960646", "0.6960646", "0.6960646", "0.6960646", "0.66814303", "0.6484851", "0.6484851", "0.6484851", "0.6484851", "0.6484851", "0.6484851", "0.6433059", "0.6408948", ...
0.80784315
1
Reset the state of the change objects to show no changes. This means set previousKey to currentKey, and clear all of the queues (additions, moves, removals). Set the previousIndexes of moved and added items to their currentIndexes Reset the list of additions, moves and removals
_reset() { if (this.isDirty) { let record; for (record = this._previousItHead = this._itHead; record !== null; record = record._next) { record._nextPrevious = record._next; } for (record = this._additionsHead; record !== null; record = record._next...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "clear() {\n this.stack = this.initialItem ? [this.initialItem] : [{ index: 0, state: [] }];\n this.position = 0;\n this.onUpdate();\n }", "reset() {\n this._objInfo.forEach(info => {\n info.obj.position.copy(info.pos);\n info.obj.up.copy(info.up);\n\n this._check...
[ "0.6439134", "0.61253965", "0.61144525", "0.605026", "0.59885365", "0.5984688", "0.5930008", "0.59166074", "0.587713", "0.5837287", "0.58365566", "0.5818653", "0.5814612", "0.5806643", "0.5801855", "0.57877046", "0.577816", "0.577816", "0.577816", "0.57446307", "0.5734253", ...
0.7481024
1
Append the record to the list of duplicates. Note: by design all records in the list of duplicates hold the same value in record.item.
add(record) { if (this._head === null) { this._head = this._tail = record; record._nextDup = null; record._prevDup = null; } else { // TODO(vicb): // assert(record.item == _head.item || // record.item is num && record...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "addItem(userItem) {\n for(var i=0; i<this._userItemList.length; i++){\n // if not check the list for a new userItem and add it to the userItemList\n if(this.userItemList[i]._item._itemCode === userItem._item._itemCode){\n console.log('ERROR: Duplicate Save');\n } else {\n var newUserIte...
[ "0.6155939", "0.60877573", "0.60471225", "0.60053426", "0.58986485", "0.5822983", "0.5798324", "0.57896537", "0.5771191", "0.57553583", "0.575485", "0.57448614", "0.57448614", "0.57448614", "0.57448614", "0.57448614", "0.57326853", "0.5666505", "0.56654316", "0.55993956", "0....
0.66902333
1
Returns a IterableChangeRecord_ having IterableChangeRecord_.trackById == trackById and IterableChangeRecord_.currentIndex >= atOrAfterIndex
get(trackById, atOrAfterIndex) { let record; for (record = this._head; record !== null; record = record._nextDup) { if ((atOrAfterIndex === null || atOrAfterIndex <= record.currentIndex) && Object.is(record.trackById, trackById)) { return record; }...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "_mismatch(record, item, itemTrackBy, index) {\n // The previous record after which we will append the current one.\n let previousRecord;\n if (record === null) {\n previousRecord = this._itTail;\n }\n else {\n previousRecord = record._prev;\n // R...
[ "0.5722303", "0.56599367", "0.56599367", "0.56599367", "0.56599367", "0.56599367", "0.5414185", "0.54116464", "0.54116464", "0.54116464", "0.53264874", "0.53264874", "0.52389705", "0.52389705", "0.52389705", "0.52389705", "0.52389705", "0.52389705", "0.5186552", "0.4951993", ...
0.6170709
1
Inserts a record before `before` or append at the end of the list when `before` is null. Notes: This method appends at `this._appendAfter`, This method updates `this._appendAfter`, The return value is the new value for the insertion pointer.
_insertBeforeOrAppend(before, record) { if (before) { const prev = before._prev; record._next = before; record._prev = prev; before._prev = record; if (prev) { prev._next = record; } if (before === this._mapHead)...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function insert(element,after) {\n var insertPos = this.find(after);\n if (insertPos > -1) {\n this.dataStore.splice(insertPos+1,0,element);\n ++this.listSize;\n return true;\n }\n return false;\n}", "function insert(element, after) {\n var insertPosition = this.find(after);\n if (insertPositi...
[ "0.6030754", "0.6001603", "0.598685", "0.598134", "0.5970492", "0.5937247", "0.5908747", "0.58863777", "0.5836007", "0.5805568", "0.579366", "0.57527065", "0.57527065", "0.565472", "0.56546164", "0.55425465", "0.54731786", "0.5468661", "0.54439783", "0.53154147", "0.5282687",...
0.78812015
1
Returns the QueryList entry at `index`.
get(index) { return this._results[index]; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function asQueryList(view, index) {\n return view.nodes[index];\n }", "function itemAtIndex(index){\r\n return self[keyTable[index]];\r\n }", "function asQueryList(view, index) {\n return view.nodes[index];\n}", "function asQueryList(view, index) {\n return view.nodes[index];\n}",...
[ "0.61281925", "0.6093671", "0.6027647", "0.6027647", "0.6027647", "0.6027647", "0.6027647", "0.6027647", "0.6027647", "0.6027647", "0.6027647", "0.60254294", "0.600086", "0.5760102", "0.57431054", "0.57006913", "0.5698816", "0.56661254", "0.5636195", "0.56122583", "0.5611914"...
0.63160753
0
Returns a copy of the internal results list as an Array.
toArray() { return this._results.slice(); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "asArray() {\n const result = new Array();\n this.toArray(result, 0);\n return result;\n }", "toArray() {\n\t\t\treturn this.array.slice();\n\t\t}", "toArray() {\n return Array.from(this.items);\n }", "toArray() {\n\t\t\t\treturn this.slice(0);\n\t\t\t}", "toArray() {\n ...
[ "0.7535309", "0.728775", "0.7096974", "0.70968795", "0.70708483", "0.6969921", "0.69573563", "0.69463575", "0.6926777", "0.6782329", "0.6748802", "0.6748802", "0.6748802", "0.67293096", "0.6711675", "0.6667143", "0.66330045", "0.66044563", "0.65647805", "0.65615356", "0.65373...
0.80347043
0
A helper function that creates query results for a given view. This function is meant to do the processing once and only once for a given view instance (a set of results for a given view doesn't change).
function materializeViewResults(tView, lView, tQuery, queryIndex) { const lQuery = lView[QUERIES].queries[queryIndex]; if (lQuery.matches === null) { const tViewData = tView.data; const tQueryMatches = tQuery.matches; const result = []; for (let i = 0; i < tQueryMatches.length; i...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function materializeViewResults(tView, lView, tQuery, queryIndex) {\n var lQuery = lView[QUERIES].queries[queryIndex];\n\n if (lQuery.matches === null) {\n var tViewData = tView.data;\n var tQueryMatches = tQuery.matches;\n var result = [];\n\n for (var i = 0; i < tQueryMatches.length; i += 2) {\n ...
[ "0.6735364", "0.66863775", "0.6447901", "0.6403648", "0.62999344", "0.62999344", "0.62999344", "0.62999344", "0.62999344", "0.62999344", "0.5937481", "0.5937481", "0.5925283", "0.5909588", "0.5909588", "0.5876529", "0.58551896", "0.58551896", "0.5670133", "0.5627586", "0.5473...
0.6800965
0
A helper function that collects (already materialized) query results from a tree of views, starting with a provided LView.
function collectQueryResults(tView, lView, queryIndex, result) { const tQuery = tView.queries.getByIndex(queryIndex); const tQueryMatches = tQuery.matches; if (tQueryMatches !== null) { const lViewResults = materializeViewResults(tView, lView, tQuery, queryIndex); for (let i = 0; i < tQueryM...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function collectQueryResults(tView, lView, queryIndex, result) {\n var tQuery = tView.queries.getByIndex(queryIndex);\n var tQueryMatches = tQuery.matches;\n\n if (tQueryMatches !== null) {\n var lViewResults = materializeViewResults(tView, lView, tQuery, queryIndex);\n\n for (var i = 0; i < tQueryMatches...
[ "0.7890622", "0.7756462", "0.7263189", "0.7263189", "0.7263189", "0.7263189", "0.7263189", "0.7263189", "0.72485936", "0.71802056", "0.60488147", "0.5826679", "0.55718166", "0.5560787", "0.5557739", "0.55084634", "0.55084634", "0.55084634", "0.55084634", "0.55084634", "0.5508...
0.78694737
1
Compute the pair of transitive scopes (compilation scope and exported scope) for a given module. This operation is memoized and the result is cached on the module's definition. This function can be called on modules with components that have not fully compiled yet, but the result should not be used until they have.
function transitiveScopesFor(moduleType) { if (!isNgModule(moduleType)) { throw new Error(`${moduleType.name} does not have a module def (ɵmod property)`); } const def = getNgModuleDef(moduleType); if (def.transitiveCompileScopes !== null) { return def.transitiveCompileScopes; } ...
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function transitiveScopesFor(moduleType) {\n if (!isNgModule(moduleType)) {\n throw new Error(`${moduleType.name} does not have a module def (ɵmod property)`);\n }\n const def = getNgModuleDef(moduleType);\n if (def.transitiveCompileScopes !== null) {\n return def.transitiveCompileScopes;...
[ "0.749281", "0.7462276", "0.7461386", "0.7312088", "0.7312088", "0.7312088", "0.7135634", "0.7128292", "0.5300363", "0.52188957", "0.51130444", "0.5086835", "0.5039414", "0.5035205", "0.50262195", "0.50262195", "0.50262195", "0.49521086", "0.48721117", "0.48637533", "0.486375...
0.751447
0
Returns the id for a given NgModule, if one is defined and known to the compiler.
getModuleId(moduleType) { return undefined; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function getProviderId(module) {\n const metaData = getClassMetadata(constant_1.TAGGED_CLS, module);\n if (metaData && metaData.id) {\n return metaData.id;\n }\n}", "function angularModuleName(module) {\n return 'App.' + module;\n}", "function makeIdentifierFromModuleName(moduleName) {\n ...
[ "0.6567957", "0.608637", "0.6022508", "0.5988656", "0.57842374", "0.5553783", "0.5486032", "0.5351961", "0.5206619", "0.5167224", "0.5105102", "0.509466", "0.509466", "0.5092661", "0.5087663", "0.50184757", "0.50166655", "0.5015477", "0.49837765", "0.49837765", "0.4966393", ...
0.68304294
0
Increases the number of pending request
increasePendingRequestCount() { this._pendingCount += 1; this._didWork = true; return this._pendingCount; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "decreasePendingRequestCount() {\n this._pendingCount -= 1;\n if (this._pendingCount < 0) {\n throw new Error('pending async requests below zero');\n }\n this._runCallbacksIfReady();\n return this._pendingCount;\n }", "decreasePendingRequestCount() {\n this....
[ "0.7237034", "0.7237034", "0.7237034", "0.7237034", "0.7237034", "0.7237034", "0.7125938", "0.7025253", "0.7025253", "0.70058376", "0.7001432", "0.6883664", "0.6766366", "0.6766366", "0.6740155", "0.6648596", "0.6648596", "0.6648596", "0.6648596", "0.6648596", "0.6648596", ...
0.79040486
0
Decreases the number of pending request
decreasePendingRequestCount() { this._pendingCount -= 1; if (this._pendingCount < 0) { throw new Error('pending async requests below zero'); } this._runCallbacksIfReady(); return this._pendingCount; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "endRequest(handle) {\n this.activeRequestCount--;\n this._issueNewRequests();\n }", "function onRequestClosed () {\n stats.dec(TRACKERS.OPEN_REQUESTS);\n\n // Increase number of abruptly closed reqs\n stats.inc(TRACKERS.TOTAL_REQ_ERROR);\n}", "function decrRequestCounterWaypoint(index) {\n\t\trequest...
[ "0.70766574", "0.68122643", "0.67667186", "0.6674214", "0.6674214", "0.6674214", "0.6674214", "0.6674214", "0.6674214", "0.66199267", "0.6612", "0.6607986", "0.6607986", "0.6597318", "0.6592506", "0.65784365", "0.65078324", "0.64988077", "0.6498362", "0.6498362", "0.6494162",...
0.7906734
0
Get the number of pending requests
getPendingRequestCount() { return this._pendingCount; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "increasePendingRequestCou...
[ "0.766631", "0.766631", "0.766631", "0.766631", "0.766631", "0.766631", "0.73932934", "0.73932934", "0.73932934", "0.73932934", "0.73932934", "0.73932934", "0.6962466", "0.6896609", "0.6896609", "0.683125", "0.6689343", "0.6658573", "0.6604643", "0.6550601", "0.63644797", "...
0.7851677
0
Find providers by name
findProviders(using, provider, exactMatch) { // TODO(juliemr): implement. return []; }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "initProvider(name) {\n\t\tif(this.availableProviders.has(name) && !this.providers.has(name)) {\n\t\t\tvar actProvider = this.availableProviders.get(name);\n\t\t\treturn this.providerFactory(name, actProvider[0], actProvider[1], actProvider[2]);\n\t\t}\n\t\telse {\n\t\t\t return false;\n\t\t}\n\t}", "function get...
[ "0.6459128", "0.6396928", "0.63961124", "0.6391404", "0.61388624", "0.61337775", "0.6131868", "0.61036354", "0.6003237", "0.59676105", "0.5884376", "0.58296686", "0.5827987", "0.58277947", "0.58231276", "0.57815707", "0.56720835", "0.5661711", "0.5648209", "0.5608413", "0.558...
0.7510326
0
Registers an application with a testability hook so that it can be tracked
registerApplication(token, testability) { this._applications.set(token, testability); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function testing() {\n console.log('Personalization App Loaded');\n}", "addHook (hook) {\n this.hooks.push(hook)\n }", "register() {\n if (this.argv.hookRequire) {\n require('@after-work.js/register')(\n this.argv,\n this.srcFiles,\n this.testFiles,\n );\n }\n }", "...
[ "0.592703", "0.5857069", "0.5668487", "0.5544105", "0.54392695", "0.53968316", "0.5389926", "0.5383747", "0.53319776", "0.5297334", "0.52883387", "0.5281036", "0.52537376", "0.5242665", "0.5185284", "0.51751566", "0.5175125", "0.5163787", "0.5152258", "0.5117701", "0.5069758"...
0.68277544
0
Get all registered testabilities
getAllTestabilities() { return Array.from(this._applications.values()); }
{ "objective": { "self": [], "paired": [], "triplet": [ [ "query", "document", "negatives" ] ] } }
[ "function GetTestability(){}", "function GetTestability() {}", "function GetTestability() {}", "function GetTestability() {}", "static getAllTests() {\n return [\n CalculatorTest.test01,\n CalculatorTest.test02,\n CalculatorTest.test03,\n CalculatorTest.test04,\n CalculatorTest.t...
[ "0.67877966", "0.6531294", "0.6531294", "0.6531294", "0.65252954", "0.6465588", "0.6465588", "0.64121467", "0.5823481", "0.5776181", "0.5682875", "0.565225", "0.55237323", "0.54783463", "0.54597974", "0.5453185", "0.5394054", "0.53884256", "0.5386909", "0.5342097", "0.5282874...
0.7668541
0