edu.isi.stella
Class OutputStream

java.lang.Object
  extended by edu.isi.stella.Stella_Object
      extended by edu.isi.stella.StandardObject
          extended by edu.isi.stella.Stream
              extended by edu.isi.stella.OutputStream
Direct Known Subclasses:
OutputFileStream, OutputStringStream

public class OutputStream
extends Stream


Field Summary
 java.io.PrintStream nativeStream
           
 
Fields inherited from class edu.isi.stella.Stream
state
 
Constructor Summary
OutputStream()
           
 
Method Summary
static void clOutputEnsurePackageDefinition(OutputStream stream, java.lang.String renamed_Package)
           
static void clOutputFileHeader(OutputStream stream, java.lang.String file, boolean ensurepackageP)
           
static void clOutputInPackageDeclaration(OutputStream stream, java.lang.String renamed_Package)
           
static void cppOutputFileHeader(OutputStream stream, java.lang.String file)
           
static void flushOutput(OutputStream self)
          Flush all buffered output of self.
 void free()
          Default method.
static void javaOutputFileHeader(OutputStream stream, java.lang.String filename)
           
static OutputStream newOutputStream()
           
static void outputCopyrightHeader(OutputStream stream)
           
static void outputFileHeader(OutputStream stream, java.lang.String file)
           
static void prettyPrintMethodParameters(OutputStream stream, MethodSlot method)
           
static void prettyPrintSlotBlock(OutputStream stream, Iterator iterator, java.lang.String slotgroup)
           
 Surrogate primaryType()
          Returns the primary type of self.
static void printXmlElementAttributes(OutputStream stream, Cons attributes)
           
static void printXmlExpression(OutputStream stream, Cons xmlExpression, int indent)
          Prints xmlExpression on stream.
static void printXmlNonElementAttributes(OutputStream stream, Cons attributes)
           
static void saveConfigurationValue(OutputStream stream, Stella_Object value)
          Save value to stream as a properly formatted configuration value.
static boolean terminateOutputStreamP(OutputStream self)
           
 
Methods inherited from class edu.isi.stella.Stream
accessStreamSlotValue, closeStream
 
Methods inherited from class edu.isi.stella.StandardObject
arrayTypeSpecifierP, baseTypeToTypeSpec, cantOverwriteActiveCollectionSlot, compatibleParameterTypesP, computeAnchoredTypeSpec, computeRelativeTypeSpec, conformingTypeSpecP, copyWrappedLiteral, cppReferenceTypeP, cppReferencizeType, cppTranslateAndPointerizeTypeSpec, cppTranslateAndReferencizeTypeSpec, cppTranslateTypeSpec, dropSlotValue, extractParameterType, extractRequiredArgumentValues, getSlot, hashCode_, idlTranslateTypeSpec, inverseSlotDemon, javaLiteralP, javaNativeLiteralWrapperNames, javaSpecialSetterName, javaTranslateArrayOfTypeSpec, javaTranslateTypeSpec, javaTranslateTypeSpecForFunction, javaTranslateTypeSpecHelper, javaYieldClassObjectArrayExpression, javaYieldClassObjectExpression, javaYieldFullyQualifiedTypeName, javaYieldTranslatedClassAndMethodNames, listifyTypeSpec, lookupClTypeFromStellaType, objectEqlP, putSlotValue, readSlotValue, runConstructorDemons, runDestructorDemons, runSlotDemons, runSlotGuardDemonsP, standardObjectP, subTypeSpecOfP, twoArgumentLeastCommonSupertype, typeSpecToBaseType, typeSpecToClass, typeToWalkedNullValueTree, validateTypeSpecifier, voidP, walkTypeSpecIsNativeTypeP, writeSlotValue, yieldTypeSpecTree
 
Methods inherited from class edu.isi.stella.Stella_Object
_, accessInContext, amPm, anchoredTypeSpecifierP, andOrNotTreeP, applyCoercionMethod, atomicExpressionP, bindToSurrogateP, booleanP, bootstrapIsaP, bquotify, cast, characterP, clTranslateAtomicTree, clTranslateATree, clTranslateBooleanTest, clTranslatePlainBooleanTest, clTranslateVerbatimBodySymbols, clYieldTypedExpressionTree, coerceATree, coerceEvaluatedTree, coerceMvTree, coerceToBoolean, coerceToModule, coerceToModuleName, coerceToSymbol, coerceToXmlElement, coercibleP, collectFeatureList, collectKeyValueList, commonLispSymbolP, computeExpressionType, cons, consify, consifyListsAndIterators, consP, consTreeMatchP, convertToLiteral, copyConsTree, cppArgumentIsStreamP, cppBinaryOperatorP, cppBlockP, cppMaybeOutputStatementWithParentheses, cppOperatorP, cppOutputAtomicExpression, cppOutputLiteral, cppOutputOneActualParameter, cppOutputStatement, cppOutputTypedEntity, cppPrognifyStatement, cppPrognP, cppStatementToList, cppStreamIsStandardOutputP, cpptrans, cppTranslateAtomicTree, cppTranslateATree, cppTranslatedArrayTypeP, csValueP, dateDivider, dateTimeDivider, day, dealWithAmPm, dealWithEra, dealWithNoonMidn, decrementReferenceCount, defaultOptionHandler, defineSystem, defmodule, deletedP, describe, describeObject, describeTersely, destructureMethodNameTree, deUglifyParseTree, either, eqlP, eqlToBooleanP, eqlToCharacterP, eqlToFloatP, eqlToIntegerP, eqlToStringP, equalConsTreesP, equalHashCode, equalP, era, estimatedEvaluationCost, evaluate, evaluateArgumentTree, evaluateAtomicTree, evaluateCommand, expandBquoteTree, filterModuleP, floatP, get, getObject, hashlist, hashMemoizedArguments, helpBquotify, helpClTranslateATree, helpCoerceATree, helpLptrans, helpPrintOutline, helpTransformBooleanProceduralExpression, helpWalkATree, homeModule, hour, idlOutputAtomicExpression, idlOutputLiteral, idlOutputStatement, idlTranslateAtomicTree, idlTranslateATree, illegalTreeP, implodePathname, incrementallyTranslate, incrementReferenceCount, inlineUnwrapBoolean, inlineWrapBoolean, inModule, integerP, isaP, javaBinaryOperatorP, javaBlockP, javaEndOfLineTokenP, javaHelpOutputPrintStream, javaMaybeOutputStatementWithParentheses, javaOperatorP, javaOutputLiteral, javaOutputStatement, javaPrognP, javaStreamIsStandardOutputP, javaSymbolCaseP, javaTranslateAtomicTree, javaTranslateATree, javaTranslateWithNativeWrapper, jptrans, keywordP, kvCons, legalTokenizerFromStateP, legalTokenizerStateP, legalTokenizerToStateP, literalEqlP, logLevelLE, lptrans, makeFileNameFromRelativePath, makeMemoizedValueEntry, makeMemoizedValueEntryn, matchConsTree, methodSlotP, minute, month, nameToString, nilP, noonMidn, numberWrapperToFloat, objectEqualP, objectHashCode, one, oneI, onlyIf, parametricTypeSpecifierP, parseArrayDimensionsSpec, parseTokenizerCharacterSpec, parseTokenizerStateModifiers, permanentCopy, permanentify, permanentifyForm, po, prettyPrintLiteral, primaryClass, printObject, printOutline, printStellaCode, printStellaDefinition, printUndefinedSuperClasses, proceduralExpressionP, ptrans, publicSlots, registerRecycledItem, runOptionHandlerP, safeEqualHashCode, safeHashCode, safePrimaryType, safeYieldTypeSpecifier, searchConsTreeP, searchConsTreeWithFilterP, searchForObject, secondp, sideEffectFreeExpressionP, simplifyBquoteTree, specialp, stella_Increment, stellaClassP, stellaCollectionP, stellaNeedToCompileP, stellaNeedToTranslateP, stellaObjectP, stellify, storageSlotP, stringifyInModule, stringP, substituteConsTree, substituteOnce, surrogateP, surrogatify, sweep, symbolCaseP, symbolP, sysTree, targetLanguageType, taxonomyIsaP, timeDivider, timeMultiply, tokenizerIncludeSpecP, tokenizerToStateAlias, tokenizerToStateName, toString, traceIf, traceKeywordP, transientifyForm, transientObjectP, transientSymbolP, translateWalkedTree, treeSize, treeToTrees, trueOptionP, tryToEvaluate, typeP, typify, unmake, unregisterRecycledItem, updateInContext, valuesTreeP, variableExpressionP, verbatimStringP, verbatimTreeP, vetOptions, vrletExpressionP, walkAtomicTree, walkATree, walkCollectionTree, walkDontCallMeTree, walkedExpressionType, walkExpressionTree, walkMvExpressionTree, walkMvTree, walkStatement, walkTopLevelExpression, walkWithoutTypeTree, warnAboutUnknownSourceType, weekday, withinContext, withinModule, withinWorld, withStellaTokenizer, withSystemDefinition, withTokenizer, wrapperP, wrapWhereTest, xmlAttributeP, xmlCdataFormP, xmlCdataP, xmlDeclarationFormP, xmlDeclarationP, xmlDoctypeFormP, xmlElementFormP, xmlElementP, xmlnsAttributeP, xmlProcessingInstructionFormP, xmlProcessingInstructionP, xmlTagCase, year, yieldCondTest, yieldCondTestOrTests, yieldHardcodedCaseSymbolIdOrIds, yieldInCursorClausesForArgumentList, yieldInCursorClausesForGeneralCollection, yieldInCursorClausesForVector, yieldTypeSpecifier, zone, zoneMinute
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

nativeStream

public java.io.PrintStream nativeStream
Constructor Detail

OutputStream

public OutputStream()
Method Detail

newOutputStream

public static OutputStream newOutputStream()

javaOutputFileHeader

public static void javaOutputFileHeader(OutputStream stream,
                                        java.lang.String filename)

cppOutputFileHeader

public static void cppOutputFileHeader(OutputStream stream,
                                       java.lang.String file)

prettyPrintSlotBlock

public static void prettyPrintSlotBlock(OutputStream stream,
                                        Iterator iterator,
                                        java.lang.String slotgroup)

prettyPrintMethodParameters

public static void prettyPrintMethodParameters(OutputStream stream,
                                               MethodSlot method)

saveConfigurationValue

public static void saveConfigurationValue(OutputStream stream,
                                          Stella_Object value)
Save value to stream as a properly formatted configuration value.

Parameters:
stream -
value -

outputFileHeader

public static void outputFileHeader(OutputStream stream,
                                    java.lang.String file)

outputCopyrightHeader

public static void outputCopyrightHeader(OutputStream stream)

printXmlExpression

public static void printXmlExpression(OutputStream stream,
                                      Cons xmlExpression,
                                      int indent)
Prints xmlExpression on stream. Indentation begins with the value of indent. If this is the null integer, no indentation is performed. Otherwise it should normally be specified as 0 (zero) for top-level calls.

It is assumed that the xmlExpression is a well-formed CONS-list representation of an XML form. It expects a form like that form returned by read_XML_expression.

Also handles a list of xml forms such as that returned by XML_expressions. In that case, each of the forms is indented by indent spaces.

Parameters:
stream -
xmlExpression -
indent -

printXmlElementAttributes

public static void printXmlElementAttributes(OutputStream stream,
                                             Cons attributes)

printXmlNonElementAttributes

public static void printXmlNonElementAttributes(OutputStream stream,
                                                Cons attributes)

clOutputInPackageDeclaration

public static void clOutputInPackageDeclaration(OutputStream stream,
                                                java.lang.String renamed_Package)

clOutputEnsurePackageDefinition

public static void clOutputEnsurePackageDefinition(OutputStream stream,
                                                   java.lang.String renamed_Package)

clOutputFileHeader

public static void clOutputFileHeader(OutputStream stream,
                                      java.lang.String file,
                                      boolean ensurepackageP)

flushOutput

public static void flushOutput(OutputStream self)
Flush all buffered output of self.

Parameters:
self -

terminateOutputStreamP

public static boolean terminateOutputStreamP(OutputStream self)

primaryType

public Surrogate primaryType()
Description copied from class: Stella_Object
Returns the primary type of self. Gets defined automatically for every non-abstract subclass of OBJECT.

Overrides:
primaryType in class Stella_Object
Returns:
Surrogate

free

public void free()
Description copied from class: Stella_Object
Default method. Deallocate storage for self.

Overrides:
free in class Stella_Object