Low to High Values in HashMap

Hello everyone, I wanted to display some values and keys of a hashmap. But I want to display them in order of values. Is there anyway to do this? The values of each key is pretty random and I'm not sure how I could sort or display the hashMap in such an order.
Any ideas on how this might be achieved easily?

For reference for anyone else having the same problem. =)
     public HashMap hashMapNumSort(HashMap hashMap){
          // to hold the result
          HashMap map = new LinkedHashMap();
          List yourMapKeys = new ArrayList(hashMap.keySet());
          List yourMapValues = new ArrayList(hashMap.values());
          TreeSet sortedSet = new TreeSet(yourMapValues);
          Object[] sortedArray = sortedSet.toArray();
          int size = sortedArray.length;
          for (int i=0; i<size; i++) {
             map.put
                (yourMapKeys.get(yourMapValues.indexOf(sortedArray)),
          sortedArray[i]);
          return map;
Edited by: thursdasy on Jan 8, 2010 11:21 PM                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

Similar Messages

  • Select-options split date into month and assign to low and high

    Hi,
       In my select-options i am giving BEDAT (01.04.2004 TO 30.10.2005).I need to split month and
    year in separate fields.that is
    select-option_low-month in one field
    select-option_high-month in second field
    select-option_low-year in third field
    select-option_high-year in fourth field.
    Finally i need to move these four fields to it_final.
    select * from mbewh into corresponding fields of table it_mbewh
               for all entries in it_final where matnr = it_final-matnr and
               bwkey = it_final-werks and lpmon = ? and lfgja = ?
               and  bklas <> ' '.
    what input i have to give in lpmon and lfgja in select query to get for lfmon (04 to 10)
    and lfgja (2004 to 2005).
    suggest some ideas.

    Hi ,
    Can you please check the following code.
    Hi ,
    data :  l_low_yr(4),
              l_high_yr(4),
              l_low_mon(2),
              l_high_mon(2).
    Splitting the select option date to month and year into low and higher values
    l_low_yr        =   s_date-low+00(04). "  Year low value from the date range
    l_low_mon    =   s_date-low+04(02). "  Month low value from the date range
    l_high_yr      =   s_date-high+00(04)."  Year high value from the date range
    l_high_mon   =   s_date-high+04(02)." Month high value from the date range
    selecting the data from the table mbewh based on some conditions.
    select * from mbewh into corresponding fields of table it_mbewh
               for all entries in it_final where matnr = it_final-matnr and
               bwkey = it_final-werks and lfmon BETWEEN  l_low_mon and l_high_mon
    and lfgja BETWEEN l_low_yr and l_high_yr   and  bklas EQ  ' '.
    This select will retrive the desired data records from the table MBEWH.
    Please let me know if this works according to your requirement.
    Thanks and Regards
    Saritha

  • How to pass the low value and high  values for select options.

    Hi,
           In selection screen I want to display the first date, last date of this month as a default value in low and high fields.  Please exaplain me how.
    Thanks and Regards,
    Surya

    hI,
         Very thanks ,
            I  did it what u said now. but those contents does not displaying on the screen.
    In this order I write the code. Please explain me
    SELECT-OPTIONS s_date FOR likp-wadat_ist.
    DATA  BEGIN TYPE wadat_ist.
    DATA LAST TYPE wadat_ist.
    initialization.
    s_date-low = BEGIN.
    s_date-high = LAST.
    at selection-screen output.
    CALL FUNCTION 'HRWPC_BL_DATES_MONTH_INTERVAL'
      EXPORTING
        datum                =  SY-DATUM
        month_pst            =  '0'
        month_ftr            =   '0'
    IMPORTING
       BEGDA                =  BEGIN
       ENDDA                =   LAST
    EXCEPTIONS
      INVALID_VALUES       = 1
      OTHERS               = 2
    IF sy-subrc <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
            WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.

  • Why am I getting very high values for the very low frequency region of a random signal?

    I am tyring to produce a power spectrum graph for a Tachogram data, related to Heart Rate Variability Analysis. This data can be thought to be as a random signal, but has a frequency spectrum range of 0 - 1HZ.
    The problem that I am facing is, I am getting very high values for very low frequency region, closer to DC value. Even the DC value is really high, in the range 10^8. It is suppose to be a low number. Any suggestions would be appreciated.
    Thanks.

    Here is what my work is all about. I am trying to develop a software for Heart Rate Variability analysis. I am not sure if you are aware of heart beat waveforms, they are bunch spikes, occuring at irregular intervals. We have to do analysis on this waveform. How ? First we have to create a plot called Tachogram. This is done by, for example, let's name the first spike R1, the second one R2, and the third one R3, and so on. This is how the co-ordinate points are created. (R1, R2-R1), (R2, R3-R2), and so on...
    Here R1 is the time instant at which the spike R1 occurs, and R2-R1 is the time difference between these peak occurences. So, if we plot these values, then it gives us one like what you saw on your time domain plot. What we have to do with this signal is, we have to apply FFT technique to produce its power spectrum for analysis. Generally the frequency range of the spectrum goes from 0 - 0.5 Hz. They part this range into VLF, LF, and HF, and analyze how much power is distributed in these regions. The distribution would tell you if you were stressed out,or have worked out, things like that. Normally, you can view spikes around LF, HF region. If you had viewed the power spectrum for the data that I sent, then that's what it pretty much looks like. I think I have said a lot about it now. Hope you get it.
    We were talking about the "other component", I can't really see where it lies, must be in the 60-80 sec. range in the graph. If you look at the spectrum, I am getting a huge value around 0.0033 Hz, how do I minimize or remove this ?
    Also, I am using Unevenly Spaced Signal Spectrum.vi, I am not sure what excactly is the unit for the Power Spectrum output. Technical Papers denote, Periodogram algorithm used by this VI, gives Power Spectral Density ? If that's right, then the unit is V^2/HZ.
    Please advise.
    Again, I should thank you for your time and effort.
    I have to meet a deadline this week in finishing this project, and your help is immense to me at this point.
    Thanks & Best Regards,

  • Table AGR_1251: Search between a range of the field "LOW" and "HIGH

    Hello Experts,
    i've got a problem by searching all users who have the authority for a transaction.
    The transaction was written in a parameter, called p_trans.
    I've the Tables AGR_1251, AGR_AGRS and AGR_USERS.
    I know what I've to do.
    Here is my Join.
    SELECT agru~uname
      INTO CORRESPONDING FIELDS OF TABLE gt_users
      FROM agr_1251 as ag12
      INNER JOIN agr_agrs as agrs
        ON  ag12~agr_name = agrs~child_agr
      INNER JOIN agr_users as agru
        ON  agrs~agr_name = agru~agr_name        
      INNER JOIN usr01 as us
        ON  agru~uname = us~bname
      WHERE ag12~object = 'S_TCODE' AND
                   ag12~field  = 'TCD' AND
                   ???? parameter p_trans between ag~low and ag~high????
    SELECT agru~uname
      APPENDING TABLE gt_users
      FROM agr_1251 as ag12
      INNER JOIN agr_agrs as agrs
        ON  ag12~agr_name = agrs~child_agr
      INNER JOIN agr_users as agru
        ON  agrs~child_agr = agru~agr_name       
      INNER JOIN usr01 as us
        ON  agru~uname = us~bname
      WHERE ag12~object = 'S_TCODE' AND
                   ag12~field  = 'TCD' AND
                   ???? parameter p_trans between ag~low and ag~high????                       
      SORT gt_users BY uname ASCENDING.
      DELETE ADJACENT DUPLICATES FROM gt_users COMPARING uname.
    Here is my question:
    In my code are question marks...here i want to say, that my transaction lays between the fields LOW and HIGH.
    But how can i say, that in WHERE.
    I have to say... Search that agr_name, where object = s_tcode, field=tcd and where my transaction lies between.
    For example: low is T and high is X and i have the transaction va21.
    So i must find out, in which range lays ma transaction.
    I hope somebody understands me
    Thanks!
    Regards,
    Marcel

    Hi Marcel,
    You are mentioning it as a parameter between having low & high values. Is it a parameter or select option.
    If its a parameter, then anyway it will have only single value at any point of time.
    If its a select option, then you need to use
    select * from
    and tcode in s_tcode.
    Thanks,
    Best regards,
    Prashant

  • Dynamic variant for select option High value

    Hi ,
    Please help me in creating dynamic variable for a select option date field high value.
    II tried the following method:
    1. Enter the values in the selection screen
    2. Save the variant using the SAVE button
    3. In the next screen for the date variable select the 'Selection variable' checkbox (L) and click on the button 'Selection variable' in the toolbar.
    4. Now you will see this variable in the next screen with 3 types of buttons. Click on the middle button (i.e. D - Dynamic date calculation).
    5. Click on the down arrow button and select the option 'Current Date'.
    5. Save the variant.
    But it is saving the date value in Field LOW of select option( From value).
    I need it in TO field( High value).
    Please help.
    regards,
    Sheeba

    Hi Sheeba
        we can do it other way .. Select the same steps as you have done but after the assigning the value current date to low ..click on the selection option push button at the application bar and choose the 'less than or equal to' option to your select option value and try the same ....
    I guess this would throw you same results as that of the value in the high value button
    Cheers,
    Jacks.

  • Low and High sliders in Audi

    Hellow!
    I use Audigy2 Value for a long time but never had this question in my mind. Now i have to make music arrangement of several songs and mix a lot of tracks in Sonar, so i extremly need to hear "true" frequencies of my tracks in monitors while mixing. And the question is - what the right position of Low and High sliders in the Audigy 2 Mixer to archi've "orriginal" sound, without any frequency disbalance? (i usually move then from 50% to 00% and, of course, it's not the right way). Heeeelp, pleeeease!

    For all the equaliser sliders, the middle position of the slider is the neutral one. Above that, the freqv is accentuated, under that, the freqv is attenuated.
    The Creative marking in % is a unfortunate one, but 50% is the position that would be neutral.

  • In VB how do I pass my low and high limit results from a TestStand Step into the ResultList and how do I retrieve them from the same?

    I am retrieving high and low limits from step results in VB code that looks something like this:
    ' (This occurs while processing a UIMsg_Trace event)
    Set step = context.Sequence.GetStep(previousStepIndex, context.StepGroup)
    '(etc.)
    ' Get step limits for results
    Set oStepProperty = step.AsPropertyObject
    If oStepProperty.Exists("limits", 0&) Then
    dblLimitHigh = step.limits.high
    dblLimitLow = step.limits.low
    '(etc.)
    So far, so good. I can see these results in
    VB debug mode.
    Immediately after this is where I try to put the limits into the results list:
    'Add Limits to results
    call mCurrentExecution.AddExtraResult("Step.Limits.High", "UpperLimit")
    call mCurrentExecution.AddExtraResult("Step.Limits.Low", "LowerLimit")
    (No apparent errors here while executing)
    But in another section of code when I try to extract the limits, I get some of the results, but I do not get any limits results.
    That section of code occurs while processing a UIMsg_EndExecution event and looks something like this:
    (misc declarations)
    'Get the size of the ResultList array
    Call oResultList.GetDimensions("", 0, sDummy, sDummy, iElements, eType)
    'Step through the ResultList array
    For iItem = 0 To iElements - 1
    Dim oResult As PropertyObject
    Set oResult = oResultList.GetPropertyObject("[" & CStr(iItem) & "]", 0)
    sMsg = "StepName = " & oResult.GetValString("TS.StepName", 0) & _
    ", Status = " & oResult.GetValString("Status", 0)
    If oResult.Exists("limits", 0&) Then
    Debug.Print "HighLimit: " & CStr(oResult.GetValNumber("Step.Limits.High", 0))
    Debug.Print "LowLimit: " & CStr(oResult.GetValNumber("Step.Limits.Low", 0))
    End If
    '(handle the results)
    Next iItem
    I can get the step name, I can get the status, but I can't get the limits. The "if" statement above which checks for "limits" never becomes true, because, apparently the limit results never made it to the results array.
    So, my question again is how can I pass the low and high limit results to the results list, and how can I retrieve the same from the results list?
    Thanks,
    Griff

    Griff,
    Hmmmm...
    I use this feature all the time and it works for me. The only real
    difference between the code you posted and what I do is that I don't
    retrieve a property object for each TestStand object, instead I pass the
    entire sequence context (of the process model) then retrieve a property
    object for the entire sequence context and use the full TestStand object
    path to reference sub-properties. For example, to access a step's
    ResultList property called "foo" I would use the path:
    "Locals.ResultList[0].TS.SequenceCall.ResultList[].Foo"
    My guess is the problem has something to do with the object from which
    you're retrieving the property object and/or the path used to obtain
    sub-properties from the object. You should be able to break-point in the
    TestStand sequence editor immediately after the test step in question
    executes, then see the extra results in the step's ResultList using the
    context viewer.
    For example, see the attached sequence file. The first step adds the extra
    result "Step.Limits" as "Limits", the second step is a Numeric Limit (which
    will have the step property of "Limits") test and the third step pops up a
    dialog if the Limits property is found in the Numeric Limit test's
    ResultList. In the Sequence Editor, try executing with the first step
    enalbled then again with the first step skipped and breakpoint on the third
    step. Use the context viewer to observe where the Limits property is added.
    That might help you narrow in on how to specify the property path to
    retrieve the value.
    If in your code, you see the extra results in the context viewer, then the
    problem lies in how you're trying to retrieve the property. If the extra
    results aren't there, then something is wrong in how you're specifying them,
    most likely a problem with the AddExtraResult call itself.
    One other thing to check... its hard to tell from the code you posted... but
    make sure you're calling AddExtraResult on the correct execution object and
    that you're calling AddExtraResult ~before~ executing the step you want the
    result to show up for. Another programmer here made the mistake of assuming
    he could call AddExtraResult ~after~ the step executed and TestStand would
    "back fill" previously executed steps. Thats not the case. Also, another
    mistake he made was expecting the extra results to appear for steps that did
    not contain the original step properties. For example, a string comparison
    step doesn't have a "Step.Limits.High" property, so if this property is
    called out explicitly in AddExtraResult, then the extra result won't appear
    in the string comparison's ResultList entry. Thats why you should simply
    specify "Step.Limits" to AddExtraResul so the Limits container (whose
    contents vary depending on the step type) will get copied to the ResultList
    regardless of the step type.
    I call AddExtraResult at the beginning of my process model, not in a UI
    message handler, so there may be some gotcha from calling it that way. If
    all else fails, try adding the AddExtraResult near the beginning of your
    process model and see if the extra results appear in each step's ResultList.
    Good luck,
    Bob Rafuse
    Etec Inc.
    [Attachment DebugExtraResults.seq, see below]
    Attachments:
    DebugExtraResults.seq ‏20 KB

  • Infopackage not taking High value

    Hi all,
    I have a routine in my infopackage. i am trying to restrict the load for 48 months and load a cube.
    I have this routine in there.
    data: l_idx like sy-tabix,
            v_date1 like sy-datum,
            v_date2 like sy-datum,
            v_char(6),
            v_char1(10),
            v_char2(10).
      read table l_t_range with key
           fieldname = 'CALMONTH'.
      l_idx = sy-tabix.
      v_date1 = sy-datum - 36 * 30.
      v_date2 = sy-datum + 12 * 30.
      CLEAR: L_T_RANGE-LOW, L_T_RANGE-HIGH.
      WRITE V_DATE1 TO v_char1  MM/DD/YYYY.
      WRITE V_DATE2 TO v_char2 MM/DD/YYYY.
      CLEAR: V_CHAR.
      v_char(4)   = v_char1+6(4).
      v_char+4(2) = v_char1(2).
      MOVE V_CHAR TO L_T_RANGE-LOW.
      CLEAR: V_CHAR.
      v_char(4)   = v_char2+6(4).
      v_char+4(2) = v_char2(2).
      MOVE V_CHAR TO L_T_RANGE-HIGH.
      modify l_t_range index l_idx.
      p_subrc = 0.
    I am able to populate Low value but it is not High value.
    Thanks,
    Vasanth.

    Hi Swarna,
    but if you map 10 values in the syndicator to your predefned schema and you create a xml file with it. Assume this file contains now only 8 tags with values since 2 mapped values did not exist on MDM side.
    XI is suppose to pick the file up and perform the mapping based on the same XML schema. The file will not be taken by XI since the XML file does not contain the same number of fields that XI is expecting based on the XML schema.
    Does anyone know how to handle this?
    This is a very common demand for a centralization scenario where you have to syndicate data back to R/3.
    How do you still keep the orginal XML schema in the XML file also without having values?
    Thanks for answering.
    BR
    Nicolas

  • Organizing data from low to high?

    Hi Community,
    I'm totally out of numbers and such, but I need to organize some data from low values to high values automatically, like for example, the earnings in 12 months, which are always variables but I would like to organize them from the lower to the higher. Is there a way to organize this automatically?
    Thanks in advance,
    Mart

    Mart,
    Would sorting your rows by column content do it for you?
    Jerry

  • Cumulative SUM based on Measure FROM LOWER to HIGHER

    Hello,
    I tried to find some post like mine but i did not find it.
    I have this scenario:
    Filter
    Cod Store
    Value
    Cenario 1
    City: RJ
    1112
    574924.05
    Type: Infantil
    1449
    617860.04
    Store: Carrefour
    1023
    873678.53
    But i need to create a new calculated member based on VALUE from LOWER to HIGH making a cumulative sum like this:
    Filter
    Cod Store
    Value
    What i NEED
    Cenario 1
    City: RJ
    1112
    574924.05
    574924.05
    Type: Infantil
    1449
    617860.04
    1192784.09
    Store: Carrefour
    1023
    873678.53
    2066462.62
    Here it is ordered by VALUE already, but in my cube is may not be. Can someone help me? i trying many ways but no one works fine.
    <b>Fabrizzio A. Caputo</b><br/> Certificações:<br/> MCT<br/> MCC<br/> Oracle OCA 11g<br/> MCITP SQL Server 2008 BI<br/> MCITP SQL Server 2008 Implementation and Maintenance<br/> MCITP SQL Server
    2008 Developer<br/> ITIL V3 Foundation <br/> Blog Pessoal: <a href="http://fabrizziocaputo.wordpress.com">www.fabrizziocaputo.wordpress.com</a><br/> Email: [email protected]

    Hi Fabrizzio,
    Most of the running total snippets you will find in the forums contains elements like currentmember, prevmember or ranges [A : B] that also refers to members.  Unfortunately the relative position of those elements  are extracted from the hierarchy
    level  of the correspondent members as defined in the cube dimensions and not from the ordered (query scope) set.
    The usual solution is to define a measure as the rank in the ordered set and take  the cumulative sum with head ():   sum(  head( ordered set, till the rank) , by the value measure ).
    If you choose the recursive solution for the running total you could use item() in combination with rank: maybe something like orderedset.item(rank measure) as an ersatz of currentmember.
    Philip,

  • Skills/Knowledge needed for low latency/high throughput development

    I have a meeting/technical interview next week for a department at work (foreign exchange). It is going to be a technical interview. I know from the team that they use java heavily, using jvm optimisation, modifications to garbage collection, and have servers placed as close to the exchanges as possible to minimise latency. They said they need to work in "micro seconds" opposed to milliseconds and this means being as efficient as possible.
    I love java development, but am relatively inexperienced but i really want this job. What would you suggest needs to be researched for a role like this in order to stand the best chance of getting it. I dont think knowing about inheritance, auto boxing/unboxing is going to help much in this?
    I am thinking potentially looking at new releases to the java platform such as closures to demonstrate i am keeping up to date with current trends but as for the rest of it i am not really sure.
    I would really appreciate some pointers around considerations for low latency / high volume / highly concurrent development in java if possible.
    Just for a little more detail, the backend uses KDB database with a java fx front end
    Thanks

    ea33334c-b8a8-437b-9807-a170194a1950 wrote:
    it is part of my graduate placement. i have to do a rotation to a new team. i hope you were only so blunt because i fogot to mention this ?
    How is any of what you just said relevant? I was 'so blunt' because you seem to be setting yourself (and your potential new teammates) up for failure. Based on what you posted you are nowhere near qualified for the task you described.
    Further there is absolutely NOTHING in what you posted that talks about any skills that you DO have. You didn't mention A SINGLE THING about your skillset or how you might add value to that team or project.
    Your educational experience should provide some guidelines for how you advance your skills in ANY subject. Each college course has prerequisites and for good reason. Taking a course when you don't have the proper foundation and background is the surest way to fail. Colleges don't let you do it. You have likely been in classes where some of your classmates were clearly in over their head. For those people that course will be nothing but headache and heartache and their chances of success are minimal.
    It is the same with most endeavors including the one you mention in your thread. Naturally you want to challenge yourself when you join a new project or team but you have to be able to hold your own and contribute. Taking on a task or project when you don't have the necessary experience will not only subject you to unnecessary problems but you can easily have a large negative impact on the entire team and project.
    I suggest you try to find a different project where whatever (still unknown to us) skills you have can be used to contribute to the team effort. No one expects new team members to know everything or as much as more experienced developers but they also don't want an 'anchor' that is going to drag them down.

  • %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm

    Hi,
    I am facing a strange problem in one of my Cisco Catalyst 4900M switch. We have a ten gig WAN link which went down (error-disabled) couple of weeks back with logs suggesting Low TX power.
    Tried followingtroubleshooting approach, but it did not resolve the problem.
    SFP replaced
    Tried connecting the link on a different port.
    Fibers tested and found to be OK
    Performed loop test and was able to see the loop on both end of the P2P link.
    Replaced the Cables between PTT demarcation till switch patch panel.
    Switch Logs:
    IOS Version: bootflash:cat4500e-entservices-mz.150-2.SG1.bin
    Model: Cisco Catalyst 4900M
    *Jun 19 12:32:36.582: %PM-4-ERR_DISABLE: link-flap error detected on Te1/1, putting Te1/1 in err-disable state
    *Jun 19 12:34:04.154: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 12:44:04.254: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 12:54:04.354: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 13:04:04.454: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 13:14:04.558: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 13:24:04.658: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 13:34:04.761: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 13:44:04.861: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 13:54:04.961: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 14:04:05.061: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 14:14:05.161: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 14:24:05.261: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 14:34:05.361: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 14:44:05.461: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 14:54:05.561: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    *Jun 19 15:04:05.661: %SFF8472-5-THRESHOLD_VIOLATION: Te1/1: Tx power low alarm; Operating value: -40.0 dBm, Threshold value: -12.2 dBm.
    Switch1#
    Switch1#
    Switch1#
    Switch1#sh int te1/1
    TenGigabitEthernet1/1 is down, line protocol is down (err-disabled)
      Hardware is Ten Gigabit Ethernet Port, address is 2c54.2de6.5100 (bia 2c54.2de6.5100)
      Description: ***P2P ***
      MTU 1500 bytes, BW 10000000 Kbit, DLY 10 usec,
         reliability 255/255, txload 1/255, rxload 1/255
      Encapsulation ARPA, loopback not set
      Keepalive set (10 sec)
      Full-duplex, 10Gb/s, link type is auto, media type is 10GBase-LR
      input flow-control is off, output flow-control is off
      ARP type: ARPA, ARP Timeout 04:00:00
      Last input 02:39:04, output never, output hang never
      Last clearing of "show interface" counters 2w0d
      Input queue: 0/2000/0/0 (size/max/drops/flushes); Total output drops: 0
      Queueing strategy: fifo
      Output queue: 0/40 (size/max)
      5 minute input rate 0 bits/sec, 0 packets/sec
      5 minute output rate 0 bits/sec, 0 packets/sec
         2367 packets input, 199072 bytes, 0 no buffer
         Received 2367 broadcasts (2367 multicasts)
         1 runts, 0 giants, 0 throttles
         5 input errors, 4 CRC, 0 frame, 0 overrun, 0 ignored
         0 input packets with dribble condition detected
         5951 packets output, 453948 bytes, 0 underruns
         0 output errors, 0 collisions, 13 interface resets
         0 babbles, 0 late collision, 0 deferred
         0 lost carrier, 0 no carrier
         0 output buffer failures, 0 output buffers swapped out
    Switch1#
    Switch1#sh int te1/1 transceiver detail
    ITU Channel not available (Wavelength not available),
    Transceiver is internally calibrated.
    mA: milliamperes, dBm: decibels (milliwatts), NA or N/A: not applicable.
    ++ : high alarm, +  : high warning, -  : low warning, -- : low alarm.
    A2D readouts (if they differ), are reported in parentheses.
    The threshold values are calibrated.
                                  High Alarm  High Warn  Low Warn   Low Alarm
              Temperature         Threshold   Threshold  Threshold  Threshold
    Port       (Celsius)          (Celsius)   (Celsius)  (Celsius)  (Celsius)
    Te1/1       30.7                74.0        70.0         0.0       -4.0
                                  High Alarm  High Warn  Low Warn   Low Alarm
               Voltage            Threshold   Threshold  Threshold  Threshold
    Port       (Volts)            (Volts)     (Volts)    (Volts)    (Volts)
    Te1/1      0.00                   N/A         N/A         N/A        N/A
               Optical            High Alarm  High Warn  Low Warn   Low Alarm
               Transmit Power     Threshold   Threshold  Threshold  Threshold
    Port       (dBm)              (dBm)       (dBm)      (dBm)      (dBm)
    Te1/1      -40.0                 4.4         0.4        -8.2      -12.2
               Optical            High Alarm  High Warn  Low Warn   Low Alarm
               Receive Power      Threshold   Threshold  Threshold  Threshold
    Port       (dBm)              (dBm)       (dBm)      (dBm)      (dBm)
    Te1/1      -12.3                 4.4         0.4       -14.4      -18.4

    I did replace the SFP with a new one.
    Interface Te1/2 is up and working.
    SESK_P2P10G-4900MSOD-SW1#sh int te1/2 transceiver de
    ITU Channel not available (Wavelength not available),
    Transceiver is internally calibrated.
    mA: milliamperes, dBm: decibels (milliwatts), NA or N/A: not applicable.
    ++ : high alarm, +  : high warning, -  : low warning, -- : low alarm.
    A2D readouts (if they differ), are reported in parentheses.
    The threshold values are calibrated.
                                  High Alarm  High Warn  Low Warn   Low Alarm
              Temperature         Threshold   Threshold  Threshold  Threshold
    Port       (Celsius)          (Celsius)   (Celsius)  (Celsius)  (Celsius)
    Te1/2       34.6                74.0        70.0         0.0       -4.0
                                  High Alarm  High Warn  Low Warn   Low Alarm
               Voltage            Threshold   Threshold  Threshold  Threshold
    Port       (Volts)            (Volts)     (Volts)    (Volts)    (Volts)
    Te1/2      3.22                   N/A         N/A         N/A        N/A
               Optical            High Alarm  High Warn  Low Warn   Low Alarm
               Transmit Power     Threshold   Threshold  Threshold  Threshold
    Port       (dBm)              (dBm)       (dBm)      (dBm)      (dBm)
    Te1/2       -1.5                 4.4         0.4        -8.2      -12.2
               Optical            High Alarm  High Warn  Low Warn   Low Alarm
               Receive Power      Threshold   Threshold  Threshold  Threshold
    Port       (dBm)              (dBm)       (dBm)      (dBm)      (dBm)
    Te1/2       -3.6                 4.4         0.4       -14.4      -18.4

  • 10.6: Apple and our customers place a high value on simple, refined, creative, well thought through interfaces. They take more work but are worth it. Apple sets a high bar. If your user interface is complex or less than very good it may be rejected

      i am newbie in IOS  i am web developer
    so i use html 5 and i development jquery mobile based application.
    in my application i just call view from web.I used objective c webview .
    but my application rejected  following issues
    - Included low resolution/jagged image/s; see screenshot
    - Portions of your app loaded, refreshed, ran, and/or responded very slowly.
    - Was not optimized to support the device screen size and/or resolution; see screenshot
    - Did not integrate with iOS features.
    they said your app is slow but app speed is good(you can see here : http://teknonova.com/Map)
    they said did not integrate with ios features .yes i just call URL from web view?is it illegal?
    and they gave issues screenshot  there is no problem with screenshot .it is good : (http://a1523.phobos.apple.com/us/r30/Purple/v4/c3/76/8a/c3768ae0-9b41-820f-9315- 40db2afc57b6/temp..gwvpnmiu.png) 
    what should i do?
    should i delete and add new app?

    10.6: Apple and our customers place a high value on simple, refined, creative, well thought through interfaces. They take more work but are worth it. Apple sets a high bar. If your user interface is complex or less than very good it may be rejected
    for this problem what is a good solutions, how need to solve our problem, we need to published our apps. so plez telme the solution for this resons

  • Compare a String Array to get Higher value

    Hi, I'm trying to figure out how can I create a method in which I can compare my array of String by getting the higher value. For example I have an array called faces[]. What I would like to say is that if 2 is less than 5, and so forth print "blahhhh". I would appreciate some ideas on which is the best way to do this. Thanks a lot. Here is the code so far. I'm working on checkWinner() method
    import java.awt.*;
    import java.awt.event.*;
    import javax.swing.*;
    public class WarCard extends JFrame implements ActionListener {
         private Card deck[];
         private int currentCard, value, winner;
         private JPanel buttonPanel, labelPanel, textFieldPanel;
         private JButton buttons[];
         private JLabel labels[];
         private JTextField textFields[];
         public WarCard()
              super( "War! " );
              String faces[] = { "Ace", "Deuce", "Three", "Four", "Five", "Six",
                   "Seven", "Eight", "Nine", "Ten", "Jack", "Queen", "King" };
              String suits[] = { "Hearts", "Diamonds", "Clubs", "Spades" };
              deck = new Card[ 52 ];
              currentCard = -1;
              //populate deck
              for ( int count = 0 ; count < deck.length; count++ )
                   deck[ count ] = new Card( faces[ count % 13], suits[ count / 13 ] );
              // get content pane and create layout
              Container container = getContentPane();
              // create label grid
              labels = new JLabel[3];
                   labels[ 0 ] = new JLabel( "Player 1: ");
                   labels[ 1 ] = new JLabel( "Player 2: ");
                   labels[ 2 ] = new JLabel( "Shuffle cards to begin" );
              labelPanel = new JPanel();
              labelPanel.setLayout( new GridLayout( 3, labels.length ) );
              for ( int count = 0; count < labels.length; count++) {
                   labelPanel.add( labels[ count ] );
              }// end for loop
              container.add( labelPanel, BorderLayout.WEST );
              // create text field grid
              textFields = new JTextField[ 3 ];
                   textFields[ 0 ] = new JTextField( 20 );
                   textFields[ 1 ] = new JTextField( 20 );
                   textFields[ 2 ] = new JTextField( 20 );
              textFieldPanel = new JPanel();
              textFieldPanel.setLayout( new GridLayout( 3, textFields.length ) );
              for ( int count = 0; count < textFields.length; count++) {
                   textFields[ count ].setEditable( false );
                   textFieldPanel.add( textFields[ count ] );
              }// end for loop
              container.add( textFieldPanel, BorderLayout.EAST );     
              // create button grid          
              buttons = new JButton[ 3 ];
                   buttons[ 0 ] = new JButton( "Deal" );
                   buttons[ 1 ] = new JButton( "Shuffle" );
                   buttons[ 2 ] = new JButton( "Exit" );
              buttonPanel = new JPanel();
              buttonPanel.setLayout( new GridLayout( 1, buttons.length ) );
              for ( int count = 0; count < buttons.length; count++) {
                   buttons[ count ].addActionListener( this );
                   buttons[ 0 ].setEnabled( false );
                   buttonPanel.add( buttons[ count ] );
              }// end for loop
              container.add( buttonPanel, BorderLayout.SOUTH );
              setSize( 425, 150 );
              setVisible( true );
        private void checkWinner()
            int i = 0;
            for( i=0; i < 13; i++ ){
             if ( s[ 0 ].equals("2 of Spades") & s[ 1 ]!="2 of Spades" ){
                    txtGame[ 2 ].setText( " You Win " );
              else{
                   txtGame[ 2 ].setText( " Compuer Win" );
         public static void main( String agrs[] )
              WarCard application = new WarCard();
              application.setDefaultCloseOperation( JFrame.EXIT_ON_CLOSE );
         public void actionPerformed( ActionEvent event)
              String testString = "";
              for ( int count = 0; count < buttons.length; count++) {
                   if ( event.getSource() == buttons[ 0 ] ) {
                        Card dealt1 = dealPlayer1();
                        Card dealt2 = dealPlayer1();
                        if ( dealt1 != null || dealt2 != null ) {
                             textFields[ 0 ].setText( dealt1.toString() );
                             textFields[ 1 ].setText( dealt2.toString() );
                             labels[ 2 ].setText( "# of Cards : " + currentCard);
                        else {
                             textFields[ 2 ].setText( "All Cards Dealt" );
                             labels[ 2 ].setText( "Shuffle Cards to continue" );
                   else if ( event.getSource() == buttons[ 1 ] ) {
                        shuffle();
                        textFields[ 0 ].setText( " " );
                        textFields[ 1 ].setText( " " );
                        labels[ 2 ].setText( "Shuffled!");
                   else if ( event.getSource() == buttons[ 2 ] ) {
                        System.exit( 0 );
              }// end for loop
         }// end method actionPerformed
              private void shuffle()
              currentCard = -1;
              for ( int first = 0; first < deck.length; first++ ) {
                   int second = ( int ) ( Math.random() * 52 );
                   Card temp = deck[ first ];
                   deck[ first ] = deck[ second ];
                   deck[ second ]= temp;
              buttons[ 0 ].setEnabled( true );
         private Card dealPlayer1()
              if ( ++currentCard < deck.length )
                   return deck[ currentCard ];
              else {
                   buttons[ 0 ].setEnabled( false );
                   return null;
    }// end of WarCard
    class Card{
         private String face;
         private String suit;
         public Card( String cardFace, String cardSuit )
              face = cardFace;
              suit = cardSuit;
         public String toString()
              return face + " of " + suit;
         }// end toString
    }// end class WarCard

    assign an int value to the card and use < == >

Maybe you are looking for

  • Delete file in the filesystem

    Hello, I am developing an application with the apex. I created a section where you can upload files to the linux file system to a specific folder, not upload to the database, I do not want me to take unnecessary space. I can also download the file li

  • Issue with posting change note processing using movement type 309

    while processing Posting change note using transaction LT05, i am getting error 'Available quantity is less than selected quantity'. we need the quantity in posting change note to be picked from same storage bin from where it has been picked during t

  • Problems with syncing with iTunes

    Have had iPhone 4 for two (2) years and been syncing with itunes all that time. As of two days ago the sync process will not sync the calendars either way (from phone to PC or from PC to phone). PC has Win7 and XP Outlook. iPhone has 5.1.1 system (no

  • Intel KMS... Finaly useful

    After the 2.6.31 kernel and xf86-video-intel 2.9 kms performance is finaly on par with performace of xf86-video-intel 2.7 with EXA on GEM kernel. And also the system is much more stable, no more hardlocks, it's intel's finaly done something 'bout tho

  • Newbie having trouble with opt/rep regions

    Hi everyone. I'm migrating my site from simple, square html to nice, elegant css. I've done most of the work, but I'm having some trouble with templates. Here's an example of how a page created with a template will (hopefully) look: http://www.technf