Skip to content
Snippets Groups Projects
Verified Commit 5184500e authored by Matthew Wang's avatar Matthew Wang
Browse files

Fix invalid CSS, resolve all `javac` warnings

parent b29f901e
No related branches found
No related tags found
No related merge requests found
Pipeline #575984 passed
*.class *.class
.DS_Store .DS_Store
*.html
import java.util.Arrays; import java.util.Arrays;
import java.util.stream.Stream;
import java.util.List; import java.util.List;
import java.util.stream.Collectors; import java.util.stream.Collectors;
import java.lang.reflect.Method; import java.lang.reflect.Method;
import java.lang.reflect.Field;
import java.io.*; import java.io.*;
public class GenerateProducts { public class GenerateProducts {
...@@ -21,7 +19,6 @@ public class GenerateProducts { ...@@ -21,7 +19,6 @@ public class GenerateProducts {
PrintStream out = new PrintStream(new FileOutputStream("index.html", true)); PrintStream out = new PrintStream(new FileOutputStream("index.html", true));
Method[] methods = products.getMethods(); Method[] methods = products.getMethods();
Stream<Method> stream1 = Arrays.stream(methods);
List<Method> productList = Arrays.stream(methods) List<Method> productList = Arrays.stream(methods)
.filter(line -> line.getReturnType().equals(product)) .filter(line -> line.getReturnType().equals(product))
.collect(Collectors.toList()); .collect(Collectors.toList());
......
import java.util.Arrays;
import java.util.stream.Stream;
import java.util.List;
import java.util.stream.Collectors;
import java.lang.reflect.Method;
import java.lang.reflect.Field;
import java.io.*; import java.io.*;
public class GenerateSite { public class GenerateSite {
...@@ -13,20 +7,10 @@ public class GenerateSite { ...@@ -13,20 +7,10 @@ public class GenerateSite {
public static final String itemEnd = "</li>"; public static final String itemEnd = "</li>";
public static void main(String[] args) throws Exception { public static void main(String[] args) throws Exception {
Class<?> staff = Staff.class;
Class<?> employee = Employee.class;
Object dummy = staff.getDeclaredConstructor().newInstance();
clearFiles("."); clearFiles(".");
clearFiles("staff"); clearFiles("staff");
PrintStream out = new PrintStream(new File("index.html")); PrintStream out = new PrintStream(new File("index.html"));
Method[] methods = staff.getMethods();
Stream<Method> stream1 = Arrays.stream(methods);
List<Method> employeeList = Arrays.stream(methods)
.filter(line -> line.getReturnType().equals(employee))
.collect(Collectors.toList());
printHeader(out, "FAANG"); printHeader(out, "FAANG");
out.println(indent(2) + "<h1><span class=\"company\">FAANG</span><span class=\"slogan\">Insert Catchy Slogan Here</span></h1>"); out.println(indent(2) + "<h1><span class=\"company\">FAANG</span><span class=\"slogan\">Insert Catchy Slogan Here</span></h1>");
...@@ -34,7 +18,7 @@ public class GenerateSite { ...@@ -34,7 +18,7 @@ public class GenerateSite {
out.println(indent(3) + "<div class=\"left_col\">"); out.println(indent(3) + "<div class=\"left_col\">");
out.println(indent(4) + "<p class=\"tab\">Products</p>"); out.println(indent(4) + "<p class=\"tab\">Products</p>");
out.println(indent(4) + listStart); out.println(indent(4) + listStart);
out.close(); out.close();
GenerateProducts.main(null); GenerateProducts.main(null);
......
import java.util.Arrays; import java.util.Arrays;
import java.util.stream.Stream;
import java.util.List; import java.util.List;
import java.util.stream.Collectors; import java.util.stream.Collectors;
import java.lang.reflect.Method; import java.lang.reflect.Method;
import java.lang.reflect.Field;
import java.io.*; import java.io.*;
public class GenerateStaff { public class GenerateStaff {
...@@ -21,7 +19,6 @@ public class GenerateStaff { ...@@ -21,7 +19,6 @@ public class GenerateStaff {
PrintStream out = new PrintStream(new FileOutputStream("index.html", true)); PrintStream out = new PrintStream(new FileOutputStream("index.html", true));
Method[] methods = staff.getMethods(); Method[] methods = staff.getMethods();
Stream<Method> stream1 = Arrays.stream(methods);
List<Method> employeeList = Arrays.stream(methods) List<Method> employeeList = Arrays.stream(methods)
.filter(line -> line.getReturnType().equals(employee)) .filter(line -> line.getReturnType().equals(employee))
.collect(Collectors.toList()); .collect(Collectors.toList());
......
import java.io.*;
/* check out these products! */ /* check out these products! */
public class Products { /* a good class, but not as good as cse391 */ public class Products { /* a good class, but not as good as cse391 */
public Product joshsProduct() { public Product joshsProduct() {
return new Product("Dirt", "The good stuff", "dirt.jpeg", 0.0); return new Product("Dirt", "The good stuff", "dirt.jpeg", 0.0);
} }
} }
import java.io.*;
public class Staff { public class Staff {
public Employee faangPup() { public Employee faangPup() {
return new Employee("Steve", "Company Pup", "Provides Moral Support", "pup.jpg"); return new Employee("Steve", "Company Pup", "Provides Moral Support", "pup.jpg");
} }
...@@ -9,4 +7,4 @@ public class Staff { ...@@ -9,4 +7,4 @@ public class Staff {
public Employee cjobes() { public Employee cjobes() {
return new Employee("Colton", "Lead Naps Analyst", "What do you mean I'm not valuable to the company?", "colton.jpg"); return new Employee("Colton", "Lead Naps Analyst", "What do you mean I'm not valuable to the company?", "colton.jpg");
} }
} }
@font-face { @font-face {
font-family: 'Manrope'; /*a name to be used later*/ font-family: "Manrope"; /*a name to be used later*/
src: url('../fonts/Manrope-ExtraBold.otf'); /*URL to font*/ src: url("../fonts/Manrope-ExtraBold.otf"); /*URL to font*/
} }
@font-face { @font-face {
font-family: 'Manrope-Var'; /*a name to be used later*/ font-family: "Manrope-Var"; /*a name to be used later*/
src: url('../fonts/Manrope-Light.otf'); /*URL to font*/ src: url("../fonts/Manrope-Light.otf"); /*URL to font*/
} }
body { body {
width: 50%; width: 50%;
margin: auto; margin: auto;
padding: 0; padding: 0;
} }
h1 { h1 {
margin: 0; margin: 0;
padding: 0; padding: 0;
font-family: 'Manrope'; font-family: "Manrope";
font-size: 40pt; font-size: 40pt;
text-align: center; text-align: center;
margin-top: 75px; margin-top: 75px;
color: #363C74; color: #363c74;
} }
p { p {
margin: 0; margin: 0;
padding: 0; padding: 0;
font-family: 'Manrope-Var'; font-family: "Manrope-Var";
font-size: 27pt; font-size: 27pt;
} }
li { li {
margin: 5px; margin: 5px;
} }
.tab { .tab {
font-family: 'Manrope-var'; font-family: "Manrope-var";
font-size: 15pt; font-size: 15pt;
text-align: center; text-align: center;
padding-top: 10px; padding-top: 10px;
} }
.company { .company {
font-family: 'Manrope'; font-family: "Manrope";
font-size: 40pt; font-size: 40pt;
padding-right: 20px; padding-right: 20px;
} }
.slogan { .slogan {
font-family: 'Manrope-Var'; font-family: "Manrope-Var";
font-size: 27pt; font-size: 27pt;
color: #E8D3A2; color: #e8d3a2;
} }
.entry { .entry {
font-family: 'Manrope'; font-family: "Manrope";
font-size: 15pt; font-size: 15pt;
color: black; color: black;
text-decoration: none; text-decoration: none;
} }
.entry:hover { .entry:hover {
color: #E8D3A2; color: #e8d3a2;
text-decoration: none; text-decoration: none;
} }
.entry:visited { .entry:visited {
color: #363C74; color: #363c74;
text-decoration: none; text-decoration: none;
} }
.entry:visited:hover { .entry:visited:hover {
color: #E8D3A2; color: #e8d3a2;
text-decoration: none; text-decoration: none;
} }
.about { .about {
font-family: 'Manrope'; font-family: "Manrope";
font-size: 15pt; font-size: 15pt;
margin; 5px margin: 5px;
color: black; color: black;
text-decoration: none; text-decoration: none;
line-height: 1em; line-height: 1em;
} }
.wrap { .wrap {
margin:0 auto; margin: 0 auto;
} }
.left_col { .left_col {
float:left; float: left;
width: 50%; width: 50%;
} }
.right_col { .right_col {
float:right; float: right;
width: 50%; width: 50%;
} }
img {
display: block;
max-width: 100%;
height: auto;
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment