OpenGamma/OG-Platform — pull request #262 by stuartarchibald (2014-11-06 10:51:06+00:00)
Title: REQS-666/PLAT-6851 Stage 1

[REQS-666](https://opengamma.atlassian.net/browse/REQS-666) is a very heavy REQ, the first item is [PLAT-6851](https://opengamma.atlassian.net/browse/PLAT-6851), which is to remove the deprecated method `toDerivative(ZonedDateTime date, String... yieldCurveNames)` from the class [`InstrumentDefinition`](https://github.com/OpenGamma/OG-Platform/blob/develop/projects/OG-Analytics/src/main/java/com/opengamma/analytics/financial/instrument/InstrumentDefinition.java#L26). This method appears in a truely giant number of classes throughout the code base so the resulting churn is massive. In an attempt to reduce churn rebases on mainline have been performed, e.g. https://github.com/OpenGamma/OG-Platform/tree/wip/REQS-666/rebase_cbbdf7e. Futher, incremental build passes were ensured, this allows the full set of changes to be split into a series of incremented PRs on mainline thus avoiding the huge patch set and replacing it with a few large ones instead!

The basic strategy for completing this task has been to replace the body of implementations of the deprecated method with a simple `UnsupportedOperationException()`. Following each replacement the tests and downstream code that is broken by the change is patched.

The following rules have been applied (in order) when fixing up the broken items:
* If a test method is marked `@Deprecated`, it is deleted.
* If the test method name matches `.*[d,D]eprecated.*()`, it is deleted.
* If a test class is marked `@Deprecated` and there is no obvious simple fix to incorporate the removal of the prototype then the class is deleted.
* If the test class name matches `.*[d,D]eprecated.*` and there is no obvious simple fix to incorporate the removal of the prototype then the class is deleted..
* If the test method or class is not marked as deprecated but the majority of the executable code references deprecated methods and there is no obvious simple fix to incorporate the removal of the prototype it is deleted.
* If the code fails to compile due to references to the deprecated prototype made from another deprecated method, the calling method body is replaced with the throwing of an exception and downstream tests are patched according to the same rules as noted here.
* If there is no obvious deprecation but a class fails to compile (usually at engine function level) the validity of use is queried with the quant team and their suggested fix is undertaken.

In reviewing this sequence of PRs, please pay particular attention to added code i.e. fixups, to ensure behavioural changes are valid. Further please ensure nothing has accidentally been removed that provided value under different circumstances.

Note: Individual commit messages do not contain a full digest due to the lack of value in adding such messages in this task.