Android Open Source - ixming-android-inject Main Activity






From Project

Back to project page ixming-android-inject.

License

The source code is released under:

Apache License

If you think the Android project ixming-android-inject listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.

Java Source Code

package org.ixming.android;
/*from  w  w w .  j a  va  2 s.  co  m*/
import org.ixming.android.inject.InjectorUtils;

import android.app.Activity;
import android.os.Bundle;

public class MainActivity extends Activity {

//  @ViewInject(id=R.id.tv1)
//  TextView test1;
  
//  @ViewInject(id=R.id.tv1)
//  private ImageView test2;
  
  // right-OK
//  @ViewInject(id=R.id.tv1)
//  private View testx;
  
//  @ViewInject(id=R.id.tv1, parentId=R.id.rlt1)
//  TextView testx2;
  
//  @ViewInject(id=R.id.tv2)
//  TextView test3;
  
//  @ViewInject(id=R.id.tv2, parentId=R.id.tv2)
//  TextView testx3;
  
  // error-OK
//  @ViewInject(id=R.id.tv2, parentId=R.id.tv1)
//  private TextView test4;
  
  // error-OK
//  @ViewInject(id=R.id.tv2, parentId=R.id.rlt1)
//  private TextView test5;
  
  // error-OK
//  @ViewInject(id=R.id.tv2, parentId=R.id.rlt2)
//  private TextView test6;
  
//  @ViewInject(id=R.id.rlt1)
//  RelativeLayout rlt1;
  
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
        InjectorUtils.defaultInstance().inject(this);
        System.gc();
    }

//    @OnClickMethodInject(id=R.id.tv1)
//    private void test1() {
//      Log.i("yytest", "test1");
//    }
    
//    @OnClickMethodInject(id=R.id.tv1)
//    private void test2(View v) {
//      Log.i("yytest", "test2 " + v);
//    }
    
//    @OnClickMethodInject(id=R.id.tv1)
//    private void test3(Object o) {
//      Log.i("yytest", "test3 " + o);
//    }
    
//    @OnClickMethodInject(id=R.id.tv1)
//    private void test4(Object...o) {
//      Log.i("yytest", "test4 " + o);
//    }
    
//    @OnClickMethodInject(id=R.id.tv1)
//    void test5(String a, byte b, Runnable c) {
//      Log.i("yytest", "test5 : " + a + ", " + b + ", " + c);
//    }
}




Java Source Code List

org.ixming.android.MainActivity.java
org.ixming.android.inject.InjectConfigure.java
org.ixming.android.inject.InjectorUtils.java
org.ixming.android.inject.ResTargetType.java
org.ixming.android.inject.annotation.OnClickMethodInject.java
org.ixming.android.inject.annotation.ResInject.java
org.ixming.android.inject.annotation.ViewInject.java
org.ixming.android.inject.annotation.ViewOnClickInject.java
org.ixming.android.inject.annotation.package-info.java
org.ixming.android.inject.core.ActivityInjectLoader.java
org.ixming.android.inject.core.BaseInjectLoader.java
org.ixming.android.inject.core.IOnClickListenerInjector.java
org.ixming.android.inject.core.IResInjector.java
org.ixming.android.inject.core.IViewFinder.java
org.ixming.android.inject.core.IViewInjector.java
org.ixming.android.inject.core.InjectLoaderFactory.java
org.ixming.android.inject.core.ResLoader.java
org.ixming.android.inject.core.ViewInjectLoader.java
org.ixming.android.inject.core.WrappedViewFinder.java
org.ixming.android.inject.themed.ThemedInjectConfigure.java
org.ixming.android.inject.themed.ThemedInjectorUtils.java
org.ixming.android.inject.themed.ThemedResInject.java
org.ixming.android.inject.themed.package-info.java
org.ixming.android.inject.package-info.java