Documentation ¶
Overview ¶
cpgo는 go언어에서 사이보스플러스를 연동하기 위한 Wrapper 라이브러리입니다. 이 라이브러리는 go-ole 패키지에 상당히 의존하고 있으므로 반드시 미리 설치해야 합니다.
Index ¶
- Variables
- func CreateThread(fnc Background, arg1 uintptr) (ret int32, err error)
- func PeekMessage(msg *ole.Msg, hwnd uint32, MsgFilterMin uint32, MsgFilterMax uint32, ...) (ret int32, err error)
- func PumpWaitingMessages() int32
- type Background
- type CpClass
- func (c *CpClass) BindEvent(callback Receiver)
- func (c *CpClass) BlockRequest()
- func (c *CpClass) CodeToFullCode(cod string) (r *ole.VARIANT)
- func (c *CpClass) CodeToIndex(cod string) (r *ole.VARIANT)
- func (c *CpClass) CodeToName(cod string) (r *ole.VARIANT)
- func (c *CpClass) Create(name string)
- func (c *CpClass) FullCodeToCode(fullcod string) (r *ole.VARIANT)
- func (c *CpClass) FullCodeToName(fullcod string) (r *ole.VARIANT)
- func (c *CpClass) GetContinue() (r *ole.VARIANT)
- func (c *CpClass) GetCount() (r *ole.VARIANT)
- func (c *CpClass) GetData(typ int, idx int) (r *ole.VARIANT)
- func (c *CpClass) GetDataValue(typ int, idx int) (result *ole.VARIANT)
- func (c *CpClass) GetDibStatus() int16
- func (c *CpClass) GetHeaderValue(typ int) (result *ole.VARIANT)
- func (c *CpClass) GetIsConnect() (r *ole.VARIANT)
- func (c *CpClass) GetLimitRemainCount(typ int) (r *ole.VARIANT)
- func (c *CpClass) GetLimitRequestRemainTime() (r *ole.VARIANT)
- func (c *CpClass) GetServerType() (r *ole.VARIANT)
- func (c *CpClass) NameToCode(nm string) (r *ole.VARIANT)
- func (c *CpClass) Release()
- func (c *CpClass) Request()
- func (c *CpClass) SetInputValue(typ int, val interface{})
- func (c *CpClass) Subscribe()
- func (c *CpClass) SubscribeLastest()
- func (c *CpClass) UnbindEvent()
- func (c *CpClass) Unsubscribe()
- type Receiver
Constants ¶
This section is empty.
Variables ¶
var ( // 이벤트 IID IID_IDibEvents, _ = ole.CLSIDFromString("{B8944520-09C3-11D4-8232-00105A7C4F8C}") IID_IDibSysEvents, _ = ole.CLSIDFromString("{60D7702A-57BA-4869-AF3F-292FDC909D75}") IID_IDibTrEvents, _ = ole.CLSIDFromString("{8B55AD34-73A3-4C33-B8CD-C95ED13823CB}") IID_CpCybosEvents, _ = ole.CLSIDFromString("{17F70631-56E5-40FC-B94F-44ADD3A850B1}") // CpCybos의 LimitType 값들 LT_TRADE_REQUEST = 0 LT_NONTRADE_REQUEST = 1 LT_SUBSCRIBE = 2 )
peekmessage 로드, 이벤트 iid
Functions ¶
func CreateThread ¶
func CreateThread(fnc Background, arg1 uintptr) (ret int32, err error)
윈도우스레드 구현
func PeekMessage ¶
func PeekMessage(msg *ole.Msg, hwnd uint32, MsgFilterMin uint32, MsgFilterMax uint32, RemoveMsg uint32) (ret int32, err error)
PeekMessage 구현
func PumpWaitingMessages ¶
func PumpWaitingMessages() int32
메시지 펌핑 (파이선 pythoncom.PumpWatingMessges 의 golang구현) WM_QUIT 로 종료되었을시 int32(1) 이 리턴됩니다.
Types ¶
type Background ¶
type CpClass ¶
type CpClass struct {
// contains filtered or unexported fields
}
사이보스플러스 객체
func (*CpClass) BindEvent ¶
이벤트를 지정할때 사용합니다. Receiver 인터페이스를 구현한 콜백을 지정하여 이벤트 수신시 콜백을 호출되게 지정할수 있습니다.
func (*CpClass) CodeToFullCode ¶
사이보스플러스 CpUtil.CpStockCode CodeToFullCode 메서드 Wrapper
func (*CpClass) CodeToIndex ¶
사이보스플러스 CpUtil.CpStockCode CodeToIndex 메서드 Wrapper
func (*CpClass) CodeToName ¶
사이보스플러스 CpUtil.CpStockCode CodeToName 메서드 Wrapper
func (*CpClass) Create ¶
사이보스플러스 객체 생성 "Library.coclass" 문자열을 넣어 객체를 생성합니다. "CpDib.StockMst" 와 같은 식으로 사용합니다.
func (*CpClass) FullCodeToCode ¶
사이보스플러스 CpUtil.CpStockCode FullCodeToCode 메서드 Wrapper
func (*CpClass) FullCodeToName ¶
사이보스플러스 CpUtil.CpStockCode FullCodeToName 메서드 Wrapper
func (*CpClass) GetContinue ¶
사이보스플러스 Property Getter 메서드입니다. Continue 프로퍼티 값을 얻어옵니다.
func (*CpClass) GetDataValue ¶
사이보스플러스 GetDataValue 메서드 Wrapper
func (*CpClass) GetDibStatus ¶
사이보스플러스 GetDibStatus 메서드 Wrapper
func (*CpClass) GetHeaderValue ¶
사이보스플러스 GetHeaderValue 메서드 Wrapper
func (*CpClass) GetIsConnect ¶
사이보스플러스 CpUtil.CpCybos ServerType Property getter
func (*CpClass) GetLimitRemainCount ¶
사이보스플러스 CpUtil.CpCybos GetLimitRemainCount 메서드 Wrapper
func (*CpClass) GetLimitRequestRemainTime ¶
사이보스플러스 CpUtil.CpCybos LimitRequestRemainTime Property getter
func (*CpClass) GetServerType ¶
사이보스플러스 CpUtil.CpCybos ServerType Property getter
func (*CpClass) NameToCode ¶
사이보스플러스 CpUtil.CpStockCode NameToCode 메서드 Wrapper
func (*CpClass) SetInputValue ¶
사이보스플러스 SetInputValue 메서드 Wrapper
func (*CpClass) SubscribeLastest ¶
func (c *CpClass) SubscribeLastest()
사이보스플러스 SubscribeLastest 메서드 Wrapper