Set Record path: sd/ftp
        cmd: setRecordPath
        param:
             path: (0,SD), (2, FTP)
499888
def set_record_path(self, path, callback=None):
        '''
        
        '''
        params = {'Path': path}
        return self.execute_command('setRecordPath', params, callback=callback)
321596
def record(self, record=True, tag=None):
        
        path = '/startvideo?force=1' if record else '/stopvideo?force=1'
        if record and tag is not None:
            path = '/startvideo?force=1&tag={}'.format(URL(tag).raw_path)

        return self._request(path)
1062923
def _startRecording(self, filename):
        
        self.setOption('_log_file_name', filename)
        self.setOption('_log_input_only', True)
        self.setOption('_log', True)
1135360
def set_recording(is_recording): #pylint: disable=redefined-outer-name
    
    prev = ctypes.c_int()
    check_call(_LIB.MXAutogradSetIsRecording(
        ctypes.c_int(is_recording), ctypes.byref(prev)))
    return bool(prev.value)
947474
async def set_record(self, *, chat: typing.Union[str, int, None] = None, user: typing.Union[str, int, None] = None,
                         state=None, data=None, bucket=None):
        
        if data is None:
            data = {}
        if bucket is None:
            bucket = {}

        chat, user = self.check_address(chat=chat, user=user)
        addr = f"fsm:{chat}:{user}"

        record = {'state': state, 'data': data, 'bucket': bucket}

        conn = await self.redis()
        await conn.execute('SET', addr, json.dumps(record))
609750
def setLogFile(self, filepath):
        
        if filepath is None:
            self._log_file = None
            return
        parsed_path = os.path.abspath(filepath)
        # Checks if the provided log filename is in a real directory, and that
        # the filename itself is not a directory.
        if os.path.isdir(os.path.dirname(parsed_path)) and not os.path.isdir(parsed_path):
            self._log_file = parsed_path
        else:
            raise IOError("File not found: " + filepath)
504077
def _SetPath(self, path):
    
    old_path = self._path
    if old_path and not io_wrapper.IsCloudPath(old_path):
      try:
        # We're done with the path, so store its size.
        size = tf.io.gfile.stat(old_path).length
        logger.debug('Setting latest size of %s to %d', old_path, size)
        self._finalized_sizes[old_path] = size
      except tf.errors.OpError as e:
        logger.error('Unable to get size of %s: %s', old_path, e)

    self._path = path
    self._loader = self._loader_factory(path)
244451
def record_file_factory(pid, record, filename):
    
    try:
        if not (hasattr(record, 'files') and record.files):
            return None
    except MissingModelError:
        return None

    try:
        return record.files[filename]
    except KeyError:
        return None
545074
def set_file(self, filename):
        
        # Use the file name as prefix if none is given
        if self.output_prefix is None:
            _, self.output_prefix = os.path.split(filename)
        # Check if the file is present, since rdpcap will not do that
        if not (os.path.isfile(filename) and os.access(filename, os.R_OK)):
            print 'The file \'{0}\' is either not present or not readable. '\
                  'Exiting!'.format(filename)
            sys.exit(1)
        try:
            packets = rdpcap(filename)
        except NameError:
            # Due probably to a bug in rdpcap, this kind of error raises a
            # NameError, because the exception that is tried to raise, is not
            # defined
            print 'The file \'{}\' is not a pcap capture file. Exiting!'\
                .format(filename)
            sys.exit(2)

        for number, packet in enumerate(packets):
            # See if there is a field called load
            self._debug('\nNUMBER {0}'.format(number), no_prefix=True)
            try:
                # Will cause AttributeError if there is no load
                packet.getfieldval('load')
                # Get the full load
                load = packet.sprintf('%TCP.payload%')
                self._debug('PAYLOAD LENGTH {0}'.format(len(load)),
                            no_prefix=True)
                self._debug(load, load=True)
                self._parse_load(load)
            except AttributeError:
                self._debug('LOAD EXCEPTION', no_prefix=True)
        if len(self.messages) > 0 and not self.messages[-1].write_closed:
            self._debug('DELETE LAST OPEN FILE')
            del self.messages[-1]

        if self.args.debug_analysis:
            sys.exit(0)
79084
def set_fingerprint(fullpath, fingerprint=None):
    
    try:
        fingerprint = fingerprint or utils.file_fingerprint(fullpath)

        record = model.FileFingerprint.get(file_path=fullpath)
        if record:
            record.set(fingerprint=fingerprint,
                       file_mtime=os.stat(fullpath).st_mtime)
        else:
            record = model.FileFingerprint(
                file_path=fullpath,
                fingerprint=fingerprint,
                file_mtime=os.stat(fullpath).st_mtime)
        orm.commit()
    except FileNotFoundError:
        orm.delete(fp for fp in model.FileFingerprint if fp.file_path == fullpath)
1281155
def set_diff(self, file_diff):
        
        self.file_diff = file_diff
        self.__record_progress(Status.START_UPLOAD)
313505
def rewrite_record(bdist_dir):
    
    info_dirs = glob.glob(pjoin(bdist_dir, '*.dist-info'))
    if len(info_dirs) != 1:
        raise WheelToolsError("Should be exactly one `*.dist_info` directory")
    record_path = pjoin(info_dirs[0], 'RECORD')
    record_relpath = relpath(record_path, bdist_dir)
    # Unsign wheel - because we're invalidating the record hash
    sig_path = pjoin(info_dirs[0], 'RECORD.jws')
    if exists(sig_path):
        os.unlink(sig_path)

    def walk():
        for dir, dirs, files in os.walk(bdist_dir):
            for f in files:
                yield pjoin(dir, f)

    def skip(path):
        """Wheel hashes every possible file."""
        return (path == record_relpath)

    with _open_for_csv(record_path, 'w+') as record_file:
        writer = csv.writer(record_file)
        for path in walk():
            relative_path = relpath(path, bdist_dir)
            if skip(relative_path):
                hash = ''
                size = ''
            else:
                with open(path, 'rb') as f:
                    data = f.read()
                digest = hashlib.sha256(data).digest()
                hash = 'sha256=' + native(urlsafe_b64encode(digest))
                size = len(data)
            path_for_record = relpath(
                path, bdist_dir).replace(psep, '/')
            writer.writerow((path_for_record, hash, size))
357864
def _gen_records(self, record, zone_id, creating=False):
        '''
        
        '''
        return _Route53Record.new(self, record, zone_id, creating)
324822
def register_path(self, path):
        
        self._paths.insert(0, os.path.abspath(path))
736517
def create_record_ptr(self, record, data, ttl=60):
        
        resource_record = self._generate_create_dict(record, 'PTR', data, ttl)

        return self.record.createObject(resource_record)
1021669
def _record_count(self):
        

        self.filepath_or_buffer.seek(0, 2)
        total_records_length = (self.filepath_or_buffer.tell() -
                                self.record_start)

        if total_records_length % 80 != 0:
            warnings.warn("xport file may be corrupted")

        if self.record_length > 80:
            self.filepath_or_buffer.seek(self.record_start)
            return total_records_length // self.record_length

        self.filepath_or_buffer.seek(-80, 2)
        last_card = self.filepath_or_buffer.read(80)
        last_card = np.frombuffer(last_card, dtype=np.uint64)

        # 8 byte blank
        ix = np.flatnonzero(last_card == 2314885530818453536)

        if len(ix) == 0:
            tail_pad = 0
        else:
            tail_pad = 8 * len(ix)

        self.filepath_or_buffer.seek(self.record_start)

        return (total_records_length - tail_pad) // self.record_length
241312
public void setPath(int pathId, String path) {
        PreparedStatement statement = null;
        try (Connection sqlConnection = sqlService.getConnection()) {
            statement = sqlConnection.prepareStatement(
                "UPDATE " + Constants.DB_TABLE_PATH +
                    " SET " + Constants.PATH_PROFILE_ACTUAL_PATH + " = ? " +
                    " WHERE " + Constants.GENERIC_ID + " = ?"
            );
            statement.setString(1, path);
            statement.setInt(2, pathId);
            statement.executeUpdate();
            statement.close();
        } catch (SQLException e) {
            e.printStackTrace();
        } finally {
            try {
                if (statement != null) {
                    statement.close();
                }
            } catch (Exception e) {
            }
        }
    }