Examples of BaseConvertor


Examples of br.com.gmartins.simbler.instructions.BaseConvertor

                andValue.append("1");
            } else {
                andValue.append("0");
            }
        }
        String andValueDecimal = new BaseConvertor().binToDec(andValue.toString());
        return finalValue(Integer.parseInt(andValueDecimal));
    }
View Full Code Here

Examples of br.com.gmartins.simbler.instructions.BaseConvertor

                andValue.append("0");
            } else {
                andValue.append("1");
            }
        }
        String andValueDecimal = new BaseConvertor().binToDec(andValue.toString());
        return finalValue(Integer.parseInt(andValueDecimal));
    }
View Full Code Here

Examples of br.com.gmartins.simbler.instructions.BaseConvertor

     * Converte o valor para decimal.
     *
     * @return
     */
    public String toDecimal() {
        BaseConvertor baseConvertor = new BaseConvertor();
        switch (this.valueType) {
            case BINARY:
                return baseConvertor.binToDec(this.value);
            case HEXADECIMAL:
                return baseConvertor.hexToDec(this.value);
            case DECIMAL:
                return value;
        }
        return null;
    }
View Full Code Here

Examples of br.com.gmartins.simbler.instructions.BaseConvertor

     * Converte o valor para Hexadecimal.
     *
     * @return
     */
    public String toHex() {
        BaseConvertor baseConvertor = new BaseConvertor();
        switch (this.valueType) {
            case BINARY:
                return baseConvertor.binToHex(this.value);
            case HEXADECIMAL:
                return value;
            case DECIMAL:
                return baseConvertor.decToHex(this.value);
        }
        return null;
    }
View Full Code Here

Examples of br.com.gmartins.simbler.instructions.BaseConvertor

     * Converte o valor para binário.
     *
     * @return
     */
    public String toBinary() {
        BaseConvertor baseConvertor = new BaseConvertor();
        switch (this.valueType) {
            case BINARY:
                return this.value;
            case HEXADECIMAL:
                return baseConvertor.hexToBin(this.value);
            case DECIMAL:
                return baseConvertor.decToBin(this.value);
        }
        return null;
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.