In this post we will write a simple regex library. The table below presents regex operators that we are going to support:
| Operator | Description |
|---|---|
A single character e.g. a , \n , \( |
A single character matches itself. Special characters need to be escaped e.g. \n .
|
Character groups e.g. [a-z] , [^xyz] |
Character group matches any character
that is part of the group. Negated character group ( [^xyz] )
matches any character that is not part of the group.Character ranges like a-z can be used inside groups.
A character c belongs to a-z range when its
numerical value falls between (int)'a' <= (int)c <= (int)'z' .
|
. wildcard |
. wildcard will match any single character.
For example ... will match any string consisting of three characters.
|
Concatenation e.g. abc ,[0-9]-[0-9] |
Just as we can concatenate strings,
we may also concatenate regexes.
The resulting expression will match an input, only when the input can be split into two parts, so that
the first part of the input matches the first concatenated regex and
the second part of the input matches the second concatenated regex.
For example input 9X matches the regex [0-9][XYZ] because 9 matches [0-9] and X matches [XYZ] .
|
Alternative e.g. Z|X|[0-9] |
Input matches the alternative when it matches
any branch of the alternative. For example inputs Z , X
and 3 will all match Z|X|[0-9] alternative because they match
respectively Z , X and [0-9] branches.
Alternative has lower priority than concatenation so foo|bar means (foo)|(bar) , not fo(o|b)ar .
|
Repetition (quantification)
e.g. a* , [0-9]? , X{1,5} |
Preceding regex must match input specified number of times. Supported operators are:
For example
[0-9]* will match any string consisting of digits, including empty string.On the other hand [0-9]{2,3} will match strings consisting of two or three decimal digits.In our limited implementation we do not support spaces (or any other whitespace characters) inside {n,m} expressions.Repetition has higher priority than concatenation and alternative so foo{5} means fo(o{5}) , not (foo){5} .Repetition operators are greedy, this means they will try to match as much input as possible. For example (a*)(a*) will match the aaaaa input in
the following way (aaaaa)() - the first a* will match
all the characters, leaving empty string for the second a* to match.
|
^ and $ anchors |
^ matches the beginning of the input.$ matches the end of the input.For example ^foo will match strings that start with
foo and bar$ will match strings that end with bar .
|
| Grouping (parentheses) |
Parentheses are used to alter the precedence of the operators. For example compare foo|bar with fo(o|b)ar ,
the first one will match foo , the second one fooar .
|
The library itself is quite small, it consists of two parts: a parser and a matcher. The parser is a very simple recursive descent parser and as most of manually written parsers it probably contains some undiscovered bugs. The parser itself is not the main focus of this article, so we will tread it as a black box that consumes regular expressions in text form and produces equivalent ASTs or Abstract Syntax Trees.
ASTs are tree like data structures,
that make order of operator evaluation and the internal structure of a regular
expression explicit.
Let’s see this on an example. The AST representation of
^a(foo|bar|egg)*b$
regex is:
The anchors ^
and $
are represented by their own
AST nodes AT_BEGINNING
and AT_END
.
To represent both character groups and single characters, we use
GROUP
nodes. GROUP
nodes are very simple, they contain a list
of characters that they match. A GROUP
node for [0-9]
regex
contains characters<PHONE_NUMBER>
in the list.
For negated groups like [^0-9]
we use NEGATED_GROUP
node,
the representation is the same as for GROUP
(we keep<PHONE_NUMBER>
characters
in the list).
Next is the tricky one, we use NEGATED_GROUP
without any characters
to represent wildcard (.
). This makes sense because an empty group []
does not match anything, so its negation will match all characters.
To represent quantification operators like ?
, +
, *
and {n,m}
we use REPEAT
nodes. REPEAT
nodes contain two additional attributes:
minimum and maximum number of allowed repetitions.
We use Long.MAX_VALUE
to signify that maximum number of repetitions is unbound.
Finally we use CONCAT
node to represent concatenation of two or more
regular expressions.
In the code all AST nodes are represented by a single class
called RAst
:
type
field describes what kind of AST node this instance
represents e.g. CONCAT
.
GROUP
and NEGATED_GROUP
nodes keep the set of matched/not-matched
characters in chars
field.
CONCAT
and ALTERNATIVE
nodes keep their children in exprs
field
(the order of children is important, hence a List
).
REPEAT
node keeps its only child as a single element list in exprs
field.
The matcher is represented in the code by BacktrackingMatcher
class.
The interface of the matcher is very simple:
Our matcher will only find the first substring of the input that matches the regex. Yet it would not be too difficult to extend the algorithm to find all matches (start matching again after the end of the previous match).
To implement our matcher we will use an algorithm design technique
called backtracking. The general idea of backtracking is
very simple: we enumerate all the possible solution candidates
in a smart way and then we return the first candidate that is a valid solution.
The part “in a smart way” is very important, usually
enumerating all solution candidates will result in a very
slow algorithm (think O(2^n)
or even O(n!)
).
The key here is to quickly and early reject some subsets of
the solutions candidates.
Let’s see this on a very simple example,
say we want to solve a puzzle that is about placing various shapes in 3x3 grid. Some places in the grid are already taken. There is also a rule that describes a valid solution: in every row and column we cannot have two shapes of the same kind.
Simple enumeration of all possible assignments of the shapes to the free places
will generate 3^5
solution candidates, most of them wrong.
A smarter candidate generation strategy
would be to check immediately after we fill a free place,
if the solution conditions still holds for this place row and column.
This would save us a lot of work, because we could discard a lot of
solution candidates much more early in the process.
For example we could discard all the solution candidates that have
Cloud shape at 1B position in the first step of the algorithm.
The name of the technique itself comes from the specific way in which the algorithm generates all the solution candidates. The naive backtracking algorithm that solves our simple puzzle looks like this:
The key part of the algorithm is the for
loop,
where we put a shape on the free place and then remove it
when don’t find a solution. This removal
or taking a move back is what gave the algorithm its name.
Alternatively we may say that when solve
returns false
,
then the board
is exactly in the same state as it was
before we called solve
.
Matching regular expression is somehow similar to solving our previous puzzle.
At each step we have several possibilities, like should we match foo
or fo
from the alternative (foo|fo)
. How much characters should
f+
expression match? Should (bar)?
match bar
or nothing?
On the other hand the most complexity in matching regular expressions
comes from the fact that we are matching a recurrent structure (tree).
It’s like matching our puzzle, but where each empty place can contain
another smaller version of the same puzzle that also must be solved.
The main entry point to our regex matching algorithm is
method. It takes three parameters, input
which is just
the input String
plus a pointer called pos
that tracks next, not yet
matched character. Input
also provides helpful methods that can
be used to save and restore pos
value (we will need that
for backtracking). Next parameter, ast
, is an AST subtree that the algorithm
should match. The last parameter cont
is the most interesting one.
In my previous blog post I wrote about
continuations, please read that post before
going further. cont
is lambda expression (but we may thread it also as
a kind of continuation), that when called will
try to match remaining part of the regex AST (e.g. it will match parents
and the remaining siblings nodes of ast
node).
The contract of match
method is as follows.
If the method is not able to match ast
subtree it will
return false
, cont
will not be called and the input
will not be modified (or it may be restored to the original state).
On the other hand if ast
subtree could be matched then
cont
will be called with the modified input
and
match
will return whatever cont
returns.
Before returning value to the client input
will be restored
to the original state (this is not strictly necessary if we
are looking for the first match but somehow makes algorithm more elegant).
At the top level we will call match
somehow like this:
This call means that we are looking for the matches
starting at index startIndex
and if we find one
we save the
end of the match in the endIndex
variable and return true
to signify that matching process should stop.
This is the only place in the algorithm where we use
return true
. Matched substring could be easily
retrieved as input.substring(startIndex, endIndex)
.
The body of match
method is a giant switch statement that
delegates matching of different AST types to different methods (not counting simple
operators):
Let’s take a look how matching a GROUP
is performed.
If the group matches next input character, we save the current
input pointer in m
variable, then we advance the input pointer
and finally we call cont
to match the
rest of the regex. After cont
returns we restore the input position
using finally
block. This is a bit hacky but it works.
Matching CONCAT
node is also simple. We use recursion to match
subsequent children expressions:
Notice that because we are not consuming any input here we have nothing to restore.
Similarly ALTERNATIVE
is easy to match:
Here currExpr
points to the current alternative branch that we are matching.
Instead of using recursion we may implement alternativeRec
using a simple for
loop, which I left as an exercise for the reader.
Matching REPEAT
node causes the most troubles, because all
quantification operators are greedy by default. This means that
e.g. a+
will try to match as much characters as possible.
To implement this behavior we first attempt to match REPEAT
s child subtree
as many times as possible, then we move “backwards” calling cont
each time to check if we have a match.
The diagram below illustrates this process:
The code of repeatRec
is:
And generally that’s it. Our simple regex engine.
There are some details left (like handling ^
or $
or
moving startIndex
) but the idea behind the backtracking
matcher should now be familiar to us.
You can find source code for the engine (including tests) on GitHub: https://github.com/marcin-chwedczuk/reng. But before you jump to see the code I really recommend you to write a similar engine (in your favorite language) yourself. This will give you a much more deeper understanding of the algorithm.
Last but not least, our algorithm has a decent performance,
given that we use reasonable regexes and inputs.
A regex like (a+)*c
matched on the input aaaaaaaaaaaaaaaaaaaaaaaaaaaab
will have a very bad performance. This is a common problem
not only in our matcher but in most regex libraries
that use backtracking algorithms. You can
read more about this problem on Wikipedia.


| There are
currently several OFDM system already in operation. Digital Audio
Broadcasting is the longest running system, having started operation in 1996.
It transmits CD quality compress digital audio, replacing the FM broadcast
system. It can transmit 6-10 CD quality channels over a 1.5 MHz system
bandwidth. |
|
| Digital Video
Broadcasting started in operation in Australia in Jan 2001, and will replace
the current analog system by around 2008. It transmits MPEG-2 compress video
at data rates up to 31 Mbps. This is sufficient to support High Definition
Television. |


Try out our Premium Member services: Virtual Legal Assistant, Query Alert Service and an ad-free experience. Free for one month and pay only if you like it.
DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. O R D E R
16.08.13
1. Vide this order I shall dispose of the application filed u/s 245(2) Cr.P.C read with section 258 Cr.P.C filed on behalf of accused no.2 S.P. Gupta seeking his discharge as well as point of framing of notice.
2. The discharge is sought on the ground that there is utter misuse of provisions of law by skipping provisions of Section 33A of the Water (Prevention & Control of Pollution) Act and even before exhausting remedy available under Clauses D (18) & D(19) of the Agreement dated 20.07.05. It is further alleged that there is false allegation in the complaint that the accused society was holding a permission to establish and operate till 26.01.07 and failed to obtain its renewal. It is further alleged that the accused society made a representation to the complainant but without addressing the issues raised therein, the present complaint has been filed against the applicant/accused. It is further alleged that plant is owned and constructed by the Government itself and society is only running the treatment plant. The fresh inspection reports conducted by the department annexed with the present application clearly shows that the discharge of treated water is as per the desired EPA Standards of the complainant. The accused society was never under obligation to obtain, consent from the complainant department for running the plant in question. DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. 1
3. It is DSIDC & DJB which is operating agency and office bearer of the accused society are senior citizens working on honorary basis and is not a beneficiary from this project in any manner. Even the agreement dated 20.07.05 had already expired on 19.07.10. and accused society is no more bound to do anything after the expiry of the said agreement. The representation dated 11.03.11 was submitted with the complainant department to relieve the accused society from its responsibility but of no avail. Even a meeting was held on 18.05.11 with the Commissioner of Industries for the purpose of clarification that no permission is required to the society in view of section 25 of Water (Prevention & Control of Pollution) Act but he refused to give a clarification in writing. Even in accordance with the agreement dated 20.07.05, complainant was to provide space for storage of solid waste latest by 31.12.05 as per serial no.17 of the said agreement but no space was provided. This is willful non performance of the authorities and for the said Act, they should be punished. Instead of taking responsibility, present complaint has been filed maliciously. Even, the complainant maliciously concealed that the appropriate authority had all powers in the agreement dated 20.07.05 to substitute any other NGO for its operation & maintenance if the working of the society was not found satisfactory but no such step was taken.
4. It is further alleged that there is an arbitration clause clause in the agreement dated 20.07.05 and before initiating any prosecution, they were duty bound to invoke the arbitration clause. It was the duty of the DSIDC to take all statutory DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. 2 permission/clearance and to renew the permission, if any, and thus applicant/accused is not responsible for any statutory lapses and is entitled for discharge.
5. Reply to the application was filed denying all the material facts. It is further stated that the application is premature. It is further stated that event the pre charge evidence is not recorded u/s 244 Cr.P.C. It is further stated that under section 245 Cr.P.C, the court is to see only prima facie case on the basis of unrebutted evidence. In the present case, even no evidence was recorded at the presummoning evidence stage, the complainant being government official. Thus, it is stated that in case the application will be allowed, it would amount to recalling the summoning order as nothing material has been brought on record after the stage of summoning except appearance of the accused and accepting them on bail.
6. It is further stated that the accused society is bound by the provisions under 'The Delhi Common Effluent Treatment Plants Rules, 2001 (DCETP Rules). It is further stated that it was the duty of the accused society to manage, maintain, operate the CETP in accordance with the prescribed standard of the various Act including Water (Prevention & Control of Pollution) Act (Water Act) to obtain necessary clearances under the Environment (Protection) Act (E.P. Act), Water Act and Air (Prevention & Control of Pollution) Act (Air Act). It is further stated that in view of the clearcut statutory provisions, the agreement can not and does not override the provisions of the DCETP Act and the DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. 3 DCETP Rules. Moreover, the complainant has never been the party to the alleged agreement and therefore, agreement has no binding effect upon the complainant. It is further alleged that that even the clause 22 of the said agreement makes it clear that it is the responsibility of the accused society to comply various laws applicable to the society and for running the Common Effluent Treatment Plant (CETP). Present complaint was filed because of contravention of provisions u/s 25/26 read with section 44/47/49 of Water Act and u/s 21/22 read with section 37/40/43 of the Air Act and u/s 12/17/19 and 23 of the DECTP Act read with rule 3(4) & (10) of DECTP Rules. Thus, it is prayed that application filed on behalf of accused no.2 is premature and is not maintainable on merits as well and therefore, same is liable to be dismissed.
7. I have given my thoughtful consideration to the submissions advanced on behalf of parties and gone through the records as well as relevant provisions of law. In support of his claim and contentions, the complainant has relied upon the judgment reported in (a) 2011 (3) Crimes 298(All) Allahabad High Court, titled as Madhu Shankar and Ors. Vs State of U.P. And Anr. (b) 2010(4) Crimes 345 (P & H), titled as Sunil Lamba vs. State of Haryana and another.
On the other hand complainant has also placed reliance upon the judgments reported in (a) 1977 CRI. L.J. 1370 in case titled as Hukamichand Devkisen Sarda and others vs Ratanlal Rupchand Heda and others (b) (2009) 1 Supreme Court Cases 407 in case titled as National Small Industries Corporation Ltd. Vs State (NCT of Delhi) and others (c) (2009) 2 Supreme DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. 4 Court Cases 147 in case titled as U.P. Pollution Control Board vs. Dr. Bhupendra Kumar Modi and another (d) AIR 2005 Supreme Court 359 in case titled as State of Orissa vs. Debendra Nath Padhi.
8. Before adverting to the rival submissions of the parties, it would be appropriate to reproduce the relevant provisions i.e. Section 24, 25 & 26 of Water Act, Section 21 & 22 of Air Act, and Section 3(4) & (10) of DCET Rules.
Section 24, 25 & 26 of Water Act.
24. Prohibition on use of stream or well for disposal of polluting matter, etc. (1) Subject to the provisions of this section,
(a) no person shall knowingly cause or permit any poisonous noxious or polluting matter determined in accordance with such standards as may be laid down by the State Board to enter (whether directly or indirectly) into any [stream or well or sewer or on land], or
(b) no person shall knowingly cause or permit to enter into any stream any other matter which may tend, either directly or in combination with similar matters, to impede the proper flow of the water of the stream in a manner leading or likely to lead to a substantial aggravation of pollution due to other causes or of its consequences.
25. Restrictions on new outlets and new discharge - [(1) Subject to this provisions of this section, no person shall, without the previous consent of the State Board,
(a) establish or take any steps to establish any industry, operation or process, or any treatment and disposal system or any extension or addition thereto, which is likely to discharge sewage or trade effluent into a stream or well or sewer or on land (such discharge being hereafter in this section referred to as discharge of sewage); or
(b) begin to make any new discharge of sewage
26. Provision regarding existing discharge of sewage or trade effluent. Where immediately before the commencement of this Act any person was discharging any sewage or trade effluent into a [stream or well or sewer or on land], the provisions of section 25 shall, so far as may be, apply in relation to such person as they apply in relation to the person referred to in that section subject to the notification that the application for consent to be made under sub section (2) of that section [shall be made on or before such date as may be specified by the State Govt. by notification in this behalf in the Official Gazette]. DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. 5 Section 21 & 22 of Air Act
21. Restrictions on use of certain industrial plants. [(1) Subject to the provisions of this section, no person shall, without the previous consent of the State Board, establish or operate any industrial plant in an air pollution control] area.
22. Persons carrying on industry, etc., not to allow emission of air pollutants in excess of the standards laid down by State Board. No person [***] operating any industrial plant, in any air pollution control area shall discharge or cause or permit to be discharged the emission of any air pollutant in excess of the standards laid down by the State Board under clause (g) of sub section (1) of section 17.
Section 3(4) & (10) of DCETP Rules
3.Functions to be performed by CETP Societies under section 4. * *
(iv) To manage, maintain and operate the CEPT In accordance with the prescribed standard of the Environment (Protection) Act, 1986 (29 of 1986), the Water (Prevention and Control of Pollution) Act, 1974 (6 of 1974), and the Air (Prevention and Control of Pollution) Act, 1981 (14 of 1981), * *
(x) To obtain the necessary clearances which are required under the Environment (Protection) Act, 1986, the Water (Prevention and Control of Pollution) Act, 1974, the Air (Prevention and Control of Pollution) Act, 1981 or under any other Act/Rules relevant to the subject.
Further, it is relevant to reproduce the extracts of agreement relied upon by the applicant/accused and complainant. Relevant clause of the agreement are reproduced as below:
17.Sludge management within the CETP and its transport to the temporary hazardous waste storage site will be the responsibility of the CETP Society. The Government shall identify storage temporary site for hazardous waste and ensure it is fully operational by December 31, 2005 and after one year the sludge/hazardous waste will be disposed of at the hazardous waste disposal site/facility.
18.Arbitration Clause: In the even of any dispute arising out of the operation of this agreement, the same shall be settled as follows:
i. One Arbitrator shall be nominated by the Commissioner of Industries ii. One Arbitrator shall be nominated by the Society DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. 6 iii. Two Arbitrators so appointed shall appoint another Arbitrator, whose decision shall be final and binding on all the parties.
22.The Society shall be solely responsible for complying/observing all existing laws like Labour, EPF, Safety regulations etc. as amended time to time.
9. The first contention raised is that the DCET Rules, 2001 was enacted for recovery of dues as arrears of land revenue in respect of the capital and recurring costs of common effluent treatment plants set up in the Industrial Estates in the National Capital Territory of Delhi and thus, there can be no prosecution. However, this contention has no merits. If the entire scheme of the said Rule is read together, it is clear that beside the aforesaid duties, the appropriate authority is bound to check the appropriate functioning of the apparatus, their installation and to give directions time to time to furnish the information for carrying on any industry, operation, process, or treatment and disposal of system including domestic sewage and such direction can be given to any occupier/society/person, officer or authority. Further, if there is non compliance or there is contraventions of provisions of the said Rules that is itself an offence punishable u/s 19 of the said Rules.
10.The next argument is that CETP Society are not bound to apply for consent under the E.P. Act, Water Act and Air Act but it is for the appropriate authority to obtain necessary permission. It is further contended that even in view of the agreement dated 20.07.05, it was the duty of the appropriate authority to obtain necessary permission prior to running any CETP system. However, said contentions are misplaced. Bare perusal of section 3 of the Delhi Common Effluent Treatment Rules, 2001, clearly mandates that it would be the function DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. 7 of CETP Society to obtain the necessary clearances which are required under the E.P. Act, Water Act and Air Act. It would be further the duty of the CETP Society to manage, operate and maintain the CETP in accordance with the standards prescribed in the said Acts.
11.It is settled principle of law that any agreement which is contrary to the statutes is void to the extent it is not in conformity with the provisions of law. There can be no estoppal against statutes. Thus, reliance placed by the applicant/accused upon the agreement dated 20.07.05 is of no help. Further, from the record, it is clear that the present complainant was neither a party nor in any way is connected with the said agreement replied upon by the applicant/accused. Since as per the statutes, it is the duty of the society to obtain necessary clearances, therefore, society can not be relieved from its duties under pretext of agreement.
12.The next argument advanced is that CETP Society is not an industry within the meaning of 2(k) of Air (Prevention & Control of Pollution) Act and therefore, there is no question of discharging untreated effluent. It is further contended that CETP plants run by the society is only discharging the treated effluent and there are report subsequent to the inspection wherein it is clearly mentioned that that there is no discharge of effluent by the accused society. In support of the said contention, applicant/accused has relied upon the 33 reports annexed with the application. So far as the documents annexed are concerned, these documents are in respect of subsequent period. Moreover, even charge has DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. 8 not been framed yet. Therefore, the defence of the accused can not be taken into consideration at this stage. So far as the society being industry or not is concerned, it is clear from the definitions of CEPT Society as provided in section 6 of Delhi Common Effluent Treatment Act, 2000. It has been provided that CEPT Society can be constituted by an Industrial Estate or Industrial Estates in Delhi for performing of such functions including setting up and operating a CETP for the units in such industrial estate or estates. Thus, definition of society makes itself clear that applicant/accused is duty bound to get the effluent treated before its discharge. Thus, by necessary implication, CETP Society is bound to perform the duties which were casted upon industries i.e to discharge the effluent only after its treatment.
13.Next arguments have been advanced that according to rule 23 of Delhi Common Effluent Treatment Rules, 2001, no court shall take cognizance except on the complaint filed on behalf of the appropriate authority and since the present complaint has not been filed on behalf of the appropriate authority i.e Commissioner of Industry or any other officer not below the rank of Joint Director, therefore, present complaint is liable to be dismissed. The said contention is misplaced. Present complaint has been filed by DPCC through Sh. Surender Singh, Environmental Engineer u/s 25/26 read with section 44/47/49 of Water (Prevention & Control of Pollution) Act and u/s 21/22 read with section 37/40/43 of the Air (Prevention & Control of Pollution) Act and u/s 12/17/19 and 23 of the Delhi Common Effluent Treatment Plant Act, 2000 read DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. 9 with rule 3(4) & (10) of the Delhi Common Effluent Treatment Rules, 2001 as well. It is clear from the para no.16 of the complaint that the complainant is the serving Environmental Engineer and thus authorized to sign and prosecute the present complaint which meet out the requirement as prescribed in Water (Prevention & Control of Pollution) Act and Air (Prevention & Control of Pollution) Act for filing of the complaint. Thus, complaint is competent to file the present complaint.
14.Next contention raised is that complaint is premature as no notice u/s 33A of Water Act was given prior to initiating prosecution nor matter was referred for arbitration in view of arbitration clause. So far as arbitration is concerned, that is not binding upon complainant and DPCC is not a party to the contract. Further, by virtue of the provision u/s 33A of Water Act, the appropriate authority is empowered to issue show cause notice for appropriate running of CETP. Lastly, it has been argued that though no precharge evidence is led but in view of provision u/s 45(2) Cr.P.C., present application is maintainable. No doubt, law is settled in this regard. The application us/ 245(2) Cr.P.C is maintainable even prior to precharge evidence. However, in the present case, complaint was filed by the government officer and he was exempted from his examination u/s 200 Cr.P.C. being a public servant. Thus, case is at the stage where it was at the time of summoning as no precharge evidence has been led yet. In view of same, allowing the application u/s 245(2) Cr.P.C will amount to recall of the summoning order at least at this stage. It is respectfully DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. 10 observed that the judgments relied upon by the accused is not applicable to the peculiar facts and circumstances of the present case. In the light of the aforesaid discussions, the application in hand having no merit and appears to have been filed with a view to delay the proceedings. Accordingly, same is dismissed with cost of Rs.10,000/ to be deposited with DLSA.
Put up for precharge evidence on 14.10.13.
(D.K. SHARMA) ACMM (Spl. Acts)/CENTRAL DELHI/16.08.13 DPCC vs M/s GTK Road Industrial Estate CETP Society & Ors. 11


{% extends "base.html" %} {% block title %}
Medieval catalogues > UNIVERSITY AND COLLEGE LIBRARIES OF OXFORD > New College > Indenture of books by John Campeden, 27 August 1401
{% endif %}10 identified entries found.
All data was derived from the List of Identifications by Professor Richard Sharpe.
{% if not printing %}
A key to codes used in the List is available (opens in new tab).{% endif %}


| Home | Libraries | People | FAQ | More |
boost::program_options::untyped_value
// In header: <boost/program_options/value_semantic.hpp> class untyped_value : public boost::program_options::value_semantic_codecvt_helper< char > { public: // construct/copy/destruct untyped_value(bool = false); // public member functions std::string name() const; unsigned min_tokens() const; unsigned max_tokens() const; bool is_composing() const; bool is_required() const; void xparse(boost::any &, const std::vector< std::string > &) const; bool apply_default(boost::any &) const; void notify(const boost::any &) const; };
Class which specifies a simple handling of a value: the value will have string type and only one token is allowed.
untyped_value
public member functionsstd::string name() const;
Returns the name of the option. The name is only meaningful for automatic help message.
unsigned min_tokens() const;
The minimum number of tokens for this option that should be present on the command line.
unsigned max_tokens() const;
The maximum number of tokens for this option that should be present on the command line.
bool is_composing() const;
Returns true if values from different sources should be composed. Otherwise, value from the first source is used and values from other sources are discarded.
bool is_required() const;
Returns true if value must be given. Non-optional value
void xparse(boost::any & value_store, const std::vector< std::string > & new_tokens) const;
If 'value_store' is already initialized, or new_tokens has more than one elements, throws. Otherwise, assigns the first string from 'new_tokens' to 'value_store', without any modifications.
bool apply_default(boost::any &) const;
Does nothing.
void notify(const boost::any &) const;
Does nothing.


A Dress and Costume Competition for the spookiest people in the town.
Inviting all posts to showcase their talent on the occassion of Dussehra.
A competition calling all Chefs to present their dishes on the World Food Day.
To explore the various tourist hot spots of the world and make tourism alive again.
A talk on the immense healing power of Yoga at physical, mental and emotional level.
An hands-on technical webinar to teach the basics of Version Control systems, Git and GitHub.
An event calling all the artists to design posters about Ozone Awareness.
A fund-raising event where we collected 1.1 Lakh rupees to help the people affected by COVID-19.
© Rotaract Club SRM KTR: All Rights Reserved.
by CodeChef SRM
ContactShubhangi SoniNishita Hiresha Verma


On her way she met a copy. The copy warned the Little Blind Text, that where it came from it would have been rewritten a thousand times and everything that was left from its origin would be the word.
A small river named Duden flows by their place and supplies it with the necessary regelialia. It is a paradisematic country, in which roasted parts of sentences fly into your mouth.
On her way she met a copy. The copy warned the Little Blind Text, that where it came from it would have been rewritten a thousand times and everything that was left from its origin would be the word "and" and the Little Blind Text should turn around and return to its own, safe country. But nothing the copy said could convince her and so it didn’t take long until a few insidious Copy Writers ambushed her, made her drunk with Longe and Parole and dragged her into their agency, where they abused her for their
Separated they live in. A small river named Duden flows by their place and supplies it with the necessary regelialia. It is a paradisematic country. A small river named Duden flows by their place and supplies it with the necessary regelialia. It is a paradisematic country, in which roasted parts of sentences fly into your mouth.
A small river named Duden flows by their place and supplies it with the necessary regelialia. It is a paradisematic country, in which roasted parts of sentences fly into your mouth.
Separated they live in. A small river named Duden flows by their place and supplies it with the necessary regelialia. It is a paradisematic country
Far far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts.
Racky Henderson
FatherFar far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts.
Henry Dee
MotherFar far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts.
Mark Huff
MotherFar far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts.
Rodel Golez
MotherFar far away, behind the word mountains, far from the countries Vokalia and Consonantia, there live the blind texts.
Ken Bosh
Mother


At one point, I've heard about Salvia from a high times artical or from a herb shop. I don't remember where I first learned about this powerful substance. My experience with Salvia is unexplainable. I picked up 1 Gram of 5x Salvia. I then loaded half of that gram into my 'Sneak a Toke' pipe, with a brand new screen. I read that Salvia has to be heated up nice and hot, to a point where it is vaporized. I also read that the user builds a tolerance within seconds. So I was determined to do this right the first time. Well, I succeeded.
I sat behind my computer, fired up my bowl with a torch lighter.. And at first pulled on it real slowly to make certain that I vaporized every bit of the Salvia, the inhaled and held the hit for 30+ seconds. Things started feeling strange, but not what I expected. So less than 5sec later, I poured the rest of the Salvia (1/2 Gram - 5x) into my pipe, and fired it up. Thatís when it hit me. It hit me so fast and so hard. I was trying to push the smoke out of my lungs as fast as possible. I felt like I just committed suicide on accident.
From my finger tips, moving up my arms, I felt like my existance was being erased. I can feel myself fighting it as it reached the rest of my body. At that point I felt like I was being torn apart backwards inside of me. Space and Time speeded up as I saw my entire life flash before my eyes before a BIG BANG occured. I felt like I traveled back to a time before I was born, in a place where I felt as I was on a assembly line. And there was God standing over me, constructing my soul. There someone else there too, Satan perhaps? I don't know.
Time shifted again, though I felt as I was in the future, after the time of my death. It felt like storm weather was coming thru, though I could not see clouds or anything. I started hearing cries and screams, when I looked in the direction of all the chaos. I could see people running. They were objects shaped like people but with a deep orange glow, almost the color of fire. I looked to see what they were running from, and I saw a giant hill with this oil liquid looking black stuff coming down it. This liquid had tenticals that was grabbing out and snatching people and pulling them down into the earth.  Hahahah'.
I was so full of fear so I started running away from this black mass. I didn't get away. It grabbed me and then the trip shifted again. I felt like I was in a small dark box like a cage. I was cold and wet, and the air smelled like kerosene. I looked out in one direction, and saw a small bit of light, but It wasn't light. I can't explain it.   At that point all light went away and it was total darkness. I curled up into a ball and started crying. Then out of no where, I hear my moms voice say 'Get up honey, get up now. Hurry!' So, I stood up and ran blindly into the darkness. Brown light started to appear. Then a flash.
I was 4 years old and running to my moms bedroom to hop in bed with her because I was scared and crying. As soon as I jumped in the bed and hid under the covers, she hugged me and said 'Shhhhh'. Within a milisecond I was warm, dry, safe.  The peak of the trip was over. I had a strong headache, and too much to think about. I know other events happend during this trip, though this was all I could remember clearly. Would I use this again? Probably not. Would I worry about getting addicted to this? NO NO NO, not possible.
Experience Reports are the writings and opinions of the individual authors who submit them.
Some of the activities described are dangerous and/or illegal and none are recommended by Erowid.


|
||||||||||
| PREV LETTER NEXT LETTER | FRAMES NO FRAMES |
GeometryReader
for the given file
and imports all the available geometry contained in the file.
GeometryReader
for the given file
and imports all the available geometry contained in the file.
MaterialReader
for the given file
and imports all the available material contained in the file.
MaterialReader
for the given file
and imports all the available material contained in the file.
ModeReader
for the given file
and imports all modes contained in the file.
ModeReader
for the given file and imports
all modes contained in the file.
ModeReader
for the given file and imports
all modes contained in the file.
MeshConnectionReader
for the given file
and imports all the available node connections contained in the file.
MeshConnectionReader
for the given file
and imports all the available node connections contained in the file.
KeyReader
for the given file and imports
all the available groups of node subsets contained in the file.
KeyReader
for the given file and imports
all the available groups of node subsets contained in the file.
equals
method.
SceneListener
, which can later be attached to
Renderable
objects.
ViewingPlatform
of the
SimpleUniverse
and sets a nominal view.
JMeshConnectionPanel
is storing any connections
between the First Mesh
and the Last Mesh
.
MeshConnectionModel
is storing any connections
between the First Mesh
and the Last Mesh
.
ModeCorrelationTableModel
is storing any
connections between the First Mode
and the Last Mode
.
First Mesh
and Last Mesh
are both
consistent.
JMeshPanel
are contained in
the stored nodes.
First Mesh
and Last Mesh
are both
consistent.
MeshModel
are contained in the
stored nodes.
First Mode
, Last Mode
, mass matrices and
JMeshConnectionPanel
are consistent.
First Mode
, Last Mode
, mass matrices and
JMeshConnectionPanel
are consistent.
ModeCorrelationTableModel
is storing any
correlations between the First Mode
and the Last Mode
.
NodeMatrix
has no data.
ModeCorrelationModel
is storing any connections
between the First Mode
and the Last Mode
.
ModeCorrelationModel
is storing any connections
between the First Mode
and the Last Mode
.
ModeCorrelationModel
is storing any correlations
between the First Mode
and the Last Mode
.
ModeCorrelationModel
is storing any correlations
between the First Mode
and the Last Mode
.
JMeshConnectionPanel
is storing any connections
between the First Mesh
and the Last Mesh
.
JMeshConnectionPanel
is storing any connections
between the First Mesh
and the Last Mesh
.
|
||||||||||
| PREV LETTER NEXT LETTER | FRAMES NO FRAMES |


Library: Algorithms
Function
Algorithm that finds the largest subrange in a range of values into which a given value can be inserted without violating the ordering of the values
#include <algorithm> namespace std { template <class ForwardIterator, class T> pair<ForwardIterator, ForwardIterator> equal_range(ForwardIterator start, ForwardIterator finish, const T& value); template <class ForwardIterator, class T, class Compare> pair<ForwardIterator, ForwardIterator> equal_range(ForwardIterator start, ForwardIterator finish, const T& value, Compare comp); }
The equal_range() algorithm performs a binary search on an ordered range to determine where the element value can be inserted without violating the range's ordering. The library includes two versions of the algorithm. The first version uses operator<() to search for the valid insertion range, and assumes that the sequence was sorted using the same ordering. The second version allows you to specify a function object of type Compare, and assumes that Compare was the function used to sort the sequence. The function object must be a binary predicate.
equal_range() returns a pair of iterators, i and j, that define a range containing elements equivalent to value, in other words, the first and last valid insertion points for value. If value is not an element in the container, i and j are equal. Otherwise, i points to the first element not "less" than value, and j points to the first element greater than value. In the second version, the ordering is defined by the comparison object. Formally, equal_range() returns a sub-range [i, j) such that value can be inserted at any iterator k within the range without violating the ordering. Depending upon the version of the algorithm used, k must satisfy one of the following conditions:
!(*k < value) && !(value < *k)
or
comp(*k,value) == false && comp(value, *k) == false
The range [start,finish) is assumed to be sorted. Type T must be LessThanComparable.
equal_range() performs at most 2 * log(finish - start) + 1 comparisons.
// // eqlrange.cpp // #include <algorithm> #include <functional> #include <iostream> #include <vector> int main () { // Typedef for convenience. typedef std::vector<int, std::allocator<int> > vector; vector::value_type arr[] = { 0, 1, 2, 2, 3, 4, 2, 2, 2, 6, 7 }; // Set up a vector. vector v1 (arr, arr + sizeof arr / sizeof *arr); // Try equal_range variants. std::pair<vector::iterator, vector::iterator> p1 = std::equal_range (v1.begin (), v1.end (), 3); std::pair<vector::iterator, vector::iterator> p2 = std::equal_range (v1.begin (), v1.end (), 2, std::less<vector::value_type> ()); // Output results. std::cout << "\nThe equal range for 3 is: " << "(" << *p1.first << " , " << *p1.second << ")" << std::endl; std::cout << "\nThe equal range for 2 is: " << "(" << *p2.first << " , " << *p2.second << ")" << std::endl; return 0; } Program Output
The equal range for 3 is: (3 , 4) The equal range for 2 is: (2 , 3)
binary_function, lower_bound(), upper_bound()
ISO/IEC 14882:1998 -- International Standard for Information Systems -- Programming Language C++, Section <IP_ADDRESS>


{% extends "special-pagelist.html" %} {% block message %}
Here is a list of pages with at least one broken link in them. A broken link is a link to a missing page.
No broken links!


Hardware
Figure 1 describes the data flow of DistributedLog. Write traffic comes to Write Proxy and the data is replicated in RF (replication factor) ways to BookKeeper. BookKeeper stores the replicated data and keeps the data for a given retention period. The data is read by Read Proxy and fanout to readers.
In such layered architecture, each layer has its own responsibilities and different resource requirements. It makes the capacity and cost model much clear and users could scale different layers independently.
Metrics
There are different metrics measuring the capability of a service instance in each layer (e.g a write proxy node, a bookie storage node, a read proxy node and such). These metrics can be rps (requests per second), bps (bits per second), number of streams that a instance can support, and latency requirements. bps is the best and simple factor on measuring the capability of current distributedlog architecture.
Write Proxy
Write Proxy (WP) is a stateless serving service that writes and replicates fan-in traffic into BookKeeper. The capability of a write proxy instance is purely dominated by the OUTBOUND network bandwidth, which is reflected as incoming Write Throughput and Replication Factor.
Calculating the capacity of Write Proxy (number of instances of write proxies) is pretty straightforward. The formula is listed as below.
Number of Write Proxies = (Write Throughput) * (Replication Factor) / (Write Proxy Outbound Bandwidth)
As it is bandwidth bound, we'd recommend using machines that have high network bandwith (e.g 10Gb NIC).
The cost estimation is also straightforward.
Bandwidth TCO ($/day/MB) = (Write Proxy TCO) / (Write Proxy Outbound Bandwidth) Cost of write proxies = (Write Throughput) * (Replication Factor) / (Bandwidth TCO)
CPUs
DistributedLog is not CPU bound. You can run an instance with 8 or 12 cores just fine.
Memories
There's a fair bit of caching. Consider running with at least 8GB of memory.
Disks
This is a stateless process, disk performances are not relevant.
Network
Depending on your throughput, you might be better off running this with 10Gb NIC. In this scenario, you can easily achieves 350MBps of writes.
BookKeeper
BookKeeper is the log segment store, which is a stateful service. There are two factors to measure the capability of a Bookie instance: bandwidth and storage. The bandwidth is majorly dominated by the outbound traffic from write proxy, which is (Write Throughput) * (Replication Factor). The storage is majorly dominated by the traffic and also Retention Period.
Calculating the capacity of BookKeeper (number of instances of bookies) is a bit more complicated than Write Proxy. The total number of instances is the maximum number of the instances of bookies calculated using bandwidth and storage.
Number of bookies based on bandwidth = (Write Throughput) * (Replication Factor) / (Bookie Inbound Bandwidth) Number of bookies based on storage = (Write Throughput) * (Replication Factor) * (Replication Factor) / (Bookie disk space) Number of bookies = maximum((number of bookies based on bandwidth), (number of bookies based on storage))
We should consider both bandwidth and storage when choosing the hardware for bookies. There are several rules to follow: - A bookie should have multiple disks. - The number of disks used as journal disks should have similar I/O bandwidth as its INBOUND network bandwidth. For example, if you plan to use a disk for journal which I/O bandwidth is around 100MBps, a 1Gb NIC is a better choice than 10Gb NIC. - The number of disks used as ledger disks should be large enough to hold data if retention period is typical long.
The cost estimation is straightforward based on the number of bookies estimated above.
Cost of bookies = (Number of bookies) * (Bookie TCO)
Read Proxy
Similar as Write Proxy, Read Proxy is also dominated by OUTBOUND bandwidth, which is reflected as incoming Write Throughput and Fanout Factor.
Calculating the capacity of Read Proxy (number of instances of read proxies) is also pretty straightforward. The formula is listed as below.
Number of Read Proxies = (Write Throughput) * (Fanout Factor) / (Read Proxy Outbound Bandwidth)
As it is bandwidth bound, we'd recommend using machines that have high network bandwith (e.g 10Gb NIC).
The cost estimation is also straightforward.
Bandwidth TCO ($/day/MB) = (Read Proxy TCO) / (Read Proxy Outbound Bandwidth) Cost of read proxies = (Write Throughput) * (Fanout Factor) / (Bandwidth TCO)


You should not be seeing a red line in this example, since it should be covered by a green line in the same location.
If the cyan point is located on the green line, this gives you access to conics which touch a given tangent in a given point of contact.


Glorify the Lord, all you works of the Lord, *
praise him and highly exalt him for ever.
In the firmament of his power, glorify the Lord, *
praise him and highly exalt him for ever.
Glorify the Lord, you angels and all powers of the Lord, *
O heavens and all waters above the heavens.
Sun and moon and stars of the sky, glorify the Lord, *
praise him and highly exalt him for ever.
Glorify the Lord, every shower of rain and fall of dew, *
all winds and fire and heat.
Winter and summer, glorify the Lord, *
praise him and highly exalt him for ever.
Glorify the Lord, O chill and cold, *
drops of dew and flakes of snow.
Frost and cold, ice and sleet, glorify the Lord, *
praise him and highly exalt him for ever.
Glorify the Lord, O nights and days, *
O shining light and enfolding dark.
Storm clouds and thunderbolts, glorify the Lord, *
praise him and highly exalt him for ever.
Let the earth glorify the Lord, *
praise him and highly exalt him for ever.
Glorify the Lord, O mountains and hills, and all that grows upon the earth, *
praise him and highly exalt him for ever.
Glorify the Lord, O springs of water, seas, and streams, *
O whales and all that move in the waters.
All birds of the air, glorify the Lord, *
praise him and highly exalt him for ever.
Glorify the Lord, O beasts of the wild, *
and all you flocks and herds.
O men and women everywhere, glorify the Lord, *
praise him and highly exalt him for ever.
Let the people of God glorify the Lord, *
praise him and highly exalt him for ever.
Glorify the Lord, O priests and servants of the Lord, *
praise him and highly exalt him for ever.
Glorify the Lord, O spirits and souls of the righteous, *
praise him and highly exalt him for ever.
You that are holy and humble of heart, glorify the Lord, *
praise him and highly exalt him for ever.
Let us glorify the Lord: the Father, the Son, and the Holy Spirit; *
praise him and highly exalt him for ever.
In the firmament of his power, glorify the Lord, *
praise him and highly exalt him for ever.


Once diceroll.py is installed and your code is able to import the module, its roll() function can be used right away. This function returns an integer, by the way. So it can be used as any other integer would be used. But first, we must give this function a value to work from.
Those of you that have used dice rolling programs before will notice that something is different. And that is, roll() uses a string for its input:
>>> die1 = roll('1D6')
>>> die2 = roll('1d6')
>>> dice = '3D4+1'
>>> print die1, die2+4, roll(dice)
3, 6, 9
The return values from roll() are always integer.
New in version 2.2
Notice that the inputted string values can be upper or lower case.
The dice types to roll are:
D3, D4, D6, D8, D10, D12, D20, D30, D100, D66, DD, FLUX, GOODFLUX, and BADFLUX
New in version 2.3
Three additional dice types are now available:
BOON, BANE, and D2
Note
You may recognize some of these dice types from various tabletop role-playing games. Not all dice types are covered by diceroll. However, more are planned for in future releases.
diceroll uses a simple standard when it comes to rolling various dice types.

D00 has been replaced with D100.
New in version 2.4
diceroll can now be used directly at a CMD prompt:
C:\>diceroll.py roll('2d6-2') Your 2D6-2 roll is 10. C:\>diceroll.py 2d6-2 Your 2D6-2 roll is 7.
Note
Typing diceroll.py -h will provide some help.
New in release 2.4.1
A TEST roll that calculates percentages for 2D6 has been added:
>>> roll('test')
6x6 Roll Chart Test
1 2 3 4 5 6
1 262 296 250 292 292 241
2 270 315 299 236 279 261
3 295 274 288 274 291 295
4 273 284 279 276 249 273
5 293 280 291 276 280 283
6 270 276 282 272 273 280
6x6 Roll Chart Percentage
1 2 3 4 5 6
1 2.62% 5.66% 8.60% 11.38% 13.93% 16.23%
2 5.66% 8.60% 11.38% 13.93% 16.23% 13.95%
3 8.60% 11.38% 13.93% 16.23% 13.95% 11.02%
4 11.38% 13.93% 16.23% 13.95% 11.02% 8.25%
5 13.93% 16.23% 13.95% 11.02% 8.25% 5.56%
6 16.23% 13.95% 11.02% 8.25% 5.56% 2.80%
The roll will return a list of percentages for 2-12 rolled.
New in release 2.4.2
D09 rolls will generate a range of 0 - 9.
New in release 2.4.3
D99 rolls will generate a range of 0 - 99.
Fixed in release 2.4.7
Minor fixes with input spacing, and logging any negative dice rolled.
New in version 3.0
D2 rolls now generate a range of 0 - 1. The 4dF roll type for FATE has been added.
New in version 3.1
1D thru 10D rolls for Traveller5 have been added. Now with DM support.


Home
Analytics
Upload
(current)
Search
Energy
Waste
(current)
Food
Nature
Solid Waste Reduction
Have you recycled any sort of materials?
Yes
No
If so, what materials and how much? (ex. plastic bottles: 20 or by the amount of money earned)
Have you reused any sort of items (containers, boxes, etc.)?
Yes
No
If so, what materials and how much?
Have you reduce the usage of anything? (ex. instead of buying boxes of plastic bottles, boil water)
Yes
No
If so, what materials and how much?


High performance, high class web development for Node.js
migrate
Express 1.x is written to run on-top of the Connect middlware framework, thus the Plugin has been replaced by Connect's middleware. By abstracting our middleware to Connect we allow additional community frameworks to develop robust, high-level frameworks using the same technologies as Express.
Previously due to legacy code implemented in the early days of node, Express unfortunately had some globals. The DSL would previously be accessed as shown below:
require('express');
configure(function(){
// app configuration
});
get('/', function(){
return 'hello world';
});
Now we utilize the CommonJS module system appropriately, and introduce express.createServer() which accepts the same arguments as http.createServer():
var express = require('express'),
app = express.createServer();
app.configure(function(){
// app configuration
});
app.get('/', function(req, res){
res.send('hello world');
});
Express 1.x does not currently allow returning of a string.
Previously Express was bundled with plugins, which were essentially what are now Connect middleware. Previously plugins would be utilized in a manor similar to below:
use(Logger);
use(MethodOverride);
use(Cookie);
Which we can now use() within our app, or pass to the express.createServer() method:
var app = express.createServer(
express.logger(),
express.methodOverride(),
express.cookieDecoder()
);
or:
var app = express.createServer();
app.use(express.logger());
app.use(express.methodOverride());
app.use(express.cookieDecoder());
For documentation on creating Connect middleware visit Middleware Authoring.
Previously a global function run(), was available:
run();
The new express.Server has the same API as http.Server, so we can do things like:
app.listen();
app.listen(3000);
Previously we could use this.param() to attempt fetching a route, query string, or request body parameter:
get('/user/:id', function(){
this.param('id');
});
Polymorphic parameter access can be done using req.param()
:
app.get('/user/:id', function(req, res){
req.param('id');
});
Route parameters are available via req.params
:
app.get('/user/:id', function(req, res){
req.params.id;
});
Old express had a weak notion of route passing, which did not support async, and was never properly implemented for practical use:
get('/', function(){
this.pass('/foobar');
});
Now Express has access to Connect's next() function, which is passed as the third and final argument. Calling next() will pass control to the next matching route, or continue down the stack of Connect middleware.
app.get('/user/:id?', function(req, res, next){
next();
});
app.get('/user', function(){
// ... respond
});
View filenames no longer take the form Express.TYPE.ENGINE, the Content-Type can be set via res.contentType() or res.header(). For example what was previously layout.html.haml, should now be layout.haml.
Previously a view render looked something like this:
get('/', function(){
this.render('index.html.haml', {
locals: { title: 'My Site' }
});
});
We now have res.render(), however the options passed to haml, jade, and others remain the same.
app.get('/', function(req, res){
res.render('index.haml', {
locals: { title: 'My Site' }
});
});
Previously rendering of a collection via partial() would look something like this:
this.partial('comment.html.haml', { collection: comments });
Although this worked just fine, it was generally to verbose, the similar but new API looks like this, as partial() is always passed as a local variable:
partial('comment.haml', { collection: comments });
To make things even less verbose we can assume the extension when omitted:
partial('comment', { collection: comments });
And once again even further, when rendering a collection we can simply pass an array, if no other options are desired:
partial('comments', comments);
Previously you would
this.redirect('/somewhere');
However you would now:
res.redirect('/somewhere');
res.redirect('/somewhere', 301);
Previously Express provided a high level http client, this library is no more as it does not belong in Express, however it may be resurrected as a separate module.
Express is no longer dependent on the JavaScript Extensions library, so those of you using the methods provided by it such as Object.merge(a, b)
will need to
roll your own, or install the module via:
$ npm install ext


Only call a function once.
var once = require('once')
function load (file, cb) {
cb = once(cb)
loader.load('file')
loader.once('load', cb)
loader.once('error', cb)
}
Or add to the Function.prototype in a responsible way:
// only has to be done once
require('once').proto()
function load (file, cb) {
cb = cb.once()
loader.load('file')
loader.once('load', cb)
loader.once('error', cb)
}
Ironically, the prototype feature makes this module twice as complicated as necessary.
To check whether you function has been called, use fn.called
. Once the
function is called for the first time the return value of the original
function is saved in fn.value
and subsequent calls will continue to
return this value.
var once = require('once')
function load (cb) {
cb = once(cb)
var stream = createStream()
stream.once('data', cb)
stream.once('end', function () {
if (!cb.called) cb(new Error('not found'))
})
}


This page contains a couple of HTML forms that GET and POST to the REST API provided by your project.
These forms let you interact with the simple dictionary REST API that is created by the project archetype.
List all Phone calls
List the phone calls
Customer Name
Start Time
End Time
Create a PhoneCall
Customer Name
Caller Phone Number
Callee Phone Number
Start Time of the Call
End Time of the Call


Warehouse Keeper Carlon: You don't have to carry unnecessary items with you anymore! Just deposit them here with us, and we will safely and efficiently deliver them to the person you designate, wherever they may be! It's so easy, you can't afford not to use our freight services!


The trouble with Bob
Date: 10th of September, 2011
Alice
The trouble with Bob is that he takes much better photos than I do:
Beautiful Sunset by Bob.
Jo’s Barbecue
Date: 14th of September, 2011
Eve
…
I will post my photos nevertheless…
Date: 15th of September, 2011
Alice
…


Instructions
| Difficulty | Speed | Click or Press Keys |
|---|---|---|
| 1-column | Slowest | a |
| 2-column | Slowest | a s |
| Easy | Slowest | a s d |
| Medium | Medium | a s d f |
| Hard | Fastest | a s d f g |
The difference in difficulty changes the frequency of note generation.
| Song Mode | Guitar Mode |
|---|---|
| Play to your choice of song! | Play your own guitar notes! |


GrDrawRect(), GrDrawRectTo(), GrFillRect(), GrFillRectTo()
Rectangles are defined by four coordinates which can be thought of as either defining the rectangle's left, top, right, and bottom bounds or as specifying two opposite corners of the rectangle.
GrDrawRect()
draws the outline of a rectangle using the passed coordinates.
GrDrawRectTo()
draws the outline of a rectangle using the current pen position as one of the defining points; the pen position is unchanged by this operation. These functions draw the rectangle outline using the current line attributes.
GrFillRect()
draws a filled rectangle defined by the passed coordinates.
GrFillRectTo()
fills a rectangle of which the pen position is one corner.
GrFillRect()
and
GrFillRectTo()
use the GState's area attributes. They do not draw a border around the rectangle; if you want a bordered rectangle, call
GrFillRect()
and follow it with
GrDrawRect()
. Note that if the order of these operations if reversed, the fill may obscure the draw.


{% seo %}
What is my risk of getting COVID-19 in Canada?:
COVID-19 is a serious health threat, and the situation is evolving daily. The risk will vary between and within communities, but given the increasing number of cases in Canada, the risk to Canadians is considered high. This does not mean that all Canadians will get the disease. It means that there is already a significant impact on our health care system. If we do not flatten the epidemic curve now, the increase of COVID-19 cases could impact health care resources available to Canadians. We continue to reassess the public health risk based on the best available evidence as the situation evolves.
While COVID-19 can make anyone sick, some Canadians with specific health circumstances are at an increased risk of more severe outcomes, including individuals:
In addition, social and economic circumstances may also be a factor in identifying someone who is vulnerable to COVID-19. This includes anyone who has:
How can I protect myself from getting COVID-19?:
Canadians should continue to think ahead about the actions that they can take to stay healthy and prevent the spread of COVID-19 in Canada. This includes staying at home as much as possible and being prepared in case you or a family member becomes ill. Everyone should be practising physical (social) distancing. Even if you do not have symptoms of COVID-19, you could become infected by others. As we continue to see transmission of the virus within different communities, we know that everyone must take precautions, even those who have not travelled outside of Canada.
In an effort to prevent the spread of COVID-19 within communities and across the country, all Canadians are advised to:
You can go for a walk if you:
If you go out for a walk, do not congregate and always practise physical (social) distancing by keeping at least 2 metres apart from others at all times.
What is physical (social) distancing and how does it help to minimize COVID-19?:
Together, we can slow the spread of COVID-19 by making a conscious effort to keep a physical distance between each other. Physical (social) distancing is proven to be one of the most effective ways to reduce the spread of illness during an outbreak.
This means making changes in your everyday routines to minimize close contact with others, including:


| OptionParser-class {optparse} | R Documentation |
Option Parser
usage
The program usage message that will printed out if
parse_args
finds a help option, %prog
is substituted with the
value of the prog
argument.
options
A list of of OptionParserOption
instances that will
define how parse_args
reacts to command line options.
OptionParserOption
instances are usually created by make_option
and can also be added to an existing OptionParser
instance via the
add_option
function.
description
Additional text for print_help
to print out between
usage statement and options statement
epilogue
Additional text for print_help
to print out after
the options statement
Trevor Davis.


One privilege escalation method requires the "storage.buckets.setIamPolicy" permission.
A vulnerable bucket policy might look something like this:
{"bindings":[{"members":["allAuthenticatedUsers","projectEditor:my-test-project","projectOwner:my-test-project"],"role":"roles\/storage.legacyBucketOwner"},{"members":["projectViewer:my-test-project"],"role":"roles\/storage.legacyBucketReader"},{"members":["projectEditor:my-test-project","projectOwner:my-test-project"],"role":"roles\/storage.legacyObjectOwner"},{"members":["projectViewer:my-test-project"],"role":"roles\/storage.legacyObjectReader"}],"etag":"ROQ="}
Ignoring most of what is defined in this policy, we can see that the “allAuthenticatedUsers” group is a member of the role “roles/storage.legacyBucketOwner”. If we look at what permissions that role is granted, we see the following:
- storage.buckets.get
- storage.buckets.getIamPolicy
- storage.buckets.setIamPolicy
- storage.buckets.update
- storage.objects.create
- storage.objects.delete
- storage.objects.list
This means that we can read (storage.buckets.getIamPolicy) and write (storage.buckets.setIamPolicy) to the buckets policy and we can create, delete, and list objects within the bucket.
Note that we see the same information by visiting this URL: https://www.googleapis.com/storage/v1/b/BUCKET_NAME/iam/testPermissions?permissions=storage.buckets.delete&permissions=storage.buckets.get&permissions=storage.buckets.getIamPolicy&permissions=storage.buckets.setIamPolicy&permissions=storage.buckets.update&permissions=storage.objects.create&permissions=storage.objects.delete&permissions=storage.objects.get&permissions=storage.objects.list&permissions=storage.objects.update
(note that the “storage.objects.getIamPolicy” and “storage.objects.setIamPolicy” permissions are omitted because they will throw an error on any bucket that is setup to disable object-level permissions. For buckets that enable object-level permissions, those values can be included).
If we look at the permissions granted by the Storage Admin role instead, we can see that it grants these privileges:
- firebase.projects.get
- resourcemanager.projects.get
- resourcemanager.projects.list
- storage.buckets.create
- storage.buckets.delete
- storage.buckets.get
- storage.buckets.getIamPolicy
- storage.buckets.list
- storage.buckets.setIamPolicy
- storage.buckets.update
- storage.objects.create
- storage.objects.delete
- storage.objects.get
- storage.objects.getIamPolicy
- storage.objects.list
- storage.objects.setIamPolicy
- storage.objects.update
There are more privileges granted to this role than the role “allAuthenticatedUsers” is a member of, so why don’t we change that?
With the “gsutil” Google Storage CLI program, we can run the following command to grant “allAuthenticatedUsers” access to the “Storage Admin” role, thus escalating the privileges we were granted to the bucket:
gsutil iam ch group:allAuthenticatedUsers:admin gs://BUCKET_NAME
Now if we look at the bucket policy again, we can see the following added to it (because the “ch” command appends instead of overwrites to the policy):
{"members":["group:allAuthenticatedUsers"],"role":"roles\/storage.admin"}
And just like that, we have escalated our privileges from a Storage Legacy Bucket Owner to a Storage Admin on a bucket that we don’t even own!
One of the main attractions to escalating from a LegacyBucketOwner to Storage Admin is the ability to use the “storage.buckets.delete” privilege. In theory, you could delete the bucket after escalating your privileges, then you could create the bucket in your own account to steal the name.
Now, if we review the privileges we are granted with the TestIamPermissions API again, we see that a few extras are added from the new role we used. Note that not all the privileges allowed by that role will be listed when using the TestIamPermissions API (such as resourcemanager.projects.list) because not all the permissions are Google Storage specific permissions and aren’t supported by the API.


# -*- coding: utf-8 -*- <% roles = [] if c.user and 'groups' in c.user and c.user['groups']: for g, p in c.user['groups']: roles.append(p) %>


Attractive valuation: Buy
by CSL StockbrokersZenith’s numbers in 9M 2019 showed a decline in yield on Loans to customers and on money market instruments. On the positive side, funding cost continues to improve, declining to 2.95% from 3.3% in 9M 2018.
Despite a steep decline in Non-Interest Income in Q3 relative to Q2 2019, Non-Interest Income growth continues to support the bank’s y/y growth in profit.
Zenith’s 9M annualised Return on Average Equity (ROAE) of 23.8% compares with our revised estimate of 22.6% for FY 2019 and with 23.7% for FY 2018. Capital Adequacy Ratio (CAR) of 23.8% (without the full impact of IFRS 9; we estimate 21.9% for FY 2019e post adjustment for IFRS transition) remains comfortably above current regulatory minimum of 15.0%.
Reported liquidity ratio of 63.8% is well above those of many of its peers. The bank also reports healthy asset quality ratios with annualised Cost of Risk (COR) of 1.1%.
The bank still rates well based on capital adequacy, sustainable long-term dividend yield, and stable asset quality. We retain our Buy recommendation on Zenith with a revised target price of N34.24/s from N33.41/s previously (current price: 17.35/s). Trading at 0.63x book value, valuations appear attractive. Based on our assumption of N2.80/s dividend for 2019e, dividend yield comes to 16.1% at current levels.
[READ MORE: Oil: International oil companies scale down on Nigeria operations]
Profitability
9M 2019 Interest Income was down 5.1% y/y but up 16.5% q/q (Q3 compared to Q2). The y/y decline was attributed to a decline in yields on both money market instruments and on Loans and Advances to customers. We attribute the Q/q growth in Interest Income to the strong loan growth in Q3. The bank’s Net Loans to customers were up 13.4% within the quarter, bringing 9M Net Loan growth to 12.1%.
Interest Expense was also down 2.9% y/y despite a 6.6% y/y growth in Interest Bearing Liabilities, resulting in an improvement in Cost of Funds to 2.95% in Q3 2019 compared with 3.3% in Q3 2018. The bank’s funding cost has been declining gradually since the spike in 2017-according to management, this has been supported largely by a re-balancing of the bank’s deposit mix in favour of cheaper retail deposits.
Overall, Net Interest Income was down 6.1% and NIMs declined to 8.69% in 9M 2019 compared to 9.6% in 9M 2018.
PBT grew 5.3% y/y and 18.6% q/q while Net profit was up 4.5% y/y. The bank’s annualised Return on Average Equity (ROAE) of 23.8% compares with 23.7% for FY 2018. We forecast FY 2019e RoAE of 22.6%.
Loans and advances
The bank’s Net Loans to customers were up 13.4% in Q3 quarter, bringing 9M loan growth to 12.1%. We model 2019e loan growth of 15.1% in line with management’s guidance. As at 9M 2019, we compute gross loan to total funding of 51.5% for the Nigerian bank without taking into consideration the effect of the 1.5% weighting on SMEs, Retail, Mortgage and Consumer loans and without adding investment securities such as corporate and state government bonds to gross loans.
Deposit growth
Customer Deposits were up 21% y/y but are only up 7.1% year to date. We believe banks will not be so keen on increasing deposits given CBN’s minimum LDR of 65% by December 2019. Consequently, we assume 8.0% deposit growth for FY 2019e compared with Management’s 10% guidance.
Update on asset quality
The bank reported relatively healthy asset quality ratios. Impairment charge was up 27.3% y/y but declined in Q3 compared to Q2. We highlight that the bank’s Impairment charge was up significantly in Q2 compared to Q1. The bank’s 9M annualised Cost of Risk (COR) of 1.14% was significantly higher than our previous 0.8% assumption for FY 2019e. We have revised our COR assumption for FY 2019e to 1.2% considering the strong loan growth and expected increase in expected credit loss. Non-Performing Loan ratio of 4.95% and coverage ratio of 148% appears a strong buffer.
_____________________________________________________________________
CSL STOCKBROKERS LIMITED CSL Stockbrokers,
Member of the Nigerian Stock Exchange,
First City Plaza, 44 Marina,
PO Box 9117,
Lagos State,
NIGERIA.


This iframe has a width of 200px. It contains a document body with a column-width of 200px, that is translateX'ed -200px. So it should be showing the second column, but it is blank in latest Webkit nightlies.
Try changing the translateX to -199px: the second column is suddenly visible.