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
scala> val line = "hello World" | |
line: String = hello World | |
scala> val list = List(line) | |
list: List[String] = List(hello World) | |
scala> val rdd = sc.parallelize(list) | |
rdd: org.apache.spark.rdd.RDD[String] = ParallelCollectionRDD[0] at parallelize at <console>:28 |
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
@NgModule({ | |
declarations: [ | |
AppComponent, | |
PreDemonstrationComponent | |
], | |
imports: [ | |
BrowserModule, HttpClientModule, FormsModule, NgxPaginationModule | |
], | |
providers: [ParameterListService], | |
bootstrap: [AppComponent] |
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
<div *ngFor = "let questions of questionList | paginate: {itemPerPage: 5, currentPage: p}"> | |
<div> | |
{{questions}} | |
</div> | |
</div> |
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
<pagination-controls (pageChange) = "p = $event" | |
previousLabel = "Previous" | |
nextLabel = "Next" | |
directionLinks = "true" | |
autoHide = "true"> | |
</pagination-controls> |
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
<dependency> | |
<groupId>org.apache.commons</groupId> | |
<artifactId>commons-lang3</artifactId> | |
<version>3.8.1</version> | |
</dependency> |
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
{ | |
"sub": "123456789 | |
"name": "Jack", | |
"admin": true | |
} |
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
{ | |
"alg": "HS256", | |
"typ": "JWT" | |
} |
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
Jwts.builder() | |
.setSubject("") | |
.signWith(HS512, new SecretKeySpec(parseBase64Binary("Bhawna"), HS512.getJcaName())) | |
.setIssuedAt(new Date()) | |
.setExpiration(addSeconds(new Date(), 80)) | |
.compact(); |
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
Jwts.parser() | |
.setSigningKey(new SecretKeySpec(parseBase64Binary("Bhawna"), HS512.getJcaName())) | |
.parseClaimsJws(token) | |
.getBody() | |
.getSubject(); |
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
<dependency> | |
<groupId>com.couchbase.client</groupId> | |
<artifactId>java-client</artifactId> | |
<version>2.5.4</version> | |
</dependency> |
OlderNewer