本文整理汇总了Java中org.fleen.util.tree.TreeNodeIterator.hasNext方法的典型用法代码示例。如果您正苦于以下问题:Java TreeNodeIterator.hasNext方法的具体用法?Java TreeNodeIterator.hasNext怎么用?Java TreeNodeIterator.hasNext使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.fleen.util.tree.TreeNodeIterator
的用法示例。
在下文中一共展示了TreeNodeIterator.hasNext方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createNodes
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
protected boolean createNodes(ForsythiaComposition composition){
Jig jig;
boolean creatednodes=false;
TreeNodeIterator i=composition.getLeafPolygonIterator();
FPolygon leaf;
ForsythiaGrammar grammar=composition.getGrammar();
while(i.hasNext()){
leaf=(FPolygon)i.next();
if(isCapped(leaf))continue;
jig=selectJig(grammar,leaf);
if(jig==null){
cap(leaf);
}else{
jig.createNodes(leaf);
creatednodes=true;}}
jigbypolygonsig.clear();
return creatednodes;}
示例2: createNodes
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
private boolean createNodes(ForsythiaComposition composition){
Jig jig;
boolean creatednodes=false;
TreeNodeIterator i=composition.getLeafPolygonIterator();
FPolygon leaf;
ForsythiaGrammar grammar=composition.getGrammar();
while(i.hasNext()){
leaf=(FPolygon)i.next();
if(isCapped(leaf))continue;
jig=selectJig(grammar,leaf);
if(jig==null){
cap(leaf);
}else{
jig.createNodes(leaf);
creatednodes=true;}}
jigbypolygonsig.clear();
return creatednodes;}
示例3: createNodes
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
protected boolean createNodes(ForsythiaComposition composition){
Jig jig;
FPolygon leaf;
boolean creatednodes=false;
TreeNodeIterator i;
//random cap at level
if(buildcycleindex==6){
i=composition.getLeafPolygonIterator();
while(i.hasNext()){
leaf=(FPolygon)i.next();
if(rnd.nextDouble()<0.3)
cap(leaf);}}
//actual create nodes thing
ForsythiaGrammar grammar=composition.getGrammar();
i=composition.getLeafPolygonIterator();
while(i.hasNext()){
leaf=(FPolygon)i.next();
if(isCapped(leaf))continue;
jig=selectJig(grammar,leaf);
if(jig==null){
cap(leaf);
}else{
jig.createNodes(leaf);
creatednodes=true;}}
jigbypolygonsig.clear();
return creatednodes;}
示例4: getTreeString
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
public String getTreeString(){
StringBuffer a=new StringBuffer();
TreeNodeIterator i=new TreeNodeIterator(this);
ConnectedGraph cg;
while(i.hasNext()){
cg=(ConnectedGraph)i.next();
a.append(cg+"\n");}
a.append("\n");
return a.toString();}
示例5: getYardsForCGTreeRoot
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
private List<KYard> getYardsForCGTreeRoot(ConnectedGraph root){
List<KYard> yards=new ArrayList<KYard>();
TreeNodeIterator i=new TreeNodeIterator(root);
ConnectedGraph cg;
while(i.hasNext()){
cg=(ConnectedGraph)i.next();
yards.addAll(getYardsForCG(cg));}
return yards;}
示例6: getHeads
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
public List<ZPolygon> getHeads(){
List<ZPolygon> heads=new ArrayList<ZPolygon>();
TreeNodeIterator i=getLatticeIterator();
ZLattice lattice;
while(i.hasNext()){
lattice=(ZLattice)i.next();
heads.addAll(lattice.getHeads());}
return heads;}
示例7: getPoints
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
public Set<ZPoint> getPoints(){
Set<ZPoint> points=new HashSet<ZPoint>();
TreeNodeIterator i=getLatticeIterator();
ZLattice lattice;
while(i.hasNext()){
lattice=(ZLattice)i.next();
points.addAll(lattice.getPoints());}
return points;}
示例8: getPrimaryPoints
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
public Set<ZPoint> getPrimaryPoints(){
Set<ZPoint> points=new HashSet<ZPoint>();
TreeNodeIterator i=getLatticeIterator();
ZLattice lattice;
while(i.hasNext()){
lattice=(ZLattice)i.next();
points.addAll(lattice.getSoul().getPrimaryPoints());}
return points;}
示例9: getSegs
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
public Set<ZSeg> getSegs(){
Set<ZSeg> segs=new HashSet<ZSeg>();
TreeNodeIterator i=getLatticeIterator();
ZLattice lattice;
while(i.hasNext()){
lattice=(ZLattice)i.next();
segs.addAll(lattice.getSegs());}
return segs;}
示例10: getNodes
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
public List<ForsythiaTreeNode> getNodes(){
List<ForsythiaTreeNode> nodes=new ArrayList<ForsythiaTreeNode>();
TreeNodeIterator i=getNodeIterator();
while(i.hasNext())
nodes.add((ForsythiaTreeNode)i.next());
return nodes;}
示例11: getPolygons
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
public List<FPolygon> getPolygons(){
List<FPolygon> polygons=new ArrayList<FPolygon>();
TreeNodeIterator i=getPolygonIterator();
while(i.hasNext())
polygons.add((FPolygon)i.next());
return polygons;}
示例12: getLeafPolygons
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
public List<FPolygon> getLeafPolygons(){
List<FPolygon> polygons=new ArrayList<FPolygon>();
TreeNodeIterator i=getLeafPolygonIterator();
while(i.hasNext())
polygons.add((FPolygon)i.next());
return polygons;}
示例13: getLattices
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
public List<ZLattice> getLattices(){
List<ZLattice> lattices=new ArrayList<ZLattice>();
TreeNodeIterator i=getLatticeIterator();
while(i.hasNext())
lattices.add((ZLattice)i.next());
return lattices;}
示例14: getYards
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
public List<ZYard> getYards(){
List<ZYard> yards=new ArrayList<ZYard>();
TreeNodeIterator i=getYardIterator();
while(i.hasNext())
yards.add((ZYard)i.next());
return yards;}
示例15: clearPrimitiveGeometryCache
import org.fleen.util.tree.TreeNodeIterator; //导入方法依赖的package包/类
public void clearPrimitiveGeometryCache(){
TreeNodeIterator i=getLatticeIterator();
ZLattice lattice;
while(i.hasNext()){
lattice=(ZLattice)i.next();
lattice.clearPrimitiveGeometryCache();}}