This file contains hidden or 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
>Intorduction | |
This module will consist of following | |
1) methods, Filters and Operators for Reading Data | |
2) query selector | |
3) Projection operator | |
>Operators | |
All command include a db.collectionName.MethodName({-parameter-}) | |
parameter can be key value pair or it could be a Range | |
db.collectionName.MethodName({key:{$operator:value}}) |
This file contains hidden or 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
> Introduction | |
This module based on data creating , Data can be crated on mongodb , or it can be imported from other source | |
We will learn about insert method and different ways of importing data into mongo DB | |
> Insert methods | |
ther eare 3 mthods | |
1 ) insertOne({}) this will take one documetns | |
2 ) insertMany({}) this tail ltake multiple documents | |
3 ) insert() It takes both single/ multiple documents |
This file contains hidden or 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
> Introductions | |
when working with project we need to find what kind of structure of our data, what will be ralation between our data | |
We will udnerstand ducuments and other types of data | |
we a will also look into diffreent type of relation, And we will Validate the Data [Schema validation] | |
>Schema | |
Mongo DB supposed to be a schemaless DB but why there is a schema, well MongoDB do not enforce schema as | |
it is enforced by RELATIONAL database. hance creating a schema is an option and as per developers need | |
It is totally developer oriented we can follow any approch, we can forefully insert value by assigninign | |
null to that extra field |
This file contains hidden or 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
> intorductioon | |
mongod is a database server , this should be up and running | |
mongod --port = PORT will be running mongo server on perticular server | |
mongo is a mongoDB shell , this is used to do all mongo operation , thought we haave DRIVERS for all kind of platform | |
Shell command are almost similar as JAVAscript driver for nodejs | |
show dbs > show databases | |
use DataBase_name > create a database | |
db.collectionName.insertOne({JSON_Document}) > create a collection and inserting a document into it |
This file contains hidden or 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
> Why agnular forms : | |
Angualr form gives key-value object of a form which can be used for multiple purpose . | |
Agnular also give a metadata related to forms. | |
In traditional HTML form we have action="somefunction()" and method="get!post" , but when we use it with angular we do not specify | |
anything to angular, angular itself treat <form> as some kind of directive|compoenent and act on it using formsModule. | |
> Types of angular forms | |
Template Driven From : in this template is fixed and form element is accessed on TS {So angular infer form from DOM side} | |
Reactive Form : in this form configuration is done on TS file Also on TEMPLATE side {form created dynamically and synced with DOM} |
This file contains hidden or 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
>Services | |
Services are used to share common logic among set ot multiple component. | |
So a Service can containe a buisness logic or it can containe call to API | |
Services can be used for [logging], for [Data storage]. | |
>Adding service | |
To added service we need to load the service into constructor and to Providers array in @Component({}) directive | |
>Hirachical Injector |
This file contains hidden or 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
>introduction Directive | |
Attribute and Structural directive | |
[No Dom change] [Dom Change] | |
Why cant we add multiple directive on same element like we can not use ngIf and ngFor on same element | |
> Gettting started with Directive | |
create a class with @Directive Devorator and [selector] as a paramter to decorator | |
using elementRef to change to style of an element | |
Note: Remember changing element style using [element.nativeElement.style.backgrroundColor] may not be available because Angular can render |
This file contains hidden or 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
> property and event binding | |
In angular property and event binding is used to transfer data acreoss compoenent | |
This is the best approch for transferring data | |
if sender and reciever compomenet are very far then we can use observable seream using a data sharing service | |
@input() and @output() property decorators are used to pass data arround | |
> View Encapsulation | |
In angular a compoenent is associated with a SCSS file which is very specefic to that acompoenent . | |
but commmon CSS behaviour does not work like that It apply CSS to all element of that file. |
This file contains hidden or 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
using System; | |
using System.Collections.Generic; | |
class MyClass { | |
static void Main(string[] args) { | |
string[] ip = Console.ReadLine().Trim().Split(' '); | |
long a = Convert.ToInt64(ip[0]); | |
long b = Convert.ToInt64(ip[1]); | |
Console.Write(commDiv(a,b)); | |
This file contains hidden or 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
Debris:Construction Debris | |
Caddies: Someone who lift golf bag, kind of helper | |
Wager: synonym for bet | |
Sprawls: Land spred arround | |
Debilitate : makeing someone weak [many hard drungs are debilitating society ] |