Giter Site home page Giter Site logo

basemax / javamystring Goto Github PK

View Code? Open in Web Editor NEW
6.0 2.0 0.0 49 KB

A tiny implementation of String class in java as final project.

License: GNU General Public License v3.0

Java 100.00%
java java-string-builder-class java-string-class java-stringbuilder java-string java-implementation java-string-implementation string-implementation implementation-string implementation

javamystring's Introduction

JavaMyString

A tiny implementation of String class in java as final project.

Java MyString

Features

  • Tiny code (Suitable to learn from it)
  • Own class
  • Suitable performance
  • Support printf with variable arguments (Varargs)

Class/Library Structure

public MyString();
public MyString(char c);
public MyString(char c[]);
public MyString(MyString value);
public MyString(String value);
public int indexOf(int ch, int fromIndex);
public int indexOf(int ch);
public int indexOf(MyString str);
public int indexOf(MyString str, int fromIndex);
public int indexOf(String str);
public int indexOf(String str, int fromIndex);
public int lastIndexOf(int ch);
public int lastIndexOf(int ch, int fromIndex);
public int lastIndexOf(String str);
public int lastIndexOf(String str, int fromIndex);
public boolean equalsIgnoreCase(MyString other);
public boolean equalsIgnoreCase(String other);
public MyString toLowerCase();
public MyString toUpperCase();
public int compareTo(MyString value);
public int compareToIgnoreCase(MyString value);
public MyString trim();
public static MyString valueOf(boolean b);
public static String valueOf(Object obj);
public String toString();
public boolean equals(Object o);
public static void printf(char[] format, Object... arguments);
public static void printf(String format, Object... arguments);
public static void printf(MyString format, Object... arguments);
public char charAt(int index);
public MyString concat(MyString value);
public void display();
public int indexOf(char ch);
public int length();
public void setAt(int index, char c);
public MyString subString(int low, int high);
public MyString subString(int low);
public char[] toCharArray();

Build

$ javac com/asrez/main.java
$ java com.asrez.main

Max Base

My nickname is Max, Programming language developer, Full-stack programmer. I love computer scientists, researchers, and compilers.

Asrez Team

A team includes some programmer, developer, designer, researcher(s) especially Max Base.

Asrez Team

javamystring's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.