Oracle Fusion Middleware C++ API Reference for Oracle Coherence
12c (12.1.2)

E26041-01

coherence/io/WrapperStreamFactory.hpp

00001 /*
00002 * WrapperStreamFactory.hpp
00003 *
00004 * Copyright (c) 2000, 2013, Oracle and/or its affiliates. All rights reserved.
00005 *
00006 * Oracle is a registered trademarks of Oracle Corporation and/or its
00007 * affiliates.
00008 *
00009 * This software is the confidential and proprietary information of Oracle
00010 * Corporation. You shall not disclose such confidential and proprietary
00011 * information and shall use it only in accordance with the terms of the
00012 * license agreement you entered into with Oracle.
00013 *
00014 * This notice may not be removed or altered.
00015 */
00016 #ifndef COH_WRAPPER_STREAM_FACTORY_HPP
00017 #define COH_WRAPPER_STREAM_FACTORY_HPP
00018 
00019 #include "coherence/lang.ns"
00020 
00021 #include "coherence/io/ReadBuffer.hpp"
00022 #include "coherence/io/WriteBuffer.hpp"
00023 
00024 COH_OPEN_NAMESPACE2(coherence,io)
00025 
00026 
00027 /**
00028 * Provides the means to wrap an BufferInput and BufferOutput, such that
00029 * functionality such as compression and encryption can be implemented
00030 * in a layered, pluggable fashion.
00031 *
00032 * @author nsa  2008.04.07
00033 */
00034 class COH_EXPORT WrapperStreamFactory
00035     : public interface_spec<WrapperStreamFactory>
00036     {
00037     // ----- WrapperStreamFactory interface ---------------------------------
00038 
00039     public:
00040         /**
00041         * Requests an InputStream that wraps the passed InputStream.
00042         *
00043         * @param  hIn  the coherence::io::ReadBuffer::BufferInput to be
00044         *              wrapped
00045         *
00046         * @return a BufferInput that delegates to ("wraps") the passed
00047         *         BufferInput
00048         */
00049         virtual ReadBuffer::BufferInput::Handle getInputStream(
00050                 ReadBuffer::BufferInput::Handle hIn) const = 0;
00051 
00052         /**
00053         * Requests an OutputStream that wraps the passed OutputStream.
00054         *
00055         * @param  hOut  the coherence::io::WriteBuffer::BufferOutput to be
00056         *               wrapped
00057         *
00058         * @return a BufferOutput that delegates to ("wraps") the passed
00059         *         BufferOutput
00060         */
00061         virtual WriteBuffer::BufferOutput::Handle getOutputStream(
00062                 WriteBuffer::BufferOutput::Handle hOut) const = 0;
00063     };
00064 
00065 COH_CLOSE_NAMESPACE2
00066 
00067 #endif // COH_WRAPPER_STREAM_FACTORY_HPP
Copyright © 2000, 2013, Oracle and/or its affiliates. All rights reserved.