private utility functions. pick some ideas if you wish...