首页 > 其他 > 详细

SAFS Distilled

时间:2015-04-09 13:40:17      阅读:194      评论:0      收藏:0      [点我收藏+]

In the org.safs.model, the class Component.java stores:

  •  information of this component‘s name
  •  reference of its parent, also a component
private String _name;
private Component _parent;

It provides interface to return its name, its parent‘s name and its parent‘s comopnent reference:

public String getName();

public Component getParent();   

public String getParentName();

 

 

 

In package org.safs.model, the Utils.java provides various functions used by other classes. For example:

/**
 * Wrap the provided val String in double-quotes.
 * @param val String to wrap in double-quotes
 * @return val wrapped in quotes or a double-quoted empty string if 
 * val was null.
 */
static public String quote(String val) {
    if (val == null) return "\"\"";
        return "\"" + val + "\"";
}   


public static String concat(String string1, String string2) {
    return string1 + "&" + string2;
}

 

SAFS Distilled

原文:http://www.cnblogs.com/kid551/p/4409017.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!