Skip to content
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

Redesign #91

Merged
merged 9 commits into from
Oct 17, 2020
Merged

Redesign #91

merged 9 commits into from
Oct 17, 2020

Conversation

hyperioxx
Copy link
Owner

No description provided.

@hyperioxx hyperioxx merged commit f254929 into master Oct 17, 2020
return se.tx
}

func (se *SipEvent) SetTransaction(tx interfaces.Transaction) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported method SipEvent.SetTransaction should have comment or be unexported

se.sipmsg = msg
}

func (se *SipEvent) GetTransaction() interfaces.Transaction {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported method SipEvent.GetTransaction should have comment or be unexported

return se.sipmsg
}

func (se *SipEvent) SetSipMessage(msg *message.SipMsg) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported method SipEvent.SetSipMessage should have comment or be unexported

}


func (se * SipEvent) GetSipMessage() *message.SipMsg {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported method SipEvent.GetSipMessage should have comment or be unexported

}


type SipEvent struct {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported type SipEvent should have comment or be unexported

@@ -44,22 +47,22 @@ func (ed *SipStack) CreateListenPoint(protocol string, host string, port int) tr
return listenpoint
}

func (ed *SipStack) CreateRequestsChannel() chan transaction.Transaction {
Channel := make(chan transaction.Transaction)
func (ed *SipStack) CreateRequestsChannel() chan interfaces.Transaction {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported method SipStack.CreateRequestsChannel should have comment or be unexported

}


type ListeningPoint interface {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported type ListeningPoint should have comment or be unexported

}


type SipEventObject interface{
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported type SipEventObject should have comment or be unexported

HandleResponses(SipEventObject)
}

type Transaction interface {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported type Transaction should have comment or be unexported

import ("github.com/KalbiProject/Kalbi/sip/message"
)

type SipListener interface {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported type SipListener should have comment or be unexported

@@ -48,7 +51,7 @@ func (ut *UDPTransport) Start() {
}
}

func (ut *UDPTransport) SetTransportChannel(channel chan *message.SipMsg) {
func (ut *UDPTransport) SetTransportChannel(channel chan interfaces.SipEventObject) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported method UDPTransport.SetTransportChannel should have comment or be unexported

}
}

func (tt *TCPTransport) SetTransportChannel(channel chan *message.SipMsg) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported method TCPTransport.SetTransportChannel should have comment or be unexported

@@ -29,13 +32,27 @@ func (tt *TCPTransport) Read() *message.SipMsg {

}

func (tt *TCPTransport) Start() {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported method TCPTransport.Start should have comment or be unexported

}


type Transaction interface {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported type Transaction should have comment or be unexported

Send(string, string, string) error
}

type SipEventObject interface{
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported type SipEventObject should have comment or be unexported

return se.sipmsg
}

func (se *SipEvent) SetSipMessage(msg *message.SipMsg) {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported method SipEvent.SetSipMessage should have comment or be unexported

}


func (se * SipEvent) GetSipMessage() *message.SipMsg {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported method SipEvent.GetSipMessage should have comment or be unexported

}


type SipEvent struct {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported type SipEvent should have comment or be unexported

GetListeningPoint() ListeningPoint
}

type SipEventObject interface{
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported type SipEventObject should have comment or be unexported

Send(string, string, string) error
}

type Transaction interface {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exported type Transaction should have comment or be unexported

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant