TypeOnGetter.java :  » JSON » jsonmarshaller » com » twolattes » json » Java Open Source

Java Open Source » JSON » jsonmarshaller 
jsonmarshaller » com » twolattes » json » TypeOnGetter.java
package com.twolattes.json;

import java.net.MalformedURLException;
import java.net.URL;

import com.twolattes.json.types.URLType;

@Entity
public class TypeOnGetter {

  private URL url;

  public TypeOnGetter() {
    try {
      url = new URL("http://www.kaching.com");
    } catch (MalformedURLException e) {
      throw new RuntimeException(e);
    }
  }

  @Value(type = URLType.class)
  public URL getUrl() {
    return url;
  }

}
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.