Posts

Showing posts from January, 2010

module - Dynamic loading and symbols sharing -

I am trying to load a module library by dl in this way, So that the module uses the world from the main application. How is this possible? I get an error message from Duppen, which is saying library / name.so: undefined symbol: ... . Its use is the only flag: RTLD_NOW . The module itself is manufactured with the written form -module -avoid-version . The answer is: When adding the main code, -Wl, - export-dynamic All symbols are automatically exported to the libraries loaded. The same question, just asked in a different way:

sql server - Copy data from one database to another using VB.NET -

I have to copy the data from one database to another using the VB.NET program. The target database is SQL Server's source database, some ownership is ODBC compliant database. I need to loop through a list of tables to copy. Read the data from the source database table for a modified date. Delete the date related to the target database table and enter the record from the source table. The databases are of the same structure i.e. The table name and the field name, but the data types may vary (although they are analog, double in the source, float in the target) no primary key exists. This is how I can do it: First, execute the order to remove the target. I can then use a detourder to get data from the source, loop through the item and create an insert order for each line. Add and execute parameters in the command with appropriate values. And wrap the whole thing in the transaction. I was just thinking that I remember any trick here. Any suggestion / This trick will be...

Generate XML with PHP and pass it to an SWF -

In the past I have created a php file that generates XML and then it refers to XML file instead and in it Worked. I'm trying it with a precompiled flash app and it's not working. Any ideas why? This works if I run the script, save it and then swf that reference to that file. If possible, I will not generate the file on the file system, what is the solution? If you drag the PHP page into the browser, then are you sure: There is no white spot before the XML prologue ( & lt;? Xml version = "1.0" ...? & Gt; ) in the file XML To check one more thing, see Firebug on the net panel ... it shows all those requests / reactions - They were done by Flash (including them) It's embedded in a web page) and make sure your flash is actually looking for the file you think.

iphone - Deselect UIButton on touch down outside -

मेरे पास एक UIButton है जो कि UIControlEventTouchUpInside पर स्वयं का चयन करता है। यह स्वतः UIControlEventTouchUpOutside पर अचयनित करता है मैं यह भी खुद को अचयनित करना चाहता हूं जब बटन के बाहर एक स्पर्श होता है UIWindow और ओवरराइड -hitTest: withEvent: ? संपादित करें: मैं ऐसा करने का एक अच्छा तरीका है बस मिला, जो मुझे डर की पुष्टि करता है कि ऐसा करने के लिए कोई बहुत ही साफ तरीका नहीं है। यह यह नहीं है कि कैसे बटन काम करना चाहिए। अगर उनके अंदर कोई स्पर्श सक्रिय नहीं है तो वे सक्रिय नहीं हो सकते। क्या आप वास्तव में लागू करने की कोशिश कर रहे हैं? शायद एक UIBUtton सबसे अच्छा विकल्प नहीं है।

How should email address opt-in implemented? -

Scenario: The user gives you an email address before signing up for the services, Email address must be validated - You email, click on the URL, then they can subscribe to the services. Question: What does the URL look like? I'm thinking that a random guide would be fine. Do you use the same random key to cancel requests? Is anyone looking for double-opt-in to implementing a good open source? I have used random GUID before such objectives to verify an email account, And it works well until you're working with ultra-safe, ultra-sensitive data, then it should be enough. I do not see the reason for using a single GUID for no request - in this way you need to store a GUID in an account that your Subscriber database (or you can store them). You can add unsubscribed links at the bottom of all e-mails, which can make this a simple one-click option.

iphone - MPMoviePlayerController release problem -

यहाँ कोड है - (शून्य) आवेदनडिफ़फिशः लॉन्चिंग: (UIApplication *) अनुप्रयोग {NSBundle * बंडल = [एनएसबींडल मुख्य बंडल]; NSString * moviePath = [बंडल पथफ़ोरेआरएसओर्स: @ "sample_mpeg4" टाइप की: @ "एमपी 4"]; एनएसड्राएल * मूवीURL = [[एनएसआरआर फ़ाइल यूआरएलथैथपाथ: फिल्मपैथ] बनाए रखा गया है; एमपी एमपीवीप्लेयर कंट्रोलर * मूवी प्लेयर = [[एमपी एमपीवीप्लेयर कंट्रोलर एलोक] इनट विथ कंटेंट यूआरएल: मूवीURL]; मूवी प्लेअर। मूवी कंट्रोलमॉड = एमपीएमवीई कंट्रोलमोडहाइड; [मूवी प्लेयर प्ले]; [[NSNotificationCenter defaultCenter] addObserver: स्वयं चयनकर्ता: @ सिलेक्टर (मूवी पीलेबैकडिफफ़िन्स :) नाम: एमपीएमवीप्लेयरप्लेबैकडिफ़फ़िनीशनोटेशन ऑब्जेक्ट: शून्य]; } - (शून्य) मूवी PlaybackDidFinish: (NSNotification *) अधिसूचना {एमपी एमपीवीप्लेयर कंट्रोलर * theMovie = [सूचना ऑब्जेक्ट]; [[NSNotificationCenter defaultCenter] हटायेंऑब्सर्वर: स्वयं का नाम: एमपी एमपीवीप्लेयरप्लेबैकडिफ़फ़िन्शनोटिफिकेशन ऑब्जेक्ट: मूवी]; [मूवी स्टॉप]; [मूवी रिलीज]; [खिड़की जोड़ेंस्यूब्यूव्यू: टैबबार नियंत्रक.दृश्य]; [खिड...

Windows 7: Loop through Taskbar items -

I'm trying to create a small utility for just for myself that appear in the taskbar Window where there is no information in the label (for example, "iTunes", "Microsoft SQL Server MGMT Studio", "~ CMD.axa"), but windows like Windows Explorer and Visual Studio and MSN have been unglrapped Which Fol Ders are listed, which projects are open, and you are talking name). I am trying to loop through windows on the windows 7 in the taskbar, but without any fate. I got some samples for XP's taskbar reader, they are no longer useful. I have tested samples in WindowsAPICodePack for Windows 7 taskbar manipulation, but it only allows me to access the windows of my processes.

php - Dropdown select based on database entries -

Therefore, I want to automatically populate the "yes" selection of the dropdown, or alternatively, "no" Would like to select The dropdown which will be used to evaluate the returned value from the database query will be selected. I have thought that since it is a real / incorrect auto-population to write only two conditions, but I thought the way to write code is better (read: less messy code) Depending on the result, auto-populate the correct selection from the drop down. The code base I am trying to write will check the variables against all the selections, then by adding a string that will select the drop down to see the user. My question is that this would be an easy way to do this, instead of $ this-> Db- & gt; Select (select 'row') Code Inquiry Code written by PHP in code for every possible drop down value:); $ Result = $ this- & gt; Db- & gt; Obtain ('Table'); // It just selects the values ​​and returns this code ...

sql - Firebird database tuning for multiprocessor -

I am running a software named Fishbol inventory and it is running on a Firebird Database (Windows Server 2003). At this time FishWell software is running very slow when a user reaches the software. I am thinking that any database or best practices can provide some information on tuning? We are currently running a Dell Power Edge 2700 Dual Trad Core with 4 GHz Ram. Any help would be greatly appreciated. Thanks in advance Robert I developed for Fisherball Inventory (2009-2010.2) Report and my business partner is a fishbol wars. We have dealt with the clients with slow databases. Give me a shout at Elbowz on Fishbollarports. Com It's strange that your server interval is visible with those glasses, but this is not unheard of. 1) Database size - Large rows will be settled while working on big DB, report / update etc. 2) Activities - some activities on the server pound 3) Variant - additional indexes on tables in new fishball editions Which allows quick questions Most of...

django: request.user is an int, not a User object -

I am using django 1.0 and I have views.py in a way that starts like this: / P> def my_view (request, org_id): a = request.user.is_staff () # Error in this line is # more code ... when I try to load the page, I got the error "The int object is not able to call" on the line described above "My users" is a "user" object in the files that are imported at the top of view.py Is, lake And deleting this import statement from view.py does not make this error. Is it possible that this other user class is probably struggling in one of my files, perhaps? Do you have any other suggestions that what might be the reason for this error? I think the problem is is_staff () . Try a = request.user.is_staff is_staff is an area of ​​the model. But it is boolean, however it may be that it is stored internally as int .

css - forcing width of menu items to take up 100% -

I site: www.yoursdproperty.com I need Top menu items home, buy property, selling property etc ... To raise 100% of the width of the top bar, If I add more items, then I moved them accordingly. Here is the CSS associated with this menu bar. Can I change something here to do this? / * Mu Menu * / #cssmenu_moo_menu {padding: 0; Margin: 0; } # Cssmenu_moo_menu a {float: left; Text-decoration: none; Display area; Cursor: indicator; Height: 35px; Font-size: 14px; font-weight: bold; Line-height: 35px; Padding: 0 15px; Hidden flurry; Border-right: 1px solid # 0d85c9; } # Cssmenu_moo_menu li li {font-weight: bold; Font-size: 12px; Border-right: none; Padding: 0; } #cssmenu_moo_menu ul {height: 35px; Swim left; List-style: none; Margin: 0; } # Cssmenu_moo_menu {background: # 006198 url (../images/moomenu.png) Repeat-X 50% Top; Height: 35px; Swim left; List-style: none; Margin: 0; Padding: 0; } # Cssmenu_moo_menu li li {padding: 0; Background: None; } # Cssmenu_moo_menu ul ul al a ...

svn - AnkhSVN not pulling in files created by another user in the same solution in VS 2008? -

I have VS SLN with about 5 projects which I have created with most files in each project. I am making a change to SVN and it is just Peaches, another developer has just started and he is VS And can be committed to the repository (I consider them full control as a user), but I can not retrieve them through the account. I can see those files which have been added to the repo browser, but when the project updates are found or the whole solan is available to the server then I can not find their file. Whatever I add, but not in other way is there a user setting which I am missing that will create this situation? I have seen it today, and I need unit tests and a full build ASAP for their files. Any ideas? Thank you. AnkhSVN may be updated with your description, you went to this famous bug: To get this work again, update your working copy with a set depth set to Infinity (since I do not use AnkhSVN, I can not tell you that he Where is the alternative, but I'm sure there i...

python - Multiprocessing and niceness value -

Is there an easy way to set the niceness value of a process or pool when it is built in multi-processing? add increment for "niceness" of os.nice (increment) process new accuracy Return to availability: Unix Is there any reason that you can not call it in the hair process?

Howto update 'title in jQuery UI Dialog? -

संभव डुप्लिकेट: इस यूआई संवाद में एक फार्म सबमिट करने के बाद> मैं यूआई संवाद से शीर्षक बदलना चाहता हूं। तो लोड के बाद कॉलबैक-फंक्शन में मुझे सुझाव देना चाहिए, लेकिन मैंने कोशिश की और परिणाम के बिना googled। क्या कोई भी विचार है? धन्यवाद! डायलॉग बनाया जाने के बाद विधि एक संवाद के गुणों को बदल देगा। इसलिए , आप लिख सकते हैं $ (जो भी हो) .dialog ('विकल्प', 'शीर्षक', 'नया शीर्षक');

data modeling - Modelling tournament brackets in MongoDB -

I'm experimenting with MongoDB to move some parts of an app to it. I am thinking of a document-based DB like the Mongoode tournament will be a good fit for the bracket, but I have a tough time coming up with a suitable model. (Still trying to get rid of RDBMS dogma) Have any ideas for a single and double-elimination tournament bracket model? Both tournament variation originally comes in each match, or one of these options is either: The player wins and advances for the next round The player wins and wins the tournament The player loses and exits the tournament The player loses and advances for a loser bracket , if you make it a model Shall have a collection of games, including schema: {_id: .., & lt; - Match ID Player: [playerId1, playerId2], as a result of: & lt; Either "WINS_TOURNAMENT" or the match match for the next match & gt; As a result, the locker: & lt; Either "EXIT_TOURNAMENT" or the matching idle of bracket match...

php - Models in Yii Framework? -

I create a website application using the YI Framework. I want to use the model with query like this: SELECT u.id, u.username, u.score, (SELECT COUNT (ownerId) Posted by P WHERE p.ownerId = u.id) as per U.U. Score DESC, Total Posts DESC LIMIT 10 Please change the query in the Yii Framework model Help me out The related chapter "Fixed Guide to Yii" -

hotkeys - multi key gesture in wpf -

मेरे पास एक राउट्यूडयूआईकममांड नामक टिप्पणी चयन है। मुझे इस आदेश के लिए एक इनपुट इशारा जोड़ने की आवश्यकता है क्योंकि यह VIstual स्टूडियो में है, अर्थात। ( Ctrl + K , Ctrl + C )। मैं यह कैसे कर सकता हूँ? Plz मेरी मदद करो (वीएस की कार्यक्षमता को ध्यान में रखें)। सादर, जवाहर यह कोड है XAML: कोड> & lt; MenuItem हेडर = "हैडर" इनपुटजस्टायरेक्ट = "Ctrl + W, E" command = "ShowCommand" / & gt; सी #: सार्वजनिक स्टेटिक रीडोनली रूटेडयूआईकममंद शो कॉमांड = नया रूटाइड यूआईकमांड ("कमांड टेक्स्ट दिखाएं", "कमांड डेब दिखाएँ", टाइपफ (इसविंडो), नया इनपुट गैस्ट्रस कलेक्शन (नया [] {नवा शो कॉमांड गेस्टायर (कुंजी। ई)})); सार्वजनिक वर्ग ShowCommandGesture: इनपुटजैचर {निजी रीडोनली कुंजी _key; प्राइवेट बूल _गोस्ट्स्टगेचर; निजी रीडोनली इन्पुटगेस्टाइरे _ctrlWGesture = नया कुंजी गियरचर (कुंजी।, मॉडिफ़ेरर कीज़ कंट्रोल); सार्वजनिक ShowCommandGesture (कुंजी) {_key = key; } सार्वजनिक ओवरराइड बॉल्स मैच (वस्तु obj, InputEventArgs inp...

c# - list.UpdateList method throwing an Exception "Microsoft.Sharepoint.SoapServerException" -

I want to modify the file / list metadata of SharePoint. For this, I List.UpdateList () method. But this is throwing an exception: Microsoft. Sharepoint.SoapServerException I am using an administrator account. And using the list web service. Can I get some good examples of modifying the metadata of the SharePoint document using C # (Web Services)?

Magento:Getting selected attribute value of product in Checkout Shipping module -

In my website, some products are not for sale in California, in the user's checkout, I have to make legality like California in the car There are no items for sale in and the user's shipping address is in California, the user can be prevented from checking out. The admin side is set up in sales by CA, using an 'AVL' attribute. Here is the code I repeat through the car and check for the attribute ........ ...... ....... $ cart = Dana :: getSingleton ('Checkout / Session') -> Mens Coat () -> Meet All Info (); Forex Currency ($ cart $ _item) {$ _product = $ _item-> getProduct (); // If the status of the availability of at least one product is set to California, then set the flag and brake if ($ _product-> getResource () -> getAttribute ('avl') -> getFrontend () -> getValue ( $ _ Product) == 'NC') {$ flag = true; break; } ...................... OK, now the problem is that I am able to get 'aval' 'Amount ...

php - ADODB to PDO quick switch -

In the past, I use adodb for mysql in php. Now, I want to use the PDO. Is there any way that I can switch from ADODEB query to PW for a switch to switch to a database quickly? "post-text" itemprop = "text"> You can test the following two examples: #PDO script: $ db = new PDO ("mysql: dbname = you_db_name; host = 127.0.0.1", "root", ""); $ $ = $ Db- & gt; Query ("Select * FROM Table") - & gt; Fetch All (PDO :: FETCH_ASSOC); Forex Currency ($ RS $ R) {} #ADOdb Script requires_once ("adodb5 / adodb.inc.php"); $ ADODB_FETCH_MODE = ADODB_FETCH_ASSOC; $ Db = new payment ("mysql: // root: @ 127.0.0.1 / you_db_name"); $ $ = $ Db- & gt; Execute ("Select * Table from"); Foreach (as $ rs $ r) {} Note that the PDO is a native compiled library and does not load at runtime.

delphi - In my custom component, how can I augment the mouse-enter and -leave events? -

I am creating a custom panel component that receives TPanel . I want to execute some code on OnMouseEnter and OnMouseLeave event for its new component, however, I do not know how to implement it Go. I see that TPanel has published the OnMouseEnter , OnMouseLeave property. How do I override them and some of my codes? Example of my thoughts: The default behavior of TMyPanel that should be in the component OnMouseEnter on the event: color: = NewColor; Lay onMouse at the event: Color: = old color; And again, I want to be able to assign some functions to run these programs at run time. This is done in the assignment application. .. TButton1.Click .. Start MyPanel1.OnMouseEnter: = DoSomethingMore; MyPanel1.OnMouse Le :: = DoSomethingElse; End; Finally, when the new panel is over, it should change the color and some other actions are written in the DoSomethingMore process. Thank you itemprop = "text"> Anohar's approach is to handle w...

DNS query in android source code -

Can anyone point to the code in an Android source code, where a DNS query is being created? I tried to find out the code where the actual DNS query is sent from an application, but I could not. Any help would be great. Thank you in advance Generally you do not have a clear DNS query in Java Make them. When you pass a hostname and Java VM gets to show the DNS query from the OS on it's behalf. This is why you do not have to configure the DNS settings for your Java VM. DNS is the pure Java implementation, but I believe that none of these is supplied with Android.

.net - How to get NLog to parse contents of file-contents renderer? -

मेरे पास एक NLog लक्ष्य है: & lt; लक्ष्य नाम = "aspNetAsyncWrapperForMail" xsi: type = "ASPNetBufferingWrapper" & gt; & Lt; लक्ष्य नाम = "मेल" xsi: प्रकार = "मेल" विषय = "त्रुटि: $ {callites: includeSourcePath = False}" smtpServer = "MySMTP" से = "me@test.com" से = "मुझे @ परीक्षण" Com "smtpAuthentication =" None "body =" $ {date} $ {फाइल-सामग्री: $ {baseir} /error.html} "html =" true "/ & gt; & Lt; / लक्ष्य & gt; Error.html इस तरह दिखता है: & lt; div & gt; & Lt; b & gt; संदेश & lt; / b & gt; = $ {message} & lt; / div & gt; मैं error.html की सामग्री को पार्स करने के लिए NLog कैसे प्राप्त कर सकता हूं, ताकि $ {message} param को NLog नियमों के साथ प्रदान किया जाए? मैंने इस पर एक चाकू लिया और इस समाधान के साथ आया: मेरा नया रेंडरर NLog.LayoutRenderers से मिला है। FileContentsLayoutRenderer उसके ब...

iphone - UIButton - should we release or not? -

OK let me explain the situation. I want to add a button to a view dynamically here is the code. UIButton * x = [UIButtonTypeRoundedRect] with UIButton Button; Here, I have not used the "alloc" function. The question has been followed for this statement. If we are using Image View for the same situation, let us create a temporary image view of your current view & amp; Leave it What to do for the button? How buttons are allocated & amp; De-allocated? If buttons are allocated? How has this been remembered? Now when I use [x release]; - Is this right or wrong? Thank you in advance for sharing your great knowledge. Sea. There is no allocation / init or new, when it is no longer necessary then it will be autoraxed. When you add it to UIView, the count increases and is kept by the view, even if the view is released.

entity framework - EF4 Update model from Database VistaDB issue -

Does VistaDB support 'update models from database' feature in EF4? I'm getting this message: "... 'System.ArgumentNullException' 'value can not be null parameter name: providerInvariantName" The general purpose of this site is to answer, so you may want to open a ticket at the VistaDB site to get help on it. Are there. Anything specific to an application should go to the seller, especially the errors. To post publicly the VS 2010 latest RC, the 13th was not compatible with VistaDB before the creation. VS is still changing things a lot. Hopefully the final release will not be too much from RC.

how to create a very large matrix using matlab -

I have a problem with matlab when I am trying to make AA matrix with a large size like 40000x40000. For example: x = zeros (4000040000); The error message has "exceeded the maximum variable size allowed by the program." There is no solution. In addition to this I have another question, can we create matrix with matrix like variable column sizes? 40000 * 40000 * 8 bytes per number = 12 GB, of course you will not have enough memory . To create a huge lot of zeros with the matrix, you need a sparse matrix : m = sparse (40000, 40000) To create an array of variants, you can use the cell array : M = Room (3, 1) m (1) = [1,2, 3] m (2) = [2,4,6,8,10] m (3) = 6 + 6i

c# 3.0 - IDictonary<string,IParameter> -

मैं IDictionary & lt; स्ट्रिंग, IParameter & gt; नमूना कोड: सार्वजनिक IDictionary & lt; स्ट्रिंग, IParameter & gt; क्वेरी पैरामीटर और इसके लिए मान प्रदान करने का प्रयास करते हुए, क्वेरीपरैमेटर्स {वापस नए शब्दकोश & lt; स्ट्रिंग, IParameter & gt; (); }} कृपया कोई उदाहरण प्रदान कर सकते हैं या मुझे आईपीआर्मेट के लिए मूल्यों को असाइन करने का तरीका बताएं। समस्या यह है कि आप हर बार एक नया उदाहरण लौटाते हैं कोशिश करें: निजी रीडोनली IDictionary & lt; स्ट्रिंग, IParameter & gt; M_QueryParameters = नया शब्दकोश & lt; स्ट्रिंग, IParameter & gt; (); सार्वजनिक IDictionary & lt; स्ट्रिंग, IParameter & gt; क्वेरी पैरामीटर {get {return m_QueryParameters; }} अब आप इसका उपयोग कर सकते हैं: प्रश्नपैमीटर्स.ऐड ("कुंजी", नया पैरामीटर ());

Remove (merge) SQL Servers' database secondary data file -

I have a database backup for which SQL Server Management Studio says there are three files in it: a .mdf File , a .ndf file and a .ldf file. This secondary data file ( .ndf one) was not created for no apparent reason, so I want to delete it altogether (without losing data), during priority, while the database Being restored is backup Is this all possible? OK, get a solution Back up the database first. Execute it: USE database_name; Then execute it, and replace logical_ndf_file_name with the logical name of your NDF file (which you can easily search through Database-> Properties_file ): DBCC Shrink file ('logical_ff_name', AMPTIIEE); Remove the optional database database_name file logical_and_file_name;

asp.net - subsonic with oracle database -

Can anyone recommend the best Oracle ASP.NET 3.5 ORM in the country..Pro and cons? P> Your main choice is between NHibernate and Entity Framework NHibernate usually wins those comparisons . I do not think SubSonic supports Oracle 3. You can read more about .NET ORM here:

google app engine - GWT+UIBinder+Gin+Guice+JDO+GAE example -

I am trying to link all these techniques, but there are many separate examples and enough to link me Experience is not together So my question: Is there a similar example? Is it possible to use UIBinder? Any recommendations to implement this? Unfortunately, I do not know of such a tutorial (possible solution to get a book on GWT , But I do not know if there is a deal with GW 2.0 and Jean) - I'm afraid it's up to you that the knowledge is to patch them together, that's what everyone has to do, right? ;) If you have some specific problems, do not hesitate to post a question about it, we can help. UiBinder + for problem - I use both technologies and it's a breeze, but this is mainly because I have MVP (model view presenter) I'm following the architecture / model - there is really no reliance on this view and the presenter does all the tasks. More on that:

ajax - How to get typing status of the other side with javascript? -

I have seen it in different places, During the chat, I can see whether the other Whether the party is typing or not. How do this easily apply? Chat When a keyboard view event, the client sends some code back to the server then the server Pushes information to customers, or other clients each time voted to the server every time.

php - Issue with opening XFDF PDf's from PGP program -

I have a system that prepares the PDF field via XFDF. This XFDF code looks ok, but when I try to open it with PHP in header () , PDF activates an error if I ignore it I'm refreshing the page, so it works fine and populates the form correctly. Using the xfdf code as well as headers below ... Any ideas why PDF does not display it immediately? & lt; `? Xml version = "1.0" encoding = "UTF-8"? & Gt; & Lt; `Xfdf xmlns =" ​​http://ns.adobe.com/xfdf/ "xml: space =" protected "& gt; & Lt; 'Regions' & gt; & Lt; `Field name =" user_name "& gt; & Lt; `Value & gt; Some names & lt; / Value & gt; & Lt; '/ Regions & gt; & Lt; `Field Name =" course_name "& gt; & Lt; `Value & gt; Some courses & lt; / Value & gt; & Lt; `/ Regions & gt; & Lt; `/ Regions & gt; & Lt; `F href =" http: // the_URL_to_the_PDF_that_needs...

File name copy algorithms -

जब मैं निम्नलिखित फाइल को उसी निर्देशिका में Windows में कॉपी करता हूं। "Log.txt" "लॉग। Txt की प्रतिलिपि" के रूप में प्रतिलिपि बनाई गई है, अगर अब "लॉग की सूची की प्रतिलिपि" कॉपी की जाती है, तो इसे "लॉग। टैक्स की कॉपी की प्रतिलिपि" के रूप में प्रतिलिपि की जाती है। अगर अब मैं "लॉग। "पाठ"> यह आसान है: // स्रोत स्ट्रिंग destring करने के लिए स्रोत फ़ाइल के पथ का प्रतिनिधित्व स्ट्रिंग = "की कॉपी" स्रोत; Int count = 2; जबकि (file.Exists (dest)) {dest = "प्रतिलिपि (" + count.ToString () + ")" + स्रोत; गिनती ++; } फ़ाइल। कॉपी (स्रोत, गंतव्य);

python - Test if a variable is a list or tuple -

In Python, what is the best way to check if any variable is a list or a tuple? (I.e. archive) What has been suggested here as evil? Update: The most common reason I want to separate a list from the string is when I have a data-structure of lists of lists of lists of lists of lists of lists of dark nested trees / strings that are indefinitely Searching with a recursive algorithm and I should know how I pressed the "leaf" nodes. Go further and use isinstance Bad as long as it contains custom sequences, iterators, and other things you really might need. However, sometimes you need to behave differently, for example, if a string passes clearly for my preference like str or Unicode Look for the form: Installing import types (var, types.StringTypes) for NB types.StringType Do not mistake for types.StringTypes . Later, the str and Unicode objects are included. The module is considered by many to be simply obsolete in favor of the object, directly ch...

Tour de Flex Source -

I love the tour de flex. I want to create an app that looks like the Tour de Flex. How can I get the source code of Tour de Flex (Bus UI code, backend content)? Perhaps sending an e-mail instead of posting on a website would be a good start? : P I think it would be better that

javascript - onclick get thumbnail url id value -

Hope someone can help me when an onclick event occurs, but there is no luck, no idea Do I have to get thumbnail ID value? Thanks & lt; A href = "test.ca/images/image-1.jpg?id=1"; Onclick = "swap (this); getVa (); return back;" & Gt; This is a small thumbnail image & lt; / A & gt; This is JS to swap thumbnails: function swap (image) {document.getElementById ("main"). Src = image.href; } Now I want to use the id at the end of thunbnail url. Note that this URL is not a single location URL. You can use the function to get the ID: var url_split = image.href.split ('='); Var id = url_split [1]; Why have not you used jQuery, although you tagged your question this way?

quering an external oracle db in rails application -

I have a website that uses a MySQL database for the whole operation but for a new need I need to get an external The Oracle database will be asked (used by another component) and list of items in a list of websites. How is it possible to connect to an external database just to present a single page? And it is possible to cache the results asked for one month and get an updated list of items before invalidating the cache. I do not want external Oracle DB queries for each request. Why not a monthly job that just copies the data from the Oracle database into a MySQL database?

iis 6 - Asp.net IIS6 - application pool recycle -

I am running an asp.net website on Windows 2003 IIS 6.0 every 24-28 hours I am getting the following error: When an error occurs, all users are disconnected from the website. Event Type: Warning Event Source: W3SVC Event Category: None Event ID: 1013 Date: 02/02/2010 Time: 19: 29 38 User: En Service in Pool Service / AA process 'default applepole' has exceeded the time limit during shutdown Process ID '1660' For more information, see the Help and Help Center at http://go.microsoft.com/fwlink/events.asp What is the meaning of any idea error is? Is this application related to pool recycle? If so, is it to "Recycle" the IIS App Pool? Yes this is a clean move IIS, and recycling app pools. How you can do this by changing the settings on the Appesan pool.

monkeypatching - Custom Form Elements in Rails -

after "text" itemprop = "text"> Then I'm new to the rail and I'm trying to figure out what is the customized method of adding custom form elements Am Currently the way I am doing it is super grotty. ActionView module helpers module FormOptionsHelper def some_new_field (object, method, option = {}, html_options = {}) #code code end-end class FormBuilder def contract_year_select (method, option = {}, Html_options = {}) @ template.some_new_field (@object_name, method, objectify_options (option), @ default_options.merge (html_options) end end end I have seen it though class form :: application form builder & lt; ActionView :: Helpers :: Form Builder Form :: ApplicationHelper.instance_methods.each do | Selector | Src = & lt; & Lt; -end_src def # {selector} (method, option = {}) @ template.send (# {selector.inspect}, @object_name, method, objectify_options (option)) end end_src class_eval src, __FILE__, __LINE__ end personal def objectif...

mySQL UPDATE query returns "0 rows affected" -

I have this query: Call phone calls Set "yes" Where is the phone number = "999 29-4655" my table is phone call ; I have a column whose name is phone number . The one I want to update is a column that has been named "yes" from called . Any thoughts that I am doing wrong? When I return my query, it says that 0 rows have been affected. Amphitamin and Yada have suggested, code> select , if your phone number table Is in. But keep in mind: If the line in the called is already "yes", Mysql will not change the value and therefore will return "affected 0 rows". So make sure to check the current value of called

events - Is there a Dependency Injection-like pattern for wiring together Subjects and Observers? -

विषय पर्यवेक्षक संबंध निर्भरता संबंध नहीं है: पर्यवेक्षक की आवश्यकता विषय नहीं आदेश मौजूद है, और इसके विपरीत। फिर भी प्रकाशकों और ग्राहकों की "एक साथ मिलकर" निर्भरता इंजेक्शन की याद दिलाता है। मेरा शूट-अप-अप गेम प्रेक्षक पैटर्न का व्यापक उपयोग करता है I उदाहरण के लिए: एक नियंत्रक ऑब्जेक्ट प्रत्येक दौर की शुरुआत में खिलाड़ी जहाज ऑब्जेक्ट उत्पन्न करता है। नियंत्रक को जहाज प्रदान करने के लिए एक फैक्टरी पर फोन करता है। जहाज अन्य बातों के अलावा, एक रिएक्टर ऑब्जेक्ट पर निर्भर करता है जो जहाज को ज़्यादा गरम कर सकता है और नष्ट कर सकता है। कारखाने इन निर्भरताओं को इंजेक्ट करता है अब तक, बहुत अच्छा। अब, एचयूडी को जहाज़ की स्थिति, खासकर रिएक्टर तापमान के बारे में पता होना चाहिए, लेकिन एचयूडी जहाज पर निर्भर नहीं करता है डि अर्थ: जहाज नष्ट होने के बाद एचएडी बनी रहती है। सवाल यह है कि नियंत्रक के पास एचयूडी के संदर्भ में नहीं है, मैं जहाज के संपर्क में एचयूडी कैसे प्राप्त कर सकता हूं? और यह सिर्फ एक नन्हा, छोटे उदाहरण है मेरे पास बहुत से ऑब्जेक्ट हैं और बहुत से ऑब्जेक्ट्स क...

Django: How do I get an array from a QueryDict in a template? -

मेरे पास मेरे request.session में निम्नलिखित QueryDict वस्तु है। & lt; QueryDict: {u'category ': [u'44', u'46 '], u'cityID': [u'null '], u'countryCode': [u '], यू'मैपसेंटर लिंक्स': [यू '2.291300800000009'], यू'मैप ज़ूम ': [u'12'], यूएमएपी केंद्र लिट ': [u'47.10983460000001'], यू'प्रिस_रेन्ज ': [यू], यूटेक्स्टबॉक्स': [यू] } & gt; एक टेम्पलेट में श्रेणी का उपयोग करके ऐरे प्राप्त करने का प्रयास करें: {{request.session.lastrequest.category}} लेकिन यह मुझे केवल सरणी के अंतिम मान देता है। मैं पूरी सरणी कैसे प्राप्त करूं? धन्यवाद जुलाई आप नहीं कर सकते आपको कॉल करने की ज़रूरत है, लेकिन आप एक टेम्प्लेट में किसी पैरामीटर के तरीकों को कॉल नहीं कर सकते हैं।

sql - stored procedure column value determined by value of another column -

I have some data like this. Date, amount, value 200 -10-12, 20, 15.43, 2009-10-13, -10, 6.98 I have a stored procedure Which will return these columns as well as create a new column which indicates whether the amount was positive or negative, so the last result of the process would be something like this. date, amount, value, results 2009-10-12, 20, 15.43, positive 2009-10-13, -10, 6.98, negative How can this be done? This is a SQL 2008 ENT DB. select date, amount, value, case when zodiac & gt; 0 then 'positive' when the amount is & lt; 0 then #_table_or_negative to #table as the 'negative' end

c# - Winforms user controls custom events -

Is there any way to give user control custom events, and event control user (I'm not sure if the correct word is , Then call) Sample of Public Partial Class: UserControl {Public Sample} (InitializeComponent ();} Private Zero Text Box (Valid Object Sender, Event Argus E) {// Iajaz User Control Event here}} and mainframe: public partial class Mainfrom : Forms {Personal Sample Sample Controller = New Sample (); Public MainForm () {this.InitializeComponent (); SampleUserControl.Click + = New EventHeadler (this.CustomEvent_Handler);} Private Zero CustomEvent_Handler (Object Sender, EventAgds E) {/ In addition to the example posted by Steve, Syntax is also available / Dot Dot}} class MyUserControl: UserControl The public event EventHandler text box is valid {{textBox1.Validated + = value; } Remove {textBox1.Validated - = value; }}}

security - How to defend excessive login requests? -

Our team has created a web application using rubies on Rails, it is not currently restricted to users due to excessive login requests Does. We want to ignore the user's login requests for some time after several unsuccessful attempts to automatically protect the robots. These are my questions: How can one write a program or script that can make excessive requests on our website? I need this because it will help me test our web application. What is the method of restricting a user who made some unsuccessful login attempts within a period? Are there underlying solutions to identify Ruby on request of a requestor and to make a request to him recently? If not, is there a common way of identifying a requestor (not specific to the Ruby on Rail) and keep track of the requester's activities? Can I identify the user with IP address or cookies or any other information that I can collect from his machine? We also expect that we can distinguish between normal users (who make ...

design - Transforming an object implicitly -

The following code shows a pattern that I sometimes see, where the object is transformed into one another Because it is passed as a parameter in a number of method call var o = New MyReferenceType (); DoSomeWorkAndPossiblyModifyO (o); DoYetMoreWorkAndPossiblyFurtherModifyO (o); // now use o ... This seems to me wrong (it seems difficult to object-oriented). Is it acceptable? This is acceptable, but generally bad style. As always, the "good" approach is: twosmwork and authoring (& amp; o); // Clear reference means we will accept changes o = DoSomeWorkAndReturnModified (o); // More elastic because you often want to keep the original The approach you presented is understandable when oh is huge, and it's making a copy in memory, the question Do not use it, or if it is a function then you (and some other = private) do not use it often and do not want to bother with & amp; Sentence - Configuration. Otherwise it is laziness that there are some diffic...

makefile - How to have GNU make explicitly test for failure? -

After not using the make for many years, I think it needs again, GNU version now. I'm pretty sure what I should do, but I do not know how, or got an answer with Google, etc. I am trying to create a test target which executes my program multiple times, save the result in the log file. Due to some trials my program should be canceled Unfortunately, my messayee first closes on the test which leads to an error. I have something like this: #makefile #search: myProg -h & gt; Test.log # Display myProg good_input & gt; & Gt; Test.log # should run ok myProg bad_input1 & gt; & Gt; Test.log # Error 1 myProg bad_input2 & gt; & Gt; Test_log # Error 2 With the above, after bad_input1 run ends, bad_input2 is never running. If you want to achieve the goal of failing, then the proper solution is to reject its exit code. # Makefile # test: myProg - H & gt; Test.log # Display myProg good_input & gt; & Gt; Test.log # should run properly! MyProg...

iphone - Calculate the size of a folder -

Just a quick one ... I was making a folder for cache images inside the document My iPhone app I want to be able to keep this folder size up to 1 MB, so I need to check the size in the bytes of my folder. I have the code to calculate the size of the file, but I need the size of the folder. What would be the best way to do this? Will I need a loop through each file? Cheers Cheers for that Alex, you've helped a lot, Now the following is the task which is written the trick ... - (unsigned long long int) folder size: (NSString *) folder path {NSArray * filesArray = [[NSFileManager defaultManager] subpathsOfDirectoryAtPath: Folder Path Error: zero]; NSEnumerator * filesEnumerator = [FilesArray objectEnumerator]; NSString * fileName; Unsigned long file file size = 0; While {fileName = [FilesEnumerator nextObject]) {NSDictionary * fileDictionary = [[NSFileManager defaultManager] File attributeAppet: [FolderPath stringBeffingPath Company: Filename] Trust link: Yes]; File...

c# - LINQ to DataSet Dataclass assignment question -

Text after " I am working on a Silverlight project while accessing a database dataset using LINQ, and then through Silverlight Send data to ASMX Web Service I defined my dataset using the Server Explorer tool (I am interested in dragging and dropping all the different tables) to use the dataset server and database without any problem Enabled. The code for one of my web methods is given below: Public listing & lt; ClassSpecification & gt; GetSpecifications () {DataSet2TableAdapters.SpecificationTableAdapter Sta = New DataSet2TableAdapters.SpecificationTableAdapter (); . Return to Sta.GetData () (AsEnumerable with New ClassSpecification Selection) (Specification = Spec.Field & LT; String & gt; ("Specification"), SpecificationType = Spec.Field & LT; String & gt; "SpecificationType"), StatusChange = Spec.Field & LT; Date Time & gt; ("StatusChange"), Tip = Spec.Field & LT; Integer> ("Tip")} ToList...

nginx - Where should I set HTTP headers, such as Expires? -

I want to deploy an app using Sinatra on fusion passenger w / nginx. If I want to set my static content - the header ending on the stylesheets, then say - This is where it can be seen in three places where I can complete it. In my Syntona app, use of API with rack midware In server config for my deployment Which of these methods is best for setting up HTTP headers? However after answering and answering and viewing the above comment, I think I have figured out the answer to my own question. The whole situation of nginx actually eliminates the first two options. This option leads to option # 3 this is where all other content config sets, such as gzip compression.

php - How to create html page dynamically from flash? -

I have a flash movie with a button to view items in a new browser window. These items are all generated in dynamic flash, so HTML has to be dynamically prepared too. Can anyone choose a way to do this? Do I need to use php or some server side script? If you have a "New Browser Window", then you should do just something navigate URL (new URLRequest ("http://www.yoursite.com/somepage.php?content=hi_there"), "_blank"); where Contains the dynamically generated content from the query string (say ... get the content "Hi there" from the above example) PHP / server side script usage If you use the "HTML Content Inside Flash "Means, you can use Flash ML (action) Hit 2 CO) If you mean "Content like Flash in HTML", then you can write script for your form, your content inside Flash, such as dynamically moving the movieclip to create it while creating an html page

How is generic function implemented in java? -

मेरी समझ के अनुसार जावा में निम्न सामान्य कार्य: सार्वजनिक स्थिर & lt; T & gt; ; टी एफ (टी एक्स) {पूर्णांक [] arr = नया पूर्णांक [4]; टी रेट = (टी) arr [2]; रिटर्न रिट; } निम्न रूप से संकलित किया गया है (जैसा कि यह असीम है): सार्वजनिक स्थिर वस्तु f (ऑब्जेक्ट x) {पूर्णांक [] arr = new पूर्णांक [4]; ऑब्जेक्ट रेट = (ऑब्जेक्ट) एआरआर [2]; रिटर्न रिट; } हालांकि, जब मैं निम्नलिखित कथन चलाता हूं, तो संकलक पूर्णांक प्रकार के लिए रिटर्न मान को समझने में सक्षम होता है। कंपाइलर इसे कैसे समझता है? पूर्णांक I = f (नया पूर्णांक (4)); क्या उपर्युक्त बयान के कार्य के लिए निम्नलिखित के रूप में कार्य किया जाना चाहिए? सार्वजनिक स्थिर & lt; टी पूर्णांक पूर्णांक & gt; टी एफ (टी एक्स) {पूर्णांक [] arr = नया पूर्णांक [4]; टी रेट = (टी) arr [2]; रिटर्न रिट; } जेनरिक्स टाइप एरर का उपयोग करते हैं मूल रूप से इसका मतलब है कि जेनेरिक कुछ भी अन्तर्निहित डाटों से अधिक नहीं है, जब आप ऐसा करते हैं: सूची & lt; integer & gt; ... यह एक सामान्य सूची से अलग नहीं...

user interface - Using WiX how do I disable/enable controls based on property change? -

I am currently melting a brain bit where I have a WiX combo box and when I change the selection other UI You want to disable / enable controls. & lt; Combobox property = "SQLAUTHTYPE" & gt; & Lt; ListItem value = "WindowsAuth" text = "Windows authentication" /> & Lt; ListItem value = "SqlAuth" text = "SQL authentication" /> & Lt; / ComboBox & gt; This happens when these events start ... MSI (c) ... Property Changes: Modifying the SQLAUTHTYPE Property Its current value is 'WindowsAuth': its new value: 'SqlAuth' MSI (C) ... Property Changes: Modifying SQL UTPP Property Its Current Value is 'Eclolite', its new Value: 'WindowsAuth' The following UI controls are flagged as disabled when WindowsAuth is selected and enabled So when SqlAuth is selected ... & lt; Control type = "edit" width = "164" height = "16" x = "25" y...

javascript - Changing adjacent cells in table when an event is triggered in JQuery -

I am trying to create a game of light. When I click on them, I can toggle the light off and shut down, but there is a problem in thinking the argument to make the adjacent one the same. For example, if I click on one edge of the table, So I should see three lights near the light, I became ill. I am thinking that this is something to force "this" in my click method, maybe "this" refers to only one I click on and not for adjacent people. I need to know, perhaps how to get it in the context of the impending people? & lt; Html & gt; & Lt; Top & gt; & Lt; Title & gt; Lite out! & Lt; / Title & gt; & Lt; Script type = "text / javascript" src = "jquery-1.4.js" & gt; & Lt; / Script & gt; & Lt; Script type = "text / javascript" & gt; Var gameBoard = new GetTdCount () function lightstats (status) {// if the light is on (gameBoard [position] == true) {// Set original position back in fa...

c# - How to change row color in datagridview? -

I want to change the color of a particular line in my datagrid view. If the value of column 7 is less than the value in column 10, then the row should be changed to red. Any suggestions about how to accomplish this? You need a loop through rows in the DataGrade view and then columns 7 and 10 in each row Compare prices. Try it: foreach (DataGridViewRow Line Vendors in DataGridView.Rows) if (Convert.ToInt32 (line Seals [7]. Value) Convert ToInt32 (line.cel [10]. Value)) {row.DefaultCellStyle.BackColor = Color .Red; }

objective c - Replica of file to Hashtable -

Before I told you to input the input from the file before moving it to the hashteble, in fact I actually Sorry I need to identify important and value from the text file and put it in my hashtable. I.e. this is a text file: LENOVA = Class_Name DELL = Class_Name WIPRO = Class_Name Samsung = Class_Name Take it as a key / value combination in the Hashible Load the class from, and at the end, hashtable. HashTable has to store it like this: main value Lenovo class_name DELL Class_Name WIPRO Class_Name Samsung Class_Name How to do it in Objective-C ?? Let me give you some ideas to proceed If you have permission to change the input text file so that it is included in Ho: "Lenovo" = "square_name"; "DELL" = "square_name"; "Wipro" = "class_name"; "Samsung" = "square_name"; Then you can do this: NSDictionary * dict = [contentsofffile with NSDictionary dictionary: @ "myfile.txt"]; ...

SQL: Exchange column values -

Want to clear some concepts about SQL Internal. Suppose I have a table: --------- tblXY ----------- x int y int Now there is a record in it: XY --- 1 4 2 3 3 2 4 1 And I The result table should be: XY --- 4 1 3 2 2 3 1 4 So I wrote this question: UPDATE tblXY SET [X] = Y, [Y] = X and found the necessary results. But how did this happen? I mean that I am setting the value of x as the current value of y and at the same time I am setting the value of y as the x. That's because operations are an atomic action - X and The current value of> Y is done before any of the functions. It is not too high: for each line: set x = y set y = x but more Like: Set for each line: tmpx = x set tmpy = y set x = tmpy set y = tmpx Keep in mind that The only conceptual approach is that it is likely to be more efficient under cover. Without it, you must temporarily store yourself for each line, or just rename the column: -)

c# - How can create a webapplication in dotnetnuke framework? -

I am very new to dotnetnuke and want to know how to make a webpic in dotnetnuke and make steps. How can we add modules using dotnetnuke? How can we manage the database in SQL Server 2005 or later. In brief, want to explain and understand Go to video downgrade

air - Run Command prompt commands through flex -

Can we run command prompt commands from an AIR or Flex application (like copy, rename etc)? I thought about creating a bat file and running it using fscommand, but it does not meet my purpose There's so much good! But you can use it only with AIR 2.0. If you want to run it via AIR & lt; 2 or Flex, you can easily use a server-side script such as Ruby / php / python to execute the command. Simply send commands over HTTP via XMT (for example, use HTTPService), and handle it in the original language (Ruby / Python, etc.). There are all kinds of things to do, but it is complicated to go with it. If you do not want anything, but Flex / AIR, you can only use AIR 2.0. yesterday :). Here's a nice tutorial. I know how it works.

php - Facebook API's require_login to work with CodeIgniter -

If I currently use facebook's need_login, it seems that linking the URL is going to the infinite loop . All of my controllers are from an FB_Controller who is on the build: $ this-> Facebook = new facebook ($ this-> API_KEY, $ secret); $ This- & gt; UID = $ this- & gt; Facebook-> Need_login (); // Infinite loop causes! I had to explicitly set a canvas callback URL on Facebook (where is my desired default controller to ask) or I get a 404 error. Apart from this, I am using the iframe rendering method. On CodeIgniter, I have specific mod_rewrite to get rid of index.php, $ config ['uri_protocol'] = "REQUEST_URI", $ config ['enable_query_strings'] = true the following two configurations There was a simple link to get to work (clicking on a link will not work as it would only navigate to the current page). I have set the user_protocol only on request_url or path_info, depending on the referrer header. So in config.php I have: ...

visual studio - Is it possible to view the messages outputted by Microsoft ReportViewer in my own front-end? -

I want to see messages displayed in Viewer Studio's output window by ReportViewer when a report is seen, in my own application . I think that involves blocking debug or console output messages in it. Is this possible? I am using Microsoft ReportViewer 2008 in the local report.

Clear session cookies with Selenium IDE? -

I am writing a test for ASP application, and would like to test sessions when a session does not start properly. Right now I am cleaning the cookies manually, but it is a bit cumbersome. (Well, honestly I forget it every fifth time and test to run again ...) Is the session in the IDE a blank way to clear cookies or a browser resume? clear and delete Ul>

zend framework - How to PASS your own mysql connection to Zend_DB? -

I have my own mysql_connect ... etc. As long as I want to use Zend Framework specifically with Zend_DB ZEND connection to use as an adapter? Like $ myconn = mysql_connect ('... blab', blah etc ...) Zend_DB_table :: setAdapter ($ myconn); Do not connect yourself to the DB, but use the factory $ db = Zend_Db :: factory ('Pdo_Mysql', array ('host' = & gt; '127.0.0.1', 'username' => 'webviewer', 'password' = & Gt; 'Xxxxxxxx', 'dbname' = & gt; 'test')); In this way you can connect to DB, but only once you are connected you will need connection and will be suited for display like this ...

How Do You Delete Duplicate Records In SQL -

एसक्यूएल में डुप्लिकेट रिकॉर्ड्स को कैसे हटाएं? इसमें SQL Server 2005 और ऊपर: साथ के रूप में (SELECT *, ROW_NUMBER () ओवर (dup_column द्वारा विभाजन) ORDER BY dup_column) आरएन से मेराटेबल) क्यू WHERE rn & gt; 1

How do I check if a Unicode directory exists on Windows in Perl? -

I have to check whether a Unicode directory exists in Perl or not. I am using Windows XP and Perl Camelbox 5.10.0. If I try to create a directory (such as Sinn has suggested here), which is already present, the program ends. Unfortunately if (! -d $ dir_name) {# directory build $ dir_name} does not recognize the Unicode directory or I'm doing something completely stupid, I checked it Before trying to encode the name of the directory, but the result is the same. How do I check for the existence of a Unicode directory? While answering your first question, I forgot that it provides a decent interface I I will go and answer However, for your immediate problem, what you need to do is do not automatically die when the CreateDirectory call fails, but to check if the error code is 0xb7 ( ERROR_ALREADY_EXISTS ), then you go on your way to your delightful path. The problem is that it is difficult to go on your happiness. When you have a Unicode file name, the solution ...

java - Equivalent of the DLR for the JVM? -

What is the DLR (.NET for dynamic language runtime) on GVM? I know that I can go about my dynamic binding and can emit my own bytecode with Java. But is there a pre-built structure (such as DLR) then I do not have to invent the wheel again? DLR is a number of different things, some of which have a direct equivalent in Java, some of which are separate, Are present in different forms and some of them are not equal. Some of those that do are already part of the platform, some will be part of Java 7 and will be available from some third parties. Runtime Binder and Caching Infrastructure DLR has a runtime binding and caching infrastructure that makes dynamic dispatch fast and efficient as a dynamic dispatch in the form of stationary dispatch. Fast and C ++ - For faster than how to style faster than virtual table remittances, it is known for more than 20 years, but most of the dynamic performance engines are those technologies Not like Polimorfik inline caching, dynamic type of ext...

c++ - How do I predict serious memory fragmentation issue is likely to happen? -

Can I check page fault time or something ..) The itemprop = "text"> itemprop = "text"> No questions are stupid if you are worried about memory fragmentation, then you have to cover how you allocate the memory so that you Can be tracked. Perhaps you should surcharge the classes in the new operator, where you think the most damage will be due to fragmentation. Use any type of logging functionality to write to you, where all this is happening, it should be enough in the form of the first practice. If you think that this is actually harming you, then you can guarantee your item You can make a section of memories of the right size, just as you want.

Is there a simple way to check if an incoming caller is a contact in Android? -

When an Android phone receives a call, it automatically checks whether the call is present in its contact database I was thinking that there is an easy way to access that information. I have a PhoneStateListener that does some work during a ringing situation, and I have to see if incoming callers are in contact list or not. Is there no way to do this contact ContentProvider ? is using the phone app contacts ContentProvider as well; I'm not sure how you want to avoid that, besides, it is the only publicly accessible way to access that information. Resolving a number for a name (pre 2.0, in this case) is quite simple: Uri Uri = Uri. Expected word (phone. CONTENT_FILTER_URL, Uri.node (number)); String name = null; Cursor cursor = context.getContentResolver (). Query (Yuri, New String [] {Phones.DISPLAY_NAME}, Blank, Blank, Blank); If (cursor! = Null & amp; cursor.more ()) {name = cursor.getString (cursor.getColumnIndex (phones.DISPLAY_NAME)); Cursor.close (); ...

Structs in C# (type could not be found) -

I'm new to C #, so please forgive this noobish question. I'm playing with a simple XNA game demo. I have a straight that I want to be available for many classes. It is defined as follows: PhotonType.cs using the system; Namespace Shippo {public essay} photon type {public color tint; } In another file in the same folder / name space, ShipCase , I refer to this structure: Nom place Shields {Public Class Pope {// ... Private Photon Type Phphototype; // ... ... public ship (float x, float y, float angle, boolean exactsound, photon type phonotype) {// ...}} This gives me both references On Compilation Errors For PhotonType Error 1 type or namespace name 'Photon type' could not be found (Do you have access instructions or an assembly reference unavailable?) What do I do here Am doing wrong Apart from this, the C # documentation says that This is an error in starting an example field in a straight. But if I want to provide default value? I am...

c# - Is an array valid for vertex element data for programmable graphics pipline? -

Posted here in response to my previous cession: I have a top structure with an array of unstable point values ​​such as: public structure vertex {float [] array = new float [4]; Public vertex (float x, float, y, float z, float w) {arrer [0] = x; Array [1] = y; Array [2] = z; Array [3] = w; }} Can that top structure be sent to a top buffer (using OpenGL or DirectX)? Is there any other byte data in an array or does it contain data for only temporary point values? As I can use this head as a conversion in the declaration (in DirectX), I can send buffer to the top and all that will be sent is a floating point value or what other information will be included in the array which Shader can break program? I'm not a C # programmer, but it looks here that you store an array reference (indicator). In vertex straight, there will be an array of an array indicator of the vertex. A Graphics API demands continuous order. Try: Public Configuration Vertex {Public Fixed Float Array...

perl - How can I track down CPU intensive requests in mod_perl? -

Using mod_perl on Apache 2.2 and Ubuntu 8.04 I have many applications on the server using Apache in pre-forwarding mode Generally things are working well but once I use 100% CPU of one of the Apache processes. Many web sites on the server are with their own virtual hosts and are SAVN servers and they are run by Apache. How can I track that application and call in that application generate high load? is now a very prominent profiler for Perl, with the easy-to-install mod_perl profile. Look for a beautiful overview with pictures. Unfortunately, Devel :: NYTProf is not pre-packed in Ubuntu Hardy (this is already packed with Yanti, Personnel, Lucid and later). You can either install packages from those distributions, CPAN You can use some suitable moves to install or just upgrade; -)

PHP - How to get the element before the last element from an array? -

How do I get an element in PHP5 from the element before the last element? $ array [count ($ array) -2] It should be numerically indexed. Array (to minus) You have at least 2 elements to work on it. (Obviously)

Authenticating against a remote server and domain (C#/3.5) -

I have a Net 3.5 service that runs on stand-alone computers. The service queries the server's event log in multiple Active Directory domains. I want to certify these using the managed code. Currently, I certify with P / WNetAddConnection2A or with back or processing with the net use. For example, this works: string user = "domain \ administrator"; String pass = "password"; String server = "server.domain.com"; String argument = String.Format ("use \\\\ {0} \\ ipc $ / user: {1} {2}", server, user, pass); System.Diagnostics.Process.Start ("net.exe", argument); System.Diagnostics.EventLog Log = New Event Log ("System", Server); Is there no way, without calling the net worth code or authenticating the event log and reading the .Net 3.5 framework? Have you seen the demo written in "System.Security.Principal.WindowsImersonationContext" and MSDN. On the way, for the net 1.1 days back, I had to write w...

php - Should I use AI on these fields in MySQL? -

I have this DB below. I wonder how I should use the ID to identify each record. Everything is linked to classified_table ! Two questions: Should I use AI on every PK in this case? Can someone give me complete code to choose the whole classified only from a ad_id (for example "bmw_330ci_8939483")? I'm new to normalized DB and working on a good database, so detailed instructions are highly appreciated ... Besides, if you have any 'incorrect' please tell me in this DB. Table: value_id (PK) option_id (FK) value classified table: classified_id (pk) ) Ad_id (VARCHAR) will be displayed in some "BMW 330C_28238239832" such as URL Poster_ID (FK) Cat_ID headline details of price_ID (FK) etc. Poster table: Poster_ID (PK) Name Email Telephone Password field table Regional area (pk) q Thir Community Thanks I have auto-input on those fields (AI), which I want to make the majority of search by Uld makes it easy to return the result, but there are p...

.net - Bind xml column and regular columns from sql server in nested controls -

I have a stored procedure that gives a mixture of plain columns and a 'column' of XML datatype. As: Select field 1, field 2, ('Certification as selection certification', XML path for dbo.MemberCertificate from '@lcid' as LCID ('Certification'), type, root ('certificate')) with AS certificates ....... I am compelling this result in Gridview, and I have nested The XML column is required to be bound for Repeater, it contains parental-child data. I have tried to set the repeater data source in the column name, such as: " & Gt; & Lt; ItemTemplate & gt; & Lt;% # XPath ("// authentication")%> & Lt; / ItemTemplate & gt; & Lt; / ASP: Repeater & gt; But it does not work, it seems as if it's coming in the form of a plain string, if I just write a line break inside the item template, then each letter in the column There is a break! I have also tried to use an XML data inline, but I get...