Skip to content

Remove protected member functions and protected attributes from rendering #8670

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 9, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions drivers/BusIn.h
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ class BusIn : private NonCopyable<BusIn> {
*/
DigitalIn &operator[](int index);

#if !defined(DOXYGEN_ONLY)
protected:
DigitalIn *_pin[16];

Expand All @@ -120,6 +121,7 @@ class BusIn : private NonCopyable<BusIn> {
private:
virtual void lock();
virtual void unlock();
#endif
};

} // namespace mbed
Expand Down
9 changes: 5 additions & 4 deletions drivers/BusInOut.h
Original file line number Diff line number Diff line change
Expand Up @@ -83,15 +83,15 @@ class BusInOut : private NonCopyable<BusInOut> {
*/
int read();

/** Set as an output
/** Set all the pins in bus as output
*/
void output();

/** Set as an input
/** Set all the pins in bus as an input
*/
void input();

/** Set the input pin mode
/** Set the input pin mode for all the pins in bus
*
* @param pull PullUp, PullDown, PullNone
*/
Expand Down Expand Up @@ -124,7 +124,7 @@ class BusInOut : private NonCopyable<BusInOut> {
* \sa BusInOut::read()
*/
operator int();

#if !defined(DOXYGEN_ONLY)
protected:
virtual void lock();
virtual void unlock();
Expand All @@ -137,6 +137,7 @@ class BusInOut : private NonCopyable<BusInOut> {
int _nc_mask;

PlatformMutex _mutex;
#endif
};

} // namespace mbed
Expand Down
3 changes: 2 additions & 1 deletion drivers/BusOut.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ class BusOut : private NonCopyable<BusOut> {
* \sa BusOut::read()
*/
operator int();

#if !defined(DOXYGEN_ONLY)
protected:
virtual void lock();
virtual void unlock();
Expand All @@ -121,6 +121,7 @@ class BusOut : private NonCopyable<BusOut> {
int _nc_mask;

PlatformMutex _mutex;
#endif
};

} // namespace mbed
Expand Down
2 changes: 2 additions & 0 deletions drivers/FlashIAP.h
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ class FlashIAP : private NonCopyable<FlashIAP> {
*/
uint8_t get_erase_value() const;

#if !defined(DOXYGEN_ONLY)
private:

/* Check if address and size are aligned to a sector
Expand All @@ -151,6 +152,7 @@ class FlashIAP : private NonCopyable<FlashIAP> {
flash_t _flash;
uint8_t *_page_buf;
static SingletonPtr<PlatformMutex> _mutex;
#endif
};

} /* namespace mbed */
Expand Down
12 changes: 7 additions & 5 deletions drivers/I2C.h
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ class I2C : private NonCopyable<I2C> {
* @param data Pointer to the byte-array to read data in to
* @param length Number of bytes to read
* @param repeated Repeated start, true - don't send stop at end
* default value is false.
* default value is false.
*
* @returns
* 0 on success (ack),
Expand All @@ -134,7 +134,7 @@ class I2C : private NonCopyable<I2C> {
* @param data Pointer to the byte-array data to send
* @param length Number of bytes to send
* @param repeated Repeated start, true - do not send stop at end
* default value is false.
* default value is false.
*
* @returns
* 0 on success (ack),
Expand Down Expand Up @@ -188,8 +188,8 @@ class I2C : private NonCopyable<I2C> {
* @param event The logical OR of events to modify
* @param callback The event callback function
* @param repeated Repeated start, true - do not send stop at end
* default value is false.
*
* default value is false.
*
* @returns Zero if the transfer has started, or -1 if I2C peripheral is busy
*/
int transfer(int address, const char *tx_buffer, int tx_length, char *rx_buffer, int rx_length, const event_callback_t &callback, int event = I2C_EVENT_TRANSFER_COMPLETE, bool repeated = false);
Expand All @@ -198,6 +198,7 @@ class I2C : private NonCopyable<I2C> {
*/
void abort_transfer();

#if !defined(DOXYGEN_ONLY)
protected:
/** Lock deep sleep only if it is not yet locked */
void lock_deep_sleep();
Expand All @@ -211,6 +212,7 @@ class I2C : private NonCopyable<I2C> {
DMAUsage _usage;
bool _deep_sleep_locked;
#endif
#endif

#if !defined(DOXYGEN_ONLY)
protected:
Expand All @@ -222,7 +224,6 @@ class I2C : private NonCopyable<I2C> {
static SingletonPtr<PlatformMutex> _mutex;
PinName _sda;
PinName _scl;
#endif

private:
/** Recover I2C bus, when stuck with SDA low
Expand All @@ -237,6 +238,7 @@ class I2C : private NonCopyable<I2C> {
*
*/
int recover(PinName sda, PinName scl);
#endif
};

} // namespace mbed
Expand Down
2 changes: 2 additions & 0 deletions drivers/InterruptManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ class InterruptManager : private NonCopyable<InterruptManager> {
"public API of mbed-os and is being removed in the future.")
bool remove_handler(pFunctionPointer_t handler, IRQn_Type irq);

#if !defined(DOXYGEN_ONLY)
private:
InterruptManager();
~InterruptManager();
Expand Down Expand Up @@ -198,6 +199,7 @@ class InterruptManager : private NonCopyable<InterruptManager> {
CallChain *_chains[NVIC_NUM_VECTORS];
static InterruptManager *_instance;
PlatformMutex _mutex;
#endif
};

} // namespace mbed
Expand Down
3 changes: 2 additions & 1 deletion drivers/LowPowerTimeout.h
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,13 @@ namespace mbed {
* @ingroup drivers
*/
class LowPowerTimeout : public LowPowerTicker, private NonCopyable<LowPowerTimeout> {

#if !defined(DOXYGEN_ONLY)
private:
virtual void handler(void)
{
_function.call();
}
#endif
};

}
Expand Down
2 changes: 2 additions & 0 deletions drivers/MbedCRC.h
Original file line number Diff line number Diff line change
Expand Up @@ -302,6 +302,7 @@ class MbedCRC {
return width;
}

#if !defined(DOXYGEN_ONLY)
private:
uint32_t _initial_value;
uint32_t _final_xor;
Expand Down Expand Up @@ -546,6 +547,7 @@ class MbedCRC {
}
_mode = (_crc_table != NULL) ? TABLE : BITWISE;
}
#endif
};

#if defined ( __CC_ARM )
Expand Down
4 changes: 1 addition & 3 deletions drivers/SPI.h
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,7 @@ class SPI : private NonCopyable<SPI> {
*/
int set_dma_usage(DMAUsage usage);

#if !defined(DOXYGEN_ONLY)
protected:
/** SPI interrupt handler.
*/
Expand Down Expand Up @@ -263,8 +264,6 @@ class SPI : private NonCopyable<SPI> {
*/
void start_transfer(const void *tx_buffer, int tx_length, void *rx_buffer, int rx_length, unsigned char bit_width, const event_callback_t &callback, int event);

#if !defined(DOXYGEN_ONLY)

private:
/** Lock deep sleep only if it is not yet locked */
void lock_deep_sleep();
Expand Down Expand Up @@ -294,7 +293,6 @@ class SPI : private NonCopyable<SPI> {
#endif //DEVICE_SPI_ASYNCH

#if !defined(DOXYGEN_ONLY)

protected:
/* Internal SPI object identifying the resources */
spi_t _spi;
Expand Down
8 changes: 6 additions & 2 deletions drivers/SerialBase.h
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ class SerialBase : private NonCopyable<SerialBase> {
*/
void send_break();

#if !defined(DOXYGEN_ONLY)
protected:

/** Acquire exclusive access to this serial port
Expand All @@ -150,7 +151,7 @@ class SerialBase : private NonCopyable<SerialBase> {
/** Release exclusive access to this serial port
*/
virtual void unlock(void);

#endif
public:

#if DEVICE_SERIAL_FC
Expand Down Expand Up @@ -235,12 +236,15 @@ class SerialBase : private NonCopyable<SerialBase> {
*/
int set_dma_usage_rx(DMAUsage usage);

#if !defined(DOXYGEN_ONLY)
protected:
void start_read(void *buffer, int buffer_size, char buffer_width, const event_callback_t &callback, int event, unsigned char char_match);
void start_write(const void *buffer, int buffer_size, char buffer_width, const event_callback_t &callback, int event);
void interrupt_handler_asynch(void);
#endif
#endif

#if !defined(DOXYGEN_ONLY)
protected:
SerialBase(PinName tx, PinName rx, int baud);
virtual ~SerialBase();
Expand All @@ -259,7 +263,7 @@ class SerialBase : private NonCopyable<SerialBase> {
serial_t _serial;
Callback<void()> _irq[IrqCnt];
int _baud;

#endif
};

} // namespace mbed
Expand Down
2 changes: 2 additions & 0 deletions drivers/Timeout.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,8 +56,10 @@ namespace mbed {
*/
class Timeout : public Ticker, private NonCopyable<Timeout> {

#if !defined(DOXYGEN_ONLY)
protected:
virtual void handler();
#endif
};

} // namespace mbed
Expand Down
2 changes: 2 additions & 0 deletions drivers/TimerEvent.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ class TimerEvent : private NonCopyable<TimerEvent> {
*/
virtual ~TimerEvent();

#if !defined(DOXYGEN_ONLY)
protected:
// The handler called to service the timer event of the derived class
virtual void handler() = 0;
Expand Down Expand Up @@ -77,6 +78,7 @@ class TimerEvent : private NonCopyable<TimerEvent> {
ticker_event_t event;

const ticker_data_t *_ticker_data;
#endif
};

} // namespace mbed
Expand Down