3 public class PeerHandleError {
5 public internal(set) var cOpaqueStruct: LDKPeerHandleError?;
7 /* DEFAULT_CONSTRUCTOR_START */
8 public init(no_connection_possible_arg: Bool) {
10 self.cOpaqueStruct = PeerHandleError_new(no_connection_possible_arg)
12 /* DEFAULT_CONSTRUCTOR_END */
14 public init(pointer: LDKPeerHandleError){
15 self.cOpaqueStruct = pointer
18 /* STRUCT_METHODS_START */
20 public func get_no_connection_possible() -> Bool {
22 return withUnsafePointer(to: self.cOpaqueStruct!) { (this_ptrPointer: UnsafePointer<LDKPeerHandleError>) in
23 PeerHandleError_get_no_connection_possible(this_ptrPointer)
27 public func set_no_connection_possible(val: Bool) -> Void {
29 let this_ptrPointer = UnsafeMutablePointer<LDKPeerHandleError>.allocate(capacity: 1)
30 this_ptrPointer.initialize(to: self.cOpaqueStruct!)
32 return PeerHandleError_set_no_connection_possible(this_ptrPointer, val);
35 public func clone(orig: PeerHandleError) -> PeerHandleError {
37 return withUnsafePointer(to: orig.cOpaqueStruct!) { (origPointer: UnsafePointer<LDKPeerHandleError>) in
38 PeerHandleError(pointer: PeerHandleError_clone(origPointer))
44 if self.cOpaqueStruct?.is_owned == false {
48 PeerHandleError_free(self.cOpaqueStruct!)
54 /* STRUCT_METHODS_END */