?? counterthreshold.cpp
字號:
/*
Copyright (c) 2008, Intel Corporation.
All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation and/or
other materials provided with the distribution.
* Neither the name of Intel Corporation nor the names of its contributors
may be used to endorse or promote products derived from this software without
specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
OF SUCH DAMAGE.
*///==============================================================================// CounterThreshold.cpp // Implementation of base class CounterThreshold//==============================================================================#include "./CounterThreshold.h" #include "../Base/base_Property.h"#include "../ThresholdImpl/CounterThreshold_Impl.h" using namespace Intel::Mobile::ThresholdAPI;//==============================================================================// C-Tor() : Default constructor//==============================================================================CounterThreshold::CounterThreshold(){}//==============================================================================// D-Tor() : //==============================================================================CounterThreshold::~CounterThreshold(){}//==============================================================================// GetNotify()//==============================================================================bool CounterThreshold::GetNotify() const{ CheckValid( IntelMobileText("CounterThreshold"), IntelMobileText("GetNotify") ); return (*reinterpret_cast<CounterThresholdImplPtr*>(m_pImpl))->GetNotify(); } // GetNotify()//==============================================================================// SetNotify()//==============================================================================bool CounterThreshold::SetNotify( bool bNotify ) { CheckValid( IntelMobileText("CounterThreshold"), IntelMobileText("SetNotify") ); return (*reinterpret_cast<CounterThresholdImplPtr*>(m_pImpl))->SetNotify( bNotify ); } // SetOffset()//++++++++++++++++++++++++++++++++++++++++++++++++++++// // Class ByteCounterThreshold////++++++++++++++++++++++++++++++++++++++++++++++++++++//==============================================================================// C-Tor() : Constructor//==============================================================================ByteCounterThreshold::ByteCounterThreshold(){ // Instantiate a new SmartPointer containing a new Impl object m_pImpl = new ByteCounterThresholdImplPtr( new ByteCounterThresholdImpl( this, 0U, 0U ) );}//==============================================================================// SetObservedProperty() : //==============================================================================bool ByteCounterThreshold::SetObservedProperty( const ByteProperty& observedProperty ){ CheckValid( IntelMobileText("ByteCounterThreshold"), IntelMobileText("SetObservedProperty") ); return Threshold::SetObservedProperty( observedProperty ); } // SetObservedProperty()//==============================================================================// GetThreshold()//==============================================================================unsigned char ByteCounterThreshold::GetThreshold() const{ CheckValid( IntelMobileText("ByteCounterThreshold"), IntelMobileText("GetThreshold") ); return (*reinterpret_cast<ByteCounterThresholdImplPtr*>(m_pImpl))->GetThreshold(); } // GetThreshold()//==============================================================================// SetThreshold()//==============================================================================bool ByteCounterThreshold::SetThreshold( unsigned char threshold ) { CheckValid( IntelMobileText("ByteCounterThreshold"), IntelMobileText("SetThreshold") ); return (*reinterpret_cast<ByteCounterThresholdImplPtr*>(m_pImpl))->SetThreshold( threshold ); } // SetThreshold()//==============================================================================// GetOffset()//==============================================================================unsigned char ByteCounterThreshold::GetOffset() const{ CheckValid( IntelMobileText("ByteCounterThreshold"), IntelMobileText("GetOffset") ); return (*reinterpret_cast<ByteCounterThresholdImplPtr*>(m_pImpl))->GetOffset(); } // GetOffset()//==============================================================================// SetOffset()//==============================================================================bool ByteCounterThreshold::SetOffset( unsigned char offset ) { CheckValid( IntelMobileText("ByteCounterThreshold"), IntelMobileText("SetOffset") ); return (*reinterpret_cast<ByteCounterThresholdImplPtr*>(m_pImpl))->SetOffset( offset ); } // SetOffset()//++++++++++++++++++++++++++++++++++++++++++++++++++++// // Class IntCounterThreshold////++++++++++++++++++++++++++++++++++++++++++++++++++++//==============================================================================// C-Tor() : Constructor//==============================================================================IntCounterThreshold::IntCounterThreshold(){ // Instantiate a new SmartPointer containing a new Impl object m_pImpl = new IntCounterThresholdImplPtr( new IntCounterThresholdImpl( this, 0, 0 ) );}//==============================================================================// SetObservedProperty() : //==============================================================================bool IntCounterThreshold::SetObservedProperty( const IntProperty& observedProperty ){ CheckValid( IntelMobileText("IntCounterThreshold"), IntelMobileText("SetObservedProperty") ); return Threshold::SetObservedProperty( observedProperty ); } // SetObservedProperty()//==============================================================================// GetThreshold()//==============================================================================__int32 IntCounterThreshold::GetThreshold() const{ CheckValid( IntelMobileText("IntCounterThreshold"), IntelMobileText("GetThreshold") ); return (*reinterpret_cast<IntCounterThresholdImplPtr*>(m_pImpl))->GetThreshold(); } // GetThreshold()//==============================================================================// SetThreshold()//==============================================================================bool IntCounterThreshold::SetThreshold( __int32 threshold ) { CheckValid( IntelMobileText("IntCounterThreshold"), IntelMobileText("SetThreshold") ); return (*reinterpret_cast<IntCounterThresholdImplPtr*>(m_pImpl))->SetThreshold( threshold ); } // SetThreshold()//==============================================================================// GetOffset()//==============================================================================__int32 IntCounterThreshold::GetOffset() const{ CheckValid( IntelMobileText("IntCounterThreshold"), IntelMobileText("GetOffset") ); return (*reinterpret_cast<IntCounterThresholdImplPtr*>(m_pImpl))->GetOffset(); } // GetOffset()//==============================================================================// SetOffset()//==============================================================================bool IntCounterThreshold::SetOffset( __int32 offset ) { CheckValid( IntelMobileText("IntCounterThreshold"), IntelMobileText("SetOffset") ); return (*reinterpret_cast<IntCounterThresholdImplPtr*>(m_pImpl))->SetOffset( offset ); } // SetOffset()//++++++++++++++++++++++++++++++++++++++++++++++++++++// // Class UIntCounterThreshold////++++++++++++++++++++++++++++++++++++++++++++++++++++//==============================================================================// C-Tor() : Constructor//==============================================================================UIntCounterThreshold::UIntCounterThreshold(){ // Instantiate a new SmartPointer containing a new Impl object m_pImpl = new UIntCounterThresholdImplPtr( new UIntCounterThresholdImpl( this, 0U, 0U ) );}//==============================================================================// SetObservedProperty() : //==============================================================================bool UIntCounterThreshold::SetObservedProperty( const UIntProperty& observedProperty ){ CheckValid( IntelMobileText("UIntCounterThreshold"), IntelMobileText("SetObservedProperty") ); return Threshold::SetObservedProperty( observedProperty ); } // SetObservedProperty()//==============================================================================// GetThreshold()//==============================================================================unsigned __int32 UIntCounterThreshold::GetThreshold() const{ CheckValid( IntelMobileText("UIntCounterThreshold"), IntelMobileText("GetThreshold") ); return (*reinterpret_cast<UIntCounterThresholdImplPtr*>(m_pImpl))->GetThreshold(); } // GetThreshold()//==============================================================================// SetThreshold()
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -