Java Object NVL nvl(String source, String defaultString)

Here you can find the source of nvl(String source, String defaultString)

Description

Method nvl.

License

Apache License

Parameter

Parameter Description
source String
defaultString String

Return

String

Declaration

public static String nvl(String source, String defaultString) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {

    public static String nvl(String source) {
        return (source != null) ? source.trim() : "";
    }// w w  w.j  a v a2 s  .com

    /**
     * Method nvl.
     *
     * @param source
     *            String
     * @param defaultString
     *            String
     * @return String
     */
    public static String nvl(String source, String defaultString) {
        return (source != null) ? source.trim() : defaultString;
    }
}

Related

  1. nvl(String pValue)
  2. nvl(String s)
  3. nvl(String s, String def)
  4. NVL(String s, String valorPorDefecto)
  5. NVL(String source, String def)
  6. nvl(String str)
  7. nvl(String str, String nullString)
  8. NVL(String str, String replace)
  9. nvl(String string)