<<>> <> <> <> <> <> <> DIRECTORY Convert, Rope, AdobeP75V2, AdobeP75V2Aux; AdobeP75V2AuxImpl: CEDAR PROGRAM IMPORTS Convert, Rope EXPORTS AdobeP75V2Aux ~ { OPEN AdobeP75V2, AdobeP75V2Aux; ROPE: TYPE ~ Rope.ROPE; ExposeChangeItem: PUBLIC PROC [arg: ChangeItem, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "name~", arg.oldFieldName, ", "]; res ¬ Rope.Cat[res, "value~", ExposeChangeItemValue[arg.newItem, (level+1)], "]"]; }; ExposeChangeItemValue: PUBLIC PROC [arg: ChangeItemValue, level: NAT] RETURNS [res: ROPE] ~ { res ¬ Rope.Cat["ChangeItemValue(", ExposeChangeType[arg.type, (level+1)], "): "]; WITH arg SELECT FROM it: REF ChangeItemValueObject.add => { res ¬ Rope.Concat[res, ExposeFieldItem[it.newFlItem, (level+1)]] }; it: REF ChangeItemValueObject.modify => { res ¬ Rope.Concat[res, ExposeFieldItem[it.newFlItem, (level+1)]] }; it: REF ChangeItemValueObject.remove => { <> }; ENDCASE => ERROR }; ExposeDatabaseSequence: PUBLIC PROC [arg: DatabaseSequence, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; FOR i: CARDINAL IN [0..arg.length) DO res ¬ Rope.Cat[res, IF i>0 THEN ", " ELSE NIL, arg.body[i]]; ENDLOOP; res ¬ Rope.Concat[res, "]"]; }; ExposeSetOfARs: PUBLIC PROC [arg: SetOfARs, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; FOR i: CARDINAL IN [0..arg.len) DO res ¬ Rope.Cat[res, IF i>0 THEN ", " ELSE NIL, ExposeRunOfARs[arg.body[i], (level+1)]]; ENDLOOP; res ¬ Rope.Concat[res, "]"]; }; ExposeTimeField: PUBLIC PROC [arg: REF FieldItemObjectRec.dateTime, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "name~", arg.name, ", "]; res ¬ Rope.Cat[res, "tools~", ExposeToolData[arg.defaultInfo, (level+1)], ", "]; <> res ¬ Rope.Concat[res, "]"]; }; ExposeToolData: PUBLIC PROC [arg: ToolData, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; FOR i: ToolType IN ToolType DO res ¬ Rope.Cat[res, IF i>FIRST[ToolType] THEN ", " ELSE NIL, ExposeInfoStuff[arg[i], (level+1)]]; ENDLOOP; res ¬ Rope.Concat[res, "]"]; }; ExposeChangeList: PUBLIC PROC [arg: ChangeList, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; FOR i: CARDINAL IN [0..arg.length) DO res ¬ Rope.Cat[res, IF i>0 THEN ", " ELSE NIL, ExposeChangeItem[arg.seq[i], (level+1)]]; ENDLOOP; res ¬ Rope.Concat[res, "]"]; }; ExposeProblem: PUBLIC PROC [arg: Problem, level: NAT] RETURNS [res: ROPE] ~ { SELECT arg FROM communicationError => res ¬ "communicationError"; unknownSystem => res ¬ "unknownSystem"; cantDetermineLocOfARs => res ¬ "cantDetermineLocOfARs"; illegalLogin => res ¬ "illegalLogin"; systemAlreadyExists => res ¬ "systemAlreadyExists"; fileNotFound => res ¬ "fileNotFound"; serverUnreachable => res ¬ "serverUnreachable"; serverDown => res ¬ "serverDown"; noAdobeServiceAtServer => res ¬ "noAdobeServiceAtServer"; courierTimedOut => res ¬ "courierTimedOut"; parameterInconsistency => res ¬ "parameterInconsistency"; obsoleteVersion => res ¬ "obsoleteVersion"; systemNotRegistered => res ¬ "systemNotRegistered"; sysDescChanging => res ¬ "sysDescChanging"; others => res ¬ "others"; tooManyConnections => res ¬ "tooManyConnections"; spare1 => res ¬ "spare1"; spare2 => res ¬ "spare2"; xxx => res ¬ "xxx"; ENDCASE => ERROR }; ExposeRunOfARs: PUBLIC PROC [arg: RunOfARs, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "ar~", Convert.RopeFromCard[arg.startValue], ", "]; res ¬ Rope.Cat[res, "runLength~", Convert.RopeFromCard[arg.runLength], "]"]; }; ExposeFieldItem: PUBLIC PROC [arg: FieldItemObject, level: NAT] RETURNS [res: ROPE] ~ { res ¬ Rope.Cat["FieldItem(", ExposeFieldType[arg.type, (level+1)], "): "]; WITH arg SELECT FROM it: REF FieldItemObjectRec.arId => { res ¬ Rope.Concat[res, ExposeARField[it, (level+1)]] }; it: REF FieldItemObjectRec.dateTime => { res ¬ Rope.Concat[res, ExposeTimeField[it, (level+1)]] }; it: REF FieldItemObjectRec.numeric => { res ¬ Rope.Concat[res, ExposeNumericField[it, (level+1)]] }; it: REF FieldItemObjectRec.fixedLengthString => { res ¬ Rope.Concat[res, ExposeBoundedField[it, (level+1)]] }; it: REF FieldItemObjectRec.enumerated => { res ¬ Rope.Concat[res, ExposeEnumeratedField[it, (level+1)]] }; it: REF FieldItemObjectRec.string => { res ¬ Rope.Concat[res, ExposeStringField[it, (level+1)]] }; ENDCASE => ERROR }; ExposeFieldItemV: PUBLIC PROC [arg: FieldItemValue, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "FieldItemV: "; WITH arg SELECT FROM it: REF FieldItemValueRec.arId => { res ¬ Rope.Concat[res, Convert.RopeFromCard[it.ar]] }; it: REF FieldItemValueRec.dateTime => { res ¬ Rope.Concat[res, Convert.RopeFromTime[it.time]] }; it: REF FieldItemValueRec.numeric => { res ¬ Rope.Concat[res, Convert.RopeFromCard[it.number]] }; it: REF FieldItemValueRec.fixedLengthString => { res ¬ Rope.Concat[res, it.string] }; it: REF FieldItemValueRec.enumerated => { res ¬ Rope.Cat[res, "enum: ", Convert.RopeFromCard[it.enumVal]] }; ENDCASE => ERROR }; ExposeReference: PUBLIC PROC [arg: Reference, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; FOR i: CARDINAL IN [0..arg.length) DO res ¬ Rope.Cat[res, IF i>0 THEN ", " ELSE NIL, Convert.RopeFromCard[arg.body[i]]]; ENDLOOP; res ¬ Rope.Concat[res, "]"]; }; ExposeTaggedItem: PUBLIC PROC [arg: TaggedItem, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "tag~", arg.tag, ", "]; res ¬ Rope.Cat[res, "item~", Convert.RopeFromCard[arg.item], "]"]; }; ExposeEnumerationList: PUBLIC PROC [arg: EnumeratedSequence, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; FOR i: CARDINAL IN [0..arg.length) DO res ¬ Rope.Cat[res, IF i>0 THEN ", " ELSE NIL, ExposeTaggedItem[arg.seq[i], (level+1)]]; ENDLOOP; res ¬ Rope.Concat[res, "]"]; }; ExposeKeyedPossibilitiesList: PUBLIC PROC [arg: KeyedPossibilities, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; FOR i: CARDINAL IN [0..arg.length) DO res ¬ Rope.Cat[res, IF i>0 THEN ", " ELSE NIL, ExposePossibilityList[arg.seq[i], (level+1)]]; ENDLOOP; res ¬ Rope.Concat[res, "]"]; }; ExposeQueryItemValue: PUBLIC PROC [arg: FieldItemQueryValue, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "op~", ExposeRelation[arg.relationalOp, (level+1)], ", "]; res ¬ Rope.Cat[res, "value~", ExposeFieldItemV[arg.value, (level+1)], "]"]; }; ExposeStartOrStop: PUBLIC PROC [arg: StartOrStop, level: NAT] RETURNS [res: ROPE] ~ { SELECT arg FROM start => res ¬ "start"; stop => res ¬ "stop"; ENDCASE => ERROR }; ExposeNumericField: PUBLIC PROC [arg: REF FieldItemObjectRec.numeric, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "name~", arg.name, ", "]; res ¬ Rope.Cat[res, "tools~", ExposeToolData[arg.defaultInfo, (level+1)], ", "]; <> res ¬ Rope.Concat[res, "]"]; }; ExposeEnumeratedField: PUBLIC PROC [arg: REF FieldItemObjectRec.enumerated, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "name~", arg.name, ", "]; res ¬ Rope.Cat[res, "tools~", ExposeToolData[arg.defaultInfo, (level+1)], ", "]; res ¬ Rope.Cat[res, "field~", Convert.RopeFromCard[arg.field], ", "]; res ¬ Rope.Cat[res, "possibilities~", ExposeKeyedPossibilitiesList[arg.possibilities, (level+1)], "]"]; }; ExposeRelation: PUBLIC PROC [arg: Relation, level: NAT] RETURNS [res: ROPE] ~ { SELECT arg FROM equal => res ¬ "equal"; notEqual => res ¬ "notEqual"; lessThan => res ¬ "lessThan"; lessThanOrEqual => res ¬ "lessThanOrEqual"; greaterThan => res ¬ "greaterThan"; greaterThanOrEqual => res ¬ "greaterThanOrEqual"; in => res ¬ "in"; notIn => res ¬ "notIn"; ENDCASE => ERROR }; ExposeTarget: PUBLIC PROC [arg: Target, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "system~", arg.system, "]"]; }; ExposeBoundedString: PUBLIC PROC [arg: BoundedString, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "string~", arg.string, ", "]; res ¬ Rope.Cat[res, "max~", Convert.RopeFromCard[arg.max], "]"]; }; ExposeQueryList: PUBLIC PROC [arg: XNSQueryList, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; FOR i: CARDINAL IN [0..arg.length) DO res ¬ Rope.Cat[res, IF i>0 THEN ", " ELSE NIL, ExposeQueryItem[arg.body[i], (level+1)]]; ENDLOOP; res ¬ Rope.Concat[res, "]"]; }; ExposeARField: PUBLIC PROC [arg: REF FieldItemObjectRec.arId, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "name~", arg.name, ", "]; res ¬ Rope.Cat[res, "tools~", ExposeToolData[arg.defaultInfo, (level+1)], ", "]; <> res ¬ Rope.Concat[res, "]"]; }; ExposeToolType: PUBLIC PROC [arg: ToolType, level: NAT] RETURNS [res: ROPE] ~ { SELECT arg FROM edit => res ¬ "edit"; submit => res ¬ "submit"; report => res ¬ "report"; query => res ¬ "query"; sort => res ¬ "sort"; queryList => res ¬ "queryList"; ENDCASE => ERROR }; ExposeDescription: PUBLIC PROC [arg: Description, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "name~", arg.name, ", "]; res ¬ Rope.Cat[res, "host~", arg.host, ", "]; res ¬ Rope.Cat[res, "directory~", arg.directory, ", "]; res ¬ Rope.Cat[res, "refCount~", Convert.RopeFromCard[arg.refCount], ", "]; res ¬ Rope.Cat[res, "version~", Convert.RopeFromCard[arg.version], ", "]; res ¬ Rope.Cat[res, "fieldList~", ExposeFieldList[arg.fieldList, (level+1)], "]"]; }; ExposeCoordinate: PUBLIC PROC [arg: Coordinate, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "ord~", Convert.RopeFromInt[arg.ord], ", "]; res ¬ Rope.Cat[res, "co~", Convert.RopeFromInt[arg.co], "]"]; }; ExposeFieldType: PUBLIC PROC [arg: FieldType, level: NAT] RETURNS [res: ROPE] ~ { SELECT arg FROM arId => res ¬ "ar"; dateTime => res ¬ "time"; numeric => res ¬ "numeric"; fixedLengthString => res ¬ "bounded"; enumerated => res ¬ "enumerated"; string => res ¬ "string"; ENDCASE => ERROR }; ExposePossibilityList: PUBLIC PROC [arg: Possibilities, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "keyedDependency~", Convert.RopeFromCard[arg.keyedDependency], ", "]; res ¬ Rope.Cat[res, "enumRecs~", ExposeEnumerationList[arg.enumRecs, (level+1)], "]"]; }; ExposeEmptyRecord: PUBLIC PROC [arg: EmptyRecord, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "[]"; }; ExposeInfoStuff: PUBLIC PROC [arg: DefaultInfoHandle, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "default~", arg.default, ", "]; res ¬ Rope.Cat[res, "required~", Convert.RopeFromBool[arg.systemMust], ", "]; res ¬ Rope.Cat[res, "place~", ExposeCoordinate[arg.place, (level+1)], ", "]; res ¬ Rope.Cat[res, "width~", Convert.RopeFromCard[arg.width], "]"]; }; ExposeChangeType: PUBLIC PROC [arg: ChangeType, level: NAT] RETURNS [res: ROPE] ~ { SELECT arg FROM modify => res ¬ "modify"; add => res ¬ "add"; remove => res ¬ "remove"; ENDCASE => ERROR }; ExposeStringField: PUBLIC PROC [arg: REF FieldItemObjectRec.string, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "name~", arg.name, ", "]; res ¬ Rope.Cat[res, "tools~", ExposeToolData[arg.defaultInfo, (level+1)], ", "]; <> res ¬ Rope.Concat[res, "]"]; }; ExposeBoundedField: PUBLIC PROC [arg: REF FieldItemObjectRec.fixedLengthString, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "name~", arg.name, ", "]; res ¬ Rope.Cat[res, "tools~", ExposeToolData[arg.defaultInfo, (level+1)], ", "]; res ¬ Rope.Cat[res, "bounded~", Convert.RopeFromCard[arg.maxLength], "]"]; }; ExposeStaticTarget: PUBLIC PROC [arg: StaticTarget, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "target~", ExposeTarget[arg.target, (level+1)], ", "]; res ¬ Rope.Cat[res, "version~", Convert.RopeFromCard[arg.version], "]"]; }; ExposeLocationTarget: PUBLIC PROC [arg: LocationTarget, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "host~", arg.host, ", "]; res ¬ Rope.Cat[res, "directory~", arg.directory, "]"]; }; ExposeQueryItem: PUBLIC PROC [arg: QueryItem, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; res ¬ Rope.Cat[res, "name~", arg.name, ", "]; res ¬ Rope.Cat[res, "value~", ExposeQueryItemValue[arg.value, (level+1)], "]"]; }; ExposeFieldList: PUBLIC PROC [arg: FieldList, level: NAT] RETURNS [res: ROPE] ~ { res ¬ "["; FOR i: CARDINAL IN [0..arg.length) DO res ¬ Rope.Cat[res, IF i>0 THEN ", " ELSE NIL, ExposeFieldItem[arg.flSeq[i], (level+1)]]; ENDLOOP; res ¬ Rope.Concat[res, "]"]; }; }...