回传数据

        https://wximg.qq.com/wxp/pdftool/get.html?id=rkalQXDBM&pa=39

        :param actions: 用户行为源类型
        :param version: 版本号 v1.0
160363
def add_user_actions(self, actions=(), version='v1.0'):
        
        return self._post(
            'user_actions/add',
            params={'version': version},
            json={'actions': actions}
        )
431747
def _get_prefixes_for_action(action):
    
    (technology, permission) = action.split(':')
    retval = ["{}:".format(technology)]
    phrase = ""
    for char in permission:
        newphrase = "{}{}".format(phrase, char)
        retval.append("{}:{}".format(technology,newphrase))
        phrase = newphrase
    return retval
1188057
public static PdfAction gotoLocalPage(int page, PdfDestination dest, PdfWriter writer) {
        PdfIndirectReference ref = writer.getPageReference(page);
        dest.addPage(ref);
        PdfAction action = new PdfAction();
        action.put(PdfName.S, PdfName.GOTO);
        action.put(PdfName.D, dest);
        return action;
    }
585928
def batch_generate_pdf_v1(template_id, request_body, opts = {})
      data, _status_code, _headers = batch_generate_pdf_v1_with_http_info(template_id, request_body, opts)
      data
    end
622701
@Deprecated
  @SuppressWarnings("unused")
  public void operaAction(String using, String... params) {
    exec.action(using, params);
  }
468954
def expand_action(data):
        
        # when given a string, assume user wants to index raw json
        if isinstance(data, string_types):
            return '{"index": {}}', data

        # make sure we don't alter the action
        data = data.copy()
        op_type = data.pop(EsBulk.OP_TYPE, EsBulk.INDEX)

        action = ActionParser._get_relevant_action_params(data, op_type)

        # no data payload for delete
        if op_type == EsBulk.DELETE:
            return action, None

        return action, data.get(EsDocProperties.SOURCE, data)
1254784
def exportAs(self, action):
        
        plugin = self.exporter(unwrapVariant(action.data()))
        if not plugin:
            return False
        
        ftypes = '{0} (*{1});;All Files (*.*)'.format(plugin.name(),
                                                      plugin.filetype())
        filename = QtGui.QFileDialog.getSaveFileName(self.window(),
                                                     'Export Data',
                                                     '',
                                                     ftypes)
        
        if type(filename) == tuple:
            filename = filename[0]
        
        if filename:
            return self.export(nativestring(filename), exporter=plugin)
        return False
1326082
def response_action(self, request, queryset):  # noqa
        
        # There can be multiple action forms on the page (at the top
        # and bottom of the change list, for example). Get the action
        # whose button was pushed.
        try:
            action_index = int(request.POST.get('index', 0))
        except ValueError:  # pragma: no cover
            action_index = 0

        # Construct the action form.
        data = request.POST.copy()
        data.pop(helpers.ACTION_CHECKBOX_NAME, None)
        data.pop("index", None)

        # Use the action whose button was pushed
        try:
            data.update({'action': data.getlist('action')[action_index]})
        except IndexError:  # pragma: no cover
            # If we didn't get an action from the chosen form that's invalid
            # POST data, so by deleting action it'll fail the validation check
            # below. So no need to do anything here
            pass

        action_form = self.action_form(data, auto_id=None)
        action_form.fields['action'].choices = self.get_action_choices(request)

        # If the form's valid we can handle the action.
        if action_form.is_valid():
            action = action_form.cleaned_data['action']
            func, name, description = self.get_actions(request)[action]

            # Get the list of selected PKs. If nothing's selected, we can't
            # perform an action on it, so bail.
            if action_form.cleaned_data['select_across']:
                selected = ALL
            else:
                selected = request.POST.getlist(helpers.ACTION_CHECKBOX_NAME)

            if not selected:
                return None

            revision_field = self.model._concurrencymeta.field

            if self.check_concurrent_action:
                self.delete_selected_confirmation_template = self.get_confirmation_template()

                # If select_across we have to avoid the use of concurrency
                if selected is not ALL:
                    filters = []
                    for x in selected:
                        try:
                            pk, version = x.split(",")
                        except ValueError:  # pragma: no cover
                            raise ImproperlyConfigured('`ConcurrencyActionMixin` error.'
                                                       'A tuple with `primary_key, version_number` '
                                                       'expected:  `%s` found' % x)
                        filters.append(Q(**{'pk': pk,
                                            revision_field.attname: version}))

                    queryset = queryset.filter(reduce(operator.or_, filters))
                    if len(selected) != queryset.count():
                        messages.error(request, 'One or more record were updated. '
                                                '(Probably by other user) '
                                                'The execution was aborted.')
                        return HttpResponseRedirect(".")
                else:
                    messages.warning(request, 'Selecting all records, you will avoid the concurrency check')

            response = func(self, request, queryset)

            # Actions may return an HttpResponse, which will be used as the
            # response from the POST. If not, we'll be a good little HTTP
            # citizen and redirect back to the changelist page.
            if isinstance(response, HttpResponse):
                return response
            else:
                return HttpResponseRedirect(".")
1272964
def TryAction(self, action, text = None, extension = ""):
        
        builder = SCons.Builder.Builder(action=action)
        self.env.Append( BUILDERS = {'SConfActionBuilder' : builder} )
        ok = self.TryBuild(self.env.SConfActionBuilder, text, extension)
        del self.env['BUILDERS']['SConfActionBuilder']
        if ok:
            outputStr = self.lastTarget.get_contents().decode()
            return (1, outputStr)
        return (0, "")
1150411
def all_actions(self):
        
        count = self.get_count_action()
        page = 1
        while True:  # не цикл for, потому как не уверен, что всё норм будет с API
            actions = self.get_action_list(page=page)
            for action in actions:
                yield action
            page += 1
            if len(actions) < options.ACTIONS_ON_PAGE or page > math.ceil(count / options.ACTIONS_ON_PAGE):
                break
130254
def getAction(self, action_name):
        

        self.log.debug("Try to get <Action %s>", action_name)
        if not isinstance(action_name, six.string_types) or not action_name:
            excp_msg = "Please specify a valid action name"
            self.log.error(excp_msg)
            raise exception.BadValue(excp_msg)

        actions = self._getActions(action_name=action_name)

        if actions is not None:
            action = actions[0]
            self.log.info("Find <Action %s>", action)
            return action

        self.log.error("No Action named %s", action_name)
        raise exception.NotFound("No Action named %s" % action_name)
1131633
def findUiActions( widget ):
    
    import_qt(globals())
    
    output = []
    for action in widget.findChildren(QtGui.QAction):
        name = nativestring(action.objectName()).lower()
        if ( name.startswith('ui') and name.endswith('act') ):
            output.append(action)
    return output
1228784
def readCLIPACTIONRECORD(self, version):
        
        pos = self.tell()
        flags = self.readUI32() if version >= 6 else self.readUI16()
        if flags == 0:
            return None
        else:
            self.seek(pos)
            return SWFClipActionRecord(self, version)
365193
Integer getVersionOrThrow(CMAResource resource, String action) {
    final Integer version = resource.getVersion();
    if (version == null) {
      throw new IllegalArgumentException(String.format(
          "Cannot perform %s action on a resource that has no version associated.",
          action));
    }
    return version;
  }
751915
function getRowSample1() {
  //设置读取最新版本，默认为1
  params.maxVersions = 1;
  //设置读取指定的列
  params.columnsToGet = ["Col1", "Col2"];
  client.getRow(params, function (err, data) {
    if (err) {
      console.log('error:', err);
      return;
    }
    console.log('success:', data);
  });
}
359133
def wkf_action(action, context={}, reload=true)
      self.class.object_service(:exec_workflow, self.class.openerp_model, action, self.id, context)
      reload_fields if reload
    end
808357
async def get_actions(self, schema=False):
        
        actions = {}
        entity = [{"tag": self.tag}]
        action_facade = client.ActionFacade.from_connection(self.connection)
        results = (
            await action_facade.ApplicationsCharmsActions(entity)).results
        for result in results:
            if result.application_tag == self.tag and result.actions:
                actions = result.actions
                break
        if not schema:
            actions = {k: v['description'] for k, v in actions.items()}
        return actions