The moment 2 parties agree on a repo, they finalize 2 numbers
– The Price is the amount paid for the security at the “opening” leg
– The Rate is the interest to be paid at the “closing” leg
For a common repo, the opening leg is a spot trade, so price is comparable to the market price of the security, but negotiable if it's illiquid.
A repo can also be forward-start. Price would be a forward price.
Routed events have a bit of theory behind it. Routing theory perhaps?
One of the (top 3?) essential jobs of xaml is linking up the GUI event handlers. These event handlers are essential and found in every GUI toolkit. WPF event handlers are often implemented as instance methods in the xaml class. The xaml xml can specify a handler method by unqualified method name like a bare-word.
A bit of history on the “event” concept. In swing and other GUI, an event instance is a single occurrence of a … say a button click (or mouse-over or a special key combination). In dotnet, an event is conceptually a (usually non-static) field holding a functor. In GUI, such an event often points to an instance method of the xaml class behind the xaml. So I feel in a dotnet gui an event in a xaml screen is like “a specific type of user action”, like a click on ButtonA. WPF uses a supercharged kind of event, built on top of the CLR event. We are talking about routed event.
To understand routed event, we better bear in mind that a xaml defines a screen, built with a tree of visuals in a containment hierarchy. Such a hierarchy is also essential in Swing.
When a user action happens, the WPF “Hollywood” typically raises 2 routed events — 1) a tunneling version then 2) a bubbling version. Tunneling events are named Preview_*, and designed to fire before the bubbling event. [[illustrated wpf]] shows a simple example. Upon a click, first the tunnel event hits outer container, then the inner image, and then a second event, the bubble event, hits the inner image then the outer container. Both the inner and outer visual object define event handlers for the click, adding up to 4 event handler methods in the code behind. Therefore we we see 4 log messages.
This is all standard behavior of “Hollywood”. It provides flexibility that you can opt out. You can disable any of the 4 event handlers, and an earlier tunneling event handler can stop the propagation of the tunneling event (ditto bubble), but often you want to give outermost container the first chance to react, before the children. “
This gives the container the power to see an event before its children“, as someone pointed out on http://stackoverflow.com/questions/1107922/wpf-routed-events-tunneling-and-bubbling. Here’s my sound byte –
In the preview (tunneling) phase, container gets the preview before the children
When WPF creators came up with the command infrastructure, they had some competing designs, motivations, trade-off etc. http://msdn.microsoft.com/en-us/library/ms752308.aspx pointed out 2 major driving forces. Here’s my wording, not the original wording
2) enable/disable the Multiple CommandSources at once.
Various authors also touched on these 2 concepts among other concepts. I find it extremely insightful to single out these 2 primary purposes.
Let me elaborate a bit ….
We often write lookup procedures to return a single joined record.
Better distinguish between these scenarios below. The same stored proc
– returns 0-row
– return a special value to indicate 0-row
– return a null value for a field
– return a default value
If possible, I generally avoid returning null value, because they
require extra parsing in java. Besides, null values can be a consequence
of many scenarios — ambiguous.
If the one and only select from the proc simply selects a bunch of
variables, then 0-row won’t happen. How do you indicate 0-row? A very
common scenario. I often use a @rowct variable, that’s updated by the
earlier table selects. In this context, we can also put special values
into other fields to indicate 0-row.
If you want the caller to know it’s 0-row, null or default value, when
all scenarios are possible.
– then choosing a default value can be tricky
– null can be tricky because in the @rowct case, a lot of fields of the
last select might be null.
Many new web frameworks rely on the dual.
– Rich Faces
Singapore is a trickier work place than US. It would be great to find a mentor and a protective manager.
I usually have good rapport with users, but it's possible that I may not jell well with some traders and some colleagues.
I hope to fall back on my ability to get-things-done and my system knowledge so they would feel it's hard to find someone to replace me.