Java.util.Currency.toString() 方法


Java.util.Currency.toString() 方法

package com.codingdict;

import java.util.*;

public class CurrencyDemo {
   public static void main(String[] args) {

      // create a currency with specified currency code
      Currency curr = Currency.getInstance("USD");

      // get the currency string and print it
      System.out.println("String representation:" + curr.toString());
   }
}