Search:

Type: Posts; User: QtFalcon

Search: Search took 0.07 seconds.

  1. [SOLVED] Re: Iinitialization of members. From Qt (C++) to Java

    Sorry! There are no mistakes :)
  2. [SOLVED] Re: Should not have trown any exceptions. But it throw: Error: incorrect "Phone Number" field

    Yes! I've just added '!' Thanks! :)



    if ( !matcherForPhoneNumber.find() ) {
    throw new ErrorPhoneNumber( phoneNumber );
    }
  3. [SOLVED] Should not have trown any exceptions. But it throw: Error: incorrect "Phone Number" field

    Hi,

    Help me to find mistake. I receive this message in my netbeans-report during testing:



    FreeFunctions.java


    /*
  4. [SOLVED] Re: Iinitialization of members. From Qt (C++) to Java

    This line doesn't work:


    this( "", "", "", "", "" );




    /**
    *
  5. Replies
    3
    Views
    1,318

    [SOLVED] Re: Test noExceptions

    I see that it is normal :D

    Such I test methods with exceptions:


    @Rule
    public ExpectedException exception = ExpectedException.none();

    // ...
  6. [SOLVED] Re: Iinitialization of members. From Qt (C++) to Java

    Thanks! It is how in C++ :D



    public class Person
    {
    Person( String nickName,
    String firstName,
    String lastName,
    String phoneNumber,
  7. Replies
    3
    Views
    1,318

    [SOLVED] Re: Test noExceptions

    Thanks!

    Is this normal?



    /**
    * Test of checkPersonFields method, of class FreeFunctions.
    */
    @Test
  8. Replies
    3
    Views
    1,318

    [SOLVED] Test noExceptions

    Hi,

    I want to test that a function has no any exceptions.

    In C++ and Google Test Framework (GTest) it will look like this:


    ASSERT_NO_THROW({
    actual = divide(a, b);
    ...
  9. [SOLVED] Re: Iinitialization of members. From Qt (C++) to Java

    What's the difference between:


    public class Example {
    public Example(int x, int y) {
    setMethodX(x);
    setMethodY(y);
    }
    }
  10. [SOLVED] Re: Iinitialization of members. From Qt (C++) to Java

    No :)

    How to set default values in constructor how in Qt:



    class Person
    {
    public:
    Person( QString nickName = QString( "" ),
  11. [SOLVED] Re: Iinitialization of members. From Qt (C++) to Java

    Please, see my code:



    /*
    * To change this license header, choose License Headers in Project Properties.
    * To change this template file, choose Tools | Templates
    * and open the template in...
  12. [SOLVED] Iinitialization of members. From Qt (C++) to Java

    Hi,

    Please, help me to write analog of this code in Java:



    #include <QString>

    class Person
    {
Results 1 to 12 of 12