Java String Encode encodeToFlex(Object o)

Here you can find the source of encodeToFlex(Object o)

Description

encode To Flex

License

Apache License

Declaration

public static String encodeToFlex(Object o)
            throws UnsupportedEncodingException 

Method Source Code

//package com.java2s;
// Licensed under the Apache License, Version 2.0 (the "License");

import java.io.UnsupportedEncodingException;

public class Main {
    public static String encodeToFlex(Object o)
            throws UnsupportedEncodingException {
        String url = java.net.URLEncoder.encode((String) o, "utf-8");
        url = url.replaceAll("\\+", "%20");
        return url;
    }//  www  .j  a v  a 2 s. c  o  m
}

Related

  1. encodeText(String str)
  2. encodeText(String str, String fromEnc, String toEnc)
  3. encodeTexts(String s)
  4. encodeTextValue(char[] characters, int offset, int length, Writer writer)
  5. encodeThoroughly(String s)
  6. encodeToForm(Map msg)
  7. encodeToString(String s)
  8. encodeURNComponent(String value)
  9. encodeUTF8(String input, boolean keepSpaces)