text stringlengths 3 1.18M |
|---|
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2009 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2009 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in... |
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to i... |
package com.thimbleware.jmemcached;
import java.util.concurrent.atomic.AtomicInteger;
import java.util.concurrent.atomic.AtomicLong;
import java.util.Set;
import java.util.Map;
import java.util.HashMap;
import java.util.HashSet;
import static java.lang.String.*;
/**
* Abstract implementation of a cache handler for ... |
package com.thimbleware.jmemcached.protocol;
import com.thimbleware.jmemcached.Cache;
import com.thimbleware.jmemcached.CacheElement;
import java.io.Serializable;
import java.util.Set;
import java.util.Map;
/**
* Represents the response to a command.
*/
public final class ResponseMessage<CACHE_ELEMENT extends Cach... |
package com.thimbleware.jmemcached.protocol.exceptions;
/**
*/
public class MalformedCommandException extends ClientException {
public MalformedCommandException() {
}
public MalformedCommandException(String s) {
super(s);
}
public MalformedCommandException(String s, Throwable throwable) ... |
package com.thimbleware.jmemcached.protocol.exceptions;
/**
*/
public class IncorrectlyTerminatedPayloadException extends ClientException {
public IncorrectlyTerminatedPayloadException() {
}
public IncorrectlyTerminatedPayloadException(String s) {
super(s);
}
public IncorrectlyTerminated... |
package com.thimbleware.jmemcached.protocol.exceptions;
/**
*/
public class UnknownCommandException extends ClientException {
public UnknownCommandException() {
}
public UnknownCommandException(String s) {
super(s);
}
public UnknownCommandException(String s, Throwable throwable) {
... |
package com.thimbleware.jmemcached.protocol.exceptions;
/**
*/
public class InvalidProtocolStateException extends Exception {
public InvalidProtocolStateException() {
}
public InvalidProtocolStateException(String s) {
super(s);
}
public InvalidProtocolStateException(String s, Throwable t... |
package com.thimbleware.jmemcached.protocol.exceptions;
/**
*/
public class ClientException extends Exception {
public ClientException() {
}
public ClientException(String s) {
super(s);
}
public ClientException(String s, Throwable throwable) {
super(s, throwable);
}
publ... |
/**
* Copyright 2008 ThimbleWare Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law o... |
package com.thimbleware.jmemcached.protocol;
import java.io.Serializable;
/**
* Class for holding the current session status.
*/
public final class SessionStatus implements Serializable {
/**
* Possible states that the current session is in.
*/
public static enum State {
WAITING_FOR_DATA,... |
package com.thimbleware.jmemcached.protocol.text;
import com.thimbleware.jmemcached.CacheElement;
import com.thimbleware.jmemcached.Key;
import com.thimbleware.jmemcached.LocalCacheElement;
import com.thimbleware.jmemcached.protocol.CommandMessage;
import com.thimbleware.jmemcached.protocol.Op;
import com.thimbleware.... |
package com.thimbleware.jmemcached.protocol.text;
import com.thimbleware.jmemcached.Cache;
import com.thimbleware.jmemcached.CacheElement;
import com.thimbleware.jmemcached.protocol.Op;
import com.thimbleware.jmemcached.protocol.ResponseMessage;
import com.thimbleware.jmemcached.protocol.exceptions.ClientException;
im... |
package com.thimbleware.jmemcached.protocol.text;
import com.thimbleware.jmemcached.Cache;
import com.thimbleware.jmemcached.protocol.MemcachedCommandHandler;
import com.thimbleware.jmemcached.protocol.SessionStatus;
import org.jboss.netty.channel.ChannelPipeline;
import org.jboss.netty.channel.ChannelPipelineFactory;... |
/**
* Copyright 2008 ThimbleWare Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applica... |
package com.thimbleware.jmemcached.protocol.binary;
import com.thimbleware.jmemcached.Key;
import com.thimbleware.jmemcached.LocalCacheElement;
import com.thimbleware.jmemcached.CacheElement;
import com.thimbleware.jmemcached.protocol.Op;
import com.thimbleware.jmemcached.protocol.CommandMessage;
import com.thimblewar... |
package com.thimbleware.jmemcached.protocol.binary;
import com.thimbleware.jmemcached.protocol.Op;
import com.thimbleware.jmemcached.protocol.ResponseMessage;
import com.thimbleware.jmemcached.protocol.exceptions.UnknownCommandException;
import com.thimbleware.jmemcached.CacheElement;
import org.jboss.netty.buffer.Cha... |
package com.thimbleware.jmemcached.protocol.binary;
import com.thimbleware.jmemcached.Cache;
import com.thimbleware.jmemcached.protocol.MemcachedCommandHandler;
import org.jboss.netty.channel.ChannelPipeline;
import org.jboss.netty.channel.ChannelPipelineFactory;
import org.jboss.netty.channel.Channels;
import org.jbo... |
/**
* Copyright 2008 ThimbleWare Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applica... |
package com.thimbleware.jmemcached.storage.mmap;
import com.thimbleware.jmemcached.storage.bytebuffer.BlockStoreFactory;
import com.thimbleware.jmemcached.storage.bytebuffer.ByteBufferBlockStore;
import org.jboss.netty.buffer.ChannelBuffers;
import java.io.File;
import java.io.IOException;
import java.io.RandomAccess... |
package com.thimbleware.jmemcached.storage.bytebuffer;
/**
*/
public interface BlockStoreFactory<BS extends ByteBufferBlockStore> {
BS manufacture(long sizeBytes, int blockSizeBytes);
}
|
package com.thimbleware.jmemcached.storage.bytebuffer;
import com.thimbleware.jmemcached.Key;
import com.thimbleware.jmemcached.LocalCacheElement;
import org.jboss.netty.buffer.ChannelBuffer;
import org.jboss.netty.buffer.ChannelBuffers;
import java.util.*;
import java.util.concurrent.locks.ReentrantReadWriteLock;
/... |
package com.thimbleware.jmemcached.storage.bytebuffer;
import com.thimbleware.jmemcached.Key;
import com.thimbleware.jmemcached.LocalCacheElement;
import org.jboss.netty.buffer.ChannelBuffer;
import org.jboss.netty.buffer.ChannelBufferInputStream;
import java.io.IOException;
import java.io.ObjectInputStream;
/**
... |
package com.thimbleware.jmemcached.storage.bytebuffer;
import com.thimbleware.jmemcached.Key;
import com.thimbleware.jmemcached.LocalCacheElement;
import com.thimbleware.jmemcached.storage.CacheStorage;
import java.io.IOException;
import java.util.*;
import java.util.concurrent.atomic.AtomicInteger;
/**
* Implement... |
package com.thimbleware.jmemcached.storage.bytebuffer;
import com.thimbleware.jmemcached.util.OpenBitSet;
import org.jboss.netty.buffer.ChannelBuffer;
import org.jboss.netty.buffer.ChannelBuffers;
import java.io.IOException;
/**
* Memory mapped block storage mechanism with a free-list maintained by TreeMap
*
* Al... |
package com.thimbleware.jmemcached.storage;
import com.thimbleware.jmemcached.storage.hash.SizedItem;
import java.io.IOException;
import java.util.concurrent.ConcurrentMap;
/**
* The interface for cache storage. Essentially a concurrent map but with methods for investigating the heap
* state of the storage unit an... |
package com.thimbleware.jmemcached.storage.hash;
/*
* Copyright 2009 Benjamin Manes
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
... |
package com.thimbleware.jmemcached.storage.hash;
/**
*/
public interface SizedItem {
int size();
}
|
/**
* Copyright 2008 ThimbleWare Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law o... |
package com.thimbleware.jmemcached;
import java.io.IOException;
import java.util.Set;
import java.util.Map;
/**
*/
public interface Cache<CACHE_ELEMENT extends CacheElement> {
/**
* Enum defining response statuses from set/add type commands
*/
public enum StoreResponse {
STORED, NOT_STORED,... |
/**
* Copyright 2008 ThimbleWare Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law o... |
package com.thimbleware.jmemcached;
import org.jboss.netty.buffer.ChannelBuffer;
import java.util.Arrays;
/**
* Represents a given key for lookup in the cache.
*
* Wraps a byte array with a precomputed hashCode.
*/
public class Key {
public ChannelBuffer bytes;
private int hashCode;
public Key(Chann... |
package com.thimbleware.jmemcached;
import com.thimbleware.jmemcached.storage.hash.SizedItem;
import org.jboss.netty.buffer.ChannelBuffer;
import java.io.Serializable;
import java.nio.ByteBuffer;
/**
*/
public interface CacheElement extends Serializable, SizedItem {
public final static long THIRTY_DAYS = 259200... |
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may... |
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may... |
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may... |
package com.thimbleware.jmemcached.util;
import org.jboss.netty.buffer.ChannelBuffer;
import org.jboss.netty.buffer.ChannelBuffers;
import java.nio.ByteBuffer;
/**
*/
public class BufferUtils {
final static int [] sizeTable = { 9, 99, 999, 9999, 99999, 999999, 9999999,
99999999, 999999999, Integer.... |
/**
* Copyright 2008 ThimbleWare Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law o... |
/*
* Licensed to the Apache Software Foundation (ASF) under one
* or more contributor license agreements. See the NOTICE file
* distributed with this work for additional information
* regarding copyright ownership. The ASF licenses this file
* to you under the Apache License, Version 2.0 (the
* "License")... |
/**
* Copyright 2008 ThimbleWare Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law o... |
/**
* Taken and adapted from the Apache Wicket source.
*/
/*
* ==============================================================================
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License... |
package com.andy.nicefi.exception;
public class DataException {
}
|
package com.andy.nicefi.exception;
import com.andy.nicefi.util.Resource;
public class LogException extends Exception{
public static final String USER_NOT_EXIST = "usernotexist";
public static final String USER_ACTIVATED_ALREADY = "useractivatedalready";
public static final String PASSWORD_NOT_CORRECT = ... |
package com.andy.nicefi.validators;
import java.util.regex.Pattern;
import com.opensymphony.xwork2.validator.ValidationException;
import com.opensymphony.xwork2.validator.validators.FieldValidatorSupport;
public class UserNameValidator extends FieldValidatorSupport{
public static final String userNamePat... |
package com.andy.nicefi.service.impl;
import java.util.List;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.and... |
package com.andy.nicefi.service;
import java.util.List;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import com.andy.nicefi.bean.User;
import com.andy.nicefi.exception.LogException;
@Service
public interface UserService {
@Transaction... |
package com.andy.nicefi.bean;
import java.io.Serializable;
public class BaseEntity implements Serializable{
/**
*
*/
private static final long serialVersionUID = 1L;
}
|
package com.andy.nicefi.bean;
public class Company {
private Long id;
private String number;
private String name;
private Boolean isLeaf;
private Boolean isBizUnit;
private Long parentId;
private int level;
private String remark;
public Long getId() {
return id;
}
public void setId(Long... |
package com.andy.nicefi.dao;
import java.util.List;
import com.andy.nicefi.bean.BaseEntity;
public interface IDAO<T extends BaseEntity> {
public void save(T instance);
public void update(T instance);
public List<T> list();
public T getObjbyId(String id);
public void delete(T instance);
public voi... |
package com.andy.nicefi.dao;
import com.andy.nicefi.bean.User;
public interface UserDAO extends IDAO<User>{
}
|
package com.andy.nicefi.dao;
import java.lang.reflect.ParameterizedType;
import java.lang.reflect.Type;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import java.util.regex.Matcher;
import java.util.regex.Pattern;
import org.apache.commons.beanutils.PropertyUtils;
import org.hibern... |
package com.andy.nicefi.dao.impl;
import java.util.List;
import org.hibernate.SessionFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;
import com.andy.nicefi.bean.User;
import com.andy.nicefi.dao.UserDAO;
@Repository
public class Us... |
package com.andy.nicefi.manager;
public abstract class BaseManager{
} |
package com.andy.nicefi.manager;
import java.util.List;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;
import com.andy.nicefi.bean.User;
import com.andy.nicefi.dao.UserDAO;
@Reposit... |
package com.andy.nicefi.action;
public class LinkAction {
public String welcome(){
return "welcome";
}
public String friends(){
return "friends";
}
public String office(){
return "office";
}
}
|
package com.andy.nicefi.action;
import java.text.MessageFormat;
import java.util.ArrayList;
import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import com.andy.nicefi.bean.User;
import com.andy.nicefi.service.UserService;
import com.andy.nicefi.util.Mail;
import com.andy.... |
package com.andy.nicefi.action;
import java.util.Map;
import org.apache.struts2.dispatcher.SessionMap;
import org.apache.struts2.interceptor.SessionAware;
import com.andy.nicefi.bean.User;
import com.andy.nicefi.exception.LogException;
import com.andy.nicefi.service.UserService;
import com.andy.nicefi.util... |
package com.andy.nicefi.util;
import java.util.ResourceBundle;
public class Resource {
public static ResourceBundle getResourceBundle(String baseName){
return ResourceBundle.getBundle(baseName);
}
public static String getString(String baseName, String key){
return getResourceBundle(baseName).getS... |
package com.andy.nicefi.util;
import java.io.UnsupportedEncodingException;
import java.security.MessageDigest;
import java.security.NoSuchAlgorithmException;
import java.util.Random;
import sun.misc.BASE64Encoder;
public class StringUtil {
public static String getMD5String(String str) {
if (str == n... |
package com.andy.nicefi.util;
public class SmtpAuth extends javax.mail.Authenticator {
private String username, password;
public SmtpAuth(String username, String password) {
this.username = username;
this.password = password;
}
protected javax.mail.PasswordAuthentication getPasswordAuthentication()... |
package com.andy.nicefi.util;
import org.hibernate.SessionFactory;
import org.hibernate.cfg.Configuration;
public class HibernateUtil {
private static final SessionFactory sessionFactory = buildSessionFactory();
private static SessionFactory buildSessionFactory(){
try {
return new Configuration(... |
package com.andy.nicefi.util;
import java.io.IOException;
import java.io.InputStream;
import java.text.MessageFormat;
import java.util.*;
import javax.mail.*;
import javax.mail.internet.*;
import javax.activation.*;
public class Mail {
// 定义发件人、收件人、SMTP服务器、用户名、密码、主题、内容等
private String displayName;
... |
/**
* Copyright 2012 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to... |
package anni.model;
public class CellModel {
public static final int TYPE_COLUMN = 0;
public static final int TYPE_PK = 1;
public static final int TYPE_FK = 2;
private String name; // 名字
private int type; // 类型
private int index; // 行号
public CellModel(String name, int type, int ... |
package anni.model;
import java.util.*;
import anni.database.*;
public class TableModel {
private String name;
private double x;
private double y;
private double w;
private double h;
private List<CellModel> lines = new ArrayList<CellModel>();
public TableModel(String name... |
package anni.model;
import java.util.*;
import anni.database.*;
public class ModelManager {
private Map<String, TableModel> tableModels = new HashMap<String, TableModel>();
private List<FkModel> fkModels = new ArrayList<FkModel>();
//
public Map<String, TableModel> getTableModels() {
... |
package anni.model;
import anni.model.geom.*;
public class FkModel {
public static final double SIN0 = Math.sin(0.5);
public static final double COS0 = Math.cos(0.5);
private double x1;
private double y1;
private double x2;
private double y2;
private String name;
private ... |
package anni.model.geom;
public class Line {
private double x1;
private double y1;
private double x2;
private double y2;
public Line(double x1, double y1, double x2, double y2) {
this.x1 = x1;
this.y1 = y1;
this.x2 = x2;
this.y2 = y2;
}
publi... |
package anni.model.geom;
public class Rect {
private double x;
private double y;
private double w;
private double h;
public Rect(double x, double y, double w, double h) {
this.x = x;
this.y = y;
this.w = w;
this.h = h;
}
public double getX() ... |
package anni.model.geom;
public class Point {
private double x;
private double y;
public Point(double x, double y) {
this.x = x;
this.y = y;
}
public double getX() {
return x;
}
public void setX(double x) {
this.x = x;
}
public ... |
package anni.database;
public class Column {
private String name;
private String typeName;
private int typeSize;
private boolean nullable;
private Table table;
private Pk pk;
private Fk fk;
public Column(String name, String typeName, int typeSize,
boolean nullable) ... |
package anni.database;
import java.util.*;
public class Table {
private int x;
private int y;
private int width;
private int height;
private String name;
private Map<String, Column> columns = new HashMap<String, Column>();
private Map<String, Pk> pks = new HashMap<String, Pk>(... |
package anni.database;
import java.sql.*;
import java.util.*;
/**
* 1.读取所有外键,外键值放到Database里
* 2.获得所有表,表放到Database里
* 3.获得表里的列,根据主键和外键修改列,所有列放到表里
*
*/
public class Database {
// sql
private String driverName = "org.hsqldb.jdbcDriver";
private String username = "sa";
private Stri... |
package anni.database;
public class Pk {
private Column column;
public Pk(Column column) {
this.column = column;
}
public Column getColumn() {
return column;
}
public String toString() {
return "Pk[" + column.getName() + "]";
}
}
|
package anni.database;
public class Fk {
private Column pkColumn;
private Column fkColumn;
private String name;
public Column getPkColumn() {
return pkColumn;
}
public void setPkColumn(Column pkColumn) {
this.pkColumn = pkColumn;
}
public Column getFkCo... |
package anni;
import java.io.*;
import java.sql.*;
import java.text.*;
import java.util.*;
import anni.database.*;
import anni.model.*;
import anni.ui.*;
public class EntityRelationship {
private Database database;
public EntityRelationship(Database database) {
this.databa... |
package anni.ui;
import java.io.*;
import anni.model.*;
public class FkUI {
public void renderScripts(FkModel fkModel, PrintWriter out) {
out.println(" fks['" + fkModel.getName() + "'] = new Fk('"
+ fkModel.getName() + "', '" + fkModel.getFrom().getName()
+ "', '" +... |
package anni.ui;
import java.io.*;
import anni.model.*;
public class TableUI {
public void renderScripts(TableModel tableModel, PrintWriter out) {
String name = tableModel.getName();
double x = tableModel.getX();
double y = tableModel.getY();
double w = tableModel.get... |
package anni.ui;
import java.io.*;
import java.util.*;
import anni.model.*;
public class UIManager {
private Map<String, TableModel> tableModels = new HashMap<String, TableModel>();
private List<FkModel> fkModels = new ArrayList<FkModel>();
private TableUI tableUI = new TableUI();
priv... |
package ${pkg}.manager;
import ${pkg}.domain.${pojo};
import anni.core.dao.ECHibernateEntityDao;
/**
* @author Lingo.
* @since ${now?string("yyyy年MM月dd日 a HH时mm分ss秒S")}
*/
public class ${pojo}Manager extends ECHibernateEntityDao<${pojo}> {
}
|
package ${webPackage};
import anni.core.web.prototype.ExtendController;
/**
* @author Lingo.
* @since ${now?string("yyyy年MM月dd日 a HH时mm分ss秒S")}
*/
public class AdminController extends ExtendController {
/**
* 后台首页.
*/
public void index() {
}
/**
* 后台上端菜单.
*/
... |
package ${pkg}.web;
import ${pkg}.manager.${pojo}Manager;
import ${pkg}.domain.${pojo};
import anni.core.web.prototype.BaseLongController;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
/**
* @author Lingo.
* @since ${now?string("yyyy年MM月dd日 a HH时mm分ss秒S")}
*/
pu... |
package ${webPackage};
import anni.core.web.prototype.ExtendController;
/**
* @author Lingo.
* @since ${now?string("yyyy年MM月dd日 a HH时mm分ss秒S")}
*/
public class IndexController extends ExtendController {
/**
* 首页.
*/
public void index() {
}
}
|
package anni.tools;
import java.io.*;
import java.util.*;
import freemarker.template.*;
public class FreemarkerUtils {
public static void process(String templatePath,
Map model,
String destDirPath,
String destFileName) throws Exception {
process(templat... |
package anni.tools;
import java.io.*;
import java.util.*;
import java.util.regex.*;
import jxl.*;
@SuppressWarnings("unchecked")
public class GenHibernateReveng {
static String basedir = null;
static String inputFileName = null;
static String packageName = null;
static String prefix = nu... |
package anni.tools;
import java.io.*;
public class FileUtils {
public static void copy(String src, String dest) throws Exception {
copy(new File(src), new File(dest));
}
public static void copy(File src, File dest) throws Exception {
if (!dest.getParentFile().exists()) {
... |
package anni.tools;
import java.io.*;
import java.util.*;
import java.util.regex.*;
import jxl.*;
@SuppressWarnings("unchecked")
public class GenXml {
static String basedir = null;
static String inputFileName = null;
static String packageName = null;
static String projectName = null;
... |
package anni.tools;
import java.io.*;
import java.lang.reflect.*;
import java.text.*;
import java.util.*;
import freemarker.template.*;
import jxl.*;
@SuppressWarnings("unchecked")
public class GenFreemarker {
Template index = null;
Template edit = null;
Template list = null;
String ge... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.