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
import React from 'react'; | |
import PropTypes from 'prop-types'; | |
import { Document, Page } from 'react-pdf'; | |
import { AutoSizer, List, WindowScroller } from 'react-virtualized'; | |
class PdfViewer extends React.Component { | |
constructor(props) { | |
super(props); | |
this.state = { |
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
html, body { | |
margin : 0px; | |
padding: 0px; | |
width: 100%; | |
height: 100%; | |
overflow-x: hidden; | |
} | |
.first-section, .second-section { | |
background-color: #f6f6f6; |
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
<!doctype html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<link rel="stylesheet" href="style.css" type="text/css"> | |
</head> | |
<body> | |
<header class="background"> </header> | |
<section class="first-section"> |
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
package com.example; | |
class PhysicsTeacher implements Teacher { | |
private String subject; | |
public PhysicsTeacher() { | |
this.subject = "Physics"; | |
} |
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
package com.example; | |
class PhysicsStudent implements Student { | |
private String description; | |
public PhysicsStudent() { | |
this.description = "I am a student who studies physics!"; | |
} |
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
package com.example; | |
import com.google.inject.Injector; | |
import com.google.inject.Guice; | |
public class Main { | |
public static void main(String[] args) { | |
Injector injector = Guice.createInjector(new PhysicsClassroomModule()); |
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
package com.example; | |
import com.google.inject.AbstractModule; | |
public class PhysicsClassroomModule extends AbstractModule { | |
@Override | |
protected void configure() { | |
bind(Student.class).to(PhysicsStudent.class); | |
bind(Teacher.class).to(PhysicsTeacher.class); |
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
package com.example; | |
import javax.inject.Inject; | |
class Classroom { | |
private Student student; | |
private Teacher teacher; | |
@Inject |
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
package com.example; | |
interface Teacher { | |
public String 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
package com.example; | |
interface Student { | |
public String getDescription(); | |
} |
NewerOlder