mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-06 12:00:04 +02:00
GP-4988 Created flow chart function graph layout
This commit is contained in:
parent
954ff4e124
commit
0a5a2ce9d8
60 changed files with 6570 additions and 1312 deletions
|
@ -4,9 +4,9 @@
|
|||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
|
@ -485,4 +485,21 @@ public class CollectionUtils {
|
|||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the only element from the given collection; null if the collection is null or empty
|
||||
* or size is greater than 1. This is meant to clients to get the one and only element in
|
||||
* a collection of size 1.
|
||||
*
|
||||
* @param c the collection
|
||||
* @return the item
|
||||
* @see #any(Collection)
|
||||
*/
|
||||
public static <T> T get(Collection<T> c) {
|
||||
if (c == null || c.size() > 1) {
|
||||
return null;
|
||||
}
|
||||
return any((Iterable<T>) c);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue