From d33218560b7b2bf2ebc4b5a33fed8aa77b8793e6 Mon Sep 17 00:00:00 2001 From: Zane Shelley Date: Thu, 15 Nov 2012 10:40:06 -0600 Subject: Merged common FSP and HB PRD code to prdf/common/ Change-Id: Iac94c3690598b7263de230934b911bb4ced34557 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/2350 Tested-by: Jenkins Server Reviewed-by: Bradley W. Bishop Reviewed-by: Zane Shelley Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/2368 Reviewed-by: A. Patrick Williams III --- .../framework/resolution/xspprdTryResolution.h | 134 +++++++++++++++++++++ 1 file changed, 134 insertions(+) create mode 100755 src/usr/diag/prdf/common/framework/resolution/xspprdTryResolution.h (limited to 'src/usr/diag/prdf/common/framework/resolution/xspprdTryResolution.h') diff --git a/src/usr/diag/prdf/common/framework/resolution/xspprdTryResolution.h b/src/usr/diag/prdf/common/framework/resolution/xspprdTryResolution.h new file mode 100755 index 000000000..2dcf9cffc --- /dev/null +++ b/src/usr/diag/prdf/common/framework/resolution/xspprdTryResolution.h @@ -0,0 +1,134 @@ +/* IBM_PROLOG_BEGIN_TAG */ +/* This is an automatically generated prolog. */ +/* */ +/* $Source: src/usr/diag/prdf/common/framework/resolution/xspprdTryResolution.h $ */ +/* */ +/* IBM CONFIDENTIAL */ +/* */ +/* COPYRIGHT International Business Machines Corp. 1998,2012 */ +/* */ +/* p1 */ +/* */ +/* Object Code Only (OCO) source materials */ +/* Licensed Internal Code Source Materials */ +/* IBM HostBoot Licensed Internal Code */ +/* */ +/* The source code for this program is not published or otherwise */ +/* divested of its trade secrets, irrespective of what has been */ +/* deposited with the U.S. Copyright Office. */ +/* */ +/* Origin: 30 */ +/* */ +/* IBM_PROLOG_END_TAG */ + +#ifndef xspprdTryResolution_h +#define xspprdTryResolution_h + +// Class Description ************************************************* +// +// Name: TryResolution +// Base class: Resolution +// +// Description: Try a resolution - if it does not work then +// call a default resolution +// Usage: +// +// End Class Description ********************************************* + +//-------------------------------------------------------------------- +// Includes +//-------------------------------------------------------------------- +#if !defined(iipResolution_h) +#include +#endif + +//-------------------------------------------------------------------- +// Forward References +//-------------------------------------------------------------------- +/** + **One line Class description** + @author Doug Gilbert + */ +class TryResolution: public Resolution +{ +public: + /** + Constructor +
    +
    Parameter: Resolution to try first +
    Parameter: Resolution if the try resolution fails +
    Returns: Nothing +
    Requirements: None +
    Promises: Object created +
    Exceptions: None +
    Notes: +

+ */ + TryResolution(Resolution &tryRes, Resolution & defaultRes); + TryResolution(); + + /* + Destructor +
    +
    Parameters: None. +
    Returns: No value returned +
    Requirements: None. +
    Promises: None. +
    Exceptions: None. +
    Notes: Compiler default is sufficient +

+ */ + // ~TryResolution(); + + /** + ** description ** +
    +
    Parameters: parms +
    Returns: return +
    Requirements: preconditions +
    Promises: postconditions +
    Exceptions: None. +
    Notes: optional +

+ */ + + /** + Resolve by calling TryResolution else call DefaultResolution +
    +
    Parameters: ServiceDataCollector +
    Returns: Return code [SUCCESS | nonZero] +
    Requirements: none. +
    Promises: if(TryResolution.Resolve() != SUCCESS) + then xDefaultResolution.Resolve(); +
    Exceptions: None. +

+ */ + virtual int32_t Resolve(STEP_CODE_DATA_STRUCT & error); + +private: // functions +private: // Data + +Resolution * xTryResolution; +Resolution * xDefaultResolution; + +}; + +inline +TryResolution::TryResolution(Resolution &tryRes, Resolution & defaultRes) +: xTryResolution(&tryRes), xDefaultResolution(&defaultRes) {} + +inline +TryResolution::TryResolution() + : xTryResolution(NULL), xDefaultResolution(NULL) {} + + +#endif /* xspprdTryResolution_h */ + +// Change Log ********************************************************* +// +// Flag Reason Vers Date Coder Description +// ---- --------- ---- -------- -------- ------------------------------- +// d49274.xx v4r5 12/28/99 dgilbert Initial Creation +// f522283 300 09/27/05 dgilbert Make flyweight-able +// +// End Change Log ***************************************************** -- cgit v1.2.1