Android Open Source - simple-matrix Matrix






From Project

Back to project page simple-matrix.

License

The source code is released under:

MIT License

If you think the Android project simple-matrix 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 com.alexkang.x3matrixcalculator;
//  w ww .j a v a 2s  .  c  om
import android.os.Parcel;
import android.os.Parcelable;

public class Matrix implements Parcelable {
  double[][] matrix;
  
  public Matrix(double[][] matrix) {
    this.matrix = matrix;
  }
  
  public Matrix(Parcel in) {
    matrix = (double[][]) in.readSerializable();
  }
  
  public double[][] getMatrix() {
    return matrix;
  }
  
  public void setMatrix(double[][] newMatrix) {
    this.matrix = newMatrix;
  }
  
  @Override
  public int describeContents() {
    // TODO Auto-generated method stub
    return 0;
  }

  @Override
  public void writeToParcel(Parcel out, int flags) {
    // TODO Auto-generated method stub
    out.writeSerializable(matrix);
  }

  public static final Parcelable.Creator<Matrix> CREATOR =
      new Parcelable.Creator<Matrix>() {
    
    @Override
    public Matrix createFromParcel(Parcel in) {
      return new Matrix(in);
    }
    
    @Override
    public Matrix[] newArray(int size) {
      return new Matrix[size];
    }
  };
}




Java Source Code List

com.alexkang.x3matrixcalculator.DisplayResultActivity.java
com.alexkang.x3matrixcalculator.MainActivity.java
com.alexkang.x3matrixcalculator.MatrixRational.java
com.alexkang.x3matrixcalculator.Matrix.java
com.alexkang.x3matrixcalculator.SettingsActivity.java
com.alexkang.x3matrixcalculator.calculations.Advanced.java
com.alexkang.x3matrixcalculator.calculations.Basic.java
com.alexkang.x3matrixcalculator.calculations.RationalAdvanced.java
com.alexkang.x3matrixcalculator.calculations.RationalBasic.java
com.alexkang.x3matrixcalculator.calculations.RationalCalc.java
com.alexkang.x3matrixcalculator.calculations.Rational.java