Here you can find the source of cast(String type)
public static String cast(String type)
//package com.java2s; /**//from www . j av a2s . c om * <copyright> * * Copyright (c) 2009, 2010 Springsite BV (The Netherlands) and others * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html * * Contributors: * Martin Taal - Initial API and implementation * IBM - getInstanceClass method * * </copyright> * * $Id: GenUtils.java,v 1.16 2011/08/25 12:35:07 mtaal Exp $ */ public class Main { public static String cast(String type) { if (type == null) { return type; } if (type.equals(Object.class.getName())) { return ""; //$NON-NLS-1$ } return "(" + type + ")"; //$NON-NLS-1$ //$NON-NLS-2$ } }