wildcard

jQuery: select all inputs with unique id (Regex/Wildcard Selectors)

I have some textboxes on a webform that have ids like this: txtFinalDeadline_1 txtFinalDeadline_2 txtFinalDeadline_3 txtFinalDeadline_4 In my jQuery how do I find all of those in order to assign a value to them. Before I had the underscore and they were all named txtFinalDeadline I could do this and it worked. $(this).find("#txtFinalDe...

Problem of * in Command line argument

I wrote a program in Java that accepts input via command line arguments. I get input of two numbers and an operator from the command line. To multiply two numbers, i have to give input as e.g. 5 3 *, but it's not working as written. Why is it not accepting * from the command line? ...

Java Generics: What is PECS?

Hi, I came across PECS (short for Producer extends and Consumer super) while reading on Generics. Can someone explain to me how to use PECS to resolve confusion between extends and super? Thanks in advance! ...

PHP file_exists and wildcard

Is there a way to write the PHP file_exists function so that it searches a directory for a file with an arbitrary extension. For instance, suppose I knew that a file were called "hello", but I didn't know the extension, how would I write a function that searched for a file called hello.* and returned the name of this file? As far as I ...

Wildcards vs. generic methods

Is there any practical difference between the following approaches to print all elements in a range? public static void printA(Iterable<?> range) { for (Object o : range) { System.out.println(o); } } public static <T> void printB(Iterable<T> range) { for (T x : range) { System.out.println(x); } }...

.Htaccess & Wildcard Subdomains — Can't get other variables to work!

It would be absolutely awesome if someone could help me out here. I have a domain, let's call it "example.com". I have wildcard subdomains setup and working great. The only problem is I can't get htaccess to see anything else like subdomain.example.com/profile/some_name/some_id_number/. In fact, I can type any garbage after the domain a...

Find and Replace a section of a string with wildcard type search

I want to be able to read a file, and replace all instances of: M9S1800.2 with S1800 (I want to get rid of the M9 and the .2). The problem I am having is that the 4 digit number after the "S" can be different every time, as well as the number after the decimal. For example, It can be: M9S3200.1 or M9S5400.1 or M9S5400.2 Can so...

Find and Replace a section of a string with wildcard type search using RegEx (while retaining some text)

I am trying to replace some text in a string with different text while retaining some of the text and I am having trouble doing it. My code is: StreamReader reader = new StreamReader(fDialog.FileName.ToString()); string content = reader.ReadToEnd(); reader.Close(); /Replace M2 with M3 (this works fine) content = Regex.Replace(conten...

Find and Replace RegEx question

I am starting to get a grip on RegEx thanks to all the great help here on SO with my other questions. But I am still suck on this one: My code is: StreamReader reader = new StreamReader(fDialog.FileName.ToString()); string content = reader.ReadToEnd(); reader.Close(); I am reading in a text file and I want to search for thi...

Find and Replace RegEx with wildcard search and addition of value

The below code is from my other questions that I have asked here on SO. Everyone has been so helpful and I almost have a grasp with regards to RegEx but I ran into another hurdle. This is what I basically need to do in a nutshell. I need to take this line that is in a text file that I load into my content variable: X17.8Y-1.Z0.1G0H...

Using "wildcards" in a vlist array to delete rows in Excel

Good Morning All, I'm trying to setup a vba macro to delete all user IDs out of a spreadsheet that do not start with designated prefixes (e.g. US, A1, VM, etc). The below block of code was found on the Code Library and looks to be what I need but there is one problem: When I enter in UserID prefixes into the vlist fields, it treats them...

Drools rules import with wildcard

Hello everyone, I am working with Drools rules. Some developers have created rules which I have to put on Guvnor (rules repository) and build packages. In these rules they have import statements with wildcards, for example: import org.drools.runtime.rule.*; When I upload this on Guvnor and try to build, it tells me: Unable to introspe...

Find and replace question regarding RegEx.Replace

Hello, I have a text file and I want to be able to change all instances of: T1M6 to N1T1M6 The T will always be a different value depending on the text file loaded. So example it could sometimes be T2M6 and that would need to be turned into N2T2M6. The N(value) must match the T(value). The M6 will always be M6. Another example:...

Editing Multiple files in vi with Wildcards

When using the programmers text editor vi, I'll often using a wildcard search to be lazy about the file I want to edit vi ThisIsAReallLongFi*.txt When this matches a single file it works great. However, if it matches multiple files vi does something weird. First, it opens the first file for editing Second, when I :wq out of the fil...

OpenFileDialog - only display filenames that have no extensions

Hello, I have the following code in my C# program: OpenFileDialog fDialog = new OpenFileDialog(); fDialog.Title = "Open a file"; fDialog.Filter = "NCF files (*.ncf)|*.ncf|All files (*.*)|*.*|No Extensions (*.)|*."; I want to be able to have the user pick from the following: .NCF (files with .NCF e...

Java Generic Collection of Generic Type with Bounded Wildcard

Please help me with this: If Lion IS-A Animal and given Cage<T>: Cage<? extends Animal> c = new Cage<Lion>(); // ok, but Set<Cage<? extends Animal>> cc = new HashSet<Cage<Lion>>(); // not ok What I don't see here? ...

Using wildcards for filenames in powershell

I am having a lot of issues trying to automate downloading from an ftp site. I know the folder the file will be in, and I know that it will be a .zip file. However I do not know what the files will be named. So I have code that works if I know the file name...for example: $sourceuri = "ftp://myFtpSite/test/myZipFile.zip" I would ...

1 domain.. 2 server and 2 applications

i have a site like twitter.com on server one and on server two i have forum, which path is like domain.com/forum on server one i wanted to implement wild card dns and put main domain on it. but on server two i wanted to keep forum separate, i cant give sub-domain forum.domain.com, because all its links are already put in search engines ...

Wildcard for terms in phrase - Lucene

Google's query syntax allows to search phrases like "as * as a skyscraper" where the asterisk can match any term (or terms). Is there a way to achieve the same thing in Lucene? The proximity operator ~ could be of use but it is not what I exactly want. ...

Signature of Collections.min/max method

In Java, the Collections class contains the following method: public static <T extends Object & Comparable<? super T>> T min(Collection<? extends T> c) Its signature is well-known for its advanced use of generics, so much that it is mentioned in the Java in a Nutshell book and in the official Sun Generics Tutorial. However, I could n...