Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
E
entwurfsmuster
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
mki-swt2
entwurfsmuster
Commits
901871d5
Commit
901871d5
authored
4 years ago
by
Peter Hertkorn
Browse files
Options
Downloads
Patches
Plain Diff
erdeBesuchen in abstract class
parent
78568cb9
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/aliensimulator/Alien.java
+4
-0
4 additions, 0 deletions
src/aliensimulator/Alien.java
src/aliensimulator/AlienMars.java
+5
-0
5 additions, 0 deletions
src/aliensimulator/AlienMars.java
src/aliensimulator/AlienSimulator.java
+7
-0
7 additions, 0 deletions
src/aliensimulator/AlienSimulator.java
with
16 additions
and
0 deletions
src/aliensimulator/Alien.java
+
4
−
0
View file @
901871d5
...
@@ -7,4 +7,8 @@ public abstract class Alien {
...
@@ -7,4 +7,8 @@ public abstract class Alien {
public
void
fliegen
()
{
public
void
fliegen
()
{
System
.
out
.
println
(
"Ich fliege durch den Weltraum."
);
System
.
out
.
println
(
"Ich fliege durch den Weltraum."
);
}
}
public
void
erdeBesuchen
(){
System
.
out
.
println
(
"Ich besuche die Erde. Die Menschen sind wundervoll."
);
}
}
}
This diff is collapsed.
Click to expand it.
src/aliensimulator/AlienMars.java
+
5
−
0
View file @
901871d5
...
@@ -5,4 +5,9 @@ public class AlienMars extends Alien {
...
@@ -5,4 +5,9 @@ public class AlienMars extends Alien {
public
void
darstellen
()
{
public
void
darstellen
()
{
System
.
out
.
println
(
"Ich bin das Alien vom Mars."
);
System
.
out
.
println
(
"Ich bin das Alien vom Mars."
);
}
}
@Override
public
void
erdeBesuchen
()
{
System
.
out
.
println
(
"Ich besuche die Erde. Die Menschen schmecken gut."
);
}
}
}
This diff is collapsed.
Click to expand it.
src/aliensimulator/AlienSimulator.java
+
7
−
0
View file @
901871d5
...
@@ -7,9 +7,16 @@ public class AlienSimulator {
...
@@ -7,9 +7,16 @@ public class AlienSimulator {
Alien
alien
=
new
AlienMars
();
Alien
alien
=
new
AlienMars
();
alien
.
darstellen
();
alien
.
darstellen
();
alien
.
fliegen
();
alien
.
fliegen
();
alien
.
erdeBesuchen
();
alien
=
new
AlienMond
();
alien
=
new
AlienMond
();
alien
.
darstellen
();
alien
.
darstellen
();
alien
.
fliegen
();
alien
.
fliegen
();
alien
.
erdeBesuchen
();
alien
=
new
AlienVenus
();
alien
.
darstellen
();
alien
.
fliegen
();
alien
.
erdeBesuchen
();
}
}
}
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment