Search Results

Search found 2579 results on 104 pages for 'mike monkiewicz'.

Page 56/104 | < Previous Page | 52 53 54 55 56 57 58 59 60 61 62 63  | Next Page >

  • filterSecurityInterceptor and metadatasource implementation spring-security

    - by Mike
    Hi! I created a class that implements the FilterInvocationSecurityMetadataSource interface. I implemented it like this: public List<ConfigAttribute> getAttributes(Object object) { FilterInvocation fi = (FilterInvocation) object; Object principal = SecurityContextHolder.getContext().getAuthentication().getPrincipal(); Long companyId = ((ExtenededUser) principal).getCompany().getId(); String url = fi.getRequestUrl(); // String httpMethod = fi.getRequest().getMethod(); List<ConfigAttribute> attributes = new ArrayList<ConfigAttribute>(); FilterSecurityService service = (FilterSecurityService) SpringBeanFinder.findBean("filterSecurityService"); Collection<Role> roles = service.getRoles(companyId); for (Role role : roles) { for (View view : role.getViews()) { if (view.getUrl().equalsIgnoreCase(url)) attributes.add(new SecurityConfig(role.getName() + "_" + role.getCompany().getName())); } } return attributes; } when I debug my application I see it reaches this class, it only reaches getAllConfigAttributes method, that is empty as I said, and return null. after that it prints this warning: Could not validate configuration attributes as the SecurityMetadataSource did not return any attributes from getAllConfigAttributes(). My aplicationContext- security is like this: <beans:bean id="filterChainProxy" class="org.springframework.security.web.FilterChainProxy"> <filter-chain-map path-type="ant"> <filter-chain filters="sif,filterSecurityInterceptor" pattern="/**" /> </filter-chain-map> </beans:bean> <beans:bean id="filterSecurityInterceptor" class="org.springframework.security.web.access.intercept.FilterSecurityInterceptor"> <beans:property name="authenticationManager" ref="authenticationManager" /> <beans:property name="accessDecisionManager" ref="accessDecisionManager" /> <beans:property name="securityMetadataSource" ref="filterSecurityMetadataSource" /> </beans:bean> <beans:bean id="filterSecurityMetadataSource" class="com.mycompany.filter.FilterSecurityMetadataSource"> </beans:bean> what could be the problem?

    Read the article

  • Why can't I attach the debugger?

    - by Mike
    I'm using Visual Studio 2008 SP1 and trying to debug a website created in ASP Classic. I have read numerous tutorials, however nothing seems to be working (PEBKAC?). I have enabled server-side debugging in IIS and am attaching the debugger to dllhost.exe. When I open my page in Google Chrome, set breakpoints and set VS to debug, nothing happens. I don't get any errors so I'm not sure what else to post. Any ideas? Thank you. :)

    Read the article

  • Is it possible to drag windows between workspaces when using Compiz?

    - by Mike Stone
    When I used Metacity, I could drag windows between workspaces using the small icon view of my workspaces. I recently started using Compiz for all the cool desktop effects, however this drag and drop feature isn't working. I use the cube effect for switching workspaces, but I noticed the wall effect doesn't allow it either. Is this just a missing feature from Compiz or is there a setting somewhere that I can enable it? I know that I can enable dragging windows across edges to the next workspace, and the expose feature to drag windows between workspaces. However, the drag and drop on the icon view is really powerful, and I would love to have it back along with all the great Compiz special effects.

    Read the article

  • Android ScrollView jumps around when setting child visibility to View.GONE

    - by Mike
    I have a ScrollView that contains an number of other views (TextViews, ImageViews, etc.). The ScrollView is taller than the screen. I have an AsyncTask that updates the children of the ScrollView based on an http response. I've discovered an interesting behavior that I can't figure out how to work around. If I set any of the children's visibilities to View.INVISIBLE as part of the AsyncTask.onPostExecute(), everything works fine. However, if I set any of the children's visibilities to View.GONE, the ScrollView jumps down from the top when onPostExecute() is called. Exactly how far seems to vary. I'm guessing that re-laying out the ScrollView is causing it to scroll away from the top for some reason. So the question is: is there a way to either prevent or work around this behavior? PS. Using ScrollView.jump(FOCUS_UP) as a workaround isn't ideal since that'll force the user to the top even if they had intended to scroll down.

    Read the article

  • Collaborative Filtering Program: What to do for a Pearson Score When There Isn't Enough Data

    - by Mike
    I'm building a recommendation engine using collaborative filtering. For similarity scores, I use a Pearson correlation. This is great most of the time, but sometimes I have users that only share a 1 or 2 fields. For example: User 1{ a: 4 b: 2 } User 2{ a: 4 b: 3 } Since this is only 2 data points, a Pearson correlation would always be 1 (a straight line or perfect correlation). This obviously isn't what I want, so what value should I use instead? I could just throw away all instances like this (give a correlation of 0), but my data is really sparse right now and I don't want to lose anything. Is there any similarity score I could use that would fit in with the rest of my similarity scores (all Pearson)?

    Read the article

  • In XPath how to select the element content

    - by Mike Q
    Hi all, Is there a way of writing an XPath expression to select the content of the element. e.g. <Element>xxx</Element> Assuming I can write XPath (/Element) to get Element how do I tweak the XPath to get xxxx returned rather than the Element wrapper.

    Read the article

  • Are there any libraries to allow Python or Ruby to get info from SVN?

    - by Mike Trpcic
    I'm looking for plugins that will allow my codebase to interact with, browse, and poll an SVN server for information about a repository. Trac can do this, but I was hoping there was an easy-to-use library available to accomplish the task, rather than trolling through the Trac codebase. Googling for this returns mostly vague results about storing your code in and SVN repository, which is far from what I'm looking for.

    Read the article

  • Why would this div have an unnecessarily large computed height?

    - by Mike Crittenden
    Link: http://www.fraynepainting.com/services The problem is that div#dditem_2 (the div with the "Take a look..." text) is getting a computed height of around 500px for no reason that I can find in the CSS, which is pushing the UL below it down really really far. I discovered that if you set display: none or position: absolute (or anything else that removes it from the flow of elements) on the sidebar, then the bottom UL moves up like it should, so it looks like maybe the UL is trying to clear the sidebar, but I can't figure out why that would be either. I've reproduced the problem in Firefox and Chrome so far. Any ideas?

    Read the article

  • use bouncy castle to create public key on j2me

    - by mike
    I got the public key from the certificate, keypair is a java.security.KeyPair object String public_key = keypair.getPublic().toString(); I want to send this to the via an http connection to a J2me application. I cannot find any documentation to convert the transmitted string to a Public key that can be used to encrypt Strings. I also want the J2me to verify signed strings from the server. I want to then send the encrypted strings back to the server.

    Read the article

  • Can't play wav file from Javascript in Firefox for Mac

    - by Mike Royle
    I have the following html file that plays a wav file when the user hovers over the 'Play' anchor tag. It works perfectly on IE, Chrome, Firefox, Opera, Safari on both Windows and Mac - except for Firefox on the Mac which does not play the file. <html> <head> <title></title> <script> function PlayAudio() { var s = document.getElementById("soundFile"); s.Play(); } </script> </head> <body> <embed src="MySound.wav" enablejavascript="true" type="audio/wav" autostart="false" width="0" height="0" id="soundFile" /> <a href="#" onmouseover="PlayAudio()">Play</a> </body> </html> If the autostart attribute of the embed tag is set to true then the wav file plays as expected in Firefox for Mac, but not on the mouseover of the anchor tag. Any ideas?

    Read the article

  • Perl, array referencing

    - by Mike
    Consider this Perl code my @a=[[1]]; print $a[0][0] . "\n"; **output** ARRAY(0x229e8) Why does it print an Array instead of 1? I would have expected @a to create an array of size 1 with a reference to a second array containing only one element, 1

    Read the article

  • Rails undefined method 'generated_methods' for nil:NilClass

    - by mike
    Okay so I was just starting this rails app and generated my first model ruby script/generate model Grid req:string class:string ctitle:string credits:float grade:string pass:boolean created my table rake db:migrate (in C:/Users/Michael/InstantRails/rails_apps/studentGrid) == CreateGrids: migrating ==================================================== -- create_table(:grids) - 0.0150s == CreateGrids: migrated (0.0150s) =========================================== and went to the console to add some data to my table Grid = Grid(id: integer, req: string, class: string, ctitle: string, credits: float, grade: string, pass: boolean, created_at: datetime, updated_at: datetime) Grid.create(:req="Math Elective", :class="Math 111", :ctitle="Calculus I", :credits=3.0) Pretty standard I thought, but then I get this error and I don't understand why NoMethodError: undefined method 'generated_methods' for nil:NilClass from C:/Users/Michael/InstantRails/ruby/lib/ruby/gems/1.8/gems/activesup port-2.3.5/lib/active_support/whiny_nil.rb:52:inmethod_missing' from C:/Users/Michael/InstantRails/ruby/lib/ruby/gems/1.8/gems/activerec ord-2.3.5/lib/active_record/attribute_methods.rb:352:in respond_to?' from C:/Users/Michael/InstantRails/ruby/lib/ruby/gems/1.8/gems/activerec ord-2.3.5/lib/active_record/base.rb:2746:inattributes=' from C:/Users/Michael/InstantRails/ruby/lib/ruby/gems/1.8/gems/activerec ord-2.3.5/lib/active_record/base.rb:2742:in each' from C:/Users/Michael/InstantRails/ruby/lib/ruby/gems/1.8/gems/activerec ord-2.3.5/lib/active_record/base.rb:2742:inattributes=' from C:/Users/Michael/InstantRails/ruby/lib/ruby/gems/1.8/gems/activerec ord-2.3.5/lib/active_record/base.rb:2438:in initialize' from C:/Users/Michael/InstantRails/ruby/lib/ruby/gems/1.8/gems/activerec ord-2.3.5/lib/active_record/base.rb:721:innew' from C:/Users/Michael/InstantRails/ruby/lib/ruby/gems/1.8/gems/activerec ord-2.3.5/lib/active_record/base.rb:721:in `create' from (irb):2 from :0

    Read the article

  • GLib Hash Table - Pointer

    - by Mike
    I'm trying to increment the value of some specific key if it was found. For some reason I keep getting the (pointer) address when I dump all keys:values from the hash table. Output a: 153654132 // should be 5 b: 1 c: 153654276 // should be 3 d: 1 e: 1 f: 153654420 // should be 3 int proc() { struct st stu; gpointer ok, ov; //... some non-related code here if(!g_hash_table_lookup_extended(table, key, &ok, &ov)){ stu.my_int = g_malloc(sizeof(guint)); *(stu.my_int) = 0; g_hash_table_insert(table, g_strdup(key), GINT_TO_POINTER(1)); }else{ stu.my_int = g_malloc(sizeof(guint)); *(stu.my_int)++; g_hash_table_insert(table, g_strdup(key), stu.my_int); } } Any ideas will be appreciate it.

    Read the article

  • GLib Hash Table - Pointer

    - by Mike
    I'm trying to increment the value of some specific key if it was found. For some reason I keep getting the (pointer) address when I dump all keys:values from the hash table. Output a: 153654132 // should be 5 b: 1 c: 153654276 // should be 3 d: 1 e: 1 f: 153654420 // should be 3 int proc() { struct st stu; gpointer ok, ov; //... some non-related code here if(!g_hash_table_lookup_extended(ht, key, &ok, &ov)){ stu.my_int = g_malloc(sizeof(guint)); *(stu.my_int) = 0; g_hash_table_insert(table, g_strdup(key), GINT_TO_POINTER(1)); }else{ stu.my_int = g_malloc(sizeof(guint)); *(stu.my_int)++; g_hash_table_insert(table, g_strdup(key), stu.my_int); } } Any ideas will be appreciate it.

    Read the article

  • Global Timer in Javascript with Multiple Callbacks

    - by Mike Beepo
    I want to create a global timer object in javascript and then be able to add callbacks to it on the fly. This way I can just use one global timer in my script to execute all actions at a certain interval rather than wasting resources by using multiples. This is how I want to be able to piece things together: var timer = new function() { clearInterval( this.interval ); //[1] At this point I want the Callbacks to be run var self = this; setTimeout(function() {self.timer()}, 200); } function otherObject = new function() { //When created I want to bind my object's function called cb to the global timer at [1] } otherObject.prototype.cb = function() { //Stuff that should be done every time the timer is run } var someObject = new otherObject(); How would I make it possible bind any number functions (most of which are functions within other objects) to run at the interval of my timer on the fly?

    Read the article

  • Some special characters defined in "ISO-8859-1" can't be shown when encoding with "UTF-8"

    - by Mike.Huang
    I need to get a string from URL request of brower, and then create a text image by requested text. I know the default encoding of the Java net transmission is "ISO-8859-1", it can works normally with all characters what defined in "ISO-8859-1". But when I request a multi-byte Unicode character (e.g. chinese or something like ¤?), then I need to decode it by "UTF-8" from "ISO-8859-1". My codes like: String reslut = new String(requestString.getBytes("ISO-8859-1"), "UTF-8"); Everything is fine, but I found some characters in ISO-8859-1 are not been shown now, which characters are 0x80 - 0xFF(defined in" ISO-8859-1"), i.e. the characters after 0x80 (in "ISO-8859-1") not been shown when converted to "UTF-8" from "ISO-8859-1". Any other method can solve this query?

    Read the article

  • Neural Network: Handling unavailable inputs (missing or incomplete data)

    - by Mike
    Hopefully the last NN question you'll get from me this weekend, but here goes :) Is there a way to handle an input that you "don't always know"... so it doesn't affect the weightings somehow? Soo... if I ask someone if they are male or female and they would not like to answer, is there a way to disregard this input? Perhaps by placing it squarely in the centre? (assuming 1,0 inputs at 0.5?) Thanks

    Read the article

  • REST for ASP.NET MVC included in MVC 2?

    - by Mike Hodnick
    Are the REST for ASP.NET MVC bits automatically included with MVC 2, or do you need to download/install/use the REST for ASP.NET MVC bits separately? Specifically, I'm referring to the REST for ASP.NET MVC download here: http://aspnet.codeplex.com/releases/view/24471#DownloadId=79561 I want to use REST for ASP.NET MVC for the automatic json/xml serialization based on the incoming request's accepted content type. I'm not really finding any info about MVC2's ability to do this out of the "box".

    Read the article

  • Database access through collections

    - by Mike
    Hi All, I have an 3 tiered application where I need to get database results and populated the UI. I have a MessagesCollection class that deals with messages. I load my user from the database. On the instantiation of a user (ie. new User()), a MessageCollection Messages = new MessageCollection(this) is performed. Message collection accepts a user as a parameter. User user = user.LoadUser("bob"); I want to get the messages for Bob. user.Messages.GetUnreadMessages(); GetUnreadMessages calls my Business Data provider which in turn calls the data access layer. The Business data provider returns List. My question is - I am not sure what the best practice is here - If I have a collection of messages in an array inside the MessagesCollection class, I could implement ICollection to provide GetEnumerator() and ability to traverse the messages. But what happens if the messages change and the the user has old messages loaded? What about big message collections? What if my user had 10,000 unread messages? I don't think accessing the database and returning 10,000 Message objects would be efficient.

    Read the article

  • forwarding a notification to another class

    - by Mike
    I am using this method - (void)keyboardWillShow:(NSNotification *)notification that is triggered when the keyboard shows. When this method is triggered, it receives a notification that contains several parameters about the keyboard, as the animation duration, animation curve and frame. I need to forward this notification and all its parameters to another class. So, I've tried to do this inside keyboardWillShow: [[NSNotificationCenter defaultCenter] postNotificationName:@"doSomething" object:notification userInfo:nil]; the doSomething notification runs doSomething method on another class, and it has this form: - (void) doSomething:(NSNotification *)notification { but when I try to read the notification values on this other class, using, for example, myRect = [[[notification userInfo] objectForKey:UIKeyboardFrameEndUserInfoKey] CGRectValue]; I obtain zero for all values. The notification is losing its parameters and not being forwarded. How can I do that? thanks.

    Read the article

  • Syncing two separate structures to the same master data

    - by Mike Burton
    I've got multiple structures to maintain in my application. All link to the same records, and one of them could be considered the "master" in that it reflects actual relationships held in files on disk. The other structures are used to "call out" elements of the main design for purchase and work orders. I'm struggling to come up with a pattern that deals appropriately with changes to the master data. As an example, the following trees might refer to the same data: A |_ B |_ C |_ D |_ E |_ B |_ C |_ D A |_ B E C |_ D A |_ B C D E These secondary structures follow internal rules, but their overall structure is usually user-determined. In all cases (including the master), any element can be used in multiple locations and in multiple trees. When I add a child to any element in the tree, I want to either automatically build the secondary structure for each instance of the "master" element or at least advertise the situation to the user and allow them to manually generate the data required for the secondary trees. Is there any pattern which might apply to this situation? I've been treating it as a view problem, but it turns out to be more complicated than that when you look at the initial generation of the data.

    Read the article

  • iphone - gesture not working on animated view

    - by Mike
    I have this animated view and a gesture assigned to it... [self.view setUserInteractionEnabled:YES]; UIImageView *sequence = [[UIImageView alloc] initWithImage:[UIImage imageNamed:@"frame0.png"]]; [sequence setUserInteractionEnabled:YES]; sequence.center = CGPointMake(centroX, centroY); NSMutableArray *array = [[NSMutableArray alloc] init] ; for (int i=0; i<30; i++) { UIImage *oneImage = [UIImage imageNamed:[NSString stringWithFormat:@"frame%d.png",i]]; [array addObject:oneImage]; } sequence.animationImages = array; sequence.animationDuration = 1.0; sequence.animationRepeatCount = 1; [self.view addSubview:sequence]; [sequence release]; sequence.startAnimating; sequence.image = [UIImage imageNamed:@"frame29.png"]; // doSomething never runs when I tap the image... why? UITapGestureRecognizer *singleTap = [[UITapGestureRecognizer alloc] initWithTarget:self action:@selector(doSomething)]; [singleTap setDelegate:self]; [singleTap setCancelsTouchesInView:NO]; [singleTap setDelaysTouchesEnded:NO]; [sequence addGestureRecognizer:singleTap]; [singleTap release]; The gesture is never called... why? I have no other gesture associated anywhere. thanks for any help.

    Read the article

  • I need information about Informatica

    - by Mike
    I need some information about the Informatica ETL tool. I am a rookie with that, so could you please recommend where can I get some tutorials to get started. Can I download the tool, and if so where can I download it? What are the alternatives to Informatica?

    Read the article

  • xpath 2.0 query - how to test for the first occurence of an element in a xml document

    - by Mike
    I have the following xsl template: <xsl:template match="para"> <fo:block xsl:use-attribute-sets="paragraph.para"> <!-- if first para in document --> <!--<xsl:if test="//para[1] intersect .">--> <xsl:if test="//para[1] intersect ."> <xsl:attribute name="space-after">10pt</xsl:attribute> <xsl:attribute name="background-color">yellow</xsl:attribute> </xsl:if> <xsl:choose> <xsl:when test="preceding-sibling::*[1][self::title]"> <xsl:attribute name="text-indent">0em</xsl:attribute> </xsl:when> <xsl:when test="parent::item"> <xsl:attribute name="text-indent">0em</xsl:attribute> </xsl:when> <xsl:otherwise> <xsl:attribute name="text-indent">1em</xsl:attribute> </xsl:otherwise> </xsl:choose> <xsl:apply-templates/> </fo:block> </xsl:template> The problem I am having is selecting the very first para node in the document from the following xml: <document> <section> <paragraph> <para>Para Text 1*#</para> <para>Para Text 2</para> </paragraph> </section> <paragraph> <para>Para Text 3*</para> <para>Para Text 4</para> <para>Para Text 5</para> <sub-paragraph> <para>Para Text 6*</para> <para>Para Text 7</para> </sub-paragraph> </paragraph> <appendix> <paragraph> <para>Para Text 8*</para> </paragraph> <paragraph> <para>Para Text 9</para> </paragraph> </appendix> </document> the xpath I am currently using is "//para[1] intersect ." which is selecting the first para for each group of para (denoted with a * in XML sample). Any ideas on how I can just select the first occurance of para within document (denoted with a #)?

    Read the article

< Previous Page | 52 53 54 55 56 57 58 59 60 61 62 63  | Next Page >