This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BeginPackage["LazyTuples`"] | |
LazyTuples::usage = "LazyTuples[lists, opts] create a LazyList of the specified chunk size (\"ChunkSize\" option), containing tuples of the original lists"; | |
TuplesFunction::usage = | |
"TuplesFunction[lists][parts: _Integer | {__Integer} | _Span] generates a tuple or a set of tuples \ | |
found at specific positions indicated, in the full list of tuples, as given by Tuples"; | |
Begin["`Private`"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ClearAll[LazyListSelect]; | |
LazyListSelect[l:Streaming`LazyList`$PLazyList, crit_, fullSelect_:None]:= | |
Module[{selFun, chunkSizeF, mappedF, result, id = Streaming`Common`StreamingUUID[]}, | |
selFun = If[fullSelect =!= None && crit === None, | |
fullSelect, | |
Function[chunkData, Select[chunkData, crit]] | |
]; | |
chunkSizeF = | |
Function[index, | |
With[{chunk = Streaming`Components`RandomAccessList`ListPart[Streaming`LazyList`LazyListData[result], index]}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class RegistrationForm(forms.Form): | |
username = forms.CharField( | |
label='Имя пользователя', | |
max_length=30, | |
widget=forms.TextInput(attrs={'class':'uname-reg'})) | |
email = forms.EmailField( | |
label='Email', | |
widget=forms.EmailInput( attrs={'class' : 'email-reg'}) | |
) | |
password1 = forms.CharField( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$sqlKeywords = { | |
"ABSOLUTE","ACTION","ADD","AFTER","ALL","ALLOCATE","ALTER","AND","ANY","ARE","ARRAY","AS", | |
"ASC","ASENSITIVE","ASSERTION","ASYMMETRIC","AT","ATOMIC","AUTHORIZATION","AVG","BEFORE", | |
"BEGIN","BETWEEN","BIGINT","BINARY","BIT","BIT_LENGTH","BLOB","BOOLEAN","BOTH","BREADTH", | |
"BY","CALL","CALLED","CASCADE","CASCADED","CASE","CAST","CATALOG","CHAR","CHARACTER", | |
"CHARACTER_LENGTH","CHAR_LENGTH","CHECK","CLOB","CLOSE","COALESCE","COLLATE","COLLATION", | |
"COLUMN","COMMIT","CONDITION","CONNECT","CONNECTION","CONSTRAINT","CONSTRAINTS","CONSTRUCTOR", | |
"CONTAINS","CONTINUE","CONVERT","CORRESPONDING","COUNT","CREATE","CROSS","CUBE","CURRENT", | |
"CURRENT_DATE","CURRENT_DEFAULT_TRANSFORM_GROUP","CURRENT_PATH","CURRENT_ROLE","CURRENT_TIME", | |
"CURRENT_TIMESTAMP","CURRENT_TRANSFORM_GROUP_FOR_TYPE","CURRENT_USER","CURSOR","CYCLE","DATA", |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ClearAll[symbolRules]; | |
symbolRules[syms_List]:= | |
Join @@ Map[ | |
Function[s, symbolRules @ Unevaluated @ s, HoldFirst], | |
Unevaluated @ syms | |
] | |
symbolRules[sym_String]:= | |
ToExpression[sym, InputForm, Function[s,symbolRules @ Unevaluated @ s, HoldFirst]]; | |
symbolRules[s_Symbol]:= Join[OwnValues[s],DownValues[s], UpValues[s], SubValues[s]]; | |
symbolRules[]:= symbolRules @ Names["Global`*"]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BeginPackage["FrozenCode`"] | |
FrozenCodeEvaluate::usage = "FrozenCodeEvaluate[Hold[code], {heads}] evaluates the code | |
in the 'frozen' mode, where only specific heads are allowed to evaluate"; | |
Begin["`Private`"] | |
ClearAll[symbolToHideQ] | |
SetAttributes[symbolToHideQ, HoldFirst]; | |
symbolToHideQ[s_Symbol, expandedSymbs_] :=! MemberQ[expandedSymbs, Unevaluated[s]]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BeginPackage["ReferenceTracker`"] | |
TrackReferences; | |
Begin["`Private`"] | |
Clear[$globalProperties]; | |
$globalProperties = { | |
OwnValues, | |
DownValues, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BeginPackage["HTMLParser`"] | |
ParseHTML::usage = "ParseHTML[s] parses a string of HTML code"; | |
HTMLContainer::usage = "HTMLContainer[tag] is an inert container for the contents of html tag"; | |
Begin["`Private`"] | |
listSplit[x_List,lengthlist_List,headlist_List]:= |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BeginPackage["RuleBasedFunction`"] | |
RuleBasedFunction::usage = "RuleBasedFunction[defs, attrs] constructs a pure function based on definitions given by rules"; | |
Fn::usage = "Fn is a symbol used to denote a function in definitions used in RuleBasedFunction"; | |
Begin["`Private`"] | |
SetAttributes[CleanUp, HoldAll] | |
CleanUp[expr_, cleanup_] := |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BeginPackage["OO`"] | |
new | |
EndPackage[] | |
BeginPackage["OO`Core`", "RuleBasedFunction`"] | |
TypeQ; | |
ObjectQ; |
NewerOlder