text
stringlengths
11
6.3k
embedding
listlengths
768
768
func (m *MockCommentsLogic) CommentsDelete(username, slug string, id int) error { ret := m.ctrl.Call(m, "CommentsDelete", username, slug, id) ret0, _ := ret[0].(error) return ret0 }
[ 0.4091882109642029, -0.5503320693969727, 0.26350224018096924, 0.3420780599117279, 1.3117890357971191, -0.14568567276000977, 0.5737292170524597, -0.7134330868721008, -0.8563111424446106, -0.25360947847366333, 0.021682990714907646, -1.031211256980896, -1.3286993503570557, 0.0974154844880104,...
func (mr *MockCommentsLogicMockRecorder) CommentsDelete(username, slug, id interface{}) *gomock.Call { return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "CommentsDelete", reflect.TypeOf((*MockCommentsLogic)(nil).CommentsDelete), username, slug, id) }
[ 0.6752293705940247, 0.14939352869987488, 0.28049761056900024, 0.1071639135479927, 0.6391871571540833, -0.1785251647233963, -0.2634662389755249, -1.414613127708435, 0.5004359483718872, 0.4483662247657776, 0.6251324415206909, 0.16466234624385834, -1.1437817811965942, 0.5107847452163696, -0...
func NewMockFavoritesLogic(ctrl *gomock.Controller) *MockFavoritesLogic { mock := &MockFavoritesLogic{ctrl: ctrl} mock.recorder = &MockFavoritesLogicMockRecorder{mock} return mock }
[ 0.8981057405471802, 0.9330951571464539, 0.11437664926052094, 0.5484924912452698, -0.6577286720275879, 0.19191543757915497, -0.2992529273033142, -0.4716237187385559, 0.2783525288105011, 0.19530406594276428, -0.2637803256511688, -0.2471894472837448, 0.28374913334846497, -0.19455204904079437,...
func (m *MockFavoritesLogic) EXPECT() *MockFavoritesLogicMockRecorder { return m.recorder }
[ 0.7080903649330139, 0.831709086894989, 0.21091079711914062, 0.20658889412879944, -0.01368906069546938, 0.30118560791015625, -0.34132033586502075, 0.19582416117191315, 0.5668544173240662, -0.1993643045425415, 0.6481751203536987, 0.784572184085846, -0.20049557089805603, -0.3668852746486664, ...
func (m *MockFavoritesLogic) FavoritesUpdate(username, slug string, favortie bool) (*domain.User, *domain.Article, error) { ret := m.ctrl.Call(m, "FavoritesUpdate", username, slug, favortie) ret0, _ := ret[0].(*domain.User) ret1, _ := ret[1].(*domain.Article) ret2, _ := ret[2].(error) return ret0, ret1, ret2 }
[ -0.16130009293556213, -0.10263828188180923, 0.07648066431283951, 0.37512218952178955, 0.2833925485610962, 0.04444976523518562, 0.07452987134456635, -0.22407345473766327, -0.9404617547988892, -0.1915474236011505, -0.7601665258407593, -1.027258038520813, -1.0115121603012085, 0.08089412748813...
func (mr *MockFavoritesLogicMockRecorder) FavoritesUpdate(username, slug, favortie interface{}) *gomock.Call { return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FavoritesUpdate", reflect.TypeOf((*MockFavoritesLogic)(nil).FavoritesUpdate), username, slug, favortie) }
[ 0.19322504103183746, 0.4117489755153656, 0.23611986637115479, 0.3418900668621063, -0.39874085783958435, 0.06937054544687271, -0.8421677947044373, -0.8729965090751648, 0.47087061405181885, 0.31974557042121887, 0.025734437629580498, 0.09280174970626831, -1.13759446144104, 0.05900589376688003...
func NewMockTagsLogic(ctrl *gomock.Controller) *MockTagsLogic { mock := &MockTagsLogic{ctrl: ctrl} mock.recorder = &MockTagsLogicMockRecorder{mock} return mock }
[ 1.010209083557129, 0.8312420845031738, 0.21203535795211792, 0.12355586141347885, -0.47465911507606506, -0.5604962706565857, -0.554557740688324, -0.8057709336280823, -0.6930146217346191, 0.857633113861084, -0.6193768382072449, -0.028630215674638748, 0.32564622163772583, 0.11174339801073074,...
func (m *MockTagsLogic) EXPECT() *MockTagsLogicMockRecorder { return m.recorder }
[ 1.0113145112991333, 0.3966574966907501, 0.15025188028812408, -0.03995891287922859, 0.0014026510762050748, -0.23482219874858856, -0.551835298538208, -0.28151699900627136, -0.4316249191761017, -0.08596370369195938, 0.707485556602478, 0.9014779329299927, -0.37420135736465454, 0.37619063258171...
func (m *MockTagsLogic) Tags() ([]string, error) { ret := m.ctrl.Call(m, "Tags") ret0, _ := ret[0].([]string) ret1, _ := ret[1].(error) return ret0, ret1 }
[ -0.17149624228477478, 0.606735348701477, 0.17856264114379883, 0.004521274007856846, 0.9895378351211548, 0.37872937321662903, 0.3045339584350586, -0.4640643298625946, -1.0139662027359009, -0.4842059314250946, -0.51775062084198, -0.9499437212944031, -0.8146417737007141, 1.0910841226577759, ...
func (mr *MockTagsLogicMockRecorder) Tags() *gomock.Call { return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Tags", reflect.TypeOf((*MockTagsLogic)(nil).Tags)) }
[ 0.31669339537620544, 1.3768088817596436, 0.1652326136827469, -0.31766772270202637, 0.3187182545661926, 0.18327462673187256, -0.9465354681015015, -1.2515454292297363, 0.5779777765274048, 0.03542809560894966, 0.4070969521999359, 0.4657677412033081, -0.9129445552825928, 1.5861124992370605, ...
func wrap1(a any,f func(float64)float64)any{ var t string = fmt.Sprintf("%T", a) switch t { case "int": return f(float64(a.(int))) case "int8": return f(float64(a.(int8))) case "int16": return f(float64(a.(int16))) case "int32": return f(float64(a.(int32))) case "int64": return f(float64(a.(int6...
[ -0.5066967010498047, -0.13688525557518005, 0.9133315086364746, 0.5861157178878784, -0.6427934765815735, -0.07471064478158951, -0.10047107934951782, -0.07903722673654556, -0.19182035326957703, 0.5436177849769592, 1.2273098230361938, 0.8273266553878784, 0.7906478643417358, 0.4033436179161072...
func wrap2(a,b any,f func(float64,float64)float64)any{ var t string = fmt.Sprintf("%T", a) var t2 string = fmt.Sprintf("%T", b) var b2 float64 switch t2 { case "int": b2 = float64(b.(int)) case "int8": b2 = float64(b.(int8)) case "int16": b2 = float64(b.(int16)) case "int32": b2 = float64(b.(int...
[ -0.4796959161758423, -0.6266561150550842, 0.9209854006767273, 0.26012223958969116, -0.6261621117591858, -0.1719927191734314, -0.4546549916267395, -0.6315977573394775, -0.5961887836456299, 0.5731096267700195, 0.7386095523834229, 0.7528026103973389, 0.7790782451629639, 0.34029269218444824, ...
func (self *State)Abs(a any)any{ self.IncOperations(self.coeff["abs"]+self.off["abs"]) return wrap1(a,math.Abs) }
[ -1.2597596645355225, -0.27405259013175964, 0.469353049993515, 0.5176918506622314, -0.5499621629714966, 0.307927668094635, -0.11254338920116425, -0.26992422342300415, 0.5168256163597107, -0.33024221658706665, 1.1378830671310425, 0.7990856170654297, 1.2879661321640015, 0.27699387073516846, ...
func (self *State)Pow(a,b any)any{ self.IncOperations(self.coeff["pow"]+self.off["pow"]) return wrap2(a,b,math.Pow) }
[ -0.8927212357521057, -0.17922411859035492, 0.3685244917869568, 0.896407961845398, 0.15239502489566803, -0.10146377980709076, -0.46060752868652344, 0.017807556316256523, -0.14324679970741272, -0.11580018699169159, 0.7269324064254761, 0.281494140625, 0.5424700379371643, -0.49950918555259705,...
func (self *State)Sqrt(a any)any{ self.IncOperations(self.coeff["sqrt"]+self.off["sqrt"]) return wrap1(a,math.Sqrt) }
[ -0.488662451505661, -0.1808650940656662, 0.2659599483013153, 0.019748136401176453, -0.6388528943061829, -0.4972619116306305, -0.39018920063972473, -0.6591575145721436, 2.004185199737549, -0.6539512872695923, 0.47750741243362427, 0.5155150294303894, 0.034660883247852325, 0.3489997684955597,...
func (self *State)Ceil(a any)any{ self.IncOperations(self.coeff["ceil"]+self.off["ceil"]) return wrap1(a,math.Ceil) }
[ -0.4431774616241455, 0.24338603019714355, 0.08366507291793823, 0.36604902148246765, -0.6683230996131897, 0.3989091217517853, 0.8457981944084167, -0.5718265771865845, 0.4621092975139618, 0.14772212505340576, 0.12993928790092468, 0.4417591094970703, 0.830288290977478, -0.6314560174942017, ...
func (self *State)Floor(a any)any{ self.IncOperations(self.coeff["floor"]+self.off["floor"]) return wrap1(a,math.Floor) }
[ -0.4235258102416992, 0.44430479407310486, 0.10742940753698349, 0.24916128814220428, -0.22145293653011322, 0.5154569745063782, 1.2385098934173584, -0.47515246272087097, 1.0576528310775757, -1.0350422859191895, 0.6071649789810181, -0.12499084323644638, 0.5316305756568909, 1.227605938911438, ...
func (self *State)Round(a any)any{ self.IncOperations(self.coeff["round"]+self.off["round"]) return wrap1(a,math.Round) }
[ -0.41313910484313965, 0.308450311422348, 0.17475467920303345, -0.20156005024909973, -0.06721509993076324, 0.10179439187049866, 1.420937418937683, -0.5252170562744141, 0.8346604704856873, -0.4395264983177185, 1.0690759420394897, 0.9582206606864929, 0.47490814328193665, 0.4021303951740265, ...
func (self *State)Min(a,b any)any{ self.IncOperations(self.coeff["min"]+self.off["min"]) return wrap2(a,b,math.Min) }
[ -0.3238166868686676, -0.3488238453865051, 0.1589685082435608, 0.38517892360687256, -0.5063227415084839, -0.24642781913280487, -1.1752647161483765, -1.2333345413208008, 0.5330842137336731, -0.7832878828048706, 0.8537760972976685, 0.6933552622795105, 0.331984281539917, -0.6424930095672607, ...
func (self *State)Max(a,b any)any{ self.IncOperations(self.coeff["max"]+self.off["max"]) return wrap2(a,b,math.Max) }
[ -0.5718243718147278, 0.20448186993598938, 0.20618268847465515, 0.7507281303405762, 0.008207155391573906, -0.3719402551651001, -1.271950602531433, -0.1990087330341339, 0.2727277874946594, -0.05270815268158913, 0.6295067071914673, 1.0296255350112915, 0.6713470220565796, -0.7868010997772217, ...
func (self *State)Sin(a any)any{ self.IncOperations(self.coeff["sin"]+self.off["sin"]) return wrap1(a,math.Sin) }
[ -1.0404095649719238, -0.21271303296089172, 0.2687714397907257, 0.7856972813606262, -0.5394297242164612, -0.02598665840923786, 0.5302813649177551, 0.06659065186977386, 1.3555409908294678, -0.9161306619644165, -0.13143615424633026, 0.8066757917404175, 0.08886733651161194, -0.4595677852630615...
func (self *State)Cos(a any)any{ self.IncOperations(self.coeff["cos"]+self.off["cos"]) return wrap1(a,math.Cos) }
[ -0.8277890086174011, 0.08679244667291641, 0.2651022970676422, 0.11129625141620636, -0.5549099445343018, -0.1151917427778244, 0.3342987298965454, 0.30056509375572205, 0.5817350745201111, -0.20099374651908875, 0.5067688822746277, 0.1503143310546875, 0.5124237537384033, -0.28747448325157166, ...
func (self *State)Asin(a any)any{ self.IncOperations(self.coeff["asin"]+self.off["asin"]) return wrap1(a,math.Asin) }
[ -0.8114498257637024, -0.3718940019607544, 0.4124259352684021, 0.3692266643047333, -1.1197006702423096, 0.25184082984924316, 0.19841669499874115, -0.3009120225906372, 0.9965134859085083, -0.2134462594985962, 0.16043701767921448, 0.6274375915527344, 0.3967033624649048, -0.015402917750179768,...
func (self *State)Acos(a any)any{ self.IncOperations(self.coeff["acos"]+self.off["acos"]) return wrap1(a,math.Acos) }
[ -0.542854368686676, -0.08074135333299637, 0.29044726490974426, -0.4150923788547516, -0.7578363418579102, -0.2879810929298401, 0.7872902750968933, -0.44326677918434143, 0.5271734595298767, 0.4851657748222351, 0.6004616022109985, 0.14960651099681854, 1.2305206060409546, -0.6875693798065186, ...
func (self *State)Tan(a any)any{ self.IncOperations(self.coeff["tan"]+self.off["tan"]) return wrap1(a,math.Tan) }
[ -1.2242764234542847, 0.07375437766313553, 0.142482727766037, -0.38109955191612244, -0.3558911681175232, 0.018846796825528145, 1.2648158073425293, -0.015590514987707138, 0.6505527496337891, -1.010874629020691, -0.24496929347515106, -0.1647537797689438, 0.6804584860801697, -0.556472063064575...
func (self *State)Atan(a any)any{ self.IncOperations(self.coeff["atan"]+self.off["atan"]) return wrap1(a,math.Atan) }
[ -0.9315236210823059, -0.5090847611427307, 0.17612534761428833, -0.08808670938014984, -0.34660962224006653, -0.303711473941803, 0.6445173621177673, 0.08561830222606659, 0.7834673523902893, -0.8805190920829773, 0.15424096584320068, 0.47332727909088135, 0.9851688146591187, -0.2436146587133407...
func (self *State)Sinh(a any)any{ self.IncOperations(self.coeff["sinh"]+self.off["sinh"]) return wrap1(a,math.Sinh) }
[ 0.0035345996730029583, 0.3750041723251343, 0.2519168555736542, 1.4576752185821533, -0.4106437563896179, 0.5284676551818848, 0.3263733983039856, 0.6769512295722961, 1.186827301979065, -0.4715206027030945, -0.2889057695865631, 0.637692391872406, 0.21028535068035126, 0.0272208359092474, 0.4...
func (self *State)Cosh(a any)any{ self.IncOperations(self.coeff["cosh"]+self.off["cosh"]) return wrap1(a,math.Cosh) }
[ 0.19672022759914398, 0.36317315697669983, 0.20203201472759247, 0.4614291787147522, -0.30207306146621704, 0.7298126220703125, 0.5712290406227112, -0.13282787799835205, 0.3966676890850067, -0.7277065515518188, 0.6448056101799011, 0.7421278953552246, 0.8852284550666809, -0.01473891083151102, ...
func (self *State)Asinh(a any)any{ self.IncOperations(self.coeff["asinh"]+self.off["asinh"]) return wrap1(a,math.Asinh) }
[ -0.09052370488643646, -0.16385430097579956, 0.4610421359539032, 0.49818000197410583, -0.7558092474937439, 0.3252507746219635, 0.13764873147010803, 0.07227642834186554, 0.764347493648529, 0.14352980256080627, -0.2840229570865631, 0.5303682088851929, 0.26973628997802734, -0.1026875376701355,...
func (self *State)Acosh(a any)any{ self.IncOperations(self.coeff["acosh"]+self.off["acosh"]) return wrap1(a,math.Acosh) }
[ 0.15127648413181305, 0.1624109148979187, 0.11387944966554642, 0.22434993088245392, -0.38452965021133423, 0.31226497888565063, 1.0870500802993774, -0.2439233958721161, 0.6625747680664062, -0.4954051971435547, 0.37460634112358093, 0.4942973852157593, 1.3044588565826416, 0.07269015908241272, ...
func (self *State)Tanh(a any)any{ self.IncOperations(self.coeff["tanh"]+self.off["tanh"]) return wrap1(a,math.Tanh) }
[ -0.14213809370994568, 0.5354269742965698, 0.1659211367368698, 0.42209944128990173, -0.34131550788879395, 0.5353966355323792, 0.702623724937439, 0.24406184256076813, 0.5469368696212769, -0.5009734034538269, -0.11782965809106827, 0.191624253988266, 0.5653345584869385, -0.29099956154823303, ...
func (self *State)Atanh(a any)any{ self.IncOperations(self.coeff["atanh"]+self.off["atanh"]) return wrap1(a,math.Atanh) }
[ 0.0935036912560463, 0.13253457844257355, 0.19554120302200317, -0.10334032773971558, -0.2110888510942459, 0.4611172080039978, 0.3834261894226074, -0.21052873134613037, 0.41378021240234375, -0.3683103621006012, 0.6064333319664001, 0.5006973147392273, 1.4789705276489258, -0.14582958817481995,...
func (self *State)Log(a any)any{ self.IncOperations(self.coeff["log"]+self.off["log"]) return wrap1(a,math.Log) }
[ -0.6606706380844116, 0.8412983417510986, 0.2018532156944275, 0.270712286233902, -0.5935400724411011, 0.062376488000154495, 0.6706249713897705, 0.015651265159249306, 1.0007091760635376, -0.7506722807884216, 0.2991848886013031, 0.19849587976932526, 0.8927006125450134, -0.15258458256721497, ...
func (self *State)Log2(a any)any{ self.IncOperations(self.coeff["log2"]+self.off["log2"]) return wrap1(a,math.Log2) }
[ -0.6865977644920349, -0.7750326991081238, 0.23339028656482697, 0.44544777274131775, -0.7748705148696899, -0.304485559463501, -0.30892008543014526, -0.614687979221344, 0.3333127200603485, -0.5261560678482056, 0.07886208593845367, 0.9803159832954407, 1.0614228248596191, 0.23270148038864136, ...
func (self *State)Log10(a any)any{ self.IncOperations(self.coeff["log10"]+self.off["log10"]) return wrap1(a,math.Log10) }
[ -0.3731222450733185, -0.1299624741077423, 0.1886022835969925, -0.8668142557144165, 0.7824241518974304, -0.5291898846626282, 0.3607507050037384, 0.5941212773323059, 1.0827057361602783, -0.1670021265745163, 0.151118203997612, 0.2278107851743698, 1.0984258651733398, -0.3525628447532654, 0.9...
func (self *State)Exp(a any)any{ self.IncOperations(self.coeff["exp"]+self.off["exp"]) return wrap1(a,math.Exp) }
[ -0.05442887917160988, 0.23207424581050873, 0.3571770191192627, 0.1918795257806778, -0.7693619728088379, 0.29346686601638794, 0.556557297706604, 0.16033610701560974, 1.3119951486587524, -0.22340776026248932, 0.534949779510498, -0.10854664444923401, 0.5765990614891052, 0.16751958429813385, ...
func (self *State)Exp2(a any)any{ self.IncOperations(self.coeff["exp2"]+self.off["exp2"]) return wrap1(a,math.Exp2) }
[ -0.2358979880809784, -0.739579975605011, 0.25849297642707825, 0.23357424139976501, -1.0944124460220337, 0.010226944461464882, 0.3133974075317383, -0.036657702177762985, 0.7949098944664001, -0.16432176530361176, 0.23609338700771332, 0.49895569682121277, 0.6940001249313354, 0.393364995718002...
func (subr *SRCountersData) Decode(b []byte) (err error) { buffer := bytes.NewReader(b) // CFE1 ... CFE8 - (Counter Field Exists) flagByte := byte(0) if flagByte, err = buffer.ReadByte(); err != nil { return fmt.Errorf("EGTS_SR_COUNTERS_DATA; Error reading flags") } flagByteAsBits := fmt.Sprintf("%08b", flagBy...
[ 0.2608255445957184, 0.2424309104681015, 0.7884881496429443, 0.06071824952960014, 0.59157395362854, 0.9196836352348328, 0.8362357020378113, -0.3160254955291748, -0.020431309938430786, 0.15915343165397644, -0.5227450728416443, 0.1337757110595703, -0.8812369108200073, 0.6536411643028259, 0....
func (subr *SRCountersData) Encode() (b []byte, err error) { buffer := new(bytes.Buffer) flags := uint64(0) for i := len(subr.CountersExists)/2 - 1; i >= 0; i-- { // reversed order of CNE opp := len(subr.CountersExists) - 1 - i subr.CountersExists[i], subr.CountersExists[opp] = subr.CountersExists[opp], subr.C...
[ 0.04968130588531494, 0.49933403730392456, 0.7264688611030579, 0.31141841411590576, 0.5208813548088074, 1.0422548055648804, 0.41738641262054443, -0.6889899969100952, -0.2214892953634262, 0.27788978815078735, -0.13308490812778473, 0.5150505304336548, -0.7971627712249756, 0.20033560693264008,...
func (subr *SRCountersData) Len() (l uint16) { encoded, _ := subr.Encode() l = uint16(len(encoded)) return l }
[ 1.421329379081726, 0.5749678611755371, 0.014456301927566528, -0.65800940990448, 0.34343111515045166, -0.09927486628293991, 0.9155312776565552, 0.23936757445335388, 0.18713004887104034, -1.4029693603515625, -1.1232589483261108, 0.289643794298172, 0.11029016226530075, 0.0353567935526371, 0...
func (p *McPinger) Ping() (*ServerInfo, error) { res, err := mcpinger.New(p.Host, p.Port).Ping() if err != nil { return nil, err } return &ServerInfo{ Protocol: res.Version.Protocol, Version: res.Version.Name, MaxPlayers: res.Players.Max, OnlinePlayers: res.Players.Online, }, nil }
[ -0.720745861530304, -0.601440966129303, 0.4146094024181366, 0.22718612849712372, -0.3032587170600891, 0.5527627468109131, -0.3389386534690857, -0.43169906735420227, -0.8436364531517029, 0.8468876481056213, -0.4622914493083954, -0.20354047417640686, -0.7108677625656128, 0.4316546320915222, ...
func (p *McPinger) PingWithTimeout() (*ServerInfo, error) { res, err := mcpinger.NewTimed(p.Host, p.Port, p.Timeout).Ping() if err != nil { return nil, err } return &ServerInfo{ Protocol: res.Version.Protocol, Version: res.Version.Name, MaxPlayers: res.Players.Max, OnlinePlayers: res.Players...
[ -0.2812868058681488, -0.5770745277404785, 0.41566821932792664, -0.06963891535997391, -1.0091228485107422, 0.6248068809509277, -0.8932433128356934, -0.4802849590778351, -0.4020540714263916, 1.2255821228027344, -0.4577605426311493, -0.11873556673526764, -0.5862680673599243, 0.382274150848388...
func (p *McPinger) IsTimeoutZero() bool { return p.Timeout == 0 }
[ 0.13126015663146973, -0.7966799139976501, 0.25077158212661743, 0.7469902634620667, -0.04774673283100128, 0.11079443991184235, -0.17255981266498566, 0.9841971397399902, 0.508156418800354, 0.9312195777893066, -0.3324007987976074, 0.04236288741230965, -0.7367518544197083, 1.1038093566894531, ...
func NoDelayDialRanker(addrs []ma.Multiaddr) []network.AddrDelay { return getAddrDelay(addrs, 0, 0, 0) }
[ -0.3733876347541809, 0.17835049331188202, 0.3541612923145294, -0.8139960765838623, -0.5714880228042603, 0.31936606764793396, -0.47540682554244995, 0.22766268253326416, 1.053049921989441, -0.3882081210613251, 0.8187974691390991, 0.3044758141040802, 0.015816161409020424, 0.9535037875175476, ...
func DefaultDialRanker(addrs []ma.Multiaddr) []network.AddrDelay { relay, addrs := filterAddrs(addrs, isRelayAddr) pvt, addrs := filterAddrs(addrs, manet.IsPrivateAddr) public, addrs := filterAddrs(addrs, func(a ma.Multiaddr) bool { return isProtocolAddr(a, ma.P_IP4) || isProtocolAddr(a, ma.P_IP6) }) var relayOffs...
[ -0.677932858467102, 0.3591456711292267, 0.6946644186973572, -0.5281765460968018, -0.12613800168037415, -0.003491050098091364, -0.3956924378871918, 0.46660903096199036, 0.6810687780380249, 0.055571384727954865, 0.463622510433197, -0.07517603039741516, -0.45106759667396545, 0.631825864315033...
func getAddrDelay(addrs []ma.Multiaddr, tcpDelay time.Duration, quicDelay time.Duration, offset time.Duration) []network.AddrDelay { sort.Slice(addrs, func(i, j int) bool { return score(addrs[i]) < score(addrs[j]) }) // If the first address is (QUIC, IPv6), make the second address (QUIC, IPv4). happyEyeballs := f...
[ -0.2691972255706787, 0.2322760373353958, 0.9238479137420654, -0.6695003509521484, -0.19711445271968842, -0.17719590663909912, 0.14751985669136047, -0.36397483944892883, 0.6726381182670593, 0.16755372285842896, 0.50087970495224, 0.05354050546884537, 0.07516995072364807, 0.2106776386499405, ...
func score(a ma.Multiaddr) int { ip4Weight := 0 if isProtocolAddr(a, ma.P_IP4) { ip4Weight = 1 << 18 } if _, err := a.ValueForProtocol(ma.P_WEBTRANSPORT); err == nil { p, _ := a.ValueForProtocol(ma.P_UDP) pi, _ := strconv.Atoi(p) return ip4Weight + (1 << 19) + pi } if _, err := a.ValueForProtocol(ma.P_QU...
[ -0.3184991776943207, -0.15857727825641632, 0.9070925712585449, -0.7692619562149048, -0.32380202412605286, -0.005482458509504795, 0.1660572588443756, -0.3249874711036682, 0.42144775390625, 0.5652140378952026, 0.3805699050426483, -0.5611203908920288, -0.6635538339614868, 0.13249553740024567,...
func filterAddrs(addrs []ma.Multiaddr, f func(a ma.Multiaddr) bool) (filtered, rest []ma.Multiaddr) { j := 0 for i := 0; i < len(addrs); i++ { if f(addrs[i]) { addrs[i], addrs[j] = addrs[j], addrs[i] j++ } } return addrs[:j], addrs[j:] }
[ -0.4082960784435272, 0.40363946557044983, 0.48584267497062683, -0.3507446348667145, -1.2569010257720947, -0.81450355052948, 0.060863833874464035, 0.41888710856437683, 0.3345377445220947, 0.8466249704360962, 0.2302723526954651, 1.0138276815414429, -0.32356706261634827, -0.005192791111767292...
func pathsFrom(idx int) int { // are we already at the end? there's only one path then. if idx == len(numbers)-1 { return 1 } // did we already calculate the paths from idx to the end? not calculate // again. paths, alreadyCalculated := pathsFromIndex[idx] if alreadyCalculated { return paths } for nxt :=...
[ -0.10412555187940598, 0.968018651008606, 0.710095226764679, 0.16674812138080597, -0.1096917986869812, -0.32224276661872864, 0.8143374919891357, -0.36504805088043213, 0.8035256862640381, -0.4557255208492279, 0.02805667370557785, -1.2285314798355103, -0.6310724020004272, -0.47628894448280334...
func (o *Options) CheckOptions() error { if o.ViceCrtFile == "" { return fmt.Errorf("path to vice certificate not provided. Aborting") } if o.ViceKeyFile == "" { return fmt.Errorf("path to vice key not provided. Aborting") } if o.VicePresidentConfig == "" { return fmt.Errorf("path to vice config not provided...
[ 0.2508659064769745, -0.052906595170497894, 0.6947436332702637, 0.46971723437309265, 0.7827774286270142, 0.39606136083602905, 0.8552239537239075, -0.4256236255168915, 0.10491519421339035, 0.7194244265556335, 0.11363370716571808, 0.18352286517620087, -0.6871092915534973, 1.0679107904434204, ...
func New() (*Db, error) { // Don't feel like setting a password on my local db p := os.Getenv("CIPHER_BIN_DB_PASSWORD") if p != "" { p = fmt.Sprintf("password=%s", p) } connStr := fmt.Sprintf( "host=%s port=%s user=%s %s dbname=%s sslmode=%s", os.Getenv("CIPHER_BIN_DB_HOST"), os.Getenv("CIPHER_BIN_DB_PORT...
[ 0.10275980085134506, -0.6852461695671082, 0.683243989944458, 0.2061014324426651, -0.9513123035430908, 0.23067033290863037, -0.12884028255939484, 0.366028755903244, -0.9508225917816162, -0.3414890766143799, -0.7212823033332825, 0.528148889541626, -0.6896542310714722, 0.9971984028816223, 0...
func (db *Db) GetMessageByUUID(uuid string) (*Message, error) { // Prepare query, takes a uuid argument, protects from sql injection stmt, err := db.Prepare("SELECT * FROM messages WHERE uuid=$1") if err != nil { log.Print("GetMessageByUUID Preparation Err: ", err) return nil, err } // Make query with our pre...
[ -0.4418758153915405, 0.44115307927131653, 0.4721987247467041, -0.6243082880973816, -0.23896823823451996, -0.6366239190101624, -0.10777738690376282, -0.6069348454475403, -0.639772891998291, 0.07486213743686676, 0.4505353271961212, -0.17301428318023682, -1.0874792337417603, 0.167038977146148...
func (db *Db) PostMessage(msg Message) error { query := `INSERT INTO messages (uuid, message, email, reference_name, password) VALUES ($1, $2, $3, $4, $5);` // Execute query with uuid and message arguments _, err := db.Exec( query, msg.UUID, msg.Message, msg.Email, msg.ReferenceName, msg.Password, ) i...
[ -0.8614233732223511, 0.9014335870742798, 0.6233826279640198, -0.0638706311583519, 0.5030288100242615, 0.40612077713012695, -0.09124447405338287, 0.32499033212661743, -1.378425121307373, 0.563886284828186, 0.08960162848234177, -0.3789549469947815, -1.9328736066818237, 0.7204535603523254, ...
func (db *Db) DestroyMessageByUUID(uuid string) error { query := `DELETE FROM messages WHERE uuid=$1;` // Execute query with uuid argument _, err := db.Exec(query, uuid) if err != nil { log.Print(err) return err } return nil }
[ -0.4137973487377167, 0.37639904022216797, 0.4246158301830292, -0.2809656858444214, -0.21101392805576324, -0.24614477157592773, 0.0785348117351532, 0.42874109745025635, -0.9464805126190186, 0.8637155890464783, 0.5135082602500916, -0.6265740394592285, -1.092560887336731, 1.071317434310913, ...
func (db *Db) DestroyStaleMessages() error { query := `DELETE FROM messages WHERE created_at <= NOW() - INTERVAL '30 days';` _, err := db.Exec(query) if err != nil { log.Print(err) return err } return nil }
[ -0.2352132350206375, 1.0095170736312866, 0.7878897786140442, -0.26206791400909424, 0.47189924120903015, 0.6422228217124939, 0.4273759424686432, -0.8647728562355042, -0.4187459647655487, 0.2031431794166565, 0.02021779678761959, 0.09074074774980545, -0.12569013237953186, 1.7051924467086792, ...
func (p *Plugin) ShowAlert(context string) error { return p.sendMessage(&ShowNotifyEventMessage{ Event: "showAlert", Context: context, }) }
[ 0.7176198959350586, -0.1022847592830658, 0.4119349718093872, 0.03901117667555809, 0.013347010128200054, -0.6907564997673035, 0.24874714016914368, -0.2987155020236969, 1.1230827569961548, 0.1202017292380333, 0.1559445559978485, 2.0512683391571045, -0.20629411935806274, 0.8217747211456299, ...
func (p *Plugin) ShowOk(context string) error { return p.sendMessage(&ShowNotifyEventMessage{ Event: "showOk", Context: context, }) }
[ 1.004765510559082, 0.3410576283931732, 0.39394158124923706, 0.42982742190361023, -0.36340928077697754, -0.4344765543937683, 0.9654950499534607, 0.45273709297180176, 0.710620105266571, 0.6871601939201355, -0.8052239418029785, 1.4964656829833984, 0.46844327449798584, 0.7793895602226257, -0...
func (p *Plugin) SetSettings(context string, payload interface{}) error { data, err := json.Marshal(payload) if err != nil { return err } return p.sendMessage(&SetSettingsEventMessage{ Event: "setSettings", Context: context, Payload: data, }) }
[ -1.4646621942520142, 0.668339729309082, 0.4723477065563202, 0.3136473298072815, 0.567194402217865, -1.069116473197937, -0.21609468758106232, -1.1595975160598755, -0.046145230531692505, 0.7702734470367432, -0.851446270942688, 0.8793403506278992, -1.3809171915054321, 0.21077439188957214, -...
func (p *Plugin) SendToPropertyInspector(context string, action string, payload interface{}) error { data, err := json.Marshal(payload) if err != nil { return err } return p.sendMessage(&SendToPropertyInspectorEventMessage{ Event: "sendToPropertyInspector", Context: context, Action: action, Payload: d...
[ -0.7924773097038269, -0.6230102777481079, 0.46448060870170593, -0.8030602931976318, 0.3509969711303711, -0.29146942496299744, -0.23974959552288055, -0.758036196231842, 0.12668786942958832, 0.4703952372074127, 0.013215377926826477, 1.1488690376281738, 0.08852583169937134, -0.187642261385917...
func (p *Plugin) SetTitle(context string, title string, target string) error { return p.sendMessage(&SetTitleEventMessage{ Event: "setTitle", Context: context, Payload: SetTitlePayload{ Title: title, Target: target, }, }) }
[ -0.6496968865394592, 0.07980526238679886, 0.3996184468269348, 0.28854823112487793, 0.5944393873214722, -0.8782882690429688, -0.7663411498069763, -0.5934702157974243, 0.6270493865013123, 0.4716287851333618, -0.6839321851730347, 1.321136236190796, -1.121820092201233, -0.5169762969017029, -...
func (p *Plugin) SetImage(context string, image string, target string) error { return p.sendMessage(&SetImageEventMessage{ Event: "setImage", Context: context, Payload: SetImagePayload{ Image: image, Target: target, }, }) }
[ -1.1932411193847656, 0.22559520602226257, 0.3799045979976654, 0.07322865724563599, 0.5096734762191772, -0.7953837513923645, -0.6635281443595886, -0.11489658802747726, 0.17980024218559265, 0.6170258522033691, 0.285230815410614, 1.5054621696472168, -0.8792852759361267, 0.20303377509117126, ...
func (p *Plugin) SwitchToProfile(context string, device string, profile string) error { return p.sendMessage(&SwitchToProfileEventMessage{ Event: "switchToProfile", Context: context, Payload: SwitchToProfilePayload{ Profile: profile, }, }) }
[ 0.029634999111294746, 0.13636961579322815, 0.5022079348564148, -0.059195809066295624, 0.4569011628627777, -0.2180873304605484, 0.28531861305236816, -1.076174259185791, 0.3188403844833374, 0.5332143306732178, -0.4326747953891754, 1.1624647378921509, -1.1765145063400269, -0.7606222629547119,...
func (p *Plugin) OpenURL(url string) error { return p.sendMessage(&OpenURLEventMessage{ Event: "openUrl", Payload: OpenURLPayload{ URL: url, }, }) }
[ -0.2416224181652069, -0.02130027301609516, 0.5053161978721619, -0.22448404133319855, -0.6320967674255371, 0.41571253538131714, 0.6458683013916016, 0.3755747079849243, 1.1465948820114136, 0.2705835998058319, -0.7821856737136841, 0.6876269578933716, -0.5921230912208557, 0.29195114970207214, ...
func NewHandler(db *rationl.DB, clientID, secret string) http.Handler { var authorizeHandler = newAuthorizeHandler(db, clientID, secret) r := mux.NewRouter() r.Handle("/", &indexHandler{db}) r.HandleFunc("/assets/{filename}", assetsHandleFunc) r.Handle("/authorize", authorizeHandler) r.Handle("/authorize/callba...
[ 0.20837540924549103, 0.3426671326160431, 0.669070839881897, 0.5795946717262268, 0.4478053152561188, 0.4901641011238098, 0.8127148747444153, 0.1620173454284668, 0.14109472930431366, -0.3937336802482605, 0.6511476635932922, -0.4460923969745636, -0.11996906250715256, 0.014972560107707977, 0...
func assetsHandleFunc(w http.ResponseWriter, r *http.Request) { vars := mux.Vars(r) filename := vars["filename"] b, err := assets.Asset(filename) if err != nil { http.NotFound(w, r) return } switch path.Ext(filename) { case ".css": w.Header().Set("Content-Type", "text/css") case ".js": w.Header().Set("C...
[ 0.3717893362045288, -0.4954785406589508, 0.7634578943252563, -0.7200831174850464, -0.1932557076215744, 0.6405336260795593, 0.9985383749008179, -0.9324692487716675, -0.372588574886322, 0.03745098412036896, 1.0873761177062988, 0.1770622581243515, 0.6490626335144043, -0.27731698751449585, 0...
func NewStorageMock(t minimock.Tester) *StorageMock { m := &StorageMock{t: t} if controller, ok := t.(minimock.MockController); ok { controller.RegisterMocker(m) } m.AllMock = mStorageMockAll{mock: m} m.AllMock.callArgs = []*StorageMockAllParams{} m.CloneMock = mStorageMockClone{mock: m} m.CloneMock.callArgs...
[ -0.12602375447750092, -0.7705879211425781, 0.3135311007499695, 0.9870110154151917, 0.1457800418138504, -0.32286903262138367, 0.7189512252807617, -0.05141087621450424, 0.07779302448034286, -0.0031716518569737673, -0.16434890031814575, -0.7546285390853882, -0.4037410318851471, 0.388926059007...
func (mmAll *mStorageMockAll) Expect(ctx context.Context, pulse insolar.PulseNumber) *mStorageMockAll { if mmAll.mock.funcAll != nil { mmAll.mock.t.Fatalf("StorageMock.All mock is already set by Set") } if mmAll.defaultExpectation == nil { mmAll.defaultExpectation = &StorageMockAllExpectation{} } mmAll.defau...
[ -0.14344531297683716, -0.2628273367881775, 0.5919774770736694, 0.9132596254348755, 0.5518712997436523, 0.08105345070362091, -0.057084161788225174, 0.486173152923584, 0.27483752369880676, -0.1380850076675415, 0.20166638493537903, 0.06211712956428528, -0.5721603035926819, 1.1187710762023926,...
func (mmAll *mStorageMockAll) Inspect(f func(ctx context.Context, pulse insolar.PulseNumber)) *mStorageMockAll { if mmAll.mock.inspectFuncAll != nil { mmAll.mock.t.Fatalf("Inspect function is already set for StorageMock.All") } mmAll.mock.inspectFuncAll = f return mmAll }
[ -0.4185164272785187, -0.7660176157951355, 0.656033456325531, 0.7106168270111084, -0.22748740017414093, 0.16513365507125854, 0.6239637732505798, 1.0675945281982422, 0.024876907467842102, -0.05139696225523949, 0.024829968810081482, -0.3896405100822449, 0.08027894794940948, 0.4829870760440826...
func (mmAll *mStorageMockAll) Return(ja1 []insolar.JetID) *StorageMock { if mmAll.mock.funcAll != nil { mmAll.mock.t.Fatalf("StorageMock.All mock is already set by Set") } if mmAll.defaultExpectation == nil { mmAll.defaultExpectation = &StorageMockAllExpectation{mock: mmAll.mock} } mmAll.defaultExpectation.re...
[ -0.11569986492395401, -0.43308258056640625, 0.5551608800888062, 0.9975171089172363, 0.33314403891563416, 0.2890947461128235, 0.014301560819149017, 0.37783682346343994, 0.40153101086616516, 0.27795833349227905, 0.4865446090698242, -0.30928748846054077, -0.8736253976821899, 0.816298365592956...
func (mmAll *mStorageMockAll) Set(f func(ctx context.Context, pulse insolar.PulseNumber) (ja1 []insolar.JetID)) *StorageMock { if mmAll.defaultExpectation != nil { mmAll.mock.t.Fatalf("Default expectation is already set for the Storage.All method") } if len(mmAll.expectations) > 0 { mmAll.mock.t.Fatalf("Some ex...
[ -0.6016062498092651, 0.08630966395139694, 0.5368141531944275, 0.4540354311466217, 0.5857446193695068, 0.3870340585708618, -0.026071030646562576, 0.7579590082168579, -0.20678672194480896, 0.08220116049051285, 0.1336660087108612, -0.2062472254037857, -0.03651687130331993, 1.0895293951034546,...
func (mmAll *mStorageMockAll) When(ctx context.Context, pulse insolar.PulseNumber) *StorageMockAllExpectation { if mmAll.mock.funcAll != nil { mmAll.mock.t.Fatalf("StorageMock.All mock is already set by Set") } expectation := &StorageMockAllExpectation{ mock: mmAll.mock, params: &StorageMockAllParams{ctx, p...
[ 0.19779495894908905, -0.3873458802700043, 0.6718134880065918, 0.5346629619598389, -0.18486200273036957, 0.46950584650039673, -0.3587699830532074, 0.7466899156570435, 0.34843894839286804, -0.34576863050460815, -0.5526494383811951, 0.08025043457746506, -0.2581329941749573, 0.5587873458862305...
func (e *StorageMockAllExpectation) Then(ja1 []insolar.JetID) *StorageMock { e.results = &StorageMockAllResults{ja1} return e.mock }
[ -0.10163535922765732, -0.5857024788856506, 0.42444512248039246, 0.8184217810630798, 0.5089022517204285, 0.29104331135749817, -0.3971445858478546, 0.9221587777137756, -0.47343069314956665, -0.35152173042297363, -0.8817567229270935, 0.17306317389011383, 0.1372106820344925, 0.6420496702194214...
func (mmAll *StorageMock) AllAfterCounter() uint64 { return mm_atomic.LoadUint64(&mmAll.afterAllCounter) }
[ 0.9107717275619507, -0.5927266478538513, 0.4684794247150421, 0.8623577356338501, -0.8687933683395386, -0.31415215134620667, 0.007444625720381737, 0.25304093956947327, 0.22399026155471802, -0.7985073328018188, -0.6958882212638855, -0.4457048773765564, -0.08057090640068054, 1.602642297744751...
func (mmAll *StorageMock) AllBeforeCounter() uint64 { return mm_atomic.LoadUint64(&mmAll.beforeAllCounter) }
[ 0.8400574326515198, -0.30275532603263855, 0.5035665035247803, 0.4366516172885895, -0.3049270212650299, -0.6031153798103333, 0.0933067724108696, 0.04291197657585144, 0.442091703414917, -0.10044597089290619, -0.4829771816730499, -0.42413657903671265, -0.33323779702186584, 1.6112035512924194,...
func (mmAll *mStorageMockAll) Calls() []*StorageMockAllParams { mmAll.mutex.RLock() argCopy := make([]*StorageMockAllParams, len(mmAll.callArgs)) copy(argCopy, mmAll.callArgs) mmAll.mutex.RUnlock() return argCopy }
[ -0.6913138628005981, -0.5034763216972351, 0.7277417182922363, 0.7648076415061951, 0.10884499549865723, 0.418437123298645, -1.3471579551696777, -0.09241408854722977, 0.5344851016998291, 0.36774590611457825, 0.1303599774837494, 0.250996470451355, -1.1287354230880737, 1.2024540901184082, -0...
func (m *StorageMock) MinimockAllDone() bool { for _, e := range m.AllMock.expectations { if mm_atomic.LoadUint64(&e.Counter) < 1 { return false } } // if default expectation was set then invocations count should be greater than zero if m.AllMock.defaultExpectation != nil && mm_atomic.LoadUint64(&m.afterAll...
[ 0.6364296674728394, -0.10351061075925827, 0.7357109189033508, 0.5223641395568848, 0.4475085735321045, 0.6491196155548096, 0.007818599231541157, 0.7397409081459045, -0.1264161616563797, -0.3968857228755951, 0.257359117269516, -0.4811384081840515, -1.0080006122589111, 1.4460750818252563, 0...
func (m *StorageMock) MinimockAllInspect() { for _, e := range m.AllMock.expectations { if mm_atomic.LoadUint64(&e.Counter) < 1 { m.t.Errorf("Expected call to StorageMock.All with params: %#v", *e.params) } } // if default expectation was set then invocations count should be greater than zero if m.AllMock.d...
[ 0.7132766842842102, -0.49073150753974915, 0.7800280451774597, 0.6484439969062805, 0.23613615334033966, 0.1432926058769226, -0.20338474214076996, 0.8906744718551636, -0.16521011292934418, -0.3256275951862335, 0.5390790700912476, -0.3436121940612793, -0.6799972057342529, 1.0775229930877686, ...
func (mmClone *mStorageMockClone) Expect(ctx context.Context, from insolar.PulseNumber, to insolar.PulseNumber, keepActual bool) *mStorageMockClone { if mmClone.mock.funcClone != nil { mmClone.mock.t.Fatalf("StorageMock.Clone mock is already set by Set") } if mmClone.defaultExpectation == nil { mmClone.defaultE...
[ -0.3930017948150635, -0.26325154304504395, 0.6841315031051636, 0.8912932872772217, 0.2983802258968353, 0.4004337787628174, 0.02042798511683941, 0.20075742900371552, -0.14039379358291626, 0.26198482513427734, 0.6327334642410278, 0.42547786235809326, -0.5502597093582153, -0.14838626980781555...
func (mmClone *mStorageMockClone) Inspect(f func(ctx context.Context, from insolar.PulseNumber, to insolar.PulseNumber, keepActual bool)) *mStorageMockClone { if mmClone.mock.inspectFuncClone != nil { mmClone.mock.t.Fatalf("Inspect function is already set for StorageMock.Clone") } mmClone.mock.inspectFuncClone = ...
[ -0.5411536693572998, -0.6423776149749756, 0.6305872201919556, 0.777075469493866, -0.43244656920433044, 0.6810862421989441, 0.8990233540534973, 0.5635626316070557, -0.54305499792099, 0.9306024312973022, 0.2653934061527252, -0.07600481808185577, 0.07239721715450287, -0.8062368631362915, 0....
func (mmClone *mStorageMockClone) Return(err error) *StorageMock { if mmClone.mock.funcClone != nil { mmClone.mock.t.Fatalf("StorageMock.Clone mock is already set by Set") } if mmClone.defaultExpectation == nil { mmClone.defaultExpectation = &StorageMockCloneExpectation{mock: mmClone.mock} } mmClone.defaultEx...
[ -0.5268864035606384, -0.38295668363571167, 0.544585645198822, 1.0931832790374756, 0.3041132986545563, 0.14840266108512878, 0.6972421407699585, 0.24293358623981476, 0.22299279272556305, 0.8952730298042297, 0.8684386610984802, -0.07297856360673904, -1.2157834768295288, -0.40239253640174866, ...
func (mmClone *mStorageMockClone) Set(f func(ctx context.Context, from insolar.PulseNumber, to insolar.PulseNumber, keepActual bool) (err error)) *StorageMock { if mmClone.defaultExpectation != nil { mmClone.mock.t.Fatalf("Default expectation is already set for the Storage.Clone method") } if len(mmClone.expectat...
[ -0.8633517026901245, -0.01695830374956131, 0.5849226117134094, 0.750025749206543, 0.6606142520904541, 0.41799554228782654, 0.5251424312591553, 0.12916365265846252, -0.5685597062110901, 0.756554365158081, 0.2633686363697052, -0.26831457018852234, -0.1875486522912979, -0.15613944828510284, ...
func (mmClone *mStorageMockClone) When(ctx context.Context, from insolar.PulseNumber, to insolar.PulseNumber, keepActual bool) *StorageMockCloneExpectation { if mmClone.mock.funcClone != nil { mmClone.mock.t.Fatalf("StorageMock.Clone mock is already set by Set") } expectation := &StorageMockCloneExpectation{ mo...
[ -0.2120097428560257, -0.7350738048553467, 0.7514579892158508, 0.6998602151870728, -0.31830865144729614, 0.8173772096633911, -0.4959743618965149, -0.08599342405796051, -0.26156094670295715, 0.3128468096256256, -0.06376709043979645, 0.534389317035675, -0.15710274875164032, -0.582129061222076...
func (e *StorageMockCloneExpectation) Then(err error) *StorageMock { e.results = &StorageMockCloneResults{err} return e.mock }
[ -0.485118567943573, -0.7024437785148621, 0.2917134165763855, 1.187453031539917, 0.8574557304382324, 0.5102960467338562, 0.13549304008483887, 0.20990358293056488, 0.029291298240423203, -0.10956954956054688, -0.6160999536514282, 0.5046932697296143, 0.047307103872299194, -0.2608698606491089, ...
func (mmClone *StorageMock) CloneAfterCounter() uint64 { return mm_atomic.LoadUint64(&mmClone.afterCloneCounter) }
[ 0.30973711609840393, -0.7517637014389038, 0.5098937153816223, 1.0154279470443726, -1.1197152137756348, 0.24381716549396515, 0.9341946840286255, -0.2999369204044342, 0.17874079942703247, -0.24173153936862946, -0.8817445635795593, -0.2811788022518158, -0.7846426963806152, 0.36692455410957336...
func (mmClone *StorageMock) CloneBeforeCounter() uint64 { return mm_atomic.LoadUint64(&mmClone.beforeCloneCounter) }
[ 0.17398542165756226, -0.10115506500005722, 0.5766980051994324, 0.6026433110237122, -0.47496360540390015, -0.2500690221786499, 0.8930697441101074, -0.5262016654014587, 0.21801729500293732, 0.11561121046543121, -0.2192019671201706, -0.09059569239616394, -1.176225185394287, 0.5271934866905212...
func (mmClone *mStorageMockClone) Calls() []*StorageMockCloneParams { mmClone.mutex.RLock() argCopy := make([]*StorageMockCloneParams, len(mmClone.callArgs)) copy(argCopy, mmClone.callArgs) mmClone.mutex.RUnlock() return argCopy }
[ -1.0290212631225586, -0.5279784202575684, 0.7489534616470337, 0.7766215205192566, 0.318958044052124, 0.3972755968570709, -0.910792350769043, -0.5443705320358276, 0.5074063539505005, 0.8308764100074768, 0.2099209427833557, 0.416282057762146, -1.1820731163024902, 0.4840313494205475, -0.650...
func (m *StorageMock) MinimockCloneDone() bool { for _, e := range m.CloneMock.expectations { if mm_atomic.LoadUint64(&e.Counter) < 1 { return false } } // if default expectation was set then invocations count should be greater than zero if m.CloneMock.defaultExpectation != nil && mm_atomic.LoadUint64(&m.af...
[ -0.30846869945526123, 0.2576463520526886, 0.701585590839386, 1.0144413709640503, 0.47523602843284607, 0.5077501535415649, 0.386321485042572, 0.2104036659002304, -0.32846587896347046, 0.3116537034511566, 0.13042008876800537, -0.4043113887310028, -1.5209331512451172, 0.27861353754997253, 0...
func (m *StorageMock) MinimockCloneInspect() { for _, e := range m.CloneMock.expectations { if mm_atomic.LoadUint64(&e.Counter) < 1 { m.t.Errorf("Expected call to StorageMock.Clone with params: %#v", *e.params) } } // if default expectation was set then invocations count should be greater than zero if m.Clo...
[ 0.14238619804382324, -0.18014083802700043, 0.6817187666893005, 0.6651686429977417, 0.38057494163513184, 0.21574142575263977, 0.10842854529619217, 0.19467197358608246, -0.27071699500083923, 0.39223167300224304, 0.5805562138557434, -0.020094631239771843, -0.6916226744651794, 0.18696016073226...
func (mmForID *mStorageMockForID) Expect(ctx context.Context, pulse insolar.PulseNumber, recordID insolar.ID) *mStorageMockForID { if mmForID.mock.funcForID != nil { mmForID.mock.t.Fatalf("StorageMock.ForID mock is already set by Set") } if mmForID.defaultExpectation == nil { mmForID.defaultExpectation = &Stora...
[ -0.16776689887046814, -0.0960833951830864, 0.40415602922439575, 0.04757605120539665, 0.46311962604522705, -0.41825658082962036, 0.12152921408414841, 0.06476649641990662, 0.04062836989760399, -0.44797128438949585, 0.25529786944389343, 0.3836396038532257, -0.17979267239570618, 0.323583513498...
func (mmForID *mStorageMockForID) Inspect(f func(ctx context.Context, pulse insolar.PulseNumber, recordID insolar.ID)) *mStorageMockForID { if mmForID.mock.inspectFuncForID != nil { mmForID.mock.t.Fatalf("Inspect function is already set for StorageMock.ForID") } mmForID.mock.inspectFuncForID = f return mmForID ...
[ -0.47611939907073975, -0.5620996356010437, 0.5602912902832031, -0.3593498468399048, -0.10791163146495819, -0.283149778842926, 0.716998279094696, 0.5917474627494812, -0.4257185757160187, -0.13557787239551544, 0.0957457572221756, -0.0925757884979248, 0.29209232330322266, -0.17117726802825928...
func (mmForID *mStorageMockForID) Return(j1 insolar.JetID, b1 bool) *StorageMock { if mmForID.mock.funcForID != nil { mmForID.mock.t.Fatalf("StorageMock.ForID mock is already set by Set") } if mmForID.defaultExpectation == nil { mmForID.defaultExpectation = &StorageMockForIDExpectation{mock: mmForID.mock} } m...
[ -0.4878418743610382, -0.0855027511715889, 0.4092544913291931, -0.2967991232872009, 0.460487425327301, -0.07449746876955032, 0.261651873588562, -0.2901861071586609, -0.10545354336500168, -0.26351749897003174, 0.3987292945384979, -0.5442367792129517, -0.5231744647026062, 0.028545979410409927...
func (mmForID *mStorageMockForID) Set(f func(ctx context.Context, pulse insolar.PulseNumber, recordID insolar.ID) (j1 insolar.JetID, b1 bool)) *StorageMock { if mmForID.defaultExpectation != nil { mmForID.mock.t.Fatalf("Default expectation is already set for the Storage.ForID method") } if len(mmForID.expectation...
[ -0.6529570817947388, 0.04967638850212097, 0.281803160905838, -0.3623915910720825, 0.8409532904624939, -0.10469765961170197, 0.299007385969162, 0.20866385102272034, -0.6951556205749512, -0.27309611439704895, 0.013683419674634933, -0.23275932669639587, 0.0965484008193016, 0.38727867603302, ...
func (mmForID *mStorageMockForID) When(ctx context.Context, pulse insolar.PulseNumber, recordID insolar.ID) *StorageMockForIDExpectation { if mmForID.mock.funcForID != nil { mmForID.mock.t.Fatalf("StorageMock.ForID mock is already set by Set") } expectation := &StorageMockForIDExpectation{ mock: mmForID.mock,...
[ 0.037632718682289124, -0.30088895559310913, 0.5094860792160034, -0.3168051838874817, -0.01562739722430706, 0.040510378777980804, -0.20980682969093323, 0.21125519275665283, -0.0042444332502782345, -0.7004543542861938, -0.6680573225021362, 0.405737966299057, 0.17918945848941803, 0.0219017490...
func (e *StorageMockForIDExpectation) Then(j1 insolar.JetID, b1 bool) *StorageMock { e.results = &StorageMockForIDResults{j1, b1} return e.mock }
[ -0.4450039863586426, -0.08753186464309692, 0.2745858430862427, 0.22517158091068268, 0.4005562961101532, 0.513298511505127, -0.27324721217155457, 0.3242403566837311, -0.8781789541244507, -0.49173980951309204, -1.023100733757019, 0.16150186955928802, -0.20498335361480713, -0.1964158415794372...
func (mmForID *StorageMock) ForIDAfterCounter() uint64 { return mm_atomic.LoadUint64(&mmForID.afterForIDCounter) }
[ 0.4243602156639099, -0.40590527653694153, 0.3706035017967224, -0.27537059783935547, -0.5161182284355164, -0.5883939862251282, 0.7550240159034729, -0.324895977973938, -0.41580864787101746, -1.2908210754394531, -0.5663890838623047, -0.8107706904411316, -0.026298418641090393, 0.68465489149093...
func (mmForID *StorageMock) ForIDBeforeCounter() uint64 { return mm_atomic.LoadUint64(&mmForID.beforeForIDCounter) }
[ 0.27840638160705566, 0.010316411964595318, 0.4094783067703247, -0.6194023489952087, 0.26214665174484253, -0.8410447835922241, 0.6212195158004761, -0.4017347991466522, -0.15589335560798645, -0.8657068610191345, -0.14378982782363892, -0.4043295681476593, -0.14918415248394012, 0.6871598362922...
func (mmForID *mStorageMockForID) Calls() []*StorageMockForIDParams { mmForID.mutex.RLock() argCopy := make([]*StorageMockForIDParams, len(mmForID.callArgs)) copy(argCopy, mmForID.callArgs) mmForID.mutex.RUnlock() return argCopy }
[ -1.0359784364700317, -0.27790194749832153, 0.460819274187088, -0.03311484679579735, 0.5263732075691223, 0.00606536865234375, -1.2616239786148071, -0.9046408534049988, 0.3114073872566223, -0.04989463463425636, -0.013984402641654015, 0.06699459999799728, -0.7317990660667419, 0.69853574037551...
func (m *StorageMock) MinimockForIDDone() bool { for _, e := range m.ForIDMock.expectations { if mm_atomic.LoadUint64(&e.Counter) < 1 { return false } } // if default expectation was set then invocations count should be greater than zero if m.ForIDMock.defaultExpectation != nil && mm_atomic.LoadUint64(&m.af...
[ -0.07156562805175781, -0.1833757609128952, 0.43884649872779846, -0.35441461205482483, 0.9984086155891418, 0.4019833207130432, 0.31969138979911804, -0.05868424102663994, -0.47619500756263733, -0.6791121959686279, 0.2606184780597687, -0.5043156147003174, -0.9249828457832336, 1.18291151523590...
func (m *StorageMock) MinimockForIDInspect() { for _, e := range m.ForIDMock.expectations { if mm_atomic.LoadUint64(&e.Counter) < 1 { m.t.Errorf("Expected call to StorageMock.ForID with params: %#v", *e.params) } } // if default expectation was set then invocations count should be greater than zero if m.For...
[ 0.05825813114643097, -0.3175295889377594, 0.5263776779174805, -0.22873909771442413, 0.8510451912879944, -0.11522011458873749, 0.2820907235145569, 0.14544489979743958, -0.5029461979866028, -0.7023951411247253, 0.565816342830658, -0.19712452590465546, -0.45156949758529663, 0.624244213104248,...
func (mmSplit *mStorageMockSplit) Expect(ctx context.Context, pulse insolar.PulseNumber, id insolar.JetID) *mStorageMockSplit { if mmSplit.mock.funcSplit != nil { mmSplit.mock.t.Fatalf("StorageMock.Split mock is already set by Set") } if mmSplit.defaultExpectation == nil { mmSplit.defaultExpectation = &StorageM...
[ -0.5157192349433899, 0.17969463765621185, 0.46127453446388245, 0.07597065716981888, 0.27322614192962646, 0.17335417866706848, 0.46680527925491333, 0.7014496922492981, 0.19350045919418335, -0.15759509801864624, 0.1572985053062439, 0.20335860550403595, -0.8113822937011719, 0.3045667409896850...