Commit 7b2c66ff authored by Jiri Sebek's avatar Jiri Sebek
Browse files

2.cviceni

parent 3adaf086
# Enterprice architect model
*.EAP
# Exported diagrams
*.png
# Intellij
.idea/
*.iml
*.iws
# Maven
log/
target/
\ No newline at end of file
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>cz-cvut-fel-omo</groupId>
<artifactId>cv2_solution</artifactId>
<version>1.0-SNAPSHOT</version>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
</properties>
<dependencies>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.11</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.3.2</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
\ No newline at end of file
package cz.cvut.fel.omo.trackingSystem;
import java.util.ArrayList;
import java.util.List;
/**
* Created by kuki on 22/09/2017.
* GpsTrackingSystem class represents the newly introduced tool for gaining control over company car park.
*/
public class GpsTrackingSystem {
// IMPLEMENT ME, PLEASE!
}
package cz.cvut.fel.omo.trackingSystem;
import java.util.ArrayList;
import java.util.List;
/**
* Created by kuki on 22/09/2017.
*/
public class Main {
public static void main(String[] args) {
/* UNCOMMENT ME, WHEN READY
// 1. Initialize company car park
List<Vehicle> carPark = new ArrayList<>();
GpsTrackingSystem companySpy = new GpsTrackingSystem();
carPark.add(new Vehicle("Volvo", "VINOKLJ15", 879));
carPark.add(new Vehicle("Volvo", "OINNLKA48", 9080));
carPark.add(new Vehicle("Volvo", "OPWAKMKL8", 1280));
// Attaching tracking devices to the car park
companySpy.attachTrackingDevices(carPark);
// Counting initial traveled distance with trackers
companySpy.generateMonthlyReport();
// Busy month filled with business travelling
carPark.forEach(car->car.drive(100));
// End of another month, generate new report
companySpy.generateMonthlyReport();
// Busy month filled with business travelling
carPark.forEach(car->car.drive(300));
// End of another month, generate new report
companySpy.generateMonthlyReport();
*/
}
}
package cz.cvut.fel.omo.trackingSystem;
/**
* Tracker is device installed into company vehicles, connected to car computer in order to obtain necessary data.
*/
public class Tracker {
// IMPLEMENT ME, PLEASE!
}
package cz.cvut.fel.omo.trackingSystem;
/**
* Class Vehicle represents a single car in company car park.
*/
public class Vehicle {
// IMPLEMENT ME, PLEASE!
}
package cz.cvut.fel.omo.trackingSystem;
import org.junit.Test;
import java.util.ArrayList;
import java.util.List;
import static org.junit.Assert.*;
/**
* Created by kuki on 22/09/2017.
*/
public class GPSTrackingSystemTest {
// IMPLEMENT ME, PLEASE!
}
\ No newline at end of file
package cz.cvut.fel.omo.trackingSystem;
import org.junit.Assert;
import org.junit.Test;
import static org.junit.Assert.*;
/**
* Created by kuki on 22/09/2017.
*/
public class TrackerTest {
// IMPLEMENT ME, PLEASE!
}
\ No newline at end of file
package cz.cvut.fel.omo.trackingSystem;
import org.junit.Test;
import static org.junit.Assert.*;
/**
* Created by kuki on 22/09/2017.
*/
public class VehicleTest {
// IMPLEMENT ME, PLEASE!
}
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment