Search Results

Search found 12083 results on 484 pages for 'general purpose'.

Page 8/484 | < Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >

  • Are there some general Network programming best practices?

    - by uriDium
    I am implementing some networking stuff in our project. It has been decided that the communication is very important and we want to do it synchronously. So the client sends something the server acknowledges. Are there some general best practices for the interaction between the client and the server. For instance if there isn't an answer from the server should the client automatically retry? Should there be a timeout period before it retries? What happens if the acknowledgement fails? At what point do we break the connection and reconnect? Is there some material? I have done searches but nothing is really coming up. I am looking for best practices in general. I am implementing this in c# (probably with sockets) so if there is anything .Net specific then please let me know too.

    Read the article

  • Here's your chance: MOS Feedback Sessions @OOW

    - by cwarticki
    Bring your questions, comments, concerns, opinions, recommendations, enhancement requests and any emotional outbursts!   As I travel the world and speak to thousands of customers, I receive plenty of feedback about My Oracle support.  Come hear directly from the source. Meet Dennis Reno, VP of Customer Portal Experience. The Customer Portal Experience team will host a My Oracle Support Tips and Techniques session and three roundtable feedback sessions at this year’s Oracle OpenWorld. The sessions will include a Hardware Support component, as well as best practices that are sure to benefit all My Oracle Support users. The events planned will give our users the opportunity to learn more about how the My Oracle Support customer portal adds value to the support process and to their business needs. The roundtable feedback sessions will allow customers to meet, give feedback, and share their experiences directly with the team responsible for the customer portal experience. Date Time (PT) Session Name Mon, Oct 1 01:45 PM My Oracle Support: Tips and Techniques for Getting the Best Hardware Support Possible (Session #CON9745) Tue, Oct 2 11:00 AM Roundtable - My Oracle Support General Feedback Wed, Oct 3 11:00 AM Roundtable - My Oracle Support Community Feedback Thr, Oct 4 11:00 AM Roundtable - My Oracle Support General Feedback Customers can find more information, including specific details about how to attend, by accessing My Oracle Support at OpenWorld (Article ID 1484508.1). Enjoy OpenWorld everyone! -Chris Warticki Global Customer Management

    Read the article

  • sqrt(int_value + 0.0) -- Does it have a purpose?

    - by Earlz
    Hello, while doing some homework in my very strange C++ book, which I've been told before to throw away, had a very peculiar code segment. I know homework stuff always throws in extra "mystery" to try to confuse you like indenting 2 lines after a single-statement for-loop. But this one I'm confused on because it seems to serve some real-purpose. basically it is like this: int counter=10; ... if(pow(floor(sqrt(counter+0.0)),2) == counter) ... I'm interested in this part especially: sqrt(counter+0.0) Is there some purpose to the +0.0? Is this the poormans way of doing a static cast to a double? Does this avoid some compiler warning on some compiler I do not use? The entire program printed the exact same thing and compiled without warnings on g++ whenever I left out the +0.0 part. Maybe I'm not using a weird enough compiler? Edit: Also, does gcc just break standard and not make an error for Ambiguous reference since sqrt can take 3 different types of parameters? [earlz@EarlzBeta-~/projects/homework1] $ cat calc.cpp #include <cmath> int main(){ int counter=0; sqrt(counter); } [earlz@EarlzBeta-~/projects/homework1] $ g++ calc.cpp /usr/lib/libstdc++.so.47.0: warning: strcpy() is almost always misused, please use strlcpy() /usr/lib/libstdc++.so.47.0: warning: strcat() is almost always misused, please use strlcat() [earlz@EarlzBeta-~/projects/homework1] $

    Read the article

  • Change default language settings in Visual Studio 2012

    - by sreejukg
    The first thing you need to do after the installation of Visual Studio 2012 is to choose the IDE preferences. Once you select your preferred collection of settings, the IDE will always choose dialogs and other options according to your selection. Nowadays developer’s needs to work with different programming environments and due to this, developers might need to reset the default settings. In this article, I am going to demonstrate how you can change the default settings in Visual Studio 2012. For the purpose of this demonstration, I have installed Visual Studio 2012 and selected C++ as my default environment settings. So now when I go to file -> new project, it will give me C++ templates by default as follows. If you want to select another language, you need to expand Other Languages section and select C# or VB. Now I am going to change these default settings. I am going to change the default language preference to C#. In Visual Studio 2012, go to tools menu and select Import and Export Settings. Here you have 3 options; one is to export the current settings so that the settings are saved for future use. Also you can import previously saved settings. The last option available is to reset it to default. It is a good Idea to export your settings and import it as you need in later stages. To reset the settings to default select the Reset option and click next. Now Visual Studio will ask you to whether you would like to save the settings, which can be used in future to restore. Select any one option and click next. For the purpose of this demo, I have selected not to save the settings. Click Next button to continue. Now Visual Studio will bring you the similar dialog that appears just after installation to select your IDE settings. Select the required settings from the available list and click Finish button. Click Finish once you are done. If everything OK, you will see the success message as below. Now go to file -> new Project, you will see the selected language appear by default. I selected C# in the previous step and the new project dialog appears as follows. Changing IDE settings in Visual Studio 2012 is very easy and straight forward.

    Read the article

  • Code Metrics: Number of IL Instructions

    - by DigiMortal
    In my previous posting about code metrics I introduced how to measure LoC (Lines of Code) in .NET applications. Now let’s take a step further and let’s take a look how to measure compiled code. This way we can somehow have a picture about what compiler produces. In this posting I will introduce you code metric called number of IL instructions. NB! Number of IL instructions is not something you can use to measure productivity of your team. If you want to get better idea about the context of this metric and LoC then please read my first posting about LoC. What are IL instructions? When code written in some .NET Framework language is compiled then compiler produces assemblies that contain byte code. These assemblies are executed later by Common Language Runtime (CLR) that is code execution engine of .NET Framework. The byte code is called Intermediate Language (IL) – this is more common language than C# and VB.NET by example. You can use ILDasm tool to convert assemblies to IL assembler so you can read them. As IL instructions are building blocks of all .NET Framework binary code these instructions are smaller and highly general – we don’t want very rich low level language because it executes slower than more general language. For every method or property call in some .NET Framework language corresponds set of IL instructions. There is no 1:1 relationship between line in high level language and line in IL assembler. There are more IL instructions than lines in C# code by example. How much instructions there are? I have no common answer because it really depends on your code. Here you can see some metrics from my current community project that is developed on SharePoint Server 2007. As average I have about 7 IL instructions per line of code. This is not metric you should use, it is just illustrative example so you can see the differences between numbers of lines and IL instructions. Why should I measure the number of IL instructions? Just take a look at chart above. Compiler does something that you cannot see – it compiles your code to IL. This is not intuitive process because you usually cannot say what is exactly the end result. You know it at greater plain but you don’t know it exactly. Therefore we can expect some surprises and that’s why we should measure the number of IL instructions. By example, you may find better solution for some method in your source code. It looks nice, it works nice and everything seems to be okay. But on server under load your fix may be way slower than previous code. Although you minimized the number of lines of code it ended up with increasing the number of IL instructions. How to measure the number of IL instructions? My choice is NDepend because Visual Studio is not able to measure this metric. Steps to make are easy. Open your NDepend project or create new and add all your application assemblies to project (you can also add Visual Studio solution to project). Run project analysis and wait until it is done. You can see over-all stats form global summary window. This is the same window I used to read the LoC and the number of IL instructions metrics for my chart. Meanwhile I made some changes to my code (enabled advanced caching for events and event registrations module) and then I ran code analysis again to get results for this section of this posting. NDepend is also able to tell you exactly what parts of code have problematically much IL instructions. The code quality section of CQL Query Explorer shows you how much problems there are with members in analyzed code. If you click on the line Methods too big (NbILInstructions) you can see all the problematic members of classes in CQL Explorer shown in image on right. In my case if have 10 methods that are too big and two of them have horrible number of IL instructions – just take a look at first two methods in this TOP10. Also note the query box. NDepend has easy and SQL-like query language to query code analysis results. You can modify these queries if you like and also you can define your own ones if default set is not enough for you. What is good result? As you can see from query window then the number of IL instructions per member should have maximally 200 IL instructions. Of course, like always, the less instructions you have, the better performing code you have. I don’t mean here little differences but big ones. By example, take a look at my first method in warnings list. The number of IL instructions it has is huge. And believe me – this method looks awful. Conclusion The number of IL instructions is useful metric when optimizing your code. For analyzing code at general level to find out too long methods you can use the number of LoC metric because it is more intuitive for you and you can therefore handle the situation more easily. Also you can use NDepend as code metrics tool because it has a lot of metrics to offer.

    Read the article

  • How to refactor use of the general Exception?

    - by Colin
    Our code catches the general exception everywhere. Usually it writes the error to a log table in the database and shows a MessageBox to the user to say that the operation requested failed. If there is database interaction, the transaction is rolled back. I have introduced a business logic layer and a data access layer to unravel some of the logic. In the data access layer, I have chosen not to catch anything and I also throw ArgumentNullExceptions and ArgumentOutOfRangeExceptions so that the message passed up the stack does not come straight from the database. In the business logic layer I put a try catch. In the catch I rollback the transaction, do the logging and rethrow. In the presentation layer there is another try catch that displays a MessageBox. I am now thinking about catching a DataException and an ArgumentException instead of an Exception where I know the code only accesses a database. Where the code accesses a web service, then I thought I would create my own "WebServiceException", which would be created in the data access layer whenever an HttpException, WebException or SoapException is thrown. So now, generally I will be catching 2 or 3 exceptions where currently I catch just the general Exception, and I think that seems OK to me. Does anyone wrap exceptions up again to carry the message up to the presentation layer? I think I should probably add a try catch to Main() that catches Exception, attempts to log it, displays an "Application has encountered an error" message and exits the application. So, my question is, does anyone see any holes in my plan? Are there any obvious exceptions that I should be catching or do these ones pretty much cover it (other than file access - I think there is only 1 place where we read-write to a config file).

    Read the article

  • General purpose physics engine

    - by Lucas
    Is there any general purpose physics engine that allows huge simulations of rigid bodies? I'm using PhysX from Nvidia, but the focus of this engine is game development, soft bodies. I want to know if exists physics engine that runs on top of PS3 cell processors or CUDA cores allowing massive scientific physics simulations.

    Read the article

  • General Purpose Language to build a compiler for

    - by Brownie
    Inspired by Eric Sink's interview on the stackoverflow podcast I would like to build a full compiler in my spare time for the learning experience. My initial thought was to build a C compiler but I'm not sure whether it would take too much time. I am wondering if there is a smaller general purpose language that would be more appropriate to implement as a first compiler effort? Or is a C implementation doable on a reasonable timescale (200 hrs)? It is my intention to target the CLR.

    Read the article

  • The Main Purpose of Events in C#

    - by Tarik
    I've been examining one of my c# books and I just saw a sentence about Events in C#:  The main purpose of events is to prevent subscribers from interfering with each other. Whatever it means, yeah actually events are working pretty much like delegates. I've been wondering why I should use events instead of delegates. So is there any one who can explain the bold part? Thanks in advance.

    Read the article

  • What is the purpose of vshost.exe file?

    - by Milen
    When I create and compile a hello world application in C#, I get three files in the Debug folder apart from the main output exe (eg: HelloWorld.exe) 1. HelloWorld.vshost.exe 2. HelloWorld.pdb 3. HelloWorld.vshost.exe.manifest What are these files and what purpose do they serve?

    Read the article

  • what is the purpose of this mysql query ?

    - by Harbhag
    SELECT id, CONCAT(lastname,', ',firstname) AS fullname, lastname, firstname FROM " . TABLE_CONTACT . " WHERE CONCAT(firstname,' ', lastname) LIKE '%$goTo%' OR CONCAT(firstname,' ', middlename,' ', lastname) LIKE '%$goTo%' OR nickname LIKE '%$goTo%' ORDER BY fullname"; Can anyone please tell me what is purpose of above query ? I am new to mysql so unable to understand it. Thanks

    Read the article

  • What's the purpose of the unnamed namespace?

    - by bbazso
    In a .cpp file, if I decare a constant as follows: namespace { const int UDP_PORT_MIN = 1024; const int UDP_PORT_MAX = 65535; } vs. just: const int UDP_PORT_MIN = 1024; const int UDP_PORT_MAX = 65535; What's the difference between these two? I often see constant definitions declared in an unnamed namespace, so I was wondering what's the purpose of the unnamed namespace in this context?

    Read the article

  • purpose of php consutructor

    - by Bharanikumar
    Hi , Am working in the classes and object class structure , but not extream level , Just class and function , then in one place instantiation . that's it , not much big functions like __construct etc , Please tell me very simply , 1.what is th purpose of constructor ad destructor , But i know theoretical explanation school level , But i am expecting something like in real time , which situation we have to use, and is there any example for that please tell me, Regards

    Read the article

< Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >