Search Results

Search found 9771 results on 391 pages for 'equivalence classes'.

Page 166/391 | < Previous Page | 162 163 164 165 166 167 168 169 170 171 172 173  | Next Page >

  • Does python import all the listed libraries? - Python

    - by RadiantHex
    Hi folks, I'm just wondering, I often have really long python files and imports tend to stack quite quickly. PEP8 says that the imports should always be written at the beginning of the file. Do all the imported libraries get imported when calling a function coded in the file? Or do only the necessary libraries get called? Does it make sense to worry about this? Is there no reason to import libraries within the functions or classes that need them?

    Read the article

  • Using a nHibernate wrapper with fluent nHibernate

    - by alex
    Is it possible to use something like this wrapper with fluent configuration? http://jeffreypalermo.com/blog/use-this-nhibernate-wrapper-to-keep-your-repository-classes-simple/ If so, where would I add the fluent config? Also, would this be suited to use in both asp.net and windows applications? I'm planning to use the repository pattern, using this to create my nHibernate session?

    Read the article

  • Programmatically convert a video to FLV

    - by Raibaz
    Hi all, i am currently working on a web application that needs to accept video uploaded by users in any format (.avi, .mov, etc.) and convert them to flv for playing in a flash-based player. Since the site is OpenCms-based, the best solution would be a ready-made plugin for OpenCms that allowed to upload and play videos doing the transcode operation in background, but just a set of Java classes to do the transcode would be great and then i could make the uploading form and playback part on my own.

    Read the article

  • MSIL inspection

    - by Frank Schwieterman
    I have some MSIL in byte format (result of reflection's GetMethodBody()) that I'd like to analyze a bit. I'd like to find all classes created with the new operator in the MSIL. Any ideas on how to do that programmatically?

    Read the article

  • Modelling class relations

    - by phenevo
    Hi, I have a few classes: Article ------- Content ID Magazine -------- Name Code And 3 tables in database: Articles Magazines ArticlesInMagazines (two fields: IDArticle and CodeMagazine) In my app, I've got a module to manage Articles, and a datagridview to relate their associated magazines DataGridView has twofields: MagazineCode IsPublished (indicates articles which have been published in this magazine). The same article can be in many magazines (1:n) How would you implement on model ? Article have to has a field : List ?? I am concerned because Magazine associates Articles

    Read the article

  • include an APK in Android.mk

    - by ayden
    I'm writing a Android.mk to make a APK-A. and APK-A would use other classes defined in APK-B. I wonder that how should I wrote the Android.mk to include APK-B. Which tag should I use? Thanks.

    Read the article

  • iPhone: Ovi maps

    - by Rupesh
    hi all, I want to use Ovi map in my iPhone application. I searched for Ovi map on google but presently it is not open.Basically I want to know following things OVi map service is from Nokia. So can i use Ovi Map in my iPhone application. If answer of 1 point is Yes, then where I found support info(code sample/classes/framework) for iPhone. Please advice

    Read the article

  • How to detect Java agents, JVMTI, etc...

    - by Andrew Westberg
    How does one secure the Java environment when running on a machine you don't control? What is to stop someone from creating a java agent or native JVMTI agent and dumping bytecode or re-writing classes to bypass licensing and/or other security checks? Is there any way to detect if any agents are running from Java code? From JNI? From a JVMTI agent?

    Read the article

  • C# inheritance of fields

    - by Emil D
    This is probably a silly question, but here it goes.Imagine you have the following classes: public class C { } public class D : C { //A subclass of C } public class A { C argument; } Now, I want to have a class B, that inherits from A.This class would obviously inherit the "argument" field, but I wish to force the "argument" field in B to be of type D, rather than C.Since D inherits from C this shouldn't create any problems. So, how would achieve this in c# ?

    Read the article

  • Lazy property loading in Nhibernate and Spring

    - by Khash
    I'm using NHibernate 2.1.2 and Spring 1.3 I have two Text columns (blobs) in one of my classes. I'm trying to use lazy="true" for the mapping of those properties but NHProfiler still shows the two columns being added to the SELECT statement when the main object is loaded. I'm using Spring.NHibernate session factory and have configured ProxyFactory with both Castle and Spring with no luck.

    Read the article

  • Java: why does extending need an empty constructor?

    - by HH
    I have classes SearchToUser and getFilesToWord. GetFilesToWord must inherit SearchToUser fields. Extending works if an empty construction in SearchToUser-class, otherwise: cannot find symbol symbol : constructor SearchToUser() location: class SearchToUser public class GetFilesToWord extends SearchToUser{ ^ 1 error make: *** [all] Error 1 I cannot understand why the empty constructor is required for extending.

    Read the article

  • How to bundle a native library and a JNI library inside a JAR?

    - by Alex B
    The library in question is Tokyo Cabinet. I want is to have the native library, JNI library, and all Java API classes in one JAR file to avoid redistribution headaches. There seems to be an attempt at this at GitHub, but It does not include the actual native library, only JNI library. It doesn't work (for me): when I use this JAR, the JVM does not even seem to find the JNI library which is packaged inside the JAR: java.lang.UnsatisfiedLinkError: no jtokyocabinet in java.library.path (tokyo_cabinet.clj:19)

    Read the article

  • how to implement IOC without a global static service?

    - by Michel
    Hi, we want to use Unity for IOC. All i've seen is the implementation that there is one global static service which holds a reference to the Unity container, which registers all interface/class combinations and every class asks that object: give me an implementation for Ithis or IThat. Frequently i see a response that this pattern is not good because it leads to a dependency from ALL classes to this service. But what i don't see often, is: what is the alternative way? Michel

    Read the article

  • Does IE 7 support the content pseudo-class?

    - by zac
    I am generating pipes in my list using pseudo-classes and it works fine except they are not being rendered in IE 7. The code looks like: .brandLinks a:after { margin: 0 4px; content: "|"; } .brandLinks a:last-child:after { content: " " } Is this just something IE 7 does not do or is my code wonky?

    Read the article

  • How to set multiple permissions in one class view, depending on http request

    - by andrew13331
    How can I change the permissions depending on if it is a get or a post. Is it possible to do it in one class or would I have to separate it out into two classes? If its a get I want "permission_classes = (permissions.IsAuthenticated)" and if its a post I want "permission_classes = (permissions.IsAdminUser)" class CategoryList(generics.ListCreateAPIView): queryset = QuestionCategory.objects.all() serializer_class = QuestionCategorySerializer permission_classes = (permissions.IsAuthenticated,)

    Read the article

  • class browsing in django

    - by jamida
    I'd like to browse active classes in Django. I think I'd learn a lot that way. So what's a good way to do that? I could use IDLE if I knew how to start Django from within IDLE. But as I'm new to Python/Django, I'm not particularly wedded to IDLE. Other alternatives?

    Read the article

  • Hibernate + Spring : cascade deletion ignoring non-nullable constraints

    - by E.Benoît
    Hello, I seem to be having one weird problem with some Hibernate data classes. In a very specific case, deleting an object should fail due to existing, non-nullable relations - however it does not. The strangest part is that a few other classes related to the same definition behave appropriately. I'm using HSQLDB 1.8.0.10, Hibernate 3.5.0 (final) and Spring 3.0.2. The Hibernate properties are set so that batch updates are disabled. The class whose instances are being deleted is: @Entity( name = "users.Credentials" ) @Table( name = "credentials" , schema = "users" ) public class Credentials extends ModelBase { private static final long serialVersionUID = 1L; /* Some basic fields here */ /** Administrator credentials, if any */ @OneToOne( mappedBy = "credentials" , fetch = FetchType.LAZY ) public AdminCredentials adminCredentials; /** Active account data */ @OneToOne( mappedBy = "credentials" , fetch = FetchType.LAZY ) public Account activeAccount; /* Some more reverse relations here */ } (ModelBase is a class that simply declares a Long field named "id" as being automatically generated) The Account class, which is one for which constraints work, looks like this: @Entity( name = "users.Account" ) @Table( name = "accounts" , schema = "users" ) public class Account extends ModelBase { private static final long serialVersionUID = 1L; /** Credentials the account is linked to */ @OneToOne( optional = false ) @JoinColumn( name = "credentials_id" , referencedColumnName = "id" , nullable = false , updatable = false ) public Credentials credentials; /* Some more fields here */ } And here is the AdminCredentials class, for which the constraints are ignored. @Entity( name = "admin.Credentials" ) @Table( name = "admin_credentials" , schema = "admin" ) public class AdminCredentials extends ModelBase { private static final long serialVersionUID = 1L; /** Credentials linked with an administrative account */ @OneToOne( optional = false ) @JoinColumn( name = "credentials_id" , referencedColumnName = "id" , nullable = false , updatable = false ) public Credentials credentials; /* Some more fields here */ } The code that attempts to delete the Credentials instances is: try { if ( account.validationKey != null ) { this.hTemplate.delete( account.validationKey ); } this.hTemplate.delete( account.languageSetting ); this.hTemplate.delete( account ); } catch ( DataIntegrityViolationException e ) { return false; } Where hTemplate is a HibernateTemplate instance provided by Spring, its flush mode having been set to EAGER. In the conditions shown above, the deletion will fail if there is an Account instance that refers to the Credentials instance being deleted, which is the expected behaviour. However, an AdminCredentials instance will be ignored, the deletion will succeed, leaving an invalid AdminCredentials instance behind (trying to refresh that instance causes an error because the Credentials instance no longer exists). I have tried moving the AdminCredentials table from the admin DB schema to the users DB schema. Strangely enough, a deletion-related error is then triggered, but not in the deletion code - it is triggered at the next query involving the table, seemingly ignoring the flush mode setting. I've been trying to understand this for hours and I must admit I'm just as clueless now as I was then.

    Read the article

< Previous Page | 162 163 164 165 166 167 168 169 170 171 172 173  | Next Page >