otdr

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 4, 2024 License: Apache-2.0 Imports: 9 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	FiberTypeProfile_name = map[int32]string{
		0: "FTP_UNKNOWN",
		1: "FTP_DSF",
		2: "FTP_LEAF",
		3: "FTP_SSMF",
		4: "FTP_TWC",
		5: "FTP_TWRS",
		6: "FTP_LS",
		7: "FTP_TERAWAVE",
		8: "FTP_TERALIGHT",
	}
	FiberTypeProfile_value = map[string]int32{
		"FTP_UNKNOWN":   0,
		"FTP_DSF":       1,
		"FTP_LEAF":      2,
		"FTP_SSMF":      3,
		"FTP_TWC":       4,
		"FTP_TWRS":      5,
		"FTP_LS":        6,
		"FTP_TERAWAVE":  7,
		"FTP_TERALIGHT": 8,
	}
)

Enum value maps for FiberTypeProfile.

View Source
var (
	InitiateRequest_ResultsMethod_name = map[int32]string{
		0: "RESULTS_UNKNOWN",
		1: "RESULTS_TO_LOCAL_DISK",
		2: "RESULTS_IN_RESPONSE",
	}
	InitiateRequest_ResultsMethod_value = map[string]int32{
		"RESULTS_UNKNOWN":       0,
		"RESULTS_TO_LOCAL_DISK": 1,
		"RESULTS_IN_RESPONSE":   2,
	}
)

Enum value maps for InitiateRequest_ResultsMethod.

View Source
var (
	InitiateProgress_State_name = map[int32]string{
		0: "UNKNOWN",
		1: "RUNNING",
		2: "PENDING",
		3: "COMPLETE",
	}
	InitiateProgress_State_value = map[string]int32{
		"UNKNOWN":  0,
		"RUNNING":  1,
		"PENDING":  2,
		"COMPLETE": 3,
	}
)

Enum value maps for InitiateProgress_State.

View Source
var (
	InitiateError_Type_name = map[int32]string{
		0: "UNSPECIFIED",
		1: "ALREADY_IN_PROGRESS",
		2: "HARDWARE_FAILURE",
	}
	InitiateError_Type_value = map[string]int32{
		"UNSPECIFIED":         0,
		"ALREADY_IN_PROGRESS": 1,
		"HARDWARE_FAILURE":    2,
	}
)

Enum value maps for InitiateError_Type.

View Source
var File_otdr_otdr_proto protoreflect.FileDescriptor

Functions

func RegisterOTDRServer

func RegisterOTDRServer(s *grpc.Server, srv OTDRServer)

Types

type Event

type Event struct {
	DistanceM    float32 `protobuf:"fixed32,1,opt,name=distance_m,json=distanceM,proto3" json:"distance_m,omitempty"`
	LossDb       float32 `protobuf:"fixed32,2,opt,name=loss_db,json=lossDb,proto3" json:"loss_db,omitempty"`
	ReflectionDb float32 `protobuf:"fixed32,3,opt,name=reflection_db,json=reflectionDb,proto3" json:"reflection_db,omitempty"`
	// contains filtered or unexported fields
}

func (*Event) Descriptor deprecated

func (*Event) Descriptor() ([]byte, []int)

Deprecated: Use Event.ProtoReflect.Descriptor instead.

func (*Event) GetDistanceM

func (x *Event) GetDistanceM() float32

func (*Event) GetLossDb

func (x *Event) GetLossDb() float32

func (*Event) GetReflectionDb

func (x *Event) GetReflectionDb() float32

func (*Event) ProtoMessage

func (*Event) ProtoMessage()

func (*Event) ProtoReflect

func (x *Event) ProtoReflect() protoreflect.Message

func (*Event) Reset

func (x *Event) Reset()

func (*Event) String

func (x *Event) String() string

type FiberTypeProfile

type FiberTypeProfile int32
const (
	FiberTypeProfile_FTP_UNKNOWN   FiberTypeProfile = 0
	FiberTypeProfile_FTP_DSF       FiberTypeProfile = 1
	FiberTypeProfile_FTP_LEAF      FiberTypeProfile = 2
	FiberTypeProfile_FTP_SSMF      FiberTypeProfile = 3
	FiberTypeProfile_FTP_TWC       FiberTypeProfile = 4
	FiberTypeProfile_FTP_TWRS      FiberTypeProfile = 5
	FiberTypeProfile_FTP_LS        FiberTypeProfile = 6
	FiberTypeProfile_FTP_TERAWAVE  FiberTypeProfile = 7
	FiberTypeProfile_FTP_TERALIGHT FiberTypeProfile = 8
)

func (FiberTypeProfile) Descriptor

func (FiberTypeProfile) Enum

func (FiberTypeProfile) EnumDescriptor deprecated

func (FiberTypeProfile) EnumDescriptor() ([]byte, []int)

Deprecated: Use FiberTypeProfile.Descriptor instead.

func (FiberTypeProfile) Number

func (FiberTypeProfile) String

func (x FiberTypeProfile) String() string

func (FiberTypeProfile) Type

type InitiateError

type InitiateError struct {
	Type   InitiateError_Type `protobuf:"varint,1,opt,name=type,proto3,enum=gnoi.optical.InitiateError_Type" json:"type,omitempty"`
	Detail string             `protobuf:"bytes,2,opt,name=detail,proto3" json:"detail,omitempty"`
	// contains filtered or unexported fields
}

func (*InitiateError) Descriptor deprecated

func (*InitiateError) Descriptor() ([]byte, []int)

Deprecated: Use InitiateError.ProtoReflect.Descriptor instead.

func (*InitiateError) GetDetail

func (x *InitiateError) GetDetail() string

func (*InitiateError) GetType

func (x *InitiateError) GetType() InitiateError_Type

func (*InitiateError) ProtoMessage

func (*InitiateError) ProtoMessage()

func (*InitiateError) ProtoReflect

func (x *InitiateError) ProtoReflect() protoreflect.Message

func (*InitiateError) Reset

func (x *InitiateError) Reset()

func (*InitiateError) String

func (x *InitiateError) String() string

type InitiateError_Type

type InitiateError_Type int32
const (
	InitiateError_UNSPECIFIED         InitiateError_Type = 0
	InitiateError_ALREADY_IN_PROGRESS InitiateError_Type = 1
	InitiateError_HARDWARE_FAILURE    InitiateError_Type = 2
)

func (InitiateError_Type) Descriptor

func (InitiateError_Type) Enum

func (InitiateError_Type) EnumDescriptor deprecated

func (InitiateError_Type) EnumDescriptor() ([]byte, []int)

Deprecated: Use InitiateError_Type.Descriptor instead.

func (InitiateError_Type) Number

func (InitiateError_Type) String

func (x InitiateError_Type) String() string

func (InitiateError_Type) Type

type InitiateProgress

type InitiateProgress struct {
	State InitiateProgress_State `protobuf:"varint,1,opt,name=state,proto3,enum=gnoi.optical.InitiateProgress_State" json:"state,omitempty"`
	// contains filtered or unexported fields
}

func (*InitiateProgress) Descriptor deprecated

func (*InitiateProgress) Descriptor() ([]byte, []int)

Deprecated: Use InitiateProgress.ProtoReflect.Descriptor instead.

func (*InitiateProgress) GetState

func (*InitiateProgress) ProtoMessage

func (*InitiateProgress) ProtoMessage()

func (*InitiateProgress) ProtoReflect

func (x *InitiateProgress) ProtoReflect() protoreflect.Message

func (*InitiateProgress) Reset

func (x *InitiateProgress) Reset()

func (*InitiateProgress) String

func (x *InitiateProgress) String() string

type InitiateProgress_State

type InitiateProgress_State int32
const (
	InitiateProgress_UNKNOWN  InitiateProgress_State = 0
	InitiateProgress_RUNNING  InitiateProgress_State = 1
	InitiateProgress_PENDING  InitiateProgress_State = 2
	InitiateProgress_COMPLETE InitiateProgress_State = 3
)

func (InitiateProgress_State) Descriptor

func (InitiateProgress_State) Enum

func (InitiateProgress_State) EnumDescriptor deprecated

func (InitiateProgress_State) EnumDescriptor() ([]byte, []int)

Deprecated: Use InitiateProgress_State.Descriptor instead.

func (InitiateProgress_State) Number

func (InitiateProgress_State) String

func (x InitiateProgress_State) String() string

func (InitiateProgress_State) Type

type InitiateRequest

type InitiateRequest struct {
	Component     *types.Path                     `protobuf:"bytes,1,opt,name=component,proto3" json:"component,omitempty"`
	ResultsMethod []InitiateRequest_ResultsMethod `` /* 156-byte string literal not displayed */
	Configuration *OTDRConfiguration              `protobuf:"bytes,3,opt,name=configuration,proto3" json:"configuration,omitempty"`
	Label         string                          `protobuf:"bytes,4,opt,name=label,proto3" json:"label,omitempty"`
	// contains filtered or unexported fields
}

func (*InitiateRequest) Descriptor deprecated

func (*InitiateRequest) Descriptor() ([]byte, []int)

Deprecated: Use InitiateRequest.ProtoReflect.Descriptor instead.

func (*InitiateRequest) GetComponent

func (x *InitiateRequest) GetComponent() *types.Path

func (*InitiateRequest) GetConfiguration

func (x *InitiateRequest) GetConfiguration() *OTDRConfiguration

func (*InitiateRequest) GetLabel

func (x *InitiateRequest) GetLabel() string

func (*InitiateRequest) GetResultsMethod

func (x *InitiateRequest) GetResultsMethod() []InitiateRequest_ResultsMethod

func (*InitiateRequest) ProtoMessage

func (*InitiateRequest) ProtoMessage()

func (*InitiateRequest) ProtoReflect

func (x *InitiateRequest) ProtoReflect() protoreflect.Message

func (*InitiateRequest) Reset

func (x *InitiateRequest) Reset()

func (*InitiateRequest) String

func (x *InitiateRequest) String() string

type InitiateRequest_ResultsMethod

type InitiateRequest_ResultsMethod int32
const (
	InitiateRequest_RESULTS_UNKNOWN       InitiateRequest_ResultsMethod = 0
	InitiateRequest_RESULTS_TO_LOCAL_DISK InitiateRequest_ResultsMethod = 1
	InitiateRequest_RESULTS_IN_RESPONSE   InitiateRequest_ResultsMethod = 2
)

func (InitiateRequest_ResultsMethod) Descriptor

func (InitiateRequest_ResultsMethod) Enum

func (InitiateRequest_ResultsMethod) EnumDescriptor deprecated

func (InitiateRequest_ResultsMethod) EnumDescriptor() ([]byte, []int)

Deprecated: Use InitiateRequest_ResultsMethod.Descriptor instead.

func (InitiateRequest_ResultsMethod) Number

func (InitiateRequest_ResultsMethod) String

func (InitiateRequest_ResultsMethod) Type

type InitiateResponse

type InitiateResponse struct {

	// Types that are assignable to Response:
	//
	//	*InitiateResponse_Progress
	//	*InitiateResponse_Results
	//	*InitiateResponse_Error
	Response isInitiateResponse_Response `protobuf_oneof:"response"`
	// contains filtered or unexported fields
}

func (*InitiateResponse) Descriptor deprecated

func (*InitiateResponse) Descriptor() ([]byte, []int)

Deprecated: Use InitiateResponse.ProtoReflect.Descriptor instead.

func (*InitiateResponse) GetError

func (x *InitiateResponse) GetError() *InitiateError

func (*InitiateResponse) GetProgress

func (x *InitiateResponse) GetProgress() *InitiateProgress

func (*InitiateResponse) GetResponse

func (m *InitiateResponse) GetResponse() isInitiateResponse_Response

func (*InitiateResponse) GetResults

func (x *InitiateResponse) GetResults() *InitiateResults

func (*InitiateResponse) ProtoMessage

func (*InitiateResponse) ProtoMessage()

func (*InitiateResponse) ProtoReflect

func (x *InitiateResponse) ProtoReflect() protoreflect.Message

func (*InitiateResponse) Reset

func (x *InitiateResponse) Reset()

func (*InitiateResponse) String

func (x *InitiateResponse) String() string

type InitiateResponse_Error

type InitiateResponse_Error struct {
	Error *InitiateError `protobuf:"bytes,3,opt,name=error,proto3,oneof"`
}

type InitiateResponse_Progress

type InitiateResponse_Progress struct {
	Progress *InitiateProgress `protobuf:"bytes,1,opt,name=progress,proto3,oneof"`
}

type InitiateResponse_Results

type InitiateResponse_Results struct {
	Results *InitiateResults `protobuf:"bytes,2,opt,name=results,proto3,oneof"`
}

type InitiateResults

type InitiateResults struct {
	LocalPath string     `protobuf:"bytes,1,opt,name=local_path,json=localPath,proto3" json:"local_path,omitempty"`
	OtdrTrace *OTDRTrace `protobuf:"bytes,2,opt,name=otdr_trace,json=otdrTrace,proto3" json:"otdr_trace,omitempty"`
	// contains filtered or unexported fields
}

func (*InitiateResults) Descriptor deprecated

func (*InitiateResults) Descriptor() ([]byte, []int)

Deprecated: Use InitiateResults.ProtoReflect.Descriptor instead.

func (*InitiateResults) GetLocalPath

func (x *InitiateResults) GetLocalPath() string

func (*InitiateResults) GetOtdrTrace

func (x *InitiateResults) GetOtdrTrace() *OTDRTrace

func (*InitiateResults) ProtoMessage

func (*InitiateResults) ProtoMessage()

func (*InitiateResults) ProtoReflect

func (x *InitiateResults) ProtoReflect() protoreflect.Message

func (*InitiateResults) Reset

func (x *InitiateResults) Reset()

func (*InitiateResults) String

func (x *InitiateResults) String() string

type OTDRClient

type OTDRClient interface {
	Initiate(ctx context.Context, in *InitiateRequest, opts ...grpc.CallOption) (OTDR_InitiateClient, error)
}

OTDRClient is the client API for OTDR service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewOTDRClient

func NewOTDRClient(cc grpc.ClientConnInterface) OTDRClient

type OTDRConfiguration

type OTDRConfiguration struct {
	AcquisitionTimeS    uint32           `protobuf:"varint,1,opt,name=acquisition_time_s,json=acquisitionTimeS,proto3" json:"acquisition_time_s,omitempty"`
	PulseWidthNs        float32          `protobuf:"fixed32,2,opt,name=pulse_width_ns,json=pulseWidthNs,proto3" json:"pulse_width_ns,omitempty"`
	WavelengthMhz       uint64           `protobuf:"varint,3,opt,name=wavelength_mhz,json=wavelengthMhz,proto3" json:"wavelength_mhz,omitempty"`
	RangeM              float32          `protobuf:"fixed32,4,opt,name=range_m,json=rangeM,proto3" json:"range_m,omitempty"`
	FiberType           FiberTypeProfile `protobuf:"varint,5,opt,name=fiber_type,json=fiberType,proto3,enum=gnoi.optical.FiberTypeProfile" json:"fiber_type,omitempty"`
	SamplingResolutionM float32          `protobuf:"fixed32,6,opt,name=sampling_resolution_m,json=samplingResolutionM,proto3" json:"sampling_resolution_m,omitempty"`
	// contains filtered or unexported fields
}

func (*OTDRConfiguration) Descriptor deprecated

func (*OTDRConfiguration) Descriptor() ([]byte, []int)

Deprecated: Use OTDRConfiguration.ProtoReflect.Descriptor instead.

func (*OTDRConfiguration) GetAcquisitionTimeS

func (x *OTDRConfiguration) GetAcquisitionTimeS() uint32

func (*OTDRConfiguration) GetFiberType

func (x *OTDRConfiguration) GetFiberType() FiberTypeProfile

func (*OTDRConfiguration) GetPulseWidthNs

func (x *OTDRConfiguration) GetPulseWidthNs() float32

func (*OTDRConfiguration) GetRangeM

func (x *OTDRConfiguration) GetRangeM() float32

func (*OTDRConfiguration) GetSamplingResolutionM

func (x *OTDRConfiguration) GetSamplingResolutionM() float32

func (*OTDRConfiguration) GetWavelengthMhz

func (x *OTDRConfiguration) GetWavelengthMhz() uint64

func (*OTDRConfiguration) ProtoMessage

func (*OTDRConfiguration) ProtoMessage()

func (*OTDRConfiguration) ProtoReflect

func (x *OTDRConfiguration) ProtoReflect() protoreflect.Message

func (*OTDRConfiguration) Reset

func (x *OTDRConfiguration) Reset()

func (*OTDRConfiguration) String

func (x *OTDRConfiguration) String() string

type OTDRServer

type OTDRServer interface {
	Initiate(*InitiateRequest, OTDR_InitiateServer) error
}

OTDRServer is the server API for OTDR service.

type OTDRTrace

type OTDRTrace struct {
	TotalLossDb         float32          `protobuf:"fixed32,1,opt,name=total_loss_db,json=totalLossDb,proto3" json:"total_loss_db,omitempty"`
	TotalLengthM        float32          `protobuf:"fixed32,2,opt,name=total_length_m,json=totalLengthM,proto3" json:"total_length_m,omitempty"`
	OpticalReturnLossDb float32          `protobuf:"fixed32,3,opt,name=optical_return_loss_db,json=opticalReturnLossDb,proto3" json:"optical_return_loss_db,omitempty"`
	AverageLossDbKm     float32          `protobuf:"fixed32,4,opt,name=average_loss_db_km,json=averageLossDbKm,proto3" json:"average_loss_db_km,omitempty"`
	DiscoveredFiberType FiberTypeProfile `` /* 156-byte string literal not displayed */
	Events              []*Event         `protobuf:"bytes,6,rep,name=events,proto3" json:"events,omitempty"`
	// contains filtered or unexported fields
}

func (*OTDRTrace) Descriptor deprecated

func (*OTDRTrace) Descriptor() ([]byte, []int)

Deprecated: Use OTDRTrace.ProtoReflect.Descriptor instead.

func (*OTDRTrace) GetAverageLossDbKm

func (x *OTDRTrace) GetAverageLossDbKm() float32

func (*OTDRTrace) GetDiscoveredFiberType

func (x *OTDRTrace) GetDiscoveredFiberType() FiberTypeProfile

func (*OTDRTrace) GetEvents

func (x *OTDRTrace) GetEvents() []*Event

func (*OTDRTrace) GetOpticalReturnLossDb

func (x *OTDRTrace) GetOpticalReturnLossDb() float32

func (*OTDRTrace) GetTotalLengthM

func (x *OTDRTrace) GetTotalLengthM() float32

func (*OTDRTrace) GetTotalLossDb

func (x *OTDRTrace) GetTotalLossDb() float32

func (*OTDRTrace) ProtoMessage

func (*OTDRTrace) ProtoMessage()

func (*OTDRTrace) ProtoReflect

func (x *OTDRTrace) ProtoReflect() protoreflect.Message

func (*OTDRTrace) Reset

func (x *OTDRTrace) Reset()

func (*OTDRTrace) String

func (x *OTDRTrace) String() string

type OTDR_InitiateClient

type OTDR_InitiateClient interface {
	Recv() (*InitiateResponse, error)
	grpc.ClientStream
}

type OTDR_InitiateServer

type OTDR_InitiateServer interface {
	Send(*InitiateResponse) error
	grpc.ServerStream
}

type UnimplementedOTDRServer

type UnimplementedOTDRServer struct {
}

UnimplementedOTDRServer can be embedded to have forward compatible implementations.

func (*UnimplementedOTDRServer) Initiate

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL