MCPcopy Create free account
hub / github.com/SeaOfNodes/Simple / add

Method add

chapter21/src/main/java/com/seaofnodes/simple/Ary.java:57–61  ·  view source on GitHub ↗

Add element in amortized constant time @param e Element to add at end of list @return true

( E e )

Source from the content-addressed store, hash-verified

55 * @param e Element to add at end of list
56 * @return true */
57 public boolean add( E e ) {
58 if( _len >= _es.length ) _es = Arrays.copyOf(_es,Math.max(1,_es.length<<1));
59 _es[_len++] = e;
60 return true;
61 }
62
63 /** Fast, constant-time, element removal. Does not preserve order
64 * @param i element to be removed

Callers 15

addAllMethod · 0.95
basicBlockLayoutMethod · 0.95
_rpo_cfgMethod · 0.95
_prettyPrintScheduledMethod · 0.95
runMethod · 0.45
evaluateMethod · 0.45
doScheduleMethod · 0.45
doBuildCTFMethod · 0.45
buildMethod · 0.45
ScriptGeneratorClass · 0.45
addVariableMethod · 0.45
getTypeMethod · 0.45

Calls

no outgoing calls

Tested by 9

runMethod · 0.36
evaluateMethod · 0.36
doScheduleMethod · 0.36
doBuildCTFMethod · 0.36
buildMethod · 0.36
addVariableMethod · 0.36
getTypeMethod · 0.36
genStructMethod · 0.36
recordExceptionMethod · 0.36