MCPcopy Index your code
hub / github.com/dronekit/dronekit-python / __len__

Method __len__

dronekit/__init__.py:2744–2750  ·  view source on GitHub ↗

Return number of waypoints. :return: The number of waypoints in the sequence.

(self)

Source from the content-addressed store, hash-verified

2742 self._vehicle._master.waypoint_set_current_send(index)
2743
2744 def __len__(self):
2745 '''
2746 Return number of waypoints.
2747
2748 :return: The number of waypoints in the sequence.
2749 '''
2750 return max(self._vehicle._wploader.count() - 1, 0)
2751
2752 def __getitem__(self, index):
2753 if isinstance(index, slice):

Callers

nothing calls this directly

Calls 1

countMethod · 0.45

Tested by

no test coverage detected