📄 movie.java
字号:
public abstract class Movie {
/* the title of the movie*/
private String title;
/*the name of the actors in the movie*/
private String[] actors;
/* the director of the movie*/
private String director;
/*constructor*/
public Movie(String initialTitle,
String[] initialActors,
String initialDirector) {
this.title = initialTitle;
this.actors = initialActors;
this.director = initialDirector;
}
/*return the value of title*/
public String getTitle() {
return this.title;
}
/*return the reference to the array of actors*/
public String[] getActors() {
return this.actors;
}
/*return the value of the director*/
public String getDirector() {
return this.director;
}
/*to string*/
public String toString() {
return this.title;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -