Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 | 29 |
30 | 31 |
Tags
- takanaru
- 신주쿠맛집
- 신주쿠 로컬식당
- 크롬 인너넷연결 안됨
- 타카마루
- 코로나백신
- windows10 크롬
- 윈도우10 vpn
- 코로나백신 부작용
- 강화 프로방스
- 코로나백신 어지러움
- 10원단위 올림
- cisco vpn
- Windows10
- 핸드폰 찾기
- 성수족발
- 오라클
- 랍스터 찜
- 노리로또
- windows10 cisco vpn
- 안드로이드폰 위치
- 크롬 인터넷연결
- 크롬 타임아웃
- 응용 프로그램 내 구입
- 코로나백신 갈증
- 10 올림
- 로니세라
- 분기날짜
- 화이자백신
- 코로나백신이상증상
Archives
- Today
- Total
이거 맘대로 되는 세상이 아니구만...
참조형 변수의 데이터타입 2월 2일 4일째 강좌 본문
반응형
참조형 변수의 데이터타입
*/
/*
class Test{
public static void main(String args[]){
OutputStream is=System.out;
is.println("abc");
}
}
class System{
static OutputStream out; //()가 없으므로 멤버변수 System클래스가 있다.
//class A{
//static B b;
//class Test{
//public static void main(String args[]){
//B obj=A.obj
//}
//}
//}
}
class OutputStream{
String s;
void Println(String s){
this.s=s;
}
}
*/
/*
class A{
static B obj; //=new B();가 없으면 NullPointerException 에러가 생긴다
}
class B{
void me(){
System.out.println("abc");
}
}
class Test{
public static void main(String args[]){
A.obj.me(); //B b=a.obj;
//b.me();로 줄일수 있다..
}
}
*/
class A{
void me1(){
this.me2().me3(); //this가 숨어있다 즉 me2는 A클래스에 있다
//B me2(){
//리턴형이 B }
}
}
class B{
void me3(){
System.out.println("abc");
}
}
/*
class A{
void me1(){
System.out.println("abc");
}
void me2(){
me1(); //this가 생략되어 있다.
}
}
class Test{
public static void main(String args[]){
new A().me2();
}
}
/*
class Test{
public static void main(String args[]){
A.a.me1().me2(); // a ---> A클래스 안에 있어야한다.
// me1()-->B라는 클래스가 me1을 가지고있다.
// me2()-->me1을 C클래스에 있따 B클래스이 리턴값이 C이다.
//
}
}
class B{
C me1(){
return new C();
}
}
class A{
static B a=new B(); //A라는 클래스 명으로 접근 하였으므로 static가 붙는다.
}
class C{
void me2(){ //A.a.me1().me2()의 리턴값이 없으므로 static를 붙인다.
System.out.println("abc");
}
}
*/
/*
class Test{
public static void main(String args[]){
A.a.me1().c.me2();
}
}
class B{
C me1(){
return new C();
}
}
class A{
static B a=new B();
}
class C{
D c=new D();
}
class D{
void me2(){
System.out.println("abc");
}
}
*/
/*
class Test{
public static void main(String args[]){
OutputStream is=System.out;
is.println("abc");
}
}
class System{
static OutputStream out; //()가 없으므로 멤버변수 System클래스가 있다.
//class A{
//static B b;
//class Test{
//public static void main(String args[]){
//B obj=A.obj
//}
//}
//}
}
class OutputStream{
String s;
void Println(String s){
this.s=s;
}
}
*/
/*
class A{
static B obj; //=new B();가 없으면 NullPointerException 에러가 생긴다
}
class B{
void me(){
System.out.println("abc");
}
}
class Test{
public static void main(String args[]){
A.obj.me(); //B b=a.obj;
//b.me();로 줄일수 있다..
}
}
*/
class A{
void me1(){
this.me2().me3(); //this가 숨어있다 즉 me2는 A클래스에 있다
//B me2(){
//리턴형이 B }
}
}
class B{
void me3(){
System.out.println("abc");
}
}
/*
class A{
void me1(){
System.out.println("abc");
}
void me2(){
me1(); //this가 생략되어 있다.
}
}
class Test{
public static void main(String args[]){
new A().me2();
}
}
/*
class Test{
public static void main(String args[]){
A.a.me1().me2(); // a ---> A클래스 안에 있어야한다.
// me1()-->B라는 클래스가 me1을 가지고있다.
// me2()-->me1을 C클래스에 있따 B클래스이 리턴값이 C이다.
//
}
}
class B{
C me1(){
return new C();
}
}
class A{
static B a=new B(); //A라는 클래스 명으로 접근 하였으므로 static가 붙는다.
}
class C{
void me2(){ //A.a.me1().me2()의 리턴값이 없으므로 static를 붙인다.
System.out.println("abc");
}
}
*/
/*
class Test{
public static void main(String args[]){
A.a.me1().c.me2();
}
}
class B{
C me1(){
return new C();
}
}
class A{
static B a=new B();
}
class C{
D c=new D();
}
class D{
void me2(){
System.out.println("abc");
}
}
Comments