8

Is there a way to print the SELection?

 2 years ago
source link: https://www.codesd.com/item/is-there-a-way-to-print-the-selection.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
neoserver,ios ssh client

Is there a way to print the SELection?

advertisements

For example, I want to trace the actions sent to my canPeformAction and they are too numerous to display at each occurrence with a "hover" in the debugger. Therefore, I want to trace to the log and examine it after my test cycle.

- (BOOL)canPerformAction:(SEL)action withSender:(id)sender {
    NSLog(@"%s: sender=%@", __FUNCTION__, sender, action);
}


You want

NSLog(@"%s: sender=%@, selector=%s", __FUNCTION__, sender,sel_getName(action));

Related Articles

For Ruby on Rails, is there a way to print the name of the web server (like Apache), possibly by Rack?

If I am running a Rails 2 or Rails 3 app, is there a way to print out the web server's name on a page (such as /foos/index)... or if Rails doesn't have any knowledge what the server is, can Rack do it?In the CGI environment, the SERVER_SOFTWARE varia

Is there a way to follow the selection range in the iframe design model?

I've been experimenting with this for a while but didn't get anything working well - is there any way to track mouseups and selections in iframe's designMode, preferably in a cross-browser compatible mode?Here's a small snippet of code I found here,

Is there a way to print the prepared statement as a string with all placeholders replaces with its actual values

This question already has an answer here: How can I get the SQL of a PreparedStatement? 9 answers Get query from java.sql.PreparedStatement [duplicate] 8 answers Is there a way we can print prepared statement as a string with all the placeholders rep

Is there a way to print the time every minute from a pipeline command without interrupting the output?

I have a long piped tail command that I execute over ssh (eg. tail -f <file>|egrep -v "lol"), and normally there is not much output and want to be sure that the connection is stile live and would like to print the time every 60 or 300 seco

Is there a way to print the console log from JavaScript, in HTML?

Say I had some JavaScript function which, when run, logged its output in the console - using console.log(). After the function has run, is there a way to make it export the result into the HTML console? ThanksYou can overwrite the default function wi

Is there a way to print the PID of the process that called my binary C

I need to know which perl script is using my C CLI. Using bash I can easily print "who" ran a script using: CALLER=$(ps ax | grep "^ *$PPID" | awk '{print $NF}') echo $CALLER Up to now I have been using this as a wrapper but it's not i

Is there a way to print the variable / pointer type in C?

I want to print out (or otherwise ascertain) the type of some variable in my program. Is there a good way to do it? By good, I mean a way that works, even if it means intentionally throwing compiler errors. For example: client.c:55: error: incompatib

Is there a way to print the structure of a multi-module project maven?

I'm facing a rather large multi module maven project. I would like to see how the root (parent) project is composed out of subprojects/ child projects in the form of groupId:artifactId (possible with some identation to reflect the hierarchy. Of cours

Is there a way to print the name of the class on which an iterator indicates?

Assume I have a program that works according to the following hierarchy: And I have a linked list container of Human * which I am iterating over with std::list<Human *>::iterator human. The following iterator can point either Men, Women and Flying M

Is there a way to print the bit representation of an object?

I'm using something like the following. Is there a better way? for (int i = 0; i < sizeof(Person) ; i++) { const char &cr = *((char*)personPtr + i); cout << bitset<CHAR_BIT>(cr); } I would suggest to provide a serialize_as_binary utilit

WPF- Is there a way to link the selected values ​​of both a TreeView and a ListBox?

I need to bind so that the Content of a content control is set to the SelectedValue of either the TreeView or the ListBox. The SelectedValue that was most recently changed should provide the content for the ContentControl.I was able to get this worki

Is there a way to print the bits without using a C-loop?

Right now, what I do is this: void print_bits(unsigned int x) { int i; for(i=WORD_SIZE-1; i>=0; i--) { (x & (1 << i)) ? putchar('1') : putchar('0'); } printf("\n"); } Also, it would be great to have a solution independent of word si

Is there a way to print integers at once through the int pointer?

#include<stdio.h> int main(){ int integers[40] = {1,2,3,4,5,6,7,8,9,10,-1}; int integers1[40]; int *ptr; int *ptr1; ptr = integers; ptr1 = integers1; while(*ptr != -1){ *ptr1++ = *ptr++; } *ptr1 = -1; ptr1 = integers1; while(*ptr1 != -1){ printf(&qu

Question from RabbitMQ - Is there a way to print a log message to the console?

I am running RabbitMQ on windows 7 ( currently for debug reasons). I want to see the messages on the open console each time I send a message. Is there a way to rout the logs to the open console? 10xCreate a logger application that connects to rabbitM

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK