addTrips method

int addTrips(
  1. String filename
)

Import routes from a file and add them to this bookmarks collection.

The method attempts to parse and import trips from the given filename. On success it returns the number of imported routes. If the import fails the method returns an error code (for example GemError.invalidInput.code).

Parameters

  • filename: Path to the file containing exported bookmarks/trips.

Returns

Implementation

int addTrips(final String filename) {
  final OperationResult resultString = objectMethod(
    pointerId,
    'RouteBookmarks',
    'addTrips',
    args: filename,
  );

  return resultString['result'];
}