⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 methodgenerator.java

📁 这是通过ejb实现从服务器上获取当前时间
💻 JAVA
字号:
package org.eclipse.jst.j2ee.ejb.gmf.templates.session;

import java.util.*;
import org.eclipse.jst.j2ee.ejb.annotation.internal.model.*;

public class MethodGenerator
{
  protected static String nl;
  public static synchronized MethodGenerator create(String lineSeparator)
  {
    nl = lineSeparator;
    MethodGenerator result = new MethodGenerator();
    nl = null;
    return result;
  }

  protected final String NL = nl == null ? (System.getProperties().getProperty("line.separator")) : nl;
  protected final String TEXT_1 = NL + "/** " + NL + " *" + NL + " * <!-- begin-xdoclet-definition --> " + NL + " * @ejb.create-method view-type=\"remote\"" + NL + " * <!-- end-xdoclet-definition --> " + NL + " * @generated" + NL + " *" + NL + " * //TODO: Must provide implementation for bean create stub" + NL + " */" + NL + "public void ejbCreate()" + NL + "{" + NL + "}" + NL + "" + NL + "/** " + NL + " *" + NL + " * <!-- begin-xdoclet-definition --> " + NL + " * @ejb.interface-method view-type=\"remote\"" + NL + " * <!-- end-xdoclet-definition --> " + NL + " * @generated" + NL + " *" + NL + " * //TODO: Must provide implementation for bean method stub" + NL + " */" + NL + "public String foo(String param)" + NL + "{" + NL + " \treturn null;" + NL + "}";

  public String generate(Object argument)
  {
    final StringBuffer stringBuffer = new StringBuffer();
      ISessionBean session  = (ISessionBean)argument; 
    stringBuffer.append(TEXT_1);
    return stringBuffer.toString();
  }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -