Commit 90d67bbe authored by Stephen Bennett's avatar Stephen Bennett

Add stubs for question 1

parent a1dc3b5a
package org.alfresco.model;
public class DirectorAndLeadingActorPair {
private final String director;
private final String leadingActor;
public DirectorAndLeadingActorPair(String director, String leadingActor) {
this.director = director;
this.leadingActor = leadingActor;
}
public String getDirector() {
return director;
}
public String getLeadingActor() {
return leadingActor;
}
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
DirectorAndLeadingActorPair that = (DirectorAndLeadingActorPair) o;
if (director != null ? !director.equals(that.director) : that.director != null) return false;
return leadingActor != null ? leadingActor.equals(that.leadingActor) : that.leadingActor == null;
}
@Override
public int hashCode() {
int result = director != null ? director.hashCode() : 0;
result = 31 * result + (leadingActor != null ? leadingActor.hashCode() : 0);
return result;
}
@Override
public String toString() {
return "DirectorAndLeadingActorPair{" +
"director='" + director + '\'' +
", leadingActor='" + leadingActor + '\'' +
'}';
}
}
package org.alfresco.questionone;
import org.alfresco.model.DirectorAndLeadingActorPair;
import org.alfresco.model.Film;
import java.util.List;
import static java.util.Collections.emptyList;
/**
* Please complete your code for question one here.
*/
public class QuestionOne {
public List<Film> top10HighestGrossingFilms() {
return emptyList();
}
public List<Film> top10ValueForMoneyFilms() {
return emptyList();
}
public String actorWhoHasAppearedInTheMostFilms() {
return "Unknown";
}
public DirectorAndLeadingActorPair mostSuccessfulDirectorAndLeadingActorPair() {
return null;
}
}
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