def truncate()

in tbapi/__init__.py [0:0]


    def truncate(self, timestamp: int, entities: 'list[str]' = None) -> bool:
        '''Truncates stream data for the given entities from given time

        Args:
            timestamp (int): Timestamp in millis. If time less than stream start time, then all stream data will be deleted.
            entities (list[str]): A list of entities. If None, all stream entities will be used.

        Returns:
            bool: true, if stream was truncated successfully.
        '''
        if entities == None:
            return self.__truncate(timestamp)
        else:
            return self.__truncateEntities(timestamp, entities)