* @return A component reference based on the values provided.
*/
private static RolloverComponentReference createRolloverComponentReference(
MarinerPageContext context, String rolloverExpression) {
PolicyReferenceResolver resolver =
context.getPolicyReferenceResolver();
// Create the identity for the rollover by resolving the expression.
// Note that this must be done up front to because we don't want
// expressions being evaluated out of order.
RuntimePolicyReference reference =
resolver.resolveUnquotedPolicyExpression(rolloverExpression,
PolicyType.ROLLOVER_IMAGE);
return new RolloverComponentReference(
context.getPolicyFetcher(), context.getAssetResolver(),
reference);