Search Results

Search found 61241 results on 2450 pages for 'empty set'.

Page 10/2450 | < Previous Page | 6 7 8 9 10 11 12 13 14 15 16 17  | Next Page >

  • std::set<T>::erase(key). What if key isn't there?

    - by Armen Tsirunyan
    if I erase an element from an std::set and pass the key, not the iterator, and the key isn't in the set right now, will an exception be thrown? The thing is every second sentence in the MSDN documentation says: "this does blah blah, but it doesn't conform to the standard". So I need to know the standard behaviour. I just couldn't find it in the standard. Redirecting to the relevant clause will do as well. Thanks.

    Read the article

  • Filter Empty Directories in Package Explorer View

    - by Matt
    Is there a way in eclipse to filter/hide empty directory trees in the package explorer view? This is different than filtering directories like '.svn' or maven's target, or filtering empty packages. It's more trying to clean up empty directories trees that show up as a result of filter rules. Context- We have a generic project in our workspace that uses filters to ignore non text based files(mp3s, jpgs, etc). It allows us to quickly edit our files in eclipse. The problem is because of the filters there are a lot of empty folders present. If eclipse can ignore any empty folders due to filters it would make the project cleaner.

    Read the article

  • How to show empty view when ListView is empty?

    - by Sheehan Alam
    Here is my layout. For some reason the empty view (TextView in this case) always appears, even when the List is not empty. I thought the ListView would automatically detect when to show the empty view. How can I hook up the empty view properly? <RelativeLayout android:id="@+id/LinearLayoutAR" android:layout_height="fill_parent" android:layout_width="fill_parent"> <ListView android:layout_width="fill_parent" android:layout_height="fill_parent" xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/ARListView"></ListView> <ProgressBar android:layout_width="wrap_content" android:layout_height="wrap_content" android:id="@+id/arProgressBar" android:layout_centerHorizontal="true" android:layout_centerVertical="true"></ProgressBar> <!-- Here is the view to show if the list is emtpy --> <TextView android:id="@id/android:empty" android:layout_width="match_parent" android:layout_height="match_parent" android:text="No Results" /> </RelativeLayout>

    Read the article

  • Patch Set 11.2.0.2 for Win32 and Win64 now available

    - by Mike Dietrich
    Oracle Database Patch Set 11.2.0.2 for Windows (Patch: 10098816) is now available for download from support.oracle.com: Oracle Database 11.2.0.2 Patch Set for Windows 32bit Oracle Database 11.2.0.2 Patch Set for Windows 64bit Please keep in mind: It's a full install - you don't have to download 11.2.0.1 first, you can start right with 11.2.0.2 You'll get it just from support.oracle.com - no download from OTN or eDelivery as this is a patch set Installation will be done by default into a separate %ORACLE_HOME% .- and this is our strong recommendation. If you'd like to install into your existing 11.2.0.1 %ORACLE_HOME% then you'll have to detach your 11.2.0.1 home from the OUI inventory first (runInstaller -detachHome ORACLE_HOME=c:\orahomes\11.2.0), save the contents of ?\network\admin and ?\database, clean up, install 11.2.0.2 and copy the saved network\admin and \database content back. Btw, Oracle Database Patch Set 10.2.0.5 for HP-UX - Patch:8202632 is available for download as well since today.

    Read the article

  • IComparer for integers with and empty strings at end

    - by paulio
    Hi, I've written the following IComparer but I need some help. I'm trying to sort a list of numbers but some of the numbers may not have been filled in. I want these numbers to be sent to the end of the list at all times.. for example... [EMPTY], 1, [EMPTY], 3, 2 would become... 1, 2, 3, [EMPTY], [EMPTY] and reversed this would become... 3, 2, 1, [EMPTY], [EMPTY] Any ideas? public int Compare(ListViewItem x, ListViewItem y) { int comparison = int.MinValue; ListViewItem.ListViewSubItem itemOne = x.SubItems[subItemIndex]; ListViewItem.ListViewSubItem itemTwo = y.SubItems[subItemIndex]; if (!string.IsNullOrEmpty(itemOne.Text) && !string.IsNullOrEmpty(itemTwo.Text)) { uint itemOneComparison = uint.Parse(itemOne.Text); uint itemTwoComparison = uint.Parse(itemTwo.Text); comparison = itemOneComparison.CompareTo(itemTwoComparison); } else { // ALWAYS SEND TO BOTTOM/END OF LIST. } // Calculate correct return value based on object comparison. if (OrderOfSort == SortOrder.Descending) { // Descending sort is selected, return negative result of compare operation. comparison = (-comparison); } else if (OrderOfSort == SortOrder.None) { // Return '0' to indicate they are equal. comparison = 0; } return comparison; } Cheers.

    Read the article

  • IComparer for integers and force empty strings to end

    - by paulio
    Hi, I've written the following IComparer but I need some help. I'm trying to sort a list of numbers but some of the numbers may not have been filled in. I want these numbers to be sent to the end of the list at all times.. for example... [EMPTY], 1, [EMPTY], 3, 2 would become... 1, 2, 3, [EMPTY], [EMPTY] and reversed this would become... 3, 2, 1, [EMPTY], [EMPTY] Any ideas? public int Compare(ListViewItem x, ListViewItem y) { int comparison = int.MinValue; ListViewItem.ListViewSubItem itemOne = x.SubItems[subItemIndex]; ListViewItem.ListViewSubItem itemTwo = y.SubItems[subItemIndex]; if (!string.IsNullOrEmpty(itemOne.Text) && !string.IsNullOrEmpty(itemTwo.Text)) { uint itemOneComparison = uint.Parse(itemOne.Text); uint itemTwoComparison = uint.Parse(itemTwo.Text); comparison = itemOneComparison.CompareTo(itemTwoComparison); } else { // ALWAYS SEND TO BOTTOM/END OF LIST. } // Calculate correct return value based on object comparison. if (OrderOfSort == SortOrder.Descending) { // Descending sort is selected, return negative result of compare operation. comparison = (-comparison); } else if (OrderOfSort == SortOrder.None) { // Return '0' to indicate they are equal. comparison = 0; } return comparison; } Cheers.

    Read the article

  • Sharepoint : send alert when field is empty : bug ?

    - by mathieu
    Is it possible to send an email alert when a field of a list is empty ? I've tried the following : Create a custom list, add a field named "TestField" Create a personal view named "TestView", filter : Show when column "TestField" is equal to "" (leave the box empty) Create an alert, immediate email when items appearing in "TestView" are modified Create an item with both fields filled Create an item with only title filled Now you should receive two alert emails, but in the view "TestView" there is only one item. Is it a bug ?

    Read the article

  • How can I fix the "TERM environment variable not set" warning in eclipse

    - by Robert
    I'm running ubuntu 12.04 LTS and working with eclipse (juno) on a c++ project. I keep getting "TERM environment variable not set" in the console while trying to run the program. I realize this means the variable needs to get set. My question is what should it be set to and how do I set it? I've read that it should be 'xterm' in a few places. So I added export TERM=xterm in my .profile and while eclipse stopped giving me the warning, instead it would output unreadable garbage everynow and then (not a side effect of the program). It did display the program output but intermixed were weird characters. This leads me to believe it's not 'xterm' I should be setting TERM to. Or I'm setting it in an incorrect way. Any help is appreciated. Sample output: **TERM environment variable not set.** Please make a selection ----------------------- 1. Create a budget 2. Edit a budget 3. Display a budget 4. Save a budget 5. Load a budget 6. Exit What is your selection: 1 **TERM environment variable not set.** Enter the name of your budget: etc The program continues to execute as expected but the message is highly annoying As someone has commented, I do use system("clear") which is likely the source of the warning? Either way, is this likely just an eclipse issue or something I can fix in ubuntu/linux

    Read the article

  • Ruby on Rails: What are partial hash arguments and full set arguments?

    - by williamjones
    I'm using asserts_redirected_to in my unit tests, and I'm receiving this warning: DEPRECATION WARNING: Using assert_redirected_to with partial hash arguments is deprecated. Specify the full set arguments instead. What is a partial hash argument, and what is a full set argument? These aren't terms that I've seen used in the Rails community before, and the only relevant results I can find on Google for these are in reference to this deprecation warning. Here is my code: assert_redirected_to :controller => :user, :action => :search also tried: assert_redirected_to({:controller => :user, :action => :search}) I might have guessed that it feels I'm missing some parameters or something like that, but the API documentation explicitly says that not all parameters need to be included: http://rails.rubyonrails.org/classes/ActionController/Assertions/ResponseAssertions.html

    Read the article

  • Set iPhone Style Location Based Alerts On Your Android Device With Google Now

    - by Gopinath
    Location based alerts of iPhone are very useful. You can set an alert to popup as soon as you reach a specific location like “Pickup milk and eggs” when I’m near a grocery store. This feature was missing in Android for a long time, but last week at Google I/O conference Google released an update to Google Now which supports location based alerts. To setup a location based alert 1. Launch Google Now 2. Type or say add reminder 3. By default it shows time based alert interface, switch it location based by touching Location icon 4. Set reminder text, choose a location and touch Set reminder 5. Your alert is set now and as soon as you are close by the specified location, you’ll see an alert on your device. This is a nice feature and I’m using it quite often for the past couple of days.  There are couple of things missing from the current version of Google Now location based alerts– recurring alerts and ability to set alerts on leaving a specific location. It is not possible to recur location based alerts. You will be alerted only once as soon as you reach the location and it is not possible to repeat the alert next time you visit the location. Lets say you want to be reminded to say hi to friend’s parents whenever you are travelling close by their home. It does not work. The second missing feature is something basic and some how Google did not incorporate in their first iteration. Lets say you are at office now and you want to set up alert to pickup flowers when you leave office. Sounds like a simple use case for location based alerts right? But there is no way to set this type of alerts. Google Now alerts you as soon as you reach a location, but not when you leave a location. Do you have an Android that supports Google Now? If so what are your thoughts on location based alerts?

    Read the article

  • What is a simple C library for a set of integer sets?

    - by conradlee
    I've got to modify a C program and I need to include a set of unsigned integer sets. That is, I have millions of sets of integers (each of these integer sets contains between 3 and 100 integers), and I need to store these in some structure, lets call it the directory, that can in logarithmic time tell me whether a given integer set already exists in the directory. The only operations that need to be defined on the directory is lookup and insert. This would be easy in languages with built-in support for useful data structures, but I'm a foreigner to C and looking around on Google did (surprisingly) not answer my question satisfactorily. This project looks about right: http://uthash.sourceforge.net/ but I would need to come up with my own hash key generator. This is a standard, simple problem, so I hope there is a standard and simple solution.

    Read the article

  • How do I wrap a repeatbale set of elements in jQuery?

    - by Globalz
    In jQuery how would I go about wrapping a repeatable set of elements with a div? For example I have: img h4 p img h4 p img h4 p I need to wrap each img, h4, p set with a div class="container". So it will look like: <div> class="container" img h4 p </div> <div> class="container" img h4 p </div> <div> class="container" img h4 p </div> Any ideas on how I can achieve this as its driving me nuts! I keep getting nested div.containers! Thanks!

    Read the article

  • Sorted exsl:node-set. Return node by it position.

    - by kalininew
    Good afternoon, gentlemen. Help me solve a very simple task. I have a set of nodes <menuList> <mode name="aasdf"/> <mode name="vfssdd"/> <mode name="aswer"/> <mode name="ddffe"/> <mode name="ffrthjhj"/> <mode name="dfdf"/> <mode name="vbdg"/> <mode name="wewer"/> <mode name="mkiiu"/> <mode name="yhtyh"/> and so on... </menuList> I have it sorted now this way <xsl:variable name="rtf"> <xsl:for-each select="//menuList/mode"> <xsl:sort data-type="text" order="ascending" select="@name"/> <xsl:value-of select="@name"/> </xsl:for-each> </xsl:variable> Now I need to get an arbitrary element in the sorted array to the number of its position. I write code <xsl:value-of select="exsl:node-set($rtf)[position() = 3]"/> and get a response error. How to do it right?

    Read the article

  • How to troubleshoot connectivity when curl gets an *empty response*

    - by chad
    I want to know how to proceed in troubleshooting why a curl request to a webserver doesn't work. I'm not looking for help that would be dependent upon my environment, I just want to know how to collect information about exactly what part of the communication is failing, port numbers, etc. chad-integration:~ # curl -v 111.222.159.30 * About to connect() to 111.222.159.30 port 80 (#0) * Trying 111.222.159.30... connected * Connected to 111.222.159.30 (111.222.159.30) port 80 (#0) > GET / HTTP/1.1 > User-Agent: curl/7.19.0 (x86_64-suse-linux-gnu) libcurl/7.19.0 OpenSSL/0.9.8h zlib/1.2.3 libidn/1.10 > Host: 111.222.159.30 > Accept: */* > * Empty reply from server * Connection #0 to host 111.222.159.30 left intact curl: (52) Empty reply from server * Closing connection #0 So, I understand that an empty response means that curl didn't get any response from the server. No problem, that's precisely what I'm trying to figure out. But what more specific info can I derive from cURL here? It was able to successfully "connect", so doesn't that involve some bidirectional communication? If so, then why does the response not come also? Note, I've verified my service is up and returning responses. Note, I'm a bit green at this level of networking, so feel free to provide some general orientation material.

    Read the article

  • Trying to delete directory with "rm -rf", but get message that it's not empty

    - by Ben Hocking
    I've tried deleting a directory using "rm -rf" and I'm getting the message "Directory not empty": Bens-MacBook-Pro:please benjaminhocking$ ls -lart empty_directory/ total 16 drwxr-xr-x 5 benjaminhocking staff 170 Aug 27 14:46 . drwxr-xr-x 3 benjaminhocking staff 102 Aug 27 15:28 .. Bens-MacBook-Pro:please benjaminhocking$ rm -rf empty_directory/ rm: empty_directory/: Directory not empty Bens-MacBook-Pro:please benjaminhocking$ rmdir empty_directory/ rmdir: empty_directory/: Directory not empty If I try the same thing using Finder (dragging the folder to the Trash), I get the message The operation can’t be completed because the item “empty_directory” is in use. I've tried doing xattr -d com.apple.quarantine, purely out of superstition, but it did no good. A probably important piece of context is that this directory was initially in a directory that should've been deleted by a "make clean" command I issued prior to Terminal locking up on me, after which a little over half of the other programs I had running also locked up, including Skype, and eventually the OS itself. I ended up having to reboot the computer by pressing and holding the power key. Edit to add: Another important piece of information I left off was that this was happening in an encrypted folder à la encfs. I was able to track down the corresponding folder in the encrypted side of things and delete it there. I still don't know why I couldn't do it from the decrypted side of things like I normally do. I'll leave this unanswered for now in case anyone has a good answer for that.

    Read the article

  • logrotate: neither rotate nor compress empty files

    - by Andrew Tobey
    i have just set up an (r)syslog server to receive the logs of various clients, which works fine. only logrotate is still not behaving as intending. i want logrotate to create a new logfile for each day, but only to keep and store i.e. compress non-empty files. my logrotate config looks currently like this # sample configuration for logrotate being a remote server for multiple clients /var/log/syslog { rotate 3 daily missingok notifempty delaycompress compress dateext nomail postrotate reload rsyslog >/dev/null 2>&1 || true endscript } # local i.e. the system's very own logs: keep logs for a whole month /var/log/kern.log /var/log/kernel-info /var/log/auth.log /var/log/auth-info /var/log/cron.log /var/log/cron-info /var/log/daemon.log /var/log/daemon-info /var/log/mail.log /var/log/rsyslog /var/log/rsyslog-info { rotate 31 daily missingok notifempty delaycompress compress dateext nomail sharedscripts postrotate reload rsyslog >/dev/null 2>&1 || true endscript } # received i.e. logs from the clients /var/log/path-to-logs/*/* { rotate 31 daily missingok notifempty delaycompress compress dateext nomail } what i end up with is having is some sort of "summarized" files such as filename-datestampDay-Day and corresponding .gz files. What I do have are empty files, which are eventually zipped. so does the notifempty directive is in fact responsible for these DayX-DayY files, days on which really nothing happened? what would be an efficient way to drop both, empty log files and their .gz files, so that I eventually only keep logs/compressed files that truly contain data?

    Read the article

  • VBScript: how to set values from recordset to string

    - by phill
    This is probably a beginner question, but how do you set a recordset to a string variable? Here is my code: Function getOffice (strname, uname) strEmail = uname WScript.Echo "email: " & strEmail Dim objRoot : Set objRoot = GetObject("LDAP://RootDSE") Dim objDomain : Set objDomain = GetObject("LDAP://" & objRoot.Get("defaultNamingContext")) Dim cn : Set cn = CreateObject("ADODB.Connection") Dim cmd : Set cmd = CreateObject("ADODB.Command") cn.Provider = "ADsDSOObject" cn.Open "Active Directory Provider" Set cmd.ActiveConnection = cn cmd.CommandText = "SELECT physicalDeliveryOfficeName FROM '" & objDomain.ADsPath & "' WHERE mail='" & strEmail & "'" cmd.Properties("Page Size") = 1 cmd.Properties("Timeout") = 300 cmd.Properties("Searchscope") = ADS_SCOPE_SUBTREE Dim objRS : Set objRS = cmd.Execute WScript.Echo objRS.Fields(0) Set cmd = Nothing Set cn = Nothing Set objDomain = Nothing Set objRoot = Nothing Dim arStore Set getOffice = objRS.Fields(0) Set objRS = Nothing End function When I try to run the function, it throws an error "vbscript runtime error: Type mismatch" I presume this means it can't set the string variable with a recordset value. How do I fix this problem?

    Read the article

  • A C# collection, which behaves like C++ set or priority_queue?

    - by Wojciech
    Hello, I have written the Dijkstra's algorithm many times in C++ - I need there set or priotity_queue, both give me possibility to add an element and find the least one (using specified comparator). Now, I've got a problem when trying to write Dijkstra in C# - is there any structure which could be useful for me? I need adding and finding or erasing the least element. Using Visual Studio '08

    Read the article

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