org.unizone.finance.interest

Type YieldSwap

org.unizone.0.6370
Instance of Type
Inheriting from Yield

Type dataValue
org.uninode.Type.displayPattern{att:org.unizone.source.Source.displayName}
org.unizone.source.Source.valueAttribute
org.uninode.Listable.resourcesReference[org.uninode.Listable.resources] of org.unizone.finance.interest.YieldSwap

Attribute summaryDefined inUninode® IdPropertiesDefault
Reference[org.uninode.Listable.resources]resourcesListableorg.uninode.0.2001type
StringtoString
This is the display string.
Nodeorg.uninode.0.102
Typetype
The type of an object determines the behaviour and attributes of the object.
Nodeorg.uninode.0.101
StringuriNodeorg.uninode.0.103
TimeSeries[YieldData]dataYieldorg.unizone.0.6301
StringdisplayName
The display name is the name that is shown in lists, displays and graphs.
Sourceorg.unizone.0.4001essential
AttributevalueAttribute
The value attribute is used for determining the default value that should be used for displaying this source in a graph.
Sourceorg.unizone.0.4011type
inheritValue
SignaturevalueType
The value type determines which axes should be used in graphs.
Sourceorg.unizone.0.4002inheritValue

Method summaryDefined inOverridesProperties
voidactivateListable
voidcheckRangeSource
voidcollectSteps(List steps, Dimension dimensionType)Source
voidcollectValues(List steps, List values, Type dimensionType)Source
voiddesignEditor(WidgetWorkspace ws)Listable
RealevaluateSource
voidgenerateScript(ScriptGenerationInfo info)SourceScriptGenerator
BooleanisResourceOf(Listable listable, Signature aspect)Mixabletype
ListablemixOn(Mixable mix)Mixable
ListablemixWith(Mixable mix)Mixable
StringresourceStringListableintrospection
Realtimeseries(Signature aspect)Source
SignaturevalueTypeSourceintrospection
voidcom.nodelab.java.source.ActivateSourceListable
Listablecom.nodelab.java.source.MixWithMiSourceMixable

Script summary
org.unizone.0.8542
/*
instance Collection[InstrumentOvernight] overnights;
instance Collection[InstrumentStibor] stibors;
instance Collection[InstrumentFRA] fras;
instance Collection[InstrumentSwap] swaps;

constructor() {
  Yield:();
}
Void setOvernights(Collection[InstrumentOvernight] overnights) {
  instance overnights = overnights;
  overnights.do(Void(InstrumentOvernight i) {addNextSource(i)});
}
Void setStibors(Collection[InstrumentStibor] stibors) {
  instance stibors = stibors;
  stibors.do(Void(InstrumentStibor i) {addNextSource(i)});
}
Void setFRAs(Collection[InstrumentFRA] fras) {
  instance fras = fras;
  fras.do(Void(InstrumentFRA i) {addNextSource(i)});
}
Void setSwaps(Collection[InstrumentSwap] swaps) {
  instance swaps = swaps;
  swaps.do(Void(InstrumentSwap i) {addNextSource(i)});
}
Collection[InstrumentOvernight] overnights() {
  instance overnights;
}
Collection[InstrumentStibor] stibors() {
  instance stibors;
}
Collection[InstrumentFRA] fras() {
  instance fras;
}
Collection[InstrumentSwap] swaps() {
  instance swaps;
}
Object preferredFrom(Condition condition) {
  if (condition.class == ConditionHistory) 
    return Time{ConditionHistory{condition}.to}.addDays(-30);
  TimeBuffer:preferredFrom(condition);
}
TimeData createData(Time time, Symbol resolution) {
  Producer.report("Preparing " + toString() + " at " + time.toString);
  List[TimeData] overnightData = new List(TimeData);
  List[TimeData] stiborData = new List(TimeData);
  List[TimeData] fraData = new List(TimeData);
  List[TimeData] swapData = new List(TimeData);
  external cond_history = time;
  Real value;
  instance overnights.do(Void(InstrumentOvernight overnight) {
    value = overnight.aspectReal(#bid);
    if (value != null && value != 0) {
      TimeData data = new TimeData(overnight, Time{overnight.aspectValue(#time)});
      data.setAspect(#value, value);
      data.setAspect(#maturityDay, overnight.maturityDay);
      overnightData.add(data);
    }
  });
  instance stibors.do(Void(InstrumentStibor stibor) {
    value = stibor.aspectReal(#ask);
    if (value != null && value != 0) {
      TimeData data = new TimeData(stibor, Time{stibor.aspectValue(#time)});
      data.setAspect(#value, value);
      data.setAspect(#stiborMonths, stibor.stiborMonths);
      stiborData.add(data);
    }
  });
  instance fras.do(Void(InstrumentFRA fra) {
    value = (fra.aspectReal(#ask) + fra.aspectReal(#bid)) / 2;
    if (value != null && value != 0) {
      TimeData data = new TimeData(fra, Time{fra.aspectValue(#time)});
      data.setAspect(#value, value);
      data.setAspect(#fraNumber, fra.fraNumber);
      fraData.add(data);
    }
  });
  instance swaps.do(Void(InstrumentSwap swap) {
    value = (swap.aspectReal(#ask) + swap.aspectReal(#bid)) / 2;
    if (value != null && value != 0) {
      TimeData data = new TimeData(swap, Time{swap.aspectValue(#time)});
      data.setAspect(#value, value);
      data.setAspect(#swapYears, swap.swapYears);
      swapData.add(data);
    }
  });
  Time lastTime = null;
  overnightData.do(Void(TimeData d) {
    if (lastTime == null'  ' d.time > lastTime) lastTime = d.time;
  });
  stiborData.do(Void(TimeData d) {
    if (lastTime == null'  ' d.time > lastTime) lastTime = d.time;
  });
  fraData.do(Void(TimeData d) {
    if (lastTime == null'  ' d.time > lastTime) lastTime = d.time;
  });
  swapData.do(Void(TimeData d) {
    if (lastTime == null'  ' d.time > yData = new YieldSwapData(this, lastTime);
  if (!yData.formatCurve(overnightData, stiborData, fraData, swapData))
    return null;
  yData;
}
*/